/*!

JSZip - A Javascript class for generating and reading zip files
<http://stuartk.com/jszip>

(c) 2009-2014 Stuart Knightley <stuart [at] stuartk.com>
Dual licenced under the MIT license or GPLv3. See https://raw.github.com/Stuk/jszip/master/LICENSE.markdown.

JSZip uses the library pako released under the MIT license :
https://github.com/nodeca/pako/blob/master/LICENSE
*/
!function(a){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=a();else if("function"==typeof define&&define.amd)define([],a);else{var b;b="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,b.JSZip=a()}}(function(){return function a(b,c,d){function e(g,h){if(!c[g]){if(!b[g]){var i="function"==typeof require&&require;if(!h&&i)return i(g,!0);if(f)return f(g,!0);var j=new Error("Cannot find module '"+g+"'");throw j.code="MODULE_NOT_FOUND",j}var k=c[g]={exports:{}};b[g][0].call(k.exports,function(a){var c=b[g][1][a];return e(c?c:a)},k,k.exports,a,b,c,d)}return c[g].exports}for(var f="function"==typeof require&&require,g=0;g<d.length;g++)e(d[g]);return e}({1:[function(a,b,c){"use strict";function d(a){if(a){this.data=a,this.length=this.data.length,this.index=0,this.zero=0;for(var b=0;b<this.data.length;b++)a[b]=255&a[b]}}var e=a("./dataReader");d.prototype=new e,d.prototype.byteAt=function(a){return this.data[this.zero+a]},d.prototype.lastIndexOfSignature=function(a){for(var b=a.charCodeAt(0),c=a.charCodeAt(1),d=a.charCodeAt(2),e=a.charCodeAt(3),f=this.length-4;f>=0;--f)if(this.data[f]===b&&this.data[f+1]===c&&this.data[f+2]===d&&this.data[f+3]===e)return f-this.zero;return-1},d.prototype.readData=function(a){if(this.checkOffset(a),0===a)return[];var b=this.data.slice(this.zero+this.index,this.zero+this.index+a);return this.index+=a,b},b.exports=d},{"./dataReader":6}],2:[function(a,b,c){"use strict";var d="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";c.encode=function(a,b){for(var c,e,f,g,h,i,j,k="",l=0;l<a.length;)c=a.charCodeAt(l++),e=a.charCodeAt(l++),f=a.charCodeAt(l++),g=c>>2,h=(3&c)<<4|e>>4,i=(15&e)<<2|f>>6,j=63&f,isNaN(e)?i=j=64:isNaN(f)&&(j=64),k=k+d.charAt(g)+d.charAt(h)+d.charAt(i)+d.charAt(j);return k},c.decode=function(a,b){var c,e,f,g,h,i,j,k="",l=0;for(a=a.replace(/[^A-Za-z0-9\+\/\=]/g,"");l<a.length;)g=d.indexOf(a.charAt(l++)),h=d.indexOf(a.charAt(l++)),i=d.indexOf(a.charAt(l++)),j=d.indexOf(a.charAt(l++)),c=g<<2|h>>4,e=(15&h)<<4|i>>2,f=(3&i)<<6|j,k+=String.fromCharCode(c),64!=i&&(k+=String.fromCharCode(e)),64!=j&&(k+=String.fromCharCode(f));return k}},{}],3:[function(a,b,c){"use strict";function d(){this.compressedSize=0,this.uncompressedSize=0,this.crc32=0,this.compressionMethod=null,this.compressedContent=null}d.prototype={getContent:function(){return null},getCompressedContent:function(){return null}},b.exports=d},{}],4:[function(a,b,c){"use strict";c.STORE={magic:"\0\0",compress:function(a,b){return a},uncompress:function(a){return a},compressInputType:null,uncompressInputType:null},c.DEFLATE=a("./flate")},{"./flate":9}],5:[function(a,b,c){"use strict";var d=a("./utils"),e=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117];b.exports=function(a,b){if("undefined"==typeof a||!a.length)return 0;var c="string"!==d.getTypeOf(a);"undefined"==typeof b&&(b=0);var f=0,g=0,h=0;b^=-1;for(var i=0,j=a.length;i<j;i++)h=c?a[i]:a.charCodeAt(i),g=255&(b^h),f=e[g],b=b>>>8^f;return b^-1}},{"./utils":22}],6:[function(a,b,c){"use strict";function d(a){this.data=null,this.length=0,this.index=0,this.zero=0}var e=a("./utils");d.prototype={checkOffset:function(a){this.checkIndex(this.index+a)},checkIndex:function(a){if(this.length<this.zero+a||a<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+a+"). Corrupted zip ?")},setIndex:function(a){this.checkIndex(a),this.index=a},skip:function(a){this.setIndex(this.index+a)},byteAt:function(a){},readInt:function(a){var b,c=0;for(this.checkOffset(a),b=this.index+a-1;b>=this.index;b--)c=(c<<8)+this.byteAt(b);return this.index+=a,c},readString:function(a){return e.transformTo("string",this.readData(a))},readData:function(a){},lastIndexOfSignature:function(a){},readDate:function(){var a=this.readInt(4);return new Date((a>>25&127)+1980,(a>>21&15)-1,a>>16&31,a>>11&31,a>>5&63,(31&a)<<1)}},b.exports=d},{"./utils":22}],7:[function(a,b,c){"use strict";c.base64=!1,c.binary=!1,c.dir=!1,c.createFolders=!1,c.date=null,c.compression=null,c.compressionOptions=null,c.comment=null,c.unixPermissions=null,c.dosPermissions=null},{}],8:[function(a,b,c){"use strict";var d=a("./utils");c.string2binary=function(a){return d.string2binary(a)},c.string2Uint8Array=function(a){return d.transformTo("uint8array",a)},c.uint8Array2String=function(a){return d.transformTo("string",a)},c.string2Blob=function(a){var b=d.transformTo("arraybuffer",a);return d.arrayBuffer2Blob(b)},c.arrayBuffer2Blob=function(a){return d.arrayBuffer2Blob(a)},c.transformTo=function(a,b){return d.transformTo(a,b)},c.getTypeOf=function(a){return d.getTypeOf(a)},c.checkSupport=function(a){return d.checkSupport(a)},c.MAX_VALUE_16BITS=d.MAX_VALUE_16BITS,c.MAX_VALUE_32BITS=d.MAX_VALUE_32BITS,c.pretty=function(a){return d.pretty(a)},c.findCompression=function(a){return d.findCompression(a)},c.isRegExp=function(a){return d.isRegExp(a)}},{"./utils":22}],9:[function(a,b,c){"use strict";var d="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Uint32Array,e=a("pako");c.uncompressInputType=d?"uint8array":"array",c.compressInputType=d?"uint8array":"array",c.magic="\b\0",c.compress=function(a,b){return e.deflateRaw(a,{level:b.level||-1})},c.uncompress=function(a){return e.inflateRaw(a)}},{pako:25}],10:[function(a,b,c){"use strict";function d(a,b){return this instanceof d?(this.files={},this.comment=null,this.root="",a&&this.load(a,b),void(this.clone=function(){var a=new d;for(var b in this)"function"!=typeof this[b]&&(a[b]=this[b]);return a})):new d(a,b)}var e=a("./base64");d.prototype=a("./object"),d.prototype.load=a("./load"),d.support=a("./support"),d.defaults=a("./defaults"),d.utils=a("./deprecatedPublicUtils"),d.base64={encode:function(a){return e.encode(a)},decode:function(a){return e.decode(a)}},d.compressions=a("./compressions"),b.exports=d},{"./base64":2,"./compressions":4,"./defaults":7,"./deprecatedPublicUtils":8,"./load":11,"./object":14,"./support":18}],11:[function(a,b,c){"use strict";var d=a("./base64"),e=a("./utf8"),f=a("./utils"),g=a("./zipEntries");b.exports=function(a,b){var c,h,i,j;for(b=f.extend(b||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:e.utf8decode}),b.base64&&(a=d.decode(a)),h=new g(a,b),c=h.files,i=0;i<c.length;i++)j=c[i],this.file(j.fileNameStr,j.decompressed,{binary:!0,optimizedBinaryString:!0,date:j.date,dir:j.dir,comment:j.fileCommentStr.length?j.fileCommentStr:null,unixPermissions:j.unixPermissions,dosPermissions:j.dosPermissions,createFolders:b.createFolders});return h.zipComment.length&&(this.comment=h.zipComment),this}},{"./base64":2,"./utf8":21,"./utils":22,"./zipEntries":23}],12:[function(a,b,c){(function(a){"use strict";b.exports=function(b,c){return new a(b,c)},b.exports.test=function(b){return a.isBuffer(b)}}).call(this,"undefined"!=typeof Buffer?Buffer:void 0)},{}],13:[function(a,b,c){"use strict";function d(a){this.data=a,this.length=this.data.length,this.index=0,this.zero=0}var e=a("./uint8ArrayReader");d.prototype=new e,d.prototype.readData=function(a){this.checkOffset(a);var b=this.data.slice(this.zero+this.index,this.zero+this.index+a);return this.index+=a,b},b.exports=d},{"./uint8ArrayReader":19}],14:[function(a,b,c){"use strict";var d=a("./support"),e=a("./utils"),f=a("./crc32"),g=a("./signature"),h=a("./defaults"),i=a("./base64"),j=a("./compressions"),k=a("./compressedObject"),l=a("./nodeBuffer"),m=a("./utf8"),n=a("./stringWriter"),o=a("./uint8ArrayWriter"),p=function(a){if(a._data instanceof k&&(a._data=a._data.getContent(),a.options.binary=!0,a.options.base64=!1,"uint8array"===e.getTypeOf(a._data))){var b=a._data;a._data=new Uint8Array(b.length),0!==b.length&&a._data.set(b,0)}return a._data},q=function(a){var b=p(a),c=e.getTypeOf(b);return"string"===c?!a.options.binary&&d.nodebuffer?l(b,"utf-8"):a.asBinary():b},r=function(a){var b=p(this);return null===b||"undefined"==typeof b?"":(this.options.base64&&(b=i.decode(b)),b=a&&this.options.binary?D.utf8decode(b):e.transformTo("string",b),a||this.options.binary||(b=e.transformTo("string",D.utf8encode(b))),b)},s=function(a,b,c){this.name=a,this.dir=c.dir,this.date=c.date,this.comment=c.comment,this.unixPermissions=c.unixPermissions,this.dosPermissions=c.dosPermissions,this._data=b,this.options=c,this._initialMetadata={dir:c.dir,date:c.date}};s.prototype={asText:function(){return r.call(this,!0)},asBinary:function(){return r.call(this,!1)},asNodeBuffer:function(){var a=q(this);return e.transformTo("nodebuffer",a)},asUint8Array:function(){var a=q(this);return e.transformTo("uint8array",a)},asArrayBuffer:function(){return this.asUint8Array().buffer}};var t=function(a,b){var c,d="";for(c=0;c<b;c++)d+=String.fromCharCode(255&a),a>>>=8;return d},u=function(a){return a=a||{},a.base64!==!0||null!==a.binary&&void 0!==a.binary||(a.binary=!0),a=e.extend(a,h),a.date=a.date||new Date,null!==a.compression&&(a.compression=a.compression.toUpperCase()),a},v=function(a,b,c){var d,f=e.getTypeOf(b);if(c=u(c),"string"==typeof c.unixPermissions&&(c.unixPermissions=parseInt(c.unixPermissions,8)),c.unixPermissions&&16384&c.unixPermissions&&(c.dir=!0),c.dosPermissions&&16&c.dosPermissions&&(c.dir=!0),c.dir&&(a=x(a)),c.createFolders&&(d=w(a))&&y.call(this,d,!0),c.dir||null===b||"undefined"==typeof b)c.base64=!1,c.binary=!1,b=null,f=null;else if("string"===f)c.binary&&!c.base64&&c.optimizedBinaryString!==!0&&(b=e.string2binary(b));else{if(c.base64=!1,c.binary=!0,!(f||b instanceof k))throw new Error("The data of '"+a+"' is in an unsupported format !");"arraybuffer"===f&&(b=e.transformTo("uint8array",b))}var g=new s(a,b,c);return this.files[a]=g,g},w=function(a){"/"==a.slice(-1)&&(a=a.substring(0,a.length-1));var b=a.lastIndexOf("/");return b>0?a.substring(0,b):""},x=function(a){return"/"!=a.slice(-1)&&(a+="/"),a},y=function(a,b){return b="undefined"!=typeof b&&b,a=x(a),this.files[a]||v.call(this,a,null,{dir:!0,createFolders:b}),this.files[a]},z=function(a,b,c){var d,g=new k;return a._data instanceof k?(g.uncompressedSize=a._data.uncompressedSize,g.crc32=a._data.crc32,0===g.uncompressedSize||a.dir?(b=j.STORE,g.compressedContent="",g.crc32=0):a._data.compressionMethod===b.magic?g.compressedContent=a._data.getCompressedContent():(d=a._data.getContent(),g.compressedContent=b.compress(e.transformTo(b.compressInputType,d),c))):(d=q(a),d&&0!==d.length&&!a.dir||(b=j.STORE,d=""),g.uncompressedSize=d.length,g.crc32=f(d),g.compressedContent=b.compress(e.transformTo(b.compressInputType,d),c)),g.compressedSize=g.compressedContent.length,g.compressionMethod=b.magic,g},A=function(a,b){var c=a;return a||(c=b?16893:33204),(65535&c)<<16},B=function(a,b){return 63&(a||0)},C=function(a,b,c,d,h,i){var j,k,l,n,o=(c.compressedContent,i!==m.utf8encode),p=e.transformTo("string",i(b.name)),q=e.transformTo("string",m.utf8encode(b.name)),r=b.comment||"",s=e.transformTo("string",i(r)),u=e.transformTo("string",m.utf8encode(r)),v=q.length!==b.name.length,w=u.length!==r.length,x=b.options,y="",z="",C="";l=b._initialMetadata.dir!==b.dir?b.dir:x.dir,n=b._initialMetadata.date!==b.date?b.date:x.date;var D=0,E=0;l&&(D|=16),"UNIX"===h?(E=798,D|=A(b.unixPermissions,l)):(E=20,D|=B(b.dosPermissions,l)),j=n.getHours(),j<<=6,j|=n.getMinutes(),j<<=5,j|=n.getSeconds()/2,k=n.getFullYear()-1980,k<<=4,k|=n.getMonth()+1,k<<=5,k|=n.getDate(),v&&(z=t(1,1)+t(f(p),4)+q,y+="up"+t(z.length,2)+z),w&&(C=t(1,1)+t(this.crc32(s),4)+u,y+="uc"+t(C.length,2)+C);var F="";F+="\n\0",F+=o||!v&&!w?"\0\0":"\0\b",F+=c.compressionMethod,F+=t(j,2),F+=t(k,2),F+=t(c.crc32,4),F+=t(c.compressedSize,4),F+=t(c.uncompressedSize,4),F+=t(p.length,2),F+=t(y.length,2);var G=g.LOCAL_FILE_HEADER+F+p+y,H=g.CENTRAL_FILE_HEADER+t(E,2)+F+t(s.length,2)+"\0\0\0\0"+t(D,4)+t(d,4)+p+y+s;return{fileRecord:G,dirRecord:H,compressedObject:c}},D={load:function(a,b){throw new Error("Load method is not defined. Is the file jszip-load.js included ?")},filter:function(a){var b,c,d,f,g=[];for(b in this.files)this.files.hasOwnProperty(b)&&(d=this.files[b],f=new s(d.name,d._data,e.extend(d.options)),c=b.slice(this.root.length,b.length),b.slice(0,this.root.length)===this.root&&a(c,f)&&g.push(f));return g},file:function(a,b,c){if(1===arguments.length){if(e.isRegExp(a)){var d=a;return this.filter(function(a,b){return!b.dir&&d.test(a)})}return this.filter(function(b,c){return!c.dir&&b===a})[0]||null}return a=this.root+a,v.call(this,a,b,c),this},folder:function(a){if(!a)return this;if(e.isRegExp(a))return this.filter(function(b,c){return c.dir&&a.test(b)});var b=this.root+a,c=y.call(this,b),d=this.clone();return d.root=c.name,d},remove:function(a){a=this.root+a;var b=this.files[a];if(b||("/"!=a.slice(-1)&&(a+="/"),b=this.files[a]),b&&!b.dir)delete this.files[a];else for(var c=this.filter(function(b,c){return c.name.slice(0,a.length)===a}),d=0;d<c.length;d++)delete this.files[c[d].name];return this},generate:function(a){a=e.extend(a||{},{base64:!0,compression:"STORE",compressionOptions:null,type:"base64",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:m.utf8encode}),e.checkSupport(a.type),"darwin"!==a.platform&&"freebsd"!==a.platform&&"linux"!==a.platform&&"sunos"!==a.platform||(a.platform="UNIX"),"win32"===a.platform&&(a.platform="DOS");var b,c,d=[],f=0,h=0,k=e.transformTo("string",a.encodeFileName(a.comment||this.comment||""));for(var l in this.files)if(this.files.hasOwnProperty(l)){var p=this.files[l],q=p.options.compression||a.compression.toUpperCase(),r=j[q];if(!r)throw new Error(q+" is not a valid compression method !");var s=p.options.compressionOptions||a.compressionOptions||{},u=z.call(this,p,r,s),v=C.call(this,l,p,u,f,a.platform,a.encodeFileName);f+=v.fileRecord.length+u.compressedSize,h+=v.dirRecord.length,d.push(v)}var w="";w=g.CENTRAL_DIRECTORY_END+"\0\0\0\0"+t(d.length,2)+t(d.length,2)+t(h,4)+t(f,4)+t(k.length,2)+k;var x=a.type.toLowerCase();for(b="uint8array"===x||"arraybuffer"===x||"blob"===x||"nodebuffer"===x?new o(f+h+w.length):new n(f+h+w.length),c=0;c<d.length;c++)b.append(d[c].fileRecord),b.append(d[c].compressedObject.compressedContent);for(c=0;c<d.length;c++)b.append(d[c].dirRecord);b.append(w);var y=b.finalize();switch(a.type.toLowerCase()){case"uint8array":case"arraybuffer":case"nodebuffer":return e.transformTo(a.type.toLowerCase(),y);case"blob":return e.arrayBuffer2Blob(e.transformTo("arraybuffer",y),a.mimeType);case"base64":return a.base64?i.encode(y):y;default:return y}},crc32:function(a,b){return f(a,b)},utf8encode:function(a){return e.transformTo("string",m.utf8encode(a))},utf8decode:function(a){return m.utf8decode(a)}};b.exports=D},{"./base64":2,"./compressedObject":3,"./compressions":4,"./crc32":5,"./defaults":7,"./nodeBuffer":12,"./signature":15,"./stringWriter":17,"./support":18,"./uint8ArrayWriter":20,"./utf8":21,"./utils":22}],15:[function(a,b,c){"use strict";c.LOCAL_FILE_HEADER="PK",c.CENTRAL_FILE_HEADER="PK",c.CENTRAL_DIRECTORY_END="PK",c.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK",c.ZIP64_CENTRAL_DIRECTORY_END="PK",c.DATA_DESCRIPTOR="PK\b"},{}],16:[function(a,b,c){"use strict";function d(a,b){this.data=a,b||(this.data=f.string2binary(this.data)),this.length=this.data.length,this.index=0,this.zero=0}var e=a("./dataReader"),f=a("./utils");d.prototype=new e,d.prototype.byteAt=function(a){return this.data.charCodeAt(this.zero+a)},d.prototype.lastIndexOfSignature=function(a){return this.data.lastIndexOf(a)-this.zero},d.prototype.readData=function(a){this.checkOffset(a);var b=this.data.slice(this.zero+this.index,this.zero+this.index+a);return this.index+=a,b},b.exports=d},{"./dataReader":6,"./utils":22}],17:[function(a,b,c){"use strict";var d=a("./utils"),e=function(){this.data=[]};e.prototype={append:function(a){a=d.transformTo("string",a),this.data.push(a)},finalize:function(){return this.data.join("")}},b.exports=e},{"./utils":22}],18:[function(a,b,c){(function(a){"use strict";if(c.base64=!0,c.array=!0,c.string=!0,c.arraybuffer="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,c.nodebuffer="undefined"!=typeof a,c.uint8array="undefined"!=typeof Uint8Array,"undefined"==typeof ArrayBuffer)c.blob=!1;else{var b=new ArrayBuffer(0);try{c.blob=0===new Blob([b],{type:"application/zip"}).size}catch(d){try{var e=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder||window.MSBlobBuilder,f=new e;f.append(b),c.blob=0===f.getBlob("application/zip").size}catch(d){c.blob=!1}}}}).call(this,"undefined"!=typeof Buffer?Buffer:void 0)},{}],19:[function(a,b,c){"use strict";function d(a){a&&(this.data=a,this.length=this.data.length,this.index=0,this.zero=0)}var e=a("./arrayReader");d.prototype=new e,d.prototype.readData=function(a){if(this.checkOffset(a),0===a)return new Uint8Array(0);var b=this.data.subarray(this.zero+this.index,this.zero+this.index+a);return this.index+=a,b},b.exports=d},{"./arrayReader":1}],20:[function(a,b,c){"use strict";var d=a("./utils"),e=function(a){this.data=new Uint8Array(a),this.index=0};e.prototype={append:function(a){0!==a.length&&(a=d.transformTo("uint8array",a),this.data.set(a,this.index),this.index+=a.length)},finalize:function(){return this.data}},b.exports=e},{"./utils":22}],21:[function(a,b,c){"use strict";for(var d=a("./utils"),e=a("./support"),f=a("./nodeBuffer"),g=new Array(256),h=0;h<256;h++)g[h]=h>=252?6:h>=248?5:h>=240?4:h>=224?3:h>=192?2:1;g[254]=g[254]=1;var i=function(a){var b,c,d,f,g,h=a.length,i=0;for(f=0;f<h;f++)c=a.charCodeAt(f),55296===(64512&c)&&f+1<h&&(d=a.charCodeAt(f+1),56320===(64512&d)&&(c=65536+(c-55296<<10)+(d-56320),f++)),i+=c<128?1:c<2048?2:c<65536?3:4;for(b=e.uint8array?new Uint8Array(i):new Array(i),g=0,f=0;g<i;f++)c=a.charCodeAt(f),55296===(64512&c)&&f+1<h&&(d=a.charCodeAt(f+1),56320===(64512&d)&&(c=65536+(c-55296<<10)+(d-56320),f++)),c<128?b[g++]=c:c<2048?(b[g++]=192|c>>>6,b[g++]=128|63&c):c<65536?(b[g++]=224|c>>>12,b[g++]=128|c>>>6&63,b[g++]=128|63&c):(b[g++]=240|c>>>18,b[g++]=128|c>>>12&63,b[g++]=128|c>>>6&63,b[g++]=128|63&c);return b},j=function(a,b){var c;for(b=b||a.length,b>a.length&&(b=a.length),c=b-1;c>=0&&128===(192&a[c]);)c--;return c<0?b:0===c?b:c+g[a[c]]>b?c:b},k=function(a){var b,c,e,f,h=a.length,i=new Array(2*h);for(c=0,b=0;b<h;)if(e=a[b++],e<128)i[c++]=e;else if(f=g[e],f>4)i[c++]=65533,b+=f-1;else{for(e&=2===f?31:3===f?15:7;f>1&&b<h;)e=e<<6|63&a[b++],f--;f>1?i[c++]=65533:e<65536?i[c++]=e:(e-=65536,i[c++]=55296|e>>10&1023,i[c++]=56320|1023&e)}return i.length!==c&&(i.subarray?i=i.subarray(0,c):i.length=c),d.applyFromCharCode(i)};c.utf8encode=function(a){return e.nodebuffer?f(a,"utf-8"):i(a)},c.utf8decode=function(a){if(e.nodebuffer)return d.transformTo("nodebuffer",a).toString("utf-8");a=d.transformTo(e.uint8array?"uint8array":"array",a);for(var b=[],c=0,f=a.length,g=65536;c<f;){var h=j(a,Math.min(c+g,f));e.uint8array?b.push(k(a.subarray(c,h))):b.push(k(a.slice(c,h))),c=h}return b.join("")}},{"./nodeBuffer":12,"./support":18,"./utils":22}],22:[function(a,b,c){"use strict";function d(a){return a}function e(a,b){for(var c=0;c<a.length;++c)b[c]=255&a.charCodeAt(c);return b}function f(a){var b=65536,d=[],e=a.length,f=c.getTypeOf(a),g=0,h=!0;try{switch(f){case"uint8array":String.fromCharCode.apply(null,new Uint8Array(0));break;case"nodebuffer":String.fromCharCode.apply(null,j(0))}}catch(i){h=!1}if(!h){for(var k="",l=0;l<a.length;l++)k+=String.fromCharCode(a[l]);return k}for(;g<e&&b>1;)try{"array"===f||"nodebuffer"===f?d.push(String.fromCharCode.apply(null,a.slice(g,Math.min(g+b,e)))):d.push(String.fromCharCode.apply(null,a.subarray(g,Math.min(g+b,e)))),g+=b}catch(i){b=Math.floor(b/2)}return d.join("")}function g(a,b){for(var c=0;c<a.length;c++)b[c]=a[c];return b}var h=a("./support"),i=a("./compressions"),j=a("./nodeBuffer");c.string2binary=function(a){for(var b="",c=0;c<a.length;c++)b+=String.fromCharCode(255&a.charCodeAt(c));return b},c.arrayBuffer2Blob=function(a,b){c.checkSupport("blob"),b=b||"application/zip";try{return new Blob([a],{type:b})}catch(d){try{var e=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder||window.MSBlobBuilder,f=new e;return f.append(a),f.getBlob(b)}catch(d){throw new Error("Bug : can't construct the Blob.")}}},c.applyFromCharCode=f;var k={};k.string={string:d,array:function(a){return e(a,new Array(a.length))},arraybuffer:function(a){return k.string.uint8array(a).buffer},uint8array:function(a){return e(a,new Uint8Array(a.length))},nodebuffer:function(a){return e(a,j(a.length))}},k.array={string:f,array:d,arraybuffer:function(a){return new Uint8Array(a).buffer},uint8array:function(a){return new Uint8Array(a)},nodebuffer:function(a){return j(a)}},k.arraybuffer={string:function(a){return f(new Uint8Array(a))},array:function(a){return g(new Uint8Array(a),new Array(a.byteLength))},arraybuffer:d,uint8array:function(a){return new Uint8Array(a)},nodebuffer:function(a){return j(new Uint8Array(a))}},k.uint8array={string:f,array:function(a){return g(a,new Array(a.length))},arraybuffer:function(a){return a.buffer},uint8array:d,nodebuffer:function(a){return j(a)}},k.nodebuffer={string:f,array:function(a){return g(a,new Array(a.length))},arraybuffer:function(a){return k.nodebuffer.uint8array(a).buffer},uint8array:function(a){return g(a,new Uint8Array(a.length))},nodebuffer:d},c.transformTo=function(a,b){if(b||(b=""),!a)return b;c.checkSupport(a);var d=c.getTypeOf(b),e=k[d][a](b);return e},c.getTypeOf=function(a){return"string"==typeof a?"string":"[object Array]"===Object.prototype.toString.call(a)?"array":h.nodebuffer&&j.test(a)?"nodebuffer":h.uint8array&&a instanceof Uint8Array?"uint8array":h.arraybuffer&&a instanceof ArrayBuffer?"arraybuffer":void 0},c.checkSupport=function(a){var b=h[a.toLowerCase()];if(!b)throw new Error(a+" is not supported by this browser")},c.MAX_VALUE_16BITS=65535,c.MAX_VALUE_32BITS=-1,c.pretty=function(a){var b,c,d="";for(c=0;c<(a||"").length;c++)b=a.charCodeAt(c),d+="\\x"+(b<16?"0":"")+b.toString(16).toUpperCase();return d},c.findCompression=function(a){for(var b in i)if(i.hasOwnProperty(b)&&i[b].magic===a)return i[b];return null},c.isRegExp=function(a){return"[object RegExp]"===Object.prototype.toString.call(a)},c.extend=function(){var a,b,c={};for(a=0;a<arguments.length;a++)for(b in arguments[a])arguments[a].hasOwnProperty(b)&&"undefined"==typeof c[b]&&(c[b]=arguments[a][b]);return c}},{"./compressions":4,"./nodeBuffer":12,"./support":18}],23:[function(a,b,c){"use strict";function d(a,b){this.files=[],this.loadOptions=b,a&&this.load(a)}var e=a("./stringReader"),f=a("./nodeBufferReader"),g=a("./uint8ArrayReader"),h=a("./arrayReader"),i=a("./utils"),j=a("./signature"),k=a("./zipEntry"),l=a("./support");a("./object");d.prototype={checkSignature:function(a){var b=this.reader.readString(4);if(b!==a)throw new Error("Corrupted zip or bug : unexpected signature ("+i.pretty(b)+", expected "+i.pretty(a)+")")},isSignature:function(a,b){var c=this.reader.index;this.reader.setIndex(a);var d=this.reader.readString(4),e=d===b;return this.reader.setIndex(c),e},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var a=this.reader.readData(this.zipCommentLength),b=l.uint8array?"uint8array":"array",c=i.transformTo(b,a);this.zipComment=this.loadOptions.decodeFileName(c)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.versionMadeBy=this.reader.readString(2),this.versionNeeded=this.reader.readInt(2),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var a,b,c,d=this.zip64EndOfCentralSize-44,e=0;e<d;)a=this.reader.readInt(2),b=this.reader.readInt(4),c=this.reader.readString(b),this.zip64ExtensibleData[a]={id:a,length:b,value:c}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),this.disksCount>1)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var a,b;for(a=0;a<this.files.length;a++)b=this.files[a],this.reader.setIndex(b.localHeaderOffset),this.checkSignature(j.LOCAL_FILE_HEADER),b.readLocalPart(this.reader),b.handleUTF8(),b.processAttributes()},readCentralDir:function(){var a;for(this.reader.setIndex(this.centralDirOffset);this.reader.readString(4)===j.CENTRAL_FILE_HEADER;)a=new k({zip64:this.zip64},this.loadOptions),a.readCentralPart(this.reader),this.files.push(a);if(this.centralDirRecords!==this.files.length&&0!==this.centralDirRecords&&0===this.files.length)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var a=this.reader.lastIndexOfSignature(j.CENTRAL_DIRECTORY_END);if(a<0){var b=!this.isSignature(0,j.LOCAL_FILE_HEADER);throw b?new Error("Can't find end of central directory : is this a zip file ? If it is, see http://stuk.github.io/jszip/documentation/howto/read_zip.html"):new Error("Corrupted zip : can't find end of central directory")}this.reader.setIndex(a);var c=a;if(this.checkSignature(j.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===i.MAX_VALUE_16BITS||this.diskWithCentralDirStart===i.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===i.MAX_VALUE_16BITS||this.centralDirRecords===i.MAX_VALUE_16BITS||this.centralDirSize===i.MAX_VALUE_32BITS||this.centralDirOffset===i.MAX_VALUE_32BITS){if(this.zip64=!0,a=this.reader.lastIndexOfSignature(j.ZIP64_CENTRAL_DIRECTORY_LOCATOR),a<0)throw new Error("Corrupted zip : can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(a),this.checkSignature(j.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,j.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(j.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip : can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(j.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var d=this.centralDirOffset+this.centralDirSize;this.zip64&&(d+=20,d+=12+this.zip64EndOfCentralSize);var e=c-d;if(e>0)this.isSignature(c,j.CENTRAL_FILE_HEADER)||(this.reader.zero=e);else if(e<0)throw new Error("Corrupted zip: missing "+Math.abs(e)+" bytes.")},prepareReader:function(a){var b=i.getTypeOf(a);if(i.checkSupport(b),"string"!==b||l.uint8array)if("nodebuffer"===b)this.reader=new f(a);else if(l.uint8array)this.reader=new g(i.transformTo("uint8array",a));else{if(!l.array)throw new Error("Unexpected error: unsupported type '"+b+"'");this.reader=new h(i.transformTo("array",a))}else this.reader=new e(a,this.loadOptions.optimizedBinaryString)},load:function(a){this.prepareReader(a),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},b.exports=d},{"./arrayReader":1,"./nodeBufferReader":13,"./object":14,"./signature":15,"./stringReader":16,"./support":18,"./uint8ArrayReader":19,"./utils":22,"./zipEntry":24}],24:[function(a,b,c){"use strict";function d(a,b){this.options=a,this.loadOptions=b}var e=a("./stringReader"),f=a("./utils"),g=a("./compressedObject"),h=a("./object"),i=a("./support"),j=0,k=3;d.prototype={isEncrypted:function(){return 1===(1&this.bitFlag)},useUTF8:function(){return 2048===(2048&this.bitFlag)},prepareCompressedContent:function(a,b,c){return function(){var d=a.index;a.setIndex(b);var e=a.readData(c);return a.setIndex(d),e}},prepareContent:function(a,b,c,d,e){return function(){var a=f.transformTo(d.uncompressInputType,this.getCompressedContent()),b=d.uncompress(a);if(b.length!==e)throw new Error("Bug : uncompressed data size mismatch");return b}},readLocalPart:function(a){var b,c;if(a.skip(22),this.fileNameLength=a.readInt(2),c=a.readInt(2),this.fileName=a.readData(this.fileNameLength),a.skip(c),this.compressedSize==-1||this.uncompressedSize==-1)throw new Error("Bug or corrupted zip : didn't get enough informations from the central directory (compressedSize == -1 || uncompressedSize == -1)");if(b=f.findCompression(this.compressionMethod),null===b)throw new Error("Corrupted zip : compression "+f.pretty(this.compressionMethod)+" unknown (inner file : "+f.transformTo("string",this.fileName)+")");if(this.decompressed=new g,this.decompressed.compressedSize=this.compressedSize,this.decompressed.uncompressedSize=this.uncompressedSize,this.decompressed.crc32=this.crc32,this.decompressed.compressionMethod=this.compressionMethod,this.decompressed.getCompressedContent=this.prepareCompressedContent(a,a.index,this.compressedSize,b),this.decompressed.getContent=this.prepareContent(a,a.index,this.compressedSize,b,this.uncompressedSize),this.loadOptions.checkCRC32&&(this.decompressed=f.transformTo("string",this.decompressed.getContent()),h.crc32(this.decompressed)!==this.crc32))throw new Error("Corrupted zip : CRC32 mismatch");
},readCentralPart:function(a){if(this.versionMadeBy=a.readInt(2),this.versionNeeded=a.readInt(2),this.bitFlag=a.readInt(2),this.compressionMethod=a.readString(2),this.date=a.readDate(),this.crc32=a.readInt(4),this.compressedSize=a.readInt(4),this.uncompressedSize=a.readInt(4),this.fileNameLength=a.readInt(2),this.extraFieldsLength=a.readInt(2),this.fileCommentLength=a.readInt(2),this.diskNumberStart=a.readInt(2),this.internalFileAttributes=a.readInt(2),this.externalFileAttributes=a.readInt(4),this.localHeaderOffset=a.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");this.fileName=a.readData(this.fileNameLength),this.readExtraFields(a),this.parseZIP64ExtraField(a),this.fileComment=a.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var a=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),a===j&&(this.dosPermissions=63&this.externalFileAttributes),a===k&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||"/"!==this.fileNameStr.slice(-1)||(this.dir=!0)},parseZIP64ExtraField:function(a){if(this.extraFields[1]){var b=new e(this.extraFields[1].value);this.uncompressedSize===f.MAX_VALUE_32BITS&&(this.uncompressedSize=b.readInt(8)),this.compressedSize===f.MAX_VALUE_32BITS&&(this.compressedSize=b.readInt(8)),this.localHeaderOffset===f.MAX_VALUE_32BITS&&(this.localHeaderOffset=b.readInt(8)),this.diskNumberStart===f.MAX_VALUE_32BITS&&(this.diskNumberStart=b.readInt(4))}},readExtraFields:function(a){var b,c,d,e=a.index;for(this.extraFields=this.extraFields||{};a.index<e+this.extraFieldsLength;)b=a.readInt(2),c=a.readInt(2),d=a.readString(c),this.extraFields[b]={id:b,length:c,value:d}},handleUTF8:function(){var a=i.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=h.utf8decode(this.fileName),this.fileCommentStr=h.utf8decode(this.fileComment);else{var b=this.findExtraFieldUnicodePath();if(null!==b)this.fileNameStr=b;else{var c=f.transformTo(a,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(c)}var d=this.findExtraFieldUnicodeComment();if(null!==d)this.fileCommentStr=d;else{var e=f.transformTo(a,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(e)}}},findExtraFieldUnicodePath:function(){var a=this.extraFields[28789];if(a){var b=new e(a.value);return 1!==b.readInt(1)?null:h.crc32(this.fileName)!==b.readInt(4)?null:h.utf8decode(b.readString(a.length-5))}return null},findExtraFieldUnicodeComment:function(){var a=this.extraFields[25461];if(a){var b=new e(a.value);return 1!==b.readInt(1)?null:h.crc32(this.fileComment)!==b.readInt(4)?null:h.utf8decode(b.readString(a.length-5))}return null}},b.exports=d},{"./compressedObject":3,"./object":14,"./stringReader":16,"./support":18,"./utils":22}],25:[function(a,b,c){"use strict";var d=a("./lib/utils/common").assign,e=a("./lib/deflate"),f=a("./lib/inflate"),g=a("./lib/zlib/constants"),h={};d(h,e,f,g),b.exports=h},{"./lib/deflate":26,"./lib/inflate":27,"./lib/utils/common":28,"./lib/zlib/constants":31}],26:[function(a,b,c){"use strict";function d(a){if(!(this instanceof d))return new d(a);this.options=i.assign({level:s,method:u,chunkSize:16384,windowBits:15,memLevel:8,strategy:t,to:""},a||{});var b=this.options;b.raw&&b.windowBits>0?b.windowBits=-b.windowBits:b.gzip&&b.windowBits>0&&b.windowBits<16&&(b.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new l,this.strm.avail_out=0;var c=h.deflateInit2(this.strm,b.level,b.method,b.windowBits,b.memLevel,b.strategy);if(c!==p)throw new Error(k[c]);if(b.header&&h.deflateSetHeader(this.strm,b.header),b.dictionary){var e;if(e="string"==typeof b.dictionary?j.string2buf(b.dictionary):"[object ArrayBuffer]"===m.call(b.dictionary)?new Uint8Array(b.dictionary):b.dictionary,c=h.deflateSetDictionary(this.strm,e),c!==p)throw new Error(k[c]);this._dict_set=!0}}function e(a,b){var c=new d(b);if(c.push(a,!0),c.err)throw c.msg;return c.result}function f(a,b){return b=b||{},b.raw=!0,e(a,b)}function g(a,b){return b=b||{},b.gzip=!0,e(a,b)}var h=a("./zlib/deflate"),i=a("./utils/common"),j=a("./utils/strings"),k=a("./zlib/messages"),l=a("./zlib/zstream"),m=Object.prototype.toString,n=0,o=4,p=0,q=1,r=2,s=-1,t=0,u=8;d.prototype.push=function(a,b){var c,d,e=this.strm,f=this.options.chunkSize;if(this.ended)return!1;d=b===~~b?b:b===!0?o:n,"string"==typeof a?e.input=j.string2buf(a):"[object ArrayBuffer]"===m.call(a)?e.input=new Uint8Array(a):e.input=a,e.next_in=0,e.avail_in=e.input.length;do{if(0===e.avail_out&&(e.output=new i.Buf8(f),e.next_out=0,e.avail_out=f),c=h.deflate(e,d),c!==q&&c!==p)return this.onEnd(c),this.ended=!0,!1;0!==e.avail_out&&(0!==e.avail_in||d!==o&&d!==r)||("string"===this.options.to?this.onData(j.buf2binstring(i.shrinkBuf(e.output,e.next_out))):this.onData(i.shrinkBuf(e.output,e.next_out)))}while((e.avail_in>0||0===e.avail_out)&&c!==q);return d===o?(c=h.deflateEnd(this.strm),this.onEnd(c),this.ended=!0,c===p):d!==r||(this.onEnd(p),e.avail_out=0,!0)},d.prototype.onData=function(a){this.chunks.push(a)},d.prototype.onEnd=function(a){a===p&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=i.flattenChunks(this.chunks)),this.chunks=[],this.err=a,this.msg=this.strm.msg},c.Deflate=d,c.deflate=e,c.deflateRaw=f,c.gzip=g},{"./utils/common":28,"./utils/strings":29,"./zlib/deflate":33,"./zlib/messages":38,"./zlib/zstream":40}],27:[function(a,b,c){"use strict";function d(a){if(!(this instanceof d))return new d(a);this.options=h.assign({chunkSize:16384,windowBits:0,to:""},a||{});var b=this.options;b.raw&&b.windowBits>=0&&b.windowBits<16&&(b.windowBits=-b.windowBits,0===b.windowBits&&(b.windowBits=-15)),!(b.windowBits>=0&&b.windowBits<16)||a&&a.windowBits||(b.windowBits+=32),b.windowBits>15&&b.windowBits<48&&0===(15&b.windowBits)&&(b.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new l,this.strm.avail_out=0;var c=g.inflateInit2(this.strm,b.windowBits);if(c!==j.Z_OK)throw new Error(k[c]);this.header=new m,g.inflateGetHeader(this.strm,this.header)}function e(a,b){var c=new d(b);if(c.push(a,!0),c.err)throw c.msg;return c.result}function f(a,b){return b=b||{},b.raw=!0,e(a,b)}var g=a("./zlib/inflate"),h=a("./utils/common"),i=a("./utils/strings"),j=a("./zlib/constants"),k=a("./zlib/messages"),l=a("./zlib/zstream"),m=a("./zlib/gzheader"),n=Object.prototype.toString;d.prototype.push=function(a,b){var c,d,e,f,k,l,m=this.strm,o=this.options.chunkSize,p=this.options.dictionary,q=!1;if(this.ended)return!1;d=b===~~b?b:b===!0?j.Z_FINISH:j.Z_NO_FLUSH,"string"==typeof a?m.input=i.binstring2buf(a):"[object ArrayBuffer]"===n.call(a)?m.input=new Uint8Array(a):m.input=a,m.next_in=0,m.avail_in=m.input.length;do{if(0===m.avail_out&&(m.output=new h.Buf8(o),m.next_out=0,m.avail_out=o),c=g.inflate(m,j.Z_NO_FLUSH),c===j.Z_NEED_DICT&&p&&(l="string"==typeof p?i.string2buf(p):"[object ArrayBuffer]"===n.call(p)?new Uint8Array(p):p,c=g.inflateSetDictionary(this.strm,l)),c===j.Z_BUF_ERROR&&q===!0&&(c=j.Z_OK,q=!1),c!==j.Z_STREAM_END&&c!==j.Z_OK)return this.onEnd(c),this.ended=!0,!1;m.next_out&&(0!==m.avail_out&&c!==j.Z_STREAM_END&&(0!==m.avail_in||d!==j.Z_FINISH&&d!==j.Z_SYNC_FLUSH)||("string"===this.options.to?(e=i.utf8border(m.output,m.next_out),f=m.next_out-e,k=i.buf2string(m.output,e),m.next_out=f,m.avail_out=o-f,f&&h.arraySet(m.output,m.output,e,f,0),this.onData(k)):this.onData(h.shrinkBuf(m.output,m.next_out)))),0===m.avail_in&&0===m.avail_out&&(q=!0)}while((m.avail_in>0||0===m.avail_out)&&c!==j.Z_STREAM_END);return c===j.Z_STREAM_END&&(d=j.Z_FINISH),d===j.Z_FINISH?(c=g.inflateEnd(this.strm),this.onEnd(c),this.ended=!0,c===j.Z_OK):d!==j.Z_SYNC_FLUSH||(this.onEnd(j.Z_OK),m.avail_out=0,!0)},d.prototype.onData=function(a){this.chunks.push(a)},d.prototype.onEnd=function(a){a===j.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=h.flattenChunks(this.chunks)),this.chunks=[],this.err=a,this.msg=this.strm.msg},c.Inflate=d,c.inflate=e,c.inflateRaw=f,c.ungzip=e},{"./utils/common":28,"./utils/strings":29,"./zlib/constants":31,"./zlib/gzheader":34,"./zlib/inflate":36,"./zlib/messages":38,"./zlib/zstream":40}],28:[function(a,b,c){"use strict";var d="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;c.assign=function(a){for(var b=Array.prototype.slice.call(arguments,1);b.length;){var c=b.shift();if(c){if("object"!=typeof c)throw new TypeError(c+"must be non-object");for(var d in c)c.hasOwnProperty(d)&&(a[d]=c[d])}}return a},c.shrinkBuf=function(a,b){return a.length===b?a:a.subarray?a.subarray(0,b):(a.length=b,a)};var e={arraySet:function(a,b,c,d,e){if(b.subarray&&a.subarray)return void a.set(b.subarray(c,c+d),e);for(var f=0;f<d;f++)a[e+f]=b[c+f]},flattenChunks:function(a){var b,c,d,e,f,g;for(d=0,b=0,c=a.length;b<c;b++)d+=a[b].length;for(g=new Uint8Array(d),e=0,b=0,c=a.length;b<c;b++)f=a[b],g.set(f,e),e+=f.length;return g}},f={arraySet:function(a,b,c,d,e){for(var f=0;f<d;f++)a[e+f]=b[c+f]},flattenChunks:function(a){return[].concat.apply([],a)}};c.setTyped=function(a){a?(c.Buf8=Uint8Array,c.Buf16=Uint16Array,c.Buf32=Int32Array,c.assign(c,e)):(c.Buf8=Array,c.Buf16=Array,c.Buf32=Array,c.assign(c,f))},c.setTyped(d)},{}],29:[function(a,b,c){"use strict";function d(a,b){if(b<65537&&(a.subarray&&g||!a.subarray&&f))return String.fromCharCode.apply(null,e.shrinkBuf(a,b));for(var c="",d=0;d<b;d++)c+=String.fromCharCode(a[d]);return c}var e=a("./common"),f=!0,g=!0;try{String.fromCharCode.apply(null,[0])}catch(h){f=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(h){g=!1}for(var i=new e.Buf8(256),j=0;j<256;j++)i[j]=j>=252?6:j>=248?5:j>=240?4:j>=224?3:j>=192?2:1;i[254]=i[254]=1,c.string2buf=function(a){var b,c,d,f,g,h=a.length,i=0;for(f=0;f<h;f++)c=a.charCodeAt(f),55296===(64512&c)&&f+1<h&&(d=a.charCodeAt(f+1),56320===(64512&d)&&(c=65536+(c-55296<<10)+(d-56320),f++)),i+=c<128?1:c<2048?2:c<65536?3:4;for(b=new e.Buf8(i),g=0,f=0;g<i;f++)c=a.charCodeAt(f),55296===(64512&c)&&f+1<h&&(d=a.charCodeAt(f+1),56320===(64512&d)&&(c=65536+(c-55296<<10)+(d-56320),f++)),c<128?b[g++]=c:c<2048?(b[g++]=192|c>>>6,b[g++]=128|63&c):c<65536?(b[g++]=224|c>>>12,b[g++]=128|c>>>6&63,b[g++]=128|63&c):(b[g++]=240|c>>>18,b[g++]=128|c>>>12&63,b[g++]=128|c>>>6&63,b[g++]=128|63&c);return b},c.buf2binstring=function(a){return d(a,a.length)},c.binstring2buf=function(a){for(var b=new e.Buf8(a.length),c=0,d=b.length;c<d;c++)b[c]=a.charCodeAt(c);return b},c.buf2string=function(a,b){var c,e,f,g,h=b||a.length,j=new Array(2*h);for(e=0,c=0;c<h;)if(f=a[c++],f<128)j[e++]=f;else if(g=i[f],g>4)j[e++]=65533,c+=g-1;else{for(f&=2===g?31:3===g?15:7;g>1&&c<h;)f=f<<6|63&a[c++],g--;g>1?j[e++]=65533:f<65536?j[e++]=f:(f-=65536,j[e++]=55296|f>>10&1023,j[e++]=56320|1023&f)}return d(j,e)},c.utf8border=function(a,b){var c;for(b=b||a.length,b>a.length&&(b=a.length),c=b-1;c>=0&&128===(192&a[c]);)c--;return c<0?b:0===c?b:c+i[a[c]]>b?c:b}},{"./common":28}],30:[function(a,b,c){"use strict";function d(a,b,c,d){for(var e=65535&a|0,f=a>>>16&65535|0,g=0;0!==c;){g=c>2e3?2e3:c,c-=g;do e=e+b[d++]|0,f=f+e|0;while(--g);e%=65521,f%=65521}return e|f<<16|0}b.exports=d},{}],31:[function(a,b,c){"use strict";b.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],32:[function(a,b,c){"use strict";function d(){for(var a,b=[],c=0;c<256;c++){a=c;for(var d=0;d<8;d++)a=1&a?3988292384^a>>>1:a>>>1;b[c]=a}return b}function e(a,b,c,d){var e=f,g=d+c;a^=-1;for(var h=d;h<g;h++)a=a>>>8^e[255&(a^b[h])];return a^-1}var f=d();b.exports=e},{}],33:[function(a,b,c){"use strict";function d(a,b){return a.msg=I[b],b}function e(a){return(a<<1)-(a>4?9:0)}function f(a){for(var b=a.length;--b>=0;)a[b]=0}function g(a){var b=a.state,c=b.pending;c>a.avail_out&&(c=a.avail_out),0!==c&&(E.arraySet(a.output,b.pending_buf,b.pending_out,c,a.next_out),a.next_out+=c,b.pending_out+=c,a.total_out+=c,a.avail_out-=c,b.pending-=c,0===b.pending&&(b.pending_out=0))}function h(a,b){F._tr_flush_block(a,a.block_start>=0?a.block_start:-1,a.strstart-a.block_start,b),a.block_start=a.strstart,g(a.strm)}function i(a,b){a.pending_buf[a.pending++]=b}function j(a,b){a.pending_buf[a.pending++]=b>>>8&255,a.pending_buf[a.pending++]=255&b}function k(a,b,c,d){var e=a.avail_in;return e>d&&(e=d),0===e?0:(a.avail_in-=e,E.arraySet(b,a.input,a.next_in,e,c),1===a.state.wrap?a.adler=G(a.adler,b,e,c):2===a.state.wrap&&(a.adler=H(a.adler,b,e,c)),a.next_in+=e,a.total_in+=e,e)}function l(a,b){var c,d,e=a.max_chain_length,f=a.strstart,g=a.prev_length,h=a.nice_match,i=a.strstart>a.w_size-la?a.strstart-(a.w_size-la):0,j=a.window,k=a.w_mask,l=a.prev,m=a.strstart+ka,n=j[f+g-1],o=j[f+g];a.prev_length>=a.good_match&&(e>>=2),h>a.lookahead&&(h=a.lookahead);do if(c=b,j[c+g]===o&&j[c+g-1]===n&&j[c]===j[f]&&j[++c]===j[f+1]){f+=2,c++;do;while(j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&f<m);if(d=ka-(m-f),f=m-ka,d>g){if(a.match_start=b,g=d,d>=h)break;n=j[f+g-1],o=j[f+g]}}while((b=l[b&k])>i&&0!==--e);return g<=a.lookahead?g:a.lookahead}function m(a){var b,c,d,e,f,g=a.w_size;do{if(e=a.window_size-a.lookahead-a.strstart,a.strstart>=g+(g-la)){E.arraySet(a.window,a.window,g,g,0),a.match_start-=g,a.strstart-=g,a.block_start-=g,c=a.hash_size,b=c;do d=a.head[--b],a.head[b]=d>=g?d-g:0;while(--c);c=g,b=c;do d=a.prev[--b],a.prev[b]=d>=g?d-g:0;while(--c);e+=g}if(0===a.strm.avail_in)break;if(c=k(a.strm,a.window,a.strstart+a.lookahead,e),a.lookahead+=c,a.lookahead+a.insert>=ja)for(f=a.strstart-a.insert,a.ins_h=a.window[f],a.ins_h=(a.ins_h<<a.hash_shift^a.window[f+1])&a.hash_mask;a.insert&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[f+ja-1])&a.hash_mask,a.prev[f&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=f,f++,a.insert--,!(a.lookahead+a.insert<ja)););}while(a.lookahead<la&&0!==a.strm.avail_in)}function n(a,b){var c=65535;for(c>a.pending_buf_size-5&&(c=a.pending_buf_size-5);;){if(a.lookahead<=1){if(m(a),0===a.lookahead&&b===J)return ua;if(0===a.lookahead)break}a.strstart+=a.lookahead,a.lookahead=0;var d=a.block_start+c;if((0===a.strstart||a.strstart>=d)&&(a.lookahead=a.strstart-d,a.strstart=d,h(a,!1),0===a.strm.avail_out))return ua;if(a.strstart-a.block_start>=a.w_size-la&&(h(a,!1),0===a.strm.avail_out))return ua}return a.insert=0,b===M?(h(a,!0),0===a.strm.avail_out?wa:xa):a.strstart>a.block_start&&(h(a,!1),0===a.strm.avail_out)?ua:ua}function o(a,b){for(var c,d;;){if(a.lookahead<la){if(m(a),a.lookahead<la&&b===J)return ua;if(0===a.lookahead)break}if(c=0,a.lookahead>=ja&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+ja-1])&a.hash_mask,c=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart),0!==c&&a.strstart-c<=a.w_size-la&&(a.match_length=l(a,c)),a.match_length>=ja)if(d=F._tr_tally(a,a.strstart-a.match_start,a.match_length-ja),a.lookahead-=a.match_length,a.match_length<=a.max_lazy_match&&a.lookahead>=ja){a.match_length--;do a.strstart++,a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+ja-1])&a.hash_mask,c=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart;while(0!==--a.match_length);a.strstart++}else a.strstart+=a.match_length,a.match_length=0,a.ins_h=a.window[a.strstart],a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+1])&a.hash_mask;else d=F._tr_tally(a,0,a.window[a.strstart]),a.lookahead--,a.strstart++;if(d&&(h(a,!1),0===a.strm.avail_out))return ua}return a.insert=a.strstart<ja-1?a.strstart:ja-1,b===M?(h(a,!0),0===a.strm.avail_out?wa:xa):a.last_lit&&(h(a,!1),0===a.strm.avail_out)?ua:va}function p(a,b){for(var c,d,e;;){if(a.lookahead<la){if(m(a),a.lookahead<la&&b===J)return ua;if(0===a.lookahead)break}if(c=0,a.lookahead>=ja&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+ja-1])&a.hash_mask,c=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart),a.prev_length=a.match_length,a.prev_match=a.match_start,a.match_length=ja-1,0!==c&&a.prev_length<a.max_lazy_match&&a.strstart-c<=a.w_size-la&&(a.match_length=l(a,c),a.match_length<=5&&(a.strategy===U||a.match_length===ja&&a.strstart-a.match_start>4096)&&(a.match_length=ja-1)),a.prev_length>=ja&&a.match_length<=a.prev_length){e=a.strstart+a.lookahead-ja,d=F._tr_tally(a,a.strstart-1-a.prev_match,a.prev_length-ja),a.lookahead-=a.prev_length-1,a.prev_length-=2;do++a.strstart<=e&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+ja-1])&a.hash_mask,c=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart);while(0!==--a.prev_length);if(a.match_available=0,a.match_length=ja-1,a.strstart++,d&&(h(a,!1),0===a.strm.avail_out))return ua}else if(a.match_available){if(d=F._tr_tally(a,0,a.window[a.strstart-1]),d&&h(a,!1),a.strstart++,a.lookahead--,0===a.strm.avail_out)return ua}else a.match_available=1,a.strstart++,a.lookahead--}return a.match_available&&(d=F._tr_tally(a,0,a.window[a.strstart-1]),a.match_available=0),a.insert=a.strstart<ja-1?a.strstart:ja-1,b===M?(h(a,!0),0===a.strm.avail_out?wa:xa):a.last_lit&&(h(a,!1),0===a.strm.avail_out)?ua:va}function q(a,b){for(var c,d,e,f,g=a.window;;){if(a.lookahead<=ka){if(m(a),a.lookahead<=ka&&b===J)return ua;if(0===a.lookahead)break}if(a.match_length=0,a.lookahead>=ja&&a.strstart>0&&(e=a.strstart-1,d=g[e],d===g[++e]&&d===g[++e]&&d===g[++e])){f=a.strstart+ka;do;while(d===g[++e]&&d===g[++e]&&d===g[++e]&&d===g[++e]&&d===g[++e]&&d===g[++e]&&d===g[++e]&&d===g[++e]&&e<f);a.match_length=ka-(f-e),a.match_length>a.lookahead&&(a.match_length=a.lookahead)}if(a.match_length>=ja?(c=F._tr_tally(a,1,a.match_length-ja),a.lookahead-=a.match_length,a.strstart+=a.match_length,a.match_length=0):(c=F._tr_tally(a,0,a.window[a.strstart]),a.lookahead--,a.strstart++),c&&(h(a,!1),0===a.strm.avail_out))return ua}return a.insert=0,b===M?(h(a,!0),0===a.strm.avail_out?wa:xa):a.last_lit&&(h(a,!1),0===a.strm.avail_out)?ua:va}function r(a,b){for(var c;;){if(0===a.lookahead&&(m(a),0===a.lookahead)){if(b===J)return ua;break}if(a.match_length=0,c=F._tr_tally(a,0,a.window[a.strstart]),a.lookahead--,a.strstart++,c&&(h(a,!1),0===a.strm.avail_out))return ua}return a.insert=0,b===M?(h(a,!0),0===a.strm.avail_out?wa:xa):a.last_lit&&(h(a,!1),0===a.strm.avail_out)?ua:va}function s(a,b,c,d,e){this.good_length=a,this.max_lazy=b,this.nice_length=c,this.max_chain=d,this.func=e}function t(a){a.window_size=2*a.w_size,f(a.head),a.max_lazy_match=D[a.level].max_lazy,a.good_match=D[a.level].good_length,a.nice_match=D[a.level].nice_length,a.max_chain_length=D[a.level].max_chain,a.strstart=0,a.block_start=0,a.lookahead=0,a.insert=0,a.match_length=a.prev_length=ja-1,a.match_available=0,a.ins_h=0}function u(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=$,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new E.Buf16(2*ha),this.dyn_dtree=new E.Buf16(2*(2*fa+1)),this.bl_tree=new E.Buf16(2*(2*ga+1)),f(this.dyn_ltree),f(this.dyn_dtree),f(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new E.Buf16(ia+1),this.heap=new E.Buf16(2*ea+1),f(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new E.Buf16(2*ea+1),f(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function v(a){var b;return a&&a.state?(a.total_in=a.total_out=0,a.data_type=Z,b=a.state,b.pending=0,b.pending_out=0,b.wrap<0&&(b.wrap=-b.wrap),b.status=b.wrap?na:sa,a.adler=2===b.wrap?0:1,b.last_flush=J,F._tr_init(b),O):d(a,Q)}function w(a){var b=v(a);return b===O&&t(a.state),b}function x(a,b){return a&&a.state?2!==a.state.wrap?Q:(a.state.gzhead=b,O):Q}function y(a,b,c,e,f,g){if(!a)return Q;var h=1;if(b===T&&(b=6),e<0?(h=0,e=-e):e>15&&(h=2,e-=16),f<1||f>_||c!==$||e<8||e>15||b<0||b>9||g<0||g>X)return d(a,Q);8===e&&(e=9);var i=new u;return a.state=i,i.strm=a,i.wrap=h,i.gzhead=null,i.w_bits=e,i.w_size=1<<i.w_bits,i.w_mask=i.w_size-1,i.hash_bits=f+7,i.hash_size=1<<i.hash_bits,i.hash_mask=i.hash_size-1,i.hash_shift=~~((i.hash_bits+ja-1)/ja),i.window=new E.Buf8(2*i.w_size),i.head=new E.Buf16(i.hash_size),i.prev=new E.Buf16(i.w_size),i.lit_bufsize=1<<f+6,i.pending_buf_size=4*i.lit_bufsize,i.pending_buf=new E.Buf8(i.pending_buf_size),i.d_buf=1*i.lit_bufsize,i.l_buf=3*i.lit_bufsize,i.level=b,i.strategy=g,i.method=c,w(a)}function z(a,b){return y(a,b,$,aa,ba,Y)}function A(a,b){var c,h,k,l;if(!a||!a.state||b>N||b<0)return a?d(a,Q):Q;if(h=a.state,!a.output||!a.input&&0!==a.avail_in||h.status===ta&&b!==M)return d(a,0===a.avail_out?S:Q);if(h.strm=a,c=h.last_flush,h.last_flush=b,h.status===na)if(2===h.wrap)a.adler=0,i(h,31),i(h,139),i(h,8),h.gzhead?(i(h,(h.gzhead.text?1:0)+(h.gzhead.hcrc?2:0)+(h.gzhead.extra?4:0)+(h.gzhead.name?8:0)+(h.gzhead.comment?16:0)),i(h,255&h.gzhead.time),i(h,h.gzhead.time>>8&255),i(h,h.gzhead.time>>16&255),i(h,h.gzhead.time>>24&255),i(h,9===h.level?2:h.strategy>=V||h.level<2?4:0),i(h,255&h.gzhead.os),h.gzhead.extra&&h.gzhead.extra.length&&(i(h,255&h.gzhead.extra.length),i(h,h.gzhead.extra.length>>8&255)),h.gzhead.hcrc&&(a.adler=H(a.adler,h.pending_buf,h.pending,0)),h.gzindex=0,h.status=oa):(i(h,0),i(h,0),i(h,0),i(h,0),i(h,0),i(h,9===h.level?2:h.strategy>=V||h.level<2?4:0),i(h,ya),h.status=sa);else{var m=$+(h.w_bits-8<<4)<<8,n=-1;n=h.strategy>=V||h.level<2?0:h.level<6?1:6===h.level?2:3,m|=n<<6,0!==h.strstart&&(m|=ma),m+=31-m%31,h.status=sa,j(h,m),0!==h.strstart&&(j(h,a.adler>>>16),j(h,65535&a.adler)),a.adler=1}if(h.status===oa)if(h.gzhead.extra){for(k=h.pending;h.gzindex<(65535&h.gzhead.extra.length)&&(h.pending!==h.pending_buf_size||(h.gzhead.hcrc&&h.pending>k&&(a.adler=H(a.adler,h.pending_buf,h.pending-k,k)),g(a),k=h.pending,h.pending!==h.pending_buf_size));)i(h,255&h.gzhead.extra[h.gzindex]),h.gzindex++;h.gzhead.hcrc&&h.pending>k&&(a.adler=H(a.adler,h.pending_buf,h.pending-k,k)),h.gzindex===h.gzhead.extra.length&&(h.gzindex=0,h.status=pa)}else h.status=pa;if(h.status===pa)if(h.gzhead.name){k=h.pending;do{if(h.pending===h.pending_buf_size&&(h.gzhead.hcrc&&h.pending>k&&(a.adler=H(a.adler,h.pending_buf,h.pending-k,k)),g(a),k=h.pending,h.pending===h.pending_buf_size)){l=1;break}l=h.gzindex<h.gzhead.name.length?255&h.gzhead.name.charCodeAt(h.gzindex++):0,i(h,l)}while(0!==l);h.gzhead.hcrc&&h.pending>k&&(a.adler=H(a.adler,h.pending_buf,h.pending-k,k)),0===l&&(h.gzindex=0,h.status=qa)}else h.status=qa;if(h.status===qa)if(h.gzhead.comment){k=h.pending;do{if(h.pending===h.pending_buf_size&&(h.gzhead.hcrc&&h.pending>k&&(a.adler=H(a.adler,h.pending_buf,h.pending-k,k)),g(a),k=h.pending,h.pending===h.pending_buf_size)){l=1;break}l=h.gzindex<h.gzhead.comment.length?255&h.gzhead.comment.charCodeAt(h.gzindex++):0,i(h,l)}while(0!==l);h.gzhead.hcrc&&h.pending>k&&(a.adler=H(a.adler,h.pending_buf,h.pending-k,k)),0===l&&(h.status=ra)}else h.status=ra;if(h.status===ra&&(h.gzhead.hcrc?(h.pending+2>h.pending_buf_size&&g(a),h.pending+2<=h.pending_buf_size&&(i(h,255&a.adler),i(h,a.adler>>8&255),a.adler=0,h.status=sa)):h.status=sa),0!==h.pending){if(g(a),0===a.avail_out)return h.last_flush=-1,O}else if(0===a.avail_in&&e(b)<=e(c)&&b!==M)return d(a,S);if(h.status===ta&&0!==a.avail_in)return d(a,S);if(0!==a.avail_in||0!==h.lookahead||b!==J&&h.status!==ta){var o=h.strategy===V?r(h,b):h.strategy===W?q(h,b):D[h.level].func(h,b);if(o!==wa&&o!==xa||(h.status=ta),o===ua||o===wa)return 0===a.avail_out&&(h.last_flush=-1),O;if(o===va&&(b===K?F._tr_align(h):b!==N&&(F._tr_stored_block(h,0,0,!1),b===L&&(f(h.head),0===h.lookahead&&(h.strstart=0,h.block_start=0,h.insert=0))),g(a),0===a.avail_out))return h.last_flush=-1,O}return b!==M?O:h.wrap<=0?P:(2===h.wrap?(i(h,255&a.adler),i(h,a.adler>>8&255),i(h,a.adler>>16&255),i(h,a.adler>>24&255),i(h,255&a.total_in),i(h,a.total_in>>8&255),i(h,a.total_in>>16&255),i(h,a.total_in>>24&255)):(j(h,a.adler>>>16),j(h,65535&a.adler)),g(a),h.wrap>0&&(h.wrap=-h.wrap),0!==h.pending?O:P)}function B(a){var b;return a&&a.state?(b=a.state.status,b!==na&&b!==oa&&b!==pa&&b!==qa&&b!==ra&&b!==sa&&b!==ta?d(a,Q):(a.state=null,b===sa?d(a,R):O)):Q}function C(a,b){var c,d,e,g,h,i,j,k,l=b.length;if(!a||!a.state)return Q;if(c=a.state,g=c.wrap,2===g||1===g&&c.status!==na||c.lookahead)return Q;for(1===g&&(a.adler=G(a.adler,b,l,0)),c.wrap=0,l>=c.w_size&&(0===g&&(f(c.head),c.strstart=0,c.block_start=0,c.insert=0),k=new E.Buf8(c.w_size),E.arraySet(k,b,l-c.w_size,c.w_size,0),b=k,l=c.w_size),h=a.avail_in,i=a.next_in,j=a.input,a.avail_in=l,a.next_in=0,a.input=b,m(c);c.lookahead>=ja;){d=c.strstart,e=c.lookahead-(ja-1);do c.ins_h=(c.ins_h<<c.hash_shift^c.window[d+ja-1])&c.hash_mask,c.prev[d&c.w_mask]=c.head[c.ins_h],c.head[c.ins_h]=d,d++;while(--e);c.strstart=d,c.lookahead=ja-1,m(c)}return c.strstart+=c.lookahead,c.block_start=c.strstart,c.insert=c.lookahead,c.lookahead=0,c.match_length=c.prev_length=ja-1,c.match_available=0,a.next_in=i,a.input=j,a.avail_in=h,c.wrap=g,O}var D,E=a("../utils/common"),F=a("./trees"),G=a("./adler32"),H=a("./crc32"),I=a("./messages"),J=0,K=1,L=3,M=4,N=5,O=0,P=1,Q=-2,R=-3,S=-5,T=-1,U=1,V=2,W=3,X=4,Y=0,Z=2,$=8,_=9,aa=15,ba=8,ca=29,da=256,ea=da+1+ca,fa=30,ga=19,ha=2*ea+1,ia=15,ja=3,ka=258,la=ka+ja+1,ma=32,na=42,oa=69,pa=73,qa=91,ra=103,sa=113,ta=666,ua=1,va=2,wa=3,xa=4,ya=3;D=[new s(0,0,0,0,n),new s(4,4,8,4,o),new s(4,5,16,8,o),new s(4,6,32,32,o),new s(4,4,16,16,p),new s(8,16,32,32,p),new s(8,16,128,128,p),new s(8,32,128,256,p),new s(32,128,258,1024,p),new s(32,258,258,4096,p)],c.deflateInit=z,c.deflateInit2=y,c.deflateReset=w,c.deflateResetKeep=v,c.deflateSetHeader=x,c.deflate=A,c.deflateEnd=B,c.deflateSetDictionary=C,c.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":28,"./adler32":30,"./crc32":32,"./messages":38,"./trees":39}],34:[function(a,b,c){"use strict";function d(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}b.exports=d},{}],35:[function(a,b,c){"use strict";var d=30,e=12;b.exports=function(a,b){var c,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C;c=a.state,f=a.next_in,B=a.input,g=f+(a.avail_in-5),h=a.next_out,C=a.output,i=h-(b-a.avail_out),j=h+(a.avail_out-257),k=c.dmax,l=c.wsize,m=c.whave,n=c.wnext,o=c.window,p=c.hold,q=c.bits,r=c.lencode,s=c.distcode,t=(1<<c.lenbits)-1,u=(1<<c.distbits)-1;a:do{q<15&&(p+=B[f++]<<q,q+=8,p+=B[f++]<<q,q+=8),v=r[p&t];b:for(;;){if(w=v>>>24,p>>>=w,q-=w,w=v>>>16&255,0===w)C[h++]=65535&v;else{if(!(16&w)){if(0===(64&w)){v=r[(65535&v)+(p&(1<<w)-1)];continue b}if(32&w){c.mode=e;break a}a.msg="invalid literal/length code",c.mode=d;break a}x=65535&v,w&=15,w&&(q<w&&(p+=B[f++]<<q,q+=8),x+=p&(1<<w)-1,p>>>=w,q-=w),q<15&&(p+=B[f++]<<q,q+=8,p+=B[f++]<<q,q+=8),v=s[p&u];c:for(;;){if(w=v>>>24,p>>>=w,q-=w,w=v>>>16&255,!(16&w)){if(0===(64&w)){v=s[(65535&v)+(p&(1<<w)-1)];continue c}a.msg="invalid distance code",c.mode=d;break a}if(y=65535&v,w&=15,q<w&&(p+=B[f++]<<q,q+=8,q<w&&(p+=B[f++]<<q,q+=8)),y+=p&(1<<w)-1,y>k){a.msg="invalid distance too far back",c.mode=d;break a}if(p>>>=w,q-=w,w=h-i,y>w){if(w=y-w,w>m&&c.sane){a.msg="invalid distance too far back",c.mode=d;break a}if(z=0,A=o,0===n){if(z+=l-w,w<x){x-=w;do C[h++]=o[z++];while(--w);z=h-y,A=C}}else if(n<w){if(z+=l+n-w,w-=n,w<x){x-=w;do C[h++]=o[z++];while(--w);if(z=0,n<x){w=n,x-=w;do C[h++]=o[z++];while(--w);z=h-y,A=C}}}else if(z+=n-w,w<x){x-=w;do C[h++]=o[z++];while(--w);z=h-y,A=C}for(;x>2;)C[h++]=A[z++],C[h++]=A[z++],C[h++]=A[z++],x-=3;x&&(C[h++]=A[z++],x>1&&(C[h++]=A[z++]))}else{z=h-y;do C[h++]=C[z++],C[h++]=C[z++],C[h++]=C[z++],x-=3;while(x>2);x&&(C[h++]=C[z++],x>1&&(C[h++]=C[z++]))}break}}break}}while(f<g&&h<j);x=q>>3,f-=x,q-=x<<3,p&=(1<<q)-1,a.next_in=f,a.next_out=h,a.avail_in=f<g?5+(g-f):5-(f-g),a.avail_out=h<j?257+(j-h):257-(h-j),c.hold=p,c.bits=q}},{}],36:[function(a,b,c){"use strict";function d(a){return(a>>>24&255)+(a>>>8&65280)+((65280&a)<<8)+((255&a)<<24)}function e(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new s.Buf16(320),this.work=new s.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function f(a){var b;return a&&a.state?(b=a.state,a.total_in=a.total_out=b.total=0,a.msg="",b.wrap&&(a.adler=1&b.wrap),b.mode=L,b.last=0,b.havedict=0,b.dmax=32768,b.head=null,b.hold=0,b.bits=0,b.lencode=b.lendyn=new s.Buf32(pa),b.distcode=b.distdyn=new s.Buf32(qa),b.sane=1,b.back=-1,D):G}function g(a){var b;return a&&a.state?(b=a.state,b.wsize=0,b.whave=0,b.wnext=0,f(a)):G}function h(a,b){var c,d;return a&&a.state?(d=a.state,b<0?(c=0,b=-b):(c=(b>>4)+1,b<48&&(b&=15)),b&&(b<8||b>15)?G:(null!==d.window&&d.wbits!==b&&(d.window=null),d.wrap=c,d.wbits=b,g(a))):G}function i(a,b){var c,d;return a?(d=new e,a.state=d,d.window=null,c=h(a,b),c!==D&&(a.state=null),c):G}function j(a){return i(a,sa)}function k(a){if(ta){var b;for(q=new s.Buf32(512),r=new s.Buf32(32),b=0;b<144;)a.lens[b++]=8;for(;b<256;)a.lens[b++]=9;for(;b<280;)a.lens[b++]=7;for(;b<288;)a.lens[b++]=8;for(w(y,a.lens,0,288,q,0,a.work,{bits:9}),b=0;b<32;)a.lens[b++]=5;w(z,a.lens,0,32,r,0,a.work,{bits:5}),ta=!1}a.lencode=q,a.lenbits=9,a.distcode=r,a.distbits=5}function l(a,b,c,d){var e,f=a.state;return null===f.window&&(f.wsize=1<<f.wbits,f.wnext=0,f.whave=0,f.window=new s.Buf8(f.wsize)),d>=f.wsize?(s.arraySet(f.window,b,c-f.wsize,f.wsize,0),f.wnext=0,f.whave=f.wsize):(e=f.wsize-f.wnext,e>d&&(e=d),s.arraySet(f.window,b,c-d,e,f.wnext),d-=e,d?(s.arraySet(f.window,b,c-d,d,0),f.wnext=d,f.whave=f.wsize):(f.wnext+=e,f.wnext===f.wsize&&(f.wnext=0),f.whave<f.wsize&&(f.whave+=e))),0}function m(a,b){var c,e,f,g,h,i,j,m,n,o,p,q,r,pa,qa,ra,sa,ta,ua,va,wa,xa,ya,za,Aa=0,Ba=new s.Buf8(4),Ca=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!a||!a.state||!a.output||!a.input&&0!==a.avail_in)return G;c=a.state,c.mode===W&&(c.mode=X),h=a.next_out,f=a.output,j=a.avail_out,g=a.next_in,e=a.input,i=a.avail_in,m=c.hold,n=c.bits,o=i,p=j,xa=D;a:for(;;)switch(c.mode){case L:if(0===c.wrap){c.mode=X;break}for(;n<16;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(2&c.wrap&&35615===m){c.check=0,Ba[0]=255&m,Ba[1]=m>>>8&255,c.check=u(c.check,Ba,2,0),m=0,n=0,c.mode=M;break}if(c.flags=0,c.head&&(c.head.done=!1),!(1&c.wrap)||(((255&m)<<8)+(m>>8))%31){a.msg="incorrect header check",c.mode=ma;break}if((15&m)!==K){a.msg="unknown compression method",c.mode=ma;break}if(m>>>=4,n-=4,wa=(15&m)+8,0===c.wbits)c.wbits=wa;else if(wa>c.wbits){a.msg="invalid window size",c.mode=ma;break}c.dmax=1<<wa,a.adler=c.check=1,c.mode=512&m?U:W,m=0,n=0;break;case M:for(;n<16;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(c.flags=m,(255&c.flags)!==K){a.msg="unknown compression method",c.mode=ma;break}if(57344&c.flags){a.msg="unknown header flags set",c.mode=ma;break}c.head&&(c.head.text=m>>8&1),512&c.flags&&(Ba[0]=255&m,Ba[1]=m>>>8&255,c.check=u(c.check,Ba,2,0)),m=0,n=0,c.mode=N;case N:for(;n<32;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}c.head&&(c.head.time=m),512&c.flags&&(Ba[0]=255&m,Ba[1]=m>>>8&255,Ba[2]=m>>>16&255,Ba[3]=m>>>24&255,c.check=u(c.check,Ba,4,0)),m=0,n=0,c.mode=O;case O:for(;n<16;){if(0===i)break a;i--,m+=e[g++]<<n,
n+=8}c.head&&(c.head.xflags=255&m,c.head.os=m>>8),512&c.flags&&(Ba[0]=255&m,Ba[1]=m>>>8&255,c.check=u(c.check,Ba,2,0)),m=0,n=0,c.mode=P;case P:if(1024&c.flags){for(;n<16;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}c.length=m,c.head&&(c.head.extra_len=m),512&c.flags&&(Ba[0]=255&m,Ba[1]=m>>>8&255,c.check=u(c.check,Ba,2,0)),m=0,n=0}else c.head&&(c.head.extra=null);c.mode=Q;case Q:if(1024&c.flags&&(q=c.length,q>i&&(q=i),q&&(c.head&&(wa=c.head.extra_len-c.length,c.head.extra||(c.head.extra=new Array(c.head.extra_len)),s.arraySet(c.head.extra,e,g,q,wa)),512&c.flags&&(c.check=u(c.check,e,q,g)),i-=q,g+=q,c.length-=q),c.length))break a;c.length=0,c.mode=R;case R:if(2048&c.flags){if(0===i)break a;q=0;do wa=e[g+q++],c.head&&wa&&c.length<65536&&(c.head.name+=String.fromCharCode(wa));while(wa&&q<i);if(512&c.flags&&(c.check=u(c.check,e,q,g)),i-=q,g+=q,wa)break a}else c.head&&(c.head.name=null);c.length=0,c.mode=S;case S:if(4096&c.flags){if(0===i)break a;q=0;do wa=e[g+q++],c.head&&wa&&c.length<65536&&(c.head.comment+=String.fromCharCode(wa));while(wa&&q<i);if(512&c.flags&&(c.check=u(c.check,e,q,g)),i-=q,g+=q,wa)break a}else c.head&&(c.head.comment=null);c.mode=T;case T:if(512&c.flags){for(;n<16;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(m!==(65535&c.check)){a.msg="header crc mismatch",c.mode=ma;break}m=0,n=0}c.head&&(c.head.hcrc=c.flags>>9&1,c.head.done=!0),a.adler=c.check=0,c.mode=W;break;case U:for(;n<32;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}a.adler=c.check=d(m),m=0,n=0,c.mode=V;case V:if(0===c.havedict)return a.next_out=h,a.avail_out=j,a.next_in=g,a.avail_in=i,c.hold=m,c.bits=n,F;a.adler=c.check=1,c.mode=W;case W:if(b===B||b===C)break a;case X:if(c.last){m>>>=7&n,n-=7&n,c.mode=ja;break}for(;n<3;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}switch(c.last=1&m,m>>>=1,n-=1,3&m){case 0:c.mode=Y;break;case 1:if(k(c),c.mode=ca,b===C){m>>>=2,n-=2;break a}break;case 2:c.mode=_;break;case 3:a.msg="invalid block type",c.mode=ma}m>>>=2,n-=2;break;case Y:for(m>>>=7&n,n-=7&n;n<32;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if((65535&m)!==(m>>>16^65535)){a.msg="invalid stored block lengths",c.mode=ma;break}if(c.length=65535&m,m=0,n=0,c.mode=Z,b===C)break a;case Z:c.mode=$;case $:if(q=c.length){if(q>i&&(q=i),q>j&&(q=j),0===q)break a;s.arraySet(f,e,g,q,h),i-=q,g+=q,j-=q,h+=q,c.length-=q;break}c.mode=W;break;case _:for(;n<14;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(c.nlen=(31&m)+257,m>>>=5,n-=5,c.ndist=(31&m)+1,m>>>=5,n-=5,c.ncode=(15&m)+4,m>>>=4,n-=4,c.nlen>286||c.ndist>30){a.msg="too many length or distance symbols",c.mode=ma;break}c.have=0,c.mode=aa;case aa:for(;c.have<c.ncode;){for(;n<3;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}c.lens[Ca[c.have++]]=7&m,m>>>=3,n-=3}for(;c.have<19;)c.lens[Ca[c.have++]]=0;if(c.lencode=c.lendyn,c.lenbits=7,ya={bits:c.lenbits},xa=w(x,c.lens,0,19,c.lencode,0,c.work,ya),c.lenbits=ya.bits,xa){a.msg="invalid code lengths set",c.mode=ma;break}c.have=0,c.mode=ba;case ba:for(;c.have<c.nlen+c.ndist;){for(;Aa=c.lencode[m&(1<<c.lenbits)-1],qa=Aa>>>24,ra=Aa>>>16&255,sa=65535&Aa,!(qa<=n);){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(sa<16)m>>>=qa,n-=qa,c.lens[c.have++]=sa;else{if(16===sa){for(za=qa+2;n<za;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(m>>>=qa,n-=qa,0===c.have){a.msg="invalid bit length repeat",c.mode=ma;break}wa=c.lens[c.have-1],q=3+(3&m),m>>>=2,n-=2}else if(17===sa){for(za=qa+3;n<za;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}m>>>=qa,n-=qa,wa=0,q=3+(7&m),m>>>=3,n-=3}else{for(za=qa+7;n<za;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}m>>>=qa,n-=qa,wa=0,q=11+(127&m),m>>>=7,n-=7}if(c.have+q>c.nlen+c.ndist){a.msg="invalid bit length repeat",c.mode=ma;break}for(;q--;)c.lens[c.have++]=wa}}if(c.mode===ma)break;if(0===c.lens[256]){a.msg="invalid code -- missing end-of-block",c.mode=ma;break}if(c.lenbits=9,ya={bits:c.lenbits},xa=w(y,c.lens,0,c.nlen,c.lencode,0,c.work,ya),c.lenbits=ya.bits,xa){a.msg="invalid literal/lengths set",c.mode=ma;break}if(c.distbits=6,c.distcode=c.distdyn,ya={bits:c.distbits},xa=w(z,c.lens,c.nlen,c.ndist,c.distcode,0,c.work,ya),c.distbits=ya.bits,xa){a.msg="invalid distances set",c.mode=ma;break}if(c.mode=ca,b===C)break a;case ca:c.mode=da;case da:if(i>=6&&j>=258){a.next_out=h,a.avail_out=j,a.next_in=g,a.avail_in=i,c.hold=m,c.bits=n,v(a,p),h=a.next_out,f=a.output,j=a.avail_out,g=a.next_in,e=a.input,i=a.avail_in,m=c.hold,n=c.bits,c.mode===W&&(c.back=-1);break}for(c.back=0;Aa=c.lencode[m&(1<<c.lenbits)-1],qa=Aa>>>24,ra=Aa>>>16&255,sa=65535&Aa,!(qa<=n);){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(ra&&0===(240&ra)){for(ta=qa,ua=ra,va=sa;Aa=c.lencode[va+((m&(1<<ta+ua)-1)>>ta)],qa=Aa>>>24,ra=Aa>>>16&255,sa=65535&Aa,!(ta+qa<=n);){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}m>>>=ta,n-=ta,c.back+=ta}if(m>>>=qa,n-=qa,c.back+=qa,c.length=sa,0===ra){c.mode=ia;break}if(32&ra){c.back=-1,c.mode=W;break}if(64&ra){a.msg="invalid literal/length code",c.mode=ma;break}c.extra=15&ra,c.mode=ea;case ea:if(c.extra){for(za=c.extra;n<za;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}c.length+=m&(1<<c.extra)-1,m>>>=c.extra,n-=c.extra,c.back+=c.extra}c.was=c.length,c.mode=fa;case fa:for(;Aa=c.distcode[m&(1<<c.distbits)-1],qa=Aa>>>24,ra=Aa>>>16&255,sa=65535&Aa,!(qa<=n);){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(0===(240&ra)){for(ta=qa,ua=ra,va=sa;Aa=c.distcode[va+((m&(1<<ta+ua)-1)>>ta)],qa=Aa>>>24,ra=Aa>>>16&255,sa=65535&Aa,!(ta+qa<=n);){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}m>>>=ta,n-=ta,c.back+=ta}if(m>>>=qa,n-=qa,c.back+=qa,64&ra){a.msg="invalid distance code",c.mode=ma;break}c.offset=sa,c.extra=15&ra,c.mode=ga;case ga:if(c.extra){for(za=c.extra;n<za;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}c.offset+=m&(1<<c.extra)-1,m>>>=c.extra,n-=c.extra,c.back+=c.extra}if(c.offset>c.dmax){a.msg="invalid distance too far back",c.mode=ma;break}c.mode=ha;case ha:if(0===j)break a;if(q=p-j,c.offset>q){if(q=c.offset-q,q>c.whave&&c.sane){a.msg="invalid distance too far back",c.mode=ma;break}q>c.wnext?(q-=c.wnext,r=c.wsize-q):r=c.wnext-q,q>c.length&&(q=c.length),pa=c.window}else pa=f,r=h-c.offset,q=c.length;q>j&&(q=j),j-=q,c.length-=q;do f[h++]=pa[r++];while(--q);0===c.length&&(c.mode=da);break;case ia:if(0===j)break a;f[h++]=c.length,j--,c.mode=da;break;case ja:if(c.wrap){for(;n<32;){if(0===i)break a;i--,m|=e[g++]<<n,n+=8}if(p-=j,a.total_out+=p,c.total+=p,p&&(a.adler=c.check=c.flags?u(c.check,f,p,h-p):t(c.check,f,p,h-p)),p=j,(c.flags?m:d(m))!==c.check){a.msg="incorrect data check",c.mode=ma;break}m=0,n=0}c.mode=ka;case ka:if(c.wrap&&c.flags){for(;n<32;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(m!==(4294967295&c.total)){a.msg="incorrect length check",c.mode=ma;break}m=0,n=0}c.mode=la;case la:xa=E;break a;case ma:xa=H;break a;case na:return I;case oa:default:return G}return a.next_out=h,a.avail_out=j,a.next_in=g,a.avail_in=i,c.hold=m,c.bits=n,(c.wsize||p!==a.avail_out&&c.mode<ma&&(c.mode<ja||b!==A))&&l(a,a.output,a.next_out,p-a.avail_out)?(c.mode=na,I):(o-=a.avail_in,p-=a.avail_out,a.total_in+=o,a.total_out+=p,c.total+=p,c.wrap&&p&&(a.adler=c.check=c.flags?u(c.check,f,p,a.next_out-p):t(c.check,f,p,a.next_out-p)),a.data_type=c.bits+(c.last?64:0)+(c.mode===W?128:0)+(c.mode===ca||c.mode===Z?256:0),(0===o&&0===p||b===A)&&xa===D&&(xa=J),xa)}function n(a){if(!a||!a.state)return G;var b=a.state;return b.window&&(b.window=null),a.state=null,D}function o(a,b){var c;return a&&a.state?(c=a.state,0===(2&c.wrap)?G:(c.head=b,b.done=!1,D)):G}function p(a,b){var c,d,e,f=b.length;return a&&a.state?(c=a.state,0!==c.wrap&&c.mode!==V?G:c.mode===V&&(d=1,d=t(d,b,f,0),d!==c.check)?H:(e=l(a,b,f,f))?(c.mode=na,I):(c.havedict=1,D)):G}var q,r,s=a("../utils/common"),t=a("./adler32"),u=a("./crc32"),v=a("./inffast"),w=a("./inftrees"),x=0,y=1,z=2,A=4,B=5,C=6,D=0,E=1,F=2,G=-2,H=-3,I=-4,J=-5,K=8,L=1,M=2,N=3,O=4,P=5,Q=6,R=7,S=8,T=9,U=10,V=11,W=12,X=13,Y=14,Z=15,$=16,_=17,aa=18,ba=19,ca=20,da=21,ea=22,fa=23,ga=24,ha=25,ia=26,ja=27,ka=28,la=29,ma=30,na=31,oa=32,pa=852,qa=592,ra=15,sa=ra,ta=!0;c.inflateReset=g,c.inflateReset2=h,c.inflateResetKeep=f,c.inflateInit=j,c.inflateInit2=i,c.inflate=m,c.inflateEnd=n,c.inflateGetHeader=o,c.inflateSetDictionary=p,c.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":28,"./adler32":30,"./crc32":32,"./inffast":35,"./inftrees":37}],37:[function(a,b,c){"use strict";var d=a("../utils/common"),e=15,f=852,g=592,h=0,i=1,j=2,k=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],l=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],m=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],n=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];b.exports=function(a,b,c,o,p,q,r,s){var t,u,v,w,x,y,z,A,B,C=s.bits,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=null,O=0,P=new d.Buf16(e+1),Q=new d.Buf16(e+1),R=null,S=0;for(D=0;D<=e;D++)P[D]=0;for(E=0;E<o;E++)P[b[c+E]]++;for(H=C,G=e;G>=1&&0===P[G];G--);if(H>G&&(H=G),0===G)return p[q++]=20971520,p[q++]=20971520,s.bits=1,0;for(F=1;F<G&&0===P[F];F++);for(H<F&&(H=F),K=1,D=1;D<=e;D++)if(K<<=1,K-=P[D],K<0)return-1;if(K>0&&(a===h||1!==G))return-1;for(Q[1]=0,D=1;D<e;D++)Q[D+1]=Q[D]+P[D];for(E=0;E<o;E++)0!==b[c+E]&&(r[Q[b[c+E]]++]=E);if(a===h?(N=R=r,y=19):a===i?(N=k,O-=257,R=l,S-=257,y=256):(N=m,R=n,y=-1),M=0,E=0,D=F,x=q,I=H,J=0,v=-1,L=1<<H,w=L-1,a===i&&L>f||a===j&&L>g)return 1;for(var T=0;;){T++,z=D-J,r[E]<y?(A=0,B=r[E]):r[E]>y?(A=R[S+r[E]],B=N[O+r[E]]):(A=96,B=0),t=1<<D-J,u=1<<I,F=u;do u-=t,p[x+(M>>J)+u]=z<<24|A<<16|B|0;while(0!==u);for(t=1<<D-1;M&t;)t>>=1;if(0!==t?(M&=t-1,M+=t):M=0,E++,0===--P[D]){if(D===G)break;D=b[c+r[E]]}if(D>H&&(M&w)!==v){for(0===J&&(J=H),x+=F,I=D-J,K=1<<I;I+J<G&&(K-=P[I+J],!(K<=0));)I++,K<<=1;if(L+=1<<I,a===i&&L>f||a===j&&L>g)return 1;v=M&w,p[v]=H<<24|I<<16|x-q|0}}return 0!==M&&(p[x+M]=D-J<<24|64<<16|0),s.bits=H,0}},{"../utils/common":28}],38:[function(a,b,c){"use strict";b.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],39:[function(a,b,c){"use strict";function d(a){for(var b=a.length;--b>=0;)a[b]=0}function e(a,b,c,d,e){this.static_tree=a,this.extra_bits=b,this.extra_base=c,this.elems=d,this.max_length=e,this.has_stree=a&&a.length}function f(a,b){this.dyn_tree=a,this.max_code=0,this.stat_desc=b}function g(a){return a<256?ia[a]:ia[256+(a>>>7)]}function h(a,b){a.pending_buf[a.pending++]=255&b,a.pending_buf[a.pending++]=b>>>8&255}function i(a,b,c){a.bi_valid>X-c?(a.bi_buf|=b<<a.bi_valid&65535,h(a,a.bi_buf),a.bi_buf=b>>X-a.bi_valid,a.bi_valid+=c-X):(a.bi_buf|=b<<a.bi_valid&65535,a.bi_valid+=c)}function j(a,b,c){i(a,c[2*b],c[2*b+1])}function k(a,b){var c=0;do c|=1&a,a>>>=1,c<<=1;while(--b>0);return c>>>1}function l(a){16===a.bi_valid?(h(a,a.bi_buf),a.bi_buf=0,a.bi_valid=0):a.bi_valid>=8&&(a.pending_buf[a.pending++]=255&a.bi_buf,a.bi_buf>>=8,a.bi_valid-=8)}function m(a,b){var c,d,e,f,g,h,i=b.dyn_tree,j=b.max_code,k=b.stat_desc.static_tree,l=b.stat_desc.has_stree,m=b.stat_desc.extra_bits,n=b.stat_desc.extra_base,o=b.stat_desc.max_length,p=0;for(f=0;f<=W;f++)a.bl_count[f]=0;for(i[2*a.heap[a.heap_max]+1]=0,c=a.heap_max+1;c<V;c++)d=a.heap[c],f=i[2*i[2*d+1]+1]+1,f>o&&(f=o,p++),i[2*d+1]=f,d>j||(a.bl_count[f]++,g=0,d>=n&&(g=m[d-n]),h=i[2*d],a.opt_len+=h*(f+g),l&&(a.static_len+=h*(k[2*d+1]+g)));if(0!==p){do{for(f=o-1;0===a.bl_count[f];)f--;a.bl_count[f]--,a.bl_count[f+1]+=2,a.bl_count[o]--,p-=2}while(p>0);for(f=o;0!==f;f--)for(d=a.bl_count[f];0!==d;)e=a.heap[--c],e>j||(i[2*e+1]!==f&&(a.opt_len+=(f-i[2*e+1])*i[2*e],i[2*e+1]=f),d--)}}function n(a,b,c){var d,e,f=new Array(W+1),g=0;for(d=1;d<=W;d++)f[d]=g=g+c[d-1]<<1;for(e=0;e<=b;e++){var h=a[2*e+1];0!==h&&(a[2*e]=k(f[h]++,h))}}function o(){var a,b,c,d,f,g=new Array(W+1);for(c=0,d=0;d<Q-1;d++)for(ka[d]=c,a=0;a<1<<ba[d];a++)ja[c++]=d;for(ja[c-1]=d,f=0,d=0;d<16;d++)for(la[d]=f,a=0;a<1<<ca[d];a++)ia[f++]=d;for(f>>=7;d<T;d++)for(la[d]=f<<7,a=0;a<1<<ca[d]-7;a++)ia[256+f++]=d;for(b=0;b<=W;b++)g[b]=0;for(a=0;a<=143;)ga[2*a+1]=8,a++,g[8]++;for(;a<=255;)ga[2*a+1]=9,a++,g[9]++;for(;a<=279;)ga[2*a+1]=7,a++,g[7]++;for(;a<=287;)ga[2*a+1]=8,a++,g[8]++;for(n(ga,S+1,g),a=0;a<T;a++)ha[2*a+1]=5,ha[2*a]=k(a,5);ma=new e(ga,ba,R+1,S,W),na=new e(ha,ca,0,T,W),oa=new e(new Array(0),da,0,U,Y)}function p(a){var b;for(b=0;b<S;b++)a.dyn_ltree[2*b]=0;for(b=0;b<T;b++)a.dyn_dtree[2*b]=0;for(b=0;b<U;b++)a.bl_tree[2*b]=0;a.dyn_ltree[2*Z]=1,a.opt_len=a.static_len=0,a.last_lit=a.matches=0}function q(a){a.bi_valid>8?h(a,a.bi_buf):a.bi_valid>0&&(a.pending_buf[a.pending++]=a.bi_buf),a.bi_buf=0,a.bi_valid=0}function r(a,b,c,d){q(a),d&&(h(a,c),h(a,~c)),G.arraySet(a.pending_buf,a.window,b,c,a.pending),a.pending+=c}function s(a,b,c,d){var e=2*b,f=2*c;return a[e]<a[f]||a[e]===a[f]&&d[b]<=d[c]}function t(a,b,c){for(var d=a.heap[c],e=c<<1;e<=a.heap_len&&(e<a.heap_len&&s(b,a.heap[e+1],a.heap[e],a.depth)&&e++,!s(b,d,a.heap[e],a.depth));)a.heap[c]=a.heap[e],c=e,e<<=1;a.heap[c]=d}function u(a,b,c){var d,e,f,h,k=0;if(0!==a.last_lit)do d=a.pending_buf[a.d_buf+2*k]<<8|a.pending_buf[a.d_buf+2*k+1],e=a.pending_buf[a.l_buf+k],k++,0===d?j(a,e,b):(f=ja[e],j(a,f+R+1,b),h=ba[f],0!==h&&(e-=ka[f],i(a,e,h)),d--,f=g(d),j(a,f,c),h=ca[f],0!==h&&(d-=la[f],i(a,d,h)));while(k<a.last_lit);j(a,Z,b)}function v(a,b){var c,d,e,f=b.dyn_tree,g=b.stat_desc.static_tree,h=b.stat_desc.has_stree,i=b.stat_desc.elems,j=-1;for(a.heap_len=0,a.heap_max=V,c=0;c<i;c++)0!==f[2*c]?(a.heap[++a.heap_len]=j=c,a.depth[c]=0):f[2*c+1]=0;for(;a.heap_len<2;)e=a.heap[++a.heap_len]=j<2?++j:0,f[2*e]=1,a.depth[e]=0,a.opt_len--,h&&(a.static_len-=g[2*e+1]);for(b.max_code=j,c=a.heap_len>>1;c>=1;c--)t(a,f,c);e=i;do c=a.heap[1],a.heap[1]=a.heap[a.heap_len--],t(a,f,1),d=a.heap[1],a.heap[--a.heap_max]=c,a.heap[--a.heap_max]=d,f[2*e]=f[2*c]+f[2*d],a.depth[e]=(a.depth[c]>=a.depth[d]?a.depth[c]:a.depth[d])+1,f[2*c+1]=f[2*d+1]=e,a.heap[1]=e++,t(a,f,1);while(a.heap_len>=2);a.heap[--a.heap_max]=a.heap[1],m(a,b),n(f,j,a.bl_count)}function w(a,b,c){var d,e,f=-1,g=b[1],h=0,i=7,j=4;for(0===g&&(i=138,j=3),b[2*(c+1)+1]=65535,d=0;d<=c;d++)e=g,g=b[2*(d+1)+1],++h<i&&e===g||(h<j?a.bl_tree[2*e]+=h:0!==e?(e!==f&&a.bl_tree[2*e]++,a.bl_tree[2*$]++):h<=10?a.bl_tree[2*_]++:a.bl_tree[2*aa]++,h=0,f=e,0===g?(i=138,j=3):e===g?(i=6,j=3):(i=7,j=4))}function x(a,b,c){var d,e,f=-1,g=b[1],h=0,k=7,l=4;for(0===g&&(k=138,l=3),d=0;d<=c;d++)if(e=g,g=b[2*(d+1)+1],!(++h<k&&e===g)){if(h<l){do j(a,e,a.bl_tree);while(0!==--h)}else 0!==e?(e!==f&&(j(a,e,a.bl_tree),h--),j(a,$,a.bl_tree),i(a,h-3,2)):h<=10?(j(a,_,a.bl_tree),i(a,h-3,3)):(j(a,aa,a.bl_tree),i(a,h-11,7));h=0,f=e,0===g?(k=138,l=3):e===g?(k=6,l=3):(k=7,l=4)}}function y(a){var b;for(w(a,a.dyn_ltree,a.l_desc.max_code),w(a,a.dyn_dtree,a.d_desc.max_code),v(a,a.bl_desc),b=U-1;b>=3&&0===a.bl_tree[2*ea[b]+1];b--);return a.opt_len+=3*(b+1)+5+5+4,b}function z(a,b,c,d){var e;for(i(a,b-257,5),i(a,c-1,5),i(a,d-4,4),e=0;e<d;e++)i(a,a.bl_tree[2*ea[e]+1],3);x(a,a.dyn_ltree,b-1),x(a,a.dyn_dtree,c-1)}function A(a){var b,c=4093624447;for(b=0;b<=31;b++,c>>>=1)if(1&c&&0!==a.dyn_ltree[2*b])return I;if(0!==a.dyn_ltree[18]||0!==a.dyn_ltree[20]||0!==a.dyn_ltree[26])return J;for(b=32;b<R;b++)if(0!==a.dyn_ltree[2*b])return J;return I}function B(a){pa||(o(),pa=!0),a.l_desc=new f(a.dyn_ltree,ma),a.d_desc=new f(a.dyn_dtree,na),a.bl_desc=new f(a.bl_tree,oa),a.bi_buf=0,a.bi_valid=0,p(a)}function C(a,b,c,d){i(a,(L<<1)+(d?1:0),3),r(a,b,c,!0)}function D(a){i(a,M<<1,3),j(a,Z,ga),l(a)}function E(a,b,c,d){var e,f,g=0;a.level>0?(a.strm.data_type===K&&(a.strm.data_type=A(a)),v(a,a.l_desc),v(a,a.d_desc),g=y(a),e=a.opt_len+3+7>>>3,f=a.static_len+3+7>>>3,f<=e&&(e=f)):e=f=c+5,c+4<=e&&b!==-1?C(a,b,c,d):a.strategy===H||f===e?(i(a,(M<<1)+(d?1:0),3),u(a,ga,ha)):(i(a,(N<<1)+(d?1:0),3),z(a,a.l_desc.max_code+1,a.d_desc.max_code+1,g+1),u(a,a.dyn_ltree,a.dyn_dtree)),p(a),d&&q(a)}function F(a,b,c){return a.pending_buf[a.d_buf+2*a.last_lit]=b>>>8&255,a.pending_buf[a.d_buf+2*a.last_lit+1]=255&b,a.pending_buf[a.l_buf+a.last_lit]=255&c,a.last_lit++,0===b?a.dyn_ltree[2*c]++:(a.matches++,b--,a.dyn_ltree[2*(ja[c]+R+1)]++,a.dyn_dtree[2*g(b)]++),a.last_lit===a.lit_bufsize-1}var G=a("../utils/common"),H=4,I=0,J=1,K=2,L=0,M=1,N=2,O=3,P=258,Q=29,R=256,S=R+1+Q,T=30,U=19,V=2*S+1,W=15,X=16,Y=7,Z=256,$=16,_=17,aa=18,ba=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],ca=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],da=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],ea=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],fa=512,ga=new Array(2*(S+2));d(ga);var ha=new Array(2*T);d(ha);var ia=new Array(fa);d(ia);var ja=new Array(P-O+1);d(ja);var ka=new Array(Q);d(ka);var la=new Array(T);d(la);var ma,na,oa,pa=!1;c._tr_init=B,c._tr_stored_block=C,c._tr_flush_block=E,c._tr_tally=F,c._tr_align=D},{"../utils/common":28}],40:[function(a,b,c){"use strict";function d(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}b.exports=d},{}]},{},[10])(10)});
/**
 * Kendo UI v2024.4.1112 (http://www.telerik.com/kendo-ui)
 * Copyright 2024 Progress Software Corporation and/or one of its subsidiaries or affiliates. All rights reserved.
 *
 * Kendo UI commercial licenses may be obtained at
 * http://www.telerik.com/purchase/license-agreement/kendo-ui-complete
 * If you do not own a commercial license, this file shall be governed by the trial license terms.
 */
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):((e="undefined"!=typeof globalThis?globalThis:e||self).kendo=e.kendo||{},e.kendo._globals=e.kendo._globals||{},e.kendo._globals.All=t())}(this,(function(){let e;const t="change",n={small:"(max-width: 500px)",medium:"(min-width: 500.1px) and (max-width: 768px)",large:"(min-width: 768.1px)"};function i(i){if(i)return e=e||Object.assign({},n,kendo.defaults.breakpoints),i in e&&(i=e[i]),function(e){let n=window.matchMedia(e),i=[],r=[],o=[],a={mediaQueryList:n};const s=e=>{o.forEach((t=>t(e))),e.matches?i.forEach((t=>t(e))):r.forEach((t=>t(e)))};return n.addEventListener(t,s),a.onChange=e=>(o.push(e),a),a.onEnter=e=>{if(i.push(e),n.matches){const i=n.media;e(new MediaQueryListEvent(t,{media:i,matches:!0}))}return a},a.onLeave=e=>(r.push(e),a),a.destroy=()=>{n&&n.removeEventListener(t,s),i=null,r=null,o=null,n=null,a=null},a}(i)}function r(e){class t extends e{static extend(e){const n=class extends t{constructor(){super(),e&&e.init&&e.init.apply(this,arguments)}};return Object.assign(n.prototype,e),o(n.prototype),n.fn=n.prototype,n}}return o(t.prototype),t.fn=t.prototype,t}function o(e){Object.defineProperty(e,"_instance",{get:function(){return this}})}var a={name:"@progress/kendo-ui",productName:"Kendo UI",productCodes:["KENDOUICOMPLETE","KENDOUI","UIASPCORE","KENDOMVC","KENDOUIMVC"],publishDate:1731445483,version:"2024.4.1112".replace(/^\s+|\s+$/g,""),licensingDocsUrl:"https://docs.telerik.com/kendo-ui/intro/installation/using-license-code?utm_medium=product&utm_source=kendojquery&utm_campaign=kendo-ui-jquery-purchase-license-keys-warning"};!function(e,t,o){var s,l=t.kendo=t.kendo||{cultures:{}},c=e.extend,d=e.each,u=Array.isArray,h=e.noop,p=Math,f=t.JSON||{},m={},g=/%/,v=/\{(\d+)(:[^\}]+)?\}/g,_=/(\d+(?:\.?)\d*)px\s*(\d+(?:\.?)\d*)px\s*(\d+(?:\.?)\d*)px\s*(\d+)?/i,b=/^(\+|-?)\d+(\.?)\d*$/,y="month",w="hour",k="zone",x="weekday",C="quarter",S={G:"era",y:"year",q:C,Q:C,M:y,L:y,d:"day",E:x,c:x,e:x,h:w,H:w,k:w,K:w,m:"minute",s:"second",a:"dayperiod",t:"dayperiod",x:k,X:k,z:k,Z:k},T={month:{type:"months",minLength:3,standAlone:"L"},quarter:{type:"quarters",minLength:3,standAlone:"q"},weekday:{type:"days",minLength:{E:0,c:3,e:3},standAlone:"c"},dayperiod:{type:"dayPeriods",minLength:0},era:{type:"eras",minLength:0}},D="function",A="string",M="number",E="object",I="null",z="boolean",P="undefined",H="prefix",F="aria-labelledby",R="aria-label",L={},B={},O=[].slice,V=["themeColor","fillMode","shape","size","rounded","positionMode"],N=function(){var e,t,n,i,r,a,s=arguments[0]||{},l=1,c=arguments.length,d=!1;for("boolean"==typeof s&&(d=s,s=arguments[l]||{},l++),"object"!=typeof s&&"function"!=typeof s&&(s={}),l===c&&(s=this,l--);l<c;l++)if(null!=(r=arguments[l]))for(i in r)"filters"!=i&&"concat"!=i&&":"!=i&&"cssNumber"!=i&&(e=s[i],s!==(n=r[i])&&(d&&n&&(jQuery.isPlainObject(n)||(t=Array.isArray(n)))?(t?(t=!1,a=e&&Array.isArray(e)?e:[]):a=e&&jQuery.isPlainObject(e)?e:{},s[i]=N(d,a,n)):n!==o&&(s[i]=n)));return s};function $(){}l.version="2024.4.1112".replace(/^\s+|\s+$/g,""),$.extend=function(e){var t,n,i=function(){},r=this,o=e&&e.init?e.init:function(){r.apply(this,arguments)};for(t in i.prototype=r.prototype,n=o.fn=o.prototype=new i,e)null!=e[t]&&e[t].constructor===Object?n[t]=c(!0,{},i.prototype[t],e[t]):n[t]=e[t];return n.constructor=o,o.extend=r.extend,o},$.prototype._initOptions=function(e){this.options=re({},this.options,e)},l.createProxyMember=function(e,t){e.fn[t]=function(){var e=this._instance;if(e)return e[t].apply(e,arguments)}},l.getBaseClass=function(e){if(e instanceof Function){let t=e;const n=Object.getPrototypeOf(t);if(n&&n!==Object&&n.name)return n}return null},l.getAllMethods=function(e){const t=Object.getOwnPropertyNames(e).filter((t=>"function"==typeof e[t])),n=Object.getOwnPropertyNames(Object.getPrototypeOf(new e({}))).filter((e=>"constructor"!==e));return t.concat(n)},l.convertPromiseToDeferred=function(t){let n=e.Deferred();return t.finally(n.always).then(n.resolve).catch(n.reject),n.promise()},l.ConvertClass=r;l.isPresent=e=>null!==e&&e!==o,l.isBlank=e=>null===e||e===o,l.isString=e=>"string"==typeof e,l.isNumeric=e=>!isNaN(e-parseFloat(e)),l.isDate=e=>e&&e.getTime;const U=l.isFunction=e=>"function"==typeof e;var W=function(){this._defaultPrevented=!0},j=function(){return!0===this._defaultPrevented},q=$.extend({init:function(){this._events={}},bind:function(e,t,n){var i,r,a,s,l=this,c=typeof e===A?[e]:e,d=typeof t===D;if(t===o){for(i in e)l.bind(i,e[i]);return l}for(i=0,r=c.length;i<r;i++)e=c[i],(s=d?t:t[e])&&(n&&(a=s,s=function(){l.unbind(e,s),a.apply(l,arguments)},s.original=a),(l._events[e]=l._events[e]||[]).push(s));return l},one:function(e,t){return this.bind(e,t,!0)},first:function(e,t){var n,i,r,o=this,a=typeof e===A?[e]:e,s=typeof t===D;for(n=0,i=a.length;n<i;n++)e=a[n],(r=s?t:t[e])&&(o._events[e]=o._events[e]||[]).unshift(r);return o},trigger:function(e,t){var n,i,r=this,o=r._events[e];if(o){for((t=t||{}).sender=r,t._defaultPrevented=!1,t.preventDefault=W,t.isDefaultPrevented=j,n=0,i=(o=o.slice()).length;n<i;n++)o[n].call(r,t);return!0===t._defaultPrevented}return!1},unbind:function(e,t){var n,i=this,r=i._events[e];if(e===o)i._events={};else if(r)if(t)for(n=r.length-1;n>=0;n--)r[n]!==t&&r[n].original!==t||r.splice(n,1);else i._events[e]=[];return i}});function G(e,t){if(t)return"'"+e.split("'").join("\\'").split('\\"').join('\\\\\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t")+"'";var n=e.charAt(0),i=e.substring(1);return"="===n?"+("+i+")+":":"===n?"+$kendoHtmlEncode("+i+")+":";"+e+";$kendoOutput+="}var K=/^\w+/,Y=/\$\{([^}]*)\}/g,Q=/\\\}/g,X=/__CURLY__/g,Z=/\\#/g,J=/__SHARP__/g,ee=["","0","00","000","0000"];function te(e,t,n){return(n=(t=t||2)-(e+="").length)?ee[t].substring(0,n)+e:e}function ne(t,n){var i,r,o;return(i=t.clone()).css("display",""),i.css("visibility","hidden"),i.appendTo(e("body")),r=i.outerWidth(n||!1),o=i.outerHeight(n||!1),i.remove(),{width:r||0,height:o||0}}function ie(e,t,n){var i=l._outerWidth,r=l._outerHeight,o=e.parent(),a=e.closest(".k-animation-container"),s=e.hasClass("k-tooltip"),c=e.is(":visible"),d=o[0].style,u=e[0].style.height;a.is(":hidden")&&a.css({display:"",position:""}),g.test(d.width)||g.test(d.height)||(c||e.add(o).show(),n&&o.css("width",""),o.css({width:t?i(e,!1,s)+1:i(e,!1,s)}),"auto"===u?e.css({height:r(o)}):o.css({height:r(e)}),c||e.hide())}function re(e){var t=1,n=arguments.length;for(t=1;t<n;t++)oe(e,arguments[t]);return e}function oe(e,n){var i,r,o,a,s,c=l.data.ObservableArray,d=l.data.LazyObservableArray,u=l.data.DataSource,h=l.data.HierarchicalDataSource;for(i in n)"__proto__"!==i&&"constructor"!==i&&(!(a=(o=typeof(r=n[i]))===E&&null!==r?r.constructor:null)||a===Array||a===c||a===d||a===u||a===h||a===RegExp||l.isFunction(t.ArrayBuffer)&&a===ArrayBuffer||r instanceof HTMLElement?o!==P&&(e[i]=r):r instanceof Date?e[i]=new Date(r.getTime()):U(r.clone)?e[i]=r.clone():(s=e[i],e[i]=typeof s===E&&s||{},oe(e[i],r)));return e}function ae(e,t,n){for(var i in t)if(t.hasOwnProperty(i)&&t[i].test(e))return i;return n!==o?n:e}function se(e){return e.replace(/\-(\w)/g,(function(e,t){return t.toUpperCase()}))}function le(t,n){var i,r={};return document.defaultView&&document.defaultView.getComputedStyle?(i=document.defaultView.getComputedStyle(t,""),n&&e.each(n,(function(e,t){r[t]=i.getPropertyValue(t)}))):(i=t.currentStyle,n&&e.each(n,(function(e,t){r[t]=i[se(t)]}))),l.size(r)||(r=i),r}s={paramName:"data",useWithBlock:!0,render:function(e,t){var n,i,r="";for(n=0,i=t.length;n<i;n++)r+=e(t[n]);return r},compile:function(e,n){var i,r,o,a=c({},this,n),s=a.paramName,d=s.match(K)[0],u=a.useWithBlock,h="var $kendoOutput, $kendoHtmlEncode = kendo.htmlEncode;";if(U(e))return e;for(h+=u?"with("+s+"){":"",h+="$kendoOutput=",r=e.replace(Q,"__CURLY__").replace(Y,"#=$kendoHtmlEncode($1)#").replace(X,"}").replace(Z,"__SHARP__").split("#"),o=0;o<r.length;o++)h+=G(r[o],o%2==0);h+=u?";}":";",h=(h+="return $kendoOutput;").replace(J,"#");try{return(i=new Function(d,h))._slotCount=Math.floor(r.length/2),i}catch(n){if(!l.debugTemplates)throw new Error(l.format("Invalid template:'{0}' Generated code:'{1}'",e,h));t.console.warn(`Invalid template:'${e}' Generated code:'${h}'`)}}},function(){var e,t,n,i=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,r={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},o={}.toString;function a(e){return i.lastIndex=0,i.test(e)?'"'+e.replace(i,(function(e){var t=r[e];return typeof t===A?t:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)}))+'"':'"'+e+'"'}function s(i,r){var l,c,d,u,h,p,f=e,m=r[i];if(m&&typeof m===E&&typeof m.toJSON===D&&(m=m.toJSON(i)),typeof n===D&&(m=n.call(r,i,m)),(p=typeof m)===A)return a(m);if(p===M)return isFinite(m)?String(m):I;if(p===z||p===I)return String(m);if(p===E){if(!m)return I;if(e+=t,h=[],"[object Array]"===o.apply(m)){for(u=m.length,l=0;l<u;l++)h[l]=s(l,m)||I;return d=0===h.length?"[]":e?"[\n"+e+h.join(",\n"+e)+"\n"+f+"]":"["+h.join(",")+"]",e=f,d}if(n&&typeof n===E)for(u=n.length,l=0;l<u;l++)typeof n[l]===A&&(d=s(c=n[l],m))&&h.push(a(c)+(e?": ":":")+d);else for(c in m)Object.hasOwnProperty.call(m,c)&&(d=s(c,m))&&h.push(a(c)+(e?": ":":")+d);return d=0===h.length?"{}":e?"{\n"+e+h.join(",\n"+e)+"\n"+f+"}":"{"+h.join(",")+"}",e=f,d}}typeof Date.prototype.toJSON!==D&&(Date.prototype.toJSON=function(){var e=this;return isFinite(e.valueOf())?te(e.getUTCFullYear(),4)+"-"+te(e.getUTCMonth()+1)+"-"+te(e.getUTCDate())+"T"+te(e.getUTCHours())+":"+te(e.getUTCMinutes())+":"+te(e.getUTCSeconds())+"Z":null},String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(){return this.valueOf()}),typeof f.stringify!==D&&(f.stringify=function(i,r,o){var a;if(e="",t="",typeof o===M)for(a=0;a<o;a+=1)t+=" ";else typeof o===A&&(t=o);if(n=r,r&&typeof r!==D&&(typeof r!==E||typeof r.length!==M))throw new Error("JSON.stringify");return s("",{"":i})})}(),function(){var t=/EEEE|dddd|ddd|dd|d|MMMM|MMM|MM|M|yyyy|yy|HH|H|hh|h|mm|m|fff|ff|f|tt|ss|s|zzz|zz|z|"[^"]*"|'[^']*'/g,n=/^(n|c|p|e)(\d*)$/i,i=/(\\.)|(['][^']*[']?)|(["][^"]*["]?)/g,r=/\,/g,a="",s=".",c="#",d="0",u="en-US",h={}.toString;function f(e){if(e){if(e.numberFormat)return e;if(typeof e===A){var t=l.cultures;return t[e]||t[e.split("-")[0]]||null}return null}return null}function m(e){return e&&(e=f(e)),e||l.cultures.current}l.cultures=l.cultures||{},l.cultures["en-US"]={name:u,numberFormat:{pattern:["-n"],decimals:2,",":",",".":".",groupSize:[3],percent:{pattern:["-n %","n %"],decimals:2,",":",",".":".",groupSize:[3],symbol:"%"},currency:{name:"US Dollar",abbr:"USD",pattern:["($n)","$n"],decimals:2,",":",",".":".",groupSize:[3],symbol:"$"}},calendars:{standard:{days:{names:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],namesAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],namesShort:["Su","Mo","Tu","We","Th","Fr","Sa"]},months:{names:["January","February","March","April","May","June","July","August","September","October","November","December"],namesAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]},AM:["AM","am","AM"],PM:["PM","pm","PM"],patterns:{d:"M/d/yyyy",D:"dddd, MMMM dd, yyyy",F:"dddd, MMMM dd, yyyy h:mm:ss tt",g:"M/d/yyyy h:mm tt",G:"M/d/yyyy h:mm:ss tt",m:"MMMM dd",M:"MMMM dd",s:"yyyy'-'MM'-'ddTHH':'mm':'ss",t:"h:mm tt",T:"h:mm:ss tt",u:"yyyy'-'MM'-'dd HH':'mm':'ss'Z'",y:"MMMM, yyyy",Y:"MMMM, yyyy"},"/":"/",":":":",firstDay:0,twoDigitYearMax:2029}}},l.culture=function(e){var t,n,i=l.cultures;if(e===o)return(n=i.current.calendars).standard.AM&&n.standard.AM.length&&n.standard.PM&&n.standard.PM.length&&n.standard.AM.indexOf("PMA0")<0&&(n.standard.AM.indexOf("AM")>-1||n.standard.PM.indexOf("PM")>-1)&&(n.standard.AM.push("a","A","PMa","PMA","PMa0","PMA0"),n.standard.PM.push("p","P","AMp","AMP","AMp0","AMP0")),i.current;(t=f(e)||i[u]).calendar=t.calendars.standard,i.current=t},l.findCulture=f,l.getCulture=m,l.kendoCultureToIntl=function(e){e=m(e)||l.cultures.current;let t={};t[e.numberFormat.currency.abbr]=e.numberFormat.currency;const n={},[i,r]=e.name.split("-");if(n.name=i,n.identity={language:i},r&&(n.territory=r),e.numberFormat&&(n.numbers={symbols:{decimal:e.numberFormat["."],group:e.numberFormat[","],percentSign:e.numberFormat.percent?.symbol||"%"},decimal:{patterns:e.numberFormat.pattern,groupSize:e.numberFormat.groupSize},currency:{patterns:e.numberFormat.currency?.pattern,groupSize:e.numberFormat.currency?.groupSize},percent:{patterns:e.numberFormat.percent?.pattern,groupSize:e.numberFormat.percent?.groupSize,decimals:e.numberFormat.percent?.decimals}},e.numberFormat.currency&&(n.numbers.currencies={[e.numberFormat.currency.abbr]:e.numberFormat.currency},n.numbers.localeCurrency=e.numberFormat.currency.abbr)),e.calendars&&e.calendars.standard){const t=e.calendars.standard;n.calendar={patterns:{d:t.patterns.d,D:t.patterns.D,F:t.patterns.F,g:t.patterns.g,G:t.patterns.G,m:t.patterns.m,M:t.patterns.M,s:t.patterns.s,t:t.patterns.t,T:t.patterns.T,u:t.patterns.u,y:t.patterns.y,Y:t.patterns.Y},days:{format:{wide:t.days.names,abbreviated:t.days.namesAbbr,short:t.days.namesShort},"stand-alone":{wide:t.days.names,abbreviated:t.days.namesAbbr,short:t.days.namesShort}},months:{format:{wide:t.months.names,abbreviated:t.months.namesAbbr,narrow:t.months.namesAbbr.map((e=>e.charAt(0)))},"stand-alone":{wide:t.months.names,abbreviated:t.months.namesAbbr,narrow:t.months.namesAbbr.map((e=>e.charAt(0)))}},dayPeriods:{format:{abbreviated:{am:t.AM[0],pm:t.PM[0]},narrow:{am:t.AM[1],pm:t.PM[1]},wide:{am:t.AM[0],pm:t.PM[0]}},"stand-alone":{abbreviated:{am:t.AM[0],pm:t.PM[0]},narrow:{am:t.AM[1],pm:t.PM[1]},wide:{am:t.AM[0],pm:t.PM[0]}}}},"firstDay"in t&&(n.firstDay=t.firstDay)}return{localeInfo:()=>({numbers:{localeCurrency:e.numberFormat.currency.abbr,currencies:t,symbols:{group:e.numberFormat[","],decimal:e.numberFormat["."],percentSign:e.numberFormat.percent.symbol}},calendar:{patterns:e.calendars.standard.patterns,months:{format:{wide:e.calendars.standard.months.names,abbreviated:e.calendars.standard.months.namesAbbr}},days:{format:{wide:e.calendars.standard.days.names,abbreviated:e.calendars.standard.days.namesAbbr}}}}),parseDate:(e,t)=>l.parseExactDate(e,t),toString:(e,t)=>b(e,t),format:(e,...t)=>l.format(e,t)}},l.culture(u);var g=function(e,t,n,i){var r,a,l,c,d,u,h=e.indexOf(i[s]),p=i.groupSize.slice(),f=p.shift();if(n=-1!==h?h:n+1,(a=(r=e.substring(t,n)).length)>=f){for(l=a,c=[];l>-1;)if((d=r.substring(l-f,l))&&c.push(d),l-=f,0===(f=(u=p.shift())!==o?u:f)){l>0&&c.push(r.substring(0,l));break}r=c.reverse().join(i[","]),e=e.substring(0,t)+r+e.substring(n)}return e},_=function(e,t,n){return t=t||0,e=e.toString().split("e"),e=Math.round(+(e[0]+"e"+(e[1]?+e[1]+t:t))),n&&(e=-e),(e=+((e=e.toString().split("e"))[0]+"e"+(e[1]?+e[1]-t:-t))).toFixed(Math.min(t,20))},b=function(e,l,u){if(l){if("[object Date]"===h.call(e))return function(e,n,i){var r=(i=m(i)).calendars.standard,a=r.days,s=r.months;return(n=n.pattern||r.patterns[n]||n).replace(t,(function(t){var n,i,l;return"d"===t?i=e.getDate():"dd"===t?i=te(e.getDate()):"ddd"===t?i=a.namesAbbr[e.getDay()]:"dddd"===t||"EEEE"===t?i=a.names[e.getDay()]:"M"===t?i=e.getMonth()+1:"MM"===t?i=te(e.getMonth()+1):"MMM"===t?i=s.namesAbbr[e.getMonth()]:"MMMM"===t?i=s.names[e.getMonth()]:"yy"===t?i=te(e.getFullYear()%100):"yyyy"===t?i=te(e.getFullYear(),4):"h"===t?i=e.getHours()%12||12:"hh"===t?i=te(e.getHours()%12||12):"H"===t?i=e.getHours():"HH"===t?i=te(e.getHours()):"m"===t?i=e.getMinutes():"mm"===t?i=te(e.getMinutes()):"s"===t?i=e.getSeconds():"ss"===t?i=te(e.getSeconds()):"f"===t?i=p.floor(e.getMilliseconds()/100):"ff"===t?((i=e.getMilliseconds())>99&&(i=p.floor(i/10)),i=te(i)):"fff"===t?i=te(e.getMilliseconds(),3):"tt"===t||"aa"===t?i=e.getHours()<12?r.AM[0]:r.PM[0]:"zzz"===t?(l=(n=e.getTimezoneOffset())<0,i=p.abs(n/60).toString().split(".")[0],n=p.abs(n)-60*i,i=(l?"+":"-")+te(i),i+=":"+te(n)):"zz"!==t&&"z"!==t||(l=(i=e.getTimezoneOffset()/60)<0,i=p.abs(i).toString().split(".")[0],i=(l?"+":"-")+("zz"===t?te(i):i)),i!==o?i:t.slice(1,t.length-1)}))}(e,l,u);if(typeof e===M)return function(e,t,l){var u,h,p,f,v,b,y,w,k,x,C,S,T,D,A,M,E,I,z,P,H=(l=m(l)).numberFormat,F=H[s],R=H.decimals,L=H.pattern[0],B=[],O=e<0,V=a,N=a,$=-1;if(e===o)return a;if(!isFinite(e))return e;if(!t)return l.name.length?e.toLocaleString():e.toString();if(v=n.exec(t)){if(p="p"===(t=v[1].toLowerCase()),((h="c"===t)||p)&&(F=(H=h?H.currency:H.percent)[s],R=H.decimals,u=H.symbol,L=H.pattern[O?0:1]),(f=v[2])&&(R=+f),"e"===t)return(f?e.toExponential(R):e.toExponential()).replace(s,H[s]);if(p&&(e*=100),O=(e=_(e,R))<0,b=(e=e.split(s))[0],y=e[1],O&&(b=b.substring(1)),N=g(b,0,b.length,H),y&&(N+=F+y),"n"===t&&!O)return N;for(e=a,k=0,x=L.length;k<x;k++)e+="n"===(C=L.charAt(k))?N:"$"===C||"%"===C?u:C;return e}if((t.indexOf("'")>-1||t.indexOf('"')>-1||t.indexOf("\\")>-1)&&(t=t.replace(i,(function(e){var t=e.charAt(0).replace("\\",""),n=e.slice(1).replace(t,"");return B.push(n),"??"}))),t=t.split(";"),O&&t[1])t=t[1],T=!0;else if(0===e&&t[2]){if(-1==(t=t[2]).indexOf(c)&&-1==t.indexOf(d))return t}else t=t[0];if((p=-1!=t.indexOf("%"))&&(e*=100),(h=-1!=(z=t.indexOf("$")))&&"\\"===t[z-1]&&(t=t.split("\\").join(""),h=!1),(h||p)&&(F=(H=h?H.currency:H.percent)[s],R=H.decimals,u=H.symbol),(S=t.indexOf(",")>-1)&&(t=t.replace(r,a)),D=t.indexOf(s),x=t.length,-1!=D)if(y=(y=(y=e.toString().split("e"))[1]?_(e,Math.abs(y[1])):y[0]).split(s)[1]||a,E=(M=t.lastIndexOf(d)-D)>-1,I=(A=t.lastIndexOf(c)-D)>-1,k=y.length,E||I||(x=(t=t.substring(0,D)+t.substring(D+1)).length,D=-1,k=0),E&&M>A)k=M;else if(A>M)if(I&&k>A){for(var U=_(e,A,O);U.charAt(U.length-1)===d&&A>0&&A>M;)A--,U=_(e,A,O);k=A}else E&&k<M&&(k=M);if(e=_(e,k,O),A=t.indexOf(c),M=t.indexOf(d),$=-1==A&&-1!=M?M:-1!=A&&-1==M?A:A>M?M:A,A=t.lastIndexOf(c),M=t.lastIndexOf(d),P=-1==A&&-1!=M?M:-1!=A&&-1==M||A>M?A:M,$==x&&(P=$),-1!=$){for(b=(N=e.toString().split(s))[0],y=N[1]||a,w=b.length,y.length,O&&-1*e>=0&&(O=!1),e=t.substring(0,$),O&&!T&&(e+="-"),k=$;k<x;){if(C=t.charAt(k),-1==D){if(P-k<w){e+=b;break}}else if(-1!=M&&M<k&&(V=a),D-k<=w&&D-k>-1&&(e+=b,k=D),D===k){e+=(y?F:a)+y,k+=P-D+1;continue}C===d?(e+=C,V=C):C===c&&(e+=V),k++}if(S&&(e=g(e,$+(O&&!T?1:0),Math.max(P,w+$),H)),P>=$&&(e+=t.substring(P+1)),h||p){for(N=a,k=0,x=e.length;k<x;k++)N+="$"===(C=e.charAt(k))||"%"===C?u:C;e=N}if(x=B.length)for(k=0;k<x;k++)e=e.replace("??",B[k])}return e}(e,l,u)}return e!==o?e:""};l.format=function(e){var t=arguments;return e.replace(v,(function(e,n,i){var r=t[parseInt(n,10)+1];return b(r,i?i.substring(1):"")}))},l._extractFormat=function(e){return"{0:"===e.slice(0,3)&&(e=e.slice(3,e.length-1)),e},l._activeElement=function(){try{return document.activeElement}catch(e){return document.documentElement.activeElement}},l._round=_,l._outerWidth=function(t,n,i){return t=e(t),i?ne(t,n).width:e(t).outerWidth(n||!1)||0},l._outerHeight=function(t,n,i){return t=e(t),i?ne(t,n).height:e(t).outerHeight(n||!1)||0},l.toString=b}(),function(){var t=/\u00A0/g,n=/\s/g,i=/[eE][\-+]?[0-9]+/,r=/[+|\-]\d{1,2}/,a=/[+|\-]\d{1,2}:?\d{2}/,s=/^\/Date\((.*?)\)\/$/,c=/[+-]\d*/,d=[[],["G","g","F"],["D","d","y","m","T","t"]],h=[["yyyy-MM-ddTHH:mm:ss.fffffffzzz","yyyy-MM-ddTHH:mm:ss.fffffff","yyyy-MM-ddTHH:mm:ss.fffzzz","yyyy-MM-ddTHH:mm:ss.fff","ddd MMM dd yyyy HH:mm:ss","yyyy-MM-ddTHH:mm:sszzz","yyyy-MM-ddTHH:mmzzz","yyyy-MM-ddTHH:mmzz","yyyy-MM-ddTHH:mm:ss","yyyy-MM-dd HH:mm:ss","yyyy/MM/dd HH:mm:ss"],["yyyy-MM-ddTHH:mm","yyyy-MM-dd HH:mm","yyyy/MM/dd HH:mm"],["yyyy/MM/dd","yyyy-MM-dd","HH:mm:ss","HH:mm"]],f={2:/^\d{1,2}/,3:/^\d{1,3}/,4:/^\d{4}/,exact3:/^\d{3}/},m={}.toString;function g(e,t,n){return!(e>=t&&e<=n)}function v(e){return e.charAt(0)}function _(t){return e.map(t,v)}function b(e){for(var t=0,n=e.length,i=[];t<n;t++)i[t]=(e[t]+"").toLowerCase();return i}function y(e){var t,n={};for(t in e)n[t]=b(e[t]);return n}function w(e){return Array.from(e).sort(((e,t)=>t.length-e.length))[0].length}function k(e,t,n,i,s){if(!e)return null;var c,d,u,h,p,m,v,b,k,x,C,S,T=function(e){for(var n=0;t[B]===e;)n++,B++;return n>0&&(B-=1),n},D=function(t){var n,i,r="";if(2===t)for(let n=0;n<=t;n++)r+=e[O+n]||"";return r=s&&r.match(f.exact3)&&Number.isInteger(Number(r))&&Number(r)>0?function(e){return e.replace(/^0*/,"")}(r):e.substr(O,t),n=f[t]||new RegExp("^\\d{1,"+t+"}"),(i=r.match(n))?(i=i[0],O+=i.length,parseInt(i,10)):null},A=function(t,n,i){for(var r,o,a,s=0,l=t.length,c=0,d=0;s<l;s++)o=(r=t[s]).length,a=e.substr(O,i||o),n&&(a=a.toLowerCase()),a==r&&o>c&&(c=o,d=s);return c?(O+=c,d+1):null},M=function(){var n=!1;return e.charAt(O)===t[B]&&(O++,n=!0),n},E=n.calendars.standard,I=null,z=null,P=null,H=null,F=null,R=null,L=null,B=0,O=0,V=!1,N=new Date,$=E.twoDigitYearMax||2029,U=N.getFullYear();for(t||(t="d"),(h=E.patterns[t])&&(t=h),u=(t=t.split("")).length;B<u;B++)if(c=t[B],V)"'"===c?V=!1:M();else if("d"===c){if(d=T("d"),E._lowerDays||(E._lowerDays=y(E.days)),null!==P&&d>2)continue;if(null===(P=d<3?D(2):A(E._lowerDays[3==d?"namesAbbr":"names"],!0))||g(P,1,31))return null}else if("M"===c){if(d=T("M"),E._lowerMonths||(E._lowerMonths=y(E.months)),null===(z=d<3?D(2):A(E._lowerMonths[3==d?"namesAbbr":"names"],!0))||g(z,1,12))return null;z-=1}else if("y"===c){if(null===(I=D(d=T("y"))))return null;2==d&&("string"==typeof $&&($=U+parseInt($,10)),(I=U-U%100+I)>$&&(I-=100))}else if("h"===c){if(T("h"),12==(H=D(2))&&(H=0),null===H||g(H,0,11))return null}else if("H"===c){if(T("H"),null===(H=D(2))||g(H,0,23))return null}else if("m"===c){if(T("m"),null===(F=D(2))||g(F,0,59))return null}else if("s"===c){if(T("s"),null===(R=D(2))||g(R,0,59))return null}else if("f"===c){if(d=T("f"),S=e.substr(O,d).match(f[3]),null!==(L=D(d))&&(L=parseFloat("0."+S[0],10),L=l._round(L,3),L*=1e3),null===L||g(L,0,999))return null}else if("t"===c){if(d=T("t"),b=E.AM,k=E.PM,1===d&&(b=_(b),k=_(k)),!(p=A(k,!1,w(k)))&&!A(b,!1,w(b)))return null}else if("z"===c){if(m=!0,d=T("z"),"Z"===e.substr(O,1)){M();continue}if(!(v=e.substr(O,6).match(d>2?a:r)))return null;if(x=(v=v[0].split(":"))[0],!(C=v[1])&&x.length>3&&(O=x.length-2,C=x.substring(O),x=x.substring(0,O)),g(x=parseInt(x,10),-12,13))return null;if(d>2&&(C=v[0][0]+C,C=parseInt(C,10),isNaN(C)||g(C,-59,59)))return null}else if("'"===c)V=!0,M();else if(!M())return null;return i&&!/^\s*$/.test(e.substr(O))?null:(null===I&&null===z&&null===P&&(null!==H||null!==F||R||null)?(I=U,z=N.getMonth(),P=N.getDate()):(null===I&&(I=U),null===P&&(P=1)),p&&H<12&&(H+=12),m?(x&&(H+=-x),C&&(F+=-C),e=new Date(Date.UTC(I,z,P,H,F,R,L))):function(e,t){t||23!==e.getHours()||e.setHours(e.getHours()+2)}(e=new Date(I,z,P,H,F,R,L),H),I<100&&e.setFullYear(I),e.getDate()!==P&&m===o?null:e)}function x(e,t,n,i,r){if("[object Date]"===m.call(e))return e;var o,a,f=0,g=null;if(e&&0===e.indexOf("/D")&&(g=s.exec(e)))return g=g[1],a=c.exec(g.substring(1)),g=new Date(parseInt(g,10)),a&&(a=function(e){var t="-"===e.substr(0,1)?-1:1;return e=e.substring(1),t*(60*parseInt(e.substr(0,2),10)+parseInt(e.substring(2),10))}(a[0]),g=l.timezone.apply(g,0),g=l.timezone.convert(g,0,-1*a)),g;for(n=l.getCulture(n),t||(t=function(e){var t,n,i,r=p.max(d.length,h.length),o=(e.calendar||e.calendars.standard).patterns,a=[];for(i=0;i<r;i++){for(t=d[i],n=0;n<t.length;n++)a.push(o[t[n]]);a=a.concat(h[i])}return a}(n)),o=(t=u(t)?t:[t]).length;f<o;f++)if(g=k(e,t[f],n,i,r))return g;return g}l.parseDate=function(e,t,n,i){return x(e,t,n,!1,i)},l.parseExactDate=function(e,t,n){return x(e,t,n,!0)},l.parseInt=function(e,t){var n=l.parseFloat(e,t);return n&&(n|=0),n},l.parseFloat=function(e,r,o){if(!e&&0!==e)return null;if(typeof e===M)return e;e=e.toString();var a,s,c=(r=l.getCulture(r)).numberFormat,d=c.percent,u=c.currency,h=u.symbol,p=d.symbol,f=e.indexOf("-");return i.test(e)?(e=parseFloat(e.replace(c["."],".")),isNaN(e)&&(e=null),e):f>0?null:(f=f>-1,e.indexOf(h)>-1||o&&o.toLowerCase().indexOf("c")>-1?(a=(c=u).pattern[0].replace("$",h).split("n"),e.indexOf(a[0])>-1&&e.indexOf(a[1])>-1&&(e=e.replace(a[0],"").replace(a[1],""),f=!0)):e.indexOf(p)>-1&&(s=!0,c=d,h=p),e=e.replace("-","").replace(h,"").replace(t," ").split(c[","].replace(t," ")).join("").replace(n,"").replace(c["."],"."),e=parseFloat(e),isNaN(e)?e=null:f&&(e*=-1),e&&s&&(e/=100),e)}}(),function(){m._scrollbar=o,m.scrollbar=function(e){if(isNaN(m._scrollbar)||e){var t,n=document.createElement("div");return n.style.cssText="overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block",n.innerHTML="&nbsp;",document.body.appendChild(n),m._scrollbar=t=n.offsetWidth-n.scrollWidth,document.body.removeChild(n),t}return m._scrollbar},m.isRtl=function(t){return e(t).closest(".k-rtl").length>0};var n=document.createElement("table");try{n.innerHTML="<tr><td></td></tr>",m.tbodyInnerHtml=!0}catch(e){m.tbodyInnerHtml=!1}m.touch="ontouchstart"in t;let i=document.documentElement.style,r="HTMLElement"in t?HTMLElement.prototype:[];m.transforms=m.transitions={css:"",prefix:"",event:"transitionend"},m.hasHW3D="WebKitCSSMatrix"in t&&"m11"in new t.WebKitCSSMatrix||"MozPerspective"in i||"msPerspective"in i,m.cssFlexbox="flexWrap"in i||"WebkitFlexWrap"in i||"msFlexWrap"in i,n=null,m.devicePixelRatio=t.devicePixelRatio===o?1:t.devicePixelRatio;try{m.screenWidth=t.outerWidth||t.screen?t.screen.availWidth:t.innerWidth,m.screenHeight=t.outerHeight||t.screen?t.screen.availHeight:t.innerHeight}catch(e){m.screenWidth=t.screen.availWidth,m.screenHeight=t.screen.availHeight}m.detectOS=function(e){var n,i=!1,r=[],o=!/mobile safari/i.test(e),a={wp:/(Windows Phone(?: OS)?)\s(\d+)\.(\d+(\.\d+)?)/,fire:/(Silk)\/(\d+)\.(\d+(\.\d+)?)/,android:/(Android|Android.*(?:Opera|Firefox).*?\/)\s*(\d+)\.?(\d+(\.\d+)?)?/,iphone:/(iPhone|iPod).*OS\s+(\d+)[\._]([\d\._]+)/,ipad:/(iPad).*OS\s+(\d+)[\._]([\d_]+)/,meego:/(MeeGo).+NokiaBrowser\/(\d+)\.([\d\._]+)/,webos:/(webOS)\/(\d+)\.(\d+(\.\d+)?)/,blackberry:/(BlackBerry|BB10).*?Version\/(\d+)\.(\d+(\.\d+)?)/,playbook:/(PlayBook).*?Tablet\s*OS\s*(\d+)\.(\d+(\.\d+)?)/,windows:/(MSIE)\s+(\d+)\.(\d+(\.\d+)?)/,tizen:/(tizen).*?Version\/(\d+)\.(\d+(\.\d+)?)/i,sailfish:/(sailfish).*rv:(\d+)\.(\d+(\.\d+)?).*firefox/i,ffos:/(Mobile).*rv:(\d+)\.(\d+(\.\d+)?).*Firefox/},s={ios:/^i(phone|pad|pod)$/i,android:/^android|fire$/i,blackberry:/^blackberry|playbook/i,windows:/windows/,wp:/wp/,flat:/sailfish|ffos|tizen/i,meego:/meego/},l={tablet:/playbook|ipad|fire/i},c={omini:/Opera\sMini/i,omobile:/Opera\sMobi/i,firefox:/Firefox|Fennec/i,mobilesafari:/version\/.*safari/i,ie:/MSIE|Windows\sPhone/i,chrome:/chrome|crios/i,webkit:/webkit/i,edge:/edge|edg|edgios|edga/i};for(var d in a)if(a.hasOwnProperty(d)&&(r=e.match(a[d]))){if("windows"==d&&"plugins"in navigator)return!1;(i={}).device=d,i.tablet=ae(d,l,!1),i.browser=ae(e,c,"default"),i.name=ae(d,s),i[i.name]=!0,i.majorVersion=r[2],i.minorVersion=(r[3]||"0").replace("_","."),n=i.minorVersion.replace(".","").substr(0,2),i.flatVersion=i.majorVersion+n+new Array(3-(n.length<3?n.length:2)).join("0"),i.cordova=typeof t.PhoneGap!==P||typeof t.cordova!==P,i.appMode=t.navigator.standalone||/file|local|wmapp/.test(t.location.protocol)||i.cordova,i.android&&(m.devicePixelRatio<1.5&&i.flatVersion<400||o)&&(m.screenWidth>800||m.screenHeight>800)&&(i.tablet=d);break}return i};var a=m.mobileOS=m.detectOS(navigator.userAgent);m.wpDevicePixelRatio=a.wp?screen.width/320:0,m.hasNativeScrolling=!1,(a.ios||a.android&&a.majorVersion>2||a.wp)&&(m.hasNativeScrolling=a),m.delayedClick=function(){if(m.touch){if(a.ios)return!0;if(a.android)return!m.browser.chrome||!(m.browser.version<32)&&!(e("meta[name=viewport]").attr("content")||"").match(/user-scalable=no/i)}return!1},m.mouseAndTouchPresent=m.touch&&!(m.mobileOS.ios||m.mobileOS.android),m.detectBrowser=function(e){var t=!1,n=[],i={edge:/(edge)[ \/]([\w.]+)/i,webkit:/(chrome|crios)[ \/]([\w.]+)/i,safari:/(webkit)[ \/]([\w.]+)/i,opera:/(opera)(?:.*version|)[ \/]([\w.]+)/i,msie:/(msie\s|trident.*? rv:)([\w.]+)/i,mozilla:/(mozilla)(?:.*? rv:([\w.]+)|)/i};for(var r in i)if(i.hasOwnProperty(r)&&(n=e.match(i[r]))){(t={})[r]=!0,t[n[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,t.version=parseInt(document.documentMode||n[2],10),t.chrome&&e.match(/(edg)[ \/]([\w.]+)/i)&&(t.chromiumEdge=!0);break}return t},m.browser=m.detectBrowser(navigator.userAgent),!a&&m.touch&&m.browser.safari&&(a=m.mobileOS={ios:!0,tablet:"tablet",device:"ipad",majorVersion:13}),m.detectClipboardAccess=function(){var e={copy:!!document.queryCommandSupported&&document.queryCommandSupported("copy"),cut:!!document.queryCommandSupported&&document.queryCommandSupported("cut"),paste:!!document.queryCommandSupported&&document.queryCommandSupported("paste")};return m.browser.chrome&&(e.paste=!1,m.browser.version>=43&&(e.copy=!0,e.cut=!0)),e},m.clipboard=m.detectClipboardAccess(),m.zoomLevel=function(){try{var e=m.browser,n=0,i=document.documentElement;return e.msie&&11==e.version&&i.scrollHeight>i.clientHeight&&!m.touch&&(n=m.scrollbar()),m.touch?i.clientWidth/t.innerWidth:e.msie&&e.version>=10?((top||t).document.documentElement.offsetWidth+n)/(top||t).innerWidth:1}catch(e){return 1}},function(t){var n="",i=e(document.documentElement),r=parseInt(t.version,10);t.msie?n="ie":t.mozilla?n="ff":t.safari?n="safari":t.webkit?n="webkit":t.opera?n="opera":t.edge&&(n="edge"),n&&(n="k-"+n+" k-"+n+r),m.mobileOS&&(n+=" k-mobile"),m.cssFlexbox||(n+=" k-no-flexbox"),i.addClass(n)}(m.browser),m.eventCapture=document.documentElement.addEventListener;var s=document.createElement("input");m.placeholder="placeholder"in s,m.propertyChangeEvent="onpropertychange"in s,m.input=function(){for(var e,t=["number","date","time","month","week","datetime","datetime-local"],n=t.length,i="test",r={},o=0;o<n;o++)e=t[o],s.setAttribute("type",e),s.value=i,r[e.replace("-","")]="text"!==s.type&&s.value!==i;return r}(),s.style.cssText="float:left;",m.cssFloat=!!s.style.cssFloat,s=null,m.stableSort=function(){for(var e=[{index:0,field:"b"}],t=1;t<513;t++)e.push({index:t,field:"a"});return e.sort((function(e,t){return e.field>t.field?1:e.field<t.field?-1:0})),1===e[0].index}(),m.matchesSelector=r.webkitMatchesSelector||r.mozMatchesSelector||r.msMatchesSelector||r.oMatchesSelector||r.matchesSelector||r.matches||function(t){for(var n=document.querySelectorAll?(this.parentNode||document).querySelectorAll(t)||[]:e(t),i=n.length;i--;)if(n[i]==this)return!0;return!1},m.matchMedia="matchMedia"in t,m.pushState=t.history&&t.history.pushState,m.hashChange="onhashchange"in t,m.customElements="registerElement"in t.document;var l=m.browser.chrome,c=m.browser.crios,d=m.browser.mozilla,u=m.browser.safari;m.msPointers=!l&&t.MSPointerEvent,m.pointers=!l&&!c&&!d&&!u&&t.PointerEvent,m.kineticScrollNeeded=a&&("ipad"!==a.device||a.majorVersion<13)&&(m.touch||m.msPointers||m.pointers)}();var ce={};function de(e,t,n,i){return typeof e===A&&(U(t)&&(i=t,t=400,n=!1),U(n)&&(i=n,n=!1),typeof t===z&&(n=t,t=400),e={effects:e,duration:t,reverse:n,complete:i}),c({effects:{},duration:400,reverse:!1,init:h,teardown:h,hide:!1},e,{completeCallback:e.complete,complete:h})}function ue(t,n,i,r,o){for(var a,s=0,l=t.length;s<l;s++)(a=e(t[s])).queue((function(){ce.promise(a,de(n,i,r,o))}));return t}e.extend(ce,{enabled:!0,Element:function(t){this.element=e(t)},promise:function(e,t){e.is(":visible")||e.css({display:e.data("olddisplay")||"block"}).css("display"),t.hide&&e.data("olddisplay",e.css("display")).hide(),t.init&&t.init(),t.completeCallback&&t.completeCallback(e),e.dequeue()},disable:function(){this.enabled=!1,this.promise=this.promiseShim},enable:function(){this.enabled=!0,this.promise=this.animatedPromise}}),ce.promiseShim=ce.promise,"kendoAnimate"in e.fn||c(e.fn,{kendoStop:function(e,t){return this.stop(e,t)},kendoAnimate:function(e,t,n,i){return ue(this,e,t,n,i)},kendoAddClass:function(e,t){return l.toggleClass(this,e,t,!0)},kendoRemoveClass:function(e,t){return l.toggleClass(this,e,t,!1)},kendoToggleClass:function(e,t,n){return l.toggleClass(this,e,t,n)}});var he=/&/g,pe=/</g,fe=/"/g,me=/'/g,ge=/>/g;var ve=function(e){return e.target};m.touch&&(ve=function(e){var t="originalEvent"in e?e.originalEvent.changedTouches:"changedTouches"in e?e.changedTouches:null;return t?document.elementFromPoint(t[0].clientX,t[0].clientY):e.target},d(["swipe","swipeLeft","swipeRight","swipeUp","swipeDown","doubleTap","tap"],(function(t,n){e.fn[n]=function(e){return this.on(n,e)}}))),m.touch?m.mobileOS?(m.mousedown="touchstart",m.mouseup="touchend",m.mousemove="touchmove",m.mousecancel="touchcancel",m.click="touchend",m.resize="orientationchange"):(m.mousedown="mousedown touchstart",m.mouseup="mouseup touchend",m.mousemove="mousemove touchmove",m.mousecancel="mouseleave touchcancel",m.click="click",m.resize="resize"):m.pointers?(m.mousemove="pointermove",m.mousedown="pointerdown",m.mouseup="pointerup",m.mousecancel="pointercancel",m.click="pointerup",m.resize="orientationchange resize"):m.msPointers?(m.mousemove="MSPointerMove",m.mousedown="MSPointerDown",m.mouseup="MSPointerUp",m.mousecancel="MSPointerCancel",m.click="MSPointerUp",m.resize="orientationchange resize"):(m.mousemove="mousemove",m.mousedown="mousedown",m.mouseup="mouseup",m.mousecancel="mouseleave",m.click="click",m.resize="resize");var _e=/^([a-z]+:)?\/\//i;c(l,{widgets:[],_widgetRegisteredCallbacks:[],ui:l.ui||{},fx:l.fx||function(e){return new l.effects.Element(e)},effects:l.effects||ce,mobile:l.mobile||{},data:l.data||{},dataviz:l.dataviz||{},drawing:l.drawing||{},spreadsheet:{messages:{}},keys:{INSERT:45,DELETE:46,BACKSPACE:8,TAB:9,ENTER:13,ESC:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,END:35,HOME:36,SPACEBAR:32,PAGEUP:33,PAGEDOWN:34,F2:113,F10:121,F12:123,NUMPAD_PLUS:107,NUMPAD_MINUS:109,NUMPAD_DOT:110},support:l.support||m,animate:l.animate||ue,ns:"",attr:function(e){return"data-"+l.ns+e},getShadows:function(e){var t=e.css("box-shadow"),n=t&&t.match(_)||[0,0,0,0,0],i=p.max(+n[3],+(n[4]||0));return{left:-n[1]+i,right:+n[1]+i,bottom:+n[2]+i}},wrap:function(n,i,r,o=!0,a){var s,c=l._outerWidth,d=l._outerHeight,u=n.parent(),h=c(t);if(u.parent().removeClass("k-animation-container-sm"),u.hasClass("k-child-animation-container"))ie(n,i,o);else{var p=n[0].style.width,f=n[0].style.height,m=g.test(p),v=g.test(f),_=n.hasClass("k-tooltip")||n.is(".k-menu-horizontal.k-context-menu"),b=n.hasClass("k-tooltip");s=m||v,!m&&(!i||i&&p||_)&&(p=i?c(n,!1,b)+1:c(n,!1,b)),(!v&&(!i||i&&f)||_)&&(f=d(n,!1,b)),n.wrap(e("<div/>").addClass("k-child-animation-container").css({width:a?"auto":p,height:f})),(u=n.parent()).wrap(e("<div/>").addClass("k-animation-container").attr("role","region")),s&&n.css({width:"100%",height:"100%"})}return h<c(u=u.parent())&&(u.addClass("k-animation-container-sm"),r=!0),r&&ie(n,i,o),u},deepExtend:re,getComputedStyles:le,isScrollable:function(e){if("false"===e.dataset[l.ns+"scrollable"])return!1;if(e&&e.className&&"string"==typeof e.className&&e.className.indexOf("k-auto-scrollable")>-1)return!0;var t=le(e,["overflow"]).overflow;return t.indexOf("auto")>-1||t.indexOf("scroll")>-1},scrollLeft:function t(n,i){var r,a,s=m.browser.webkit,l=m.browser.mozilla,c=m.browser.version;if(n instanceof e&&i!==o)n.each((function(e,n){t(n,i)}));else if(r=n instanceof e?n[0]:n){if(a=m.isRtl(n),i===o)return a&&s&&(c<85||m.browser.safari)?r.scrollWidth-r.clientWidth-r.scrollLeft:Math.abs(r.scrollLeft);a&&s&&(c<85||m.browser.safari)?r.scrollLeft=r.scrollWidth-r.clientWidth-i:r.scrollLeft=a&&(l||s)&&i>0?-i:i}},size:function(e){var t,n=0;for(t in e)e.hasOwnProperty(t)&&"toJSON"!=t&&n++;return n},toCamelCase:se,toHyphens:function(e){return e.replace(/([a-z][A-Z])/g,(function(e){return e.charAt(0)+"-"+e.charAt(1).toLowerCase()}))},getOffset:l.getOffset||function(e,n,i){n||(n="offset");var r=e[n](),o={top:r.top,right:r.right,bottom:r.bottom,left:r.left};if(m.browser.msie&&(m.pointers||m.msPointers)&&!i){var a=m.isRtl(e)?1:-1;o.top-=t.pageYOffset-document.documentElement.scrollTop,o.left-=t.pageXOffset+a*document.documentElement.scrollLeft}return o},parseEffects:l.parseEffects||function(e){var t={};return d("string"==typeof e?e.split(" "):e,(function(e){t[e]=this})),t},toggleClass:l.toggleClass||function(e,t,n,i){return t&&(t=t.split(" "),d(t,(function(t,n){e.toggleClass(n,i)}))),e},directions:l.directions||{left:{reverse:"right"},right:{reverse:"left"},down:{reverse:"up"},up:{reverse:"down"},top:{reverse:"bottom"},bottom:{reverse:"top"},in:{reverse:"out"},out:{reverse:"in"}},Observable:q,Class:$,Template:s,template:s.compile.bind(s),render:s.render.bind(s),stringify:f.stringify.bind(f),eventTarget:ve,htmlEncode:function(e,t){return!0===t&&(e=function(e){var t={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"};return e.replace(/&(?:amp|lt|gt|quot|#39);/g,(function(e){return t[e]}))}(e)),(""+e).replace(he,"&amp;").replace(pe,"&lt;").replace(ge,"&gt;").replace(fe,"&quot;").replace(me,"&#39;")},unescape:function(e){var n;try{n=t.decodeURIComponent(e)}catch(t){n=e.replace(/%u([\dA-F]{4})|%([\dA-F]{2})/gi,(function(e,t,n){return String.fromCharCode(parseInt("0x"+(t||n),16))}))}return n},isLocalUrl:function(e){return e&&!_e.test(e)},mediaQuery:i,expr:function(e,t,n){return typeof t==A&&(n=t,t=!1),n=n||"d",(e=e||"")&&"["!==e.charAt(0)&&(e="."+e),t?(e=function(e,t){var n,i,r,o,a=t||"d",s=1;for(i=0,r=e.length;i<r;i++)""!==(o=e[i])&&(0!==(n=o.indexOf("["))&&(-1==n?o="."+o:(s++,o="."+o.substring(0,n)+" || {})"+o.substring(n))),s++,a+=o+(i<r-1?" || {})":")"));return new Array(s).join("(")+a}((e=(e=e.replace(/"([^.]*)\.([^"]*)"/g,'"$1_$DOT$_$2"')).replace(/'([^.]*)\.([^']*)'/g,"'$1_$DOT$_$2'")).split("."),n),e=e.replace(/_\$DOT\$_/g,".")):e=n+e,e},exprToArray:(e,t)=>(e=e||"").indexOf(".")>=0||e.indexOf("[")>=0?e.split(/[[\].]/).map((e=>e.replace(/["']/g,""))).filter((e=>e)):""===e?[]:[e],getter:function(e,t){var n=e+t;return L[n]=L[n]||(n=>{const i=l.exprToArray(e,t);let r=n;for(let e=0;e<i.length;e++)if(r=r[i[e]],!l.isPresent(r)&&t)return r;return r})},setter:function(e){return B[e]=B[e]||((t,n)=>{const i=l.exprToArray(e),r=({parent:e,val:t,prop:n,props:i})=>{i.length?(e=e[i.shift()],r({parent:e,val:t,prop:n,props:i})):e[n]=t};r({parent:t,val:n,prop:i.pop(),props:i})})},accessor:function(e){return{get:l.getter(e),set:l.setter(e)}},guid:function(){var e,t,n="",i="abcdef";for(n+=i[Math.floor(Math.random()*Math.floor(6))],e=1;e<32;e++)t=16*p.random()|0,8!=e&&12!=e&&16!=e&&20!=e||(n+="-"),n+=(12==e?4:16==e?3&t|8:t).toString(16);return n},roleSelector:function(e){return e.replace(/(\S+)/g,"["+l.attr("role")+"=$1],").slice(0,-1)},directiveSelector:function(e){var t=e.split(" ");if(t)for(var n=0;n<t.length;n++)"view"!=t[n]&&(t[n]=t[n].replace(/(\w*)(view|bar|strip|over)$/,"$1-$2"));return t.join(" ").replace(/(\S+)/g,"kendo-mobile-$1,").slice(0,-1)},triggeredByInput:function(e){return/^(label|input|textarea|select)$/i.test(e.target.tagName)},onWidgetRegistered:function(e){for(var t=0,n=l.widgets.length;t<n;t++)e(l.widgets[t]);l._widgetRegisteredCallbacks.push(e)},logToConsole:function(e,n){var i=t.console;!l.suppressLog&&void 0!==i&&i.log&&i[n||"log"](e)}});var be=q.extend({init:function(e,t){var n=this;KendoLicensing.validatePackage(a)||(n._showWatermarkOverlay=Ze),n.element=l.jQuery(e).handler(n),q.fn.init.call(n);var i,r=t?t.dataSource:null;t&&(i=(n.componentTypes||{})[(t||{}).componentType]),r&&(t=c({},t,{dataSource:{}})),t=n.options=c(!0,{},n.options,n.defaults,i||{},t),r&&(t.dataSource=r),n.element.attr(l.attr("role"))||n.element.attr(l.attr("role"),(t.name||"").toLowerCase()),n.element.data("kendo"+t.prefix+t.name,n),n.bind(n.events,t)},events:[],options:{prefix:""},_hasBindingTarget:function(){return!!this.element[0].kendoBindingTarget},_tabindex:function(e){e=e||this.wrapper;var t=this.element,n="tabindex",i=e.attr(n)||t.attr(n);t.removeAttr(n),e.attr(n,isNaN(i)?0:i)},setOptions:function(t){this._clearCssClasses(t),this._setEvents(t),e.extend(this.options,t),this._applyCssClasses()},_setEvents:function(e){for(var t,n=this,i=0,r=n.events.length;i<r;i++)t=n.events[i],n.options[t]&&e[t]&&(n.unbind(t,n.options[t]),n._events&&n._events[t]&&delete n._events[t]);n.bind(n.events,e)},resize:function(e){var t=this.getSize(),n=this._size;(e||(t.width>0||t.height>0)&&(!n||t.width!==n.width||t.height!==n.height))&&(this._size=t,this._resize(t,e),this.trigger("resize",t))},getSize:function(){return l.dimensions(this.element)},size:function(e){if(!e)return this.getSize();this.setSize(e)},setSize:e.noop,_resize:e.noop,destroy:function(){var e=this;e.element.removeData("kendo"+e.options.prefix+e.options.name),e.element.removeData("handler"),e.unbind()},_destroy:function(){this.destroy()},_applyCssClasses:function(e){var t,n,i,r,o=this.__proto__.options,a=this.options,s=e||this.wrapper||this.element,c=[];if(l.cssProperties.propertyDictionary[o.name]){for(t=0;t<V.length;t++)n=V[t],r=this.options._altname||o.name,o.hasOwnProperty(n)&&("themeColor"===n?(i=l.cssProperties.getValidClass({widget:r,propName:"fillMode",value:a.fillMode}))&&i.length&&c.push(l.cssProperties.getValidClass({widget:r,propName:n,value:a[n],fill:a.fillMode})):c.push(l.cssProperties.getValidClass({widget:r,propName:n,value:a[n]})));s.addClass(c.join(" "))}},_ariaLabel:function(t){var n,i=this.element,r=i.attr("id"),o=e('label[for="'+r+'"]'),a=i.attr(R),s=i.attr(F);t[0]!==i[0]&&(a?t.attr(R,a):s?t.attr(F,s):o.length&&(n=o.attr("id")||this._generateLabelId(o,r||l.guid()),t.attr(F,n)))},_clearCssClasses:function(e,t){var n,i,r,o=this.__proto__.options,a=this.options,s=t||this.wrapper||this.element;if(l.cssProperties.propertyDictionary[o.name])for(n=0;n<V.length;n++)i=V[n],r=this.options._altname||o.name,o.hasOwnProperty(i)&&e.hasOwnProperty(i)&&("themeColor"===i?s.removeClass(l.cssProperties.getValidClass({widget:r,propName:i,value:a[i],fill:a.fillMode})):("fillMode"===i&&s.removeClass(l.cssProperties.getValidClass({widget:r,propName:"themeColor",value:a.themeColor,fill:a.fillMode})),s.removeClass(l.cssProperties.getValidClass({widget:r,propName:i,value:a[i]}))))},_generateLabelId:function(e,t){var n=t+"_label";return e.attr("id",n),n}}),ye=be.extend({dataItems:function(){return this.dataSource.flatView()}});l.dimensions=function(e,t){var n=e[0];return t&&e.css(t),{width:n.offsetWidth,height:n.offsetHeight}},l.notify=h;var we=/template$/i,ke=/^\s*(?:\{(?:.|\r\n|\n)*\}|\[(?:.|\r\n|\n)*\])\s*$/,xe=/^\{(\d+)(:[^\}]+)?\}|^\[[A-Za-z_]+\]$/,Ce=/([A-Z])/g;function Se(e,t,n){let i,r=!1;if(0===t.indexOf("data")&&(t=(t=t.substring(4)).charAt(0).toLowerCase()+t.substring(1)),t=t.replace(Ce,"-$1"),i=e.getAttribute("data-"+l.ns+t),null===i&&(i=e.getAttribute("bind:data-"+l.ns+t),r=!0),null===i)i=o;else if("null"===i)i=null;else if("true"===i)i=!0;else if("false"===i)i=!1;else if(b.test(i)&&"mask"!=t&&"format"!=t)i=parseFloat(i);else if(ke.test(i)&&!xe.test(i))try{i=f.parse(i)}catch(e){i=new Function("return ("+i+")")()}else r&&(i=n[i],i instanceof q&&(i=i.toJSON(!0)));return i}function Te(t,n,i){var r,a,s={},c=t.getAttribute("data-"+l.ns+"role");for(r in n)(a=Se(t,r,i))!==o&&(we.test(r)&&"drawer"!=c&&("string"==typeof a?a=De(a)?l.template(e("#"+a).html()):i&&i[a]?l.template(i[a]):l.template(a):U(a)||(a=t.getAttribute(r))),s[r]=a);return s}function De(t){try{return e("#"+t).length}catch(e){}return!1}function Ae(t,n){return e.contains(t,n)?-1:1}function Me(){var t=e(this);return e.inArray(t.attr("data-"+l.ns+"role"),["slider","rangeslider","breadcrumb"])>-1||t.is(":visible")}l.initWidget=function(n,i,r,a){var s,c,d,u,h,p,f,m,g,v;if(r?r.roles&&(r=r.roles):r=l.ui.roles,p=(n=n.nodeType?n:n[0]).getAttribute("data-"+l.ns+"role")){d=(g=-1===p.indexOf("."))?r[p]:l.getter(p)(t);var _=e(n).data(),b=d?"kendo"+d.fn.options.prefix+d.fn.options.name:"";for(var y in v=g?new RegExp("^kendo.*"+p+"$","i"):new RegExp("^"+b+"$","i"),_)if(y.match(v)){if(y!==b)return _[y];s=_[y]}if(d){for(m=Se(n,"dataSource"),i=e.extend({},Te(n,e.extend({},d.fn.options,d.fn.defaults),a),i),m&&(i.dataSource=typeof m===A?l.getter(m)(t):m),u=0,h=d.fn.events.length;u<h;u++)(f=Se(n,c=d.fn.events[u]))!==o&&(i[c]=l.getter(f)(t));return s?e.isEmptyObject(i)||s.setOptions(i):s=new d(n,i),s}}},l.rolesFromNamespaces=function(e){var t,n,i=[];for(e[0]||(e=[l.ui,l.dataviz.ui]),t=0,n=e.length;t<n;t++)i[t]=e[t].roles;return c.apply(null,[{}].concat(i.reverse()))},l.init=function(t){var n=l.rolesFromNamespaces(O.call(arguments,1));e(t).find("[data-"+l.ns+"role]").addBack().each((function(){l.initWidget(this,{},n)}))},l.destroy=function(t){e(t).find("[data-"+l.ns+"role]").addBack().each((function(){var t=e(this).data();for(var n in t)0===n.indexOf("kendo")&&typeof t[n].destroy===D&&t[n].destroy()}))},l.resize=function(t,n){var i=e(t).find("[data-"+l.ns+"role]").addBack().filter(Me);if(i.length){var r=e.makeArray(i);r.sort(Ae),e.each(r,(function(){var t=l.widgetInstance(e(this));t&&t.resize(n)}))}},l.parseOptions=Te,c(l.ui,{Widget:be,DataBoundWidget:ye,roles:{},progress:function(t,n,i){var r,o,a,s,c,d=t.find(".k-loading-mask"),u=l.support,h=u.browser;c=(i=e.extend({},{width:"100%",height:"100%",top:t.scrollTop(),opacity:!1},i)).opacity?"k-loading-mask k-opaque":"k-loading-mask",n?d.length||(o=(r=u.isRtl(t))?"right":"left",s=l.scrollLeft(t),a=h.webkit&&r?t[0].scrollWidth-t.width()-2*s:0,d=e(l.format("<div class='{0}'><span role='alert' aria-live='polite' class='k-loading-text'>{1}</span><div class='k-loading-image'></div><div class='k-loading-color'></div></div>",c,l.ui.progress.messages.loading)).width(i.width).height(i.height).css("top",i.top).css(o,Math.abs(s)+a).prependTo(t)):d&&d.remove()},plugin:function(t,n,i){var r,a=t.fn.options.name;i=i||"",(n=n||l.ui)[a]=t,n.roles[a.toLowerCase()]=t,r="getKendo"+i+a;var s={name:a="kendo"+i+a,widget:t,prefix:i||""};l.widgets.push(s);for(var c=0,d=l._widgetRegisteredCallbacks.length;c<d;c++)l._widgetRegisteredCallbacks[c](s);e.fn[a]=function(n){var i,r=this;return typeof n===A?(i=O.call(arguments,1),this.each((function(){var t,s,c=e.data(this,a);if(!c)throw new Error(l.format("Cannot call method '{0}' of {1} before it is initialized",n,a));if(typeof(t=c[n])!==D)throw new Error(l.format("Cannot find method '{0}' of {1}",n,a));if((s=t.apply(c,i))!==o)return r=s,!1}))):this.each((function(){return new t(this,n)})),r},e.fn[a].widget=t,e.fn[r]=function(){return this.data(a)}}}),l.ui.progress.messages={loading:"Loading..."};var Ee={bind:function(){return this},nullObject:!0,options:{}},Ie=be.extend({init:function(e,t){be.fn.init.call(this,e,t),this.element.autoApplyNS(),this.wrapper=this.element,this.element.addClass("km-widget")},destroy:function(){be.fn.destroy.call(this),this.element.kendoDestroy()},options:{prefix:"Mobile"},events:[],view:function(){var e=this.element.closest(l.roleSelector("view splitview modalview drawer"));return l.widgetInstance(e,l.mobile.ui)||Ee},viewHasNativeScrolling:function(){var e=this.view();return e&&e.options.useNativeScrolling},container:function(){var e=this.element.closest(l.roleSelector("view layout modalview drawer splitview"));return l.widgetInstance(e.eq(0),l.mobile.ui)||Ee}});function ze(t,n){var i=t.nodeName.toLowerCase();return(/input|select|textarea|button|object/.test(i)?!t.disabled:"a"===i&&t.href||n)&&function(t){return e.expr.pseudos.visible(t)&&!e(t).parents().addBack().filter((function(){return"hidden"===e.css(this,"visibility")})).length}(t)}c(l.mobile,{init:function(e){l.init(e,l.mobile.ui,l.ui,l.dataviz.ui)},roles:{},ui:{Widget:Ie,DataBoundWidget:ye.extend(Ie.prototype),roles:{},plugin:function(e){l.ui.plugin(e,l.mobile.ui,"Mobile")}}}),re(l.dataviz,{init:function(e){l.init(e,l.dataviz.ui)},ui:{roles:{},themes:{},views:[],plugin:function(e){l.ui.plugin(e,l.dataviz.ui)}},roles:{}}),l.touchScroller=function(t,n){return n||(n={}),n.useNative=!0,e(t).map((function(t,i){return i=e(i),!(!m.kineticScrollNeeded||!l.mobile.ui.Scroller||i.data("kendoMobileScroller"))&&(i.kendoMobileScroller(n),i.data("kendoMobileScroller"))}))[0]},l.preventDefault=function(e){e.preventDefault()},l.widgetInstance=function(e,n){var i,r,o=e.data(l.ns+"role"),a=[],s=e.data("kendoView");if(o){if("content"===o&&(o="scroller"),"view"===o&&s)return s;if(n)if(n[0])for(i=0,r=n.length;i<r;i++)a.push(n[i].roles[o]);else a.push(n.roles[o]);else a=[l.ui.roles[o],l.dataviz.ui.roles[o],l.mobile.ui.roles[o]];for(o.indexOf(".")>=0&&(a=[l.getter(o)(t)]),i=0,r=a.length;i<r;i++){var c=a[i];if(c){var d=e.data("kendo"+c.fn.options.prefix+c.fn.options.name);if(d)return d}}}},l.onResize=function(n){var i=n;return m.mobileOS.android&&(i=function(){setTimeout(n,600)}),e(t).on(m.resize,i),i},l.unbindResize=function(n){e(t).off(m.resize,n)},l.attrValue=function(e,t){return e.data(l.ns+t)},l.days={Sunday:0,Monday:1,Tuesday:2,Wednesday:3,Thursday:4,Friday:5,Saturday:6},e.extend(e.expr.pseudos,{kendoFocusable:function(t){var n=e.attr(t,"tabindex");return ze(t,!isNaN(n)&&n>-1)}});var Pe=["mousedown","mousemove","mouseenter","mouseleave","mouseover","mouseout","mouseup","click"],He={setupMouseMute:function(){var t=0,n=Pe.length,i=document.documentElement;if(!He.mouseTrap&&m.eventCapture){He.mouseTrap=!0,He.bustClick=!1,He.captureMouse=!1;for(var r=function(t){He.captureMouse&&("click"===t.type?He.bustClick&&!e(t.target).is("label, input, [data-rel=external]")&&(t.preventDefault(),t.stopPropagation()):t.stopPropagation())};t<n;t++)i.addEventListener(Pe[t],r,!0)}},muteMouse:function(e){He.captureMouse=!0,e.data.bustClick&&(He.bustClick=!0),clearTimeout(He.mouseTrapTimeoutID)},unMuteMouse:function(){clearTimeout(He.mouseTrapTimeoutID),He.mouseTrapTimeoutID=setTimeout((function(){He.captureMouse=!1,He.bustClick=!1}),400)}},Fe={down:"touchstart mousedown",move:"mousemove touchmove",up:"mouseup touchend touchcancel",cancel:"mouseleave touchcancel"};m.touch&&(m.mobileOS.ios||m.mobileOS.android)?Fe={down:"touchstart",move:"touchmove",up:"touchend touchcancel",cancel:"touchcancel"}:m.pointers?Fe={down:"pointerdown",move:"pointermove",up:"pointerup",cancel:"pointercancel pointerleave"}:m.msPointers&&(Fe={down:"MSPointerDown",move:"MSPointerMove",up:"MSPointerUp",cancel:"MSPointerCancel MSPointerLeave"}),m.msPointers&&!("onmspointerenter"in t)&&e.each({MSPointerEnter:"MSPointerOver",MSPointerLeave:"MSPointerOut"},(function(t,n){e.event.special[t]={delegateType:n,bindType:n,handle:function(t){var i,r=t.relatedTarget,o=t.handleObj;return r&&(r===this||e.contains(this,r))||(t.type=o.origType,i=o.handler.apply(this,arguments),t.type=n),i}}}));var Re=function(e){return Fe[e]||e},Le=/([^ ]+)/g;l.applyEventMap=function(e,t){return e=e.replace(Le,Re),t&&(e=e.replace(Le,"$1."+t)),e},l.keyDownHandler=function(e,t){var n=t._events.kendoKeydown;if(!n)return!0;n=n.slice(),e.sender=t,e.preventKendoKeydown=!1;for(var i=0,r=n.length;i<r;i++)n[i].call(t,e);return!e.preventKendoKeydown};var Be=e.fn.on;function Oe(e,t){return new Oe.fn.init(e,t)}N(!0,Oe,e),Oe.fn=Oe.prototype=new e,Oe.fn.constructor=Oe,Oe.fn.init=function(t,n){return n&&n instanceof e&&!(n instanceof Oe)&&(n=Oe(n)),e.fn.init.call(this,t,n,Ve)},Oe.fn.init.prototype=Oe.fn;var Ve=Oe(document);c(Oe.fn,{handler:function(e){return this.data("handler",e),this},autoApplyNS:function(e){return this.data("kendoNS",e||l.guid()),this},on:function(){var e=this,t=e.data("kendoNS");if(1===arguments.length)return Be.call(e,arguments[0]);var n=e,i=O.call(arguments);typeof i[i.length-1]===P&&i.pop();var r=i[i.length-1],o=l.applyEventMap(i[0],t);if(m.mouseAndTouchPresent&&o.search(/mouse|click/)>-1&&this[0]!==document.documentElement){He.setupMouseMute();var a=2===i.length?null:i[1],s=o.indexOf("click")>-1&&o.indexOf("touchend")>-1;Be.call(this,{touchstart:He.muteMouse,touchend:He.unMuteMouse},a,{bustClick:s})}if(-1!==arguments[0].indexOf("keydown")&&i[1]&&i[1].options){i[0]=o;var c=i[1],d=i[i.length-1];return i[i.length-1]=function(e){if(l.keyDownHandler(e,c))return d.apply(this,[e])},Be.apply(e,i),e}return typeof r===A&&(n=e.data("handler"),r=n[r],i[i.length-1]=function(e){r.call(n,e)}),i[0]=o,Be.apply(e,i),e},kendoDestroy:function(e){return(e=e||this.data("kendoNS"))&&this.off("."+e),this}}),l.jQuery=Oe,l.eventMap=Fe,l.timezone=function(){var e={Jan:0,Feb:1,Mar:2,Apr:3,May:4,Jun:5,Jul:6,Aug:7,Sep:8,Oct:9,Nov:10,Dec:11},t={Sun:0,Mon:1,Tue:2,Wed:3,Thu:4,Fri:5,Sat:6};function n(n,i){var r,o,a,s=i[3],l=i[4],c=i[5],d=i[8];return d||(i[8]=d={}),d[n]?d[n]:(isNaN(l)?0===l.indexOf("last")?(r=new Date(Date.UTC(n,e[s]+1,1,c[0]-24,c[1],c[2],0)),o=t[l.substr(4,3)],a=r.getUTCDay(),r.setUTCDate(r.getUTCDate()+o-a-(o>a?7:0))):l.indexOf(">=")>=0?(r=new Date(Date.UTC(n,e[s],l.substr(5),c[0],c[1],c[2],0)),o=t[l.substr(0,3)],a=r.getUTCDay(),r.setUTCDate(r.getUTCDate()+o-a+(o<a?7:0))):l.indexOf("<=")>=0&&(r=new Date(Date.UTC(n,e[s],l.substr(5),c[0],c[1],c[2],0)),o=t[l.substr(0,3)],a=r.getUTCDay(),r.setUTCDate(r.getUTCDate()+o-a-(o>a?7:0))):r=new Date(Date.UTC(n,e[s],l,c[0],c[1],c[2],0)),d[n]=r)}function i(e,t,i){if(!(t=t[i])){var r=i.split(":"),o=0;return r.length>1&&(o=60*r[0]+Number(r[1])),[-1e6,"max","-","Jan",1,[0,0,0],o,"-"]}var a=new Date(e).getUTCFullYear();t=jQuery.grep(t,(function(e){var t=e[0],n=e[1];return t<=a&&(n>=a||t==a&&"only"==n||"max"==n)})),t.push(e),t.sort((function(e,t){return"number"!=typeof e&&(e=Number(n(a,e))),"number"!=typeof t&&(t=Number(n(a,t))),e-t}));var s=t[jQuery.inArray(e,t)-1]||t[t.length-1];return isNaN(s)?s:null}function r(e,t,n,r){typeof e!=M&&(e=Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));var o=function(e,t,n){var i=t[n];if("string"==typeof i&&(i=t[i]),!i)throw new Error('Timezone "'+n+'" is either incorrect, or kendo.timezones.min.js is not included.');for(var r=i.length-1;r>=0;r--){var o=i[r][3];if(o&&e>o)break}var a=i[r+1];if(!a)throw new Error('Timezone "'+n+'" not found on '+e+".");return a}(e,t,r);return{zone:o,rule:i(e,n,o[1])}}return{zones:{},rules:{},offset:function(e,t){if("Etc/UTC"==t||"Etc/GMT"==t)return 0;var n=r(e,this.zones,this.rules,t),i=n.zone,o=n.rule;return l.parseFloat(o?i[0]-o[6]:i[0])},convert:function(e,t,n){var i,r=n;typeof t==A&&(t=this.offset(e,t)),typeof n==A&&(n=this.offset(e,n));var o=e.getTimezoneOffset(),a=(e=new Date(e.getTime()+6e4*(t-n))).getTimezoneOffset();return typeof r==A&&(r=this.offset(e,r)),i=a-o+(n-r),new Date(e.getTime()+6e4*i)},apply:function(e,t){return this.convert(e,e.getTimezoneOffset(),t)},remove:function(e,t){return this.convert(e,t,e.getTimezoneOffset())},abbr:function(e,t){var n=r(e,this.zones,this.rules,t),i=n.zone,o=n.rule,a=i[2];return a.indexOf("/")>=0?a.split("/")[o&&+o[6]?1:0]:a.indexOf("%s")>=0?a.replace("%s",o&&"-"!=o[7]?o[7]:""):a},toLocalDate:function(e){return this.apply(new Date(e),"Etc/UTC")}}}(),l.date=function(){var e=6e4,t=864e5;function n(e,t){return 0===t&&23===e.getHours()&&(e.setHours(e.getHours()+2),!0)}function i(e,t,i){var r=e.getHours();i=i||1,t=(t-e.getDay()+7*i)%7,e.setDate(e.getDate()+t),n(e,r)}function r(e,t,n){return i(e=new Date(e),t,n),e}function a(e){return new Date(e.getFullYear(),e.getMonth(),1)}function s(e,n){var i=new Date(e.getFullYear(),0,1,-6),o=function(e,t){return 1!==t?u(r(e,t,-1),4):u(e,4-(e.getDay()||7))}(e,n),a=o.getTime()-i.getTime(),s=Math.floor(a/t);return 1+Math.floor(s/7)}function c(e){return n(e=new Date(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0),0),e}function d(e){return f(e).getTime()-c(f(e))}function u(e,i){var r=e.getHours();return h(e=new Date(e),i*t),n(e,r),e}function h(t,n,i){var r,o=t.getTimezoneOffset();t.setTime(t.getTime()+n),i||(r=t.getTimezoneOffset()-o,t.setTime(t.getTime()+r*e))}function p(){return c(new Date)}function f(e){var t=new Date(1980,1,1,0,0,0);return e&&t.setHours(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()),t}function m(e,t){var n=new Date(e);return new Date(n.setFullYear(n.getFullYear()+t))}function g(e,t){var n=e[e.length-1];n&&"LITERAL"===n.type?n.pattern+=t:e.push({type:"literal",pattern:t})}function v(e){return"h"===e||"K"===e}function _(e,t,n){return n=n||0,e.indexOf(t,n)===n}return{adjustDST:n,dayOfWeek:r,setDayOfWeek:i,getDate:c,isInDateRange:function(e,n,i){var r,o=n.getTime(),a=i.getTime();return o>=a&&(a+=t),(r=e.getTime())>=o&&r<=a},isInTimeRange:function(e,n,i){var r,o=d(n),a=d(i);return!e||o==a||(n>=i&&(i+=t),o>(r=d(e))&&(r+=t),a<o&&(a+=t),r>=o&&r<=a)},isToday:function(e){return c(e).getTime()==p().getTime()},nextDay:function(e){return u(e,1)},previousDay:function(e){return u(e,-1)},toUtcTime:function(e){return Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())},MS_PER_DAY:t,MS_PER_HOUR:36e5,MS_PER_MINUTE:e,setTime:h,setHours:function(e,t){return n(e=new Date(e.getFullYear(),e.getMonth(),e.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()),t.getHours()),e},addDays:u,today:p,toInvariantTime:f,firstDayOfMonth:a,splitDateFormat:function(e){for(var t,n,i,r,o,a,s,c,d=function(e,t){var n,i=t.calendar;return"string"==typeof e&&(n=i.patterns[e]?i.patterns[e]:e),n||(n=i.patterns.d),n}(e,l.culture()).replaceAll("dddd","EEEE").replaceAll("ddd","EEE").replace("tt","aa"),u=[],h=/d{1,2}|E{1,6}|e{1,6}|c{3,6}|c{1}|M{1,5}|L{1,5}|y{1,4}|H{1,2}|h{1,2}|k{1,2}|K{1,2}|m{1,2}|a{1,5}|s{1,2}|S{1,3}|t{1,2}|z{1,4}|Z{1,5}|x{1,5}|X{1,5}|G{1,5}|q{1,5}|Q{1,5}|"[^"]*"|'[^']*'/g,p=h.lastIndex=0,f=h.exec(d);f;){var m=f[0];p<f.index&&g(u,d.substring(p,f.index)),_(m,'"')||_(m,"'")?g(u,m):(t=m[0],i={type:n=S[t],pattern:m},"hour"===n&&(i.hour12=v(m)),(r=T[n])&&(o="number"==typeof r.minLength?r.minLength:r.minLength[t],(a=m.length)>=o&&"aa"!==m&&(i.names={type:r.type,nameType:(s=a,c=void 0,s<=3?c="abbreviated":4===s?c="wide":5===s&&(c="narrow"),c),standAlone:r.standAlone===t})),u.push(i)),p=h.lastIndex,f=h.exec(d)}return p<d.length&&g(u,d.substring(p)),u},dateFieldName:function(e){return(l.culture().calendar.dateFields[e.type]||{})[e.nameType]},dateFormatNames:function(e){let{type:t,nameType:n}=e;const i=l.culture();"wide"===n&&(n="names"),"abbreviated"===n&&(n="namesAbbr"),"narrow"===n&&(n="namesShort");let r=i.calendar[t][n];return r||(r=i.calendar[t].name),r},lastDayOfMonth:function(e){var t=new Date(e.getFullYear(),e.getMonth()+1,0),n=a(e),i=Math.abs(t.getTimezoneOffset()-n.getTimezoneOffset());return i&&t.setHours(n.getHours()+i/60),t},weekInYear:function(e,t){t===o&&(t=l.culture().calendar.firstDay);var n=u(e,-7),i=u(e,7),r=s(e,t);return 0===r?s(n,t)+1:53===r&&s(i,t)>1?1:r},getMilliseconds:d,firstDayOfYear:function(e){return new Date(e.getFullYear(),0,1)},lastDayOfYear:function(e){return new Date(e.getFullYear(),11,31)},nextYear:function(e){return m(e,1)},previousYear:function(e){return m(e,-1)}}}(),l.stripWhitespace=function(e){if(document.createNodeIterator)for(var t=document.createNodeIterator(e,NodeFilter.SHOW_TEXT,(function(t){return t.parentNode==e?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_REJECT}),!1);t.nextNode();)t.referenceNode&&!t.referenceNode.textContent.trim()&&t.referenceNode.parentNode.removeChild(t.referenceNode)};var Ne=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.oRequestAnimationFrame||t.msRequestAnimationFrame||function(e){setTimeout(e,1e3/60)};l.animationFrame=function(e){Ne.call(t,e)};var $e=[];l.queueAnimation=function(e){$e[$e.length]=e,1===$e.length&&l.runNextAnimation()},l.runNextAnimation=function(){l.animationFrame((function(){$e[0]&&($e.shift()(),$e[0]&&l.runNextAnimation())}))},l.parseQueryStringParams=function(e){for(var t={},n=(e.split("?")[1]||"").split(/&|=/),i=n.length,r=0;r<i;r+=2)""!==n[r]&&(t[decodeURIComponent(n[r])]=decodeURIComponent(n[r+1]));return t},l.elementUnderCursor=function(e){if(void 0!==e.x.client)return document.elementFromPoint(e.x.client,e.y.client)},l.wheelDeltaY=function(e){var t,n=e.originalEvent,i=n.wheelDeltaY;return n.wheelDelta?(i===o||i)&&(t=n.wheelDelta):n.detail&&n.axis===n.VERTICAL_AXIS&&(t=10*-n.detail),t},l.throttle=function(e,t){var n,i=0;if(!t||t<=0)return e;var r=function(){var r=this,o=+new Date-i,a=arguments;function s(){e.apply(r,a),i=+new Date}if(!i)return s();n&&clearTimeout(n),o>t?s():n=setTimeout(s,t-o)};return r.cancel=function(){clearTimeout(n)},r},l.caret=function(t,n,i){var r,a=n!==o;if(i===o&&(i=n),t[0]&&(t=t[0]),!a||!t.disabled){try{if(t.selectionStart!==o)if(a){t.focus();var s=m.mobileOS;s.wp||s.android?setTimeout((function(){t.setSelectionRange(n,i)}),0):t.setSelectionRange(n,i)}else n=[t.selectionStart,t.selectionEnd];else if(document.selection)if(e(t).is(":visible")&&t.focus(),r=t.createTextRange(),a)r.collapse(!0),r.moveStart("character",n),r.moveEnd("character",i-n),r.select();else{var l,c,d=r.duplicate();r.moveToBookmark(document.selection.createRange().getBookmark()),d.setEndPoint("EndToStart",r),c=(l=d.text.length)+r.text.length,n=[l,c]}}catch(e){n=[]}return n}},l.antiForgeryTokens=function(){var t={},n=e("meta[name=csrf-token],meta[name=_csrf]").attr("content"),i=e("meta[name=csrf-param],meta[name=_csrf_header]").attr("content");return e("input[name^='__RequestVerificationToken']").each((function(){t[this.name]=this.value})),i!==o&&n!==o&&(t[i]=n),t},l.cycleForm=function(e){var t=e.find("input, .k-widget, .k-dropdownlist, .k-combobox").first(),n=e.find("button, .k-button").last();function i(e){var t=l.widgetInstance(e);t&&t.focus?t.focus():e.trigger("focus")}n.on("keydown",(function(e){e.keyCode!=l.keys.TAB||e.shiftKey||(e.preventDefault(),i(t))})),t.on("keydown",(function(e){e.keyCode==l.keys.TAB&&e.shiftKey&&(e.preventDefault(),i(n))}))},l.focusElement=function(n){var i=[],r=n.parentsUntil("body").filter((function(e,t){return"visible"!==l.getComputedStyles(t,["overflow"]).overflow})).add(t);r.each((function(t,n){i[t]=e(n).scrollTop()}));try{n[0].setActive()}catch(e){n[0].focus()}r.each((function(t,n){e(n).scrollTop(i[t])}))},l.focusNextElement=function(){if(document.activeElement){var t=e(":kendoFocusable"),n=t.index(document.activeElement);if(n>-1)(t[n+1]||t[0]).focus()}},l.trim=function(e){return e?e.toString().trim():""},l.getWidgetFocusableElement=function(t){var n=t.closest(":kendoFocusable"),i=l.widgetInstance(t);return n.length?n:i?"Editor"===i.options.name?e(i.body):i.wrapper.find(":kendoFocusable").first():t},l.addAttribute=function(e,t,n){var i=e.attr(t)||"";i.indexOf(n)<0&&e.attr(t,(i+" "+n).trim())},l.removeAttribute=function(e,t,n){var i=e.attr(t)||"";e.attr(t,i.replace(n,"").trim())},l.toggleAttribute=function(e,t,n){(e.attr(t)||"").indexOf(n)<0?l.addAttribute(e,t,n):l.removeAttribute(e,t,n)},l.matchesMedia=function(e){var n=l._bootstrapToMedia(e)||e;return m.matchMedia&&t.matchMedia(n).matches},l._bootstrapToMedia=function(e){return{xs:"(max-width: 576px)",sm:"(min-width: 576px)",md:"(min-width: 768px)",lg:"(min-width: 992px)",xl:"(min-width: 1200px)"}[e]},l.fileGroupMap={audio:[".aif",".iff",".m3u",".m4a",".mid",".mp3",".mpa",".wav",".wma",".ogg",".wav",".wma",".wpl"],video:[".3g2",".3gp",".avi",".asf",".flv",".m4u",".rm",".h264",".m4v",".mkv",".mov",".mp4",".mpg",".rm",".swf",".vob",".wmv"],image:[".ai",".dds",".heic",".jpe","jfif",".jif",".jp2",".jps",".eps",".bmp",".gif",".jpeg",".jpg",".png",".ps",".psd",".svg",".svgz",".tif",".tiff"],txt:[".doc",".docx",".log",".pages",".tex",".wpd",".wps",".odt",".rtf",".text",".txt",".wks"],presentation:[".key",".odp",".pps",".ppt",".pptx"],data:[".xlr",".xls",".xlsx"],programming:[".tmp",".bak",".msi",".cab",".cpl",".cur",".dll",".dmp",".drv",".icns",".ico",".link",".sys",".cfg",".ini",".asp",".aspx",".cer",".csr",".css",".dcr",".htm",".html",".js",".php",".rss",".xhtml"],pdf:[".pdf"],config:[".apk",".app",".bat",".cgi",".com",".exe",".gadget",".jar",".wsf"],zip:[".7z",".cbr",".gz",".sitx",".arj",".deb",".pkg",".rar",".rpm",".tar.gz",".z",".zip",".zipx"],"disc-image":[".dmg",".iso",".toast",".vcd",".bin",".cue",".mdf"]},l.getFileGroup=function(e,t){var n=l.fileGroupMap,i=Object.keys(n),r="file";if(e===o||!e.length)return r;for(var a=0;a<i.length;a+=1){if(n[i[a]].indexOf(e.toLowerCase())>-1)return t?"file-"+i[a]:i[a]}return r},l.getFileSizeMessage=function(e){if(0===e)return"0 Byte";var t=parseInt(Math.floor(Math.log(e)/Math.log(1024)),10);return Math.round(e/Math.pow(1024,t),2)+" "+["Bytes","KB","MB","GB","TB"][t]},l.selectorFromClasses=function(e){return"."+e.split(" ").join(".")};var Ue=["base","primary","secondary","tertiary","inherit","info","success","warning","error","dark","light","inverse"],We=["solid","outline","flat"],je=["rectangle","square"],qe=[["small","sm"],["medium","md"],["large","lg"]],Ge=[["small","sm"],["medium","md"],["large","lg"]],Ke=["fixed","static","sticky","absolute"],Ye=[["both","resize"],["horizontal","resize-x"],["vertical","resize-y"]],Qe=["auto","hidden","visible","scroll","clip"],Xe=[["vertical","!k-flex-col"],["horizontal","!k-flex-row"]];l.cssProperties=function(){var e={};function t(t,n,i){e[t]||(e[t]={}),e[t][n]=i||n}function n(e,n){for(var i=0;i<n.length;i++)u(n[i])?t(e,n[i][0],n[i][1]):t(e,n[i])}return n("themeColor",Ue),n("fillMode",We),n("shape",je),n("size",qe),n("positionMode",Ke),n("rounded",Ge),n("resize",Ye),n("overflow",Qe),n("layoutFlow",Xe),{positionModeValues:Ke,roundedValues:Ge,sizeValues:qe,shapeValues:je,fillModeValues:We,themeColorValues:Ue,defaultValues:e,propertyDictionary:{},registerValues:function(e,t){var n,i,r,o,a,s,c=l.cssProperties.propertyDictionary;for(n=0;n<t.length;n++)for(r=t[n].prop,a=t[n].values,c[e][r]||(c[e][r]={}),o=c[e][r],i=0;i<a.length;i++)s=a[i],u(a[i])?o[s[0]]=s[1]:o[s]=s},getValidClass:function(e){var t,n,i,r=e.widget,o=e.propName,a=e.value,s=e.fill,c=l.cssProperties,d=c.defaultValues[o],u=c.propertyDictionary[r],h=e.prefix;return u&&(n=(t=u[o])&&t[a]||d[a])?(i="themeColor"===o?u[H]+s+"-":"positionMode"===o?"k-pos-":"rounded"===o?"k-rounded-":"resize"===o?"k-":"overflow"===o?"k-overflow-":"layoutFlow"===o?"":u[H],(i=h||i)+n):""},registerPrefix:function(e,t){var n=l.cssProperties.propertyDictionary;n[e]||(n[e]={}),n[e][H]=t}}}(),l.registerCssClass=function(e,t,n){l.propertyToCssClassMap[e]||(l.propertyToCssClassMap[e]={}),l.propertyToCssClassMap[e][t]=n||t},l.registerCssClasses=function(e,t){for(var n=0;n<t.length;n++)u(t[n])?l.registerCssClass(e,t[n][0],t[n][1]):l.registerCssClass(e,t[n])},l.getValidCssClass=function(e,t,n){var i=l.propertyToCssClassMap[t][n];if(i)return e+i},l.propertyToCssClassMap={},l.registerCssClasses("themeColor",Ue),l.registerCssClasses("fill",We),l.registerCssClasses("shape",je),l.registerCssClasses("size",qe),l.registerCssClasses("positionMode",Ke),l.applyStylesFromKendoAttributes=function(t,n){let i=n.map((e=>`[${l.attr(`style-${e}`)}]`)).join(",");t.find(i).addBack(i).each(((t,i)=>{let r=e(i);n.forEach((function(e){let t=l.attr(`style-${e}`);r.attr(t)&&(r.css(e,r.attr(t)),r.removeAttr(t))}))}))},l.whenAll=function(t){var n,i=1==arguments.length&&Array.isArray(t)?t:Array.prototype.slice.call(arguments),r=i.length,o=r,a=e.Deferred(),s=0,c=0,d=Array(r),u=Array(r),h=Array(r);function p(e,t,n){return function(){n!=i&&c++,a.notifyWith(t[e]=this,n[e]=Array.prototype.slice.call(arguments)),--o||a[(c?"reject":"resolve")+"With"](t,n)}}for(;s<r;s++)(n=i[s])&&l.isFunction(n.promise)?n.promise().done(p(s,h,i)).fail(p(s,d,u)):(a.notifyWith(this,n),--o);return o||a.resolveWith(h,i),a.promise()},function(){function n(t,n,i,r){var o=e("<form>").attr({action:i,method:"POST",target:r}),a=l.antiForgeryTokens();a.fileName=n;var s=t.split(";base64,");for(var c in a.contentType=s[0].replace("data:",""),a.base64=s[1],a)a.hasOwnProperty(c)&&e("<input>").attr({value:a[c],name:c,type:"hidden"}).appendTo(o);o.appendTo("body").submit().remove()}var i=document.createElement("a"),r="download"in i&&!l.support.browser.edge;function o(e,t){var n=e;if("string"==typeof e){for(var i=e.split(";base64,"),r=i[0],o=atob(i[1]),a=new Uint8Array(o.length),s=0;s<o.length;s++)a[s]=o.charCodeAt(s);n=new Blob([a.buffer],{type:r})}navigator.msSaveBlob(n,t)}function a(e,n){t.Blob&&e instanceof Blob&&(e=URL.createObjectURL(e)),i.download=n,i.href=e;var r=document.createEvent("MouseEvents");r.initMouseEvent("click",!0,!1,t,0,0,0,0,0,!1,!1,!1,!1,0,null),i.dispatchEvent(r),setTimeout((function(){URL.revokeObjectURL(e)}))}l.saveAs=function(e){var t=n;e.forceProxy||(r?t=a:navigator.msSaveBlob&&(t=o)),t(e.dataURI,e.fileName,e.proxyURL,e.proxyTarget)}}(),l.proxyModelSetters=function(e){var t={};return Object.keys(e||{}).forEach((function(n){Object.defineProperty(t,n,{get:function(){return e[n]},set:function(t){e[n]=t,e.dirty=!0}})})),t},l.getSeriesColors=function(){var t=e('<div class="k-var--series-a"></div><div class="k-var--series-b"></div><div class="k-var--series-c"></div><div class="k-var--series-d"></div><div class="k-var--series-e"></div><div class="k-var--series-f"></div>'),n=[];return t.appendTo(e("body")),t.each((function(t,i){n.push(e(i).css("background-color"))})),t.remove(),n},l.isElement=function(e){return e instanceof Element||e instanceof HTMLDocument},l.defaults=l.defaults||{},l.setDefaults=function(e,t){var n=e.split("."),i=l.defaults;e=n.pop(),n.forEach((function(e){i[e]===o&&(i[e]={}),i=i[e]})),t.constructor===Object?i[e]=re({},i[e],t):i[e]=t},l.debugTemplates=t.DEBUG_KENDO_TEMPLATES,l.setDefaults("breakpoints",n),l.class2type={},jQuery.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),(function(e,t){l.class2type["[object "+t+"]"]=t.toLowerCase()})),l.type=function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?l.class2type[Object.prototype.toString.call(e)]||"object":typeof e};var KendoLicensing={validatePackage:function(){return!0},setScriptKey:function(){}};function Ze(e){KendoLicensing.addWatermarkOverlay&&KendoLicensing.addWatermarkOverlay(e,a),KendoLicensing.showBanner&&KendoLicensing.showBanner(a)}t.KendoLicensing={setScriptKey:KendoLicensing.setScriptKey}}(jQuery,window);kendo;!function(e){var t=window.kendo,n="change",i="same",r=t.support,o=window.location,a=window.history,s=t.support.browser.msie,l=/^#*/,c=window.document;function d(e,t){return t?(e+"/"===t&&(e=t),new RegExp("^"+t,"i").test(e)||(e=t+"/"+e),o.protocol+"//"+(o.host+"/"+e).replace(/\/\/+/g,"/")):e}function u(e){return e?"#!":"#"}function h(e){var t=o.href;return"#!"===e&&t.indexOf("#")>-1&&t.indexOf("#!")<0?null:t.split(e)[1]||""}function p(e,t){return 0===t.indexOf(e)?t.substr(e.length).replace(/\/\//g,"/"):t}var f=t.Class.extend({back:function(){s?setTimeout((function(){a.back()})):a.back()},forward:function(){s?setTimeout((function(){a.forward()})):a.forward()},length:function(){return a.length},replaceLocation:function(e){o.replace(e)}}),m=f.extend({init:function(e){this.root=e},navigate:function(e){a.pushState({},c.title,d(e,this.root))},replace:function(e){a.replaceState({},c.title,d(e,this.root))},normalize:function(e){return p(this.root,e)},current:function(){var e=o.pathname;return o.search&&(e+=o.search),p(this.root,e)},change:function(t){e(window).bind("popstate.kendo",t)},stop:function(){e(window).unbind("popstate.kendo")},normalizeCurrent:function(e){var t,n=e.root,i=o.pathname,r=h(u(e.hashBang));n===i+"/"&&(t=n),n===i&&r&&(t=d(r.replace(l,""),n)),t&&a.pushState({},c.title,t)}});function g(e){return e.replace(/^(#)?/,"#")}function v(e){return e.replace(/^(#(!)?)?/,"#!")}var _=f.extend({init:function(e){this._id=t.guid(),this.prefix=u(e),this.fix=e?v:g},navigate:function(e){o.hash=this.fix(e)},replace:function(e){this.replaceLocation(this.fix(e))},normalize:function(e){return e.indexOf(this.prefix)<0?e:e.split(this.prefix)[1]},change:function(t){r.hashChange?e(window).on("hashchange."+this._id,t):this._interval=setInterval(t,50)},stop:function(){e(window).off("hashchange."+this._id),clearInterval(this._interval)},current:function(){return h(this.prefix)},normalizeCurrent:function(e){var t=o.pathname,n=e.root;return!(!e.pushState||n===t)&&(this.replaceLocation(n+this.prefix+p(n,t)),!0)}}),b=t.Observable.extend({start:function(t){if(t=t||{},this.bind([n,"back",i],t),!this._started){this._started=!0,t.root=t.root||"/";var r,o=this.createAdapter(t);o.normalizeCurrent(t)||(r=o.current(),e.extend(this,{adapter:o,root:t.root,historyLength:o.length(),current:r,locations:[r]}),o.change(this._checkUrl.bind(this)))}},createAdapter:function(e){return r.pushState&&e.pushState?new m(e.root):new _(e.hashBang)},stop:function(){this._started&&(this.adapter.stop(),this.unbind(n),this._started=!1)},change:function(e){this.bind(n,e)},replace:function(e,t){this._navigate(e,t,(function(t){t.replace(e),this.locations[this.locations.length-1]=this.current}))},navigate:function(e,t){if("#:back"===e)return this.backCalled=!0,void this.adapter.back();this._navigate(e,t,(function(t){t.navigate(e),this.locations.push(this.current)}))},_navigate:function(e,t,r){var o=this.adapter;e=o.normalize(e),this.current!==e&&this.current!==decodeURIComponent(e)?!t&&this.trigger(n,{url:e,decode:!1})||(this.current=e,r.call(this,o),this.historyLength=o.length()):this.trigger(i)},_checkUrl:function(){var e=this.adapter,t=e.current(),i=e.length(),r=this.historyLength===i,o=t===this.locations[this.locations.length-2]&&r,a=this.backCalled,s=this.current;return null===t||this.current===t||this.current===decodeURIComponent(t)||(this.historyLength=i,this.backCalled=!1,this.current=t,o&&this.trigger("back",{url:s,to:t})?(e.forward(),void(this.current=s)):this.trigger(n,{url:t,backButtonPressed:!a})?(o?e.forward():(e.back(),this.historyLength--),void(this.current=s)):void(o?this.locations.pop():this.locations.push(t)))}});t.History=b,t.History.HistoryAdapter=f,t.History.HashAdapter=_,t.History.PushStateAdapter=m,t.absoluteURL=d,t.history=new b}(window.kendo.jQuery);kendo;!function(){var e=window.kendo,t=e.history,n=e.Observable,i="init",r="routeMissing",o="change",a="back",s="same",l=/\((.*?)\)/g,c=/(\(\?)?:\w+/g,d=/\*\w+/g,u=/[\-{}\[\]+?.,\\\^$|#\s]/g;function h(e,t){return t?e:"([^/]+)"}function p(e){return e.replace(/(\?.*)|(#.*)/g,"")}var f=e.Class.extend({init:function(e,t,n){e instanceof RegExp||(e=function(e,t){return new RegExp("^"+e.replace(u,"\\$&").replace(l,"(?:$1)?").replace(c,h).replace(d,"(.*?)")+"$",t?"i":"")}(e,n)),this.route=e,this._callback=t},callback:function(t,n,i){var r,o,a=0,s=e.parseQueryStringParams(t);if(s._back=n,t=p(t),o=(r=this.route.exec(t).slice(1)).length,i)for(;a<o;a++)void 0!==r[a]&&(r[a]=decodeURIComponent(r[a]));r.push(s),this._callback.apply(null,r)},worksWith:function(e,t,n){return!!this.route.test(p(e))&&(this.callback(e,t,n),!0)}}),m=n.extend({init:function(e){e||(e={}),n.fn.init.call(this),this.routes=[],this.pushState=e.pushState,this.hashBang=e.hashBang,this.root=e.root,this.ignoreCase=!1!==e.ignoreCase,this.bind([i,r,o,s,a],e)},destroy:function(){t.unbind(o,this._urlChangedProxy),t.unbind(s,this._sameProxy),t.unbind(a,this._backProxy),this.unbind()},start:function(){var e=this,n=function(t){e._back(t)},r=function(t){e._urlChanged(t)};t.start({same:function(){e._same()},change:r,back:n,pushState:e.pushState,hashBang:e.hashBang,root:e.root});var o={url:t.current||"/",preventDefault:$.noop};e.trigger(i,o)||e._urlChanged(o),this._urlChangedProxy=r,this._backProxy=n},route:function(e,t){this.routes.push(new f(e,t,this.ignoreCase))},navigate:function(t,n){e.history.navigate(t,n)},replace:function(t,n){e.history.replace(t,n)},_back:function(e){this.trigger(a,{url:e.url,to:e.to})&&e.preventDefault()},_same:function(){this.trigger(s)},_urlChanged:function(t){var n=t.url,i=!!t.decode,a=t.backButtonPressed;if(n||(n="/"),this.trigger(o,{url:t.url,params:e.parseQueryStringParams(t.url),backButtonPressed:a}))t.preventDefault();else{for(var s=0,l=this.routes,c=l.length;s<c;s++)if(l[s].worksWith(n,a,i))return;this.trigger(r,{url:n,params:e.parseQueryStringParams(n),backButtonPressed:a})&&t.preventDefault()}}});e.Router=m}();!function(e){var t=window.kendo,n=e.extend,i="\r\n",r="\r\n\r\n",o=t.isFunction,a={eq:"eq",neq:"ne",gt:"gt",gte:"ge",lt:"lt",lte:"le",contains:"substringof",doesnotcontain:"substringof",endswith:"endswith",startswith:"startswith",isnull:"eq",isnotnull:"ne",isnullorempty:"eq",isnotnullorempty:"ne",isempty:"eq",isnotempty:"ne"},s=n({},a,{contains:"contains"}),l={pageSize:e.noop,page:e.noop,filter:function(e,t,n){t&&(t=d(t,n))&&(e.$filter=t)},sort:function(t,n){var i=e.map(n,(function(e){var t=e.field.replace(/\./g,"/");return"desc"===e.dir&&(t+=" desc"),t})).join(",");i&&(t.$orderby=i)},skip:function(e,t){t&&(e.$skip=t)},take:function(e,t){t&&(e.$top=t)}},c={read:{dataType:"jsonp"}};function d(e,n){var i,r,o,l,c,u,h,p,f=[],m=e.logic||"and",g=e.filters;for(i=0,r=g.length;i<r;i++)o=(e=g[i]).field,h=e.value,u=e.operator,e.filters?e=d(e,n):(p=e.ignoreCase,o=o.replace(/\./g,"/"),e=a[u],n&&(e=s[u]),"isnullorempty"===u?e=t.format("({0} {1} null or {0} {1} '')",o,e):"isnotnullorempty"===u?e=t.format("({0} {1} null and {0} {1} '')",o,e):"isnull"===u||"isnotnull"===u?e=t.format("{0} {1} null",o,e):"isempty"===u||"isnotempty"===u?e=t.format("{0} {1} ''",o,e):e&&undefined!==h&&("string"===(l=t.type(h))?(c="'{1}'",h=h.replace(/'/g,"''"),!0===p&&(o="tolower("+o+")")):"date"===l?n?(c="{1:yyyy-MM-ddTHH:mm:ss+00:00}",h=t.timezone.apply(h,"Etc/UTC")):c="datetime'{1:yyyy-MM-ddTHH:mm:ss}'":c="{1}",e.length>3?"substringof"!==e?c="{0}({2},"+c+")":(c="{0}("+c+",{2})","doesnotcontain"===u&&(n?(c="{0}({2},'{1}') eq -1",e="indexof"):c+=" eq false")):c="{2} {0} "+c,e=t.format(c,e,h,o))),f.push(e);return e=f.join(" "+m+" "),f.length>1&&(e="("+e+")"),e}function u(e){for(var t in e)0===t.indexOf("@odata")&&delete e[t]}function h(){return Math.floor(65536*(1+Math.random())).toString(16).substr(1)}function p(e){return e+h()+"-"+h()+"-"+h()}function f(e,t){var n="\r\n--"+e;return t&&(n+="--"),n}function m(e,n,i,r){var a=e.options[r].url,s=t.format("{0} ",i);return o(a)?s+a(n):s+a}function g(e,t){var n="";return n+=f(e,!1),n+="\r\nContent-Type: application/http",n+="\r\nContent-Transfer-Encoding: binary",n+="\r\nContent-ID: "+t}function v(e,n,o,a,s,l,c){var d="";return d+=function(e,t){var n="";return n+="--"+e+i,n+="Content-Type: multipart/mixed; boundary="+t+i,n}(n,o),d+=function(e,n,o,a,s,l){for(var c,d,u="",h=0;h<e.length;h++)u+=g(n,o),u+=r+m(s,e[h],s.options[a].type,a)+" HTTP/1.1",l||(u+=(c=e[h],d=void 0,d="",d+="\r\nContent-Type: application/json;odata=minimalmetadata",d+="\r\nPrefer: return=representation",d+=r+t.stringify(c))),u+=i,o++;return u}(e,o,a,l,s,c),d+=f(o,!0),d+=i}n(!0,t.data,{schemas:{odata:{type:"json",data:function(e){return e.d.results||[e.d]},total:"d.__count"}},transports:{odata:{read:{cache:!0,dataType:"jsonp",jsonp:"$callback"},update:{cache:!0,dataType:"json",contentType:"application/json",type:"PUT"},create:{cache:!0,dataType:"json",contentType:"application/json",type:"POST"},destroy:{cache:!0,dataType:"json",type:"DELETE"},parameterMap:function(e,n,i){var r,o,a,s;if(e=e||{},n=n||"read",s=(s=(this.options||c)[n])?s.dataType:"json","read"===n)for(a in r={$inlinecount:"allpages"},"json"!=s&&(r.$format="json"),e)l[a]?l[a](r,e[a],i):r[a]=e[a];else{if("json"!==s)throw new Error("Only json dataType can be used for "+n+" operation.");if("destroy"!==n){for(a in e)"number"==typeof(o=e[a])&&(e[a]=o+"");r=t.stringify(e)}}return r}}}}),n(!0,t.data,{schemas:{"odata-v4":{type:"json",data:function(t){if(Array.isArray(t)){for(var n=0;n<t.length;n++)u(t[n]);return t}return u(t=e.extend({},t)),t.value?t.value:[t]},total:function(e){return e["@odata.count"]}}},transports:{"odata-v4":{batch:{type:"POST"},read:{cache:!0,dataType:"json"},update:{cache:!0,dataType:"json",contentType:"application/json;IEEE754Compatible=true",type:"PUT"},create:{cache:!0,dataType:"json",contentType:"application/json;IEEE754Compatible=true",type:"POST"},destroy:{cache:!0,dataType:"json",type:"DELETE"},parameterMap:function(e,n){var i=t.data.transports.odata.parameterMap(e,n,!0);return"read"==n&&(i.$count=!0,delete i.$inlinecount),i&&i.$filter&&(i.$filter=i.$filter.replace(/('[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}')/gi,(function(e){return e.substring(1,e.length-1)}))),i},submit:function(i){var r=function(e,t){var i=n({},e.options.batch),r=p("sf_batch_"),a="",s=0,l=e.options.batch.url,c=p("sf_changeset_");return i.type=e.options.batch.type,i.url=o(l)?l():l,i.headers=n(i.headers||{},{"Content-Type":"multipart/mixed; boundary="+r}),t.updated.length&&(a+=v(t.updated,r,c,s,e,"update",!1),s+=t.updated.length,c=p("sf_changeset_")),t.destroyed.length&&(a+=v(t.destroyed,r,c,s,e,"destroy",!0),s+=t.destroyed.length,c=p("sf_changeset_")),t.created.length&&(a+=v(t.created,r,c,s,e,"create",!1)),a+=f(r,!0),i.data=a,i}(this,i.data),a=i.data;(a.updated.length||a.destroyed.length||a.created.length)&&e.ajax(n(!0,{},{success:function(e){var n,r=function(e){var n,i,r,o,a,s=e.match(/--changesetresponse_[a-z0-9-]+$/gm),l=0,c=[];c.push({models:[],passed:!0});for(var d=0;d<s.length;d++)(o=s[d]).lastIndexOf("--",o.length-1)?d<s.length-1&&c.push({models:[],passed:!0}):(l=l?e.indexOf(o,l+o.length):e.indexOf(o),i=(n=e.substring(l,e.indexOf("--",l+1))).match(/^HTTP\/1\.\d (\d{3}) (.*)$/gm).pop(),(r=t.parseFloat(i.match(/\d{3}/g).pop()))>=200&&r<=299?(a=n.match(/\{.*\}/gm))&&c[c.length-1].models.push(JSON.parse(a[0])):c[c.length-1].passed=!1);return c}(e),o=0;a.updated.length&&((n=r[o]).passed&&i.success(n.models.length?n.models:[],"update"),o++),a.destroyed.length&&((n=r[o]).passed&&i.success([],"destroy"),o++),a.created.length&&(n=r[o]).passed&&i.success(n.models,"create")},error:function(e,t,n){i.error(e,t,n)}},r))}}}})}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=Array.isArray,i=e.isPlainObject,r=e.map,o=e.each,a=e.extend,s=t.getter,l=t.Class.extend({init:function(e){var s=this,l=e.total,c=e.model,d=e.parse,u=e.errors,h=e.serialize,p=e.data;if(c){if(i(c)){var f=e.modelBase||t.data.Model;c.fields&&o(c.fields,(function(e,n){i(n)&&n.field?t.isFunction(n.field)||(n=a(n,{field:s.getter(n.field)})):n={field:s.getter(n)},c.fields[e]=n}));var m=c.id;if(m){var g={};g[s.xpathToMember(m,!0)]={field:s.getter(m)},c.fields=a(g,c.fields),c.id=s.xpathToMember(m)}c=f.define(c)}s.model=c}if(l&&("string"==typeof l?(l=s.getter(l),s.total=function(e){return parseInt(l(e),10)}):"function"==typeof l&&(s.total=l)),u&&("string"==typeof u?(u=s.getter(u),s.errors=function(e){return u(e)||null}):"function"==typeof u&&(s.errors=u)),p&&("string"==typeof p?(p=s.xpathToMember(p),s.data=function(e){var t,i=s.evaluate(e,p);return i=n(i)?i:[i],s.model&&c.fields?(t=new s.model,r(i,(function(e){if(e){var n,i={};for(n in c.fields)i[n]=t._parse(n,c.fields[n].field(e));return i}}))):i}):"function"==typeof p&&(s.data=p)),"function"==typeof d){var v=s.parse;s.parse=function(e){var t=d.call(s,e);return v.call(s,t)}}"function"==typeof h&&(s.serialize=h)},total:function(e){return this.data(e).length},errors:function(e){return e?e.errors:null},serialize:function(e){return e},parseDOM:function(e){var t,i,r,o,a,s,l,c={},d=e.attributes,u=d.length;for(l=0;l<u;l++)c["@"+(s=d[l]).nodeName]=s.nodeValue;for(i=e.firstChild;i;i=i.nextSibling)3===(r=i.nodeType)||4===r?c["#text"]=i.nodeValue:1===r&&(t=this.parseDOM(i),a=c[o=i.nodeName],n(a)?a.push(t):a=undefined!==a?[a,t]:t,c[o]=a);return c},evaluate:function(e,t){for(var i,r,o,a,s,l=t.split(".");i=l.shift();)if(e=e[i],n(e)){for(r=[],t=l.join("."),s=0,o=e.length;s<o;s++)a=this.evaluate(e[s],t),a=n(a)?a:[a],r.push.apply(r,a);return r}return e},parse:function(t){var n,i,r={};return n=t.documentElement||e.parseXML(t).documentElement,i=this.parseDOM(n),r[n.nodeName]=i,r},xpathToMember:function(e,t){return e?(e=e.replace(/^\//,"").replace(/\//g,".")).indexOf("@")>=0?e.replace(/\.?(@.*)/,t?"$1":'["$1"]'):e.indexOf("text()")>=0?e.replace(/(\.?text\(\))/,t?"#text":'["#text"]'):e:""},getter:function(e){return s(this.xpathToMember(e),!0)}});e.extend(!0,t.data,{XmlDataReader:l,readers:{xml:l}})}(window.kendo.jQuery);kendo;const s={or:{concat:(e,t)=>n=>e(n)||t(n),identity:()=>!1},and:{concat:(e,t)=>n=>e(n)&&t(n),identity:()=>!0}},l={isnullorempty:e=>kendo.isBlank(e)||""===e,isnotnullorempty:e=>kendo.isPresent(e)&&""!==e,contains:(e,t)=>(e+"").indexOf(t)>=0,doesnotcontain:(e,t)=>-1===(e+"").indexOf(t),doesnotendwith:(e,t)=>(e+"").indexOf(t,(e||"").length-(t||"").length)<0,doesnotstartwith:(e,t)=>-1===(e+"").lastIndexOf(t,0),endswith:(e,t)=>(e+"").indexOf(t,(e||"").length-(t||"").length)>=0,eq:(e,t)=>e===t,gt:(e,t)=>e>t,gte:(e,t)=>e>=t,isempty:e=>""===e,isnotempty:e=>""!==e,isnotnull:e=>kendo.isPresent(e),isnull:e=>kendo.isBlank(e),lt:(e,t)=>e<t,lte:(e,t)=>e<=t,neq:(e,t)=>e!=t,startswith:(e,t)=>0===(e+"").lastIndexOf(t,0)},c=/^\/Date\((.*?)\)\/$/,d=({field:e,ignoreCase:t,value:n,operator:i="eq",accentFoldingFiltering:r})=>{e=kendo.isPresent(e)?e:e=>e,t=!kendo.isPresent(t)||t;const o=((e,t,n,i)=>{if(!kendo.isPresent(t))return e;let r=e;if(kendo.isString(t)){const o=c.exec(t);o?t=new Date(+o[1]):r=t=>{const r=e(t);return"string"==typeof r&&n?i?r.toLocaleLowerCase(i):r.toLowerCase():kendo.isNumeric(r)?r+"":r}}return kendo.isDate(t)?e=>{const t=r(e);return kendo.isDate(t)?t.getTime():t}:r})(kendo.isFunction(e)?e:kendo.getter(e,!0),n,t,r);n=((e,t,n)=>{if(null!=e&&kendo.isString(e)){const i=c.exec(e);if(i)return new Date(+i[1]).getTime();if(t)return n?e.toLocaleLowerCase(n):e.toLowerCase()}else if(null!=e&&kendo.isDate(e))return e.getTime();return e})(n,t,r);const a=kendo.isFunction(i)?i:l[i];return e=>a(o(e),n,t)},u=e=>{const t=e.accentFoldingFiltering,n=s[e.logic||"and"];return e.filters.filter(kendo.isPresent).map((e=>{return n=e,kendo.isPresent(n.filters)?u(h(e,t)):d(h(e,t));var n})).reduce(n.concat,n.identity)},h=(e,t)=>kendo.isPresent(t)?Object.assign(e,{accentFoldingFiltering:t}):e;!function(e,t){var n,i=e.extend,r=e.isPlainObject,o=e.isEmptyObject,a=Array.isArray,s=e.grep,l=e.ajax,c=e.each,d=e.noop,h=window.kendo,p=h.isFunction,f=h.Observable,m=h.Class,g="string",v="function",_="create",b="read",y="update",w="destroy",k="change",x="sync",C="get",S="error",T="requestStart",D="progress",A="requestEnd",M="itemsLoaded",E="itemLoad",I=[_,b,y,w],z=function(e){return e},P=h.getter,H=h.stringify,F=Math,R=[].push,L=[].join,B=[].pop,O=[].splice,V=[].shift,N=[].slice,$=[].unshift,U={}.toString,W=h.support.stableSort,j=/^\/Date\((.*?)\)\/$/,q=[],G=f.extend({init:function(e,t){var n=this;n.type=t||X,f.fn.init.call(n),n.length=e.length,n.wrapAll(e,n),n._loadPromises=[],n._loadedNodes=[]},at:function(e){return this[e]},toJSON:function(e){var t,n,i=this.length,r=new Array(i);for(t=0;t<i;t++)(n=this[t])instanceof X&&(n=n.toJSON(e)),r[t]=n;return r},parent:d,wrapAll:function(e,t){var n,i,r=this,o=function(){return r};for(t=t||[],n=0,i=e.length;n<i;n++)t[n]=r.wrap(e[n],o);return t},wrap:function(e,t){var n=this;return null!==e&&"[object Object]"===U.call(e)&&(e instanceof n.type||e instanceof te||(e=e instanceof X?e.toJSON():e,e=new n.type(e)),e.parent=t,e.bind(k,(function(t){var i=e.hasOwnProperty("hasSubgroups");n.trigger(k,{field:t.field,node:t.node,index:t.index,items:t.items||[this],action:t.node||i?t.action||"itemloaded":"itemchange"})})),e.bind(E,(function(e){n._loadPromises.push(e.promise),n._loading=!0,e.promise.done((function(){n._loadedNodes.push(e.node);var t=n._loadPromises.indexOf(e.promise);n._loadPromises.splice(t,1),n._loadPromises.length||(n._loading=!1,n.trigger(M,{collection:n,nodes:n._loadedNodes}),n._loadedNodes=[])}))}))),e},loading:function(){return this._loading},push:function(){var e,t=this.length,n=this.wrapAll(arguments);return e=R.apply(this,n),this.omitChangeEvent||this.trigger(k,{action:"add",index:t,items:n}),e},slice:N,sort:[].sort,join:L,pop:function(){var e=this.length,t=B.apply(this);return e&&this.trigger(k,{action:"remove",index:e-1,items:[t]}),t},splice:function(e,t,n){var i,r,o,a=this.wrapAll(N.call(arguments,2));if((i=O.apply(this,[e,t].concat(a))).length)for(this.omitChangeEvent||(this.trigger(k,{action:"remove",index:e,items:this.omitCache&&this.omitCache.length?i.concat(this.omitCache):i}),this.omitCache=[]),r=0,o=i.length;r<o;r++)i[r]&&i[r].children&&i[r].unbind(k);return n&&(this.omitChangeEvent||this.trigger(k,{action:"add",index:e,items:a})),i},shift:function(){var e=this.length,t=V.apply(this);return e&&this.trigger(k,{action:"remove",index:0,items:[t]}),t},unshift:function(){var e,t=this.wrapAll(arguments);return e=$.apply(this,t),this.trigger(k,{action:"add",index:0,items:t}),e},indexOf:function(e){var t,n;for(t=0,n=this.length;t<n;t++)if(this[t]===e)return t;return-1},forEach:function(e,t){for(var n=0,i=this.length,r=t||window;n<i;n++)e.call(r,this[n],n,this)},map:function(e,t){for(var n=0,i=[],r=this.length,o=t||window;n<r;n++)i[n]=e.call(o,this[n],n,this);return i},reduce:function(e){var t,n=0,i=this.length;for(2==arguments.length?t=arguments[1]:n<i&&(t=this[n++]);n<i;n++)t=e(t,this[n],n,this);return t},reduceRight:function(e){var t,n=this.length-1;for(2==arguments.length?t=arguments[1]:n>0&&(t=this[n--]);n>=0;n--)t=e(t,this[n],n,this);return t},filter:function(e,t){for(var n,i=0,r=[],o=this.length,a=t||window;i<o;i++)n=this[i],e.call(a,n,i,this)&&(r[r.length]=n);return r},find:function(e,t){for(var n,i=0,r=this.length,o=t||window;i<r;i++)if(n=this[i],e.call(o,n,i,this))return n},every:function(e,t){for(var n,i=0,r=this.length,o=t||window;i<r;i++)if(n=this[i],!e.call(o,n,i,this))return!1;return!0},some:function(e,t){for(var n,i=0,r=this.length,o=t||window;i<r;i++)if(n=this[i],e.call(o,n,i,this))return!0;return!1},remove:function(e){var t=this.indexOf(e);-1!==t&&this.splice(t,1)},empty:function(){this.splice(0,this.length)}});"undefined"!=typeof Symbol&&Symbol.iterator&&!G.prototype[Symbol.iterator]&&(G.prototype[Symbol.iterator]=[][Symbol.iterator]);var K=G.extend({init:function(e,t,n){f.fn.init.call(this),this.type=t||X,n&&(this._events=n);for(var i=0;i<e.length;i++)this[i]=e[i];this.length=i,this._parent=function(){return this}.bind(this),this._loadPromises=[],this._loadedNodes=[]},at:function(e){var t=this[e];return t instanceof this.type?t.parent=this._parent:t=this[e]=this.wrap(t,this._parent),t}});function Y(e,t,n,i){return function(r){var o,a={};for(o in r)a[o]=r[o];a.field=i?n+"."+r.field:n,t==k&&e._notifyChange&&e._notifyChange(a),e.trigger(t,a)}}function Q(e,t){var n,i,r=[],o=[];for(function(e){return"object"==typeof e&&Object.getPrototypeOf(e)===Object.getPrototypeOf({})||Object.getPrototypeOf(e)===Object.getPrototypeOf(new Date)||"object"!=typeof e}(e=e||{})||(o=Object.getOwnPropertyNames(Object.getPrototypeOf(e)).filter((e=>0!==e.indexOf("__")))),n=Object.getOwnPropertyNames(e).concat(o),i=q.filter((function(e){return n.indexOf(e)<0}));e;)Object.getOwnPropertyNames(e).forEach((function(e){-1===r.indexOf(e)&&(!t||i.indexOf(e)<0)&&r.push(e)})),e=Object.getPrototypeOf(e);return r}q=Q({},!1);var X=f.extend({init:function(e){var t,n=this,i=Q(e,!0),r=function(){return n};f.fn.init.call(this),this._handlers={},i.forEach((function(i){"object"==typeof(t=e[i])&&t&&!t.getTime&&"_"!=i.charAt(0)&&(t=n.wrap(t,i,r)),n[i]=t})),n.uid=h.guid()},shouldSerialize:function(e,t){return"object"==typeof t&&(t=t&&t[e]),this.hasOwnProperty(e)&&"_handlers"!==e&&"_events"!==e&&(t||typeof this[e]!==v)&&"uid"!==e},forEach:function(e){for(var t in this)this.shouldSerialize(t)&&e(this[t],t)},toJSON:function(e){var t,n,i={};for(n in this)this.shouldSerialize(n,e)&&(((t=this[n])instanceof X||t instanceof G)&&(t=t.toJSON(e)),i[n]=t);return i},get:function(e){var t=this;return t.trigger(C,{field:e}),"this"===e?t:h.getter(e,!0)(t)},_set:function(e,t){var n=e.indexOf(".")>=0;if(n)for(var i=e.split("."),r="";i.length>1;){r+=i.shift();var o=h.getter(r,!0)(this);if(o instanceof X)return o.set(i.join("."),t),n;r+="."}return h.setter(e)(this,t),n},set:function(e,t){var n=this,i=!1,r=e.indexOf(".")>=0,o=h.getter(e,!0)(n);return o!==t&&(o instanceof f&&this._handlers[e]&&(this._handlers[e].get&&o.unbind(C,this._handlers[e].get),o.unbind(k,this._handlers[e].change)),(i=n.trigger("set",{field:e,value:t}))||(r||(t=n.wrap(t,e,(function(){return n}))),(!n._set(e,t)||e.indexOf("(")>=0||e.indexOf("[")>=0)&&n.trigger(k,{field:e}))),i},parent:d,wrap:function(e,t,n){var i,r,o=this,a=U.call(e);if(null!=e&&("[object Object]"===a||"[object Array]"===a)){var s=e instanceof G,l=e instanceof qe;"[object Object]"!==a||l||s?("[object Array]"===a||s||l)&&(s||l||(e=new G(e)),r=Y(o,k,t,!1),e.bind(k,r),o._handlers[t]={change:r}):(e instanceof X||(e=new X(e)),i=Y(o,C,t,!0),e.bind(C,i),r=Y(o,k,t,!0),e.bind(k,r),o._handlers[t]={get:i,change:r}),e.parent=n}return e}});function Z(e,t){if(e===t)return!0;var n,i=h.type(e);if(i!==h.type(t))return!1;if("date"===i)return e.getTime()===t.getTime();if("object"!==i&&"array"!==i)return!1;for(n in e)if(!Z(e[n],t[n]))return!1;return!0}var J={number:function(e){return typeof e===g&&"null"===e.toLowerCase()?null:h.parseFloat(e)},date:function(e){return typeof e===g&&"null"===e.toLowerCase()?null:h.parseDate(e)},boolean:function(e){return typeof e===g?"null"===e.toLowerCase()?null:"true"===e.toLowerCase():null!=e?!!e:e},string:function(e){return typeof e===g&&"null"===e.toLowerCase()?null:null!=e?e+"":e},default:function(e){return e}},ee={string:"",number:0,date:new Date,boolean:!1,default:""};var te=X.extend({init:function(n){var i=this;if((!n||e.isEmptyObject(n))&&(n=e.extend({},i.defaults,n),i._initializers))for(var r=0;r<i._initializers.length;r++){var o=i._initializers[r];n[o]=i.defaults[o]()}X.fn.init.call(i,n),i.dirty=!1,i.dirtyFields={},i.idField&&(i.id=i.get(i.idField),i.id===t&&(i.id=i._defaultId))},shouldSerialize:function(e){return X.fn.shouldSerialize.call(this,e)&&"uid"!==e&&!("id"!==this.idField&&"id"===e)&&"dirty"!==e&&"dirtyFields"!==e&&"_accessors"!==e},_parse:function(e,t){var n,i=e,o=this.fields||{};return(e=o[e])||(e=function(e,t){var n,i;for(i in e){if(n=e[i],r(n)&&n.field&&n.field===t)return n;if(n===t)return n}return null}(o,i)),e&&!(n=e.parse)&&e.type&&(n=J[e.type.toLowerCase()]),n?n(t):t},_notifyChange:function(e){var t=e.action;"add"!=t&&"remove"!=t||(this.dirty=!0,this.dirtyFields[e.field]=!0)},editable:function(e){return!(e=(this.fields||{})[e])||!1!==e.editable},set:function(e,t){var n=this,i=n.dirty;n.editable(e)&&(Z(t=n._parse(e,t),n.get(e))?n.trigger("equalSet",{field:e,value:t}):(n.dirty=!0,n.dirtyFields[e]=!0,X.fn.set.call(n,e,t)&&!i&&(n.dirty=i,n.dirty||(n.dirtyFields[e]=!1))))},accept:function(e){var t,n=this,i=function(){return n};for(t in e){var r=e[t];"_"!=t.charAt(0)&&(r=n.wrap(e[t],t,i)),n._set(t,r)}n.idField&&(n.id=n.get(n.idField)),n.dirty=!1,n.dirtyFields={}},isNew:function(){return this.id===this._defaultId}});te.define=function(n,r){r===t&&(r=n,n=te);var o,a,s,l,c,d,u,h,p=i({defaults:{}},r),f={},m=p.id,v=[];if(m&&(p.idField=m),p.id&&delete p.id,m&&(p.defaults[m]=p._defaultId=""),"[object Array]"===U.call(p.fields)){for(d=0,u=p.fields.length;d<u;d++)typeof(s=p.fields[d])===g?f[s]={}:s.field&&(f[s.field]=s);p.fields=f}for(a in p.fields){l=(s=p.fields[a]).type||"default",c=null,h=a;let n=typeof s.field===g?s.field:a;s.nullable&&!s.defaultValue||"function"==typeof(c=p.defaults[h!==n?h:n]=s.defaultValue!==t?s.defaultValue:ee[l.toLowerCase()])&&v.push(n),r.id===n&&(p._defaultId=c),p.defaults[h!==n?h:n]=c,e.isPlainObject(s)?s.parse=s.parse||J[l]:s={parse:J[l]}}return v.length>0&&(p._initializers=v),(o=n.extend(p)).define=function(e){return te.define(o,e)},p.fields&&(o.fields=p.fields,o.idField=p.idField),o};var ne={selector:function(e){return p(e)?e:P(e)},compare:function(e){var t=this.selector(e);return function(e,n){return e=t(e),n=t(n),null==e&&null==n?0:null==e?-1:null==n?1:e.localeCompare?e.localeCompare(n):e>n?1:e<n?-1:0}},create:function(e){var t=e.compare||this.compare(e.field);return"desc"==e.dir?function(e,n){return t(n,e,!0)}:t},combine:function(e){return function(t,n){var i,r,o=e[0](t,n);for(i=1,r=e.length;i<r;i++)o=o||e[i](t,n);return o}}},ie=i({},ne,{asc:function(e){var t=this.selector(e);return function(e,n){var i=t(e),r=t(n);return i&&i.getTime&&r&&r.getTime&&(i=i.getTime(),r=r.getTime()),i===r?e.__position-n.__position:null==i?-1:null==r?1:i.localeCompare?i.localeCompare(r):i>r?1:-1}},desc:function(e){var t=this.selector(e);return function(e,n){var i=t(e),r=t(n);return i&&i.getTime&&r&&r.getTime&&(i=i.getTime(),r=r.getTime()),i===r?e.__position-n.__position:null==i?1:null==r?-1:r.localeCompare?r.localeCompare(i):i<r?1:-1}},create:function(e){return this[e.dir](e.field)}});n=function(e,t){var n,i=e.length,r=new Array(i);for(n=0;n<i;n++)r[n]=t(e[n],n,e);return r};var re=function(){function e(e){return"string"==typeof e&&(e=e.replace(/[\r\n]+/g,"")),JSON.stringify(e)}function t(t){return function(n,i,r,o){return i+="",r&&(n="("+n+" + '').toString()"+(o?".toLocaleLowerCase('"+o+"')":".toLowerCase()"),i=o?i.toLocaleLowerCase(o):i.toLowerCase()),t(n,e(i),r)}}function n(t,n,i,r,o){if(null!=i){if(typeof i===g){var a=j.exec(i);a?i=new Date(+a[1]):r?(i=e(o?i.toLocaleLowerCase(o):i.toLowerCase()),n="(("+n+" || '')+'')"+(o?".toLocaleLowerCase('"+o+"')":".toLowerCase()")):i=e(i)}i.getTime&&(n="("+n+"&&"+n+".getTime?"+n+".getTime():"+n+")",i=i.getTime())}return n+" "+t+" "+i}function i(e){for(var t="/^",n=!1,i=0;i<e.length;++i){var r=e.charAt(i);if(n)t+="\\"+r;else{if("~"==r){n=!0;continue}"*"==r?t+=".*":"?"==r?t+=".":".+^$()[]{}|\\/\n\r\u2028\u2029 ".indexOf(r)>=0?t+="\\"+r:t+=r}n=!1}return t+"$/"}return{quote:function(t){return t&&t.getTime?"new Date("+t.getTime()+")":e(t)},eq:function(e,t,i,r){return n("==",e,t,i,r)},neq:function(e,t,i,r){return n("!=",e,t,i,r)},gt:function(e,t,i){return n(">",e,t,i)},gte:function(e,t,i){return n(">=",e,t,i)},lt:function(e,t,i){return n("<",e,t,i)},lte:function(e,t,i){return n("<=",e,t,i)},startswith:t((function(e,t){return e+".lastIndexOf("+t+", 0) == 0"})),doesnotstartwith:t((function(e,t){return e+".lastIndexOf("+t+", 0) == -1"})),endswith:t((function(e,t){return e+".indexOf("+t+", "+e+".length - "+(t?t.length-2:0)+") >= 0"})),doesnotendwith:t((function(e,t){return e+".indexOf("+t+", "+e+".length - "+(t?t.length-2:0)+") < 0"})),contains:t((function(e,t){return e+".indexOf("+t+") >= 0"})),doesnotcontain:t((function(e,t){return e+".indexOf("+t+") == -1"})),matches:t((function(e,t){return i(t=t.substring(1,t.length-1))+".test("+e+")"})),doesnotmatch:t((function(e,t){return"!"+i(t=t.substring(1,t.length-1))+".test("+e+")"})),isempty:function(e){return e+" === ''"},isnotempty:function(e){return e+" !== ''"},isnull:function(e){return"("+e+" == null)"},isnotnull:function(e){return"("+e+" != null)"},isnullorempty:function(e){return"("+e+" === null) || ("+e+" === '')"},isnotnullorempty:function(e){return"("+e+" !== null) && ("+e+" !== '')"}}}();function oe(e){this.data=e||[]}function ae(e,n){if(e){var i=typeof e===g?{field:e,dir:n}:e,r=a(i)?i:i!==t?[i]:[];return s(r,(function(e){return!!e.dir}))}}function se(e,n){var i={};if(e)for(var r=typeof e===g?{field:e,dir:n}:e,o=a(r)?r:r!==t?[r]:[],s=0;s<o.length;s++)i[o[s].field]={dir:o[s].dir,index:s+1};return i}oe.filterExpr=function(e,n={noEval:!1}){if(n.noEval)return function(e){return u(e)}(e);var i,r,o,a,s,l,c=[],d=[],p=[],f=e.filters;for(i=0,r=f.length;i<r;i++)s=(o=f[i]).field,l=o.operator,o.filters?(o=(a=oe.filterExpr(o)).expression.replace(/__o\[(\d+)\]/g,(function(e,t){return t=+t,"__o["+(p.length+t)+"]"})).replace(/__f\[(\d+)\]/g,(function(e,t){return t=+t,"__f["+(d.length+t)+"]"})),p.push.apply(p,a.operators),d.push.apply(d,a.fields)):(typeof s===v?(a="__f["+d.length+"](d)",d.push(s)):a=h.expr(s),typeof l===v?(o="__o["+p.length+"]("+a+", "+re.quote(o.value)+")",p.push(l)):o=re[(l||"eq").toLowerCase()](a,o.value,o.ignoreCase===t||o.ignoreCase,e.accentFoldingFiltering)),c.push(o);return{expression:"("+c.join({and:" && ",or:" || "}[e.logic])+")",fields:d,operators:p}};var le={"==":"eq",equals:"eq",isequalto:"eq",equalto:"eq",equal:"eq","!=":"neq",ne:"neq",notequals:"neq",isnotequalto:"neq",notequalto:"neq",notequal:"neq","<":"lt",islessthan:"lt",lessthan:"lt",less:"lt","<=":"lte",le:"lte",islessthanorequalto:"lte",lessthanequal:"lte",">":"gt",isgreaterthan:"gt",greaterthan:"gt",greater:"gt",">=":"gte",isgreaterthanorequalto:"gte",greaterthanequal:"gte",ge:"gte",notsubstringof:"doesnotcontain",isnull:"isnull",isempty:"isempty",isnotempty:"isnotempty"};function ce(e){var t,n,i,r,o=e.filters;if(o)for(t=0,n=o.length;t<n;t++)(r=(i=o[t]).operator)&&typeof r===g&&(i.operator=le[r.toLowerCase()]||r),ce(i)}function de(e){if(e&&!o(e))return!a(e)&&e.filters||(e={logic:"and",filters:a(e)?e:[e]}),ce(e),e}function ue(e,t){return!e.logic&&!t.logic&&(e.field===t.field&&e.value===t.value&&e.operator===t.operator)}function he(e){return o(e=e||{})?{logic:"and",filters:[]}:de(e)}function pe(e,t){return t.logic||e.field>t.field?1:e.field<t.field?-1:0}function fe(e,i,r,o){var s=typeof e===g?{field:e,dir:i,compare:r,skipItemSorting:o}:e,l=a(s)?s:s!==t?[s]:[];return n(l,(function(e){return{field:e.field,dir:e.dir||"asc",aggregates:e.aggregates,compare:e.compare,skipItemSorting:e.skipItemSorting}}))}function me(e,t,n){for(var i=fe(e,t,n),r=0;r<i.length;r++)delete i[r].compare;return i}function ge(e,t){return e&&e.getTime&&t&&t.getTime?e.getTime()===t.getTime():e===t}function ve(e,t,n,i,r,o){var a,s,l,c=(t=t||[]).length;for(a=0;a<c;a++){l=(s=t[a]).aggregate;var d=s.field;e[d]=e[d]||{},o[d]=o[d]||{},o[d][l]=o[d][l]||{},e[d][l]=_e[l.toLowerCase()](e[d][l],n,h.accessor(d),i,r,o[d][l])}}oe.normalizeFilter=de,oe.compareFilters=function e(t,n){if(t=he(t),n=he(n),t.logic!==n.logic)return!1;var i,r,o=(t.filters||[]).slice(),a=(n.filters||[]).slice();if(o.length!==a.length)return!1;o=o.sort(pe),a=a.sort(pe);for(var s=0;s<o.length;s++)if(i=o[s],r=a[s],i.logic&&r.logic){if(!e(i,r))return!1}else if(!ue(i,r))return!1;return!0},oe.prototype={toArray:function(){return this.data},range:function(e,t){return new oe(this.data.slice(e,e+t))},skip:function(e){return new oe(this.data.slice(e))},take:function(e){return new oe(this.data.slice(0,e))},select:function(e){return new oe(n(this.data,e))},order:function(e,t,n){var i={dir:t};return e&&(e.compare?i.compare=e.compare:i.field=e),new oe(n?this.data.sort(ne.create(i)):this.data.slice(0).sort(ne.create(i)))},orderBy:function(e,t){return this.order(e,"asc",t)},orderByDescending:function(e,t){return this.order(e,"desc",t)},sort:function(e,t,n,i){var r,o,a=ae(e,t),s=[];if(n=n||ne,a.length){for(r=0,o=a.length;r<o;r++)s.push(n.create(a[r]));return this.orderBy({compare:n.combine(s)},i)}return this},filter:function(e){var t,n=this.data;return(e=de(e))&&0!==e.filters.length?(t=oe.filterExpr(e,{noEval:!0}),new oe(n.filter(t))):this},group:function(e,t,n){e=fe(e||[]),t=t||this.data;var i,r=new oe(this.data),o=(e,n)=>n=n||new oe(t).filter([{field:e.field,operator:"eq",value:e.value,ignoreCase:!1}]);return e.length>0&&(i=e[0],r=n&&n.groupPaging?new oe(t).groupAllData(i,t).select((function(t){var r,a=e.length>1?new oe(t.items).group(e.slice(1),o(t,r).toArray(),n).toArray():t.items;return{field:t.field,value:t.value,hasSubgroups:e.length>1,items:a,aggregates:i.aggregates&&i.aggregates.length?o(t,r).aggregate(i.aggregates):{},uid:h.guid(),itemCount:a.length,subgroupCount:a.length}})):r.groupBy(i).select((function(t){var n;return{field:t.field,value:t.value,items:e.length>1?new oe(t.items).group(e.slice(1),o(t,n).toArray()).toArray():t.items,hasSubgroups:e.length>1,aggregates:i.aggregates&&i.aggregates.length?o(t,n).aggregate(i.aggregates):{}}}))),r},groupBy:function(e){if(o(e)||!this.data.length)return new oe([]);var t,n,i,r,a=e.field,s=e.skipItemSorting?this.data:this._sortForGrouping(a,e.dir||"asc"),l=h.accessor(a),c=l.get(s[0],a),d={field:a,value:c,items:[]},u=[d];for(i=0,r=s.length;i<r;i++)t=s[i],ge(c,n=l.get(t,a))||(d={field:a,value:c=n,items:[]},u.push(d)),d.items.push(t);return new oe(u=this._sortGroups(u,e))},groupAllData:function(e,t){if(o(e)||this.data&&!this.data.length)return new oe([]);var n,i,r,a,s=e.field,l=e.skipItemSorting?t:new oe(t).sort(s,e.dir||"asc",ie).toArray(),c=h.accessor(s),d=c.get(l[0],s),u={field:s,value:d,items:[]},p=[u];for(r=0,a=l.length;r<a;r++)n=l[r],ge(d,i=c.get(n,s))||(u={field:s,value:d=i,items:[]},p.push(u)),u.items.push(n);return new oe(p=this._sortGroups(p,e))},_sortForGrouping:function(e,t){var n,i,r=this.data;if(!W){for(n=0,i=r.length;n<i;n++)r[n].__position=n;for(n=0,i=(r=new oe(r).sort(e,t,ie).toArray()).length;n<i;n++)delete r[n].__position;return r}return this.sort(e,t).toArray()},_sortGroups:function(e,t){var n=e;return t&&p(t.compare)&&(n=new oe(n).order({compare:t.compare},t.dir||"asc").toArray()),n},aggregate:function(e){var t,n,i={},r={};if(e&&e.length)for(t=0,n=this.data.length;t<n;t++)ve(i,e,this.data[t],t,n,r);return i}};var _e={sum:function(e,t,n){var i=n.get(t);return be(e)?be(i)&&(e+=i):e=i,e},count:function(e){return(e||0)+1},average:function(e,n,i,r,o,a){var s=i.get(n);return a.count===t&&(a.count=0),be(e)?be(s)&&(e+=s):e=s,be(s)&&a.count++,r==o-1&&be(e)&&(e/=a.count),e},max:function(e,t,n){var i=n.get(t);return be(e)||ye(e)||(e=i),e<i&&(be(i)||ye(i))&&(e=i),e},min:function(e,t,n){var i=n.get(t);return be(e)||ye(e)||(e=i),e>i&&(be(i)||ye(i))&&(e=i),e}};function be(e){return"number"==typeof e&&!isNaN(e)}function ye(e){return e&&e.getTime}function we(e){var t,n=e.length,i=new Array(n);for(t=0;t<n;t++)i[t]=e[t].toJSON();return i}oe.normalizeGroup=fe,oe.normalizeSort=ae,oe.process=function(e,r,s){var l,c,d=(r=r||{}).group,u=function(e){for(var t=a(e)?e:[e],n=0;n<t.length;n++)if(t[n]&&p(t[n].compare))return!0;return!1}(fe(d||[])),h=new oe(e),f=me(d||[]),m=ae(r.sort||[]),g=u?m:f.concat(m),v=r.filterCallback,_=r.filter,b=r.skip,y=r.take;return g&&s&&(h=h.sort(g,t,t,s)),_&&(h=h.filter(_),v&&(h=v(h)),c=h.toArray().length),g&&(s||(h=h.sort(g)),d&&(e=h.toArray())),u?(h=h.group(d,e,r),b===t||y===t||r.groupPaging||(h=new oe(Pe(h.toArray())).range(b,y),l=n(f,(function(e){return i({},e,{skipItemSorting:!0})})),h=h.group(l,e,r))):(b!==t&&y!==t&&(b+y>(c=h.data.length)&&r.virtual&&(b=(b-=b+y-c)<0?0:b),h=h.range(b,y)),!d||o(d)&&0===d.length||(h=h.group(d,e,r))),{total:c,data:h.toArray()}};var ke=m.extend({init:function(e){this.data=e.data},read:function(e){e.success(this.data)},update:function(e){e.success(e.data)},create:function(e){e.success(e.data)},destroy:function(e){e.success(e.data)}}),xe=m.extend({init:function(e){var t,n=this;e=n.options=i({},n.options,e),c(I,(function(t,n){typeof e[n]===g&&(e[n]={url:e[n]})})),n.cache=e.cache?Ce.create(e.cache):{find:d,add:d},t=e.parameterMap,e.submit&&(n.submit=e.submit),p(e.push)&&(n.push=e.push),n.push||(n.push=z),n.parameterMap=p(t)?t:function(e){var n={};return c(e,(function(e,i){e in t&&(e=t[e],r(e)&&(i=e.value(i),e=e.key)),n[e]=i})),n}},options:{parameterMap:z},create:function(e){return l(this.setup(e,_))},read:function(n){var i,r,o=this.cache;n=this.setup(n,b),i=n.success||d,n.error,(r=o.find(n.data))!==t?i(r):(n.success=function(e){o.add(n.data,e),i(e)},e.ajax(n))},update:function(e){return l(this.setup(e,y))},destroy:function(e){return l(this.setup(e,w))},setup:function(e,t){e=e||{};var n,r=this.options[t],o=p(r.data)?r.data(e.data):r.data;return e=i(!0,{},r,e),n=i(!0,{},o,e.data),e.data=this.parameterMap(n,t),p(e.url)&&(e.url=e.url(n)),e}}),Ce=m.extend({init:function(){this._store={}},add:function(e,n){e!==t&&(this._store[H(e)]=n)},find:function(e){return this._store[H(e)]},clear:function(){this._store={}},remove:function(e){delete this._store[H(e)]}});function Se(e,t,n,i,r){var o,a,s,l,c,d={};for(l=0,c=e.length;l<c;l++)for(a in o=e[l],t)(s=r[a])&&s!==a&&(d[s]||(d[s]=h.setter(s)),d[s](o,t[a](o)),delete o[a])}function Te(e,t,n,i,r){var o,a,s,l,c;for(l=0,c=e.length;l<c;l++)for(a in o=e[l],t)o[a]=n._parse(a,t[a](o)),(s=r[a])&&s!==a&&delete o[s]}function De(e,t,n,i,r){var o,a,s,l;for(a=0,l=e.length;a<l;a++)(s=i[(o=e[a]).field])&&s!=o.field&&(o.field=s),o.value=n._parse(o.field,o.value),o.items&&(o.hasSubgroups?De(o.items,t,n,i,r):Te(o.items,t,n,0,r))}function Ae(e,t,n,i,r,o){return function(a){return a=e(a),Me(t,n,i,r,o)(a)}}function Me(e,t,n,i,r){return function(a){return a&&!o(n)&&("[object Array]"===U.call(a)||a instanceof G||(a=[a]),t(a,n,new e,i,r)),a||[]}}Ce.create=function(e){var t={inmemory:function(){return new Ce}};return r(e)&&p(e.find)?e:!0===e?new Ce:t[e]()};var Ee=m.extend({init:function(e){var t,n,i,o,a=this;for(t in e=e||{})n=e[t],a[t]=typeof n===g?P(n):n;o=e.modelBase||te,r(a.model)&&(a.model=i=o.define(a.model));var s=a.data.bind(a);if(a._dataAccessFunction=s,a.model){var l,d,u=a.groups.bind(a),h=a.serialize.bind(a),p={},f={},m={},v={},_=!1;(i=a.model).fields&&(c(i.fields,(function(e,t){var n;l=e,r(t)&&t.field?l=t.field:typeof t===g&&(l=t),r(t)&&t.from&&(n=t.from),_=_||n&&n!==e||l!==e,d=n||l,f[e]=-1!==d.indexOf(".")?P(d,!0):P(d),m[e]=P(e),p[n||l]=e,v[e]=n||l})),!e.serialize&&_&&(a.serialize=Ae(h,i,Se,m,p,v))),a._dataAccessFunction=s,a._wrapDataAccessBase=Me(i,Te,f,p,v),a.data=Ae(s,i,Te,f,p,v),a.groups=Ae(u,i,De,f,p,v)}},errors:function(e){return e?e.errors:null},parse:z,data:z,total:function(e){return e.length},groups:z,aggregates:function(){return{}},serialize:function(e){return e}});function Ie(e,t){var n,i;if(t.items&&t.items.length)for(var r=0;r<t.items.length;r++)n=e.items[e.items.length-1],i=t.items[r],n&&i?n.hasSubgroups&&n.value==i.value?Ie(n,i):n.field&&n.value==i.value?(n.items.omitChangeEvent=!0,n.items.push.apply(n.items,i.items),n.items.omitChangeEvent=!1):(e.items.omitChangeEvent=!0,e.items.push.apply(e.items,[i]),e.items.omitChangeEvent=!1):i&&(e.items.omitChangeEvent=!0,e.items.push.apply(e.items,[i]),e.items.omitChangeEvent=!1)}function ze(e,t,n,i){for(var r,o,a=0;t.length&&i;){var s=(o=(r=t[a]).items).length;if(e&&e.field===r.field&&e.value===r.value?(e.hasSubgroups&&e.items.length?ze(e.items[e.items.length-1],r.items,n,i):(o=o.slice(n,n+i),e.items=e.items.concat(o)),t.splice(a--,1)):r.hasSubgroups&&o.length?(ze(r,o,n,i),r.items.length||t.splice(a--,1)):(o=o.slice(n,n+i),r.items=o,r.items.length||t.splice(a--,1)),0===o.length?n-=s:(n=0,i-=o.length),++a>=t.length)break}a<t.length&&t.splice(a,t.length-a)}function Pe(e,t){for(var n,i,r=[],o=(e||[]).length,a=p(t)?t:function(e,t){return e[t]},s=0;s<o;s++)if((n=a(e,s)).hasSubgroups)r=r.concat(Pe(n.items));else{i=n.items;for(var l=0;l<i.length;l++)r.push(a(i,l))}return r}function He(e){var t,n,i,r,o=[];for(t=0,n=e.length;t<n;t++){var a=e.at(t);if(a.items)if(a.hasSubgroups)o=o.concat(He(a.items));else for(i=a.items,r=0;r<i.length;r++)o.push(i.at(r))}return o}function Fe(e,t){var n,i,r;if(t)for(n=0,i=e.length;n<i;n++)(r=e.at(n)).items&&(r.hasSubgroups?Fe(r.items,t):r.items=new K(r.items,t,r.items._events))}function Re(e,t){for(var n=0;n<e.length;n++)if(e[n].hasSubgroups){if(Re(e[n].items,t))return!0}else if(t(e[n].items,e[n]))return!0}function Le(e,t,n,i){for(var r=0;r<e.length&&e[r].data!==t&&!Be(e[r].data,n,i);r++);}function Be(e,t,n){for(var i=0,r=e.length;i<r;i++){if(e[i]&&e[i].hasSubgroups)return Be(e[i].items,t,n);if(e[i]===t||e[i]===n)return e[i]=n,!0}}function Oe(e,n,i,r,o){for(var a=0,s=e.length;a<s;a++){var l=e[a];if(l&&!(l instanceof r))if(l.hasSubgroups===t||o){for(var c=0;c<n.length;c++)if(n[c]===l){e[a]=n.at(c),Le(i,n,l,e[a]);break}}else Oe(l.items,n,i,r,o)}}function Ve(e,t){return t?$e(e,(function(e){return e.uid&&e.uid==t.uid||e[t.idField]===t.id&&t.id!==t._defaultId})):-1}function Ne(e,t){return t?$e(e,(function(e){return e.uid==t.uid})):-1}function $e(e,t){var n,i;if(e){for(n=0,i=e.length;n<i;n++)if(t(e[n]))return n;return-1}}function Ue(e,t){if(e&&!o(e)){var n,i=e[t];return n=r(i)?i.from||i.field||t:e[t]||t,p(n)?t:n}return t}function We(e,t){var n,i,r={};for(var o in e)"filters"!==o&&(r[o]=e[o]);if(e.filters)for(r.filters=[],n=0,i=e.filters.length;n<i;n++)r.filters[n]=We(e.filters[n],t);else r.field=Ue(t.fields,r.field);return r}function je(e,t){var n,i,r,o,s=[];for(n=0,i=e.length;n<i;n++){for(var l in r={},o=e[n])r[l]=o[l];r.field=Ue(t.fields,r.field),r.aggregates&&a(r.aggregates)&&(r.aggregates=je(r.aggregates,t)),s.push(r)}return s}var qe=f.extend({init:function(e){var n,r=this;if(e&&(n=e.data),e=r.options=i({},r.options,e),r._map={},r._prefetch={},r._data=[],r._pristineData=[],r._ranges=[],r._view=[],r._pristineTotal=0,r._destroyed=[],r._pageSize=e.pageSize,r._page=e.page||(e.pageSize?1:t),r._sort=ae(e.sort),r._sortFields=se(e.sort),r._filter=de(e.filter),r._group=fe(e.group),r._aggregate=e.aggregate,r._total=e.total,r._groupPaging=e.groupPaging,r._groupPaging&&(r._groupsState={}),r._shouldDetachObservableParents=!0,f.fn.init.call(r),r.transport=Ge.create(e,n,r),p(r.transport.push)&&r.transport.push({pushCreate:r._pushCreate.bind(r),pushUpdate:r._pushUpdate.bind(r),pushDestroy:r._pushDestroy.bind(r)}),null!=e.offlineStorage)if("string"==typeof e.offlineStorage){var o=e.offlineStorage;r._storage={getItem:function(){return JSON.parse(localStorage.getItem(o))},setItem:function(e){localStorage.setItem(o,H(r.reader.serialize(e)))}}}else r._storage=e.offlineStorage;r.reader=new h.data.readers[e.schema.type||"json"](e.schema),r.reader.model,r._detachObservableParents(),r._data=r._observe(r._data),r._online=!0,r.bind(["push",S,k,T,x,A,D],e)},options:{data:null,schema:{modelBase:te},offlineStorage:null,serverSorting:!1,serverPaging:!1,serverFiltering:!1,serverGrouping:!1,serverAggregates:!1,batch:!1,inPlaceSort:!1},clone:function(){return this},online:function(n){return n!==t?this._online!=n&&(this._online=n,n)?this.sync():e.Deferred().resolve().promise():this._online},offlineData:function(e){return null==this.options.offlineStorage?null:e!==t?this._storage.setItem(e):this._storage.getItem()||[]},_isGrouped:function(){return(this.group()||[]).length},_isServerGrouped:function(){var e=this.group()||[];return this.options.serverGrouping&&e.length},_isServerGroupPaged:function(){return this._isServerGrouped()&&this._groupPaging},_isGroupPaged:function(){var e=this._group||[];return this._groupPaging&&e.length},_pushCreate:function(e){this._push(e,"pushCreate")},_pushUpdate:function(e){this._push(e,"pushUpdate")},_pushDestroy:function(e){this._push(e,"pushDestroy")},_push:function(e,t){var n=this._readData(e);n||(n=e),this[t](n)},_flatData:function(e,t){if(e){if(this._isServerGrouped())return He(e);if(!t)for(var n=0;n<e.length;n++)e.at(n)}return e},parent:d,get:function(e){var t,n,i=this._flatData(this._data,this.options.useRanges);for(t=0,n=i.length;t<n;t++)if(i[t].id==e)return i[t]},getByUid:function(e){return this._getByUid(e,this._data)},_getByUid:function(e,t){var n,i,r=this._flatData(t,this.options.useRanges);if(r)for(n=0,i=r.length;n<i;n++)if(r[n].uid==e)return r[n]},indexOf:function(e){return Ne(this._data,e)},at:function(e){return this._data.at(e)},data:function(e){var n=this;if(e===t){if(n._data)for(var i=0;i<n._data.length;i++)n._data.at(i);return n._data}n._detachObservableParents(),n._data=this._observe(e),n._pristineData=e.slice(0),n._storeData(),n._ranges=[],n.trigger("reset"),n._addRange(n._data),n._total=n._data.length,n._pristineTotal=n._total,n._process(n._data)},view:function(e){if(e===t)return this._view;this._view=this._observeView(e)},_observeView:function(e){var t=this;Oe(e,t._data,t._ranges,t.reader.model||X,t._isServerGrouped());var n=new K(e,t.reader.model);return n.parent=function(){return t.parent()},n},flatView:function(){return(this.group()||[]).length?He(this._view):this._view},add:function(e){return this.insert(this._data.length,e)},_createNewModel:function(e){return this.reader.model?new this.reader.model(e):e instanceof X?e:new X(e)},insert:function(e,t){return t||(t=e,e=0),t instanceof te||(t=this._createNewModel(t)),this._isServerGrouped()?this._data.splice(e,0,this._wrapInEmptyGroup(t)):this._data.splice(e,0,t),this._insertModelInRange(e,t),t},pushInsert:function(t,n){var i=this._getCurrentRangeSpan();n||(n=t,t=0),a(n)||(n=[n]);var r=[],o=this.options.autoSync;this.options.autoSync=!1;try{for(var s=0;s<n.length;s++){var l=n[s],c=this.insert(t,l);r.push(c);var d=c.toJSON();this._isServerGrouped()&&(d=this._wrapInEmptyGroup(d)),this._pristineData.push(d),i&&i.length&&e(i).last()[0].pristineData.push(d),t++}}finally{this.options.autoSync=o}r.length&&this.trigger("push",{type:"create",items:r})},pushCreate:function(e){this.pushInsert(this._data.length,e)},pushUpdate:function(e){a(e)||(e=[e]);for(var t=[],n=0;n<e.length;n++){var i=e[n],r=this._createNewModel(i),o=this.get(r.id);o?(t.push(o),o.accept(i),o.trigger(k),this._updatePristineForModel(o,i)):this.pushCreate(i)}t.length&&this.trigger("push",{type:"update",items:t})},pushDestroy:function(e){var t=this._removeItems(e);t.length&&this.trigger("push",{type:"destroy",items:t})},_removeItems:function(e,t){a(e)||(e=[e]);var n=void 0===t||t,i=[],r=this.options.autoSync;this.options.autoSync=!1;try{for(var o=0;o<e.length;o++){var s=e[o],l=this._createNewModel(s),c=!1,d=o;this._eachItem(this._data,(function(t){d!==e.length-1?(t.omitChangeEvent=!0,t.omitCache=[]):t.omitChangeEvent=!1;for(var n=0;n<t.length;n++){var r=t.at(n);if(r.id===l.id){t.omitChangeEvent&&t.omitCache.push(r),i.push(r),t.splice(n,1),c=!0;break}}})),c&&n&&(this._removePristineForModel(l),this._destroyed.pop())}}finally{this.options.autoSync=r}return i},pushMove:function(e,t){var n=this._moveItems(e,t);n.length&&this.trigger("push",{type:"update",items:n})},_moveItems:function(e,t){a(t)||(t=[t]);var n=[],i=this.options.autoSync;this.options.autoSync=!1;try{for(var r=0;r<t.length;r++){var o=t[r];this._eachItem(this._data,(function(t){for(var i=0;i<t.length;i++){var r=t.at(i);if(r.uid===o.uid){n.push(r),t.splice(e>=i?--e:e,0,t.splice(i,1)[0]),e++;break}}}))}}finally{this.options.autoSync=i}return n},remove:function(e){var t,n=this,i=n._isServerGrouped();return!i||!e.uid||e.isNew&&e.isNew()||n._pushInDestroyed(e),this._eachItem(n._data,(function(n){if(t=function(e,t){if(e){var n,i,r=e.length;for(i=0;i<r;i++)if((n=e[i]).uid&&n.uid==t.uid)return e.splice(i,1),n}}(n,e),t&&i)return!0})),this._removeModelFromRanges(e),e},destroyed:function(){return this._destroyed},created:function(){var e,t,n=[],i=this._flatData(this._data,this.options.useRanges);for(e=0,t=i.length;e<t;e++)i[e].isNew&&i[e].isNew()&&!i[e].notFetched&&n.push(i[e]);return n},updated:function(){var e,t,n=[],i=this._flatData(this._data,this.options.useRanges);for(e=0,t=i.length;e<t;e++)i[e].isNew&&!i[e].isNew()&&i[e].dirty&&n.push(i[e]);return n},sync:function(){var t=this,n=[],i=[],r=t._destroyed,o=e.Deferred().resolve().promise();if(t.online()){if(!t.reader.model)return o;n=t.created(),i=t.updated();var a=[];t.options.batch&&t.transport.submit?a=t._sendSubmit(n,i,r):(a.push.apply(a,t._send("create",n)),a.push.apply(a,t._send("update",i)),a.push.apply(a,t._send("destroy",r))),o=e.when.apply(null,a).then((function(){var e,n,i=[];for(e=0,n=arguments.length;e<n;e++)arguments[e]&&(t._accept(arguments[e]),i.push(...arguments[e].models));t._storeData(!0),t._syncEnd(),t._change({action:"sync",changedItems:i}),t.trigger(x),t._isServerGroupPaged()&&t.read()}))}else t._storeData(!0),t._syncEnd(),t._change({action:"sync"});return o},_syncEnd:d,cancelChanges:function(e){var t=this;e instanceof h.data.Model?t._cancelModel(e):(t._destroyed=[],t._detachObservableParents(),t._data=t._observe(t._pristineData),t.options.serverPaging&&(t._total=t._pristineTotal),t._ranges=[],t._addRange(t._data,0),t._changesCanceled(),t._change(),t._markOfflineUpdatesAsDirty(),t._isServerGrouped()&&t.read())},_changesCanceled:d,_markOfflineUpdatesAsDirty:function(){var e=this;null!=e.options.offlineStorage&&e._eachItem(e._data,(function(e){for(var t=0;t<e.length;t++){var n=e.at(t);"update"!=n.__state__&&"create"!=n.__state__||(n.dirty=!0)}}))},hasChanges:function(){var e,t,n=this._flatData(this._data,this.options.useRanges);if(this._destroyed.length)return!0;for(e=0,t=n.length;e<t;e++)if(n[e].isNew&&n[e].isNew()||n[e].dirty)return!0;return!1},_accept:function(t){var n,i=this,r=t.models,s=t.response,l=0,c=i._isServerGrouped(),d=i._pristineData,u=t.type;if(i.trigger(A,{response:s,type:u}),s&&!o(s)){if(s=i.reader.parse(s),i._handleCustomErrors(s))return;s=i.reader.data(s),a(s)||(s=[s])}else s=e.map(r,(function(e){return e.toJSON()}));for("destroy"===u&&(i._destroyed=[]),l=0,n=r.length;l<n;l++)"destroy"!==u?(r[l].accept(s[l]),"create"===u?d.push(c?i._wrapInEmptyGroup(r[l].toJSON()):s[l]):"update"===u&&i._updatePristineForModel(r[l],s[l])):i._removePristineForModel(r[l])},_updatePristineForModel:function(e,t){this._executeOnPristineForModel(e,(function(e,n){h.deepExtend(n[e],t)}))},_executeOnPristineForModel:function(e,t){this._eachPristineItem((function(n){var i=Ve(n,e);if(i>-1)return t(i,n),!0}))},_removePristineForModel:function(e){this._executeOnPristineForModel(e,(function(e,t){t.splice(e,1)}))},_readData:function(e){return(this._isServerGrouped()?this.reader.groups:this.reader.data).call(this.reader,e)},_eachPristineItem:function(e){var t=this,n=t.options,i=t._getCurrentRangeSpan();t._eachItem(t._pristineData,e),n.serverPaging&&n.useRanges&&c(i,(function(n,i){t._eachItem(i.pristineData,e)}))},_eachItem:function(e,t){e&&e.length&&(this._isServerGrouped()?Re(e,t):t(e))},_pristineForModel:function(e){var t,n;return this._eachPristineItem((function(i){if((n=Ve(i,e))>-1)return t=i[n],!0})),t},_cancelModel:function(e){var t=this,n=this._pristineForModel(e);this._eachItem(this._data,(function(i){var r=Ne(i,e);r>=0&&(!n||e.isNew()&&!n.__state__?(t._modelCanceled(e),i.splice(r,1),t._removeModelFromRanges(e)):(i[r].accept(n),"update"==n.__state__&&(i[r].dirty=!0)))}))},_modelCanceled:d,_submit:function(t,n){var r=this;r.trigger(T,{type:"submit"}),r.trigger(D),r.transport.submit(i({success:function(n,i){var r=e.grep(t,(function(e){return e.type==i}))[0];r&&r.resolve({response:n,models:r.models,type:i})},error:function(e,n,i){for(var o=0;o<t.length;o++)t[o].reject(e);r.error(e,n,i)}},n))},_sendSubmit:function(t,n,i){var r=this,o=[];return r.options.batch&&(t.length&&o.push(e.Deferred((function(e){e.type="create",e.models=t}))),n.length&&o.push(e.Deferred((function(e){e.type="update",e.models=n}))),i.length&&o.push(e.Deferred((function(e){e.type="destroy",e.models=i}))),r._submit(o,{data:{created:r.reader.serialize(we(t)),updated:r.reader.serialize(we(n)),destroyed:r.reader.serialize(we(i))}})),o},_promise:function(t,n,r){var o=this;return e.Deferred((function(e){o.trigger(T,{type:r}),o.trigger(D),o.transport[r].call(o.transport,i({success:function(t){e.resolve({response:t,models:n,type:r})},error:function(t,n,i){e.reject(t),o.error(t,n,i)}},t))})).promise()},_send:function(e,t){var n,i,r=this,o=[],a=r.reader.serialize(we(t));if(r.options.batch)t.length&&o.push(r._promise({data:{models:a}},t,e));else for(n=0,i=t.length;n<i;n++)o.push(r._promise({data:a[n]},[t[n]],e));return o},read:function(t){var n=this,i=n._params(t),r=e.Deferred();return n._queueRequest(i,(function(){var e=n.trigger(T,{type:"read"});e?(n._dequeueRequest(),r.resolve(e)):(n.trigger(D),n._ranges=[],n.trigger("reset"),n.online()?n.transport.read({data:i,success:function(e){n._ranges=[],n.success(e,i),r.resolve()},error:function(){var e=N.call(arguments);n.error.apply(n,e),r.reject.apply(r,e)}}):null!=n.options.offlineStorage&&(n.success(n.offlineData(),i),r.resolve()))})),r.promise()},_readAggregates:function(e){return this.reader.aggregates(e)},success:function(e){var t,n,i=this,r=i.options;if(i.trigger(A,{response:e,type:"read"}),i.online()){if(e=i.reader.parse(e),i._handleCustomErrors(e))return void i._dequeueRequest();i._total=i.reader.total(e),i._isServerGroupPaged()&&(i._serverGroupsTotal=i._total),i._pageSize>i._total&&(i._pageSize=i._total,i.options.pageSize&&i.options.pageSize>i._pageSize&&(i._pageSize=i.options.pageSize)),i._aggregate&&r.serverAggregates&&(i._aggregateResult=i._readAggregates(e)),e=i._readData(e),i._destroyed=[]}else{e=i._readData(e),t=[];var o,a={},s=i.reader.model,l=s?s.idField:"id";for(o=0;o<this._destroyed.length;o++){var c=this._destroyed[o][l];a[c]=c}for(o=0;o<e.length;o++){var d=e[o];"destroy"==d.__state__?a[d[l]]||this._pushInDestroyed(this._createNewModel(d)):t.push(d)}e=t,i._total=e.length}if(i._pristineTotal=i._total,n=i._skip&&i._data.length&&i._skip<i._data.length,i.options.endless){n&&i._pristineData.splice(i._skip,i._pristineData.length),t=e.slice(0);for(var u=0;u<t.length;u++)i._pristineData.push(t[u])}else i._pristineData=e.slice(0);if(i._detachObservableParents(),i.options.endless){i._data.unbind(k,i._changeHandler),i._isServerGrouped()&&i._data[i._data.length-1].value===e[0].value&&(Ie(i._data[i._data.length-1],e[0]),e.shift()),e=i._observe(e),n&&i._data.splice(i._skip,i._data.length);for(var h=0;h<e.length;h++)i._data.push(e[h]);i._data.bind(k,i._changeHandler)}else i._data=i._observe(e);i._markOfflineUpdatesAsDirty(),i._storeData(),i._addRange(i._data),i._process(i._data),i._dequeueRequest()},_detachObservableParents:function(){if(this._data&&this._shouldDetachObservableParents)for(var e=0;e<this._data.length;e++)this._data[e].parent&&(this._data[e].parent=d)},_storeData:function(e){var t=this._isServerGrouped(),n=this.reader.model;if(null!=this.options.offlineStorage){for(var i=function e(i){for(var r=[],o=0;o<i.length;o++){var a=i.at(o),s=a.toJSON();t&&a.items?s.items=e(a.items):(s.uid=a.uid,n&&(a.isNew()?s.__state__="create":a.dirty&&(s.__state__="update"))),r.push(s)}return r}(this._data),r=[],o=0;o<this._destroyed.length;o++){var a=this._destroyed[o].toJSON();a.__state__="destroy",r.push(a)}this.offlineData(i.concat(r)),e&&(this._pristineData=this.reader.reader?this.reader.reader._wrapDataAccessBase(i):this.reader._wrapDataAccessBase(i))}},_addRange:function(e,t){var n,i=this,r=void 0!==t?t:i._skip||0,o={data:e,pristineData:e.toJSON(),timestamp:i._timeStamp()};this._isGroupPaged()?(n=r+e.length,o.outerStart=r,o.outerEnd=n):n=r+i._flatData(e,!0).length,o.start=r,o.end=n,i._ranges.push(o),i._sortRanges(),i._isGroupPaged()&&(i._groupsFlat||(i._groupsFlat=[]),i._appendToGroupsFlat(o.data),i._updateOuterRangesLength())},_appendToGroupsFlat:function(e){for(var t=e.length,n=0;n<t;n++)this._groupsFlat.push(e[n])},_getGroupByUid:function(e){for(var t,n=this._groupsFlat.length,i=0;i<n;i++)if((t=this._groupsFlat[i]).uid===e)return t},_sortRanges:function(){this._ranges.sort((function(e,t){return e.start-t.start}))},error:function(e,t,n){this._dequeueRequest(),this.trigger(A,{}),this.trigger(S,{xhr:e,status:t,errorThrown:n})},_params:function(e){var t=this,n=i({take:t.take(),skip:t.skip(),page:t.page(),pageSize:t.pageSize(),sort:t._sort,filter:t._filter,group:t._group,aggregate:t._aggregate,groupPaging:!!t._groupPaging,isExcelExportRequest:t.options.isExcelExportRequest},e);return t.options.serverPaging||(delete n.take,delete n.skip,delete n.page,delete n.pageSize),t.options.serverGrouping?t.reader.model&&n.group&&(n.group=je(n.group,t.reader.model)):delete n.group,t.options.serverFiltering?t.reader.model&&n.filter&&(n.filter=We(n.filter,t.reader.model)):delete n.filter,t.options.serverSorting?t.reader.model&&n.sort&&(n.sort=je(n.sort,t.reader.model)):delete n.sort,t.options.serverAggregates?t.reader.model&&n.aggregate&&(n.aggregate=je(n.aggregate,t.reader.model)):delete n.aggregate,t.options.groupPaging&&t.options.serverPaging&&t.options.serverGrouping||delete n.groupPaging,t.options.isExcelExportRequest||delete n.isExcelExportRequest,n},_queueRequest:function(e,n){var i=this;i._requestInProgress?i._pending={callback:n.bind(i),options:e}:(i._requestInProgress=!0,i._pending=t,n())},_dequeueRequest:function(){var e=this;e._requestInProgress=!1,e._pending&&e._queueRequest(e._pending.options,e._pending.callback)},_handleCustomErrors:function(e){if(this.reader.errors){var t=this.reader.errors(e);if(t)return this.trigger(S,{xhr:null,status:"customerror",errorThrown:"custom error",errors:t}),!0}return!1},_shouldWrap:function(e){var t=this.reader.model;return!(!t||!e.length)&&!(e[0]instanceof t)},_observe:function(e){var t=this,n=t.reader.model;(t._shouldDetachObservableParents=!0,e instanceof G)?(t._shouldDetachObservableParents=!1,t._shouldWrap(e)&&(e.type=t.reader.model,e.wrapAll(e,e))):(e=new(t.pageSize()&&!t.options.serverPaging?K:G)(e,t.reader.model)).parent=function(){return t.parent()};return t._isServerGrouped()&&Fe(e,n),!(t._changeHandler&&t._data&&t._data instanceof G)||t.options.useRanges&&t.options.serverPaging?t._changeHandler=t._change.bind(t):t._data.unbind(k,t._changeHandler),e.bind(k,t._changeHandler)},_updateTotalForAction:function(e,t){var n=this,i=parseInt(n._total,10);be(n._total)||(i=parseInt(n._pristineTotal,10)),"add"===e?i+=t.length:"remove"===e?i-=t.length:"itemchange"===e||"sync"===e||n.options.serverPaging?"sync"===e&&(i=n._pristineTotal=parseInt(n._total,10)):i=n._pristineTotal,n._total=i},_operationsForUpdatedFields:function(){const e=this,t=e._updatedFields||[],n={};let i,r=!1;return n.sort=e._sort,n.filter=e._filter,n.group=e._group,n.aggregate=e._aggregate,i=H(n),r=t.some((e=>i.indexOf(`"field":"${e}"`)>-1)),!r},_pushInDestroyed:function(e){this._destroyed.find((function(t){return t.uid===e.uid}))||this._destroyed.push(e)},_change:function(e){let t,n,i,r=this,o=e?e.action:"";if("remove"===o)for(t=0,i=e.items.length;t<i;t++)e.items[t].isNew&&e.items[t].isNew()||r._pushInDestroyed(e.items[t]);if(e&&(n=e.items||[],e.partialUpdate=r._operationsForUpdatedFields()&&!r._preventPartialUpdate,"itemchange"===e.action&&n.some((e=>e.dirtyFields)))){let t=e.items[0],n=Object.keys(t.dirtyFields),i=n;for(const e of n)if(t[e]instanceof Object){let n=h.stringify(t[e]);if(n){let t=JSON.parse(n),r=Object.keys(t).map((t=>e+"."+t));i.push(...r)}}r._updatedFields=i}if(!r.options.autoSync||"add"!==o&&"remove"!==o&&"itemchange"!==o)r._updateTotalForAction(o,e?e.items:[]),r._process(r._data,e);else{"add"===o&&(r._preventPartialUpdate=!0);var a=function(t){"sync"===t.action&&(r._preventPartialUpdate=!1,r.unbind("change",a),r._updateTotalForAction(o,e.items))};r.first("change",a),r.sync()}},_calculateAggregates:function(e,t){t=t||{};var n=new oe(e),i=t.aggregate,r=t.filter;return r&&(n=n.filter(r)),n.aggregate(i)},_process:function(e,n){var i,r=this,o={};if(!0!==r.options.serverPaging&&(o.skip=r._skip,o.take=r._take||r._pageSize,o.skip===t&&r._page!==t&&r._pageSize!==t&&(o.skip=(r._page-1)*r._pageSize),r.options.useRanges&&(o.skip=r.currentRangeStart())),!0!==r.options.serverSorting&&(o.sort=r._sort),!0!==r.options.serverFiltering&&(o.filter=r._filter),!0!==r.options.serverGrouping&&(o.group=r._group),!0!==r.options.serverAggregates&&(o.aggregate=r._aggregate),r.options.serverGrouping&&r._clearEmptyGroups(e),o.groupPaging=r._groupPaging,i=r._isGroupPaged()&&n&&("page"===n.action||"expandGroup"===n.action||"collapseGroup"===n.action)?r._queryProcess(e,{aggregate:r._aggregate}):r._queryProcess(e,o),r._filter&&n&&"add"===n.action){var a=n.items[0],s=i.data;r._isGrouped()&&!this._isServerGrouped()&&(s=He(s)),s.find((function(e){return e.uid===a.uid}))||(i.data.splice(a.index,0,r._isGrouped()?r._wrapInEmptyGroup(a):a),i.total++)}!0!==r.options.serverAggregates&&(r._aggregateResult=r._calculateAggregates(i.dataToAggregate||e,o)),r._setView(i,o,n),r._setFilterTotal(i.total,!1),(n=n||{}).items=n.items||r._view,r.trigger(k,n)},_setView:function(e,t,n){var i=this;if(i._isGroupPaged()&&!i._isServerGrouped())if(!n||"page"!==n.action&&"expandGroup"!==n.action&&"collapseGroup"!==n.action){i._ranges=[];var r=new oe(e.data);i._addRange(i._observe(e.data)),t.skip+t.take>e.data.length&&(t.skip=Math.max(0,e.data.length-t.take)),i.view(r.range(t.skip,t.take).toArray())}else i.view(e.data),i._updateOuterRangesLength();else i.view(e.data)},_clearEmptyGroups:function(e){for(var t=e.length-1;t>=0;t--){var n=e[t];n.hasSubgroups&&this._clearEmptyGroups(n.items),!n.items||n.items.length||n.itemCount||O.apply(n.parent(),[t,1])}},_queryProcess:function(e,t){return this.options.inPlaceSort?oe.process(e,t,this.options.inPlaceSort):oe.process(e,t)},_mergeState:function(n){var i,r=this;return n!==t&&(r._pageSize=n.pageSize,r._page=n.page,r._sort=n.sort,r._filter=n.filter,r._group=n.group,r._aggregate=n.aggregate,r._skip=r._currentRangeStart=n.skip,r._take=n.take,r._skip===t&&(r._skip=r._currentRangeStart=r.skip(),n.skip=r.skip()),r._take===t&&r._pageSize!==t&&(r._take=r._pageSize,n.take=r._take),r.options.virtual&&(n.virtual=r.options.virtual),n.sort&&(r._sort=n.sort=ae(n.sort),r._sortFields=se(n.sort)),n.filter&&(r._filter=n.filter=r.options.accentFoldingFiltering&&!e.isEmptyObject(n.filter)?e.extend({},de(n.filter),{accentFoldingFiltering:r.options.accentFoldingFiltering}):de(n.filter)),n.group&&(r._group=n.group=fe(n.group)),n.aggregate&&(r._aggregate=n.aggregate=(i=n.aggregate,a(i)?i:[i]))),n},query:function(n){var i;if(this.options.serverSorting||this.options.serverPaging||this.options.serverFiltering||this.options.serverGrouping||this.options.serverAggregates||(this._data===t||0===this._data.length)&&!this._destroyed.length){if(this.options.endless){var r=n.pageSize-this.pageSize();r>0?(r=this.pageSize(),n.page=n.pageSize/r,n.pageSize=r):(n.page=1,this.options.endless=!1)}return this.read(this._mergeState(n))}var o=this.trigger(T,{type:"read"});return o||(this.trigger(D),n&&(n.groupPaging=this._groupPaging),i=this._queryProcess(this._data,this._mergeState(n)),this._setFilterTotal(i.total,!0),this._aggregateResult=this._calculateAggregates(i.dataToAggregate||this._data,n),this._setView(i,n),this.trigger(A,{type:"read"}),this.trigger(k,{items:i.data,action:n?n.action:""})),e.Deferred().resolve(o).promise()},_hasExpandedSubGroups:function(e){var t=!1,n=e.items?e.items.length:0;if(!e.hasSubgroups)return!1;for(var i=0;i<n;i++)if(this._groupsState[e.items[i].uid]){t=!0;break}return t},_findGroupedRange:function(e,t,n,i,r){for(var o,a,s,l,c,d=this,u=e.length,h=0;h<u&&(o=e[h],!(n.taken>=n.take));h++)if(d._getGroupByUid(o.uid)||d._groupsFlat.push(o),d._groupsState[o.uid]){if(d._isServerGroupPaged()){if(d._fetchGroupItems(o,n,i,r))return void(d._fetchingGroupItems=!0);if(l=(o.subgroupCount||o.itemCount)+1,c=n.skip-n.skipped,!d._hasExpandedSubGroups(o)&&c>l){n.skipped+=l;continue}}if(n.includeParents&&n.skipped<n.skip?(n.skipped++,o.excludeHeader=!0):n.includeParents&&(n.taken++,o.excludeHeader=!1),o.hasSubgroups&&o.items&&o.items.length)o.currentItems=[],i||(i=[]),i.push(o),d._findGroupedRange(o.items,o.currentItems,n,i,r),i.pop(),o.currentItems.length||n.taken>0?t.push(o):o.excludeHeader=!1;else{a=[],s=o.items.length;for(var p=0;p<s;p++)if(n.skipped<n.skip)n.skipped++;else{if(n.taken>=n.take)break;a.push(o.items[p]),n.taken++}a.length||n.taken>0?(o.currentItems=a,t.push(o)):o.excludeHeader=!1}}else{if(n.skipped<n.skip){n.skipped++;continue}t.push(o),n.taken++}},_expandedSubGroupItemsCount:function(e,t,n){var i,r,o=this,a=0,s="number"==typeof t,l=s?t:e.subgroupCount;if(!e.hasSubgroups)return a;for(var c=0;c<l&&(i=e.items[c]);c++)if(i.hasSubgroups&&o._groupsState[e.uid]?(a+=r=o._expandedSubGroupItemsCount(i,l,!0),s&&(l-=r)):!i.hasSubgroups&&o._groupsState[i.uid]&&(a+=r=i.items?i.items.length:0,s&&(l-=r)),n&&(a+=1,s&&(l-=1)),s&&a>l)return a;return a},_fetchGroupItems:function(e,t,n,i){let r,o,a,s,l=this,c=e.hasSubgroups?e.subgroupCount:e.itemCount,d=t.take,u=t.skipped,h=l.take();if(t.includeParents&&(u<t.skip?u+=1:d-=1),!e.items||e.items&&!e.items.length)return l.getGroupItems(e,t,n,i,0),!0;{if(s=this._expandedSubGroupItemsCount(e,t.skip-u),r=Math.max(t.skip-(u+s),0),r>=c)return!1;let p=Math.min(r+d,c-1);if(o=e.items[r],a=e.items[p],o.notFetched)return l.getGroupItems(e,t,n,i,r,F.round((r+h)/h)),!0;if(a.notFetched)return l.getGroupItems(e,t,n,i,F.max(F.floor((r+h)/h),0)*h,F.round((r+h)/h)),!0;if(!o.notFetched&&!a.notFetched&&function(e,t,n){for(let i=t;i<n;i++)if(e[i].notFetched)return!0;return!1}(e.items,r,p))return l.getGroupItems(e,t,n,i,r,p),!0}},getGroupItems:function(e,t,n,i,r,o){var a,s,l,c,d=this;e.items||(e.items=[]),a=d.take(),s=this._composeItemsFilter(e,n),l={page:o||1,pageSize:a,skip:r,take:a,filter:s,aggregate:d._aggregate,sort:d._sort},(c=d.findSubgroups(e))&&c.length&&(l.group=c),l.groupPaging=!0,d._queueWithTimeout(l,(function(){d.trigger(T,{type:"read"})?d._dequeueRequest():d.transport.read({data:l,success:d._groupItemsSuccessHandler(e,t.skip,d.take(),i,r),error:function(){var e=N.call(arguments);d.error.apply(d,e)}})}),100)},_queueWithTimeout:function(e,t,n){let i=this;clearTimeout(i._timeout),i._timeout=setTimeout((function(){i._queueRequest(e,t)}),n)},_groupItemsSuccessHandler:function(e,t,n,i,r){var o=this,a=o._timeStamp();i=p(i)?i:d;var s=o.options.schema&&o.options.schema.total?o.options.schema.total:"Total";return function(l){var c,d,u=te.define(o.options.schema.model);o._dequeueRequest(),o.trigger(A,{response:l,type:"read"}),d=p(s)?s(l):l[s],l=o.reader.parse(l),e.hasSubgroups?(c=o.reader.groups(l),e.subgroupCount=d):c=(c=o.reader.data(l)).map((function(e){return new u(e)})),e.items.omitChangeEvent=!0;for(var h=0;h<d;h++)h>=r&&h<r+n?e.items.splice(h,1,c[h-r]):e.items[h]||e.items.splice(h,0,{notFetched:!0});e.items.omitChangeEvent=!1,o._updateRangePristineData(e),o._fetchingGroupItems=!1,e.countAdded||(o._serverGroupsTotal+=d,e.countAdded=!0),o.range(t,n,i,"expandGroup"),(a>=o._currentRequestTimeStamp||!o._skipRequestsInProgress)&&o.trigger(k,{})}},findSubgroups:function(e){var t=this._group.map((function(e){return e.field})).indexOf(e.field);return this._group.slice(t+1,this._group.length)},_composeItemsFilter:function(e,t){var n={logic:"and",filters:[]};if(this.filter()&&n.filters.push(this.filter()),(n=i(!0,{},n)).filters.push({field:e.field,operator:"eq",value:e.value}),t)for(var r=0;r<t.length;r++)n.filters.push({field:t[r].field,operator:"eq",value:t[r].value});return n},_updateRangePristineData:function(e){for(var t,n,i,r,o,a=this,s=a._ranges,l=s.length,c=0;c<l;c++){r=(i=s[c]).data.length,o=[],t=null;for(var d=0;d<r&&(n=i.data[d],o.push(d),!(n.uid===e.uid||n.hasSubgroups&&n.items.length&&a._containsSubGroup(n,e,o)));d++)o.pop();if(o.length){for(t=s[c].pristineData;o.length>1;)t=t[o.splice(0,1)[0]].items;t[o[0]]=a._cloneGroup(e);break}}},_containsSubGroup:function(e,t,n){var i,r=e.items.length;if(e.hasSubgroups&&r)for(var o=0;o<r;o++){if(i=e.items[o],n.push(o),i.uid===t.uid||i.hasSubgroups&&i.items.length&&this._containsSubGroup(i,t,n))return!0;n.pop()}},_cloneGroup:function(e){var t=this;return(e="function"==typeof e.toJSON?e.toJSON():e).items&&e.items.length&&(e.items=e.items.map((function(e){return t._cloneGroup(e)}))),e},_setFilterTotal:function(e,n){var i=this;i.options.serverFiltering||(e!==t?i._total=e:n&&(i._total=i._data.length))},fetch:function(e){var t=this;return this._query().done((function(n){!0!==n&&p(e)&&e.call(t)}))},_query:function(e){var t=this;return t.query(i({},{page:t.page(),pageSize:t.pageSize(),sort:t.sort(),filter:t.filter(),group:t.group(),aggregate:t.aggregate()},e))},next:function(e){var t=this,n=t.page(),i=t.total();if(e=e||{},n&&!(i&&n+1>t.totalPages()))return t._skip=t._currentRangeStart=n*t.take(),n+=1,e.page=n,t._query(e),n},prev:function(e){var t=this,n=t.page();if(e=e||{},n&&1!==n)return t._skip=t._currentRangeStart=t._skip-t.take(),n-=1,e.page=n,t._query(e),n},page:function(e){var n,i=this;if(e!==t){e=F.max(F.min(F.max(e,1),i.totalPages()),1);var r=i.take();return i._isGroupPaged()?(e-=1,void i.range(e*r,r,null,"page")):void i._query(i._pageableQueryOptions({page:e}))}return(n=i.skip())!==t?F.round((n||0)/(i.take()||1))+1:t},pageSize:function(e){var n=this;if(e===t)return n.take();n._query(n._pageableQueryOptions({pageSize:e,page:1}))},sort:function(e){var n=this;return e!==t?(n.trigger("sort"),void n._query({sort:e})):n._sort},filter:function(e){var n=this;if(e===t)return n._filter;n.trigger("reset"),n._query({filter:e,page:1})},group:function(e){var n=this,i={group:e};if(n._groupPaging&&(e===t||e&&e.length||(n._ranges=[]),i.page=1),e===t)return n._group;n._query(i)},getGroupsFlat:function(e){var t,n,i=[];for(t=0,n=e.length;t<n;t++){var r=e[t];r.hasSubgroups&&(i=i.concat(this.getGroupsFlat(r.items))),i.push(r)}return i},total:function(){return parseInt(this._total||0,10)},groupsTotal:function(e){var t=this;return t._group.length?t._isServerGrouped()?(t._serverGroupsTotal||(t._serverGroupsTotal=t.total()),t._serverGroupsTotal):t._calculateGroupsTotal(t._ranges.length?t._ranges[0].data:[],e):t.total()},_calculateGroupsTotal:function(e,t,n,i){var r,o,a=this;if(n=n||"items",a._group.length&&e){r=0,o=e.length;for(var s=0;s<o;s++)r+=a.groupCount(e[s],t,n,i);return a._groupsTotal=r,r}return a._groupsTotal=a._data.length,a._groupsTotal},groupCount:function(e,t,n,i){var r=this,o=0;return e.hasSubgroups&&r._groupsState[e.uid]?((t&&!e.excludeHeader||i)&&(o+=1),e[n].forEach((function(e){o+=r.groupCount(e,t,n,i)}))):r._groupsState[e.uid]?((t&&!e.excludeHeader||i)&&o++,o+=e[n]?e[n].length:0):o++,o},countGroupRange:function(e){for(var t=0,n=e.length,i=0;i<n;i++)t+=this.groupCount(e[i],!0);return t},aggregate:function(e){if(e===t)return this._aggregate;this._query({aggregate:e})},aggregates:function(){var e=this._aggregateResult;return o(e)&&(e=this._emptyAggregates(this.aggregate())),e},_emptyAggregates:function(e){var t={};if(!o(e)){var n={};a(e)||(e=[e]);for(var i=0;i<e.length;i++)n[e[i].aggregate]=0,t[e[i].field]=n}return t},_pageableQueryOptions:function(e){return e},_wrapInEmptyGroup:function(e){var t,n,i,r=this.group();for(i=r.length-1,0;i>=0;i--)n=r[i],t={value:e.get?e.get(n.field):e[n.field],field:n.field,items:t?[t]:[e],hasSubgroups:!!t,aggregates:this._emptyAggregates(n.aggregates)};return t},totalPages:function(){var e=this,t=e.pageSize()||e.total(),n=e._isGroupPaged()?e.groupsTotal(!0):e.total();return F.ceil((n||0)/t)},inRange:function(e,t){var n=this,i=F.min(e+t,n.total());return!n.options.serverPaging&&n._data.length>0||n._findRange(e,i).length>0},lastRange:function(){var e=this._ranges;return e[e.length-1]||{start:0,end:0,data:[]}},firstItemUid:function(){var e=this._ranges;return e.length&&e[0].data.length&&e[0].data[0].uid},enableRequestsInProgress:function(){this._skipRequestsInProgress=!1},_timeStamp:function(){return(new Date).getTime()},range:function(e,n,i,r){this._currentRequestTimeStamp=this._timeStamp(),this._skipRequestsInProgress=!0;var o=this._isGroupPaged()?this.groupsTotal(!0):this.total();"expandGroup"!==r&&"collapseGroup"!==r||this._updateOuterRangesLength(),e=F.min(e||0,o),i=p(i)?i:d;var a,s=this,l=F.max(F.floor(e/n),0)*n,c=F.min(l+n,o);if(((a=s._findRange(e,F.min(e+n,o),i)).length||0===o)&&!s._fetchingGroupItems)return s._processRangeData(a,e,n,s._originalPageSkip||l,s._originalSize||c,{action:r}),s._originalPageSkip=null,s._originalSize=null,void i();s._isGroupPaged()&&(s._originalPageSkip=l,s._originalSize=c,l=F.max(F.floor(s._adjustPageSkip(e,n)/n),0)*n,c=F.min(l+n,o)),n===t||s._fetchingGroupItems||(s._isGroupPaged()&&!s._groupRangeExists(l,n)||!s._rangeExists(l,c)?s.prefetch(l,n,(function(){e>l&&c<s.total()&&!s._rangeExists(c,F.min(c+n,s.total()))?s.prefetch(c,n,(function(){s.range(e,n,i)})):s.range(e,n,i)})):l<e&&s.prefetch(c,n,(function(){s.range(e,n,i)})))},_findRange:function(e,n,i){var r,o,a,s,l,c,d,u,h,p,f,m,g=this,v=g._ranges,_=[],b=g.options,y=b.serverSorting||b.serverPaging||b.serverFiltering||b.serverGrouping||b.serverAggregates,w={take:n-e,skip:e,skipped:0,taken:0,includeParents:!0},k=g._isGroupPaged(),x=k?"outerStart":"start",C=k?"outerEnd":"end";for(o=0,f=v.length;o<f;o++){if(r=v[o],k){if(r.outerStart>=n)return[];if(e>r.outerEnd){w.skipped+=r.outerEnd-(m||0),m=r.outerEnd;continue}if(void 0!==m&&m!=r.outerStart&&(w.skipped+=r.outerStart-m),w.skipped>w.skip)return[];for(void 0===m&&e>0&&r.start>0&&(w.skipped=r.outerStart),a=o;;){if(this._findGroupedRange(r.data,_,w,null,i),g._calculateGroupsTotal(_,!0,"currentItems")>=w.take)return _;if(g._fetchingGroupItems)return[];if(!v[++a]||v[a].outerStart!==r.outerEnd)break;r=v[a]}}else if(e>=r[x]&&e<=r[C]){for(p=0,a=o;a<f;a++)if(r=v[a],(h=g._flatData(r.data,!0)).length&&e+p>=r.start){if(c=r.data,d=r.end,!y){if(b.inPlaceSort)u=g._queryProcess(r.data,{filter:g.filter()});else{var S=me(g.group()||[]).concat(ae(g.sort()||[]));u=g._queryProcess(r.data,{sort:S,filter:g.filter()})}h=c=u.data,u.total!==t&&(d=u.total)}if(s=0,e+p>r.start&&(s=e+p-r.start),l=h.length,d>n&&(l-=d-n),p+=l-s,_=g._mergeGroups(_,c,s,l),n<=r.end&&p==n-e)return _}break}m=r.outerEnd}return[]},_getRangesMismatch:function(e){for(var t=this._ranges,n=0,i=0;;){var r=t[i];if(!r||r.outerStart>e)break;r.outerEnd!=r.end&&(n=r.outerEnd-r.end),i++}return n},_mergeGroups:function(e,t,n,i){if(this._isServerGrouped()){var r,o=t.toJSON();return e.length&&(r=e[e.length-1]),ze(r,o,n,i),e.concat(o)}return e.concat(t.slice(n,i))},_processRangeData:function(e,n,i,r,o,a){var s=this;s._pending=t,s._skip=n>s.skip()&&!s._omitPrefetch?F.min(o,(s.totalPages()-1)*s.take()):r,s._currentRangeStart=n,s._take=i;var l=s.options.serverPaging,c=s.options.serverSorting,d=s.options.serverFiltering,u=s.options.serverAggregates;try{s.options.serverPaging=!0,s._isServerGrouped()||s.group()&&s.group().length||(s.options.serverSorting=!0),s.options.serverFiltering=!0,s.options.serverPaging=!0,s.options.serverAggregates=!0,l&&(s._detachObservableParents(),s._data=e=s._observe(e)),s._process(e,a)}finally{s.options.serverPaging=l,s.options.serverSorting=c,s.options.serverFiltering=d,s.options.serverAggregates=u}},skip:function(){var e=this;return e._skip===t?e._page!==t?(e._page-1)*(e.take()||1):t:e._skip},currentRangeStart:function(){return this._currentRangeStart||0},take:function(){return this._take||this._pageSize},_prefetchSuccessHandler:function(e,t,n,i){var r=this,o=r._timeStamp();return function(a){var s,l,c,d=!1,u={start:e,end:t,data:[],timestamp:r._timeStamp()};if(r._dequeueRequest(),r.trigger(A,{response:a,type:"read"}),a=r.reader.parse(a),(c=r._readData(a)).length){for(s=0,l=r._ranges.length;s<l;s++)if(r._ranges[s].start===e){d=!0,u=r._ranges[s],r._isGroupPaged()||(u.pristineData=c,u.data=r._observe(c),u.end=u.start+r._flatData(u.data,!0).length,r._sortRanges());break}d||r._addRange(r._observe(c),e)}r._total=r.reader.total(a),(i||o>=r._currentRequestTimeStamp||!r._skipRequestsInProgress)&&(n&&c.length?n():r.trigger(k,{}))}},prefetch:function(e,t,n){var i=this,r=F.min(e+t,i.total()),o={take:t,skip:e,page:e/t+1,pageSize:t,sort:i._sort,filter:i._filter,group:i._group,aggregate:i._aggregate};i._isGroupPaged()&&!i._isServerGrouped()&&i._groupRangeExists(e,r)?n&&n():i._isServerGroupPaged()&&!i._groupRangeExists(e,r)||!i._rangeExists(e,r)?i._queueWithTimeout(o,(function(){i.trigger(T,{type:"read"})?i._dequeueRequest():(i._omitPrefetch&&i.trigger(D),i.transport.read({data:i._params(o),success:i._prefetchSuccessHandler(e,r,n),error:function(){var e=N.call(arguments);i.error.apply(i,e)}}))}),100):n&&n()},_multiplePrefetch:function(e,t,n){var i=this,r=F.min(e+t,i.total()),o={take:t,skip:e,page:e/t+1,pageSize:t,sort:i._sort,filter:i._filter,group:i._group,aggregate:i._aggregate};i._rangeExists(e,r)?n&&n():i.trigger(T,{type:"read"})||i.transport.read({data:i._params(o),success:i._prefetchSuccessHandler(e,r,n,!0)})},_adjustPageSkip:function(e,t){var n,i,r=this,o=r._getPrevRange(e),a=r.total();if(o){if(!(i=r._getRangesMismatch(e)))return e;e-=i}if((n=F.max(F.floor(e/t),0)*t)>a)for(;!((n-=t)<a););return n},_getNextRange:function(e){var t,n,i=this._ranges;for(t=0,n=i.length;t<n;t++)if(i[t].start<=e&&i[t].end>=e)return i[t]},_getPrevRange:function(e){var t,n,i=this._ranges;for(t=i.length-1;t>=0;t--)if(i[t].outerStart<=e){n=i[t];break}return n},_rangeExists:function(e,t){var n,i,r=this._ranges;for(n=0,i=r.length;n<i;n++)if(r[n].start<=e&&r[n].end>=t)return!0;return!1},_groupRangeExists:function(e,t){var n,i,r=this,o=r._ranges,a=0,s=r.groupsTotal(!0);for(t>s&&!r._isServerGrouped()&&(t=s),n=0,i=o.length;n<i;n++){var l=o[n];l.outerStart<=e&&l.outerEnd>=e?a+=l.outerEnd-e:l.outerStart<=t&&l.outerEnd>=t&&(a+=t-l.outerStart)}return a>=t-e},_getCurrentRangeSpan:function(){var e,t,n=this,i=n._ranges,r=n.currentRangeStart(),o=r+(n.take()||0),a=[],s=i.length;for(t=0;t<s;t++)((e=i[t]).start<=r&&e.end>=r||e.start>=r&&e.start<=o)&&a.push(e);return a},_removeModelFromRanges:function(e){for(var t,n=0,i=this._ranges.length;n<i;n++)t=this._ranges[n],this._removeModelFromRange(t,e);this._updateRangesLength()},_removeModelFromRange:function(e,t){this._eachItem(e.data,(function(e){if(e)for(var n=0;n<e.length;n++){var i=e[n];if(i.uid&&i.uid==t.uid){[].splice.call(e,n,1);break}}}))},_insertModelInRange:function(e,t){var n,i,r=this,o=r._ranges||[],a=o.length;for(i=0;i<a;i++)if((n=o[i]).start<=e&&n.end>=e){r._getByUid(t.uid,n.data)||(r._isServerGrouped()?n.data.splice(e,0,r._wrapInEmptyGroup(t)):n.data.splice(e,0,t));break}r._updateRangesLength()},_updateRangesLength:function(){var e,t,n=this,i=n._ranges||[],r=i.length,o=!1,a=0,s=0;for(t=0;t<r;t++)e=i[t],s=(n._isGroupPaged()?e.data.length:n._flatData(e.data,!0).length)-F.abs(e.end-e.start),o||0===s?o&&(e.start+=a,e.end+=a):(o=!0,a=s,e.end+=a)},_updateOuterRangesLength:function(){var e,t,n,i,r=this,o=r._ranges||[],a=o.length,s=0;for(t=0;t<a;t++)e=o[t],i=r._isGroupPaged()?r._calculateGroupsTotal(e.data,!0,"items",!0):r._flatData(e.data,!0).length,n?(n.end!=e.start&&(s=e.start-n.end),e.outerStart=n.outerEnd+s,s=0):e.outerStart=e.start,e.outerEnd=e.outerStart+i,n=e}}),Ge={};Ge.create=function(t,n,o){var a,s=t.transport?e.extend({},t.transport):null;return s?(s.read=typeof s.read===g?{url:s.read}:s.read,"jsdo"===t.type&&(s.dataSource=o),t.type&&(h.data.transports=h.data.transports||{},h.data.schemas=h.data.schemas||{},h.data.transports[t.type]?r(h.data.transports[t.type])?s=i(!0,{},h.data.transports[t.type],s):a=new h.data.transports[t.type](i(s,{data:n})):h.logToConsole("Unknown DataSource transport type '"+t.type+"'.\nVerify that registration scripts for this type are included after Kendo UI on the page.","warn"),t.schema=i(!0,{},h.data.schemas[t.type],t.schema)),a||(a=p(s.read)?s:new xe(s))):a=new ke({data:t.data||[]}),a},qe.create=function(n){(a(n)||n instanceof G)&&(n={data:n});var r,s,l,c=n||{},d=c.data,u=c.fields,p=c.table,f=c.select,m={};if(d||!u||c.transport||(p?d=function(t,n){var i,r,o,a,s,l,c,d=e(t)[0].tBodies[0],u=d?d.rows:[],h=n.length,p=[];for(i=0,r=u.length;i<r;i++){for(s={},c=!0,a=u[i].cells,o=0;o<h;o++)"th"!==(l=a[o]).nodeName.toLowerCase()&&(c=!1,s[n[o].field]=l.innerHTML);c||p.push(s)}return p}(p,u):f&&(d=function(t,n){t=e(t)[0];var i,r,o,a,s,l,c=t.options,d=n[0],u=n[1],h=[];for(i=0,r=c.length;i<r;i++)s={},(o=(a=c[i]).parentNode)===t&&(o=null),a.disabled||o&&o.disabled||(o&&(s.optgroup=o.label),s[d.field]=a.text,l=(l=a.attributes.value)&&l.specified?a.value:a.text,s[u.field]=l,h.push(s));return h}(f,u),c.group===t&&d[0]&&d[0].optgroup!==t&&(c.group="optgroup"))),h.data.Model&&u&&(!c.schema||!c.schema.model)){for(r=0,s=u.length;r<s;r++)(l=u[r]).type&&(m[l.field]=l);o(m)||(c.schema=i(!0,c.schema,{model:{fields:m}}))}return c.data=d,f=null,c.select=null,p=null,c.table=null,c instanceof qe?c:new qe(c)};var Ke=te.define({idField:"id",init:function(e){var t=this,n=t.hasChildren||e&&e.hasChildren,r="items",o={};if(h.data.Model.fn.init.call(t,e),typeof t.children===g&&(r=t.children),o={schema:{data:r,model:{hasChildren:n,id:t.idField,fields:t.fields}}},typeof t.children!==g&&i(o,t.children),o.data=e,n||(n=o.schema.data),typeof n===g&&(n=h.getter(n)),p(n)){var a=n.call(t,t);a&&0===a.length?t.hasChildren=!1:t.hasChildren=!!a}t._childrenOptions=o,t.hasChildren&&t._initChildren(),t._loaded=!(!e||!e._loaded)},_initChildren:function(){var e,t,n,i=this;i.children instanceof Qe||(t=(e=i.children=new Qe(i._childrenOptions)).transport,n=t.parameterMap,t.parameterMap=function(e,t){return e[i.idField||"id"]=i.id,n&&(e=n.call(i,e,t)),e},e.parent=function(){return i},e.bind(k,(function(e){e.node=e.node||i,i.trigger(k,e)})),e.bind(S,(function(e){var t=i.parent();t&&(e.node=e.node||i,t.trigger(S,e))})),e.bind(M,(function(e){var t=i.parent();t&&t.trigger(M,e)})),i._updateChildrenField())},append:function(e){this._initChildren(),this.loaded(!0),this.children.add(e)},hasChildren:!1,level:function(){for(var e=this.parentNode(),t=0;e&&e.parentNode;)t++,e=e.parentNode?e.parentNode():null;return t},_updateChildrenField:function(){this[this._childrenOptions.schema.data||"items"]=this.children.data()},_childrenLoaded:function(){this._loaded=!0,this._updateChildrenField()},load:function(){var n,i,r={},o="_query";return this.hasChildren?(this._initChildren(),n=this.children,r[this.idField||"id"]=this.id,this._loaded||(n._data=t,o="read"),n.one(k,this._childrenLoaded.bind(this)),this._matchFilter&&(r.filter={field:"_matchFilter",operator:"eq",value:!0}),i=n[o](r),this._loaded||this.trigger(E,{promise:i,node:this})):this.loaded(!0),i||e.Deferred().resolve().promise()},parentNode:function(){return this.parent().parent()},loaded:function(e){if(e===t)return this._loaded;this._loaded=e},shouldSerialize:function(e){return te.fn.shouldSerialize.call(this,e)&&"children"!==e&&"_loaded"!==e&&"hasChildren"!==e&&"_childrenOptions"!==e}});function Ye(e){return function(){var t=this._data,n=qe.fn[e].apply(this,N.call(arguments));return this._data!=t&&this._attachBubbleHandlers(),n}}var Qe=qe.extend({init:function(e){var t=Ke.define({children:e});e.filter&&!e.serverFiltering&&(this._hierarchicalFilter=e.filter,e.filter=null),qe.fn.init.call(this,i(!0,{},{schema:{modelBase:t,model:t}},e)),this._attachBubbleHandlers()},_attachBubbleHandlers:function(){var e=this;e._data.bind(S,(function(t){e.trigger(S,t)})),e._data.bind(M,(function(t){e.trigger(M,t)}))},loading:function(){return!!this._data&&(this._data.loading()||this._childrenLoading())},_childrenLoading:function(){var e=!1;return this._data.forEach((function(t){t.hasChildren&&t.children.loading()&&(e=!0)})),e},read:function(e){var t=qe.fn.read.call(this,e);return this._hierarchicalFilter&&(this._data&&this._data.length>0?this.filter(this._hierarchicalFilter):(this.options.filter=this._hierarchicalFilter,this._filter=de(this.options.filter),this._hierarchicalFilter=null)),t},remove:function(e){var t,n=e.parentNode(),i=this;return n&&n._initChildren&&(i=n.children),t=qe.fn.remove.call(i,e),n&&!i.data().length&&(n.hasChildren=!1),t},success:Ye("success"),data:Ye("data"),insert:function(e,t){var n=this.parent();return n&&n._initChildren&&(n.hasChildren=!0,n._initChildren()),qe.fn.insert.call(this,e,t)},filter:function(e){if(e===t)return this._filter;!this.options.serverFiltering&&this._markHierarchicalQuery(e)&&(e={logic:"or",filters:[e,{field:"_matchFilter",operator:"equals",value:!0}]}),this.trigger("reset"),this._query({filter:e,page:1})},_markHierarchicalQuery:function(t){var n,i=this.options.accentFoldingFiltering;return(t=i?e.extend({},de(t),{accentFoldingFiltering:i}):de(t))&&0!==t.filters.length?(n=oe.filterExpr(t,{noEval:!0}),this._updateHierarchicalFilter(n),!0):(this._updateHierarchicalFilter((function(){return!0})),!1)},_updateHierarchicalFilter:function(e){for(var t,n=this._data,i=!1,r=0;r<n.length;r++)(t=n[r]).hasChildren?(t._matchFilter=t.children._updateHierarchicalFilter(e),t._matchFilter||(t._matchFilter=e(t))):t._matchFilter=e(t),t._matchFilter&&(i=!0);return i},_find:function(e,t){var n,i,r,o,a=this._data;if(a){if(r=qe.fn[e].call(this,t))return r;for(n=0,i=(a=this._flatData(this._data)).length;n<i;n++)if((o=a[n].children)instanceof Qe&&(r=o[e](t)))return r}},get:function(e){return this._find("get",e)},getByUid:function(e){return this._find("getByUid",e)}});function Xe(t,n){var i,r,o,a,s,l,c,d,u=e(t).children(),p=[],f=n[0].field,m=n[1]&&n[1].field,g=n[2]&&n[2].field,v=n[3]&&n[3].field;function _(e,t){return e.filter(t).add(e.find(t))}for(i=0,r=u.length;i<r;i++)o={_loaded:!0},l=(a=u.eq(i))[0].firstChild,t=(d=a.children()).filter("ul"),d=d.filter(":not(ul)"),(s=a.attr("data-id"))&&(o.id=s),l&&(o[f]=3==l.nodeType?l.nodeValue:d.text()),m&&(o[m]=_(d,"a").attr("href")),v&&(o[v]=_(d,"img").attr("src")),g&&(c=_(d,".k-sprite").prop("className"),o[g]=c&&h.trim(c.replace("k-sprite",""))),t.length&&(o.items=Xe(t.eq(0),n)),"true"==a.attr("data-hasChildren")&&(o.hasChildren=!0),p.push(o);return p}Qe.create=function(e){var t=(e=e&&e.push?{data:e}:e)||{},n=t.data,i=t.fields,r=t.list;return n&&n._dataSource?n._dataSource:(n||!i||t.transport||r&&(n=Xe(r,i)),t.data=n,t instanceof Qe?t:new Qe(t))};var Ze=h.Observable.extend({init:function(e,t,n){h.Observable.fn.init.call(this),this._prefetching=!1,this.dataSource=e,this.prefetch=!n;var i=this;e.bind("change",(function(){i._change()})),e.bind("reset",(function(){i._reset()})),this._syncWithDataSource(),this.setViewSize(t)},setViewSize:function(e){this.viewSize=e,this._recalculate()},at:function(e){var t=this.pageSize,n=!0;return e>=this.total()?(this.trigger("endreached",{index:e}),null):this.useRanges?this.useRanges?((e<this.dataOffset||e>=this.skip+t)&&(n=this.range(Math.floor(e/t)*t)),e===this.prefetchThreshold&&this._prefetch(),e===this.midPageThreshold?this.range(this.nextMidRange,!0):e===this.nextPageThreshold?this.range(this.nextFullRange):e===this.pullBackThreshold&&(this.offset===this.skip?this.range(this.previousMidRange):this.range(this.previousFullRange)),n?this.dataSource.at(e-this.dataOffset):(this.trigger("endreached",{index:e}),null)):void 0:this.dataSource.view()[e]},indexOf:function(e){return this.dataSource.data().indexOf(e)+this.dataOffset},total:function(){return parseInt(this.dataSource.total(),10)},next:function(){var e=this,t=e.pageSize,n=e.skip-e.viewSize+t,i=F.max(F.floor(n/t),0)*t;this.offset=n,this.dataSource.prefetch(i,t,(function(){e._goToRange(n,!0)}))},range:function(e,t){if(this.offset===e)return!0;var n=this,i=this.pageSize,r=F.max(F.floor(e/i),0)*i,o=this.dataSource;return t&&(r+=i),o.inRange(e,i)?(this.offset=e,this._recalculate(),this._goToRange(e),!0):!this.prefetch||(o.prefetch(r,i,(function(){n.offset=e,n._recalculate(),n._goToRange(e,!0)})),!1)},syncDataSource:function(){var e=this.offset;this.offset=null,this.range(e)},destroy:function(){this.unbind()},_prefetch:function(){var e=this,t=this.pageSize,n=this.skip+t,i=this.dataSource;i.inRange(n,t)||this._prefetching||!this.prefetch||(this._prefetching=!0,this.trigger("prefetching",{skip:n,take:t}),i.prefetch(n,t,(function(){e._prefetching=!1,e.trigger("prefetched",{skip:n,take:t})})))},_goToRange:function(e,t){this.offset===e&&(this.dataOffset=e,this._expanding=t,this.dataSource.range(e,this.pageSize),this.dataSource.enableRequestsInProgress())},_reset:function(){this._syncPending=!0},_change:function(){var e=this.dataSource;this.length=this.useRanges?e.lastRange().end:e.view().length,this._syncPending&&(this._syncWithDataSource(),this._recalculate(),this._syncPending=!1,this.trigger("reset",{offset:this.offset})),this.trigger("resize"),this._expanding&&this.trigger("expand"),delete this._expanding},_syncWithDataSource:function(){var e=this.dataSource;this._firstItemUid=e.firstItemUid(),this.dataOffset=this.offset=e.skip()||0,this.pageSize=e.pageSize(),this.useRanges=e.options.serverPaging},_recalculate:function(){var e=this.pageSize,t=this.offset,n=this.viewSize,i=Math.ceil(t/e)*e;this.skip=i,this.midPageThreshold=i+e-1,this.nextPageThreshold=i+n-1,this.prefetchThreshold=i+Math.floor(e/3*2),this.pullBackThreshold=this.offset-1,this.nextMidRange=i+e-n,this.nextFullRange=i,this.previousMidRange=t-n,this.previousFullRange=i-e}}),Je=h.Observable.extend({init:function(e,t){var n=this;h.Observable.fn.init.call(n),this.dataSource=e,this.batchSize=t,this._total=0,this.buffer=new Ze(e,3*t),this.buffer.bind({endreached:function(e){n.trigger("endreached",{index:e.index})},prefetching:function(e){n.trigger("prefetching",{skip:e.skip,take:e.take})},prefetched:function(e){n.trigger("prefetched",{skip:e.skip,take:e.take})},reset:function(){n._total=0,n.trigger("reset")},resize:function(){n._total=Math.ceil(this.length/n.batchSize),n.trigger("resize",{total:n.total(),offset:this.offset})}})},syncDataSource:function(){this.buffer.syncDataSource()},at:function(e){var t,n=this.buffer,i=e*this.batchSize,r=this.batchSize,o=[];n.offset>i&&n.at(n.offset-1);for(var a=0;a<r&&null!==(t=n.at(i+a));a++)o.push(t);return o},total:function(){return this._total},destroy:function(){this.buffer.destroy(),this.unbind()}});i(!0,h.data,{readers:{json:Ee},Query:oe,DataSource:qe,HierarchicalDataSource:Qe,Node:Ke,Comparer:ne,ObservableObject:X,ObservableArray:G,LazyObservableArray:K,LocalTransport:ke,RemoteTransport:xe,Cache:Ce,DataReader:Ee,Model:te,Buffer:Ze,BatchBuffer:Je})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.htmlEncode,r=n.Observable,o=n.data.ObservableObject,a=n.data.ObservableArray,s={}.toString,l={},c=n.Class,d="value",u="source",h="events",p="checked",f=!0,m="change";!function(){var e=document.createElement("a");try{delete e.test}catch(e){f=!1}}();var g=r.extend({init:function(e,t){var n=this;r.fn.init.call(n),n.source=e[0],n.parents=e,n.path=t,n.dependencies={},n.dependencies[t]=!0,n.observable=n.source instanceof r,n._access=function(e){n.dependencies[e.field]=!0},n.observable&&(n._change=function(e){n.change(e)},n.source.bind(m,n._change))},_parents:function(){var t=this.parents,n=this.get();if(n&&"function"==typeof n.parent){var i=n.parent();e.inArray(i,t)<0&&(t=[i].concat(t))}return t},change:function(e){var t,n,i=e.field,r=this;if("this"===r.path)r.trigger(m,e);else for(t in r.dependencies)if(0===t.indexOf(i)&&(!(n=t.charAt(i.length))||"."===n||"["===n)){r.trigger(m,e);break}},start:function(e){e.bind("get",this._access)},stop:function(e){e.unbind("get",this._access)},get:function(){var e=this,n=e.source,i=0,r=e.path,a=n;if(!e.observable)return a;for(e.start(e.source),a=n.get(r);a===t&&n;)(n=e.parents[++i])instanceof o&&(a=n.get(r));if(a===t)for(n=e.source;a===t&&n;)(n=n.parent())instanceof o&&(a=n.get(r));return"function"==typeof a&&((i=r.lastIndexOf("."))>0&&(n=n.get(r.substring(0,i))),e.start(n),a=n!==e.source?a.call(n,e.source):a.call(n),e.stop(n)),n&&n!==e.source&&(e.currentSource=n,n.unbind(m,e._change).bind(m,e._change)),e.stop(e.source),a},set:function(e){var t=this.currentSource||this.source,i=n.getter(this.path)(t);"function"==typeof i?t!==this.source?i.call(t,this.source,e):i.call(t,e):t.set(this.path,e)},destroy:function(){this.observable&&(this.source.unbind(m,this._change),this.currentSource&&this.currentSource.unbind(m,this._change)),this.unbind()}}),v=g.extend({get:function(){var e,t=this.source,n=this.path,i=0;for(e=t.get(n);!e&&t;)(t=this.parents[++i])instanceof o&&(e=t.get(n));if(e)return e.bind(t)}}),_=g.extend({init:function(e,t,n){g.fn.init.call(this,e,t),this.template=n},render:function(e){var t;return this.start(this.source),t=n.render(this.template,e),this.stop(this.source),t}}),b=c.extend({init:function(e,t,n){this.element=e,this.bindings=t,this.options=n},bind:function(e,t){var n=this;(e=t?e[t]:e).bind(m,(function(e){n.refresh(t||e)})),n.refresh(t)},destroy:function(){}}),y=b.extend({dataType:function(){return(this.element.getAttribute("data-"+n.ns+"type")||this.element.type||"text").toLowerCase()},parsedValue:function(){return this._parseValue(this.element.value,this.dataType())},_parseValue:function(e,t){return"date"==t?e=n.parseDate(e,"yyyy-MM-dd"):"datetime-local"==t?e=n.parseDate(e,["yyyy-MM-ddTHH:mm:ss","yyyy-MM-ddTHH:mm"]):"number"==t?e=n.parseFloat(e):"boolean"==t&&(e=e.toLowerCase(),e=null!==n.parseFloat(e)?Boolean(n.parseFloat(e)):"true"===e.toLowerCase()),e}});function w(t,i,r){return b.extend({init:function(e,t,n){var i=this;b.fn.init.call(i,e.element[0],t,n),i.widget=e,i._dataBinding=i.dataBinding.bind(i),i._dataBound=i.dataBound.bind(i),i._itemChange=i.itemChange.bind(i)},itemChange:function(e){M(e.item[0],e.data,this._ns(e.ns),[e.data].concat(this.bindings[t]._parents()))},dataBinding:function(e){var t,n,i=this.widget,r=e.removedItems||i.items();for(t=0,n=r.length;t<n;t++)z(r[t],!1)},_ns:function(t){t=t||n.ui;var i=[n.ui,n.dataviz.ui,n.mobile.ui];return i.splice(e.inArray(t,i),1),i.unshift(t),n.rolesFromNamespaces(i)},dataBound:function(e){var r,o,a,s,l=this.widget,c=e.addedItems||l.items(),d=l[i],u=n.data.HierarchicalDataSource;if(!(u&&d instanceof u)&&c.length)for(a=e.addedDataItems||d.flatView(),s=this.bindings[t]._parents(),r=0,o=a.length;r<o;r++)c[r]&&M(c[r],a[r],this._ns(e.ns),[a[r]].concat(s))},refresh:function(e){var o,a,s,l=this,c=l.widget;(e=e||{}).action||(l.destroy(),c.bind("dataBinding",l._dataBinding),c.bind("dataBound",l._dataBound),c.bind("itemChange",l._itemChange),o=l.bindings[t].get(),c[i]instanceof n.data.DataSource&&c[i]!=o&&(o instanceof n.data.DataSource?c[r](o):o&&o._dataSource?c[r](o._dataSource):(a=n.ui.Select&&c instanceof n.ui.Select,s=n.ui.MultiSelect&&c instanceof n.ui.MultiSelect,n.ui.DropDownTree&&c instanceof n.ui.DropDownTree?c.treeview[i].data(o):c[i].data(o),l.bindings.value&&(a||s)&&c.value(H(l.bindings.value.get(),c.options.dataValueField)))))},destroy:function(){var e=this.widget;e.unbind("dataBinding",this._dataBinding),e.unbind("dataBound",this._dataBound),e.unbind("itemChange",this._itemChange)}})}l.attr=b.extend({refresh:function(e){this.element.setAttribute(e,this.bindings.attr[e].get())}}),l.css=b.extend({init:function(e,t,n){b.fn.init.call(this,e,t,n),this.classes={}},refresh:function(t){var n=e(this.element),i=this.bindings.css[t];(this.classes[t]=i.get())?n.addClass(t):n.removeClass(t)}}),l.style=b.extend({refresh:function(e){this.element.style[e]=this.bindings.style[e].get()||""}}),l.enabled=b.extend({refresh:function(){this.bindings.enabled.get()?this.element.removeAttribute("disabled"):this.element.setAttribute("disabled","disabled")}}),l.readonly=b.extend({refresh:function(){this.bindings.readonly.get()?this.element.setAttribute("readonly","readonly"):this.element.removeAttribute("readonly")}}),l.disabled=b.extend({refresh:function(){this.bindings.disabled.get()?this.element.setAttribute("disabled","disabled"):this.element.removeAttribute("disabled")}}),l.events=b.extend({init:function(e,t,n){b.fn.init.call(this,e,t,n),this.handlers={}},refresh:function(t){var n=e(this.element),i=this.bindings.events[t],r=this.handlers[t];r&&n.off(t,r),r=this.handlers[t]=i.get(),n.on(t,i.source,r)},destroy:function(){var t,n=e(this.element);for(t in this.handlers)n.off(t,this.handlers[t])}}),l.text=b.extend({refresh:function(){var t=this.bindings.text.get(),i=this.element.getAttribute("data-"+n.ns+"format")||"";null==t&&(t=""),e(this.element).text(n.toString(t,i))}}),l.visible=b.extend({refresh:function(){this.bindings.visible.get()?this.element.style.display="":this.element.style.display="none"}}),l.invisible=b.extend({refresh:function(){this.bindings.invisible.get()?this.element.style.display="none":this.element.style.display=""}}),l.html=b.extend({refresh:function(){this.element.innerHTML=this.bindings.html.get()}}),l.value=y.extend({init:function(t,n,i){y.fn.init.call(this,t,n,i),this._change=this.change.bind(this),this.eventName=i.valueUpdate||m,e(this.element).on(this.eventName,this._change),this._initChange=!1},change:function(){this._initChange=this.eventName!=m,this.bindings[d].set(this.parsedValue()),this._initChange=!1},refresh:function(){if(!this._initChange){var e=this.bindings[d].get();null==e&&(e="");var t=this.dataType();"date"==t?e=n.toString(e,"yyyy-MM-dd"):"datetime-local"==t&&(e=n.toString(e,"yyyy-MM-ddTHH:mm:ss")),this.element.value=e}this._initChange=!1},destroy:function(){e(this.element).off(this.eventName,this._change)}}),l.source=b.extend({init:function(e,t,i){b.fn.init.call(this,e,t,i);var r=this.bindings.source.get();r instanceof n.data.DataSource&&!1!==i.autoBind&&r.fetch()},refresh:function(e){var t=this,i=t.bindings.source.get();i instanceof a||i instanceof n.data.DataSource?"add"==(e=e||{}).action?t.add(e.index,e.items):"remove"==e.action?t.remove(e.index,e.items):"itemchange"!=e.action&&t.render():t.render()},container:function(){var e=this.element;return"table"==e.nodeName.toLowerCase()&&(e.tBodies[0]||e.appendChild(document.createElement("tbody")),e=e.tBodies[0]),e},template:function(){var e=this.options,t=e.template,r=this.container().nodeName.toLowerCase();return t||(t="select"==r?e.valueField||e.textField?t=>{const r=n.getter(e.valueField||e.textField)(t),o=n.getter(e.textField||e.valueField)(t);return`<option value="${i(r)}">${i(o)}</option>`}:e=>`<option>${i(e)}</option>`:"tbody"==r?e=>`<tr><td>${i(e)}</td></tr>`:"ul"==r||"ol"==r?e=>`<li>${i(e)}</li>`:e=>`${i(e)}`,t=n.template(t)),t},add:function(t,i){var r,o,a,s,l=this.container(),c=l.cloneNode(!1),d=l.children[t];if(e(c).html(n.render(this.template(),i)),c.children.length)for(r=this.bindings.source._parents(),o=0,a=i.length;o<a;o++)s=c.children[0],l.insertBefore(s,d||null),M(s,i[o],this.options.roles,[i[o]].concat(r))},remove:function(e,t){var n,i=this.container();for(n=0;n<t.length;n++){var r=i.children[e];z(r,!0),r.parentNode==i&&i.removeChild(r)}},render:function(){var t,i,r,o=this.bindings.source.get(),l=this.container(),c=this.template();if(null!=o)if(o instanceof n.data.DataSource&&(o=o.view()),o instanceof a||"[object Array]"===s.call(o)||(o=[o]),this.bindings.template){if(P(l,!0),e(l).html(this.bindings.template.render(o)),l.children.length)for(t=this.bindings.source._parents(),i=0,r=o.length;i<r;i++)M(l.children[i],o[i],this.options.roles,[o[i]].concat(t))}else e(l).html(n.render(c,o))}}),l.input={checked:y.extend({init:function(t,n,i){y.fn.init.call(this,t,n,i),this._change=this.change.bind(this),e(this.element).change(this._change)},change:function(){var e=this.element,t=this.value();if("radio"==e.type)t=this.parsedValue(),this.bindings[p].set(t);else if("checkbox"==e.type){var n,i=this.bindings[p].get();if(i instanceof a){if((t=this.parsedValue())instanceof Date){for(var r=0;r<i.length;r++)if(i[r]instanceof Date&&+i[r]==+t){n=r;break}}else n=i.indexOf(t);n>-1?i.splice(n,1):i.push(t)}else this.bindings[p].set(t)}},refresh:function(){var e=this.bindings[p].get(),t=e,i=this.dataType(),r=this.element;if("checkbox"==r.type)if(t instanceof a){var o=-1;if((e=this.parsedValue())instanceof Date){for(var s=0;s<t.length;s++)if(t[s]instanceof Date&&+t[s]==+e){o=s;break}}else o=t.indexOf(e);r.checked=o>=0}else r.checked=t;else"radio"==r.type&&("date"==i?e=n.toString(e,"yyyy-MM-dd"):"datetime-local"==i&&(e=n.toString(e,"yyyy-MM-ddTHH:mm:ss")),null!=e&&r.value===e.toString()?r.checked=!0:r.checked=!1)},value:function(){var e=this.element,t=e.value;return"checkbox"==e.type&&(t=e.checked),t},destroy:function(){e(this.element).off(m,this._change)}})},l.select={source:l.source.extend({refresh:function(i){var r=this,o=r.bindings.source.get();if(o instanceof a||o instanceof n.data.DataSource){if("add"==(i=i||{}).action)r.add(i.index,i.items);else if("remove"==i.action)r.remove(i.index,i.items);else if(("itemchange"==i.action||i.action===t)&&(r.render(),r.bindings.value&&r.bindings.value)){var s=H(r.bindings.value.get(),e(r.element).data("valueField"));null===s?r.element.selectedIndex=-1:r.element.value=s}}else r.render()}}),value:y.extend({init:function(t,n,i){y.fn.init.call(this,t,n,i),this._change=this.change.bind(this),e(this.element).change(this._change)},parsedValue:function(){var e,t,n,i,r=this.dataType(),o=[];for(n=0,i=this.element.options.length;n<i;n++)(t=this.element.options[n]).selected&&(e=(e=t.attributes.value)&&e.specified?t.value:t.text,o.push(this._parseValue(e,r)));return o},change:function(){var e,i,r,s,l,c,u=[],h=this.element,p=this.options.valueField||this.options.textField,f=this.options.valuePrimitive;for(l=0,c=h.options.length;l<c;l++)(i=h.options[l]).selected&&(s=(s=i.attributes.value)&&s.specified?i.value:i.text,p?u.push(s):u.push(this._parseValue(s,this.dataType())));if(p)for((e=this.bindings.source.get())instanceof n.data.DataSource&&(e=e.view()),r=0;r<u.length;r++)for(l=0,c=e.length;l<c;l++){var m=e[l].get(p);if(String(m)===u[r]){u[r]=e[l];break}}(s=this.bindings[d].get())instanceof a?s.splice.apply(s,[0,s.length].concat(u)):f||!(s instanceof o||null===s||s===t)&&p?this.bindings[d].set(u[0].get(p)):this.bindings[d].set(u[0])},refresh:function(){var e,t,i=this.element,r=i.options,s=this.bindings[d].get(),l=s,c=this.options.valueField||this.options.textField,u=this.dataType();l instanceof a||(l=new a([s])),i.selectedIndex=-1;for(var h=0;h<l.length;h++)for(s=l[h],c&&s instanceof o&&(s=s.get(c)),"date"==u?s=n.toString(l[h],"yyyy-MM-dd"):"datetime-local"==u&&(s=n.toString(l[h],"yyyy-MM-ddTHH:mm:ss")),e=0;e<r.length;e++)""===(t=r[e].value)&&""!==s&&(t=r[e].text),null!=s&&t==s.toString()&&(r[e].selected=!0,!0)},destroy:function(){e(this.element).off(m,this._change)}})},l.widget={events:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this.widget=e,this.handlers={}},refresh:function(e){var t=this.bindings.events[e],n=this.handlers[e];n&&this.widget.unbind(e,n),(n=t.get())&&(this.handlers[e]=function(e){e.data=t.source,n(e),e.data===t.source&&delete e.data},this.widget.bind(e,this.handlers[e]))},destroy:function(){var e;for(e in this.handlers)this.widget.unbind(e,this.handlers[e])}}),checked:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this.widget=e,this._change=this.change.bind(this),this.widget.bind(m,this._change)},change:function(){this.bindings[p].set(this.value())},refresh:function(){var e=this.bindings[p].get();"radio"===this.element.type?e!==t?this.widget.check(e.toString()===this.value()):this.widget.check(!1):this.widget.check(!0===e)},value:function(){var e=this.element,t=e.value;return"on"!=t&&"off"!=t&&"checkbox"!=this.element.type||(t=e.checked),t},destroy:function(){this.widget.unbind(m,this._change)}}),start:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this._change=this.change.bind(this),this.widget=e,this.widget.bind(m,this._change)},change:function(){this.bindings.start.set(this.widget.range().start)},refresh:function(){var e=this.bindings.start.get(),t=this.widget._range?this.widget._range.end:null;this.widget.range({start:e,end:t})},destroy:function(){this.widget.unbind(m,this._change)}}),end:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this._change=this.change.bind(this),this.widget=e,this.widget.bind(m,this._change)},change:function(){this.bindings.end.set(this.widget.range().end)},refresh:function(){var e=this.bindings.end.get(),t=this.widget._range?this.widget._range.start:null;this.widget.range({start:t,end:e})},destroy:function(){this.widget.unbind(m,this._change)}}),visible:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this.widget=e},refresh:function(){var e=this.bindings.visible.get();this.widget.wrapper[0].style.display=e?"":"none"}}),invisible:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this.widget=e},refresh:function(){var e=this.bindings.invisible.get();this.widget.wrapper[0].style.display=e?"none":""}}),floatingLabel:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),e.floatingLabel&&e.floatingLabel.refresh()}}),enabled:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this.widget=e,this.readonly=this.element.readOnly},refresh:function(){this.widget.enable&&this.widget.enable(this.bindings.enabled.get()),this.readonly&&this.widget.readonly&&this.widget.readonly(this.readonly)}}),disabled:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this.widget=e},refresh:function(){this.widget.enable&&this.widget.enable(!this.bindings.disabled.get())}}),source:w("source","dataSource","setDataSource"),value:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this.widget=e,this._change=this.change.bind(this),this.widget.first(m,this._change);var i=this.bindings.value.get();this._valueIsObservableObject=!n.valuePrimitive&&(null==i||i instanceof o),this._valueIsObservableArray=i instanceof a,this._initChange=!1},_source:function(){var e;return this.widget.dataItem&&(e=this.widget.dataItem())&&e instanceof o?[e]:(this.bindings.source&&(e=this.bindings.source.get()),(!e||e instanceof n.data.DataSource)&&(e=this.widget.dataSource.flatView()),e)},change:function(){var e,t,n,i,r,o,a,l=this.widget.value(),c=this.options.dataValueField||this.options.dataTextField,d="[object Array]"===s.call(l),u=this._valueIsObservableObject,h=[];if(this._initChange=!0,c)if(""===l&&(u||this.options.valuePrimitive))l=null;else{for(a=this._source(),d&&(t=l.length,h=l.slice(0)),r=0,o=a.length;r<o;r++)if(i=(n=a[r]).get(c),d){for(e=0;e<t;e++)if(i==h[e]){h[e]=n;break}}else if(i==l){l=u?n:i;break}h[0]&&(l=this._valueIsObservableArray?h:u||!c?h[0]:h[0].get(c))}this.bindings.value.set(l),this._initChange=!1},refresh:function(){if(!this._initChange){var e,n=this.widget,i=n.options,r=i.dataTextField,s=i.dataValueField||r,l=this.bindings.value.get(),c=i.text||"",d=0,u=[];if(l===t&&(l=null),s)if(l instanceof a){for(e=l.length;d<e;d++)u[d]=l[d].get(s);l=u}else l instanceof o&&(c=l.get(r),l=l.get(s));!1!==i.autoBind||i.cascadeFrom||!n.listView||n.listView.bound()?n.value(l):(r!==s||c||(c=l),c||!l&&0!==l||!i.valuePrimitive?n._preselect(l,c):n.value(l))}this._initChange=!1},destroy:function(){this.widget.unbind(m,this._change)}}),dropdowntree:{value:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this.widget=e,this._change=this.change.bind(this),this.widget.first(m,this._change),this._initChange=!1},change:function(){var e=this,n=e.bindings[d].get(),i=e.options.valuePrimitive,r=e.widget.treeview.select(),o=e.widget._isMultipleSelection()?e.widget._getAllChecked():e.widget.treeview.dataItem(r)||e.widget.value(),s=i||!1===e.widget.options.autoBind?e.widget.value():o,l=this.options.dataValueField||this.options.dataTextField;if(s=s.slice?s.slice(0):s,e._initChange=!0,n instanceof a){for(var c,u,h,p=[],f=s.length,m=0,g=0,v=n[m];v!==t;){for(h=!1,g=0;g<f;g++)if(i?s[g]==v:(u=(u=s[g]).get?u.get(l):u)==(v.get?v.get(l):v)){s.splice(g,1),f-=1,h=!0;break}h?m+=1:(p.push(v),k(n,m,1),c=m),v=n[m]}k(n,n.length,0,s),p.length&&n.trigger("change",{action:"remove",items:p,index:c}),s.length&&n.trigger("change",{action:"add",items:s,index:n.length-1})}else e.bindings[d].set(s);e._initChange=!1},refresh:function(){if(!this._initChange){var e,t,n=this.options,i=this.widget,r=n.dataValueField||n.dataTextField,s=this.bindings.value.get(),l=s,c=0,d=[];if(r)if(s instanceof a){for(e=s.length;c<e;c++)t=s[c],d[c]=t.get?t.get(r):t;s=d}else s instanceof o&&(s=s.get(r));!1===n.autoBind&&!0!==n.valuePrimitive?i._preselect(l,s):i.value(s)}},destroy:function(){this.widget.unbind(m,this._change)}})},gantt:{dependencies:w("dependencies","dependencies","setDependenciesDataSource")},multiselect:{value:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this.widget=e,this._change=this.change.bind(this),this.widget.first(m,this._change),this._initChange=!1},change:function(){var e=this,n=e.bindings[d].get(),i=e.options.valuePrimitive,r=i?e.widget.value():e.widget.dataItems(),o=this.options.dataValueField||this.options.dataTextField;if(r=r.slice(0),e._initChange=!0,n instanceof a){for(var s,l,c,u=[],h=r.length,p=0,f=0,m=n[p];m!==t;){for(c=!1,f=0;f<h;f++)if(i?r[f]==m:(l=(l=r[f]).get?l.get(o):l)==(m.get?m.get(o):m)){r.splice(f,1),h-=1,c=!0;break}c?p+=1:(u.push(m),k(n,p,1),s=p),m=n[p]}k(n,n.length,0,r),u.length&&n.trigger("change",{action:"remove",items:u,index:s}),r.length&&n.trigger("change",{action:"add",items:r,index:n.length-1})}else e.bindings[d].set(r);e._initChange=!1},refresh:function(){if(!this._initChange){var e,n,i=this.options,r=this.widget,s=i.dataValueField||i.dataTextField,l=this.bindings.value.get(),c=l,d=0,u=[];if(l===t&&(l=null),s)if(l instanceof a){for(e=l.length;d<e;d++)n=l[d],u[d]=n.get?n.get(s):n;l=u}else l instanceof o&&(l=l.get(s));!1!==i.autoBind||!0===i.valuePrimitive||r._isBound()?r.value(l):r._preselect(c,l)}},destroy:function(){this.widget.unbind(m,this._change)}})},scheduler:{source:w("source","dataSource","setDataSource").extend({dataBound:function(e){var t,n,i,r,o=this.widget,a=e.addedItems||o.items();if(a.length)for(i=e.addedDataItems||o.dataItems(),r=this.bindings.source._parents(),t=0,n=i.length;t<n;t++)M(a[t],i[t],this._ns(e.ns),[i[t]].concat(r))}})},grid:{source:w("source","dataSource","setDataSource").extend({dataBound:function(e){var t,n,i,r,o=this.widget,a=e.addedItems||o.items();if(a.length)for(r=e.addedDataItems||o.dataItems(),i=this.bindings.source._parents(),t=0,n=r.length;t<n;t++)M(a[t],r[t],this._ns(e.ns),[r[t]].concat(i))}})},badge:{text:b.extend({init:function(e,t,n){b.fn.init.call(this,e.element[0],t,n),this.widget=e},refresh:function(){var e=this.bindings.text.get();null==e&&(e=""),this.widget.text(e)}})}};var k=function(e,t,n,i){n=n||0;var r,o=(i=i||[]).length,a=e.length,s=[].slice.call(e,t+n),l=s.length;if(o){for(o=t+o,r=0;t<o;t++)e[t]=i[r],r++;e.length=o}else if(n)for(e.length=t,n+=t;t<n;)delete e[--n];if(l){for(l=t+l,r=0;t<l;t++)e[t]=s[r],r++;e.length=l}for(t=e.length;t<a;)delete e[t],t++},x=c.extend({init:function(e,t){this.target=e,this.options=t,this.toDestroy=[]},bind:function(e){var t,n,i,r,o,a,s=this instanceof C,l=this.binders();for(t in e)t==d?n=!0:t==u?i=!0:t!=h||s?t==p?o=!0:"css"==t?a=!0:this.applyBinding(t,e,l):r=!0;i&&this.applyBinding(u,e,l),n&&this.applyBinding(d,e,l),o&&this.applyBinding(p,e,l),r&&!s&&this.applyBinding(h,e,l),a&&!s&&this.applyBinding("css",e,l),s&&this.target&&this.target.floatingLabel&&this.applyBinding("floatingLabel",e,l)},binders:function(){return l[this.target.nodeName.toLowerCase()]||{}},applyBinding:function(e,t,n){var i,r=n[e]||l[e],o=this.toDestroy,a=t[e];if(r)if(r=new r(this.target,t,this.options),o.push(r),a instanceof g)r.bind(a),o.push(a);else for(i in a)r.bind(a,i),o.push(a[i]);else if("template"!==e)throw new Error("The "+e+" binding is not supported by the "+this.target.nodeName.toLowerCase()+" element")},destroy:function(){var e,t,n=this.toDestroy;for(e=0,t=n.length;e<t;e++)n[e].destroy()}}),C=x.extend({binders:function(){return l.widget[this.target.options.name.toLowerCase()]||{}},applyBinding:function(e,t,n){var i,r=n[e]||l.widget[e],o=this.toDestroy,a=t[e];if(!r)throw new Error("The "+e+" binding is not supported by the "+this.target.options.name+" widget");if(r=new r(this.target,t,this.target.options),o.push(r),a instanceof g)r.bind(a),o.push(a);else for(i in a)r.bind(a,i),o.push(a[i])}});var S=/[A-Za-z0-9_\-]+:(\{([^}]*)\}|[^,}]+)/g,T=/\s/g;function D(e){var t,n,i,r,o,a,s,l={};for(t=0,n=(s=e.match(S)).length;t<n;t++)r=(i=s[t]).indexOf(":"),o=i.substring(0,r),"{"==(a=i.substring(r+1)).charAt(0)&&(a=D(a)),l[o]=a;return l}function A(e,t,n){var i,r={};for(i in e)r[i]=new n(t,e[i]);return r}function M(e,t,i,r){if(e&&!e.getAttribute("data-"+n.ns+"stop")){var o,a,s,l=e.getAttribute("data-"+n.ns+"role"),c=e.getAttribute("data-"+n.ns+"bind"),d=[],u=!0,h={};r=r||[t],(l||c)&&I(e,!1),l&&(s=function(e,t,i){var r=n.initWidget(e,{},t,i);if(r)return new C(r)}(e,i,t)),c&&(c=D(c.replace(T,"")),s||((h=n.parseOptions(e,{textField:"",valueField:"",template:"",valueUpdate:m,valuePrimitive:!1,autoBind:!0},t)).roles=i,s=new x(e,h)),s.source=t,a=A(c,r,g),h.template&&(a.template=new _(r,"",h.template)),a.click&&(c.events=c.events||{},c.events.click=c.click,a.click.destroy(),delete a.click),a.source&&(u=!1),c.attr&&(a.attr=A(c.attr,r,g)),c.style&&(a.style=A(c.style,r,g)),c.events&&(a.events=A(c.events,r,v)),c.css&&(a.css=A(c.css,r,g)),s.bind(a)),s&&(e.kendoBindingTarget=s);var p=e.children;if(u&&p&&!e.getAttribute("data-"+n.ns+"stop")){for(o=0;o<p.length;o++)d[o]=p[o];for(o=0;o<d.length;o++)M(d[o],t,i,r)}}}function E(t,i){var r,o,a,s=n.rolesFromNamespaces([].slice.call(arguments,2));for(i=n.observable(i),r=0,o=(t=e(t)).length;r<o;r++)1===(a=t[r]).nodeType&&M(a,i,s)}function I(t,i){var r=t.kendoBindingTarget;if(r&&(r.destroy(),f?delete t.kendoBindingTarget:t.removeAttribute?t.removeAttribute("kendoBindingTarget"):t.kendoBindingTarget=null),i){var o=n.widgetInstance(e(t));o&&"function"==typeof o.destroy&&o.destroy()}}function z(e,t){e&&(I(e,t),P(e,t))}function P(e,t){var n=e.children;if(n)for(var i=0,r=n.length;i<r;i++)z(n[i],t)}function H(e,t){var n,i,r=[],s=0;if(!t)return e;if(e instanceof a){for(n=e.length;s<n;s++)i=e[s],r[s]=i.get?i.get(t):i[t];e=r}else e instanceof o&&(e=e.get(t));return e}n.unbind=function(t){var n,i;for(n=0,i=(t=e(t)).length;n<i;n++)z(t[n],!1)},n.bind=E,n.data.binders=l,n.data.Binder=b,n.notify=function(e,t){var n=e.element,i=n[0].kendoBindingTarget;i&&E(n,i.source,t)},n.observable=function(e){return e instanceof o||(e=new o(e)),e},n.observableHierarchy=function(e){var t=n.data.HierarchicalDataSource.create(e);return t.fetch(),function e(t){var n,i;for(n=0;n<t.length;n++)t[n]._initChildren(),(i=t[n].children).fetch(),t[n].items=i.data(),e(t[n].items)}(t.data()),t._data._dataSource=t,t._data}}(window.kendo.jQuery);kendo;!function(e){let t=window.kendo,n=t.effects,i=e.each,r=e.extend,o=t.support,a=/matrix3?d?\s*\(.*,\s*([\d\.\-]+)\w*?,\s*([\d\.\-]+)\w*?,\s*([\d\.\-]+)\w*?,\s*([\d\.\-]+)\w*?/i,s=/translatex?$/i,l=/(zoom|fade|expand)(\w+)/,c=/(zoom|fade|expand)/,d=["perspective","rotate","rotatex","rotatey","rotatez","rotate3d","scale","scalex","scaley","scalez","scale3d","skew","skewx","skewy","translate","translatex","translatey","translatez","translate3d","matrix","matrix3d"],u=["rotate","scale","scalex","scaley","skew","skewx","skewy","translate","translatex","translatey","matrix"],h=Math.round,p="px",f="auto",m="width",g="height",v="hidden",_="origin",b="abortId",y="overflow",w="position",k="completeCallback",x="transitionend",C="transition",S="transform",T="perspective",D="1500px",A="perspective("+D+")",M={left:{reverse:"right",property:"left",transition:"translatex",vertical:!1,modifier:-1},right:{reverse:"left",property:"left",transition:"translatex",vertical:!1,modifier:1},down:{reverse:"up",property:"top",transition:"translatey",vertical:!0,modifier:1},up:{reverse:"down",property:"top",transition:"translatey",vertical:!0,modifier:-1},top:{reverse:"bottom"},bottom:{reverse:"top"},in:{reverse:"out",modifier:-1},out:{reverse:"in",modifier:1},vertical:{reverse:"vertical"},horizontal:{reverse:"horizontal"}};function E(e){return parseInt(e,10)}function I(e,t){var n,i,r,a,s=[],l={};for(i in t)n=i.toLowerCase(),a=-1!=d.indexOf(n),!o.hasHW3D&&a&&-1==u.indexOf(n)?delete t[i]:(r=t[i],a?s.push(i+"("+r+")"):l[i]=r);return s.length&&(l[S]=s.join(" ")),l}t.directions=M,r(e.fn,{kendoStop:function(e,t){return n.stopQueue(this,e||!1,t||!1)}}),t.toggleClass=function(e,t,n,o){return t&&(t=t.split(" "),n=r({exclusive:"all",duration:400,ease:"ease-out"},n),e.css(C,n.exclusive+" "+n.duration+"ms "+n.ease),setTimeout((function(){e.css(C,"").css(g)}),n.duration),i(t,(function(t,n){e.toggleClass(n,o)}))),e},t.parseEffects=function(e,t){var n={};return"string"==typeof e?i(e.split(" "),(function(e,i){var r=!c.test(i),o=i.replace(l,(function(e,t,n){return t+":"+n.toLowerCase()})).split(":"),a=o[1],s={};o.length>1&&(s.direction=t&&r?M[a].reverse:a),n[o[0]]=s})):i(e,(function(e){var i=this.direction;i&&t&&!c.test(e)&&(this.direction=M[i].reverse),n[e]=this})),n},r(n,{transition:function(t,n,i){let o,a,s=0,l=t.data("keys")||[];i=r({duration:200,ease:"ease-out",complete:null,exclusive:"all"},i);let c=!1,d=function(){c||(c=!0,a&&(clearTimeout(a),a=null),t.removeData(b).dequeue().css(C,"").css(C),i.complete.call(t))};i.duration=e.fx&&e.fx.speeds[i.duration]||i.duration,o=I(0,n),e.merge(l,function(e){var t=[];for(var n in e)t.push(n);return t}(o)),e.hasOwnProperty("uniqueSort")?t.data("keys",e.uniqueSort(l)).height():t.data("keys",e.unique(l)).height(),t.css(C,i.exclusive+" "+i.duration+"ms "+i.ease).css(C),t.css(o).css(S),t.one(x,d),0!==i.duration&&(s=500),a=setTimeout(d,i.duration+s),t.data(b,a),t.data(k,d)},stopQueue:function(e,n,i){var r,o=e.data("keys"),a=!i&&o,s=e.data(k);return a&&(r=t.getComputedStyles(e[0],o)),s&&s(),a&&e.css(r),e.removeData("keys").stop(n)}});var z=t.Class.extend({init:function(e,t){var n=this;n.element=e,n.effects=[],n.options=t,n.restore=[]},run:function(t){let i,o,a,s,l,c,d=this,u=t.length,h=d.element,p=d.options,f=e.Deferred(),m={},g={};for(d.effects=t,f.done(d.complete.bind(d)),h.data("animating",!0),o=0;o<u;o++)for(i=t[o],i.setReverse(p.reverse),i.setOptions(p),d.addRestoreProperties(i.restore),i.prepare(m,g),l=i.children(),a=0,c=l.length;a<c;a++)l[a].duration(p.duration).run();for(var v in p.effects)r(g,p.effects[v].properties);for(h.is(":visible")||r(m,{display:h.data("olddisplay")||"block"}),p.reset||(s=h.data("targetTransform"),s&&(m=r(s,m))),m=I(0,m),h.css(m).css(S),o=0;o<u;o++)t[o].setup();return p.init&&p.init(),h.data("targetTransform",g),n.animate(h,g,r({},p,{complete:f.resolve})),f.promise()},stop:function(){e(this.element).kendoStop(!0,!0)},addRestoreProperties:function(e){for(var t,n=this.element,i=0,r=e.length;i<r;i++)t=e[i],this.restore.push(t),n.data(t)||n.data(t,n.css(t))},restoreCallback:function(){for(var e=this.element,t=0,n=this.restore.length;t<n;t++){var i=this.restore[t];e.css(i,e.data(i))}},complete:function(){let e=this,t=0,n=e.element,i=e.options,r=e.effects,o=r.length;for(n.removeData("animating").dequeue(),i.hide&&n.data("olddisplay",n.css("display")).hide(),this.restoreCallback();t<o;t++)r[t].teardown();i.completeCallback&&i.completeCallback(n)}});n.promise=function(e,i){var r,o,a=[],s=new z(e,i),l=t.parseEffects(i.effects);for(var c in i.effects=l,l)(r=n[H(c)])&&(o=new r(e,l[c].direction),a.push(o));a[0]?s.run(a):(e.is(":visible")||e.css({display:e.data("olddisplay")||"block"}).css("display"),i.init&&i.init(),e.dequeue(),s.complete())},r(n,{animate:function(e,t,i){let r=!1!==i.transition;delete i.transition,"transition"in n&&r?n.transition(e,t,i):e.animate(function(e){for(var t in e)-1!=d.indexOf(t)&&-1==u.indexOf(t)&&delete e[t];return e}(t),{queue:!1,show:!1,hide:!1,duration:i.duration,complete:i.complete})}}),n.animatedPromise=n.promise;var P=t.Class.extend({init:function(e,t){var n=this;n.element=e,n._direction=t,n.options={},n._additionalEffects=[],n.restore||(n.restore=[])},reverse:function(){return this._reverse=!0,this.run()},play:function(){return this._reverse=!1,this.run()},add:function(e){return this._additionalEffects.push(e),this},direction:function(e){return this._direction=e,this},duration:function(e){return this._duration=e,this},compositeRun:function(){var e=this,t=new z(e.element,{reverse:e._reverse,duration:e._duration}),n=e._additionalEffects.concat([e]);return t.run(n)},run:function(){if(this._additionalEffects&&this._additionalEffects[0])return this.compositeRun();let t,i,o=this,a=o.element,s=0,l=o.restore,c=l.length,d=e.Deferred(),u={},h={},p=o.children(),f=p.length;for(d.done(o._complete.bind(o)),a.data("animating",!0),s=0;s<c;s++)t=l[s],a.data(t)||a.data(t,a.css(t));for(s=0;s<f;s++)p[s].duration(o._duration).run();return o.prepare(u,h),a.is(":visible")||r(u,{display:a.data("olddisplay")||"block"}),i=a.data("targetTransform"),i&&(u=r(i,u)),u=I(0,u),a.css(u).css(S),o.setup(),a.data("targetTransform",h),n.animate(a,h,{duration:o._duration,complete:d.resolve}),d.promise()},stop:function(){var t=0,n=this.children(),i=n.length;for(t=0;t<i;t++)n[t].stop();return e(this.element).kendoStop(!0,!0),this},restoreCallback:function(){for(var e=this.element,t=0,n=this.restore.length;t<n;t++){var i=this.restore[t];e.css(i,e.data(i))}},_complete:function(){let e=this,t=e.element;t.removeData("animating").dequeue(),e.restoreCallback(),e.shouldHide()&&t.data("olddisplay",t.css("display")).hide(),e.teardown()},setOptions:function(e){r(!0,this.options,e)},children:function(){return[]},shouldHide:e.noop,setup:e.noop,prepare:e.noop,teardown:e.noop,directions:[],setReverse:function(e){return this._reverse=e,this}});function H(e){return e.charAt(0).toUpperCase()+e.substring(1)}function F(e,t){var r=P.extend(t),o=r.prototype.directions;n[H(e)]=r,n.Element.prototype[e]=function(e,t,n,i){return new r(this.element,e,t,n,i)},i(o,(function(t,i){n.Element.prototype[e+H(i)]=function(e,t,n){return new r(this.element,i,e,t,n)}}))}var R=["left","right","up","down"],L=["in","out"];function B(e,t,n,i){F(e,{directions:L,startValue:function(e){return this._startValue=e,this},endValue:function(e){return this._endValue=e,this},shouldHide:function(){return this._shouldHide},prepare:function(e,r){var o,a,s="out"===this._direction,l=this.element.data(t);o=!(isNaN(l)||l==n)?l:void 0!==this._startValue?this._startValue:s?n:i,a=void 0!==this._endValue?this._endValue:s?i:n,this._reverse?(e[t]=a,r[t]=o):(e[t]=o,r[t]=a),this._shouldHide=r[t]===i}})}F("slideIn",{directions:R,divisor:function(e){return this.options.divisor=e,this},prepare:function(e,n){let i,r=this,o=r.element,a=t._outerWidth,s=t._outerHeight,l=M[r._direction],c=-l.modifier*(l.vertical?s(o):a(o))/(r.options&&r.options.divisor||1)+p;r._reverse&&(i=e,e=n,n=i),e[l.transition]=c,n[l.transition]="0px"}}),F("tile",{directions:R,init:function(e,t,n){P.prototype.init.call(this,e,t),this.options={previous:n}},previousDivisor:function(e){return this.options.previousDivisor=e,this},children:function(){var e=this,n=e._reverse,i=e.options.previous,r=e.options.previousDivisor||1,o=e._direction,a=[t.fx(e.element).slideIn(o).setReverse(n)];return i&&a.push(t.fx(i).slideIn(M[o].reverse).divisor(r).setReverse(!n)),a}}),B("fade","opacity",1,0),B("zoom","scale",1,.01),F("slideMargin",{prepare:function(e,t){var n,i=this,r=i.element,o=i.options,a=r.data(_),s=o.offset,l=i._reverse;l||null!==a||r.data(_,parseFloat(r.css("margin-"+o.axis))),n=r.data(_)||0,t["margin-"+o.axis]=l?n:n+s}}),F("slideTo",{prepare:function(e,t){let n=this,i=n.element,r=n.options.offset.split(","),o=n._reverse;t.translatex=o?0:r[0],t.translatey=o?0:r[1],i.css("left")}}),F("expand",{directions:["horizontal","vertical"],restore:[y],prepare:function(e,t){var n=this,i=n.element,r=n.options,o=n._reverse,a="vertical"===n._direction?g:m,s=i[0].style[a],l=i.data(a),c=parseFloat(l||s),d=h(i.css(a,f)[a]());e.overflow=v,c=r&&r.reset?d||c:c||d,t[a]=(o?0:c)+p,e[a]=(o?c:0)+p,undefined===l&&i.data(a,s)},shouldHide:function(){return this._reverse},teardown:function(){var e=this.element,t="vertical"===this._direction?g:m,n=e.data(t);n!=f&&""!==n||setTimeout((function(){e.css(t,f).css(t)}),0)}});var O={position:"absolute",marginLeft:0,marginTop:0,scale:1};F("transfer",{init:function(e,t){this.element=e,this.options={target:t},this.restore=[]},setup:function(){this.element.appendTo(document.body)},prepare:function(e,t){var i=this,o=i.element,l=n.box(o),c=n.box(i.options.target),d=function(e,t){let n=e.css(S);if("none"==n)return"scale"==t?1:0;let i=n.match(new RegExp(t+"\\s*\\(([\\d\\w\\.]+)")),r=0;return i?r=E(i[1]):(i=n.match(a)||[0,0,0,0,0],t=t.toLowerCase(),s.test(t)?r=parseFloat(i[3]/i[2]):"translatey"==t?r=parseFloat(i[4]/i[2]):"scale"==t?r=parseFloat(i[2]):"rotate"==t&&(r=parseFloat(Math.atan2(i[2],i[1])))),r}(o,"scale"),u=n.fillScale(c,l),h=n.transformOrigin(c,l);r(e,O),t.scale=1,o.css(S,"scale(1)").css(S),o.css(S,"scale("+d+")"),e.top=l.top,e.left=l.left,e.transformOrigin=h.x+p+" "+h.y+p,i._reverse?e.scale=u:t.scale=u}});var V={top:"rect(auto auto $size auto)",bottom:"rect($size auto auto auto)",left:"rect(auto $size auto auto)",right:"rect(auto auto auto $size)"},N={top:{start:"rotatex(0deg)",end:"rotatex(180deg)"},bottom:{start:"rotatex(-180deg)",end:"rotatex(0deg)"},left:{start:"rotatey(0deg)",end:"rotatey(-180deg)"},right:{start:"rotatey(180deg)",end:"rotatey(0deg)"}};function $(e,n){var i=e[t.directions[n].vertical?g:m]()/2+"px";return V[n].replace("$size",i)}F("turningPage",{directions:R,init:function(e,t,n){P.prototype.init.call(this,e,t),this._container=n},prepare:function(e,n){var i=this,r=i._reverse,o=r?M[i._direction].reverse:i._direction,a=N[o];e.zIndex=1,i._clipInHalf&&(e.clip=$(i._container,t.directions[o].reverse)),e["backface-visibility"]=v,n[S]=A+(r?a.start:a.end),e[S]=A+(r?a.end:a.start)},setup:function(){this._container.append(this.element)},face:function(e){return this._face=e,this},shouldHide:function(){var e=this._reverse,t=this._face;return e&&!t||!e&&t},clipInHalf:function(e){return this._clipInHalf=e,this},temporary:function(){return this.element.addClass("temp-page"),this}}),F("staticPage",{directions:R,init:function(e,t,n){P.prototype.init.call(this,e,t),this._container=n},restore:["clip"],prepare:function(e,t){var n=this,i=n._reverse?M[n._direction].reverse:n._direction;e.clip=$(n._container,i),e.opacity=.999,t.opacity=1},shouldHide:function(){var e=this._reverse,t=this._face;return e&&!t||!e&&t},face:function(e){return this._face=e,this}}),F("pageturn",{directions:["horizontal","vertical"],init:function(e,t,n,i){P.prototype.init.call(this,e,t),this.options={},this.options.face=n,this.options.back=i},children:function(){var e,n=this,i=n.options,r="horizontal"===n._direction?"left":"top",o=t.directions[r].reverse,a=n._reverse,s=i.face.clone(!0).removeAttr("id"),l=i.back.clone(!0).removeAttr("id"),c=n.element;return a&&(e=r,r=o,o=e),[t.fx(i.face).staticPage(r,c).face(!0).setReverse(a),t.fx(i.back).staticPage(o,c).setReverse(a),t.fx(s).turningPage(r,c).face(!0).clipInHalf(!0).temporary().setReverse(a),t.fx(l).turningPage(o,c).clipInHalf(!0).temporary().setReverse(a)]},prepare:function(e,t){e[T]=D,e.transformStyle="preserve-3d",e.opacity=.999,t.opacity=1},teardown:function(){this.element.find(".temp-page").remove()}}),F("flip",{directions:["horizontal","vertical"],init:function(e,t,n,i){P.prototype.init.call(this,e,t),this.options={},this.options.face=n,this.options.back=i},children:function(){var e,n=this,i=n.options,r="horizontal"===n._direction?"left":"top",o=t.directions[r].reverse,a=n._reverse,s=n.element;return a&&(e=r,r=o,o=e),[t.fx(i.face).turningPage(r,s).face(!0).setReverse(a),t.fx(i.back).turningPage(o,s).setReverse(a)]},prepare:function(e){e[T]=D,e.transformStyle="preserve-3d"}});var U=!o.mobileOS.android;F("replace",{_before:e.noop,_after:e.noop,init:function(t,n,i){P.prototype.init.call(this,t),this._previous=e(n),this._transitionClass=i},duration:function(){throw new Error("The replace effect does not support duration setting; the effect duration may be customized through the transition class rule")},beforeTransition:function(e){return this._before=e,this},afterTransition:function(e){return this._after=e,this},_both:function(){return e().add(this._element).add(this._previous)},_containerClass:function(){var e=this._direction,t="k-fx k-fx-start k-fx-"+this._transitionClass;return e&&(t+=" k-fx-"+e),this._reverse&&(t+=" k-fx-reverse"),t},complete:function(t){if(!(!this.deferred||t&&e(t.target).is(".km-touch-scrollbar, .km-actionsheet-wrapper"))){var n=this.container;n.removeClass("k-fx-end").removeClass(this._containerClass()).off(x,this.completeProxy),this._previous.hide().removeClass("k-fx-current"),this.element.removeClass("k-fx-next"),U&&n.css(y,""),this.isAbsolute||this._both().css(w,""),this.deferred.resolve(),delete this.deferred}},run:function(){if(this._additionalEffects&&this._additionalEffects[0])return this.compositeRun();let n,i=this,r=i.element,o=i._previous,a=r.parents().filter(o.parents()).first(),s=i._both(),l=e.Deferred(),c=r.css(w);return a.length||(a=r.parent()),this.container=a,this.deferred=l,this.isAbsolute="absolute"==c,this.isAbsolute||s.css(w,"absolute"),U&&(n=a.css(y),a.css(y,"hidden")),r.addClass("k-fx-hidden"),a.addClass(this._containerClass()),this.completeProxy=this.complete.bind(this),a.on(x,this.completeProxy),t.animationFrame((function(){r.removeClass("k-fx-hidden").addClass("k-fx-next"),o.css("display","").addClass("k-fx-current"),i._before(o,r),t.animationFrame((function(){a.removeClass("k-fx-start").addClass("k-fx-end"),i._after(o,r)}))})),l.promise()},stop:function(){this.complete()}});var W=t.Class.extend({init:function(){var e=this;e._tickProxy=e._tick.bind(e),e._started=!1},tick:e.noop,done:e.noop,onEnd:e.noop,onCancel:e.noop,start:function(){this.enabled()&&(this.done()?this.onEnd():(this._started=!0,t.animationFrame(this._tickProxy)))},enabled:function(){return!0},cancel:function(){this._started=!1,this.onCancel()},_tick:function(){var e=this;e._started&&(e.tick(),e.done()?(e._started=!1,e.onEnd()):t.animationFrame(e._tickProxy))}}),j=W.extend({init:function(e){r(this,e),W.fn.init.call(this)},done:function(){return this.timePassed()>=this.duration},timePassed:function(){return Math.min(this.duration,new Date-this.startDate)},moveTo:function(e){var t=this,n=t.movable;t.initial=n[t.axis],t.delta=e.location-t.initial,t.duration="number"==typeof e.duration?e.duration:300,t.tick=t._easeProxy(e.ease),t.startDate=new Date,t.start()},_easeProxy:function(e){var t=this;return function(){t.movable.moveAxis(t.axis,e(t.timePassed(),t.initial,t.delta,t.duration))}}});r(j,{easeOutExpo:function(e,t,n,i){return e==i?t+n:n*(1-Math.pow(2,-10*e/i))+t},easeOutBack:function(e,t,n,i,r){return n*((e=e/i-1)*e*(((r=1.70158)+1)*e+r)+1)+t}}),n.Animation=W,n.Transition=j,n.createEffect=F,n.box=function(n){var i=(n=e(n)).offset();return i.width=t._outerWidth(n),i.height=t._outerHeight(n),i},n.transformOrigin=function(e,t){var n=(e.left-t.left)*t.width/(t.width-e.width),i=(e.top-t.top)*t.height/(t.height-e.height);return{x:isNaN(n)?0:n,y:isNaN(i)?0:i}},n.fillScale=function(e,t){return Math.min(e.width/t.width,e.height/t.height)},n.fitScale=function(e,t){return Math.max(e.width/t.width,e.height/t.height)}}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.attr,i=t.ui,r=t.attrValue,o=(t.directiveSelector,t.Observable),a=t.ui.Widget,s=t.roleSelector,l="init",c="transitionStart",d="transitionEnd",u="show",h="hide",p=/unrecognized expression/,f="showStart",m="sameViewRequested",g="viewShow",v="viewTypeDetermined",_="after",b="k-content",y="k-view",w="k-stretched-view",k="k-widget",x="k-footer",C=t.ui.Widget.extend({init:function(n,i){var r=this;i=i||{},r.id=t.guid(),o.fn.init.call(r),this.options=e.extend({},this.options,i),r.content=n,r.options.renderOnInit&&a.fn.init.call(r,r._createElement(),i),r.options.wrapInSections&&r._renderSections(),r.tagName=i.tagName||"div",r.model=i.model,r._wrap=!1!==i.wrap,this._evalTemplate=i.evalTemplate||!1,this._useWithBlock=i.useWithBlock,r._fragments={},r.bind([l,u,h,c,d],i)},options:{name:"View",renderOnInit:!1,wrapInSections:!1,detachOnHide:!0,detachOnDestroy:!0},render:function(n){var i=this,r=!i.element;return r&&(i.element=i._createElement()),n&&e(n).append(i.element),r&&(t.bind(i.element,i.model),i.trigger(l)),n&&(i._eachFragment("attach"),i.trigger(u)),i.element},clone:function(){return new S(this)},triggerBeforeShow:function(){return!0},triggerBeforeHide:function(){return!0},showStart:function(){var e=this.render();e&&e.css("display",""),this.trigger(f,{view:this})},showEnd:function(){},hideEnd:function(){this.hide()},beforeTransition:function(e){this.trigger(c,{type:e})},afterTransition:function(e){this.trigger(d,{type:e})},hide:function(){this.options.detachOnHide&&(this._eachFragment("detach"),e(this.element).detach()),this.trigger(h)},destroy:function(){var e=this,n=e.element;n&&(a.fn.destroy.call(e),t.unbind(n),t.destroy(n),e.options.detachOnDestroy&&n.remove())},purge:function(){var t=this;t.destroy(),e(t.element).add(t.content).add(t.wrapper).off().remove()},fragments:function(t){e.extend(this._fragments,t)},_eachFragment:function(e){for(var t in this._fragments)this._fragments[t][e](this,t)},_createElement:function(){var n,i,r=this,o="<"+r.tagName+">";try{"SCRIPT"===(i=e(document.getElementById(r.content)||r.content))[0].tagName&&(i=i.html())}catch(e){p.test(e.message)&&(i=r.content)}if("string"==typeof i)i=i.replace(/^\s+|\s+$/g,""),r._evalTemplate&&(i=t.template(i,{useWithBlock:r._useWithBlock})(r.model||{})),n=e(o).append(i),r._wrap||(n=n.contents());else{if(n=i,r._evalTemplate){var a=e(t.template(e("<div />").append(n.clone(!0)).html(),{useWithBlock:r._useWithBlock})(r.model||{}));e.contains(document,n[0])&&n.replaceWith(a),n=a}r._wrap&&(n=n.wrapAll(o).parent())}return n},_renderSections:function(){var e=this;e.options.wrapInSections&&(e._wrapper(),e._createContent(),e._createHeader(),e._createFooter())},_wrapper:function(){var e=this,n=e.content;n.is(s("view"))?e.wrapper=e.content:e.wrapper=n.wrap("<div data-"+t.ns+'stretch="true" data-'+t.ns+'role="view" data-'+t.ns+'init-widgets="false"></div>').parent();var i=e.wrapper;i.attr("id",e.id),i.addClass(y),i.addClass(k),i.attr("role","view")},_createContent:function(){var t=e(this.wrapper),i=s("content");t.children(i)[0]||t.children().filter((function(){var t=e(this);if(!t.is(s("header"))&&!t.is(s("footer")))return t})).wrap("<div "+n("role")+'="content"></div>');this.contentElement=t.children(s("content")),this.contentElement.addClass(w).addClass(b)},_createHeader:function(){var e=this.wrapper;this.header=e.children(s("header"))},_createFooter:function(){var e=this.wrapper;this.footer=e.children(s("footer")).addClass(x)}}),S=t.Class.extend({init:function(t){e.extend(this,{element:t.element.clone(!0),transition:t.transition,id:t.id}),t.element.parent().append(this.element)},hideEnd:function(){this.element.remove()},beforeTransition:e.noop,afterTransition:e.noop}),T=C.extend({init:function(e,t){C.fn.init.call(this,e,t),this.containers={}},container:function(e){var t=this.containers[e];return t||(t=this._createContainer(e),this.containers[e]=t),t},showIn:function(e,t,n){this.container(e).show(t,n)},_createContainer:function(e){var t,n=this.render(),i=n.find(e);if(!i.length&&n.is(e)){if(!n.is(e))throw new Error("can't find a container with the specified "+e+" selector");i=n}return(t=new M(i)).bind("accepted",(function(e){e.view.render(i)})),t}}),D=C.extend({attach:function(e,t){e.element.find(t).replaceWith(this.render())},detach:function(){}}),A=/^(\w+)(:(\w+))?( (\w+))?$/;var M=o.extend({init:function(e){o.fn.init.call(this),this.container=e,this.history=[],this.view=null,this.running=!1},after:function(){this.running=!1,this.trigger("complete",{view:this.view}),this.trigger("after")},end:function(){this.view.showEnd(),this.previous.hideEnd(),this.after()},show:function(e,n,i){if(!e.triggerBeforeShow()||this.view&&!this.view.triggerBeforeHide())return this.trigger("after"),!1;i=i||e.id;var r=this,o=e===r.view?e.clone():r.view,a=r.history,s=(a[a.length-2]||{}).id===i,l=n||(s?a[a.length-1].transition:e.transition),c=function(e){if(!e)return{};var t=e.match(A)||[];return{type:t[1],direction:t[3],reverse:"reverse"===t[5]}}(l);return r.running&&r.effect.stop(),"none"===l&&(l=null),r.trigger("accepted",{view:e}),r.view=e,r.previous=o,r.running=!0,s?a.pop():a.push({id:i,transition:l}),o?(l&&t.effects.enabled?(e.element.addClass("k-fx-hidden"),e.showStart(),s&&!n&&(c.reverse=!c.reverse),r.effect=t.fx(e.element).replace(o.element,c.type).beforeTransition((function(){e.beforeTransition("show"),o.beforeTransition("hide")})).afterTransition((function(){e.afterTransition("show"),o.afterTransition("hide")})).direction(c.direction).setReverse(c.reverse),r.effect.run().then((function(){r.end()}))):(e.showStart(),r.end()),!0):(e.showStart(),e.showEnd(),r.after(),!0)},destroy:function(){var e=this.view;e&&e.destroy&&e.destroy()}}),E=o.extend({init:function(n){var i,r,a=this;o.fn.init.call(a),a.options=n,e.extend(a,n),a.sandbox=e("<div />"),r=a.container,i=a._hideViews(r),a.rootView=i.first(),a.layouts={},a.viewContainer=new t.ViewContainer(a.container),a.viewContainer.bind("accepted",(function(e){e.view.params=a.params})),a.viewContainer.bind("complete",(function(e){a.trigger(g,{view:e.view})})),a.viewContainer.bind(_,(function(){a.trigger(_)})),this.bind(this.events,n)},events:[f,_,g,"loadStart","loadComplete",m,v],destroy:function(){var e=this,n=e.viewContainer;for(var i in t.destroy(e.container),e.layouts)this.layouts[i].destroy();n&&n.destroy()},view:function(){return this.viewContainer.view},showView:function(e,n,i){if(""===(e=e.replace(new RegExp("^"+this.remoteViewURLPrefix),""))&&this.remoteViewURLPrefix&&(e="/"),e.replace(/^#/,"")===this.url)return this.trigger(m),!1;this.trigger(f);var r=this,o=r._findViewElement(e),a=t.widgetInstance(o);return r.url=e.replace(/^#/,""),r.params=i,a&&a.reload&&(a.purge(),o=[]),this.trigger(v,{remote:0===o.length,url:e}),!o[0]||(a||(a=r._createView(o)),r.viewContainer.show(a,n,e))},append:function(t,i){var r,o,a=this.sandbox,s=(i||"").split("?")[0],l=this.container;return t.indexOf("<body")>-1&&(t=e("<div>").append(t).html()),a[0].innerHTML=t,l.append(a.children("script, style")),(o=(r=this._hideViews(a)).first()).length||(r=o=a.wrapInner("<div data-role=view />").children()),s&&o.hide().attr(n("url"),s),l.append(r),t=null,this._createView(o)},_locate:function(e){return s(e)},_findViewElement:function(e){var t,i=e.split("?")[0];return i?((t=this.container.children("["+n("url")+"='"+i+"']"))[0]||-1!==i.indexOf("/")||(t=this.container.children("#"===i.charAt(0)?i:"#"+i)),t[0]||(t=this._findViewElementById(e)),t):this.rootView},_findViewElementById:function(e){return this.container.children("[id='"+e+"']")},_createView:function(e){return this._createSpaView(e)},_createMobileView:function(e){return t.initWidget(e,{defaultTransition:this.transition,loader:this.loader,container:this.container,getLayout:this.getLayoutProxy,modelScope:this.modelScope,reload:r(e,"reload")},i.roles)},_createSpaView:function(e){var n=(this.options||{}).viewOptions||{};return new t.View(e,{renderOnInit:n.renderOnInit,wrap:n.wrap||!1,wrapInSections:n.wrapInSections,detachOnHide:n.detachOnHide,detachOnDestroy:n.detachOnDestroy})},_hideViews:function(e){return e.children(this._locate("view")).hide()}});t.ViewEngine=E,t.ViewContainer=M,t.Fragment=D,t.Layout=T,t.View=C,t.ViewClone=S}(window.kendo.jQuery);kendo;!function(e){function t(){this.node=null}function n(){}t.prototype={remove:function(){this.node.parentNode&&this.node.parentNode.removeChild(this.node),this.attr={}},attr:{},text:function(){return""}},n.prototype={nodeName:"#null",attr:{style:{}},children:[],remove:function(){}};var i=new n;function r(e,t,n){this.nodeName=e,this.attr=t||{},this.children=n||[]}function o(e,t){this.nodeValue=String(e),this.force=t}function a(e,t){this.html=e,this.replace=t}r.prototype=new t,r.prototype.appendTo=function(e){for(var t="string"==typeof this.nodeName?document.createElement(this.nodeName):this.nodeName,n=this.children,r=0;r<n.length;r++)n[r].render(t,i);return e.appendChild(t),t},r.prototype.render=function(e,t){var n;if(t.nodeName!==this.nodeName)t.remove(),n=this.appendTo(e);else{var r;n=t.node;var o=this.children,a=o.length,s=t.children,l=s.length;if(Math.abs(l-a)>2)return void this.render({appendChild:function(n){e.replaceChild(n,t.node)}},i);for(r=0;r<a;r++)o[r].render(n,s[r]||i);for(r=a;r<l;r++)s[r].remove()}this.node=n,this.syncAttributes(t.attr),this.removeAttributes(t.attr)},r.prototype.syncAttributes=function(e){var t=this.attr;for(var n in t){var i=t[n],r=e[n];"style"===n?this.setStyle(i,r):i!==r&&this.setAttribute(n,i,r)}},r.prototype.setStyle=function(e,t){var n,i=this.node;if(t)for(n in e)e[n]!==t[n]&&(i.style[n]=e[n]);else for(n in e)i.style[n]=e[n]},r.prototype.removeStyle=function(e){var t=this.attr.style||{},n=this.node;for(var i in e)void 0===t[i]&&(n.style[i]="")},r.prototype.removeAttributes=function(e){var t=this.attr;for(var n in e)"style"===n?this.removeStyle(e.style):void 0===t[n]&&this.removeAttribute(n)},r.prototype.removeAttribute=function(e){var t=this.node;"style"===e?t.style.cssText="":"className"===e?t.className="":t.removeAttribute(e)},r.prototype.setAttribute=function(e,t){var n=this.node;void 0!==n[e]?n[e]=t:n.setAttribute(e,t)},r.prototype.text=function(){for(var e="",t=0;t<this.children.length;++t)e+=this.children[t].text();return e},o.prototype=new t,o.prototype.nodeName="#text",o.prototype.render=function(e,t){var n;t.nodeName!==this.nodeName||this.force?(t.remove(),n=document.createTextNode(this.nodeValue),e.appendChild(n)):(n=t.node,this.nodeValue!==t.nodeValue&&n.parentNode&&(n.nodeValue=this.nodeValue)),this.node=n},o.prototype.text=function(){return this.nodeValue},a.prototype={nodeName:"#html",attr:{},remove:function(){for(var e=0;e<this.nodes.length;e++){var t=this.nodes[e];t.parentNode&&t.parentNode.removeChild(t)}},render:function(e,t){var n,i;if(t.nodeName!==this.nodeName||t.html!==this.html||this.replace){this.replace&&t.replace&&t.nodes&&t.nodes.length&&t.nodes[0].outerHTML?(i=function(e,t,n){var i;return s.innerHTML=n,i=s.firstChild,e.replaceChild(i,t),i}(e,t.nodes[0],this.html),n=e.lastChild):(t.remove(),n=e.lastChild,function(e,t){s.innerHTML=t;for(;s.firstChild;)e.appendChild(s.firstChild)}(e,this.html)),this.nodes=[],i&&this.nodes.push(i);for(var r=n?n.nextSibling:e.firstChild;r;r=r.nextSibling)this.nodes.push(r)}else this.nodes=t.nodes.slice(0)}};var s=document.createElement("div");function l(e,t){return new a(e,t)}function c(e,t,n){return new r(e,t,n)}function d(e,t){return new o(e,t)}function u(e){this.root=e,this.children=[]}u.prototype={html:l,element:c,text:d,render:function(e){var t,n,r=this.children;for(t=0,n=e.length;t<n;t++){var o=r[t];o?o.node&&o.node.parentNode||(o.remove(),o=i):o=i,e[t].render(this.root,o)}for(t=n;t<r.length;t++)r[t].remove();this.children=e}},e.dom={html:l,text:d,element:c,Tree:u,Node:t}}(window.kendo);var p=-2;function f(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function m(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var n=t.shift();if(n){if("object"!=typeof n)throw new TypeError(n+"must be non-object");for(var i in n)f(n,i)&&(e[i]=n[i])}}return e}function g(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)}var v={arraySet:function(e,t,n,i,r){if(t.subarray&&e.subarray)e.set(t.subarray(n,n+i),r);else for(var o=0;o<i;o++)e[r+o]=t[n+o]},flattenChunks:function(e){var t,n,i,r,o,a;for(i=0,t=0,n=e.length;t<n;t++)i+=e[t].length;for(a=new Uint8Array(i),r=0,t=0,n=e.length;t<n;t++)o=e[t],a.set(o,r),r+=o.length;return a},Buf8:function(e){return new Uint8Array(e)},Buf16:function(e){return new Uint16Array(e)},Buf32:function(e){return new Int32Array(e)}},_={arraySet:function(e,t,n,i,r){for(var o=0;o<i;o++)e[r+o]=t[n+o]},flattenChunks:function(e){return[].concat.apply([],e)},Buf8:function(e){return new Array(e)},Buf16:function(e){return new Array(e)},Buf32:function(e){return new Array(e)}},b=function(){var e="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;return b=function(){return e},e},y=function(e,t,n,i,r){return(y=b()?v.arraySet:_.arraySet)(e,t,n,i,r)},w=function(e){return(w=b()?v.flattenChunks:_.flattenChunks)(e)},k=function(e){return(k=b()?v.Buf8:_.Buf8)(e)},x=function(e){return(x=b()?v.Buf16:_.Buf16)(e)},C=function(e){return(C=b()?v.Buf32:_.Buf32)(e)},S=function(){var e=!0;try{String.fromCharCode.apply(null,[0])}catch(t){e=!1}return S=function(){return e},e},T=function(){var e=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(t){e=!1}return T=function(){return e},e},D=function(e){for(var t=k(256),n=0;n<256;n++)t[n]=n>=252?6:n>=248?5:n>=240?4:n>=224?3:n>=192?2:1;return t[254]=t[254]=1,D=function(e){return t[e]},t[e]};function A(e){var t,n,i,r,o,a=e.length,s=0;for(r=0;r<a;r++)55296==(64512&(n=e.charCodeAt(r)))&&r+1<a&&56320==(64512&(i=e.charCodeAt(r+1)))&&(n=65536+(n-55296<<10)+(i-56320),r++),s+=n<128?1:n<2048?2:n<65536?3:4;for(t=new Uint8Array(s),o=0,r=0;o<s;r++)55296==(64512&(n=e.charCodeAt(r)))&&r+1<a&&56320==(64512&(i=e.charCodeAt(r+1)))&&(n=65536+(n-55296<<10)+(i-56320),r++),n<128?t[o++]=n:n<2048?(t[o++]=192|n>>>6,t[o++]=128|63&n):n<65536?(t[o++]=224|n>>>12,t[o++]=128|n>>>6&63,t[o++]=128|63&n):(t[o++]=240|n>>>18,t[o++]=128|n>>>12&63,t[o++]=128|n>>>6&63,t[o++]=128|63&n);return t}function M(e,t){if(t<65534&&(e.subarray&&T()||!e.subarray&&S()))return String.fromCharCode.apply(null,g(e,t));for(var n="",i=0;i<t;i++)n+=String.fromCharCode(e[i]);return n}function E(e,t){var n,i,r,o,a=t||e.length,s=new Array(2*a);for(i=0,n=0;n<a;)if((r=e[n++])<128)s[i++]=r;else if((o=D(r))>4)s[i++]=65533,n+=o-1;else{for(r&=2===o?31:3===o?15:7;o>1&&n<a;)r=r<<6|63&e[n++],o--;o>1?s[i++]=65533:r<65536?s[i++]=r:(r-=65536,s[i++]=55296|r>>10&1023,s[i++]=56320|1023&r)}return M(s,i)}function I(e,t){var n;for((t=t||e.length)>e.length&&(t=e.length),n=t-1;n>=0&&128==(192&e[n]);)n--;return n<0||0===n?t:n+D(e[n])>t?n:t}function z(e,t,n,i){for(var r=65535&e,o=e>>>16&65535,a=0;0!==n;){n-=a=n>2e3?2e3:n;do{o=o+(r=r+t[i++]|0)|0}while(--a);r%=65521,o%=65521}return r|o<<16}var P=function(){var e=function(){for(var e,t=[],n=0;n<256;n++){e=n;for(var i=0;i<8;i++)e=1&e?3988292384^e>>>1:e>>>1;t[n]=e}return t}();return P=function(){return e},e};function H(e,t,n,i){var r=P(),o=i+n;e^=-1;for(var a=i;a<o;a++)e=e>>>8^r[255&(e^t[a])];return~e}function F(e,t){var n,i,r,o,a,s,l,c,d,u,h,p,f,m,g,v,_,b,y,w,k,x,C,S,T;n=e.state,i=e.next_in,S=e.input,r=i+(e.avail_in-5),o=e.next_out,T=e.output,a=o-(t-e.avail_out),s=o+(e.avail_out-257),l=n.dmax,c=n.wsize,d=n.whave,u=n.wnext,h=n.window,p=n.hold,f=n.bits,m=n.lencode,g=n.distcode,v=(1<<n.lenbits)-1,_=(1<<n.distbits)-1;e:do{f<15&&(p+=S[i++]<<f,f+=8,p+=S[i++]<<f,f+=8),b=m[p&v];t:for(;;){if(p>>>=y=b>>>24,f-=y,0===(y=b>>>16&255))T[o++]=65535&b;else{if(!(16&y)){if(64&y){if(32&y){n.mode=12;break e}e.msg="invalid literal/length code",n.mode=30;break e}b=m[(65535&b)+(p&(1<<y)-1)];continue t}for(w=65535&b,(y&=15)&&(f<y&&(p+=S[i++]<<f,f+=8),w+=p&(1<<y)-1,p>>>=y,f-=y),f<15&&(p+=S[i++]<<f,f+=8,p+=S[i++]<<f,f+=8),b=g[p&_];;){if(p>>>=y=b>>>24,f-=y,16&(y=b>>>16&255)){if(k=65535&b,f<(y&=15)&&(p+=S[i++]<<f,(f+=8)<y&&(p+=S[i++]<<f,f+=8)),(k+=p&(1<<y)-1)>l){e.msg="invalid distance too far back",n.mode=30;break e}if(p>>>=y,f-=y,k>(y=o-a)){if((y=k-y)>d&&n.sane){e.msg="invalid distance too far back",n.mode=30;break e}if(x=0,C=h,0===u){if(x+=c-y,y<w){w-=y;do{T[o++]=h[x++]}while(--y);x=o-k,C=T}}else if(u<y){if(x+=c+u-y,(y-=u)<w){w-=y;do{T[o++]=h[x++]}while(--y);if(x=0,u<w){w-=y=u;do{T[o++]=h[x++]}while(--y);x=o-k,C=T}}}else if(x+=u-y,y<w){w-=y;do{T[o++]=h[x++]}while(--y);x=o-k,C=T}for(;w>2;)T[o++]=C[x++],T[o++]=C[x++],T[o++]=C[x++],w-=3;w&&(T[o++]=C[x++],w>1&&(T[o++]=C[x++]))}else{x=o-k;do{T[o++]=T[x++],T[o++]=T[x++],T[o++]=T[x++],w-=3}while(w>2);w&&(T[o++]=T[x++],w>1&&(T[o++]=T[x++]))}break}if(64&y){e.msg="invalid distance code",n.mode=30;break e}b=g[(65535&b)+(p&(1<<y)-1)]}}break}}while(i<r&&o<s);i-=w=f>>3,p&=(1<<(f-=w<<3))-1,e.next_in=i,e.next_out=o,e.avail_in=i<r?r-i+5:5-(i-r),e.avail_out=o<s?s-o+257:257-(o-s),n.hold=p,n.bits=f}var R=15,L=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],B=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],O=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],V=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];function N(e,t,n,i,r,o,a,s){var l,c,d,u,h,p,f,m,g,v=s.bits,_=0,b=0,y=0,w=0,k=0,C=0,S=0,T=0,D=0,A=0,M=null,E=0,I=x(16),z=x(16),P=null,H=0;for(_=0;_<=R;_++)I[_]=0;for(b=0;b<i;b++)I[t[n+b]]++;for(k=v,w=R;w>=1&&0===I[w];w--);if(k>w&&(k=w),0===w)return r[o++]=20971520,r[o++]=20971520,s.bits=1,0;for(y=1;y<w&&0===I[y];y++);for(k<y&&(k=y),T=1,_=1;_<=R;_++)if(T<<=1,(T-=I[_])<0)return-1;if(T>0&&(0===e||1!==w))return-1;for(z[1]=0,_=1;_<R;_++)z[_+1]=z[_]+I[_];for(b=0;b<i;b++)0!==t[n+b]&&(a[z[t[n+b]]++]=b);if(0===e?(M=P=a,p=19):1===e?(M=L,E-=257,P=B,H-=257,p=256):(M=O,P=V,p=-1),A=0,b=0,_=y,h=o,C=k,S=0,d=-1,u=(D=1<<k)-1,1===e&&D>852||2===e&&D>592)return 1;for(;;){f=_-S,a[b]<p?(m=0,g=a[b]):a[b]>p?(m=P[H+a[b]],g=M[E+a[b]]):(m=96,g=0),l=1<<_-S,y=c=1<<C;do{r[h+(A>>S)+(c-=l)]=f<<24|m<<16|g}while(0!==c);for(l=1<<_-1;A&l;)l>>=1;if(0!==l?(A&=l-1,A+=l):A=0,b++,0==--I[_]){if(_===w)break;_=t[n+a[b]]}if(_>k&&(A&u)!==d){for(0===S&&(S=k),h+=y,T=1<<(C=_-S);C+S<w&&!((T-=I[C+S])<=0);)C++,T<<=1;if(D+=1<<C,1===e&&D>852||2===e&&D>592)return 1;r[d=A&u]=k<<24|C<<16|h-o}}return 0!==A&&(r[h+A]=_-S<<24|64<<16),s.bits=k,0}var U=-2,W=12,j=30;function q(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function G(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=x(320),this.work=x(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function K(e){var t;return e&&e.state?((t=e.state).wsize=0,t.whave=0,t.wnext=0,function(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=1,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=C(852),t.distcode=t.distdyn=C(592),t.sane=1,t.back=-1,0):U}(e)):U}function Y(e,t){var n,i;return e?(i=new G,e.state=i,i.window=null,n=function(e,t){var n,i;return e&&e.state?(i=e.state,t<0?(n=0,t=-t):(n=1+(t>>4),t<48&&(t&=15)),t&&(t<8||t>15)?U:(null!==i.window&&i.wbits!==t&&(i.window=null),i.wrap=n,i.wbits=t,K(e))):U}(e,t),0!==n&&(e.state=null),n):U}var Q,X,Z=!0;function J(e){if(Z){var t;for(Q=C(512),X=C(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(N(1,e.lens,0,288,Q,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;N(2,e.lens,0,32,X,0,e.work,{bits:5}),Z=!1}e.lencode=Q,e.lenbits=9,e.distcode=X,e.distbits=5}function ee(e,t,n,i){var r,o=e.state;return null===o.window&&(o.wsize=1<<o.wbits,o.wnext=0,o.whave=0,o.window=k(o.wsize)),i>=o.wsize?(y(o.window,t,n-o.wsize,o.wsize,0),o.wnext=0,o.whave=o.wsize):((r=o.wsize-o.wnext)>i&&(r=i),y(o.window,t,n-i,r,o.wnext),(i-=r)?(y(o.window,t,n-i,i,0),o.wnext=i,o.whave=o.wsize):(o.wnext+=r,o.wnext===o.wsize&&(o.wnext=0),o.whave<o.wsize&&(o.whave+=r))),0}function te(e,t){var n,i,r,o,a,s,l,c,d,u,h,p,f,m,g,v,_,b,w,x,C,S,T,D,A=0,M=k(4),E=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return U;(n=e.state).mode===W&&(n.mode=13),a=e.next_out,r=e.output,l=e.avail_out,o=e.next_in,i=e.input,s=e.avail_in,c=n.hold,d=n.bits,u=s,h=l,S=0;e:for(;;)switch(n.mode){case 1:if(0===n.wrap){n.mode=13;break}for(;d<16;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(2&n.wrap&&35615===c){n.check=0,M[0]=255&c,M[1]=c>>>8&255,n.check=H(n.check,M,2,0),c=0,d=0,n.mode=2;break}if(n.flags=0,n.head&&(n.head.done=!1),!(1&n.wrap)||(((255&c)<<8)+(c>>8))%31){e.msg="incorrect header check",n.mode=j;break}if(8!=(15&c)){e.msg="unknown compression method",n.mode=j;break}if(d-=4,C=8+(15&(c>>>=4)),0===n.wbits)n.wbits=C;else if(C>n.wbits){e.msg="invalid window size",n.mode=j;break}n.dmax=1<<C,e.adler=n.check=1,n.mode=512&c?10:W,c=0,d=0;break;case 2:for(;d<16;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(n.flags=c,8!=(255&n.flags)){e.msg="unknown compression method",n.mode=j;break}if(57344&n.flags){e.msg="unknown header flags set",n.mode=j;break}n.head&&(n.head.text=c>>8&1),512&n.flags&&(M[0]=255&c,M[1]=c>>>8&255,n.check=H(n.check,M,2,0)),c=0,d=0,n.mode=3;case 3:for(;d<32;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}n.head&&(n.head.time=c),512&n.flags&&(M[0]=255&c,M[1]=c>>>8&255,M[2]=c>>>16&255,M[3]=c>>>24&255,n.check=H(n.check,M,4,0)),c=0,d=0,n.mode=4;case 4:for(;d<16;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}n.head&&(n.head.xflags=255&c,n.head.os=c>>8),512&n.flags&&(M[0]=255&c,M[1]=c>>>8&255,n.check=H(n.check,M,2,0)),c=0,d=0,n.mode=5;case 5:if(1024&n.flags){for(;d<16;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}n.length=c,n.head&&(n.head.extra_len=c),512&n.flags&&(M[0]=255&c,M[1]=c>>>8&255,n.check=H(n.check,M,2,0)),c=0,d=0}else n.head&&(n.head.extra=null);n.mode=6;case 6:if(1024&n.flags&&((p=n.length)>s&&(p=s),p&&(n.head&&(C=n.head.extra_len-n.length,n.head.extra||(n.head.extra=new Array(n.head.extra_len)),y(n.head.extra,i,o,p,C)),512&n.flags&&(n.check=H(n.check,i,p,o)),s-=p,o+=p,n.length-=p),n.length))break e;n.length=0,n.mode=7;case 7:if(2048&n.flags){if(0===s)break e;p=0;do{C=i[o+p++],n.head&&C&&n.length<65536&&(n.head.name+=String.fromCharCode(C))}while(C&&p<s);if(512&n.flags&&(n.check=H(n.check,i,p,o)),s-=p,o+=p,C)break e}else n.head&&(n.head.name=null);n.length=0,n.mode=8;case 8:if(4096&n.flags){if(0===s)break e;p=0;do{C=i[o+p++],n.head&&C&&n.length<65536&&(n.head.comment+=String.fromCharCode(C))}while(C&&p<s);if(512&n.flags&&(n.check=H(n.check,i,p,o)),s-=p,o+=p,C)break e}else n.head&&(n.head.comment=null);n.mode=9;case 9:if(512&n.flags){for(;d<16;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(c!==(65535&n.check)){e.msg="header crc mismatch",n.mode=j;break}c=0,d=0}n.head&&(n.head.hcrc=n.flags>>9&1,n.head.done=!0),e.adler=n.check=0,n.mode=W;break;case 10:for(;d<32;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}e.adler=n.check=q(c),c=0,d=0,n.mode=11;case 11:if(0===n.havedict)return e.next_out=a,e.avail_out=l,e.next_in=o,e.avail_in=s,n.hold=c,n.bits=d,2;e.adler=n.check=1,n.mode=W;case W:if(5===t||6===t)break e;case 13:if(n.last){c>>>=7&d,d-=7&d,n.mode=27;break}for(;d<3;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}switch(n.last=1&c,d-=1,3&(c>>>=1)){case 0:n.mode=14;break;case 1:if(J(n),n.mode=20,6===t){c>>>=2,d-=2;break e}break;case 2:n.mode=17;break;case 3:e.msg="invalid block type",n.mode=j}c>>>=2,d-=2;break;case 14:for(c>>>=7&d,d-=7&d;d<32;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if((65535&c)!=(c>>>16^65535)){e.msg="invalid stored block lengths",n.mode=j;break}if(n.length=65535&c,c=0,d=0,n.mode=15,6===t)break e;case 15:n.mode=16;case 16:if(p=n.length){if(p>s&&(p=s),p>l&&(p=l),0===p)break e;y(r,i,o,p,a),s-=p,o+=p,l-=p,a+=p,n.length-=p;break}n.mode=W;break;case 17:for(;d<14;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(n.nlen=257+(31&c),c>>>=5,d-=5,n.ndist=1+(31&c),c>>>=5,d-=5,n.ncode=4+(15&c),c>>>=4,d-=4,n.nlen>286||n.ndist>30){e.msg="too many length or distance symbols",n.mode=j;break}n.have=0,n.mode=18;case 18:for(;n.have<n.ncode;){for(;d<3;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}n.lens[E[n.have++]]=7&c,c>>>=3,d-=3}for(;n.have<19;)n.lens[E[n.have++]]=0;if(n.lencode=n.lendyn,n.lenbits=7,T={bits:n.lenbits},S=N(0,n.lens,0,19,n.lencode,0,n.work,T),n.lenbits=T.bits,S){e.msg="invalid code lengths set",n.mode=j;break}n.have=0,n.mode=19;case 19:for(;n.have<n.nlen+n.ndist;){for(;v=(A=n.lencode[c&(1<<n.lenbits)-1])>>>16&255,_=65535&A,!((g=A>>>24)<=d);){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(_<16)c>>>=g,d-=g,n.lens[n.have++]=_;else{if(16===_){for(D=g+2;d<D;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(c>>>=g,d-=g,0===n.have){e.msg="invalid bit length repeat",n.mode=j;break}C=n.lens[n.have-1],p=3+(3&c),c>>>=2,d-=2}else if(17===_){for(D=g+3;d<D;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}d-=g,C=0,p=3+(7&(c>>>=g)),c>>>=3,d-=3}else{for(D=g+7;d<D;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}d-=g,C=0,p=11+(127&(c>>>=g)),c>>>=7,d-=7}if(n.have+p>n.nlen+n.ndist){e.msg="invalid bit length repeat",n.mode=j;break}for(;p--;)n.lens[n.have++]=C}}if(n.mode===j)break;if(0===n.lens[256]){e.msg="invalid code -- missing end-of-block",n.mode=j;break}if(n.lenbits=9,T={bits:n.lenbits},S=N(1,n.lens,0,n.nlen,n.lencode,0,n.work,T),n.lenbits=T.bits,S){e.msg="invalid literal/lengths set",n.mode=j;break}if(n.distbits=6,n.distcode=n.distdyn,T={bits:n.distbits},S=N(2,n.lens,n.nlen,n.ndist,n.distcode,0,n.work,T),n.distbits=T.bits,S){e.msg="invalid distances set",n.mode=j;break}if(n.mode=20,6===t)break e;case 20:n.mode=21;case 21:if(s>=6&&l>=258){e.next_out=a,e.avail_out=l,e.next_in=o,e.avail_in=s,n.hold=c,n.bits=d,F(e,h),a=e.next_out,r=e.output,l=e.avail_out,o=e.next_in,i=e.input,s=e.avail_in,c=n.hold,d=n.bits,n.mode===W&&(n.back=-1);break}for(n.back=0;v=(A=n.lencode[c&(1<<n.lenbits)-1])>>>16&255,_=65535&A,!((g=A>>>24)<=d);){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(v&&!(240&v)){for(b=g,w=v,x=_;v=(A=n.lencode[x+((c&(1<<b+w)-1)>>b)])>>>16&255,_=65535&A,!(b+(g=A>>>24)<=d);){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}c>>>=b,d-=b,n.back+=b}if(c>>>=g,d-=g,n.back+=g,n.length=_,0===v){n.mode=26;break}if(32&v){n.back=-1,n.mode=W;break}if(64&v){e.msg="invalid literal/length code",n.mode=j;break}n.extra=15&v,n.mode=22;case 22:if(n.extra){for(D=n.extra;d<D;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}n.length+=c&(1<<n.extra)-1,c>>>=n.extra,d-=n.extra,n.back+=n.extra}n.was=n.length,n.mode=23;case 23:for(;v=(A=n.distcode[c&(1<<n.distbits)-1])>>>16&255,_=65535&A,!((g=A>>>24)<=d);){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(!(240&v)){for(b=g,w=v,x=_;v=(A=n.distcode[x+((c&(1<<b+w)-1)>>b)])>>>16&255,_=65535&A,!(b+(g=A>>>24)<=d);){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}c>>>=b,d-=b,n.back+=b}if(c>>>=g,d-=g,n.back+=g,64&v){e.msg="invalid distance code",n.mode=j;break}n.offset=_,n.extra=15&v,n.mode=24;case 24:if(n.extra){for(D=n.extra;d<D;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}n.offset+=c&(1<<n.extra)-1,c>>>=n.extra,d-=n.extra,n.back+=n.extra}if(n.offset>n.dmax){e.msg="invalid distance too far back",n.mode=j;break}n.mode=25;case 25:if(0===l)break e;if(p=h-l,n.offset>p){if((p=n.offset-p)>n.whave&&n.sane){e.msg="invalid distance too far back",n.mode=j;break}p>n.wnext?(p-=n.wnext,f=n.wsize-p):f=n.wnext-p,p>n.length&&(p=n.length),m=n.window}else m=r,f=a-n.offset,p=n.length;p>l&&(p=l),l-=p,n.length-=p;do{r[a++]=m[f++]}while(--p);0===n.length&&(n.mode=21);break;case 26:if(0===l)break e;r[a++]=n.length,l--,n.mode=21;break;case 27:if(n.wrap){for(;d<32;){if(0===s)break e;s--,c|=i[o++]<<d,d+=8}if(h-=l,e.total_out+=h,n.total+=h,h&&(e.adler=n.check=n.flags?H(n.check,r,h,a-h):z(n.check,r,h,a-h)),h=l,(n.flags?c:q(c))!==n.check){e.msg="incorrect data check",n.mode=j;break}c=0,d=0}n.mode=28;case 28:if(n.wrap&&n.flags){for(;d<32;){if(0===s)break e;s--,c+=i[o++]<<d,d+=8}if(c!==(4294967295&n.total)){e.msg="incorrect length check",n.mode=j;break}c=0,d=0}n.mode=29;case 29:S=1;break e;case j:S=-3;break e;case 31:return-4;default:return U}return e.next_out=a,e.avail_out=l,e.next_in=o,e.avail_in=s,n.hold=c,n.bits=d,(n.wsize||h!==e.avail_out&&n.mode<j&&(n.mode<27||4!==t))&&ee(e,e.output,e.next_out,h-e.avail_out),u-=e.avail_in,h-=e.avail_out,e.total_in+=u,e.total_out+=h,n.total+=h,n.wrap&&h&&(e.adler=n.check=n.flags?H(n.check,r,h,e.next_out-h):z(n.check,r,h,e.next_out-h)),e.data_type=n.bits+(n.last?64:0)+(n.mode===W?128:0)+(20===n.mode||15===n.mode?256:0),(0===u&&0===h||4===t)&&0===S&&(S=-5),S}function ne(e,t){var n,i=t.length;return e&&e.state?0!==(n=e.state).wrap&&11!==n.mode?U:11===n.mode&&z(1,t,i,0)!==n.check?-3:ee(e,t,i,i)?(n.mode=31,-4):(n.havedict=1,0):U}var ie={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"};function re(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}function oe(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}var ae=Object.prototype.toString,se=function e(t){if(!(this instanceof e))return new e(t);this.options=m({chunkSize:16384,windowBits:0,to:""},t||{});var n=this.options;n.raw&&n.windowBits>=0&&n.windowBits<16&&(n.windowBits=-n.windowBits,0===n.windowBits&&(n.windowBits=-15)),!(n.windowBits>=0&&n.windowBits<16)||t&&t.windowBits||(n.windowBits+=32),n.windowBits>15&&n.windowBits<48&&(15&n.windowBits||(n.windowBits|=15)),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new re,this.strm.avail_out=0;var i,r,o,a=Y(this.strm,n.windowBits);if(0!==a)throw new Error(ie[a]);if(this.header=new oe,i=this.strm,r=this.header,i&&i.state&&2&(o=i.state).wrap&&(o.head=r,r.done=!1),n.dictionary&&("string"==typeof n.dictionary?n.dictionary=A(n.dictionary):"[object ArrayBuffer]"===ae.call(n.dictionary)&&(n.dictionary=new Uint8Array(n.dictionary)),n.raw&&0!==(a=ne(this.strm,n.dictionary))))throw new Error(ie[a])};se.prototype.push=function(e,t){var n,i,r,o,a,s,l=this.strm,c=this.options.chunkSize,d=this.options.dictionary,u=!1;if(this.ended)return!1;i=t===~~t?t:!0===t?4:0,"string"==typeof e?l.input=function(e){for(var t=new Uint8Array(e.length),n=0,i=t.length;n<i;n++)t[n]=e.charCodeAt(n);return t}(e):"[object ArrayBuffer]"===ae.call(e)?l.input=new Uint8Array(e):l.input=e,l.next_in=0,l.avail_in=l.input.length;do{if(0===l.avail_out&&(l.output=k(c),l.next_out=0,l.avail_out=c),2===(n=te(l,0))&&d&&(s="string"==typeof d?A(d):"[object ArrayBuffer]"===ae.call(d)?new Uint8Array(d):d,n=ne(this.strm,s)),-5===n&&!0===u&&(n=0,u=!1),1!==n&&0!==n)return this.onEnd(n),this.ended=!0,!1;l.next_out&&(0!==l.avail_out&&1!==n&&(0!==l.avail_in||4!==i&&2!==i)||("string"===this.options.to?(r=I(l.output,l.next_out),o=l.next_out-r,a=E(l.output,r),l.next_out=o,l.avail_out=c-o,o&&y(l.output,l.output,r,o,0),this.onData(a)):this.onData(g(l.output,l.next_out)))),0===l.avail_in&&0===l.avail_out&&(u=!0)}while((l.avail_in>0||0===l.avail_out)&&1!==n);return 1===n&&(i=4),4===i?(n=function(e){if(!e||!e.state)return U;var t=e.state;return t.window&&(t.window=null),e.state=null,0}(this.strm),this.onEnd(n),this.ended=!0,0===n):2!==i||(this.onEnd(0),l.avail_out=0,!0)},se.prototype.onData=function(e){this.chunks.push(e)},se.prototype.onEnd=function(e){0===e&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=w(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};function le(e){for(var t=e.length;--t>=0;)e[t]=0}var ce,de,ue,he,pe,fe,me,ge,ve,_e=256,be=286,ye=30,we=15,ke=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],xe=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],Ce=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],Se=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];function Te(e,t,n,i,r){this.static_tree=e,this.extra_bits=t,this.extra_base=n,this.elems=i,this.max_length=r,this.has_stree=e&&e.length}function De(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}function Ae(e){return e<256?ue[e]:ue[256+(e>>>7)]}function Me(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255}function Ee(e,t,n){e.bi_valid>16-n?(e.bi_buf|=t<<e.bi_valid&65535,Me(e,e.bi_buf),e.bi_buf=t>>16-e.bi_valid,e.bi_valid+=n-16):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=n)}function Ie(e,t,n){Ee(e,n[2*t],n[2*t+1])}function ze(e,t){var n=0;do{n|=1&e,e>>>=1,n<<=1}while(--t>0);return n>>>1}function Pe(e,t,n){var i,r,o=new Array(16),a=0;for(i=1;i<=we;i++)o[i]=a=a+n[i-1]<<1;for(r=0;r<=t;r++){var s=e[2*r+1];0!==s&&(e[2*r]=ze(o[s]++,s))}}function He(e){var t;for(t=0;t<be;t++)e.dyn_ltree[2*t]=0;for(t=0;t<ye;t++)e.dyn_dtree[2*t]=0;for(t=0;t<19;t++)e.bl_tree[2*t]=0;e.dyn_ltree[512]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}function Fe(e){e.bi_valid>8?Me(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}function Re(e,t,n,i){var r=2*t,o=2*n;return e[r]<e[o]||e[r]===e[o]&&i[t]<=i[n]}function Le(e,t,n){for(var i=e.heap[n],r=n<<1;r<=e.heap_len&&(r<e.heap_len&&Re(t,e.heap[r+1],e.heap[r],e.depth)&&r++,!Re(t,i,e.heap[r],e.depth));)e.heap[n]=e.heap[r],n=r,r<<=1;e.heap[n]=i}function Be(e,t,n){var i,r,o,a,s=0;if(0!==e.last_lit)do{i=e.pending_buf[e.d_buf+2*s]<<8|e.pending_buf[e.d_buf+2*s+1],r=e.pending_buf[e.l_buf+s],s++,0===i?Ie(e,r,t):(Ie(e,(o=he[r])+_e+1,t),0!==(a=ke[o])&&Ee(e,r-=pe[o],a),Ie(e,o=Ae(--i),n),0!==(a=xe[o])&&Ee(e,i-=fe[o],a))}while(s<e.last_lit);Ie(e,256,t)}function Oe(e,t){var n,i,r,o=t.dyn_tree,a=t.stat_desc.static_tree,s=t.stat_desc.has_stree,l=t.stat_desc.elems,c=-1;for(e.heap_len=0,e.heap_max=573,n=0;n<l;n++)0!==o[2*n]?(e.heap[++e.heap_len]=c=n,e.depth[n]=0):o[2*n+1]=0;for(;e.heap_len<2;)o[2*(r=e.heap[++e.heap_len]=c<2?++c:0)]=1,e.depth[r]=0,e.opt_len--,s&&(e.static_len-=a[2*r+1]);for(t.max_code=c,n=e.heap_len>>1;n>=1;n--)Le(e,o,n);r=l;do{n=e.heap[1],e.heap[1]=e.heap[e.heap_len--],Le(e,o,1),i=e.heap[1],e.heap[--e.heap_max]=n,e.heap[--e.heap_max]=i,o[2*r]=o[2*n]+o[2*i],e.depth[r]=(e.depth[n]>=e.depth[i]?e.depth[n]:e.depth[i])+1,o[2*n+1]=o[2*i+1]=r,e.heap[1]=r++,Le(e,o,1)}while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],function(e,t){var n,i,r,o,a,s,l=t.dyn_tree,c=t.max_code,d=t.stat_desc.static_tree,u=t.stat_desc.has_stree,h=t.stat_desc.extra_bits,p=t.stat_desc.extra_base,f=t.stat_desc.max_length,m=0;for(o=0;o<=we;o++)e.bl_count[o]=0;for(l[2*e.heap[e.heap_max]+1]=0,n=e.heap_max+1;n<573;n++)(o=l[2*l[2*(i=e.heap[n])+1]+1]+1)>f&&(o=f,m++),l[2*i+1]=o,i>c||(e.bl_count[o]++,a=0,i>=p&&(a=h[i-p]),s=l[2*i],e.opt_len+=s*(o+a),u&&(e.static_len+=s*(d[2*i+1]+a)));if(0!==m){do{for(o=f-1;0===e.bl_count[o];)o--;e.bl_count[o]--,e.bl_count[o+1]+=2,e.bl_count[f]--,m-=2}while(m>0);for(o=f;0!==o;o--)for(i=e.bl_count[o];0!==i;)(r=e.heap[--n])>c||(l[2*r+1]!==o&&(e.opt_len+=(o-l[2*r+1])*l[2*r],l[2*r+1]=o),i--)}}(e,t),Pe(o,c,e.bl_count)}function Ve(e,t,n){var i,r,o=-1,a=t[1],s=0,l=7,c=4;for(0===a&&(l=138,c=3),t[2*(n+1)+1]=65535,i=0;i<=n;i++)r=a,a=t[2*(i+1)+1],++s<l&&r===a||(s<c?e.bl_tree[2*r]+=s:0!==r?(r!==o&&e.bl_tree[2*r]++,e.bl_tree[32]++):s<=10?e.bl_tree[34]++:e.bl_tree[36]++,s=0,o=r,0===a?(l=138,c=3):r===a?(l=6,c=3):(l=7,c=4))}function Ne(e,t,n){var i,r,o=-1,a=t[1],s=0,l=7,c=4;for(0===a&&(l=138,c=3),i=0;i<=n;i++)if(r=a,a=t[2*(i+1)+1],!(++s<l&&r===a)){if(s<c)do{Ie(e,r,e.bl_tree)}while(0!=--s);else 0!==r?(r!==o&&(Ie(e,r,e.bl_tree),s--),Ie(e,16,e.bl_tree),Ee(e,s-3,2)):s<=10?(Ie(e,17,e.bl_tree),Ee(e,s-3,3)):(Ie(e,18,e.bl_tree),Ee(e,s-11,7));s=0,o=r,0===a?(l=138,c=3):r===a?(l=6,c=3):(l=7,c=4)}}var $e=!1;function Ue(e){$e||(!function(){var e,t,n,i,r,o=new Array(16);for(le(ce=new Array(576)),le(de=new Array(60)),le(ue=new Array(512)),le(he=new Array(256)),le(pe=new Array(29)),le(fe=new Array(ye)),n=0,i=0;i<28;i++)for(pe[i]=n,e=0;e<1<<ke[i];e++)he[n++]=i;for(he[n-1]=i,r=0,i=0;i<16;i++)for(fe[i]=r,e=0;e<1<<xe[i];e++)ue[r++]=i;for(r>>=7;i<ye;i++)for(fe[i]=r<<7,e=0;e<1<<xe[i]-7;e++)ue[256+r++]=i;for(t=0;t<=we;t++)o[t]=0;for(e=0;e<=143;)ce[2*e+1]=8,e++,o[8]++;for(;e<=255;)ce[2*e+1]=9,e++,o[9]++;for(;e<=279;)ce[2*e+1]=7,e++,o[7]++;for(;e<=287;)ce[2*e+1]=8,e++,o[8]++;for(Pe(ce,287,o),e=0;e<ye;e++)de[2*e+1]=5,de[2*e]=ze(e,5);me=new Te(ce,ke,257,be,we),ge=new Te(de,xe,0,ye,we),ve=new Te(new Array(0),Ce,0,19,7)}(),$e=!0),e.l_desc=new De(e.dyn_ltree,me),e.d_desc=new De(e.dyn_dtree,ge),e.bl_desc=new De(e.bl_tree,ve),e.bi_buf=0,e.bi_valid=0,He(e)}function We(e,t,n,i){Ee(e,0+(i?1:0),3),function(e,t,n,i){Fe(e),i&&(Me(e,n),Me(e,~n)),y(e.pending_buf,e.window,t,n,e.pending),e.pending+=n}(e,t,n,!0)}function je(e){Ee(e,2,3),Ie(e,256,ce),function(e){16===e.bi_valid?(Me(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}(e)}function qe(e,t,n,i){var r,o,a=0;e.level>0?(2===e.strm.data_type&&(e.strm.data_type=function(e){var t,n=4093624447;for(t=0;t<=31;t++,n>>>=1)if(1&n&&0!==e.dyn_ltree[2*t])return 0;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return 1;for(t=32;t<_e;t++)if(0!==e.dyn_ltree[2*t])return 1;return 0}(e)),Oe(e,e.l_desc),Oe(e,e.d_desc),a=function(e){var t;for(Ve(e,e.dyn_ltree,e.l_desc.max_code),Ve(e,e.dyn_dtree,e.d_desc.max_code),Oe(e,e.bl_desc),t=18;t>=3&&0===e.bl_tree[2*Se[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}(e),r=e.opt_len+3+7>>>3,(o=e.static_len+3+7>>>3)<=r&&(r=o)):r=o=n+5,n+4<=r&&-1!==t?We(e,t,n,i):4===e.strategy||o===r?(Ee(e,2+(i?1:0),3),Be(e,ce,de)):(Ee(e,4+(i?1:0),3),function(e,t,n,i){var r;for(Ee(e,t-257,5),Ee(e,n-1,5),Ee(e,i-4,4),r=0;r<i;r++)Ee(e,e.bl_tree[2*Se[r]+1],3);Ne(e,e.dyn_ltree,t-1),Ne(e,e.dyn_dtree,n-1)}(e,e.l_desc.max_code+1,e.d_desc.max_code+1,a+1),Be(e,e.dyn_ltree,e.dyn_dtree)),He(e),i&&Fe(e)}function Ge(e,t,n){return e.pending_buf[e.d_buf+2*e.last_lit]=t>>>8&255,e.pending_buf[e.d_buf+2*e.last_lit+1]=255&t,e.pending_buf[e.l_buf+e.last_lit]=255&n,e.last_lit++,0===t?e.dyn_ltree[2*n]++:(e.matches++,t--,e.dyn_ltree[2*(he[n]+_e+1)]++,e.dyn_dtree[2*Ae(t)]++),e.last_lit===e.lit_bufsize-1}var Ke=258,Ye=262,Qe=103,Xe=113,Ze=666;function Je(e,t){return e.msg=ie[t],t}function et(e){return(e<<1)-(e>4?9:0)}function tt(e){for(var t=e.length;--t>=0;)e[t]=0}function nt(e){var t=e.state,n=t.pending;n>e.avail_out&&(n=e.avail_out),0!==n&&(y(e.output,t.pending_buf,t.pending_out,n,e.next_out),e.next_out+=n,t.pending_out+=n,e.total_out+=n,e.avail_out-=n,t.pending-=n,0===t.pending&&(t.pending_out=0))}function it(e,t){qe(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,nt(e.strm)}function rt(e,t){e.pending_buf[e.pending++]=t}function ot(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t}function at(e,t,n,i){var r=e.avail_in;return r>i&&(r=i),0===r?0:(e.avail_in-=r,y(t,e.input,e.next_in,r,n),1===e.state.wrap?e.adler=z(e.adler,t,r,n):2===e.state.wrap&&(e.adler=H(e.adler,t,r,n)),e.next_in+=r,e.total_in+=r,r)}function st(e,t){var n,i,r=e.max_chain_length,o=e.strstart,a=e.prev_length,s=e.nice_match,l=e.strstart>e.w_size-Ye?e.strstart-(e.w_size-Ye):0,c=e.window,d=e.w_mask,u=e.prev,h=e.strstart+Ke,p=c[o+a-1],f=c[o+a];e.prev_length>=e.good_match&&(r>>=2),s>e.lookahead&&(s=e.lookahead);do{if(c[(n=t)+a]===f&&c[n+a-1]===p&&c[n]===c[o]&&c[++n]===c[o+1]){o+=2,n++;do{}while(c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&o<h);if(i=Ke-(h-o),o=h-Ke,i>a){if(e.match_start=t,a=i,i>=s)break;p=c[o+a-1],f=c[o+a]}}}while((t=u[t&d])>l&&0!=--r);return a<=e.lookahead?a:e.lookahead}function lt(e){var t,n,i,r,o,a=e.w_size;do{if(r=e.window_size-e.lookahead-e.strstart,e.strstart>=a+(a-Ye)){y(e.window,e.window,a,a,0),e.match_start-=a,e.strstart-=a,e.block_start-=a,t=n=e.hash_size;do{i=e.head[--t],e.head[t]=i>=a?i-a:0}while(--n);t=n=a;do{i=e.prev[--t],e.prev[t]=i>=a?i-a:0}while(--n);r+=a}if(0===e.strm.avail_in)break;if(n=at(e.strm,e.window,e.strstart+e.lookahead,r),e.lookahead+=n,e.lookahead+e.insert>=3)for(o=e.strstart-e.insert,e.ins_h=e.window[o],e.ins_h=(e.ins_h<<e.hash_shift^e.window[o+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[o+3-1])&e.hash_mask,e.prev[o&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=o,o++,e.insert--,!(e.lookahead+e.insert<3)););}while(e.lookahead<Ye&&0!==e.strm.avail_in)}function ct(e,t){var n=65535;for(n>e.pending_buf_size-5&&(n=e.pending_buf_size-5);;){if(e.lookahead<=1){if(lt(e),0===e.lookahead&&0===t)return 1;if(0===e.lookahead)break}e.strstart+=e.lookahead,e.lookahead=0;var i=e.block_start+n;if((0===e.strstart||e.strstart>=i)&&(e.lookahead=e.strstart-i,e.strstart=i,it(e,!1),0===e.strm.avail_out))return 1;if(e.strstart-e.block_start>=e.w_size-Ye&&(it(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(it(e,!0),0===e.strm.avail_out?3:4):(e.strstart>e.block_start&&(it(e,!1),e.strm.avail_out),1)}function dt(e,t){for(var n,i;;){if(e.lookahead<Ye){if(lt(e),e.lookahead<Ye&&0===t)return 1;if(0===e.lookahead)break}if(n=0,e.lookahead>=3&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==n&&e.strstart-n<=e.w_size-Ye&&(e.match_length=st(e,n)),e.match_length>=3)if(i=Ge(e,e.strstart-e.match_start,e.match_length-3),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=3){e.match_length--;do{e.strstart++,e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart}while(0!=--e.match_length);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+1])&e.hash_mask;else i=Ge(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(i&&(it(e,!1),0===e.strm.avail_out))return 1}return e.insert=e.strstart<2?e.strstart:2,4===t?(it(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(it(e,!1),0===e.strm.avail_out)?1:2}function ut(e,t){for(var n,i,r;;){if(e.lookahead<Ye){if(lt(e),e.lookahead<Ye&&0===t)return 1;if(0===e.lookahead)break}if(n=0,e.lookahead>=3&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=2,0!==n&&e.prev_length<e.max_lazy_match&&e.strstart-n<=e.w_size-Ye&&(e.match_length=st(e,n),e.match_length<=5&&(1===e.strategy||3===e.match_length&&e.strstart-e.match_start>4096)&&(e.match_length=2)),e.prev_length>=3&&e.match_length<=e.prev_length){r=e.strstart+e.lookahead-3,i=Ge(e,e.strstart-1-e.prev_match,e.prev_length-3),e.lookahead-=e.prev_length-1,e.prev_length-=2;do{++e.strstart<=r&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+3-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart)}while(0!=--e.prev_length);if(e.match_available=0,e.match_length=2,e.strstart++,i&&(it(e,!1),0===e.strm.avail_out))return 1}else if(e.match_available){if((i=Ge(e,0,e.window[e.strstart-1]))&&it(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return 1}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(i=Ge(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<2?e.strstart:2,4===t?(it(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(it(e,!1),0===e.strm.avail_out)?1:2}function ht(e,t,n,i,r){this.good_length=e,this.max_lazy=t,this.nice_length=n,this.max_chain=i,this.func=r}var pt=function(){var e=[new ht(0,0,0,0,ct),new ht(4,4,8,4,dt),new ht(4,5,16,8,dt),new ht(4,6,32,32,dt),new ht(4,4,16,16,ut),new ht(8,16,32,32,ut),new ht(8,16,128,128,ut),new ht(8,32,128,256,ut),new ht(32,128,258,1024,ut),new ht(32,258,258,4096,ut)];return pt=function(){return e},e};function ft(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=8,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=x(1146),this.dyn_dtree=x(122),this.bl_tree=x(78),tt(this.dyn_ltree),tt(this.dyn_dtree),tt(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=x(16),this.heap=x(573),tt(this.heap),this.heap_len=0,this.heap_max=0,this.depth=x(573),tt(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function mt(e){var t=function(e){var t;return e&&e.state?(e.total_in=e.total_out=0,e.data_type=2,(t=e.state).pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap?42:Xe,e.adler=2===t.wrap?0:1,t.last_flush=0,Ue(t),0):Je(e,p)}(e);return 0===t&&function(e){e.window_size=2*e.w_size,tt(e.head);var t=pt();e.max_lazy_match=t[e.level].max_lazy,e.good_match=t[e.level].good_length,e.nice_match=t[e.level].nice_length,e.max_chain_length=t[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=2,e.match_available=0,e.ins_h=0}(e.state),t}function gt(e,t){var n,i,r,o;if(!e||!e.state||t>5||t<0)return e?Je(e,p):p;if(i=e.state,!e.output||!e.input&&0!==e.avail_in||i.status===Ze&&4!==t)return Je(e,0===e.avail_out?-5:p);if(i.strm=e,n=i.last_flush,i.last_flush=t,42===i.status)if(2===i.wrap)e.adler=0,rt(i,31),rt(i,139),rt(i,8),i.gzhead?(rt(i,(i.gzhead.text?1:0)+(i.gzhead.hcrc?2:0)+(i.gzhead.extra?4:0)+(i.gzhead.name?8:0)+(i.gzhead.comment?16:0)),rt(i,255&i.gzhead.time),rt(i,i.gzhead.time>>8&255),rt(i,i.gzhead.time>>16&255),rt(i,i.gzhead.time>>24&255),rt(i,9===i.level?2:i.strategy>=2||i.level<2?4:0),rt(i,255&i.gzhead.os),i.gzhead.extra&&i.gzhead.extra.length&&(rt(i,255&i.gzhead.extra.length),rt(i,i.gzhead.extra.length>>8&255)),i.gzhead.hcrc&&(e.adler=H(e.adler,i.pending_buf,i.pending,0)),i.gzindex=0,i.status=69):(rt(i,0),rt(i,0),rt(i,0),rt(i,0),rt(i,0),rt(i,9===i.level?2:i.strategy>=2||i.level<2?4:0),rt(i,3),i.status=Xe);else{var a=8+(i.w_bits-8<<4)<<8;a|=(i.strategy>=2||i.level<2?0:i.level<6?1:6===i.level?2:3)<<6,0!==i.strstart&&(a|=32),a+=31-a%31,i.status=Xe,ot(i,a),0!==i.strstart&&(ot(i,e.adler>>>16),ot(i,65535&e.adler)),e.adler=1}if(69===i.status)if(i.gzhead.extra){for(r=i.pending;i.gzindex<(65535&i.gzhead.extra.length)&&(i.pending!==i.pending_buf_size||(i.gzhead.hcrc&&i.pending>r&&(e.adler=H(e.adler,i.pending_buf,i.pending-r,r)),nt(e),r=i.pending,i.pending!==i.pending_buf_size));)rt(i,255&i.gzhead.extra[i.gzindex]),i.gzindex++;i.gzhead.hcrc&&i.pending>r&&(e.adler=H(e.adler,i.pending_buf,i.pending-r,r)),i.gzindex===i.gzhead.extra.length&&(i.gzindex=0,i.status=73)}else i.status=73;if(73===i.status)if(i.gzhead.name){r=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>r&&(e.adler=H(e.adler,i.pending_buf,i.pending-r,r)),nt(e),r=i.pending,i.pending===i.pending_buf_size)){o=1;break}o=i.gzindex<i.gzhead.name.length?255&i.gzhead.name.charCodeAt(i.gzindex++):0,rt(i,o)}while(0!==o);i.gzhead.hcrc&&i.pending>r&&(e.adler=H(e.adler,i.pending_buf,i.pending-r,r)),0===o&&(i.gzindex=0,i.status=91)}else i.status=91;if(91===i.status)if(i.gzhead.comment){r=i.pending;do{if(i.pending===i.pending_buf_size&&(i.gzhead.hcrc&&i.pending>r&&(e.adler=H(e.adler,i.pending_buf,i.pending-r,r)),nt(e),r=i.pending,i.pending===i.pending_buf_size)){o=1;break}o=i.gzindex<i.gzhead.comment.length?255&i.gzhead.comment.charCodeAt(i.gzindex++):0,rt(i,o)}while(0!==o);i.gzhead.hcrc&&i.pending>r&&(e.adler=H(e.adler,i.pending_buf,i.pending-r,r)),0===o&&(i.status=Qe)}else i.status=Qe;if(i.status===Qe&&(i.gzhead.hcrc?(i.pending+2>i.pending_buf_size&&nt(e),i.pending+2<=i.pending_buf_size&&(rt(i,255&e.adler),rt(i,e.adler>>8&255),e.adler=0,i.status=Xe)):i.status=Xe),0!==i.pending){if(nt(e),0===e.avail_out)return i.last_flush=-1,0}else if(0===e.avail_in&&et(t)<=et(n)&&4!==t)return Je(e,-5);if(i.status===Ze&&0!==e.avail_in)return Je(e,-5);if(0!==e.avail_in||0!==i.lookahead||0!==t&&i.status!==Ze){var s=2===i.strategy?function(e,t){for(var n;;){if(0===e.lookahead&&(lt(e),0===e.lookahead)){if(0===t)return 1;break}if(e.match_length=0,n=Ge(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,n&&(it(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(it(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(it(e,!1),0===e.strm.avail_out)?1:2}(i,t):3===i.strategy?function(e,t){for(var n,i,r,o,a=e.window;;){if(e.lookahead<=Ke){if(lt(e),e.lookahead<=Ke&&0===t)return 1;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=3&&e.strstart>0&&(i=a[r=e.strstart-1])===a[++r]&&i===a[++r]&&i===a[++r]){o=e.strstart+Ke;do{}while(i===a[++r]&&i===a[++r]&&i===a[++r]&&i===a[++r]&&i===a[++r]&&i===a[++r]&&i===a[++r]&&i===a[++r]&&r<o);e.match_length=Ke-(o-r),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=3?(n=Ge(e,1,e.match_length-3),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(n=Ge(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),n&&(it(e,!1),0===e.strm.avail_out))return 1}return e.insert=0,4===t?(it(e,!0),0===e.strm.avail_out?3:4):e.last_lit&&(it(e,!1),0===e.strm.avail_out)?1:2}(i,t):pt()[i.level].func(i,t);if(3!==s&&4!==s||(i.status=Ze),1===s||3===s)return 0===e.avail_out&&(i.last_flush=-1),0;if(2===s&&(1===t?je(i):5!==t&&(We(i,0,0,!1),3===t&&(tt(i.head),0===i.lookahead&&(i.strstart=0,i.block_start=0,i.insert=0))),nt(e),0===e.avail_out))return i.last_flush=-1,0}return 4!==t?0:i.wrap<=0?1:(2===i.wrap?(rt(i,255&e.adler),rt(i,e.adler>>8&255),rt(i,e.adler>>16&255),rt(i,e.adler>>24&255),rt(i,255&e.total_in),rt(i,e.total_in>>8&255),rt(i,e.total_in>>16&255),rt(i,e.total_in>>24&255)):(ot(i,e.adler>>>16),ot(i,65535&e.adler)),nt(e),i.wrap>0&&(i.wrap=-i.wrap),0!==i.pending?0:1)}var vt=Object.prototype.toString,_t=function(e){this.options=m({level:-1,method:8,chunkSize:16384,windowBits:15,memLevel:8,strategy:0,to:""},e||{});var t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new re,this.strm.avail_out=0;var n,i,r=function(e,t,n,i,r,o){if(!e)return p;var a=1;if(-1===t&&(t=6),i<0?(a=0,i=-i):i>15&&(a=2,i-=16),r<1||r>9||8!==n||i<8||i>15||t<0||t>9||o<0||o>4)return Je(e,p);8===i&&(i=9);var s=new ft;return e.state=s,s.strm=e,s.wrap=a,s.gzhead=null,s.w_bits=i,s.w_size=1<<s.w_bits,s.w_mask=s.w_size-1,s.hash_bits=r+7,s.hash_size=1<<s.hash_bits,s.hash_mask=s.hash_size-1,s.hash_shift=~~((s.hash_bits+3-1)/3),s.window=k(2*s.w_size),s.head=x(s.hash_size),s.prev=x(s.w_size),s.lit_bufsize=1<<r+6,s.pending_buf_size=4*s.lit_bufsize,s.pending_buf=k(s.pending_buf_size),s.d_buf=1*s.lit_bufsize,s.l_buf=3*s.lit_bufsize,s.level=t,s.strategy=o,s.method=n,mt(e)}(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(0!==r)throw new Error(ie[r]);if(t.header&&(n=this.strm,i=t.header,n&&n.state&&(2!==n.state.wrap||(n.state.gzhead=i))),t.dictionary){var o;if(o="string"==typeof t.dictionary?A(t.dictionary):"[object ArrayBuffer]"===vt.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,r=function(e,t){var n,i,r,o,a,s,l,c,d=t.length;if(!e||!e.state)return p;if(2===(o=(n=e.state).wrap)||1===o&&42!==n.status||n.lookahead)return p;for(1===o&&(e.adler=z(e.adler,t,d,0)),n.wrap=0,d>=n.w_size&&(0===o&&(tt(n.head),n.strstart=0,n.block_start=0,n.insert=0),c=k(n.w_size),y(c,t,d-n.w_size,n.w_size,0),t=c,d=n.w_size),a=e.avail_in,s=e.next_in,l=e.input,e.avail_in=d,e.next_in=0,e.input=t,lt(n);n.lookahead>=3;){i=n.strstart,r=n.lookahead-2;do{n.ins_h=(n.ins_h<<n.hash_shift^n.window[i+3-1])&n.hash_mask,n.prev[i&n.w_mask]=n.head[n.ins_h],n.head[n.ins_h]=i,i++}while(--r);n.strstart=i,n.lookahead=2,lt(n)}return n.strstart+=n.lookahead,n.block_start=n.strstart,n.insert=n.lookahead,n.lookahead=0,n.match_length=n.prev_length=2,n.match_available=0,e.next_in=s,e.input=l,e.avail_in=a,n.wrap=o,0}(this.strm,o),0!==r)throw new Error(ie[r]);this._dict_set=!0}};function bt(e,t){var n=new _t(t);if(n.push(e,!0),n.err)throw n.msg||ie[n.err];return n.result}_t.prototype.push=function(e,t){var n,i,r,o=this.strm,a=this.options.chunkSize;if(this.ended)return!1;i=t===~~t?t:!0===t?4:0,"string"==typeof e?o.input=A(e):"[object ArrayBuffer]"===vt.call(e)?o.input=new Uint8Array(e):o.input=e,o.next_in=0,o.avail_in=o.input.length;do{if(0===o.avail_out&&(o.output=k(a),o.next_out=0,o.avail_out=a),1!==(n=gt(o,i))&&0!==n)return this.onEnd(n),this.ended=!0,!1;0!==o.avail_out&&(0!==o.avail_in||4!==i&&2!==i)||("string"===this.options.to?this.onData(M(r=g(o.output,o.next_out),r.length)):this.onData(g(o.output,o.next_out)))}while((o.avail_in>0||0===o.avail_out)&&1!==n);return 4===i?(n=function(e){var t;return e&&e.state?42!==(t=e.state.status)&&69!==t&&73!==t&&91!==t&&t!==Qe&&t!==Xe&&t!==Ze?Je(e,p):(e.state=null,t===Xe?Je(e,-3):0):p}(this.strm),this.onEnd(n),this.ended=!0,0===n):2!==i||(this.onEnd(0),o.avail_out=0,!0)},_t.prototype.onData=function(e){this.chunks.push(e)},_t.prototype.onEnd=function(e){0===e&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=w(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg};var yt={Promise:Promise},wt={base64:!0,array:!0,string:!0,nodebuffer:!1,nodestream:!1,get arraybuffer(){return"undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array},get uint8array(){return"undefined"!=typeof Uint8Array},get blob(){return kt()}},kt=function(){var e;if("undefined"==typeof ArrayBuffer)e=!1;else{var t=new ArrayBuffer(0);try{e=0===new Blob([t],{type:"application/zip"}).size}catch(t){e=!1}}return kt=function(){return e},e},xt="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function Ct(e){return e}function St(e,t){for(var n=0;n<e.length;++n)t[n]=255&e.charCodeAt(n);return t}function Tt(e,t,n){var i=[],r=0,o=e.length;if(o<=n)return String.fromCharCode.apply(null,e);for(;r<o;)"array"===t?i.push(String.fromCharCode.apply(null,e.slice(r,Math.min(r+n,o)))):i.push(String.fromCharCode.apply(null,e.subarray(r,Math.min(r+n,o)))),r+=n;return i.join("")}var Dt=function(){var e;try{e=wt.uint8array&&1===String.fromCharCode.apply(null,new Uint8Array(1)).length}catch(t){e=!1}return Dt=function(){return e},e};function At(e){var t=65536,n=Pt(e),i=!0;if("uint8array"===n&&(i=Dt()),i)for(;t>1;)try{return Tt(e,n,t)}catch(e){t=Math.floor(t/2)}return function(e){for(var t="",n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return t}(e)}var Mt=At;function Et(e,t){for(var n=0;n<e.length;n++)t[n]=e[n];return t}var It={string:{string:Ct,array:function(e){return St(e,new Array(e.length))},arraybuffer:function(e){return It.string.uint8array(e).buffer},uint8array:function(e){return St(e,new Uint8Array(e.length))}},array:{string:At,array:Ct,arraybuffer:function(e){return new Uint8Array(e).buffer},uint8array:function(e){return new Uint8Array(e)}},arraybuffer:{string:function(e){return At(new Uint8Array(e))},array:function(e){return Et(new Uint8Array(e),new Array(e.byteLength))},arraybuffer:Ct,uint8array:function(e){return new Uint8Array(e)}},uint8array:{string:At,array:function(e){return Et(e,new Array(e.length))},arraybuffer:function(e){return e.buffer},uint8array:Ct}},zt=function(e,t){if(t||(t=""),!e)return t;Ht(e);var n=Pt(t);return It[n][e](t)},Pt=function(e){return"string"==typeof e?"string":"[object Array]"===Object.prototype.toString.call(e)?"array":wt.uint8array&&e instanceof Uint8Array?"uint8array":wt.arraybuffer&&e instanceof ArrayBuffer?"arraybuffer":void 0},Ht=function(e){if(!wt[e.toLowerCase()])throw new Error(e+" is not supported by this platform")},Ft=65535,Rt=-1,Lt=function(e){var t,n,i="";for(n=0;n<(e||"").length;n++)i+="\\x"+((t=e.charCodeAt(n))<16?"0":"")+t.toString(16).toUpperCase();return i},Bt=function(e,t,n){setTimeout((function(){e.apply(n||null,t||[])}),0)},Ot=function(){var e,t,n=arguments,i={};for(e=0;e<arguments.length;e++)for(t in arguments[e])Object.hasOwnProperty.call(n[e],t)&&void 0===i[t]&&(i[t]=n[e][t]);return i},Vt=function(e,t,n,i,r){return yt.Promise.resolve(t).then((function(e){return wt.blob&&(e instanceof Blob||-1!==["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(e)))&&"undefined"!=typeof FileReader?new yt.Promise((function(t,n){var i=new FileReader;i.onload=function(e){t(e.target.result)},i.onerror=function(e){n(e.target.error)},i.readAsArrayBuffer(e)})):e})).then((function(t){var o,a=Pt(t);return a?("arraybuffer"===a?t=zt("uint8array",t):"string"===a&&(r?t=function(e){var t,n,i,r,o,a,s=0,l=0,c="data:";if(e.substr(0,5)===c)throw new Error("Invalid base64 input, it looks like a data url.");var d,u=3*(e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"")).length/4;if(e.charAt(e.length-1)===xt.charAt(64)&&u--,e.charAt(e.length-2)===xt.charAt(64)&&u--,u%1!=0)throw new Error("Invalid base64 input, bad content length.");for(d=wt.uint8array?new Uint8Array(0|u):new Array(0|u);s<e.length;)t=xt.indexOf(e.charAt(s++))<<2|(r=xt.indexOf(e.charAt(s++)))>>4,n=(15&r)<<4|(o=xt.indexOf(e.charAt(s++)))>>2,i=(3&o)<<6|(a=xt.indexOf(e.charAt(s++))),d[l++]=t,64!==o&&(d[l++]=n),64!==a&&(d[l++]=i);return d}(t):n&&!0!==i&&(t=St(o=t,wt.uint8array?new Uint8Array(o.length):new Array(o.length)))),t):yt.Promise.reject(new Error("Can't read the data of '"+e+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))}))},Nt=function(e){this.name=e||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null};Nt.prototype.push=function(e){this.emit("data",e)},Nt.prototype.end=function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(e){this.emit("error",e)}return!0},Nt.prototype.error=function(e){return!this.isFinished&&(this.isPaused?this.generatedError=e:(this.isFinished=!0,this.emit("error",e),this.previous&&this.previous.error(e),this.cleanUp()),!0)},Nt.prototype.on=function(e,t){return this._listeners[e].push(t),this},Nt.prototype.cleanUp=function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},Nt.prototype.emit=function(e,t){if(this._listeners[e])for(var n=0;n<this._listeners[e].length;n++)this._listeners[e][n].call(this,t)},Nt.prototype.pipe=function(e){return e.registerPrevious(this)},Nt.prototype.registerPrevious=function(e){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=e.streamInfo,this.mergeStreamInfo(),this.previous=e;var t=this;return e.on("data",(function(e){t.processChunk(e)})),e.on("end",(function(){t.end()})),e.on("error",(function(e){t.error(e)})),this},Nt.prototype.pause=function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},Nt.prototype.resume=function(){if(!this.isPaused||this.isFinished)return!1;this.isPaused=!1;var e=!1;return this.generatedError&&(this.error(this.generatedError),e=!0),this.previous&&this.previous.resume(),!e},Nt.prototype.flush=function(){},Nt.prototype.processChunk=function(e){this.push(e)},Nt.prototype.withStreamInfo=function(e,t){return this.extraStreamInfo[e]=t,this.mergeStreamInfo(),this},Nt.prototype.mergeStreamInfo=function(){for(var e in this.extraStreamInfo)this.extraStreamInfo.hasOwnProperty(e)&&(this.streamInfo[e]=this.extraStreamInfo[e])},Nt.prototype.lock=function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},Nt.prototype.toString=function(){var e="Worker "+this.name;return this.previous?this.previous+" -> "+e:e};var $t=function(e){for(var t=new Array(256),n=0;n<256;n++)t[n]=n>=252?6:n>=248?5:n>=240?4:n>=224?3:n>=192?2:1;return t[254]=t[254]=1,$t=function(e){return t[e]},t[e]},Ut=function(e){return function(e){var t,n,i,r,o,a=e.length,s=0;for(r=0;r<a;r++)55296==(64512&(n=e.charCodeAt(r)))&&r+1<a&&56320==(64512&(i=e.charCodeAt(r+1)))&&(n=65536+(n-55296<<10)+(i-56320),r++),s+=n<128?1:n<2048?2:n<65536?3:4;for(t=wt.uint8array?new Uint8Array(s):new Array(s),o=0,r=0;o<s;r++)55296==(64512&(n=e.charCodeAt(r)))&&r+1<a&&56320==(64512&(i=e.charCodeAt(r+1)))&&(n=65536+(n-55296<<10)+(i-56320),r++),n<128?t[o++]=n:n<2048?(t[o++]=192|n>>>6,t[o++]=128|63&n):n<65536?(t[o++]=224|n>>>12,t[o++]=128|n>>>6&63,t[o++]=128|63&n):(t[o++]=240|n>>>18,t[o++]=128|n>>>12&63,t[o++]=128|n>>>6&63,t[o++]=128|63&n);return t}(e)},Wt=function(e){return function(e){var t,n,i,r,o=e.length,a=new Array(2*o);for(n=0,t=0;t<o;)if((i=e[t++])<128)a[n++]=i;else if((r=$t(i))>4)a[n++]=65533,t+=r-1;else{for(i&=2===r?31:3===r?15:7;r>1&&t<o;)i=i<<6|63&e[t++],r--;r>1?a[n++]=65533:i<65536?a[n++]=i:(i-=65536,a[n++]=55296|i>>10&1023,a[n++]=56320|1023&i)}return a.length!==n&&(a.subarray?a=a.subarray(0,n):a.length=n),Mt(a)}(e=zt(wt.uint8array?"uint8array":"array",e))},jt=function(e){function t(){e.call(this,"utf-8 decode"),this.leftOver=null}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.processChunk=function(e){var t=zt(wt.uint8array?"uint8array":"array",e.data);if(this.leftOver&&this.leftOver.length){if(wt.uint8array){var n=t;(t=new Uint8Array(n.length+this.leftOver.length)).set(this.leftOver,0),t.set(n,this.leftOver.length)}else t=this.leftOver.concat(t);this.leftOver=null}var i=function(e,t){var n;for((t=t||e.length)>e.length&&(t=e.length),n=t-1;n>=0&&128==(192&e[n]);)n--;return n<0||0===n?t:n+$t(e[n])>t?n:t}(t),r=t;i!==t.length&&(wt.uint8array?(r=t.subarray(0,i),this.leftOver=t.subarray(i,t.length)):(r=t.slice(0,i),this.leftOver=t.slice(i,t.length))),this.push({data:Wt(r),meta:e.meta})},t.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:Wt(this.leftOver),meta:{}}),this.leftOver=null)},t}(Nt),qt=function(e){function t(){e.call(this,"utf-8 encode")}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.processChunk=function(e){this.push({data:Ut(e.data),meta:e.meta})},t}(Nt),Gt=function(e){function t(t){e.call(this,"ConvertWorker to "+t),this.destType=t}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.processChunk=function(e){this.push({data:zt(this.destType,e.data),meta:e.meta})},t}(Nt);function Kt(e,t,n){switch(e){case"blob":return function(e,t){return Ht("blob"),new Blob([e],{type:t})}(zt("arraybuffer",t),n);case"base64":return function(e){for(var t,n,i,r,o,a,s,l=[],c=0,d=e.length,u=d,h="string"!=typeof e;c<e.length;)u=d-c,h?(t=e[c++],n=c<d?e[c++]:0,i=c<d?e[c++]:0):(t=e.charCodeAt(c++),n=c<d?e.charCodeAt(c++):0,i=c<d?e.charCodeAt(c++):0),r=t>>2,o=(3&t)<<4|n>>4,a=u>1?(15&n)<<2|i>>6:64,s=u>2?63&i:64,l.push(xt.charAt(r)+xt.charAt(o)+xt.charAt(a)+xt.charAt(s));return l.join("")}(t);default:return zt(e,t)}}function Yt(e,t){return new yt.Promise((function(n,i){var r=[],o=e._internalType,a=e._outputType,s=e._mimeType;e.on("data",(function(e,n){r.push(e),t&&t(n)})).on("error",(function(e){r=[],i(e)})).on("end",(function(){try{var e=Kt(a,function(e,t){var n,i=0,r=null,o=0;for(n=0;n<t.length;n++)o+=t[n].length;switch(e){case"string":return t.join("");case"array":return Array.prototype.concat.apply([],t);case"uint8array":for(r=new Uint8Array(o),n=0;n<t.length;n++)r.set(t[n],i),i+=t[n].length;return r;default:throw new Error("concat : unsupported type '"+e+"'")}}(o,r),s);n(e)}catch(e){i(e)}r=[]})).resume()}))}var Qt=function(e,t,n){var i=t;switch(t){case"blob":case"arraybuffer":i="uint8array";break;case"base64":i="string"}try{this._internalType=i,this._outputType=t,this._mimeType=n,Ht(i),this._worker=e.pipe(new Gt(i)),e.lock()}catch(e){this._worker=new Nt("error"),this._worker.error(e)}};Qt.prototype.accumulate=function(e){return Yt(this,e)},Qt.prototype.on=function(e,t){var n=this;return"data"===e?this._worker.on(e,(function(e){t.call(n,e.data,e.meta)})):this._worker.on(e,(function(){Bt(t,arguments,n)})),this},Qt.prototype.resume=function(){return Bt(this._worker.resume,[],this._worker),this},Qt.prototype.pause=function(){return this._worker.pause(),this};var Xt=!0,Zt=Object.freeze({__proto__:null,base64:!1,binary:!1,dir:!1,createFolders:Xt,date:null,compression:null,compressionOptions:null,comment:null,unixPermissions:null,dosPermissions:null}),Jt=function(e){function t(t){e.call(this,"DataWorker");var n=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,t.then((function(e){n.dataIsReady=!0,n.data=e,n.max=e&&e.length||0,n.type=Pt(e),n.isPaused||n._tickAndRepeat()}),(function(e){n.error(e)}))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.cleanUp=function(){e.prototype.cleanUp.call(this),this.data=null},t.prototype.resume=function(){return!!e.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,Bt(this._tickAndRepeat,[],this)),!0)},t.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(Bt(this._tickAndRepeat,[],this),this._tickScheduled=!0))},t.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var e=null,t=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":e=this.data.substring(this.index,t);break;case"uint8array":e=this.data.subarray(this.index,t);break;case"array":e=this.data.slice(this.index,t)}return this.index=t,this.push({data:e,meta:{percent:this.max?this.index/this.max*100:0}})},t}(Nt),en=function(e){function t(t){e.call(this,"DataLengthProbe for "+t),this.propName=t,this.withStreamInfo(t,0)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.processChunk=function(t){if(t){var n=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=n+t.data.length}e.prototype.processChunk.call(this,t)},t}(Nt),tn=function(){for(var e=[],t=0;t<256;t++){for(var n=t,i=0;i<8;i++)n=1&n?3988292384^n>>>1:n>>>1;e[t]=n}return tn=function(){return e},e};function nn(e,t){return void 0!==e&&e.length?"string"!==Pt(e)?function(e,t,n,i){var r=tn(),o=i+n;e=~e;for(var a=i;a<o;a++)e=e>>>8^r[255&(e^t[a])];return~e}(0|t,e,e.length,0):function(e,t,n,i){var r=tn(),o=i+n;e=~e;for(var a=i;a<o;a++)e=e>>>8^r[255&(e^t.charCodeAt(a))];return~e}(0|t,e,e.length,0):0}var rn=function(e){function t(){e.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.processChunk=function(e){this.streamInfo.crc32=nn(e.data,this.streamInfo.crc32||0),this.push(e)},t}(Nt),on=function(e,t,n,i,r){this.compressedSize=e,this.uncompressedSize=t,this.crc32=n,this.compression=i,this.compressedContent=r};on.prototype.getContentWorker=function(){var e=new Jt(yt.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new en("data_length")),t=this;return e.on("end",(function(){if(this.streamInfo.data_length!==t.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")})),e},on.prototype.getCompressedWorker=function(){return new Jt(yt.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)},on.createWorkerFrom=function(e,t,n){return e.pipe(new rn).pipe(new en("uncompressedSize")).pipe(t.compressWorker(n)).pipe(new en("compressedSize")).withStreamInfo("compression",t)};var an=function(e,t,n){this.name=e,this.dir=n.dir,this.date=n.date,this.comment=n.comment,this.unixPermissions=n.unixPermissions,this.dosPermissions=n.dosPermissions,this._data=t,this._dataBinary=n.binary,this.options={compression:n.compression,compressionOptions:n.compressionOptions}};an.prototype.internalStream=function(e){var t=null,n="string";try{if(!e)throw new Error("No output type specified.");var i="string"===(n=e.toLowerCase())||"text"===n;"binarystring"!==n&&"text"!==n||(n="string"),t=this._decompressWorker();var r=!this._dataBinary;r&&!i&&(t=t.pipe(new qt)),!r&&i&&(t=t.pipe(new jt))}catch(e){(t=new Nt("error")).error(e)}return new Qt(t,n,"")},an.prototype.async=function(e,t){return this.internalStream(e).accumulate(t)},an.prototype._compressWorker=function(e,t){if(this._data instanceof on&&this._data.compression.magic===e.magic)return this._data.getCompressedWorker();var n=this._decompressWorker();return this._dataBinary||(n=n.pipe(new qt)),on.createWorkerFrom(n,e,t)},an.prototype._decompressWorker=function(){return this._data instanceof on?this._data.getContentWorker():this._data instanceof Nt?this._data:new Jt(this._data)};var sn=function(){var e="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Uint32Array?"uint8array":"array";sn=function(){return e}},ln=function(e){function t(t,n){e.call(this,"FlateWorker/"+t),this._pako=null,this._pakoAction=t,this._pakoOptions=n,this.meta={}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.processChunk=function(e){this.meta=e.meta,null===this._pako&&this._createPako(),this._pako.push(zt(sn(),e.data),!1)},t.prototype.flush=function(){e.prototype.flush.call(this),null===this._pako&&this._createPako(),this._pako.push([],!0)},t.prototype.cleanUp=function(){e.prototype.cleanUp.call(this),this._pako=null},t.prototype._createPako=function(){var e=this,t={raw:!0,level:this._pakoOptions.level||-1};this._pako="Deflate"===this._pakoAction?new _t(t):new se(t),this._pako.onData=function(t){e.push({data:t,meta:e.meta})}},t}(Nt),cn={magic:"\b\0",compressWorker:function(e){return new ln("Deflate",e)},uncompressWorker:function(){return new ln("Inflate",{})}},dn={STORE:{magic:"\0\0",compressWorker:function(){return new Nt("STORE compression")},uncompressWorker:function(){return new Nt("STORE decompression")}},DEFLATE:cn},un="PK",hn="PK",pn="PK",fn="PK",mn="PK",gn=function(e,t){var n,i="";for(n=0;n<t;n++)i+=String.fromCharCode(255&e),e>>>=8;return i},vn=function(e,t,n,i,r,o){var a,s,l=e.file,c=e.compression,d=o!==Ut,u=zt("string",o(l.name)),h=zt("string",Ut(l.name)),p=l.comment,f=zt("string",o(p)),m=zt("string",Ut(p)),g=h.length!==l.name.length,v=m.length!==p.length,_="",b="",y="",w=l.dir,k=l.date,x={crc32:0,compressedSize:0,uncompressedSize:0};t&&!n||(x.crc32=e.crc32,x.compressedSize=e.compressedSize,x.uncompressedSize=e.uncompressedSize);var C=0;t&&(C|=8),d||!g&&!v||(C|=2048);var S=0,T=0;w&&(S|=16),"UNIX"===r?(T=798,S|=function(e,t){var n=e;return e||(n=t?16893:33204),(65535&n)<<16}(l.unixPermissions,w)):(T=20,S|=function(e){return 63&(e||0)}(l.dosPermissions)),a=k.getUTCHours(),a<<=6,a|=k.getUTCMinutes(),a<<=5,a|=k.getUTCSeconds()/2,s=k.getUTCFullYear()-1980,s<<=4,s|=k.getUTCMonth()+1,s<<=5,s|=k.getUTCDate(),g&&(b=gn(1,1)+gn(nn(u),4)+h,_+="up"+gn(b.length,2)+b),v&&(y=gn(1,1)+gn(nn(f),4)+m,_+="uc"+gn(y.length,2)+y);var D="";return D+="\n\0",D+=gn(C,2),D+=c.magic,D+=gn(a,2),D+=gn(s,2),D+=gn(x.crc32,4),D+=gn(x.compressedSize,4),D+=gn(x.uncompressedSize,4),D+=gn(u.length,2),D+=gn(_.length,2),{fileRecord:un+D+u+_,dirRecord:hn+gn(T,2)+D+gn(f.length,2)+"\0\0\0\0"+gn(S,4)+gn(i,4)+u+_+f}},_n=function(e){return"PK\b"+gn(e.crc32,4)+gn(e.compressedSize,4)+gn(e.uncompressedSize,4)},bn=function(e){function t(t,n,i,r){e.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=n,this.zipPlatform=i,this.encodeFileName=r,this.streamFiles=t,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.push=function(t){var n=t.meta.percent||0,i=this.entriesCount,r=this._sources.length;this.accumulate?this.contentBuffer.push(t):(this.bytesWritten+=t.data.length,e.prototype.push.call(this,{data:t.data,meta:{currentFile:this.currentFile,percent:i?(n+100*(i-r-1))/i:100}}))},t.prototype.openedSource=function(e){this.currentSourceOffset=this.bytesWritten,this.currentFile=e.file.name;var t=this.streamFiles&&!e.file.dir;if(t){var n=vn(e,t,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:n.fileRecord,meta:{percent:0}})}else this.accumulate=!0},t.prototype.closedSource=function(e){this.accumulate=!1;var t=this.streamFiles&&!e.file.dir,n=vn(e,t,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(n.dirRecord),t)this.push({data:_n(e),meta:{percent:100}});else for(this.push({data:n.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},t.prototype.flush=function(){for(var e=this.bytesWritten,t=0;t<this.dirRecords.length;t++)this.push({data:this.dirRecords[t],meta:{percent:100}});var n=this.bytesWritten-e,i=function(e,t,n,i,r){var o=zt("string",r(i));return pn+"\0\0\0\0"+gn(e,2)+gn(e,2)+gn(t,4)+gn(n,4)+gn(o.length,2)+o}(this.dirRecords.length,n,e,this.zipComment,this.encodeFileName);this.push({data:i,meta:{percent:100}})},t.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},t.prototype.registerPrevious=function(e){this._sources.push(e);var t=this;return e.on("data",(function(e){t.processChunk(e)})),e.on("end",(function(){t.closedSource(t.previous.streamInfo),t._sources.length?t.prepareNextSource():t.end()})),e.on("error",(function(e){t.error(e)})),this},t.prototype.resume=function(){return!!e.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},t.prototype.error=function(t){var n=this._sources;if(!e.prototype.error.call(this,t))return!1;for(var i=0;i<n.length;i++)try{n[i].error(t)}catch(e){}return!0},t.prototype.lock=function(){e.prototype.lock.call(this);for(var t=this._sources,n=0;n<t.length;n++)t[n].lock()},t}(Nt),yn=function(e,t,n){var i=new bn(t.streamFiles,n,t.platform,t.encodeFileName),r=0;try{e.forEach((function(e,n){r++;var o=function(e,t){var n=e||t,i=dn[n];if(!i)throw new Error(n+" is not a valid compression method !");return i}(n.options.compression,t.compression),a=n.options.compressionOptions||t.compressionOptions||{},s=n.dir,l=n.date;n._compressWorker(o,a).withStreamInfo("file",{name:e,dir:s,date:l,comment:n.comment||"",unixPermissions:n.unixPermissions,dosPermissions:n.dosPermissions}).pipe(i)})),i.entriesCount=r}catch(e){i.error(e)}return i},wn=function(e){this.data=e,this.length=e.length,this.index=0,this.zero=0};wn.prototype.checkOffset=function(e){this.checkIndex(this.index+e)},wn.prototype.checkIndex=function(e){if(this.length<this.zero+e||e<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+e+"). Corrupted zip ?")},wn.prototype.setIndex=function(e){this.checkIndex(e),this.index=e},wn.prototype.skip=function(e){this.setIndex(this.index+e)},wn.prototype.byteAt=function(e){},wn.prototype.readInt=function(e){var t,n=0;for(this.checkOffset(e),t=this.index+e-1;t>=this.index;t--)n=(n<<8)+this.byteAt(t);return this.index+=e,n},wn.prototype.readString=function(e){return zt("string",this.readData(e))},wn.prototype.readData=function(e){},wn.prototype.lastIndexOfSignature=function(e){},wn.prototype.readAndCheckSignature=function(e){},wn.prototype.readDate=function(){var e=this.readInt(4);return new Date(Date.UTC(1980+(e>>25&127),(e>>21&15)-1,e>>16&31,e>>11&31,e>>5&63,(31&e)<<1))};var kn=function(e){function t(t){e.call(this,t);for(var n=0;n<this.data.length;n++)t[n]=255&t[n]}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.byteAt=function(e){return this.data[this.zero+e]},t.prototype.lastIndexOfSignature=function(e){for(var t=e.charCodeAt(0),n=e.charCodeAt(1),i=e.charCodeAt(2),r=e.charCodeAt(3),o=this.length-4;o>=0;--o)if(this.data[o]===t&&this.data[o+1]===n&&this.data[o+2]===i&&this.data[o+3]===r)return o-this.zero;return-1},t.prototype.readAndCheckSignature=function(e){var t=e.charCodeAt(0),n=e.charCodeAt(1),i=e.charCodeAt(2),r=e.charCodeAt(3),o=this.readData(4);return t===o[0]&&n===o[1]&&i===o[2]&&r===o[3]},t.prototype.readData=function(e){if(this.checkOffset(e),0===e)return[];var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t}(wn),xn=function(e){function t(t){e.call(this,t)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.byteAt=function(e){return this.data.charCodeAt(this.zero+e)},t.prototype.lastIndexOfSignature=function(e){return this.data.lastIndexOf(e)-this.zero},t.prototype.readAndCheckSignature=function(e){return e===this.readData(4)},t.prototype.readData=function(e){this.checkOffset(e);var t=this.data.slice(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t}(wn),Cn=function(e){function t(t){e.call(this,t)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.readData=function(e){if(this.checkOffset(e),0===e)return new Uint8Array(0);var t=this.data.subarray(this.zero+this.index,this.zero+this.index+e);return this.index+=e,t},t}(kn);function Sn(e){var t=Pt(e);return Ht(t),"string"!==t||wt.uint8array?wt.uint8array?new Cn(zt("uint8array",e)):new kn(zt("array",e)):new xn(e)}var Tn=function(e,t){this.options=e,this.loadOptions=t};Tn.prototype.isEncrypted=function(){return!(1&~this.bitFlag)},Tn.prototype.useUTF8=function(){return!(2048&~this.bitFlag)},Tn.prototype.readLocalPart=function(e){var t,n;if(e.skip(22),this.fileNameLength=e.readInt(2),n=e.readInt(2),this.fileName=e.readData(this.fileNameLength),e.skip(n),-1===this.compressedSize||-1===this.uncompressedSize)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if(null===(t=function(e){for(var t in dn)if(dn.hasOwnProperty(t)&&dn[t].magic===e)return dn[t];return null}(this.compressionMethod)))throw new Error("Corrupted zip : compression "+Lt(this.compressionMethod)+" unknown (inner file : "+zt("string",this.fileName)+")");this.decompressed=new on(this.compressedSize,this.uncompressedSize,this.crc32,t,e.readData(this.compressedSize))},Tn.prototype.readCentralPart=function(e){this.versionMadeBy=e.readInt(2),e.skip(2),this.bitFlag=e.readInt(2),this.compressionMethod=e.readString(2),this.date=e.readDate(),this.crc32=e.readInt(4),this.compressedSize=e.readInt(4),this.uncompressedSize=e.readInt(4);var t=e.readInt(2);if(this.extraFieldsLength=e.readInt(2),this.fileCommentLength=e.readInt(2),this.diskNumberStart=e.readInt(2),this.internalFileAttributes=e.readInt(2),this.externalFileAttributes=e.readInt(4),this.localHeaderOffset=e.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");e.skip(t),this.readExtraFields(e),this.parseZIP64ExtraField(e),this.fileComment=e.readData(this.fileCommentLength)},Tn.prototype.processAttributes=function(){this.unixPermissions=null,this.dosPermissions=null;var e=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),0===e&&(this.dosPermissions=63&this.externalFileAttributes),3===e&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||"/"!==this.fileNameStr.slice(-1)||(this.dir=!0)},Tn.prototype.parseZIP64ExtraField=function(e){if(this.extraFields[1]){var t=Sn(this.extraFields[1].value);this.uncompressedSize===Rt&&(this.uncompressedSize=t.readInt(8)),this.compressedSize===Rt&&(this.compressedSize=t.readInt(8)),this.localHeaderOffset===Rt&&(this.localHeaderOffset=t.readInt(8)),this.diskNumberStart===Rt&&(this.diskNumberStart=t.readInt(4))}},Tn.prototype.readExtraFields=function(e){var t,n,i,r=e.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});e.index<r;)t=e.readInt(2),n=e.readInt(2),i=e.readData(n),this.extraFields[t]={id:t,length:n,value:i}},Tn.prototype.handleUTF8=function(){var e=wt.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=Wt(this.fileName),this.fileCommentStr=Wt(this.fileComment);else{var t=this.findExtraFieldUnicodePath();if(null!==t)this.fileNameStr=t;else{var n=zt(e,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(n)}var i=this.findExtraFieldUnicodeComment();if(null!==i)this.fileCommentStr=i;else{var r=zt(e,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(r)}}},Tn.prototype.findExtraFieldUnicodePath=function(){var e=this.extraFields[28789];if(e){var t=Sn(e.value);return 1!==t.readInt(1)||nn(this.fileName)!==t.readInt(4)?null:Wt(t.readData(e.length-5))}return null},Tn.prototype.findExtraFieldUnicodeComment=function(){var e=this.extraFields[25461];if(e){var t=Sn(e.value);return 1!==t.readInt(1)||nn(this.fileComment)!==t.readInt(4)?null:Wt(t.readData(e.length-5))}return null};var Dn=function(e){this.files=[],this.loadOptions=e};function An(e){return new yt.Promise((function(t,n){var i=e.decompressed.getContentWorker().pipe(new rn);i.on("error",(function(e){n(e)})).on("end",(function(){i.streamInfo.crc32!==e.decompressed.crc32?n(new Error("Corrupted zip : CRC32 mismatch")):t()})).resume()}))}function Mn(e,t){var n=this;return t=Ot(t||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:Wt}),Vt("the loaded zip file",e,!0,t.optimizedBinaryString,t.base64).then((function(e){var n=new Dn(t);return n.load(e),n})).then((function(e){var n=[yt.Promise.resolve(e)],i=e.files;if(t.checkCRC32)for(var r=0;r<i.length;r++)n.push(An(i[r]));return yt.Promise.all(n)})).then((function(e){for(var i=e.shift(),r=i.files,o=0;o<r.length;o++){var a=r[o];n.file(a.fileNameStr,a.decompressed,{binary:!0,optimizedBinaryString:!0,date:a.date,dir:a.dir,comment:a.fileCommentStr.length?a.fileCommentStr:null,unixPermissions:a.unixPermissions,dosPermissions:a.dosPermissions,createFolders:t.createFolders})}return i.zipComment.length&&(n.comment=i.zipComment),n}))}Dn.prototype.checkSignature=function(e){if(!this.reader.readAndCheckSignature(e)){this.reader.index-=4;var t=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+Lt(t)+", expected "+Lt(e)+")")}},Dn.prototype.isSignature=function(e,t){var n=this.reader.index;this.reader.setIndex(e);var i=this.reader.readString(4)===t;return this.reader.setIndex(n),i},Dn.prototype.readBlockEndOfCentral=function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var e=this.reader.readData(this.zipCommentLength),t=wt.uint8array?"uint8array":"array",n=zt(t,e);this.zipComment=this.loadOptions.decodeFileName(n)},Dn.prototype.readBlockZip64EndOfCentral=function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var e,t,n,i=this.zip64EndOfCentralSize-44;0<i;)e=this.reader.readInt(2),t=this.reader.readInt(4),n=this.reader.readData(t),this.zip64ExtensibleData[e]={id:e,length:t,value:n}},Dn.prototype.readBlockZip64EndOfCentralLocator=function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),this.disksCount>1)throw new Error("Multi-volumes zip are not supported")},Dn.prototype.readLocalFiles=function(){var e,t;for(e=0;e<this.files.length;e++)t=this.files[e],this.reader.setIndex(t.localHeaderOffset),this.checkSignature(un),t.readLocalPart(this.reader),t.handleUTF8(),t.processAttributes()},Dn.prototype.readCentralDir=function(){var e;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(hn);)(e=new Tn({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(e);if(this.centralDirRecords!==this.files.length&&0!==this.centralDirRecords&&0===this.files.length)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},Dn.prototype.readEndOfCentral=function(){var e=this.reader.lastIndexOfSignature(pn);if(e<0)throw!this.isSignature(0,un)?new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html"):new Error("Corrupted zip: can't find end of central directory");this.reader.setIndex(e);var t=e;if(this.checkSignature(pn),this.readBlockEndOfCentral(),this.diskNumber===Ft||this.diskWithCentralDirStart===Ft||this.centralDirRecordsOnThisDisk===Ft||this.centralDirRecords===Ft||this.centralDirSize===Rt||this.centralDirOffset===Rt){if(this.zip64=!0,(e=this.reader.lastIndexOfSignature(fn))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(e),this.checkSignature(fn),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,mn)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(mn),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(mn),this.readBlockZip64EndOfCentral()}var n=this.centralDirOffset+this.centralDirSize;this.zip64&&(n+=20,n+=12+this.zip64EndOfCentralSize);var i=t-n;if(i>0)this.isSignature(t,hn)||(this.reader.zero=i);else if(i<0)throw new Error("Corrupted zip: missing "+Math.abs(i)+" bytes.")},Dn.prototype.prepareReader=function(e){this.reader=Sn(e)},Dn.prototype.load=function(e){this.prepareReader(e),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()};var En=function(e,t,n){var i,r=Pt(t),o=Ot(n||{},Zt);o.date=o.date||new Date,null!==o.compression&&(o.compression=o.compression.toUpperCase()),"string"==typeof o.unixPermissions&&(o.unixPermissions=parseInt(o.unixPermissions,8)),o.unixPermissions&&16384&o.unixPermissions&&(o.dir=!0),o.dosPermissions&&16&o.dosPermissions&&(o.dir=!0),o.dir&&(e=zn(e)),o.createFolders&&(i=In(e))&&Pn.call(this,i,!0);var a="string"===r&&!1===o.binary&&!1===o.base64;n&&void 0!==n.binary||(o.binary=!a),(t instanceof on&&0===t.uncompressedSize||o.dir||!t||0===t.length)&&(o.base64=!1,o.binary=!0,t="",o.compression="STORE",r="string");var s=null;s=t instanceof on||t instanceof Nt?t:Vt(e,t,o.binary,o.optimizedBinaryString,o.base64);var l=new an(e,s,o);this.files[e]=l},In=function(e){"/"===e.slice(-1)&&(e=e.substring(0,e.length-1));var t=e.lastIndexOf("/");return t>0?e.substring(0,t):""},zn=function(e){return"/"!==e.slice(-1)&&(e+="/"),e},Pn=function(e,t){return t=void 0!==t?t:Xt,e=zn(e),this.files[e]||En.call(this,e,null,{dir:!0,createFolders:t}),this.files[e]};function Hn(e){return"[object RegExp]"===Object.prototype.toString.call(e)}var Fn=function e(){if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var t=new e;for(var n in this)"function"!=typeof this[n]&&(t[n]=this[n]);return t}},Rn={support:{configurable:!0},defaults:{configurable:!0},version:{configurable:!0},external:{configurable:!0}};Fn.prototype.load=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},Fn.prototype.forEach=function(e){var t,n,i;for(t in this.files)i=this.files[t],(n=t.slice(this.root.length,t.length))&&t.slice(0,this.root.length)===this.root&&e(n,i)},Fn.prototype.filter=function(e){var t=[];return this.forEach((function(n,i){e(n,i)&&t.push(i)})),t},Fn.prototype.file=function(e,t,n){if(1===arguments.length){if(Hn(e)){var i=e;return this.filter((function(e,t){return!t.dir&&i.test(e)}))}var r=this.files[this.root+e];return r&&!r.dir?r:null}return e=this.root+e,En.call(this,e,t,n),this},Fn.prototype.folder=function(e){if(!e)return this;if(Hn(e))return this.filter((function(t,n){return n.dir&&e.test(t)}));var t=this.root+e,n=Pn.call(this,t),i=this.clone();return i.root=n.name,i},Fn.prototype.remove=function(e){e=this.root+e;var t=this.files[e];if(t||("/"!==e.slice(-1)&&(e+="/"),t=this.files[e]),t&&!t.dir)delete this.files[e];else for(var n=this.filter((function(t,n){return n.name.slice(0,e.length)===e})),i=0;i<n.length;i++)delete this.files[n[i].name];return this},Fn.prototype.generate=function(e){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},Fn.prototype.generateInternalStream=function(e){var t,n={};try{if((n=Ot(e||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:Ut})).type=n.type.toLowerCase(),n.compression=n.compression.toUpperCase(),"binarystring"===n.type&&(n.type="string"),!n.type)throw new Error("No output type specified.");Ht(n.type),"darwin"!==n.platform&&"freebsd"!==n.platform&&"linux"!==n.platform&&"sunos"!==n.platform||(n.platform="UNIX"),"win32"===n.platform&&(n.platform="DOS");var i=n.comment||this.comment||"";t=yn(this,n,i)}catch(e){(t=new Nt("error")).error(e)}return new Qt(t,n.type||"string",n.mimeType)},Fn.prototype.generateAsync=function(e,t){return this.generateInternalStream(e).accumulate(t)},Fn.prototype.loadAsync=function(e,t){return Mn.apply(this,[e,t])},Fn.loadAsync=function(e,t){return(new Fn).loadAsync(e,t)},Rn.support.get=function(){return wt},Rn.defaults.get=function(){return Zt},Rn.version.get=function(){return"3.2.2-esm"},Rn.external.get=function(){return yt},Object.defineProperties(Fn,Rn);var Ln={compile:function(e){return e}},Bn=function(){};Bn.register=function(e){Ln=e},Bn.compile=function(e){return Ln.compile(e)};var On=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g,Vn={},Nn="undefined";function $n(e){if(Vn[e])return Vn[e];var t=[];return e.replace(On,(function(e,n,i,r){t.push(typeof n!==Nn?n:i||r)})),Vn[e]=function(e){for(var n=e,i=0;i<t.length&&n;i++)n=n[t[i]];return n},Vn[e]}function Un(e,t){return e.reduce((function(e,n,i){var r=t(n,i);return null!=r&&e.push(r),e}),[])}function Wn(e){return e.title+": "+e.value}function jn(e,t){for(var n=[],i=0;i<e;i++)n.push(t(i));return n}function qn(e){return e.id}Vn[Nn]=function(e){return e};var Gn=function(e){e.columns=this._trimColumns(e.columns||[]),this.allColumns=Un(this._leafColumns(e.columns||[]),this._prepareColumn),this.columns=this._visibleColumns(this.allColumns),this.options=e,this.data=e.data||[],this.aggregates=e.aggregates||{},this.groups=[].concat(e.groups||[]),this.hasGroups=this.groups.length>0,this.hierarchy=e.hierarchy,this.hasGroupHeaderColumn=this.columns.some((function(e){return e.groupHeaderColumnTemplate})),this.collapsible=this.options.collapsible};Gn.prototype.workbook=function(){var e={sheets:[{columns:this._columns(),rows:this.hierarchy?this._hierarchyRows():this._rows(),freezePane:this._freezePane(),filter:this._filter()}]};return e},Gn.prototype._trimColumns=function(e){var t=this;return e.filter((function(e){var n=Boolean(e.field);return!n&&e.columns&&(n=t._trimColumns(e.columns).length>0),n}))},Gn.prototype._leafColumns=function(e){for(var t=[],n=0;n<e.length;n++)e[n].columns?t=t.concat(this._leafColumns(e[n].columns)):t.push(e[n]);return t},Gn.prototype._prepareColumn=function(e){if(!e.field)return null;var t=function(t){return $n(e.field)(t)},n=null;return e.values&&(n={},e.values.forEach((function(e){n[e.value]=e.text})),t=function(t){return n[$n(e.field)(t)]}),Object.assign({},e,{value:t,values:n,groupHeaderTemplate:e.groupHeaderTemplate?Bn.compile(e.groupHeaderTemplate):Wn,groupHeaderColumnTemplate:e.groupHeaderColumnTemplate?Bn.compile(e.groupHeaderColumnTemplate):null,groupFooterTemplate:e.groupFooterTemplate?Bn.compile(e.groupFooterTemplate):null,footerTemplate:e.footerTemplate?Bn.compile(e.footerTemplate):null})},Gn.prototype._filter=function(){if(!this.options.filterable)return null;var e=this._depth();return{from:e,to:e+this.columns.length-1}},Gn.prototype._createPaddingCells=function(e){var t=this;return jn(e,(function(){return Object.assign({background:"#dfdfdf",color:"#333"},t.options.paddingCellOptions)}))},Gn.prototype._dataRow=function(e,t,n){var i=this._createPaddingCells(t);if(this.hasGroups&&n&&e.items){i=i.concat(this._groupHeaderCells(e,t,n));var r=this._dataRows(e.items,t+1);return r.unshift({type:"group-header",cells:i,level:this.collapsible?t:null}),r.concat(this._footer(e,t))}for(var o=[],a=0;a<this.columns.length;a++)o[a]=this._cell(e,this.columns[a]);return this.hierarchy&&(o[0].colSpan=n-t+1),[{type:"data",cells:i.concat(o),level:this.collapsible?t:null}]},Gn.prototype._groupHeaderCells=function(e,t,n){var i=[],r=this.allColumns.filter((function(t){return t.field===e.field}))[0]||{},o=r&&r.title?r.title:e.field,a=r?r.groupHeaderTemplate||r.groupHeaderColumnTemplate:null,s=Object.assign({title:o,field:e.field,value:r&&r.values?r.values[e.value]:e.value,aggregates:e.aggregates,items:e.items},e.aggregates[e.field]),l=a?a(s):o+": "+e.value;return i.push(Object.assign({value:l,background:"#dfdfdf",color:"#333",colSpan:(this.hasGroupHeaderColumn?1:this.columns.length)+n-t},r.groupHeaderCellOptions)),this.hasGroupHeaderColumn&&this.columns.forEach((function(t,n){n>0&&i.push(Object.assign({background:"#dfdfdf",color:"#333",value:t.groupHeaderColumnTemplate?t.groupHeaderColumnTemplate(Object.assign({group:s},s,e.aggregates[t.field])):void 0},t.groupHeaderCellOptions))})),i},Gn.prototype._dataRows=function(e,t){for(var n=this._depth(),i=[],r=0;r<e.length;r++)i.push.apply(i,this._dataRow(e[r],t,n));return i},Gn.prototype._hierarchyRows=function(){var e,t=this._depth(),n=this.data,i=this.hierarchy.itemLevel,r=this.hierarchy.itemId||qn,o=this._hasFooterTemplate(),a=[],s=[],l=0;o||(this.collapsible=!1);for(var c=0;c<n.length;c++){var d=n[c],u=i(d,c);o&&(u>l?s.push({id:e,level:l}):u<l&&a.push.apply(a,this._hierarchyFooterRows(s,u,t)),l=u,e=r(d,c)),a.push.apply(a,this._dataRow(d,u+1,t))}if(o){a.push.apply(a,this._hierarchyFooterRows(s,0,t));var h=n.length?this.aggregates[n[0].parentId]:{};a.push(this._hierarchyFooter(h,0,t))}return this._prependHeaderRows(a),a},Gn.prototype._hierarchyFooterRows=function(e,t,n){for(var i=[];e.length&&e[e.length-1].level>=t;){var r=e.pop();i.push(this._hierarchyFooter(this.aggregates[r.id],r.level+1,n))}return i},Gn.prototype._hasFooterTemplate=function(){for(var e=this.columns,t=0;t<e.length;t++)if(e[t].footerTemplate)return!0},Gn.prototype._hierarchyFooter=function(e,t,n){var i=this.columns.map((function(i,r){var o=r?1:n-t+1;if(i.footerTemplate){var a=(e||{})[i.field];return Object.assign({background:"#dfdfdf",color:"#333",colSpan:o,value:i.footerTemplate(Object.assign({aggregates:e},a))},i.footerCellOptions)}return Object.assign({background:"#dfdfdf",color:"#333",colSpan:o},i.footerCellOptions)}));return{type:"footer",cells:this._createPaddingCells(t).concat(i),level:this.collapsible?t:null}},Gn.prototype._footer=function(e,t){var n,i,r=[],o=this.columns.some((function(e){return e.groupFooterTemplate}));o&&(i={group:{items:e.items,field:e.field,value:e.value}},n={},Object.keys(e.aggregates).forEach((function(t){n[t]=Object.assign({},e.aggregates[t],i)})));var a=this.columns.map((function(t){if(t.groupFooterTemplate){var r=Object.assign({},n,e.aggregates[t.field],i);return Object.assign({background:"#dfdfdf",color:"#333",value:t.groupFooterTemplate(r)},t.groupFooterCellOptions)}return Object.assign({background:"#dfdfdf",color:"#333"},t.groupFooterCellOptions)}));return o&&r.push({type:"group-footer",cells:this._createPaddingCells(this.groups.length).concat(a),level:this.collapsible?t:null}),r},Gn.prototype._isColumnVisible=function(e){return this._visibleColumns([e]).length>0&&(e.field||e.columns)},Gn.prototype._visibleColumns=function(e){var t=this;return e.filter((function(e){var n=e.exportable;"object"==typeof n&&(n=e.exportable.excel);var i=!e.hidden&&!1!==n,r=e.hidden&&!0===n,o=i||r;return o&&e.columns&&(o=t._visibleColumns(e.columns).length>0),o}))},Gn.prototype._headerRow=function(e,t){var n=this,i=e.cells.map((function(t){return Object.assign(t,{colSpan:t.colSpan>1?t.colSpan:1,rowSpan:e.rowSpan>1&&!t.colSpan?e.rowSpan:1})}));return this.hierarchy&&i[0].firstCell&&(i[0].colSpan+=this._depth()),{type:"header",cells:jn(t.length,(function(){return Object.assign({background:"#7a7a7a",color:"#fff"},n.options.headerPaddingCellOptions)})).concat(i)}},Gn.prototype._prependHeaderRows=function(e){var t=this.groups,n=[{rowSpan:1,cells:[],index:0}];this._prepareHeaderRows(n,this.options.columns);for(var i=n.length-1;i>=0;i--)e.unshift(this._headerRow(n[i],t))},Gn.prototype._prepareHeaderRows=function(e,t,n,i){for(var r=this,o=i||e[e.length-1],a=e[o.index+1],s=0,l=0;l<t.length;l++){var c=t[l];if(r._isColumnVisible(c)){var d=Object.assign({background:"#7a7a7a",color:"#fff",value:c.title||c.field,colSpan:0,firstCell:0===l&&(!n||n.firstCell)},c.headerCellOptions);o.cells.push(d),c.columns&&c.columns.length&&(a||(a={rowSpan:0,cells:[],index:e.length},e.push(a)),d.colSpan=r._trimColumns(r._visibleColumns(c.columns)).length,r._prepareHeaderRows(e,c.columns,d,a),s+=d.colSpan-1,o.rowSpan=e.length-o.index)}}n&&(n.colSpan+=s)},Gn.prototype._rows=function(){var e=this,t=this._dataRows(this.data,0);if(this.columns.length){this._prependHeaderRows(t);var n=!1,i=this.columns.map((function(t){return t.footerTemplate?(n=!0,Object.assign({background:"#dfdfdf",color:"#333",value:t.footerTemplate(Object.assign({},e.aggregates,e.aggregates[t.field]))},t.footerCellOptions)):Object.assign({background:"#dfdfdf",color:"#333"},t.footerCellOptions)}));n&&t.push({type:"footer",cells:this._createPaddingCells(this.groups.length).concat(i)})}return t},Gn.prototype._headerDepth=function(e){for(var t=0,n=0;n<e.length;n++)if(e[n].columns){var i=this._headerDepth(e[n].columns);i>t&&(t=i)}return 1+t},Gn.prototype._freezePane=function(){var e=this._visibleColumns(this.options.columns||[]),t=this._visibleColumns(this._trimColumns(this._leafColumns(e.filter((function(e){return e.locked}))))).length;return{rowSplit:this._headerDepth(e),colSplit:t?t+this.groups.length:0}},Gn.prototype._cell=function(e,t){return Object.assign({value:t.value(e)},t.cellOptions)},Gn.prototype._depth=function(){return this.hierarchy?this.hierarchy.depth:this.groups.length},Gn.prototype._columns=function(){return jn(this._depth(),(function(){return{width:20}})).concat(this.columns.map((function(e){return{width:parseInt(e.width,10),autoWidth:!e.width}})))};var Kn={toString:function(e){return e}},Yn=function(){};function Qn(e,t,n){return(1461*(e+4800+((t-13)/12|0))/4|0)+(367*(t-1-12*((t-13)/12|0))/12|0)-(3*((e+4900+((t-13)/12|0))/100|0)/4|0)+n-32075}Yn.register=function(e){Kn=e},Yn.toString=function(e,t){return Kn.toString(e,t)};var Xn=Qn(1900,0,-1);function Zn(e){var t,n,i,r,o=(t=e.getHours(),n=e.getMinutes(),i=e.getSeconds(),r=e.getMilliseconds(),(t+(n+(i+r/1e3)/60)/60)/24),a=function(e,t,n){return Qn(e,t,n)-Xn}(e.getFullYear(),e.getMonth(),e.getDate());return a<0?a-1+o:a+o}var Jn="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",ei="data:"+Jn+";base64,",ti={compression:"DEFLATE",type:"base64"},ni={compression:"DEFLATE",type:"blob"},ii={compression:"DEFLATE",type:"arraybuffer"};function ri(e){return ei+e}function oi(e,t){return t.indexOf(e)}var ai=JSON.parse.bind(JSON);function si(e){return String(e).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\"/g,"&quot;").replace(/\'/g,"&#39;")}function li(e,t){for(var n="",i=0;i<e;++i)n+=t(i);return n}function ci(e,t){var n="";if(null!=e)if(Array.isArray(e))for(var i=0;i<e.length;++i)n+=t(e[i],i);else"object"==typeof e&&Object.keys(e).forEach((function(i,r){n+=t(e[i],i,r)}));return n}var di='<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\r',ui=di+'\n            <Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">\n               <Relationship Id="rId3" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties" Target="docProps/app.xml"/>\n               <Relationship Id="rId2" Type="http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties" Target="docProps/core.xml"/>\n               <Relationship Id="rId1" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument" Target="xl/workbook.xml"/>\n            </Relationships>',hi=function(e){var t=e.frozenColumns,n=e.frozenRows,i=e.columns,r=e.defaults,o=e.data,a=e.index,s=e.mergeCells,l=e.autoFilter,c=e.filter,d=e.showGridLines,u=e.hyperlinks,h=e.validations,p=e.defaultCellStyleId,f=e.rtl,m=e.legacyDrawing,g=e.drawing,v=e.lastRow,_=e.lastCol,b=e.hasDisabledCells;return di+'\n<worksheet xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" xmlns:x14ac="http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac" mc:Ignorable="x14ac">\n   '+(v&&_?'<dimension ref="A1:'+mi(v-1,_-1)+'" />':"")+"\n\n   <sheetViews>\n     <sheetView "+(f?'rightToLeft="1"':"")+" "+(0===a?'tabSelected="1"':"")+' workbookViewId="0" '+(!1===d?'showGridLines="0"':"")+">\n     "+(n||t?'\n       <pane state="frozen"\n         '+(t?'xSplit="'+t+'"':"")+"\n         "+(n?'ySplit="'+n+'"':"")+'\n         topLeftCell="'+(String.fromCharCode(65+(t||0))+((n||0)+1))+'"\n       />':"")+'\n     </sheetView>\n   </sheetViews>\n\n   <sheetFormatPr x14ac:dyDescent="0.25" '+(r.skipCustomHeight?"":'customHeight="1"')+' defaultRowHeight="'+(r.rowHeight?.75*r.rowHeight:15)+'"\n     '+(r.columnWidth?'defaultColWidth="'+_i(r.columnWidth)+'"':"")+" />\n\n   "+(null!=p||i&&i.length>0?"\n     <cols>\n       "+(i&&i.length?"":'\n         <col min="1" max="16384" style="'+p+'"\n              '+(r.columnWidth?'width="'+_i(r.columnWidth)+'"':"")+" /> ")+"\n       "+ci(i,(function(e,t){var n="number"==typeof e.index?e.index+1:t+1;return 0===e.width?"<col "+(null!=p?'style="'+p+'"':"")+'\n                        min="'+n+'" max="'+n+'" hidden="1" customWidth="1" />':"<col "+(null!=p?'style="'+p+'"':"")+'\n                      min="'+n+'" max="'+n+'" customWidth="1"\n                      '+(e.autoWidth?'width="'+(7*e.width+5)/7*256/256+'" bestFit="1"':'width="'+_i(e.width)+'"')+" />"}))+"\n     </cols>":"")+"\n\n   <sheetData>\n     "+ci(o,(function(e,t){return'\n         <row r="'+("number"==typeof e.index?e.index+1:t+1)+'" x14ac:dyDescent="0.25"\n              '+(e.level?'outlineLevel="'+e.level+'"':"")+"\n              "+(0===e.height?'hidden="1"':e.height?'ht="'+(.75*e.height+'" customHeight="1"'):"")+">\n           "+ci(e.data,(function(e){return'\n             <c r="'+e.ref+'" '+(e.style?'s="'+e.style+'"':"")+" "+(e.type?'t="'+e.type+'"':"")+">\n               "+(null!=e.formula?function(e){if("string"==typeof e)return"<f>"+si(e)+"</f>";return'<f t="array" ref="'+e.ref+'">'+si(e.src)+"</f>"}(e.formula):"")+"\n               "+(null!=e.value?"<v>"+si(e.value)+"</v>":"")+"\n             </c>"}))+"\n         </row>\n       "}))+"\n   </sheetData>\n\n   "+(b?'<sheetProtection sheet="1" objects="1" scenarios="1"/>':"")+"\n\n   "+(l?'<autoFilter ref="'+l.from+":"+l.to+'"/>':c?$i(c):"")+"\n\n   "+(s.length?'\n     <mergeCells count="'+s.length+'">\n       '+ci(s,(function(e){return'<mergeCell ref="'+e+'"/>'}))+"\n     </mergeCells>":"")+"\n\n   "+(h.length?"\n     <dataValidations>\n       "+ci(h,(function(e){return'\n         <dataValidation sqref="'+e.sqref.join(" ")+'"\n                         showErrorMessage="'+e.showErrorMessage+'"\n                         type="'+si(e.type)+'"\n                         '+("list"!==e.type?'operator="'+si(e.operator)+'"':"")+'\n                         allowBlank="'+e.allowBlank+'"\n                         showDropDown="'+e.showDropDown+'"\n                         '+(e.error?'error="'+si(e.error)+'"':"")+"\n                         "+(e.errorTitle?'errorTitle="'+si(e.errorTitle)+'"':"")+">\n           "+(e.formula1?"<formula1>"+si(e.formula1)+"</formula1>":"")+"\n           "+(e.formula2?"<formula2>"+si(e.formula2)+"</formula2>":"")+"\n         </dataValidation>"}))+"\n     </dataValidations>":"")+"\n\n   "+(u.length?"\n     <hyperlinks>\n       "+ci(u,(function(e){return'\n         <hyperlink ref="'+e.ref+'" r:id="'+e.rId+'"/>'}))+"\n     </hyperlinks>":"")+'\n\n   <pageMargins left="0.7" right="0.7" top="0.75" bottom="0.75" header="0.3" footer="0.3" />\n   '+(g?'<drawing r:id="'+g+'"/>':"")+"\n   "+(m?'<legacyDrawing r:id="'+m+'"/>':"")+"\n</worksheet>"},pi=function(e){return di+'\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">\n  '+ci(e,(function(e){return'\n    <Relationship Id="'+e.rId+'" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/image" Target="'+e.target+'"/>'}))+"\n</Relationships>"};function fi(e){var t=Math.floor(e/26)-1;return(t>=0?fi(t):"")+String.fromCharCode(65+e%26)}function mi(e,t){return fi(t)+(e+1)}function gi(e,t){return"$"+fi(t)+"$"+(e+1)}function vi(e){return(e.frozenRows||(e.freezePane||{}).rowSplit||1)-1}function _i(e){return e/7-Math.floor(128/7)/256}var bi=function(e,t,n,i){this.options=e,this._strings=t,this._styles=n,this._borders=i,this._validations={},this._comments=[],this._drawings=e.drawings||[],this._hyperlinks=(this.options.hyperlinks||[]).map((function(e,t){return Object.assign({},e,{rId:"link"+t})}))};function yi(e){var t=e.length;return e.forEach((function(e){e.index&&e.index>=t&&(t=e.index+1)})),t}bi.prototype.relsToXML=function(){var e=this._hyperlinks,t=this._comments,n=this._drawings;if(e.length||t.length||n.length)return function(e){var t=e.hyperlinks,n=e.comments,i=e.sheetIndex,r=e.drawings;return di+'\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">\n  '+ci(t,(function(e){return'\n    <Relationship Id="'+e.rId+'" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink" Target="'+si(e.target)+'" TargetMode="External" />'}))+"\n  "+(n.length?'\n    <Relationship Id="comment'+i+'" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments" Target="../comments'+i+'.xml"/>\n    <Relationship Id="vml'+i+'" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/vmlDrawing" Target="../drawings/vmlDrawing'+i+'.vml"/>':"")+"\n  "+(r.length?'\n    <Relationship Id="drw'+i+'" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing" Target="../drawings/drawing'+i+'.xml"/>':"")+"\n</Relationships>"}({hyperlinks:e,comments:t,sheetIndex:this.options.sheetIndex,drawings:n})},bi.prototype.toXML=function(e){var t=this,n=this.options.mergedCells||[],i=function(e,t){var n=[],i=[];!function(e,t){for(var n=0;n<e.length;n++){var i=e[n];if(i){var r=i.index;"number"!=typeof r&&(r=n),t(i,r)}}}(e,(function(e,t){var r={_source:e,index:t,height:e.height,level:e.level,cells:[]};n.push(r),i[t]=r}));for(var r=Mi(n).slice(0),o={rowData:n,rowsByIndex:i,mergedCells:t},a=0;a<r.length;a++)Pi(r[a],o),delete r[a]._source;return Mi(n)}(this.options.rows||[],n);this._readCells(i);var r,o=this.options.filter;o&&"number"==typeof o.from&&"number"==typeof o.to?o={from:mi(vi(this.options),o.from),to:mi(vi(this.options),o.to)}:o&&o.ref&&o.columns&&(r=o,o=null);var a=[];for(var s in t._validations)Object.prototype.hasOwnProperty.call(t._validations,s)&&a.push(t._validations[s]);var l=null,c=this.options.defaultCellStyle;this._hasDisabledCells&&(c=c?Object.assign({disabled:!1},c):{disabled:!1}),c&&(l=this._lookupStyle(c));var d=this.options.freezePane||{},u=this.options.defaults||{},h=this.options.rows?this._getLastRow():1,p=this.options.rows?this._getLastCol():1;return hi({frozenColumns:this.options.frozenColumns||d.colSplit,frozenRows:this.options.frozenRows||d.rowSplit,columns:this.options.columns,defaults:u,data:i,index:e,mergeCells:n,autoFilter:o,filter:r,showGridLines:this.options.showGridLines,hyperlinks:this._hyperlinks,validations:a,defaultCellStyleId:l,rtl:void 0!==this.options.rtl?this.options.rtl:u.rtl,legacyDrawing:this._comments.length?"vml"+this.options.sheetIndex:null,drawing:this._drawings.length?"drw"+this.options.sheetIndex:null,lastRow:h,lastCol:p,hasDisabledCells:this._hasDisabledCells})},bi.prototype.commentsXML=function(){if(this._comments.length)return function(e){var t=e.comments;return di+'\n<comments xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main">\n  <authors>\n    <author></author>\n  </authors>\n  <commentList>\n    '+ci(t,(function(e){return'\n      <comment ref="'+e.ref+'" authorId="0">\n        <text>\n          <r>\n            <rPr>\n              <sz val="8"/>\n              <color indexed="81"/>\n              <rFont val="Tahoma"/>\n              <charset val="1"/>\n            </rPr>\n            <t>'+si(e.text)+"</t>\n          </r>\n        </text>\n      </comment>"}))+"\n  </commentList>\n</comments>"}({comments:this._comments})},bi.prototype.drawingsXML=function(e){if(this._drawings.length){var t={},n=this._drawings.map((function(n){var i=Ii(n.topLeftCell),r=t[n.image];return r||(r=t[n.image]={rId:"img"+n.image,target:e[n.image].target}),{col:i.col,colOffset:zi(n.offsetX),row:i.row,rowOffset:zi(n.offsetY),width:zi(n.width),height:zi(n.height),imageId:r.rId}}));return{main:(i=n,di+'\n<xdr:wsDr xmlns:xdr="http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing"\n          xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main"\n          xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships">\n  '+ci(i,(function(e,t){return'\n    <xdr:oneCellAnchor editAs="oneCell">\n      <xdr:from>\n        <xdr:col>'+e.col+"</xdr:col>\n        <xdr:colOff>"+e.colOffset+"</xdr:colOff>\n        <xdr:row>"+e.row+"</xdr:row>\n        <xdr:rowOff>"+e.rowOffset+'</xdr:rowOff>\n      </xdr:from>\n      <xdr:ext cx="'+e.width+'" cy="'+e.height+'" />\n      <xdr:pic>\n        <xdr:nvPicPr>\n          <xdr:cNvPr id="'+(t+1)+'" name="Picture '+(t+1)+'"/>\n          <xdr:cNvPicPr/>\n        </xdr:nvPicPr>\n        <xdr:blipFill>\n          <a:blip r:embed="'+e.imageId+'"/>\n          <a:stretch>\n            <a:fillRect/>\n          </a:stretch>\n        </xdr:blipFill>\n        <xdr:spPr>\n          <a:prstGeom prst="rect">\n            <a:avLst/>\n          </a:prstGeom>\n        </xdr:spPr>\n      </xdr:pic>\n      <xdr:clientData/>\n    </xdr:oneCellAnchor>'}))+"\n</xdr:wsDr>"),rels:pi(t)}}var i},bi.prototype.legacyDrawing=function(){if(this._comments.length)return function(e){return'<xml xmlns:v="urn:schemas-microsoft-com:vml"\n     xmlns:o="urn:schemas-microsoft-com:office:office"\n     xmlns:x="urn:schemas-microsoft-com:office:excel">\n  <v:shapetype coordsize="21600,21600" id="_x0000_t202" path="m,l,21600r21600,l21600,xe">\n    <v:stroke joinstyle="miter"/>\n    <v:path gradientshapeok="t" o:connecttype="rect"/>\n  </v:shapetype>\n  '+ci(e.comments,(function(e){return'\n    <v:shape type="#_x0000_t202" style="visibility: hidden" fillcolor="#ffffe1" o:insetmode="auto">\n      <v:shadow on="t" color="black" obscured="t"/>\n      <x:ClientData ObjectType="Note">\n        <x:MoveWithCells/>\n        <x:SizeWithCells/>\n        <x:Anchor>'+e.anchor+"</x:Anchor>\n        <x:AutoFill>False</x:AutoFill>\n        <x:Row>"+e.row+"</x:Row>\n        <x:Column>"+e.col+"</x:Column>\n      </x:ClientData>\n    </v:shape>"}))+"\n</xml>"}({comments:this._comments})},bi.prototype._lookupString=function(e){var t,n="$"+e,i=this._strings.indexes[n];return void 0!==i?t=i:(t=this._strings.indexes[n]=this._strings.uniqueCount,this._strings.uniqueCount++),this._strings.count++,t},bi.prototype._lookupStyle=function(e){var t=JSON.stringify(e);if("{}"===t)return 0;var n=oi(t,this._styles);return n<0&&(n=this._styles.push(t)-1),n+1},bi.prototype._lookupBorder=function(e){var t=JSON.stringify(e);if("{}"!==t){var n=oi(t,this._borders);return n<0&&(n=this._borders.push(t)-1),n+1}},bi.prototype._readCells=function(e){for(var t=0;t<e.length;t++){var n=e[t],i=n.cells;n.data=[];for(var r=0;r<i.length;r++){var o=this._cell(i[r],n.index,r);o&&n.data.push(o)}}},bi.prototype._cell=function(e,t,n){var i=this;if(!e||e===Ai)return null;var r=e.value,o={};e.borderLeft&&(o.left=e.borderLeft),e.borderRight&&(o.right=e.borderRight),e.borderTop&&(o.top=e.borderTop),e.borderBottom&&(o.bottom=e.borderBottom),e.dBorders&&(o.diagonal=e.dBorders),o=this._lookupBorder(o);var a,s=this.options.defaultCellStyle||{},l={borderId:o};a=function(t,n){var i=e[t];if(void 0===i&&(i=s[t]),void 0!==i)return l[n||t]=i,!0},a("color"),a("background"),a("bold"),a("italic"),a("underline"),a("fontFamily")||a("fontName","fontFamily"),a("fontSize"),a("format"),a("textAlign")||a("hAlign","textAlign"),a("verticalAlign")||a("vAlign","verticalAlign"),a("wrap"),a("indent"),a("disabled")||a("enable")&&(l.disabled=!l.enable,delete l.enable),l.disabled&&(i._hasDisabledCells=!0);var c=(this.options.columns||[])[n],d=typeof r;if(c&&c.autoWidth&&(!e.colSpan||1===e.colSpan)){var u=r;"number"===d&&(u=Yn.toString(r,e.format)),c.width=Math.max(c.width||0,String(u).length)}"string"===d?(r=function(e){return String(e).replace(/[\x00-\x09\x0B\x0C\x0E-\x1F]/g,"").replace(/\r?\n/g,"\r\n")}(r),r=this._lookupString(r),d="s"):"number"===d?d="n":"boolean"===d?(d="b",r=Number(r)):r&&r.getTime?(d=null,r=Zn(r),l.format||(l.format="mm-dd-yy")):(d=null,r=null),l=this._lookupStyle(l);var h=mi(t,n);if(e.validation&&this._addValidation(e.validation,h),e.comment){var p=[n+1,15,t,10,n+3,15,t+3,4];this._comments.push({ref:h,text:e.comment,row:t,col:n,anchor:p.join(", ")})}return{value:r,formula:e.formula,type:d,style:l,ref:h}},bi.prototype._addValidation=function(e,t){var n={showErrorMessage:"reject"===e.type?1:0,formula1:e.from,formula2:e.to,type:ki[e.dataType]||e.dataType,operator:wi[e.comparerType]||e.comparerType,allowBlank:e.allowNulls?1:0,showDropDown:e.showButton?0:1,error:e.messageTemplate,errorTitle:e.titleTemplate},i=JSON.stringify(n);this._validations[i]||(this._validations[i]=n,n.sqref=[]),this._validations[i].sqref.push(t)},bi.prototype._getLastRow=function(){return yi(this.options.rows)},bi.prototype._getLastCol=function(){var e=0;return this.options.rows.forEach((function(t){t.cells&&(e=Math.max(e,yi(t.cells)))})),e};var wi={greaterThanOrEqualTo:"greaterThanOrEqual",lessThanOrEqualTo:"lessThanOrEqual"},ki={number:"decimal"},xi={General:0,0:1,"0.00":2,"#,##0":3,"#,##0.00":4,"0%":9,"0.00%":10,"0.00E+00":11,"# ?/?":12,"# ??/??":13,"mm-dd-yy":14,"d-mmm-yy":15,"d-mmm":16,"mmm-yy":17,"h:mm AM/PM":18,"h:mm:ss AM/PM":19,"h:mm":20,"h:mm:ss":21,"m/d/yy h:mm":22,"#,##0 ;(#,##0)":37,"#,##0 ;[Red](#,##0)":38,"#,##0.00;(#,##0.00)":39,"#,##0.00;[Red](#,##0.00)":40,"mm:ss":45,"[h]:mm:ss":46,"mmss.0":47,"##0.0E+0":48,"@":49,"[$-404]e/m/d":27,"m/d/yy":30,t0:59,"t0.00":60,"t#,##0":61,"t#,##0.00":62,"t0%":67,"t0.00%":68,"t# ?/?":69,"t# ??/??":70};function Ci(e){var t=function(e){function t(e){var t=parseInt(e,10).toString(16);return t.length<2?"0"+t:t}var n=/^rgba?\((\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(?:,\s*([0-9.]+)\s*)?\)/i.exec(e.trim());return n?"#"+t(255*(n[4]?parseFloat(n[4]):1)|0)+t(n[1])+t(n[2])+t(n[3]):e}(e);return t.length<6&&(t=t.replace(/(\w)/g,(function(e,t){return t+t}))),(t=t.substring(1).toUpperCase()).length<8&&(t="FF"+t),t}var Si=function(e){var t=this;this.options=e||{},this._strings={indexes:{},count:0,uniqueCount:0},this._styles=[],this._borders=[],this._images=this.options.images,this._imgId=0,this._sheets=Un(this.options.sheets||[],(function(e,n){return e.defaults=t.options,e.sheetIndex=n+1,new bi(e,t._strings,t._styles,t._borders)}))};function Ti(e,t){var n,i,r="";return t&&(r+="<"+e+' style="'+(n=t.size,i="thin",2===n?i="medium":3===n&&(i="thick"),i+'">'),t.color&&(r+='<color rgb="'+Ci(t.color)+'"/>'),r+="</"+e+">"),r}function Di(e){var t=e.diagonal?e.diagonal.type:0;return"<border "+(2&t?'diagonalUp="true"':"")+" "+(1&t?'diagonalDown="true"':"")+">\n      "+Ti("left",e.left)+"\n      "+Ti("right",e.right)+"\n      "+Ti("top",e.top)+"\n      "+Ti("bottom",e.bottom)+"\n      "+Ti("diagonal",e.diagonal)+"\n    </border>"}Si.prototype.imageFilename=function(e){var t=++this._imgId;switch(e){case"image/jpg":case"image/jpeg":return"image"+t+".jpg";case"image/png":return"image"+t+".png";case"image/gif":return"image"+t+".gif";default:return"image"+t+".bin"}},Si.prototype.toZIP=function(){var e=this,t=new Fn,n=t.folder("docProps");n.file("core.xml",function(e){var t=e.creator,n=e.lastModifiedBy,i=e.created,r=e.modified;return di+'\n <cp:coreProperties xmlns:cp="http://schemas.openxmlformats.org/package/2006/metadata/core-properties"\n   xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:dcterms="http://purl.org/dc/terms/"\n   xmlns:dcmitype="http://purl.org/dc/dcmitype/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">\n   <dc:creator>'+si(t)+"</dc:creator>\n   <cp:lastModifiedBy>"+si(n)+'</cp:lastModifiedBy>\n   <dcterms:created xsi:type="dcterms:W3CDTF">'+si(i)+'</dcterms:created>\n   <dcterms:modified xsi:type="dcterms:W3CDTF">'+si(r)+"</dcterms:modified>\n</cp:coreProperties>"}({creator:this.options.creator||"Kendo UI",lastModifiedBy:this.options.creator||"Kendo UI",created:this.options.date||(new Date).toJSON(),modified:this.options.date||(new Date).toJSON()}));var i=this._sheets.length;n.file("app.xml",function(e){var t=e.sheets;return di+'\n<Properties xmlns="http://schemas.openxmlformats.org/officeDocument/2006/extended-properties" xmlns:vt="http://schemas.openxmlformats.org/officeDocument/2006/docPropsVTypes">\n  <Application>Microsoft Excel</Application>\n  <DocSecurity>0</DocSecurity>\n  <ScaleCrop>false</ScaleCrop>\n  <HeadingPairs>\n    <vt:vector size="2" baseType="variant">\n      <vt:variant>\n        <vt:lpstr>Worksheets</vt:lpstr>\n      </vt:variant>\n      <vt:variant>\n        <vt:i4>'+t.length+'</vt:i4>\n      </vt:variant>\n    </vt:vector>\n  </HeadingPairs>\n  <TitlesOfParts>\n    <vt:vector size="'+t.length+'" baseType="lpstr">'+ci(t,(function(e,t){return e.options.title?"<vt:lpstr>"+si(e.options.title)+"</vt:lpstr>":"<vt:lpstr>Sheet"+(t+1)+"</vt:lpstr>"}))+"</vt:vector>\n  </TitlesOfParts>\n  <LinksUpToDate>false</LinksUpToDate>\n  <SharedDoc>false</SharedDoc>\n  <HyperlinksChanged>false</HyperlinksChanged>\n  <AppVersion>14.0300</AppVersion>\n</Properties>"}({sheets:this._sheets})),t.folder("_rels").file(".rels",ui);var r=t.folder("xl");if(r.folder("_rels").file("workbook.xml.rels",function(e){var t=e.count;return di+'\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">\n  '+li(t,(function(e){return'\n    <Relationship Id="rId'+(e+1)+'" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet" Target="worksheets/sheet'+(e+1)+'.xml" />'}))+'\n  <Relationship Id="rId'+(t+1)+'" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles" Target="styles.xml" />\n  <Relationship Id="rId'+(t+2)+'" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings" Target="sharedStrings.xml" />\n</Relationships>'}({count:i})),this._images){var o=r.folder("media");Object.keys(this._images).forEach((function(t){var n=e._images[t],i=e.imageFilename(n.type);o.file(i,n.data),n.target="../media/"+i}))}var a={};r.file("workbook.xml",function(e){var t=e.sheets,n=e.filterNames,i=e.userNames;return di+'\n<workbook xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships">\n  <fileVersion appName="xl" lastEdited="5" lowestEdited="5" rupBuild="9303" />\n  <workbookPr defaultThemeVersion="124226" />\n  <bookViews>\n    <workbookView xWindow="240" yWindow="45" windowWidth="18195" windowHeight="7995" />\n  </bookViews>\n  <sheets>\n  '+ci(t,(function(e,t){var n=e.options,i=n.name||n.title||"Sheet"+(t+1),r=n.state||"visible";return'<sheet name="'+si(i)+'" state="'+r+'" sheetId="'+(t+1)+'" r:id="rId'+(t+1)+'" />'}))+"\n  </sheets>\n  "+(n.length||i.length?"\n    <definedNames>\n      "+ci(n,(function(e){return'\n         <definedName name="_xlnm._FilterDatabase" hidden="1" localSheetId="'+e.localSheetId+'">'+si(function(e){return/^\'/.test(e)||/^[a-z_][a-z0-9_]*$/i.test(e)?e:"'"+e.replace(/\x27/g,"\\'")+"'"}(e.name))+"!"+si(e.from)+":"+si(e.to)+"</definedName>"}))+"\n      "+ci(i,(function(e){return'\n         <definedName name="'+e.name+'" hidden="'+(e.hidden?1:0)+'" '+(null!=e.localSheetId?'localSheetId="'+e.localSheetId+'"':"")+">"+si(e.value)+"</definedName>"}))+"\n    </definedNames>":"")+'\n  <calcPr fullCalcOnLoad="1" calcId="145621" />\n</workbook>'}({sheets:this._sheets,filterNames:Un(this._sheets,(function(e,t){var n=e.options,i=n.name||n.title||"Sheet"+(t+1);a[i.toLowerCase()]=t;var r=n.filter;if(r){if(r.ref){var o=r.ref.split(":"),s=Ii(o[0]),l=Ii(o[1]);return{localSheetId:t,name:i,from:gi(s.row,s.col),to:gi(l.row,l.col)}}if(void 0!==r.from&&void 0!==r.to)return{localSheetId:t,name:i,from:gi(vi(n),r.from),to:gi(vi(n),r.to)}}})),userNames:Un(this.options.names||[],(function(e){return{name:e.localName,localSheetId:e.sheet?a[e.sheet.toLowerCase()]:null,value:e.value,hidden:e.hidden}}))}));for(var s=r.folder("worksheets"),l=r.folder("drawings"),c=l.folder("_rels"),d=s.folder("_rels"),u=[],h=[],p=0;p<i;p++){var f=e._sheets[p],m="sheet"+(p+1)+".xml",g=f.toXML(p),v=f.relsToXML(),_=f.commentsXML(),b=f.legacyDrawing(),y=f.drawingsXML(e._images);if(v&&d.file(m+".rels",v),_){var w="comments"+f.options.sheetIndex+".xml";r.file(w,_),u.push(w)}if(b&&l.file("vmlDrawing"+f.options.sheetIndex+".vml",b),y){var k="drawing"+f.options.sheetIndex+".xml";l.file(k,y.main),c.file(k+".rels",y.rels),h.push(k)}s.file(m,g)}var x=Un(this._borders,ai),C=Un(this._styles,ai),S=function(e){return e.underline||e.bold||e.italic||e.color||e.fontFamily||e.fontSize},T=Un(C,(function(e){if(e.fontSize&&(e.fontSize=function(e){var t,n=Number(e);return n&&(t=3*n/4),t}(e.fontSize)),e.color&&(e.color=Ci(e.color)),S(e))return e})),D=Un(C,(function(e){if(e.format&&void 0===xi[e.format])return e})),A=Un(C,(function(e){if(e.background)return e.background=Ci(e.background),e}));return r.file("styles.xml",function(e){var t=e.formats,n=e.fonts,i=e.fills,r=e.borders,o=e.styles;return di+'\n<styleSheet\n    xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main"\n    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"\n    mc:Ignorable="x14ac"\n    xmlns:x14ac="http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac">\n  <numFmts count="'+t.length+'">\n  '+ci(t,(function(e,t){return'\n    <numFmt formatCode="'+si(e.format)+'" numFmtId="'+(165+t)+'" />'}))+'\n  </numFmts>\n  <fonts count="'+(n.length+1)+'" x14ac:knownFonts="1">\n    <font>\n       <sz val="11" />\n       <color theme="1" />\n       <name val="Calibri" />\n       <family val="2" />\n       <scheme val="minor" />\n    </font>\n    '+ci(n,(function(e){return"\n    <font>\n      "+(e.bold?"<b/>":"")+"\n      "+(e.italic?"<i/>":"")+"\n      "+(e.underline?"<u/>":"")+'\n      <sz val="'+(e.fontSize||11)+'" />\n      '+(e.color?'<color rgb="'+si(e.color)+'" />':'<color theme="1" />')+"\n      "+(e.fontFamily?'\n        <name val="'+si(e.fontFamily)+'" />\n        <family val="2" />\n      ':'\n        <name val="Calibri" />\n        <family val="2" />\n        <scheme val="minor" />\n      ')+"\n    </font>"}))+'\n  </fonts>\n  <fills count="'+(i.length+2)+'">\n      <fill><patternFill patternType="none"/></fill>\n      <fill><patternFill patternType="gray125"/></fill>\n    '+ci(i,(function(e){return"\n      "+(e.background?'\n        <fill>\n          <patternFill patternType="solid">\n              <fgColor rgb="'+si(e.background)+'"/>\n          </patternFill>\n        </fill>\n      ':"")}))+'\n  </fills>\n  <borders count="'+(r.length+1)+'">\n    <border><left/><right/><top/><bottom/><diagonal/></border>\n    '+ci(r,Di)+'\n  </borders>\n  <cellStyleXfs count="1">\n    <xf borderId="0" fillId="0" fontId="0" />\n  </cellStyleXfs>\n  <cellXfs count="'+(o.length+1)+'">\n    <xf numFmtId="0" fontId="0" fillId="0" borderId="0" xfId="0" />\n    '+ci(o,(function(e){return'\n      <xf xfId="0"\n          '+(e.fontId?'fontId="'+e.fontId+'" applyFont="1"':"")+"\n          "+(e.fillId?'fillId="'+e.fillId+'" applyFill="1"':"")+"\n          "+(e.numFmtId?'numFmtId="'+e.numFmtId+'" applyNumberFormat="1"':"")+"\n          "+(e.textAlign||e.verticalAlign||e.wrap?'applyAlignment="1"':"")+"\n          "+(e.borderId?'borderId="'+e.borderId+'" applyBorder="1"':"")+"\n          "+(null!=e.disabled?'applyProtection="1"':"")+">\n        "+(e.textAlign||e.verticalAlign||e.wrap?"\n        <alignment\n          "+(e.textAlign?'horizontal="'+si(e.textAlign)+'"':"")+"\n          "+(e.verticalAlign?'vertical="'+si(e.verticalAlign)+'"':"")+"\n          "+(e.indent?'indent="'+si(e.indent)+'"':"")+"\n          "+(e.wrap?'wrapText="1"':"")+" />\n        ":"")+"\n        "+(null!=e.disabled?'\n        <protection locked="'+(e.disabled?1:0)+'" />\n        ':"")+"\n      </xf>\n    "}))+'\n  </cellXfs>\n  <cellStyles count="1">\n    <cellStyle name="Normal" xfId="0" builtinId="0"/>\n  </cellStyles>\n  <dxfs count="0" />\n  <tableStyles count="0" defaultTableStyle="TableStyleMedium2" defaultPivotStyle="PivotStyleMedium9" />\n</styleSheet>'}({fonts:T,fills:A,formats:D,borders:x,styles:Un(C,(function(e){var t={};return S(e)&&(t.fontId=oi(e,T)+1),e.background&&(t.fillId=oi(e,A)+2),t.textAlign=e.textAlign,t.indent=e.indent,t.verticalAlign=e.verticalAlign,t.wrap=e.wrap,t.borderId=e.borderId,e.format&&(void 0!==xi[e.format]?t.numFmtId=xi[e.format]:t.numFmtId=165+oi(e,D)),null!=e.disabled&&(t.disabled=e.disabled),t}))})),r.file("sharedStrings.xml",function(e){var t=e.count,n=e.uniqueCount,i=e.indexes;return di+'\n<sst xmlns="http://schemas.openxmlformats.org/spreadsheetml/2006/main" count="'+t+'" uniqueCount="'+n+'">\n  '+ci(Object.keys(i),(function(e){return'\n    <si><t xml:space="preserve">'+si(e.substring(1))+"</t></si>"}))+"\n</sst>"}(this._strings)),t.file("[Content_Types].xml",function(e){var t=e.sheetCount,n=e.commentFiles,i=e.drawingFiles;return di+'\n<Types xmlns="http://schemas.openxmlformats.org/package/2006/content-types">\n  <Default Extension="png" ContentType="image/png"/>\n  <Default Extension="gif" ContentType="image/gif"/>\n  <Default Extension="jpg" ContentType="image/jpeg"/>\n  <Default Extension="rels" ContentType="application/vnd.openxmlformats-package.relationships+xml" />\n  <Default Extension="xml" ContentType="application/xml" />\n  <Default Extension="vml" ContentType="application/vnd.openxmlformats-officedocument.vmlDrawing"/>\n  <Override PartName="/xl/workbook.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml" />\n  <Override PartName="/xl/styles.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml"/>\n  <Override PartName="/xl/sharedStrings.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml"/>\n  '+li(t,(function(e){return'<Override PartName="/xl/worksheets/sheet'+(e+1)+'.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml" />'}))+"\n  "+ci(n,(function(e){return'<Override PartName="/xl/'+e+'" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml"/>'}))+"\n  "+ci(i,(function(e){return'<Override PartName="/xl/drawings/'+e+'" ContentType="application/vnd.openxmlformats-officedocument.drawing+xml"/>'}))+'\n  <Override PartName="/docProps/core.xml" ContentType="application/vnd.openxmlformats-package.core-properties+xml" />\n  <Override PartName="/docProps/app.xml" ContentType="application/vnd.openxmlformats-officedocument.extended-properties+xml" />\n</Types>'}({sheetCount:i,commentFiles:u,drawingFiles:h})),t},Si.prototype.toDataURL=function(){var e=this.toZIP();return e.generateAsync?e.generateAsync(ti).then(ri):ri(e.generate(ti))},Si.prototype.toBlob=function(){var e=this.toZIP();return e.generateAsync?e.generateAsync(ni):new Blob([e.generate(ii)],{type:Jn})};var Ai={};function Mi(e){return e.sort((function(e,t){return e.index-t.index}))}function Ei(e,t){for(var n=0;n<e.length;++n){var i=e[n].split(":"),r=i[0];if(r===t){var o=i[1];return r=Ii(r),{rowSpan:(o=Ii(o)).row-r.row+1,colSpan:o.col-r.col+1}}}}function Ii(e){var t,n=/^([a-z]+)(\d+)$/i.exec(e);return{row:(t=n[2],parseInt(t,10)-1),col:function(e){for(var t=e.toUpperCase(),n=0,i=0;i<t.length;++i)n=26*n+t.charCodeAt(i)-64;return n-1}(n[1])}}function zi(e){return Math.round(9525*e)}function Pi(e,t){var n,i,r=e._source,o=e.index,a=r.cells,s=e.cells;if(a)for(var l=0;l<a.length;l++){var c=a[l]||Ai,d=c.rowSpan||1,u=c.colSpan||1,h=Hi(s,c),p=mi(o,h);if(1===d&&1===u){var f=Ei(t.mergedCells,p);f&&(u=f.colSpan,d=f.rowSpan)}if(Ri(c,s,h,u),(d>1||u>1)&&(n=t.mergedCells,i=p+":"+mi(o+d-1,h+u-1),n.indexOf(i)<0&&n.push(i)),d>1)for(var m=o+1;m<o+d;m++){var g=t.rowsByIndex[m];g||(g=t.rowsByIndex[m]={index:m,cells:[]},t.rowData.push(g)),Ri(c,g.cells,h-1,u+1)}}}function Hi(e,t){var n;return"number"==typeof t.index?(n=t.index,Fi(e,t,t.index)):n=function(e,t){for(var n=e.length,i=0;i<e.length+1;i++)if(!e[i]){e[i]=t,n=i;break}return n}(e,t),n}function Fi(e,t,n){e[n]=t}function Ri(e,t,n,i){for(var r=1;r<i;r++){Fi(t,{borderTop:e.borderTop,borderRight:e.borderRight,borderBottom:e.borderBottom,borderLeft:e.borderLeft},n+r)}}var Li=function(e){var t=e.ref,n=e.columns,i=e.generators;return'\n<autoFilter ref="'+t+'">\n  '+ci(n,(function(e){return'\n    <filterColumn colId="'+e.index+'">\n      '+i[e.filter](e)+"\n    </filterColumn>\n  "}))+"\n</autoFilter>"},Bi=function(e){return"\n<customFilters "+("and"===e.logic?'and="1"':"")+">\n"+ci(e.criteria,(function(e){var t=$i.customOperator(e);return"<customFilter "+(t?'operator="'+t+'"':"")+' val="'+$i.customValue(e)+'"/>'}))+"\n</customFilters>"},Oi=function(e){var t=e.type;return'<dynamicFilter type="'+$i.dynamicFilterType(t)+'" />'},Vi=function(e){var t=e.type,n=e.value;return'<top10 percent="'+(/percent$/i.test(t)?1:0)+'"\n       top="'+(/^top/i.test(t)?1:0)+'"\n       val="'+n+'" />'},Ni=function(e){return"<filters "+(e.blanks?'blank="1"':"")+">\n    "+ci(e.values,(function(e){return'\n      <filter val="'+e+'" />'}))+"\n  </filters>"};function $i(e){return Li({ref:e.ref,columns:e.columns,generators:{custom:Bi,dynamic:Oi,top:Vi,value:Ni}})}$i.customOperator=function(e){return{eq:"equal",gt:"greaterThan",gte:"greaterThanOrEqual",lt:"lessThan",lte:"lessThanOrEqual",ne:"notEqual",doesnotstartwith:"notEqual",doesnotendwith:"notEqual",doesnotcontain:"notEqual",doesnotmatch:"notEqual"}[e.operator.toLowerCase()]},$i.customValue=function(e){function t(e){return e.replace(/([*?])/g,"~$1")}switch(e.operator.toLowerCase()){case"startswith":case"doesnotstartwith":return t(e.value)+"*";case"endswith":case"doesnotendwith":return"*"+t(e.value);case"contains":case"doesnotcontain":return"*"+t(e.value)+"*";default:return e.value}},$i.dynamicFilterType=function(e){return{quarter1:"Q1",quarter2:"Q2",quarter3:"Q3",quarter4:"Q4",january:"M1",february:"M2",march:"M3",april:"M4",may:"M5",june:"M6",july:"M7",august:"M8",september:"M9",october:"M10",november:"M11",december:"M12"}[e.toLowerCase()]||e};!function(e){Yn.register({toString:kendo.toString});let t=kendo.ConvertClass(Si);var n=t.prototype.toDataURL;Object.assign(t.prototype,{toDataURL:function(){var e=n.call(this);if("string"!=typeof e)throw new Error("The toDataURL method can be used only with jsZip 2. Either include jsZip 2 or use the toDataURLAsync method.");return e},toDataURLAsync:function(){var t=e.Deferred(),i=n.call(this);return"string"==typeof i?i=t.resolve(i):i&&i.then&&i.then((function(e){t.resolve(e)}),(function(){t.reject()})),t.promise()}}),window.kendo.ooxml=window.kendo.ooxml||{},window.kendo.ooxml.IntlService=Yn,window.kendo.ooxml.Workbook=t,window.kendo.ooxml.Worksheet=kendo.ConvertClass(bi),window.kendo.ooxml.createZip=function(){if("undefined"==typeof JSZip)throw new Error("JSZip not found. Check http://docs.telerik.com/kendo-ui/framework/excel/introduction#requirements for more details.");return new JSZip}}(window.kendo.jQuery),function(e,t){var n=e.extend;let i=t.ConvertClass(Gn);Bn.register({compile:t.template}),t.ExcelExporter=t.Class.extend({init:function(e){this.options=e;var i=e.dataSource;if(i instanceof t.data.DataSource){i.filter()||(i.options.filter=void 0),this.dataSource=new i.constructor(n({},i.options,{page:e.allPages?0:i.page(),filter:i.filter(),pageSize:e.allPages||e.groupPaging?i.total():i.pageSize()||i.total(),sort:i.sort(),group:i.group(),aggregate:i.aggregate(),isExcelExportRequest:!0}));var r=i.data();if(r.length>0){if(e.hierarchy)for(var o=0;o<r.length;o++)!1!==r[o].expanded&&void 0!==r[o].expanded||(r[o].expanded=!0,r[o].shouldRestoreExpandedState=!0);this.dataSource._data=r;var a=this.dataSource.transport;i._isServerGrouped()&&a.options&&a.options.data&&(a.options.data=null)}}else this.dataSource=t.data.DataSource.create(i)},_hierarchy:function(){var e=this.options.hierarchy,t=this.dataSource;if(e&&t.level){e={itemLevel:function(e){return t.level(e)}};for(var n,i=t.view(),r=0,o=0;o<i.length;o++)(n=t.level(i[o]))>r&&(r=n);e.depth=r+1}else e=!1;return{hierarchy:e}},_restoreExpandedState:function(){var e=this.options,t=e.dataSource.data(),n=e.hierarchy;if(t.length>0&&n)for(var i=0;i<t.length;i++)t[i].shouldRestoreExpandedState&&(t[i].expanded=!1,delete t[i].shouldRestoreExpandedState)},workbook:function(){return e.Deferred(function(e){this.dataSource.fetch().then(function(){var t=new i(n({},this.options,this._hierarchy(),{data:this.dataSource.view(),groups:this.dataSource.group(),aggregates:this.dataSource.aggregates()})).workbook();e.resolve(t,this.dataSource.view())}.bind(this))}.bind(this)).promise()}}),window.kendo.excel=window.kendo.excel||{},window.kendo.excel.ExcelExporter=i,window.kendo.excel.TemplateService=Bn}(kendo.jQuery,kendo),function(e,t){t.ExcelMixin={extend:function(t){t.events.push("excelExport"),t.options.excel=e.extend(t.options.excel,this.options),t.saveAsExcel=this.saveAsExcel},options:{proxyURL:"",allPages:!1,filterable:!1,fileName:"Export.xlsx",collapsible:!1},saveAsExcel:function(e){var n=this.options.excel||{},i=new t.ExcelExporter({columns:this.columns,dataSource:this.dataSource,allPages:n.allPages,filterable:n.filterable,hierarchy:n.hierarchy,collapsible:n.collapsible});i.workbook().then(function(r,o){if(!this.trigger("excelExport",{workbook:r,data:o})){var a=new t.ooxml.Workbook(r);a.options||(a.options={}),a.options.skipCustomHeight=!0,a.toDataURLAsync().then((function(o){t.saveAs({dataURI:o,fileName:r.fileName||n.fileName,proxyURL:n.proxyURL,forceProxy:n.forceProxy}),i._restoreExpandedState&&i._restoreExpandedState(),e&&e.resolve()}))}}.bind(this))}}}(kendo.jQuery,kendo);!function(e){var t=window.kendo,n=t.isFunction;function i(e){return e&&n(e.done)&&n(e.fail)}function r(e){return e&&n(e.then)&&n(e.catch)}var o=t.data.RemoteTransport.extend({init:function(e){var n=e&&e.signalr?e.signalr:{},o=n.promise;if(!o)throw new Error('The "promise" option must be set.');if(!i(o)&&!r(o))throw new Error('The "promise" option must be a Promise.');this.promise=o;var a=n.hub;if(!a)throw new Error('The "hub" option must be set.');if("function"!=typeof a.on||"function"!=typeof a.invoke)throw new Error('The "hub" option is not a valid SignalR hub proxy.');this.hub=a,t.data.RemoteTransport.fn.init.call(this,e)},push:function(e){var t=this.options.signalr.client||{};t.create&&this.hub.on(t.create,e.pushCreate),t.update&&this.hub.on(t.update,e.pushUpdate),t.destroy&&this.hub.on(t.destroy,e.pushDestroy)},_crud:function(n,o){var a=this.hub,s=this.promise,l=this.options.signalr.server;if(!l||!l[o])throw new Error(t.format('The "server.{0}" option must be set.',o));var c=[l[o]],d=this.parameterMap(n.data,o);e.isEmptyObject(d)||c.push(d),i(s)?s.done((function(){a.invoke.apply(a,c).done(n.success).fail(n.error)})):r(s)&&s.then((function(){a.invoke.apply(a,c).then(n.success).catch(n.error)}))},read:function(e){this._crud(e,"read")},create:function(e){this._crud(e,"create")},update:function(e){this._crud(e,"update")},destroy:function(e){this._crud(e,"destroy")}});e.extend(!0,t.data,{transports:{signalr:o}})}(window.kendo.jQuery);kendo;var Ui=function(){return"undefined"!=typeof window},Wi={wp:/(Windows Phone(?: OS)?)\s(\d+)\.(\d+(\.\d+)?)/,fire:/(Silk)\/(\d+)\.(\d+(\.\d+)?)/,android:/(Android|Android.*(?:Opera|Firefox).*?\/)\s*(\d+)(\.(\d+(\.\d+)?))?/,iphone:/(iPhone|iPod).*OS\s+(\d+)[\._]([\d\._]+)/,ipad:/(iPad).*OS\s+(\d+)[\._]([\d_]+)/,meego:/(MeeGo).+NokiaBrowser\/(\d+)\.([\d\._]+)/,webos:/(webOS)\/(\d+)\.(\d+(\.\d+)?)/,blackberry:/(BlackBerry|BB10).*?Version\/(\d+)\.(\d+(\.\d+)?)/,playbook:/(PlayBook).*?Tablet\s*OS\s*(\d+)\.(\d+(\.\d+)?)/,windows:/(MSIE)\s+(\d+)\.(\d+(\.\d+)?)/,tizen:/(tizen).*?Version\/(\d+)\.(\d+(\.\d+)?)/i,sailfish:/(sailfish).*rv:(\d+)\.(\d+(\.\d+)?).*firefox/i,ffos:/(Mobile).*rv:(\d+)\.(\d+(\.\d+)?).*Firefox/},ji={ios:/^i(phone|pad|pod)$/i,android:/^android|fire$/i,blackberry:/^blackberry|playbook/i,windows:/windows/,wp:/wp/,flat:/sailfish|ffos|tizen/i,meego:/meego/},qi={edge:/(edge)[ \/]([\w.]+)/i,webkit:/(chrome)[ \/]([\w.]+)/i,safari:/(webkit)[ \/]([\w.]+)/i,opera:/(opera)(?:.*version|)[ \/]([\w.]+)/i,msie:/(msie\s|trident.*? rv:)([\w.]+)/i,mozilla:/(mozilla)(?:.*? rv:([\w.]+)|)/i},Gi={omini:/Opera\sMini/i,omobile:/Opera\sMobi/i,firefox:/Firefox|Fennec/i,mobilesafari:/version\/.*safari/i,ie:/MSIE|Windows\sPhone/i,chrome:/chrome|crios/i,webkit:/webkit/i},Ki=function(e,t,n){for(var i in t)if(t.hasOwnProperty(i)&&t[i].test(e))return i;return void 0!==n?n:e},Yi=Ui()&&window.navigator?window.navigator.userAgent:null,Qi=Yi?function(e){var t=null,n=[];for(var i in qi)if(qi.hasOwnProperty(i)&&(n=e.match(qi[i]))){(t={})[i]=!0,t[n[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,t.version=parseInt(document.documentMode||n[2],10);break}return t}(Yi):null;Yi&&function(e){var t,n=[];for(var i in Wi)if(Wi.hasOwnProperty(i)){if(!(n=e.match(Wi[i])))continue;if("windows"===i&&"plugins"in window.navigator)return null;var r={};return r.device=i,r.browser=Ki(e,Gi,"default"),r.name=Ki(i,ji),r[r.name]=!0,r.majorVersion=n[2],r.minorVersion=n[3]?n[3].replace("_","."):".0",t=r.minorVersion.replace(".","").substr(0,2),r.flatVersion=r.majorVersion+t+new Array(3-(t.length<3?t.length:2)).join("0"),r.cordova=void 0!==typeof window.PhoneGap||void 0!==typeof window.cordova,r.appMode=window.navigator.standalone||/file|local|wmapp/.test(window.location.protocol)||r.cordova,r}}(Yi),Ui()&&window,Qi&&!Qi.chrome&&window.MSPointerEvent,Qi&&!Qi.chrome&&window.PointerEvent;var Xi={};Xi[void 0]=function(e){return e};var Zi=/\/\*[\s\S]*?\*\//g,Ji=/([^\s:;]+?)\s*:\s*((?:(?:url\(\s*(?:(?:[^"')\\]|\\.)*|"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*')\s*\)|"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*'|[^;"'])*?)\s*)(?=;|$)/gi,er=/&quot;|&#34;|&#x22;/gi,tr=/&apos;|&#39;|&#x27;/gi;function nr(e){for(var t,n,i={},r=(e||"").replace(Zi,"").replace(er,'"').replace(tr,"'"),o=Ji.exec(r);null!==o;)t=o[1].trim(),n=o[2].trim(),i[t]=n,o=Ji.exec(r);return i}var ir=function(){return"undefined"!=typeof window},rr={wp:/(Windows Phone(?: OS)?)\s(\d+)\.(\d+(\.\d+)?)/,fire:/(Silk)\/(\d+)\.(\d+(\.\d+)?)/,android:/(Android|Android.*(?:Opera|Firefox).*?\/)\s*(\d+)(\.(\d+(\.\d+)?))?/,iphone:/(iPhone|iPod).*OS\s+(\d+)[\._]([\d\._]+)/,ipad:/(iPad).*OS\s+(\d+)[\._]([\d_]+)/,meego:/(MeeGo).+NokiaBrowser\/(\d+)\.([\d\._]+)/,webos:/(webOS)\/(\d+)\.(\d+(\.\d+)?)/,blackberry:/(BlackBerry|BB10).*?Version\/(\d+)\.(\d+(\.\d+)?)/,playbook:/(PlayBook).*?Tablet\s*OS\s*(\d+)\.(\d+(\.\d+)?)/,windows:/(MSIE)\s+(\d+)\.(\d+(\.\d+)?)/,tizen:/(tizen).*?Version\/(\d+)\.(\d+(\.\d+)?)/i,sailfish:/(sailfish).*rv:(\d+)\.(\d+(\.\d+)?).*firefox/i,ffos:/(Mobile).*rv:(\d+)\.(\d+(\.\d+)?).*Firefox/},or={ios:/^i(phone|pad|pod)$/i,android:/^android|fire$/i,blackberry:/^blackberry|playbook/i,windows:/windows/,wp:/wp/,flat:/sailfish|ffos|tizen/i,meego:/meego/},ar={edge:/(edge)[ \/]([\w.]+)/i,webkit:/(chrome)[ \/]([\w.]+)/i,safari:/(webkit)[ \/]([\w.]+)/i,opera:/(opera)(?:.*version|)[ \/]([\w.]+)/i,msie:/(msie\s|trident.*? rv:)([\w.]+)/i,mozilla:/(mozilla)(?:.*? rv:([\w.]+)|)/i},sr={omini:/Opera\sMini/i,omobile:/Opera\sMobi/i,firefox:/Firefox|Fennec/i,mobilesafari:/version\/.*safari/i,ie:/MSIE|Windows\sPhone/i,chrome:/chrome|crios/i,webkit:/webkit/i},lr=function(e,t,n){for(var i in t)if(t.hasOwnProperty(i)&&t[i].test(e))return i;return void 0!==n?n:e},cr=function(e){var t,n=[];for(var i in rr)if(rr.hasOwnProperty(i)){if(!(n=e.match(rr[i])))continue;if("windows"===i&&"plugins"in window.navigator)return null;var r={};return r.device=i,r.browser=lr(e,sr,"default"),r.name=lr(i,or),r[r.name]=!0,r.majorVersion=n[2],r.minorVersion=n[3]?n[3].replace("_","."):".0",t=r.minorVersion.replace(".","").substr(0,2),r.flatVersion=r.majorVersion+t+new Array(3-(t.length<3?t.length:2)).join("0"),r.cordova=void 0!==typeof window.PhoneGap||void 0!==typeof window.cordova,r.appMode=window.navigator.standalone||/file|local|wmapp/.test(window.location.protocol)||r.cordova,r}return null},dr=function(e){var t=null,n=[];for(var i in ar)if(ar.hasOwnProperty(i)&&(n=e.match(ar[i]))){(t={})[i]=!0,t[n[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,t.version=parseInt(document.documentMode||n[2],10);break}return t},ur=ir()&&window.navigator?window.navigator.userAgent:null,hr=ur?dr(ur):null;ur&&cr(ur),ir()&&window,hr&&!hr.chrome&&window.MSPointerEvent,hr&&!hr.chrome&&window.PointerEvent;var pr={};pr[void 0]=function(e){return e};var fr=function(){},mr=function(e){function t(){e.call(this),this._events={}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.bind=function(e,t,n){var i=arguments,r=this,o=vr(e),a=gr(t),s=o.length;if(void 0===t){for(var l in e)r.bind(l,e[l]);return this}for(var c=function(e){var s=o[e],l=a?t:t[s];if(l){if(n){var c=l;(l=function(){r.unbind(s,l),c.apply(r,i)}).original=c}(r._events[s]=r._events[s]||[]).push(l)}},d=0;d<s;d++)c(d);return this},t.prototype.one=function(e,t){return this.bind(e,t,!0)},t.prototype.first=function(e,t){for(var n=vr(e),i=gr(t),r=0,o=n.length;r<o;r++){var a=n[r],s=i?t:t[a];if(s)(this._events[a]=this._events[a]||[]).unshift(s)}return this},t.prototype.trigger=function(e,t){void 0===t&&(t={});var n=this._events[e];if(n){var i=n.length;t.sender=this,t._defaultPrevented=!1,t.preventDefault=_r,t.isDefaultPrevented=br,n=n.slice();for(var r=0;r<i;r++)n[r].call(this,t);return!0===t._defaultPrevented}return!1},t.prototype.unbind=function(e,t){var n=this._events[e];if(void 0===e)this._events={};else if(n)if(t)for(var i=n.length-1;i>=0;i--)n[i]!==t&&n[i].original!==t||n.splice(i,1);else this._events[e]=[];return this},t}(fr);function gr(e){return"function"==typeof e}function vr(e){return"string"==typeof e?[e]:e}function _r(){this._defaultPrevented=!0}function br(){return!0===this._defaultPrevented}var yr=function(e){var t="undefined"!=typeof window?window:{},n=t.requestAnimationFrame||t.webkitRequestAnimationFrame||t.mozRequestAnimationFrame||t.oRequestAnimationFrame||t.msRequestAnimationFrame||function(e){setTimeout(e,1e3/60)};yr=function(e){return n.call(t,e)},yr(e)},wr=yr,kr=/&/g,xr=/</g,Cr=/"/g,Sr=/'/g,Tr=/>/g;function Dr(e){return String(e).replace(kr,"&amp;").replace(xr,"&lt;").replace(Tr,"&gt;").replace(Cr,"&quot;").replace(Sr,"&#39;")}function Ar(e){var t=window.console;void 0!==t&&t.log&&t.log(e)}function Mr(e){var t=e.dataURI,n=e.fileName,i=t;if("string"==typeof i&&window.Blob){for(var r=i.split(";base64,"),o=r[0],a=atob(r[1]),s=new Uint8Array(a.length),l=0;l<a.length;l++)s[l]=a.charCodeAt(l);i=new Blob([s.buffer],{type:o})}if(navigator.msSaveBlob)navigator.msSaveBlob(i,n);else{var c=document.createElement("a");c.download=n,i=c.href=URL.createObjectURL(i);var d=document.createEvent("MouseEvents");d.initMouseEvent("click",!0,!1,window,0,0,0,0,0,!1,!1,!1,!1,0,null),c.dispatchEvent(d),setTimeout((function(){URL.revokeObjectURL(i)}))}}var Er=null,Ir={get browser(){return"undefined"==typeof window||Er||(Er=function(e){var t={edge:/(edge)[ \/]([\w.]+)/i,webkit:/(chrome)[ \/]([\w.]+)/i,safari:/(webkit)[ \/]([\w.]+)/i,opera:/(opera)(?:.*version|)[ \/]([\w.]+)/i,msie:/(msie\s|trident.*? rv:)([\w.]+)/i,mozilla:/(mozilla)(?:.*? rv:([\w.]+))/i},n={};for(var i in t)if(t.hasOwnProperty(i)){var r=e.match(t[i]);if(r){n[i]=!0,n[r[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,n.version=parseInt(document.documentMode||r[2],10);break}}return n}(window.navigator.userAgent)),Er}};var zr=Date.now||function(){return(new Date).getTime()};function Pr(e,t){var n,i=0;if(!t||t<=0)return e;var r=function(){var r=zr()-i,o=arguments,a=function(){e.apply(null,o),i=zr()};if(!i)return a();n&&clearTimeout(n),r>t?a():n=setTimeout(a,t-r)};return r.cancel=function(){clearTimeout(n)},r}var Hr={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgrey:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",grey:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"778899",lightslategrey:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",red:"ff0000",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"},Fr=Ir.browser,Rr=function(e){var t=Object.keys(Hr);t.push("transparent");var n=new RegExp("^("+t.join("|")+")(\\W|$)","i");return Rr=function(e){return n.exec(e)},n.exec(e)},Lr=function(e){function t(){e.call(this)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.toHSV=function(){return this},t.prototype.toRGB=function(){return this},t.prototype.toHex=function(e){return this.toBytes().toHex(e)},t.prototype.toBytes=function(){return this},t.prototype.toCss=function(e){return"#"+this.toHex(e)},t.prototype.toCssRgba=function(){var e=this.toBytes();return"rgba("+e.r+", "+e.g+", "+e.b+", "+parseFloat(Number(this.a).toFixed(3))+")"},t.prototype.toDisplay=function(){return Fr.msie&&Fr.version<9?this.toCss():this.toCssRgba()},t.prototype.equals=function(e){return e===this||null!=e&&this.toCssRgba()===jr(e).toCssRgba()},t.prototype.diff=function(e){if(null===e)return NaN;var t=this.toBytes(),n=e.toBytes();return Math.sqrt(Math.pow(.3*(t.r-n.r),2)+Math.pow(.59*(t.g-n.g),2)+Math.pow(.11*(t.b-n.b),2))},t.prototype.clone=function(){var e=this.toBytes();return e===this&&(e=new Or(e.r,e.g,e.b,e.a)),e},t}(fr),Br=function(e){function t(t,n,i,r){e.call(this),this.r=t,this.g=n,this.b=i,this.a=r}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.toHSV=function(){var e,t,n=this,i=n.r,r=n.g,o=n.b,a=Math.min(i,r,o),s=Math.max(i,r,o),l=s-a,c=s;return 0===l?new Nr(0,0,c,this.a):(0!==s?(t=l/s,e=i===s?(r-o)/l:r===s?2+(o-i)/l:4+(i-r)/l,(e*=60)<0&&(e+=360)):(t=0,e=-1),new Nr(e,t,c,this.a))},t.prototype.toHSL=function(){var e,t,n=this,i=n.r,r=n.g,o=n.b,a=Math.max(i,r,o),s=Math.min(i,r,o),l=(a+s)/2;if(a===s)e=t=0;else{var c=a-s;switch(t=l>.5?c/(2-a-s):c/(a+s),a){case i:e=(r-o)/c+(r<o?6:0);break;case r:e=(o-i)/c+2;break;case o:e=(i-r)/c+4}}return new $r(60*e,100*t,100*l,this.a)},t.prototype.toBytes=function(){return new Or(255*this.r,255*this.g,255*this.b,this.a)},t}(Lr),Or=function(e){function t(t,n,i,r){e.call(this,Math.round(t),Math.round(n),Math.round(i),r)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.toRGB=function(){return new e(this.r/255,this.g/255,this.b/255,this.a)},t.prototype.toHSV=function(){return this.toRGB().toHSV()},t.prototype.toHSL=function(){return this.toRGB().toHSL()},t.prototype.toHex=function(e){var t=Vr(this.r,2)+Vr(this.g,2)+Vr(this.b,2);return e&&e.alpha&&(t+=Vr(Math.round(255*this.a),2)),t},t.prototype.toBytes=function(){return this},t}(Br);function Vr(e,t,n){void 0===n&&(n="0");for(var i=e.toString(16);t>i.length;)i=n+i;return i}var Nr=function(e){function t(t,n,i,r){e.call(this),this.h=t,this.s=n,this.v=i,this.a=r}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.toRGB=function(){var e,t,n,i=this,r=i.h,o=i.s,a=i.v;if(0===o)e=t=n=a;else{r/=60;var s=Math.floor(r),l=r-s,c=a*(1-o),d=a*(1-o*l),u=a*(1-o*(1-l));switch(s){case 0:e=a,t=u,n=c;break;case 1:e=d,t=a,n=c;break;case 2:e=c,t=a,n=u;break;case 3:e=c,t=d,n=a;break;case 4:e=u,t=c,n=a;break;default:e=a,t=c,n=d}}return new Br(e,t,n,this.a)},t.prototype.toHSL=function(){return this.toRGB().toHSL()},t.prototype.toBytes=function(){return this.toRGB().toBytes()},t}(Lr),$r=function(e){function t(t,n,i,r){e.call(this),this.h=t,this.s=n,this.l=i,this.a=r}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.toRGB=function(){var e,t,n,i=this.h/360,r=this.s/100,o=this.l/100;if(0===r)e=t=n=o;else{var a=o<.5?o*(1+r):o+r-o*r,s=2*o-a;e=Ur(s,a,i+1/3),t=Ur(s,a,i),n=Ur(s,a,i-1/3)}return new Br(e,t,n,this.a)},t.prototype.toHSV=function(){return this.toRGB().toHSV()},t.prototype.toBytes=function(){return this.toRGB().toBytes()},t}(Lr);function Ur(e,t,n){var i=n;return i<0&&(i+=1),i>1&&(i-=1),i<1/6?e+6*(t-e)*i:i<.5?t:i<2/3?e+(t-e)*(2/3-i)*6:e}function Wr(e){return parseFloat(parseFloat(parseInt(e,16)/255).toFixed(3))}function jr(e,t){var n,i;if(!e||"none"===e)return null;if(e instanceof Lr)return e;var r=e.toLowerCase();if(n=Rr(r))return(r="transparent"===n[1]?new Br(1,1,1,0):jr(Hr[n[1]],t)).match=[n[1]],r;if((n=/^#?([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})\b/i.exec(r))?i=new Or(parseInt(n[1],16),parseInt(n[2],16),parseInt(n[3],16),1):(n=/^#?([0-9a-f])([0-9a-f])([0-9a-f])\b/i.exec(r))?i=new Or(parseInt(n[1]+n[1],16),parseInt(n[2]+n[2],16),parseInt(n[3]+n[3],16),1):(n=/^#?([0-9a-f])([0-9a-f])([0-9a-f])([0-9a-f])\b/i.exec(r))?i=new Or(parseInt(n[1]+n[1],16),parseInt(n[2]+n[2],16),parseInt(n[3]+n[3],16),Wr(n[4]+n[4])):(n=/^#?([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})\b/i.exec(r))?i=new Or(parseInt(n[1],16),parseInt(n[2],16),parseInt(n[3],16),Wr(n[4])):(n=/^rgb\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*\)/.exec(r))?i=new Or(parseInt(n[1],10),parseInt(n[2],10),parseInt(n[3],10),1):(n=/^rgba\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9.]+)\s*\)/.exec(r))?i=new Or(parseInt(n[1],10),parseInt(n[2],10),parseInt(n[3],10),parseFloat(n[4])):(n=/^rgb\(\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*\)/.exec(r))?i=new Br(parseFloat(n[1])/100,parseFloat(n[2])/100,parseFloat(n[3])/100,1):(n=/^rgba\(\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9.]+)\s*\)/.exec(r))?i=new Br(parseFloat(n[1])/100,parseFloat(n[2])/100,parseFloat(n[3])/100,parseFloat(n[4])):(n=/^color\(\s*srgb\s*([0-9]*\.?[0-9]+)\s+([0-9]*\.?[0-9]+)\s+([0-9]*\.?[0-9]+)\s*(\/\s+([0-9]*\.?[0-9]+))?\)/.exec(r))&&(i=new Br(parseFloat(n[1]),parseFloat(n[2]),parseFloat(n[3]),parseFloat(n[5]||"1"))),i)i.match=n;else if(!t)throw new Error("Cannot parse color: "+r);return i}var qr=function(e){function t(n){var i=this;if(e.call(this),1===arguments.length)for(var r=t.formats,o=this.resolveColor(n),a=0;a<r.length;a++){var s=r[a].re,l=r[a].process,c=s.exec(o);if(c){var d=l(c);i.r=d[0],i.g=d[1],i.b=d[2]}}else this.r=arguments[0],this.g=arguments[1],this.b=arguments[2];this.r=this.normalizeByte(this.r),this.g=this.normalizeByte(this.g),this.b=this.normalizeByte(this.b)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.toHex=function(){var e=this.padDigit,t=this.r.toString(16),n=this.g.toString(16),i=this.b.toString(16);return"#"+e(t)+e(n)+e(i)},t.prototype.resolveColor=function(e){var n=e||"black";return"#"===n.charAt(0)&&(n=n.substr(1,6)),n=(n=n.replace(/ /g,"")).toLowerCase(),n=t.namedColors[n]||n},t.prototype.normalizeByte=function(e){return e<0||isNaN(e)?0:e>255?255:e},t.prototype.padDigit=function(e){return 1===e.length?"0"+e:e},t.prototype.brightness=function(e){var t=Math.round;return this.r=t(this.normalizeByte(this.r*e)),this.g=t(this.normalizeByte(this.g*e)),this.b=t(this.normalizeByte(this.b*e)),this},t.prototype.percBrightness=function(){return Math.sqrt(.241*this.r*this.r+.691*this.g*this.g+.068*this.b*this.b)},t.prototype.isDark=function(){return this.percBrightness()<180},t.fromBytes=function(e,t,n,i){return new Or(e,t,n,null!=i?i:1)},t.fromRGB=function(e,t,n,i){return new Br(e,t,n,null!=i?i:1)},t.fromHSV=function(e,t,n,i){return new Nr(e,t,n,null!=i?i:1)},t.fromHSL=function(e,t,n,i){return new $r(e,t,n,null!=i?i:1)},t}(fr);qr.formats=[{re:/^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,process:function(e){return[parseInt(e[1],10),parseInt(e[2],10),parseInt(e[3],10)]}},{re:/^(\w{2})(\w{2})(\w{2})$/,process:function(e){return[parseInt(e[1],16),parseInt(e[2],16),parseInt(e[3],16)]}},{re:/^(\w{1})(\w{1})(\w{1})$/,process:function(e){return[parseInt(e[1]+e[1],16),parseInt(e[2]+e[2],16),parseInt(e[3]+e[3],16)]}}],qr.namedColors=Hr;var Gr=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.observers=function(){return this._observers=this._observers||[],this._observers},t.prototype.addObserver=function(e){return this._observers?this._observers.push(e):this._observers=[e],this},t.prototype.removeObserver=function(e){var t=this.observers(),n=t.indexOf(e);return-1!==n&&t.splice(n,1),this},t.prototype.trigger=function(e,t){var n=this._observers;if(n&&!this._suspended)for(var i=0;i<n.length;i++){var r=n[i];r[e]&&r[e](t)}return this},t.prototype.optionsChange=function(e){void 0===e&&(e={}),e.element=this,this.trigger("optionsChange",e)},t.prototype.geometryChange=function(){this.trigger("geometryChange",{element:this})},t.prototype.suspend=function(){return this._suspended=(this._suspended||0)+1,this},t.prototype.resume=function(){return this._suspended=Math.max((this._suspended||0)-1,0),this},t.prototype._observerField=function(e,t){this[e]&&this[e].removeObserver(this),this[e]=t,t.addObserver(this)},t}(fr);function Kr(e,t){return e.push.apply(e,t),e}var Yr={1:"i",10:"x",100:"c",2:"ii",20:"xx",200:"cc",3:"iii",30:"xxx",300:"ccc",4:"iv",40:"xl",400:"cd",5:"v",50:"l",500:"d",6:"vi",60:"lx",600:"dc",7:"vii",70:"lxx",700:"dcc",8:"viii",80:"lxxx",800:"dccc",9:"ix",90:"xc",900:"cm",1e3:"m"};function Qr(e){for(var t=[1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],n="";e>0;)e<t[0]?t.shift():(n+=Yr[t[0]],e-=t[0]);return n}function Xr(){var e,t,n=new Promise((function(i,r){e=function(e){return n._state="resolved",i(e),n},t=function(e){return n._state="rejected",r(e),n}}));return n._state="pending",n.resolve=e,n.reject=t,n.state=function(){return n._state},n}function Zr(e){return void 0!==e}var Jr=1;function eo(){return"kdef"+Jr++}var to=Math.PI/180,no=Number.MAX_VALUE,io=-Number.MAX_VALUE;function ro(e){return e/to}var oo=String.fromCharCode;function ao(e){return oo(e>>8)+oo(255&e)}var so="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function lo(e){for(var t="",n=0,i=function(e){for(var t="",n=0;n<e.length;n++){var i=e.charCodeAt(n);if(55296<=i&&i<=56319){var r=i,o=e.charCodeAt(++n);isNaN(o)||(i=1024*(r-55296)+(o-56320)+65536)}i<128?t+=oo(i):i<2048?(t+=oo(192|i>>>6),t+=oo(128|63&i)):i<65536?(t+=oo(224|i>>>12),t+=oo(128|i>>>6&63),t+=oo(128|63&i)):i<1114111&&(t+=oo(240|i>>>18),t+=oo(128|i>>>12&63),t+=oo(128|i>>>6&63),t+=oo(128|63&i))}return t}(e);n<i.length;){var r=i.charCodeAt(n++),o=i.charCodeAt(n++),a=i.charCodeAt(n++),s=r>>2,l=(3&r)<<4|o>>4,c=(15&o)<<2|a>>6,d=63&a;isNaN(o)?c=d=64:isNaN(a)&&(d=64),t=t+so.charAt(s)+so.charAt(l)+so.charAt(c)+so.charAt(d)}return t}function co(e){return Zr((e.x||{}).location)?{x:e.x.location,y:e.y.location}:{x:e.pageX||e.clientX||0,y:e.pageY||e.clientY||0}}function uo(e){return void 0===e&&(e={}),e.touch?e.touch.initialTouch:e.target}function ho(e){return""===e||null===e||"none"===e||"transparent"===e||!Zr(e)}function po(e){if(e)return e[e.length-1]}function fo(e,t,n){return Math.max(Math.min(e,n),t)}function mo(e,t){if(e.length<2)return e.slice();return function e(n){if(n.length<=1)return n;var i=Math.floor(n.length/2),r=n.slice(0,i),o=n.slice(i);return function(e,n){for(var i=[],r=0,o=0,a=0;r<e.length&&o<n.length;)t(e[r],n[o])<=0?i[a++]=e[r++]:i[a++]=n[o++];return r<e.length&&i.push.apply(i,e.slice(r)),o<n.length&&i.push.apply(i,n.slice(o)),i}(r=e(r),o=e(o))}(e)}function go(e){return Promise.all(e)}function vo(e){return e*to}function _o(e,t){var n,i=(n=t)?Math.pow(10,n):1;return Math.round(e*i)/i}function bo(e,t){return Zr(e)?e:t}function yo(e,t){for(var n in t)for(var i=n.trim().split(" "),r=0;r<i.length;r++)e.addEventListener(i[r],t[n],!1)}function wo(e){var t=e.getBoundingClientRect(),n=document.documentElement;return{top:t.top+(window.pageYOffset||n.scrollTop)-(n.clientTop||0),left:t.left+(window.pageXOffset||n.scrollLeft)-(n.clientLeft||0)}}function ko(e,t){for(var n={},i=window.getComputedStyle(e)||{},r=Array.isArray(t)?t:[t],o=0;o<r.length;o++){var a=r[o];n[a]=i[a]}return n}function xo(e){return isNaN(e)?e:e+"px"}function Co(e,t){if(!t){var n=ko(e,["width","height"]);return{width:parseInt(n.width,10),height:parseInt(n.height,10)}}var i=t.width,r=t.height;Zr(i)&&(e.style.width=xo(i)),Zr(r)&&(e.style.height=xo(r))}function So(e,t){for(var n in void 0===t&&(t={}),t)for(var i=n.trim().split(" "),r=0;r<i.length;r++)e.removeEventListener(i[r],t[n],!1)}function To(e){var t=ko(e,["paddingLeft","paddingTop"]),n=t.paddingLeft,i=t.paddingTop;return{top:parseFloat(i),left:parseFloat(n)}}var Do=function(e){function t(t,n,i,r,o,a){void 0===t&&(t=0),void 0===n&&(n=0),void 0===i&&(i=0),void 0===r&&(r=0),void 0===o&&(o=0),void 0===a&&(a=0),e.call(this),this.a=t,this.b=n,this.c=i,this.d=r,this.e=o,this.f=a}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.multiplyCopy=function(e){return new t(this.a*e.a+this.c*e.b,this.b*e.a+this.d*e.b,this.a*e.c+this.c*e.d,this.b*e.c+this.d*e.d,this.a*e.e+this.c*e.f+this.e,this.b*e.e+this.d*e.f+this.f)},t.prototype.invert=function(){var e=this,n=e.a,i=e.b,r=e.c,o=e.d,a=e.e,s=e.f,l=n*o-i*r;return 0===l?null:new t(o/l,-i/l,-r/l,n/l,(r*s-o*a)/l,(i*a-n*s)/l)},t.prototype.clone=function(){return new t(this.a,this.b,this.c,this.d,this.e,this.f)},t.prototype.equals=function(e){return!!e&&(this.a===e.a&&this.b===e.b&&this.c===e.c&&this.d===e.d&&this.e===e.e&&this.f===e.f)},t.prototype.round=function(e){return this.a=_o(this.a,e),this.b=_o(this.b,e),this.c=_o(this.c,e),this.d=_o(this.d,e),this.e=_o(this.e,e),this.f=_o(this.f,e),this},t.prototype.toArray=function(e){var t=[this.a,this.b,this.c,this.d,this.e,this.f];if(Zr(e))for(var n=0;n<t.length;n++)t[n]=_o(t[n],e);return t},t.prototype.toString=function(e,t){return void 0===t&&(t=","),this.toArray(e).join(t)},t.translate=function(e,n){return new t(1,0,0,1,e,n)},t.unit=function(){return new t(1,0,0,1,0,0)},t.rotate=function(e,n,i){var r=new t;return r.a=Math.cos(vo(e)),r.b=Math.sin(vo(e)),r.c=-r.b,r.d=r.a,r.e=n-n*r.a+i*r.b||0,r.f=i-i*r.a-n*r.b||0,r},t.scale=function(e,n){return new t(e,0,0,n,0,0)},t}(fr);Do.IDENTITY=Do.unit();var Ao=/matrix\((.*)\)/;function Mo(e){var t=getComputedStyle(e).transform;return"none"===t?Do.unit():function(e){var t=e.match(Ao);if(null===t||2!==t.length)return Do.unit();var n=t[1].split(",").map((function(e){return parseFloat(e)}));return new(Function.prototype.bind.apply(Do,[null].concat(n)))}(t)}function Eo(e){if(!e)return Do.unit();for(var t=Mo(e),n=e.parentElement;n;){var i=Mo(n);t=t.multiplyCopy(i),n=n.parentElement}return t.b=t.c=t.e=t.f=0,t}var Io=function(e){function t(t){e.call(this),this._size=t,this._length=0,this._map={}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.put=function(e,t){var n=this._map,i={key:e,value:t};n[e]=i,this._head?(this._tail.newer=i,i.older=this._tail,this._tail=i):this._head=this._tail=i,this._length>=this._size?(n[this._head.key]=null,this._head=this._head.newer,this._head.older=null):this._length++},t.prototype.get=function(e){var t=this._map[e];if(t)return t===this._head&&t!==this._tail&&(this._head=t.newer,this._head.older=null),t!==this._tail&&(t.older&&(t.older.newer=t.newer,t.newer.older=t.older),t.older=this._tail,t.newer=null,this._tail.newer=t,this._tail=t),t.value},t}(fr),zo=/\r?\n|\r|\t/g;function Po(e){return String(e).replace(zo," ")}function Ho(e){var t=[];for(var n in e)t.push(n+e[n]);return t.sort().join("")}function Fo(e){for(var t=2166136261,n=0;n<e.length;++n)t+=(t<<1)+(t<<4)+(t<<7)+(t<<8)+(t<<24),t^=e.charCodeAt(n);return t>>>0}var Ro,Lo={baselineMarkerSize:1};"undefined"!=typeof document&&((Ro=document.createElement("div")).style.setProperty("position","absolute","important"),Ro.style.setProperty("top","-4000px","important"),Ro.style.setProperty("width","auto","important"),Ro.style.setProperty("height","auto","important"),Ro.style.setProperty("padding","0","important"),Ro.style.setProperty("margin","0","important"),Ro.style.setProperty("border","0","important"),Ro.style.setProperty("line-height","normal","important"),Ro.style.setProperty("visibility","hidden","important"),Ro.style.setProperty("white-space","pre","important"));var Bo=function(e){function t(t){e.call(this),this._cache=new Io(1e3),this.options=Object.assign({},Lo,t)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.measure=function(e,t,n){if(void 0===n&&(n={}),null==e)return{width:0,height:0,baseline:0};var i=Fo(e+Ho(t)),r=this._cache.get(i);if(r)return r;var o={width:0,height:0,baseline:0},a=n.box||Ro,s=this._baselineMarker().cloneNode(!1);for(var l in t){var c=t[l];void 0!==c&&(a.style[l]=c)}var d=!1!==n.normalizeText?Po(e):String(e);return a.textContent=d,a.appendChild(s),document.body.appendChild(a),d.length&&(o.width=a.offsetWidth-this.options.baselineMarkerSize,o.height=a.offsetHeight,o.baseline=s.offsetTop+this.options.baselineMarkerSize),o.width>0&&o.height>0&&this._cache.put(i,o),a.parentNode.removeChild(a),o},t.prototype._baselineMarker=function(){var e=document.createElement("div");return e.style.display="inline-block",e.style.verticalAlign="baseline",e.style.width=this.options.baselineMarkerSize+"px",e.style.height=this.options.baselineMarkerSize+"px",e.style.overflow="hidden",e},t}(fr);function Oo(e,t,n){return Bo.current.measure(e,t,n)}Bo.current=new Bo;var Vo=Object.freeze({__proto__:null,DEG_TO_RAD:to,LRUCache:Io,MAX_NUM:no,MIN_NUM:io,TextMetrics:Bo,append:Kr,arabicToRoman:Qr,bindEvents:yo,createPromise:Xr,defined:Zr,definitionId:eo,deg:ro,elementOffset:wo,elementPadding:To,elementScale:Eo,elementSize:Co,elementStyles:ko,encodeBase64:lo,eventCoordinates:co,eventElement:uo,hashKey:Fo,isTransparent:ho,last:po,limitValue:fo,measureText:Oo,mergeSort:mo,normalizeText:Po,now:zr,objectKey:Ho,promiseAll:go,rad:vo,round:_o,unbindEvents:So,valueOrDefault:bo}),No={}.toString,$o=function(e){function t(t,n){for(var i in void 0===n&&(n=""),e.call(this),this.prefix=n,t){var r=t[i];r=this._wrap(r,i),this[i]=r}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.get=function(e){for(var t=e.split("."),n=this;t.length&&n;){n=n[t.shift()]}return n},t.prototype.set=function(e,t){this.get(e)!==t&&(this._set(e,this._wrap(t,e)),this.optionsChange({field:this.prefix+e,value:t}))},t.prototype._set=function(e,n){var i=e.indexOf(".")>=0,r=this,o=e;if(i){for(var a=o.split("."),s=this.prefix;a.length>1;){s+=(o=a.shift())+".";var l=r[o];l||((l=new t({},s)).addObserver(this),r[o]=l),r=l}o=a[0]}r._clear(o),r[o]=n},t.prototype._clear=function(e){var t=this[e];t&&t.removeObserver&&t.removeObserver(this)},t.prototype._wrap=function(e,n){var i=No.call(e),r=e;return null!==r&&Zr(r)&&"[object Object]"===i&&(e instanceof t||e instanceof fr||(r=new t(r,this.prefix+n+".")),r.addObserver(this)),r},t}(Gr);function Uo(e){return function(t){return this[e]!==t&&(this[e]=t,this.geometryChange()),this}}function Wo(e){return function(){return this[e]}}var jo=function(e,t){var n=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(e);return function(e,t){for(var n=0;n<t.length;n++){var i=t[n],r=i.charAt(0).toUpperCase()+i.substring(1,i.length);e["set"+r]=Uo(i),e["get"+r]=Wo(i)}}(n.prototype,t),n};function qo(e){return e&&"function"==typeof e.matrix?e.matrix():e}var Go=function(e){function t(t,n){e.call(this),this.x=t||0,this.y=n||0}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={ZERO:{configurable:!0}};return t.prototype.equals=function(e){return e&&e.x===this.x&&e.y===this.y},t.prototype.clone=function(){return new t(this.x,this.y)},t.prototype.rotate=function(e,n){var i=t.create(n)||t.ZERO;return this.transform(Do.rotate(e,i.x,i.y))},t.prototype.translate=function(e,t){return this.x+=e,this.y+=t,this.geometryChange(),this},t.prototype.translateWith=function(e){return this.translate(e.x,e.y)},t.prototype.move=function(e,t){return this.x=this.y=0,this.translate(e,t)},t.prototype.scale=function(e,t){return void 0===t&&(t=e),this.x*=e,this.y*=t,this.geometryChange(),this},t.prototype.scaleCopy=function(e,t){return this.clone().scale(e,t)},t.prototype.transform=function(e){var t=qo(e),n=this.x,i=this.y;return this.x=t.a*n+t.c*i+t.e,this.y=t.b*n+t.d*i+t.f,this.geometryChange(),this},t.prototype.transformCopy=function(e){var t=this.clone();return e&&t.transform(e),t},t.prototype.distanceTo=function(e){var t=this.x-e.x,n=this.y-e.y;return Math.sqrt(t*t+n*n)},t.prototype.round=function(e){return this.x=_o(this.x,e),this.y=_o(this.y,e),this.geometryChange(),this},t.prototype.toArray=function(e){var t=Zr(e);return[t?_o(this.x,e):this.x,t?_o(this.y,e):this.y]},t.prototype.toString=function(e,t){void 0===t&&(t=" ");var n=this.x,i=this.y;return Zr(e)&&(n=_o(n,e),i=_o(i,e)),n+t+i},t.create=function(e,n){if(Zr(e))return e instanceof t?e:1===arguments.length&&2===e.length?new t(e[0],e[1]):new t(e,n)},t.min=function(){for(var e=arguments,n=no,i=no,r=0;r<arguments.length;r++){var o=e[r];n=Math.min(o.x,n),i=Math.min(o.y,i)}return new t(n,i)},t.max=function(){for(var e=arguments,n=io,i=io,r=0;r<arguments.length;r++){var o=e[r];n=Math.max(o.x,n),i=Math.max(o.y,i)}return new t(n,i)},t.minPoint=function(){return new t(io,io)},t.maxPoint=function(){return new t(no,no)},n.ZERO.get=function(){return new t(0,0)},Object.defineProperties(t,n),t}(jo(Gr,["x","y"])),Ko=function(e){function t(t,n){e.call(this),this.width=t||0,this.height=n||0}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={ZERO:{configurable:!0}};return t.prototype.equals=function(e){return e&&e.width===this.width&&e.height===this.height},t.prototype.clone=function(){return new t(this.width,this.height)},t.prototype.toArray=function(e){var t=Zr(e);return[t?_o(this.width,e):this.width,t?_o(this.height,e):this.height]},t.create=function(e,n){if(Zr(e))return e instanceof t?e:1===arguments.length&&2===e.length?new t(e[0],e[1]):new t(e,n)},n.ZERO.get=function(){return new t(0,0)},Object.defineProperties(t,n),t}(jo(Gr,["width","height"])),Yo=function(e){function t(t,n,i){void 0===t&&(t=new Go),void 0===n&&(n=new Ko),void 0===i&&(i=0),e.call(this),this.setOrigin(t),this.setSize(n),this.setCornerRadius(i)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.clone=function(){return new t(this.origin.clone(),this.size.clone())},t.prototype.equals=function(e){return e&&e.origin.equals(this.origin)&&e.size.equals(this.size)},t.prototype.setOrigin=function(e){return this._observerField("origin",Go.create(e)),this.geometryChange(),this},t.prototype.getOrigin=function(){return this.origin},t.prototype.setCornerRadius=function(e){return this.cornerRadius=Array.isArray(e)?e:[e,e],this.geometryChange(),this},t.prototype.getCornerRadius=function(){return this.cornerRadius},t.prototype.setSize=function(e){return this._observerField("size",Ko.create(e)),this.geometryChange(),this},t.prototype.getSize=function(){return this.size},t.prototype.width=function(){return this.size.width},t.prototype.height=function(){return this.size.height},t.prototype.topLeft=function(){return this.origin.clone()},t.prototype.bottomRight=function(){return this.origin.clone().translate(this.width(),this.height())},t.prototype.topRight=function(){return this.origin.clone().translate(this.width(),0)},t.prototype.bottomLeft=function(){return this.origin.clone().translate(0,this.height())},t.prototype.center=function(){return this.origin.clone().translate(this.width()/2,this.height()/2)},t.prototype.bbox=function(e){var n=this.topLeft().transformCopy(e),i=this.topRight().transformCopy(e),r=this.bottomRight().transformCopy(e),o=this.bottomLeft().transformCopy(e);return t.fromPoints(n,i,r,o)},t.prototype.transformCopy=function(e){return t.fromPoints(this.topLeft().transform(e),this.bottomRight().transform(e))},t.prototype.expand=function(e,t){return void 0===t&&(t=e),this.size.width+=2*e,this.size.height+=2*t,this.origin.translate(-e,-t),this},t.prototype.expandCopy=function(e,t){return this.clone().expand(e,t)},t.prototype.containsPoint=function(e){var t=this.origin,n=this.bottomRight();return!(e.x<t.x||e.y<t.y||n.x<e.x||n.y<e.y)},t.prototype._isOnPath=function(e,t){var n=this.expandCopy(t,t),i=this.expandCopy(-t,-t);return n.containsPoint(e)&&!i.containsPoint(e)},t.fromPoints=function(){var e=Go.min.apply(null,arguments),n=Go.max.apply(null,arguments);return new t(e,new Ko(n.x-e.x,n.y-e.y))},t.union=function(e,n){return t.fromPoints(Go.min(e.topLeft(),n.topLeft()),Go.max(e.bottomRight(),n.bottomRight()))},t.intersect=function(e,n){var i={left:e.topLeft().x,top:e.topLeft().y,right:e.bottomRight().x,bottom:e.bottomRight().y},r={left:n.topLeft().x,top:n.topLeft().y,right:n.bottomRight().x,bottom:n.bottomRight().y};if(i.left<=r.right&&r.left<=i.right&&i.top<=r.bottom&&r.top<=i.bottom)return t.fromPoints(new Go(Math.max(i.left,r.left),Math.max(i.top,r.top)),new Go(Math.min(i.right,r.right),Math.min(i.bottom,r.bottom)))},t}(Gr),Qo=function(e){function t(t){void 0===t&&(t=Do.unit()),e.call(this),this._matrix=t}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.clone=function(){return new t(this._matrix.clone())},t.prototype.equals=function(e){return e&&e._matrix.equals(this._matrix)},t.prototype.translate=function(e,t){return this._matrix=this._matrix.multiplyCopy(Do.translate(e,t)),this._optionsChange(),this},t.prototype.scale=function(e,t,n){void 0===t&&(t=e),void 0===n&&(n=null);var i=n;return i&&(i=Go.create(i),this._matrix=this._matrix.multiplyCopy(Do.translate(i.x,i.y))),this._matrix=this._matrix.multiplyCopy(Do.scale(e,t)),i&&(this._matrix=this._matrix.multiplyCopy(Do.translate(-i.x,-i.y))),this._optionsChange(),this},t.prototype.rotate=function(e,t){var n=Go.create(t)||Go.ZERO;return this._matrix=this._matrix.multiplyCopy(Do.rotate(e,n.x,n.y)),this._optionsChange(),this},t.prototype.multiply=function(e){var t=qo(e);return this._matrix=this._matrix.multiplyCopy(t),this._optionsChange(),this},t.prototype.matrix=function(e){return e?(this._matrix=e,this._optionsChange(),this):this._matrix},t.prototype._optionsChange=function(){this.optionsChange({field:"transform",value:this})},t}(Gr);function Xo(e){return null===e?null:e instanceof Qo?e:new Qo(e)}var Zo={dot:[1.5,3.5],dash:[4,3.5],longdash:[8,3.5],dashdot:[3.5,3.5,1.5,3.5],longdashdot:[8,3.5,1.5,3.5],longdashdotdot:[8,3.5,1.5,3.5,1.5,3.5]},Jo="solid",ea="butt",ta="Pattern",na=function(e){function t(t){e.call(this),this._initOptions(t)}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return"Rect"},t.prototype._initOptions=function(e){void 0===e&&(e={});var t=e.clip,n=e.transform;n&&(e.transform=Xo(n)),t&&!t.id&&(t.id=eo()),this.options=new $o(e),this.options.addObserver(this)},t.prototype.transform=function(e){if(!Zr(e))return this.options.get("transform");this.options.set("transform",Xo(e))},t.prototype.parentTransform=function(){for(var e,t=this;t.parent;){var n=(t=t.parent).transform();n&&(e=n.matrix().multiplyCopy(e||Do.unit()))}if(e)return Xo(e)},t.prototype.currentTransform=function(e){void 0===e&&(e=this.parentTransform());var t,n=qo(this.transform()),i=qo(e);if(t=n&&i?i.multiplyCopy(n):n||i)return Xo(t)},t.prototype.visible=function(e){return Zr(e)?(this.options.set("visible",e),this):!1!==this.options.get("visible")},t.prototype.clip=function(e){var t=this.options;return Zr(e)?(e&&!e.id&&(e.id=eo()),t.set("clip",e),this):t.get("clip")},t.prototype.opacity=function(e){return Zr(e)?(this.options.set("opacity",e),this):bo(this.options.get("opacity"),1)},t.prototype.className=function(e){return Zr(e)?(this.options.set("className",e),this):this.options.get("className")},t.prototype.clippedBBox=function(e){var t=this._clippedBBox(e);if(t){var n=this.clip();return n?Yo.intersect(t,n.bbox(e)):t}},t.prototype.containsPoint=function(e,t){if(this.visible()){var n=this.currentTransform(t),i=e;return n&&(i=e.transformCopy(n.matrix().invert())),this._hasFill()&&this._containsPoint(i)||this._isOnPath&&this._hasStroke()&&this._isOnPath(i)}return!1},t.prototype._hasFill=function(){var e=this.options.fill;return e&&(e.nodeType===ta||!ho(e.color))},t.prototype._hasStroke=function(){var e=this.options.stroke;return e&&e.width>0&&!ho(e.color)},t.prototype._clippedBBox=function(e){return this.bbox(e)},Object.defineProperties(t.prototype,n),t}(Gr);function ia(e,t,n,i){var r=0,o=0;return i&&(r=Math.atan2(i.c*n,i.a*t),0!==i.b&&(o=Math.atan2(i.d*n,i.b*t))),{x:r,y:o}}var ra=Math.PI/2,oa=function(e){function t(t,n){void 0===t&&(t=new Go),void 0===n&&(n=0),e.call(this),this.setCenter(t),this.setRadius(n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setCenter=function(e){return this._observerField("center",Go.create(e)),this.geometryChange(),this},t.prototype.getCenter=function(){return this.center},t.prototype.equals=function(e){return e&&e.center.equals(this.center)&&e.radius===this.radius},t.prototype.clone=function(){return new t(this.center.clone(),this.radius)},t.prototype.pointAt=function(e){return this._pointAt(vo(e))},t.prototype.bbox=function(e){for(var t=ia(this.center,this.radius,this.radius,e),n=Go.maxPoint(),i=Go.minPoint(),r=0;r<4;r++){var o=this._pointAt(t.x+r*ra).transformCopy(e),a=this._pointAt(t.y+r*ra).transformCopy(e),s=new Go(o.x,a.y);n=Go.min(n,s),i=Go.max(i,s)}return Yo.fromPoints(n,i)},t.prototype._pointAt=function(e){var t=this.center,n=this.radius;return new Go(t.x+n*Math.cos(e),t.y+n*Math.sin(e))},t.prototype.containsPoint=function(e){var t=this.center,n=this.radius;return Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2)<=Math.pow(n,2)},t.prototype._isOnPath=function(e,t){var n=this.center,i=this.radius,r=n.distanceTo(e);return i-t<=r&&r<=i+t},t}(jo(Gr,["radius"])),aa=function(e){return function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.fill=function(e,t){var n=this.options;if(Zr(e)){if(e&&"Gradient"!==e.nodeType){var i={color:e};Zr(t)&&(i.opacity=t),n.set("fill",i)}else n.set("fill",e);return this}return n.get("fill")},t.prototype.stroke=function(e,t,n){return Zr(e)?(this.options.set("stroke.color",e),Zr(t)&&this.options.set("stroke.width",t),Zr(n)&&this.options.set("stroke.opacity",n),this):this.options.get("stroke")},t}(e)},sa=Do.IDENTITY.toString(),la=function(e){return function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.bbox=function(e){var t,n=qo(this.currentTransform(e)),i=n?n.toString():sa;this._bboxCache&&this._matrixHash===i?t=this._bboxCache.clone():(t=this._bbox(n),this._bboxCache=t?t.clone():null,this._matrixHash=i);var r=this.options.get("stroke.width");return r&&t&&t.expand(r/2),t},t.prototype.geometryChange=function(){delete this._bboxCache,this.trigger("geometryChange",{element:this})},t}(e)};function ca(e){var t="_"+e;return function(e){return Zr(e)?(this._observerField(t,e),this.geometryChange(),this):this[t]}}var da=function(e,t){void 0===t&&(t=["geometry"]);var n=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(e);return function(e,t){for(var n=0;n<t.length;n++)e[t[n]]=ca(t[n])}(n.prototype,t),n},ua=function(e){function t(t,n){void 0===t&&(t=new oa),void 0===n&&(n={}),e.call(this,n),this.geometry(t),Zr(this.options.stroke)||this.stroke("#000")}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return"Circle"},t.prototype.rawBBox=function(){return this._geometry.bbox()},t.prototype._bbox=function(e){return this._geometry.bbox(e)},t.prototype._containsPoint=function(e){return this.geometry().containsPoint(e)},t.prototype._isOnPath=function(e){return this.geometry()._isOnPath(e,this.options.stroke.width/2)},Object.defineProperties(t.prototype,n),t}(aa(la(da(na)))),ha=10;function pa(e,t,n){return void 0===n&&(n=ha),0===_o(Math.abs(e-t),n)}function fa(e,t,n){return e<t||pa(e,t,n)}var ma=Math.pow,ga=function(e){function t(t,n){void 0===t&&(t=new Go),void 0===n&&(n={}),e.call(this),this.setCenter(t),this.radiusX=n.radiusX,this.radiusY=n.radiusY||n.radiusX,this.startAngle=n.startAngle,this.endAngle=n.endAngle,this.anticlockwise=n.anticlockwise||!1,this.xRotation=n.xRotation}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.clone=function(){return new t(this.center,{radiusX:this.radiusX,radiusY:this.radiusY,startAngle:this.startAngle,endAngle:this.endAngle,anticlockwise:this.anticlockwise})},t.prototype.setCenter=function(e){return this._observerField("center",Go.create(e)),this.geometryChange(),this},t.prototype.getCenter=function(){return this.center},t.prototype.pointAt=function(e){var t=this.center,n=vo(e);return new Go(t.x+this.radiusX*Math.cos(n),t.y+this.radiusY*Math.sin(n))},t.prototype.curvePoints=function(){var e,t=this.startAngle,n=this.anticlockwise?-1:1,i=[this.pointAt(t)],r=this._arcInterval(),o=r.endAngle-r.startAngle,a=Math.ceil(o/45),s=o/a,l=t;this.xRotation&&(e=Xo().rotate(this.xRotation,this.center));for(var c=1;c<=a;c++){var d=l+n*s,u=this._intervalCurvePoints(l,d,e);i.push(u.cp1,u.cp2,u.p2),l=d}return i},t.prototype.bbox=function(e){for(var t=this._arcInterval(),n=t.startAngle,i=t.endAngle,r=ia(this.center,this.radiusX,this.radiusY,e),o=ro(r.x),a=ro(r.y),s=this.pointAt(i).transformCopy(e),l=_a(o,n),c=_a(a,n),d=this.pointAt(n).transformCopy(e),u=Go.min(d,s),h=Go.max(d,s);l<i||c<i;){var p=void 0;l<i&&(p=this.pointAt(l).transformCopy(e),l+=90);var f=void 0;c<i&&(f=this.pointAt(c).transformCopy(e),c+=90),d=new Go(p.x,f.y),u=Go.min(u,d),h=Go.max(h,d)}return Yo.fromPoints(u,h)},t.prototype._arcInterval=function(){var e=this,t=e.startAngle,n=e.endAngle,i=e.anticlockwise;if(i){var r=t;t=n,n=r}return(t>n||i&&t===n)&&(n+=360),{startAngle:t,endAngle:n}},t.prototype._intervalCurvePoints=function(e,t,n){var i=this.pointAt(e),r=this.pointAt(t),o=this._derivativeAt(e),a=this._derivativeAt(t),s=(vo(t)-vo(e))/3,l=new Go(i.x+s*o.x,i.y+s*o.y),c=new Go(r.x-s*a.x,r.y-s*a.y);return n&&(i.transform(n),r.transform(n),l.transform(n),c.transform(n)),{p1:i,cp1:l,cp2:c,p2:r}},t.prototype._derivativeAt=function(e){var t=vo(e);return new Go(-this.radiusX*Math.sin(t),this.radiusY*Math.cos(t))},t.prototype.containsPoint=function(e){var t,n=this._arcInterval(),i=n.endAngle-n.startAngle,r=this,o=r.center,a=r.radiusX,s=r.radiusY,l=o.distanceTo(e),c=Math.atan2(e.y-o.y,e.x-o.x),d=a*s/Math.sqrt(ma(a,2)*ma(Math.sin(c),2)+ma(s,2)*ma(Math.cos(c),2)),u=this.pointAt(this.startAngle).round(ha),h=this.pointAt(this.endAngle).round(ha),p=function(e,t,n,i){var r=t.x-e.x,o=i.x-n.x,a=t.y-e.y,s=i.y-n.y,l=e.x-n.x,c=e.y-n.y,d=r*s-o*a,u=(r*c-a*l)/d,h=(o*c-s*l)/d;if(u>=0&&u<=1&&h>=0&&h<=1)return new Go(e.x+h*r,e.y+h*a)}(o,e.round(ha),u,h);if(i<180)t=p&&fa(o.distanceTo(p),l)&&fa(l,d);else{var f=va(o.x,o.y,a,s,e.x,e.y);360!==f&&(f=(360+f)%360);var m=n.startAngle<=f&&f<=n.endAngle;t=m&&fa(l,d)||!m&&(!p||p.equals(e))}return t},t.prototype._isOnPath=function(e,t){var n=this._arcInterval(),i=this.center,r=va(i.x,i.y,this.radiusX,this.radiusY,e.x,e.y);return 360!==r&&(r=(360+r)%360),n.startAngle<=r&&r<=n.endAngle&&this.pointAt(r).distanceTo(e)<=t},t.fromPoints=function(e,n,i,r,o,a,s){var l=function(e){var t=e.x1,n=e.y1,i=e.x2,r=e.y2,o=e.rx,a=e.ry,s=e.largeArc,l=e.swipe,c=e.rotation;void 0===c&&(c=0);var d=vo(c),u=Math.cos(d),h=Math.sin(d),p=u*(t-i)/2+h*(n-r)/2,f=-h*(t-i)/2+u*(n-r)/2,m=s!==l?1:-1,g=Math.pow(p,2),v=Math.pow(f,2),_=Math.pow(o,2),b=Math.pow(a,2),y=g/_+v/b;y>1&&(o*=y=Math.sqrt(g/_+v/b),_=Math.pow(o,2),a*=y,b=Math.pow(a,2));var w=m*Math.sqrt((_*b-_*v-b*g)/(_*v+b*g));isNaN(w)&&(w=0);var k=w*(o*f)/a,x=a*p*-w/o,C=u*k-h*x+(t+i)/2,S=h*k+u*x+(n+r)/2,T=(p-k)/o,D=(f-x)/a,A=-(p+k)/o,M=-(f+x)/a,E=(D>=0?1:-1)*ro(Math.acos(T/Math.sqrt(T*T+D*D))),I=_o((T*A+D*M)/(Math.sqrt(T*T+D*D)*Math.sqrt(A*A+M*M)),10),z=(T*M-D*A>=0?1:-1)*ro(Math.acos(I));!l&&z>0&&(z-=360);l&&z<0&&(z+=360);var P=E+z,H=P>=0?1:-1;return P=Math.abs(P)%360*H,{center:new Go(C,S),startAngle:E,endAngle:P,radiusX:o,radiusY:a,xRotation:c}}({x1:e.x,y1:e.y,x2:n.x,y2:n.y,rx:i,ry:r,largeArc:o,swipe:a,rotation:s});return new t(l.center,{startAngle:l.startAngle,endAngle:l.endAngle,radiusX:l.radiusX,radiusY:l.radiusY,xRotation:l.xRotation,anticlockwise:0===a})},t}(jo(Gr,["radiusX","radiusY","startAngle","endAngle","anticlockwise"]));function va(e,t,n,i,r,o){var a=_o((r-e)/n,3),s=_o((o-t)/i,3);return _o(ro(Math.atan2(s,a)))}function _a(e,t){for(var n=e;n<t;)n+=90;return n}var ba=[].push,ya=[].pop,wa=[].splice,ka=[].shift,xa=[].slice,Ca=[].unshift,Sa=function(e){function t(t){void 0===t&&(t=[]),e.call(this),this.length=0,this._splice(0,t.length,t)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.elements=function(e){return e?(this._splice(0,this.length,e),this._change(),this):this.slice(0)},t.prototype.push=function(){var e=arguments,t=ba.apply(this,e);return this._add(e),t},t.prototype.slice=function(){return xa.call(this)},t.prototype.pop=function(){var e=this.length,t=ya.apply(this);return e&&this._remove([t]),t},t.prototype.splice=function(e,t){var n=xa.call(arguments,2),i=this._splice(e,t,n);return this._change(),i},t.prototype.shift=function(){var e=this.length,t=ka.apply(this);return e&&this._remove([t]),t},t.prototype.unshift=function(){var e=arguments,t=Ca.apply(this,e);return this._add(e),t},t.prototype.indexOf=function(e){for(var t=this.length,n=0;n<t;n++)if(this[n]===e)return n;return-1},t.prototype._splice=function(e,t,n){var i=wa.apply(this,[e,t].concat(n));return this._clearObserver(i),this._setObserver(n),i},t.prototype._add=function(e){this._setObserver(e),this._change()},t.prototype._remove=function(e){this._clearObserver(e),this._change()},t.prototype._setObserver=function(e){for(var t=0;t<e.length;t++)e[t].addObserver(this)},t.prototype._clearObserver=function(e){for(var t=0;t<e.length;t++)e[t].removeObserver(this)},t.prototype._change=function(){},t}(Gr),Ta=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._change=function(){this.geometryChange()},t}(Sa);function Da(e,t,n){var i=ro(Math.atan2(t.y-e.y,t.x-e.x));return n.transformCopy(Xo().rotate(-i,e)).x<e.x}function Aa(e,t,n){var i=1-e;return Math.pow(i,3)*n[0][t]+3*Math.pow(i,2)*e*n[1][t]+3*Math.pow(e,2)*i*n[2][t]+Math.pow(e,3)*n[3][t]}function Ma(e,t){return[-e[0][t]+3*e[1][t]-3*e[2][t]+e[3][t],3*(e[0][t]-2*e[1][t]+e[2][t]),3*(-e[0][t]+e[1][t]),e[0][t]]}var Ea=function(e){function t(t,n){void 0===t&&(t=0),void 0===n&&(n=0),e.call(this),this.real=t,this.img=n}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.add=function(e){return new t(_o(this.real+e.real,ha),_o(this.img+e.img,ha))},t.prototype.addConstant=function(e){return new t(this.real+e,this.img)},t.prototype.negate=function(){return new t(-this.real,-this.img)},t.prototype.multiply=function(e){return new t(this.real*e.real-this.img*e.img,this.real*e.img+this.img*e.real)},t.prototype.multiplyConstant=function(e){return new t(this.real*e,this.img*e)},t.prototype.nthRoot=function(e){var n=Math.atan2(this.img,this.real),i=Math.sqrt(Math.pow(this.img,2)+Math.pow(this.real,2)),r=Math.pow(i,1/e);return new t(r*Math.cos(n/e),r*Math.sin(n/e))},t.prototype.equals=function(e){return this.real===e.real&&this.img===e.img},t.prototype.isReal=function(){return 0===this.img},t}(fr);function Ia(e){return e<0?-1:1}function za(e,t,n,i){if(0===e)return function(e,t,n){var i=Math.sqrt(Math.pow(t,2)-4*e*n);return[(-t+i)/(2*e),(-t-i)/(2*e)]}(t,n,i);var r,o,a,s,l,c,d,u=(3*e*n-Math.pow(t,2))/(3*Math.pow(e,2)),h=(2*Math.pow(t,3)-9*e*t*n+27*Math.pow(e,2)*i)/(27*Math.pow(e,3)),p=Math.pow(u/3,3)+Math.pow(h/2,2),f=new Ea(0,1),m=-t/(3*e);p<0?(r=new Ea(-h/2,Math.sqrt(-p)).nthRoot(3),o=new Ea(-h/2,-Math.sqrt(-p)).nthRoot(3)):(r=-h/2+Math.sqrt(p),r=new Ea(Ia(r)*Math.pow(Math.abs(r),1/3)),o=-h/2-Math.sqrt(p),o=new Ea(Ia(o)*Math.pow(Math.abs(o),1/3))),a=r.add(o),c=r.add(o).multiplyConstant(-.5),d=r.add(o.negate()).multiplyConstant(Math.sqrt(3)/2),s=c.add(f.multiply(d)),l=c.add(f.negate().multiply(d));var g=[];return a.isReal()&&g.push(_o(a.real+m,ha)),s.isReal()&&g.push(_o(s.real+m,ha)),l.isReal()&&g.push(_o(l.real+m,ha)),g}function Pa(e,t,n,i,r){for(var o,a=Ma(e,i),s=za(a[0],a[1],a[2],a[3]-t[i]),l=0;l<s.length;l++)if(0<=s[l]&&s[l]<=1&&(o=Aa(s[l],n,e),Math.abs(o-t[n])<=r))return!0}function Ha(e,t,n){var i;if(e.x!==t.x){var r=Math.min(e.x,t.x),o=Math.max(e.x,t.x),a=Math.min(e.y,t.y),s=Math.max(e.y,t.y),l=r<=n.x&&n.x<o;i=a===s?n.y<=a&&l:l&&(s-a)*((e.x-t.x)*(e.y-t.y)>0?n.x-r:o-n.x)/(o-r)+a-n.y>=0}return i?1:0}function Fa(e){var t="_"+e;return function(e){return Zr(e)?(this._observerField(t,Go.create(e)),this.geometryChange(),this):this[t]}}var Ra=function(e,t){var n=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(e);return function(e,t){for(var n=0;n<t.length;n++)e[t[n]]=Fa(t[n])}(n.prototype,t),n},La=function(e){function t(t,n,i){e.call(this),this.anchor(t||new Go),this.controlIn(n),this.controlOut(i)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.bboxTo=function(e,t){var n=this.anchor().transformCopy(t),i=e.anchor().transformCopy(t);return this.controlOut()&&e.controlIn()?this._curveBoundingBox(n,this.controlOut().transformCopy(t),e.controlIn().transformCopy(t),i):this._lineBoundingBox(n,i)},t.prototype._lineBoundingBox=function(e,t){return Yo.fromPoints(e,t)},t.prototype._curveBoundingBox=function(e,t,n,i){var r=[e,t,n,i],o=this._curveExtremesFor(r,"x"),a=this._curveExtremesFor(r,"y"),s=Ba([o.min,o.max,e.x,i.x]),l=Ba([a.min,a.max,e.y,i.y]);return Yo.fromPoints(new Go(s.min,l.min),new Go(s.max,l.max))},t.prototype._curveExtremesFor=function(e,t){var n=this._curveExtremes(e[0][t],e[1][t],e[2][t],e[3][t]);return{min:Aa(n.min,t,e),max:Aa(n.max,t,e)}},t.prototype._curveExtremes=function(e,t,n,i){var r=e-3*t+3*n-i,o=-2*(e-2*t+n),a=e-t,s=Math.sqrt(o*o-4*r*a),l=0,c=1;0===r?0!==o&&(l=c=-a/o):isNaN(s)||(l=(-o+s)/(2*r),c=(-o-s)/(2*r));var d=Math.max(Math.min(l,c),0);(d<0||d>1)&&(d=0);var u=Math.min(Math.max(l,c),1);return(u>1||u<0)&&(u=1),{min:d,max:u}},t.prototype._intersectionsTo=function(e,t){var n;return n=this.controlOut()&&e.controlIn()?function(e,t,n){for(var i,r=Ma(e,"x"),o=za(r[0],r[1],r[2],r[3]-t.x),a=0,s=0;s<o.length;s++)(pa(i=Aa(o[s],"y",e),t.y)||i>t.y)&&((0===o[s]||1===o[s])&&n.bottomRight().x>t.x||0<o[s]&&o[s]<1)&&a++;return a}([this.anchor(),this.controlOut(),e.controlIn(),e.anchor()],t,this.bboxTo(e)):Ha(this.anchor(),e.anchor(),t),n},t.prototype._isOnCurveTo=function(e,t,n,i){if(this.bboxTo(e).expand(n,n).containsPoint(t)){var r=this.anchor(),o=this.controlOut(),a=e.controlIn(),s=e.anchor();if("start"===i&&r.distanceTo(t)<=n)return!Da(r,o,t);if("end"===i&&s.distanceTo(t)<=n)return!Da(s,a,t);var l=[r,o,a,s];if(Pa(l,t,"x","y",n)||Pa(l,t,"y","x",n))return!0;var c=Xo().rotate(45,t),d=[r.transformCopy(c),o.transformCopy(c),a.transformCopy(c),s.transformCopy(c)];return Pa(d,t,"x","y",n)||Pa(d,t,"y","x",n)}},t.prototype._isOnLineTo=function(e,t,n){var i=this.anchor(),r=e.anchor(),o=ro(Math.atan2(r.y-i.y,r.x-i.x));return new Yo([i.x,i.y-n/2],[i.distanceTo(r),n]).containsPoint(t.transformCopy(Xo().rotate(-o,i)))},t.prototype._isOnPathTo=function(e,t,n,i){return this.controlOut()&&e.controlIn()?this._isOnCurveTo(e,t,n/2,i):this._isOnLineTo(e,t,n)},t}(Ra(Gr,["anchor","controlIn","controlOut"]));function Ba(e){for(var t=e.length,n=no,i=io,r=0;r<t;r++)i=Math.max(i,e[r]),n=Math.min(n,e[r]);return{min:n,max:i}}var Oa=Object.freeze({__proto__:null,Arc:ga,Circle:oa,Matrix:Do,Point:Go,Rect:Yo,Segment:La,Size:Ko,Transformation:Qo,toMatrix:qo,transform:Xo}),Va="x",Na="y";function $a(e,t){var n=e.slice(0),i=[],r=n.length;if(r>2&&(Ua(0,n),r=n.length),r<2||2===r&&n[0].equals(n[1]))return i;var o,a,s=n[0],l=n[1],c=n[2];for(i.push(new La(s));s.equals(n[r-1]);)t=!0,n.pop(),r--;if(2===r){var d=Ga(s,l,Va,Na);return po(i).controlOut(Ya(d,s,l,Va,Na)),i.push(new La(l,Qa(d,s,l,Va,Na))),i}if(t){var u=ja(s=n[r-1],l=n[0],c=n[1]);o=u[1],a=u[0]}else{o=Ya(Ga(s,l,Va,Na),s,l,Va,Na)}for(var h=o,p=0;p<=r-3;p++)if(Ua(p,n),p+3<=(r=n.length)){var f=ja(s=n[p],l=n[p+1],c=n[p+2]);po(i).controlOut(h),h=f[1];var m=f[0];i.push(new La(l,m))}if(t){var g=ja(s=n[r-2],l=n[r-1],c=n[0]);po(i).controlOut(h),i.push(new La(l,g[0])),po(i).controlOut(g[1]),i.push(new La(c,a))}else{var v=Ga(l,c,Va,Na);po(i).controlOut(h),i.push(new La(c,Qa(v,l,c,Va,Na)))}return i}function Ua(e,t){for(;t[e+1]&&(t[e].equals(t[e+1])||t[e+1].equals(t[e+2]));)t.splice(e+1,1)}function Wa(e,t){var n=(t.y-e.y)/(t.x-e.x);return[e.y-n*e.x,n]}function ja(e,t,n){var i,r=Va,o=Na,a=!1,s=!1;if(function(e,t,n){var i=Za(Wa(e,t),n.x);return e.x===t.x&&t.x===n.x||_o(i,1)===_o(n.y,1)}(e,t,n))i=Ga(e,t,Va,Na);else{var l={x:Ka(e,t,n,Va),y:Ka(e,t,n,Na)};if(l.x&&l.y)i=Ga(e,n,Va,Na),a=!0;else if(function(e,t,n){var i=!1;if(e.x===t.x)i=!0;else if(t.x===n.x)(t.y<n.y&&e.y<=t.y||n.y<t.y&&t.y<=e.y)&&(i=!0);else{var r=Za(Wa(e,t),n.x);e.y<=t.y&&n.y<=r||t.y<=e.y&&n.y>=r||(i=!0)}return i}(e,t,n)&&(r=Na,o=Va),l[r])i=0;else i=.01*(n[o]<e[o]&&e[o]<=t[o]||e[o]<n[o]&&t[o]<=e[o]?Ja((n[o]-e[o])*(t[r]-e[r])):-Ja((n[r]-e[r])*(t[o]-e[o]))),s=!0}var c=Qa(i,e,t,r,o);if(s){var d=r;r=o,o=d}var u=Ya(i,t,n,r,o);return a&&(qa(e,t,c,i),qa(t,n,u,i)),[c,u]}function qa(e,t,n,i){e.y<t.y?t.y<n.y?(n.x=e.x+(t.y-e.y)/i,n.y=t.y):n.y<e.y&&(n.x=t.x-(t.y-e.y)/i,n.y=e.y):n.y<t.y?(n.x=e.x-(e.y-t.y)/i,n.y=t.y):e.y<n.y&&(n.x=t.x+(e.y-t.y)/i,n.y=e.y)}function Ga(e,t,n,i){var r=t[n]-e[n],o=t[i]-e[i];return 0===r?0:o/r}function Ka(e,t,n,i){return n[i]>t[i]&&t[i]>e[i]||n[i]<t[i]&&t[i]<e[i]}function Ya(e,t,n,i,r){var o=t[i],a=.333*(n[i]-o);return Xa(o+a,t[r]+a*e,i,r)}function Qa(e,t,n,i,r){var o=t[i],a=n[i],s=.333*(a-o);return Xa(a-s,n[r]-s*e,i,r)}function Xa(e,t,n,i){var r=new Go;return r[n]=e,r[i]=t,r}function Za(e,t){for(var n=e.length,i=0,r=0;r<n;r++)i+=Math.pow(t,r)*e[r];return i}function Ja(e){return e<=0?-1:1}var es={l:function(e,t){for(var n=t.parameters,i=t.position,r=0;r<n.length;r+=2){var o=new Go(n[r],n[r+1]);t.isRelative&&o.translateWith(i),e.lineTo(o.x,o.y),i.x=o.x,i.y=o.y}},c:function(e,t){for(var n=t.parameters,i=t.position,r=0;r<n.length;r+=6){var o=new Go(n[r],n[r+1]),a=new Go(n[r+2],n[r+3]),s=new Go(n[r+4],n[r+5]);t.isRelative&&(a.translateWith(i),o.translateWith(i),s.translateWith(i)),e.curveTo(o,a,s),i.x=s.x,i.y=s.y}},v:function(e,t){var n=t.isRelative?0:t.position.x;ts(t.parameters,!0,n),this.l(e,t)},h:function(e,t){var n=t.isRelative?0:t.position.y;ts(t.parameters,!1,n),this.l(e,t)},a:function(e,t){for(var n=t.parameters,i=t.position,r=0;r<n.length;r+=7){var o=n[r],a=n[r+1],s=n[r+2],l=n[r+3],c=n[r+4],d=new Go(n[r+5],n[r+6]);t.isRelative&&d.translateWith(i),i.x===d.x&&i.y===d.y||(e.arcTo(d,o,a,l,c,s),i.x=d.x,i.y=d.y)}},s:function(e,t){var n,i=t.parameters,r=t.position,o=t.previousCommand;"s"!==o&&"c"!==o||(n=po(po(e.paths).segments).controlIn());for(var a=0;a<i.length;a+=4){var s=new Go(i[a],i[a+1]),l=new Go(i[a+2],i[a+3]),c=void 0;t.isRelative&&(s.translateWith(r),l.translateWith(r)),c=n?ns(n,r):r.clone(),n=s,e.curveTo(c,s,l),r.x=l.x,r.y=l.y}},q:function(e,t){for(var n=t.parameters,i=t.position,r=0;r<n.length;r+=4){var o=new Go(n[r],n[r+1]),a=new Go(n[r+2],n[r+3]);t.isRelative&&(o.translateWith(i),a.translateWith(i));var s=rs(i,o,a);e.curveTo(s.controlOut,s.controlIn,a),i.x=a.x,i.y=a.y}},t:function(e,t){var n,i=t.parameters,r=t.position,o=t.previousCommand;"q"!==o&&"t"!==o||(n=po(po(e.paths).segments).controlIn().clone().translateWith(r.scaleCopy(-1/3)).scale(1.5));for(var a=0;a<i.length;a+=2){var s=new Go(i[a],i[a+1]);t.isRelative&&s.translateWith(r),n=n?ns(n,r):r.clone();var l=rs(r,n,s);e.curveTo(l.controlOut,l.controlIn,s),r.x=s.x,r.y=s.y}}};function ts(e,t,n){for(var i=t?0:1,r=0;r<e.length;r+=2)e.splice(r+i,0,n)}function ns(e,t){if(e&&t)return t.scaleCopy(2).translate(-e.x,-e.y)}var is=1/3;function rs(e,t,n){var i=t.clone().scale(2/3);return{controlOut:i.clone().translateWith(e.scaleCopy(is)),controlIn:i.translateWith(n.scaleCopy(is))}}var os=/([a-df-z]{1})([^a-df-z]*)(z)?/gi,as=/[,\s]?([+\-]?(?:\d*\.\d+|\d+)(?:[eE][+\-]?\d+)?)/g;function ss(e,t){var n,i=new Go;return t.replace(os,(function(t,r,o,a){var s=r.toLowerCase(),l=s===r,c=function(e){var t=[];return e.replace(as,(function(e,n){t.push(parseFloat(n))})),t}(o.trim());if("m"===s&&(l?(i.x+=c[0],i.y+=c[1]):(i.x=c[0],i.y=c[1]),e.moveTo(i.x,i.y),c.length>2&&(s="l",c.splice(0,2))),es[s])es[s](e,{parameters:c,position:i,isRelative:l,previousCommand:n}),a&&"z"===a.toLowerCase()&&e.close();else if("m"!==s)throw new Error("Error while parsing SVG path. Unsupported command: "+s);n=s})),e}function ls(e,t,n){for(var i,r=0;r<e.length;r++){var o=e[r];if(o.visible()){var a=t?o.bbox(n):o.rawBBox();a&&(i=i?Yo.union(i,a):a)}}return i}function cs(e,t){for(var n,i=0;i<e.length;i++){var r=e[i];if(r.visible()){var o=r.clippedBBox(t);o&&(n=n?Yo.union(n,o):o)}}return n}var ds=" ",us=function(e){function t(t){e.call(this,t),this.segments=new Ta,this.segments.addObserver(this),Zr(this.options.stroke)||(this.stroke("#000"),Zr(this.options.stroke.lineJoin)||this.options.set("stroke.lineJoin","miter"))}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return"Path"},t.prototype.moveTo=function(e,t){return this.suspend(),this.segments.elements([]),this.resume(),this.lineTo(e,t),this},t.prototype.lineTo=function(e,t){var n=Zr(t)?new Go(e,t):e,i=new La(n);return this.segments.push(i),this},t.prototype.curveTo=function(e,t,n){if(this.segments.length>0){var i=po(this.segments),r=new La(n,t);this.suspend(),i.controlOut(e),this.resume(),this.segments.push(r)}return this},t.prototype.arc=function(e,t,n,i,r){if(this.segments.length>0){var o=po(this.segments).anchor(),a=vo(e),s=new Go(o.x-n*Math.cos(a),o.y-i*Math.sin(a)),l=new ga(s,{startAngle:e,endAngle:t,radiusX:n,radiusY:i,anticlockwise:r});this._addArcSegments(l)}return this},t.prototype.arcTo=function(e,t,n,i,r,o){if(this.segments.length>0){var a=po(this.segments).anchor(),s=ga.fromPoints(a,Go.create(e),t,n,i,r,o);this._addArcSegments(s)}return this},t.prototype._addArcSegments=function(e){this.suspend();for(var t=e.curvePoints(),n=1;n<t.length;n+=3)this.curveTo(t[n],t[n+1],t[n+2]);this.resume(),this.geometryChange()},t.prototype.close=function(){return this.options.closed=!0,this.geometryChange(),this},t.prototype.rawBBox=function(){return this._bbox()},t.prototype.toString=function(e){var t,n,i,r="",o=this.segments,a=o.length;if(a>0){for(var s,l=[],c=(i=e,function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];return e.map((function(e){return e.toString(i)})).join(ds)}),d=1;d<a;d++){var u=(t=o[d-1],n=o[d],t.controlOut()&&n.controlIn()?"C":"L");u!==s&&(s=u,l.push(u)),"L"===u?l.push(c(o[d].anchor())):l.push(c(o[d-1].controlOut(),o[d].controlIn(),o[d].anchor()))}r="M"+c(o[0].anchor())+ds+l.join(ds),this.options.closed&&(r+="Z")}return r},t.prototype._containsPoint=function(e){for(var t,n,i=this.segments,r=i.length,o=0,a=1;a<r;a++)t=i[a-1],n=i[a],o+=t._intersectionsTo(n,e);return!this.options.closed&&i[0].anchor().equals(i[r-1].anchor())||(o+=Ha(i[0].anchor(),i[r-1].anchor(),e)),o%2!=0},t.prototype._isOnPath=function(e,t){var n=this.segments,i=n.length,r=t||this.options.stroke.width;if(i>1){if(n[0]._isOnPathTo(n[1],e,r,"start"))return!0;for(var o=2;o<=i-2;o++)if(n[o-1]._isOnPathTo(n[o],e,r))return!0;if(n[i-2]._isOnPathTo(n[i-1],e,r,"end"))return!0}return!1},t.prototype._bbox=function(e){var t,n=this.segments,i=n.length;if(1===i){var r=n[0].anchor().transformCopy(e);t=new Yo(r,Ko.ZERO)}else if(i>0)for(var o=1;o<i;o++){var a=n[o-1].bboxTo(n[o],e);t=t?Yo.union(t,a):a}return t},t.parse=function(e,t){return hs.parse(e,t)},t.fromRect=function(e,n){var i=new t(n),r=e.cornerRadius,o=r[0],a=r[1];if(0===o&&0===a)i.moveTo(e.topLeft()).lineTo(e.topRight()).lineTo(e.bottomRight()).lineTo(e.bottomLeft()).close();else{var s=e.origin,l=s.x,c=s.y,d=e.width(),u=e.height();o=fo(o,0,d/2),a=fo(a,0,u/2),i.moveTo(l+o,c).lineTo(l+d-o,c).arcTo([l+d,c+a],o,a,!1).lineTo(l+d,c+u-a).arcTo([l+d-o,c+u],o,a,!1).lineTo(l+o,c+u).arcTo([l,c+u-a],o,a,!1).lineTo(l,c+a).arcTo([l+o,c],o,a,!1)}return i},t.fromPoints=function(e,n){if(e){for(var i=new t(n),r=0;r<e.length;r++){var o=Go.create(e[r]);o&&(0===r?i.moveTo(o):i.lineTo(o))}return i}},t.curveFromPoints=function(e,n){if(e){var i=$a(e),r=new t(n);return r.segments.push.apply(r.segments,i),r}},t.fromArc=function(e,n){var i=new t(n),r=e.startAngle,o=e.pointAt(r);return i.moveTo(o.x,o.y),i.arc(r,e.endAngle,e.radiusX,e.radiusY,e.anticlockwise),i},Object.defineProperties(t.prototype,n),t}(aa(la(na))),hs=function(e){function t(t){e.call(this,t),this.paths=new Ta,this.paths.addObserver(this),Zr(this.options.stroke)||this.stroke("#000")}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={nodeType:{configurable:!0}};return t.parse=function(e,n){return ss(new t(n),e)},t.prototype.toString=function(e){var t=this.paths,n="";if(t.length>0){for(var i=[],r=0;r<t.length;r++)i.push(t[r].toString(e));n=i.join(ds)}return n},n.nodeType.get=function(){return"MultiPath"},t.prototype.moveTo=function(e,t){var n=new us;return n.moveTo(e,t),this.paths.push(n),this},t.prototype.lineTo=function(e,t){return this.paths.length>0&&po(this.paths).lineTo(e,t),this},t.prototype.curveTo=function(e,t,n){return this.paths.length>0&&po(this.paths).curveTo(e,t,n),this},t.prototype.arc=function(e,t,n,i,r){return this.paths.length>0&&po(this.paths).arc(e,t,n,i,r),this},t.prototype.arcTo=function(e,t,n,i,r,o){return this.paths.length>0&&po(this.paths).arcTo(e,t,n,i,r,o),this},t.prototype.close=function(){return this.paths.length>0&&po(this.paths).close(),this},t.prototype._bbox=function(e){return ls(this.paths,!0,e)},t.prototype.rawBBox=function(){return ls(this.paths,!1)},t.prototype._containsPoint=function(e){for(var t=this.paths,n=0;n<t.length;n++)if(t[n]._containsPoint(e))return!0;return!1},t.prototype._isOnPath=function(e){for(var t=this.paths,n=this.options.stroke.width,i=0;i<t.length;i++)if(t[i]._isOnPath(e,n))return!0;return!1},t.prototype._clippedBBox=function(e){return cs(this.paths,this.currentTransform(e))},Object.defineProperties(t.prototype,n),t}(aa(la(na))),ps=function(e){function t(t,n){void 0===t&&(t=new ga),void 0===n&&(n={}),e.call(this,n),this.geometry(t),Zr(this.options.stroke)||this.stroke("#000")}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return"Arc"},t.prototype._bbox=function(e){return this._geometry.bbox(e)},t.prototype.rawBBox=function(){return this.geometry().bbox()},t.prototype.toPath=function(){var e=new us,t=this.geometry().curvePoints();if(t.length>0){e.moveTo(t[0].x,t[0].y);for(var n=1;n<t.length;n+=3)e.curveTo(t[n],t[n+1],t[n+2])}return e},t.prototype._containsPoint=function(e){return this.geometry().containsPoint(e)},t.prototype._isOnPath=function(e){return this.geometry()._isOnPath(e,this.options.stroke.width/2)},Object.defineProperties(t.prototype,n),t}(aa(la(da(na)))),fs=function(e){function t(t,n,i){void 0===n&&(n=new Go),void 0===i&&(i={}),e.call(this,i),this.content(t),this.position(n),this.options.font||(this.options.font="12px sans-serif"),Zr(this.options.fill)||this.fill("#000")}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return"Text"},t.prototype.content=function(e){return Zr(e)?(this.options.set("content",e),this):this.options.get("content")},t.prototype.measure=function(){return Oo(this.content(),{font:this.options.get("font")})},t.prototype.rect=function(){var e=this.measure(),t=this.position().clone();return new Yo(t,[e.width,e.height])},t.prototype.bbox=function(e){var t=qo(this.currentTransform(e));return this.rect().bbox(t)},t.prototype.rawBBox=function(){return this.rect().bbox()},t.prototype._containsPoint=function(e){return this.rect().containsPoint(e)},Object.defineProperties(t.prototype,n),t}(aa(Ra(na,["position"]))),ms=function(e){function t(t,n,i){void 0===n&&(n=new Yo),void 0===i&&(i={}),e.call(this,i),this.src(t),this.rect(n)}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return"Image"},t.prototype.src=function(e){return Zr(e)?(this.options.set("src",e),this):this.options.get("src")},t.prototype.bbox=function(e){var t=qo(this.currentTransform(e));return this._rect.bbox(t)},t.prototype.rawBBox=function(){return this._rect.bbox()},t.prototype._containsPoint=function(e){return this._rect.containsPoint(e)},t.prototype._hasFill=function(){return this.src()},Object.defineProperties(t.prototype,n),t}(da(na,["rect"])),gs=function(e,t){return function(e){function n(){e.apply(this,arguments)}return e&&(n.__proto__=e),n.prototype=Object.create(e&&e.prototype),n.prototype.constructor=n,n.prototype.traverse=function(e){for(var n=this[t],i=0;i<n.length;i++){var r=n[i];r.traverse?r.traverse(e):e(r)}return this},n}(e)},vs=function(e){function t(t){e.call(this,t),this.children=[]}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return"Group"},t.prototype.childrenChange=function(e,t,n){this.trigger("childrenChange",{action:e,items:t,index:n})},t.prototype.append=function(){return Kr(this.children,arguments),this._reparent(arguments,this),this.childrenChange("add",arguments),this},t.prototype.insert=function(e,t){return this.children.splice(e,0,t),t.parent=this,this.childrenChange("add",[t],e),this},t.prototype.insertAt=function(e,t){return this.insert(t,e)},t.prototype.remove=function(e){var t=this.children.indexOf(e);return t>=0&&(this.children.splice(t,1),e.parent=null,this.childrenChange("remove",[e],t)),this},t.prototype.removeAt=function(e){if(0<=e&&e<this.children.length){var t=this.children[e];this.children.splice(e,1),t.parent=null,this.childrenChange("remove",[t],e)}return this},t.prototype.clear=function(){var e=this.children;return this.children=[],this._reparent(e,null),this.childrenChange("remove",e,0),this},t.prototype.bbox=function(e){return ls(this.children,!0,this.currentTransform(e))},t.prototype.rawBBox=function(){return ls(this.children,!1)},t.prototype._clippedBBox=function(e){return cs(this.children,this.currentTransform(e))},t.prototype.currentTransform=function(e){return na.prototype.currentTransform.call(this,e)||null},t.prototype.containsPoint=function(e,t){if(this.visible())for(var n=this.children,i=this.currentTransform(t),r=0;r<n.length;r++)if(n[r].containsPoint(e,i))return!0;return!1},t.prototype._reparent=function(e,t){for(var n=0;n<e.length;n++){var i=e[n],r=i.parent;r&&r!==this&&r.remove&&r.remove(i),i.parent=t}},Object.defineProperties(t.prototype,n),t}(gs(na,"children"));function _s(e,t,n){var i=n.transform()||Xo(),r=i.matrix();r.e+=e.x-t.origin.x,r.f+=e.y-t.origin.y,i.matrix(r),n.transform(i)}function bs(e,t,n,i,r){return"start"===n?t.origin[i]:"end"===n?t.origin[i]+t.size[r]-e:t.origin[i]+(t.size[r]-e)/2}function ys(e,t,n,i,r){return"start"===n?t.origin[i]+t.size[r]-e:"end"===n?t.origin[i]:t.origin[i]+(t.size[r]-e)/2}var ws={alignContent:"start",justifyContent:"start",alignItems:"start",spacing:0,orientation:"horizontal",lineSpacing:0,wrap:!0,revers:!1},ks=function(e,t){e.forEach(t)},xs=function(e,t){for(var n=e.length-1;n>=0;n--)t(e[n],n)},Cs=function(e){function t(t,n){e.call(this,Object.assign({},ws,n)),this._rect=t,this._fieldMap={}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.rect=function(e){return e?(this._rect=e,this):this._rect},t.prototype._initMap=function(){var e=this.options,t=this._fieldMap;"horizontal"===e.orientation?(t.sizeField="width",t.groupsSizeField="height",t.groupAxis="x",t.groupsAxis="y"):(t.sizeField="height",t.groupsSizeField="width",t.groupAxis="y",t.groupsAxis="x"),e.reverse?(this.forEach=xs,this.justifyAlign=ys):(this.forEach=ks,this.justifyAlign=bs)},t.prototype.reflow=function(){if(this._rect&&0!==this.children.length){this._initMap(),this.options.transform&&this.transform(null);for(var e,t,n,i=this.options,r=this._rect,o=this._initGroups(),a=o.groups,s=o.groupsSize,l=this._fieldMap,c=l.sizeField,d=l.groupsSizeField,u=l.groupAxis,h=l.groupsAxis,p=new Go,f=new Go,m=new Ko,g=bs(s,r,i.alignContent,h,d),v=function(r,o){var a=t.elements[o];f[u]=e,f[h]=bs(r.size[d],n,i.alignItems,h,d),_s(f,r,a),e+=r.size[c]+i.spacing},_=0;_<a.length;_++)t=a[_],p[u]=e=this.justifyAlign(t.size,r,i.justifyContent,u,c),p[h]=g,m[c]=t.size,m[d]=t.lineSize,n=new Yo(p,m),this.forEach(t.bboxes,v),g+=t.lineSize+i.lineSpacing;if(!i.wrap&&t.size>r.size[c]){var b=r.size[c]/n.size[c],y=n.topLeft().scale(b,b),w=bs(n.size[d]*b,r,i.alignContent,h,d),k=Xo();"x"===u?k.translate(r.origin.x-y.x,w-y.y):k.translate(w-y.x,r.origin.y-y.y),k.scale(b,b),this.transform(k)}}},t.prototype._initGroups=function(){for(var e=this,t=this.options,n=this.children,i=t.lineSpacing,r=t.wrap,o=t.spacing,a=this._fieldMap.sizeField,s=this._newGroup(),l=[],c=function(){l.push(s),d+=s.lineSize+i},d=-i,u=0;u<n.length;u++){var h=n[u],p=n[u].clippedBBox();h.visible()&&p&&(r&&s.size+p.size[a]+o>e._rect.size[a]?0===s.bboxes.length?(e._addToGroup(s,p,h),c(),s=e._newGroup()):(c(),s=e._newGroup(),e._addToGroup(s,p,h)):e._addToGroup(s,p,h))}return s.bboxes.length&&c(),{groups:l,groupsSize:d}},t.prototype._addToGroup=function(e,t,n){e.size+=t.size[this._fieldMap.sizeField]+this.options.spacing,e.lineSize=Math.max(t.size[this._fieldMap.groupsSizeField],e.lineSize),e.bboxes.push(t),e.elements.push(n)},t.prototype._newGroup=function(){return{lineSize:0,size:-this.options.spacing,bboxes:[],elements:[]}},t}(vs),Ss=function(e){function t(t,n){void 0===t&&(t=new Yo),void 0===n&&(n={}),e.call(this,n),this.geometry(t),Zr(this.options.stroke)||this.stroke("#000")}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return"Rect"},t.prototype._bbox=function(e){return this._geometry.bbox(e)},t.prototype.rawBBox=function(){return this._geometry.bbox()},t.prototype._containsPoint=function(e){return this._geometry.containsPoint(e)},t.prototype._isOnPath=function(e){return this.geometry()._isOnPath(e,this.options.stroke.width/2)},Object.defineProperties(t.prototype,n),t}(aa(la(da(na))));function Ts(e,t,n,i,r){for(var o=0;o<e.length;o++){var a=e[o].clippedBBox();if(a){var s=a.origin.clone();s[i]=bs(a.size[r],t,n||"start",i,r),_s(s,a,e[o])}}}function Ds(e,t,n,i){if(e.length>1)for(var r=new Go,o=e[0].bbox,a=1;a<e.length;a++){var s=e[a].element,l=e[a].bbox;r[t]=o.origin[t]+o.size[i],r[n]=l.origin[n],_s(r,l,s),l.origin[t]=r[t],o=l}}function As(e){for(var t=[],n=0;n<e.length;n++){var i=e[n],r=i.clippedBBox();r&&t.push({element:i,bbox:r})}return t}function Ms(e,t,n,i,r){for(var o=function(e,t,n){for(var i,r,o=t.size[n],a=[],s=[],l=0,c=function(){s.push({element:i,bbox:r})},d=0;d<e.length;d++)if(i=e[d],r=i.clippedBBox()){var u=r.size[n];l+u>o?s.length?(a.push(s),s=[],c(),l=u):(c(),a.push(s),s=[],l=0):(c(),l+=u)}return s.length&&a.push(s),a}(e,t,r),a=t.origin.clone(),s=[],l=0;l<o.length;l++){var c=o[l],d=c[0];a[i]=d.bbox.origin[i],_s(a,d.bbox,d.element),d.bbox.origin[n]=a[n],Ds(c,n,i,r),s.push([]);for(var u=0;u<c.length;u++)s[l].push(c[u].element)}return s}var Es=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._change=function(){this.optionsChange({field:"stops"})},t}(Sa);function Is(e){return function(t){return Zr(t)?(this.options.set(e,t),this):this.options.get(e)}}var zs,Ps,Hs=function(e){function t(t,n,i){e.call(this),this.options=new $o({offset:t,color:n,opacity:Zr(i)?i:1}),this.options.addObserver(this)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.create=function(e){if(Zr(e))return e instanceof t?e:e.length>1?new t(e[0],e[1],e[2]):new t(e.offset,e.color,e.opacity)},t}((zs=["offset","color","opacity"],Ps=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(Gr),function(e,t){for(var n=0;n<t.length;n++)e[t[n]]=Is(t[n])}(Ps.prototype,zs),Ps)),Fs=function(e){function t(t){void 0===t&&(t={}),e.call(this),this.stops=new Es(this._createStops(t.stops)),this.stops.addObserver(this),this._userSpace=t.userSpace,this.id=eo()}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return"Gradient"},t.prototype.userSpace=function(e){return Zr(e)?(this._userSpace=e,this.optionsChange(),this):this._userSpace},t.prototype._createStops=function(e){void 0===e&&(e=[]);for(var t=[],n=0;n<e.length;n++)t.push(Hs.create(e[n]));return t},t.prototype.addStop=function(e,t,n){this.stops.push(new Hs(e,t,n))},t.prototype.removeStop=function(e){var t=this.stops.indexOf(e);t>=0&&this.stops.splice(t,1)},t.prototype.optionsChange=function(e){this.trigger("optionsChange",{field:"gradient"+(e?"."+e.field:""),value:this})},t.prototype.geometryChange=function(){this.optionsChange()},Object.defineProperties(t.prototype,n),t}(Gr),Rs=function(e){function t(t){void 0===t&&(t={}),e.call(this,t),this.start(t.start||new Go),this.end(t.end||new Go(1,0))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(Ra(Fs,["start","end"])),Ls=function(e){function t(t){void 0===t&&(t={}),e.call(this,t),this.center(t.center||new Go),this._radius=Zr(t.radius)?t.radius:1,this._fallbackFill=t.fallbackFill}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.radius=function(e){return Zr(e)?(this._radius=e,this.geometryChange(),this):this._radius},t.prototype.fallbackFill=function(e){return Zr(e)?(this._fallbackFill=e,this.optionsChange(),this):this._fallbackFill},t}(Ra(Fs,["center"])),Bs="#aba4a6",Os=2,Vs=18,Ns=10,$s=10,Us=18,Ws=2,js=function(e){function t(t){e.call(this);var n=t.width,i=t.height;this._size=Ko.create([n,i]),this.id=eo()}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={nodeType:{configurable:!0}};return n.nodeType.get=function(){return ta},t.prototype.size=function(e){return e?(this._size=Ko.create(e),this):this._size},Object.defineProperties(t.prototype,n),t}(vs),qs=function(e,t,n){t&&e.append(new Ss(new Yo([0,0],n),{fill:{color:t},stroke:null}))};function Gs(e){void 0===e&&(e={});var t=e.gap;void 0===t&&(t=$s);var n=e.radius;void 0===n&&(n=Ns);var i=e.color;void 0===i&&(i=Bs);var r=e.background,o={fill:{color:i},stroke:null},a=4*n+2*t,s=3*n+1.5*t,l=[a/2,n+.5*t],c=[0,s],d=[a,s],u=new js({width:a,height:a});return qs(u,r,[a,a]),u.append(new ua(new oa(l,n),o),new ua(new oa(c,n),o),new ua(new oa(d,n),o)),u}function Ks(e){void 0===e&&(e={});var t=e.gap;void 0===t&&(t=Vs);var n=e.width;void 0===n&&(n=Os);var i=e.color;void 0===i&&(i=Bs);var r=e.background,o=n+t,a={fill:null,stroke:{color:i,width:n/2}},s=new js({width:o,height:o});qs(s,r,[o,o]);var l=n/4,c=o-n/4,d=new us(a);d.moveTo(l,0).lineTo(l,o);var u=new us(a);return u.moveTo(c,0).lineTo(c,o),s.append(d,u),s}function Ys(e){void 0===e&&(e={});var t=e.gap;void 0===t&&(t=Vs);var n=e.width;void 0===n&&(n=Os);var i=e.color;void 0===i&&(i=Bs);var r=e.background,o=Math.sqrt(2)*(n+t),a={fill:null,stroke:{color:i,width:n}},s=new js({width:o,height:o});qs(s,r,[o,o]);var l=new us(a);l.moveTo(0,0).lineTo(o,o);var c=new us(a);return c.moveTo(o,0).lineTo(0,o),s.append(l,c),s}function Qs(e){void 0===e&&(e={});var t=e.gap;void 0===t&&(t=Vs);var n=e.width;void 0===n&&(n=Os);var i=e.color;void 0===i&&(i=Bs);var r=e.background,o=Math.sqrt(2)*(n+t),a={fill:null,stroke:{color:i,width:n,lineCap:"square"}},s=new js({width:o,height:o});qs(s,r,[o,o]);var l=new us(a);l.moveTo(0,o/2).lineTo(o/2,0);var c=new us(a);return c.moveTo(o/2,o).lineTo(o,o/2),s.append(l,c),s}function Xs(e){void 0===e&&(e={});var t=e.gap;void 0===t&&(t=Ws);var n=e.size;void 0===n&&(n=Us);var i=e.color;void 0===i&&(i=Bs);var r=e.background,o=n+t,a=t/2,s={fill:{color:i},stroke:null},l=new js({width:o,height:o});qs(l,r,[o,o]);var c=new Ss(new Yo([a,a],[n,n]),s);return l.append(c),l}var Zs,Js,el=Object.freeze({__proto__:null,easeOutElastic:function(e,t,n,i){var r=1.70158,o=0,a=i;return 0===e?n:1===e?n+i:(o||(o=.5),a<Math.abs(i)?(a=i,r=o/4):r=o/(2*Math.PI)*Math.asin(i/a),a*Math.pow(2,-10*e)*Math.sin((Number(e)-r)*(1.1*Math.PI)/o)+i+n)},linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2}}),tl=function(e){function t(){e.call(this),this._items=[]}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={current:{configurable:!0}};return n.current.get=function(){return Zs||(Zs=new t),Zs},t.prototype.register=function(e,t){this._items.push({name:e,type:t})},t.prototype.create=function(e,t){var n,i=this._items;if(t&&t.type)for(var r=t.type.toLowerCase(),o=0;o<i.length;o++)if(i[o].name.toLowerCase()===r){n=i[o];break}if(n)return new n.type(e,t)},Object.defineProperties(t,n),t}(fr),nl=function(e){function t(t,n){e.call(this),this.options=Object.assign({},this.options,n),this.element=t}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={options:{configurable:!0}};return t.create=function(e,t,n){return tl.current.create(e,t,n)},n.options.get=function(){return this._options||{duration:500,easing:"swing"}},n.options.set=function(e){this._options=e},t.prototype.setup=function(){},t.prototype.step=function(){},t.prototype.play=function(){var e=this,t=this.options,n=t.duration,i=t.delay;void 0===i&&(i=0);var r=el[t.easing],o=zr()+i,a=o+n;0===n?(this.step(1),this.abort()):setTimeout((function(){var t=function(){if(!e._stopped){var i=zr(),s=fo(i-o,0,n),l=r(s/n,s,0,1,n);e.step(l),i<a?wr(t):e.abort()}};t()}),i)},t.prototype.abort=function(){this._stopped=!0},t.prototype.destroy=function(){this.abort()},Object.defineProperties(t.prototype,n),t}(fr),il=function(e){function t(){e.apply(this,arguments)}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={current:{configurable:!0}};return n.current.get=function(){return Js||(Js=new t),Js},t.prototype.parse=function(e,t){return ss(new hs(t),e)},Object.defineProperties(t,n),t}(fr),rl=function(e){function t(t){e.call(this),this.childNodes=[],this.parent=null,t&&(this.srcElement=t,this.observe())}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this.srcElement&&this.srcElement.removeObserver(this);for(var e=this.childNodes,t=0;t<e.length;t++)this.childNodes[t].destroy();this.parent=null},t.prototype.load=function(){},t.prototype.observe=function(){this.srcElement&&this.srcElement.addObserver(this)},t.prototype.append=function(e){this.childNodes.push(e),e.parent=this},t.prototype.insertAt=function(e,t){this.childNodes.splice(t,0,e),e.parent=this},t.prototype.remove=function(e,t){for(var n=e+t,i=e;i<n;i++)this.childNodes[i].removeSelf();this.childNodes.splice(e,t)},t.prototype.removeSelf=function(){this.clear(),this.destroy()},t.prototype.clear=function(){this.remove(0,this.childNodes.length)},t.prototype.invalidate=function(){this.parent&&this.parent.invalidate()},t.prototype.geometryChange=function(){this.invalidate()},t.prototype.optionsChange=function(){this.invalidate()},t.prototype.childrenChange=function(e){"add"===e.action?this.load(e.items,e.index):"remove"===e.action&&this.remove(e.index,e.items.length),this.invalidate()},t}(fr),ol=["click","mouseenter","mouseleave","mousemove","resize"],al=function(e){function t(t,n){e.call(this),this.options=Object.assign({},n),this.element=t,this.element._kendoExportVisual=this.exportVisual.bind(this),this._click=this._handler("click"),this._mouseenter=this._handler("mouseenter"),this._mouseleave=this._handler("mouseleave"),this._mousemove=this._handler("mousemove"),this._visual=new vs,Co(t,this.options),this.bind(ol,this.options),this._enableTracking()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.draw=function(e){this._visual.children.push(e)},t.prototype.clear=function(){this._visual.children=[]},t.prototype.destroy=function(){this._visual=null,this.element._kendoExportVisual=null,this.unbind()},t.prototype.eventTarget=function(e){for(var t,n=uo(e);!t&&n&&(t=n._kendoNode,n!==this.element);)n=n.parentElement;if(t)return t.srcElement},t.prototype.exportVisual=function(){return this._visual},t.prototype.getSize=function(){return Co(this.element)},t.prototype.currentSize=function(e){if(!e)return this._size;this._size=e},t.prototype.setSize=function(e){Co(this.element,e),this.currentSize(e),this._resize()},t.prototype.resize=function(e){var t=this.getSize(),n=this.currentSize();(e||(t.width>0||t.height>0)&&(!n||t.width!==n.width||t.height!==n.height))&&(this.currentSize(t),this._resize(t,e),this.trigger("resize",t))},t.prototype.size=function(e){if(!e)return this.getSize();this.setSize(e)},t.prototype.suspendTracking=function(){this._suspendedTracking=!0},t.prototype.resumeTracking=function(){this._suspendedTracking=!1},t.prototype._enableTracking=function(){},t.prototype._resize=function(){},t.prototype._handler=function(e){var t=this;return function(n){var i=t.eventTarget(n);i&&!t._suspendedTracking&&t.trigger(e,{element:i,originalEvent:n,type:e})}},t.prototype._elementOffset=function(){var e=this.element,t=To(e),n=wo(e),i=n.left,r=n.top;return{left:i+t.left,top:r+t.top}},t.prototype._surfacePoint=function(e){var t=this._elementOffset(),n=co(e),i=n.x-t.left,r=n.y-t.top,o=Eo(this.element).invert();return new Go(i,r).transform(o)},t}(mr);function sl(e,t){return Zr(t)&&null!==t?" "+e+'="'+t+'" ':""}function ll(e){for(var t="",n=0;n<e.length;n++)t+=sl(e[n][0],e[n][1]);return t}function cl(e){for(var t="",n=0;n<e.length;n++){var i=e[n][1];Zr(i)&&(t+=e[n][0]+":"+i+";")}if(""!==t)return t}var dl={},ul=function(e,t){var n=nr(t);Object.keys(n).forEach((function(t){e.style[t]=n[t]}))},hl="data-style",pl=function(e){return(e||"").replace(/\sstyle=/g," "+hl+"=")},fl=function(e){Array.from(e.querySelectorAll("["+hl+"]")).forEach((function(e){var t=e.getAttribute(hl);e.removeAttribute(hl),ul(e,t)}))},ml=function(e,t){e.innerHTML=pl(t),fl(e)},gl="http://www.w3.org/2000/svg",vl="none",_l=function(e,t){ml(e,t)};if("undefined"!=typeof document){var bl="<svg xmlns='"+gl+"'></svg>",yl=document.createElement("div"),wl="undefined"!=typeof DOMParser;yl.innerHTML=bl,wl&&yl.firstChild.namespaceURI!==gl&&(_l=function(e,t){var n=(new DOMParser).parseFromString(pl(t),"text/xml");fl(n);var i=document.adoptNode(n.documentElement);e.innerHTML="",e.appendChild(i)})}var kl=_l,xl="transform",Cl={clip:"clip-path",fill:"fill"};function Sl(e,t){return"clip"===e||"fill"===e&&(!t||"Gradient"===t.nodeType||t.nodeType===ta)}var Tl=function(e){function t(t,n){e.call(this,t),this.definitions={},this.options=n}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this.element&&(this.element._kendoNode=null,this.element=null),this.clearDefinitions(),e.prototype.destroy.call(this)},t.prototype.load=function(e,t){for(var n=this,i=0;i<e.length;i++){var r=e[i],o=r.children,a=new dl[r.nodeType](r,n.options);Zr(t)?n.insertAt(a,t):n.append(a),a.createDefinitions(),o&&o.length>0&&a.load(o);var s=n.element;s&&a.attachTo(s,t)}},t.prototype.root=function(){for(var e=this;e.parent;)e=e.parent;return e},t.prototype.attachTo=function(e,t){var n=document.createElement("div");kl(n,"<svg xmlns='"+gl+"' version='1.1'>"+this.render()+"</svg>");var i=n.firstChild.firstChild;i&&(Zr(t)?e.insertBefore(i,e.childNodes[t]||null):e.appendChild(i),this.setElement(i))},t.prototype.setElement=function(e){this.element&&(this.element._kendoNode=null),this.element=e,this.element._kendoNode=this;for(var t=this.childNodes,n=0;n<t.length;n++){var i=e.childNodes[n];t[n].setElement(i)}},t.prototype.clear=function(){this.clearDefinitions(),this.element&&(this.element.innerHTML="");for(var e=this.childNodes,t=0;t<e.length;t++)e[t].destroy();this.childNodes=[]},t.prototype.removeSelf=function(){if(this.element){var t=this.element.parentNode;t&&t.removeChild(this.element),this.element=null}e.prototype.removeSelf.call(this)},t.prototype.template=function(){return this.renderChildren()},t.prototype.render=function(){return this.template()},t.prototype.renderChildren=function(){for(var e=this.childNodes,t="",n=0;n<e.length;n++)t+=e[n].render();return t},t.prototype.optionsChange=function(t){var n=t.field,i=t.value;"visible"===n?this.css("display",i?"":vl):Cl[n]&&Sl(n,i)?this.updateDefinition(n,i):"opacity"===n?this.attr("opacity",i):"cursor"===n?this.css("cursor",i):"id"===n&&(i?this.attr("id",i):this.removeAttr("id")),e.prototype.optionsChange.call(this,t)},t.prototype.accessibilityOptionsChange=function(e){var t=e.field,n=e.value;"role"===t?n?this.attr("role",n):this.removeAttr("role"):"ariaLabel"===t?n?this.attr("aria-label",Dr(n)):this.removeAttr("aria-label"):"ariaRoleDescription"===t?n?this.attr("aria-roledescription",Dr(n)):this.removeAttr("aria-roledescription"):"ariaChecked"===t?Zr(n)?this.attr("aria-checked",n):this.removeAttr("aria-checked"):"className"===t&&this.className(n)},t.prototype.attr=function(e,t){this.element&&this.element.setAttribute(e,t)},t.prototype.allAttr=function(e){for(var t=0;t<e.length;t++)this.attr(e[t][0],e[t][1])},t.prototype.toggleAttr=function(e,t){t?this.attr(e,t):this.removeAttr(e)},t.prototype.css=function(e,t){this.element&&(this.element.style[e]=t)},t.prototype.allCss=function(e){for(var t=0;t<e.length;t++)this.css(e[t][0],e[t][1])},t.prototype.className=function(e){var t,n=this;this.element&&((t=this.element.classList).remove.apply(t,this.element.classList),e.split(" ").forEach((function(e){n.element.classList.add(e)})))},t.prototype.removeAttr=function(e){this.element&&this.element.removeAttribute(e)},t.prototype.mapTransform=function(e){var t=[];return e&&t.push([xl,"matrix("+e.matrix().toString(6)+")"]),t},t.prototype.renderTransform=function(){return ll(this.mapTransform(this.srcElement.transform()))},t.prototype.transformChange=function(e){e?this.allAttr(this.mapTransform(e)):this.removeAttr(xl)},t.prototype.mapStyle=function(){var e=this.srcElement.options,t=[["cursor",e.cursor]];return!1===e.visible&&t.push(["display",vl]),t},t.prototype.renderStyle=function(){return sl("style",cl(this.mapStyle(!0)))},t.prototype.renderOpacity=function(){return sl("opacity",this.srcElement.options.opacity)},t.prototype.renderId=function(){return sl("id",this.srcElement.options.id)},t.prototype.renderClassName=function(){return sl("class",this.srcElement.options.className)},t.prototype.renderRole=function(){return sl("role",this.srcElement.options.role)},t.prototype.renderAriaLabel=function(){var e=this.srcElement.options.ariaLabel;return e&&(e=Dr(e)),sl("aria-label",e)},t.prototype.renderAriaRoleDescription=function(){var e=this.srcElement.options.ariaRoleDescription;return e&&(e=Dr(e)),sl("aria-roledescription",e)},t.prototype.renderAriaChecked=function(){return sl("aria-checked",this.srcElement.options.ariaChecked)},t.prototype.createDefinitions=function(){var e=this.srcElement,t=this.definitions;if(e){var n,i=e.options;for(var r in Cl){var o=i.get(r);o&&Sl(r,o)&&(t[r]=o,n=!0)}n&&this.definitionChange({action:"add",definitions:t})}},t.prototype.definitionChange=function(e){this.parent&&this.parent.definitionChange(e)},t.prototype.updateDefinition=function(e,t){var n=this.definitions,i=n[e],r=Cl[e],o={};i&&(o[e]=i,this.definitionChange({action:"remove",definitions:o}),delete n[e]),t?(o[e]=t,this.definitionChange({action:"add",definitions:o}),n[e]=t,this.attr(r,this.refUrl(t.id))):i&&this.removeAttr(r)},t.prototype.clearDefinitions=function(){var e=this.definitions;this.definitionChange({action:"remove",definitions:e}),this.definitions={}},t.prototype.renderDefinitions=function(){return ll(this.mapDefinitions())},t.prototype.mapDefinitions=function(){var e=this.definitions,t=[];for(var n in e)t.push([Cl[n],this.refUrl(e[n].id)]);return t},t.prototype.refUrl=function(e){var t=(this.options||{}).skipBaseHref,n=this.baseUrl().replace(/'/g,"\\'");return"url("+(t?"":n)+"#"+e+")"},t.prototype.baseUrl=function(){return function(){var e=document.getElementsByTagName("base")[0],t=document.location.href,n="";if(e&&!(Ir.browser||{}).msie){var i=t.indexOf("#");-1!==i&&(t=t.substring(0,i)),n=t}return n}()},t}(rl),Dl=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.template=function(){return"<stop "+this.renderOffset()+" "+this.renderStyle()+" />"},t.prototype.renderOffset=function(){return sl("offset",this.srcElement.offset())},t.prototype.mapStyle=function(){var e=this.srcElement;return[["stop-color",e.color()],["stop-opacity",e.opacity()]]},t.prototype.optionsChange=function(e){"offset"===e.field?this.attr(e.field,e.value):"color"!==e.field&&"opacity"!==e.field||this.css("stop-"+e.field,e.value)},t}(Tl),Al=function(e){function t(t){e.call(this,t),this.id=t.id,this.loadStops()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.loadStops=function(){for(var e=this.srcElement.stops,t=this.element,n=0;n<e.length;n++){var i=new Dl(e[n]);this.append(i),t&&i.attachTo(t)}},t.prototype.optionsChange=function(e){"gradient.stops"===e.field?(rl.prototype.clear.call(this),this.loadStops()):"gradient"===e.field&&this.allAttr(this.mapCoordinates())},t.prototype.renderCoordinates=function(){return ll(this.mapCoordinates())},t.prototype.mapSpace=function(){return["gradientUnits",this.srcElement.userSpace()?"userSpaceOnUse":"objectBoundingBox"]},t}(Tl),Ml=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.template=function(){return"<linearGradient id='"+this.id+"' "+this.renderCoordinates()+">"+this.renderChildren()+"</linearGradient>"},t.prototype.mapCoordinates=function(){var e=this.srcElement,t=e.start(),n=e.end();return[["x1",t.x],["y1",t.y],["x2",n.x],["y2",n.y],this.mapSpace()]},t}(Al),El=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.template=function(){return"<radialGradient id='"+this.id+"' "+this.renderCoordinates()+">"+this.renderChildren()+"</radialGradient>"},t.prototype.mapCoordinates=function(){var e=this.srcElement,t=e.center(),n=e.radius();return[["cx",t.x],["cy",t.y],["r",n],this.mapSpace()]},t}(Al),Il=function(e){function t(t){e.call(this,t),this.id=t.id,this.load(t.children)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.template=function(){var e=this.srcElement.size().getWidth(),t=this.srcElement.size().getHeight();return"<pattern id='"+this.srcElement.id+"' width='"+e+"' height='"+t+"' patternUnits='userSpaceOnUse'>"+this.renderChildren()+"</pattern>"},t}(Tl),zl=function(e){function t(t){e.call(this),this.srcElement=t,this.id=t.id,this.load([t])}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.renderClipRule=function(){return sl("clip-rule","evenodd")},t.prototype.template=function(){return"<clipPath "+this.renderClipRule()+" id='"+this.id+"'>"+this.renderChildren()+"</clipPath>"},t}(Tl),Pl=function(e){function t(){e.call(this),this.definitionMap={}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.attachTo=function(e){this.element=e},t.prototype.template=function(){return"<defs>"+this.renderChildren()+"</defs>"},t.prototype.definitionChange=function(e){var t=e.definitions,n=e.action;"add"===n?this.addDefinitions(t):"remove"===n&&this.removeDefinitions(t)},t.prototype.createDefinition=function(e,t){var n;return"clip"===e?n=zl:"fill"===e&&(t instanceof Rs?n=Ml:t instanceof Ls?n=El:t.nodeType===ta&&(n=Il)),new n(t)},t.prototype.addDefinitions=function(e){for(var t in e)this.addDefinition(t,e[t])},t.prototype.addDefinition=function(e,t){var n=this.element,i=this.definitionMap,r=t.id,o=i[r];if(o)o.count++;else{var a=this.createDefinition(e,t);i[r]={element:a,count:1},this.append(a),n&&a.attachTo(this.element)}},t.prototype.removeDefinitions=function(e){for(var t in e)this.removeDefinition(e[t])},t.prototype.removeDefinition=function(e){var t=this.definitionMap,n=e.id,i=t[n];i&&(i.count--,0===i.count&&(this.remove(this.childNodes.indexOf(i.element),1),delete t[n]))},t}(Tl),Hl=function(e){function t(t){e.call(this),this.options=t,this.defs=new Pl}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.attachTo=function(e){this.element=e,this.defs.attachTo(e.firstElementChild)},t.prototype.clear=function(){rl.prototype.clear.call(this)},t.prototype.template=function(){return this.defs.render()+this.renderChildren()},t.prototype.definitionChange=function(e){this.defs.definitionChange(e)},t}(Tl),Fl={"fill.opacity":"fill-opacity","stroke.color":"stroke","stroke.width":"stroke-width","stroke.opacity":"stroke-opacity"},Rl=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.geometryChange=function(){this.attr("d",this.renderData()),this.invalidate()},t.prototype.optionsChange=function(t){switch(t.field){case"fill":t.value?this.allAttr(this.mapFill(t.value)):this.removeAttr("fill");break;case"fill.color":this.allAttr(this.mapFill({color:t.value}));break;case"stroke":t.value?this.allAttr(this.mapStroke(t.value)):this.removeAttr("stroke");break;case"transform":this.transformChange(t.value);break;default:var n=Fl[t.field];n&&this.attr(n,t.value)}this.accessibilityOptionsChange(t),e.prototype.optionsChange.call(this,t)},t.prototype.content=function(){this.element&&(this.element.textContent=this.srcElement.content())},t.prototype.renderData=function(){return this.srcElement.toString(3)||void 0},t.prototype.mapStroke=function(e){var t=[];return e&&!ho(e.color)?(t.push(["stroke",e.color]),t.push(["stroke-width",e.width]),t.push(["stroke-linecap",this.renderLinecap(e)]),t.push(["stroke-linejoin",e.lineJoin]),Zr(e.opacity)&&t.push(["stroke-opacity",e.opacity]),Zr(e.dashType)&&t.push(["stroke-dasharray",this.renderDashType(e)])):t.push(["stroke",vl]),t},t.prototype.renderStroke=function(){return ll(this.mapStroke(this.srcElement.options.stroke))},t.prototype.renderDashType=function(e){var t=e.dashType,n=e.width;if(void 0===n&&(n=1),t&&t!==Jo){for(var i=Zo[t.toLowerCase()],r=[],o=0;o<i.length;o++)r.push(i[o]*n);return r.join(" ")}},t.prototype.renderLinecap=function(e){var t=e.dashType,n=e.lineCap;return t&&t!==Jo?ea:n},t.prototype.mapFill=function(e){var t=[];return(!e||"Gradient"!==e.nodeType&&e.nodeType!==ta)&&(e&&!ho(e.color)?(t.push(["fill",e.color]),Zr(e.opacity)&&t.push(["fill-opacity",e.opacity])):t.push(["fill",vl])),t},t.prototype.renderFill=function(){return ll(this.mapFill(this.srcElement.options.fill))},t.prototype.template=function(){return"<path "+this.renderId()+" "+this.renderStyle()+" "+this.renderOpacity()+" "+sl("d",this.renderData())+this.renderStroke()+this.renderFill()+this.renderDefinitions()+this.renderTransform()+this.renderClassName()+" "+this.renderRole()+this.renderAriaLabel()+" "+this.renderAriaRoleDescription()+this.renderAriaChecked()+" ></path>"},t}(Tl),Ll=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.renderData=function(){return this.srcElement.toPath().toString(3)},t}(Rl),Bl=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.geometryChange=function(){var e=this.center();this.attr("cx",e.x),this.attr("cy",e.y),this.attr("r",this.radius()),this.invalidate()},t.prototype.center=function(){return this.srcElement.geometry().center},t.prototype.radius=function(){return this.srcElement.geometry().radius},t.prototype.template=function(){return"<circle "+this.renderId()+" "+this.renderStyle()+" "+this.renderOpacity()+"cx='"+this.center().x+"' cy='"+this.center().y+"' r='"+this.radius()+"'"+this.renderStroke()+" "+this.renderFill()+" "+this.renderDefinitions()+this.renderClassName()+" "+this.renderRole()+this.renderAriaLabel()+" "+this.renderAriaRoleDescription()+this.renderAriaChecked()+" "+this.renderTransform()+" ></circle>"},t}(Rl),Ol=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.template=function(){return"<g"+(this.renderId()+this.renderTransform()+this.renderClassName()+this.renderStyle()+this.renderOpacity()+this.renderRole()+this.renderAriaLabel()+this.renderAriaRoleDescription()+this.renderAriaChecked()+this.renderDefinitions())+">"+this.renderChildren()+"</g>"},t.prototype.optionsChange=function(t){var n=t.field,i=t.value;"transform"===n&&this.transformChange(i),this.accessibilityOptionsChange(t),e.prototype.optionsChange.call(this,t)},t}(Tl),Vl=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.geometryChange=function(){this.allAttr(this.mapPosition()),this.invalidate()},t.prototype.optionsChange=function(t){"src"===t.field&&this.allAttr(this.mapSource()),e.prototype.optionsChange.call(this,t)},t.prototype.mapPosition=function(){var e=this.srcElement.rect(),t=e.topLeft();return[["x",t.x],["y",t.y],["width",e.width()+"px"],["height",e.height()+"px"]]},t.prototype.renderPosition=function(){return ll(this.mapPosition())},t.prototype.mapSource=function(e){var t=this.srcElement.src();return e&&(t=Dr(t)),[["xlink:href",t]]},t.prototype.renderSource=function(){return ll(this.mapSource(!0))},t.prototype.template=function(){return"<image preserveAspectRatio='none' "+this.renderId()+" "+this.renderStyle()+" "+this.renderTransform()+" "+this.renderOpacity()+this.renderPosition()+" "+this.renderSource()+" "+this.renderDefinitions()+this.renderClassName()+" "+this.renderRole()+this.renderAriaLabel()+" "+this.renderAriaRoleDescription()+this.renderAriaChecked()+" ></image>"},t}(Rl),Nl=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.renderData=function(){return this.srcElement.toString(3)||"undefined"},t}(Rl),$l=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.geometryChange=function(){var e=this.srcElement.geometry();this.attr("x",e.origin.x),this.attr("y",e.origin.y),this.attr("width",e.size.width),this.attr("height",e.size.height),this.attr("rx",e.cornerRadius[0]),this.attr("ry",e.cornerRadius[1]),this.invalidate()},t.prototype.size=function(){return this.srcElement.geometry().size},t.prototype.origin=function(){return this.srcElement.geometry().origin},t.prototype.rx=function(){return this.srcElement.geometry().cornerRadius[0]},t.prototype.ry=function(){return this.srcElement.geometry().cornerRadius[1]},t.prototype.template=function(){return"<rect "+this.renderId()+" "+this.renderStyle()+" "+this.renderOpacity()+" x='"+this.origin().x+"' y='"+this.origin().y+"' rx='"+this.rx()+"' ry='"+this.ry()+"' width='"+this.size().width+"' height='"+this.size().height+"' "+this.renderStroke()+" "+this.renderFill()+" "+this.renderDefinitions()+" "+this.renderTransform()+this.renderClassName()+" "+this.renderRole()+this.renderAriaLabel()+" "+this.renderAriaRoleDescription()+this.renderAriaChecked()+" />"},t}(Rl),Ul=/&(?:[a-zA-Z]+|#\d+);/g;function Wl(e){if(!e||"string"!=typeof e||!Ul.test(e))return e;var t=Wl._element;return Ul.lastIndex=0,e.replace(Ul,(function(e){return t.innerHTML=e,t.textContent||t.innerText}))}"undefined"!=typeof document&&(Wl._element=document.createElement("span"));var jl=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.geometryChange=function(){var e=this.pos();this.attr("x",e.x),this.attr("y",e.y),this.invalidate()},t.prototype.optionsChange=function(t){"font"===t.field?(this.attr("style",cl(this.mapStyle())),this.geometryChange()):"content"===t.field&&e.prototype.content.call(this,this.srcElement.content()),e.prototype.optionsChange.call(this,t)},t.prototype.mapStyle=function(t){var n=e.prototype.mapStyle.call(this,t),i=this.srcElement.options.font;return t&&(i=Dr(i)),n.push(["font",i],["white-space","pre"]),n},t.prototype.pos=function(){var e=this.srcElement.position(),t=this.srcElement.measure();return e.clone().setY(e.y+t.baseline)},t.prototype.renderContent=function(){var e=this.srcElement.content();return Po(e=Dr(e=Wl(e)))},t.prototype.renderTextAnchor=function(){var e;return!(this.options||{}).rtl||Ir.browser.msie||Ir.browser.edge||(e="end"),sl("text-anchor",e)},t.prototype.renderPaintOrder=function(){var e=this.srcElement.options.paintOrder;return e?sl("paint-order",e):""},t.prototype.template=function(){return"<text "+this.renderId()+" "+this.renderTextAnchor()+" "+this.renderStyle()+" "+this.renderOpacity()+"x='"+this.pos().x+"' y='"+this.pos().y+"' "+this.renderStroke()+" "+this.renderTransform()+" "+this.renderDefinitions()+this.renderPaintOrder()+this.renderFill()+this.renderClassName()+" "+this.renderRole()+this.renderAriaLabel()+" "+this.renderAriaRoleDescription()+this.renderAriaChecked()+">"+this.renderContent()+"</text>"},t}(Rl);dl.Arc=Ll,dl.Circle=Bl,dl.Group=Ol,dl.Image=Vl,dl.MultiPath=Nl,dl.Path=Rl,dl.Rect=$l,dl.Text=jl;var ql=function(e){function t(t,n){e.call(this,t,n),this._root=new Hl(Object.assign({rtl:"rtl"===ko(t,"direction").direction},this.options)),kl(this.element,this._template("")),this._rootElement=this.element.firstElementChild,this._rootElement.style.width="100%",this._rootElement.style.height="100%",this._rootElement.style.overflow="hidden",function(e){var t;try{t=e.getScreenCTM?e.getScreenCTM():null}catch(e){}if(t){var n=-t.e%1,i=-t.f%1,r=e.style;0===n&&0===i||(r.left=n+"px",r.top=i+"px")}}(this._rootElement),this._root.attachTo(this._rootElement),yo(this.element,{click:this._click,mouseover:this._mouseenter,mouseout:this._mouseleave,mousemove:this._mousemove}),this.resize()}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={type:{configurable:!0}};return n.type.get=function(){return"svg"},t.prototype.destroy=function(){this._root&&(this._root.destroy(),this._root=null,this._rootElement=null,So(this.element,{click:this._click,mouseover:this._mouseenter,mouseout:this._mouseleave,mousemove:this._mousemove})),e.prototype.destroy.call(this)},t.prototype.translate=function(e){var t=Math.round(e.x)+" "+Math.round(e.y)+" "+this._size.width+" "+this._size.height;this._offset=e,this._rootElement.setAttribute("viewBox",t)},t.prototype.draw=function(t){e.prototype.draw.call(this,t),this._root.load([t])},t.prototype.clear=function(){e.prototype.clear.call(this),this._root.clear()},t.prototype.svg=function(){return"<?xml version='1.0' ?>"+this._template()},t.prototype.exportVisual=function(){var e=this._visual,t=this._offset;if(t){var n=new vs;n.children.push(e),n.transform(Xo().translate(-t.x,-t.y)),e=n}return e},t.prototype._resize=function(){this._offset&&this.translate(this._offset)},t.prototype._template=function(e){return"<svg "+("string"==typeof e?e:"style='width: 100%; height: 100%; overflow: hidden;' ")+"xmlns='"+gl+"' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1'>"+this._root.render()+"</svg>"},Object.defineProperties(t.prototype,n),t}(al),Gl={},Kl=function(e){function t(t){e.call(this,t),t&&this.initClip()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initClip=function(){var e=this.srcElement.clip();e&&(this.clip=e,e.addObserver(this))},t.prototype.clear=function(){this.srcElement&&this.srcElement.removeObserver(this),this.clearClip(),e.prototype.clear.call(this)},t.prototype.clearClip=function(){this.clip&&(this.clip.removeObserver(this),delete this.clip)},t.prototype.setClip=function(e){this.clip&&(e.beginPath(),new Gl[this.clip.nodeType](this.clip).renderPoints(e,this.clip),e.clip("evenodd"))},t.prototype.optionsChange=function(t){"clip"===t.field&&(this.clearClip(),this.initClip()),e.prototype.optionsChange.call(this,t)},t.prototype.setTransform=function(e){if(this.srcElement){var t=this.srcElement.transform();t&&e.transform.apply(e,t.matrix().toArray(6))}},t.prototype.loadElements=function(e,t,n){for(var i=0;i<e.length;i++){var r=e[i],o=r.children,a=new Gl[r.nodeType](r,n);o&&o.length>0&&a.load(o,t,n),Zr(t)?this.insertAt(a,t):this.append(a)}},t.prototype.load=function(e,t,n){this.loadElements(e,t,n),this.invalidate()},t.prototype.setOpacity=function(e){if(this.srcElement){var t=this.srcElement.opacity();Zr(t)&&this.globalAlpha(e,t)}},t.prototype.globalAlpha=function(e,t){var n=t;n&&e.globalAlpha&&(n*=e.globalAlpha),e.globalAlpha=n},t.prototype.visible=function(){var e=this.srcElement;return!e||e&&!1!==e.options.visible},t}(rl),Yl=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.renderTo=function(e){if(this.visible()){e.save(),this.setTransform(e),this.setClip(e),this.setOpacity(e);for(var t=this.childNodes,n=0;n<t.length;n++){var i=t[n];i.visible()&&i.renderTo(e)}e.restore()}},t}(gs(Kl,"childNodes")),Ql=1e3/60,Xl=function(e){function t(t,n){e.call(this),this.canvas=t,this.size=n,this.ctx=t.getContext("2d");var i=this._invalidate.bind(this);this.invalidate=Pr((function(){wr(i)}),Ql)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){e.prototype.destroy.call(this),this.canvas=null,this.ctx=null},t.prototype.load=function(e,t,n){this.loadElements(e,t,n),this._invalidate()},t.prototype._rescale=function(e){var t=this.canvas,n=this.size;t.width=n.width*e,t.height=n.height*e,this.ctx.scale(e,e)},t.prototype._devicePixelRatio=function(){return"number"==typeof window.devicePixelRatio?window.devicePixelRatio:1},t.prototype._invalidate=function(e){if(this.ctx){var t=e&&e.fixedScale?1:this._devicePixelRatio();this._rescale(t),this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height),this.renderTo(this.ctx)}},t}(gs(Yl,"childNodes")),Zl=function(e){function t(){e.call(this),this.shapes=[]}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._add=function(e,t){this.shapes.push({bbox:t,shape:e}),e._quadNode=this},t.prototype.pointShapes=function(e){for(var t=this.shapes,n=t.length,i=[],r=0;r<n;r++)t[r].bbox.containsPoint(e)&&i.push(t[r].shape);return i},t.prototype.insert=function(e,t){this._add(e,t)},t.prototype.remove=function(e){for(var t=this.shapes,n=t.length,i=0;i<n;i++)if(t[i].shape===e){t.splice(i,1);break}},t}(fr),Jl=function(e){function t(t){e.call(this),this.children=[],this.rect=t}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.inBounds=function(e){var t=this.rect,n=t.bottomRight(),i=e.bottomRight(),r=t.origin.x<=e.origin.x&&t.origin.y<=e.origin.y&&i.x<=n.x&&i.y<=n.y;return r},t.prototype.pointShapes=function(t){for(var n=this.children,i=n.length,r=e.prototype.pointShapes.call(this,t),o=0;o<i;o++)Kr(r,n[o].pointShapes(t));return r},t.prototype.insert=function(e,t){var n=this.children,i=!1;if(this.inBounds(t)){if(this.shapes.length<4)this._add(e,t);else{n.length||this._initChildren();for(var r=0;r<n.length;r++)if(n[r].insert(e,t)){i=!0;break}i||this._add(e,t)}i=!0}return i},t.prototype._initChildren=function(){var e=this.rect,n=this.children,i=e.center(),r=e.width()/2,o=e.height()/2;n.push(new t(new Yo([e.origin.x,e.origin.y],[r,o])),new t(new Yo([i.x,e.origin.y],[r,o])),new t(new Yo([e.origin.x,i.y],[r,o])),new t(new Yo([i.x,i.y],[r,o])))},t}(Zl),ec=3e3,tc=function(e){function t(){e.call(this),this.initRoots()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initRoots=function(){this.rootMap={},this.root=new Zl,this.rootElements=[]},t.prototype.clear=function(){for(var e=this.rootElements,t=0;t<e.length;t++)this.remove(e[t]);this.initRoots()},t.prototype.pointShape=function(e){var t=(this.rootMap[Math.floor(e.x/ec)]||{})[Math.floor(e.y/ec)],n=this.root.pointShapes(e);t&&(n=n.concat(t.pointShapes(e))),this.assignZindex(n),n.sort(nc);for(var i=0;i<n.length;i++)if(n[i].containsPoint(e))return n[i]},t.prototype.assignZindex=function(e){for(var t=0;t<e.length;t++){for(var n=e[t],i=0,r=Math.pow(1e4,75),o=[];n;)o.push(n),n=n.parent;for(;o.length;)i+=(((n=o.pop()).parent?n.parent.children:this.rootElements).indexOf(n)+1)*r,r/=1e4;e[t]._zIndex=i}},t.prototype.optionsChange=function(e){"transform"!==e.field&&"stroke.width"!==e.field||this.bboxChange(e.element)},t.prototype.geometryChange=function(e){this.bboxChange(e.element)},t.prototype.bboxChange=function(e){if("Group"===e.nodeType)for(var t=0;t<e.children.length;t++)this.bboxChange(e.children[t]);else e._quadNode&&e._quadNode.remove(e),this._insertShape(e)},t.prototype.add=function(e){var t=Array.isArray(e)?e.slice(0):[e];Kr(this.rootElements,t),this._insert(t)},t.prototype.childrenChange=function(e){if("remove"===e.action)for(var t=0;t<e.items.length;t++)this.remove(e.items[t]);else this._insert(Array.prototype.slice.call(e.items,0))},t.prototype._insert=function(e){for(var t;e.length>0;)(t=e.pop()).addObserver(this),"Group"===t.nodeType?Kr(e,t.children):this._insertShape(t)},t.prototype._insertShape=function(e){var t=e.bbox();if(t){var n=this.getSectors(t),i=n[0][0],r=n[1][0];if(this.inRoot(n))this.root.insert(e,t);else{var o=this.rootMap;o[i]||(o[i]={}),o[i][r]||(o[i][r]=new Jl(new Yo([i*ec,r*ec],[ec,ec]))),o[i][r].insert(e,t)}}},t.prototype.remove=function(e){if(e.removeObserver(this),"Group"===e.nodeType)for(var t=e.children,n=0;n<t.length;n++)this.remove(t[n]);else e._quadNode&&(e._quadNode.remove(e),delete e._quadNode)},t.prototype.inRoot=function(e){return e[0].length>1||e[1].length>1},t.prototype.getSectors=function(e){for(var t=e.bottomRight(),n=Math.floor(t.x/ec),i=Math.floor(t.y/ec),r=[[],[]],o=Math.floor(e.origin.x/ec);o<=n;o++)r[0].push(o);for(var a=Math.floor(e.origin.y/ec);a<=i;a++)r[1].push(a);return r},t}(fr);function nc(e,t){return e._zIndex<t._zIndex?1:e._zIndex>t._zIndex?-1:0}var ic=function(e){e.bind("mouseenter",this._mouseenter.bind(this)),e.bind("mouseleave",this._mouseleave.bind(this)),this.element=e.element};function rc(e,t){var n=t.segments;if(0!==n.length){var i=n[0],r=i.anchor();e.moveTo(r.x,r.y);for(var o=1;o<n.length;o++){r=(i=n[o]).anchor();var a=n[o-1].controlOut(),s=i.controlIn();a&&s?e.bezierCurveTo(a.x,a.y,s.x,s.y,r.x,r.y):e.lineTo(r.x,r.y)}t.options.closed&&e.closePath()}}ic.prototype.clear=function(){this._resetCursor()},ic.prototype.destroy=function(){this._resetCursor(),delete this.element},ic.prototype._mouseenter=function(e){var t=this._shapeCursor(e);t?(this._current||(this._defaultCursor=this._getCursor()),this._setCursor(t)):this._resetCursor()},ic.prototype._mouseleave=function(){this._resetCursor()},ic.prototype._shapeCursor=function(e){for(var t=e.element;t&&!Zr(t.options.cursor);)t=t.parent;if(t)return t.options.cursor},ic.prototype._getCursor=function(){if(this.element)return this.element.style.cursor},ic.prototype._setCursor=function(e){this.element&&(this.element.style.cursor=e,this._current=e)},ic.prototype._resetCursor=function(){this._current&&(this._setCursor(this._defaultCursor||""),delete this._current)};var oc=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.renderTo=function(e){e.save(),this.setTransform(e),this.setClip(e),this.setOpacity(e),e.beginPath(),this.renderPoints(e,this.srcElement),this.setLineDash(e),this.setLineCap(e),this.setLineJoin(e),this.setFill(e),this.setStroke(e),e.restore()},t.prototype.setFill=function(e){var t=this.srcElement.options.fill,n=!1;return t&&("Gradient"===t.nodeType?(this.setGradientFill(e,t),n=!0):t.nodeType===ta?(this.setPatternFill(e,t),n=!0):ho(t.color)||(e.fillStyle=t.color,e.save(),this.globalAlpha(e,t.opacity),e.fill(),e.restore(),n=!0)),n},t.prototype.setGradientFill=function(e,t){var n,i=this.srcElement.rawBBox();if(t instanceof Rs){var r=t.start(),o=t.end();n=e.createLinearGradient(r.x,r.y,o.x,o.y)}else if(t instanceof Ls){var a=t.center();n=e.createRadialGradient(a.x,a.y,0,a.x,a.y,t.radius())}!function(e,t){for(var n=0;n<t.length;n++){var i=t[n],r=jr(i.color());r.a*=i.opacity(),e.addColorStop(i.offset(),r.toCssRgba())}}(n,t.stops),e.save(),t.userSpace()||e.transform(i.width(),0,0,i.height(),i.origin.x,i.origin.y),e.fillStyle=n,e.fill(),e.restore()},t.prototype.setPatternFill=function(e,t){var n=t.size(),i=document.createElement("canvas"),r=i.getContext("2d");i.width=n.getWidth(),i.height=n.getHeight(),this.childNodes.length=0,this.loadElements(t.children);for(var o=this.childNodes,a=0;a<o.length;a++){o[a].renderTo(r)}e.save(),e.fillStyle=e.createPattern(i,"repeat"),e.fill(),e.restore()},t.prototype.setStroke=function(e){var t=this.srcElement.options.stroke;if(t&&!ho(t.color)&&t.width>0)return e.strokeStyle=t.color,e.lineWidth=bo(t.width,1),e.lineJoin=bo(t.lineJoin,e.lineJoin),e.save(),this.globalAlpha(e,t.opacity),e.stroke(),e.restore(),!0},t.prototype.dashType=function(){var e=this.srcElement.options.stroke;if(e&&e.dashType)return e.dashType.toLowerCase()},t.prototype.setLineDash=function(e){var t=this.dashType();if(t&&t!==Jo){var n=Zo[t];e.setLineDash?e.setLineDash(n):(e.mozDash=n,e.webkitLineDash=n)}},t.prototype.setLineCap=function(e){var t=this.dashType(),n=this.srcElement.options.stroke;t&&t!==Jo?e.lineCap=ea:n&&n.lineCap&&(e.lineCap=n.lineCap)},t.prototype.setLineJoin=function(e){var t=this.srcElement.options.stroke;t&&t.lineJoin&&(e.lineJoin=t.lineJoin)},t.prototype.renderPoints=function(e,t){rc(e,t)},t}(Kl),ac=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.renderPoints=function(e){rc(e,this.srcElement.toPath())},t}(oc),sc=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.renderPoints=function(e){var t=this.srcElement.geometry(),n=t.center,i=t.radius;e.arc(n.x,n.y,i,0,2*Math.PI)},t}(oc),lc=function(e){function t(t,n){e.call(this,t),this.onLoad=this.onLoad.bind(this),this.onError=this.onError.bind(this),this.loading=Xr();var i=this.img=new Image,r=t.src();n&&!/^data:/i.test(r)&&(i.crossOrigin=n),r&&(i.src=r),i.complete?this.onLoad():(i.onload=this.onLoad,i.onerror=this.onError)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.renderTo=function(e){"resolved"===this.loading.state()&&(e.save(),this.setTransform(e),this.setClip(e),this.drawImage(e),e.restore())},t.prototype.optionsChange=function(t){"src"===t.field?(this.loading=Xr(),this.img.src=this.srcElement.src()):e.prototype.optionsChange.call(this,t)},t.prototype.onLoad=function(){this.loading.resolve(),this.invalidate()},t.prototype.onError=function(){this.loading.reject(new Error("Unable to load image '"+this.img.src+"'. Check for connectivity and verify CORS headers."))},t.prototype.drawImage=function(e){var t=this.srcElement.rect(),n=t.topLeft();e.drawImage(this.img,n.x,n.y,t.width(),t.height())},t}(oc),cc=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.renderPoints=function(e){for(var t=this.srcElement.paths,n=0;n<t.length;n++)rc(e,t[n])},t}(oc),dc=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.renderPoints=function(t){var n=this.srcElement.geometry(),i=n.cornerRadius,r=i[0],o=i[1];if(0===r&&0===o){var a=n.origin,s=n.size;t.rect(a.x,a.y,s.width,s.height)}else e.prototype.renderPoints.call(this,t,us.fromRect(n))},t}(oc),uc=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.renderTo=function(e){var t=this.srcElement,n=t.position(),i=t.measure();e.save(),this.setTransform(e),this.setClip(e),this.setOpacity(e),e.beginPath(),e.font=t.options.font,e.textAlign="left","stroke"===t.options.paintOrder?(this.stroke(e,t,n,i),this.fill(e,t,n,i)):(this.fill(e,t,n,i),this.stroke(e,t,n,i)),e.restore()},t.prototype.stroke=function(e,t,n,i){this.setStroke(e)&&(this.setLineDash(e),e.strokeText(t.content(),n.x,n.y+i.baseline))},t.prototype.fill=function(e,t,n,i){this.setFill(e)&&e.fillText(t.content(),n.x,n.y+i.baseline)},t}(oc);Gl.Arc=ac,Gl.Circle=sc,Gl.Group=Yl,Gl.Image=lc,Gl.MultiPath=cc,Gl.Path=oc,Gl.Rect=dc,Gl.Text=uc;var hc,pc,fc=function(e){function t(t,n){e.call(this,t,n),this.element.innerHTML=this._template(this);var i=this.element.firstElementChild;i.style.width="100%",i.style.height="100%";var r=Co(t);i.width=r.width,i.height=r.height,this._rootElement=i,this._root=new Xl(i,r),this._mouseTrackHandler=this._trackMouse.bind(this),yo(this.element,{click:this._mouseTrackHandler,mousemove:this._mouseTrackHandler})}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={type:{configurable:!0}};return n.type.get=function(){return"canvas"},t.prototype.destroy=function(){e.prototype.destroy.call(this),this._root&&(this._root.destroy(),this._root=null),this._searchTree&&(this._searchTree.clear(),delete this._searchTree),this._cursor&&(this._cursor.destroy(),delete this._cursor),So(this.element,{click:this._mouseTrackHandler,mousemove:this._mouseTrackHandler})},t.prototype.draw=function(t){e.prototype.draw.call(this,t),this._root.load([t],void 0,this.options.cors),this._searchTree&&this._searchTree.add([t])},t.prototype.clear=function(){e.prototype.clear.call(this),this._root.clear(),this._searchTree&&this._searchTree.clear(),this._cursor&&this._cursor.clear()},t.prototype.eventTarget=function(e){if(this._searchTree){var t=this._surfacePoint(e);return this._searchTree.pointShape(t)}},t.prototype.image=function(){var e=this._root,t=this._rootElement,n=[];e.traverse((function(e){e.loading&&n.push(e.loading)}));var i=Xr(),r=function(){e._invalidate({fixedScale:!0});try{var n=t.toDataURL();i.resolve(n)}catch(e){i.reject(e)}};return go(n).then(r,r),i},t.prototype.suspendTracking=function(){e.prototype.suspendTracking.call(this),this._searchTree&&(this._searchTree.clear(),delete this._searchTree)},t.prototype.resumeTracking=function(){if(e.prototype.resumeTracking.call(this),!this._searchTree){this._searchTree=new tc;for(var t=this._root.childNodes,n=[],i=0;i<t.length;i++)n.push(t[i].srcElement);this._searchTree.add(n)}},t.prototype._resize=function(){this._rootElement.width=this._size.width,this._rootElement.height=this._size.height,this._root.size=this._size,this._root.invalidate()},t.prototype._template=function(){return"<canvas></canvas>"},t.prototype._enableTracking=function(){this._searchTree=new tc,this._cursor=new ic(this),e.prototype._enableTracking.call(this)},t.prototype._trackMouse=function(e){if(!this._suspendedTracking){var t=this.eventTarget(e);if("click"!==e.type){var n=this._currentShape;n&&n!==t&&this.trigger("mouseleave",{element:n,originalEvent:e,type:"mouseleave"}),t&&n!==t&&this.trigger("mouseenter",{element:t,originalEvent:e,type:"mouseenter"}),this.trigger("mousemove",{element:t,originalEvent:e,type:"mousemove"}),this._currentShape=t}else t&&this.trigger("click",{element:t,originalEvent:e,type:"click"})}},Object.defineProperties(t.prototype,n),t}(al),mc=function(){return"undefined"!=typeof document},gc=function(e){function t(){e.call(this),this._items=[{name:"svg",type:ql},{name:"canvas",type:fc}]}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={support:{configurable:!0},current:{configurable:!0}};return n.support.get=function(){return pc||(pc={canvas:mc()&&document.createElement("canvas").getContext,svg:mc()&&document.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure","1.1")}),pc},n.current.get=function(){return hc||(hc=new t),hc},t.prototype.create=function(e,t){var n=this._items,i=n[0];if(t&&t.type)for(var r=t.type.toLowerCase(),o=0;o<n.length;o++)if(n[o].name===r){i=n[o];break}if(i)return new i.type(e,t);Ar("Warning: Unable to create Kendo UI Drawing Surface. Possible causes:\n- The browser does not support SVG and Canvas. User agent: "+navigator.userAgent)},Object.defineProperties(t,n),t}(fr),vc=function(e){function t(){e.apply(this,arguments)}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={support:{configurable:!0}};return n.support.get=function(){return gc.support},t.create=function(e,t){return gc.current.create(e,t)},Object.defineProperties(t,n),t}(al);function _c(e){var t=new Hl({skipBaseHref:!0}),n=e.clippedBBox(),i=e;if(n){var r=n.getOrigin(),o=new vs;o.transform(Xo().translate(-r.x,-r.y)),o.children.push(e),i=o}t.load([i]);var a="<?xml version='1.0' ?><svg xmlns='"+gl+"' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1'>"+t.render()+"</svg>";return t.destroy(),a}var bc=Object.freeze({__proto__:null,ArcNode:Ll,CircleNode:Bl,ClipNode:zl,DefinitionNode:Pl,GradientStopNode:Dl,GroupNode:Ol,ImageNode:Vl,LinearGradientNode:Ml,MultiPathNode:Nl,Node:Tl,PathNode:Rl,RadialGradientNode:El,RectNode:$l,RootNode:Hl,Surface:ql,TextNode:jl,exportGroup:_c}),yc=Object.freeze({__proto__:null,ArcNode:ac,CircleNode:sc,GroupNode:Yl,ImageNode:lc,MultiPathNode:cc,Node:Kl,PathNode:oc,RectNode:dc,RootNode:Xl,Surface:fc,TextNode:uc});var wc,kc=Object.freeze({__proto__:null,Animation:nl,AnimationFactory:tl,Arc:ps,BaseNode:rl,Circle:ua,Element:na,Gradient:Fs,GradientStop:Hs,Group:vs,HasObservers:Gr,Image:ms,Layout:Cs,LinearGradient:Rs,MultiPath:hs,OptionsStore:$o,Path:us,PathParser:il,Pattern:js,QuadNode:Jl,RadialGradient:Ls,Rect:Ss,ShapesQuadTree:tc,Surface:vc,SurfaceFactory:gc,Text:fs,align:function(e,t,n){Ts(e,t,n,"x","width")},canvas:yc,crosshatchPattern:Ys,diagonalStripesPattern:Qs,dotsPattern:Gs,exportImage:function(e,t){var n={width:"800px",height:"600px",cors:"Anonymous"},i=e,r=e.clippedBBox();if(r){var o=r.getOrigin();(i=new vs).transform(Xo().translate(-o.x,-o.y)),i.children.push(e);var a=r.getSize();n.width=a.width+"px",n.height=a.height+"px"}var s=Object.assign(n,t),l=document.createElement("div"),c=l.style;c.display="none",c.width=s.width,c.height=s.height,document.body.appendChild(l);var d=new fc(l,s);d.suspendTracking(),d.draw(i);var u=d.image(),h=function(){d.destroy(),document.body.removeChild(l)};return u.then(h,h),u},exportSVG:function(e,t){var n=_c(e);return t&&t.raw||(n="data:image/svg+xml;base64,"+lo(n)),Xr().resolve(n)},fit:function(e,t){var n=e.clippedBBox();if(n){var i=n.size,r=t.size;if(r.width<i.width||r.height<i.height){var o=Math.min(r.width/i.width,r.height/i.height),a=e.transform()||Xo();a.scale(o,o),e.transform(a)}}},gridPattern:Xs,parsePath:ss,stack:function(e){Ds(As(e),"x","y","width")},svg:bc,util:Vo,vAlign:function(e,t,n){Ts(e,t,n,"y","height")},vStack:function(e){Ds(As(e),"y","x","height")},vWrap:function(e,t){return Ms(e,t,"y","x","height")},verticalStripesPattern:Ks,wrap:function(e,t){return Ms(e,t,"x","y","width")}}),xc="undefined"!=typeof Uint8Array&&Ir.browser&&(!Ir.browser.msie||Ir.browser.version>9),Cc=(wc="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",{decode:function(e){for(var t=e.replace(/[^A-Za-z0-9\+\/\=]/g,""),n=0,i=t.length,r=[];n<i;){var o=wc.indexOf(t.charAt(n++)),a=wc.indexOf(t.charAt(n++)),s=wc.indexOf(t.charAt(n++)),l=wc.indexOf(t.charAt(n++)),c=o<<2|a>>>4,d=(15&a)<<4|s>>>2,u=(3&s)<<6|l;r.push(c),64!=s&&r.push(d),64!=l&&r.push(u)}return r},encode:function(e){for(var t=0,n=e.length,i="";t<n;){var r=e[t++],o=e[t++],a=e[t++],s=(3&r)<<4|o>>>4,l=(15&o)<<2|a>>>6,c=63&a;t-n==2?l=c=64:t-n==1&&(c=64),i+=wc.charAt(r>>>2)+wc.charAt(s)+wc.charAt(l)+wc.charAt(c)}return i}});function Sc(e){var t=0,n=0;null==e?e=xc?new Uint8Array(256):[]:n=e.length;var i=xc?function(t){if(t>=e.length){var n=new Uint8Array(Math.max(t+256,2*e.length));n.set(e,0),e=n}}:function(){},r=xc?function(){return new Uint8Array(e.buffer,0,n)}:function(){return e},o=xc?function(r){if("string"==typeof r)return g(r);var o=r.length;i(t+o),e.set(r,t),(t+=o)>n&&(n=t)}:function(e){if("string"==typeof e)return g(e);for(var t=0;t<e.length;++t)l(e[t])},a=xc?function(t,n){if(e.buffer.slice)return new Uint8Array(e.buffer.slice(t,t+n));var i=new Uint8Array(n);return i.set(new Uint8Array(e.buffer,t,n)),i}:function(t,n){return e.slice(t,t+n)};function s(){return t<n?e[t++]:0}function l(r){i(t),e[t++]=255&r,t>n&&(n=t)}function c(){return s()<<8|s()}function d(e){l(e>>8),l(e)}function u(){return 65536*c()+c()}function h(e){d(e>>>16&65535),d(65535&e)}function p(){var e=u();return e>=2147483648?e-4294967296:e}function f(e){h(e<0?e+4294967296:e)}function m(e){return v(e,s)}function g(e){for(var t=0;t<e.length;++t)l(e.charCodeAt(t))}function v(e,t){for(var n=new Array(e),i=0;i<e;++i)n[i]=t();return n}var _={eof:function(){return t>=n},readByte:s,writeByte:l,readShort:c,writeShort:d,readLong:u,writeLong:h,readFixed:function(){return u()/65536},writeFixed:function(e){h(Math.round(65536*e))},readShort_:function(){var e=c();return e>=32768?e-65536:e},writeShort_:function(e){d(e<0?e+65536:e)},readLong_:p,writeLong_:f,readFixed_:function(){return p()/65536},writeFixed_:function(e){f(Math.round(65536*e))},read:m,write:o,readString:function(e){return String.fromCharCode.apply(String,m(e))},writeString:g,times:v,get:r,slice:a,offset:function(e){return null!=e?(t=e,_):t},skip:function(e){t+=e},toString:function(){throw new Error("FIX CALLER.  BinaryStream is no longer convertible to string!")},length:function(){return n},saveExcursion:function(e){var n=t;try{return e()}finally{t=n}},writeBase64:function(e){window.atob?g(window.atob(e)):o(Cc.decode(e))},base64:function(){return Cc.encode(r())}};return _}function Tc(e){return window.atob?function(e){for(var t=window.atob(e),n=new Uint8Array(t.length),i=0;i<t.length;i++)n[i]=t.charCodeAt(i);return n}(e):function(e){for(var t=new Uint8Array(e.length),n=0;n<e.length;n++)t[n]=e[n];return t}(Cc.decode(e))}function Dc(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function Ac(e){return Object.keys(e).sort((function(e,t){return e-t})).map(parseFloat)}var Mc=function(e){this.raw=e,this.scalerType=e.readLong(),this.tableCount=e.readShort(),this.searchRange=e.readShort(),this.entrySelector=e.readShort(),this.rangeShift=e.readShort();for(var t=this.tables={},n=0;n<this.tableCount;++n){var i={tag:e.readString(4),checksum:e.readLong(),offset:e.readLong(),length:e.readLong()};t[i.tag]=i}};Mc.prototype.readTable=function(e,t){var n=this.tables[e];if(!n)throw new Error("Table "+e+" not found in directory");return this[e]=n.table=new t(this,n)},Mc.prototype.render=function(e){var t=Object.keys(e).length,n=Math.pow(2,Math.floor(Math.log(t)/Math.LN2)),i=16*n,r=Math.floor(Math.log(n)/Math.LN2),o=16*t-i,a=Sc();a.writeLong(this.scalerType),a.writeShort(t),a.writeShort(i),a.writeShort(r),a.writeShort(o);var s=16*t,l=a.offset()+s,c=null,d=Sc();for(var u in e)if(Dc(e,u)){var h=e[u];for(a.writeString(u),a.writeLong(this.checksum(h)),a.writeLong(l),a.writeLong(h.length),d.write(h),"head"==u&&(c=l),l+=h.length;l%4;)d.writeByte(0),l++}a.write(d.get());var p=2981146554-this.checksum(a.get());return a.offset(c+8),a.writeLong(p),a.get()},Mc.prototype.checksum=function(e){e=Sc(e);for(var t=0;!e.eof();)t+=e.readLong();return 4294967295&t};var Ec=function(e,t){this.definition=t,this.length=t.length,this.offset=t.offset,this.file=e,this.rawData=e.raw,this.parse(e.raw)};Ec.prototype.raw=function(){return this.rawData.slice(this.offset,this.length)},Ec.prototype.parse=function(){};var Ic,zc,Pc,Hc=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parse=function(e){e.offset(this.offset),this.version=e.readLong(),this.revision=e.readLong(),this.checkSumAdjustment=e.readLong(),this.magicNumber=e.readLong(),this.flags=e.readShort(),this.unitsPerEm=e.readShort(),this.created=e.read(8),this.modified=e.read(8),this.xMin=e.readShort_(),this.yMin=e.readShort_(),this.xMax=e.readShort_(),this.yMax=e.readShort_(),this.macStyle=e.readShort(),this.lowestRecPPEM=e.readShort(),this.fontDirectionHint=e.readShort_(),this.indexToLocFormat=e.readShort_(),this.glyphDataFormat=e.readShort_()},t.prototype.render=function(e){var t=Sc();return t.writeLong(this.version),t.writeLong(this.revision),t.writeLong(0),t.writeLong(this.magicNumber),t.writeShort(this.flags),t.writeShort(this.unitsPerEm),t.write(this.created),t.write(this.modified),t.writeShort_(this.xMin),t.writeShort_(this.yMin),t.writeShort_(this.xMax),t.writeShort_(this.yMax),t.writeShort(this.macStyle),t.writeShort(this.lowestRecPPEM),t.writeShort_(this.fontDirectionHint),t.writeShort_(e),t.writeShort_(this.glyphDataFormat),t.get()},t}(Ec),Fc=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parse=function(e){e.offset(this.offset);var t=this.file.head.indexToLocFormat;this.offsets=0===t?e.times(this.length/2,(function(){return 2*e.readShort()})):e.times(this.length/4,e.readLong)},t.prototype.offsetOf=function(e){return this.offsets[e]},t.prototype.lengthOf=function(e){return this.offsets[e+1]-this.offsets[e]},t.prototype.render=function(e){for(var t=Sc(),n=e[e.length-1]>65535,i=0;i<e.length;++i)n?t.writeLong(e[i]):t.writeShort(e[i]/2);return{format:n?1:0,table:t.get()}},t}(Ec),Rc=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parse=function(e){e.offset(this.offset),this.version=e.readLong(),this.ascent=e.readShort_(),this.descent=e.readShort_(),this.lineGap=e.readShort_(),this.advanceWidthMax=e.readShort(),this.minLeftSideBearing=e.readShort_(),this.minRightSideBearing=e.readShort_(),this.xMaxExtent=e.readShort_(),this.caretSlopeRise=e.readShort_(),this.caretSlopeRun=e.readShort_(),this.caretOffset=e.readShort_(),e.skip(8),this.metricDataFormat=e.readShort_(),this.numOfLongHorMetrics=e.readShort()},t.prototype.render=function(e){var t=Sc();return t.writeLong(this.version),t.writeShort_(this.ascent),t.writeShort_(this.descent),t.writeShort_(this.lineGap),t.writeShort(this.advanceWidthMax),t.writeShort_(this.minLeftSideBearing),t.writeShort_(this.minRightSideBearing),t.writeShort_(this.xMaxExtent),t.writeShort_(this.caretSlopeRise),t.writeShort_(this.caretSlopeRun),t.writeShort_(this.caretOffset),t.write([0,0,0,0,0,0,0,0]),t.writeShort_(this.metricDataFormat),t.writeShort(e.length),t.get()},t}(Ec),Lc=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parse=function(e){e.offset(this.offset),this.version=e.readLong(),this.numGlyphs=e.readShort(),this.maxPoints=e.readShort(),this.maxContours=e.readShort(),this.maxComponentPoints=e.readShort(),this.maxComponentContours=e.readShort(),this.maxZones=e.readShort(),this.maxTwilightPoints=e.readShort(),this.maxStorage=e.readShort(),this.maxFunctionDefs=e.readShort(),this.maxInstructionDefs=e.readShort(),this.maxStackElements=e.readShort(),this.maxSizeOfInstructions=e.readShort(),this.maxComponentElements=e.readShort(),this.maxComponentDepth=e.readShort()},t.prototype.render=function(e){var t=Sc();return t.writeLong(this.version),t.writeShort(e.length),t.writeShort(this.maxPoints),t.writeShort(this.maxContours),t.writeShort(this.maxComponentPoints),t.writeShort(this.maxComponentContours),t.writeShort(this.maxZones),t.writeShort(this.maxTwilightPoints),t.writeShort(this.maxStorage),t.writeShort(this.maxFunctionDefs),t.writeShort(this.maxInstructionDefs),t.writeShort(this.maxStackElements),t.writeShort(this.maxSizeOfInstructions),t.writeShort(this.maxComponentElements),t.writeShort(this.maxComponentDepth),t.get()},t}(Ec),Bc=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parse=function(e){e.offset(this.offset);var t=this.file,n=t.hhea;this.metrics=e.times(n.numOfLongHorMetrics,(function(){return{advance:e.readShort(),lsb:e.readShort_()}}));var i=t.maxp.numGlyphs-t.hhea.numOfLongHorMetrics;this.leftSideBearings=e.times(i,e.readShort_)},t.prototype.forGlyph=function(e){var t=this.metrics,n=t.length;return e<n?t[e]:{advance:t[n-1].advance,lsb:this.leftSideBearings[e-n]}},t.prototype.render=function(e){for(var t=Sc(),n=0;n<e.length;++n){var i=this.forGlyph(e[n]);t.writeShort(i.advance),t.writeShort_(i.lsb)}return t.get()},t}(Ec),Oc=function(){var e=function(e){this.raw=e},t={compound:{configurable:!0}};t.compound.get=function(){return!1},e.prototype.render=function(){return this.raw.get()},Object.defineProperties(e.prototype,t);var n=function(e){this.raw=e;for(var t=this.glyphIds=[],n=this.idOffsets=[];;){var i=e.readShort();if(n.push(e.offset()),t.push(e.readShort()),!(32&i))break;e.skip(1&i?4:2),128&i?e.skip(8):64&i?e.skip(4):8&i&&e.skip(2)}},i={compound:{configurable:!0}};return i.compound.get=function(){return!0},n.prototype.render=function(e){for(var t=Sc(this.raw.get()),n=0;n<this.glyphIds.length;++n){var i=this.glyphIds[n];t.offset(this.idOffsets[n]),t.writeShort(e[i])}return t.get()},Object.defineProperties(n.prototype,i),function(t){function i(){t.apply(this,arguments)}return t&&(i.__proto__=t),i.prototype=Object.create(t&&t.prototype),i.prototype.constructor=i,i.prototype.parse=function(){this.cache={}},i.prototype.glyphFor=function(t){var i=this.cache;if(Dc(i,t))return i[t];var r=this.file.loca,o=r.lengthOf(t);if(0===o)return i[t]=null;var a=this.rawData,s=this.offset+r.offsetOf(t),l=Sc(a.slice(s,o)),c=l.readShort_(),d=l.readShort_(),u=l.readShort_(),h=l.readShort_(),p=l.readShort_(),f=i[t]=c<0?new n(l):new e(l);return f.numberOfContours=c,f.xMin=d,f.yMin=u,f.xMax=h,f.yMax=p,f},i.prototype.render=function(e,t,n){for(var i=Sc(),r=[],o=0;o<t.length;++o){var a=e[t[o]];i.offset()%2&&i.writeByte(0),r.push(i.offset()),a&&i.write(a.render(n))}return i.offset()%2&&i.writeByte(0),r.push(i.offset()),{table:i.get(),offsets:r}},i}(Ec)}(),Vc=(Ic=function(e,t){this.text=e,this.length=e.length,this.platformID=t.platformID,this.platformSpecificID=t.platformSpecificID,this.languageID=t.languageID,this.nameID=t.nameID},function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parse=function(e){e.offset(this.offset),e.readShort();for(var t=e.readShort(),n=this.offset+e.readShort(),i=e.times(t,(function(){return{platformID:e.readShort(),platformSpecificID:e.readShort(),languageID:e.readShort(),nameID:e.readShort(),length:e.readShort(),offset:e.readShort()+n}})),r=this.strings={},o=0;o<i.length;++o){var a=i[o];e.offset(a.offset);var s=e.readString(a.length);r[a.nameID]||(r[a.nameID]=[]),r[a.nameID].push(new Ic(s,a))}this.postscriptEntry=r[6][0],this.postscriptName=this.postscriptEntry.text.replace(/[^\x20-\x7F]/g,"")},t.prototype.render=function(e){var t=this.strings,n=0;for(var i in t)Dc(t,i)&&(n+=t[i].length);var r=Sc(),o=Sc();for(i in r.writeShort(0),r.writeShort(n),r.writeShort(6+12*n),t)if(Dc(t,i))for(var a=6==i?[new Ic(e,this.postscriptEntry)]:t[i],s=0;s<a.length;++s){var l=a[s];r.writeShort(l.platformID),r.writeShort(l.platformSpecificID),r.writeShort(l.languageID),r.writeShort(l.nameID),r.writeShort(l.length),r.writeShort(o.offset()),o.writeString(l.text)}return r.write(o.get()),r.get()},t}(Ec)),Nc=(zc=".notdef .null nonmarkingreturn space exclam quotedbl numbersign dollar percent ampersand quotesingle parenleft parenright asterisk plus comma hyphen period slash zero one two three four five six seven eight nine colon semicolon less equal greater question at A B C D E F G H I J K L M N O P Q R S T U V W X Y Z bracketleft backslash bracketright asciicircum underscore grave a b c d e f g h i j k l m n o p q r s t u v w x y z braceleft bar braceright asciitilde Adieresis Aring Ccedilla Eacute Ntilde Odieresis Udieresis aacute agrave acircumflex adieresis atilde aring ccedilla eacute egrave ecircumflex edieresis iacute igrave icircumflex idieresis ntilde oacute ograve ocircumflex odieresis otilde uacute ugrave ucircumflex udieresis dagger degree cent sterling section bullet paragraph germandbls registered copyright trademark acute dieresis notequal AE Oslash infinity plusminus lessequal greaterequal yen mu partialdiff summation product pi integral ordfeminine ordmasculine Omega ae oslash questiondown exclamdown logicalnot radical florin approxequal Delta guillemotleft guillemotright ellipsis nonbreakingspace Agrave Atilde Otilde OE oe endash emdash quotedblleft quotedblright quoteleft quoteright divide lozenge ydieresis Ydieresis fraction currency guilsinglleft guilsinglright fi fl daggerdbl periodcentered quotesinglbase quotedblbase perthousand Acircumflex Ecircumflex Aacute Edieresis Egrave Iacute Icircumflex Idieresis Igrave Oacute Ocircumflex apple Ograve Uacute Ucircumflex Ugrave dotlessi circumflex tilde macron breve dotaccent ring cedilla hungarumlaut ogonek caron Lslash lslash Scaron scaron Zcaron zcaron brokenbar Eth eth Yacute yacute Thorn thorn minus multiply onesuperior twosuperior threesuperior onehalf onequarter threequarters franc Gbreve gbreve Idotaccent Scedilla scedilla Cacute cacute Ccaron ccaron dcroat".split(/\s+/g),function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parse=function(e){var t;switch(e.offset(this.offset),this.format=e.readLong(),this.italicAngle=e.readFixed_(),this.underlinePosition=e.readShort_(),this.underlineThickness=e.readShort_(),this.isFixedPitch=e.readLong(),this.minMemType42=e.readLong(),this.maxMemType42=e.readLong(),this.minMemType1=e.readLong(),this.maxMemType1=e.readLong(),this.format){case 65536:case 196608:break;case 131072:t=e.readShort(),this.glyphNameIndex=e.times(t,e.readShort),this.names=[];for(var n=this.offset+this.length;e.offset()<n;)this.names.push(e.readString(e.readByte()));break;case 151552:t=e.readShort(),this.offsets=e.read(t);break;case 262144:this.map=e.times(this.file.maxp.numGlyphs,e.readShort)}},t.prototype.glyphFor=function(e){switch(this.format){case 65536:return zc[e]||".notdef";case 131072:var t=this.glyphNameIndex[e];return t<zc.length?zc[t]:this.names[t-zc.length]||".notdef";case 151552:case 196608:return".notdef";case 262144:return this.map[e]||65535}},t.prototype.render=function(e){if(196608==this.format)return this.raw();var t=Sc(this.rawData.slice(this.offset,32));t.writeLong(131072),t.offset(32);for(var n=[],i=[],r=0;r<e.length;++r){var o=e[r],a=this.glyphFor(o),s=zc.indexOf(a);s>=0?n.push(s):(n.push(zc.length+i.length),i.push(a))}for(t.writeShort(e.length),r=0;r<n.length;++r)t.writeShort(n[r]);for(r=0;r<i.length;++r)t.writeByte(i[r].length),t.writeString(i[r]);return t.get()},t}(Ec)),$c=(Pc=function(e,t,n){var i=this;i.platformID=e.readShort(),i.platformSpecificID=e.readShort(),i.offset=t+e.readLong(),e.saveExcursion((function(){var t;switch(e.offset(i.offset),i.format=e.readShort(),i.format){case 0:i.length=e.readShort(),i.language=e.readShort();for(var r=0;r<256;++r)n[r]=e.readByte();break;case 4:i.length=e.readShort(),i.language=e.readShort();var o=e.readShort()/2;e.skip(6);var a=e.times(o,e.readShort);e.skip(2);var s=e.times(o,e.readShort),l=e.times(o,e.readShort_),c=e.times(o,e.readShort),d=(i.length+i.offset-e.offset())/2,u=e.times(d,e.readShort);for(r=0;r<o;++r){var h=s[r],p=a[r];for(t=h;t<=p;++t){var f;0===c[r]?f=t+l[r]:0!==(f=u[c[r]/2-(o-r)+(t-h)]||0)&&(f+=l[r]),n[t]=65535&f}}break;case 6:i.length=e.readShort(),i.language=e.readShort(),t=e.readShort();for(var m=e.readShort();m-- >0;)n[t++]=e.readShort();break;case 12:e.readShort(),i.length=e.readLong(),i.language=e.readLong();for(var g=e.readLong();g-- >0;){t=e.readLong();for(var v=e.readLong(),_=e.readLong();t<=v;)n[t++]=_++}break;default:window.console&&window.console.error("Unhandled CMAP format: "+i.format)}}))},function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parse=function(e){var t=this,n=t.offset;e.offset(n),t.codeMap={},t.version=e.readShort();var i=e.readShort();t.tables=e.times(i,(function(){return new Pc(e,n,t.codeMap)}))},t.render=function(e,t){var n=Sc();return n.writeShort(0),n.writeShort(1),n.write(function(e,t){var n=Ac(e),i=[],r=[],o=null,a=null;function s(n){return t[e[n]]}for(var l=0;l<n.length;++l){var c=n[l],d=s(c)-c;null!=o&&d===a||(o&&r.push(o),i.push(c),a=d),o=c}o&&r.push(o),r.push(65535),i.push(65535);var u=i.length,h=2*u,p=2*Math.pow(2,Math.floor(Math.log(u)/Math.LN2)),f=Math.log(p/2)/Math.LN2,m=h-p,g=[],v=[],_=[];for(l=0;l<u;++l){var b=i[l],y=r[l];if(65535==b){g.push(0),v.push(0);break}var w=s(b);if(b-w>=32768){g.push(0),v.push(2*(_.length+u-l));for(var k=b;k<=y;++k)_.push(s(k))}else g.push(w-b),v.push(0)}var x=Sc();return x.writeShort(3),x.writeShort(1),x.writeLong(12),x.writeShort(4),x.writeShort(16+8*u+2*_.length),x.writeShort(0),x.writeShort(h),x.writeShort(p),x.writeShort(f),x.writeShort(m),r.forEach(x.writeShort),x.writeShort(0),i.forEach(x.writeShort),g.forEach(x.writeShort_),v.forEach(x.writeShort),_.forEach(x.writeShort),x.get()}(e,t)),n.get()},t}(Ec)),Uc=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parse=function(e){e.offset(this.offset),this.version=e.readShort(),this.averageCharWidth=e.readShort_(),this.weightClass=e.readShort(),this.widthClass=e.readShort(),this.type=e.readShort(),this.ySubscriptXSize=e.readShort_(),this.ySubscriptYSize=e.readShort_(),this.ySubscriptXOffset=e.readShort_(),this.ySubscriptYOffset=e.readShort_(),this.ySuperscriptXSize=e.readShort_(),this.ySuperscriptYSize=e.readShort_(),this.ySuperscriptXOffset=e.readShort_(),this.ySuperscriptYOffset=e.readShort_(),this.yStrikeoutSize=e.readShort_(),this.yStrikeoutPosition=e.readShort_(),this.familyClass=e.readShort_(),this.panose=e.times(10,e.readByte),this.charRange=e.times(4,e.readLong),this.vendorID=e.readString(4),this.selection=e.readShort(),this.firstCharIndex=e.readShort(),this.lastCharIndex=e.readShort(),this.version>0&&(this.ascent=e.readShort_(),this.descent=e.readShort_(),this.lineGap=e.readShort_(),this.winAscent=e.readShort(),this.winDescent=e.readShort(),this.codePageRange=e.times(2,e.readLong),this.version>1&&(this.xHeight=e.readShort(),this.capHeight=e.readShort(),this.defaultChar=e.readShort(),this.breakChar=e.readShort(),this.maxContext=e.readShort()))},t.prototype.render=function(){return this.raw()},t}(Ec),Wc=1e5;var jc=function(e){this.font=e,this.subset={},this.unicodes={},this.ogid2ngid={0:0},this.ngid2ogid={0:0},this.ncid2ogid={},this.next=this.firstChar=1,this.nextGid=1,this.psName=function(){for(var e="",t=String(Wc),n=0;n<t.length;++n)e+=String.fromCharCode(t.charCodeAt(n)-48+65);return++Wc,e}()+"+"+this.font.psName};jc.prototype.use=function(e){var t=this;if("string"==typeof e)return function(e){for(var t,n,i=[],r=0,o=e.length;r<o;)(t=e.charCodeAt(r++))>=55296&&t<=56319&&r<o?56320==(64512&(n=e.charCodeAt(r++)))?i.push(((1023&t)<<10)+(1023&n)+65536):(i.push(t),r--):i.push(t);return i}(e).reduce((function(e,n){return e+String.fromCharCode(t.use(n))}),"");var n=t.unicodes[e];if(!n){n=t.next++,t.subset[n]=e,t.unicodes[e]=n;var i=t.font.cmap.codeMap[e];if(i&&(t.ncid2ogid[n]=i,null==t.ogid2ngid[i])){var r=t.nextGid++;t.ogid2ngid[i]=r,t.ngid2ogid[r]=i}}return n},jc.prototype.encodeText=function(e){return this.use(e)},jc.prototype.glyphIds=function(){return Ac(this.ogid2ngid)},jc.prototype.glyphsFor=function(e,t){t||(t={});for(var n=0;n<e.length;++n){var i=e[n];if(!t[i]){var r=t[i]=this.font.glyf.glyphFor(i);r&&r.compound&&this.glyphsFor(r.glyphIds,t)}}return t},jc.prototype.render=function(){var e=this,t=this.glyphsFor(this.glyphIds());for(var n in t)if(Dc(t,n)&&(n=parseInt(n,10),null==e.ogid2ngid[n])){var i=e.nextGid++;e.ogid2ngid[n]=i,e.ngid2ogid[i]=n}var r=Ac(this.ngid2ogid).map((function(e){return this.ngid2ogid[e]}),this),o=this.font,a=o.glyf.render(t,r,this.ogid2ngid),s=o.loca.render(a.offsets);this.lastChar=this.next-1;var l={cmap:$c.render(this.ncid2ogid,this.ogid2ngid),glyf:a.table,loca:s.table,hmtx:o.hmtx.render(r),hhea:o.hhea.render(r),maxp:o.maxp.render(r),post:o.post.render(r),name:o.name.render(this.psName),head:o.head.render(s.format),"OS/2":o.os2.render()};return this.font.directory.render(l)},jc.prototype.cidToGidMap=function(){for(var e=Sc(),t=0,n=this.firstChar;n<this.next;++n){for(;t<n;)e.writeShort(0),t++;var i=this.ncid2ogid[n];if(i){var r=this.ogid2ngid[i];e.writeShort(r)}else e.writeShort(0);t++}return e.get()};var qc=function(e,t){var n=this,i=n.contents=Sc(e);if("ttcf"==i.readString(4)){var r,o=function(){i.offset(r),n.parse()};if(!t)throw new Error("Must specify a name for TTC files");i.readLong();for(var a=i.readLong(),s=0;s<a;++s)if(r=i.readLong(),i.saveExcursion(o),n.psName==t)return;throw new Error("Font "+t+" not found in collection")}i.offset(0),n.parse()};qc.prototype.parse=function(){var e=this.directory=new Mc(this.contents);this.head=e.readTable("head",Hc),this.loca=e.readTable("loca",Fc),this.hhea=e.readTable("hhea",Rc),this.maxp=e.readTable("maxp",Lc),this.hmtx=e.readTable("hmtx",Bc),this.glyf=e.readTable("glyf",Oc),this.name=e.readTable("name",Vc),this.post=e.readTable("post",Nc),this.cmap=e.readTable("cmap",$c),this.os2=e.readTable("OS/2",Uc),this.psName=this.name.postscriptName,this.ascent=this.os2.ascent||this.hhea.ascent,this.descent=this.os2.descent||this.hhea.descent,this.lineGap=this.os2.lineGap||this.hhea.lineGap,this.scale=1e3/this.head.unitsPerEm},qc.prototype.widthOfGlyph=function(e){return this.hmtx.forGlyph(e).advance*this.scale},qc.prototype.makeSubset=function(){return new jc(this)};var Gc=bt;var Kc=Ir.browser,Yc="\n",Qc=0,Xc={a0:[2383.94,3370.39],a1:[1683.78,2383.94],a2:[1190.55,1683.78],a3:[841.89,1190.55],a4:[595.28,841.89],a5:[419.53,595.28],a6:[297.64,419.53],a7:[209.76,297.64],a8:[147.4,209.76],a9:[104.88,147.4],a10:[73.7,104.88],b0:[2834.65,4008.19],b1:[2004.09,2834.65],b2:[1417.32,2004.09],b3:[1000.63,1417.32],b4:[708.66,1000.63],b5:[498.9,708.66],b6:[354.33,498.9],b7:[249.45,354.33],b8:[175.75,249.45],b9:[124.72,175.75],b10:[87.87,124.72],c0:[2599.37,3676.54],c1:[1836.85,2599.37],c2:[1298.27,1836.85],c3:[918.43,1298.27],c4:[649.13,918.43],c5:[459.21,649.13],c6:[323.15,459.21],c7:[229.61,323.15],c8:[161.57,229.61],c9:[113.39,161.57],c10:[79.37,113.39],executive:[521.86,756],folio:[612,936],legal:[612,1008],letter:[612,792],tabloid:[792,1224]};function Zc(){var e=0,t=Sc();function n(){for(var e=arguments,i=0;i<arguments.length;++i){var r=e[i];if(void 0===r)throw new Error("Cannot output undefined to PDF");if(r instanceof vd)r.beforeRender(n),r.render(n);else if(dd(r))ud(r,n);else if(r instanceof Date)hd(r,n);else if("number"==typeof r){if(isNaN(r))throw new Error("Cannot output NaN to PDF");var o=r.toFixed(7);o.indexOf(".")>=0&&(o=o.replace(/\.?0+$/,"")),"-0"==o&&(o="0"),t.writeString(o)}else/string|boolean/.test(typeof r)?t.writeString(String(r)):"function"==typeof r.get?t.write(r.get()):"object"==typeof r&&(r?n(new kd(r)):t.writeString("null"))}}return n.writeData=function(e){t.write(e)},n.withIndent=function(t){++e,t(n),--e},n.indent=function(){n(Yc,sd("",2*e,"  ")),n.apply(null,arguments)},n.offset=function(){return t.offset()},n.toString=function(){throw new Error("FIX CALLER")},n.get=function(){return t.get()},n.stream=function(){return t},n}function Jc(e){if("function"!=typeof e){var t=e;e=function(e,n){return e in t?t[e]:n}}var n=e("paperSize",Xc.a4);if(!n)return{};if("string"==typeof n&&null==(n=Xc[n.toLowerCase()]))throw new Error("Unknown paper size");n[0]=gd(n[0]),n[1]=gd(n[1]),e("landscape",!1)&&(n=[Math.max(n[0],n[1]),Math.min(n[0],n[1])]);var i=e("margin");return i&&(i="string"==typeof i||"number"==typeof i?{left:i=gd(i,0),top:i,right:i,bottom:i}:{left:gd(i.left,0),top:gd(i.top,0),right:gd(i.right,0),bottom:gd(i.bottom,0)},e("addMargin")&&(n[0]+=i.left+i.right,n[1]+=i.top+i.bottom)),{paperSize:n,margin:i}}var ed={"Times-Roman":!0,"Times-Bold":!0,"Times-Italic":!0,"Times-BoldItalic":!0,Helvetica:!0,"Helvetica-Bold":!0,"Helvetica-Oblique":!0,"Helvetica-BoldOblique":!0,Courier:!0,"Courier-Bold":!0,"Courier-Oblique":!0,"Courier-BoldOblique":!0,Symbol:!0,ZapfDingbats:!0};var td={};function nd(){td={}}var id,rd=(id=function(e,t){var n=ed[e];n?t(n):function(e,t){var n;if(Kc.msie&&(n=/^data:.*?;base64,/i.exec(e)))t(Tc(e.substr(n[0].length)));else{var i=new XMLHttpRequest;i.open("GET",e,!0),xc&&(i.responseType="arraybuffer"),i.onload=function(){200==i.status||304==i.status?t(xc?new Uint8Array(i.response):new window.VBArray(i.responseBody).toArray()):r()},i.onerror=r,i.send(null)}function r(){window.console&&(window.console.error?window.console.error("Cannot load URL: %s",e):window.console.log("Cannot load URL: %s",e)),t(null)}}(e,(function(n){if(null==n)throw new Error("Cannot load font from "+e);var i=new qc(n);ed[e]=i,t(i)}))},function(e,t){var n=e.length,i=n;if(0===n)return t();function r(){0==--n&&t()}for(;i-- >0;)id(e[i],r)}),od=function(e,t,n){n=Object.assign({jpegQuality:.92,keepPNG:!1},n);var i=Object.keys(e),r=i.length;if(0===r)return t();function o(){0==--r&&t()}i.forEach((function(t){!function(e,t,n,i){var r,o,a=td[e];if(a)n(a);else if(a=new Image,/^data:/i.test(e)||(a.crossOrigin="Anonymous"),xc&&!/^data:/i.test(e)){var s=new XMLHttpRequest;s.onload=function(){if(o=s.response,Kc.mozilla&&"image/svg+xml"==o.type){var e=new FileReader;e.onload=function(){var e=(new window.DOMParser).parseFromString(this.result,"image/svg+xml").documentElement;e.getAttribute("width")&&e.getAttribute("height")?l(r=URL.createObjectURL(o)):(e.setAttribute("width",t.width),e.setAttribute("height",t.height),l("data:image/svg+xml;base64,"+lo((new window.XMLSerializer).serializeToString(e))))},e.readAsText(o)}else l(r=URL.createObjectURL(o))},s.onerror=d,s.open("GET",e,!0),s.responseType="blob",s.send()}else l(e);function l(e){a.src=e,a.complete&&!Kc.msie?u.call(a):(a.onload=u,a.onerror=d)}function c(){t||(t={width:a.width,height:a.height});var o=document.createElement("canvas");o.width=t.width,o.height=t.height;var s,l=o.getContext("2d");l.drawImage(a,0,0,t.width,t.height);try{s=l.getImageData(0,0,t.width,t.height)}catch(e){return void d()}finally{r&&URL.revokeObjectURL(r)}for(var c=!1,u=Sc(),h=Sc(),p=s.data,f=0;f<p.length;){u.writeByte(p[f++]),u.writeByte(p[f++]),u.writeByte(p[f++]);var m=p[f++];m<255&&(c=!0),h.writeByte(m)}if(c||i.keepPNG)a=new Ad(t.width,t.height,u,h);else{var g=o.toDataURL("image/jpeg",i.jpegQuality);g=g.substr(g.indexOf(";base64,")+8);var v=Sc();v.writeBase64(g),a=new Dd(v)}n(td[e]=a)}function d(){n(td[e]="ERROR")}function u(){if(t){var i=o&&"image/svg+xml"===o.type||/^data:image\/svg\+xml;/i.test(this.src.substring(0,19)),s=t.width>=a.width||t.height>=a.height;!i&&s&&(t=null)}if(!t&&o&&/^image\/jpe?g$/i.test(o.type)){var l=new FileReader;l.onload=function(){try{var t=new Dd(Sc(new Uint8Array(this.result)));URL.revokeObjectURL(r),n(td[e]=t)}catch(e){c()}},l.readAsArrayBuffer(o)}else c()}}(t,e[t],o,n)}))},ad=function(e){var t=this,n=Zc(),i=0,r=[];function o(t,n){return e&&null!=e[t]?e[t]:n}t.getOption=o,t.attach=function(e){return r.indexOf(e)<0&&(!function(e,t){var n=e.beforeRender,i=e.render;e.beforeRender=function(){},e.render=function(e){e(t," 0 R")},e.renderFull=function(r){e._offset=r.offset(),r(t," 0 obj "),n.call(e,r),i.call(e,r),r(" endobj")}}(e,++i),r.push(e)),e},t.pages=[],t.FONTS={},t.IMAGES={},t.GRAD_COL_FUNCTIONS={},t.GRAD_OPC_FUNCTIONS={},t.GRAD_COL={},t.GRAD_OPC={};var a=t.attach(new Cd),s=t.attach(new Sd);if(o("autoPrint")){var l={};l.JavaScript=new kd({Names:[new _d("JS"),t.attach(new kd({S:wd("JavaScript"),JS:new _d("print(true);")}))]}),a.props.Names=new kd(l)}a.setPages(s);var c=t.attach(new kd({Producer:new _d(o("producer","Kendo UI PDF Generator"),!0),Title:new _d(o("title",""),!0),Author:new _d(o("author",""),!0),Subject:new _d(o("subject",""),!0),Keywords:new _d(o("keywords",""),!0),Creator:new _d(o("creator","Kendo UI PDF Generator"),!0),CreationDate:o("date",new Date)}));t.addPage=function(e){var n=Jc((function(t,n){return e&&null!=e[t]?e[t]:n})),i=n.paperSize,r=n.margin,o=i[0],a=i[1];r&&(o-=r.left+r.right,a-=r.top+r.bottom);var l=new xd(Zc(),null,!0),c={Contents:t.attach(l),Parent:s,MediaBox:[0,0,i[0],i[1]]},d=new Rd(t,c);return d._content=l,s.addPage(t.attach(d)),d.transform(1,0,0,-1,0,i[1]),r&&(d.translate(r.left,r.top),d.rect(0,0,o,a),d.clip()),t.pages.push(d),d},t.render=function(){var e;for(n("%PDF-1.4",Yc,"%ÂÁÚÏÎ",Yc,Yc),e=0;e<r.length;++e)r[e].renderFull(n),n(Yc,Yc);var t=n.offset();for(n("xref",Yc,0," ",r.length+1,Yc),n("0000000000 65535 f ",Yc),e=0;e<r.length;++e)n(ld(r[e]._offset,10)," 00000 n ",Yc);return n(Yc),n("trailer",Yc),n(new kd({Size:r.length+1,Root:a,Info:c}),Yc,Yc),n("startxref",Yc,t,Yc),n("%%EOF",Yc),n.stream().offset(0)},t.loadFonts=rd,t.loadImages=od};function sd(e,t,n){for(;e.length<t;)e=n+e;return e}function ld(e,t){return sd(String(e),t,"0")}function cd(e,t){return Object.prototype.hasOwnProperty.call(e,t)}ad.prototype.getFont=function(e){var t=this.FONTS[e];if(!t){if(!(t=ed[e]))throw new Error("Font "+e+" has not been loaded");t=!0===t?this.attach(new Md(e)):this.attach(new Ed(this,t)),this.FONTS[e]=t}return t},ad.prototype.getImage=function(e){var t=this.IMAGES[e];if(!t){if(!(t=td[e]))throw new Error("Image "+e+" has not been loaded");if("ERROR"===t)return null;t=this.IMAGES[e]=this.attach(t.asStream(this))}return t},ad.prototype.getOpacityGS=function(e,t){var n=parseFloat(e).toFixed(3);e=parseFloat(n),n+=t?"S":"F";var i=this._opacityGSCache||(this._opacityGSCache={}),r=i[n];if(!r){var o={Type:wd("ExtGState")};t?o.CA=e:o.ca=e,(r=this.attach(new kd(o)))._resourceName=wd("GS"+ ++Qc),i[n]=r}return r},ad.prototype.dict=function(e){return new kd(e)},ad.prototype.name=function(e){return wd(e)},ad.prototype.stream=function(e,t){return new xd(t,e)};var dd=Array.isArray||function(e){return e instanceof Array};function ud(e,t){t("["),e.length>0&&t.withIndent((function(){for(var n=0;n<e.length;++n)n>0&&n%8==0?t.indent(e[n]):t(" ",e[n])})),t(" ]")}function hd(e,t){t("(D:",ld(e.getUTCFullYear(),4),ld(e.getUTCMonth()+1,2),ld(e.getUTCDate(),2),ld(e.getUTCHours(),2),ld(e.getUTCMinutes(),2),ld(e.getUTCSeconds(),2),"Z)")}function pd(e){return e*(72/25.4)}function fd(e){return pd(10*e)}function md(e){return 72*e}function gd(e,t){if("number"==typeof e)return e;var n;if("string"==typeof e&&(n=/^\s*([0-9.]+)\s*(mm|cm|in|pt)\s*$/.exec(e))){var i=parseFloat(n[1]);if(!isNaN(i))return"pt"==n[2]?i:{mm:pd,cm:fd,in:md}[n[2]](i)}if(null!=t)return t;throw new Error("Can't parse unit: "+e)}var vd=function(){};vd.prototype.beforeRender=function(){};var _d=function(e){function t(t,n){e.call(this),this.value=t,this.utf16be=Boolean(n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(e){var t=this.value;if(this.utf16be)t="þÿ"+function(e){for(var t="",n=0;n<e.length;n++){var i=e.charCodeAt(n);if(i<65535)t+=ao(i);else{var r=56320+(i-65536&1023);t+=ao(55296+(i-65536>>10)),t+=ao(r)}}return t}(t),e("(",t=t.replace(/([\(\)\\])/g,"\\$1"),")");else{for(var n=[40],i=0;i<t.length;++i){var r=255&t.charCodeAt(i);40!=r&&41!=r&&92!=r||n.push(92),n.push(r)}n.push(41),e.writeData(n)}},t.prototype.toString=function(){return this.value},t}(vd),bd=function(e){function t(t){e.call(this,t),this.value=t}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(e){e("<");for(var t=0;t<this.value.length;++t)e(ld(this.value.charCodeAt(t).toString(16),4));e(">")},t}(_d),yd=function(e){function t(t){e.call(this),this.name=t}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.get=function(e){return wd(e)},t.prototype.render=function(e){e("/"+this.escape())},t.prototype.escape=function(){return this.name.replace(/[^\x21-\x7E]/g,(function(e){return"#"+ld(e.charCodeAt(0).toString(16),2)}))},t.prototype.toString=function(){return this.name},t}(vd);function wd(e){return new yd(e)}var kd=function(e){function t(t){e.call(this),this.props=t}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(e){var t=this.props,n=!0;e("<<"),e.withIndent((function(){for(var i in t)cd(t,i)&&!/^_/.test(i)&&(n=!1,e.indent(wd(i)," ",t[i]))})),n||e.indent(),e(">>")},t}(vd),xd=function(e){function t(t,n,i){if(e.call(this),"string"==typeof t){var r=Sc();r.write(t),t=r}this.data=t,this.props=n||{},this.compress=i}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(e){var t=this.data.get(),n=this.props;this.compress&&(n.Filter?n.Filter instanceof Array||(n.Filter=[n.Filter]):n.Filter=[],n.Filter.unshift(wd("FlateDecode")),t=Gc(t)),n.Length=t.length,e(new kd(n)," stream",Yc),e.writeData(t),e(Yc,"endstream")},t}(vd),Cd=function(e){function t(){e.call(this,{Type:wd("Catalog")})}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setPages=function(e){this.props.Pages=e},t}(kd),Sd=function(e){function t(){e.call(this,{Type:wd("Pages"),Kids:[],Count:0})}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.addPage=function(e){this.props.Kids.push(e),this.props.Count++},t}(kd),Td=[192,193,194,195,197,198,199,201,202,203,205,206,207],Dd=function(e){var t,n,i,r;if(e.offset(0),65496!=e.readShort())throw new Error("Invalid JPEG image");for(;!e.eof();){if(255!=e.readByte())throw new Error("Invalid JPEG image");var o=e.readByte(),a=e.readShort();if(Td.indexOf(o)>=0){r=e.readByte(),n=e.readShort(),t=e.readShort(),i=e.readByte();break}e.skip(a-2)}if(null==i)throw new Error("Invalid JPEG image");var s={Type:wd("XObject"),Subtype:wd("Image"),Width:t,Height:n,BitsPerComponent:r,Filter:wd("DCTDecode")};switch(i){case 1:s.ColorSpace=wd("DeviceGray");break;case 3:s.ColorSpace=wd("DeviceRGB");break;case 4:s.ColorSpace=wd("DeviceCMYK"),s.Decode=[1,0,1,0,1,0,1,0]}this.asStream=function(){e.offset(0);var t=new xd(e,s);return t._resourceName=wd("I"+ ++Qc),t}},Ad=function(e,t,n,i){this.asStream=function(r){var o=new xd(i,{Type:wd("XObject"),Subtype:wd("Image"),Width:e,Height:t,BitsPerComponent:8,ColorSpace:wd("DeviceGray")},!0),a=new xd(n,{Type:wd("XObject"),Subtype:wd("Image"),Width:e,Height:t,BitsPerComponent:8,ColorSpace:wd("DeviceRGB"),SMask:r.attach(o)},!0);return a._resourceName=wd("I"+ ++Qc),a}},Md=function(e){function t(t){e.call(this,{Type:wd("Font"),Subtype:wd("Type1"),BaseFont:wd(t)}),this._resourceName=wd("F"+ ++Qc)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.encodeText=function(e){return new _d(String(e))},t}(kd),Ed=function(e){function t(t,n,i){e.call(this,{}),(i=this.props).Type=wd("Font"),i.Subtype=wd("Type0"),i.Encoding=wd("Identity-H"),this._pdf=t,this._font=n,this._sub=n.makeSubset(),this._resourceName=wd("F"+ ++Qc);var r=n.head;this.name=n.psName;var o=this.scale=n.scale;this.bbox=[r.xMin*o,r.yMin*o,r.xMax*o,r.yMax*o],this.italicAngle=n.post.italicAngle,this.ascent=n.ascent*o,this.descent=n.descent*o,this.lineGap=n.lineGap*o,this.capHeight=n.os2.capHeight||this.ascent,this.xHeight=n.os2.xHeight||0,this.stemV=0,this.familyClass=(n.os2.familyClass||0)>>8,this.isSerif=this.familyClass>=1&&this.familyClass<=7,this.isScript=10==this.familyClass,this.flags=(n.post.isFixedPitch?1:0)|(this.isSerif?2:0)|(this.isScript?8:0)|(0!==this.italicAngle?64:0)|32}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.encodeText=function(e){return new bd(this._sub.encodeText(String(e)))},t.prototype.getTextWidth=function(e,t){for(var n=0,i=this._font.cmap.codeMap,r=0;r<t.length;++r){var o=i[t.charCodeAt(r)];n+=this._font.widthOfGlyph(o||0)}return n*e/1e3},t.prototype.beforeRender=function(){var t=this,n=t._sub,i=n.render(),r=new xd(Sc(i),{Length1:i.length},!0),o=t._pdf.attach(new e({Type:wd("FontDescriptor"),FontName:wd(t._sub.psName),FontBBox:t.bbox,Flags:t.flags,StemV:t.stemV,ItalicAngle:t.italicAngle,Ascent:t.ascent,Descent:t.descent,CapHeight:t.capHeight,XHeight:t.xHeight,FontFile2:t._pdf.attach(r)})),a=n.ncid2ogid,s=n.firstChar,l=n.lastChar,c=[];!function e(n,i){if(n<=l){var r=a[n];null==r?e(n+1):(i||c.push(n,i=[]),i.push(t._font.widthOfGlyph(r)),e(n+1,i))}}(s);var d=new e({Type:wd("Font"),Subtype:wd("CIDFontType2"),BaseFont:wd(t._sub.psName),CIDSystemInfo:new e({Registry:new _d("Adobe"),Ordering:new _d("Identity"),Supplement:0}),FontDescriptor:o,FirstChar:s,LastChar:l,DW:Math.round(t._font.widthOfGlyph(0)),W:c,CIDToGIDMap:t._pdf.attach(t._makeCidToGidMap())}),u=t.props;u.BaseFont=wd(t._sub.psName),u.DescendantFonts=[t._pdf.attach(d)];var h=new Id(s,l,n.subset),p=new xd(Zc(),null,!0);p.data(h),u.ToUnicode=t._pdf.attach(p)},t.prototype._makeCidToGidMap=function(){return new xd(Sc(this._sub.cidToGidMap()),null,!0)},t}(kd),Id=function(e){function t(t,n,i){e.call(this),this.firstChar=t,this.lastChar=n,this.map=i}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(e){e.indent("/CIDInit /ProcSet findresource begin"),e.indent("12 dict begin"),e.indent("begincmap"),e.indent("/CIDSystemInfo <<"),e.indent("  /Registry (Adobe)"),e.indent("  /Ordering (UCS)"),e.indent("  /Supplement 0"),e.indent(">> def"),e.indent("/CMapName /Adobe-Identity-UCS def"),e.indent("/CMapType 2 def"),e.indent("1 begincodespacerange"),e.indent("  <0000><ffff>"),e.indent("endcodespacerange");var t=this;e.indent(t.lastChar-t.firstChar+1," beginbfchar"),e.withIndent((function(){for(var n=t.firstChar;n<=t.lastChar;++n){var i=t.map[n],r=[i].map((function(e){var t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|1023&e),t+=String.fromCharCode(e)})).join("");e.indent("<",ld(n.toString(16),4),">","<");for(var o=0;o<r.length;++o)e(ld(r.charCodeAt(o).toString(16),4));e(">")}})),e.indent("endbfchar"),e.indent("endcmap"),e.indent("CMapName currentdict /CMap defineresource pop"),e.indent("end"),e.indent("end")},t}(vd);function zd(e){return e.map((function(e){return dd(e)?zd(e):"number"==typeof e?(Math.round(1e3*e)/1e3).toFixed(3):e})).join(" ")}function Pd(e,t,n,i,r,o,a){var s=zd([t,n,i,r,o,a]),l=e.GRAD_COL_FUNCTIONS[s];return l||(l=e.GRAD_COL_FUNCTIONS[s]=e.attach(new kd({FunctionType:2,Domain:[0,1],Range:[0,1,0,1,0,1],N:1,C0:[t,n,i],C1:[r,o,a]}))),l}function Hd(e,t,n){var i=zd([t,n]),r=e.GRAD_OPC_FUNCTIONS[i];return r||(r=e.GRAD_OPC_FUNCTIONS[i]=e.attach(new kd({FunctionType:2,Domain:[0,1],Range:[0,1],N:1,C0:[t],C1:[n]}))),r}function Fd(e,t,n){var i="radial"==t.type,r=function(e,t){var n,i,r,o,a,s=!1,l=[],c=[],d=[],u=[];for(n=1;n<t.length;++n)i=t[n-1],r=t[n],o=i.color,a=r.color,c.push(Pd(e,o.r,o.g,o.b,a.r,a.g,a.b)),(o.a<1||a.a<1)&&(s=!0),d.push(r.offset),u.push(0,1);if(s)for(n=1;n<t.length;++n)i=t[n-1],r=t[n],o=i.color,a=r.color,l.push(Hd(e,o.a,a.a));return d.pop(),{hasAlpha:s,colors:h(c),opacities:s?h(l):null};function h(e){return 1==e.length?e[0]:{FunctionType:3,Functions:e,Domain:[0,1],Bounds:d,Encode:u}}}(e,t.stops),o=i?[t.start.x,t.start.y,t.start.r,t.end.x,t.end.y,t.end.r]:[t.start.x,t.start.y,t.end.x,t.end.y],a=function(e,t,n,i,r,o){var a,s;if(!o){var l=[t].concat(i);n.forEach((function(e){l.push(e.offset,e.color.r,e.color.g,e.color.b)})),s=zd(l),a=e.GRAD_COL[s]}return a||(a=new kd({Type:wd("Shading"),ShadingType:t?3:2,ColorSpace:wd("DeviceRGB"),Coords:i,Domain:[0,1],Function:r,Extend:[!0,!0]}),e.attach(a),a._resourceName="S"+ ++Qc,s&&(e.GRAD_COL[s]=a)),a}(e,i,t.stops,o,r.colors,t.userSpace&&n),s=r.hasAlpha?function(e,t,n,i,r,o){var a,s;if(!o){var l=[t].concat(i);n.forEach((function(e){l.push(e.offset,e.color.a)})),s=zd(l),a=e.GRAD_OPC[s]}return a||(a=new kd({Type:wd("ExtGState"),AIS:!1,CA:1,ca:1,SMask:{Type:wd("Mask"),S:wd("Luminosity"),G:e.attach(new xd("/a0 gs /s0 sh",{Type:wd("XObject"),Subtype:wd("Form"),FormType:1,BBox:o?[o.left,o.top+o.height,o.left+o.width,o.top]:[0,1,1,0],Group:{Type:wd("Group"),S:wd("Transparency"),CS:wd("DeviceGray"),I:!0},Resources:{ExtGState:{a0:{CA:1,ca:1}},Shading:{s0:{ColorSpace:wd("DeviceGray"),Coords:i,Domain:[0,1],ShadingType:t?3:2,Function:r,Extend:[!0,!0]}}}}))}}),e.attach(a),a._resourceName="O"+ ++Qc,s&&(e.GRAD_OPC[s]=a)),a}(e,i,t.stops,o,r.opacities,t.userSpace&&n):null;return{hasAlpha:r.hasAlpha,shading:a,opacity:s}}var Rd=function(e){function t(t,n){e.call(this,n),this._pdf=t,this._rcount=0,this._textMode=!1,this._fontResources={},this._gsResources={},this._xResources={},this._patResources={},this._shResources={},this._opacity=1,this._matrix=[1,0,0,1,0,0],this._annotations=[],this._font=null,this._fontSize=null,this._contextStack=[],(n=this.props).Type=wd("Page"),n.ProcSet=[wd("PDF"),wd("Text"),wd("ImageB"),wd("ImageC"),wd("ImageI")],n.Resources=new e({Font:new e(this._fontResources),ExtGState:new e(this._gsResources),XObject:new e(this._xResources),Pattern:new e(this._patResources),Shading:new e(this._shResources)}),n.Annots=this._annotations}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._out=function(){this._content.data.apply(null,arguments)},t.prototype.transform=function(e,t,n,i,r,o){var a;(1!==(a=arguments)[0]||0!==a[1]||0!==a[2]||1!==a[3]||0!==a[4]||0!==a[5])&&(this._matrix=function(e,t){var n=e[0],i=e[1],r=e[2],o=e[3],a=e[4],s=e[5],l=t[0],c=t[1],d=t[2],u=t[3],h=t[4],p=t[5];return[n*l+i*d,n*c+i*u,r*l+o*d,r*c+o*u,a*l+s*d+h,a*c+s*u+p]}(arguments,this._matrix),this._out(e," ",t," ",n," ",i," ",r," ",o," cm"),this._out(Yc))},t.prototype.translate=function(e,t){this.transform(1,0,0,1,e,t)},t.prototype.scale=function(e,t){this.transform(e,0,0,t,0,0)},t.prototype.rotate=function(e){var t=Math.cos(e),n=Math.sin(e);this.transform(t,n,-n,t,0,0)},t.prototype.beginText=function(){this._textMode=!0,this._out("BT",Yc)},t.prototype.endText=function(){this._textMode=!1,this._out("ET",Yc)},t.prototype._requireTextMode=function(){if(!this._textMode)throw new Error("Text mode required; call page.beginText() first")},t.prototype._requireFont=function(){if(!this._font)throw new Error("No font selected; call page.setFont() first")},t.prototype.setFont=function(e,t){this._requireTextMode(),null==e?e=this._font:e instanceof Ed||(e=this._pdf.getFont(e)),null==t&&(t=this._fontSize),this._fontResources[e._resourceName]=e,this._font=e,this._fontSize=t,this._out(e._resourceName," ",t," Tf",Yc)},t.prototype.setTextLeading=function(e){this._requireTextMode(),this._out(e," TL",Yc)},t.prototype.setTextRenderingMode=function(e){this._requireTextMode(),this._out(e," Tr",Yc)},t.prototype.showText=function(e,t){if(this._requireFont(),e.length>1&&t&&this._font instanceof Ed){var n=t/this._font.getTextWidth(this._fontSize,e)*100;this._out(n," Tz ")}this._out(this._font.encodeText(e)," Tj",Yc)},t.prototype.showTextNL=function(e){this._requireFont(),this._out(this._font.encodeText(e)," '",Yc)},t.prototype.addLink=function(t,n){var i=this._toPage({x:n.left,y:n.bottom}),r=this._toPage({x:n.right,y:n.top});this._annotations.push(new e({Type:wd("Annot"),Subtype:wd("Link"),Rect:[i.x,i.y,r.x,r.y],Border:[0,0,0],A:new e({Type:wd("Action"),S:wd("URI"),URI:new _d(t)})}))},t.prototype.setStrokeColor=function(e,t,n){this._out(e," ",t," ",n," RG",Yc)},t.prototype.setOpacity=function(e){this.setFillOpacity(e),this.setStrokeOpacity(e),this._opacity*=e},t.prototype.setStrokeOpacity=function(e){if(e<1){var t=this._pdf.getOpacityGS(this._opacity*e,!0);this._gsResources[t._resourceName]=t,this._out(t._resourceName," gs",Yc)}},t.prototype.setFillColor=function(e,t,n){this._out(e," ",t," ",n," rg",Yc)},t.prototype.setFillOpacity=function(e){if(e<1){var t=this._pdf.getOpacityGS(this._opacity*e,!1);this._gsResources[t._resourceName]=t,this._out(t._resourceName," gs",Yc)}},t.prototype.gradient=function(e,t){this.save(),this.rect(t.left,t.top,t.width,t.height),this.clip(),e.userSpace||this.transform(t.width,0,0,t.height,t.left,t.top);var n,i=Fd(this._pdf,e,t),r=i.shading._resourceName;this._shResources[r]=i.shading,i.hasAlpha&&(n=i.opacity._resourceName,this._gsResources[n]=i.opacity,this._out("/"+n+" gs ")),this._out("/"+r+" sh",Yc),this.restore()},t.prototype.setDashPattern=function(e,t){this._out(e," ",t," d",Yc)},t.prototype.setLineWidth=function(e){this._out(e," w",Yc)},t.prototype.setLineCap=function(e){this._out(e," J",Yc)},t.prototype.setLineJoin=function(e){this._out(e," j",Yc)},t.prototype.setMitterLimit=function(e){this._out(e," M",Yc)},t.prototype.save=function(){this._contextStack.push(this._context()),this._out("q",Yc)},t.prototype.restore=function(){this._out("Q",Yc),this._context(this._contextStack.pop())},t.prototype.moveTo=function(e,t){this._out(e," ",t," m",Yc)},t.prototype.lineTo=function(e,t){this._out(e," ",t," l",Yc)},t.prototype.bezier=function(e,t,n,i,r,o){this._out(e," ",t," ",n," ",i," ",r," ",o," c",Yc)},t.prototype.bezier1=function(e,t,n,i){this._out(e," ",t," ",n," ",i," y",Yc)},t.prototype.bezier2=function(e,t,n,i){this._out(e," ",t," ",n," ",i," v",Yc)},t.prototype.close=function(){this._out("h",Yc)},t.prototype.rect=function(e,t,n,i){this._out(e," ",t," ",n," ",i," re",Yc)},t.prototype.ellipse=function(e,t,n,i){function r(t){return e+t}function o(e){return t+e}var a=.5522847498307936;this.moveTo(r(0),o(i)),this.bezier(r(n*a),o(i),r(n),o(i*a),r(n),o(0)),this.bezier(r(n),o(-i*a),r(n*a),o(-i),r(0),o(-i)),this.bezier(r(-n*a),o(-i),r(-n),o(-i*a),r(-n),o(0)),this.bezier(r(-n),o(i*a),r(-n*a),o(i),r(0),o(i))},t.prototype.circle=function(e,t,n){this.ellipse(e,t,n,n)},t.prototype.stroke=function(){this._out("S",Yc)},t.prototype.nop=function(){this._out("n",Yc)},t.prototype.clip=function(){this._out("W n",Yc)},t.prototype.clipStroke=function(){this._out("W S",Yc)},t.prototype.closeStroke=function(){this._out("s",Yc)},t.prototype.fill=function(){this._out("f",Yc)},t.prototype.fillStroke=function(){this._out("B",Yc)},t.prototype.drawImage=function(e){var t=this._pdf.getImage(e);t&&(this._xResources[t._resourceName]=t,this._out(t._resourceName," Do",Yc))},t.prototype.comment=function(e){var t=this;e.split(/\r?\n/g).forEach((function(e){t._out("% ",e,Yc)}))},t.prototype._context=function(e){if(null==e)return{opacity:this._opacity,matrix:this._matrix};this._opacity=e.opacity,this._matrix=e.matrix},t.prototype._toPage=function(e){var t=this._matrix,n=t[0],i=t[1],r=t[2],o=t[3],a=t[4],s=t[5];return{x:n*e.x+r*e.y+a,y:i*e.x+o*e.y+s}},t}(kd);function Ld(e){return e.replace(/^\s*(['"])(.*)\1\s*$/,"$2")}function Bd(e){var t=/^\s*((normal|italic)\s+)?((normal|small-caps)\s+)?((normal|bold|\d+)\s+)?(([0-9.]+)(px|pt))(\/(([0-9.]+)(px|pt)|normal))?\s+(.*?)\s*$/i.exec(e);if(!t)return{fontSize:12,fontFamily:"sans-serif"};var n=t[8]?parseInt(t[8],10):12;return{italic:t[2]&&"italic"==t[2].toLowerCase(),variant:t[4],bold:t[6]&&/bold|700/i.test(t[6]),fontSize:n,lineHeight:t[12]?"normal"==t[12]?n:parseInt(t[12],10):null,fontFamily:t[14].split(/\s*,\s*/g).map(Ld)}}function Od(e){function t(t){return e.bold&&(t+="|bold"),e.italic&&(t+="|italic"),t.toLowerCase()}var n,i,r=e.fontFamily;if(r instanceof Array)for(var o=0;o<r.length&&(n=t(r[o]),!(i=Vd[n]));++o);else i=Vd[r.toLowerCase()];for(;"function"==typeof i;)i=i();return i||(i="Times-Roman"),i}var Vd={serif:"Times-Roman","serif|bold":"Times-Bold","serif|italic":"Times-Italic","serif|bold|italic":"Times-BoldItalic","sans-serif":"Helvetica","sans-serif|bold":"Helvetica-Bold","sans-serif|italic":"Helvetica-Oblique","sans-serif|bold|italic":"Helvetica-BoldOblique",monospace:"Courier","monospace|bold":"Courier-Bold","monospace|italic":"Courier-Oblique","monospace|bold|italic":"Courier-BoldOblique",zapfdingbats:"ZapfDingbats","zapfdingbats|bold":"ZapfDingbats","zapfdingbats|italic":"ZapfDingbats","zapfdingbats|bold|italic":"ZapfDingbats"};function Nd(e,t){e=e.toLowerCase(),Vd[e]=function(){return Vd[t]},Vd[e+"|bold"]=function(){return Vd[t+"|bold"]},Vd[e+"|italic"]=function(){return Vd[t+"|italic"]},Vd[e+"|bold|italic"]=function(){return Vd[t+"|bold|italic"]}}function $d(e,t){if(1==arguments.length)for(var n in e)cd(e,n)&&$d(n,e[n]);else switch(e=e.toLowerCase(),Vd[e]=t,e){case"dejavu sans":Vd["sans-serif"]=t;break;case"dejavu sans|bold":Vd["sans-serif|bold"]=t;break;case"dejavu sans|italic":Vd["sans-serif|italic"]=t;break;case"dejavu sans|bold|italic":Vd["sans-serif|bold|italic"]=t;break;case"dejavu serif":Vd.serif=t;break;case"dejavu serif|bold":Vd["serif|bold"]=t;break;case"dejavu serif|italic":Vd["serif|italic"]=t;break;case"dejavu serif|bold|italic":Vd["serif|bold|italic"]=t;break;case"dejavu mono":Vd.monospace=t;break;case"dejavu mono|bold":Vd["monospace|bold"]=t;break;case"dejavu mono|italic":Vd["monospace|italic"]=t;break;case"dejavu mono|bold|italic":Vd["monospace|bold|italic"]=t}}Nd("Times New Roman","serif"),Nd("Courier New","monospace"),Nd("Arial","sans-serif"),Nd("Helvetica","sans-serif"),Nd("Verdana","sans-serif"),Nd("Tahoma","sans-serif"),Nd("Georgia","sans-serif"),Nd("Monaco","monospace"),Nd("Andale Mono","monospace");var Ud={fill:0,stroke:1,fillAndStroke:2,invisible:3,fillAndClip:4,strokeAndClip:5,fillStrokeClip:6,clip:7},Wd=Ud,jd={dash:[4],dashDot:[4,2,1,2],dot:[1,2],longDash:[8,2],longDashDot:[8,2,1,2],longDashDotDot:[8,2,1,2,1,2],solid:[]},qd={butt:0,round:1,square:2},Gd={miter:0,round:1,bevel:2};function Kd(e,t){var n=[],i={},r=e.options;function o(e,t,n){return n||(n=r),n.pdf&&null!=n.pdf[e]?n.pdf[e]:t}var a=o("multiPage"),s=o("imgDPI",300);function l(){if(!(--c>0)){var n=new ad({producer:o("producer"),title:o("title"),author:o("author"),subject:o("subject"),keywords:o("keywords"),creator:o("creator"),date:o("date"),autoPrint:o("autoPrint")});a?e.children.forEach(i):i(e),t(n.render(),n)}function i(e){var t=e.options,i=function(e){var t,n=!1,i=Do.unit(),r=null;do{t=!1,e=d(e)}while(e&&t);return{root:e,bbox:r};function o(e){return t=!0,e}function a(e){return e.visible()&&e.opacity()>0&&(Jd(e.fill())||Jd(e.stroke()))}function s(e){for(var t=[],n=0;n<e.length;++n){var i=d(e[n]);null!=i&&t.push(i)}return t}function l(e,t){var r=n,o=i;e.transform()&&(i=i.multiplyCopy(e.transform().matrix()));var a=e.clip();a&&"function"==typeof a.bbox&&(a=a.bbox())&&(a=a.bbox(i),n=n?Yo.intersect(n,a):a);try{return t()}finally{n=r,i=o}}function c(e){if(null==n)return!1;var t=e.rawBBox();return t&&(t=t.bbox(i)),n&&t&&(t=Yo.intersect(t,n)),t}function d(t){return l(t,(function(){if(!(t instanceof vs||t instanceof hs)){var n=c(t);if(!n)return o(null);r=r?Yo.union(r,n):n}return Xd({Path:function(e){return 0!==e.segments.length&&a(e)?e:o(null)},MultiPath:function(e){if(!a(e))return o(null);var t=new hs(e.options);return t.paths=s(e.paths),0===t.paths.length?o(null):t},Circle:function(e){return a(e)?e:o(null)},Arc:function(e){return a(e)?e:o(null)},Text:function(e){return/\S/.test(e.content())&&a(e)?e:o(null)},Image:function(e){return e.visible()&&e.opacity()>0?e:o(null)},Group:function(t){if(!(t.visible()&&t.opacity()>0))return o(null);var n=new vs(t.options);return n.children=s(t.children),n._pdfLink=t._pdfLink,t===e||0!==n.children.length||t._pdfLink?n:o(null)},Rect:function(e){return a(e)?e:o(null)}},t)}))}}(e),r=i.bbox;e=i.root;var a=o("paperSize",o("paperSize","auto"),t),s=!1;if("auto"==a)if(r){var l=r.getSize();a=[l.width,l.height],s=!0;var c=r.getOrigin();(i=new vs).transform(new Do(1,0,0,1,-c.x,-c.y)),i.append(e),e=i}else a="A4";Zd(e,n.addPage({paperSize:a,margin:o("margin",o("margin"),t),addMargin:s,landscape:o("landscape",o("landscape",!1),t)}),n)}}nd(),e.traverse((function(e){Xd({Image:function(e){var t=e.src(),n=e.bbox().size;if(s){var r=i[t];n={width:Math.ceil(n.width*s/72),height:Math.ceil(n.height*s/72)},r&&(n.width=Math.max(r.width,n.width),n.height=Math.max(r.height,n.height))}i[t]=n},Text:function(e){var t=Od(Bd(e.options.font));n.indexOf(t)<0&&n.push(t)}},e)}));var c=2;rd(n,l),od(i,l,{jpegQuality:o("jpegQuality",.92),keepPNG:o("keepPNG",!1)})}function Yd(e,t){Kd(e,(function(e){t("data:application/pdf;base64,"+e.base64())}))}function Qd(e,t){Kd(e,(function(e){t(new window.Blob([e.get()],{type:"application/pdf"}))}))}function Xd(e,t){var n=e[t.nodeType];return n?n.call.apply(n,arguments):t}function Zd(e,t,n){e.options._pdfDebug&&t.comment("BEGIN: "+e.options._pdfDebug);var i=e.transform(),r=e.opacity();if(t.save(),null!=r&&r<1&&t.setOpacity(r),function(e,t){var n=e.stroke&&e.stroke();if(!n)return;var i=n.color;if(i){if(null==(i=uu(i)))return;t.setStrokeColor(i.r,i.g,i.b),1!=i.a&&t.setStrokeOpacity(i.a)}var r=n.width;if(null!=r){if(0===r)return;t.setLineWidth(r)}var o=n.dashType;o&&t.setDashPattern(jd[o],0);var a=n.lineCap;a&&t.setLineCap(qd[a]);var s=n.lineJoin;s&&t.setLineJoin(Gd[s]);var l=n.opacity;null!=l&&t.setStrokeOpacity(l)}(e,t),function(e,t){var n=e.fill&&e.fill();if(!n)return;if(n instanceof Fs)return;var i=n.color;if(i){if(null==(i=uu(i)))return;t.setFillColor(i.r,i.g,i.b),1!=i.a&&t.setFillOpacity(i.a)}var r=n.opacity;null!=r&&t.setFillOpacity(r)}(e,t),i){var o=i.matrix();t.transform(o.a,o.b,o.c,o.d,o.e,o.f)}!function(e,t,n){var i=e.clip();i&&(nu(i,t,n),t.clip())}(e,t,n),Xd({Path:iu,MultiPath:ru,Circle:ou,Arc:au,Text:su,Image:cu,Group:lu,Rect:du},e,t,n),t.restore(),e.options._pdfDebug&&t.comment("END: "+e.options._pdfDebug)}function Jd(e){return e&&(e instanceof Fs||e.color&&!/^(none|transparent)$/i.test(e.color)&&(null==e.width||e.width>0)&&(null==e.opacity||e.opacity>0))}function eu(e,t,n,i){var r=e.fill();if(r instanceof Fs){i?t.clipStroke():t.clip();var o,a,s=r instanceof Ls;s?(o={x:r.center().x,y:r.center().y,r:0},a={x:r.center().x,y:r.center().y,r:r.radius()}):(o={x:r.start().x,y:r.start().y},a={x:r.end().x,y:r.end().y});var l=r.stops.elements().map((function(e){var t=e.offset();t=/%$/.test(t)?parseFloat(t)/100:parseFloat(t);var n=uu(e.color());return n.a*=e.opacity(),{offset:t,color:n}}));l.unshift(l[0]),l.push(l[l.length-1]);var c={userSpace:r.userSpace(),type:s?"radial":"linear",start:o,end:a,stops:l},d=e.rawBBox(),u=d.topLeft(),h=d.getSize();return d={left:u.x,top:u.y,width:h.width,height:h.height},t.gradient(c,d),!0}}function tu(e,t,n){Jd(e.fill())&&Jd(e.stroke())?eu(e,t,0,!0)||t.fillStroke():Jd(e.fill())?eu(e,t,0,!1)||t.fill():Jd(e.stroke())?t.stroke():t.nop()}function nu(e,t,n){var i=e.segments;if(0!==i.length&&!function(e,t){var n=e.segments;if(4==n.length&&e.options.closed){for(var i=[],r=0;r<n.length;++r){if(n[r].controlIn())return!1;i[r]=n[r].anchor()}if(i[0].y==i[1].y&&i[1].x==i[2].x&&i[2].y==i[3].y&&i[3].x==i[0].x||i[0].x==i[1].x&&i[1].y==i[2].y&&i[2].x==i[3].x&&i[3].y==i[0].y)return t.rect(i[0].x,i[0].y,i[2].x-i[0].x,i[2].y-i[0].y),!0}}(e,t)){for(var r,o=0;o<i.length;++o){var a=i[o],s=a.anchor();if(r){var l=r.controlOut(),c=a.controlIn();l&&c?t.bezier(l.x,l.y,c.x,c.y,s.x,s.y):t.lineTo(s.x,s.y)}else t.moveTo(s.x,s.y);r=a}e.options.closed&&t.close()}}function iu(e,t,n){nu(e,t),tu(e,t)}function ru(e,t,n){for(var i=e.paths,r=0;r<i.length;++r)nu(i[r],t);tu(e,t)}function ou(e,t,n){var i=e.geometry();t.circle(i.center.x,i.center.y,i.radius),tu(e,t)}function au(e,t,n){var i=e.geometry().curvePoints();t.moveTo(i[0].x,i[0].y);for(var r=1;r<i.length;)t.bezier(i[r].x,i[r++].y,i[r].x,i[r++].y,i[r].x,i[r++].y);tu(e,t)}function su(e,t){var n,i=Bd(e.options.font),r=e._position;t.transform(1,0,0,-1,r.x,r.y+i.fontSize);var o=function(n){t.beginText(),t.setFont(Od(i),i.fontSize),t.setTextRenderingMode(n),t.showText(e.content(),e._pdfRect?e._pdfRect.width():null)};e.fill()&&e.stroke()?(n=Wd.fillAndStroke,"stroke"===e.options.paintOrder&&(o(Wd.stroke),n=Wd.fill)):e.fill()?n=Wd.fill:e.stroke()&&(n=Wd.stroke),o(n),t.endText()}function lu(e,t,n){e._pdfLink&&t.addLink(e._pdfLink.url,e._pdfLink);for(var i=e.children,r=0;r<i.length;++r)Zd(i[r],t,n)}function cu(e,t){var n=e.src();if(n){var i=e.rect(),r=i.getOrigin(),o=i.getSize();t.transform(o.width,0,0,-o.height,r.x,r.y+o.height),t.drawImage(n)}}function du(e,t,n){var i=e.geometry(),r=i.cornerRadius,o=r[0],a=r[1];0===o&&0===a?(t.rect(i.origin.x,i.origin.y,i.size.width,i.size.height),tu(e,t)):iu(us.fromRect(i,e.options),t)}function uu(e){var t=jr(e,!0);return t?t.toRGB():null}function hu(e,t){var n=Xr();for(var i in t)"margin"==i&&e.options.pdf&&e.options.pdf._ignoreMargin||e.options.set("pdf."+i,t[i]);return Yd(e,n.resolve),n}var pu=Object.freeze({__proto__:null,BinaryStream:Sc,Document:ad,TEXT_RENDERING_MODE:Ud,clearImageCache:nd,defineFont:$d,exportPDF:hu,exportPDFToBlob:function(e,t){var n=Xr();for(var i in t)"margin"==i&&e.options.pdf&&e.options.pdf._ignoreMargin||e.options.set("pdf."+i,t[i]);return window.Blob&&!Ir.browser.safari?Qd(e,n.resolve):Yd(e,n.resolve),n},getFontURL:Od,getPaperOptions:Jc,loadFonts:rd,loadImages:od,parseFontDef:Bd,render:Kd,saveAs:function(e,t,n,i){window.Blob&&!Ir.browser.safari?Qd(e,(function(e){Mr({dataURI:e,fileName:t}),i&&i(e)})):Yd(e,(function(e){Mr({dataURI:e,fileName:t,proxyURL:n}),i&&i(e)}))},toBlob:Qd,toDataURL:Yd}),fu=Ir.browser||{};function mu(e){return Array.prototype.slice.call(e)}var gu="KENDO-PSEUDO-ELEMENT",vu="data-kendo-bullet-type",_u={},bu={};bu._root=bu;var yu=!!("undefined"!=typeof window)&&(fu.msie||fu.edge),wu=function(e){function t(t,n,i){e.call(this,t,n.getOrigin(),i),this._pdfRect=n}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.rect=function(){return this._pdfRect},t.prototype.rawBBox=function(){return this._pdfRect},t}(fs);function ku(e,t){Object.keys(t).forEach((function(n){e.style[n]=t[n]}))}var xu,Cu="undefined"!=typeof Element&&Element.prototype&&((xu=Element.prototype).matches?function(e,t){return e.matches(t)}:xu.webkitMatchesSelector?function(e,t){return e.webkitMatchesSelector(t)}:xu.mozMatchesSelector?function(e,t){return e.mozMatchesSelector(t)}:xu.msMatchesSelector?function(e,t){return e.msMatchesSelector(t)}:function(e){return-1!==[].indexOf.call(document.querySelectorAll(e),this)});function Su(e,t){if(e.closest)return e.closest(t);for(;e&&!/^\[object (?:HTML)?Document\]$/.test(String(e));){if(1==e.nodeType&&Cu(e,t))return e;e=e.parentNode}}var Tu=function(e){return e?function t(n){var i=n.cloneNode(!1);if(1==n.nodeType){var r,o=e(n),a=e(i),s=o.data();for(r in s)a.data(r,s[r]);for(/^canvas$/i.test(n.tagName)?i.getContext("2d").drawImage(n,0,0):/^(?:input|select|textarea|option)$/i.test(n.tagName)&&(i.removeAttribute("id"),i.removeAttribute("name"),/^textarea$/i.test(n.tagName)||(i.value=n.value),i.checked=n.checked,i.selected=n.selected),n._kendoExportVisual&&(i._kendoExportVisual=n._kendoExportVisual),r=n.firstChild;r;r=r.nextSibling)i.appendChild(t(r))}return i}:function(e){var t=function e(t){var n=t.cloneNode(!1);t._kendoExportVisual&&(n._kendoExportVisual=t._kendoExportVisual);for(var i=t.firstChild;i;i=i.nextSibling)n.appendChild(e(i));return n}(e),n=e.querySelectorAll("canvas");n.length&&mu(t.querySelectorAll("canvas")).forEach((function(e,t){e.getContext("2d").drawImage(n[t],0,0)}));var i=e.querySelectorAll("input, select, textarea, option");return mu(t.querySelectorAll("input, select, textarea, option")).forEach((function(e,t){e.removeAttribute("id"),e.removeAttribute("name"),/^textarea$/i.test(e.tagName)||(e.value=i[t].value),e.checked=i[t].checked,e.selected=i[t].selected})),t}}("undefined"!=typeof window&&window.kendo&&window.kendo.jQuery);function Du(e,t){t||(t={});var n=Xr();if(!e)return n.reject("No element to export");if("function"!=typeof window.getComputedStyle)throw new Error("window.getComputedStyle is missing.  You are using an unsupported browser, or running in IE8 compatibility mode.  Drawing HTML is supported in Chrome, Firefox, Safari and IE9+.");$d(Hu(e.ownerDocument));var i,r="number"==typeof(i=t.scale||1)?{x:i,y:i}:Array.isArray(i)?{x:i[0],y:i[1]}:{x:i.x,y:i.y};function o(e){var n,i,o=new vs,a=e.getBoundingClientRect();return nh(o,[r.x,0,0,r.y,-a.left*r.x,-a.top*r.y]),bu._clipbox=!1,bu._matrix=Do.unit(),bu._stackingContext={element:e,group:o},!0===t.avoidLinks?bu._avoidLinks="a":bu._avoidLinks=t.avoidLinks,i="k-pdf-export",(n=e).classList?n.classList.add(i):n.className+=" "+i,bh(e,o),function(e,t){e.classList?e.classList.remove(t):e.className=e.className.split(/\s+/).reduce((function(e,n){return n!=t&&e.push(n),e}),[]).join(" ")}(e,"k-pdf-export"),o}function a(e){if(null!=e)return"string"==typeof e&&(e=function(){throw new Error("Template implementation missing.")}(e.replace(/^\s+|\s+$/g,""))),"function"==typeof e?function(t){var n=e(t);if(n&&"string"==typeof n){var i=document.createElement("div");ml(i,n),n=i.firstElementChild}return n}:function(){return e.cloneNode(!0)}}return $u([e],(function(){var i=t&&t.forcePageBreak,s=t&&t.paperSize&&"auto"!=t.paperSize,l=Jc((function(e,n){return"paperSize"==e?s?t[e]:"A4":e in t?t[e]:n})),c=s&&l.paperSize[0],d=s&&l.paperSize[1],u=t.margin&&l.margin,h=Boolean(u);if(i||d){u||(u={left:0,top:0,right:0,bottom:0}),c&&(c/=r.x),d&&(d/=r.y),u.left/=r.x,u.right/=r.x,u.top/=r.y,u.bottom/=r.y;var p=new vs({pdf:{multiPage:!0,paperSize:s?l.paperSize:"auto",_ignoreMargin:h}});!function(e,t,n,i,r,o,s){var l=a(s.template),c=t.ownerDocument,d=[],u=s._destructive?t:Tu(t),h=c.createElement("KENDO-PDF-DOCUMENT"),p=0;mu(u.querySelectorAll("tfoot")).forEach((function(e){e.parentNode.appendChild(e)})),mu(u.querySelectorAll("ol")).forEach((function(e){mu(e.children).forEach((function(e,t){e.setAttribute("kendo-split-index",t)}))})),ku(h,{display:"block",position:"absolute",boxSizing:"content-box",left:"-10000px",top:"-10000px"}),i&&(ku(h,{width:i+"px",paddingLeft:o.left+"px",paddingRight:o.right+"px"}),ku(u,{overflow:"hidden"}));t.parentNode.insertBefore(h,t),h.appendChild(u),s.beforePageBreak?Nu([h],(function(){s.beforePageBreak(h,f)})):Nu([h],f);function f(){("-"!=n||r)&&g(u);var t=b();u.parentNode.insertBefore(t,u),t.appendChild(u),l&&d.forEach((function(e,t){var n=l({element:e,pageNum:t+1,totalPages:d.length});n&&e.appendChild(n)})),$u(d,e.bind(null,{pages:d,container:h}))}function m(e){if(s.keepTogether&&Cu(e,s.keepTogether)&&e.offsetHeight<=r-p)return!0;var t=e.tagName;return!(/^h[1-6]$/i.test(t)&&e.offsetHeight>=r-p)&&(e.getAttribute("data-kendo-chart")||/^(?:img|tr|thead|th|tfoot|iframe|svg|object|canvas|input|textarea|select|video|h[1-6])/i.test(e.tagName))}function g(e){if("TABLE"==e.tagName&&ku(e,{tableLayout:"fixed"}),!m(e)){var t=Gu(e),i=parseFloat(Ku(t,"padding-bottom")),o=parseFloat(Ku(t,"border-bottom-width")),a=p;p+=i+o;for(var s=!0,l=e.firstChild;l;l=l.nextSibling)if(1==l.nodeType){if(s=!1,Cu(l,n)){_(l);continue}if(!r){g(l);continue}if(!/^(?:static|relative)$/.test(Ku(Gu(l),"position")))continue;var c=y(l);1==c||c&&m(l)?_(l):g(l)}else 3==l.nodeType&&r&&(w(l,s),s=!1);p=a}}function v(e){var t=e.parentNode,n=t.firstChild;if(e===n)return!0;if(e===t.children[0]){if(7==n.nodeType||8==n.nodeType)return!0;if(3==n.nodeType)return!/\S/.test(n.data)}return!1}function _(e){if(1==e.nodeType&&e!==u&&v(e))return _(e.parentNode);var t,n,i,r,o;n=(t=Su(e,"table"))&&t.querySelector("colgroup"),s.repeatHeaders&&(i=t&&t.querySelector("thead"),(r=Su(e,".k-grid"))&&r.querySelector(".k-auto-scrollable")&&(o=r.querySelector(".k-grid-header")));var a=b(),l=c.createRange();l.setStartBefore(u),l.setEndBefore(e),a.appendChild(l.extractContents()),u.parentNode.insertBefore(a,u),k(e.parentNode),t&&(t=Su(e,"table"),s.repeatHeaders&&i&&t.insertBefore(i.cloneNode(!0),t.firstChild),n&&t.insertBefore(n.cloneNode(!0),t.firstChild)),s.repeatHeaders&&o&&(r=Su(e,".k-grid")).insertBefore(o.cloneNode(!0),r.firstChild)}function b(){var e=c.createElement("KENDO-PDF-PAGE");return ku(e,{display:"block",boxSizing:"content-box",width:i?i+"px":"auto",padding:o.top+"px "+o.right+"px "+o.bottom+"px "+o.left+"px",position:"relative",height:r?r+"px":"auto",overflow:r||i?"hidden":"visible",clear:"both"}),s&&s.pageClassName&&(e.className=s.pageClassName),d.push(e),e}function y(e){var t=e.getBoundingClientRect();if(0===t.width||0===t.height)return 0;var n=u.getBoundingClientRect().top,i=r-p;return t.height>i?3:t.top-n>i?1:t.bottom-n>i?2:0}function w(e,t){if(/\S/.test(e.data)){var n=e.data.length,i=c.createRange();i.selectNodeContents(e);var r=y(i);if(r){var o=e;if(1==r)_(t?e.parentNode:e);else if(function t(n,r,o){return i.setEnd(e,r),n==r||r==o?r:y(i)?t(n,n+r>>1,r):t(r,r+o>>1,o)}(0,n>>1,n),!/\S/.test(i.toString())&&t)_(e.parentNode);else{o=e.splitText(i.endOffset);var a=b();i.setStartBefore(u),a.appendChild(i.extractContents()),u.parentNode.insertBefore(a,u),k(o.parentNode)}w(o)}}}function k(e){var t=Su(e,"li");t&&(t.setAttribute("kendo-no-bullet","1"),k(t.parentNode))}}((function(e){if(t.progress){var i=!1,r=0;!function a(){if(r<e.pages.length){var s=o(e.pages[r]);p.append(s),t.progress({page:s,pageNum:++r,totalPages:e.pages.length,cancel:function(){i=!0}}),i?e.container.parentNode.removeChild(e.container):setTimeout(a)}else e.container.parentNode.removeChild(e.container),n.resolve(p)}()}else e.pages.forEach((function(e){p.append(o(e))})),e.container.parentNode.removeChild(e.container),n.resolve(p)}),e,i,c?c-u.left-u.right:null,d?d-u.top-u.bottom:null,u,t)}else n.resolve(o(e))})),n}function Au(e){var t=new vs;return bu._clipbox=!1,bu._matrix=Do.unit(),bu._stackingContext={element:e,group:t},Wu(e,Gu(e),t),3==e.firstChild.nodeType?_h(e,e.firstChild,t):ph(e,t),ju(),t}var Mu,Eu=function(){var e=/^((-webkit-|-moz-|-o-|-ms-)?linear-gradient\s*)\(/,t=/^([-0-9.]+%)/,n=/^([-0-9.]+px)/,i=/^(left|right|top|bottom|to|center)\W/,r=/^([-0-9.]+(deg|grad|rad|turn)|0)/,o=/^(\s+)/,a=/^(\()/,s=/^(\))/,l=/^(,)/,c=/^(url)\(/,d=/^(.*?)\)/,u={},h={};function p(h){var p,f=h;if(Fu(u,f))return u[f];function m(e){!function(){var e=o.exec(h);e&&(h=h.substr(e[1].length))}();var t=e.exec(h);if(t)return h=h.substr(t[1].length),t[1]}function g(){var e,i,r=jr(h,!0);if(r){var o=/^#[0-9a-f]+/i.exec(h)||/^rgba?\(.*?\)/i.exec(h)||/^..*?\b/.exec(h);return h=h.substr(o[0].length),r=r.toRGB(),(e=m(n))||(i=m(t)),{color:r,length:e,percent:i}}}return(p=m(e))?p=function(e){var n,o,c,d=[],u=!1;if(m(a)){if("0"==(n=m(r))&&(n="0deg"),n?(n=function(e){var t=parseFloat(e);return/grad$/.test(e)?Math.PI*t/200:/rad$/.test(e)?t:/turn$/.test(e)?Math.PI*t*2:/deg$/.test(e)?Math.PI*t/180:void 0}(n),m(l)):("to"==(o=m(i))?o=m(i):o&&/^-/.test(e)&&(u=!0),c=m(i),m(l)),/-moz-/.test(e)&&null==n&&null==o){var p=m(t),f=m(t);u=!0,"0%"==p?o="left":"100%"==p&&(o="right"),"0%"==f?c="top":"100%"==f&&(c="bottom"),m(l)}for(;h&&!m(s);){var v=g();if(!v)break;d.push(v),m(l)}return{type:"linear",angle:n,to:o&&c?o+" "+c:o||c||null,stops:d,reverse:u}}}(p):(p=m(c))&&(p=function(){if(m(a)){var e=m(d);return e=e.replace(/^['"]+|["']+$/g,""),m(s),{type:"url",url:e}}}()),u[f]=p||{type:"none"}}return function(e){return Fu(h,e)?h[e]:h[e]=Iu(e).map(p)}}(),Iu=(Mu={},function(e,t){t||(t=/^\s*,\s*/);var n=e+t;if(Fu(Mu,n))return Mu[n];var i,r=[],o=0,a=0,s=0,l=!1;function c(t){return i=t.exec(e.substr(a))}function d(e){return e.replace(/^\s+|\s+$/g,"")}for(;a<e.length;)!l&&c(/^[\(\[\{]/)?(s++,a++):!l&&c(/^[\)\]\}]/)?(s--,a++):!l&&c(/^[\"\']/)?(l=i[0],a++):"'"==l&&c(/^\\\'/)||'"'==l&&c(/^\\\"/)?a+=2:"'"==l&&c(/^\'/)||'"'==l&&c(/^\"/)?(l=!1,a++):c(t)?(!l&&!s&&a>o&&(r.push(d(e.substring(o,a))),o=a+i[0].length),a+=i[0].length):a++;return o<a&&r.push(d(e.substring(o,a))),Mu[n]=r}),zu=function(e){return function(t){var n,i=e[t];i||((n=/url\((['"]?)([^'")]*?)\1\)\s+format\((['"]?)truetype\3\)/.exec(t))||(n=/url\((['"]?)([^'")]*?\.ttf)\1\)/.exec(t)))&&(i=e[t]=n[2]);return i}}(Object.create(null)),Pu=function(e){return function(t){var n=e[t];return null==n&&(n=e[t]=Oo("Mapq",{font:t}).height),n}}(Object.create(null));function Hu(e){null==e&&(e=document);for(var t={},n=0;n<e.styleSheets.length;++n)i(e.styleSheets[n]);return t;function i(e){if(e){var t=null;try{t=e.cssRules}catch(e){}t&&function(e,t){for(var n=0;n<t.length;++n){var a=t[n];switch(a.type){case 3:i(a.styleSheet);break;case 5:var s=a.style,l=Iu(Ku(s,"font-family")),c=/^([56789]00|bold)$/i.test(Ku(s,"font-weight")),d="italic"==Ku(s,"font-style"),u=r(a);u.length>0&&o(e,l,c,d,u[0])}}}(e,t)}}function r(e){var t=Ku(e.style,"src");if(t)return Iu(t).reduce((function(e,t){var n=zu(t);return n&&e.push(n),e}),[]);var n=zu(e.cssText);return n?[n]:[]}function o(e,n,i,r,o){/^data:/i.test(o)||/^[^\/:]+:\/\//.test(o)||/^\//.test(o)||(o=String(e.href).replace(/[^\/]*$/,"")+o),n.forEach((function(e){e=e.replace(/^(['"]?)(.*?)\1$/,"$2"),i&&(e+="|bold"),r&&(e+="|italic"),t[e]=o}))}}function Fu(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function Ru(e,t){var n=bu;for(e="_counter_"+e;n&&!Fu(n,e);)n=Object.getPrototypeOf(n);n||(n=bu._root),n[e]=(n[e]||0)+(null==t?1:t)}function Lu(e,t){bu[e="_counter_"+e]=null==t?0:t}function Bu(e,t,n){for(var i=0;i<e.length;){var r=e[i++],o=parseFloat(e[i]);isNaN(o)?t(r,n):(t(r,o),++i)}}function Ou(e){var t=Ku(e,"counter-reset");t&&Bu(Iu(t,/^\s+/),Lu,0);var n=Ku(e,"counter-increment");n&&Bu(Iu(n,/^\s+/),Ru,1)}function Vu(e,t){var n=jr(e,!0);return n&&(n=n.toRGB(),t?n=n.toCssRgba():0===n.a&&(n=null)),n}function Nu(e,t){var n=0,i=!1;function r(){!i&&--n<=0&&(t(),i=!0)}e.forEach((function(e){for(var t=e.querySelectorAll("img"),i=0;i<t.length;++i){var o=t[i];o.complete||(n++,o.onload=o.onerror=r)}})),n||r()}function $u(e,t){var n=[];function i(e){_u[e]||(_u[e]=!0,n.push(e))}e.forEach((function e(t){/^img$/i.test(t.tagName)&&i(t.src),Eu(Ku(Gu(t),"background-image")).forEach((function(e){"url"==e.type&&i(e.url)})),t.children&&mu(t.children).forEach(e)}));var r=n.length;function o(){--r<=0&&Nu(e,t)}0===r&&o(),n.forEach((function(e){var t=_u[e]=new window.Image;/^data:/i.test(e)||(t.crossOrigin="Anonymous"),t.src=e,t.complete?o():(t.onload=o,t.onerror=function(){_u[e]=null,o()})}))}function Uu(e){var t="";do{var n=e%26;t=String.fromCharCode(97+n)+t,e=Math.floor(e/26)}while(e>0);return t}function Wu(e,t,n){(bu=Object.create(bu))[e.tagName.toLowerCase()]={element:e,style:t};var i=Ku(t,"text-decoration");if(i&&"none"!=i){var r=Ku(t,"text-decoration-color");i.split(/\s+/g).forEach((function(e){if(!bu[e]&&(bu[e]=r,"underline"==e)){var n=Ku(t,"text-underline-offset");"auto"!=n&&(bu["underline-offset"]=parseFloat(n))}}))}(function(e){function t(t){return Ku(e,t)}if("none"!=t("transform")||"static"!=t("position")||"auto"!=t("z-index")||t("opacity")<1)return!0})(t)&&(bu._stackingContext={element:e,group:n})}function ju(){bu=Object.getPrototypeOf(bu)}function qu(e){if(null!=bu._clipbox){var t=e.bbox(bu._matrix);bu._clipbox?bu._clipbox=Yo.intersect(bu._clipbox,t):bu._clipbox=t}}function Gu(e,t){return window.getComputedStyle(e,t||null)}function Ku(e,t,n){var i=e.getPropertyValue(t);return null!=i&&""!==i||(fu.webkit?i=e.getPropertyValue("-webkit-"+t):fu.mozilla?i=e.getPropertyValue("-moz-"+t):fu.opera?i=e.getPropertyValue("-o-"+t):yu&&(i=e.getPropertyValue("-ms-"+t))),arguments.length>2&&(null==i||""===i)?n:i}function Yu(e,t,n,i){e.setProperty(t,n,i),fu.webkit?e.setProperty("-webkit-"+t,n,i):fu.mozilla?e.setProperty("-moz-"+t,n,i):fu.opera?e.setProperty("-o-"+t,n,i):yu&&(e.setProperty("-ms-"+t,n,i),e[t="ms"+t.replace(/(^|-)([a-z])/g,(function(e,t,n){return t+n.toUpperCase()}))]=n)}function Qu(e,t){return t="border-"+t,{width:parseFloat(Ku(e,t+"-width")),style:Ku(e,t+"-style"),color:Vu(Ku(e,t+"-color"),!0)}}function Xu(e,t){var n=e.style.cssText,i=t();return ul(e,n),i}function Zu(e,t){var n=Ku(e,"border-"+t+"-radius").split(/\s+/g).map(parseFloat);return 1==n.length&&n.push(n[0]),oh({x:n[0],y:n[1]})}function Ju(e){var t=e.getBoundingClientRect();return t=eh(t,"border-*-width",e),t=eh(t,"padding-*",e)}function eh(e,t,n){var i,r,o,a,s;return"string"==typeof t?(i=Gu(n),r=parseFloat(Ku(i,t.replace("*","top"))),o=parseFloat(Ku(i,t.replace("*","right"))),a=parseFloat(Ku(i,t.replace("*","bottom"))),s=parseFloat(Ku(i,t.replace("*","left")))):"number"==typeof t&&(r=o=a=s=t),{top:e.top+r,right:e.right-o,bottom:e.bottom-a,left:e.left+s,width:e.right-e.left-o-s,height:e.bottom-e.top-a-r}}function th(e){return 180*e/Math.PI%360}function nh(e,t){return t=new Do(t[0],t[1],t[2],t[3],t[4],t[5]),e.transform(t),t}function ih(e,t){e.clip(t)}function rh(e,t,n,i){for(var r=new ga([t,n],i).curvePoints(),o=1;o<r.length;)e.curveTo(r[o++],r[o++],r[o++])}function oh(e){return(e.x<=0||e.y<=0)&&(e.x=e.y=0),e}function ah(e,t,n,i,r){var o=Math.max(0,t.x),a=Math.max(0,t.y),s=Math.max(0,n.x),l=Math.max(0,n.y),c=Math.max(0,i.x),d=Math.max(0,i.y),u=Math.max(0,r.x),h=Math.max(0,r.y),p=Math.min(e.width/(o+s),e.height/(l+d),e.width/(c+u),e.height/(h+a));return p<1&&(o*=p,a*=p,s*=p,l*=p,c*=p,d*=p,u*=p,h*=p),{tl:{x:o,y:a},tr:{x:s,y:l},br:{x:c,y:d},bl:{x:u,y:h}}}function sh(e,t,n){var i=Gu(e),r=Zu(i,"top-left"),o=Zu(i,"top-right"),a=Zu(i,"bottom-left"),s=Zu(i,"bottom-right");if("padding"==n||"content"==n){var l=Qu(i,"top"),c=Qu(i,"right"),d=Qu(i,"bottom"),u=Qu(i,"left");if(r.x-=u.width,r.y-=l.width,o.x-=c.width,o.y-=l.width,s.x-=c.width,s.y-=d.width,a.x-=u.width,a.y-=d.width,"content"==n){var h=parseFloat(Ku(i,"padding-top")),p=parseFloat(Ku(i,"padding-right")),f=parseFloat(Ku(i,"padding-bottom")),m=parseFloat(Ku(i,"padding-left"));r.x-=m,r.y-=h,o.x-=p,o.y-=h,s.x-=p,s.y-=f,a.x-=m,a.y-=f}}return"number"==typeof n&&(r.x-=n,r.y-=n,o.x-=n,o.y-=n,s.x-=n,s.y-=n,a.x-=n,a.y-=n),lh(t,r,o,s,a)}function lh(e,t,n,i,r){var o=ah(e,t,n,i,r),a=o.tl,s=o.tr,l=o.br,c=o.bl,d=new us({fill:null,stroke:null});return d.moveTo(e.left,e.top+a.y),a.x&&rh(d,e.left+a.x,e.top+a.y,{startAngle:-180,endAngle:-90,radiusX:a.x,radiusY:a.y}),d.lineTo(e.right-s.x,e.top),s.x&&rh(d,e.right-s.x,e.top+s.y,{startAngle:-90,endAngle:0,radiusX:s.x,radiusY:s.y}),d.lineTo(e.right,e.bottom-l.y),l.x&&rh(d,e.right-l.x,e.bottom-l.y,{startAngle:0,endAngle:90,radiusX:l.x,radiusY:l.y}),d.lineTo(e.left+c.x,e.bottom),c.x&&rh(d,e.left+c.x,e.bottom-c.y,{startAngle:90,endAngle:180,radiusX:c.x,radiusY:c.y}),d.close()}function ch(e,t){var n=String(parseFloat(e));switch(t){case"decimal-leading-zero":return n.length<2&&(n="0"+n),n;case"lower-roman":return Qr(e).toLowerCase();case"upper-roman":return Qr(e).toUpperCase();case"lower-latin":case"lower-alpha":return Uu(e-1);case"upper-latin":case"upper-alpha":return Uu(e-1).toUpperCase();default:return n}}function dh(e,t){function n(e,t,n){return n?(n=n.replace(/^\s*(["'])(.*)\1\s*$/,"$2"),function(e){var t=[],n=bu;for(e="_counter_"+e;n;)Fu(n,e)&&t.push(n[e]),n=Object.getPrototypeOf(n);return t.reverse()}(e).map((function(e){return ch(e,t)})).join(n)):ch(function(e){return bu[e="_counter_"+e]}(e)||0,t)}var i,r=Iu(t,/^\s+/),o=[];return r.forEach((function(t){var r;(i=/^\s*(["'])(.*)\1\s*$/.exec(t))?o.push(i[2].replace(/\\([0-9a-f]{4})/gi,(function(e,t){return String.fromCharCode(parseInt(t,16))}))):(i=/^\s*counter\((.*?)\)\s*$/.exec(t))?(r=Iu(i[1]),o.push(n(r[0],r[1]))):(i=/^\s*counters\((.*?)\)\s*$/.exec(t))?(r=Iu(i[1]),o.push(n(r[0],r[2],r[1]))):(i=/^\s*attr\((.*?)\)\s*$/.exec(t))?o.push(e.getAttribute(i[1])||""):o.push(t)})),o.join("")}function uh(e){if(e.cssText)return e.cssText;for(var t=[],n=0;n<e.length;++n)t.push(e[n]+": "+Ku(e,e[n]));return t.join(";\n")}function hh(e,t){if(e.tagName!=gu){var n=[];if(r(":before",e.firstChild),r(":after",null),n.length>0){var i=e.className;e.className+=" kendo-pdf-hide-pseudo-elements",ph(e,t),e.className=i,n.forEach((function(t){e.removeChild(t)}))}else ph(e,t)}else ph(e,t);function r(t,i){var r=Gu(e,t),o=r.content;if(Ou(r),o&&"normal"!=o&&"none"!=o&&"0px"!=r.width){var a=e.ownerDocument.createElement(gu);ul(a,uh(r)),a.textContent=dh(e,o),e.insertBefore(a,i),n.push(a)}}}function ph(e,t){var n=Gu(e),i=Qu(n,"top"),r=Qu(n,"right"),o=Qu(n,"bottom"),a=Qu(n,"left"),s=Zu(n,"top-left"),l=Zu(n,"top-right"),c=Zu(n,"bottom-left"),d=Zu(n,"bottom-right"),u=Ku(n,"direction"),h=Ku(n,"background-color");h=Vu(h);var p,f,m=Eu(Ku(n,"background-image")),g=Iu(Ku(n,"background-repeat")),v=Iu(Ku(n,"background-position")),_=Iu(Ku(n,"background-origin")),b=Iu(Ku(n,"background-size"));yu&&"ellipsis"==(p=n.textOverflow)&&(f=e.style.textOverflow,e.style.textOverflow="clip"),fu.msie&&fu.version<10&&(v=Iu(e.currentStyle.backgroundPosition));var y,w,k,x=eh(e.getBoundingClientRect(),"border-*-width",e);!function(){var e=Ku(n,"clip"),i=/^\s*rect\((.*)\)\s*$/.exec(e);if(i){var r=i[1].split(/[ ,]+/g),o="auto"==r[0]?x.top:parseFloat(r[0])+x.top,a="auto"==r[1]?x.right:parseFloat(r[1])+x.left,s="auto"==r[2]?x.bottom:parseFloat(r[2])+x.top,l="auto"==r[3]?x.left:parseFloat(r[3])+x.left,c=new vs,d=(new us).moveTo(l,o).lineTo(a,o).lineTo(a,s).lineTo(l,s).close();ih(c,d),t.append(c),t=c,qu(d)}}();var C=Ku(n,"display");if("table-row"==C)for(y=[],w=0,k=e.children;w<k.length;++w)y.push(k[w].getBoundingClientRect());else 1==(y=e.getClientRects()).length&&(y=[e.getBoundingClientRect()]);for(y=function(t){if(/^td$/i.test(e.tagName)){var n=bu.table;if(n&&"collapse"==Ku(n.style,"border-collapse")){var i=Qu(n.style,"left").width,r=Qu(n.style,"top").width;if(0===i&&0===r)return t;var o=n.element.getBoundingClientRect(),a=n.element.rows[0].cells[0].getBoundingClientRect();if(a.top==o.top||a.left==o.left)return mu(t).map((function(e){return{left:e.left+i,top:e.top+r,right:e.right+i,bottom:e.bottom+r,height:e.height,width:e.width}}))}}return t}(y),w=0;w<y.length;++w)A(y[w],0===w,w==y.length-1);if("A"==e.tagName&&e.href&&!/^#?$/.test(e.getAttribute("href"))&&(!bu._avoidLinks||!Cu(e,bu._avoidLinks))){var S=document.createRange();S.selectNodeContents(e),mu(S.getClientRects()).forEach((function(n){var i=new vs;i._pdfLink={url:e.href,top:n.top,right:n.right,bottom:n.bottom,left:n.left},t.append(i)}))}return y.length>0&&"list-item"==C&&!e.getAttribute("kendo-no-bullet")&&function(){var i=Ku(n,"list-style-type");if("none"==i)return;var r=Ku(n,"list-style-position");function o(n){Xu(e,(function(){e.style.position="relative";var i=e.ownerDocument.createElement(gu);i.style.position="absolute",i.style.boxSizing="border-box","outside"==r?(i.style.width="6em",i.style.left="-6.8em",i.style.textAlign="right"):i.style.left="0px",n(i),e.insertBefore(i,e.firstChild),bh(i,t),e.removeChild(i)}))}function a(t){var n=e.parentNode.children,i=e.getAttribute("kendo-split-index");if(null!=i)return t(0|i,n.length);for(var r=0;r<n.length;++r)if(n[r]===e)return t(r,n.length)}switch(i){case"circle":case"disc":case"square":o((function(e){e.innerHTML="&nbsp;",e.setAttribute(vu,i)}));break;case"decimal":case"decimal-leading-zero":o((function(e){a((function(t){++t,"decimal-leading-zero"==i&&t<10&&(t="0"+t),e.innerHTML=t+"."}))}));break;case"lower-roman":case"upper-roman":o((function(e){a((function(t){t=Qr(t+1),"upper-roman"==i&&(t=t.toUpperCase()),e.innerHTML=t+"."}))}));break;case"lower-latin":case"lower-alpha":case"upper-latin":case"upper-alpha":o((function(e){a((function(t){t=Uu(t),/^upper/i.test(i)&&(t=t.toUpperCase()),e.innerHTML=t+"."}))}))}}(y[0]),function(){function i(){var n=sh(e,x,"padding"),i=new vs;ih(i,n),t.append(i),t=i,qu(n)}!function(e){return/^(?:textarea|select|input)$/i.test(e.tagName)}(e)?(/^(hidden|auto|scroll)/.test(Ku(n,"overflow"))||/^(hidden|auto|scroll)/.test(Ku(n,"overflow-x"))||/^(hidden|auto|scroll)/.test(Ku(n,"overflow-y")))&&i():i()}(),function(e,t){var n;if(e._kendoExportVisual){var i=e.getBoundingClientRect(),r={width:i.width,height:i.height};n=e._kendoExportVisual(r)}else if(window.kendo&&window.kendo.jQuery&&e.getAttribute(window.kendo.attr("role"))){var o=window.kendo.widgetInstance(window.kendo.jQuery(e));o&&(o.exportDOMVisual||o.exportVisual)&&(n=o.exportDOMVisual?o.exportDOMVisual():o.exportVisual())}if(!n)return!1;var a=new vs;a.children.push(n);var s=e.getBoundingClientRect();return a.transform(Xo().translate(s.left,s.top)),t.append(a),!0}(e,t)||function(e,t){var n=e.getAttribute(vu);if(!n)return!1;var i=e.getBoundingClientRect(),r=Gu(e).color;if("square"===n){var o=i.height/5;t.append(new Ss(new Yo([i.right-o,i.top+i.height/2.1],[o,o])).fill(r).stroke(r))}else{var a=i.height/7,s=[i.right-a,i.top+(i.height+a)/2],l=new ua(new oa(s,a));"circle"===n?l.stroke(r,.5):l.fill(r).stroke(null),t.append(l)}return!0}(e,t)||vh(e,t),yu&&"ellipsis"==p&&(e.style.textOverflow=f),t;function T(e,n,i,r,o,a,s,l){if(!(i<=0)){var c,d=new vs;nh(d,l),t.append(d),oh(a),oh(s),c=new us({fill:{color:e},stroke:null}),d.append(c),c.moveTo(a.x?Math.max(a.x,r):0,0).lineTo(n-(s.x?Math.max(s.x,o):0),0).lineTo(n-Math.max(s.x,o),i).lineTo(Math.max(a.x,r),i).close(),a.x&&u(r,a,[-1,0,0,1,a.x,0]),s.x&&u(o,s,[1,0,0,1,n-s.x,0])}function u(t,n,r){var o=Math.PI/2*t/(t+i),a={x:n.x-t,y:n.y-i},s=new us({fill:{color:e},stroke:null}).moveTo(0,0);nh(s,r),rh(s,0,n.y,{startAngle:-90,endAngle:-th(o),radiusX:n.x,radiusY:n.y}),a.x>0&&a.y>0?(s.lineTo(a.x*Math.cos(o),n.y-a.y*Math.sin(o)),rh(s,0,n.y,{startAngle:-th(o),endAngle:-90,radiusX:a.x,radiusY:a.y,anticlockwise:!0})):a.x>0?s.lineTo(a.x,i).lineTo(0,i):s.lineTo(a.x,i).lineTo(a.x,0),d.append(s.close())}}function D(t,n,i,r,o,a,s){var l;if(i&&"none"!=i)if("url"==i.type){var c=_u[i.url];c&&c.width>0&&c.height>0&&d(t,n,c.width,c.height,(function(e,t){e.append(new ms(i.url,t))}))}else{if("linear"!=i.type)return;d(t,n,n.width,n.height,(l=i,function(e,t){var n=t.width(),i=t.height();switch(l.type){case"linear":var r=null!=l.angle?l.angle:Math.PI;switch(l.to){case"top":r=0;break;case"left":r=-Math.PI/2;break;case"bottom":r=Math.PI;break;case"right":r=Math.PI/2;break;case"top left":case"left top":r=-Math.atan2(i,n);break;case"top right":case"right top":r=Math.atan2(i,n);break;case"bottom left":case"left bottom":r=Math.PI+Math.atan2(i,n);break;case"bottom right":case"right bottom":r=Math.PI-Math.atan2(i,n)}l.reverse&&(r-=Math.PI),(r%=2*Math.PI)<0&&(r+=2*Math.PI);var o=Math.abs(n*Math.sin(r))+Math.abs(i*Math.cos(r)),a=Math.atan(n*Math.tan(r)/i),s=Math.sin(a),c=Math.cos(a),d=Math.abs(s)+Math.abs(c),u=d/2*s,h=d/2*c;r>Math.PI/2&&r<=3*Math.PI/2&&(u=-u,h=-h);var p=[],f=0,m=l.stops.map((function(e,t){var n=e.percent;n?n=parseFloat(n)/100:e.length?n=parseFloat(e.length)/o:0===t?n=0:t==l.stops.length-1&&(n=1);var i={color:e.color.toCssRgba(),offset:n};return null!=n?(f=n,p.forEach((function(e,t){e.stop.offset=e.left+(f-e.left)*(t+1)/(p.length+1)})),p=[]):p.push({left:f,stop:i}),i})),g=[.5-u,.5+h],v=[.5+u,.5-h];e.append(us.fromRect(t).stroke(null).fill(new Rs({start:g,end:v,stops:m,userSpace:!1})));break;case"radial":window.console&&window.console.log&&window.console.log("Radial gradients are not yet supported in HTML renderer")}}))}function d(t,n,i,l,c){var d,u=i/l,h=n;if("content-box"==a?(h=eh(h,"border-*-width",e),h=eh(h,"padding-*",e)):"padding-box"==a&&(h=eh(h,"border-*-width",e)),!/^\s*auto(\s+auto)?\s*$/.test(s))if("contain"==s)d=Math.min(h.width/i,h.height/l),i*=d,l*=d;else if("cover"==s)d=Math.max(h.width/i,h.height/l),i*=d,l*=d;else{var p=s.split(/\s+/g);i=/%$/.test(p[0])?h.width*parseFloat(p[0])/100:parseFloat(p[0]),l=1==p.length||"auto"==p[1]?i/u:/%$/.test(p[1])?h.height*parseFloat(p[1])/100:parseFloat(p[1])}var f=String(o);switch(f){case"bottom":f="50% 100%";break;case"top":f="50% 0";break;case"left":f="0 50%";break;case"right":f="100% 50%";break;case"center":f="50% 50%"}1==(f=f.split(/\s+/)).length&&(f[1]="50%"),/%$/.test(f[0])?f[0]=parseFloat(f[0])/100*(h.width-i):f[0]=parseFloat(f[0]),/%$/.test(f[1])?f[1]=parseFloat(f[1])/100*(h.height-l):f[1]=parseFloat(f[1]);var m=new Yo([h.left+f[0],h.top+f[1]],[i,l]);function g(){for(;m.origin.x>n.left;)m.origin.x-=i}function v(){for(;m.origin.y>n.top;)m.origin.y-=l}function _(){for(;m.origin.x<n.right;)c(t,m.clone()),m.origin.x+=i}if("no-repeat"==r)c(t,m);else if("repeat-x"==r)g(),_();else if("repeat-y"==r)for(v();m.origin.y<n.bottom;)c(t,m.clone()),m.origin.y+=l;else if("repeat"==r){g(),v();for(var b=m.origin.clone();m.origin.y<n.bottom;)m.origin.x=b.x,_(),m.origin.y+=l}}}function A(n,p,f){if(0!==n.width&&0!==n.height){!function(e){var n=new vs;if(ih(n,lh(e,s,l,d,c)),t.append(n),h){var i=new us({fill:{color:h.toCssRgba()},stroke:null});i.moveTo(e.left,e.top).lineTo(e.right,e.top).lineTo(e.right,e.bottom).lineTo(e.left,e.bottom).close(),n.append(i)}for(var r=m.length;--r>=0;)D(n,e,m[r],g[r%g.length],v[r%v.length],_[r%_.length],b[r%b.length])}(n);var y=a.width>0&&(p&&"ltr"==u||f&&"rtl"==u),w=r.width>0&&(f&&"ltr"==u||p&&"rtl"==u);if(0!==i.width||0!==a.width||0!==r.width||0!==o.width){if(i.color==r.color&&i.color==o.color&&i.color==a.color&&i.width==r.width&&i.width==o.width&&i.width==a.width&&y&&w){n=eh(n,i.width/2);var k=sh(e,n,i.width/2);return k.options.stroke={color:i.color,width:i.width},void t.append(k)}if(0===s.x&&0===l.x&&0===d.x&&0===c.x&&i.width<2&&a.width<2&&r.width<2&&o.width<2)return i.width>0&&t.append(new us({stroke:{width:i.width,color:i.color}}).moveTo(n.left,n.top+i.width/2).lineTo(n.right,n.top+i.width/2)),o.width>0&&t.append(new us({stroke:{width:o.width,color:o.color}}).moveTo(n.left,n.bottom-o.width/2).lineTo(n.right,n.bottom-o.width/2)),y&&t.append(new us({stroke:{width:a.width,color:a.color}}).moveTo(n.left+a.width/2,n.top).lineTo(n.left+a.width/2,n.bottom)),void(w&&t.append(new us({stroke:{width:r.width,color:r.color}}).moveTo(n.right-r.width/2,n.top).lineTo(n.right-r.width/2,n.bottom)));var x=ah(n,s,l,d,c),C=x.tl,S=x.tr,A=x.br,M=x.bl;T(i.color,n.width,i.width,a.width,r.width,C,S,[1,0,0,1,n.left,n.top]),T(o.color,n.width,o.width,r.width,a.width,A,M,[-1,0,0,-1,n.right,n.bottom]),T(a.color,n.height,a.width,o.width,i.width,E(M),E(C),[0,-1,1,0,n.left,n.bottom]),T(r.color,n.height,r.width,i.width,o.width,E(S),E(A),[0,1,-1,0,n.right,n.top])}}function E(e){return{x:e.y,y:e.x}}}}function fh(e,t,n){var i=Ju(e),r=new Yo([i.left,i.top],[i.width,i.height]),o=new ms(t,r);ih(o,sh(e,i,"content")),n.append(o)}function mh(e,t){var n=Gu(e),i=Gu(t),r=parseFloat(Ku(n,"z-index")),o=parseFloat(Ku(i,"z-index")),a=Ku(n,"position"),s=Ku(i,"position");return isNaN(r)&&isNaN(o)?/static|absolute/.test(a)&&/static|absolute/.test(s)?0:"static"==a?-1:"static"==s?1:0:isNaN(r)?0===o?0:o>0?-1:1:isNaN(o)?0===r?0:r>0?1:-1:parseFloat(r)-parseFloat(o)}function gh(e,t){var n=e.tagName.toLowerCase();if("input"==n&&("checkbox"==e.type||"radio"==e.type))return function(e,t){var n=Ku(Gu(e),"color"),i=e.getBoundingClientRect();"checkbox"==e.type?(t.append(us.fromRect(new Yo([i.left+1,i.top+1],[i.width-2,i.height-2])).stroke(n,1)),e.checked&&t.append((new us).stroke(n,1.2).moveTo(i.left+.22*i.width,i.top+.55*i.height).lineTo(i.left+.45*i.width,i.top+.75*i.height).lineTo(i.left+.78*i.width,i.top+.22*i.width))):(t.append(new ua(new oa([(i.left+i.right)/2,(i.top+i.bottom)/2],Math.min(i.width-2,i.height-2)/2)).stroke(n,1)),e.checked&&t.append(new ua(new oa([(i.left+i.right)/2,(i.top+i.bottom)/2],Math.min(i.width-8,i.height-8)/2)).fill(n).stroke(null)))}(e,t);var i,r=e.parentNode,o=e.ownerDocument,a=o.createElement(gu);if(ul(a,uh(Gu(e))),"input"==n&&(a.style.whiteSpace="pre"),"select"!=n&&"textarea"!=n||(a.style.overflow="auto"),"select"==n)if(e.multiple)for(var s=0;s<e.options.length;++s)i=o.createElement(gu),ul(i,uh(Gu(e.options[s]))),i.style.display="block",i.textContent=e.options[s].textContent,a.appendChild(i);else i=function(e){return e.selectedOptions&&e.selectedOptions.length>0?e.selectedOptions[0]:e.options[e.selectedIndex]}(e),i&&(a.textContent=i.textContent);else a.textContent=e.value;r.insertBefore(a,e),a.scrollLeft=e.scrollLeft,a.scrollTop=e.scrollTop,e.style.display="none",vh(a,t),e.style.display="",r.removeChild(a)}function vh(e,t){switch(bu._stackingContext.element===e&&(bu._stackingContext.group=t),e.tagName.toLowerCase()){case"img":fh(e,e.src,t);break;case"svg":var n=function(e){var t=new window.XMLSerializer,n=t.serializeToString(e);if(fu.mozilla&&(!e.getAttribute("width")||!e.getAttribute("height"))){var i=(new window.DOMParser).parseFromString(n,"image/svg+xml").documentElement,r=Ju(e);i.setAttribute("width",r.width),i.setAttribute("height",r.height),n=t.serializeToString(i)}return n}(e);fh(e,"data:image/svg+xml;base64,"+lo(n),t);break;case"canvas":try{fh(e,e.toDataURL("image/png"),t)}catch(e){}break;case"textarea":case"input":case"select":gh(e,t);break;default:for(var i=[],r=[],o=[],a=e.firstChild;a;a=a.nextSibling)switch(a.nodeType){case 3:/\S/.test(a.data)&&_h(e,a,t);break;case 1:var s=Gu(a),l=Ku(s,"float");"static"!=Ku(s,"position")?o.push(a):"none"!=l?r.push(a):i.push(a)}mo(i,mh).forEach((function(e){bh(e,t)})),mo(r,mh).forEach((function(e){bh(e,t)})),mo(o,mh).forEach((function(e){bh(e,t)}))}}function _h(e,t,n){if(null!=(i=bu._clipbox)&&!(i?0===i.width()||0===i.height():void 0)){var i,r=Gu(e);if(!(parseFloat(Ku(r,"text-indent"))<-500)){var o=t.data,a=0,s=o.search(/\S\s*$/)+1;if(s){var l=Ku(r,"font-size"),c=Ku(r,"line-height"),d=[Ku(r,"font-style"),Ku(r,"font-variant"),Ku(r,"font-weight"),l,Ku(r,"font-family")].join(" ");if(l=parseFloat(l),c=parseFloat(c),0!==l&&!isNaN(l)){var u=Ku(r,"color"),h=e.ownerDocument.createRange(),p="justify"==Ku(r,"text-align"),f=Ku(r,"column-count",1),m=Ku(r,"white-space"),g=Ku(r,"text-transform"),v=e.getBoundingClientRect().width/l*5;0===v&&(v=500);var _=null,b=bu.underline,y=bu["line-through"],w=bu.overline,k=bu["underline-offset"];for(b&&x((function(e){var t=l/12,n=e.bottom;n+=null!=k?k:t;T(t,e,b,n)}));!S(););return void((y||w)&&x((function(e){var t=l/12;T(t,e,y,e.bottom-e.height/2.7),T(t,e,w,e.top)})))}}}}function x(e){h.selectNode(t);var n=mu(h.getClientRects());x=function(e){return n.forEach(e)},x(e)}function C(e){if(yu||fu.chrome||fu.safari){for(var t=e.getClientRects(),n={top:1/0,right:-1/0,bottom:-1/0,left:1/0},i=!1,r=0;r<t.length;++r){var o=t[r];o.width<=1||o.bottom===_||(n.left=Math.min(o.left,n.left),n.top=Math.min(o.top,n.top),n.right=Math.max(o.right,n.right),n.bottom=Math.max(o.bottom,n.bottom),i=!0)}return i?(n.width=n.right-n.left,n.height=n.bottom-n.top,n):e.getBoundingClientRect()}return e.getBoundingClientRect()}function S(){var e,i=a,r=o.substr(a).search(/\S/);if(a+=r,r<0||a>=s)return!0;h.setStart(t,a),h.setEnd(t,a+1),e=C(h);var l=!1;if((p||f>1)&&(r=o.substr(a).search(/\s/))>=0){h.setEnd(t,a+r);var b=C(h);b.bottom==e.bottom&&(e=b,l=!0,a+=r)}if(!l){if(r=function n(i,r,o){h.setEnd(t,r);var a=C(h);return a.bottom!=e.bottom&&i<r?n(i,i+r>>1,r):a.right!=e.right?(e=a,r<o?n(r,r+o>>1,o):r):r}(a,Math.min(s,a+v),s),r==a)return!0;if(a=r,0===(r=h.toString().search(/\s+$/)))return!1;r>0&&(h.setEnd(t,h.startOffset+r),e=C(h))}yu&&(e=h.getClientRects()[0]);var y=h.toString();if(/^(?:pre|pre-wrap)$/i.test(m)){if(/\t/.test(y)){var w=0;for(r=i;r<h.startOffset;++r){var k=o.charCodeAt(r);9==k?w+=8-w%8:10==k||13==k?w=0:w++}for(;(r=y.search("\t"))>=0;){var x="        ".substr(0,8-(w+r)%8);y=y.substr(0,r)+x+y.substr(r+1)}}}else y=y.replace(/\s+/g," ");l||(_=e.bottom),function(e,t){if(yu&&!isNaN(c)){var i=Pu(d),r=(t.top+t.bottom-i)/2;t={top:r,right:t.right,bottom:r+i,left:t.left,height:i,width:t.right-t.left}}switch(g){case"uppercase":e=e.toUpperCase();break;case"lowercase":e=e.toLowerCase();break;case"capitalize":e=e.replace(/(?:^|\s)\S/g,(function(e){return e.toUpperCase()}))}var o=new wu(e,new Yo([t.left,t.top],[t.width,t.height]),{font:d,fill:{color:u}});n.append(o)}(y,e)}function T(e,t,i,r){if(i){var o=new us({stroke:{width:e,color:i}});r-=e,o.moveTo(t.left,r).lineTo(t.right,r),n.append(o)}}}function bh(e,t){var n=Gu(e);if(Ou(n),!/^(style|script|link|meta|iframe|col|colgroup)$/i.test(e.tagName)&&null!=bu._clipbox){var i=parseFloat(Ku(n,"opacity")),r=Ku(n,"visibility"),o=Ku(n,"display");if(0!==i&&"hidden"!=r&&"none"!=o){var a,s=function(e){var t=Ku(e,"transform");if("none"==t)return null;var n=/^\s*matrix\(\s*(.*?)\s*\)\s*$/.exec(t);if(n){var i=Ku(e,"transform-origin");return{matrix:n=n[1].split(/\s*,\s*/g).map(parseFloat),origin:i=i.split(/\s+/g).map(parseFloat)}}}(n),l=Ku(n,"z-index");(s||i<1)&&"auto"==l&&(l=0),a=function(e,t,n){var i;"auto"!=n?(i=bu._stackingContext.group,n=parseFloat(n)):(i=t,n=0);for(var r=i.children,o=0;o<r.length&&!(null!=r[o]._dom_zIndex&&r[o]._dom_zIndex>n);++o);var a=new vs;if(i.insert(o,a),a._dom_zIndex=n,i!==t&&bu._clipbox){var s=bu._matrix.invert(),l=bu._clipbox.transformCopy(s);ih(a,us.fromRect(l))}return a}(0,t,l),i<1&&a.opacity(i*a.opacity()),Wu(e,n,a),s?Xu(e,(function(){Yu(e.style,"transform","none","important"),Yu(e.style,"transition","none","important"),"static"==Ku(n,"position")&&Yu(e.style,"position","relative","important");var t=e.getBoundingClientRect(),i=t.left+s.origin[0],r=t.top+s.origin[1],o=[1,0,0,1,-i,-r];o=yh(o,s.matrix),o=yh(o,[1,0,0,1,i,r]),o=nh(a,o),bu._matrix=bu._matrix.multiplyCopy(o),hh(e,a)})):hh(e,a),ju()}}}function yh(e,t){var n=e[0],i=e[1],r=e[2],o=e[3],a=e[4],s=e[5],l=t[0],c=t[1],d=t[2],u=t[3];return[n*l+i*d,n*c+i*u,r*l+o*d,r*c+o*u,a*l+s*d+t[4],a*c+s*u+t[5]]}window.kendo=window.kendo||{},kendo.deepExtend(kendo,{parseColor:jr,namedColors:Hr,Color:qr});!function(e){var t=window.kendo,n=t.ui,i=n.Widget,r=t.Class,o=t.support,a=t.getOffset,s=t._outerWidth,l=t._outerHeight,c="open",d="close",u="deactivate",h="activate",p="center",f="left",m="right",g="top",v="bottom",_="absolute",b="hidden",y="body",w="location",k="position",x="visible",C="effects",S="k-active",T=".k-picker-wrap, .k-dropdown-wrap, .k-link",D=e(document.documentElement),A=e(window),M="scroll",E="transform",I=e.extend,z=".kendoPopup",P=["font-size","font-family","font-stretch","font-style","font-weight","line-height"];function H(t,n){return!(!t||!n)&&(t===n||e.contains(t,n))}var F=i.extend({init:function(n,r){var a,s=this;(r=r||{}).isRtl&&(r.origin=r.origin||v+" "+m,r.position=r.position||g+" "+m),i.fn.init.call(s,n,r),n=s.element,r=s.options,s.collisions=r.collision?r.collision.split(" "):[],s.downEvent=t.applyEventMap("down",t.guid()),1===s.collisions.length&&s.collisions.push(s.collisions[0]),a=e(s.options.anchor).closest(".k-popup,.k-group,.k-menu-group").filter(":not([class^=km-])"),r.appendTo=e(e(r.appendTo)[0]||a[0]||document.body),s.element.hide().addClass("k-popup").toggleClass("k-rtl",!!r.isRtl).appendTo(r.appendTo).attr("aria-hidden",!0).on("mouseenter"+z,(function(){s._hovered=!0})).on("wheel"+z,(function(t){var n=e(t.target).find(".k-list"),i=n.parent();n.length&&n.is(":visible")&&(0===i.scrollTop()&&t.originalEvent.deltaY<0||i.scrollTop()===i.prop("scrollHeight")-i.prop("offsetHeight")&&t.originalEvent.deltaY>0)&&t.preventDefault()})).on("mouseleave"+z,(function(){s._hovered=!1})),s.wrapper=e(),!1===r.animation&&(r.animation={open:{effects:{}},close:{hide:!0,effects:{}}}),I(r.animation.open,{complete:function(){s.wrapper.addClass("k-animation-container-shown"),s.wrapper.css("overflow",""),s._activated=!0,s._trigger(h)}}),I(r.animation.close,{complete:function(){s._animationClose()}}),s._mousedownProxy=function(e){s._mousedown(e)},o.mobileOS.android?s._resizeProxy=function(e){setTimeout((function(){s._resize(e)}),600)}:s._resizeProxy=function(e){s._resize(e)},r.toggleTarget&&e(r.toggleTarget).on(r.toggleEvent+z,s.toggle.bind(s))},events:[c,h,d,u],options:{name:"Popup",toggleEvent:"click",origin:v+" "+f,position:g+" "+f,anchor:y,appendTo:null,collision:"flip fit",viewport:window,copyAnchorStyles:!0,autosize:!1,autowidth:!1,modal:!1,adjustSize:{width:0,height:0},animation:{open:{effects:"slideIn:down",transition:!0,duration:200},close:{duration:100,hide:!0}},omitOriginOffsets:!1},_animationClose:function(){var e=this,t=e.wrapper.data(w);e.wrapper.hide(),t&&e.wrapper.css(t),e.options.anchor!=y&&e._hideActiveClass(),e._closing=!1,e._trigger(u)},destroy:function(){var n,r=this,o=r.options,a=r.element.off(z);i.fn.destroy.call(r),o.toggleTarget&&e(o.toggleTarget).off(z),o.modal||(D.off(r.downEvent,r._mousedownProxy),r._toggleResize(!1)),t.destroy(r.element.children()),a.removeData(),o.appendTo[0]===document.body&&((n=a.closest(".k-animation-container"))[0]?n.remove():a.remove())},open:function(n,i){var r,a,s,l=this,d={isFixed:!isNaN(parseInt(i,10)),x:n,y:i},u=l._shouldCorrectWidth,h=l.element,p=l.options,f=e(p.anchor),m=h[0]&&h.hasClass("km-widget"),v=h.find("[role='listbox']");if(!l.visible()){if(p.copyAnchorStyles&&(m&&"font-size"==P[0]&&P.shift(),h.css(t.getComputedStyles(f[0],P))),l.element.parent().data("animating")||l._trigger(c))return;l._activated=!1,p.modal||(D.off(l.downEvent,l._mousedownProxy).on(l.downEvent,l._mousedownProxy),l._toggleResize(!1),l._toggleResize(!0)),l.wrapper=a=t.wrap(h,p.autosize,p._resizeOnWrap,u,p.autowidth).css({overflow:b,display:"block",position:_}).attr("aria-hidden",!1),s=h.parent(),v.attr("aria-label")?a.attr("aria-label",v.attr("aria-label")):v.attr("aria-labelledby")&&a.attr("aria-labelledby",v.attr("aria-labelledby")),o.mobileOS.android&&s.css(E,"translatez(0)"),a.css(k),e(p.appendTo)[0]==document.body&&a.css(g,"-10000px"),l.flipped=l._position(d),r=l._openAnimation(),p.anchor==y||l.element.hasClass("k-tooltip")||l._addActiveClass(),s.hide(),h.show(),l.wrapper.show(),s.data(C,r.effects).kendoStop(!0).kendoAnimate(r),h.attr("aria-hidden",!1)}},_location:function(n){var i,r=this,a=r.element,s=r.options,l=e(s.anchor),c=a[0]&&a.hasClass("km-widget");s.copyAnchorStyles&&(c&&"font-size"==P[0]&&P.shift(),a.css(t.getComputedStyles(l[0],P))),r.wrapper=i=t.wrap(a,s.autosize).css({overflow:b,display:"block",position:_}),o.mobileOS.android&&i.css(E,"translatez(0)"),i.css(k),e(s.appendTo)[0]==document.body&&i.css(g,"-10000px"),r._position(n||{});var d=i.offset();return{width:t._outerWidth(i),height:t._outerHeight(i),left:d.left,top:d.top}},_openAnimation:function(){var e=I(!0,{},this.options.animation.open);return e.effects=t.parseEffects(e.effects,this.flipped),e},_hideActiveClass:function(){e(this.options.anchor).children(T).removeClass(S)},_addActiveClass:function(){e(this.options.anchor).children(T).addClass(S)},position:function(){this.visible()&&(this.flipped=this._position())},toggle:function(){this[this.visible()?d:c]()},visible:function(){return this.wrapper.is(":"+x)&&this.element.is(":"+x)},close:function(n){var i,r,o,a,s=this,l=s.element.parent(),c=s.options;if(s.visible()){if(i=s.wrapper[0]?s.wrapper:t.wrap(s.element).hide(),s._toggleResize(!1),s._closing||s._trigger(d))return void s._toggleResize(!0);s.wrapper.removeClass("k-animation-container-shown"),s.element.find(".k-popup").each((function(){var t=e(this).data("kendoPopup");t&&t.close(n)})),D.off(s.downEvent,s._mousedownProxy),n?r={hide:!0,effects:{}}:(r=I(!0,{},c.animation.close),o=l.data(C),!(a=r.effects)&&!t.size(a)&&o&&t.size(o)&&(r.effects=o,r.reverse=!0),s._closing=!0),l.kendoStop(!0),s.element.attr("aria-hidden",!0),i.css({overflow:b}).attr("aria-hidden",!0),l.kendoAnimate(r),n&&s._animationClose()}},_trigger:function(e){return this.trigger(e,{type:e})},_resize:function(e){var t=this;-1!==o.resize.indexOf(e.type)?(clearTimeout(t._resizeTimeout),t._resizeTimeout=setTimeout((function(){t._position(),t._resizeTimeout=null}),50)):(!t._hovered||t._activated&&t.element.find(".k-list").length>0)&&t.close()},_toggleResize:function(e){var t=e?"on":"off",n=o.resize;o.mobileOS.ios||o.mobileOS.android||o.browser.safari||(n+=" "+M),e&&!this.scrollableParents&&(this.scrollableParents=this._scrollableParents()),this.scrollableParents&&this.scrollableParents.length&&this.scrollableParents[t](M,this._resizeProxy),A[t](n,this._resizeProxy)},_mousedown:function(n){var i=this,r=i.element[0],o=i.options,a=e(o.anchor)[0],s=o.toggleTarget,l=t.eventTarget(n),c=e(l).closest(".k-popup"),d=c.parent().parent(".km-shim").length;c=c[0],!d&&c&&c!==i.element[0]||"popover"!==e(n.target).closest("a").data("rel")&&(H(r,l)||H(a,l)||s&&H(e(s)[0],l)||i.close())},_fit:function(e,t,n){var i=0;return e+t>n&&(i=n-(e+t)),e<0&&(i=-e),i},_flip:function(e,t,n,i,r,o,a){var s=0;return a=a||t,o!==r&&o!==p&&r!==p&&(e+a>i&&(s+=-(n+t)),e+s<0&&(s+=n+t)),s},_scrollableParents:function(){return e(this.options.anchor).parentsUntil("body").filter((function(e,n){return t.isScrollable(n)}))},_position:function(n){var i,r,c,d,u,h,p,f=this,m=f.element,g=f.wrapper,v=f.options,_=e(v.viewport),b=o.zoomLevel(),y=!!(_[0]==window&&window.innerWidth&&b<=1.02),x=e(v.anchor),C=v.origin.toLowerCase().split(" "),S=v.position.toLowerCase().split(" "),T=f.collisions,D=10002,A=0,M=document.documentElement;(u=v.viewport===window?{top:window.pageYOffset||document.documentElement.scrollTop||0,left:window.pageXOffset||document.documentElement.scrollLeft||0}:_.offset(),y?(h=window.innerWidth,p=window.innerHeight):(h=_.width(),p=_.height()),y&&M.scrollHeight-M.clientHeight>0)&&(h-=(v.isRtl?-1:1)*t.support.scrollbar());if((i=x.parents().filter(g.siblings()))[0])if(c=Math.max(Number(i.css("zIndex")),0))D=c+10;else for(d=(r=x.parentsUntil(i)).length;A<d;A++)(c=Number(e(r[A]).css("zIndex")))&&D<c&&(D=c+10);g.css("zIndex",D),n&&n.isFixed?g.css({left:n.x,top:n.y}):g.css(f._align(C,S));var E=a(g,k,x[0]===g.offsetParent()[0]),z=a(g);x.offsetParent().parent(".k-animation-container,.k-popup,.k-group,.k-menu-group").length&&(E=a(g,k,!0),z=a(g)),z.top-=u.top,z.left-=u.left,f.wrapper.data(w)||g.data(w,I({},E));var P=I({},z),H=I({},E),F=v.adjustSize;"fit"===T[0]&&(H.top+=f._fit(P.top,l(g)+F.height,p/b)),"fit"===T[1]&&(H.left+=f._fit(P.left,s(g)+F.width,h/b));var R=I({},H),L=l(m),B=l(g);return!g.height()&&L&&(B+=L),"flip"===T[0]&&(H.top+=f._flip(P.top,L,l(x),p/b,C[0],S[0],B)),"flip"===T[1]&&(H.left+=f._flip(P.left,s(m),s(x),h/b,C[1],S[1],s(g))),g.css(H),H.left!=R.left||H.top!=R.top},_align:function(t,n){var i,r=this,o=r.wrapper,c=e(r.options.anchor),d=t[0],u=t[1],h=n[0],f=n[1],g=a(c),_=e(r.options.appendTo),b=s(o)||s(o.find(".k-child-animation-container").children().first()),y=l(o)||l(o.find(".k-child-animation-container").children().first()),w=s(c),k=l(c),x=r.options.omitOriginOffsets?0:g.top,C=r.options.omitOriginOffsets?0:g.left,S=Math.round;return _[0]!=document.body&&(x-=(i=a(_)).top,C-=i.left),d===v&&(x+=k),d===p&&(x+=S(k/2)),h===v&&(x-=y),h===p&&(x-=S(y/2)),u===m&&(C+=w),u===p&&(C+=S(w/2)),f===m&&(C-=b),f===p&&(C-=S(b/2)),{top:x,left:C}}});n.plugin(F);var R=t.support.stableSort,L="kendoTabKeyTrap",B=r.extend({init:function(t,n){this.element=e(t),this.element.autoApplyNS(L)},trap:function(){this.element.on("keydown",this._keepInTrap.bind(this))},removeTrap:function(){this.element.kendoDestroy(L)},destroy:function(){this.element.kendoDestroy(L),this.element=undefined},shouldTrap:function(){return!0},_keepInTrap:function(e){if(9===e.which&&this.shouldTrap()&&!e.isDefaultPrevented()){var t=this._focusableElements(),n=this._sortFocusableElements(t),i=this._nextFocusable(e,n);i&&this._focus(i),e.preventDefault()}},_focusableElements:function(){var t=this.element.find("a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), iframe, object, embed, [tabindex], *[contenteditable]").filter((function(t,n){return n.tabIndex>=0&&e(n).is(":visible")&&!e(n).is("[disabled]")}));return this.element.is("[tabindex]")&&[].push.call(t,this.element[0]),t},_sortFocusableElements:function(e){var t;if(R)t=[].sort.call(e,(function(e,t){return e.tabIndex-t.tabIndex}));else{var n="__k_index";e.each((function(e,t){t.setAttribute(n,e)})),t=[].sort.call(e,(function(e,t){return e.tabIndex===t.tabIndex?parseInt(e.getAttribute(n),10)-parseInt(t.getAttribute(n),10):e.tabIndex-t.tabIndex})),e.removeAttr(n)}return t},_nextFocusable:function(e,t){var n=t.length,i=t.index(e.target);return t.get((i+(e.shiftKey?-1:1))%n)},_focus:function(e){"IFRAME"!=e.nodeName?(e.focus(),"INPUT"==e.nodeName&&e.setSelectionRange&&this._haveSelectionRange(e)&&e.setSelectionRange(0,e.value.length)):e.contentWindow.document.body.focus()},_haveSelectionRange:function(e){var t=e.type.toLowerCase();return"text"===t||"search"===t||"url"===t||"tel"===t||"password"===t}});n.Popup.TabKeyTrap=B}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.Class;t.html=t.html||{};var i=n.extend({init:function(t,n){this.element=e(t),delete(n=n||{}).name,this._initOptions(n)},options:{stylingOptions:[]},_addClasses:function(){var e=this,n=e.options,i=n.stylingOptions,r=e.wrapper.data("added-classes");i=i.map((function(e){var i;return"themeColor"!==e||(i=t.cssProperties.getValidClass({widget:n.name,propName:"fillMode",value:n.fillMode}))&&0!==i.length?t.cssProperties.getValidClass({widget:n.name,propName:e,value:n[e],fill:n.fillMode}):""})),r&&e.wrapper.removeClass(r.join(" ")),e.wrapper.data("added-classes",i),e.wrapper.addClass(i.join(" "))},html:function(){return this.wrapper[0].outerHTML}});e.extend(t.html,{HTMLBase:i})}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=e.extend,i=t.html.HTMLBase,r="k-i-",o="k-svg-i-",a="k-flip-",s=`${a}h`,l=`${a}v`,c={svg:(e,t)=>new p(e,t),font:(e,t)=>new h(e,t)},d={default:"",horizontal:s,vertical:l,both:`${s} ${l}`},u=i.extend({init:function(e,t){i.fn.init.call(this,e,t),this._wrapper()},options:{name:"HTMLIcon",size:"none",themeColor:"none",flip:"default",iconClass:"",stylingOptions:["size","themeColor","fill"]},_wrapper:function(){this._addClasses()},_addClasses:function(){var e=this,n=e.options,i=n.stylingOptions,r=e.wrapper.data("added-classes");i=i.map((function(e){return"themeColor"===e?t.cssProperties.getValidClass({widget:n.name,propName:e,value:n[e],prefix:"k-color-"}):"fill"===e?d[n.flip]:t.cssProperties.getValidClass({widget:n.name,propName:e,value:n[e],fill:n.fillMode})})),r&&e.wrapper.removeClass(r.filter((t=>t!==e._className)).join(" ")),e.wrapper.data("added-classes",i.concat([e._className])),e.wrapper.addClass(i.join(" "))}}),h=u.extend({init:function(e,t){u.fn.init.call(this,e,t)},options:n({},u.fn.options,{name:"HTMLFontIcon",icon:null}),_wrapper:function(){var e=this,t=e.element[0].className.split(" ").find((e=>e.includes(r))),n=e.options.icon?`${e.options.icon.startsWith(r)?"":r}${e.options.icon}`:"";e._className=n,e.wrapper=e.element.addClass("k-icon k-font-icon").removeClass(t).addClass(n).addClass(e.options.iconClass||""),u.fn._wrapper.call(this)}}),p=u.extend({init:function(e,t){e.empty(),u.fn.init.call(this,e,t)},options:n({},u.fn.options,{name:"HTMLSVGIcon",icon:null}),_wrapper:function(){var n,i=this,r=i.options.icon,a=i.options.iconClass,s=i.element[0].className.split(" ").find((e=>e.includes(o))),l=e("<svg></svg>");if(!r&&a){const e=/k-i-(\w+(?:-\w+)*)/;let t=a.match(e);t&&(r=t[1],a=a.replace(t[0],""))}t.isString(r)&&(r=r.replace("k-i-","").replace(/-./g,(e=>e[1].toUpperCase())),r=t.ui.svgIcons[r]||t.ui.svgIcons[`${r}Icon`]),n=r&&r.name?`${o}${r.name}`:"",i._className=n,i.wrapper=i.element.addClass("k-icon k-svg-icon").removeClass(s).addClass(n).addClass(a||""),e.isPlainObject(r)&&(l.attr("viewBox",r.viewBox||"").attr({viewBox:r.viewBox||"",focusable:"false",xmlns:"http://www.w3.org/2000/svg"}).html(r.content||""),i.wrapper.append(l[0].outerHTML)),u.fn._wrapper.call(this)}});e.extend(t.html,{renderIcon:function(n,i){return(!n||e.isPlainObject(n)||t.isString(n))&&(i=n,n=e("<span></span>")),t.isString(i)&&(i={icon:i}),t.isPresent(i.type)||(i.type=t.defaults.iconType?t.defaults.iconType:"svg"),t.isFunction(i.type)?i.type(n,i):t.isFunction(c[i.type])?c[i.type](n,i).html():null},HTMLFontIcon:h,HTMLSvgIcon:p,getIconRenderer:e=>c[e]}),t.cssProperties.registerPrefix("HTMLFontIcon","k-icon-"),t.cssProperties.registerValues("HTMLFontIcon",[{prop:"size",values:t.cssProperties.sizeValues.concat([["xsmall","xs"],["xlarge","xl"],["xxlarge","xxl"],["xxxlarge","xxxl"]])},{prop:"themeColor",values:["primary","secondary","tertiary","inherit","info","success","warning","error","dark","light","inverse"]}]),t.cssProperties.registerPrefix("HTMLSVGIcon","k-icon-"),t.cssProperties.registerValues("HTMLSVGIcon",[{prop:"size",values:t.cssProperties.sizeValues.concat([["xsmall","xs"],["xlarge","xl"],["xxlarge","xxl"],["xxxlarge","xxxl"]])},{prop:"themeColor",values:["primary","secondary","tertiary","inherit","info","success","warning","error","dark","light","inverse"]}])}(window.kendo.jQuery);kendo;var wh=Object.freeze({__proto__:null,accessibilityIcon:{name:"accessibility",content:'<path d="M208 48c0-26.5 21.5-48 48-48s48 21.5 48 48-21.5 48-48 48-48-21.5-48-48m240 112v-32H64v32l128 16v80l-32 224h48l32-160h32l32 160h48l-32-224v-80z" />',viewBox:"0 0 512 512"},aggregateFieldsIcon:{name:"aggregate-fields",content:'<path d="M128 128c-17.7 0-32 14.3-32 32v160c0 17.7 14.3 32 32 32h256c32 0 32-32 32-32H128zm-64 64c-17.7 0-32 14.3-32 32v160c0 17.7 14.3 32 32 32h256c32 0 32-32 32-32H64zM448 64H192c-17.6 0-32 14.4-32 32v160c0 17.6 14.4 32 32 32h256c17.6 0 32-14.4 32-32V96c0-17.6-14.4-32-32-32m1 192s0 .1 0 0l-256.9.1-.1-.1V96.1l.1-.1H448v160z" />',viewBox:"0 0 512 512"},alignBottomIcon:{name:"align-bottom",content:'<path d="M480 352H32v-32h448zm-64 32H96v32h320zm64 64H32v32h448z" />',viewBox:"0 0 512 512"},alignCenterIcon:{name:"align-center",content:'<path d="M448 96H64V64h384zm-64 64H128v-32h256zm64 64H64v-32h384zm-64 64H128v-32h256zm64 64H64v-32h384zm-64 64H128v-32h256z" />',viewBox:"0 0 512 512"},alignItemsBaselineAltIcon:{name:"align-items-baseline-alt",content:'<path d="M255 288v-64h96V96h-96V32h-32v64h-96v128h96v64H63v128h160v64h32v-64h160V288zm-32 96H95v-64h128zm0-192h-64v-64h64z" />',viewBox:"0 0 512 512"},alignItemsBaselineIcon:{name:"align-items-baseline",content:'<path d="M415 224V64H287v160h-64v-96H95v96H31v32h64v96h128v-96h64v160h128V256h64v-32zm-224 96h-64v-64h64zm192 64h-64V256h64z" />',viewBox:"0 0 512 512"},alignItemsCenterAltIcon:{name:"align-items-center-alt",content:'<path d="M479 256h-64v160H287V256h-64v96H95v-96H31v-32h64v-96h128v96h64V64h128v160h64z" />',viewBox:"0 0 512 512"},alignItemsCenterIcon:{name:"align-items-center",content:'<path d="M415 416H255v64h-32v-64H63V288h160v-64h-96V96h96V32h32v64h96v128h-96v64h160z" />',viewBox:"0 0 512 512"},alignItemsEndAltIcon:{name:"align-items-end-alt",content:'<path d="M223 417H95V193h128zM31 449v32h448v-32zM415 65H287v352h128z" />',viewBox:"0 0 512 512"},alignItemsEndIcon:{name:"align-items-end",content:'<path d="M192 96h224v128H192zm256-64v448h32V32zM64 416h352V288H64z" />',viewBox:"0 0 512 512"},alignItemsStartAltIcon:{name:"align-items-start-alt",content:'<path d="M96 96h128v224H96zM32 32v32h448V32zm256 416h128V96H288z" />',viewBox:"0 0 512 512"},alignItemsStartIcon:{name:"align-items-start",content:'<path d="M319 224H95V96h224zM31 480h32V32H31zm64-192v128h352V288z" />',viewBox:"0 0 512 512"},alignItemsStretchAltIcon:{name:"align-items-stretch-alt",content:'<path d="M223 96v320H95V96zM31 480h448v-32H31zm0-448v32h448V32zm256 63v320h128V95z" />',viewBox:"0 0 512 512"},alignItemsStretchIcon:{name:"align-items-stretch",content:'<path d="M415 224H95V96h320zM31 480h32V32H31zM447 32v448h32V32zM96 416h320V288H96z" />',viewBox:"0 0 512 512"},alignJustifyIcon:{name:"align-justify",content:'<path d="M448 160H64v-32h384zm0-96H64v32h384zM64 352h384v-32H64zm0-64h384v-32H64zm0-64h384v-32H64zm0 192h384v-32H64z" />',viewBox:"0 0 512 512"},alignLeftIcon:{name:"align-left",content:'<path d="M448 96H64V64h384zm-96 32H64v32h288zm96 64H64v32h384zm-96 64H64v32h288zm96 64H64v32h384zm-96 64H64v32h288z" />',viewBox:"0 0 512 512"},alignMiddleIcon:{name:"align-middle",content:'<path d="M480 192H32v-32h448zm-64 32H96v32h320zm64 64H32v32h448z" />',viewBox:"0 0 512 512"},alignRemoveIcon:{name:"align-remove",content:'<path d="m78.9 192 32 32H64v-32zM64 288h110.9l-32-32H64zm0 64h174.9l-32-32H64zm0 32v32h238.9l-32-32zm393.4 96 22.6-22.6-41.4-41.4h9.4v-32h-41.4l-32-32H448v-32H342.6l-32-32H448v-32H278.6l-32-32H448v-32H214.6l-32-32H448v-32H150.6l-32-32H448V64H86.6l-32-32L32 54.6" />',viewBox:"0 0 512 512"},alignRightIcon:{name:"align-right",content:'<path d="M64 192h384v32H64zm384-96V64H64v32zm-288 64h288v-32H160zM64 320v32h384v-32zm96-32h288v-32H160zm0 96v32h288v-32z" />',viewBox:"0 0 512 512"},alignSelfCenterAltIcon:{name:"align-self-center-alt",content:'<path d="M415 224V64H287v160h-64v-96H95v96H31v32h64v96h128v-96h64v160h128V256h64v-32zm-32 0v160h-64V96h64z" />',viewBox:"0 0 512 512"},alignSelfCenterIcon:{name:"align-self-center",content:'<path d="M255 288v-64h96V96h-96V32h-32v64h-96v128h96v64H63v128h160v64h32v-64h160V288zm128 96H95v-64h288z" />',viewBox:"0 0 512 512"},alignSelfEndAltIcon:{name:"align-self-end-alt",content:'<path d="M479 449v32H31v-32zM223 193H95v224h128zm192 224H287V65h128zM383 97h-64v288h64z" />',viewBox:"0 0 512 512"},alignSelfEndIcon:{name:"align-self-end",content:'<path d="M64 416h352V288H64zm32-96h288v64H96zm96-224h224v128H192zm288-64v448h-32V32z" />',viewBox:"0 0 512 512"},alignSelfStartAltIcon:{name:"align-self-start-alt",content:'<path d="M95 96h128v224H95zm192 0h128v352H287zm32 320h64V128h-64zM31 32v32h448V32z" />',viewBox:"0 0 512 512"},alignSelfStartIcon:{name:"align-self-start",content:'<path d="M31 32h32v448H31zm288 64H95v128h224zm128 192v128H95V288zm-32 32H127v64h288z" />',viewBox:"0 0 512 512"},alignSelfStretchAltIcon:{name:"align-self-stretch-alt",content:'<path d="M223 96v320H95V96zM31 480h448v-32H31zM415 96v320H287V96zm-32 32h-64v256h64zM31 32v32h448V32z" />',viewBox:"0 0 512 512"},alignSelfStretchIcon:{name:"align-self-stretch",content:'<path d="M95 96h320v128H95zM31 480h32V32H31zm64-192h320v128H95zm32 96h256v-64H127zM447 32v448h32V32z" />',viewBox:"0 0 512 512"},alignToGridIcon:{name:"align-to-grid",content:'<path d="M320 320H128V128h192zM96 0H64v512h32zm352 0h-32v512h32zm64 64H0v32h512zm0 352H0v32h512z" />',viewBox:"0 0 512 512"},alignTopIcon:{name:"align-top",content:'<path d="M480 64H32V32h448zm-64 32H96v32h320zm64 64H32v32h448z" />',viewBox:"0 0 512 512"},allIcon:{name:"all",content:'<path d="M120.1 343H52l-12 34.4c-2.9 8.5-4.4 14.8-4.4 19 0 3.3 1.3 6.2 3.8 8.8s8.1 4.2 16.5 4.9v5.9H0v-6q11.1-2.4 14.4-6.3c4.4-5.2 9.4-15.7 14.8-31.5L91.4 192H96l61.6 182.2q7.5 21.9 13.5 28.5c4 4.4 9.7 6.8 16.9 7.3v6h-70v-5.9c7-.4 11.7-1.9 14.2-4.3 2.5-2.5 3.7-5.5 3.7-9 0-4.7-1.7-12.2-5.2-22.3zm-3.5-12-30-88.5L55.8 331zm227.7 23.1 4.3 1.2-15.1 60.7H197v-6h6.5c7.4 0 12.6-3.1 15.8-9.3 1.8-3.5 2.7-11.7 2.7-24.5V222.7c0-14-1.2-13.9-3.6-17.5-3.3-4.9-8.3-7.3-14.9-7.3H196v-6h80v6.1s-15.4 1-19.2 3.3-6.4 5.2-7.8 8.8c-1.4 3.5-2.1 3.1-2 16.5v149.6c-.1 9.1.6 15.4 2 18.8 1 2.3 2.7 4 4.8 5.1 2.2 1.1 9 1.7 20.4 1.9h12.9c13.6-.2 23.1-1.5 28.6-4s10.5-7 15-13.5 9.1-16.6 13.6-30.4m163.4 0 4.3 1.2-15.1 60.7H360v-6h6.5c7.4 0 12.6-3.1 15.8-9.3 1.8-3.5 2.7-11.7 2.7-24.5V222.7c0-14-1.2-13.9-3.6-17.5-3.3-4.9-8.3-7.3-14.9-7.3H360v-6h80v6.1s-16.1 1-19.9 3.3-6.4 5.2-7.8 8.8c-1.4 3.5-2.1 3.1-2.4 16.5v149.6c.3 9.1 1 15.4 2.4 18.8 1 2.3 2.7 4 4.8 5.1s9 1.7 20.4 1.9h12.9c13.6-.2 23.1-1.5 28.6-4s10.5-7 15-13.5 9.2-16.6 13.7-30.4M512 96H0v32h512z" />',viewBox:"0 0 512 512"},anchorIcon:{name:"anchor",content:'<path d="m352 288 44.5 44.5c-22.3 40.7-61.7 70.7-108.5 80.3V151.4c19.1-11.1 32-31.8 32-55.4 0-35.3-28.7-64-64-64s-64 28.7-64 64c0 23.6 12.9 44.3 32 55.4v261.4c-46.8-9.5-86.2-39.6-108.5-80.3L160 288H32v128l36.9-36.9C108.9 439.9 177.8 480 256 480s147.1-40.1 187.1-100.9L480 416V288zM256 64c17.6 0 32 14.4 32 32s-14.4 32-32 32-32-14.4-32-32 14.4-32 32-32" />',viewBox:"0 0 512 512"},applyFormatIcon:{name:"apply-format",content:'<path d="M380.984 313.69c12.445 12.445 12.445 32.81 0 45.255L266.529 470.658c-12.445 12.445-32.787 12.467-45.255 0L0 248.898c18.584 18.584 40.255-4.835 40.255-4.835L154.71 132.671c12.445-12.445 32.81-12.445 45.255 0zm89.682-227.101-45.255-45.255c-12.445-12.445-32.81-12.445-45.255 0l-67.882 67.882-22.627-22.627c-12.445-12.445-32.81-12.445-45.255 0l-22.627 22.627 181.019 181.019 22.627-22.627c12.445-12.445 12.445-32.81 0-45.255l-22.627-22.627 67.882-67.882c12.445-12.446 12.445-32.81 0-45.255" />',viewBox:"0 0 512 512"},arrowDownIcon:{name:"arrow-down",content:'<path d="M128 224h96V96h64l.001 128H384L256.001 416z" />',viewBox:"0 0 512 512"},arrowLeftIcon:{name:"arrow-left",content:'<path d="M288 128v96h128v64l-128 .001V384L96 256.001z" />',viewBox:"0 0 512 512"},arrowOverflowDownIcon:{name:"arrow-overflow-down",content:'<path d="M384 160 256 352 128 160zM128 96v32h256V96z" />',viewBox:"0 0 512 512"},arrowRightIcon:{name:"arrow-right",content:'<path d="M224 384v-96H96v-64h128v-96l192 128z" />',viewBox:"0 0 512 512"},arrowRotateCcwIcon:{name:"arrow-rotate-ccw",content:'<path d="m62 176 55.5 32C103.8 231.6 96 258.9 96 288c0 88.2 71.8 160 160 160s160-71.8 160-160-71.8-160-160-160v64L96 96 256 0v64c123.7 0 224 100.3 224 224S379.7 512 256 512 32 411.7 32 288c0-40.8 10.9-79.1 30-112" />',viewBox:"0 0 512 512"},arrowRotateCcwSmallIcon:{name:"arrow-rotate-ccw-small",content:'<path d="m101.4 238.6 46.4 12.4c-2.5 9.3-3.8 19-3.8 29 0 61.8 50.2 112 112 112s112-50.2 112-112-50.2-112-112-112v56l-128-80 128-80v56c88.4 0 160 71.6 160 160s-71.6 160-160 160S96 368.4 96 280c0-14.3 1.9-28.2 5.4-41.4" />',viewBox:"0 0 512 512"},arrowRotateCwIcon:{name:"arrow-rotate-cw",content:'<path d="M480 288c0 123.7-100.3 224-224 224S32 411.7 32 288 132.3 64 256 64V0l160 96-160 96v-64c-88.2 0-160 71.8-160 160s71.8 160 160 160 160-71.8 160-160c0-29.1-7.8-56.4-21.5-80l55.5-32c19.1 32.9 30 71.2 30 112" />',viewBox:"0 0 512 512"},arrowRotateCwSmallIcon:{name:"arrow-rotate-cw-small",content:'<path d="M416 280c0 88.4-71.6 160-160 160S96 368.4 96 280s71.6-160 160-160V64l128 80-128 80v-56c-61.8 0-112 50.2-112 112s50.2 112 112 112 112-50.2 112-112c0-10-1.3-19.7-3.8-29l46.4-12.4c3.5 13.2 5.4 27.1 5.4 41.4" />',viewBox:"0 0 512 512"},arrowUpIcon:{name:"arrow-up",content:'<path d="M384 288h-96v128h-64l-.001-128H128L255.999 96z" />',viewBox:"0 0 512 512"},arrowsAxesIcon:{name:"arrows-axes",content:'<path d="M352 480v-64H128v64H96v-64H32v-32h64V160H32l80-128 80 128h-64v224h224v-64l128 80z" />',viewBox:"0 0 512 512"},arrowsLeftRightIcon:{name:"arrows-left-right",content:'<path d="m512 240-128-80v64H128v-64L0 240l128 80v-64h256v64z" />',viewBox:"0 0 512 512"},arrowsMoveIcon:{name:"arrows-move",content:'<path d="M384 320v-32h-96v96h32l-64 96-64-96h32v-96h-96v32l-96-64 96-64v32h96v-96h-32l64-96 64 96h-32v96h96v-32l96 64z" />',viewBox:"0 0 512 512"},arrowsNoChangeIcon:{name:"arrows-no-change",content:'<path d="M256 160 128 352 0 160zm96 0L224 352h256.001z" />',viewBox:"0 0 512 512"},arrowsNoRepeatIcon:{name:"arrows-no-repeat",content:'<path d="m321 434.2 47.5 47.5C335.5 501 297 512 256 512 132.3 512 32 411.7 32 288c0-41 11-79.5 30.3-112.6l47.5 47.5c-8.9 19.9-13.8 41.9-13.8 65 0 88.2 71.8 160 160 160 23.1.1 45.2-4.8 65-13.7m118.3-17.5c12.9-18.3 23.1-38.7 30.1-60.4 6.9-21.5 10.6-44.5 10.6-68.3 0-40.8-10.9-79.1-30-112l-55.5 32c13.6 23.5 21.5 50.9 21.5 80 0 4.8-.2 9.5-.6 14.2-2.2 24.8-10.1 47.9-22.3 68.2L173.6 150.9c20.3-12.2 43.4-20.1 68.2-22.3 4.7-.4 9.4-.6 14.2-.6v64l160-96L256 0v64c-23.8 0-46.7 3.7-68.3 10.6-21.8 7-42.1 17.2-60.4 30.1L22.6 0 0 22.6 489.4 512l22.6-22.6z" />',viewBox:"0 0 512 512"},arrowsSwapIcon:{name:"arrows-swap",content:'<path d="M256 160h-64v224h-32V160H96l80-128zm96 192V128h-32v224h-64l80 128 80-128z" />',viewBox:"0 0 512 512"},arrowsTopBottomIcon:{name:"arrows-top-bottom",content:'<path d="m240 512 80-128h-64V128h64L240 0l-80 128h64v256h-64z" />',viewBox:"0 0 512 512"},barcodeIcon:{name:"barcode",content:'<path d="M480 64H32C14.3 64 0 78.3 0 96v320c0 17.7 14.3 32 32 32h448c17.7 0 32-14.3 32-32V96c0-17.7-14.3-32-32-32M96 384H64V128h32zm96-32h-64V128h64zm64 0h-32V128h32zm64 0h-32V128h32zm64 0h-32V128h32zm64 32h-32V128h32z" />',viewBox:"0 0 512 512"},barcodeOutlineIcon:{name:"barcode-outline",content:'<path d="M96 384H64V128h32zm96-256h-64v224h64zm64 0h-32v224h32zm64 0h-32v224h32zm64 0h-32v224h32zm64 0h-32v256h32zm64-32v320c0 17.7-14.3 32-32 32H32c-17.7 0-32-14.3-32-32V96c0-17.7 14.3-32 32-32h448c17.7 0 32 14.3 32 32m-32 0H32v320h448z" />',viewBox:"0 0 512 512"},barcodeQrCodeScannerIcon:{name:"barcode-qr-code-scanner",content:'<path d="M256 288h32v128h-32zm64 128h64V288h-64zm128 0V288h-32v128zM32 32h64V0H0v96h32zm0 352H0v96h96v-32H32zM416 0v32h64v64h32V0zm64 448h-64v32h96v-96h-32zm0-224H32v32h448zM288 64h-32v128h32zm96 0h-64v128h64zm64 0h-32v128h32zM64 64h96v96H64zm32 64h32V96H96zm128 32h-32v32h32zm0-96h-32v64h32zM64 320h96v96H64zm32 64h32v-32H96zm96 0v32h32v-64h-32zm0-64h32v-32h-32z" />',viewBox:"0 0 512 512"},barcodeScannerIcon:{name:"barcode-scanner",content:'<path d="M32 96H0V0h96v32H32zm0 288H0v96h96v-32H32zM416 0v32h64v64h32V0zm64 448h-64v32h96v-96h-32zm-192-32h32V288h-32zm32-352h-32v128h32zm-64 0h-32v128h32zM128 416h64V288h-64zm-64 0h32V288H64zM192 64h-64v128h64zm32 352h32V288h-32zM64 64v128h32V64zm384 0h-32v128h32zm0 352V288h-32v128zm-96 0h32V288h-32zm32-352h-32v128h32zm96 160H32v32h448z" />',viewBox:"0 0 512 512"},behanceBoxIcon:{name:"behance-box",content:'<path d="M167.543 228.938h-56.884v-56.479h50.939q16.803 0 27.663 3.988c8.376 3.844 12.576 11.718 12.576 23.652 0 10.735-3.197 18.249-9.511 22.482-6.368 4.219-14.612 6.357-24.783 6.357m220.527 11.836c-7.313-6.494-16.367-9.727-27.217-9.727-11.76 0-20.895 3.427-27.378 10.335-6.483 6.881-10.555 16.249-12.242 28.021h79.079c-.83-12.573-4.902-22.079-12.242-28.629m-196.379 34.862c-5.575-2.774-13.369-4.219-23.409-4.335h-57.624v68.255h56.831c10.146 0 18.072-1.503 23.726-4.508 10.251-5.577 15.377-16.211 15.377-31.931 0-13.35-4.967-22.482-14.901-27.481M480 64v384c0 17.664-14.336 32-32 32H64c-17.664 0-32-14.336-32-32V64c0-17.664 14.336-32 32-32h384c17.664 0 32 14.336 32 32m-176 96h112v-32H304zm-48 146.729c0-14.709-3.065-27.221-9.142-37.509-6.078-10.316-15.087-17.829-27.056-22.597 7.873-4.392 13.845-9.247 17.887-14.564 7.213-9.507 10.806-22.077 10.806-37.711 0-15.171-3.593-28.175-10.727-39.055-11.916-17.743-32.128-26.846-60.689-27.293H64v256h105.445c11.889 0 22.907-1.127 33.079-3.439 10.172-2.341 18.97-6.618 26.447-12.859 6.632-5.433 12.154-12.166 16.592-20.17C252.512 335.51 256 321.899 256 306.729m190.442-42.024c-2.117-14.204-6.804-26.667-14.01-37.444-7.956-12.187-18.082-21.126-30.324-26.777-12.242-5.665-25.985-8.484-41.254-8.484-25.744 0-46.638 8.387-62.765 25.091-16.127 16.746-24.163 40.788-24.163 72.18 0 33.437 8.894 57.644 26.762 72.456C318.555 376.594 339.155 384 362.514 384c28.288 0 50.308-8.788 66.033-26.391 10.072-11.081 15.778-26.86 17.011-37.609h-46.879c-1.178 6-2.512 10.667-9.429 17.327-6.536 5.555-15.028 8.318-25.476 8.318-9.858 0-18.297-2.266-25.288-6.798-11.546-7.323-17.654-18.977-18.35-37.133h127.807c.24-15.641-.269-28.691-1.501-37.009" />',viewBox:"0 0 512 512"},behanceIcon:{name:"behance",content:'<path d="M448 128H304V96h144zM245.335 254.873c7.09 11.573 10.665 25.65 10.665 42.197 0 17.067-4.069 32.379-12.176 45.903-5.178 9.005-11.62 16.58-19.358 22.691-8.723 7.022-18.988 11.833-30.855 14.467C181.744 382.732 168.89 384 155.02 384H32V96h131.927c33.321.504 56.901 10.744 70.803 30.705 8.323 12.24 12.515 26.869 12.515 43.936 0 17.588-4.192 31.729-12.607 42.425-4.716 5.982-11.683 11.443-20.868 16.385 13.963 5.364 24.474 13.817 31.565 25.422m-158.9-45.318H152.8c11.867 0 21.484-2.406 28.913-7.152 7.367-4.763 11.097-13.215 11.097-25.292 0-13.426-4.901-22.285-14.672-26.609q-12.67-4.486-32.273-4.486h-59.43zm111.923 83.452c0-15.019-5.795-25.292-17.385-30.917-6.504-3.121-15.597-4.746-27.31-4.876H86.435v76.787h66.303c11.836 0 21.084-1.69 27.68-5.071 11.96-6.275 17.94-18.238 17.94-35.923M479.932 288H330.824c.813 21.182 7.938 34.778 21.409 43.322 8.157 5.287 18.002 7.931 29.503 7.931 12.189 0 22.096-3.224 29.722-9.704 4.157-3.482 7.813-8.318 11.001-14.541h54.693c-1.438 12.541-8.095 25.276-19.846 38.204C438.959 373.748 413.269 384 380.266 384c-27.253 0-51.286-8.64-72.132-25.985-20.846-17.28-31.222-45.522-31.222-84.532 0-36.624 9.376-64.672 28.19-84.21C323.917 169.785 348.294 160 378.328 160c17.814 0 33.847 3.288 48.129 9.898 14.282 6.593 26.096 17.023 35.378 31.24 8.407 12.573 13.876 27.114 16.346 43.685 1.438 9.704 2.033 24.929 1.751 43.177m-55.567-37.696c-.969-14.669-5.72-25.759-14.283-33.4-8.532-7.576-19.095-11.348-31.753-11.348-13.72 0-24.377 3.998-31.94 12.058-7.563 8.028-12.314 18.957-14.282 32.691z" />',viewBox:"0 0 512 512"},bellIcon:{name:"bell",content:'<path d="M192 416h128c0 35.3-28.7 64-64 64s-64-28.7-64-64m160-256c0-42-26.9-77.6-64.4-90.7.3-1.7.4-3.5.4-5.3 0-17.7-14.3-32-32-32s-32 14.3-32 32c0 1.8.2 3.6.4 5.3C186.9 82.4 160 118 160 160c0 88.4-43 160-96 160v64h384v-64c-53 0-96-71.6-96-160" />',viewBox:"0 0 512 512"},binocularsIcon:{name:"binoculars",content:'<path d="M480 288v96c0 17.7-14.3 32-32 32h-96c-17.7 0-32-14.3-32-32v-64H192v64c0 17.7-14.3 32-32 32H64c-17.7 0-32-14.3-32-32v-96c0-17.7 14.3-32 32-32v-64c0-17.7 14.3-32 32-32v-32c0-17.7 14.3-32 32-32h64s32 0 32 32v128h64V128c0-32 32-32 32-32h64c17.7 0 32 14.3 32 32v32c17.7 0 32 14.3 32 32v64c17.7 0 32 14.3 32 32M208 64h16V32h-96v32zm160 0h16V32h-96v32zM48 448H32v32h160v-32zm272 32h160v-32H320z" />',viewBox:"0 0 512 512"},bloggerBoxIcon:{name:"blogger-box",content:'<path d="M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m-31 280.7c0 57.1-46.6 103.3-104.2 103.3H200.4C142.7 416 96 369.8 96 312.7V199.3C96 142.2 142.7 96 200.4 96h52.1C310 96 356 138.9 356 196c.7 10.7 10.4 20 21.4 20h18c11.5 0 20.7 12.1 20.6 23.5zM196 216h60c11 0 20-9 20-20s-9-20-20-20h-60c-11 0-20 9-20 20s9 20 20 20m120 80H196c-11 0-20 9-20 20s9 20 20 20h120c11 0 20-9 20-20s-9-20-20-20" />',viewBox:"0 0 512 512"},bloggerIcon:{name:"blogger",content:'<path d="M188.9 64C119.9 64 64 119.5 64 188v136.1C64 392.5 119.9 448 188.9 448h134.4c69 0 124.7-55.5 124.7-123.9v-87.9c0-13.7-11-28.2-24.8-28.2h-21.5c-13.2 0-24.7-11.2-25.6-24 0-68.5-55.2-120-124.2-120zm-4.9 96h72c13.2 0 24 10.8 24 24s-10.8 24-24 24h-72c-13.2 0-24-10.8-24-24s10.8-24 24-24m0 144h144c13.2 0 24 10.8 24 24s-10.8 24-24 24H184c-13.2 0-24-10.8-24-24s10.8-24 24-24" />',viewBox:"0 0 512 512"},blurIcon:{name:"blur",content:'<path d="M384 320c0 64-32 128-128 128-64 0-128-48-128-128 0-96 128-128 128-256 0 0 128 129.1 128 256" />',viewBox:"0 0 512 512"},boldIcon:{name:"bold",content:'<path d="M128 96h115.8c25.3 0 44.2 1.1 56.6 3.2s23.6 6.5 33.4 13.2q14.7 10.05 24.6 26.7c6.6 11.1 9.8 23.6 9.8 37.4 0 15-4.1 28.7-12.1 41.2-8.1 12.5-19.1 21.9-32.9 28.2 19.5 5.7 34.5 15.4 45 29s15.7 29.8 15.7 48.2c0 14.6-3.4 28.7-10.2 42.4-6.7 13.8-16 24.8-27.7 33s-26.1 13.3-43.3 15.2c-10.8 1.2-36.7 1.9-78 2.2H128zm64 53v74h30.9c25.2 0 40.8-.4 46.9-1.1 11.1-1.3 19.7-5.2 26.1-11.5 6.3-6.3 9.5-14.7 9.5-25 0-9.9-2.7-18-8.2-24.1-5.5-6.2-13.6-10-24.4-11.2-6.4-.7-24.8-1.1-55.2-1.1zm0 127.1V362h48.6c23.4 0 38.1-.7 44.5-2 9.6-1.8 17.5-6 23.6-12.8s9-15.9 9-27.3c0-9.6-2.3-17.9-7-24.6s-11.4-11.6-20.3-14.7c-8.8-3.1-28-4.6-57.5-4.6z" />',viewBox:"0 0 512 512"},bookIcon:{name:"book",content:'<path d="M448 480V96h-32v352H128c-17.6 0-32-14.4-32-32s14.4-32 32-32h256V32H128c-35.2 0-64 28.8-64 64v320c0 23.6 12.9 44.2 32 55.3 9.4 5.5 20.4 8.7 32 8.7zM128 64h224v288H128zm192 64H160V96h160zm0 128H160v-32h160zm-32-64H160v-32h128z" />',viewBox:"0 0 512 512"},borderBottomIcon:{name:"border-bottom",content:'<path d="M32 448v-32h416v32zm32-96H32v32h32zm0-32H32v-32h32zm0-64H32v-32h32zm0-64H32v-32h32zm0-64H32V96h32zm384 192h-32v-32h32zm0-64h-32v-32h32zm0-64h-32v-32h32zm0-64h-32V96h32zM128 256H96v-32h32zm64 0h-32v-32h32zm64 128h-32v-32h32zm0-64h-32v-32h32zm0-64h-32v-32h32zm0-64h-32v-32h32zm0-64h-32V96h32zm0-64h-32V32h32zM64 32H32v32h32zm64 32H96V32h32zm64 0h-32V32h32zm128-32h-32v32h32zm64 32h-32V32h32zm64 0h-32V32h32zM320 224h-32v32h32zm64 32h-32v-32h32zm64 128h-32v-32h32z" />',viewBox:"0 0 512 512"},borderColorIcon:{name:"border-color",content:'<path d="M480 384v96H168l95.9-96zm-80-182.14L121.86 480H32v-89.86L310.14 112zm-65.28-24.89-22.4-22.4L82.56 384.01l-5.44 5.44 22.72 22.72L128 384.01zm136.02-45.98L426.03 176 336 86.29l45.01-45.02c12.36-12.36 32.33-12.36 45.01 0l44.71 45.02c12.36 12.04 12.36 32.33 0 44.69z" />',viewBox:"0 0 512 512"},borderLeftIcon:{name:"border-left",content:'<path d="M32 32h32v416H32zm96 32V32H96v32zm32 0V32h32v32zm64 0V32h32v32zm64 0V32h32v32zm64 0V32h32v32zM160 448v-32h32v32zm64 0v-32h32v32zm64 0v-32h32v32zm64 0v-32h32v32zM224 128V96h32v32zm0 64v-32h32v32zM96 256v-32h32v32zm64 0v-32h32v32zm64 0v-32h32v32zm64 0v-32h32v32zm64 0v-32h32v32zm64 0v-32h32v32zm32-192V32h-32v32zm-32 64V96h32v32zm0 64v-32h32v32zm32 128v-32h-32v32zm-32 64v-32h32v32zm0 64v-32h32v32zM256 320v-32h-32v32zm-32 64v-32h32v32zM96 448v-32h32v32z" />',viewBox:"0 0 512 512"},borderRadiusBottomLeftIcon:{name:"border-radius-bottom-left",content:'<path d="M384 368c0 8.8-7.2 16-16 16h-64c-97 0-176-79-176-176v-64c0-8.8 7.2-16 16-16s16 7.2 16 16v64c0 79.4 64.6 144 144 144h64c8.8 0 16 7.2 16 16" />',viewBox:"0 0 512 512"},borderRadiusBottomRightIcon:{name:"border-radius-bottom-right",content:'<path d="M368 128c8.8 0 16 7.2 16 16v64c0 97-79 176-176 176h-64c-8.8 0-16-7.2-16-16s7.2-16 16-16h64c79.4 0 144-64.6 144-144v-64c0-8.8 7.2-16 16-16" />',viewBox:"0 0 512 512"},borderRadiusIcon:{name:"border-radius",content:'<path d="M64 32h96v32H64v96H32V32zm384 416h-96v32h128V352h-32zM352 32v32h96v96h32V32zM64 352H32v128h128v-32H64z" />',viewBox:"0 0 512 512"},borderRadiusTopLeftIcon:{name:"border-radius-top-left",content:'<path d="M144 384c-8.8 0-16-7.2-16-16v-64c0-97 79-176 176-176h64c8.8 0 16 7.2 16 16s-7.2 16-16 16h-64c-79.4 0-144 64.6-144 144v64c0 8.8-7.2 16-16 16" />',viewBox:"0 0 512 512"},borderRadiusTopRightIcon:{name:"border-radius-top-right",content:'<path d="M128 144c0-8.8 7.2-16 16-16h64c97 0 176 79 176 176v64c0 8.8-7.2 16-16 16s-16-7.2-16-16v-64c0-79.4-64.6-144-144-144h-64c-8.8 0-16-7.2-16-16" />',viewBox:"0 0 512 512"},borderRightIcon:{name:"border-right",content:'<path d="M448 448h-32V32h32zM384 64V32h-32v32zm-96 0V32h32v32zm-64 0V32h32v32zm-64 0V32h32v32zm-64 0V32h32v32zm192 384v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zm128-320V96h32v32zm0 64v-32h32v32zm128 64v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zM64 64V32H32v32zm-32 64V96h32v32zm0 64v-32h32v32zm32 128v-32H32v32zm-32 64v-32h32v32zm0 64v-32h32v32zm224-128v-32h-32v32zm-32 64v-32h32v32zm128 64v-32h32v32z" />',viewBox:"0 0 512 512"},borderStyleBottomIcon:{name:"border-style-bottom",content:'<path d="M96 480v-64h320v64zm1-416h320V32H97zM64 416V96H32v320zm416 0V96h-32v320z" />',viewBox:"0 0 512 512"},borderStyleIcon:{name:"border-style",content:'<path d="M32 96h32v320H32zm416 1h32v320h-32zM96 32h320v32H96zm0 416h320v32H96z" />',viewBox:"0 0 512 512"},borderStyleLeftIcon:{name:"border-style-left",content:'<path d="M32 96h64v320H32zm416 1v320h32V97zM96 64h320V32H96zm0 416h320v-32H96z" />',viewBox:"0 0 512 512"},borderStyleRightIcon:{name:"border-style-right",content:'<path d="M480 416h-64V96h64zm-416-1V95H32v320zm352 33H96v32h320zm0-416H96v32h320z" />',viewBox:"0 0 512 512"},borderStyleTopIcon:{name:"border-style-top",content:'<path d="M416 32v64H96V32zm-1 416H95v32h320zm33-352v320h32V96zM32 96v320h32V96z" />',viewBox:"0 0 512 512"},borderTopIcon:{name:"border-top",content:'<path d="M448 32v32H32V32zM64 96H32v32h32zm0 96H32v-32h32zm0 64H32v-32h32zm0 64H32v-32h32zm0 64H32v-32h32zm384-192h-32v-32h32zm0 64h-32v-32h32zm0 64h-32v-32h32zm0 64h-32v-32h32zM128 256H96v-32h32zm64 0h-32v-32h32zm64-128h-32V96h32zm0 64h-32v-32h32zm0 64h-32v-32h32zm0 64h-32v-32h32zm0 64h-32v-32h32zm0 64h-32v-32h32zM64 416H32v32h32zm64 32H96v-32h32zm64 0h-32v-32h32zm128-32h-32v32h32zm64 32h-32v-32h32zm64 0h-32v-32h32zM320 224h-32v32h32zm64 32h-32v-32h32zm64-128h-32V96h32z" />',viewBox:"0 0 512 512"},borderTypeIcon:{name:"border-type",content:'<path d="M479 96H33v64h446zM96 384c0-17.67-14.33-32-32-32s-32 14.33-32 32 14.33 32 32 32 32-14.33 32-32m128 0c0-17.67-14.33-32-32-32s-32 14.33-32 32 14.33 32 32 32 32-14.33 32-32m128 0c0-17.67-14.33-32-32-32s-32 14.33-32 32 14.33 32 32 32 32-14.33 32-32m128 0c0-17.67-14.33-32-32-32s-32 14.33-32 32 14.33 32 32 32 32-14.33 32-32M224 224H32v64h192zm256 0H288v64h192z" />',viewBox:"0 0 512 512"},bordersAllIcon:{name:"borders-all",content:'<path d="M32 32v416h416V32zm32 32h160v160H64zm0 352V256h160v160zm352 0H256V256h160zm0-192H256V64h160z" />',viewBox:"0 0 512 512"},bordersInsideHorizontalIcon:{name:"borders-inside-horizontal",content:'<path d="M448 224v32H32v-32zM64 32H32v32h32zm0 96H32V96h32zm0 64H32v-32h32zm0 128H32v-32h32zm0 64H32v-32h32zm384-256h-32V96h32zm0 64h-32v-32h32zm0 128h-32v-32h32zm0 64h-32v-32h32zM128 64H96V32h32zm64 0h-32V32h32zm64 0h-32V32h32zm0 64h-32V96h32zm0 64h-32v-32h32zm0 128h-32v-32h32zm0 64h-32v-32h32zm0 64h-32v-32h32zM64 416H32v32h32zm64 32H96v-32h32zm64 0h-32v-32h32zm128-32h-32v32h32zm64 32h-32v-32h32zm64 0h-32v-32h32zM320 32h-32v32h32zm64 32h-32V32h32zm64 0h-32V32h32z" />',viewBox:"0 0 512 512"},bordersInsideIcon:{name:"borders-inside",content:'<path d="M64 64H32V32h32zm0 32H32v32h32zm0 64H32v32h32zm0 128H32v32h32zm0 64H32v32h32zM448 96h-32v32h32zm0 64h-32v32h32zm0 128h-32v32h32zm0 64h-32v32h32zM128 32H96v32h32zm64 0h-32v32h32zM64 416H32v32h32zm64 0H96v32h32zm64 0h-32v32h32zm128 0h-32v32h32zm64 0h-32v32h32zm64 0h-32v32h32zM320 32h-32v32h32zm64 0h-32v32h32zm64 0h-32v32h32zm0 192H256V32h-32v192H32v32h192v192h32V256h192z" />',viewBox:"0 0 512 512"},bordersInsideVerticalIcon:{name:"borders-inside-vertical",content:'<path d="M256 448h-32V32h32zM448 64V32h-32v32zm-96 0V32h32v32zm-64 0V32h32v32zm-128 0V32h32v32zm-64 0V32h32v32zm256 384v-32h32v32zm-64 0v-32h32v32zm-128 0v-32h32v32zm-64 0v-32h32v32zm320-320V96h32v32zm0 64v-32h32v32zm0 64v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zm-128 0v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zM64 64V32H32v32zm-32 64V96h32v32zm0 64v-32h32v32zm32 128v-32H32v32zm-32 64v-32h32v32zm0 64v-32h32v32zm416-128v-32h-32v32zm-32 64v-32h32v32zm0 64v-32h32v32z" />',viewBox:"0 0 512 512"},bordersNoneIcon:{name:"borders-none",content:'<path d="M384 64V32h-32v32zm-96 0V32h32v32zm-64 0V32h32v32zm-64 0V32h32v32zm-64 0V32h32v32zm192 384v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zm128-320V96h32v32zm0 64v-32h32v32zm128 64v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zm-64 0v-32h32v32zM64 64V32H32v32zm-32 64V96h32v32zm0 64v-32h32v32zm32 128v-32H32v32zm-32 64v-32h32v32zm0 64v-32h32v32zm384-192v-32h32v32zm32-192V32h-32v32zm-32 64V96h32v32zm0 64v-32h32v32zm32 128v-32h-32v32zm-32 64v-32h32v32zm0 64v-32h32v32zM256 320v-32h-32v32zm-32 64v-32h32v32zm128 64v-32h32v32z" />',viewBox:"0 0 512 512"},bordersOutsideIcon:{name:"borders-outside",content:'<path d="M128 256H96v-32h32zm64-32h-32v32h32zm64 0h-32v32h32zm0-64h-32v32h32zm0-64h-32v32h32zm0 256h-32v32h32zm0-64h-32v32h32zm64-64h-32v32h32zm64 0h-32v32h32zm64-192v416H32V32zm-32 32H64v352h352z" />',viewBox:"0 0 512 512"},bordersShowHideIcon:{name:"borders-show-hide",content:'<path d="M64 448h128v32H32V32h448v128h-32V64H64zm384 0h-64v32h96v-96h-32zM160 288v-64H96v64zm64 0h64v-64h-64zm160-32v-32h-32v32zM288 96h-64v64h64zm0 384L160 352l45-45 83 83 147-147 45 45z" />',viewBox:"0 0 512 512"},boxSizingIcon:{name:"box-sizing",content:'<path d="M32 0H0v480h480V0zm416 448H32V32h416zm-96-320h-32V96h32zM96 192H64v-32h32zm0-64H64V96h32zm64 0h-32V96h32zm64 0h-32V96h32zm64 0h-32V96h32zM96 256H64v-32h32zm320-128h-32V96h32zm0 128h-32v-32h32zm0-64h-32v-32h32zM96 384H64v-32h32zm256 0h-32v-32h32zm-192 0h-32v-32h32zm64 0h-32v-32h32zm64 0h-32v-32h32zm128 0h-32v-32h32zM96 320H64v-32h32zm320 0h-32v-32h32z" />',viewBox:"0 0 512 512"},brightnessContrastIcon:{name:"brightness-contrast",content:'<path d="M165.5 346.5c12.4 12.5 12.4 32.9 0 45.3l-22.6 22.6c-12.5 12.4-32.8 12.4-45.3 0-12.4-12.5-12.4-32.9 0-45.3l22.6-22.6c12.5-12.4 32.9-12.4 45.3 0M256 128c17.6 0 32-14.4 32-32V64c0-17.6-14.4-32-32-32s-32 14.4-32 32v32c0 17.6 14.4 32 32 32m135.8 37.5 22.6-22.6c12.4-12.4 12.4-32.8 0-45.3-12.4-12.4-32.8-12.4-45.3 0l-22.6 22.6c-12.4 12.4-12.4 32.8 0 45.3 12.5 12.4 32.8 12.4 45.3 0m-271.6 0c12.4 12.4 32.8 12.4 45.3 0 12.4-12.4 12.4-32.8 0-45.3l-22.6-22.6c-12.4-12.4-32.8-12.4-45.3 0-12.4 12.5-12.4 32.8 0 45.3zM128 256c0-17.6-14.4-32-32-32H64c-17.6 0-32 14.4-32 32s14.4 32 32 32h32c17.6 0 32-14.4 32-32m263.8 90.5c-12.4-12.4-32.8-12.4-45.3 0-12.4 12.5-12.4 32.8 0 45.3l22.6 22.6c12.4 12.4 32.8 12.4 45.3 0 12.4-12.4 12.4-32.8 0-45.3zM448 224h-32c-17.6 0-32 14.4-32 32s14.4 32 32 32h32c17.6 0 32-14.4 32-32s-14.4-32-32-32m-96 32c0 53-43 96-96 96s-96-43-96-96 43-96 96-96 96 43 96 96m-32 0c0-35.3-28.7-64-64-64v128c35.3 0 64-28.7 64-64m-64 128c-17.6 0-32 14.4-32 32v32c0 17.6 14.4 32 32 32s32-14.4 32-32v-32c0-17.6-14.4-32-32-32" />',viewBox:"0 0 512 512"},bringBackwardIcon:{name:"bring-backward",content:'<path d="M192 192v256h256V192zm224 224H224V224h192zM320 64H64v256h96V160h160z" />',viewBox:"0 0 512 512"},bringForwardIcon:{name:"bring-forward",content:'<path d="M448 192v256H192V320H64V64h256v128zm-32 32h-96v96h-96v96h192z" />',viewBox:"0 0 512 512"},bringToBackIcon:{name:"bring-to-back",content:'<path d="M128 192h64V64H64v128zM96 96h64v64H96zm192 192h96V128H224v96h-96v160h160zm128 32h-96v128h128V320zm0 96h-64v-64h64z" />',viewBox:"0 0 512 512"},bringToFrontIcon:{name:"bring-to-front",content:'<path d="M96 128V96h96V64H64v128h32zm224 256h64V128H128v256zm96-64v96h-96v32h128V320z" />',viewBox:"0 0 512 512"},brushIcon:{name:"brush",content:'<path d="M32 480s46.4-5.6 96-16c22.3-4.7 46.9-14 70.7-37.7 56.9-56.9.2-112.9.2-112.9s-56.7-56.9-113.3-.2c-23.4 23.4-20.1 57.1-19.7 89.8.8 59.7-33.9 77-33.9 77M470.7 64 448 41.3c-12.4-12.4-32.8-12.4-45.3 0L204.3 239.8c11.5 5.8 20.8 12.2 27.7 17.6 5.3 4.2 9.2 7.7 11.3 9.8l.8.8.8.8c2.1 2.1 5.6 5.9 9.7 11.1 5.4 6.8 11.8 16.2 17.6 27.6l23.5-23.5 174.9-174.9c12.5-12.3 12.5-32.7.1-45.1M448 86.6 277.4 257.3c-4.8-5.8-8.6-9.9-10.6-11.9-2.3-2.3-6.3-6.1-12-10.7L425.4 64h.1z" />',viewBox:"0 0 512 512"},buildingBlocksIcon:{name:"building-blocks",content:'<path d="M127.9 289V128H160V80c0-8.8 7.2-16 16-16h32c8.8 0 16 7.2 16 16v48h64V80c0-8.8 7.2-16 16-16h32c8.8 0 16 7.2 16 16v48h32v160zM96 320v-48c0-8.8-7.2-16-16-16H48c-8.8 0-16 7.2-16 16v48H0v128h224V320zm384 0v-48c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v48H288v128h224V320z" />',viewBox:"0 0 512 512"},buttonIcon:{name:"button",content:'<path d="m130.1 130.1 36.1 93.9H64c-17.6 0-32-14.4-32-32V64c0-17.6 14.4-32 32-32h384c17.6 0 32 14.4 32 32v128c0 17.6-14.4 32-32 32h-73.8zM480 299 185.8 185.8 299 480l22.6-113.1L434.7 480l45.3-45.3-113.1-113.1z" />',viewBox:"0 0 512 512"},calculatorIcon:{name:"calculator",content:'<path d="M64 64v384h384V64zm96 352H96v-64h64zm0-96H96v-64h64zm96 96h-64v-64h64zm0-96h-64v-64h64zm160 96h-96V256h96zm0-224H96V96h320z" />',viewBox:"0 0 512 512"},calendarDateIcon:{name:"calendar-date",content:'<path d="M448 32h-64V0h-64v32H192V0h-64v32H64c-17.6 0-32 14.4-32 32v384c0 17.6 14.4 32 32 32h384c17.6 0 32-14.4 32-32V64c0-17.6-14.4-32-32-32m0 416-383.9.1-.1-.1V192h384zm0-288H64V64.1l.1-.1H128v32h64V64h128v32h64V64h63.9l.1.1zM192 270.6S171.9 288 142 288v-32c29.9 0 58-32 58-32h24v192h-32zM384 416H256v-14.2c0-9.7 1.6-18.4 4.8-26 3.3-7.7 7.3-14.6 12.2-20.7 4.8-6.1 10.2-11.5 15.9-16.2s11.3-8.9 16.4-12.7c5.5-3.9 10.3-7.7 14.4-11.3 4.2-3.6 7.6-7.2 10.4-10.7q4.2-5.25 6.3-10.8 2.1-5.4 2.1-11.7c0-8.1-2.3-14.1-6.8-18.4-4.5-4.1-11.5-6.2-20.7-6.2-16 0-31.5 6.4-46.1 19.4v-37.1c16.5-10.6 35-16.1 55.5-16.1 9.6 0 18.2 1.3 25.7 3.8 7.6 2.5 14.1 6.1 19.3 10.7s9.3 10.3 12.1 17c2.7 6.6 4.1 14.1 4.1 22.3 0 8.7-1.4 16.6-4 23.3-2.7 6.8-6.3 12.9-10.6 18.5-4.5 5.6-9.5 10.6-15.3 15.2s-11.8 9.1-18 13.4c-4.2 3-8.3 5.9-12.2 8.9-3.9 2.9-7.4 5.8-10.4 8.7s-5.3 5.7-7.1 8.4c-1.9 2.7-2.7 7.8-2.7 10.3H384z" />',viewBox:"0 0 512 512"},calendarIcon:{name:"calendar",content:'<path d="M416 416H288V288h128zm64-352v384c0 17.6-14.4 32-32 32H64c-17.6 0-32-14.4-32-32V64c0-17.6 14.4-32 32-32h64V0h64v32h128V0h64v32h64c17.6 0 32 14.4 32 32m-32 128H64v255.9l.1.1 383.9-.1zm0-127.9q-.15-.15 0 0l-64-.1v32h-64V64H192v32h-64V64H64.1l-.1.1V160h384z" />',viewBox:"0 0 512 512"},cameraIcon:{name:"camera",content:'<path d="M448 128h-64l-64-64H192l-64 64H64c-17.6 0-32 14.4-32 32v288c0 17.6 14.4 32 32 32h384c17.6 0 32-14.4 32-32V160c0-17.6-14.4-32-32-32M256 416c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112m64-112c0 35.3-28.7 64-64 64s-64-28.7-64-64 28.7-64 64-64 64 28.7 64 64" />',viewBox:"0 0 512 512"},cancelCircleIcon:{name:"cancel-circle",content:'<path d="m169.4 214.6 128 128c-12.5 6-26.6 9.4-41.4 9.4-52.9 0-96-43.1-96-96 0-14.8 3.4-28.8 9.4-41.4M256 160c-14.8 0-28.8 3.4-41.4 9.4l128 128c6-12.5 9.4-26.6 9.4-41.4 0-52.9-43.1-96-96-96m224 96c0 123.7-100.3 224-224 224S32 379.7 32 256 132.3 32 256 32s224 100.3 224 224m-64 0c0-88.2-71.8-160-160-160-32.6 0-62.9 9.8-88.2 26.6-17.9 11.9-33.4 27.3-45.3 45.3C105.8 193.1 96 223.4 96 256c0 88.2 71.8 160 160 160 32.6 0 62.9-9.8 88.2-26.6 17.9-11.9 33.4-27.3 45.3-45.3 16.7-25.2 26.5-55.5 26.5-88.1" />',viewBox:"0 0 512 512"},cancelIcon:{name:"cancel",content:'<path d="M256 32c-50.3 0-96.8 16.6-134.1 44.6-17.2 12.8-32.4 28.1-45.3 45.3C48.6 159.2 32 205.7 32 256c0 123.7 100.3 224 224 224 50.3 0 96.8-16.6 134.1-44.6 17.2-12.8 32.4-28.1 45.3-45.3 28-37.4 44.6-83.8 44.6-134.1 0-123.7-100.3-224-224-224m0 384c-88.2 0-160-71.8-160-160 0-32.6 9.8-62.9 26.6-88.2l221.6 221.6C318.9 406.2 288.6 416 256 416m133.4-71.8L167.8 122.6C193.1 105.8 223.4 96 256 96c88.2 0 160 71.8 160 160 0 32.6-9.8 62.9-26.6 88.2" />',viewBox:"0 0 512 512"},cancelOutlineIcon:{name:"cancel-outline",content:'<path d="M256 32c-56.1 0-107.4 20.6-146.7 54.7-8.1 7-15.6 14.6-22.6 22.6C52.6 148.6 32 199.9 32 256c0 123.7 100.3 224 224 224 56.1 0 107.4-20.6 146.7-54.7 8.1-7 15.6-14.6 22.6-22.6C459.4 363.4 480 312.1 480 256c0-123.7-100.3-224-224-224m0 416c-106 0-192-86-192-192 0-47.2 17.1-90.5 45.4-124L380 402.6c-33.5 28.3-76.8 45.4-124 45.4m146.6-68L132 109.4C165.5 81.1 208.8 64 256 64c106 0 192 86 192 192 0 47.2-17.1 90.5-45.4 124" />',viewBox:"0 0 512 512"},caretAltDownIcon:{name:"caret-alt-down",content:'<path d="M256 352 128 160h256z" />',viewBox:"0 0 512 512"},caretAltExpandIcon:{name:"caret-alt-expand",content:'<path d="M128 288h256L256 480zM256 32 128 224h256.001z" />',viewBox:"0 0 512 512"},caretAltLeftIcon:{name:"caret-alt-left",content:'<path d="m160 256 192-128v256z" />',viewBox:"0 0 512 512"},caretAltRightIcon:{name:"caret-alt-right",content:'<path d="M352 256 160 384V128z" />',viewBox:"0 0 512 512"},caretAltToBottomIcon:{name:"caret-alt-to-bottom",content:'<path d="M384 128 256 320 128 128zM128 352h256v-32H128z" />',viewBox:"0 0 512 512"},caretAltToLeftIcon:{name:"caret-alt-to-left",content:'<path d="M352 384 160 256l192-128zM128 128v256h32V128z" />',viewBox:"0 0 512 512"},caretAltToRightIcon:{name:"caret-alt-to-right",content:'<path d="m128 128 192 128-192 128zm224 256V128h-32v256z" />',viewBox:"0 0 512 512"},caretAltToTopIcon:{name:"caret-alt-to-top",content:'<path d="m128 352 128-192 128 192zm256-224H128v32h256z" />',viewBox:"0 0 512 512"},caretAltUpIcon:{name:"caret-alt-up",content:'<path d="m256 160 128 192H128z" />',viewBox:"0 0 512 512"},caretBlIcon:{name:"caret-bl",content:'<path d="M160 352V160l192 192z" />',viewBox:"0 0 512 512"},caretBrIcon:{name:"caret-br",content:'<path d="M352 352H160l192-192z" />',viewBox:"0 0 512 512"},caretDoubleAltDownIcon:{name:"caret-double-alt-down",content:'<path d="M384 64 256 256 128 64zM256 448l128-192-128 1H128z" />',viewBox:"0 0 512 512"},caretDoubleAltLeftIcon:{name:"caret-double-alt-left",content:'<path d="M448 384 256 256.001l192-128zM64 256.001 256 384V128z" />',viewBox:"0 0 512 512"},caretDoubleAltRightIcon:{name:"caret-double-alt-right",content:'<path d="m64 128 192 128L64 384zm384 128L256 128v256z" />',viewBox:"0 0 512 512"},caretDoubleAltUpIcon:{name:"caret-double-alt-up",content:'<path d="m128 448 128-192 128 192zM256 64 128 256h256z" />',viewBox:"0 0 512 512"},caretTlIcon:{name:"caret-tl",content:'<path d="M160 160h192L160 352z" />',viewBox:"0 0 512 512"},caretTrIcon:{name:"caret-tr",content:'<path d="M352 160v192L160 160z" />',viewBox:"0 0 512 512"},cartIcon:{name:"cart",content:'<path d="M192 368c0 26.51-21.49 48-48 48s-48-21.49-48-48 21.49-48 48-48 48 21.49 48 48m144-48c-26.51 0-48 21.49-48 48s21.49 48 48 48 48-21.49 48-48-21.49-48-48-48M128 96V64H32v32h64v192h288v-32H128zm32 128h256v-32H160zm0-96v32h288v-32z" />',viewBox:"0 0 512 512"},categorizeIcon:{name:"categorize",content:'<path d="M32 32v192l160-96zm0 448V288l160 96zM192 64h288v32H192zm0 96h288v32H192zm0 160h288v32H192zm0 96h288v32H192z" />',viewBox:"0 0 512 512"},cellSplitHorizontallyIcon:{name:"cell-split-horizontally",content:'<path d="M32 32v416h416V32zm32 32h160v64H64zm160 160h-64v-64h64zM64 160h64v64H64zm0 96h160v64H64zm0 160v-64h160v64zm192-256h64v64h-64zm160 256H256v-64h160zm0-96H256v-64h160zm0-96h-64v-64h64zm0-96H256V64h160z" />',viewBox:"0 0 512 512"},cellSplitVerticallyIcon:{name:"cell-split-vertically",content:'<path d="M32 448h416V32H32zm32-32V256h64v160zm160-160v64h-64v-64zm-64 160v-64h64v64zm96 0V256h64v160zm160 0h-64V256h64zM160 224v-64h64v64zM416 64v160h-64V64zm-96 0v160h-64V64zm-96 0v64h-64V64zm-96 0v160H64V64z" />',viewBox:"0 0 512 512"},cellsMergeHorizontallyIcon:{name:"cells-merge-horizontally",content:'<path d="M32 32v416h416V32zm160 32h96v96h-96zM64 64h96v96H64zm96 352H64v-96h96zm128 0h-96v-96h96zm128 0h-96v-96h96zm0-128H64v-96h352zm0-128h-96V64h96z" />',viewBox:"0 0 512 512"},cellsMergeIcon:{name:"cells-merge",content:'<path d="M32 32v448h416V32zm160 32h96v64h-96zM64 64h96v64H64zm96 384H64v-64h96zm128 0h-96v-64h96zm128 0h-96v-64h96zm0-96H64V160h352zm0-224h-96V64h96z" />',viewBox:"0 0 512 512"},cellsMergeVerticallyIcon:{name:"cells-merge-vertically",content:'<path d="M32 448h416V32H32zm32-160v-96h96v96zm0 128v-96h96v96zm352-96v96h-96v-96zm0-128v96h-96v-96zm0-128v96h-96V64zm-128 0v352h-96V64zm-128 0v96H64V64z" />',viewBox:"0 0 512 512"},changeManuallyIcon:{name:"change-manually",content:'<path d="m416 353 32-32v159H32V32h416v64h-32V64H64v384h352zm-192-3.7V416h66.7l169.7-168.5-67.9-67.9zm55.3 34-22.6-22.6 135.8-135.8 22.6 22.6zM502.7 160 480 137.3c-12.4-12.4-32.8-12.4-45.3 0L412.2 160l67.9 67.9 22.6-22.6c12.4-12.5 12.4-32.9 0-45.3M191.9 416H167v-22h-.6c-7.9 14.6-19.4 22-34.6 22-11.2 0-20-3.3-26.3-9.8S96 391 96 380.3c0-23.1 12.4-36.5 37.2-40.4l33.9-5.1c0-17.4-7.7-26.1-23.2-26.1-13.6 0-25.8 5-36.8 15v-24.2c12-7.6 25.9-11.5 41.7-11.5 28.8 0 43.3 15.2 43.3 45.6V416zM167 353.1l-23.9 3.6c-7.4 1-13 3-16.8 5.8s-5.6 7.8-5.6 14.9c0 5.2 1.7 9.4 5.2 12.7s8.1 5 13.9 5c7.9 0 14.4-3 19.5-8.9 5.2-5.9 7.7-13.4 7.7-22.4z" />',viewBox:"0 0 512 512"},chartAreaClusteredIcon:{name:"chart-area-clustered",content:'<path d="m405.5 200.3-88.2-88.2-91.2 114L192 192l-37.6 45.1L64 146.8V32H32v448h448V96zM320 160l66.7 66.7L320 320l-71.1-71.1zM64 192l69.8 69.8L64 345.6z" />',viewBox:"0 0 512 512"},chartAreaRangeIcon:{name:"chart-area-range",content:'<path d="M64 416v32h416v32H32V32h32v224l128-128 128 64L480 32v192L320 384l-127-64z" />',viewBox:"0 0 512 512"},chartAreaStacked100Icon:{name:"chart-area-stacked100",content:'<path d="M32 32v448h448V32zm416 108.8L320 320 192 192 64 345.6V64h384z" />',viewBox:"0 0 512 512"},chartAreaStackedIcon:{name:"chart-area-stacked",content:'<path d="m320 165.3-128-64-128 128V32H32v448h448V32zm128 7.5L320 352 192 224 64 377.6v-103l134.3-134.3 126.1 63 123.6-103z" />',viewBox:"0 0 512 512"},chartBarClusteredIcon:{name:"chart-bar-clustered",content:'<path d="M64 448v-64h160V224H64v-32h352V32H32v448h448v-32zm128-192v96H64v-96z" />',viewBox:"0 0 512 512"},chartBarRangeIcon:{name:"chart-bar-range",content:'<path d="M480 448v32H32V32h32v416zm-96-192H160v96h224zm32-32v160H128V224zm64-192H256v160h224z" />',viewBox:"0 0 512 512"},chartBarStacked100Icon:{name:"chart-bar-stacked100",content:'<path d="M480 192V32H32v448h448v-32H64v-64h416V224H64v-32zm-160 64v96H64v-96zM64 64h160v96H64z" />',viewBox:"0 0 512 512"},chartBarStackedIcon:{name:"chart-bar-stacked",content:'<path d="M64 448v-64h352V224H64v-32h256V32H32v448h448v-32zm0-384h96v96H64zm192 192v96H64v-96z" />',viewBox:"0 0 512 512"},chartBubbleIcon:{name:"chart-bubble",content:'<path d="M480 448v32H32V32h32v416zM192 256c-35.3 0-64 28.7-64 64s28.7 64 64 64 64-28.7 64-64-28.7-64-64-64m0-32c53 0 96 43 96 96s-43 96-96 96-96-43-96-96 43-96 96-96m224 96c-17.7 0-32 14.3-32 32s14.3 32 32 32 32-14.3 32-32-14.3-32-32-32m0-32c35.3 0 64 28.7 64 64s-28.7 64-64 64-64-28.7-64-64 28.7-64 64-64M368 96c-44.2 0-80 35.8-80 80s35.8 80 80 80 80-35.8 80-80-35.8-80-80-80M176 64c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48" />',viewBox:"0 0 512 512"},chartCandlestickIcon:{name:"chart-candlestick",content:'<path d="M480 448v32H32V32h32v416zm-192-96h-64v64h-32v-64h-64V96h64V32h32v64h64zm-32-224h-96v192h96zm224 64h-64V64h-32v128h-64v128h64v64h32v-64h64z" />',viewBox:"0 0 512 512"},chartChoroplethIcon:{name:"chart-choropleth",content:'<path d="M448 64v384H64V64zm32-32H32v448h448zm-96 256v13.3l-64 64v37.5l13.3 13.3H416V264.6zm-50.7-160 64 64-32 32 18.8 23.4 32-21.3V96H288v18.8l13.3 13.3h32zM224 192l32 32-23.7 23.7L352 276v-20l-32-32 32-32-32-32h-32l-32-32V96h-32l-64 64 32 32zm0 86-32 10-32 32 32 32v32l-32 32h128v-64l50.4-50.4zm-29.4-37.8 16.2-16.2h-32l-64-64 64-64H96v167.5zM114.8 320l37.6-37.6L96 296.5V416h32v-13.3l32-32v-5.5z" />',viewBox:"0 0 512 512"},chartColumnClusteredIcon:{name:"chart-column-clustered",content:'<path d="M320 96v352h-32V288H128v160H64V32H32v448h448V96zm-64 352h-96V320h96z" />',viewBox:"0 0 512 512"},chartColumnRangeIcon:{name:"chart-column-range",content:'<path d="M480 448v32H32V32h32v416zM256 128h-96v224h96zm32-32v288H128V96zm192-64H320v224h160z" />',viewBox:"0 0 512 512"},chartColumnStacked100Icon:{name:"chart-column-stacked100",content:'<path d="M320 32v416h-32V32H128v416H64V32H32v448h448V32zM160 448V192h96v256zm192 0V288h96v160z" />',viewBox:"0 0 512 512"},chartColumnStackedIcon:{name:"chart-column-stacked",content:'<path d="M320 192v256h-32V96H128v352H64V32H32v448h448V192zM160 448V256h96v192zm192 0v-96h96v96z" />',viewBox:"0 0 512 512"},chartDoughnutIcon:{name:"chart-doughnut",content:'<path d="M473 310.3c.9-2.1 1.4-4.2 1.8-6.3l.1-.5c.5-2.1.9-4.1 1.3-6.2v-.3c.8-4.4 1.5-8.8 1.8-13.3v-.4c.5-2 .7-3.9.9-5.9l.1-1.7c.1-1.6.3-3.1.4-4.7 0-.7.1-1.4.1-2 .1-1.5.2-3.1.2-4.6 0-.6 0-1.3.1-1.9.1-2.2.1-4.3.1-6.5 0-31.8-6.7-63.2-19.8-92.2-1.5-3.3-3.1-6.6-4.7-9.8-4.1-8-8.7-15.8-13.8-23.3-5-7.4-10.5-14.6-16.4-21.3-1.2-1.3-2.4-2.7-3.6-4-2.4-2.7-4.9-5.3-7.4-7.8s-5.1-5-7.8-7.4-5.4-4.7-8.1-7c-4.1-3.4-8.4-6.7-12.8-9.8-20.7-14.8-43.8-25.9-68.3-32.9-5.3-1.5-10.7-2.8-16.2-4-3.6-.7-7.3-1.4-11-2s-7.4-1-11.2-1.3c-5.6-.6-11.3-.9-17.1-1.1-1.9 0-3.9-.1-5.8-.1C132.3 32 32 132.3 32 256s100.3 224 224 224c105 0 193.1-72.2 217-169.7M320 256c0 35.3-28.7 64-64 64s-64-28.7-64-64 28.7-64 64-64 64 28.7 64 64m71.8 135.8c-74.4 75.6-195.9 76.6-271.5 2.2S43.7 198 118 122.4l2.2-2.2c36-36.1 84.9-56.3 135.8-56.2v96c-53 0-96 43-96 96s43 96 96 96c44 0 82.4-30 93.1-72.7l93.2 23.3c-8.4 33.8-25.9 64.6-50.5 89.2m-39.8-133v.8zm0 2.8v.9zm-.4 2.9-.1.7zm-.6 3.2v.2zm-1 5.9v.1zm0 2.8v.2z" />',viewBox:"0 0 512 512"},chartLineIcon:{name:"chart-line",content:'<path d="M64 448h416v32H32V32h32zm152.4-190.4L96 416v-51.2l97.2-129.6 41.2-33-27.3-34.1L96 224v-38l119.9-58.1 43.5 54.3 109-87.2 55.9 85.7L480 114v47l-38 46.7 38 58.3.5 53.3-58.5-87-82.5 101.3-85.1-106.4zm63-50.4 60.1 75.2 64.3-77.1-42.7-63.5z" />',viewBox:"0 0 512 512"},chartLineMarkersIcon:{name:"chart-line-markers",content:'<path d="M480 448v32H0V32h32v416zm0-96c.1 17.7-14.2 32-31.9 32.1s-32-14.2-32.1-31.9c0-1.3.1-2.7.2-4l-83.7-62.8c-8 3.4-17.1 3.4-25.2 0l-83.7 62.8c2.1 17.5-10.4 33.5-27.9 35.6s-33.5-10.4-35.6-27.9c-.7-6.2.3-12.4 3.1-18l-49-73.6-22.7 39.6c8.9 15.3 3.7 34.9-11.5 43.8s-34.9 3.7-43.8-11.5-3.7-34.9 11.5-43.8c4.9-2.8 10.4-4.3 16-4.4l30.6-53.5-28.4-42.6c-.7 0-1.4.1-2.1.1-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32c0 4.9-1.1 9.8-3.3 14.2l19.5 29.3 52.2-91.3c-8.9-15.3-3.8-34.9 11.5-43.8s34.9-3.8 43.8 11.5c2.5 4.4 4 9.2 4.3 14.3l78.4 39.2c14.7-9.7 34.6-5.7 44.3 9 .3.5.7 1.1 1 1.6h72.6c8.8-15.3 28.4-20.5 43.7-11.7s20.5 28.4 11.7 43.7-28.4 20.5-43.7 11.7c-4.9-2.8-8.9-6.8-11.7-11.7h-72.6c-8.8 15.3-28.4 20.5-43.7 11.7-9.3-5.4-15.3-15.1-15.9-25.8l-78.4-39.2c-5.2 3.4-11.3 5.3-17.5 5.3l-60 105.2 57.9 86.9c.7 0 1.4-.1 2.1-.1 4.3 0 8.6.9 12.6 2.6l83.7-62.8c-2.2-17.5 10.3-33.5 27.8-35.7s33.5 10.3 35.7 27.8q.45 3.9 0 7.8l83.7 62.8c16.2-7 35.1.6 42 16.8 1.6 4.1 2.5 8.4 2.5 12.7m-48-192c0 8.8 7.2 16 16 16s16-7.2 16-16-7.2-16-16-16-16 7.2-16 16m-128 0c0 8.8 7.2 16 16 16s16-7.2 16-16-7.2-16-16-16-16 7.2-16 16M176 96c0 8.8 7.2 16 16 16s16-7.2 16-16-7.2-16-16-16-16 7.2-16 16m-96 64c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m0 160c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128 32c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128-96c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128 96c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16" />',viewBox:"0 0 512 512"},chartLineStacked100Icon:{name:"chart-line-stacked100",content:'<path d="M480 448v32H32V32h32v416zM224 228l128 64 128-96v-36l-128 96-128-64-128 96v36zM480 32H96v32h384z" />',viewBox:"0 0 512 512"},chartLineStacked100MarkersIcon:{name:"chart-line-stacked100-markers",content:'<path d="M480 448v32H0V32h32v416zm0-192c0 17.7-14.3 32-32 32-5.5 0-11-1.4-15.8-4.2l-81.1 60.8c4.1 17.2-6.6 34.4-23.8 38.5s-34.4-6.6-38.5-23.8c-.6-2.4-.9-4.9-.9-7.4l-76.8-38.4c-10.2 7.6-23.9 8.5-35 2.2L95 376.5c4.1 17.2-6.6 34.4-23.8 38.5s-34.4-6.6-38.5-23.8 6.6-34.4 23.8-38.5c7.9-1.9 16.1-.7 23.1 3.3l81.1-60.8c-4.1-17.2 6.6-34.4 23.8-38.5s34.4 6.6 38.5 23.8c.6 2.4.9 4.9.9 7.4l76.8 38.4c10.2-7.6 23.9-8.5 35-2.2l81.1-60.8c-4.1-17.2 6.5-34.5 23.7-38.6s34.5 6.5 38.6 23.7c.6 2.5.9 5.1.9 7.6M80 384c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128-96c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128 64c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128-96c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m16-192c0 17.7-14.3 32-32 32-11.4 0-22-6.1-27.7-16h-72.6c-8.8 15.3-28.4 20.5-43.7 11.7-4.9-2.8-8.9-6.8-11.7-11.7h-72.6c-8.8 15.3-28.4 20.5-43.7 11.7-4.9-2.8-8.9-6.8-11.7-11.7H91.7C82.9 95.3 63.3 100.5 48 91.7S27.4 63.3 36.3 48 64.7 27.5 80 36.3c4.9 2.8 8.9 6.8 11.7 11.7h72.6c8.8-15.3 28.4-20.5 43.7-11.7 4.9 2.8 8.9 6.8 11.7 11.7h72.6c8.8-15.3 28.4-20.5 43.7-11.7 4.9 2.8 8.9 6.8 11.7 11.7h72.6c8.8-15.3 28.4-20.5 43.7-11.7 9.9 5.7 16 16.3 16 27.7M80 64c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128 0c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128 0c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128 0c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16" />',viewBox:"0 0 512 512"},chartLineStackedIcon:{name:"chart-line-stacked",content:'<path d="M480 448v32H32V32h32v416zM224 292l128 64 128-96v-36l-128 96-128-64-128 96v36zm0-160 128 92 128-60v-36l-128 60-128-92-128 64v36z" />',viewBox:"0 0 512 512"},chartLineStackedMarkersIcon:{name:"chart-line-stacked-markers",content:'<path d="M480 448v32H0V32h32v416zm0-320c0 17.7-14.3 32-32 32-6.9 0-13.7-2.2-19.2-6.4L352 192c0 17.7-14.3 32-32 32s-32-14.3-32-32c0-2.5.3-5 .9-7.4l-81.1-60.8c-11.1 6.3-24.8 5.4-35-2.2L96 160c0 17.7-14.3 32-32 32s-32-14.3-32-32 14.3-32 32-32c6.9 0 13.7 2.2 19.2 6.4L160 96c0-17.7 14.3-32 32-32s32 14.3 32 32c0 2.5-.3 5-.9 7.4l81.1 60.8c11.1-6.3 24.8-5.4 35 2.2L416 128c0-17.7 14.3-32 32-32s32 14.3 32 32M80 160c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128-64c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128 96c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128-64c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m16 128c0 17.7-14.3 32-32 32-5.5 0-11-1.4-15.8-4.2l-81.1 60.8c4.1 17.2-6.6 34.4-23.8 38.5s-34.4-6.6-38.5-23.8c-.6-2.4-.9-4.9-.9-7.4l-76.8-38.4c-10.2 7.6-23.9 8.5-35 2.2L95 376.5c4.1 17.2-6.6 34.4-23.8 38.5s-34.4-6.6-38.5-23.8 6.6-34.4 23.8-38.5c7.9-1.9 16.1-.7 23.1 3.3l81.1-60.8c-4.1-17.2 6.6-34.4 23.8-38.5s34.4 6.6 38.5 23.8c.6 2.4.9 4.9.9 7.4l76.8 38.4c10.2-7.6 23.9-8.5 35-2.2l81.1-60.8c-4.1-17.2 6.5-34.5 23.7-38.6s34.5 6.5 38.6 23.7c.6 2.5.9 5.1.9 7.6M80 384c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128-96c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128 64c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m128-96c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16" />',viewBox:"0 0 512 512"},chartOhlcIcon:{name:"chart-ohlc",content:'<path d="M480 448v32H32V32h32v416zM224 320V96h-32v32h-64v32h64v256h32v-64h64v-32zM416 96V32h-32v160h-64v32h64v96h32V128h64V96z" />',viewBox:"0 0 512 512"},chartPieIcon:{name:"chart-pie",content:'<path d="M473 310.3c.9-2.1 1.4-4.2 1.8-6.3l.1-.5c.5-2.1.9-4.1 1.3-6.2v-.2c.8-4.4 1.5-8.8 1.8-13.3v-.4c.5-2 .7-3.9.9-5.9l.1-1.7c.1-1.6.3-3.1.4-4.7 0-.7.1-1.4.1-2 .1-1.5.2-3.1.2-4.6 0-.6 0-1.3.1-1.9.1-2.2.1-4.3.1-6.5 0-31.8-6.7-63.2-19.8-92.2-1.5-3.3-3.1-6.6-4.7-9.8-4.1-8-8.7-15.8-13.8-23.3-5-7.4-10.5-14.6-16.4-21.3-1.2-1.3-2.4-2.7-3.6-4-2.4-2.7-4.9-5.3-7.4-7.8s-5.1-5-7.8-7.4-5.4-4.7-8.1-7c-4.1-3.4-8.4-6.7-12.8-9.8-20.7-14.8-43.8-25.9-68.3-32.9-5.3-1.5-10.7-2.8-16.2-4-3.6-.7-7.3-1.4-11-2s-7.4-1-11.2-1.3c-5.6-.6-11.3-.9-17.1-1.1-1.9 0-3.9-.1-5.8-.1C132.3 32 32 132.3 32 256s100.3 224 224 224c105 0 193.1-72.2 217-169.7m-81.2 81.5c-74.4 75.6-195.9 76.6-271.5 2.2S43.7 198 118 122.5l2.2-2.2c36-36.2 84.9-56.4 135.8-56.3v192l186.3 46.6c-8.4 33.8-25.9 64.6-50.5 89.2" />',viewBox:"0 0 512 512"},chartRadarFilledIcon:{name:"chart-radar-filled",content:'<path d="m354.4 372.1 65.1 89.6-25.9 18.8-75-103.2-109.2-21.8-90.8 125-25.9-18.8 90-123.8-67.3-101L32 216.6l7.5-31.1 65.8 16L240 107.2V32h32v80l99.2 99.2L472 187.7l7.3 31.2-98.8 23z" />',viewBox:"0 0 512 512"},chartRadarIcon:{name:"chart-radar",content:'<path d="M272 32h-32v44L80.7 195.5l-41.1-10-7.6 31.1 42.3 10.3 81 148.5-62.7 86.3 25.9 18.8 67.2-92.5L344 412.3l49.5 68.2 25.9-18.8-46.8-64.4 40.8-163.1 65.8-15.3-7.3-31.2-74.9 17.4L272 80zm-32 202.2-119-28.9L240 116zm32 0v-109l88.4 88.4zm-95.9 112.5-59.8-109.6 118.5 28.8zm172 17.3-71-97.7 101.3-23.6zm-30.6 12-110.6-17 49.1-67.6z" />',viewBox:"0 0 512 512"},chartRadarMarkersIcon:{name:"chart-radar-markers",content:'<path d="m472 187.7-51.2 11.9c-9.4-8-22.5-9.9-33.8-4.8L288.1 96c0-11.5-6.2-22.1-16.1-27.8V32h-32v36.4c-7.1 4.1-12.3 10.8-14.6 18.6L96.1 184c-8.6 0-16.7 3.4-22.8 9.5l-32.8-8-7.5 31.1 32.3 7.8c2.7 9.9 10 17.8 19.6 21.5l61 111.8c-3 8.9-2 18.7 2.9 26.7l-56.1 77.3 25.9 18.8L177 400c8.5-.2 16.5-3.8 22.3-10l122 18.8c3.9 13.8 16.5 23.2 30.8 23.2 1.9 0 3.9-.2 5.8-.5l35.6 49 25.9-18.8-37.1-51.1c3.7-10.4 1.7-22-5.2-30.6l31.4-125.2c11.8-3.2 20.8-12.9 23.1-24.9l47.7-11.1zm-111.4 25.9L272 234.2V125.1zM256 80c8.8 0 16 7.2 16 16s-7.2 16-16 16-16-7.2-16-16 7.2-16 16-16m-21.1 39.9c1.6 1.4 3.3 2.6 5.1 3.7V234l-113.3-27.6c-.4-1.4-1-2.8-1.6-4.1zM96 232c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16m80 152c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16m7.2-47.2c-2.4-.5-4.8-.8-7.2-.8-1.8 0-3.7.2-5.5.5l-52.9-96.9c.7-.6 1.3-1.2 1.9-1.9l115.3 28zm23.6 22 49.1-67.6 61.5 84.6zM352 416c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16m-3.9-52.3L277 265.9l97.4-22.6c.9 1.2 1.9 2.4 3 3.5zM400 240c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16" />',viewBox:"0 0 512 512"},chartRoseIcon:{name:"chart-rose",content:'<path d="M226 251.4 44.3 329.3c-23.8-68.9-12.6-145.1 30-204.3zm-82.1-109.5L240 222V96.8c-36.2 3.6-70.1 19.6-96.1 45.1m231.5 160.2L279 278l27.3 95.7c31.8-13.6 56.7-39.4 69.1-71.6M96 353.4c37.3 69.1 115 106.1 192.2 91.4L244 290zM272 32v211.4l204.6 51.1c2.3-12.9 3.4-26 3.4-39.1C480 137.1 388.2 40.2 272 32" />',viewBox:"0 0 512 512"},chartScatterIcon:{name:"chart-scatter",content:'<path d="M480 448v32H32V32h32v416zM160 96c0 17.7-14.3 32-32 32s-32-14.3-32-32 14.3-32 32-32 32 14.3 32 32m-16 0c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m112 192c0 17.7-14.3 32-32 32s-32-14.3-32-32 14.3-32 32-32 32 14.3 32 32m-16 0c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m112-128c0 17.7-14.3 32-32 32s-32-14.3-32-32 14.3-32 32-32 32 14.3 32 32m-16 0c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m112 192c0 17.7-14.3 32-32 32s-32-14.3-32-32 14.3-32 32-32 32 14.3 32 32m-16 0c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16" />',viewBox:"0 0 512 512"},chartScatterSmoothLinesIcon:{name:"chart-scatter-smooth-lines",content:'<path d="M480 448v32H32V32h32v416zm-144-87.8c21.1-19.9 31.8-44.5 31.8-73.1 0-27.3-11-47.6-32.6-60.6-17.3-10.3-38.8-14.5-59.6-18.6-46.2-9-66.5-16.3-66.8-47.9-.4-41.2 71.8-65.5 114.8-76.4C385.4 68.1 448.4 64 449 64l-2-32c-2.7.2-66.2 4.3-130.8 20.5-38.7 9.7-69.8 21.8-92.4 36-31.4 19.8-47.3 43.9-47 71.7.2 27.2 11.3 47.6 32.9 60.5 17.3 10.3 38.9 14.5 59.7 18.6 19 3.7 36.9 7.2 49.3 14.6 11.9 7.1 17 17.1 17 33.2 0 19.7-7.1 36-21.7 49.7-24.1 22.8-68.9 38.2-129.3 44.6-29.2 3-58.5 3.9-87.8 2.6l-2 32c1.7.1 12.1.7 28 .7 51.4 0 159.8-6.4 213.1-56.5" />',viewBox:"0 0 512 512"},chartScatterSmoothLinesMarkersIcon:{name:"chart-scatter-smooth-lines-markers",content:'<path d="M480 448v32H32V32h32v416zm0-384c0 17.7-14.3 32-32 32-15.6 0-28.9-11.2-31.5-26.5-9.2-1.3-22-1.8-39-.8C342.5 71 305.1 79.4 275 92c-19.1 7.9-47.9 23-60.7 45.1 12.7 12.3 13 32.6.6 45.3l-1.1 1.1c9.1 13.1 28.9 18.6 61.1 25.1 21 4.2 42.8 8.5 60.2 18.9 12.7 7.6 21.7 17.8 27 30.3 16.8 5.6 25.8 23.7 20.2 40.5-3.2 9.5-10.6 17-20.1 20.2-11.2 29.5-39.2 54.6-81.6 72.2-29.7 12.1-61.2 19.2-93.2 21.1q-6 .3-11.4.3c-9.6.1-19.3-.7-28.8-2.5-14.1 10.6-34.2 7.7-44.8-6.4s-7.7-34.2 6.4-44.8 34.2-7.7 44.8 6.4c3.2 4.2 5.2 9.1 6 14.3 8.7 1 17.5 1.2 26.2.7 28.3-1.6 56.2-7.9 82.5-18.6 19.7-8.2 49.8-24.3 62-49.6-13-12-13.8-32.2-1.8-45.2.4-.5.8-.9 1.3-1.3-9.1-13.2-28.8-18.7-61.1-25.2-21-4.2-42.8-8.5-60.2-18.9-12.8-7.7-21.9-18-27.2-30.7-16.7-5.9-25.4-24.2-19.5-40.9 3.3-9.4 10.9-16.7 20.4-19.8 5-11 12-21 20.6-29.5 14.6-14.5 34.7-27.2 59.8-37.6C296 48.6 337 39.2 375.4 36.8c22.9-1.5 40-.4 52.8 2.1 13.9-11 34-8.6 44.9 5.3 4.5 5.6 6.9 12.6 6.9 19.8m-272 96c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m-64 224c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m192-96c0 8.8 7.2 16 16 16s16-7.2 16-16-7.2-16-16-16-16 7.2-16 16M464 64c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16" />',viewBox:"0 0 512 512"},chartScatterStraightLinesIcon:{name:"chart-scatter-straight-lines",content:'<path d="M480 448v32H32V32h32v416zm-98.5-156.9-158.8-127L448 64V32L161.3 156l161.2 128.9L128 384v32z" />',viewBox:"0 0 512 512"},chartScatterStraightLinesMarkersIcon:{name:"chart-scatter-straight-lines-markers",content:'<path d="M480 448v32H32V32h32v416zm0-384c0 17.7-14.3 32-32 32-7.4 0-14.6-2.6-20.3-7.3L224 165.1l116.4 93.1c16.5-6.4 35 1.7 41.4 18.2s-1.7 35-18.2 41.4c-10.3 4-22 2.4-30.8-4.2l-173.1 74.2c-2.1 17.5-18 30.1-35.6 28s-30.1-18-28-35.6c2.1-17.5 18-30.1 35.6-28 5.6.7 10.9 2.8 15.4 6.2l173.1-74.2c0-.4.1-.7.1-1l-116.7-93.4c-16.5 6.4-35-1.7-41.4-18.2s1.7-35 18.2-41.4c10.8-4.2 23-2.3 32 5.1l204.1-76.5c2.9-17.4 19.4-29.2 36.8-26.3C468.7 35.1 480 48.4 480 64m-272 96c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m-64 224c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16m192-96c0 8.8 7.2 16 16 16s16-7.2 16-16-7.2-16-16-16-16 7.2-16 16M464 64c0-8.8-7.2-16-16-16s-16 7.2-16 16 7.2 16 16 16 16-7.2 16-16" />',viewBox:"0 0 512 512"},checkCircleIcon:{name:"check-circle",content:'<path d="M256 32C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32m-32 352L96 256l45-45 83 83 147-147 45 45z" />',viewBox:"0 0 512 512"},checkIcon:{name:"check",content:'<path d="M434.7 82.7 480 128 192 416 32 256l45.3-45.3L192 325.5z" />',viewBox:"0 0 512 512"},checkOutlineIcon:{name:"check-outline",content:'<path d="M256 32C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32m0 416c-106 0-192-86-192-192S150 64 256 64s192 86 192 192-86 192-192 192m-32-154-83-83-45 45 128 128 176-176-45-45z" />',viewBox:"0 0 512 512"},checkboxCheckedIcon:{name:"checkbox-checked",content:'<path d="M64 64v384h384V64zm352 352H96V96h320zm-77.3-269.3L384 192 224 352l-96-96 45.3-45.3 50.7 50.7z" />',viewBox:"0 0 512 512"},checkboxIcon:{name:"checkbox",content:'<path d="M64 64v384h384V64zm352 352H96V96h320z" />',viewBox:"0 0 512 512"},checkboxIndeterminateIcon:{name:"checkbox-indeterminate",content:'<path d="M128 128h256v256H128zM64 64v384h384V64zm352 352H96V96h320z" />',viewBox:"0 0 512 512"},checkboxNullIcon:{name:"checkbox-null",content:'<path d="M192 64h128v32H192zm224 0h-64v32h64v64h32V64zm0 256h32V192h-32zm0 96h-64v32h96v-96h-32zm-224 32h128v-32H192zm-96-96H64v96h96v-32H96zm0-160H64v128h32zM64 64v96h32V96h64V64z" />',viewBox:"0 0 512 512"},chevronDoubleDownIcon:{name:"chevron-double-down",content:'<path d="M382.1 224 256 350.1 129.9 224 96 257.9l160 160 160-160zm0-128L256 222.1 129.9 96 96 129.9l160 160 160-160z" />',viewBox:"0 0 512 512"},chevronDoubleLeftIcon:{name:"chevron-double-left",content:'<path d="M289 383 162.9 257 289 130.9 255 97 95 257l160 160zm128 0L290.9 257 417 130.9 383 97 223 257l160 160z" />',viewBox:"0 0 512 512"},chevronDoubleRightIcon:{name:"chevron-double-right",content:'<path d="M223 130.9 349.1 257 223 383l34 34 160-160L257 97zm-128 0L221.1 257 95 383l34 34 160-160L129 97z" />',viewBox:"0 0 512 512"},chevronDoubleUpIcon:{name:"chevron-double-up",content:'<path d="m129.9 289.9 126.1-126L382.1 290l33.9-34L256 96 96 256zm0 128 126.1-126L382.1 418l33.9-34-160-160L96 384z" />',viewBox:"0 0 512 512"},chevronDownIcon:{name:"chevron-down",content:'<path d="m382.059 158.059-126.06 126.06-126.061-126.06L96 192l159.999 160L416 192z" />',viewBox:"0 0 512 512"},chevronLeftIcon:{name:"chevron-left",content:'<path d="m353.941 382.059-126.06-126.06 126.06-126.061L320 96 160 255.999 320 416z" />',viewBox:"0 0 512 512"},chevronRightIcon:{name:"chevron-right",content:'<path d="m158.059 129.941 126.06 126.06-126.06 126.061L192 416l160-159.999L192 96z" />',viewBox:"0 0 512 512"},chevronUpIcon:{name:"chevron-up",content:'<path d="m129.941 353.941 126.06-126.06 126.061 126.06L416 320 256.001 160 96 320z" />',viewBox:"0 0 512 512"},circleIcon:{name:"circle",content:'<path d="M384 256c0 70.7-57.3 128-128 128s-128-57.3-128-128 57.3-128 128-128 128 57.3 128 128" />',viewBox:"0 0 512 512"},clearCssIcon:{name:"clear-css",content:'<path d="M402.784 290.235 221.765 109.216l22.627-22.627c12.445-12.445 32.81-12.445 45.255 0l22.627 22.627 67.882-67.882c12.445-12.445 32.81-12.445 45.255 0l45.255 45.255c12.445 12.445 12.445 32.81 0 45.255l-67.882 67.882 22.627 22.627c12.445 12.445 12.445 32.81 0 45.255zm-21.8 23.455-181.02-181.019c-12.346-12.346-32.483-12.437-44.953-.287L54.627 32 32 54.627l100.074 100.074-91.819 89.362S18.585 267.482 0 248.898l221.274 221.76c12.467 12.467 32.81 12.445 45.255 0l91.851-89.651L457.373 480 480 457.373l-98.73-98.73c12.151-12.47 12.06-32.607-.286-44.953" />',viewBox:"0 0 512 512"},clipboardCodeIcon:{name:"clipboard-code",content:'<path d="M214.6 361.4 192 384l-80-80 80-80 22.6 22.6-57.3 57.4zM448 64v384c0 17.7-14.3 32-32 32H96c-17.7 0-32-14.3-32-32V64c0-17.7 14.3-32 32-32h104.6C211.7 12.9 232.3 0 256 0s44.3 12.9 55.4 32H416c17.7 0 32 14.3 32 32m-224 0h64c0-17.7-14.3-32-32-32s-32 14.3-32 32m192 0h-64v64H160V64H96v384h320zM297.4 246.6l57.4 57.4-57.4 57.4L320 384l80-80-80-80z" />',viewBox:"0 0 512 512"},clipboardHtmlIcon:{name:"clipboard-html",content:'<path d="M214.6 361.4 192 384l-80-80 80-80 22.6 22.6-57.3 57.4zM448 64v384c0 17.7-14.3 32-32 32H96c-17.7 0-32-14.3-32-32V64c0-17.7 14.3-32 32-32h104.6C211.7 12.9 232.3 0 256 0s44.3 12.9 55.4 32H416c17.7 0 32 14.3 32 32m-224 0h64c0-17.7-14.3-32-32-32s-32 14.3-32 32m192 0h-64v64H160V64H96v384h320zM271.2 183.9 209.8 416l30.9 8.3L302.2 192zm26.2 62.7 57.4 57.4-57.4 57.4L320 384l80-80-80-80z" />',viewBox:"0 0 512 512"},clipboardIcon:{name:"clipboard",content:'<path d="M416 32H311.4C300.3 12.9 279.7 0 256 0s-44.3 12.9-55.4 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m-160 0c17.7 0 32 14.3 32 32h-64c0-17.7 14.3-32 32-32m160 416H96V64h64v64h192V64h64z" />',viewBox:"0 0 512 512"},clipboardMarkdownIcon:{name:"clipboard-markdown",content:'<path d="M226 224h30v128h-32v-72.8l-32.2 45.6L160 279v73h-32V224h32l31.8 46.2zm126 64h32l-48 64-48-64h32l.2-64H352zm64-256H311.4C300.3 12.9 279.7 0 256 0s-44.3 12.9-55.4 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m-160 0c17.7 0 32 14.3 32 32h-64c0-17.7 14.3-32 32-32m160 416H96V64h64v64h192V64h64z" />',viewBox:"0 0 512 512"},clipboardTextIcon:{name:"clipboard-text",content:'<path d="M416 32H311.4C300.3 12.9 279.7 0 256 0s-44.3 12.9-55.4 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m-160 0c17.7 0 32 14.3 32 32h-64c0-17.7 14.3-32 32-32m160 416H96V64h64v64h192V64h64zm-32-224H128v-32h256zm0 64H128v-32h256zm0 64H128v-32h256zm0 64H128v-32h256z" />',viewBox:"0 0 512 512"},clipboardWordAltIcon:{name:"clipboard-word-alt",content:'<path d="m128 160 48.5 192h46.7L256 238.4 285.3 352h43.1L384 160h-73v35h19.3l-22.2 86-28.8-121h-45.4l-33.1 119.3-25-119.3zM416 32H311.4C300.3 12.9 279.7 0 256 0s-44.3 12.9-55.4 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m-160 0c17.7 0 32 14.3 32 32h-64c0-17.7 14.3-32 32-32m160 416H96V64h64v64h192V64h64z" />',viewBox:"0 0 512 512"},clipboardWordIcon:{name:"clipboard-word",content:'<path d="m128 160 48.5 192h46.7L256 238.4 285.3 352h43.1L384 160h-73v35h19.3l-22.2 86-28.8-121h-45.4l-33.1 119.3-25-119.3zM416 32H311.4C300.3 12.9 279.7 0 256 0s-44.3 12.9-55.4 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m-160 0c17.7 0 32 14.3 32 32h-64c0-17.7 14.3-32 32-32m160 416H96V64h64v64h192V64h64zm-32-32H128v-32h256z" />',viewBox:"0 0 512 512"},clockArrowRotateIcon:{name:"clock-arrow-rotate",content:'<path d="M256 32C132.3 32 32 132.3 32 256h32c0-105.9 86.1-192 192-192s192 86.1 192 192-86.1 192-192 192c-57 0-108.3-25-143.5-64.5L176 320H32v144l57.8-57.8C130.8 451.5 190 480 256 480c123.7 0 224-100.3 224-224S379.7 32 256 32m-32 96v160h160v-32H256V128z" />',viewBox:"0 0 512 512"},clockIcon:{name:"clock",content:'<path d="M256 128h-32v160h160v-32H256zm0-96C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32m0 416c-105.9 0-192-86.1-192-192S150.1 64 256 64s192 86.1 192 192-86.1 192-192 192" />',viewBox:"0 0 512 512"},closedCaptionsIcon:{name:"closed-captions",content:'<path d="M480 64H32S0 64 0 96v320c0 32 32 32 32 32h448c32 0 32-32 32-32V96s0-32-32-32M240 205c-6.1-4.5-13.5-7.8-21.9-10.1-8.5-2.3-17.1-3.5-25.8-3.5q-27 0-42.6 17.4c-10.4 11.6-15.6 27.4-15.6 47.3 0 19.8 5.2 35.4 15.6 46.9s24.3 17.2 41.7 17.2c16.1 0 32.3-4.6 47.6-13.8V373c-17.2 7.4-38.2 11-62.1 11-23.4 0-43.6-5-60.6-15.1s-29.9-24.4-38.9-43-13.4-40-13.4-64.3c0-26.1 5-49.4 15-69.7 10-20.4 24.2-36.1 42.5-47.2s39.4-16.7 63.2-16.7c19 0 37.4 2.6 55.3 7.8zm208 0c-6.1-4.5-13.5-7.8-21.9-10.1-8.5-2.3-17.1-3.5-25.8-3.5q-27 0-42.6 17.4c-10.4 11.6-15.6 27.4-15.6 47.3 0 19.8 5.2 35.4 15.6 46.9s24.3 17.2 41.7 17.2c16.1 0 32.3-4.6 47.6-13.8V373c-17.2 7.4-38.2 11-62.1 11-23.4 0-43.6-5-60.6-15.1s-29.9-24.4-38.9-43-13.4-40-13.4-64.3c0-26.1 5-49.4 15-69.7 10-20.4 24.2-36.1 42.5-47.2s39.4-16.7 63.2-16.7c19 0 37.4 2.6 55.3 7.8z" />',viewBox:"0 0 512 512"},cloudIcon:{name:"cloud",content:'<path d="M442.2 243.6c3.7-11.2 5.8-23.2 5.8-35.6 0-61.9-50.1-112-112-112-37.8 0-71.3 18.8-91.6 47.5-15-9.8-33-15.5-52.3-15.5-52.9 0-95.8 42.9-95.8 95.8 0 1.8.1 3.6.2 5.5C58.9 242.3 32 278 32 320c0 53 43 96 96 96h256c53 0 96-43 96-96 0-31.1-14.8-58.8-37.8-76.4" />',viewBox:"0 0 512 512"},codeIcon:{name:"code",content:'<path d="M512 256 384 384l-22.6-22.6L466.7 256 361.4 150.6 384 128zM150.6 361.4 45.3 256l105.4-105.4L128 128 0 256l128 128zM321.1 72.3 290.2 64l-99.4 375.7 30.9 8.3z" />',viewBox:"0 0 512 512"},codeSnippetIcon:{name:"code-snippet",content:'<path d="M416 32V0h-32v32h-32V0h-32v32h-32V0h-32v32h-32V0h-32v32h-32V0h-32v32H96V0H64v32H32v32H0v32h32v32H0v32h32v32H0v32h32v32H0v32h32v32H0v32h32v32H0v32h32v32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v-32h32v-32h-32v-32h32v-32h-32v-32h32v-32h-32v-32h32v-32h-32v-32h32v-32h-32V96h32V64h-32V32zm0 256v128H64V64h352zM32 0v32H0V0zM0 448h32v32H0zm198.6-265.4L141.3 240l57.4 57.4L176 320l-80-80 80-80zM304 160l80 80-80 80-22.6-22.6 57.4-57.4-57.4-57.4zM480 32h-32V0h32zm-32 448v-32h32v32z" />',viewBox:"0 0 512 512"},colResizeIcon:{name:"col-resize",content:'<path d="M128 255h64v33h-64v64.6L0 271.9l128-80.7zm96 225h64V32h-64zm288-207.9-128-80.7V256h-64v33h64v63.9z" />',viewBox:"0 0 512 512"},columnFreezeIcon:{name:"column-freeze",content:'<path d="M32 32v416h416V32zm128 32v64L96 64zM64 96l96 96v64l-96-96zm0 128 96 96v64l-96-96zm0 192v-64l64 64zm224 0h-96v-96h96zm0-128h-96v-96h96zm-96-128V64h96v96zm224 256h-96v-96h96zm0-128h-96v-96h96zm0-128h-96V64h96z" />',viewBox:"0 0 512 512"},columnsIcon:{name:"columns",content:'<path d="M64 32h96v448H64zm128 448h96V32h-96zM320 32v448h96V32z" />',viewBox:"0 0 512 512"},commentIcon:{name:"comment",content:'<path d="M448 32H64c-17.6 0-32 14.4-32 32v416l96-96h320c17.6 0 32-14.4 32-32V64c0-17.6-14.4-32-32-32m0 319.942a1 1 0 0 1-.058.058H114.745L64 402.745V64.057a1 1 0 0 1 .057-.057h383.885q.031.027.058.057z" />',viewBox:"0 0 512 512"},commentRemoveIcon:{name:"comment-remove",content:'<path d="M114.745 352 64 402.745V64.057a1 1 0 0 1 .057-.057h383.885q.031.027.058.057V256h32V64c0-17.6-14.4-32-32-32H64c-17.6 0-32 14.4-32 32v416l96-96h128v-32zM480 342.627 457.373 320 400 377.373 342.627 320 320 342.627 377.373 400 320 457.373 342.627 480 400 422.627 457.373 480 480 457.373 422.627 400z" />',viewBox:"0 0 512 512"},commentsRemoveIcon:{name:"comments-remove",content:'<path d="M480 64c0-17.6-14.4-32-32-32H160c-17.6 0-32 14.4-32 32v32h32V64.1l.1-.1H448l.1.1V256l-.1.1h32zM377.4 400l22.6 22.6-57.4 57.4-22.6-22.6zm0 0L320 342.6l22.6-22.6 57.4 57.4zm45.2 0 57.4 57.4-22.6 22.6-57.4-57.4-22.6-22.6 22.6-22.6 57.4-57.4 22.6 22.6zm-304.3-16L64 420.2V160.1l.1-.1H352l.1.1V256h32v-96c0-17.6-14.4-32-32-32H64c-17.6 0-32 14.4-32 32v320l96-64h128v-32z" />',viewBox:"0 0 512 512"},connectorIcon:{name:"connector",content:'<path d="M416 112c0 26.51-21.49 48-48 48-20.898 0-38.667-13.359-45.258-32H256v288h-98.742c-6.591 18.641-24.36 32-45.258 32-26.51 0-48-21.49-48-48s21.49-48 48-48c20.898 0 38.667 13.359 45.258 32H224V96h98.742c6.591-18.641 24.36-32 45.258-32 26.51 0 48 21.49 48 48" />',viewBox:"0 0 512 512"},convertLowercaseIcon:{name:"convert-lowercase",content:'<path d="M480.1 416H436v-36h-.7c-13.8 24-34.1 36-60.8 36-19.7 0-35.1-5.3-46.3-16-11.1-10.7-16.7-24.9-16.7-42.5 0-37.8 21.7-59.9 65.3-66.2l59.4-8.4c0-28.6-13.5-42.8-40.7-42.8-23.8 0-45.4 8.2-64.5 24.7V225c21.1-12.5 45.5-18.8 73.1-18.8 50.6 0 75.9 25 75.9 74.8v135zM436 313.1l-42 5.9c-13 1.7-22.8 4.9-29.4 9.5s-9.9 12.7-9.9 24.3c0 8.5 3 15.4 9.1 20.8s14.2 8.1 24.3 8.1c13.8 0 25.2-4.8 34.3-14.5 9-9.7 13.6-21.9 13.6-36.6zM240 416h48L184 96h-48L32 416h48l26-80h108zM121.6 288 160 169.8 198.4 288z" />',viewBox:"0 0 512 512"},convertUppercaseIcon:{name:"convert-uppercase",content:'<path d="M200.1 416H156v-36h-.7c-13.8 24-34.1 36-60.8 36-19.7 0-35.1-5.3-46.3-16-11.1-10.7-16.7-24.9-16.7-42.5 0-37.8 21.7-59.9 65.3-66.2l59.4-8.4c0-28.6-13.5-42.8-40.7-42.8-23.8 0-45.4 8.2-64.5 24.7V225c21.1-12.5 45.5-18.8 73.1-18.8 50.6 0 75.9 25 75.9 74.8v135zM157 313.1l-42 5.9c-13 1.7-22.8 4.9-29.4 9.5s-9.9 12.7-9.9 24.3c0 8.5 3 15.4 9.1 20.8s14.2 8.1 24.3 8.1c13.8 0 25.2-4.8 34.3-14.5 9-9.7 13.6-21.9 13.6-36.6zM432 416h48L376 96h-48L224 416h48l26-80h108zM313.6 288 352 169.8 390.4 288z" />',viewBox:"0 0 512 512"},copyFormatIcon:{name:"copy-format",content:'<path d="M96 480h160v32H64v-64H0V288h32v128h32v-64h32zm32-32h96v-32h-96zm0-96v32h32v-32zm284.2-92.6L253.8 101c-12.4-12.4-32.9-12.4-45.3.1l-69.8 69.8-.2.2c-11.6 11.6-30 12.7-42.5 2.7l200.9 200.9c12.5 12.5 32.8 12.4 45.3 0l69.9-69.9c12.5-12.5 12.5-33 .1-45.4M502.7 32 480 9.3c-12.4-12.4-32.8-12.4-45.3 0l-67.9 67.9-22.6-22.6c-12.4-12.4-32.8-12.4-45.3 0l-22.6 22.6 158.4 158.4 22.6-22.6c12.4-12.4 12.4-32.8 0-45.3l-22.6-22.6 67.9-67.9c12.5-12.4 12.5-32.8.1-45.2" />',viewBox:"0 0 512 512"},copyIcon:{name:"copy",content:'<path d="M384 96H192c-17.7 0-32 14.3-32 32v320c0 17.7 14.3 32 32 32h256c17.7 0 32-14.3 32-32V192zm64 352H192V128h160v96h96zM64 384h64v32H64c-17.7 0-32-14.3-32-32V64c0-17.7 14.3-32 32-32h192l32 32H64z" />',viewBox:"0 0 512 512"},cropIcon:{name:"crop",content:'<path d="M0 96h64v64H0zm448 256v64h64v-64zm-32-224c0-17.6-14.4-32-32-32H192v64h160v320h64zM96 384c0 17.6 14.4 32 32 32h192v-64H160V32H96z" />',viewBox:"0 0 512 512"},crosstabIcon:{name:"crosstab",content:'<path d="M192.3 32H32v160h1v288h447V32zm-.3 416H96v-96h96zm0-128H96v-96h96zm0-128H96V96h96zm128 256h-96v-96h96zm0-128h-96v-96h96zm0-128h-96V96h96zm128 256h-96v-96h96zm0-128h-96v-96h96zm0-128h-96V96h96z" />',viewBox:"0 0 512 512"},crosstabWizardIcon:{name:"crosstab-wizard",content:'<path d="M192 416V192h224v96l32 32V0H0v160h1v288h318.7l-31.9-32zM320 64h96v96h-96zm-128 0h96v96h-96zm-32 352H64v-96h96zm0-128H64v-96h96zm0-128H64V64h96zm344.6 330.1-15.5 15.5c-8.6 8.6-22.4 8.6-31 0l-124-124c-8.6-8.6-8.6-22.4 0-31l15.5-15.5c8.6-8.6 22.4-8.6 31 0l124 124c8.6 8.5 8.6 22.4 0 31M221.2 300.8c-4.3 5.8-2.6 14.2 4 17.8 1.9 1 4 1.4 6.1 1.4l25.4-.3c3.9-.1 7.7 1.8 10 5.1l14.8 21c4.2 5.9 12.7 6.9 18.1 1.7 1.5-1.5 2.6-3.3 3.2-5.3l7.5-24.3c1.2-3.8 4.1-6.7 7.9-7.9l24.5-7.6c6.3-2 9.9-8.7 7.9-15-.8-2.5-2.4-4.7-4.5-6.2l-21-14.8c-3.2-2.3-5.1-6-5.1-10l.3-25.7c.1-6.6-5.2-12.1-11.8-12.2-2.6 0-5.2.8-7.3 2.4l-20.6 15.4c-3.2 2.4-7.3 3-11 1.8l-24.3-8.3c-6.8-2.3-14.3 1.9-15.7 9.3-.4 2.1-.1 4.2.5 6.2l8.2 24.1c1.3 3.7.6 7.8-1.8 11z" />',viewBox:"0 0 512 512"},csIcon:{name:"cs",content:'<path d="M165.9 128c-26.4 0-49.8 5.6-70.1 16.7s-36 26.8-47.1 47.2S32 235.5 32 261.6c0 24.3 5 45.7 14.9 64.3s24.3 32.9 43.1 43 41.2 15.1 67.2 15.1c26.4 0 46.6-3.7 65.8-11v-66.5c-17.1 9.2-32 13.8-49.8 13.8-19.3 0-34.7-5.7-46.2-17.2s-17.3-27.1-17.3-46.9c0-19.9 5.8-35.7 17.3-47.3s27.3-17.4 47.2-17.4c9.6 0 16 1.2 25.4 3.5s17.5 5.5 24.4 9.7v-68.9c-19.7-5.2-37-7.8-58.1-7.8m158.8 0-13.3 62h-29l-9.3 46h28.6l-10.3 43h-25.6l-9.8 46h25.2l-12.5 59h50l12.9-59h43.5l-12.5 59h49.2l13.3-59h26.8l11.5-46h-28.2l10.3-43h24.2l10.3-46h-23.7l13.5-63h-51.7l-13.5 63h-43.5l13.5-63h-50zm26.9 108H395l-10.3 43h-43.3z" />',viewBox:"0 0 512 512"},csprojIcon:{name:"csproj",content:'<path d="M64 32c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32zm157.9 32.1c19.3-1.2 35.2 14.7 34 34-1 15.9-13.9 28.8-29.9 29.9-19.3 1.2-35.2-14.7-34-34 1.1-16 14-28.9 29.9-29.9m96 0c19.3-1.2 35.2 14.7 34 34-1 15.9-13.9 28.8-29.9 29.9-19.3 1.2-35.2-14.7-34-34 1.1-16 14-28.9 29.9-29.9m96 0c19.3-1.2 35.2 14.7 34 34-1 15.9-13.9 28.8-29.9 29.9-19.3 1.2-35.2-14.7-34-34 1.1-16 14-28.9 29.9-29.9M64 160h384v288H64zm119.7 64c-17.3 0-32.7 3.5-46 10.4s-23.6 16.8-30.9 29.5c-7.3 12.8-10.9 27.3-10.9 43.6 0 15.2 3.3 28.6 9.8 40.2s15.9 20.6 28.3 26.8c12.4 6.3 27 9.4 44.1 9.4q25.95 0 45.9-6.9v-41.5c-11.9 5.8-23.7 8.6-35.4 8.6-12.6 0-22.8-3.6-30.3-10.7s-11.4-16.9-11.4-29.2c0-12.4 3.8-22.3 11.3-29.6s17.9-10.9 31-10.9c6.3 0 12.6.7 18.8 2.1s11.5 3.5 16 6v-43c-13.1-3.2-26.4-4.8-40.3-4.8m114.2 0-8.3 39h-17.4l-5.7 29H284l-6.1 26H262l-6.1 29h15.4l-7.7 37h30.9l7.9-37h26.8l-7.7 37h30.4l8.2-37h16.3l7.2-29h-17.2l6.1-26h15l6.3-29h-14.7l8.3-39H356l-8.3 39h-26.4l8.3-39zm16.8 68h26.8l-6.3 27h-26.7z" />',viewBox:"0 0 512 512"},css3Icon:{name:"css3",content:'<path d="m64 32 30.2 384L256 480l161.8-64L448 32zm65.6 82h250.3l-4.9 48.9L255.4 214h115.9L358 366.1l-102.1 29.7-102.4-30.2-6.6-76.6h50.9l3.3 39.7 54.4 13.8.5-.1v-.1l56.3-15.8 3.9-64.4H143.7l-3.8-47.8 123-51.2H135.7z" />',viewBox:"0 0 512 512"},cssIcon:{name:"css",content:'<path d="m192 96-32 .1S96 96 96 160v48c0 27.8-21.8 31.4-32 32H48c-2.2 0-4.3.4-6.2 1.2-.5.2-1 .4-1.4.7s-.9.5-1.3.8c-1.3.9-2.4 1.9-3.4 3.1-.2.2-.3.4-.5.6-.9 1.2-1.7 2.6-2.2 4.1-.2.5-.3 1-.5 1.5-.3 1-.4 2.1-.5 3.2v1.6c.1 1.1.2 2.1.5 3.2.1.5.3 1 .5 1.5.5 1.5 1.3 2.8 2.2 4.1.2.2.3.4.5.6 1 1.2 2.1 2.2 3.4 3.1.4.3.9.5 1.3.8s.9.5 1.4.7c1.9.8 4 1.2 6.2 1.2h16c10.2.6 32 4.2 32 32v48c0 64 64 63.9 64 63.9l32 .1v-32l-31.8-.1s-32.2.1-32.2-32v-48.5s0-29-19.6-47.9c19.6-18.8 19.6-47.9 19.6-47.9v-47.9c0-31.9 32.2-31.8 32.2-31.8l31.8-.1zm128-.1V128l31.7.1S384 128 384 160v48s0 29.1 19.5 48C384 274.9 384 304 384 304v48c0 32-32.1 31.9-32.1 31.9l-31.9.1v32l32.1-.1s63.9.1 63.9-63.7V304c0-27.8 21.8-31.4 32-32h16c2.2 0 4.3-.4 6.2-1.2.5-.2 1-.4 1.4-.7s.9-.5 1.3-.8c1.3-.9 2.4-1.9 3.4-3.1.2-.2.3-.4.5-.6.9-1.2 1.7-2.6 2.2-4.1.2-.5.3-1 .5-1.5.3-1 .4-2.1.5-3.2v-1.6c-.1-1.1-.2-2.1-.5-3.2-.1-.5-.3-1-.5-1.5-.5-1.5-1.3-2.8-2.2-4.1-.2-.2-.3-.4-.5-.6-1-1.2-2.1-2.2-3.4-3.1-.4-.3-.9-.5-1.3-.8s-.9-.5-1.4-.7c-1.9-.8-4-1.2-6.2-1.2h-16.1c-10.2-.6-31.9-4.2-31.9-32v-48c0-64-64.1-63.9-64.1-63.9z" />',viewBox:"0 0 512 512"},customFormatIcon:{name:"custom-format",content:'<path d="M128 128v224H80V182.4s-13.1 19.1-48 19.1v-40.6c34.9 0 61.7-32.9 61.7-32.9zm94.4 184H320v40H169v-16.6c.3-11.3 2.2-21.4 6-30.3 3.8-9 8.6-17 14.3-24.1s12-13.4 18.8-18.9 13.3-10.4 19.4-14.8c6.5-4.6 12.1-9 17-13.2s9-8.4 12.3-12.5 5.8-8.3 7.5-12.6c1.6-4.2 2.5-8.8 2.5-13.6 0-9.4-2.7-16.5-8-21.4-5.3-4.8-13.5-7.2-24.4-7.2-18.9 0-37.1 7.5-54.4 22.6v-42.7q28.8-18.6 64.8-18.6c11.2 0 21.2 1.5 30 4.4 8.9 2.9 16.4 7.1 22.5 12.5s10.8 12 14.1 19.7c3.2 7.7 4.8 16.4 4.8 25.9 0 10.1-1.6 19.2-4.7 27-3.1 7.9-7.3 15.1-12.4 21.5-5.2 6.5-11.1 12.4-17.9 17.7q-10.2 8.1-21 15.6c-4.9 3.5-9.7 6.9-14.2 10.4-4.6 3.4-8.6 6.8-12.1 10.1s-6.2 6.6-8.3 9.8c-2.2 3.1-3.2 9.3-3.2 9.3M341 341.2v-41.7s32.1 15.8 51.5 15.8c12.2 0 21.8-2.6 28.6-7.9s10.2-12.5 10.2-21.9c0-9.7-4.2-17.1-12.7-22.3-8.4-5.3-20-7.9-34.8-7.2H364v-37h17.7c28.4 0 42.6-9.4 42.6-28.1q0-26.4-32.7-26.4c-14.7 0-28.8 4.7-42.6 14v-38.9c15.4-7.7 33.1-11.5 53.6-11.5 22.3 0 39.6 5 52.1 14.9 12.4 10 18.7 22.9 18.7 38.8 0 28.3-14.5 46-43.4 53.2v.3c15.5 1.9 27.6 7.5 36.5 16.8 8.9 9.2 13.3 20.6 13.3 34 0 20.3-7.4 36.4-22.4 48.2S421.9 352 395.7 352c-22.3.1-40.6-3.5-54.7-10.8" />',viewBox:"0 0 512 512"},customIconIcon:{name:"custom-icon",content:'<path d="M352 249H196.6q.9 35.7 19.8 55.2c18.9 19.5 30 18.8 52 19.4 4.9.1-1.1 28.8-12.4 28.8-30.9 0-51.6-9.7-69.3-29.1-17.8-19.4-26.7-46.8-26.7-82 0-33.3 9.7-60.4 29.1-81.4s43.5-31.4 72.4-31.4c28.8 0 51.1 9.1 66.9 27.2S352 199 352 231.1zm-36-29.9c-.1-19.8-5.1-35.2-14.7-46.2-9.7-11-23.1-16.5-40.3-16.5-16.6 0-30.7 5.8-42.4 17.3-11.6 11.6-18.8 26.7-21.5 45.3zM448 384V64c0-17.7-14.3-32-32-32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h256zm-32-32h-96v96H96V64h320z" />',viewBox:"0 0 512 512"},cutIcon:{name:"cut",content:'<path d="M480 32h-45.3L256 210.7 210.7 256l-69.5 69.5c-9.1-3.6-18.9-5.5-29.2-5.5-44.2 0-80 35.8-80 80 0 10.3 2 20.2 5.5 29.2 8.1 20.7 24.6 37.1 45.3 45.3 9.1 3.6 18.9 5.5 29.2 5.5 44.2 0 80-35.8 80-80 0-10.3-2-20.2-5.5-29.2l69.5-69.5 69.5 69.5c-3.6 9.1-5.5 18.9-5.5 29.2 0 44.2 35.8 80 80 80 10.3 0 20.2-2 29.2-5.5 20.7-8.1 37.1-24.6 45.3-45.3 3.6-9.1 5.5-18.9 5.5-29.2 0-44.2-35.8-80-80-80-10.3 0-20.2 2-29.2 5.5L301.3 256 480 77.3zM160 400c0 26.5-21.5 48-48 48-.9 0-1.8 0-2.7-.1-24.4-1.3-43.9-20.9-45.3-45.3 0-.9-.1-1.8-.1-2.7 0-26.5 21.5-48 48-48 .9 0 1.8 0 2.7.1 24.4 1.3 43.9 20.9 45.3 45.3.1.9.1 1.8.1 2.7m237.3-47.9c.9 0 1.8-.1 2.7-.1 26.5 0 48 21.5 48 48 0 .9 0 1.8-.1 2.7-1.3 24.4-20.9 43.9-45.3 45.3-.9 0-1.8.1-2.7.1-26.5 0-48-21.5-48-48 0-.9 0-1.8.1-2.7 1.4-24.5 20.9-44 45.3-45.3M240 256c0-8.8 7.2-16 16-16s16 7.2 16 16-7.2 16-16 16-16-7.2-16-16m-74.5-45.3L32 77.3V32h45.3l133.5 133.5z" />',viewBox:"0 0 512 512"},dataCsvIcon:{name:"data-csv",content:'<path d="M415.9 93.6v.3c-.5 33.9-86.3 61.3-191.9 61.3S32.6 127.8 32.1 93.9v-.3C32.1 59.6 118 32 224 32s191.9 27.6 191.9 61.6m0 46.4v.3c-.5 33.9-86.3 61.3-191.9 61.3S32.5 174.2 32 140.3v-.3l.1 86.8v.3c.5 33.9 86.3 61.3 191.9 61.3s191.4-27.4 192-61.3v-.3zm.1 180-.1-52v.3c-.3 21.7-35.7 40.8-88.9 51.7zM271 420.8c-7.7 4.5-16.4 6.8-25.4 6.7q-14.55 0-23.1-9c-8.55-9-8.6-14.1-8.6-24.3 0-10.6 3-19 9.1-25.2s14-9.3 23.9-9.3c8.4-.1 16.7 2 24 6.3v-22.8c-7-2.6-15.7-3.9-25.9-3.9-16.6 0-30 5.2-40.4 15.7S189 379.1 189 395.9c0 15.8 4.6 28.4 13.8 37.9s21.9 14.2 38 14.2c12.3 0 22.3-1.9 30-5.6zm36.6 25.7c5.4 1 10.9 1.5 16.4 1.5 5.4 0 10.7-.5 16-1.6 4.7-.9 9.2-2.7 13.3-5.3 3.8-2.4 6.8-5.8 9-9.7 2.2-4 3.3-8.9 3.3-14.8.1-3.8-.6-7.6-1.9-11.2-1.3-3.2-3.1-6.1-5.5-8.5-2.6-2.6-5.5-4.9-8.6-6.7-3.6-2.1-7.4-4-11.3-5.6-3.1-1.3-5.8-2.5-8.3-3.7-2.2-1-4.3-2.3-6.2-3.7-1.5-1.1-2.9-2.4-4-4-.9-1.4-1.4-3-1.4-4.7 0-1.5.4-3.1 1.2-4.4.9-1.4 2.1-2.5 3.5-3.3 1.7-1 3.6-1.7 5.6-2.2 2.4-.5 4.9-.8 7.3-.8 2.1 0 4.1.2 6.2.4 2.2.3 4.4.8 6.5 1.4 2.2.6 4.3 1.4 6.4 2.3 2 .9 3.9 2 5.8 3.2v-21.9q-5.7-2.1-11.7-3c-4.8-.7-9.7-1-14.5-1-5.3 0-10.6.6-15.8 1.8-4.7 1.1-9.1 3-13.1 5.6-3.7 2.5-6.8 5.8-9 9.7-2.3 4.3-3.4 9.2-3.3 14.1-.2 6.5 2 12.8 6 17.9 4 4.9 10.1 9.1 18.3 12.5q4.8 1.95 9 3.9c2.5 1.1 4.9 2.5 7.2 4 1.8 1.2 3.5 2.7 4.8 4.5 1.2 1.6 1.8 3.5 1.8 5.5 0 1.5-.4 2.9-1.1 4.2-.8 1.4-2 2.5-3.3 3.4-1.7 1-3.6 1.8-5.6 2.2-2.6.6-5.2.8-7.8.8-5.1 0-10.2-.9-15.1-2.7-5.1-1.8-9.8-4.5-13.9-8V442c4.5 2.3 9 3.8 13.8 4.5m147.7-105.4-21.8 72.8c-1.1 3.5-1.8 7.1-2.3 10.8h-.4c-.3-3.6-1.1-7.1-2.1-10.5l-21.9-73.1h-25.5l35.7 105h26.8l36.2-105zm-295.3-15C85.7 317.7 32.4 295 32 268.3v-.3l.1 86.8v.3c.4 26.7 53.7 49.3 127.9 57.8z" />',viewBox:"0 0 512 512"},dataIcon:{name:"data",content:'<path d="M448 125.6v.3c-.5 33.9-86.3 61.3-192 61.3S64.5 159.8 64 125.9v-.3c0-34 86-61.6 192-61.6s192 27.6 192 61.6m0 46.4v.3c-.5 33.9-86.3 61.3-192 61.3S64.5 206.2 64 172.3v-.3l1 86.8v.5c.5 33.7 85.8 61 191 61s190.5-27.3 191-61v-.5zm0 128v.3c-.5 33.9-86.3 61.3-192 61.3S64.5 334.2 64 300.3v-.3l1 86.8v.5c.5 33.7 85.8 61 191 61s190.5-27.3 191-61v-.5z" />',viewBox:"0 0 512 512"},dataJsonIcon:{name:"data-json",content:'<path d="M415.9 93.6v.3c-.5 33.9-86.3 61.3-191.9 61.3S32.6 127.8 32.1 93.9v-.3C32.1 59.6 118 32 224 32s191.9 27.6 191.9 61.6m0 46.4v.3c-.5 33.9-86.3 61.3-191.9 61.3S32.5 174.2 32 140.3v-.3l.1 86.8v.3c.5 33.9 86.3 61.3 191.9 61.3s191.4-27.4 192-61.3v-.3zm.1 180-.1-52v.3c-.3 21.7-35.7 40.8-88.9 51.7zm-251.3 21.1h-23.6v62.4q0 24-16.2 24c-4.9.1-9.7-1.5-13.6-4.5v22.2c4.9 1.9 10.1 2.9 15.3 2.8 12.4 0 21.8-3.7 28.3-11.2s9.8-18.2 9.8-32.3zm31.7 105.4c5.4 1 10.9 1.5 16.4 1.5 5.4 0 10.7-.5 16-1.6 4.7-.9 9.2-2.7 13.3-5.3 3.8-2.4 6.8-5.8 9-9.7 2.2-4 3.3-8.9 3.3-14.8.1-3.8-.6-7.6-1.9-11.2-1.3-3.2-3.1-6.1-5.5-8.5-2.6-2.6-5.4-4.9-8.6-6.7-3.6-2.1-7.4-4-11.3-5.6-3.1-1.3-5.8-2.5-8.3-3.7-2.2-1-4.3-2.3-6.2-3.7-1.6-1.1-2.9-2.4-4-4-.9-1.4-1.4-3-1.4-4.7 0-1.5.4-3.1 1.2-4.4.9-1.4 2.1-2.5 3.5-3.3 1.7-1 3.6-1.7 5.6-2.2 2.4-.5 4.9-.8 7.4-.7 2.1 0 4.1.1 6.2.4 2.2.3 4.4.8 6.6 1.4s4.3 1.4 6.4 2.3c2 .9 3.9 2 5.8 3.2v-21.9q-5.7-2.1-11.7-3c-4.8-.7-9.7-1-14.5-1-5.3 0-10.6.6-15.8 1.8-4.7 1.1-9.1 3-13.1 5.6-3.7 2.5-6.8 5.8-9 9.7-2.3 4.3-3.4 9.2-3.3 14.1-.2 6.5 1.9 12.8 6 17.9 4 4.9 10.1 9.1 18.4 12.5q4.8 1.95 9 3.9c2.5 1.1 4.9 2.5 7.2 4 1.8 1.2 3.5 2.7 4.8 4.5 1.2 1.6 1.8 3.5 1.8 5.5 0 1.5-.4 2.9-1.1 4.2-.8 1.4-2 2.5-3.3 3.4-1.7 1-3.6 1.8-5.6 2.2-2.6.6-5.2.8-7.8.8-5.1 0-10.3-.9-15.1-2.7-5.1-1.8-9.7-4.5-13.8-8v23.4c4.1 2.2 8.7 3.7 13.4 4.4m157.3-13.7q14.4-15.15 14.4-39.9c0-16.1-4.6-29-13.9-38.8s-21.4-14.7-36.4-14.7c-15.9 0-28.6 5.1-38.2 15.4s-14.4 23.7-14.4 40.3c0 15.7 4.7 28.5 14.2 38.3s21.7 14.7 36.8 14.7q23.1-.15 37.5-15.3m-17.5-64c4.6 6 6.9 14.5 7 25.4 0 10.4-2.4 18.6-7.2 24.5s-11.3 8.8-19.4 8.8c-7.5.2-14.6-3.2-19.2-9.1-4.9-6.1-7.3-14.3-7.3-24.7 0-10.2 2.4-18.5 7.3-24.7s11.5-9.3 19.8-9.3c8 0 14.4 3.1 19 9.1M480 341.1h-22.3v58.1q-.15 7.2.6 14.4h-.3c-1.6-2.8-3.4-5.7-5.3-8.6L411 341.1h-25.5v105h22.3v-57.7c0-7.6-.2-13.3-.6-17h.3c1.6 3 3.4 5.9 5.3 8.7l43.3 66H480zM96 313.9c-39-11.2-63.7-27.5-64-45.6v-.3l.1 86.8v.3c.3 18.1 24.9 34.3 63.9 45.6z" />',viewBox:"0 0 512 512"},dataOdsIcon:{name:"data-ods",content:'<path d="M415.94 93.61v.33c-.53 33.88-86.26 61.29-191.93 61.29S32.6 127.82 32.07 93.94v-.33C32.06 59.59 118 32 224 32s191.94 27.59 191.94 61.61m-.06 46.39v.32c-.53 33.88-86.26 61.29-191.93 61.29S32.54 174.2 32 140.32V140l.12 86.81v.32c.53 33.88 86.26 61.29 191.93 61.29S415.46 261 416 227.13v-.32Zm.12 180-.07-52v.32c-.34 21.73-35.73 40.8-88.93 51.68Zm-256 6.11C85.73 317.69 32.43 295 32 268.32V268l.12 86.81v.32C32.55 381.8 85.8 404.47 160 412.9Zm73.5 123.55q-22.26 0-36.28-14.49t-14-37.76q0-24.57 14.24-39.74t37.72-15.18q22.18 0 35.88 14.53t13.69 38.3q0 24.42-14.2 39.38t-37.05 14.96m1-87.08q-12.28 0-19.51 9.22t-7.23 24.39q0 15.39 7.23 24.35a23.15 23.15 0 0 0 18.93 9q12.07 0 19.15-8.71t7.08-24.17q0-16.11-6.86-25.08t-18.78-9Zm68.9 85.28V344.23h36.71q55.22 0 55.21 50.51 0 24.21-15.06 38.66t-40.15 14.46Zm23.34-84.63v65.69h11.57q15.17 0 23.81-9.1t8.64-24.82q0-14.82-8.56-23.31t-24-8.49Zm82.49 80.65v-23.12a44.8 44.8 0 0 0 13.66 7.91 43.9 43.9 0 0 0 14.89 2.64 33 33 0 0 0 7.7-.8 18 18 0 0 0 5.49-2.2 9.7 9.7 0 0 0 3.29-3.33 8.3 8.3 0 0 0 1.08-4.15 9 9 0 0 0-1.73-5.42 18.8 18.8 0 0 0-4.74-4.41 49 49 0 0 0-7.12-3.9q-4.11-1.87-8.89-3.83-12.14-5.06-18.1-12.36a27 27 0 0 1-6-17.63 28.05 28.05 0 0 1 3.25-13.91 27.7 27.7 0 0 1 8.85-9.58 39.9 39.9 0 0 1 13-5.53 66.6 66.6 0 0 1 15.61-1.77 94 94 0 0 1 14.34 1 56.4 56.4 0 0 1 11.53 3v21.6a36 36 0 0 0-5.68-3.18 45 45 0 0 0-6.32-2.27 49 49 0 0 0-6.47-1.34 45.5 45.5 0 0 0-6.1-.43 31.7 31.7 0 0 0-7.23.76 18.2 18.2 0 0 0-5.49 2.13 10.5 10.5 0 0 0-3.47 3.29 7.77 7.77 0 0 0-1.23 4.3 8.27 8.27 0 0 0 1.37 4.66 15.9 15.9 0 0 0 3.91 3.9 41 41 0 0 0 6.14 3.61q3.61 1.77 8.16 3.65a91.6 91.6 0 0 1 11.17 5.53 39.9 39.9 0 0 1 8.49 6.61 25.8 25.8 0 0 1 5.42 8.42 29.8 29.8 0 0 1 1.88 11q0 8.67-3.29 14.56a26.7 26.7 0 0 1-8.92 9.54 38.6 38.6 0 0 1-13.12 5.24 76 76 0 0 1-15.79 1.59 88 88 0 0 1-16.22-1.44 49.2 49.2 0 0 1-13.31-4.34Z" />',viewBox:"0 0 512 512"},dataRestIcon:{name:"data-rest",content:'<path d="M32 268v.33zm0 .33.12 86.48v.32c.29 18.1 24.9 34.34 63.87 45.56l.01-86.77c-38.99-11.22-63.7-27.48-64-45.59m192.01-113.1c105.67 0 191.4-27.41 191.93-61.29v-.33C415.94 59.59 330 32 224 32S32.06 59.59 32.07 93.61v.33c.53 33.88 86.27 61.29 191.94 61.29M32 140.32s0 .01 0 0V140zm384 86.81v-.32l-.12-86.81v.32c-.53 33.88-86.26 61.29-191.93 61.29-105.66 0-191.4-27.41-191.95-61.28l.12 86.48v.32c.53 33.88 86.26 61.29 191.93 61.29S415.46 261 416 227.13M327 320h89l-.07-52v.32c-.34 21.73-35.73 40.8-88.93 51.68m-130.74 96.93 19.85 31.05h-27.17l-16.33-27.03c-1.22-2.05-2.39-3.88-3.52-5.49-1.12-1.61-2.26-2.99-3.41-4.14s-2.34-2.03-3.59-2.64-2.6-.92-4.06-.92h-6.37v40.21H128V342.95h37.5c25.49 0 38.23 9.52 38.23 28.56q0 5.49-1.68 10.14c-1.12 3.1-2.71 5.9-4.76 8.39s-4.53 4.64-7.43 6.45c-2.91 1.81-6.14 3.22-9.7 4.25v.29c1.56.49 3.08 1.28 4.54 2.38s2.88 2.38 4.25 3.85c1.37 1.46 2.67 3.04 3.92 4.72 1.23 1.69 2.37 3.34 3.39 4.95m-17.43-42.48c0-9.18-5.49-13.77-16.48-13.77h-10.69v29.22h10.25c5.08 0 9.16-1.46 12.23-4.39 3.13-2.98 4.69-6.67 4.69-11.06m70.75 30.32h34.35v-19.19h-34.35v-23.36h36.91v-19.26h-60.57v105.03h62.99V428.8h-39.33zm115.58-6.01c-2.39-2.49-5.26-4.72-8.61-6.7-3.34-1.98-7.12-3.85-11.32-5.6-3.08-1.27-5.84-2.5-8.28-3.7s-4.52-2.42-6.23-3.66q-2.565-1.86-3.96-3.96c-.93-1.39-1.39-2.97-1.39-4.72 0-1.61.41-3.06 1.25-4.36.83-1.29 2-2.4 3.52-3.33 1.51-.93 3.37-1.65 5.57-2.16s4.64-.77 7.32-.77c1.95 0 4.02.15 6.19.44s4.36.75 6.56 1.36 4.33 1.38 6.41 2.31c2.07.93 3.99 2 5.75 3.22v-21.9c-3.56-1.37-7.46-2.38-11.68-3.04s-9.07-.99-14.54-.99c-5.57 0-10.84.6-15.82 1.79s-9.36 3.06-13.15 5.6c-3.78 2.54-6.77 5.77-8.97 9.7q-3.3 5.895-3.3 14.1c0 6.98 2.01 12.94 6.04 17.87s10.14 9.11 18.35 12.52c3.22 1.32 6.23 2.61 9.01 3.88s5.19 2.59 7.21 3.96q3.045 2.055 4.8 4.47c1.755 2.415 1.76 3.44 1.76 5.49 0 1.51-.37 2.92-1.1 4.21s-1.84 2.42-3.33 3.37-3.34 1.7-5.57 2.23q-3.33.81-7.8.81-7.62 0-15.09-2.67c-7.47-2.67-9.59-4.46-13.84-8.02v23.44c3.81 1.95 8.31 3.42 13.51 4.39s10.68 1.46 16.44 1.46c5.61 0 10.95-.54 16-1.61s9.49-2.84 13.29-5.31 6.82-5.69 9.05-9.67q3.33-5.97 3.33-14.76c0-4.25-.63-7.97-1.9-11.17a26.1 26.1 0 0 0-5.48-8.52m14.94-55.81v19.26h29.81v85.77h23.73v-85.77h29.96v-19.26z" />',viewBox:"0 0 512 512"},dataSdsIcon:{name:"data-sds",content:'<path d="M224 152.54c105.6 0 191.4-27.4 191.9-61.3v-.3c0-34-85.9-61.6-191.9-61.6S32.1 56.94 32.1 90.94v.3c.5 33.9 86.3 61.3 191.9 61.3m-191.9 71.9c.5 33.9 86.3 61.3 191.9 61.3s191.4-27.4 192-61.3v-.3l-.1-86.5c-.5 33.9-86.3 61.3-191.9 61.3s-191.49-27.4-192-61.29l.1 86.49zm-.1 41.21.1 86.49v.3c.4 26.7 53.7 49.3 127.9 57.8v-86.8c-74.29-8.4-127.59-31.1-128-57.79m320 37.69 105 70-105 70v-52.5H189v-35h163z" />',viewBox:"0 0 512 512"},dataSqlIcon:{name:"data-sql",content:'<path d="M415.9 93.6v.3c-.5 33.9-86.3 61.3-191.9 61.3S32.6 127.8 32.1 93.9v-.3C32.1 59.6 118 32 224 32s191.9 27.6 191.9 61.6m0 46.4v.3c-.5 33.9-86.3 61.3-191.9 61.3S32.5 174.2 32 140.3v-.3l.1 86.8v.3c.5 33.9 86.3 61.3 191.9 61.3s191.4-27.4 192-61.3v-.3zm.1 180-.1-52v.3c-.3 21.7-35.7 40.8-88.9 51.7zM209.1 448.6c5.4 1 10.9 1.5 16.4 1.5 5.4 0 10.7-.5 16-1.6 4.7-.9 9.2-2.7 13.3-5.3 3.8-2.4 6.8-5.8 9-9.7 2.2-4 3.3-8.9 3.3-14.8.1-3.8-.6-7.6-1.9-11.2-1.3-3.2-3.1-6.1-5.5-8.5-2.5-2.6-5.4-4.9-8.6-6.7-3.6-2.1-7.4-4-11.3-5.6-3.1-1.3-5.8-2.5-8.3-3.7-2.2-1-4.3-2.3-6.2-3.7-1.6-1.1-2.9-2.4-4-4-.9-1.4-1.4-3-1.4-4.7 0-1.5.4-3.1 1.3-4.4.9-1.4 2.1-2.5 3.5-3.3 1.7-1 3.6-1.7 5.6-2.2 2.4-.5 4.9-.8 7.3-.8 2.1 0 4.1.2 6.2.4 2.2.3 4.4.8 6.6 1.4s4.3 1.4 6.4 2.3c2 .9 3.9 2 5.8 3.2v-21.9q-5.7-2.1-11.7-3c-4.8-.7-9.7-1-14.5-1-5.3 0-10.6.6-15.8 1.8-4.7 1.1-9.1 3-13.1 5.6-3.7 2.5-6.8 5.8-9 9.7-2.3 4.3-3.4 9.2-3.3 14.1-.2 6.5 1.9 12.8 6 17.9 4 4.9 10.1 9.1 18.4 12.5q4.8 1.95 9 3.9c2.5 1.1 4.9 2.4 7.2 4 1.8 1.2 3.5 2.7 4.8 4.5 1.2 1.6 1.8 3.5 1.8 5.5 0 1.5-.4 2.9-1.1 4.2-.8 1.4-2 2.5-3.3 3.4-1.7 1-3.6 1.8-5.6 2.2-2.6.6-5.2.8-7.8.8-5.1 0-10.3-.9-15.1-2.7-5.1-1.8-9.7-4.5-13.8-8v23.4c4 2.3 8.6 3.8 13.4 4.5m172.8-21.2c5.7-9 8.5-19.8 8.5-32.4 0-16.1-4.6-29-13.9-38.8s-21.3-14.7-36.2-14.8c-16 0-28.8 5.1-38.5 15.4s-14.4 23.7-14.4 40.3c-.1 7 1.1 13.9 3.4 20.4 2.1 6.1 5.4 11.7 9.6 16.6 4.2 4.7 9.3 8.6 15 11.2 6.1 2.8 12.8 4.4 19.5 4.5 3.8 4.2 7.4 8.1 10.9 11.8q4.95 5.25 10.8 9.6c3.6 2.6 7.4 4.8 11.6 6.4s8.7 2.4 13.2 2.3c3.4 0 6.7-.2 10.1-.7 2.2-.3 4.3-.8 6.5-1.3V458c-.8.3-1.6.6-2.4.8l-2.7.6c-.9.2-1.9.3-2.8.4s-1.8.1-2.6.1c-2.7 0-5.4-.2-8-.6-2.5-.4-4.9-1.1-7.1-2.1q-3.75-1.65-6.9-4.2c-2.6-2-5-4.3-7.3-6.7 9.9-3.4 18.2-10.1 23.7-18.9m-23.3-56.3c4.6 6 6.9 14.5 6.9 25.3 0 10.4-2.4 18.6-7.2 24.5-4.8 6-11.3 8.9-19.4 8.8-7.5.2-14.7-3.2-19.3-9.1-4.8-6.1-7.3-14.3-7.3-24.7s2.4-18.6 7.3-24.7c4.9-6.2 11.5-9.4 19.8-9.4 8.3.1 14.6 3.1 19.2 9.3m121.4 58h-38.9v-85.8h-23.7v105H480zm-320-103C85.7 317.7 32.4 295 32 268.3v-.3l.1 86.8v.3c.4 26.7 53.7 49.3 127.9 57.8z" />',viewBox:"0 0 512 512"},dataWebIcon:{name:"data-web",content:'<path d="M415.9 93.6v.3c-.5 33.9-86.3 61.3-191.9 61.3S32.6 127.8 32.1 93.9v-.3C32.1 59.6 118 32 224 32s191.9 27.6 191.9 61.6m0 46.4v.3c-.5 33.9-86.3 61.3-191.9 61.3S32.5 174.2 32 140.3v-.3l.1 86.8v.3c.5 33.9 86.3 61.3 191.9 61.3s191.4-27.4 192-61.3v-.3zm.1 180-.1-52v.3c-.3 21.7-35.7 40.8-88.9 51.7zm-151.1 23-14.5 70.1q-1.2 5.85-1.5 11.7h-.3c-.3-3.8-.9-7.6-1.7-11.3L229.6 343h-25.3l-19.1 69.6c-1.1 4-1.9 8.1-2.1 12.3h-.4c-.2-4-.6-8-1.4-12l-14.8-70h-25.8l27.6 105h27.3l17.9-67.4c1-3.9 1.6-7.8 1.9-11.8h.3c.1 4 .7 7.9 1.7 11.8l17.4 67.4H261l27.8-105h-23.9zm109.8 85.8h-39.3v-24h34.4v-19.2h-34.4v-23.4h36.9V343h-60.6v105h63zm66.8 19.2c11.9 0 21.3-2.8 28.2-8.5 6.9-5.6 10.3-13.3 10.3-22.9.1-6.3-2.3-12.3-6.7-16.8-4.5-4.6-10.4-7.3-17.9-8.3v-.3c5.6-1.5 10.8-4.5 14.7-8.9 3.8-4 5.8-9.4 5.8-14.9 0-7.8-3.2-13.9-9.5-18.2s-15.3-6.5-27-6.5h-38.3v105h40.4zm-7.9-87.6c11.5 0 17.3 3.9 17.3 11.6.2 3.7-1.4 7.3-4.2 9.8-2.8 2.4-6.6 3.6-11.5 3.5h-10.4v-24.9zm4.1 42.5c5.5 0 9.7 1.2 12.8 3.6 3 2.4 4.7 6 4.6 9.9.2 4-1.5 7.9-4.6 10.4s-7.4 3.8-12.9 3.8h-12.8v-27.7zM96 313.9c-39-11.2-63.7-27.5-64-45.6v-.3l.1 86.8v.3c.3 18.1 24.9 34.3 63.9 45.6z" />',viewBox:"0 0 512 512"},decimalDecreaseIcon:{name:"decimal-decrease",content:'<path d="M384 32c-35.3 0-64 28.7-64 64v64c0 35.3 28.7 64 64 64 35.4 0 64-28.7 64-64V96c0-35.3-28.6-64-64-64m32 116.7c0 23.5-14.3 42.6-32 42.6-17.6 0-32-19.1-32-42.6V106c0-23.6 14.4-42.7 32-42.7 17.7 0 32 19.1 32 42.7zM384 256c-35.3 0-64 28.7-64 64v64c0 35.3 28.7 64 64 64 35.4 0 64-28.7 64-64v-64c0-35.3-28.6-64-64-64m32 116.7c0 23.6-14.3 42.7-32 42.7-17.6 0-32-19.1-32-42.7V330c0-23.6 14.4-42.7 32-42.7 17.7 0 32 19.1 32 42.7zM224 32c-35.3 0-64 28.7-64 64v64c0 35.3 28.7 64 64 64 35.4 0 64-28.7 64-64V96c0-35.3-28.7-64-64-64m32 116.7c0 23.5-14.3 42.6-32 42.6s-32-19.1-32-42.6V106c0-23.6 14.3-42.7 32-42.7s32 19.1 32 42.7zM128 224H96v-32h32zm128 192h32v32h-32zM64 256l128 96-128 96z" />',viewBox:"0 0 512 512"},decimalIncreaseIcon:{name:"decimal-increase",content:'<path d="M384 256c-35.3 0-64 28.7-64 64v64c0 35.3 28.7 64 64 64 35.4 0 64-28.7 64-64v-64c0-35.3-28.6-64-64-64m32 118c0 23.6-14.3 42.7-32 42.7-17.6 0-32-19.1-32-42.7v-42.7c0-23.5 14.4-42.6 32-42.6 17.7 0 32 19.1 32 42.6zM384 32c-35.3 0-64 28.7-64 64v64c0 35.3 28.7 64 64 64 35.4 0 64-28.7 64-64V96c0-35.3-28.6-64-64-64m32 118c0 23.6-14.3 42.7-32 42.7-17.6 0-32-19.1-32-42.7v-42.7c0-23.6 14.4-42.7 32-42.7 17.7 0 32 19.1 32 42.7zM224 256c-35.3 0-64 28.7-64 64v64c0 35.3 28.7 64 64 64s64-28.7 64-64v-64c0-35.3-28.6-64-64-64m32 118c0 23.6-14.3 42.7-32 42.7s-32-19.1-32-42.7v-42.7c0-23.5 14.3-42.6 32-42.6s32 19.1 32 42.6zM96 416h32v32H96zm160-224h32v32h-32zM192 32v192L64 128z" />',viewBox:"0 0 512 512"},decreaseHorizontalSpacingIcon:{name:"decrease-horizontal-spacing",content:'<path d="M480 96v160h-96v-64h-96v160h-96V192H96v96H32V64h64v96h96V0h96v160h96V96zM111.6 352 89 374.6l57.4 57.4L89 489.4l22.6 22.6 80-80zM288 432l80 80 22.6-22.6-57.3-57.4 57.4-57.4L368 352z" />',viewBox:"0 0 512 512"},decreaseVerticalSpacingIcon:{name:"decrease-vertical-spacing",content:'<path d="M191 320v96h96v64H63v-64h96v-96H-1v-96h160v-96H95V32h160v96h-64v96h160v96zm160 105.4 22.6 22.6 57.4-57.4 57.4 57.4 22.6-22.6-80-80zm80-226.8 80-80L488.4 96 431 153.4 373.6 96 351 118.6z" />',viewBox:"0 0 512 512"},deliciousBoxIcon:{name:"delicious-box",content:'<path d="M480 448V64c0-17.7-14.3-32-32-32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32m-224-32V256H96V96h160v160h160v160z" />',viewBox:"0 0 512 512"},deliciousIcon:{name:"delicious",content:'<path d="M256 32h224v224H256zM32 256h224v224H32z" />',viewBox:"0 0 512 512"},detailSectionIcon:{name:"detail-section",content:'<path d="M96 32c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32zm320 416H96V64h320zm-33-224h-63v-32h63zm-96-32h-63v32h63zm-96 0h-63v32h63zm192 96h-63v32h63zm-96 0h-63v32h63zm-96 0h-63v32h63z" />',viewBox:"0 0 512 512"},diggBoxIcon:{name:"digg-box",content:'<path d="M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32M160 203.5V352H64V192h64v-64h32zM212 352h-32V192h32zm0-192h-32v-32h32zm119 153.7V416h-96v-32h64v-32h-64V192h96zm117 0V416h-96v-32h64v-32h-64V192h96zM96 224h32v96H96zm171 0h32v96h-32zm117 0h32v96h-32z" />',viewBox:"0 0 512 512"},diggIcon:{name:"digg",content:'<path d="M96 96v64H32v160h96V96zm64 0v32h32V96zm0 64v160h32V160zm64 0v160h64v32h-64v32h96V160zm128 0v160h64v32h-64v32h96V160zM64 192h32v96H64zm192 0h32v96h-32zm128 0h32v96h-32z" />',viewBox:"0 0 512 512"},dimensionsIcon:{name:"dimensions",content:'<path d="M320 0H0v512h128V128h384V0zM32 32h64v64H32zm64 352H64v32h32v64H32V320h64zm0-192H64v32h32v64H32V128h64zm128-96V64h-32v32h-64V32h160v64zm256 0h-64V64h-32v32h-64V32h160z" />',viewBox:"0 0 512 512"},displayBlockIcon:{name:"display-block",content:'<path d="M32 32h448v32H32zm0 416h448v32H32zm0-64h448V128H32zm64-192h320v128H96z" />',viewBox:"0 0 512 512"},displayFlexIcon:{name:"display-flex",content:'<path d="M32 32v448h448V32zm416 416H64V64h384zM128 128h96v256h-96zm160 0h96v256h-96z" />',viewBox:"0 0 512 512"},displayInlineBlockIcon:{name:"display-inline-block",content:'<path d="M448 32h32v448h-32zM32 32h32v448H32zm64 352h320V128H96zm64-192h192v128H160z" />',viewBox:"0 0 512 512"},displayInlineFlexIcon:{name:"display-inline-flex",content:'<path d="M96 416h320V96H96zm32-288h256v256H128zm32 32h64v192h-64zm128 0h64v192h-64zM32 32h32v448H32zm416 0h32v448h-32z" />',viewBox:"0 0 512 512"},divIcon:{name:"div",content:'<path d="M0 416v-6h7.1c7.9 0 13.6-3 16.9-9.1 2-3.6 3-11.8 3-24.5V231.6c0-14-1.3-22.8-3.9-26.3-3.6-4.9-9-7.3-16.1-7.3H0v-6h77.6c28.5 0 50.2 3.8 65 11.4 14.9 7.6 26.8 20.3 35.8 38s13.6 38.2 13.6 61.5c0 31.2-8.1 57.2-24.2 78.1-18.1 23.3-45.6 35-82.6 35zm54-16.2c11.9 3.1 21.9 4.6 29.9 4.6 21.7 0 39.8-9 54.1-26.9s21.5-42.3 21.5-73c0-30.9-7.2-55.3-21.5-73.2-14.3-17.8-32.8-26.8-55.2-26.8q-12.6 0-28.8 4.8zM298 410v6h-83v-6h6.7c7.8 0 13.5-2.7 17-8.1q3.3-5.25 3.3-25.5V231.6q0-17.1-1.8-22.5c-.9-2.8-2.8-5.1-5.7-7.1-4.1-2.6-8.4-4-12.8-4H215v-6h83v6h-7q-11.85 0-17.4 8.1-3.6 5.25-3.6 25.5v144.9c0 11.4.6 18.9 1.9 22.5 1 2.8 3 5.1 6 7.1 4.1 2.6 8.5 4 13.1 4h7zm214-218v6c-6.4 1.4-11.3 3.9-14.6 7.4-4.7 5.3-8.9 13.4-12.6 24.2L421.6 416h-4.9l-67.9-188.8c-3.5-9.7-5.9-15.6-7.4-17.8-2.2-3.3-5-5.9-8.2-7.8-3.3-1.9-7.6-3.1-13.2-3.6v-6h74v6c-8.4 1-13.8 2.7-16.3 5.2s-3.7 5.7-3.7 9.5c0 5.4 2 13.8 6.1 25.2l46.1 128.4L469 239.5c4.2-12.5 6.3-21.2 6.3-26q0-4.65-3.9-9c-2.6-2.9-6.9-4.9-13.1-6.1-.4-.1-1.2-.3-2.3-.5v-6h56zm0-96H0v32h512z" />',viewBox:"0 0 512 512"},divideIcon:{name:"divide",content:'<path d="M416 64 192 448h-64L352 64z" />',viewBox:"0 0 512 512"},documentManagerIcon:{name:"document-manager",content:'<path d="M64 416h224v32H64zm224-64H64v32h224zM400 0C288 0 288 96 288 96v160s0 64 80 64 80-64 80-64V96s0-32-48-32-48 32-48 32v128h32V116c0-11 .6-20 16-20s16 9 16 20v140s0 32-48 32-48-32-48-32V96s0-64 80-64 80 64 80 64v128h32V96s0-96-112-96M106.7 288 96 320H64l64-192h32l64 192h-32l-10.7-32zm10.6-32h53.3L144 176zM320 480H32V96h224V64H32C14.3 64 0 78.3 0 96v384c0 17.7 14.3 32 32 32h288c17.7 0 32-14.3 32-32V352h-32z" />',viewBox:"0 0 512 512"},dollarIcon:{name:"dollar",content:'<path d="M326.6 273c-8.3-7.3-18.4-13.6-30.4-19.1-11.8-5.4-25.2-10.2-40.2-14.5V131.3c6.5.8 13 2.2 17.7 4.2 7.5 3.3 13.7 7.8 18.8 13.7q7.65 8.7 11.4 20.7c2.6 8 3.8 16.7 3.8 26.2H352c0-29.2-7.5-52-22.5-68.8s-36-26.8-62.9-30.1c0 0-5-.4-10.6-.8V32h-32v66.2c-11.9 1.5-22.6 4.3-32.2 8.4-10.6 4.5-19.6 10.3-27.1 17.5s-13.2 15.6-17.2 25.4c-4 9.7-6 20.5-6 32.2 0 12.7 2.2 23.8 6.7 33.4s11 18.2 19.5 25.6 18.8 13.8 30.9 19.3c7.8 3.5 16.3 6.8 25.4 9.7v110.7q-4.05-.6-8.1-1.5c-7.9-1.8-15.2-5.1-21.7-9.8s-11.8-11-15.8-19-6-18-6-30H128c0 16.2 2.6 30 7.9 41.6s12.4 21.2 21.3 28.6c8.9 7.5 19.1 13.3 30.6 17.3s23.4 6.5 35.7 7.5c0 0 .2 0 .5.1V480h32v-64.7c1.9-.2 3.1-.3 3.1-.3 14.1-1.3 26.9-4.1 38.4-8.3q17.25-6.45 29.4-17.1c8.1-7.1 14.3-15.6 18.6-25.4s6.5-20.9 6.5-33.2c0-12.5-2.2-23.5-6.5-33-4.3-9.4-10.6-17.8-18.9-25m-104.7-46.2c-8.8-4.1-15.9-8.4-21.2-12.9s-9.1-9.6-11.3-15c-2.2-5.5-3.4-11.6-3.4-18.5 0-7.4 1.2-14.1 3.6-20.3 2.4-6.1 6-11.3 10.8-15.7 4.8-4.3 10.9-7.7 18.3-10.1 1.7-.6 3.5-1 5.3-1.5v94.9c-.6-.2-1.4-.5-2.1-.9m81 125.2c-3 6.2-7.5 11.4-13.2 15.8-5.8 4.3-12.8 7.7-21.2 10-3.9 1.1-8.1 1.9-12.5 2.5V279.2c5.6 2 10.7 4.1 15.3 6.2 8.6 4 15.6 8.3 20.9 13 5.4 4.7 9.3 9.7 11.7 15.1q3.6 8.1 3.6 17.7c0 7.7-1.5 14.7-4.6 20.8" />',viewBox:"0 0 512 512"},downloadIcon:{name:"download",content:'<path d="M32 384v96h448v-96zM288 32h-64v128h-96l128 160 128-160h-96z" />',viewBox:"0 0 512 512"},downloadLightIcon:{name:"download-light",content:'<path d="M368 256 256 384 144 256h96V32h32v224zm112 192H32v32h448z" />',viewBox:"0 0 512 512"},dragAndDropIcon:{name:"drag-and-drop",content:'<path d="m32 128 192 112L32 352zm224 96v32h224v-32z" />',viewBox:"0 0 512 512"},dribbbleBoxIcon:{name:"dribbble-box",content:'<path d="M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32M256 448c-106 0-192-86-192-192S150 64 256 64s192 86 192 192-86 192-192 192m28-164.8c-82.9 28.9-118.1 83.4-126.7 98.7 27.2 21.3 61.5 34.1 98.7 34.1 22.5 0 43.9-4.6 63.3-13-3.3-18.4-13.1-65.2-34.2-120.1-.4 0-.8.2-1.1.3m-95.5-172.3c-44.9 20.9-78.5 62.1-89 111.8 17.1-.1 78.6-1.7 147.6-20-24.3-43.2-50.3-80.1-58.6-91.8m79 146.8c2.1-.7 4.3-1.3 6.5-2-4.1-9.3-8.6-18.6-13.3-27.8-74.1 22.2-146.1 23.4-164.6 23.4 0 1.6-.1 3.1-.1 4.7 0 40.8 15.3 78 40.4 106.3 10.5-16.7 54.6-79.9 131.1-104.6m94.9-121.1C334.2 111.3 296.9 96 256 96c-12.4 0-24.5 1.4-36 4.1 8.7 11.9 34.9 48.8 58.8 92.7 50.7-19 76-46.7 83.6-56.2m-46.6 138.7C335 328 344 371.9 346.9 387.8c35.2-24.3 60.2-62.5 67.2-106.6-13.2-3.7-53.4-13.1-98.3-5.9m-24.4-58.1c3.8 7.8 7.5 15.8 10.9 23.8 1.2 2.8 2.4 5.7 3.5 8.5 48-6 95.7 1.8 110.2 4.5-.5-37.2-13.7-71.4-35.4-98.3-8.4 10-36.1 39.8-89.2 61.5" />',viewBox:"0 0 512 512"},dribbbleIcon:{name:"dribbble",content:'<path d="M256 32C132.469 32 32 132.469 32 256c0 123.5 100.469 224 224 224 123.5 0 224-100.5 224-224 0-123.531-100.5-224-224-224m148.094 103.281c26.625 32.562 42.781 74.031 43.188 119.188-6.312-1.312-69.562-14.156-133.219-6.156a851 851 0 0 0-4.125-9.875c-3.969-9.312-8.25-18.594-12.688-27.719 70.75-28.875 102.812-69.969 106.844-75.438M256 64.969c48.594 0 93.031 18.219 126.812 48.188-3.438 4.906-32.25 43.625-100.281 69.125-31.344-57.594-66.094-104.938-71.375-112A191 191 0 0 1 256 64.969m-81.344 18.156c5.031 6.938 39.219 54.312 70.938 110.656-89.5 23.781-168.344 23.438-176.906 23.312 12.406-59.374 52.437-108.718 105.968-133.968m-110 173.156c0-1.969.031-3.906.094-5.844 8.375.156 101.094 1.375 196.657-27.219 5.469 10.719 10.688 21.594 15.5 32.469a193 193 0 0 0-7.531 2.281c-98.688 31.875-151.188 118.812-155.531 126.25-30.564-33.937-49.189-78.812-49.189-127.937M256 447.594c-44.25 0-85-15.094-117.438-40.375 3.438-7.031 42.156-81.875 150.094-119.5.406-.125.812-.281 1.25-.406 26.875 69.812 37.969 128.312 40.812 145.094-22.968 9.781-48.218 15.187-74.718 15.187m106.875-32.719c-1.938-11.625-12.125-67.625-37.156-136.406 59.969-9.594 112.625 6.125 119.188 8.188-8.532 53.218-39.095 99.218-82.032 128.218" />',viewBox:"0 0 512 512"},dropletIcon:{name:"droplet",content:'<path d="M256 384v32c-53 0-96-43-96-96h32c0 35.3 28.7 64 64 64m160-72c0 92.8-71.6 168-160 168S96 404.8 96 312C96 181.3 256 32 256 32s160 149.3 160 280m-32 0c0-46.3-25.3-104.7-73-169-20-27-40.3-49.8-55-65.4-14.7 15.6-34.9 38.5-55 65.4-47.8 64.3-73 122.8-73 169 0 75 57.4 136 128 136s128-61 128-136" />',viewBox:"0 0 512 512"},dropletSlashIcon:{name:"droplet-slash",content:'<path d="m317.9 431 23.2 23.2C316.5 470.6 287.3 480 256 480c-88.4 0-160-75.2-160-168 0-27.8 7.2-56.4 18.6-84.2l24.8 24.8C131.9 274 128 293.9 128 312c0 75 57.4 136 128 136 22.4 0 43.5-6.2 61.9-17M256 416v-32c-35.3 0-64-28.7-64-64h-32c0 53 43 96 96 96m224 41.4L457.4 480 32 54.6 54.6 32l108.7 108.7C207 77.7 256 32 256 32s160 149.3 160 280c0 24.1-4.9 47.1-13.6 67.8zM384 312c0-46.3-25.3-104.7-73-169-20-27-40.3-49.8-55-65.4-14.7 15.6-34.9 38.5-55 65.4-1.4 1.9-2.7 3.7-4.1 5.6-.8 1.1-1.5 2.1-2.3 3.2l-1.5 2.1-3 4.2c-.2.3-.4.5-.6.8-1 1.5-2.1 3-3.1 4.5-.1.1-.1.2-.2.3l191.2 191.2c.5-1.6 1-3.3 1.4-4.9 0-.2.1-.4.1-.5.4-1.5.8-2.9 1.1-4.4.1-.3.1-.6.2-.9.3-1.4.6-2.7.9-4.1.1-.4.2-.8.2-1.2.2-1.3.5-2.6.7-3.9.1-.5.2-1 .2-1.5.2-1.2.3-2.5.5-3.7.1-.5.1-1.1.2-1.6l.3-3.6c0-.6.1-1.1.1-1.7.1-1.3.2-2.5.2-3.8 0-.5.1-1 .1-1.6.4-1.9.4-3.7.4-5.5" />',viewBox:"0 0 512 512"},dropletSliderIcon:{name:"droplet-slider",content:'<path d="M192 384v32c-53 0-96-43-96-96h32c0 35.3 28.7 64 64 64m160-72c0 92.8-71.6 168-160 168S32 404.8 32 312C32 181.3 192 32 192 32s160 149.3 160 280m-32 0c0-46.3-25.3-104.7-73-169-20-27-40.3-49.8-55-65.4-14.7 15.6-34.9 38.5-55 65.4-47.8 64.3-73 122.8-73 169 0 75 57.4 136 128 136s128-61 128-136m128-88h-32v256h32zm0-192h-32v64h32zm-64 96v64h96v-64z" />',viewBox:"0 0 512 512"},editAnnotationsIcon:{name:"edit-annotations",content:'<path d="M447.95 32H64c-17.6 0-32 14.4-32 32v416l95.99-96h127.99v-32H114.73L64 402.75V64.06l.06-.06H447.9l.06.06V224h32V64c0-17.6-14.4-32-32-32zm27.4 251.3-22.65-22.65c-6.25-6.2-16.45-6.2-22.65 0L407.4 283.3l45.29 45.3 22.65-22.65c6.2-6.25 6.2-16.45 0-22.65zm-79.24 11.3L255.98 434.75V480h45.24l140.13-140.15zM289.92 446.05l-11.3-11.3 117.49-117.5 11.3 11.3zM352 256H96v-32h256zm32-64H96v-32h288zm32-64H96V96h320zm-96 192H96v-32h224z" />',viewBox:"0 0 512 512"},editToolsIcon:{name:"edit-tools",content:'<path d="m260.6 288 11.5 31.5 56.2-56.6L244.2 32H139.8L0 416h76.8l28-76.8 18.6-51.2zm-17.5-48H140.9L192 99.5zM224 413.3V480h66.7l169.7-168.5-67.9-67.9zm55.3 34-22.6-22.6 135.8-135.8 22.6 22.6zm223.4-178-22.6 22.6-67.9-67.9 22.5-22.7c12.5-12.4 32.9-12.4 45.3 0l22.7 22.7c12.4 12.4 12.4 32.8 0 45.3" />',viewBox:"0 0 512 512"},envelopBoxIcon:{name:"envelop-box",content:'<path d="m377 182.4-88.8 88.8-31.2 29-33.2-29-88.8-88.8c-7.7 2-13.8 8.1-15.8 15.8l73 73-73 73c2 7.7 8.1 13.8 15.8 15.8l73-73 49 44.8 47-44.8 73 73c7.7-2 13.8-8.1 15.8-15.8l-73-73 73-73c-2-7.7-8.1-13.8-15.8-15.8M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m-32 329.6c0 12.4-10 22.4-22.4 22.4H118.4C106 384 96 374 96 361.6V182.4c0-12.4 10-22.4 22.4-22.4h275.2c12.4 0 22.4 10 22.4 22.4z" />',viewBox:"0 0 512 512"},envelopIcon:{name:"envelop",content:'<path d="M64 96c-17.7 0-32 14.3-32 32v256c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V128c0-17.7-14.3-32-32-32zm23.7 32L256 296.3 424.3 128c11 2.9 19.7 11.6 22.6 22.6L342.6 254.9l104.3 104.3c-2.9 11-11.6 19.7-22.6 22.6L320 277.5l-64 64-64-64L87.7 381.8c-11-2.9-19.7-11.6-22.6-22.6l104.3-104.3L65.1 150.6c2.9-11 11.6-19.7 22.6-22.6" />',viewBox:"0 0 512 512"},envelopLinkIcon:{name:"envelop-link",content:'<path d="M224 432c0-5.1.8-10.1 2.3-14.7C232.5 398 250.6 384 272 384h64c-1.5-1.9-3-3.8-4.6-5.6-14.6-16.2-35.8-26.4-59.4-26.4-12.2 0-23.8 2.7-34.1 7.6-4.4 2.1-8.6 4.6-12.5 7.4-16.4 11.8-28.2 29.7-32 50.4-.9 4.7-1.4 9.6-1.4 14.6 0 44.2 35.8 80 80 80 26.2 0 49.4-12.6 64-32h-64c-26.5 0-48-21.5-48-48m208-80c-26.2 0-49.4 12.6-64 32h64c26.5 0 48 21.5 48 48s-21.5 48-48 48h-64c14.6 19.4 37.8 32 64 32 44.2 0 80-35.8 80-80s-35.8-80-80-80m0 64H272c-8.8 0-16 7.2-16 16s7.2 16 16 16h160c8.8 0 16-7.2 16-16s-7.2-16-16-16M32 0C14.3 0 0 14.3 0 32v256c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V32c0-17.7-14.3-32-32-32zm23.7 32L224 200.3 392.3 32c11 2.9 19.7 11.6 22.6 22.6L310.6 158.9l104.3 104.3c-2.9 11-11.6 19.7-22.6 22.6L288 181.5l-64 64-64-64L55.7 285.8c-11-2.9-19.7-11.6-22.6-22.6l104.3-104.3L33.1 54.6C36 43.6 44.7 34.9 55.7 32" />',viewBox:"0 0 512 512"},envelopeBoxIcon:{name:"envelope-box",content:'<path d="m377 182.4-88.8 88.8-31.2 29-33.2-29-88.8-88.8c-7.7 2-13.8 8.1-15.8 15.8l73 73-73 73c2 7.7 8.1 13.8 15.8 15.8l73-73 49 44.8 47-44.8 73 73c7.7-2 13.8-8.1 15.8-15.8l-73-73 73-73c-2-7.7-8.1-13.8-15.8-15.8M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m-32 329.6c0 12.4-10 22.4-22.4 22.4H118.4C106 384 96 374 96 361.6V182.4c0-12.4 10-22.4 22.4-22.4h275.2c12.4 0 22.4 10 22.4 22.4z" />',viewBox:"0 0 512 512"},envelopeIcon:{name:"envelope",content:'<path d="M64 96c-17.7 0-32 14.3-32 32v256c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V128c0-17.7-14.3-32-32-32zm23.7 32L256 296.3 424.3 128c11 2.9 19.7 11.6 22.6 22.6L342.6 254.9l104.3 104.3c-2.9 11-11.6 19.7-22.6 22.6L320 277.5l-64 64-64-64L87.7 381.8c-11-2.9-19.7-11.6-22.6-22.6l104.3-104.3L65.1 150.6c2.9-11 11.6-19.7 22.6-22.6" />',viewBox:"0 0 512 512"},envelopeLinkIcon:{name:"envelope-link",content:'<path d="M224 432c0-5.1.8-10.1 2.3-14.7C232.5 398 250.6 384 272 384h64c-1.5-1.9-3-3.8-4.6-5.6-14.6-16.2-35.8-26.4-59.4-26.4-12.2 0-23.8 2.7-34.1 7.6-4.4 2.1-8.6 4.6-12.5 7.4-16.4 11.8-28.2 29.7-32 50.4-.9 4.7-1.4 9.6-1.4 14.6 0 44.2 35.8 80 80 80 26.2 0 49.4-12.6 64-32h-64c-26.5 0-48-21.5-48-48m208-80c-26.2 0-49.4 12.6-64 32h64c26.5 0 48 21.5 48 48s-21.5 48-48 48h-64c14.6 19.4 37.8 32 64 32 44.2 0 80-35.8 80-80s-35.8-80-80-80m0 64H272c-8.8 0-16 7.2-16 16s7.2 16 16 16h160c8.8 0 16-7.2 16-16s-7.2-16-16-16M32 0C14.3 0 0 14.3 0 32v256c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V32c0-17.7-14.3-32-32-32zm23.7 32L224 200.3 392.3 32c11 2.9 19.7 11.6 22.6 22.6L310.6 158.9l104.3 104.3c-2.9 11-11.6 19.7-22.6 22.6L288 181.5l-64 64-64-64L55.7 285.8c-11-2.9-19.7-11.6-22.6-22.6l104.3-104.3L33.1 54.6C36 43.6 44.7 34.9 55.7 32" />',viewBox:"0 0 512 512"},equalIcon:{name:"equal",content:'<path d="M96 288h320v64H96zm0-128v64h320v-64z" />',viewBox:"0 0 512 512"},eraserOutlineIcon:{name:"eraser-outline",content:'<path d="m199.55 448.07.07-.07H82.75l.07.07H32V480h448v-31.93zm275.76-298.34L362.25 36.68A15.97 15.97 0 0 0 350.94 32c-4.09 0-8.19 1.56-11.32 4.68l-152.93 152.9-22.61 22.62L50.74 325.52c-24.99 24.98-24.99 65.5-.01 90.48h180.9l68.14-68.13 22.62-22.6 152.92-152.91c6.25-6.25 6.25-16.38 0-22.63M218.38 383.99H66.86c-5.34-11.79-3.17-26.18 6.51-35.85l113.34-113.31 90.43 90.42zm81.39-81.35h-.01l-90.44-90.43L350.93 70.62l90.44 90.42z" />',viewBox:"0 0 512 512"},exclamationCircleIcon:{name:"exclamation-circle",content:'<path d="M224 128h64v160h-64zm0 256h64v-64h-64zm256-128c0 123.7-100.3 224-224 224S32 379.7 32 256 132.3 32 256 32s224 100.3 224 224m-32 0c0-106-86-192-192-192S64 150 64 256s86 192 192 192 192-86 192-192" />',viewBox:"0 0 512 512"},exeIcon:{name:"exe",content:'<path d="M64 32c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32zm160 32c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32m96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32m96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32M64 160h384v288H64z" />',viewBox:"0 0 512 512"},exportIcon:{name:"export",content:'<path d="M96 480c-4.3 0-8.5-.8-12.5-2.5-3.8-1.6-7.3-3.9-10.2-6.9-2.9-2.9-5.3-6.4-6.9-10.2-1.7-3.9-2.5-8.2-2.5-12.5V192c0-4.3.8-8.5 2.5-12.5 1.6-3.8 3.9-7.3 6.9-10.2 2.9-2.9 6.4-5.3 10.2-6.9 3.9-1.7 8.2-2.5 12.5-2.5h96.3v31.9H96.4v256.3h319.1V191.9h-95.9V160H416c17.7 0 32 14.3 32 31.9V448c0 17.7-14.3 32-31.9 32zm192-160V126h64.5L256 32l-96.5 94H224v194z" />',viewBox:"0 0 512 512"},eyeIcon:{name:"eye",content:'<path d="M256 128c-94.8 0-179.8 51.5-224 128 44.3 76.5 129.3 128 224 128s179.8-51.5 224-128c-44.2-76.5-129.2-128-224-128m-32 64c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32M69.8 256c18.4-26.4 44.8-48.7 72.6-65.1 12.2-7.2 25.1-13.2 38.4-17.9-22.6 20.5-36.8 50.1-36.8 83s14.2 62.5 36.8 83c-13.3-4.7-26.2-10.7-38.4-17.9-27.8-16.4-54.2-38.7-72.6-65.1m299.8 65.1c-12.2 7.2-25.1 13.2-38.4 17.9 22.6-20.5 36.8-50.1 36.8-83s-14.2-62.5-36.8-83c13.3 4.7 26.2 10.7 38.4 17.9 27.8 16.4 54.2 38.7 72.6 65.1-18.5 26.4-44.8 48.7-72.6 65.1" />',viewBox:"0 0 512 512"},eyeSlashIcon:{name:"eye-slash",content:'<path d="m245.43 358.68 24.92 24.92c-4.75.26-9.54.4-14.34.4-94.7 0-179.7-51.5-224-128 13.19-22.83 30.01-43.43 49.65-61.1l23.01 23.01C91.46 229.29 79.51 242.07 69.8 256c26.33 33.77 54.15 53.86 72.6 65.1 39.18 23.88 77.54 33.37 103.03 37.58m131.42-4.44L480 457.39 457.39 480 345.51 368.12s-.07.03-.1.04L232.2 254.94l.11-.03-39.21-39.21-.03.11-26.8-26.8s.04-.05.06-.08l-7.01-7.01s-.06.03-.09.04l-24.17-24.17s.06-.03.09-.05L32 54.61 54.61 32l111.87 111.87A260.2 260.2 0 0 1 256 128c94.8 0 179.8 51.5 224 128-24 41.53-60.05 75.69-103.15 98.24m-7.25-33.14c27.8-16.4 54.1-38.7 72.6-65.1-18.4-26.4-44.8-48.7-72.6-65.1-12.2-7.2-25.1-13.2-38.4-17.9 22.6 20.5 36.8 50.1 36.8 83 0 25.15-8.31 48.37-22.32 67.08l7.01 7.01c5.76-2.76 11.41-5.74 16.91-8.99" />',viewBox:"0 0 512 512"},eyedropperIcon:{name:"eyedropper",content:'<path d="m461.1 56.9-6.2-6.2c-25-25-65.5-25-90.5 0l-60.8 60.8-4.3-4.3c-6.2-6.2-16.4-6.2-22.6 0l-9.4 9.4c-6.2 6.2-6.2 16.4 0 22.6l4.3 4.3L70.8 344.4c-8.2 8.2-14 18.5-16.8 29.7l-21.5 85.7c-2.2 8.6 3.1 17.4 11.7 19.5q3.9.9 7.8 0l85.7-21.4c11.3-2.8 21.5-8.6 29.7-16.8l200.8-200.8 4.4 4.4c6.2 6.2 16.4 6.2 22.6 0l9.4-9.4c6.2-6.2 6.2-16.4 0-22.6l-4.4-4.4 60.8-60.8c25-25 24.9-65.5.1-90.6M224 320h-64l144-144 32 32z" />',viewBox:"0 0 512 512"},facebookBoxIcon:{name:"facebook-box",content:'<path d="M57.6 32C43.6 32 32 43.5 32 57.6v396.8c0 14 11.5 25.6 25.6 25.6h396.8c14 0 25.6-11.5 25.6-25.6V57.6c0-14-11.5-25.6-25.6-25.6zm315.8 65.5c24.1 0 42 2.3 42 2.3L414 155s-18.2-.2-38.1-.2c-21.5 0-24.9 9.9-24.9 26.1V224h64.1l-2.8 59H351v165h-63V283h-44v-59h44v-50.5c0-39.6 25.8-76 85.4-76" />',viewBox:"0 0 512 512"},facebookIcon:{name:"facebook",content:'<path d="M290 32c-59.8 0-96 32-96 96v64h-66v96h66v192h96V288h80l14-96h-94v-32c0-32 32-32 32-32h62V34.9c-7.2-.9-65.4-2.9-94-2.9" />',viewBox:"0 0 512 512"},fileAddIcon:{name:"file-add",content:'<path d="M512 416h-64v64h-32v-64h-64v-32h64v-64h32v64h64zM96 448V64h224v96h96v96h32V128l-96-96H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h224v-32" />',viewBox:"0 0 512 512"},fileAscxIcon:{name:"file-ascx",content:'<path d="M384 224h-96v-32h96zm0 160h-96v-32h96zM256 256H128v-96h128zm0 160H128v-96h128zm96-384H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},fileAudioIcon:{name:"file-audio",content:'<path d="M218 353.8c-5.5-2.9-12.1-4.5-19-4.5-21 0-38 14.8-38 33.2s17 33.2 38 33.2 38-14.8 38-33.2V256.6l96-22.6v87.8c-5.5-2.9-12.1-4.5-19-4.5-21 0-38 14.8-38 33.2s17 33.2 38 33.2 38-14.8 38-33.2V192.2l-134 31.5zM352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},fileBacIcon:{name:"file-bac",content:'<path d="M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H289v-96h64l-96.5-96-95.5 96h64v96H96V64h224v96h96z" />',viewBox:"0 0 512 512"},fileConfigIcon:{name:"file-config",content:'<path d="M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96zm-41.8-124.6-23.7-17.9c1-5.7 1.6-11.5 1.6-17.4 0-6-.5-11.8-1.6-17.4l23.7-17.9c3.7-2.8 4.7-7.9 2.4-11.9l-19.4-33.5c-2.3-4-7.2-5.6-11.5-3.9L318.4 215c-8.8-7.5-19-13.5-30.2-17.4l-3.7-29.5c-.6-4.6-4.5-8-9.1-8h-38.7c-4.6 0-8.5 3.4-9.1 8l-3.7 29.5c-11.1 4-21.3 9.9-30.2 17.4l-27.4-11.6c-4.2-1.8-9.2-.1-11.5 3.9l-19.4 33.5c-2.3 4-1.3 9.1 2.4 11.9l23.7 17.9c-1 5.7-1.6 11.5-1.6 17.4 0 6 .5 11.8 1.6 17.4l-23.7 17.9c-3.7 2.8-4.7 7.9-2.4 11.9l19.4 33.5c2.3 4 7.2 5.6 11.5 3.9l27.4-11.6c8.8 7.5 19 13.5 30.2 17.4l3.7 29.5c.6 4.6 4.5 8 9.1 8h38.7c4.6 0 8.5-3.4 9.1-8l3.7-29.5c11.1-4 21.3-9.9 30.2-17.4l27.4 11.6c4.2 1.8 9.2.1 11.5-3.9l19.4-33.5c2.2-4 1.2-9-2.5-11.8M256 336c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48" />',viewBox:"0 0 512 512"},fileCsvIcon:{name:"file-csv",content:'<path d="M178.6 224c-10 0-18.9 2.1-26.7 6.2-7.7 4.2-13.7 10.1-17.9 17.7q-6.3 11.4-6.3 26.1c0 9.1 1.9 17.1 5.7 24.1s9.2 12.3 16.4 16.1 15.7 5.7 25.6 5.7c10 0 18.9-1.4 26.6-4.1v-24.9c-6.9 3.5-13.8 5.2-20.5 5.2-7.3 0-13.2-2.1-17.6-6.4s-6.6-10.1-6.6-17.6 2.2-13.4 6.6-17.7 10.4-6.5 18-6.5c3.7 0 7.3.4 10.9 1.3s6.7 2.1 9.2 3.6V227c-7.6-2-15.3-2.9-23.4-3m73.8.1c-11.5 0-20.6 2.7-27.5 8.1-6.8 5.4-10.2 12.5-10.2 21.5 0 12.8 7.5 22.1 22.4 27.8 4.6 1.7 7.8 3.1 9.5 4.1s3 2 3.8 3.2 1.2 2.5 1.2 4c0 2.1-.8 3.7-2.5 4.8s-4.1 1.7-7.1 1.7c-4.1 0-8.4-.9-13.2-2.6-4.7-1.8-9-4-12.9-6.9V315c8.1 3.3 17 4.9 26.7 4.9 8.4 0 15.5-1.1 21.5-3.4 6-2.2 10.6-5.7 13.9-10.2 3.3-4.6 5-9.9 5-16.1 0-6.3-2-11.8-6-16.4s-10.8-8.9-20.4-12.8c-4.9-2-8.1-3.7-9.6-5s-2.3-2.9-2.3-4.8c0-2 1-3.6 2.8-4.8q2.85-1.8 7.5-1.8c7.6 0 15.2 2.1 23 6.4v-23.6c-4-1.1-7.1-1.8-9.3-2.2s-4.7-.7-7.4-1c-2.7-.1-5.8-.1-8.9-.1m39.8-.1 30 96h31.4l30.4-96h-29.1l-13.8 58.9c-1.1 4.4-1.8 8.1-2 11.1h-.6c-.1-2.4-.8-5.9-1.9-10.7L322.4 224zM352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},fileDataIcon:{name:"file-data",content:'<path d="M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96zM128 229.3v149.4c0 20.6 19.1 37.3 42.7 37.3h170.6c23.6 0 42.7-16.7 42.7-37.3V229.3c0-20.6-19.1-37.3-42.7-37.3H170.7c-23.6 0-42.7 16.7-42.7 37.3M247 379h-76v-47h76zm18-112h76v47h-76zm0 65h76v47h-76zm-18-19h-76v-47h76z" />',viewBox:"0 0 512 512"},fileDiscImageIcon:{name:"file-disc-image",content:'<path d="M256.1 322.7c3.7 0 7.2-1.1 10.1-3s5.2-4.5 6.7-7.6c1.2-2.5 1.9-5.2 1.9-8.1 0-10.3-8.4-18.7-18.7-18.7-2.8 0-5.4.6-7.7 1.7-3.4 1.6-6.3 4.1-8.3 7.3-1.7 2.8-2.7 6.1-2.7 9.7 0 10.4 8.3 18.7 18.7 18.7m-52.5-117.8c-19.1 10.1-34.9 25.5-45.4 44.4-9 16.1-14.1 34.7-14.1 54.4 0 61.7 50 111.7 111.7 111.7 20 0 38.8-5.3 55.1-14.5 18.6-10.6 33.9-26.4 43.9-45.4 8.1-15.5 12.7-33.1 12.7-51.8 0-61.7-50-111.7-111.7-111.7-18.9 0-36.7 4.7-52.2 12.9m89.8 99.2c0 6.1-1.4 11.8-4 16.9l48.7 25.8c-8.3 15.8-20.9 28.9-36.3 37.7l-26.6-48.3c-5.6 3.3-12.1 5.3-19.1 5.3-20.6 0-37.4-16.7-37.4-37.4 0-6.8 1.8-13.2 5-18.7l-49.2-27.1c8.8-15.7 22-28.6 38-37l26.8 49.3c5-2.5 10.7-3.9 16.7-3.9 20.7 0 37.4 16.7 37.4 37.4M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},fileErrorIcon:{name:"file-error",content:'<path d="M160 320h32V160h-32zm16 32c-8.8 0-16 7.2-16 16s7.2 16 16 16 16-7.2 16-16-7.2-16-16-16M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},fileExcelIcon:{name:"file-excel",content:'<path d="m288 304 64 112h-48l-48-84.5-31.5 52.5H256v32h-96l64-112-64-112h48l48 84 48-84h48zm64-272H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},fileFlashIcon:{name:"file-flash",content:'<path d="M352 191.3V237c-21 .2-46.6-3.2-69.6 45H320v45h-47.9s-37.4 91.1-111.9 90.1c-.6-10 0-30.8 0-45 49.3-7.6 65.4-62.1 76.8-89.4 26.5-82.8 73.9-92 93.4-92.1 5.6 0 21.6.7 21.6.7m96-63.3v320c0 17.7-14.3 32-32 32H96c-17.7 0-32-14.3-32-32V64c0-17.7 14.3-32 32-32h256zm-32 32h-96V64H96v384h320z" />',viewBox:"0 0 512 512"},fileFooterIcon:{name:"file-footer",content:'<path d="M416 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m0 416H96V64h320zm-32-224H128v-32h256zm0-96H128v32h256zm0 160H128v96h256z" />',viewBox:"0 0 512 512"},fileHeaderIcon:{name:"file-header",content:'<path d="M416 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m0 416H96V64h320zm-32-64H128v-32h256zm0-96H128v32h256zm0-160H128v96h256z" />',viewBox:"0 0 512 512"},fileHorizontalIcon:{name:"file-horizontal",content:'<path d="M384 64H64c-17.7 0-32 14.3-32 32v320c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V160zm64 352H64V96h288v96h96z" />',viewBox:"0 0 512 512"},fileIcon:{name:"file",content:'<path d="M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},fileImageIcon:{name:"file-image",content:'<path d="M298.7 385.2S272.2 288 213.1 288s-85 128-85 128h256s-11.9-78.7-42.7-78.7-42.7 47.9-42.7 47.9M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96zM288 256c0 17.7 14.3 32 32 32s32-14.3 32-32-14.3-32-32-32-32 14.3-32 32" />',viewBox:"0 0 512 512"},fileMdbIcon:{name:"file-mdb",content:'<path d="M231.1 192 144 416h80v-32h-25.5l14.8-38h85.6l27.2 70h42L281 192zm-1.5 112 26.5-68 26.4 68zM352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},filePdfIcon:{name:"file-pdf",content:'<path d="M240.9 160c-7.6 0-13.8 4-15.4 9.9-4.9 18.6.2 46.3 9.4 82.3l-2.4 5.9c-6.6 16.4-14.8 33-22.1 47.6l-1 1.9c-7.7 15.3-14.6 28.4-21 39.4l-6.5 3.5c-.5.3-11.6 6.3-14.3 7.9-22.2 13.6-36.9 28.9-39.4 41.2-.8 3.9-.2 8.9 3.7 11.2l6.3 3.2c2.7 1.4 5.6 2.1 8.6 2.1 15.8 0 34.2-20.2 59.5-65.3 29.2-9.7 62.5-17.8 91.6-22.3 22.2 12.8 49.5 21.7 66.8 21.7q4.65 0 7.8-.9c3.3-.9 6.1-2.8 7.8-5.4 3.4-5.2 4-12.2 3.1-19.5-.3-2.1-2-4.8-3.8-6.6-5.1-5.2-16.5-7.9-33.7-8.1-11.7-.1-25.8.9-40.6 3-6.6-3.9-13.5-8.2-18.8-13.3-14.4-13.8-26.5-32.9-34-53.9.5-2 .9-3.7 1.3-5.4 0 0 8.1-47.1 6-63.1-.3-2.2-.5-2.8-1.1-4.5l-.7-1.9c-2.2-5.2-6.5-10.7-13.3-10.4zm2.7 8.4c5.1 0 8 13.1 8.2 25.4.3 12.3-2.6 20.9-6 27.3-2.9-9.4-4.3-24.3-4.3-34-.1-.1-.3-18.7 2.1-18.7m.4 104.1c8.6 16 19.3 29.5 31.9 40.4 1.6 1.3 3.2 2.7 5 4.1-25.6 5.2-47.7 11.5-67.1 19.1 3.6-6.5 7.2-13.3 11-20.6 9.1-17.7 14.9-31.6 19.2-43m102.2 51.6c9.3 0 12 0 21.1 2.3 9.1 2.4 9.2 7.2 7.6 8.2s-6 1.6-8.9 1.6c-9.2 0-20.7-4.3-36.8-11.4 6.3-.4 11.9-.7 17-.7m-165.4 35.8c-17.7 28.8-29.5 40.3-37.3 43.8 2.9-8.1 14.3-24 31.2-38.1 1.1-.9 3.7-3.4 6.1-5.7M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},filePptIcon:{name:"file-ppt",content:'<path d="m192 192-32 32h32v192h49v-80h25.6c16.4 0 29.1-1.5 38.2-4.4 14.4-4.5 25.9-12.9 34.4-25.4s12.8-26.6 12.8-42.6q0-23.7-12-41.1c-12-17.4-18.8-20.1-32.4-25.4-10.3-3.7-24.4-5.5-42-5.5M241 225h20.1c11.2.3 20.2 2.1 26.9 5.6 12.1 6.4 23.3 17.6 23.3 33.5 0 17.3-11.9 29-25.2 35-6.7 2.9-15.1 4.4-25.2 3.9H241zM352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},filePresentationIcon:{name:"file-presentation",content:'<path d="M127.5 214.4c0 9.9 6.1 18.2 14.5 21.2v113.1c0 12.4 9.6 22.4 21.3 22.4H246v11.8l-13.6 14.6c-1.9 2-3 4.8-3 8 0 6.3 4.7 11.3 10.5 11.3 2.8 0 5.5-1.3 7.4-3.3.1-.1.2-.3.4-.4l8.9-9.6 8.9 9.6c.1.1.2.3.4.4 1.9 2 4.5 3.3 7.4 3.3 5.8 0 10.5-5 10.5-11.3 0-3.1-1.2-6-3-8L267 382.8V371h78.8c11.1 0 20.1-9.3 20.9-21h1.3V235.9c9-2.6 15.7-11.3 15.7-21.6 0-12.4-9.5-22.4-21.3-22.4H148.8c-11.8.1-21.3 10.1-21.3 22.5M299 237h43v89h-43zm-64 26h43v63h-43zm-64 18h43v45h-43zM352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},fileProgrammingIcon:{name:"file-programming",content:'<path d="m236 256-52.6-.2-48.6 48.6.1.1c-4.1 3.9-6.7 9.4-6.7 15.5 0 5.8 2.3 11 6 14.8l49.1 49.1 46.8-.2-59.7-59.7c.2-.9.3-1.8.3-2.8zm105.2 65.5c.1.9.2 1.9.3 2.8L281.9 384l46.8.2 49.1-49.1c3.7-3.8 6-9.1 6-14.8 0-6.1-2.6-11.6-6.7-15.5l.1-.1-48.6-48.7-52.6.2zM352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},filePsdIcon:{name:"file-psd",content:'<path d="M128 160v256h45v-91h21.4q36.3 0 57.9-23.4c14.4-15.6 21.6-36.1 21.6-61.3 0-53.4-25.2-80.2-75.5-80.2H128zm45 44h17.5c23.7 0 35.5 12.8 35.5 38.6 0 26.3-11.8 39.4-35.5 39.4H173zm164.6 51.7c-8.1 0-15.9.9-23.4 2.8s-14.2 4.7-20 8.6-10.4 9-14 15.2c-3.5 6.2-5.2 13.6-5.2 22.1 0 6.2.8 11.7 2.3 16.3 1.5 4.5 3.7 8.6 6.7 12.1 2.9 3.5 6.5 6.5 10.8 9.2s9.3 5.1 15 7.4c3.5 1.5 7.2 2.8 11 4s7.3 2.5 10.5 4 5.8 3.2 7.8 5.2 3 4.5 3 7.5c0 4.7-2.2 8.2-6.7 10.4-4.5 2.3-10.6 3.4-18.5 3.4-6.4 0-13.3-1.2-20.5-3.4s-14.5-5.8-21.7-10.4v38.3c13.4 5.2 27.9 7.7 43.7 7.7 8.5 0 16.8-.9 24.7-2.8 7.9-1.8 15-4.8 21.1-8.8s10.9-9.2 14.7-15.7 5.5-14.2 5.5-23.3c0-6.5-.9-12-2.7-16.8-1.8-4.7-4.4-8.7-7.8-12.2s-7.4-6.5-12.2-9.1c-4.7-2.6-10-5-15.9-7.1-3.2-1.2-6.5-2.4-9.8-3.5s-6.3-2.4-9-3.9-4.9-3.1-6.5-5.2-2.5-4.4-2.5-7.1c0-2.1.5-3.9 1.7-5.6 1.1-1.7 2.6-3 4.6-4s4.2-1.8 6.7-2.4 5.2-.8 8.1-.8c6.1 0 12.3.9 18.8 2.6 6.4 1.7 12.3 4.4 18 7.8v-36.4c-6.3-2-12.8-3.5-19.3-4.5s-13-1.6-19.3-1.6zM352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96z" />',viewBox:"0 0 512 512"},fileReportIcon:{name:"file-report",content:'<path d="M416 32H96a32 32 0 0 0-32 32v384a32 32 0 0 0 32 32h320a32 32 0 0 0 32-32V64a32 32 0 0 0-32-32m0 416H96V64h320Zm-96-96-160 .14V384l160-.14Zm32-64-192 .17V320l192-.17ZM223.15 127.9a64 64 0 1 0 64 64h-64Zm32-32v64h64a64 64 0 0 0-63.99-64Z" />',viewBox:"0 0 512 512"},fileTxtIcon:{name:"file-txt",content:'<path d="M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96zm-32-96v32H128v-32zM256 160v32H128v-32m256 64v32H128v-32zm-256 96v-32h224v32z" />',viewBox:"0 0 512 512"},fileTypescriptIcon:{name:"file-typescript",content:'<path d="M64 128h192v48h-72v208h-48V176H64zm316.6 107.6c-35-12.6-50.1-21.6-50.1-40.6 0-14.6 12.9-29.9 43.3-29.9 24.6 0 42.9 7.1 52.3 11.8l11.5-36.6c-13.6-6.5-34.4-12.3-62.8-12.3-56.8 0-92.7 30.6-92.7 71.3 0 35.6 27.6 57.6 70.9 72.1 33.1 11.4 46.4 22.4 46.4 41.2 0 20.3-17.1 33.9-47.6 33.9-24.4 0-47.9-7.4-63.3-15.8l-10.6 37.6c14.3 8.3 43.1 15.8 70.8 15.8 67.6 0 99.3-34.6 99.3-74.6 0-35.8-21.9-57.4-67.4-73.9" />',viewBox:"0 0 512 512"},fileVideoIcon:{name:"file-video",content:'<path d="M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96zM304 304.8v-.8c0-8.8-7.2-16-16-16h-10.1c24.2-3.1 42.8-24.3 41.8-49.6-1-24.8-21.2-45-46-46-27.4-1.1-49.9 20.8-49.9 48 0 24.4 18.2 44.6 41.8 47.6h-70.4c17.2-1.7 30.3-16.9 28.7-34.8-1.4-15.5-14.1-27.9-29.6-28.9-18.7-1.3-34.2 13.5-34.2 31.9 0 16.6 12.7 30.2 28.8 31.8H176c-8.8 0-16 7.2-16 16v64c0 8.8 7.2 16 16 16h111.7c8.4 0 15.6-6.3 16.3-14.6.2-3.1-.3-6.1-1.7-8.7l1.8 1.1 44.9 27.1c1.3.8 2.7 1.2 4.1 1.2 1.3 0 2.7-.3 3.9-1 2.5-1.4 4.1-4.1 4.1-7v-95.8c0-2.9-1.5-5.5-4-6.9s-5.5-1.5-8 0zM193.5 272c-.5.1-1 .1-1.5.1s-1 0-1.5-.1h-.2c-8.6-.8-15.1-8.5-14.3-17.2.6-7.9 7.2-14.2 15.1-14.6 9.2-.5 16.8 6.9 16.8 16 .1 8.1-6.1 15-14.4 15.8m82.3-.3c-.3 0-.6.1-.9.1-1 .1-2.1.2-3.1.2s-2.1 0-3.1-.2c-.3 0-.6-.1-.9-.1-15.9-2-27.9-15.7-27.9-31.7 0-17.6 14.4-32 32-32s32 14.4 32 32c-.1 16.1-12.1 29.7-28.1 31.7" />',viewBox:"0 0 512 512"},fileWordIcon:{name:"file-word",content:'<path d="M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96zm-32.4-256-6.9 32-41.6 192h-46.7l-32.8-132.5L222.9 416h-46.7l-48.6-224h47.8l24.8 139.2L233.3 192h44.5l33.1 139.2L330.1 224H311v-32z" />',viewBox:"0 0 512 512"},fileWrenchIcon:{name:"file-wrench",content:'<path d="M470.7 480 448 502.7c-12.4 12.4-32.8 12.4-45.1-.1l-93.1-93.1c-11.8 4.2-24.5 6.5-37.8 6.5-61.9 0-112-50.1-112-112 0-13.2 2.3-25.9 6.5-37.6l48.9 48.9c12.4 12.4 32.8 12.4 45.3 0l22.6-22.6c12.4-12.4 12.4-32.8 0-45.3l-48.9-48.9c11.8-4.2 24.4-6.5 37.6-6.5 61.9 0 112 50.1 112 112 0 13.2-2.3 25.9-6.5 37.6l93.2 93.1c12.4 12.5 12.4 32.9 0 45.3m-22.8-23-86.3-86.3c-6.4 8.6-14 16.2-22.6 22.6l86.4 86.3 22.6-22.5v-.1zM96 64h224v96h96v128h32V128l-96-96H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h160v-32H96z" />',viewBox:"0 0 512 512"},fileZipIcon:{name:"file-zip",content:'<path d="M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h64v32h32v32h-32v32h32v32h-32v32h32v32h-32v32h32v34.7c-18.6 6.6-32 24.4-32 45.3 0 26.5 21.5 48 48 48s48-21.5 48-48c0-20.9-13.4-38.7-32-45.3V256h32v-32h-32v-32h32v-32h-32v-32h32V96h-32V64h96v96h96zm-192-80c0 8.8-7.2 16-16 16s-16-7.2-16-16 7.2-16 16-16 16 7.2 16 16" />',viewBox:"0 0 512 512"},filesErrorIcon:{name:"files-error",content:'<path d="M64 64h224l-32-32H64c-17.7 0-32 14.3-32 32v320c0 17.7 14.3 32 32 32h64v-32H64zm208 320c-8.8 0-16 7.2-16 16s7.2 16 16 16 16-7.2 16-16-7.2-16-16-16M384 96H192c-17.7 0-32 14.3-32 32v320c0 17.7 14.3 32 32 32h256c17.7 0 32-14.3 32-32V192zm64 352H192V128h160v96h96zm-192-96h32V192h-32z" />',viewBox:"0 0 512 512"},filmIcon:{name:"film",content:'<path d="M416 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32M128 448H96v-32h32zm0-96H96v-64h32zm0-128H96v-64h32zm0-128H96V64h32zm224 352H160v-96h192zm0-128H160V192h192zm0-160H160V64h192zm64 288h-32v-32h32zm0-96h-32v-64h32zm0-128h-32v-64h32zm0-128h-32V64h32z" />',viewBox:"0 0 512 512"},filterAddExpressionIcon:{name:"filter-add-expression",content:'<path d="M480 64v32H32V64zm-192 96h192v-32H288zm0 128h192v-64H288zm0 96h192v-32H288zm0 64h192v-32H288zM96 352h64v-64h64v-64h-64v-64H96v64H32v64h64z" />',viewBox:"0 0 512 512"},filterAddGroupIcon:{name:"filter-add-group",content:'<path d="M352 352v32h-32v64h32v32h-64V352zm64 0v32h32v64h-32v32h64V352zM160 160H96v64H32v64h64v64h64v-64h64v-64h-64zm128 0h192v-32H288zM32 64v32h448V64zm256 224h192v-64H288z" />',viewBox:"0 0 512 512"},filterClearIcon:{name:"filter-clear",content:'<path d="m143.5 64 168.2 168.2L288 256v160l-64 64V256L64 96V64zm236.1 100.4L448 96V64H279.3l-64-64L192 22l298 298 22-23.3z" />',viewBox:"0 0 512 512"},filterIcon:{name:"filter",content:'<path d="M64 64v32l160 160v224l64-64V256L448 96V64z" />',viewBox:"0 0 512 512"},filterSmallIcon:{name:"filter-small",content:'<path d="M128 128h256v32l-96 96v96l-64 64V256l-96-96z" />',viewBox:"0 0 512 512"},filterSortAscSmallIcon:{name:"filter-sort-asc-small",content:'<path d="M448 128v32l-96 96v64l-32 64V256l-96-96v-32zM64 224h64v160h32V224h64l-80-96z" />',viewBox:"0 0 512 512"},filterSortDescSmallIcon:{name:"filter-sort-desc-small",content:'<path d="M448 128v32l-96 96v64l-32 64V256l-96-96v-32zM144 384l80-96h-64V128h-32v160H64z" />',viewBox:"0 0 512 512"},flashManagerIcon:{name:"flash-manager",content:'<path d="M255.9 0C114.6 0 0 114.6 0 256.1 0 397.4 114.6 512 255.9 512 397.4 512 512 397.4 512 256.1 512 114.6 397.4 0 255.9 0M384 160c-30.1.3-48.4-4.6-81.2 64H352v64h-64s-53.5 129.4-160 128c-.8-14.2 0-43.9 0-64 70.5-10.7 93.6-88.3 109.9-126.9C286.3 74.5 384 95.1 384 95.1z" />',viewBox:"0 0 512 512"},flipHorizontalIcon:{name:"flip-horizontal",content:'<path d="M448 448H288V64zm-384 0L224 64v384zm128-224-80 192h80z" />',viewBox:"0 0 512 512"},flipVerticalIcon:{name:"flip-vertical",content:'<path d="M64 288h384L64 448zm0-224v160h384zm32 128v-80l192 80z" />',viewBox:"0 0 512 512"},folderAddIcon:{name:"folder-add",content:'<path d="M96 160h288c17.7 0 32 14.3 32 32v64h-32v-64H96zm352 224h-32v-64h-32v64h-64v32h64v64h32v-64h64v-32zM64 96h114.8l32 32H256l-64-64H64c-17.7 0-32 14.3-32 32v288c0 17.7 14.3 32 32 32h192v-32H64z" />',viewBox:"0 0 512 512"},folderIcon:{name:"folder",content:'<path d="m242.8 128-32-32H96v288h320V192H128v-32h288c17.7 0 32 14.3 32 32v192c0 17.7-14.3 32-32 32H96c-17.7 0-32-14.3-32-32V96c0-17.7 14.3-32 32-32h128l64 64" />',viewBox:"0 0 512 512"},folderMoreIcon:{name:"folder-more",content:'<path d="M64 384h96v32H64c-17.7 0-32-14.3-32-32V96c0-17.7 14.3-32 32-32h128l64 64h-45.2l-32-32H64zm192-32c-17.7 0-32 14.3-32 32s14.3 32 32 32 32-14.3 32-32-14.3-32-32-32m160-64v-96c0-17.7-14.3-32-32-32H96v32h288v96zm32 64c-17.7 0-32 14.3-32 32s14.3 32 32 32 32-14.3 32-32-14.3-32-32-32m-96 0c-17.7 0-32 14.3-32 32s14.3 32 32 32 32-14.3 32-32-14.3-32-32-32" />',viewBox:"0 0 512 512"},folderOpenIcon:{name:"folder-open",content:'<path d="M425.6 160h-246c-17.6 0-37.2 14.4-43.6 32L64 384V96h114.8l32 32H256l-64-64H64c-17.7 0-32 14.3-32 32v288c0 17.7 14.3 32 32 32h268.4c17.6 0 37.2-14.4 43.6-32l70-192c6.4-17.6-2.8-32-20.4-32M346 373.1c-2 5.5-10.1 10.9-13.6 10.9H98.1L166 202.9c2-5.5 10.1-10.9 13.6-10.9h232.3z" />',viewBox:"0 0 512 512"},folderUpIcon:{name:"folder-up",content:'<path d="M96 160h288c17.7 0 32 14.3 32 32v64l-32 32v-96H96zM64 96h114.8l32 32H256l-64-64H64c-17.7 0-32 14.3-32 32v288c0 17.7 14.3 32 32 32h192l32-32H64zm336 240-80 80h64v64h32v-64h64z" />',viewBox:"0 0 512 512"},fontFamilyIcon:{name:"font-family",content:'<path d="M224 416V160h-95l-.8-64H384v64h-96v256z" />',viewBox:"0 0 512 512"},fontGrowIcon:{name:"font-grow",content:'<path d="m384 32-96 128h192zM222 96h-60L32 480h60l32.4-96h135.2l32.4 96h60zm-78 230.4 48-141.7 48 141.7z" />',viewBox:"0 0 512 512"},fontShrinkIcon:{name:"font-shrink",content:'<path d="m384 160 96-128H288zm-152 0h-48L80 480h48l25.9-80h108.2l25.9 80h48zm-62.4 192L208 233.9 246.4 352z" />',viewBox:"0 0 512 512"},fontSizeIcon:{name:"font-size",content:'<path d="M97 224 32 416h29l16.9-50H146l16.9 50h29l-65-192zm-8.9 112 23.9-70.6 23.9 70.6zM376 96h-48L224 416h48l26-80h108l26 80h48zm-62.4 192L352 169.8 390.4 288z" />',viewBox:"0 0 512 512"},foregroundColorIcon:{name:"foreground-color",content:'<path d="M299.5 96h-87.1L96 416h64l23.3-64h145.4l23.3 64h64zm-92.9 192L256 152.2 305.4 288z" />',viewBox:"0 0 512 512"},formElementIcon:{name:"form-element",content:'<path d="M416 32V0h-32v32h-32V0h-32v32h-32V0h-32v32h-32V0h-32v32h-32V0h-32v32H96V0H64v32H32v32H0v32h32v32H0v32h32v32H0v32h32v32H0v32h32v32H0v32h32v32H0v32h32v32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v-32h32v-32h-32v-32h32v-32h-32v-32h32v-32h-32v-32h32v-32h-32v-32h32v-32h-32V96h32V64h-32V32zm0 384H64V64h352zm32 64v-32h32v32zm32-448h-32V0h32zM0 448h32v32H0zM32 0v32H0V0zm160 128H96v32h96zm192 0H224v32h160zm0 64H224v32h160zm0 64H224v32h160zm0 64H224v32h160zm-192 0H96v32h96zm0-64H96v32h96zm0-64H96v32h96z" />',viewBox:"0 0 512 512"},formIcon:{name:"form",content:'<path d="M416 32V0h-32v32h-32V0h-32v32h-32V0h-32v32h-32V0h-32v32h-32V0h-32v32H96V0H64v32H32v32H0v32h32v32H0v32h32v32H0v32h32v32H0v32h32v32H0v32h32v32H0v32h32v32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v32h32v-32h32v-32h32v-32h-32v-32h32v-32h-32v-32h32v-32h-32v-32h32v-32h-32v-32h32v-32h-32V96h32V64h-32V32zm0 384H64V64h352zm32 64v-32h32v32zm32-448h-32V0h32zM0 448h32v32H0zM32 0v32H0V0z" />',viewBox:"0 0 512 512"},formatCodeBlockIcon:{name:"format-code-block",content:'<path d="M224 352v160h288V352zm102.6 105.4L304 480l-48-48 22.6-22.6L304 384l22.6 22.6-25.3 25.4zM432 480l-22.6-22.6 25.4-25.4-25.4-25.4L432 384l25.4 25.4L480 432zM192 160V32c0-17.6-14.4-32-32-32h-32c-17.6 0-32 14.4-32 32v128L0 256h288zm96 128H0v192h64V320h32v160h32V320h32v160h32V320h96z" />',viewBox:"0 0 512 512"},formulaFxIcon:{name:"formula-fx",content:'<path d="m214 183.4-24.7 110c-11.5 53.4-22.7 92.1-33.7 116.1s-23.8 41.8-38.4 53.2C102.5 474.3 85.7 480 66.7 480c-12 0-20.7-2.7-26.3-8S32 460.5 32 453.3c0-6.7 2.3-12.5 7-17.4s10.8-7.3 18.3-7.3c6.3 0 11.2 1.9 14.5 5.6 3.4 3.7 5.1 8.5 5.1 14.2 0 5.2-1 9.1-3.2 11.6-2.1 2.5-3.2 4.2-3.2 5l1 1.7q1.2 1.2 3 1.2c4.2 0 7.8-1.5 10.8-4.7 7.4-7.7 13-17 16.6-27.9 2.5-7.5 7.4-27.4 14.5-59.5l43-192.6h-29.3l7-28.7c10.5.2 18.2-1.4 23-4.7s9.8-10.6 15.2-22c15.4-33.1 31.7-60.1 48.9-74.4S260.4 32 281.5 32c13.5 0 23.3 3 29.4 9.1s9.2 13.9 9.2 23.5c0 8.5-2 15.2-6.1 20.2-4.1 5.1-9.2 7.5-15.2 7.5-5.6 0-10.3-2-13.9-6.1s-5.5-9-5.5-14.7c0-4.1 1.1-8.4 3.5-13 2.3-4.6 3.5-7.7 3.5-9.3 0-1.8-.5-3.3-1.6-4.4-1-1.1-2.4-1.7-4.1-1.7-8.3 0-16.8 5.9-25.5 17.9-14.3 19.1-25.9 52.5-34.5 93.8h30.5l-7.4 28.7zm78.7 22.7 68.9-14.1c12.5 23.3 21.3 48.9 26.5 76.9 12.9-22.7 22.7-38.6 29.3-47.6 8.8-12.2 16.1-20.1 21.8-23.8 5.8-3.7 11.9-5.5 18.3-5.5 7.2 0 12.8 2.4 16.7 7 3.9 4.7 5.8 11 5.8 19 0 7.5-2 13.6-5.8 18.4-3.9 4.7-8.7 7.1-14.5 7.1-4.2 0-9-.9-14.5-2.7-5.4-1.8-9.3-2.7-11.3-2.7-5.6 0-10.8 2.4-15.8 7-6.8 6.4-15.2 20.1-25.3 41 11.2 46.9 20.1 75.5 26.9 85.8 3.9 6.1 7.9 9.2 12.1 9.2 3.4 0 6.4-1 8.9-3 3.8-3.3 9.7-11.5 17.6-24.6l7.1 4.9c-11.6 22.2-22.9 37.9-34 46.9-8.4 7-16.7 10.6-24.9 10.6-8.4 0-15.4-2.3-21-6.7-5.6-4.5-10.6-11.7-14.9-21.8-4.4-10-9.5-26.2-15.4-48.4q-23.1 34.95-36.3 51c-8.7 10.7-16 17.7-21.8 21s-12 4.9-18.6 4.9c-6.8 0-12.3-2.4-16.3-7q-6-7.05-6-18.3c0-7.9 2.2-14.5 6.5-19.6 4.3-5.2 9.9-7.7 16.6-7.7 3.6 0 7.6 1.3 12.1 3.7 6.6 3.8 11.3 5.7 14.2 5.7 3.8 0 7.2-.9 10.3-2.8 3.9-2.4 9-7.4 15-15.3 3.7-4.8 10.5-15.1 20.4-31-12.6-55.8-22.5-89.1-29.6-100-4.5-7-10.2-10.6-17-10.6-3.6 0-7.9.6-13 1.9z" />',viewBox:"0 0 512 512"},forwardIcon:{name:"forward",content:'<path d="M0 416V96l256 160zm512-160L256 96v320z" />',viewBox:"0 0 512 512"},freeTextIcon:{name:"free-text",content:'<path d="M448 125.27c18.64-6.59 32-24.37 32-45.27 0-26.51-21.49-48-48-48-20.9 0-38.68 13.36-45.27 32H128V32H32v96h32v258.73C45.36 393.32 32 411.1 32 432c0 26.51 21.49 48 48 48 20.9 0 38.68-13.36 45.27-32H384v32h96v-96h-32zM432 64c8.82 0 16 7.18 16 16s-7.18 16-16 16-16-7.18-16-16 7.18-16 16-16M64 64h32v32H64zm16 384c-8.82 0-16-7.18-16-16s7.18-16 16-16 16 7.18 16 16-7.18 16-16 16m368 0h-32v-32h32zm-64-64v32H125.27c-4.82-13.64-15.63-24.45-29.27-29.27V128h32V96h258.73c4.82 13.64 15.63 24.45 29.27 29.27V384zm-153.6 0V179.2h-76.16l-.64-51.2h204.8v51.2h-76.8V384z" />',viewBox:"0 0 512 512"},fullscreenExitIcon:{name:"fullscreen-exit",content:'<path d="M160 32H96v96H0v64h160zM96 480h64V320H0v64h96zm416-288v-64h-96V32h-64v160zm-96 192h96v-64H352v160h64z" />',viewBox:"0 0 512 512"},fullscreenIcon:{name:"fullscreen",content:'<path d="M0 32h160v64H64v96H0zm64 288H0v160h160v-64H64zM352 32v64h96v96h64V32zm96 384h-96v64h160V320h-64z" />',viewBox:"0 0 512 512"},gapColumnIcon:{name:"gap-column",content:'<path d="M32 32v448h448V32zm416 416H64V64h384zM96 96h96v320H96zm224 0h96v320h-96z" />',viewBox:"0 0 512 512"},gapRowIcon:{name:"gap-row",content:'<path d="M480 32H32v448h448zM64 448V64h384v384zM96 96h320v96H96zm0 224h320v96H96z" />',viewBox:"0 0 512 512"},gaugeLinearIcon:{name:"gauge-linear",content:'<path d="M16 164h480v184H16zM90 58h110l-55 74zM16 380h36v74H16zm444 0h36v74h-36zm-222 0h36v74h-36zm-111 0h36v36h-36zm222 0h36v36h-36z" />',viewBox:"0 0 512 512"},gaugeRadialIcon:{name:"gauge-radial",content:'<path d="M256 16C123.5 16 16 123.5 16 256s107.5 240 240 240 240-107.5 240-240S388.5 16 256 16m0 445.7c-113.4 0-205.7-92.3-205.7-205.7S142.6 50.3 256 50.3 461.7 142.6 461.7 256 369.4 461.7 256 461.7m0-377.1c94.7 0 171.4 76.7 171.5 171.5h-68.6c0-56.8-46.2-102.9-102.9-102.9-22.2 0-42.8 7-59.6 19l37.4 37.4c6.7-3.2 14.3-5 22.2-5 28.4 0 51.4 23 51.4 51.4s-23 51.4-51.4 51.4-51.4-23-51.4-51.4c0-8 1.8-15.5 5-22.2l-37.4-37.4c-11.9 16.9-19 37.4-19 59.6H84.6c0-41.2 14.5-78.9 38.7-108.5l-12.7-12.7 24.2-24.2 12.7 12.7c29.6-24.2 67.3-38.7 108.5-38.7" />',viewBox:"0 0 512 512"},gearIcon:{name:"gear",content:'<path d="m462.7 317.9-41.5-31.4c1.8-9.9 2.8-20.1 2.8-30.5s-1-20.6-2.8-30.5l41.5-31.4c6.4-4.9 8.2-13.8 4.2-20.8L433 114.6c-4-7-12.6-9.9-20.1-6.7l-48 20.2c-15.4-13.2-33.3-23.6-52.8-30.5L305.8 46c-1-8-7.8-14-15.9-14h-67.8c-8.1 0-14.9 6-15.9 14l-6.5 51.6c-19.5 6.9-37.4 17.3-52.8 30.5l-48-20.2c-7.4-3.1-16-.2-20.1 6.7l-33.9 58.7c-4 7-2.2 15.9 4.2 20.8l41.5 31.4C89 235.4 88 245.6 88 256s1 20.6 2.8 30.5l-41.5 31.4c-6.4 4.9-8.2 13.8-4.2 20.8L79 397.4c4 7 12.6 9.9 20.1 6.7l48-20.2c15.4 13.2 33.3 23.6 52.8 30.5l6.5 51.6c1 8 7.8 14 15.9 14h67.8c8.1 0 14.9-6 15.9-14l6.5-51.6c19.5-6.9 37.4-17.3 52.8-30.5l48 20.2c7.4 3.1 16 .2 20.1-6.7l33.9-58.7c3.7-7 1.9-15.9-4.6-20.8M256 340c-46.4 0-84-37.6-84-84s37.6-84 84-84 84 37.6 84 84-37.6 84-84 84" />',viewBox:"0 0 512 512"},gearsIcon:{name:"gears",content:'<path d="m331.9 364.2-29.6-22.4c1.3-7.1 2-14.3 2-21.8 0-7.4-.7-14.7-2-21.8l29.6-22.4c4.6-3.5 5.9-9.8 3-14.8l-24.2-42c-2.9-5-9-7.1-14.3-4.8L262 228.7c-11-9.4-23.8-16.9-37.7-21.8l-4.6-36.9c-.7-5.7-5.6-10-11.3-10H160c-5.8 0-10.6 4.3-11.3 10l-4.6 36.9c-13.9 4.9-26.7 12.4-37.7 21.8l-34.3-14.5c-5.3-2.2-11.5-.2-14.3 4.8l-24.3 42c-2.9 5-1.6 11.3 3 14.8l29.6 22.4c-1.3 7.1-2 14.3-2 21.8 0 7.4.7 14.7 2 21.8l-29.6 22.4c-4.6 3.5-5.9 9.8-3 14.8l24.2 42c2.9 5 9 7.1 14.3 4.8l34.3-14.5c11 9.4 23.8 16.9 37.7 21.8l4.6 36.9c.7 5.7 5.6 10 11.3 10h48.4c5.8 0 10.6-4.3 11.3-10l4.6-36.9c13.9-4.9 26.7-12.4 37.7-21.8l34.3 14.5c5.3 2.2 11.5.2 14.3-4.8l24.2-41.9c3-5 1.8-11.4-2.8-14.9M184.2 380c-33.1 0-60-26.9-60-60s26.9-60 60-60 60 26.9 60 60-26.9 60-60 60m293.1-225.5L459.4 141c.8-4.2 1.2-8.6 1.2-13 0-4.5-.4-8.8-1.2-13l17.8-13.4c2.7-2.1 3.5-5.9 1.8-8.9l-14.5-25.2c-1.8-3-5.4-4.2-8.6-2.8l-20.6 8.7c-6.7-5.7-14.3-10.1-22.7-13.1L409.9 38c-.4-3.4-3.3-6-6.8-6h-29c-3.4 0-6.4 2.5-6.8 6l-2.7 22.2c-8.3 2.9-16 7.5-22.7 13.1l-20.6-8.7c-3.2-1.4-6.9-.1-8.6 2.8l-14.5 25.2c-1.8 3-1 6.9 1.8 8.9l17.8 13.4c-.8 4.2-1.2 8.6-1.2 13 0 4.5.4 8.8 1.2 13L300 154.5c-2.7 2.1-3.5 5.9-1.8 8.9l14.5 25.2c1.8 3 5.4 4.2 8.6 2.8l20.6-8.7c6.7 5.7 14.3 10.1 22.7 13.1l2.7 22.2c.4 3.4 3.3 6 6.8 6h29c3.4 0 6.4-2.5 6.8-6l2.7-22.2c8.3-2.9 16-7.5 22.7-13.1l20.6 8.7c3.2 1.4 6.9.1 8.6-2.8l14.5-25.2c1.8-3 1-6.9-1.7-8.9m-88.7 9.5c-19.9 0-36.1-16.2-36.1-36.1s16.2-36.1 36.1-36.1 36.1 16.2 36.1 36.1c-.1 19.9-16.1 36.1-36.1 36.1" />',viewBox:"0 0 512 512"},globeIcon:{name:"globe",content:'<path d="M256 32C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32m106.2 314.7c-34.7 10-66.7 64.2-76.4 101.3-17.9-9.4 9.8-90.2 5.4-112.4-4.3-22.1-13-14.4-22.6-27.6-17.8-31.5.9-48.3-5.6-55.9-6.5-7.7-4.9-18.3-45-29.9s-75.9-81.9-87.8-104.1c-11.9-22.1 26.6-47 81.3-52.6 10.3-1 19.7-1.5 28.4-1.5 37.8.1 61.9 9 80 17.5 22.2 10.5 20.1 39.3 8.1 39.3s-35.8-16.6-47.2 23.2-40.1 19.9-59.1 39.3 24.4 37.1 33.6 49.3 33.1-.6 52.6 3.9c32.6 28.8 66.7 41 74.3 54.8 3.3 16.6 4.4 34.9-20 55.4" />',viewBox:"0 0 512 512"},globeLinkIcon:{name:"globe-link",content:'<path d="M161.7 412.6C69.1 391.2 0 308.1 0 209 0 93.6 93.6 0 209 0s209 93.6 209 209c0 58.2-23.8 110.8-62.2 148.7-20.5-23.1-50.4-37.7-83.8-37.7-3.9 0-7.8.2-11.6.6 12-15.9 26.4-28.8 41.3-33 22.6-18.6 21.6-35.2 18.6-50.2-7-12.6-38.7-23.6-68.8-49.7-18.1-4-40.2 7.5-48.7-3.5-8.5-11.1-48.7-27.1-31.1-44.7s44.2.5 54.8-35.7C236.9 67.6 259 82.6 270 82.6c11.1 0 13.1-26.1-7.5-35.7-20.6-9.5-49.7-19.6-100.5-14.6-50.7 5-86.4 27.6-75.4 47.7 11.1 20.1 44.2 83.9 81.4 94.5s35.7 20.2 41.7 27.1c6 7-11.3 22.2 5.1 50.8 8.9 12 17 5 21 25.1 1.9 9.4-2.7 30.3-6.4 50.8-34.9 14.4-61 46-67.7 84.3M224 432c0-5.1.8-10.1 2.3-14.7C232.5 398 250.6 384 272 384h64c-1.5-1.9-3-3.8-4.6-5.6-14.6-16.2-35.8-26.4-59.4-26.4-12.2 0-23.8 2.7-34.1 7.6-4.4 2.1-8.6 4.6-12.5 7.4-16.4 11.8-28.2 29.7-32 50.4-.9 4.7-1.4 9.6-1.4 14.6 0 44.2 35.8 80 80 80 26.2 0 49.4-12.6 64-32h-64c-26.5 0-48-21.5-48-48m208-80c-26.2 0-49.4 12.6-64 32h64c26.5 0 48 21.5 48 48s-21.5 48-48 48h-64c14.6 19.4 37.8 32 64 32 44.2 0 80-35.8 80-80s-35.8-80-80-80m0 64H272c-8.8 0-16 7.2-16 16s7.2 16 16 16h160c8.8 0 16-7.2 16-16s-7.2-16-16-16" />',viewBox:"0 0 512 512"},globeOutlineIcon:{name:"globe-outline",content:'<path d="M256 32C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32M64 256c0-57 24.8-108.2 64.3-143.3.3 1.8 1 3.6 1.9 5.4 11.9 22.1 47.7 92.5 87.8 104.1s38.6 22.2 45 29.9c6.5 7.7-12.2 24.4 5.6 55.9 9.6 13.2 18.3 5.5 22.6 27.6 4.1 21-20.6 95-7.8 110.4-9 1.3-18.1 2-27.4 2-106 0-192-86-192-192m222.4 189.6c10.5-37 41.8-89.2 75.8-98.9 24.4-20.5 23.3-38.8 20.1-55.4-7.6-13.9-41.7-26-74.3-54.8-19.5-4.4-43.4 8.3-52.6-3.9s-52.6-29.9-33.6-49.3 47.7.6 59.1-39.3 35.2-23.2 47.2-23.2S342.2 92 320 81.5c-16.7-7.9-38.6-16.1-71.7-17.4 2.6-.1 5.2-.2 7.8-.2 106 0 192 86 192 192C448 351.7 378 431 286.4 445.6" />',viewBox:"0 0 512 512"},globeUnlinkIcon:{name:"globe-unlink",content:'<path d="M161.7 412.6C69.1 391.2 0 308.1 0 209 0 93.6 93.6 0 209 0s209 93.6 209 209c0 58.2-23.8 110.8-62.2 148.7-20.5-23.1-50.4-37.7-83.8-37.7-3.9 0-7.8.2-11.6.6 12-15.9 26.4-28.8 41.3-33 22.6-18.6 21.6-35.2 18.6-50.2-7-12.6-38.7-23.6-68.8-49.7-18.1-4-40.2 7.5-48.7-3.5-8.5-11.1-48.7-27.1-31.1-44.7s44.2.5 54.8-35.7C236.9 67.6 259 82.6 270 82.6s13.1-26.1-7.5-35.7c-20.6-9.5-49.7-19.6-100.5-14.6-50.7 5-86.4 27.6-75.4 47.7 11.1 20.1 44.2 83.9 81.4 94.5s35.7 20.2 41.7 27.1c6 7-11.3 22.2 5.1 50.8 8.9 12 17 5 21 25.1 1.9 9.4-2.7 30.3-6.4 50.8-34.9 14.4-61 46-67.7 84.3M224 432c0-5.1.8-10.1 2.3-14.7C232.5 398 250.6 384 272 384h64c-1.5-1.9-3-3.8-4.6-5.6-14.6-16.2-35.8-26.4-59.4-26.4-12.2 0-23.8 2.7-34.1 7.6-4.4 2.1-8.6 4.6-12.5 7.4-16.4 11.8-28.2 29.7-32 50.4-.9 4.7-1.4 9.6-1.4 14.6 0 44.2 35.8 80 80 80 26.2 0 49.4-12.6 64-32h-64c-26.5 0-48-21.5-48-48m208-80c-26.2 0-49.4 12.6-64 32h64c26.5 0 48 21.5 48 48s-21.5 48-48 48h-64c14.6 19.4 37.8 32 64 32 44.2 0 80-35.8 80-80s-35.8-80-80-80" />',viewBox:"0 0 512 512"},googleBoxIcon:{name:"google-box",content:'<path d="M212.6 236.1c5.1-5.1 8.2-10.8 9.4-17.1s1.8-11.6 1.8-15.8c0-8.1-1.2-17-3.6-26.6s-6-18.6-10.8-27-10.7-15.4-17.7-21-15.2-8.4-24.4-8.4c-6 0-11.8 1.3-17.5 4.1s-10.3 6.3-13.9 10.8c-3.9 4.8-6.5 10-7.8 15.7s-2 11.6-2 17.6c0 7.5 1.1 15.9 3.4 25.2s5.7 18 10.3 26.1 10.5 14.9 17.5 20.5c7 5.5 15.3 8.3 24.9 8.3q8.55 0 16.8-3.6c8.25-3.6 10-5.2 13.6-8.8M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32M270.9 394.1c-5.1 10.2-12.6 19.3-22.4 27.2s-22.2 14.4-37 19.4c-14.8 4.9-31.8 7.4-50.9 7.4-16.2 0-30.3-1.8-42.4-5.4s-22.2-8.4-30.3-14.4-14.1-12.8-18-20.4-5.9-15.6-5.9-24c0-8.1 2.5-17.2 7.4-27.6s14-19.4 27.2-27.2c6.8-4.2 14.3-7.6 22.2-10.1s15.8-4.6 23.6-6c7.8-1.5 15.1-2.5 22-3.1s12.9-1.1 18-1.3c-3.3-4.2-6.4-8.6-9.2-13.3s-4.3-10.4-4.3-17.3c0-3.9.4-7.1 1.3-9.7s1.9-5.2 3.1-7.9c-2.4.3-4.8.5-7.2.7s-4.8.2-7.2.2c-12 0-22.6-2-31.9-6q-13.95-6-23.4-15.9c-6.3-6.6-11.1-14.1-14.3-22.7s-4.9-17.2-4.9-25.8c0-10.5 2.4-21 7.2-31.6s12-20.1 21.6-28.5c12.8-10.5 26.4-17.2 40.6-20.2s27.5-4.5 39.7-4.6H288l-28.7 16h-27.8c2.7 1.9 5.8 4.7 9.4 8.1 3.6 3.5 7 7.6 10.3 12.6s6.1 10.7 8.5 17.3 3.6 14.1 3.6 22.5-1.1 15.7-3.1 22c-2.1 6.3-4.9 11.9-8.5 16.9s-7.6 9.4-12.1 13.5-9.2 7.9-13.9 11.5c-3 3-5.9 6.1-8.5 9.4s-4 7.5-4 12.6 1.3 9.1 4 11.9 5.2 5.3 7.6 7.4l16.2 12.6q7.2 6.3 14.1 12.6c4.6 4.2 8.7 8.7 12.1 13.5 3.5 4.8 6.2 10.1 8.3 16.2s3.2 12.9 3.2 20.7c-.1 10.2-2.6 20.5-7.8 30.8m-34.1-42.6c-3.9-4.5-9-9.1-15.3-13.9s-13.6-10.2-22-16.2c-1.8-.3-3.4-.4-4.7-.4h-5.6c-.9 0-3 .1-6.3.2s-7.2.4-11.7.9-9.3 1.2-14.3 2.3-10 2.3-14.8 3.8c-2.4.9-5.8 2.3-10.1 4.3s-8.6 4.7-12.8 8.3-7.8 8.1-11 13.5c-3.1 5.4-4.7 12.1-4.7 20.2 0 16.2 7.1 29.3 21.3 39.5s33.4 15.3 57.7 15.3c21.5 0 37.9-4.5 49.2-13.7s16.8-20.7 16.8-34.8c0-5.7-1-10.8-2.9-15.5s-4.9-9.3-8.8-13.8" />',viewBox:"0 0 512 512"},googleIcon:{name:"google",content:'<path d="M268.3 33c-16.1-1-33.4 1-52 4.9s-36.4 12.8-53.2 26.5c-12.6 11-21.9 23.4-28.3 37.3-6.3 13.9-9.4 27.7-9.4 41.5 0 11.4 2.1 22.7 6.5 33.8 4.3 11.1 10.6 21.1 18.8 29.7s18.4 15.6 30.6 20.9 26.1 7.9 41.8 7.9c3.1 0 6.2-.1 9.4-.3s6.3-.5 9.4-.9c-1.6 3.5-2.9 7-4.1 10.3s-1.8 7.6-1.8 12.6c0 9 1.9 16.5 5.6 22.6s7.7 11.9 12 17.4c-6.7.4-14.5 1-23.5 1.8s-18.6 2.1-28.8 4.1-20.5 4.6-30.9 7.9-20.1 7.7-29.1 13.2c-17.2 10.2-29.1 22-35.6 35.6S96 385.4 96 396c0 11 2.6 21.5 7.7 31.5s12.9 18.9 23.5 26.7c10.6 7.9 23.8 14.1 39.7 18.8s34.4 7 55.5 7c25.1 0 47.3-3.2 66.7-9.7s35.6-14.9 48.5-25.3 22.7-22.3 29.4-35.6 10-26.9 10-40.6c0-10.2-1.4-19.3-4.2-27.1-2.7-7.9-6.4-14.9-10.8-21.2q-6.75-9.45-15.9-17.7c-9.15-8.25-12.3-11-18.5-16.5l-21.1-16.5c-3.2-2.8-6.5-6-10-9.7s-5.3-8.9-5.3-15.6 1.8-12.2 5.3-16.5 7.2-8.4 11.2-12.4c6.2-4.7 12.4-9.7 18.2-15 5.9-5.3 11.2-11.2 15.9-17.6 4.7-6.5 8.4-13.8 11.2-22.1 2.7-8.2 4.1-17.9 4.1-28.8s-1.5-20.8-4.7-29.5c-3.1-8.6-6.8-16.2-11.2-22.7q-6.45-9.75-13.5-16.5c-7.05-6.75-12.4-11.4-12.4-11.4H352l31.7-20zm-37.1 17.8c12.2 0 22.8 3.6 32 10.9s17 16.4 23.2 27.5c6.2 11 11 22.8 14.1 35.4s4.7 24.2 4.7 34.8c0 5.5-.8 12.4-2.3 20.7s-5.7 15.7-12.4 22.4c-4.7 4.7-10.7 8.7-18 11.8-7.3 3.2-14.6 4.7-22 4.7-12.5 0-23.4-3.6-32.6-10.9S201 191.8 195 181.3q-9.15-15.9-13.5-34.2c-4.35-18.3-4.4-23.2-4.4-33.1 0-7.9.9-15.5 2.7-23S185 76.6 190 70.3c4.7-5.9 10.8-10.6 18.2-14.1 7.5-3.6 15.1-5.4 23-5.4M260 314h7.3c1.8 0 3.8.2 6.2.6 11 7.8 20.6 14.9 28.8 21.2 8.2 6.2 14.9 12.4 20 18.2 5.1 5.9 8.9 11.8 11.5 18 2.5 6 3.8 12.8 3.8 20.3 0 18.4-7.3 33.6-22 45.6-14.7 11.9-36.2 17.9-64.4 17.9-31.8 0-57-6.7-75.6-20s-27.9-30.6-27.9-51.7c0-10.6 2.1-19.4 6.2-26.5 4.1-7 8.9-12.9 14.4-17.6s11.1-8.3 16.8-10.8c5.7-2.6 10.1-4.4 13.2-5.6 6.3-2 12.7-3.6 19.4-5s12.9-2.4 18.8-3q8.85-.9 15.3-1.2c4.2-.2 7-.3 8.2-.4" />',viewBox:"0 0 512 512"},googlePlusBoxIcon:{name:"google-plus-box",content:'<path d="M212.6 236.1c5.1-5.1 8.2-10.8 9.4-17.1s1.8-11.6 1.8-15.8c0-8.1-1.2-17-3.6-26.6s-6-18.6-10.8-27-10.7-15.4-17.7-21-15.2-8.4-24.4-8.4c-6 0-11.8 1.3-17.5 4.1s-10.3 6.3-13.9 10.8c-3.9 4.8-6.5 10-7.8 15.7s-2 11.6-2 17.6c0 7.5 1.1 15.9 3.4 25.2s5.7 18 10.3 26.1 10.5 14.9 17.5 20.5c7 5.5 15.3 8.3 24.9 8.3q8.55 0 16.8-3.6c8.25-3.6 10-5.2 13.6-8.8M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32M270.9 394.1c-5.1 10.2-12.6 19.3-22.4 27.2s-22.2 14.4-37 19.4c-14.8 4.9-31.8 7.4-50.9 7.4-16.2 0-30.3-1.8-42.4-5.4s-22.2-8.4-30.3-14.4-14.1-12.8-18-20.4-5.9-15.6-5.9-24c0-8.1 2.5-17.2 7.4-27.6s14-19.4 27.2-27.2c6.8-4.2 14.3-7.6 22.2-10.1s15.8-4.6 23.6-6c7.8-1.5 15.1-2.5 22-3.1s12.9-1.1 18-1.3c-3.3-4.2-6.4-8.6-9.2-13.3s-4.3-10.4-4.3-17.3c0-3.9.4-7.1 1.3-9.7s1.9-5.2 3.1-7.9c-2.4.3-4.8.5-7.2.7s-4.8.2-7.2.2c-12 0-22.6-2-31.9-6q-13.95-6-23.4-15.9c-6.3-6.6-11.1-14.1-14.3-22.7s-4.9-17.2-4.9-25.8c0-10.5 2.4-21 7.2-31.6s12-20.1 21.6-28.5c12.8-10.5 26.4-17.2 40.6-20.2s27.5-4.5 39.7-4.6H288l-28.7 16h-27.8c2.7 1.9 5.8 4.7 9.4 8.1 3.6 3.5 7 7.6 10.3 12.6s6.1 10.7 8.5 17.3 3.6 14.1 3.6 22.5-1.1 15.7-3.1 22c-2.1 6.3-4.9 11.9-8.5 16.9s-7.6 9.4-12.1 13.5-9.2 7.9-13.9 11.5c-3 3-5.9 6.1-8.5 9.4s-4 7.5-4 12.6 1.3 9.1 4 11.9 5.2 5.3 7.6 7.4l16.2 12.6q7.2 6.3 14.1 12.6c4.6 4.2 8.7 8.7 12.1 13.5 3.5 4.8 6.2 10.1 8.3 16.2s3.2 12.9 3.2 20.7c-.1 10.2-2.6 20.5-7.8 30.8M448 192h-64v64h-32v-64h-64v-32h64V96h32v64h64zM236.8 351.5c-3.9-4.5-9-9.1-15.3-13.9s-13.6-10.2-22-16.2c-1.8-.3-3.4-.4-4.7-.4h-5.6c-.9 0-3 .1-6.3.2s-7.2.4-11.7.9-9.3 1.2-14.3 2.3-10 2.3-14.8 3.8c-2.4.9-5.8 2.3-10.1 4.3s-8.6 4.7-12.8 8.3-7.8 8.1-11 13.5c-3.1 5.4-4.7 12.1-4.7 20.2 0 16.2 7.1 29.3 21.3 39.5s33.4 15.3 57.7 15.3c21.5 0 37.9-4.5 49.2-13.7s16.8-20.7 16.8-34.8c0-5.7-1-10.8-2.9-15.5s-4.9-9.3-8.8-13.8" />',viewBox:"0 0 512 512"},googlePlusIcon:{name:"google-plus",content:'<path d="M204.3 33c-16.1-1-33.4 1-52 4.9s-36.4 12.8-53.2 26.5c-12.6 11-22 23.4-28.3 37.3s-9.4 27.7-9.4 41.5c0 11.4 2.1 22.7 6.5 33.8 4.3 11.1 10.6 21.1 18.8 29.7s18.4 15.6 30.6 20.9 26.1 7.9 41.8 7.9c3.1 0 6.2-.1 9.4-.3s6.3-.5 9.4-.9c-1.6 3.5-2.9 7-4.1 10.3s-1.8 7.6-1.8 12.6c0 9 1.9 16.5 5.6 22.6s7.7 11.9 12 17.4c-6.7.4-14.5 1-23.5 1.8s-18.6 2.1-28.8 4.1-20.5 4.6-30.9 7.9-20.1 7.7-29.1 13.2c-17.2 10.2-29.1 22-35.6 35.6S32 385.4 32 396c0 11 2.6 21.5 7.7 31.5s12.9 18.9 23.5 26.7S87 468.3 102.9 473s34.4 7 55.6 7c25.1 0 47.3-3.2 66.7-9.7s35.6-14.9 48.5-25.3 22.7-22.3 29.4-35.6 10-26.9 10-40.6c0-10.2-1.4-19.3-4.2-27.1-2.7-7.9-6.4-14.9-10.8-21.2q-6.75-9.45-15.9-17.7c-9.15-8.25-12.3-11-18.5-16.5l-21.2-16.5c-3.2-2.8-6.5-6-10-9.7s-5.3-8.9-5.3-15.6 1.8-12.2 5.3-16.5 7.2-8.4 11.2-12.4c6.2-4.7 12.4-9.7 18.2-15 5.9-5.3 11.2-11.2 15.9-17.6 4.7-6.5 8.4-13.8 11.2-22.1 2.7-8.2 4.1-17.9 4.1-28.8s-1.5-20.8-4.7-29.5c-3.1-8.6-6.8-16.2-11.2-22.7q-6.45-9.75-13.5-16.5c-7.05-6.75-12.4-11.4-12.4-11.4H288l31.7-20zm-37 17.8c12.2 0 22.8 3.6 32 10.9s17 16.4 23.2 27.5c6.2 11 11 22.8 14.1 35.4s4.7 24.2 4.7 34.8c0 5.5-.8 12.4-2.3 20.7-1.6 8.3-5.7 15.7-12.4 22.4-4.7 4.7-10.7 8.7-18 11.8-7.3 3.2-14.6 4.7-22 4.7-12.5 0-23.4-3.6-32.6-10.9s-16.9-16.3-22.9-26.8q-9.15-15.9-13.5-34.2c-4.35-18.3-4.4-23.2-4.4-33.1 0-7.9.9-15.5 2.7-23S121 76.6 126 70.3c4.7-5.9 10.8-10.6 18.2-14.1q11.25-5.4 23.1-5.4M196.1 314h7.3c1.8 0 3.8.2 6.2.6 11 7.8 20.6 14.9 28.8 21.2 8.2 6.2 14.9 12.4 20 18.2 5.1 5.9 8.9 11.8 11.5 18 2.5 6 3.8 12.8 3.8 20.3 0 18.4-7.3 33.6-22 45.6-14.7 11.9-36.2 17.9-64.4 17.9-31.8 0-57-6.7-75.6-20s-27.9-30.6-27.9-51.7c0-10.6 2.1-19.4 6.2-26.5s8.9-12.9 14.4-17.6 11.1-8.3 16.8-10.8c5.7-2.6 10.1-4.4 13.2-5.6 6.3-2 12.7-3.6 19.4-5s12.9-2.4 18.8-3q8.85-.9 15.3-1.2c4.2-.2 6.9-.3 8.2-.4M384 32v64h-64v32h64v64h32v-64h64V96h-64V32z" />',viewBox:"0 0 512 512"},graphIcon:{name:"graph",content:'<path d="M64 448h416v32H32V32h32zm128-192-96 96v64h384V160L288 320zM416 64l14.2 14.2L288 192l-96-64-96 96v64l96-96 96 64 174.5-145.4L480 128V64z" />',viewBox:"0 0 512 512"},grayscaleIcon:{name:"grayscale",content:'<path d="M32 64C14.3 64 0 78.3 0 96v320c0 17.7 14.3 32 32 32h416c17.7 0 32-14.3 32-32V96c0-17.7-14.3-32-32-32zm0 32h416v320H32zm48 32c-8.8 0-16 7.2-16 16v224c0 8.8 7.2 16 16 16s16-7.2 16-16V144c0-8.8-7.2-16-16-16m64 0c-8.8 0-16 7.2-16 16v224c0 8.8 7.2 16 16 16s16-7.2 16-16V144c0-8.8-7.2-16-16-16m64 0c-8.8 0-16 7.2-16 16v224c0 8.8 7.2 16 16 16s16-7.2 16-16V144c0-8.8-7.2-16-16-16m64 0c-8.8 0-16 7.2-16 16v224c0 8.8 7.2 16 16 16s16-7.2 16-16V144c0-8.8-7.2-16-16-16m64 0c-8.8 0-16 7.2-16 16v224c0 8.8 7.2 16 16 16s16-7.2 16-16V144c0-8.8-7.2-16-16-16m64 0c-8.8 0-16 7.2-16 16v224c0 8.8 7.2 16 16 16s16-7.2 16-16V144c0-8.8-7.2-16-16-16m0 4c6.6 0 12 5.4 12 12v224c0 6.6-5.4 12-12 12s-12-5.4-12-12V144c0-6.6 5.4-12 12-12m-64 1c6.1 0 11 4.9 11 11v224c0 6.1-4.9 11-11 11s-11-4.9-11-11V144c0-6.1 4.9-11 11-11m-64 2c5 0 9 4 9 9v224c0 5-4 9-9 9s-9-4-9-9V144c0-5 4-9 9-9m-64 1c4.4 0 8 3.6 8 8v224c0 4.4-3.6 8-8 8s-8-3.6-8-8V144c0-4.4 3.6-8 8-8m-64 4c2.2 0 4 1.8 4 4v224c0 2.2-1.8 4-4 4s-4-1.8-4-4V144c0-2.2 1.8-4 4-4" />',viewBox:"0 0 512 512"},greaterOrEqualIcon:{name:"greater-or-equal",content:'<path d="M160 318.1 286.1 192 160 65.9 193.9 32l160 160-160 160zM128 416v32h256v-32z" />',viewBox:"0 0 512 512"},gridIcon:{name:"grid",content:'<path d="M32 32h128v128H32zm160 448h128V352H192zm-160 0h128V352H32zm0-160h128V192H32zm160 0h128V192H192zM352 32v128h128V32zm0 288h128V192H352zM192 160h128V32H192zm160 320h128V352H352z" />',viewBox:"0 0 512 512"},gridLayoutIcon:{name:"grid-layout",content:'<path d="M32 32h96v96H32zm128 0v96h320V32zM32 288h96v-96H32zm128 0h320v-96H160zM32 448h96v-96H32zm128 0h320v-96H160z" />',viewBox:"0 0 512 512"},groupBoxIcon:{name:"group-box",content:'<path d="M144 81.6c-10.6-7.5-25.2-11.1-44.1-11.1-40.5 0-61.7 15-63.6 45.2h26.1c.7-16.8 12.8-25 36-25 11 0 19.2 1.6 24.4 4.8 2.6 1.6 4.6 3.3 6.2 5.1 1.5 1.9 2.5 4 3.2 6.6s1.2 5.6 1.4 9.4c.1 3.6.1 8.2.1 13.6h-12.8c-59.4 0-89.1 17.2-89.1 51.4 0 6.4 1.3 12 3.8 17.2 2.5 5.3 6 9.7 10.4 13.4 4.4 3.8 9.7 6.6 16 8.7 6.1 2.2 12.8 3.2 20 3.2 20.9 0 38.2-6.2 51.7-18.6v17.9H160v-97.8c0-22.1-5.4-36.7-16-44m-10.1 100.2c-2.3 3.3-5.1 6.2-8.4 9-3.2 2.6-6.8 4.9-10.7 6.8s-8 3.3-12.2 4.3-8.6 1.4-12.8 1.4c-9.6 0-17-2-22.5-5.9-5.5-4-8.3-9.8-8.3-17.2 0-20.7 18.9-30.9 56.9-30.9h18zM316 115.7c-2.7-9.3-6.6-17.2-11.8-23.8-5-6.4-11.4-11.5-18.7-15-7.5-3.4-16-5.2-25.5-5.2-16.4 0-30.2 6.9-41.7 20.5V32H192v192h26.2v-14.8c10.9 9.7 24.3 14.8 40 14.8 8.8 0 17-1.9 24.5-5.4 7.6-3.7 14.1-8.9 19.7-15.5 5.5-6.7 9.8-14.9 13-24.4 3-9.6 4.6-20.4 4.6-32.1 0-11.5-1.3-21.8-4-30.9m-32.6 73.6c-6.6 9.5-15.6 14.2-26.8 14.2-14.5 0-27.4-5.9-38.4-17.8v-69.1c11.9-16.6 25-24.9 39.4-24.9 11.4 0 20 4.6 26.2 13.9 6.2 9.2 9.3 22.9 9.3 41 .1 18.9-3.2 33.3-9.7 42.7M450 110c1.8 3.2 2.7 6.9 3 11.2h27c-.9-7.3-3.1-13.8-6.4-19.6s-7.6-10.5-12.7-14.2c-5.2-3.9-11.2-6.8-18-8.8-6.9-2-14.2-3-22.2-3-10.3 0-19.5 1.6-28 4.9s-15.7 8.1-21.8 14.4c-6 6.3-10.7 14.1-14 23.3s-4.9 19.7-4.9 31.5c0 11.9 1.6 22.5 4.9 31.7 3.1 9.2 7.8 17 13.9 23.2 6 6.3 13.3 11.1 21.8 14.4 8.3 3.3 17.9 5 28.2 5 8 0 15.3-1 22.2-3 6.8-2 12.8-4.9 18-8.8 5.1-3.9 9.4-8.8 12.7-14.4s5.5-12.1 6.4-19.6h-27c-.3 4.2-1.2 7.9-3 11.2-1.8 3.2-4.2 5.9-7 8.1-3 2.2-6.3 3.9-10.1 4.9-3.9 1.2-7.9 1.7-12.2 1.7-6.3 0-11.9-1.2-17-3.5-5.2-2.3-9.7-5.8-13.4-10.4-3.7-4.5-6.6-10.2-8.5-17-2.1-6.8-3.1-14.7-3.1-23.6 0-9.1 1-17.1 3.1-23.9 2.1-6.9 5.1-12.5 8.8-17.1 3.7-4.5 8-7.8 13.3-10.1 5.1-2.3 10.7-3.5 16.8-3.5 4.3 0 8.3.6 12.2 1.7 3.9 1.2 7.2 2.7 10.1 4.9 2.8 2.4 5.2 5.1 6.9 8.4M128 256h256v32H128zm0 64h256v32H128zm0 64h256v32H128zm256 32H128v-32h256zm0-128H128v-32h256zm0 64H128v-32h256zm32-96h32v192c0 17.7-14.3 32-32 32H96c-17.7 0-32-14.3-32-32V256h32v192h320z" />',viewBox:"0 0 512 512"},groupCollectionIcon:{name:"group-collection",content:'<path d="M448 352H160v-32h288zm0 32H160v32h288zm0-288H160v32h288zm0 64H160v32h288zM64 192V96h64l32-32H32v160h128l-32-32zm0 224v-96h64l32-32H32v160h128l-32-32z" />',viewBox:"0 0 512 512"},groupFooterSectionIcon:{name:"group-footer-section",content:'<path d="m128 448 32 32H32V32h128l-32 32H64v384zm320-160H128v96h320zm0-160H128v32h320zm0 64H128v32h320z" />',viewBox:"0 0 512 512"},groupHeaderSectionIcon:{name:"group-header-section",content:'<path d="m128 448 32 32H32V32h128l-32 32H64v384zm320-320H128v96h320zm0 160H128v32h320zm0 64H128v32h320z" />',viewBox:"0 0 512 512"},groupIcon:{name:"group",content:'<path d="M32 256h192v192H32zm0-32h192V32H32zm224 224h192V256H256zm0-416v192h192V32z" />',viewBox:"0 0 512 512"},groupSectionIcon:{name:"group-section",content:'<path d="m128 416 32 32H32V32h128l-32 32H64v352zm320-288H128v32h320zm0 192H128v32h320zm0-96H128v32h320z" />',viewBox:"0 0 512 512"},h1Icon:{name:"h1",content:'<path d="M128 288h96v-57q0-16.8-2.1-22.2c-1.1-2.7-3.3-5-6.8-7-4.6-2.6-10.1-3.9-15.3-3.9H192v-6h96v6h-7.7c-5.1 0-10 1.2-14.5 3.7-3.4 1.7-5.7 4.3-7 7.8-1.2 3.5-1.8 10.7-1.8 28.3V384c0 4.3.7 11.6 2.1 15.2 1.1 2.7 3.2 5 6.6 7q7.05 3.9 14.7 3.9h7.7v6h-96v-6h7.7c9 0 16.2-2.6 20.3-7.9 2.7-3.5 4.1-11.8 4.1-24.9V304h-96v73.1c0 11.1.7 18.4 2.1 22 1.1 2.7 3.4 5 6.8 7 4.7 2.6 9.6 3.9 14.8 3.9h8.3v6H64v-6h7.8c9.1 0 16.2-2.6 20.3-7.9 2.6-3.5 3.9-11.8 3.9-18.1V237.9c0-18.1-.7-25.5-2.1-29-1.1-2.7-3.3-5-6.6-7-4.8-2.6-10.3-3.9-15.5-3.9H64v-6h96v6h-8c-5.3 0-10.2 1.2-14.9 3.7-3.4 1.7-5.7 4.3-7.1 7.8-1.3 3.5-2 10.7-2 21.4zm192-69.9 63-26.1h1v185.3c0 12.3.5 20 1.5 23s3.2 5.3 6.4 7 14.1 2.5 24.1 2.8v6h-96v-6c10.4-.2 20.9-1.1 23.9-2.7s5.1-3.7 6.3-6.3q1.8-3.9 1.8-23.7V258.8c0-16-.5-26.2-1.6-30.8-.8-3.5-2.1-6-4.1-7.6q-3-2.4-7.2-2.4c-4 0-9.5 1.7-16.7 5zM512 96H0v32h512z" />',viewBox:"0 0 512 512"},h2Icon:{name:"h2",content:'<path d="M128 288h96v-57q0-16.8-2.1-22.2c-1.1-2.7-3.3-5-6.8-7-4.6-2.6-10.1-3.9-15.3-3.9H192v-6h96v6h-7.7c-5.1 0-10 1.2-14.5 3.7-3.4 1.7-5.7 4.3-7 7.8-1.2 3.5-1.8 10.7-1.8 28.3V384c0 4.3.7 11.6 2.1 15.2 1.1 2.7 3.2 5 6.6 7q7.05 3.9 14.7 3.9h7.7v6h-96v-6h7.7c9 0 16.2-2.6 20.3-7.9 2.7-3.5 4.1-11.8 4.1-24.9V304h-96v73.1c0 11.1.7 18.4 2.1 22 1.1 2.7 3.4 5 6.8 7 4.7 2.6 9.6 3.9 14.8 3.9h8.3v6H64v-6h7.8c9.1 0 16.2-2.6 20.3-7.9 2.6-3.5 3.9-11.8 3.9-18.1V237.9c0-18.1-.7-25.5-2.1-29-1.1-2.7-3.3-5-6.6-7-4.8-2.6-10.3-3.9-15.5-3.9H64v-6h96v6h-8c-5.3 0-10.2 1.2-14.9 3.7-3.4 1.7-5.7 4.3-7.1 7.8-1.3 3.5-2 10.7-2 21.4zm336 86-15.3 42H320v-5.5c38.2-34.9 65.1-63.3 80.7-85.4q23.4-33.15 23.4-60.6c0-14-4.3-25.4-12.8-34.4-8.6-9-18.8-13.5-30.7-13.5-10.8 0-20.5 3.2-29.1 9.5s-15 15.6-19.1 27.8h-6c2.7-20 9.7-35.4 20.9-46.1s25.2-16.1 42-16.1c17.9 0 32.8 5.7 44.7 17.2 12 11.5 17.9 25 17.9 40.6 0 11.1-2.6 22.3-7.8 33.4-8 17.5-21 36.1-39 55.7-27 29.4-43.8 47.2-50.5 53.3h56.9c11.8 0 20-.4 24.8-1.3 4.7-.9 9-2.6 12.8-5.3s7.1-6.5 10-11.4zm48-278H0v32h512z" />',viewBox:"0 0 512 512"},h3Icon:{name:"h3",content:'<path d="M128 288h96v-57q0-16.8-2.1-22.2c-1.1-2.7-3.3-5-6.8-7-4.6-2.6-10.1-3.9-15.3-3.9H192v-6h96v6h-7.7c-5.1 0-10 1.2-14.5 3.7-3.4 1.7-5.7 4.3-7 7.8-1.2 3.5-1.8 10.7-1.8 28.3V384c0 4.3.7 11.6 2.1 15.2 1.1 2.7 3.2 5 6.6 7q7.05 3.9 14.7 3.9h7.7v6h-96v-6h7.7c9 0 16.2-2.6 20.3-7.9 2.7-3.5 4.1-11.8 4.1-24.9V304h-96v73.1c0 11.1.7 18.4 2.1 22 1.1 2.7 3.4 5 6.8 7 4.7 2.6 9.6 3.9 14.8 3.9h8.3v6H64v-6h7.8c9.1 0 16.2-2.6 20.3-7.9 2.6-3.5 3.9-11.8 3.9-18.1V237.9c0-18.1-.7-25.5-2.1-29-1.1-2.7-3.3-5-6.6-7-4.8-2.6-10.3-3.9-15.5-3.9H64v-6h96v6h-8c-5.3 0-10.2 1.2-14.9 3.7-3.4 1.7-5.7 4.3-7.1 7.8-1.3 3.5-2 10.7-2 21.4zm195.6-50.6q9.6-21.75 24.3-33.6c9.8-7.9 22-11.9 36.6-11.9 18 0 31.9 5.6 41.5 16.9 7.3 8.4 11 17.3 11 26.9 0 15.7-10.3 31.9-30.9 48.7 13.8 5.2 24.3 12.6 31.4 22.3s10.6 21 10.6 34c0 18.7-6.2 34.8-18.6 48.5q-24.3 26.7-70.2 26.7c-15.2 0-25.5-1.8-31-5.4s-8.2-7.5-8.2-11.6q0-4.65 3.9-8.1c2.6-2.3 5.7-3.5 9.4-3.5 2.8 0 5.6.4 8.5 1.3 1.9.5 6.1 2.5 12.8 5.8q9.9 4.95 13.8 6c4.1 1.2 8.5 1.8 13.1 1.8 11.3 0 21.1-4.2 29.5-12.6s12.5-18.3 12.5-29.8c0-8.4-1.9-16.5-5.8-24.5-2.9-5.9-6-10.4-9.5-13.5-4.8-4.2-11.3-8.1-19.6-11.5s-16.8-5.2-25.4-5.2H358v-4.8c8.7-1.1 17.5-4.1 26.3-9.1s15.2-11 19.2-18 6-14.7 6-23.1c0-10.9-3.6-19.8-10.7-26.5s-16-10.1-26.6-10.1c-17.2 0-31.5 8.8-43 26.4zM512 96H0v32h512z" />',viewBox:"0 0 512 512"},h4Icon:{name:"h4",content:'<path d="M128 288h96v-57q0-16.8-2.1-22.2c-1.1-2.7-3.3-5-6.8-7-4.6-2.6-10.1-3.9-15.3-3.9H192v-6h96v6h-7.7c-5.1 0-10 1.2-14.5 3.7-3.4 1.7-5.7 4.3-7 7.8-1.2 3.5-1.8 10.7-1.8 28.3V384c0 4.3.7 11.6 2.1 15.2 1.1 2.7 3.2 5 6.6 7q7.05 3.9 14.7 3.9h7.7v6h-96v-6h7.7c9 0 16.2-2.6 20.3-7.9 2.7-3.5 4.1-11.8 4.1-24.9V304h-96v73.1c0 11.1.7 18.4 2.1 22 1.1 2.7 3.4 5 6.8 7 4.7 2.6 9.6 3.9 14.8 3.9h8.3v6H64v-6h7.8c9.1 0 16.2-2.6 20.3-7.9 2.6-3.5 3.9-11.8 3.9-18.1V237.9c0-18.1-.7-25.5-2.1-29-1.1-2.7-3.3-5-6.6-7-4.8-2.6-10.3-3.9-15.5-3.9H64v-6h96v6h-8c-5.3 0-10.2 1.2-14.9 3.7-3.4 1.7-5.7 4.3-7.1 7.8-1.3 3.5-2 10.7-2 21.4zm341 47v23h-29v58h-27v-58h-93v-20.7L422.1 192H440v143zm-56 0V226.1L336 335zm99-239H0v32h512z" />',viewBox:"0 0 512 512"},h5Icon:{name:"h5",content:'<path d="M128 288h96v-57q0-16.8-2.1-22.2c-1.1-2.7-3.3-5-6.8-7-4.6-2.6-10.1-3.9-15.3-3.9H192v-6h96v6h-7.7c-5.1 0-10 1.2-14.5 3.7-3.4 1.7-5.7 4.3-7 7.8-1.2 3.5-1.8 10.7-1.8 28.3V384c0 4.3.7 11.6 2.1 15.2 1.1 2.7 3.2 5 6.6 7q7.05 3.9 14.7 3.9h7.7v6h-96v-6h7.7c9 0 16.2-2.6 20.3-7.9 2.7-3.5 4.1-11.8 4.1-24.9V304h-96v73.1c0 11.1.7 18.4 2.1 22 1.1 2.7 3.4 5 6.8 7 4.7 2.6 9.6 3.9 14.8 3.9h8.3v6H64v-6h7.8c9.1 0 16.2-2.6 20.3-7.9 2.6-3.5 3.9-11.8 3.9-18.1V237.9c0-18.1-.7-25.5-2.1-29-1.1-2.7-3.3-5-6.6-7-4.8-2.6-10.3-3.9-15.5-3.9H64v-6h96v6h-8c-5.3 0-10.2 1.2-14.9 3.7-3.4 1.7-5.7 4.3-7.1 7.8-1.3 3.5-2 10.7-2 21.4zm320-96-12.6 28h-66L355 249.1c28.6 4.2 51.2 14.9 68 32 14.3 14.7 21.5 32 21.5 51.9 0 11.6-2.3 22.3-7 32.1s-10.6 18.2-17.7 25.2c-7.1 6.9-15 12.5-23.8 16.7-12.4 6-25.1 8.9-38.2 8.9-13.2 0-22.7-2.2-28.7-6.7s-9-9.4-9-14.9c0-3 1.2-5.7 3.7-8s5.6-3.5 9.4-3.5c2.8 0 5.3.4 7.4 1.3s5.7 3.1 10.8 6.7q12.15 8.4 24.6 8.4 18.9 0 33.3-14.4c14.4-14.4 14.3-21.2 14.3-35 0-13.3-4.3-25.7-12.8-37.3-8.5-11.5-20.3-20.4-35.3-26.7-11.8-4.9-27.8-7.7-48.1-8.4l42.1-85.5H448zm64-96H0v32h512z" />',viewBox:"0 0 512 512"},h6Icon:{name:"h6",content:'<path d="M128 288h96v-57q0-16.8-2.1-22.2c-1.1-2.7-3.3-5-6.8-7-4.6-2.6-10.1-3.9-15.3-3.9H192v-6h96v6h-7.7c-5.1 0-10 1.2-14.5 3.7-3.4 1.7-5.7 4.3-7 7.8-1.2 3.5-1.8 10.7-1.8 28.3V384c0 4.3.7 11.6 2.1 15.2 1.1 2.7 3.2 5 6.6 7q7.05 3.9 14.7 3.9h7.7v6h-96v-6h7.7c9 0 16.2-2.6 20.3-7.9 2.7-3.5 4.1-11.8 4.1-24.9V304h-96v73.1c0 11.1.7 18.4 2.1 22 1.1 2.7 3.4 5 6.8 7 4.7 2.6 9.6 3.9 14.8 3.9h8.3v6H64v-6h7.8c9.1 0 16.2-2.6 20.3-7.9 2.6-3.5 3.9-11.8 3.9-18.1V237.9c0-18.1-.7-25.5-2.1-29-1.1-2.7-3.3-5-6.6-7-4.8-2.6-10.3-3.9-15.5-3.9H64v-6h96v6h-8c-5.3 0-10.2 1.2-14.9 3.7-3.4 1.7-5.7 4.3-7.1 7.8-1.3 3.5-2 10.7-2 21.4zm316-96v5.9c-13.1 1.4-23.9 4.2-32.2 8.4s-16.5 10.6-24.6 19.2-14.8 18.2-20.2 28.7c-5.3 10.6-9.8 23.1-13.4 37.6 14.3-10.5 28.7-15.8 43.2-15.8 13.8 0 25.8 5.9 36 17.8S448 321 448 339.6c0 18-5.1 34.5-15.4 49.3-12.3 18-28.7 27-49 27-13.8 0-25.6-4.9-35.2-14.6-18.9-19-28.4-43.6-28.4-73.8 0-19.3 3.6-37.7 10.9-55s17.6-32.8 31.1-46.3 26.4-22.5 38.8-27.2 23.8-7 34.5-7zm-92.9 111.4c-1.8 14.3-2.7 25.9-2.7 34.7 0 10.2 1.8 21.2 5.3 33.2 3.5 11.9 8.8 21.4 15.8 28.4 5.1 5 11.3 7.5 18.5 7.5 8.7 0 16.4-4.3 23.2-13q10.2-13.05 10.2-37.2 0-27.15-10.2-47.1C401 289.95 394.8 290 382.4 290c-3.8 0-7.8.8-12.2 2.5-4.3 1.6-10.7 5.2-19.1 10.9M512 96H0v32h512z" />',viewBox:"0 0 512 512"},handIcon:{name:"hand",content:'<path d="M442.5 130.7c-15.5-6.7-33.7-.2-41.4 15.1-8.2 21.3-23.3 79.9-25.8 87.6-2.1 6.5-5 12-11.3 9.7-4.7-1.7-3.5-7.2-2.4-12.6l2.7-17 18.1-112.4c2.8-17.4-9-33.8-26.5-36.6-17.4-2.8-33.8 9-36.6 26.5L304 197.9s-2.1 14.1-3 18.7c-1 5.2-1.4 12.3-7.7 11.9-5-.3-5.3-3.8-5.3-7.3V64c0-17.6-14.2-31.9-31.8-32h.1-.3c-17.7 0-32 14.3-32 32v.4c0 1.1.9 140.6.6 149.7-.2 5.4-.7 9.5-6.8 10.3-7.8 1.1-8.6-8-8.6-8l-3.1-20.9v.7L190 90.8v.1c-2.6-17.5-18.9-29.5-36.2-26.9-17.5 2.6-29.5 18.9-26.9 36.2 0 .1 0 .2.1.3l24.8 165.3 2.4 15.9c.5 3.2-.7 6.6-3.3 8.6l-.1.1c-4.1 3.1-10 2.5-13.5-1.4l-12.2-13.2-37.3-41-.1-.1c-11.9-13-32.1-14-45.3-2.1-13 11.9-14 32.1-2.1 45.2l55.7 61s34.1 49 62.5 88.4c28.3 39.3 72.3 52.4 129.5 52.4s113.9-21.8 126.9-95.4c13.7-78.5 6.5-107.9 23.7-150.4 11.6-28.9 15.1-45.8 21.1-63.2 5.4-15.6-1.9-33.3-17.2-39.9" />',viewBox:"0 0 512 512"},handleDragIcon:{name:"handle-drag",content:'<path d="M160 64h64v384h-64zm96 0v384h64V64z" />',viewBox:"0 0 512 512"},handleResizeAltIcon:{name:"handle-resize-alt",content:'<path d="M480 224v256H224v-64h192V224z" />',viewBox:"0 0 512 512"},handleResizeIcon:{name:"handle-resize",content:'<path d="m379.5 475.5-22.6-22.6 96-96 22.6 22.6zm79.7-208.2-22.6-22.6-191.9 191.9 22.6 22.6z" />',viewBox:"0 0 512 512"},hdIcon:{name:"hd",content:'<path d="M480 64H32C14.4 64 0 78.4 0 96v320c0 17.6 14.4 32 32 32h448c17.6 0 32-14.4 32-32V96c0-17.6-14.4-32-32-32M256 384h-64v-96h-64v96H64V128h64v96h64v-96h64zm210.3-68.9c-5.1 16.2-11.8 29.4-19.8 39.1-8.2 9.8-18.2 17.4-29.8 22.4-11.5 4.9-26.3 7.4-43.9 7.4H288V128h82.6c20.3 0 35.4 2.2 46.1 6.8s20.6 12.2 29.5 22.8c8.7 10.5 15.7 24.1 20.6 40.6 4.8 16.2 7.3 36.5 7.3 60.3-.1 21.5-2.7 40.6-7.8 56.6m-54.2-94.2c2.6 8.5 3.9 20.5 3.9 35.6 0 14.5-1.3 26.3-3.9 35.1-2.5 8.4-5.5 14.4-8.9 18-3.3 3.5-7.5 6-12.8 7.7-3.8 1.2-11.8 2.7-28.3 2.7H336V192h12.9c21.4 0 30.6.9 34.5 1.7 6.9 1.4 12.6 4.1 17.5 8.4 4.9 4.5 8.7 10.8 11.2 18.8" />',viewBox:"0 0 512 512"},heartIcon:{name:"heart",content:'<path d="m447.2 256.8-32.8 32.8L256 448 97.6 289.6l-32.8-32.8c-43.7-43.7-43.7-116.3 0-160s114.7-43.7 158.4 0l32.8 32.8 32.8-32.8c43.7-43.7 114.7-43.7 158.4 0s43.7 116.3 0 160" />',viewBox:"0 0 512 512"},heartOutlineIcon:{name:"heart-outline",content:'<path d="M447.2 96.8c-43.7-43.7-114.7-43.7-158.4 0L256 129.6l-32.8-32.8c-43.7-43.7-114.7-43.7-158.4 0s-43.7 116.3 0 160l32.8 32.8L256 448l158.4-158.4 32.8-32.8c43.7-43.7 43.7-116.3 0-160m-22.6 137.4L256 402.7 87.4 234.2C72.3 219.1 64 198.7 64 176.8s8.3-42.3 23.4-57.4S122.6 96 144 96s41.5 8.3 56.6 23.4l55.4 55.4 55.4-55.4C326.5 104.3 346.6 96 368 96s41.5 8.3 56.6 23.4 23.4 35.5 23.4 57.4-8.3 42.3-23.4 57.4" />',viewBox:"0 0 512 512"},highlightFreeIcon:{name:"highlight-free",content:'<path d="M446.57 120.72 368.1 42.41c-11.99-11.97-31.22-12.61-43.99-1.48l-1.61 1.41-180.35 151.77-18.44 15.51a28.8 28.8 0 0 0-5.27 5.81q-.105.135-.18.27c-6.94 10.85-5.94 25.32 3.78 35.03l2.12 2.12-.05.12-14 33.94-25.55 61.94-48.8 48.7c-4.36 4.35-4.74 9.05-2.12 13.42 2.12 3.52 7.97 6.04 11.43 6.04 20.72-.03 73.7-.42 84.75-.4l11.31-11.29 49.49-18.49 45.89-20.67a28.66 28.66 0 0 0 20.25 8.35c5.23 0 10.45-1.42 15.03-4.24 1.1-.66 2.16-1.41 3.17-2.25l.02-.02a28 28 0 0 0 3.7-3.63l167.93-198.14 1.44-1.64c11.13-12.75 10.48-31.91-1.49-43.87zM84.56 394.02l22.63-22.59 11.32 11.29c-17.68 6.36-23.34 7.77-33.96 11.3zm92.62-31.17-23.06 11.9-35.01-37.93 27-63.88 68.01 70.87-36.95 19.05zm76.8-25.19L150.46 234.81l194.9-169.67 78.45 78.3L254 337.66zM480 385.16v31.75c-1.91.44-2.99.92-4.85 1.48-6.28 2.34-12.11 5.31-17.68 8.61-5.25 3.33-10.34 6.83-15.56 10.19-7.23 4.66-14.6 9.2-22.1 13.6-11.75 6.9-23.55 13.65-37.68 17.12-6.06 1.49-12.66 2.33-19.09 2.33q-1.86 0-3.69-.09c-8.14-.43-16.39-1.72-24.32-3.25-25.93-4.98-50.44-14.43-76.87-17.73-5.03-.45-10.08-.67-15.13-.67-4.75 0-9.5.2-14.23.61-12.15 1.66-23.65 5.29-34.98 9.1-10.54 3.55-21.08 7.01-32.02 9.73-21.25 5.27-43.04 7.31-65.14 8.81C75.2 478.21 32 481 32 481v-31.95s30.06-1.9 44.95-2.91c13.71-.93 27.5-1.6 41.17-2.95 19.86-2.37 39.02-7.11 57.55-13.26 12.49-4.26 25.07-8.72 38.39-11.01 9.37-1.61 18.84-2.34 28.3-2.34 17.38 0 34.75 2.48 51.46 6.57 21.2 5.2 41.96 12.05 63.93 14.92 1.62.12 3.23.18 4.85.18 1.2 0 2.4-.04 3.6-.11 2.83-.44 5.6-1.08 8.3-1.87 5.62-2.15 10.76-4.9 15.87-7.76 5.79-3.24 11.48-6.59 17.09-10.02 10.09-6.34 19.75-13.11 30.06-19.23 10.3-6.1 21.91-10.94 34.36-13.55 2.04-.43 3.9-.71 5.76-.71.78 0 1.56.05 2.36.16" />',viewBox:"0 0 512 512"},highlightIcon:{name:"highlight",content:'<path d="M271.66 369.51c1.06-.49 2.11-1.22 3.17-2.25-1.01.84-2.07 1.59-3.17 2.25M480 448v32H32v-32zm-33.43-328.28L368.1 41.41c-11.99-11.97-31.22-12.61-43.99-1.48l-1.61 1.41-180.35 151.77-18.44 15.51a28.8 28.8 0 0 0-5.27 5.81q-.105.135-.18.27c-6.94 10.85-5.94 25.32 3.78 35.03l2.12 2.12-.05.12-14 33.94-25.55 61.94-48.8 48.7c-4.36 4.35-4.74 9.05-2.12 13.42 2.12 3.52 7.97 6.04 11.43 6.04 20.72-.03 73.7-.42 84.75-.4l11.31-11.29 49.49-18.49 45.89-20.67a28.66 28.66 0 0 0 20.25 8.35c5.23 0 10.45-1.42 15.03-4.24 1.1-.66 2.16-1.41 3.17-2.25l.02-.02a28 28 0 0 0 3.7-3.63l167.93-198.14 1.44-1.64c11.13-12.75 10.48-31.91-1.49-43.87zM84.56 393.02l22.63-22.59 11.32 11.29c-17.68 6.36-23.34 7.77-33.96 11.3zm92.62-31.17-23.06 11.9-35.01-37.93 27-63.88 68.01 70.87-36.95 19.05zm76.8-25.19L150.46 233.81l194.9-169.67 78.45 78.3L254 336.66z" />',viewBox:"0 0 512 512"},homeIcon:{name:"home",content:'<path d="M480 256c0 17.7-14.3 32-32 32-9.1 0-17.4-3.8-23.2-10l-8.8-8.7V416c0 17.7-14.3 32-32 32h-64c-17.7 0-32-14.3-32-32v-96h-64v96c0 17.7-14.3 32-32 32h-64c-17.7 0-32-14.3-32-32V268.6l-8.3 8.9C81.8 284 73.4 288 64 288c-17.7 0-32-14.3-32-32 0-8.5 3.3-16.1 8.6-21.9l.2-.2 1-1 191-191.3 1-1c5.8-5.5 13.6-8.9 22.2-8.9 9.1 0 17.3 3.8 23.1 9.9L470.3 233l.7.7.3.3c5.4 5.8 8.7 13.5 8.7 22" />',viewBox:"0 0 512 512"},horizontalRuleIcon:{name:"horizontal-rule",content:'<path d="M320 96H32V64h288zm96 32H32v32h384zm64 96H32v64h448zM320 352H32v32h288zm96 64H32v32h384z" />',viewBox:"0 0 512 512"},html5Icon:{name:"html5",content:'<path d="m64 32 30.4 384 161.3 64 161.7-64L448 32zm68 83h247.7l-1.2 13.2-2.2 24.8-1 11H186.1l4.5 51h180.1l-1.2 13.3-11.7 129.9-.7 8.4-101.3 37-101.2-37-6.9-77.6h49l3.5 39.7 55.5 24 55.6-24.1 5.8-64.6h-172L133 128.2z" />',viewBox:"0 0 512 512"},hyperlinkOpenIcon:{name:"hyperlink-open",content:'<path d="M32 480h448V256h-32v192H64V64h192V32H32zM320 32l56.9 56.9.5.5L224 242.7l45.3 45.3 153.3-153.4L480 192V32z" />',viewBox:"0 0 512 512"},hyperlinkOpenSmIcon:{name:"hyperlink-open-sm",content:'<path d="M96 416h320v-96h-32v64H128V128h64V96H96zM256 96h160v160l-57.4-57.4L237.3 320 192 274.7l121.4-121.4-.5-.5z" />',viewBox:"0 0 512 512"},imageAbsolutePositionIcon:{name:"image-absolute-position",content:'<path d="M416 240c0 26.5-21.5 48-48 48s-48-21.5-48-48 21.5-48 48-48 48 21.5 48 48m96-80v320c0 17.7-14.3 32-32 32H160c-17.7 0-32-14.3-32-32V160c0-17.7 14.3-32 32-32h320c17.7 0 32 14.3 32 32m-32 26.7c0-14.7-11.9-26.7-26.7-26.7H186.7c-14.7 0-26.7 11.9-26.7 26.7V384l96-96 96 96 64-64 64 64zM32 0H0v512h32v-64h32v-32H32v-64h32v-32H32v-64h32v-32H32v-64h32v-32H32V32h96v32h32V32h64v32h32V32h64v32h32V32h64v32h32V32h64V0z" />',viewBox:"0 0 512 512"},imageAddIcon:{name:"image-add",content:'<path d="M272 160c26.5 0 48 21.5 48 48s-21.5 48-48 48-48-21.5-48-48 21.5-48 48-48m80 112-16 16-64 64-128-128L32 336V96.1l.1-.1h383.8l.1.1-.1 191.9H448V96c0-17.6-14.4-32-32-32H32C14.4 64 0 78.4 0 96v320c0 17.6 14.4 32 32 32h256v-64h64zm128 144h-32v-64h-32v64h-64v32h64v64h32v-64h64v-32z" />',viewBox:"0 0 512 512"},imageEditIcon:{name:"image-edit",content:'<path d="M304 160c26.5 0 48 21.5 48 48s-21.5 48-48 48-48-21.5-48-48 21.5-48 48-48m-32.6 159.4L176 224 64 336V96.1l.1-.1h383.8l.1.1V160h32V96c0-17.6-14.4-32-32-32H64c-17.6 0-32 14.4-32 32v320c0 17.6 14.4 32 32 32h128v-47.5zm189-7.9L290.7 480H224v-66.7l168.5-169.7zm-45.3 0-22.6-22.6-135.8 135.8 22.6 22.6zM447.9 448c17.7 0 32.1-14.4 32.1-32v-78.9L369.1 448zm54.8-224L480 201.3c-12.4-12.4-32.8-12.4-45.3 0L412.2 224l67.9 67.9 22.6-22.6c12.4-12.5 12.4-32.9 0-45.3" />',viewBox:"0 0 512 512"},imageExportIcon:{name:"image-export",content:'<path d="M384 384v-79.9l-32-32-80 80-128-128-112 112v-240l.1-.1h383.8l.1.1-.1 223.9H448V96c0-17.6-14.4-32-32-32H32C14.4 64 0 78.4 0 96v320c0 17.6 14.4 32 32 32h256v-64zM272 160c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48m48 288h96v64l96-80-96-80v64h-96z" />',viewBox:"0 0 512 512"},imageIcon:{name:"image",content:'<path d="M304 160c26.5 0 48 21.5 48 48s-21.5 48-48 48-48-21.5-48-48 21.5-48 48-48m144-96H64c-17.6 0-32 14.4-32 32v320c0 17.6 14.4 32 32 32h384c17.6 0 32-14.4 32-32V96c0-17.6-14.4-32-32-32m-.1 272-64-64-80 80L176 224 64 336V96.1l.1-.1h383.8l.1.1z" />',viewBox:"0 0 512 512"},imageMapEditorIcon:{name:"image-map-editor",content:'<path d="M448 64H64c-17.6 0-32 14.4-32 32v320c0 17.6 14.4 32 32 32h384c17.6 0 32-14.4 32-32V96c0-17.6-14.4-32-32-32M96 384H64v-32h32zm96 0h-64v-32h64zm96 0h-64v-32h64zm96 0h-64v-32h64zm64 0h-32v-32h32zm-.1-48-64-64-80 80L176 224 64 336V192h32v-32H64V96.1l.1-.1H128v32h32V96h287.9l.1.1zM352 208c0 26.5-21.5 48-48 48s-48-21.5-48-48 21.5-48 48-48 48 21.5 48 48m-224-48h32v32h-32z" />',viewBox:"0 0 512 512"},imageResizeIcon:{name:"image-resize",content:'<path d="M427.3 404.7 352 329.4V32H32v320h297.4l75.3 75.3L352 480h128V352zM64 320V64h256v233.4L203.3 180.7 256 128H128v128l52.7-52.7L297.4 320z" />',viewBox:"0 0 512 512"},imagesIcon:{name:"images",content:'<path d="M256 288c0 17.7-14.3 32-32 32s-32-14.3-32-32 14.3-32 32-32 32 14.3 32 32m96-64v192c0 17.7-14.3 32-32 32H64c-17.7 0-32-14.3-32-32V224c0-17.7 14.3-32 32-32h256c17.7 0 32 14.3 32 32m-31.8 0q-.15-.15 0 0l-256.1-.1-.1.1v149.9l74.6-70 85.3 80 53.3-50 42.7 40zm63.8-96H128c-17.7 0-32 14.3-32 32h288v224c17.7 0 32-14.3 32-32V160c0-17.7-14.3-32-32-32m64-64H192c-17.7 0-32 14.3-32 32h288v224c17.7 0 32-14.3 32-32V96c0-17.7-14.3-32-32-32" />',viewBox:"0 0 512 512"},importIcon:{name:"import",content:'<path d="M96 480c-17.7 0-32-14.3-32-31.9V192c0-17.7 14.3-32 32-32h96.3v30.9H96.4V448h319.1V190.9h-95.9V160H416c17.7 0 32 14.3 32 31.9V448c0 17.7-14.3 32-31.9 32zm159.5-162 96.5-94h-64.5V32h-64v192H159z" />',viewBox:"0 0 512 512"},inboxIcon:{name:"inbox",content:'<path d="M384 32H128L32 288v160c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V288zM150.2 64h211.6l84 224H352l-32 64H192l-32-64H66.2z" />',viewBox:"0 0 512 512"},increaseHorizontalSpacingIcon:{name:"increase-horizontal-spacing",content:'<path d="M480 96v160h-96v-64h-96v160h-96V192H96v96H32V64h64v96h96V0h96v160h96V96zM335.7 352l-22.6 22.6 57.4 57.4-57.4 57.4 22.6 22.6 80-80zM64 432l80 80 22.6-22.6-57.3-57.4 57.4-57.4L144 352z" />',viewBox:"0 0 512 512"},increaseVerticalSpacingIcon:{name:"increase-vertical-spacing",content:'<path d="M192 320v96h96v64H64v-64h96v-96H0v-96h160v-96H96V32h160v96h-64v96h160v96zm320 48.1-22.6-22.6-57.4 57.3-57.4-57.4-22.6 22.7 80 80zM432 96l-80 80 22.6 22.6 57.4-57.4 57.4 57.4L512 176z" />',viewBox:"0 0 512 512"},indentIcon:{name:"indent",content:'<path d="M480 64H32V32h448zm0 32H224v32h256zm0 64H224v32h256zm0 64H224v32h256zm0 64H224v32h256zm0 64H224v32h256zm0 64H32v32h448zM160 240 32 128v224z" />',viewBox:"0 0 512 512"},infoCircleIcon:{name:"info-circle",content:'<path d="M288 352h32v32H192v-32h32v-96h-32v-32h96zm0-224h-64v64h64zm192 128c0 123.7-100.3 224-224 224S32 379.7 32 256 132.3 32 256 32s224 100.3 224 224m-32 0c0-106-86-192-192-192S64 150 64 256s86 192 192 192 192-86 192-192" />',viewBox:"0 0 512 512"},infoSolidIcon:{name:"info-solid",content:'<path d="M256 32C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32m-32 96h64v64h-64zm96 256H192v-32h32v-96h-32v-32h96v128h32z" />',viewBox:"0 0 512 512"},inheritedIcon:{name:"inherited",content:'<path d="M448 320v128H320V320h30.4L256 244.5 161.6 320H192v128H64V320h46.4l120-96H176V64h160v160h-54.4l120 96z" />',viewBox:"0 0 512 512"},insertBottomIcon:{name:"insert-bottom",content:'<path d="M192 224h192v32H192zm0 128h288v-32H192zm192-192H192v32h192zM32 224v224l96-112z" />',viewBox:"0 0 512 512"},insertMiddleIcon:{name:"insert-middle",content:'<path d="M192 128h192v32H192zm0 128h288v-32H192zm192 64H192v32h192zM32 128v224l96-112z" />',viewBox:"0 0 512 512"},insertTopIcon:{name:"insert-top",content:'<path d="M192 320h192v32H192zm0-128h288v-32H192zm192 64H192v32h192zM32 64v224l96-112z" />',viewBox:"0 0 512 512"},invertColorsIcon:{name:"invert-colors",content:'<path d="m320 32-64 48 64 48V96h64v64h-32l48 64 48-64h-32V64h-96zM32 64v192h192V64zm192 192v192h192V256zM64 96h128v128H64z" />',viewBox:"0 0 512 512"},italicIcon:{name:"italic",content:'<path d="m377.2 128 6.8-32H198.8l-6.8 32h59.2l-54.4 256h-62l-6.8 32h185.2l6.8-32h-59.2l54.4-256z" />',viewBox:"0 0 512 512"},jsIcon:{name:"js",content:'<path d="M478.4 96C471 59.5 438.7 32 400 32H208c-38.7 0-71 27.5-78.4 64-1.1 5.2-1.6 10.5-1.6 16v272H32v16c0 5.5.5 10.8 1.6 16 7.4 36.5 39.7 64 78.4 64h192c38.7 0 71-27.5 78.4-64 1.1-5.2 1.6-10.5 1.6-16V128h96v-16c0-5.5-.5-10.8-1.6-16m-124.8 0c-1.1 5.2-1.6 10.5-1.6 16v288c0 5.6-1 11-2.8 16-6.6 18.6-24.4 32-45.2 32-20.9 0-38.7-13.4-45.2-32-1.8-5-2.8-10.4-2.8-16v-16h-96V112c0-5.6 1-11 2.8-16 6.6-18.6 24.4-32 45.2-32h160c-7 9.3-12 20.2-14.4 32M320 192H192v-32h128zm0 64H192v-32h128zm0 64H192v-32h128z" />',viewBox:"0 0 512 512"},justifyContentAroundAltIcon:{name:"justify-content-around-alt",content:'<path d="M95 96h320v128H95zM31 512h448v-32H31zm65-96h320V288H96zM31 0v32h448V0z" />',viewBox:"0 0 512 512"},justifyContentAroundIcon:{name:"justify-content-around",content:'<path d="M95 96h128v320H95zm384-64v448h32V32zM287 415h128V95H287zM-1 480h32V32H-1z" />',viewBox:"0 0 512 512"},justifyContentBetweenAltIcon:{name:"justify-content-between-alt",content:'<path d="M95 64h320v128H95zM31 512h448v-32H31zm65-64h320V320H96zM31 0v32h448V0z" />',viewBox:"0 0 512 512"},justifyContentBetweenIcon:{name:"justify-content-between",content:'<path d="M63 96h128v320H63zm416-64v448h32V32zM319 415h128V95H319zM-1 480h32V32H-1z" />',viewBox:"0 0 512 512"},justifyContentCenterAltIcon:{name:"justify-content-center-alt",content:'<path d="M415 192H95V64h320zM31 224v32h448v-32zm65 192h320V288H96z" />',viewBox:"0 0 512 512"},justifyContentCenterIcon:{name:"justify-content-center",content:'<path d="M63 96h128v320H63zm160 384h32V32h-32zm64-385v320h128V95z" />',viewBox:"0 0 512 512"},justifyContentEndAltIcon:{name:"justify-content-end-alt",content:'<path d="M415 257H95V129h320zM31 449v32h448v-32zm65-32h320V289H96z" />',viewBox:"0 0 512 512"},justifyContentEndIcon:{name:"justify-content-end",content:'<path d="M128 96h128v320H128zm320-64v448h32V32zM288 415h128V95H288z" />',viewBox:"0 0 512 512"},justifyContentStartAltIcon:{name:"justify-content-start-alt",content:'<path d="M415 224H95V96h320zM31 32v32h448V32zm65 352h320V256H96z" />',viewBox:"0 0 512 512"},justifyContentStartIcon:{name:"justify-content-start",content:'<path d="M95 96h128v320H95zM31 480h32V32H31zM255 95v320h128V95z" />',viewBox:"0 0 512 512"},kpiStatusDenyIcon:{name:"kpi-status-deny",content:'<path d="M480 256 256 480 32 256 256 32z" />',viewBox:"0 0 512 512"},kpiStatusHoldIcon:{name:"kpi-status-hold",content:'<path d="M256 64 32 448h448z" />',viewBox:"0 0 512 512"},kpiStatusOpenIcon:{name:"kpi-status-open",content:'<path d="M480 256c0 123.7-100.3 224-224 224S32 379.7 32 256 132.3 32 256 32s224 100.3 224 224" />',viewBox:"0 0 512 512"},launchIcon:{name:"launch",content:'<path d="M96 96v320h96v-32h-64V128h256v64h32V96zm320 160v160H256l57.4-57.4L192 237.3l45.3-45.3 121.4 121.4.5-.5z" />',viewBox:"0 0 512 512"},layout1By4Icon:{name:"layout-1-by-4",content:'<path d="M32 0h192v480H32zm224 0v96h192V0zm0 224h192v-96H256zm0 128h192v-96H256zm0 128h192v-96H256z" />',viewBox:"0 0 512 512"},layout2By2Icon:{name:"layout-2-by-2",content:'<path d="M32 224h192V0H32zm224 0h192V0H256zM32 480h192V256H32zm224 0h192V256H256z" />',viewBox:"0 0 512 512"},layoutIcon:{name:"layout",content:'<path d="M192 416h256v64H192zm0-32h256v-64H192zM32 480h128V128H32zm160-288h256v-64H192zm0 96h256v-64H192zM32 0v96h416V0z" />',viewBox:"0 0 512 512"},layoutSideBySideIcon:{name:"layout-side-by-side",content:'<path d="M32 384h416v96H32zm0-32h416v-96H32zm0-128h416v-96H32zM32 0v96h416V0z" />',viewBox:"0 0 512 512"},layoutStackedIcon:{name:"layout-stacked",content:'<path d="M32 256h192v96H32zm0 224h192v-96H32zm224-128h192v-96H256zM32 0v224h416V0zm224 480h192v-96H256z" />',viewBox:"0 0 512 512"},lessOrEqualIcon:{name:"less-or-equal",content:'<path d="m318.1 352-160-160 160-160L352 65.9 225.9 192 352 318.1zM128 416v32h256v-32z" />',viewBox:"0 0 512 512"},letterSpaceIcon:{name:"letter-space",content:'<path d="m310 336 26 80h48L280 96h-48L128 416h48l26-80zm-54-166.2L294.4 288h-76.8zM448 32h32v448h-32zM32 32h32v448H32z" />',viewBox:"0 0 512 512"},levelDownIcon:{name:"level-down",content:'<path d="M288 192v64h64l-80 128-80-128h64v-64H128v-32h288v32z" />',viewBox:"0 0 512 512"},levelToTopIcon:{name:"level-to-top",content:'<path d="m128 288 80-128 80 128h-64v64h192v32H192v-96zm288-160H96v32h320z" />',viewBox:"0 0 512 512"},levelUpIcon:{name:"level-up",content:'<path d="m128 288 80-128 80 128h-64v64h192v32H192v-96z" />',viewBox:"0 0 512 512"},lineHeightIcon:{name:"line-height",content:'<path d="m310 336 26 80h48L280 96h-48L128 416h48l26-80zm-54-166.2L294.4 288h-76.8zM32 32h448v32H32zm0 416h448v32H32z" />',viewBox:"0 0 512 512"},linkAddIcon:{name:"link-add",content:'<path d="M448 416v-64h-32v64h-64v32h64v64h32v-64h64v-32zM96 256c0-17.7 14.3-32 32-32h256c17.7 0 32 14.3 32 32s-14.3 32-32 32H128c-17.7 0-32-14.3-32-32m-32 0c0 35.4 28.6 64 64 64h110.8c-22.1 38.2-63.5 64-110.8 64C57.3 384 0 326.7 0 256s57.3-128 128-128c47.4 0 88.7 25.8 110.8 64H128c-35.4 0-64 28.6-64 64m416 84.7c19.9-22.6 32-52.2 32-84.7 0-70.7-57.3-128-128-128-47.3 0-88.7 25.8-110.8 64H384c35.3 0 64 28.6 64 64s-28.6 64-64 64h96zM384 320H273.2c22.1 38.2 63.4 64 110.8 64z" />',viewBox:"0 0 512 512"},linkIcon:{name:"link",content:'<path d="M384 384c-47.4 0-88.7-25.8-110.8-64H384c35.4 0 64-28.6 64-64s-28.7-64-64-64H273.2c22.1-38.2 63.5-64 110.8-64 70.7 0 128 57.3 128 128s-57.3 128-128 128M96 256c0-17.7 14.3-32 32-32h256c17.7 0 32 14.3 32 32s-14.3 32-32 32H128c-17.7 0-32-14.3-32-32m-32 0c0 35.4 28.6 64 64 64h110.8c-22.1 38.2-63.5 64-110.8 64C57.3 384 0 326.7 0 256s57.3-128 128-128c47.4 0 88.7 25.8 110.8 64H128c-35.4 0-64 28.6-64 64" />',viewBox:"0 0 512 512"},linkVerticalIcon:{name:"link-vertical",content:'<path d="M128 384c0-47.4 25.8-88.7 64-110.8V384c0 35.4 28.6 64 64 64s64-28.7 64-64V273.2c38.2 22.1 64 63.5 64 110.8 0 70.7-57.3 128-128 128s-128-57.3-128-128M256 96c17.7 0 32 14.3 32 32v256c0 17.7-14.3 32-32 32s-32-14.3-32-32V128c0-17.7 14.3-32 32-32m0-32c-35.4 0-64 28.6-64 64v110.8c-38.2-22.1-64-63.5-64-110.8C128 57.3 185.3 0 256 0s128 57.3 128 128c0 47.4-25.8 88.7-64 110.8V128c0-35.4-28.6-64-64-64" />',viewBox:"0 0 512 512"},linkedinBoxIcon:{name:"linkedin-box",content:'<path d="M448 32H64c-17.6 0-32 14.4-32 32v384c0 17.6 14.4 32 32 32h384c17.6 0 32-14.4 32-32V64c0-17.6-14.4-32-32-32M160 416H96V192h64zm-32-256c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32m288 256h-64V288c0-17.7-14.3-32-32-32s-32 14.3-32 32v128h-64V192h64v39.7c13.2-18.1 33.4-39.7 56-39.7 39.8 0 72 35.8 72 80z" />',viewBox:"0 0 512 512"},linkedinIcon:{name:"linkedin",content:'<path d="M112 32c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48M64 160v288h96V160zm128 0v288h96V288c0-32 32-32 32-32s32 0 32 32v160h96V290.9c0-66.5-13.6-130.9-96-130.9-36.2 0-62.9 32-64 44.9V160z" />',viewBox:"0 0 512 512"},listLatinBigIcon:{name:"list-latin-big",content:'<path d="M115.1 136H72.6l-7.4 24H32.1L79.3 31.5h29.1L155.9 160h-33.3zm-35-23.9h27.6L93.8 67.5zM42.1 320V191.5h46.2c16.5 0 29.1 3 37.7 9.1q12.9 9.15 12.9 26.4c0 6.6-1.5 12.3-4.6 17s-7.6 8.2-13.5 10.4c6.7 1.8 11.9 5.1 15.4 9.9q5.4 7.2 5.4 17.7c0 12.6-4 22.1-12 28.4s-19.8 9.5-35.4 9.7H42.1zm31-74.9h16.2c6.8-.1 11.6-1.3 14.5-3.7s4.3-6 4.3-10.7c0-5.4-1.6-9.3-4.7-11.7s-8.2-3.6-15.1-3.6H73.1zm0 20.3v30.8h20.3c5.6 0 9.9-1.3 12.9-3.8q4.5-3.9 4.5-10.8c0-10.7-5.3-16.1-16-16.2zm73 171.1q-.6 13.35-7.2 23.7t-18.6 15.9c-8 3.8-17.1 5.6-27.3 5.6q-25.35 0-39.9-16.5c-14.55-16.5-14.6-26.5-14.6-46.6v-6.4c0-12.6 2.2-23.6 6.6-33.1Q51.7 365 64 357.2c8.2-5.1 17.8-7.7 28.6-7.7 15.6 0 28.1 4.1 37.6 12.3q14.25 12.3 16.2 33.9h-30.9c-.2-7.8-2.2-13.4-5.9-16.9-3.7-3.4-9.4-5.1-16.9-5.1-7.7 0-13.4 2.9-16.9 8.6-3.6 5.8-5.5 15-5.6 27.6v9.1c0 13.7 1.7 23.5 5.2 29.4 3.4 5.9 9.4 8.8 17.8 8.8 7.1 0 12.6-1.7 16.3-5 3.8-3.4 5.8-8.7 6-16h30.6zM192 96h288v32H192zm0 160h288v32H192zm0 160h288v32H192z" />',viewBox:"0 0 512 512"},listLatinSmallIcon:{name:"list-latin-small",content:'<path d="M94.5 152c-1.1-1.9-2-4.8-2.8-8.6-5.5 6.9-13.1 10.3-22.9 10.3-9 0-16.7-2.7-22.9-8.2-6.3-5.4-9.4-12.3-9.4-20.5 0-10.4 3.8-18.2 11.5-23.5 7.6-5.3 18.8-7.9 33.4-7.9h9.2v-5.1q0-13.2-11.4-13.2c-7.1 0-10.6 3.5-10.6 10.5H38.7c0-9.2 3.9-16.7 11.8-22.5s17.9-8.6 30.1-8.6 21.8 3 28.9 8.9 10.7 14.1 10.9 24.4v42.3c.1 8.8 1.5 15.5 4.1 20.1v1.5zm-18.6-19.4c3.7 0 6.8-.8 9.2-2.4s4.2-3.4 5.3-5.4v-15.3h-8.6c-10.4 0-15.5 4.6-15.5 13.9q0 4.05 2.7 6.6c1.8 1.7 4.1 2.6 6.9 2.6M129.4 280c0 15.7-3.2 27.7-9.7 36.1s-15.6 12.6-27.4 12.6c-9.7 0-17.5-3.9-23.5-11.6l-1.2 9.8H41V191.4h29.7v47.7c5.5-6.3 12.7-9.4 21.4-9.4 11.9 0 21.1 4.3 27.5 12.8 6.5 8.5 9.7 20.5 9.7 36zm-29.8-1.9c0-9.2-1.2-15.7-3.7-19.6-2.4-3.9-6.2-5.9-11.3-5.9-6.7 0-11.4 2.6-13.9 7.7v37.9c2.5 5.1 7.2 7.6 14.1 7.6 7 0 11.4-3.4 13.3-10.2 1-3.4 1.5-9.2 1.5-17.5M81.1 452.8c4.2 0 7.4-1.1 9.7-3.4s3.4-5.4 3.4-9.5h27.9c0 10.5-3.8 19.1-11.3 25.8s-17.2 10.1-29 10.1c-13.9 0-24.8-4.4-32.8-13.1s-12-20.8-12-36.2v-1.2c0-9.6 1.8-18.2 5.3-25.6 3.6-7.4 8.7-13.1 15.4-17 6.7-4 14.7-6 23.8-6 12.4 0 22.3 3.4 29.6 10.3s10.9 16.2 10.9 28H94.2q0-7.35-3.6-11.4c-2.4-2.6-5.6-4-9.7-4q-11.55 0-13.5 14.7-.6 4.65-.6 12.9c0 9.6 1.1 16.2 3.4 19.9s5.9 5.7 10.9 5.7M192 96h288v32H192zm0 160h288v32H192zm0 160h288v32H192z" />',viewBox:"0 0 512 512"},listOrderedIcon:{name:"list-ordered",content:'<path d="M192 64h288v32H192zm0 160h288v32H192zm0 160h288v32H192zM96 32v128H64V64c-1.5 1.3-14.9 7.8-22.1 10V50.8c7.2-2.1 13.9-4.8 20.3-8 6.3-3.3 12.1-6.8 17.2-10.7zM66.7 297h61.1v23H32v-9.5c0-6.4 1.2-12.2 3.7-17.3q3.75-7.65 9.3-13.8t12.3-10.8c4.5-3.1 8.7-6 12.7-8.5 4.2-2.6 7.9-5.1 11.1-7.6 3.2-2.4 5.9-4.8 8-7.2 2.2-2.4 3.8-4.8 4.9-7.2s1.6-5 1.6-7.8c0-5.4-1.7-9.5-5.2-12.2-3.5-2.8-8.8-4.1-16-4.1-12.4 0-24.2 4.3-35.5 12.9v-24.4c12.5-7.1 26.6-10.6 42.4-10.6 7.3 0 13.8.8 19.6 2.5q8.7 2.55 14.7 7.2c4 3.1 7.1 6.9 9.2 11.3s3.2 9.3 3.2 14.8c0 5.8-1 10.9-3.1 15.5-2 4.5-4.8 8.6-8.1 12.3-3.4 3.7-7.3 7.1-11.7 10.1-4.4 3.1-9 6-13.8 8.9-3.2 2-6.3 4-9.3 5.9-3 2-5.6 3.9-7.9 5.8s-4.1 3.8-5.4 5.6-2 3.6-2 5.2M32 473.8V450c10.1 6 21.8 9.1 35.3 9.1q12.75 0 19.8-4.5c4.7-3 7.1-7.2 7.1-12.5 0-5.5-2.9-9.8-8.8-12.8-5.8-3-13.9-4.5-24.1-4.5h-14V404h12.9c19.6 0 29.4-5.4 29.4-16.1 0-10.1-7.5-15.1-22.6-15.1-10.1 0-19.9 2.7-29.4 8v-22.3c10.6-4.4 22.9-6.6 37-6.6 15.4 0 27.4 2.8 36 8.5s12.9 13.1 12.9 22.2c0 16.2-10 26.3-29.9 30.4v.4c10.6 1.1 19 4.3 25.2 9.5 6.2 5.3 9.2 11.7 9.2 19.4 0 11.6-5.1 20.7-15.4 27.4S88.1 480 69.9 480c-15.5 0-28.2-2.1-37.9-6.2" />',viewBox:"0 0 512 512"},listRomanBigIcon:{name:"list-roman-big",content:'<path d="M32 32h32v128H32zm0 288h32V192H32zm64 0h32V192H96zM32 480h32V352H32zm64 0h32V352H96zm64 0h32V352h-32zM128 96h352v32H128zm64 160h288v32H192zm64 160h224v32H256zM96 152c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m64 160c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m64 160c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8" />',viewBox:"0 0 512 512"},listRomanLowerIcon:{name:"list-roman-lower",content:'<path d="M32 64h16v96H32zm0 256h16v-96H32zm32 0h16v-96H64zM32 480h16v-96H32zm32 0h16v-96H64zm32 0h16v-96H96zM48 40c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 112c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 160c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8M48 200c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 0c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8M48 360c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 0c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 0c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 112c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8M128 96h352v32H128zm32 160h320v32H160zm32 160h288v32H192z" />',viewBox:"0 0 512 512"},listRomanSmallIcon:{name:"list-roman-small",content:'<path d="M32 64h16v96H32zm0 256h16v-96H32zm32 0h16v-96H64zM32 480h16v-96H32zm32 0h16v-96H64zm32 0h16v-96H96zM48 40c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 112c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 160c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8M48 200c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 0c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8M48 360c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 0c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 0c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m32 112c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8M128 96h352v32H128zm32 160h320v32H160zm32 160h288v32H192z" />',viewBox:"0 0 512 512"},listRomanUpperIcon:{name:"list-roman-upper",content:'<path d="M32 32h32v128H32zm0 288h32V192H32zm64 0h32V192H96zM32 480h32V352H32zm64 0h32V352H96zm64 0h32V352h-32zM128 96h352v32H128zm64 160h288v32H192zm64 160h224v32H256zM96 152c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m64 160c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8m64 160c0 4.4-3.6 8-8 8s-8-3.6-8-8 3.6-8 8-8 8 3.6 8 8" />',viewBox:"0 0 512 512"},listUnorderedIcon:{name:"list-unordered",content:'<path d="M192 64h288v32H192zm0 160h288v32H192zm0 160h288v32H192zM80 32c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48m0 160c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48m0 160c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48" />',viewBox:"0 0 512 512"},listUnorderedOutlineIcon:{name:"list-unordered-outline",content:'<path d="M192 80h288v32H192zm0 160h288v32H192zm0 160h288v32H192zM80 80c8.8 0 16 7.2 16 16s-7.2 16-16 16-16-7.2-16-16 7.2-16 16-16m0-32c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48m0 192c8.8 0 16 7.2 16 16s-7.2 16-16 16-16-7.2-16-16 7.2-16 16-16m0-32c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48m0 192c8.8 0 16 7.2 16 16s-7.2 16-16 16-16-7.2-16-16 7.2-16 16-16m0-32c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48" />',viewBox:"0 0 512 512"},listUnorderedSquareIcon:{name:"list-unordered-square",content:'<path d="M128 160H32V64h96zm0 64H32v96h96zm0 160H32v96h96zm64-256h288V96H192zm0 160h288v-32H192zm0 160h288v-32H192z" />',viewBox:"0 0 512 512"},lockIcon:{name:"lock",content:'<path d="M384 224h-32v-96c0-53-43-96-96-96s-96 43-96 96v96h-32c-17.6 0-32 14.4-32 32v192c0 17.6 14.4 32 32 32h256c17.6 0 32-14.4 32-32V256c0-17.6-14.4-32-32-32m-192-96c0-35.3 28.7-64 64-64s64 28.7 64 64v96H192zm64 256c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32" />',viewBox:"0 0 512 512"},loginIcon:{name:"login",content:'<path d="M384 480h96V32h-96zM32 224v64h128v96l160-128-160-128v96z" />',viewBox:"0 0 512 512"},logoutIcon:{name:"logout",content:'<path d="M128 32H32v448h96zm64 192v64h128v96l160-128-160-128v96z" />',viewBox:"0 0 512 512"},makeHorizontalSpacingEqualIcon:{name:"make-horizontal-spacing-equal",content:'<path d="M480 160v160h-96v-64h-96v160h-96V256H96v96H32V128h64v96h96V64h96v160h96v-64z" />',viewBox:"0 0 512 512"},makeSameHeightIcon:{name:"make-same-height",content:'<path d="M128 0v480H32V0zm96 192v96h96v-96zM272.1 0l-48.4 64H256v64h33V64h31.6zM288 416v-64h-32v64h-32l48 64 48-64zM448 0h-96v32h96v96h32V0zm0 352v96h-96v32h128V352z" />',viewBox:"0 0 512 512"},makeSameSizeIcon:{name:"make-same-size",content:'<path d="M288 192v96h-96v-96zM240.1 0l-48.4 64H224v64h33V64h31.6zM256 416v-64h-32v64h-32l48 64 48-64zm224-175.9-64-48.4V224h-64v33h64v31.6zM64 224v-32L0 240l64 48v-32h64v-32zM128 0H0v128h32V32h96zm320 0h-96v32h96v96h32V0zM32 448v-96H0v128h128v-32zm416-96v96h-96v32h128V352z" />',viewBox:"0 0 512 512"},makeSameWidthIcon:{name:"make-same-width",content:'<path d="M480 128H0V32h480zm-192 96h-96v96h96zm192 48.1-64-48.4V256h-64v33h64v31.6zM64 256v-32L0 272l64 48v-32h64v-32zm384 96v96h-96v32h128V352zM32 448v-96H0v128h128v-32z" />',viewBox:"0 0 512 512"},makeVerticalSpacingEqualIcon:{name:"make-vertical-spacing-equal",content:'<path d="M256 320v96h96v64H128v-64h96v-96H64v-96h160v-96h-64V32h160v96h-64v96h160v96z" />',viewBox:"0 0 512 512"},mapMarkerIcon:{name:"map-marker",content:'<path d="M256 0C158.8 0 80 78.8 80 176s176 336 176 336 176-238.8 176-336S353.2 0 256 0m0 288c-61.9 0-112-50.1-112-112S194.1 64 256 64s112 50.1 112 112-50.1 112-112 112" />',viewBox:"0 0 512 512"},mapMarkerTargetIcon:{name:"map-marker-target",content:'<path d="M256 0C158.8 0 80 78.8 80 176s176 336 176 336 176-238.8 176-336S353.2 0 256 0m0 288c-61.9 0-112-50.1-112-112S194.1 64 256 64s112 50.1 112 112-50.1 112-112 112m48-112c0 26.5-21.5 48-48 48s-48-21.5-48-48 21.5-48 48-48 48 21.5 48 48" />',viewBox:"0 0 512 512"},maxHeightIcon:{name:"max-height",content:'<path d="M384 0H96v32h288zm0 479H240.6L320 352h-64V160h64L240 32l-80 128h64v192h-64l79.4 127H96v32h288z" />',viewBox:"0 0 512 512"},maxWidthIcon:{name:"max-width",content:'<path d="M0 96v288h32V96zm479 0v143.4L352 160v64H160v-64L32 240l128 80v-64h192v64l127-79.4V384h32V96z" />',viewBox:"0 0 512 512"},mediaManagerIcon:{name:"media-manager",content:'<path d="M192 384V128l192 128zm32-319.3V0C108.2 14.4 14.4 108.2 0 224h64.7c13.5-80.3 79-145.8 159.3-159.3m64 382.6V512c115.8-14.4 209.6-108.2 224-224h-64.7c-13.5 80.3-79 145.8-159.3 159.3M64.7 288H0c14.4 115.8 108.2 209.6 224 224v-64.7c-80.3-13.5-145.8-79-159.3-159.3m382.6-64H512C497.6 108.2 403.8 14.4 288 0v64.7c80.3 13.5 145.8 79 159.3 159.3" />',viewBox:"0 0 512 512"},menuIcon:{name:"menu",content:'<path d="M480 32v96H32V32zM32 192v96h448v-96zm448 160H32v96h448z" />',viewBox:"0 0 512 512"},minHeightIcon:{name:"min-height",content:'<path d="M240 192H96v32h288v-32zm144 96H96v32h288zM160 448h160l-80-128zm64 0h32v64h-32zm32-384V0h-32v64h-64l80 128 80-128z" />',viewBox:"0 0 512 512"},minWidthIcon:{name:"min-width",content:'<path d="M192 240v144h32V96h-32zm96-144v288h32V96zm160 224V160l-128 80zm0-96h64v32h-64zm-384 0H0v32h64v64l128-80-128-80z" />',viewBox:"0 0 512 512"},minusCircleIcon:{name:"minus-circle",content:'<path d="M256 32C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32M128 288v-64h256v64z" />',viewBox:"0 0 512 512"},minusIcon:{name:"minus",content:'<path d="M96 224v64h320v-64z" />',viewBox:"0 0 512 512"},minusOutlineIcon:{name:"minus-outline",content:'<path d="M128 224h256v64H128zM256 32C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32m0 416c-106 0-192-86-192-192S150 64 256 64s192 86 192 192-86 192-192 192" />',viewBox:"0 0 512 512"},minusSmIcon:{name:"minus-sm",content:'<path d="M352 224v64H160v-64z" />',viewBox:"0 0 512 512"},mirrorIcon:{name:"mirror",content:'<path d="M192 64H32v384h160zm-31 352s0 .1 0 0l-96.9.1-.1-.1V96.1l.1-.1H160v320zm95 64h-32V32h32zm32-416h160v384H288z" />',viewBox:"0 0 512 512"},moreHorizontalIcon:{name:"more-horizontal",content:'<path d="M128 240c0-26.4-21.6-48-48-48s-48 21.6-48 48 21.6 48 48 48 48-21.6 48-48m64 0c0 26.4 21.6 48 48 48s48-21.6 48-48-21.6-48-48-48-48 21.6-48 48m160 0c0 26.4 21.6 48 48 48s48-21.6 48-48-21.6-48-48-48-48 21.6-48 48" />',viewBox:"0 0 512 512"},moreVerticalIcon:{name:"more-vertical",content:'<path d="M240 128c26.4 0 48-21.6 48-48s-21.6-48-48-48-48 21.6-48 48 21.6 48 48 48m0 64c-26.4 0-48 21.6-48 48s21.6 48 48 48 48-21.6 48-48-21.6-48-48-48m0 160c-26.4 0-48 21.6-48 48s21.6 48 48 48 48-21.6 48-48-21.6-48-48-48" />',viewBox:"0 0 512 512"},musicNotesIcon:{name:"music-notes",content:'<path d="M160 170v-64m0-.2v259c-13.4-8-30-12.8-48-12.8-44.2 0-80 28.7-80 64s35.8 64 80 64 80-28.7 80-64V162.5l256-59.1v165.4c-13.4-8-30-12.8-48-12.8-44.2 0-80 28.7-80 64s35.8 64 80 64 80-28.7 80-64V32z" />',viewBox:"0 0 512 512"},myspaceBoxIcon:{name:"myspace-box",content:'<path d="M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32M128 416H64v-63.5c0-17.9 14.3-32.5 32-32.5s32 14.5 32 32.5zM96 288c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32m160 128h-96v-75.3c0-29.1 21.5-52.7 48-52.7s48 23.6 48 52.7zm-48-160c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48m208 160H288v-92.9c0-37.1 27.2-67.1 64-67.1s64 30 64 67.1zm-64-192c-35.4 0-64-28.6-64-64s28.6-64 64-64 64 28.6 64 64-28.6 64-64 64" />',viewBox:"0 0 512 512"},myspaceIcon:{name:"myspace",content:'<path d="M400 64c-44.2 0-80 35.8-80 80s35.8 80 80 80 80-35.8 80-80-35.8-80-80-80m-176 64c-35.4 0-64 28.6-64 64s28.6 64 64 64 64-28.6 64-64-28.6-64-64-64M80 192c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48m320 64c-44.2 0-80 36.1-80 80.5V448h160V336.5c0-44.5-35.8-80.5-80-80.5m-176 32c-35.4 0-64 31.5-64 70.3V448h128v-89.7c0-38.8-28.6-70.3-64-70.3M80 320c-26.5 0-48 21.8-48 48.7V448h96v-79.3c0-26.9-21.5-48.7-48-48.7" />',viewBox:"0 0 512 512"},nonRecurrenceIcon:{name:"non-recurrence",content:'<path d="m321 434.2 47.5 47.5C335.5 501 297 512 256 512 132.3 512 32 411.7 32 288c0-41 11-79.5 30.3-112.6l47.5 47.5c-8.9 19.9-13.8 41.9-13.8 65 0 88.2 71.8 160 160 160 23.1.1 45.2-4.8 65-13.7m118.3-17.5c12.9-18.3 23.1-38.7 30.1-60.4 6.9-21.5 10.6-44.5 10.6-68.3 0-40.8-10.9-79.1-30-112l-55.5 32c13.6 23.5 21.5 50.9 21.5 80 0 4.8-.2 9.5-.6 14.2-2.2 24.8-10.1 47.9-22.3 68.2L173.6 150.9c20.3-12.2 43.4-20.1 68.2-22.3 4.7-.4 9.4-.6 14.2-.6v64l160-96L256 0v64c-23.8 0-46.7 3.7-68.3 10.6-21.8 7-42.1 17.2-60.4 30.1L22.6 0 0 22.6 489.4 512l22.6-22.6z" />',viewBox:"0 0 512 512"},notEqualIcon:{name:"not-equal",content:'<path d="m290.7 224-37.3 64H416v64H216l-56 96h-48l56-96H96v-64h109.3l37.3-64H96v-64h184l56-96h48l-56 96h88v64z" />',viewBox:"0 0 512 512"},outdentIcon:{name:"outdent",content:'<path d="M480 64H32V32h448zm0 32H224v32h256zm0 64H224v32h256zm0 64H224v32h256zm0 64H224v32h256zm0 64H224v32h256zm0 64H32v32h448zm-320-64V128L32 240z" />',viewBox:"0 0 512 512"},outlineOffsetIcon:{name:"outline-offset",content:'<path d="M448 32H32v448h448V32zm0 416H64V64h384zM160 320v32h192V160H160zm32-128h128v128H192z" />',viewBox:"0 0 512 512"},outlineWidthIcon:{name:"outline-width",content:'<path d="M416 32H32v448h448V32zm0 384H96V96h320zm-256-32h224V128H128v256zm0-224h192v192H160z" />',viewBox:"0 0 512 512"},overlapIcon:{name:"overlap",content:'<path d="M320 320V64H64v256zM192 448h256V192h-96v160H192z" />',viewBox:"0 0 512 512"},paddingBottomIcon:{name:"padding-bottom",content:'<path d="M288.2 352H256v64h64v64H160v-64h64v-64h-32v-64h96.2zM160 32h64v96h-32.2v32H288v-32h-32V32h64V0H160zm192 192v-32.2h-32V288h32v-32h96v64h32V160h-32v64zm-224 32v32.2h32V192h-32v32H32v-64H0v160h32v-64z" />',viewBox:"0 0 512 512"},paddingIcon:{name:"padding",content:'<path d="M128 288.2V256H32v64H0V160h32v64h96v-32h32v96.2zM448 160v64h-96v-32.2h-32V288h32v-32h96v64h32V160zM256 352h32.2v-32H192v32h32v96h-64v32h160v-32h-64zm-32-224h-32.2v32H288v-32h-32V32h64V0H160v32h64z" />',viewBox:"0 0 512 512"},paddingLeftIcon:{name:"padding-left",content:'<path d="M128 288.2V256H64v64H0V160h64v64h64v-32h64v96.2zM448 160v64h-96v-32.2h-32V288h32v-32h96v64h32V160zM256 352h32.2v-32H192v32h32v96h-64v32h160v-32h-64zm-32-224h-32.2v32H288v-32h-32V32h64V0H160v32h64z" />',viewBox:"0 0 512 512"},paddingRightIcon:{name:"padding-right",content:'<path d="M352 191.8V224h64v-64h64v160h-64v-64h-64v32h-64v-96.2zM32 320v-64h96v32.2h32V192h-32v32H32v-64H0v160zm192-192h-32.2v32H288v-32h-32V32h64V0H160v32h64zm32 224h32.2v-32H192v32h32v96h-64v32h160v-32h-64z" />',viewBox:"0 0 512 512"},paddingTopIcon:{name:"padding-top",content:'<path d="M191.8 128H224V64h-64V0h160v64h-64v64h32v64h-96.2zM320 448h-64v-96h32.2v-32H192v32h32v96h-64v32h160zM128 256v32.2h32V192h-32v32H32v-64H0v160h32v-64zm224-32v-32.2h-32V288h32v-32h96v64h32V160h-32v64z" />',viewBox:"0 0 512 512"},pageFooterSectionIcon:{name:"page-footer-section",content:'<path d="M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96zm-31-32H129v-96h256zm0-160H129v32h256zm0-64H129v32h256z" />',viewBox:"0 0 512 512"},pageHeaderSectionIcon:{name:"page-header-section",content:'<path d="M352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96zm-32-160H128v-96h256zm0 96H128v32h256zm0-64H128v32h256z" />',viewBox:"0 0 512 512"},paletteIcon:{name:"palette",content:'<path d="m206 256.6 160-160c-2.2-5.7-4.8-11.1-7.9-16.3-24.2-40.8-60.1-66-107.8-75.9-2.3-.5-4.7-1-7.1-1.4C192-5.8 143.1 4.8 96.5 34.6 49.3 64.7 19.2 107.2 6.1 162c-13 54.8-5.2 106.4 23.4 154.6 14.2 23.8 31.3 43.2 51.4 58.4 3.8-25.2 13.4-52 36.4-75 31.3-31.4 64-41.3 88.7-43.4M288 64c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32m-96-32c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32M64 256c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32m0-128c0-17.7 14.3-32 32-32s32 14.3 32 32-14.3 32-32 32-32-14.3-32-32m438.7 12.9L480 118.3c-12.4-12.4-32.8-12.4-45.3 0L281.1 271.9c11.5 5.8 20.8 12.2 27.7 17.6 5.3 4.2 9.2 7.7 11.3 9.8l11.3 12.7c5.4 6.8 11.8 16.2 17.6 27.6l153.5-153.5c12.6-12.4 12.6-32.8.2-45.2M354.3 289.3c-4.8-5.8-8.6-9.9-10.6-11.9-2.3-2.3-6.3-6.1-12-10.7L457.4 141h.1l22.5 22.5zm-78.7 169c-23.8 23.7-48.4 33-70.7 37.7-49.6 10.4-96 16-96 16s34.7-17.3 33.9-77c-.4-32.7-3.7-66.4 19.7-89.8 56.6-56.7 113.3.2 113.3.2s56.7 56-.2 112.9" />',viewBox:"0 0 512 512"},paneFreezeIcon:{name:"pane-freeze",content:'<path d="M32 32v416h416V32zm256 32 96 96h-64l-96-96zm-128 0 96 96h-64L96 64zM64 96l96 96v64l-96-96zm0 128 96 96v64l-96-96zm0 192v-64l64 64zm224 0h-96v-96h96zm0-128h-96v-96h96zm128 128h-96v-96h96zm0-128h-96v-96h96zM352 64h64v64z" />',viewBox:"0 0 512 512"},paperPlaneIcon:{name:"paper-plane",content:'<path d="M469.783 271.879 54.329 446.734c-13.149 5.534-26.266-8.042-21.225-21.967l48.3-133.404c2.16-5.966 7.298-10.169 13.326-10.901C312.468 256 239.85 263.839 312.468 256c-72.618-7.839 0 0-217.739-24.462-6.027-.732-11.165-4.935-13.325-10.901l-48.3-133.404C28.063 73.308 41.18 59.732 54.33 65.266l415.454 174.855c13.623 5.734 13.623 26.024 0 31.758" />',viewBox:"0 0 512 512"},paperclipAltIcon:{name:"paperclip-alt",content:'<path d="M407 452.1c-18.6 18.6-43 27.9-67.5 27.9s-48.9-9.3-67.6-27.9L69.3 249.4c-49.7-49.7-49.7-130.5 0-180.2s130.5-49.7 180.2 0l180.2 180.2-22.7 22.5L226.9 91.8c-37.2-37.2-97.9-37.2-135.1 0s-37.2 97.9 0 135.1l202.7 202.7c24.8 24.8 65.2 24.8 90.1 0 24.8-24.8 24.8-65.2 0-90.1L181.9 136.8c-12.4-12.4-32.7-12.4-45 0s-12.4 32.7 0 45L317 362l-22.5 22.5-180.2-180.1c-24.8-24.8-24.8-65.2 0-90.1s65.2-24.8 90.1 0L407 317c37.3 37.2 37.3 97.9 0 135.1" />',viewBox:"0 0 512 512"},paperclipIcon:{name:"paperclip",content:'<path d="M384 128v256h-32V128c0-52.9-43.1-96-96-96s-96 43.1-96 96v288c0 35.3 28.7 64 64 64s64-28.7 64-64V128c0-17.6-14.4-32-32-32s-32 14.4-32 32v256h-32V128c0-35.3 28.7-64 64-64s64 28.7 64 64v288c0 52.9-43.1 96-96 96s-96-43.1-96-96V128C128 57.4 185.4 0 256 0s128 57.4 128 128" />',viewBox:"0 0 512 512"},paragraphAddIcon:{name:"paragraph-add",content:'<path d="M320 96h-64v352h-32V96h-64v352h-32V256c-53 0-96-43-96-96s43-96 96-96h192zm96 256v-64h-32v64h-64v32h64v64h32v-64h64v-32z" />',viewBox:"0 0 512 512"},paragraphHeightIcon:{name:"paragraph-height",content:'<path d="M480 64H224V32h256zm0 32H224v32h256zm0 64H224v32h256zm0 64H224v32h256zm0 64H224v32h256zm0 64H224v32h256zm0 64H224v32h256zm-368 32 80-128h-64V160h64L112 32 32 160h64v160H32z" />',viewBox:"0 0 512 512"},paragraphMarkIcon:{name:"paragraph-mark",content:'<path d="M423.79 69.29h-74.57v410.16h-37.29V69.29h-74.57v410.16h-37.29V255.73c-61.76 0-111.86-50.1-111.86-111.86s50.1-111.86 111.86-111.86h223.72V69.3Z" />',viewBox:"0 0 512 512"},parameterBooleanIcon:{name:"parameter-boolean",content:'<path d="M64 96c-17.7 0-32 14.3-32 32v256c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V128c0-17.7-14.3-32-32-32zm384 288H64V128h384zM207 212h-39v114h-32V212H96v-26h111zm96.8-37-68.1 163h-27.5l67.9-163zM416 212h-49v34h45v26h-45v54h-32V186h81z" />',viewBox:"0 0 512 512"},parameterDateTimeIcon:{name:"parameter-date-time",content:'<path d="M416 202.8V128c0-17.7-14.3-32-32-32H64c-17.7 0-32 14.3-32 32v256c0 17.7 14.3 32 32 32h304c61.9 0 112-50.1 112.1-111.9 0-43.3-25-82.8-64.1-101.3M64.1 384 64 192h304c-61.9 0-112 50.2-112 112 0 30.1 12.1 58.9 33.6 80zm303.9 0c-44.2 0-80-35.8-80-80s35.8-80 80-80 80 35.8 80 80-35.8 80-80 80m48-96v32h-64v-64h32v32zm-224 32H96v-96h96z" />',viewBox:"0 0 512 512"},parameterFloatIcon:{name:"parameter-float",content:'<path d="M64 96c-17.7 0-32 14.3-32 32v256c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V128c0-17.7-14.3-32-32-32zm384 288H64V128h384zm-276-55.6c-33.3 0-50-23.4-50-70.2q0-36.45 13.5-55.5c13.5-19.05 22.1-19.1 39.2-19.1 32.6 0 48.8 23.8 48.8 71.4 0 23.7-4.4 41.9-13.3 54.5s-21.6 18.9-38.2 18.9m1.4-121.3c-13.3 0-20 16.8-20 50.3 0 31.6 6.5 47.4 19.6 47.4 12.8 0 19.1-16.3 19.1-48.8s-6.2-48.9-18.7-48.9m83.8 121.3c-4.7.1-9.2-1.5-12.7-4.7-3.3-2.9-5.2-7.1-5.1-11.5-.1-4.4 1.8-8.7 5.2-11.5 3.6-3 8.3-4.6 13-4.5q7.95 0 12.9 4.5c6.4 5.9 6.7 15.9.8 22.2l-.9.9c-3.3 3.1-7.8 4.6-13.2 4.6M390 326h-88v-24h29v-87.2l-30 6.4v-25.5l60-12.1V302h29z" />',viewBox:"0 0 512 512"},parameterIntegerIcon:{name:"parameter-integer",content:'<path d="M64 96c-17.7 0-32 14.3-32 32v256c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V128c0-17.7-14.3-32-32-32zm384 288H64V128h384zm-262.6-58H96.8v-24.4h29v-87.2L96 220.8v-25l60.6-12.2v118h28.8zm59.2-26.2v.6h56.8V326h-92.2v-24l40.1-38.4c8.1-7.7 13.7-14.2 17-19.5 3.2-4.9 4.9-10.7 4.9-16.6 0-12.9-6.9-19.3-20.8-19.3-12 0-23.6 4.8-34.6 14.4v-27.2c12.2-7.9 25.9-11.8 41.2-11.8 14.3 0 25.5 3.6 33.5 10.8s12.1 16.9 12.1 29.1q0 24.45-29.4 50.7zm82.1 21.6v-26.9c9.4 6.8 20.3 10.3 32.8 10.3 7.9 0 14-1.7 18.4-5.1s6.6-8.1 6.6-14.2c0-6.2-2.7-11.1-8.1-14.5s-12.9-5.1-22.4-5.1h-12.6v-23.6H353c18.2 0 27.4-6.1 27.4-18.2q0-17.1-21-17.1c-9.4 0-18.5 3-27.3 9.1V191c9.8-4.9 21.3-7.4 34.4-7.4 14.3 0 25.5 3.2 33.5 9.7 7.8 6 12.2 15.3 12 25.1 0 18.3-9.3 29.8-27.8 34.4v.5q14.85 1.8 23.4 10.8c5.7 5.9 8.8 13.8 8.6 21.9 0 13.1-4.8 23.4-14.4 31.1s-22.8 11.4-39.6 11.4c-14.7-.1-26.4-2.4-35.5-7.1" />',viewBox:"0 0 512 512"},parameterStringIcon:{name:"parameter-string",content:'<path d="M127.3 328.9c13.2 0 23.1-5.6 29.8-16.8h.4v14.4h29.2v-59.8c0-28.5-14.3-42.7-42.8-42.7-6.9.1-13.7.9-20.4 2.5-7.4 1.7-13.3 3.6-17.6 5.9v23.2c10.8-7.1 22.1-10.6 34-10.6s17.8 5.5 17.8 16.4l-27.2 3.6Q96 269.5 96 298.6c0 9.2 2.8 16.5 8.3 22s13.2 8.3 23 8.3m12.2-47.5 18.2-2.3v6.7c0 6.1-1.8 11.2-5.5 15.2-3.6 4-8.8 6.2-14.2 6-4.2 0-7.5-1.1-9.9-3.4-2.4-2.2-3.8-5.4-3.7-8.6 0-7.7 5-12.3 15.1-13.6m209 33.5c-9.5-9.3-14.3-21.3-14.3-36q0-25.5 15.3-40.2c10.2-9.8 23.8-14.7 40.9-14.7 11.8 0 20.3 1.6 25.6 4.7v26.2c-6.2-4.7-13.8-7.3-21.6-7.2q-13.35 0-21 7.8c-5.2 5.2-7.8 12.3-7.8 21.4 0 8.9 2.5 15.8 7.4 20.9 4.9 5 11.8 7.6 20.4 7.6 7.7 0 15.2-2.4 22.6-7.3v24.8c-7 4-17 6-30.2 6-15.3 0-27.8-4.7-37.3-14m-104 .5h.4q9.45 14.1 27.9 14.1c13.6 0 24.5-5 32.6-15.1s12.2-23.5 12.2-40.1q0-22.95-10.5-36.3c-10.5-13.35-16.9-13.3-29.8-13.3-14.1 0-24.9 5.8-32.5 17.5h-.4V179h-30.9v148h30.9zm-.5-42.2c0-7.4 2-13.4 6.1-18.1 3.8-4.5 9.5-7.1 15.4-6.9 6.6 0 11.6 2.3 15.2 7 3.5 4.7 5.3 11.1 5.3 19.4 0 10-1.9 17.7-5.8 23.1s-9.3 8.2-16.4 8.2c-5.5.1-10.7-2.2-14.3-6.4-3.7-4.2-5.6-9.6-5.6-16zM448 96H64c-17.7 0-32 14.3-32 32v256c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V128c0-17.7-14.3-32-32-32m0 288H64V128h384z" />',viewBox:"0 0 512 512"},parametersByteArrayIcon:{name:"parameters-byte-array",content:'<path d="M64 96c-17.7 0-32 14.3-32 32v256c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V128c0-17.7-14.3-32-32-32zm384 288H64V128h384zm-306.2-55.6c-33.3 0-50-23.4-50-70.2q0-36.45 13.5-55.5c13.5-19.05 22.1-19.1 39.2-19.1 32.6 0 48.8 23.8 48.8 71.4 0 23.7-4.4 41.9-13.3 54.5s-21.6 18.9-38.2 18.9m1.4-121.3c-13.3 0-20 16.8-20 50.3 0 31.6 6.5 47.4 19.6 47.4 12.8 0 19.1-16.3 19.1-48.8s-6.2-48.9-18.7-48.9m113.6 121.3c-33.3 0-50-23.4-50-70.2q0-36.45 13.5-55.5c13.5-19.05 22.1-19.1 39.2-19.1 32.6 0 48.8 23.8 48.8 71.4 0 23.7-4.4 41.9-13.3 54.5-8.8 12.6-21.6 18.9-38.2 18.9m1.4-121.3c-13.3 0-20 16.8-20 50.3 0 31.6 6.5 47.4 19.6 47.4 12.8 0 19.2-16.3 19.2-48.8s-6.3-48.8-18.8-48.9M420 326h-88v-24h29v-87.2l-30 6.4v-25.4l61-12.3V302h28z" />',viewBox:"0 0 512 512"},parametersIcon:{name:"parameters",content:'<path d="M96 32c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32zm320 416H96V64h320zM285.3 160c-8.9-25-36.3-38.1-61.4-29.2-13.7 4.8-24.4 15.6-29.2 29.2H128v32h66.7c8.9 25 36.3 38.1 61.4 29.2 13.7-4.8 24.4-15.6 29.2-29.2H384v-32zM240 192c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16m109.3 96c-8.9-25-36.3-38.1-61.4-29.2-13.7 4.8-24.4 15.6-29.2 29.2H128v32h130.7c8.9 25 36.3 38.1 61.4 29.2 13.7-4.8 24.4-15.6 29.2-29.2H384v-32zM304 320c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16" />',viewBox:"0 0 512 512"},parametersUnknownIcon:{name:"parameters-unknown",content:'<path d="M64 96c-17.7 0-32 14.3-32 32v256c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V128c0-17.7-14.3-32-32-32zm384 288H64V128h384zm-64-64h-64v-32h64zm-96 0h-64v-32h64zm-96 0h-64v-32h64z" />',viewBox:"0 0 512 512"},passwordIcon:{name:"password",content:'<path d="M480 64v384h-32V64zM174.2 221.1l-11.3-11.3-34.9 34.9V192H96v52.7l-34.9-34.9-11.3 11.3L84.7 256H32v32h52.7l-34.9 34.9 11.3 11.3L96 299.3V352h32v-52.7l34.9 34.9 11.3-11.3-34.9-34.9H192v-32h-52.7zm224 0-11.3-11.3-34.9 34.9V192h-32v52.7l-34.9-34.9-11.3 11.3 34.9 34.9H256v32h52.7l-34.9 34.9 11.3 11.3 34.9-34.9V352h32v-52.7l34.9 34.9 11.3-11.3-34.9-34.9H416v-32h-52.7z" />',viewBox:"0 0 512 512"},pauseIcon:{name:"pause",content:'<path d="M320 0h160v512H320zM32 512h160V0H32z" />',viewBox:"0 0 512 512"},pauseSmIcon:{name:"pause-sm",content:'<path d="M288 96h96v320h-96zM96 416h96V96H96z" />',viewBox:"0 0 512 512"},pencilIcon:{name:"pencil",content:'<path d="m334.9 86.6 45.3-45.3c12.4-12.4 32.8-12.4 45.3 0l45.3 45.3c12.4 12.4 12.4 32.8 0 45.3l-45.3 45.3zm-22.6 22.6L32 389.5V480h90.5l280.3-280.3zM99.9 412.1l-22.6-22.6 235-235 22.6 22.6z" />',viewBox:"0 0 512 512"},percentIcon:{name:"percent",content:'<path d="M352 64h32L160 448h-32zm16 160c-44.2 0-80 50.1-80 112s35.8 112 80 112 80-50.1 80-112-35.8-112-80-112m0 192c-22.7 0-48-32.9-48-80s25.3-80 48-80 48 32.9 48 80-25.3 80-48 80M144 64c-44.2 0-80 50.1-80 112s35.8 112 80 112 80-50.1 80-112-35.8-112-80-112m0 192c-22.7 0-48-32.9-48-80s25.3-80 48-80 48 32.9 48 80-25.3 80-48 80" />',viewBox:"0 0 512 512"},photosIcon:{name:"photos",content:'<path d="M256 288c0 17.7-14.3 32-32 32s-32-14.3-32-32 14.3-32 32-32 32 14.3 32 32m96-64v192c0 17.7-14.3 32-32 32H64c-17.7 0-32-14.3-32-32V224c0-17.7 14.3-32 32-32h256c17.7 0 32 14.3 32 32m-31.8 0q-.15-.15 0 0l-256.1-.1-.1.1v149.9l74.6-70 85.3 80 53.3-50 42.7 40zm63.8-96H128c-17.7 0-32 14.3-32 32h288v224c17.7 0 32-14.3 32-32V160c0-17.7-14.3-32-32-32m64-64H192c-17.7 0-32 14.3-32 32h288v224c17.7 0 32-14.3 32-32V96c0-17.7-14.3-32-32-32" />',viewBox:"0 0 512 512"},pinIcon:{name:"pin",content:'<path d="M320 256V96c0-17.6-14.4-32-32-32h-96c-17.6 0-32 14.4-32 32v160H96v32h128v160h32V288h128v-32zm-128 0V96h64v160z" />',viewBox:"0 0 512 512"},pinterestBoxIcon:{name:"pinterest-box",content:'<path d="M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32M276.6 327.3c-19.8 0-38.5-10.8-44.9-22.9 0 0-10.7 42.4-12.9 50.5-8 28.9-31.4 57.8-33.2 60.2-1.3 1.6-4.1 1.1-4.4-1.1-.5-3.7-6.5-40.1.5-69.9 3.5-14.9 23.6-100.2 23.6-100.2s-5.9-11.7-5.9-29.1c0-27.2 15.8-47.6 35.5-47.6 16.7 0 24.8 12.5 24.8 27.6 0 16.8-10.7 41.9-16.2 65.2-4.6 19.5 9.8 35.4 29 35.4 34.8 0 58.3-44.7 58.3-97.7 0-40.3-27.1-70.4-76.5-70.4-55.7 0-90.5 41.6-90.5 88 0 16 4.7 27.3 12.1 36.1 3.4 4 3.9 5.6 2.6 10.2-.9 3.4-2.9 11.5-3.7 14.8-1.2 4.6-5 6.3-9.2 4.6-25.6-10.4-37.6-38.5-37.6-70.2C128 158.6 172 96 259.4 96c70.2 0 116.4 50.8 116.4 105.3-.1 72.1-40.2 126-99.2 126" />',viewBox:"0 0 512 512"},pinterestIcon:{name:"pinterest",content:'<path d="M250.7 32C126.6 32 64 119.7 64 192.7c0 44.3 17 83.6 53.5 98.3 6 2.4 11.4.1 13.1-6.4 1.2-4.5 4.1-15.9 5.3-20.7 1.8-6.5 1.1-8.7-3.7-14.3-10.5-12.2-17.2-28.1-17.2-50.5 0-65.1 49.4-123.3 128.6-123.3 70.2 0 108.7 42.2 108.7 98.6 0 74.2-33.3 136.8-82.8 136.8-27.3 0-47.8-22.2-41.2-49.6 7.9-32.6 23.1-67.8 23.1-91.3 0-21.1-11.5-38.7-35.2-38.7-27.9 0-50.4 28.5-50.4 66.6 0 24.3 8.3 40.7 8.3 40.7s-28.6 119.3-33.6 140.2c-10 41.6-1.5 92.7-.8 97.8.5 3 4.4 3.7 6.2 1.5 2.6-3.3 35.9-43.8 47.2-84.2 3.2-11.4 18.4-70.8 18.4-70.8 9.1 17.1 35.6 32.1 63.8 32.1 84 0 141-75.4 141-176.4C416 103 350.3 32 250.7 32" />',viewBox:"0 0 512 512"},playIcon:{name:"play",content:'<path d="M0 512V0l512 256z" />',viewBox:"0 0 512 512"},playSmIcon:{name:"play-sm",content:'<path d="M96 416V96l320 160z" />',viewBox:"0 0 512 512"},playlistIcon:{name:"playlist",content:'<path d="M0 256h320v64H0zM512 64H0V0h512zm-128 64.8V397c-13.4-8-30-12.8-48-12.8-44.2 0-80 28.7-80 64s35.8 64 80 64 80-28.7 80-64V193h96v-65zM0 128v64h320v-64z" />',viewBox:"0 0 512 512"},plusCircleIcon:{name:"plus-circle",content:'<path d="M256 32C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32m32 256v96h-64v-96h-96v-64h96v-96h64v96h96v64z" />',viewBox:"0 0 512 512"},plusIcon:{name:"plus",content:'<path d="M288 224V96h-64v128H96v64h128v128h64V288h128v-64z" />',viewBox:"0 0 512 512"},plusOutlineIcon:{name:"plus-outline",content:'<path d="M288 288v96h-64v-96h-96v-64h96v-96h64v96h96v64zM256 32C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32m0 416c-106 0-192-86-192-192S150 64 256 64s192 86 192 192-86 192-192 192" />',viewBox:"0 0 512 512"},plusSmIcon:{name:"plus-sm",content:'<path d="M352 224v64h-64v64h-64v-64h-64v-64h64v-64h64v64z" />',viewBox:"0 0 512 512"},pointerIcon:{name:"pointer",content:'<path d="m285.5 326.1 43.9 124.4-83.5 29.5-43.8-124.2L128 416V32l256 288z" />',viewBox:"0 0 512 512"},positionBottomIcon:{name:"position-bottom",content:'<path d="M32 64v416h448V32H32zm416 0v384H64V64zM96 320h320v96H96z" />',viewBox:"0 0 512 512"},positionLeftIcon:{name:"position-left",content:'<path d="M448 32H32v448h448V32zm0 416H64V64h384zM96 96h96v320H96z" />',viewBox:"0 0 512 512"},positionRightIcon:{name:"position-right",content:'<path d="M64 480h416V32H32v448zm0-416h384v384H64zm256 32h96v320h-96z" />',viewBox:"0 0 512 512"},positionTopIcon:{name:"position-top",content:'<path d="M480 448V32H32v448h448zm-416 0V64h384v384zM96 96h320v96H96z" />',viewBox:"0 0 512 512"},printIcon:{name:"print",content:'<path d="M448 160h-32V96l-64-64H128c-17.7 0-32 14.3-32 32v96H64c-17.6 0-32 14.4-32 32v160c0 17.6 14.4 32 32 32h32v64c0 17.6 14.4 32 32 32h256c17.6 0 32-14.4 32-32v-64h32c17.6 0 32-14.4 32-32V192c0-17.6-14.4-32-32-32M128 64h192v64h64v64H128zm320 256h-64v127.9l-.1.1H128.1l-.1-.1V320H64v-32h384zm-288 0h192v32H160zm0 64h160v32H160z" />',viewBox:"0 0 512 512"},puzzlePieceIcon:{name:"puzzle-piece",content:'<path d="M480 352c0 1 0 2-.1 2.9v.8c0 .8-.1 1.7-.2 2.5v.5c-.1 1-.2 1.9-.4 2.8-.1.4-.1.9-.2 1.3s-.1.8-.2 1.2-.2.7-.2 1.1l-.6 2.7c-.1.4-.2.7-.3 1.1 0 .2-.1.5-.2.7-.2.5-.4 1.1-.5 1.7-.3.9-.6 1.8-.9 2.6 0 .1-.1.2-.1.3-.3.8-.6 1.6-.9 2.3-.1.2-.2.5-.3.7-.3.8-.7 1.5-1 2.3 0 .1-.1.2-.1.2-.4.8-.8 1.6-1.3 2.4l-.6 1.2c-.2.4-.4.7-.6 1.1-.2.3-.3.6-.5.8-.5.8-1 1.5-1.5 2.3l-.6.9c-.2.4-.5.7-.7 1s-.5.6-.7.9c-.5.7-1.1 1.4-1.7 2.1l-.3.3-1.5 1.8c-.2.2-.3.4-.5.5-.6.7-1.2 1.3-1.9 2-.6.6-1.3 1.3-2 1.9-.4.3-.7.7-1.1 1-.3.3-.7.6-1 .9-.2.1-.3.3-.5.4-.7.6-1.4 1.1-2.1 1.7-.3.3-.7.5-1 .8-.3.2-.6.5-1 .7l-.9.6c-.8.5-1.5 1-2.3 1.5-.2.1-.5.3-.7.4-.4.2-.7.4-1.1.6s-.8.5-1.3.7c-.8.4-1.6.9-2.4 1.3-.1.1-.2.1-.3.2-.3.2-.7.4-1 .5-.6.2-1.2.5-1.9.8-.8.3-1.6.6-2.3.9-.1 0-.2.1-.3.1-.9.3-1.7.6-2.6.9-.6.2-1.2.3-1.7.6-.2.1-.5.1-.7.2-.4.1-.7.2-1.1.3l-2.7.6c-.3.1-.5.1-.8.2-.5.1-1.1.2-1.7.3-.4.1-.8.1-1.2.2-.9.1-1.9.3-2.8.4-.2 0-.5 0-.7.1-.4.1-.9.1-1.3.1-.6 0-1.1.1-1.7.1-1 0-2 .1-2.9.1-1.2 0-2.3 0-3.5-.1-.4 0-.7-.1-1.1-.1-.8-.1-1.6-.1-2.3-.2-.4 0-.9-.1-1.3-.2l-2.1-.3c-.4-.1-.9-.2-1.3-.2-.7-.1-1.4-.3-2-.4-.4-.1-.9-.2-1.3-.3-.7-.2-1.4-.3-2-.5l-1.2-.3c-.7-.2-1.4-.4-2.1-.7-.4-.1-.7-.2-1.1-.4-.8-.3-1.5-.6-2.3-.9-.3-.1-.5-.2-.8-.3-1-.4-1.9-.8-2.8-1.2-.1 0-.1-.1-.2-.1-3.1-1.5-6-3.2-8.8-5.1-.1 0-.1-.1-.2-.2-.8-.6-1.7-1.2-2.5-1.8-.1-.1-.2-.2-.3-.2-.8-.6-1.6-1.2-2.3-1.9-.3-.2-.6-.5-.8-.7-.5-.4-1-.8-1.4-1.3l-.5-.5c-.8-.8-1.6-1.5-2.3-2.3l-1.5-1.5c-.3-.3-.5-.6-.7-.9-.1-.2-.2-.3-.4-.5-4.9-5.7-12-8.9-19.5-8.9h-1.4c-14.3 0-25.9 11.6-25.9 25.9v70H217.9c-14.3 0-25.9-11.6-25.9-25.9v-1.4c0-7.5 3.3-14.6 8.9-19.5 15-12.5 24.2-31.6 23-52.9-1.8-32.5-28.3-58.7-60.9-60.2-36.7-1.7-67 27.6-67 63.9 0 19.6 8.8 37.1 22.6 48.8 5.9 5 9.4 12.2 9.4 19.9v1.4c0 14.3-11.6 25.9-25.9 25.9H32V192h70.1c14.3 0 25.9-11.6 25.9-25.9v-1.4c0-7.5-3.3-14.6-8.9-19.5l-.3-.3c-.7-.5-1.4-1.1-2-1.7l-.6-.6c-.8-.8-1.6-1.5-2.3-2.3l-.2-.2c-.7-.7-1.4-1.5-2.1-2.3-.1-.1-.2-.2-.2-.3-.7-.8-1.3-1.5-1.9-2.3-.1-.1-.2-.2-.2-.3-.6-.8-1.2-1.6-1.8-2.5l-.2-.2c-1.9-2.8-3.6-5.7-5.1-8.8 0-.1-.1-.1-.1-.2-.4-.9-.9-1.9-1.2-2.8-.1-.3-.2-.5-.3-.8-.3-.8-.6-1.5-.9-2.3-.1-.3-.2-.7-.4-1.1-.2-.7-.5-1.4-.7-2.1l-.3-1.2c-.2-.7-.4-1.4-.5-2-.1-.4-.2-.9-.3-1.3-.1-.7-.3-1.4-.4-2-.1-.4-.2-.9-.2-1.3l-.3-2.1c-.1-.4-.1-.9-.2-1.3-.1-.8-.1-1.6-.2-2.3 0-.4-.1-.7-.1-1.1-.1-1.2-.1-2.3-.1-3.5 0-1 0-2 .1-2.9 0-.4 0-.9.1-1.3 0-.7.1-1.4.2-2v-.4c.1-.9.2-1.9.4-2.8 0-.2.1-.4.1-.7.1-.8.3-1.6.4-2.4 0-.2.1-.4.1-.5l.6-2.7c0-.1.1-.3.1-.4.2-.7.4-1.4.6-2.2l.3-.9c.3-.9.6-1.8.9-2.6 0-.1.1-.2.1-.3.3-.8.6-1.6.9-2.3.1-.2.2-.5.3-.7.3-.8.7-1.5 1-2.3 0-.1.1-.2.1-.3.4-.8.8-1.6 1.3-2.4l.3-.6c.4-.7.7-1.3 1.1-1.9.1-.2.2-.3.3-.5.5-.8 1-1.5 1.5-2.3.1-.1.2-.3.3-.4.4-.6.9-1.2 1.3-1.8.1-.2.3-.4.4-.6.5-.7 1.1-1.4 1.7-2.1l.3-.3 1.5-1.8c.2-.2.3-.4.5-.5.6-.7 1.2-1.3 1.9-2 .6-.6 1.3-1.3 2-1.9.2-.2.4-.3.5-.5l1.8-1.5.3-.3c.7-.6 1.4-1.1 2.1-1.7.2-.1.3-.3.5-.4.6-.5 1.3-.9 1.9-1.3.2-.1.3-.2.5-.3.8-.5 1.5-1 2.3-1.5.1-.1.3-.2.4-.2.6-.4 1.3-.8 1.9-1.1.2-.1.5-.3.7-.4.8-.4 1.6-.9 2.4-1.3.1 0 .2-.1.2-.1.8-.4 1.5-.7 2.3-1 .2-.1.5-.2.7-.3.8-.3 1.5-.6 2.3-.9.1 0 .2-.1.3-.1.9-.3 1.7-.6 2.6-.9.3-.1.6-.2.8-.3.7-.2 1.4-.4 2.2-.6.2 0 .3-.1.5-.1l2.7-.6c.2 0 .4-.1.6-.1.8-.2 1.6-.3 2.3-.4.2 0 .5-.1.7-.1.9-.1 1.9-.3 2.8-.4.2 0 .4 0 .5-.1.8-.1 1.6-.1 2.5-.2h.7c1 0 1.9-.1 2.9-.1s2 0 3 .1h.7c.9.1 1.8.1 2.7.2h.2c30 3.1 53.9 26.9 57.1 57 0 .3.1.7.1 1 .1.7.1 1.4.2 2.1 0 .5 0 .9.1 1.4v5c0 .5-.1 1-.1 1.4 0 .6-.1 1.2-.1 1.7s-.1 1-.2 1.5c-.1.6-.1 1.1-.2 1.7-.1.5-.1 1-.2 1.5s-.2 1.1-.3 1.6l-.3 1.5c-.1.5-.2 1-.4 1.5-.1.5-.2 1-.4 1.5-.1.5-.3.9-.4 1.4-.2.5-.3 1-.5 1.5-.1.4-.3.9-.4 1.3-.2.5-.4 1.1-.6 1.6-.1.4-.3.8-.5 1.2-.2.6-.4 1.1-.7 1.7-.1.3-.3.7-.4 1-.3.6-.5 1.2-.8 1.8-.1.2-.2.5-.4.7-.3.7-.7 1.3-1 2 0 .1-.1.2-.1.2-3.8 6.7-8.7 12.7-14.5 17.7h-.1c-5.8 5-9.4 12.2-9.4 19.9v1.4c0 14.3 11.6 25.9 25.9 25.9H320v116.7c0 6.3 5.1 11.3 11.3 11.3H357c5.2 0 9.1-4.1 10-9.2 0-.1.1-.1.1-.2 5-5.8 10.9-10.8 17.7-14.5.1 0 .2-.1.2-.1.7-.4 1.3-.7 2-1 .2-.1.5-.2.7-.4.6-.3 1.2-.6 1.8-.8.3-.1.7-.3 1-.4.6-.2 1.1-.5 1.7-.7.4-.2.8-.3 1.2-.5.5-.2 1.1-.4 1.6-.6.4-.2.9-.3 1.3-.4.5-.2 1-.3 1.5-.5.5-.1.9-.3 1.4-.4s1-.3 1.5-.4 1-.2 1.5-.4l1.5-.3c.5-.1 1.1-.2 1.6-.3s1-.2 1.5-.2c.6-.1 1.1-.1 1.7-.2.5-.1 1-.1 1.5-.2.6-.1 1.1-.1 1.7-.1.5 0 1-.1 1.4-.1h5c.5 0 .9 0 1.4.1.7 0 1.4.1 2.1.2.3 0 .7.1 1 .1 30 3.1 53.9 27 57 57.1v.2c.1.9.2 1.8.2 2.7v.7c.2.4.2 1.4.2 2.4" />',viewBox:"0 0 512 512"},qrCodeIcon:{name:"qr-code",content:'<path d="M320 0v192h192V0zm160 160H352V32h128zm-32-32h-64V64h64zM0 0v192h192V0zm160 160H32V32h128zm-32-32H64V64h64zM0 320v192h192V320zm160 160H32V352h128zm-32-32H64v-64h64zm32-224h32v32h-32zm0 64h-32v-32h32zm-64-64h32v32H96zm-32 32H32v-32h32zm32 32H64v-32h32zm128 0h-32v-32h32zm32-32h-32v-32h32zm0-64h32v32h-32zm0 0h-32v-32h32zm0-64h32v32h-32zm0 0h-32V96h32zm0-64h32v32h-32zm0 0h-32V32h32zm64 192h-32v-32h32zm-96 32h32v32h-32zm64 0h-32v-32h32zm0 64h-32v-32h32zm-32 32h-32v-32h32zm0 0h32v32h-32zm0 64h-32v-32h32zm64-64h-32v-32h32zm0-64h-32v-32h32zm0-64h32v32h-32zm64 0h-32v-32h32zm32 32h-32v-32h32zm32-32h-32v-32h32zm-96 32h32v32h-32zm0 64h-32v-32h32zm0 0h32v32h-32zm32-32h32v32h-32zm32-32h32v32h-32zm-96 96h32v32h-32zm0 64h-32v-32h32zm-32 32h-32v-32h32zm192-192h-32v-32h32zM352 416h32v32h-32zm0 64h-32v-32h32zm64-64h-32v-32h32zm32-96h32v32h-32zm0 64h-32v-32h32zm-32 32h32v32h-32zm0 64h-32v-32h32zm64-64h-32v-32h32zm0 64h-32v-32h32zm32-32h-32v-32h32zm0-64h-32v-32h32zm0-64h-32v-32h32zm0-64h-32v-32h32zM256 512h-32v-32h32zm64 0h-32v-32h32zm32-32h32v32h-32zm64 0h32v32h-32zm96 32h-32v-32h32z" />',viewBox:"0 0 512 512"},qrCodeOutlineIcon:{name:"qr-code-outline",content:'<path d="M192 224v32h-32v-32zm-64 64h32v-32h-32zm-32-64v32h32v-32zm-32 64h32v-32H64zm128 0h32v-32h-32zm64-64h-32v32h32zm32-32h-32v32h32zm-64-32v32h32v-32zm64-32h-32v32h32zm-64-32v32h32V96zm64-32h-32v32h32zm32 192v-32h-32v32zm-96 32v32h32v-32zm64-32h-32v32h32zm0 64h-32v32h32zm-64 32v32h32v-32zm32 32v32h32v-32zm-32 64h32v-32h-32zm64-96v32h32v-32zm32-32v-32h-32v32zm32-32v-32h-32v32zm32-64h-32v32h32zm32 64v-32h-32v32zm32-64h-32v32h32zm-64 96v-32h-32v32zm-32 32v-32h-32v32zm0 32h32v-32h-32zm32-32h32v-32h-32zm64-32v-32h-32v32zm-128 64v32h32v-32zm-32 64h32v-32h-32zm64 0h32v-32h-32zm32-32h32v-32h-32zm64-32v-32h-32v32zm0 64v-32h-32v32zM512 0v512H0V0zm-32 32H32v448h448zm-32 160H320V64h128zm-32-32-.5-64H352v64zm-224 32H64V64h128zm-32-32-.5-64H96v64zm32 288H64V320h128zm-32-32-.5-64H96v64z" />',viewBox:"0 0 512 512"},qrCodeScannerIcon:{name:"qr-code-scanner",content:'<path d="M512 0v96h-32V32h-64V0zm-32 448h-64v32h96v-96h-32zM64 64h128v128H64zm32 96h64V96H96zM32 32h64V0H0v96h32zm0 224h448v-32H32zm0 128H0v96h96v-32H32zM288 96h-32v32h32zm-64-32v32h32V64zm224 128H320V64h128zm-32-96h-64v64h64zm-128 96v-32h-32v32zm-32-64h-32v32h32zM64 288h128v128H64zm32 96h64v-64H96zm192-64h-32v32h32zm-64-32v32h32v-32zm32 128h32v-32h-32zm-32-64v32h32v-32zm96-64h-32v32h32zm-32 64v32h32v-32zm64 0v-32h-32v32zm-32 64h32v-32h-32zm64-128h-32v32h32zm-32 64v32h32v-32zm64 0v-32h-32v32zm0 64v-32h-32v32zm32-128h-32v32h32zm0 96v-32h-32v32z" />',viewBox:"0 0 512 512"},questionCircleIcon:{name:"question-circle",content:'<path d="M352 192c0 45.2-23.4 65.9-40.6 81-15.1 13.3-23.4 20.7-23.4 47h-64c0-55.2 27.1-79.2 45.1-95 13.8-12.1 18.9-16.7 18.9-33 0-17.6-14.4-32-32-32s-32 14.4-32 32h-64c0-53 43-96 96-96s96 43 96 96M224 416h64v-64h-64zm256-160c0 123.7-100.3 224-224 224S32 379.7 32 256 132.3 32 256 32s224 100.3 224 224m-32 0c0-106-86-192-192-192S64 150 64 256s86 192 192 192 192-86 192-192" />',viewBox:"0 0 512 512"},radiobuttonCheckedIcon:{name:"radiobutton-checked",content:'<path d="M351.6 255.3c0 53.2-43.1 96.4-96.4 96.4s-96.4-43.1-96.4-96.4 43.1-96.4 96.4-96.4 96.4 43.2 96.4 96.4M256 64C150 64 64 150 64 256s86 192 192 192 192-86 192-192S362 64 256 64m0 352c-88.4 0-160-71.6-160-160S167.6 96 256 96s160 71.6 160 160-71.6 160-160 160" />',viewBox:"0 0 512 512"},radiobuttonIcon:{name:"radiobutton",content:'<path d="M256 64C150 64 64 150 64 256s86 192 192 192 192-86 192-192S362 64 256 64m0 352c-88.4 0-160-71.6-160-160S167.6 96 256 96s160 71.6 160 160-71.6 160-160 160" />',viewBox:"0 0 512 512"},redditBoxIcon:{name:"reddit-box",content:'<path d="M111.1 244.9c-5.2 6.1-9.6 12.7-13.2 19.9-2.1-1.5-3.9-3.6-5.5-6.5-2.3-2.6-3.4-5.9-3.4-9.8v-1.4c.5-5.8 3-10.8 7.7-15.1 5.3-4 10.9-6.3 16.8-7h2.4c2.4 0 4.6.3 6.6 1 2 .6 4.1 1.3 6.3 1.9a124.3 124.3 0 0 0-17.7 17m252.1-94.3c4.4 3.7 9.1 5.4 14.4 5.4h1.4c5.3 0 10-1.8 14.2-5.4 4-3.7 6.3-8 6.9-13.1v-1q0-8.25-6.9-13.8c-3.8-3.8-8.3-5.6-13.6-5.7h-1.1c-2.2 0-4.1.1-5.5.5-4.6.9-8.4 3.2-11.2 6.6-3.3 3.4-4.8 7.4-4.8 12.4v1c0 5.1 2 9.5 6.2 13.1M394.5 279c2.3 6.1 3.5 12.4 3.5 19v5.7c0 1.8-.3 3.4-1 5-2.1 9.3-6.4 18-13 26.2-5.6 7.5-12.8 14.4-21.6 20.6-13.1 8.8-27.3 15.5-42.7 20.2s-31 7.6-47 8.9c-2.7.4-5.5.5-8.1.5h-8.1c-16 0-31.8-1.6-47.4-4.9s-30.2-8.5-44-15.7l-3.4-1.9-3.6-1.7c-9.8-6.2-18.3-13.1-25.8-20.6-7.7-8.6-12.9-18-15.8-28.1-1.3-3.9-1.9-8.4-1.9-13.7 0-13.6 4.2-25.7 12.7-36.3 8.3-10.6 18.3-19.3 30.1-26.4 11.8-7 24.2-12.4 37.3-16.1 19.6-5.7 40.2-8.7 61.8-8.7h.1q11.25 0 23.1 1.2c11.85 1.2 15.6 2 23.1 3.6l7.4 1.9 7.7 1.9c13.1 3.7 25.6 9 37.4 15.8 11.9 6.9 21.8 15.6 30 26.2 3.8 5.6 6.9 11.4 9.2 17.4m-205.9 21.9c2.3.9 4.7 1.4 7.5 1.4 6.3 0 12-2.1 16.9-6.3 5.3-4.3 8-9.7 8-15.9v-1.5c0-5.9-2.5-11-7.5-15.2-5.3-4.3-11.2-6.6-17.4-6.6-1.9 0-3.5.1-4.7.5-4.3.6-8.2 2.3-11.5 5.2-3.3 2.8-5.5 6.3-6.9 10.3-.7.9-1 2-1 3.1v3.1c0 5.3 1.4 10 4.3 14 3.3 4 7.3 6.7 12.3 7.9m139.5 38.2c0-1-.3-2.4-1-4.3-1-2.4-2.6-4.1-4.7-4.9-2.5-1.3-4.6-1.9-6.4-1.9-1.9 0-4 .5-5.9 1.5-17.2 9.6-36 14.5-56.2 14.7-15.1 0-29.3-3-42.2-8.8-1.9-.6-4.2-2.2-6.8-4.6-.6-.3-1.3-.6-2.1-1s-1.6-.6-2.4-1c-1.9-.6-3.4-1-4.3-1v.1c-.9 0-2.4.4-4.3 1h-.5c-1.9.6-3.7 2-5.4 4.3-.9 1.6-1.4 3.6-1.4 5.9 0 1.9.5 3.9 1.4 5.9 1 1.6 2.4 2.9 4.3 3.8 18.2 11.4 38.1 17.1 59.8 17.1h3.6c10.5 0 20.6-1 30.4-3s19.3-5.1 28.5-9.4c1.2-.6 2.6-1.3 4.1-1.9 1.4-.6 3-1.4 4.5-2.4 1.6-.7 3-1.6 4.1-2.9 1.6-1.6 2.5-3.3 2.9-5-.2-.4 0-1.2 0-2.2m12.2-59.2q0-3.3-1.5-7.2c-1.2-4.6-4.2-8.4-8.8-11.5q-6.75-3.9-14.1-3.9c-2.7 0-5.5.5-8.4 1.4-4.6 1.6-8.4 4.4-11.3 8.4-3 3.5-4.6 7.8-4.6 12.7 0 1.8.2 3.1.4 4.1v.5c1 5.6 3.8 9.8 8.4 12.7 4.6 3.5 9.9 5.3 15.8 5.3 1.9 0 4.1-.5 6.7-1.4h.7c4.2-.8 8.2-3.4 12.2-7.7 3-3.9 4.5-8.4 4.5-13.4M480 64v384c0 17.6-14.4 32-32 32H64c-17.6 0-32-14.4-32-32V64c0-17.6 14.4-32 32-32h384c17.6 0 32 14.4 32 32m-32.3 181c-.9-10.3-5.2-19.1-12.4-26.6-7.4-7.6-16.2-12.7-26-15.4h-.1c-4.5-1-8.7-1.4-12.7-1.4-10.6-.2-19.8 2.4-28 7.7-1.7.8-3.9 2.1-6.5 4.1-.6-.6-1.3-1-1.9-1l-.5-.5c-13.7-7.2-28-12.7-43.1-16.3-15.1-3.7-30.4-6-46.1-7 0-5.8.5-25.5 1.4-31.3s2.8-11.1 5.6-16.1c3.6-7.2 10.1-11.3 19.1-12.3h4.3c5.6 0 11 .8 16.3 2.3s10.6 3.2 15.9 5.2v1.5c0 5.6 1.1 10.8 3.4 15.3 2.2 4.5 5.2 8.7 8.8 12.5 7.7 7.8 17.1 12.3 28.4 13.3h5.5c11.2 0 21.1-3.6 30.1-10.9 4-3.3 7.3-7.2 9.8-11.7 2.6-4.4 4.2-9.4 4.8-15.1.3-1 .5-2.4.5-4.3.2-8.3-2.4-16.2-7.7-23.4-5.3-6.9-11.9-11.9-19.7-14.7h-.5c-4.9-2.3-10.7-3.4-17.3-3.4q-8.1 0-17.1 2.4h-.4c-9.7 3.8-17.1 9.7-22.5 17.6-13.3-5.4-26.5-8-39.5-8-4.9 0-9.9.5-14.9 1.4h.9c-6.6 1.6-12.4 4.4-17.5 8.3s-9.3 8.7-12.5 14.3c-4 6.5-6.6 23.5-7.9 30.9-1.3 7.3-1.9 18.7-1.9 26-15.7 1.1-31.3 3.4-47.2 6.8-15.7 3.5-30.4 8.9-44.2 16.4-1 .3-1.8.7-2.6 1s-1.5.6-2.2 1c-4.7-3.4-9.7-6-15.4-7.9-5.9-1.9-12.1-2.9-18.6-2.9h-4.3c-6.5 0-12.6 1.2-18.1 3.6s-10.6 5.8-15.2 10.1c-4.3 4.3-7.8 9.2-10.4 14.5-2.7 5.4-3.9 11-3.9 16.9.3 8.1 3.3 16 8.9 23.5 4.3 6.2 10.4 11.5 18.2 15.8-.4 1.6-.6 3.3-.7 5.1s-.2 3.6-.2 5.2c0 7.5 1.1 15 3.4 22.6 2.3 7.5 5.5 14.6 9.8 21.1 8.1 12.5 18.4 22.9 30.7 31.2s25.3 15.1 39.1 20.4q19.65 7.5 40.5 11.1c13.9 2.5 28.1 3.7 42.4 3.7 9.4 0 18.8-.6 28.1-1.8 9.4-1.2 18.8-2.8 28.2-4.7 17.4-4.1 34.1-10.4 50.2-18.8s29.5-19.5 40.8-33.2c12.8-15.4 19.2-32.6 19.2-51.7 0-1.9-.1-3.8-.3-5.6s-.4-3.6-.7-5.1c7.5-3.7 13.7-8.9 18.7-15.8 5.3-7.2 7.9-15.2 7.9-24V245zm-37.1-17q-7.05-3.3-14.1-3.3c-4.6 0-8.9.9-12.9 2.9 6.5 5.3 12.5 10.9 17.7 17q7.95 9.15 13.2 20.4 3.3-2.85 6-6.9c1.9-3.2 2.9-6.8 2.9-10.8 0-2.9-.9-6-2.4-9.4-2.3-4-5.8-7.3-10.4-9.9" />',viewBox:"0 0 512 512"},redditIcon:{name:"reddit",content:'<path d="M420.3 33c-7 0-14.5 1-22.4 3h-1.7c-12.4 4.8-21.9 12.3-28.8 22.5-17-7-34-10.4-50.7-10.4-6.3 0-12.6.6-19.1 1.9H296c-8.8 2.1-16.5 5.8-23.3 11s-12.4 11.6-16.6 19.1c-5.3 8.7-8.9 31.3-10.5 41.1-1.7 9.8-2.6 25-2.6 34.7-20.9 1.5-41.8 4.5-62.8 9.1s-40.6 11.9-59 21.9c-1.3.4-2.5.9-3.5 1.3s-2 .9-2.9 1.3c-6.2-4.5-13-8-20.5-10.6Q82.6 175 69.4 175h-5.8c-8.7 0-16.7 1.6-24.1 4.8s-14.1 7.7-20.3 13.4c-5.8 5.8-10.3 12.2-13.9 19.4-3.6 7.3-5.3 14.8-5.3 22.7.4 10.8 4.4 21.3 11.8 31.4 5.7 8.3 13.8 15.4 24.3 21.1-.5 2.1-.7 4.4-1 6.8q-.3 3.75-.3 6.9c0 10 1.5 20 4.5 30.1s7.4 19.4 13.1 28.1c10.9 16.6 24.5 30.5 40.9 41.6 16.4 11 33.8 20.2 52.1 27.2 17.5 6.6 35.5 11.6 54 14.8 18.6 3.3 37.4 5 56.6 5 12.5 0 25.1-.8 37.5-2.4 12.5-1.6 25-3.7 37.6-6.3 23.2-5.5 45.5-13.9 66.8-25.1s39.4-26 54.3-44.3c17.1-20.5 25.6-43.4 25.6-68.8 0-2.6-.1-5.1-.4-7.5s-.5-4.7-.9-6.8c10-4.9 18.3-11.9 24.9-21.1 7.1-9.6 10.6-20.3 10.6-32v-3c-1.2-13.4-6.8-25.1-16.3-34.9q-14.7-15-34.2-20.1h-.6c-6-1.3-11.6-1.9-16.9-1.9-14.1-.2-26.6 3.2-37.4 10.2-2.3 1.1-5.2 2.8-8.6 5.4-.8-.9-1.8-1.3-2.6-1.3l-.7-.6c-18.2-9.6-37.5-16.9-57.7-21.8-20.1-4.9-40.6-8-61.6-9.3 0-7.7.7-34.2 1.8-41.9s3.7-14.8 7.5-21.4c4.9-9.6 13.4-15.1 25.6-16.4h5.8c7.4 0 14.7 1.1 21.7 3 7.1 2 14.1 4.3 21.2 6.9v1.9c0 7.5 1.5 14.2 4.5 20.3 2.9 6 6.9 11.6 11.8 16.5 10.3 10.4 22.8 16.3 37.7 17.5h7.3c14.9 0 28.1-4.8 39.8-14.4 5.3-4.4 9.7-9.6 13.1-15.5s5.5-12.5 6.4-20c.4-1.3.6-3.2.6-5.8.2-11-3.3-21.4-10.3-30.9-7.1-9.2-15.8-15.7-26.2-19.5h-.5c-6.5-2.7-14.1-4.1-22.9-4m1.2 27.4c7.2.1 13.2 2.7 18.3 7.7C446 73 449 79.2 449 86.7V88c-.8 6.8-3.9 12.7-9.3 17.6-5.5 4.9-11.9 7.4-19.1 7.4h-1.9c-7.1 0-13.4-2.5-19.4-7.4-5.5-4.7-8.3-10.6-8.3-17.6v-1.3c0-6.6 2.1-12.1 6.5-16.6 3.8-4.7 8.9-7.7 15.1-8.9 2-.4 4.4-.6 7.5-.6.4-.2.9-.2 1.4-.2m-165 125.7c10 0 20.3.5 30.8 1.6 10.6 1.1 20.9 2.7 30.8 4.8l9.9 2.6 10.2 2.6c17.5 4.9 34.1 11.9 49.9 21.1s29 20.8 40 34.9c5.1 7.3 9.2 14.9 12.3 23s4.6 16.5 4.6 25.3v7.6c0 2.3-.4 4.6-1.3 6.7-2.8 12.4-8.5 24-17.3 34.9-7.4 10-17 19.2-28.8 27.5-17.5 11.7-36.4 20.7-56.9 26.9-20.4 6.2-41.3 10.1-62.7 11.8-3.6.5-7.3.6-10.8.6h-10.8c-21.3 0-42.4-2.2-63.1-6.6-20.8-4.4-40.3-11.4-58.6-21l-4.5-2.6-4.8-2.2c-13-8.3-24.4-17.5-34.5-27.5-10.2-11.5-17.2-24-21.1-37.4-1.7-5.2-2.6-11.2-2.6-18.2 0-18.1 5.6-34.2 16.9-48.3 11-14.1 24.4-25.8 40.1-35.2s32.2-16.5 49.7-21.4c26.2-7.7 53.7-11.6 82.6-11.5M65.7 204h3.2c3.2 0 6.1.4 8.8 1.3 2.6.9 5.4 1.7 8.4 2.6-8.7 7-16.5 14.6-23.5 22.7-6.9 8.1-12.8 17-17.7 26.6-2.8-2-5.2-4.8-7.4-8.6-3-3.5-4.5-7.8-4.5-13.1v-2.1c.7-7.7 4-14.4 10.3-20.2 7.1-5.3 14.6-8.3 22.4-9.2m377.6-.4c6.4 0 12.7 1.5 18.9 4.4 6.1 3.5 10.8 7.8 13.7 13.2 2.1 4.5 3.2 8.6 3.2 12.5 0 5.3-1.2 10.1-3.8 14.4-2.4 3.6-5 6.7-8 9.2-4.7-10-10.6-19.1-17.6-27.2s-14.9-15.6-23.6-22.7c5.3-2.6 11-3.8 17.2-3.8m-107.6 43.2c-3.6 0-7.4.7-11.2 1.9-6.2 2.2-11.2 5.9-15 11.2-4 4.7-6.1 10.3-6.1 16.9 0 2.4.2 4.2.6 5.5v.6c1.3 7.5 5.1 13.1 11.2 17 6.2 4.7 13.2 7 21.1 7 2.5 0 5.5-.6 9-1.9h.9c5.6-1.1 11-4.5 16.3-10.2 3.8-5.3 5.8-11.4 5.8-18 0-3-.6-6.2-2-9.6-1.6-6.2-5.6-11.3-11.8-15.3-5.9-3.3-12.2-5.1-18.8-5.1m-158.8-.1c-2.6 0-4.7.2-6.3.7-5.8.9-10.8 3.1-15.2 6.9-4.4 3.7-7.4 8.3-9.1 13.6-.9 1.2-1.3 2.7-1.3 4.1v4.2c0 7 1.9 13.2 5.8 18.6 4.2 5.1 9.6 8.5 16.3 10.2 3 1.2 6.3 1.9 9.9 1.9 8.3 0 15.8-2.8 22.4-8.3 7.1-5.7 10.6-12.8 10.6-21.1v-2q0-11.85-9.9-20.1c-7.2-5.8-14.9-8.7-23.2-8.7m-1.6 94c-1.2 0-3.2.5-5.7 1.3h-.8c-2.6.8-5 2.7-7.3 5.7-1.2 2.1-1.9 4.8-1.9 8 0 2.6.6 5.2 1.9 8 1.3 2.2 3.2 3.9 5.8 5.1q36.75 23.1 80.7 23.1h4.8c14.1 0 27.8-1.3 41-4s26.1-6.9 38.5-12.6c1.7-.9 3.5-1.7 5.4-2.6 1.9-.8 3.9-1.9 6-3.2 2.2-.9 4-2.1 5.5-3.8 2.1-2.1 3.3-4.4 3.8-6.8.4-.8.7-1.9.7-3.2s-.4-3.2-1.3-5.8c-1.3-3.2-3.5-5.4-6.4-6.7-3.3-1.7-6.2-2.6-8.6-2.6-2.5 0-5.3.6-8 2-23.2 13-48.6 19.6-76 19.8-20.4 0-39.5-3.9-57-11.8-2.5-.9-5.7-2.9-9.2-6.1-.9-.4-1.8-.8-2.8-1.3s-2.2-.9-3.3-1.3c-2.7-.8-4.6-1.3-5.8-1.2" />',viewBox:"0 0 512 512"},redoIcon:{name:"redo",content:'<path d="M256 192V64l224 192-224 192V320c-87.2 0-166.2 39.4-223.9 96C34.5 294.4 133.9 192 256 192" />',viewBox:"0 0 512 512"},regularExpressionIcon:{name:"regular-expression",content:'<path d="M442.6 299.7 352 247.4V352h-64V247.4l-90.6 52.3-32-55.4L256 192l-90.6-52.3 32-55.4 90.6 52.3V32h64v104.6l90.6-52.3 32 55.4L384 192l90.6 52.3zM80 384c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48" />',viewBox:"0 0 512 512"},removeHorizontalSpacingIcon:{name:"remove-horizontal-spacing",content:'<path d="M480 96v160h-96v-64h-96v160h-96V192H96v96H32V64h64v96h96V0h96v160h96V96zm-32.5 278.2-22.6-22.6-57.4 57.4-57.4-57.4-22.6 22.6 57.4 57.4-57.4 57.4 22.6 22.6 57.4-57.4 57.4 57.4 22.6-22.6-57.4-57.4zm-256 0-22.6-22.6-57.4 57.4-57.4-57.4-22.6 22.6 57.4 57.4L31.5 489l22.6 22.6 57.4-57.4 57.4 57.4 22.6-22.6-57.4-57.4z" />',viewBox:"0 0 512 512"},removeVerticalSpacingIcon:{name:"remove-vertical-spacing",content:'<path d="M192 320v96h96v64H64v-64h96v-96H0v-96h160v-96H96V32h160v96h-64v96h160v96zm320 22.6L489.4 320 432 377.4 374.6 320 352 342.6l57.4 57.4-57.4 57.4 22.6 22.6 57.4-57.4 57.4 57.4 22.6-22.6-57.4-57.4zm0-288L489.4 32 432 89.4 374.6 32 352 54.6l57.4 57.4-57.4 57.4 22.6 22.6 57.4-57.4 57.4 57.4 22.6-22.6-57.4-57.4z" />',viewBox:"0 0 512 512"},reorderIcon:{name:"reorder",content:'<path d="M480 128v64H32v-64zM32 224v64h448v-64zm448 96H32v64h448z" />',viewBox:"0 0 512 512"},replaceAllIcon:{name:"replace-all",content:'<path d="M288 288h192v192H288zm64-64H224V32h128zM320 64h-64v128h64zM160 352H96V160h96V96H96c-35.3 0-64 28.7-64 64v192c0 35.3 28.7 64 64 64h64v64l96-96-96-96zM448 32v192h32V32zm-32 0h-32v192h32z" />',viewBox:"0 0 512 512"},replaceSingleIcon:{name:"replace-single",content:'<path d="M288 288h192v192H288zM32 160v192c0 35.3 28.7 64 64 64h64v64l96-96-96-96v64H96V160h160V96H96c-35.3 0-64 28.7-64 64M480 32v192H288V32zm-32 32H320v128h128z" />',viewBox:"0 0 512 512"},reportElementIcon:{name:"report-element",content:'<path d="M480 320V192H160v48H96v-80h256V32H32v128h32v320h32v-48h64v48h256V352H160v48H96V272h64v48ZM64 64h256v64H64Zm128 320h192v64H192z" />',viewBox:"0 0 512 512"},rewindIcon:{name:"rewind",content:'<path d="M256 256 512 96v320zm0 160V96L0 256z" />',viewBox:"0 0 512 512"},rightDoubleQuotesIcon:{name:"right-double-quotes",content:'<path d="M136 100.2c-57.4 0-104 46.6-104 104s46.6 104 104 104c20.1 0 38.9-5.7 54.8-15.6-14.2 30.5-37.4 55.2-69.2 73.7-44 25.6-89.1 29.6-89.6 29.6l1.3 15.9 1.3 15.9c2.1-.2 51.8-4.4 102-33.2 47.1-27 103.3-81.3 103.3-186.1.1-1.4.1-2.8.1-4.3 0-57.3-46.6-103.9-104-103.9m344 104c0-57.4-46.6-104-104-104s-104 46.6-104 104 46.6 104 104 104c20.1 0 38.9-5.7 54.8-15.6-14.2 30.5-37.4 55.2-69.2 73.7-44 25.6-89.1 29.6-89.6 29.6l2.6 31.9c2.1-.2 51.8-4.4 102-33.2 47.1-27 103.3-81.3 103.3-186.1.1-1.4.1-2.8.1-4.3" />',viewBox:"0 0 512 512"},rotateIcon:{name:"rotate",content:'<path d="M256 448q12.3 0 24-1.8v32.3q-11.85 1.5-24 1.5c-12.15 0-16.1-.5-24-1.5v-32.3q11.7 1.8 24 1.8m-116-7c12.7 9.7 26.6 17.8 41.5 24l16.2-28c-15.1-5.9-29.1-14.1-41.5-24.1zm-61-78.5c6.3 14.9 14.4 28.8 24 41.5l28-16.2c-10-12.5-18.1-26.4-24.1-41.5zM256 128v64l128-80-128-80v64q-12.15 0-24 1.5c-17.7 2.2-34.6 6.8-50.5 13.5-14.9 6.3-28.8 14.4-41.5 24-14 10.6-26.4 23-37 37-9.7 12.7-17.8 26.6-24 41.5-6.7 15.9-11.3 32.8-13.5 50.5Q64 275.85 64 288c0 12.15.5 16.1 1.5 24h32.3Q96 300.3 96 288c0-12.3.6-16.2 1.8-24 1.8-11.9 4.9-23.4 9.2-34.3 5.9-15.1 14.1-29.1 24.1-41.5 7.4-9.3 15.8-17.7 25.1-25.1 12.5-10 26.4-18.1 41.5-24.1 10.9-4.3 22.4-7.4 34.3-9.2q11.7-1.8 24-1.8m190.5 136h-32.3q1.8 11.7 1.8 24c0 12.3-.6 16.2-1.8 24h32.3q1.5-11.85 1.5-24c0-12.15-.5-16.1-1.5-24m-65.6 123.8 28 16.2c9.7-12.7 17.8-26.6 24-41.5l-28-16.2c-5.8 15.1-14 29.1-24 41.5M314.3 437l16.2 28c14.9-6.3 28.8-14.4 41.5-24l-16.2-28c-12.4 9.9-26.4 18.1-41.5 24" />',viewBox:"0 0 512 512"},rotateLeftIcon:{name:"rotate-left",content:'<path d="M32 448 192 64v384zm192-160 256 160H224zm32 128h112.4L256 345.7zm64-256V96l-96 80 96 80v-64h96v96h32V160z" />',viewBox:"0 0 512 512"},rotateRightIcon:{name:"rotate-right",content:'<path d="M320 448V64l160 384zm-32 0H32l256-160zm-32-102.3L143.6 416H256zM64 160v128h32v-96h96v64l96-80-96-80v64z" />',viewBox:"0 0 512 512"},roundCornersIcon:{name:"round-corners",content:'<path d="M448 320c0 70.692-57.308 128-128 128H192c-70.692 0-128-57.308-128-128V192c0-70.692 57.308-128 128-128h128c70.692 0 128 57.308 128 128z" />',viewBox:"0 0 512 512"},rowFreezeIcon:{name:"row-freeze",content:'<path d="M32 448h416V32H32zM64 96l64 64H64zm96-32 96 96h-64L96 64zm128 0 96 96h-64l-96-96zm128 64-64-64h64zm-96 160v-96h96v96zm-128 0v-96h96v96zm-32 0H64v-96h96zm160 128v-96h96v96zm-128 0v-96h96v96zm-128 0v-96h96v96z" />',viewBox:"0 0 512 512"},rowsIcon:{name:"rows",content:'<path d="M480 64v96H32V64zM32 192v96h448v-96zm448 128H32v96h448z" />',viewBox:"0 0 512 512"},rssBoxIcon:{name:"rss-box",content:'<path d="M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32M115.2 447.6c-28.3 0-51.2-22.8-51.2-51s22.9-51 51.2-51 51.2 22.8 51.2 51-23 51-51.2 51m128.8.4c0-48.1-18.7-93.3-52.8-127.3-34-33.9-79.2-52.6-127.2-52.6v-73.6c140.1 0 254.1 113.7 254.1 253.5zm129.9 0c0-171.2-139-310.4-309.9-310.4V64c211.6 0 383.8 172.3 383.8 384z" />',viewBox:"0 0 512 512"},rssIcon:{name:"rss",content:'<path d="M151.4 420c0 32.9-26.7 59.5-59.7 59.5S32 452.9 32 420s26.7-59.5 59.7-59.5 59.7 26.7 59.7 59.5M32 184.3v85.9c56 0 108.5 21.8 148.1 61.3 39.6 39.6 61.4 92.3 61.4 148.5h86.2C327.6 317 195 184.3 32 184.3M32 32v85.9c199.4 0 361.6 162.5 361.6 362.1h86.2C479.8 233 278.9 32 32 32" />',viewBox:"0 0 512 512"},rulerOutlineIcon:{name:"ruler-outline",content:'<path d="M448.37 192H48c-8.84 0-16 7.16-16 16v96c0 8.84 7.16 16 16 16h400.37c8.84 0 16-7.16 16-16v-96c0-8.84-7.16-16-16-16m-16 96H64v-64h32.04v32h16.04v-32h32.06v32h16.03v-32h32.06v32h16.04v-32h32.06v32h16.03v-32h32.06v32h16.04v-32h32.06v32h16.03v-32h31.06v32h16.04v-32h32.72z" />',viewBox:"0 0 512 512"},saveIcon:{name:"save",content:'<path d="M384 32H64c-17.6 0-32 14.4-32 32v384c0 17.6 14.4 32 32 32h384c17.6 0 32-14.4 32-32V128zm-64 32v128h-64V64zm128 384-383.9.1-.1-.1V64.1l.1-.1H96v160h256V64h18.7l77.3 77.3z" />',viewBox:"0 0 512 512"},searchIcon:{name:"search",content:'<path d="M365.3 320h-22.7l-26.7-26.7C338.5 265.7 352 230.4 352 192c0-88.4-71.6-160-160-160S32 103.6 32 192s71.6 160 160 160c38.4 0 73.7-13.5 101.3-36.1l26.7 26.7v22.7L434.7 480l45.3-45.3zM64 192c0-70.7 57.3-128 128-128s128 57.3 128 128-57.3 128-128 128S64 262.7 64 192" />',viewBox:"0 0 512 512"},selectAllIcon:{name:"select-all",content:'<path d="M448 448h32v32h-32zm0-448h32v32h-32zM0 448h32v32H0zM0 0h32v32H0zm448 384h32v32h-32zm0-64h32v32h-32zm0-64h32v32h-32zm0-64h32v32h-32zm0-64h32v32h-32zm0-64h32v32h-32zM0 384h32v32H0zm0-64h32v32H0zm0-64h32v32H0zm0-64h32v32H0zm0-64h32v32H0zm0-64h32v32H0zm128 384h32v32h-32zm-64 0h32v32H64zm128 0h32v32h-32zm64 0h32v32h-32zm64 0h32v32h-32zm64 0h32v32h-32zM64 0h32v32H64zm64 0h32v32h-32zm64 0h32v32h-32zm64 0h32v32h-32zm64 0h32v32h-32zm64 0h32v32h-32zm-96 64 53.4 53.4L240 218.9 138.6 117.4 192 64H64v128l53.5-53.5L218.9 240 117.5 341.5 64 288v128h128l-53.4-53.4L240 261.1l101.4 101.5L288 416h128V288l-53.5 53.5L261.1 240l101.4-101.5L416 192V64z" />',viewBox:"0 0 512 512"},selectBoxIcon:{name:"select-box",content:'<path d="M384 352H128v-32h256zm0 32H128v32h256zm0-128H128v32h256zm96-192v128c0 17.6-14.4 32-32 32v224c0 17.7-14.3 32-32 32H96c-17.7 0-32-14.3-32-32V224c-17.6 0-32-14.4-32-32V64c0-17.6 14.4-32 32-32h384c17.6 0 32 14.4 32 32M352 96l32 64 32-64zm64 128H96v224h320z" />',viewBox:"0 0 512 512"},setColumnPositionIcon:{name:"set-column-position",content:'<path d="M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32M192 416H96V96h96zm224 0H224v-32h192zm0-64H224v-64h192zm0-96H224v-64h192zm0-96H224V96h192z" />',viewBox:"0 0 512 512"},shapeLineIcon:{name:"shape-line",content:'<path d="M480 54.6 54.6 480 32 457.4 457.4 32z" />',viewBox:"0 0 512 512"},shapesIcon:{name:"shapes",content:'<path d="M480 32H160v131.204C86.969 178.029 32 242.594 32 320c0 88.365 71.635 160 160 160 77.406 0 141.972-54.969 156.797-128H480zM192 448c-70.692 0-128-57.308-128-128 0-59.643 40.793-109.758 96-123.967 1.173-.302 2.354-.583 3.539-.852.357-.081.717-.156 1.076-.234a125 125 0 0 1 3.764-.762 126 126 0 0 1 2.557-.448c.369-.061.736-.125 1.105-.184q3.635-.569 7.335-.932c.379-.037.759-.067 1.139-.101a132 132 0 0 1 3.913-.29q1.309-.075 2.623-.125c.392-.015.782-.033 1.174-.045 1.254-.036 2.512-.06 3.775-.06 70.692 0 128 57.308 128 128 0 1.264-.023 2.521-.06 3.775-.012.393-.03.782-.045 1.174a127 127 0 0 1-.207 3.922q-.09 1.31-.207 2.613c-.034.38-.064.761-.102 1.14a127 127 0 0 1-.933 7.339c-.057.365-.121.728-.181 1.092a128 128 0 0 1-.683 3.785q-.256 1.29-.535 2.571c-.075.346-.147.692-.226 1.037a135 135 0 0 1-.855 3.552c-14.208 55.207-64.323 96-123.966 96m256-128h-96c0-88.365-71.635-160-160-160V64h256z" />',viewBox:"0 0 512 512"},shareIcon:{name:"share",content:'<path d="M480 432c0 44.2-35.8 80-80 80s-80-35.8-80-80c0-10.6 2.1-20.7 5.8-30l-158.6-88.1C152.9 327.6 133.4 336 112 336c-44.2 0-80-35.8-80-80s35.8-80 80-80c21.4 0 40.9 8.4 55.2 22.1L325.8 110c-3.8-9.3-5.8-19.4-5.8-30 0-44.2 35.8-80 80-80s80 35.8 80 80-35.8 80-80 80c-22 0-41.9-8.9-56.4-23.3l-158 87.8c4.1 9.7 6.4 20.3 6.4 31.5s-2.3 21.8-6.4 31.5l158 87.8C358.1 360.9 378 352 400 352c44.2 0 80 35.8 80 80" />',viewBox:"0 0 512 512"},sharpenIcon:{name:"sharpen",content:'<path d="M256 32 128 480h256zm0 116.5L341.6 448H170.4z" />',viewBox:"0 0 512 512"},signatureIcon:{name:"signature",content:'<path d="M32 448h448v32H32zM448 32H288v64h160zm-96 340.9L256 224l32-96h160l32 96-96 148.9V416h-32zm0-59.1V256h32v57.8l60.8-94.3-19.9-59.5H311.1l-19.9 59.6zM78.8 377.3c8.7-10.3 23.9-25.6 37.2-17.3 14.9 9.3 25.1 42.1 56.9 43.8 27.2-.6 18.9-34.6 36.7-33.2 16.6 0 19.5 47.8 46.5 47.9 25.7.1 37.4-14.5 37.3-28 .1-29-62.5-87.7-85.4-98-21.4-9.6-34-2.3-39.7 6-5.3 7.9 9.3 34.5-13.7 41.2-17.3 1.5-29.2-33.2-62.1-33.2S77 354.1 32 352c13.1 6 32.8 42 46.8 25.3" />',viewBox:"0 0 512 512"},silverlightIcon:{name:"silverlight",content:'<path d="M256 0 0 256l256 256 256-256zm-75.9 324c-21.6 0-40.5-6.3-52.1-13.7v-33.2c14.5 10.8 32.9 17.9 51.4 17.9 16.3 0 28.6-5 28.6-17.6 0-10.6-6.8-14.5-18.9-18.9l-23.6-7.9c-23.9-7.9-39.7-20.3-39.7-47 0-29.9 25.7-46.2 57.3-46.2 19.7 0 35.8 4.7 48.8 12.6v32.9c-13.9-10.2-29.1-16.8-47.8-16.8-14.5 0-25.5 4.9-25.5 16 0 9.9 6.5 13.9 17.9 17.6l25.2 8.6c27.1 9.2 39.4 23.9 39.4 47.8.2 31.9-26.8 47.9-61 47.9m95.9-4V160h32v128h76v32z" />',viewBox:"0 0 512 512"},sizeToGridIcon:{name:"size-to-grid",content:'<path d="M384 384H128V128h256zM96 0H64v512h32zm352 0h-32v512h32zm64 64H0v32h512zm0 352H0v32h512z" />',viewBox:"0 0 512 512"},slidersIcon:{name:"sliders",content:'<path d="M480 96v32H285.3c-6.6 18.6-24.4 32-45.3 32s-38.7-13.4-45.3-32H32V96h162.7c6.6-18.6 24.4-32 45.3-32s38.7 13.4 45.3 32zm-112 96c-20.9 0-38.7 13.4-45.3 32H32v32h290.7c6.6 18.6 24.4 32 45.3 32s38.7-13.4 45.3-32H480v-32h-66.7c-6.6-18.6-24.4-32-45.3-32M176 320c-20.9 0-38.7 13.4-45.3 32H32v32h98.7c6.6 18.6 24.4 32 45.3 32s38.7-13.4 45.3-32H480v-32H221.3c-6.6-18.6-24.4-32-45.3-32" />',viewBox:"0 0 512 512"},slnIcon:{name:"sln",content:'<path d="M352 32 172.5 211.5 64 128l-32 32v192l32 32 108.5-83.5L352 480l128-32V64zM64 320V192l64 64zm166.4-64L352 162.5v187.1z" />',viewBox:"0 0 512 512"},snapGridIcon:{name:"snap-grid",content:'<path d="M480 128V96h-96V0h-32v96h-96V0h-32v96h-96V0H96v96H0v32h96v96H0v32h96v96H0v32h96v96h32v-96h96v96h32v-96h96v96h32v-96h96v-32h-96v-96h96v-32h-96v-96zm-352 0h96v96h-96zm0 224v-96h96v96zm224 0h-96v-96h96zm0-128h-96v-96h96z" />',viewBox:"0 0 512 512"},snapToGridlinesIcon:{name:"snap-to-gridlines",content:'<path d="M160 32H0v416h288V32zm-32 384H32v-96h96zm0-128H32v-96h96zm0-128H32V64h96zm128 256h-96v-96h96zm0-128h-96v-96h96zm0-128h-96V64h96zm256 80c0 44.2-35.8 80-80 80h-32v-32h32c26.5 0 48-21.5 48-48s-21.5-48-48-48h-32v-32h32c44.2 0 80 35.8 80 80m-160-48h32v-32h-32zm0 128h32v-32h-32z" />',viewBox:"0 0 512 512"},snapToSnaplinesIcon:{name:"snap-to-snaplines",content:'<path d="M224 128h96V96h-96V32h-32v64h-64V32H96v64H32v32h64v256H32v32h64v64h32v-64h64v64h32v-64h256v-32H224zm-32 256h-64V128h64zm208-64h-32v-32h32c26.5 0 48-21.5 48-48s-21.5-48-48-48h-32v-32h32c44.2 0 80 35.8 80 80s-35.8 80-80 80m-48-160h-32v32h32zm-32 160h32v-32h-32z" />',viewBox:"0 0 512 512"},sortAscIcon:{name:"sort-asc",content:'<path d="M96 352h320v64H96zm0-128h224v64H96zm0-128h128v64H96z" />',viewBox:"0 0 512 512"},sortAscSmallIcon:{name:"sort-asc-small",content:'<path d="M256 192v224h-32V192h-96L240 64l112 128z" />',viewBox:"0 0 512 512"},sortClearIcon:{name:"sort-clear",content:'<path d="m110.9 224 64 64H96v-64zM96 416h128v-64H96zm214.6-128h9.4v-64h-73.4l-64-64H416V96H118.6l-64-64L32 54.6 457.4 480l22.6-22.6z" />',viewBox:"0 0 512 512"},sortDescIcon:{name:"sort-desc",content:'<path d="M96 96h320v64H96zm0 128h224v64H96zm0 128h128v64H96z" />',viewBox:"0 0 512 512"},sortDescSmallIcon:{name:"sort-desc-small",content:'<path d="M352 288 240 416 128 288h96V64h32v224z" />',viewBox:"0 0 512 512"},sparklesIcon:{name:"sparkles",content:'<path d="m320 32 54.3 137.7L512 224l-137.7 54.3L320 416l-54.3-137.7L128 224l137.7-54.3zM94 350 0 384l94 34 34 94 34-94 94-34-94-34-34-94zM70.6 70.6 0 96l70.5 25.5L96 192l25.5-70.5L192 96l-70.5-25.5L96 0 70.5 70.5Z" />',viewBox:"0 0 512 512"},spellCheckerIcon:{name:"spell-checker",content:'<path d="M113.2 206.2q-11.1 9.3-24.6 13.5c-13.5 4.2-19.3 4.2-31 4.2-8.4 0-16.1-1-23.1-2.9s-13.1-4.9-18.2-8.8-9.1-8.8-12-14.6C1.4 192 0 185.2 0 177.5c0-18.9 8.1-32.9 24.4-41.9s40.9-13.5 74-13.5h13.7c0-2.6 0-5.3-.1-8.2s-.3-5.4-.7-7.6c-.8-7.6-3.5-13.2-8-17-4.5-3.7-11.8-5.6-21.7-5.6-10.4 0-18.1 1.9-23.3 5.8s-7.8 9.5-7.8 16.8H7c2.4-32.7 27.8-49 76.3-49 6.6 0 12.6.2 17.9.6s10.2 1.1 14.6 2c4.4 1 8.6 2.2 12.5 3.7s7.6 3.4 11.4 5.7c3.5 2.2 6.4 4.7 9 7.4 2.5 2.8 4.6 6.1 6.4 9.9 1.7 3.9 3 8.3 3.8 13.3s1.2 10.8 1.2 17.4V224h-46.8zm-1-58H96.8c-16.2 0-28.4 2-36.5 5.9s-12.2 10.6-12.2 20.2q0 10.95 7.5 16.2c7.5 5.25 11.5 5.2 19.4 5.2 7.6 0 14.6-1.5 21.2-4.5s11.9-6.9 15.8-11.7v-31.3zm125.2-61.6c5.5-7.2 12.3-12.8 20.2-16.7S274 64 283.1 64c10.2 0 19.2 1.9 26.8 5.7 7.7 3.8 14.1 9.2 19.3 16.3s9.1 15.7 11.7 25.9 4 21.6 4 34.3-1.2 19-4.3 29.4c-3 10.4-7.6 17.9-13.3 25.2q-8.55 10.95-20.7 17.1c-12.15 6.15-17.3 6.1-27.5 6.1-17.5 0-31.9-5.2-43.3-15.6V224H192V0h45.4zm0 91.7c4.4 4.1 9.1 7.2 14.1 9.4 5 2.1 10.5 3.2 16.5 3.2 9.8 0 17.4-4.3 22.7-12.8 5.3-8.6 7.9-14.7 7.9-31.8 0-32.7-9.6-49-28.7-49-6.2 0-12 1.9-17.4 5.6s-10.5 9-15.1 15.8zM442.2 224c-12.4 0-23.4-1.8-33.3-5.4-9.8-3.6-18.1-8.8-25-15.6-6.8-6.8-12-15.2-15.7-25.1s-5.5-21.3-5.5-34 1.8-24 5.5-33.9 8.9-18.2 15.9-25.1q10.35-10.35 25.2-15.6 14.85-5.4 33.6-5.4 30 0 48 14.1c18 14.1 19 23 21 40.9h-41c-1-7-3.9-12.7-8.8-16.9s-11.2-6.3-19.2-6.3c-10.2 0-18.4 3.9-24.5 11.6s-9.2 19.9-9.2 36.6c0 16.5 3.1 28.7 9.2 36.5s14.3 11.7 24.5 11.7c7.9 0 14.4-2.1 19.3-6.3s7.8-9.8 8.7-16.9h41c-2.5 17.7-9.7 31.2-21.5 40.7-11.6 9.6-27.7 14.4-48.2 14.4m69.8 0L224 512 64 352l64-64 96 96z" />',viewBox:"0 0 512 512"},stampIcon:{name:"stamp",content:'<path d="M384 288h-32v-16c0-26.51-21.49-48-48-48 0-15.19 5.53-26.16 12.53-40.05 8.53-16.92 19.1-37.9 19.45-70.26.02-.56.02-1.12.02-1.69 0-44.18-35.82-80-80-80s-80 35.82-80 80c0 .57 0 1.13.02 1.69.35 32.36 10.92 53.34 19.45 70.26 7 13.89 12.53 24.86 12.53 40.05-26.51 0-48 21.49-48 48v16h-32c-35.35 0-64 28.65-64 64v64h31v16c0 26.51 21.49 48 48 48h225c26.51 0 48-21.49 48-48v-16h32v-64c0-35.35-28.65-64-64-64m-151.06-99.38c-2.66-6.7-5.8-12.93-8.9-19.08C215.79 153.17 208 137.71 208 112s21.53-48 48-48 48 21.53 48 48-7.79 41.17-16.04 57.54c-3.1 6.15-6.24 12.38-8.9 19.08-4.09 10.25-7.06 21.59-7.06 35.38h-32c0-13.79-2.97-25.13-7.06-35.38M192 272c0-8.82 7.18-16 16-16h96c8.82 0 16 7.18 16 16v16H192zm192 160c0 8.82-7.18 16-16 16H143c-8.82 0-16-7.18-16-16v-16h257zm32-48H96v-32c0-17.64 14.36-32 32-32h256c17.64 0 32 14.36 32 32z" />',viewBox:"0 0 512 512"},starIcon:{name:"star",content:'<path d="M256 391.5 117.2 480 154 314.1 32 202.4 192.9 188 256 32l63.1 156L480 202.4 358 314.1 394.8 480z" />',viewBox:"0 0 512 512"},starOutlineIcon:{name:"star-outline",content:'<path d="M480 202.4 319.1 188 256 32l-63.1 156L32 202.4l122 111.7L117.2 480 256 391.5 394.8 480 358 314.1zM256 353.6l-90.8 57.9 24-108.5-82.1-75.2 108.1-9.7L256 117.3l40.8 100.8 108.1 9.7-82.1 75.2 24.1 108.5z" />',viewBox:"0 0 512 512"},stickIcon:{name:"stick",content:'<path d="M192 96c0-17.7-14.3-32-32-32H96c-17.7 0-32 14.3-32 32v32h128zm128 160c0 35.3-28.7 64-64 64s-64-28.7-64-64v-96H64v96c0 106 86 192 192 192s192-86 192-192v-96H320zm96-192h-64c-17.7 0-32 14.3-32 32v32h128V96c0-17.7-14.3-32-32-32" />',viewBox:"0 0 512 512"},stickyNoteIcon:{name:"sticky-note",content:'<path d="M160 32v.37l.37-.37zM32 160v.37l.37-.37zM160.37 32 32 160.37V480h448V32zM160 77.63V160H77.63zM448 448H64V192h128V64h256zm-32-288H224v-32h192zm0 224H96v-32h320zm0-65H96v-32h320zm0-62H96v-32h320z" />',viewBox:"0 0 512 512"},stopIcon:{name:"stop",content:'<path d="M512 512H0V0h512z" />',viewBox:"0 0 512 512"},stopSmIcon:{name:"stop-sm",content:'<path d="M416 416H96V96h320z" />',viewBox:"0 0 512 512"},strikethroughIcon:{name:"strikethrough",content:'<path d="M393.9 320c.1-23.9 4.5-41.4 13.5-52.5 9.1-11.1 20.8-16.7 35.3-16.7 9.6 0 17.7 3.1 24.5 9.3s11.4 15.4 14.1 27.7l27.9-4.7c-3.3-18.4-10.8-32.7-22.5-42.7s-26.8-15-45.2-15c-14.5 0-28.1 3.6-40.4 11.1-12.4 7.4-21.6 18.5-27.7 33.2-5.9 14.4-8.9 31.2-9.1 50.4h-25.5v-2.2c0-13.2-1.7-25.6-5.1-37.1s-8.1-21.4-14.2-29.6c-6-8.1-13.7-14.5-23-19s-19.2-6.8-29.6-6.8c-18.9 0-34.3 8.2-46.4 24.6v-90H192v160h-45v-25.8c0-13.7-.5-23.3-1.4-28.5-1.7-8.5-4.7-15.5-9-21.1-4.3-5.5-10.9-10.2-19.9-13.8s-20.8-5.5-35.3-5.5c-14.6 0-27.4 2.1-38.5 6.4s-19.5 10.4-25.4 18.4c-5.8 8-10 18.4-12.6 31.4l28.1 4.1c3.1-13 7.8-22 14.3-27.1s16.4-7.7 29.9-7.7q21.75 0 32.7 10.5c5.4 5.1 8.1 14 8.1 26.6 0 1.1 0 3.8-.2 8.1-11 4.1-28 7.7-51.2 10.7-11.4 1.5-19.9 3-25.5 4.7-6.7 2-12.9 4.9-18.5 8.6H0v32h1.2c-.8 3.8-1.2 7.7-1.2 11.8 0 15.2 5 27.8 15 37.6S39.3 416 57.9 416c11.3 0 21.8-1.9 31.6-6s20.1-10.9 30.7-20.6h.1c.8 8.6 2.7 20.3 5.7 26.7h30c-3.6-7-6-18.4-7.3-26.1-1-6-1.6-18.7-1.8-37.9h45v64h26.6V389q17.1 27 47.1 27c20.1 0 37.3-8.5 51.7-25.6 8.6-10.2 14.6-23 18-38.3h31.8c3.3 16 9.4 29.2 18.3 39.5 14.1 16.3 32.7 24.5 55.9 24.5 18.5 0 34.1-6 46.8-17.8 12.1-11.3 19.8-26.7 23.2-46.2h.5v-32H393.9zm-280.7 42.6c-4.1 9-10.4 16.1-19 21.4-8.6 5.2-18.4 7.8-29.5 7.8-11.2 0-19.6-2.8-25.4-8.2-5.8-5.6-8.7-12.4-8.7-20.7 0-3.9.7-7.5 2.1-10.9h83.6c-.7 4.1-1.8 7.7-3.1 10.6m105.1-43.3c0-22.2 4.6-39.2 13.7-50.9 9.1-11.8 20-17.6 32.5-17.6s23.1 5.6 31.8 17c8.8 11.3 13.1 28.7 13.2 52.3h-91.3c.1-.3.1-.6.1-.8m77.6 53.6c-9.1 11.8-20 17.7-32.5 17.7-15.5 0-27.7-8-36.7-23.9-2.2-3.9-4-8.8-5.3-14.7H306c-2.4 8.3-5.7 15.3-10.1 20.9m173.5 6.6c-7.5 7.5-16.9 11.2-28.2 11.2-14 0-25.4-5.6-34.1-16.7q-6.6-8.4-9.9-21.9h85.5c-2.6 11.9-7 21.1-13.3 27.4" />',viewBox:"0 0 512 512"},stripAllFormattingIcon:{name:"strip-all-formatting",content:'<path d="M32 480h224v32H0v.1V256h32zm32-32h159v-32H64zm97-96H63v32h98zm-65-64H64v32h32zm316.2-28.6L253.8 101c-12.4-12.4-32.9-12.4-45.3.1l-69.8 69.8-.2.2c-11.6 11.6-30 12.7-42.5 2.7l200.9 200.9c12.5 12.5 32.8 12.4 45.3 0l69.9-69.9c12.5-12.5 12.5-33 .1-45.4M502.7 32 480 9.3c-12.4-12.4-32.8-12.4-45.3 0l-67.9 67.9-22.6-22.6c-12.4-12.4-32.8-12.4-45.3 0l-22.6 22.6 158.4 158.4 22.6-22.6c12.4-12.4 12.4-32.8 0-45.3l-22.6-22.6 67.9-67.9c12.5-12.4 12.5-32.8.1-45.2" />',viewBox:"0 0 512 512"},stripCssFormatIcon:{name:"strip-css-format",content:'<path d="M0 288v224h416V288zm145 65.9c-10-6.2-21-9.3-33.4-9.3-13.6 0-24.5 4.6-32.9 13.7-8.3 9.1-12.5 21.5-12.5 37.1 0 15 3.9 26.9 11.8 35.8s18.4 13.3 31.7 13.3c12.7 0 24.3-3.3 34.3-9.9v31.8c-9.9 5.5-23.7 8.2-40.7 8.2-22.2 0-39.6-7-52.3-20.9-12.7-14-19-32.5-19-55.8 0-24.7 7.1-44.8 21.4-60.2s32.8-23.1 55.6-23.1c14.1 0 26 1.9 36 5.7zM260.6 450c-3.1 5.9-7.2 10.6-12.4 14.2s-11.3 6.2-18.2 7.8q-10.5 2.4-21.9 2.4c-7.9 0-15.4-.7-22.5-2.2-7.2-1.4-13.4-3.6-18.5-6.5v-34.4c5.8 5.3 12.2 9.2 18.9 11.8q10.35 3.9 20.7 3.9c4.1 0 7.7-.4 10.7-1.2 3.1-.8 5.6-1.9 7.7-3.3 2-1.4 3.6-3.1 4.6-5s1.5-4 1.5-6.2q0-4.5-2.4-8.1t-6.6-6.6c-4.2-3-6.1-4-9.9-5.8-3.8-1.9-8-3.8-12.4-5.7-11.3-5-19.6-11.2-25.1-18.4-5.5-7.3-8.3-15.9-8.3-26.2q0-12.15 4.5-20.7c4.5-8.55 7.1-10.6 12.3-14.3s11.2-6.5 18-8.3c6.9-1.8 14.1-2.6 21.7-2.6 7.5 0 14.2.5 19.9 1.5 5.8 1 11.2 2.5 16 4.5v32.2c-2.4-1.8-5.1-3.4-7.9-4.7-2.9-1.4-5.8-2.5-8.8-3.4s-6-1.6-9-2-5.8-.6-8.5-.6c-3.7 0-7.1.4-10.1 1.1-3 .8-5.6 1.8-7.7 3.2s-3.7 3-4.8 4.9-1.7 4-1.7 6.4c0 2.6.6 4.9 1.9 7s3.1 4 5.4 5.8 5.2 3.6 8.6 5.4 7.2 3.6 11.4 5.5c5.8 2.6 11 5.3 15.5 8.3 4.6 2.9 8.6 6.2 11.8 9.9 3.3 3.7 5.8 7.9 7.6 12.6 1.7 4.7 2.6 10.2 2.6 16.3 0 8.5-1.6 15.7-4.6 21.5m119 0c-3.1 5.9-7.2 10.6-12.4 14.2s-11.3 6.2-18.2 7.8q-10.5 2.4-21.9 2.4c-7.9 0-15.4-.7-22.5-2.2-7.2-1.4-13.4-3.6-18.5-6.5v-34.4c5.8 5.3 12.2 9.2 18.9 11.8q10.35 3.9 20.7 3.9c4.1 0 7.7-.4 10.7-1.2 3.1-.8 5.6-1.9 7.7-3.3 2-1.4 3.6-3.1 4.6-5s1.5-4 1.5-6.2q0-4.5-2.4-8.1t-6.6-6.6c-4.2-3-6.1-4-9.9-5.8-3.8-1.9-8-3.8-12.4-5.7-11.3-5-19.6-11.2-25.1-18.4-5.5-7.3-8.3-15.9-8.3-26.2q0-12.15 4.5-20.7c3-5.8 7.1-10.6 12.3-14.3s11.2-6.5 18-8.3c6.9-1.8 14.1-2.6 21.7-2.6 7.5 0 14.2.5 19.9 1.5 5.8 1 11.2 2.5 16 4.5v32.2c-2.4-1.8-5.1-3.4-7.9-4.7-2.9-1.4-5.8-2.5-8.8-3.4s-6-1.6-9-2-5.8-.6-8.5-.6c-3.7 0-7.1.4-10.1 1.1-3 .8-5.6 1.8-7.7 3.2s-3.7 3-4.8 4.9-1.7 4-1.7 6.4c0 2.6.6 4.9 1.9 7s3.1 4 5.4 5.8c2.4 1.8 5.2 3.6 8.6 5.4s7.2 3.6 11.4 5.5c5.8 2.6 11 5.3 15.5 8.3 4.6 2.9 8.5 6.2 11.8 9.9s5.8 7.9 7.6 12.6c1.7 4.7 2.6 10.2 2.6 16.3 0 8.5-1.5 15.7-4.6 21.5M502.7 32 480 9.3c-12.4-12.4-32.8-12.4-45.3 0l-67.9 67.9-22.6-22.6c-12.4-12.4-32.8-12.4-45.3 0l-22.6 22.6 158.4 158.4 22.6-22.6c12.4-12.4 12.4-32.8 0-45.3l-22.6-22.6 67.9-67.9c12.5-12.4 12.5-32.8.1-45.2m-246.9 69.9c-12.4-12.4-32.8-12.4-45.3 0l-79.7 79.7c-12.4 12.4-32.8 12.4-45.3 0L160 256h249.9z" />',viewBox:"0 0 512 512"},stripFontElementsIcon:{name:"strip-font-elements",content:'<path d="M502.666 31.961 480.039 9.334c-12.445-12.445-32.81-12.445-45.255 0l-67.882 67.882-22.627-22.627c-12.445-12.445-32.81-12.445-45.255 0l-22.627 22.627 158.392 158.392 22.627-22.627c12.445-12.445 12.445-32.81 0-45.255l-22.627-22.627 67.882-67.882c12.444-12.446 12.444-32.811-.001-45.256m-246.848 69.936c-12.445-12.445-32.81-12.445-45.255 0l-79.706 79.706c-12.445 12.445-32.81 12.445-45.255 0L160 256h249.921zM176 348.121 200.706 416h-49.412zM0 288v224h352V288zm224 192-11.647-32h-72.706L128 480H96l58.235-160h43.53L256 480z" />',viewBox:"0 0 512 512"},stripSpanElementsIcon:{name:"strip-span-elements",content:'<path d="M96 288 0 400l96 112h256V288zm170.3 167.5c-3.9 5.9-9.3 10.6-16.1 14.2s-14.6 6.2-23.6 7.8-18.4 2.4-28.4 2.4c-10.2 0-20-.7-29.2-2.2-9.2-1.4-17.2-3.6-24-6.5v-34.5c7.5 5.2 15.7 9.2 24.6 11.8 8.8 2.6 17.8 3.9 26.8 3.9 5.3 0 9.9-.4 13.9-1.2q5.85-1.2 9.9-3.3c2.6-1.4 4.6-3.1 5.9-5s2-4 2-6.2c0-3-1-5.7-3.1-8.1s-4.9-4.6-8.5-6.6-7.9-4-12.8-5.8c-4.9-1.9-10.3-3.8-16-5.7-14.6-5-25.4-11.2-32.6-18.4-7.2-7.3-10.7-16-10.7-26.3 0-8.1 2-15 5.9-20.8s9.2-10.5 15.9-14.3c6.7-3.7 14.5-6.5 23.3-8.3s18.2-2.6 28.1-2.6q14.55 0 25.8 1.5c11.25 1.5 14.4 2.5 20.7 4.5v32.3c-3.1-1.8-6.5-3.4-10.2-4.7-3.7-1.4-7.5-2.5-11.4-3.4s-7.8-1.6-11.6-2c-3.9-.4-7.5-.6-11-.6-4.8 0-9.1.4-13 1.1-3.9.8-7.2 1.8-9.9 3.2s-4.8 3-6.2 4.9c-1.5 1.9-2.2 4-2.2 6.4 0 2.6.8 4.9 2.5 7 1.6 2.1 4 4 7 5.8q4.5 2.7 11.1 5.4 6.45 2.7 14.7 5.4c7.5 2.6 14.2 5.3 20.1 8.3q8.85 4.35 15.3 9.9c4.2 3.7 7.5 7.9 9.8 12.6s3.4 10.2 3.4 16.4c-.3 8.6-2.3 15.9-6.2 21.7M502.7 32 480 9.3c-12.4-12.4-32.8-12.4-45.3 0l-67.9 67.9-22.6-22.6c-12.4-12.4-32.8-12.4-45.3 0l-22.6 22.6 158.4 158.4 22.6-22.6c12.4-12.4 12.4-32.8 0-45.3l-22.6-22.6 67.9-67.9c12.5-12.4 12.5-32.8.1-45.2m-246.9 69.9c-12.4-12.4-32.8-12.4-45.3 0l-79.7 79.7c-12.4 12.4-32.8 12.4-45.3 0L160 256h249.9z" />',viewBox:"0 0 512 512"},stripWordFormattingIcon:{name:"strip-word-formatting",content:'<path d="M0 288v224h352V288zm239.3 192h-37.7L176 385.4 147.4 480h-40.9L64 320h40.6l21.9 100.4L155.8 320h40.4l25.2 100.4 19.4-71.4H224v-29h64zM502.7 77.2l-67.9 67.9 22.6 22.6c12.4 12.4 12.4 32.8 0 45.3l-22.6 22.6L276.4 77.2 299 54.6c12.4-12.4 32.8-12.4 45.3 0l22.6 22.6 67.9-67.9c12.4-12.4 32.8-12.4 45.3 0L502.7 32c12.4 12.4 12.4 32.8 0 45.2M409.9 256H160l-74.4-74.4c12.4 12.4 32.8 12.4 45.3 0l79.7-79.7c12.4-12.4 32.8-12.4 45.3 0z" />',viewBox:"0 0 512 512"},stumbleUponBoxIcon:{name:"stumble-upon-box",content:'<path d="M64 32c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32zm191.5 96.3c82.5 0 82.5 87.3 82.5 87.3v8.4l-31.9 8-23.1-8v-8.6s0-29.2-27.5-29.2-27.5 29.2-27.5 29.2v81.5s0 87-82 87-82-87-82-87V256h55v41h-.9c.9 17.2 11 29.1 27.5 29.1s26.6-12 27.6-29.1h-.2v-81.4s0-87.3 82.5-87.3M283.1 256l23 7.6L338 256v40.7c.9 17.2 11 29.1 27.5 29.1s26.6-11.9 27.5-29.1V256h55v40.7s0 87.3-82.5 87.3-82.5-87.3-82.5-87.3z" />',viewBox:"0 0 512 512"},stumbleUponIcon:{name:"stumble-upon",content:'<path d="m288.1 256 26.8 8.4L352 256v64c1.1 18.9 12.8 32 32 32s30.9-13.1 32-32v-64h64v64s0 96-96 96-96-96-96-96zm26.8-23.2L288 224v-32s0-32-32-32-32 32-32 32v128s0 96-96 96-96-96-96-96v-64h64v64c1.1 18.9 12.8 32 32 32 19.1 0 30.9-13.2 32.1-32h-.1V192s0-96 96-96 96 96 96 96v32z" />',viewBox:"0 0 512 512"},subreportIcon:{name:"subreport",content:'<path d="M448 480c0 17.7-14.3 32-32 32H128c-17.7 0-32-14.3-32-32v-96h32v96h288V96H128v64H96V96c0-17.7 14.3-32 32-32h288c17.7 0 32 14.3 32 32zM63.9 32l254.3-.2L286.4 0 63.8.2C46.2.2 32 14.4 32 32l.1 128H64zm.1 351H32v32c0 17.7 14.3 32 32 32zm-32-62.9S64 288 95 288v32l65-48.1L96 224v32c-32.1 0-64 32.1-64 64.1M352 384l-160 .1V416l160-.1zm-96-192c-35.3 0-64 28.7-64 64s28.7 64 64 64 64-28.7 64-64h-64zm32-32v64h64c0-35.3-28.7-64-64-64" />',viewBox:"0 0 512 512"},subscriptIcon:{name:"subscript",content:'<path d="m198.6 304 89.4 89.4-22.6 22.6-89.4-89.4L86.6 416 64 393.4l89.4-89.4L64 214.6 86.6 192l89.4 89.4 89.4-89.4 22.6 22.6zm167.7 144h81.4v32H320v-11.9c0-8 1.7-15.3 5-21.7s7.5-12.1 12.5-17.2 10.5-9.6 16.4-13.5 11.6-7.4 16.9-10.6c5.6-3.3 10.6-6.4 14.8-9.4s7.8-6 10.7-8.9c2.9-3 5.1-6 6.5-9s2.1-6.3 2.1-9.7c0-6.7-2.3-11.8-7-15.3-4.6-3.4-11.7-5.2-21.3-5.2-16.5 0-32.3 5.4-47.4 16.1v-30.5c16.7-8.9 35.5-13.3 56.5-13.3 9.7 0 18.5 1 26.2 3.1s14.3 5.1 19.6 8.9c5.4 3.9 9.4 8.6 12.3 14.1 2.8 5.5 4.2 11.7 4.2 18.5 0 7.2-1.4 13.7-4.1 19.3s-6.3 10.8-10.8 15.4-9.7 8.8-15.6 12.7c-5.9 3.8-12 7.6-18.3 11.1-4.3 2.5-8.4 5-12.4 7.4q-6 3.75-10.5 7.2c-3.1 2.6-7.1 6.6-10 10.4" />',viewBox:"0 0 512 512"},sumIcon:{name:"sum",content:'<path d="M416 64v128l-64-64H160l128 128-128 128h192l64-64v128H96v-64l128-128L96 128V64z" />',viewBox:"0 0 512 512"},supscriptIcon:{name:"supscript",content:'<path d="m198.6 304 89.4 89.4-22.6 22.6-89.4-89.4L86.6 416 64 393.4l89.4-89.4L64 214.6 86.6 192l89.4 89.4 89.4-89.4 22.6 22.6zm167.7-112h81.4v32H320v-11.9c0-8 1.7-15.3 5-21.7s7.5-12.1 12.5-17.2 10.5-9.6 16.4-13.5 11.6-7.4 16.9-10.6c5.6-3.3 10.6-6.4 14.8-9.4s7.8-6 10.7-8.9c2.9-3 5.1-6 6.5-9s2.1-6.3 2.1-9.7c0-6.7-2.3-11.8-7-15.3-4.6-3.4-11.7-5.2-21.3-5.2-16.5 0-32.3 5.4-47.4 16.1V77.3c16.7-8.9 35.5-13.3 56.5-13.3 9.7 0 18.5 1 26.2 3.1s14.3 5.1 19.6 8.9c5.4 3.9 9.4 8.6 12.3 14.1 2.8 5.5 4.2 11.7 4.2 18.5 0 7.2-1.4 13.7-4.1 19.3s-6.3 10.8-10.8 15.4-9.7 8.8-15.6 12.7c-5.9 3.8-12 7.6-18.3 11.1-4.3 2.5-8.4 5-12.4 7.4q-6 3.75-10.5 7.2c-3.1 2.5-7.1 6.5-10 10.3" />',viewBox:"0 0 512 512"},symbolIcon:{name:"symbol",content:'<path d="m448 416 32-32v96H320V375.8c11.4-5.1 22.2-11.5 32-19 38.9-29.7 64-76.9 64-130.1C416 136.8 344.4 64 256 64S96 136.8 96 226.7c0 53.2 25.1 100.5 64 130.1 9.8 7.5 20.6 13.9 32 19V480H32v-96l32 32h96v-18.5C84.3 366.7 32 300.6 32 224 32 118 132.3 32 256 32s224 86 224 192c0 76.6-52.3 142.7-128 173.5V416z" />',viewBox:"0 0 512 512"},tableAddIcon:{name:"table-add",content:'<path d="M448 320V32H32v416h288V320zm-288 96H64v-96h96zm0-128H64v-96h96zm0-128H64V64h96zm128 256h-96v-96h96zm0-128h-96v-96h96zm0-128h-96V64h96zm32-96h96v96h-96zm0 224v-96h96v96zm192 128v32h-64v64h-32v-64h-64v-32h64v-64h32v64z" />',viewBox:"0 0 512 512"},tableAlignBottomCenterIcon:{name:"table-align-bottom-center",content:'<path d="M32 480V0h448v480zM64 32v416h384V32zm288 224H160v32h192zm64 64H96v32h320zm-64 64H160v32h192z" />',viewBox:"0 0 512 512"},tableAlignBottomLeftIcon:{name:"table-align-bottom-left",content:'<path d="M32 480V0h448v480zM64 32v416h384V32zm32 256h192v-32H96zm0 64h320v-32H96zm0 64h192v-32H96z" />',viewBox:"0 0 512 512"},tableAlignBottomRightIcon:{name:"table-align-bottom-right",content:'<path d="M32 480V0h448v480zM64 32v416h384V32zm352 224H224v32h192zm0 64H96v32h320zm0 64H224v32h192z" />',viewBox:"0 0 512 512"},tableAlignMiddleCenterIcon:{name:"table-align-middle-center",content:'<path d="M32 480V0h448v480zM64 32v416h384V32zm288 128H160v32h192zm64 64H96v32h320zm-64 64H160v32h192z" />',viewBox:"0 0 512 512"},tableAlignMiddleLeftIcon:{name:"table-align-middle-left",content:'<path d="M32 480V0h448v480zM64 32v416h384V32zm32 160h192v-32H96zm0 64h320v-32H96zm0 64h192v-32H96z" />',viewBox:"0 0 512 512"},tableAlignMiddleRightIcon:{name:"table-align-middle-right",content:'<path d="M32 480V0h448v480zM64 32v416h384V32zm352 128H224v32h192zm0 64H96v32h320zm0 64H224v32h192z" />',viewBox:"0 0 512 512"},tableAlignRemoveIcon:{name:"table-align-remove",content:'<path d="M32 0v480h448V0zm416 448H64V32h384zM131.6 224l29.9 32H128v-32zm-3.6 64h63.4l29.9 32H128zm123.1 64 29.9 32H128v-32zM96 92l22.6-22.6L143.5 96H384v32H173.4l29.9 32H384v32H233.1l29.9 32h121v32h-91.2l29.9 32H384v32h-31.4l63.4 68-22.6 22.6z" />',viewBox:"0 0 512 512"},tableAlignTopCenterIcon:{name:"table-align-top-center",content:'<path d="M32 480V0h448v480zM64 32v416h384V32zm288 32H160v32h192zm64 64H96v32h320zm-64 64H160v32h192z" />',viewBox:"0 0 512 512"},tableAlignTopLeftIcon:{name:"table-align-top-left",content:'<path d="M32 480V0h448v480zM64 32v416h384V32zm32 64h192V64H96zm0 64h320v-32H96zm0 64h192v-32H96z" />',viewBox:"0 0 512 512"},tableAlignTopRightIcon:{name:"table-align-top-right",content:'<path d="M32 480V0h448v480zM64 32v416h384V32zm352 32H224v32h192zm0 64H96v32h320zm0 64H224v32h192z" />',viewBox:"0 0 512 512"},tableBodyIcon:{name:"table-body",content:'<path d="M32 32v416h416V32zm256 32v96h-96V64zm128 256v64L224 192h64zM64 64h96v96H64zm0 128h96v96H64zm0 224v-96h96v96zm128 0v-64l64 64zm128 0L192 288v-64l192 192zm96-160-64-64h64zm0-96h-96V64h96z" />',viewBox:"0 0 512 512"},tableCellDeleteIcon:{name:"table-cell-delete",content:'<path d="M96 192h160v128H96zM32 352h160v128H32zm32 32v64h96v-64zm128-224H32V32h160zm-32-96H64v64h96zm262.627 192L480 313.373 457.373 336 400 278.627 342.627 336 320 313.373 377.373 256 320 198.627 342.627 176 400 233.373 457.373 176 480 198.627z" />',viewBox:"0 0 512 512"},tableCellIcon:{name:"table-cell",content:'<path d="M32 32v416h416V32zm128 384H64v-96h96zm0-128H64v-96h96zm0-128H64V64h96zm128 256h-96v-96h96zm0-256h-96V64h96zm128 256h-96v-96h96zm0-128h-96v-96h96zm0-128h-96V64h96z" />',viewBox:"0 0 512 512"},tableCellPropertiesIcon:{name:"table-cell-properties",content:'<path d="m502.666 77.216-22.627 22.627-67.882-67.882 22.627-22.627c12.445-12.445 32.81-12.445 45.255 0l22.627 22.627c12.445 12.445 12.445 32.81 0 45.255M384 256l32-32v288H0V96h288l-32 32h-96v96h32v96h96v32h96zM128 384H32v96h96zm0-128H32v96h96zm0-128H32v96h96zm128 256h-96v96h96zm128 0h-96v96h96zm8.483-332.365 67.882 67.882-141.588 141.588L290.66 288H224v-66.66l26.895-28.118zm22.627 67.882L392.483 96.89 256.719 232.654l11.314 11.314 11.314 11.314z" />',viewBox:"0 0 512 512"},tableColumnDeleteIcon:{name:"table-column-delete",content:'<path d="M192 288v224h128V288zm0-288v64h128V0zm160 32h128v416H352zm96 288h-64v96h64zm0-128h-64v96h64zm0-128h-64v96h64zM32 32h128v416H32zm96 288H64v96h64zm0-128H64v96h64zm0-128H64v96h64zm128 89.373L313.373 96 336 118.627 278.627 176 336 233.373 313.373 256 256 198.627 198.627 256 176 233.373 233.373 176 176 118.627 198.627 96z" />',viewBox:"0 0 512 512"},tableColumnGroupsIcon:{name:"table-column-groups",content:'<path d="M32 32v416h416V32zm256 32v64l-64-64zm0 320-96-96v-64l96 96zM192 96l96 96v64l-96-96zM64 64h96v96H64zm0 128h96v96H64zm0 224v-96h96v96zm128 0v-64l64 64zm224 0h-96v-96h96zm0-128h-96v-96h96zm0-128h-96V64h96z" />',viewBox:"0 0 512 512"},tableColumnInsertLeftIcon:{name:"table-column-insert-left",content:'<path d="M32 480V0h128v480zM480 32v416H192V32zM224 160h96V64h-96zm0 128h96v-96h-96zm0 128h96v-96h-96zm224-96h-96v96h96zm0-32v-96h-96v96zm0-224h-96v96h96z" />',viewBox:"0 0 512 512"},tableColumnInsertRightIcon:{name:"table-column-insert-right",content:'<path d="M352 480V0h128v480zM320 32v416H32V32zm-32 32h-96v96h96zm0 128h-96v96h96zm0 128h-96v96h96zM64 416h96v-96H64zm96-128v-96H64v96zM64 160h96V64H64z" />',viewBox:"0 0 512 512"},tableCornerIcon:{name:"table-corner",content:'<path d="M32 32v416h416V32zm256 32v96h-96V64zm0 128v96h-96v-96zM160 64v64L96 64zM64 96l64 64H64zm0 96h96v96H64zm0 224v-96h96v96zm128 0v-96h96v96zm224 0h-96v-96h96zm0-128h-96v-96h96zm0-128h-96V64h96z" />',viewBox:"0 0 512 512"},tableDeleteIcon:{name:"table-delete",content:'<path d="M32 32v416h416V32zm384 128h-64v32h64v96h-64v32h64v96h-96v-64h-32v64h-96v-64h-32v64H64v-96h64v-32H64v-96h64v-32H64V64h96v64h32V64h96v64h32V64h96zm-153.4 80 57.4 57.4-22.6 22.6-57.4-57.4-57.4 57.4-22.6-22.6 57.4-57.4-57.4-57.4 22.6-22.6 57.4 57.4 57.4-57.4 22.6 22.6z" />',viewBox:"0 0 512 512"},tableIcon:{name:"table",content:'<path d="M32 32v416h416V32zm256 32v96h-96V64zm0 128v96h-96v-96zM64 64h96v96H64zm0 128h96v96H64zm0 224v-96h96v96zm128 0v-96h96v96zm224 0h-96v-96h96zm0-128h-96v-96h96zm0-128h-96V64h96z" />',viewBox:"0 0 512 512"},tablePositionCenterIcon:{name:"table-position-center",content:'<path d="M352 256V32H128v224zM256 64h64v64h-64zm-32 160h-64v-64h64zm0-96h-64V64h64zm32 32h64v64h-64zM32 448h320v32H32zm448-128v32H32v-32zM32 384h448v32H32z" />',viewBox:"0 0 512 512"},tablePositionEndIcon:{name:"table-position-end",content:'<path d="M32 384h448v32H32zm0 96h320v-32H32zM480 32v224H256V32zM352 160h-64v64h64zm0-96h-64v64h64zm96 96h-64v64h64zm0-96h-64v64h64zM32 352h448v-32H32z" />',viewBox:"0 0 512 512"},tablePositionStartIcon:{name:"table-position-start",content:'<path d="M480 320v32H32v-32zM32 416h448v-32H32zm192-160H32V32h224v224zm-64-128h64V64h-64zm-32 32H64v64h64zm0-96H64v64h64zm32 160h64v-64h-64zM32 480h320v-32H32z" />',viewBox:"0 0 512 512"},tablePropertiesIcon:{name:"table-properties",content:'<path d="m502.666 77.216-22.627 22.627-67.882-67.882 22.627-22.627c12.445-12.445 32.81-12.445 45.255 0l22.627 22.627c12.445 12.445 12.445 32.81 0 45.255M392.483 51.635l67.882 67.882L290.66 288H224v-66.66zm22.627 67.882L392.483 96.89 256.719 232.654l22.627 22.627zM384 256l32-32v288H0V96h288l-32 32h-96v224h224zM128 384H32v96h96zm0-128H32v96h96zm0-128H32v96h96zm128 256h-96v96h96zm128 0h-96v96h96z" />',viewBox:"0 0 512 512"},tableRowDeleteIcon:{name:"table-row-delete",content:'<path d="M224 192H0v128h224zm288 0h-64v128h64zm-32 160v128H64V352zm-288 96v-64H96v64zm128 0v-64h-96v64zm128 0v-64h-96v64zm32-416v128H64V32zm-288 96V64H96v64zm128 0V64h-96v64zm128 0V64h-96v64zm-89.373 128L416 313.373 393.373 336 336 278.627 278.627 336 256 313.373 313.373 256 256 198.627 278.627 176 336 233.373 393.373 176 416 198.627z" />',viewBox:"0 0 512 512"},tableRowGroupsIcon:{name:"table-row-groups",content:'<path d="M32 32v416h416V32zm256 32v96h-96V64zm-64 128h64l96 96h-64zm32 96h-64l-96-96h64zM64 64h96v96H64zm0 160 64 64H64zm0 192v-96h96v96zm128 0v-96h96v96zm224 0h-96v-96h96zm0-160-64-64h64zm0-96h-96V64h96z" />',viewBox:"0 0 512 512"},tableRowInsertAboveIcon:{name:"table-row-insert-above",content:'<path d="M480 160H0V32h480zM32 192h416v288H32zm32 32v96h96v-96zm128 0v96h96v-96zm128 0v96h96v-96zm96 224v-96h-96v96zm-128-96h-96v96h96zm-128 96v-96H64v96z" />',viewBox:"0 0 512 512"},tableRowInsertBelowIcon:{name:"table-row-insert-below",content:'<path d="M480 480H0V352h480zM32 32h416v288H32zm128 256v-96H64v96zm128 0v-96h-96v96zm128 0v-96h-96v96zM320 64v96h96V64zm-32 0h-96v96h96zM64 64v96h96V64z" />',viewBox:"0 0 512 512"},tableUnmergeIcon:{name:"table-unmerge",content:'<path d="M32 32v416h416V32zm160 32h96v96h-96zm96 128v96h-96v-96zM64 64h96v96H64zm0 128h96v96H64zm96 224H64v-96h96zm128 0h-96v-96h96zm128 0h-96v-96h96zm0-128h-96v-96h96zm0-128h-96V64h96z" />',viewBox:"0 0 512 512"},tableWizardIcon:{name:"table-wizard",content:'<path d="M160 384V160h224v96l32 32V0H0v416h288l-32-32zM288 32h96v96h-96zm-128 0h96v96h-96zm-32 352H32v-96h96zm0-128H32v-96h96zm0-128H32V32h96zm376.6 362.1-15.5 15.5c-8.6 8.6-22.4 8.6-31 0l-124-124c-8.6-8.6-8.6-22.4 0-31l15.5-15.5c8.6-8.6 22.4-8.6 31 0l124 124c8.6 8.5 8.6 22.4 0 31m-158.5-209-21-14.8c-3.2-2.3-5.1-6-5.1-10l.3-25.7c.1-6.6-5.2-12.1-11.8-12.2-2.6 0-5.2.8-7.3 2.4l-20.6 15.4c-3.2 2.4-7.3 3-11 1.8l-24.3-8.3c-6.8-2.3-14.3 1.9-15.7 9.3-.4 2.1-.1 4.2.5 6.2l8.2 24.1c1.3 3.7.6 7.8-1.8 11l-15.4 20.6c-4.3 5.8-2.6 14.2 4 17.8 1.9 1 4 1.4 6.1 1.4l25.4-.3c3.9-.1 7.7 1.8 10 5.1l14.8 21c4.2 5.9 12.7 6.9 18.1 1.7 1.5-1.5 2.6-3.3 3.2-5.3l7.5-24.3c1.2-3.8 4.1-6.7 7.9-7.9l24.5-7.6c6.3-2 9.8-8.7 7.9-15-.7-2.7-2.3-4.9-4.4-6.4" />',viewBox:"0 0 512 512"},tellAFriendBoxIcon:{name:"tell-a-friend-box",content:'<path d="M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32M144 96c26.5 0 48 21.5 48 48s-21.5 48-48 48-48-21.5-48-48 21.5-48 48-48m80 320H64v-96c0-48.3 26-96 80.2-96 51.7 0 79.8 52.1 79.8 96zm223.6 0H288s0-192 80-192 79.6 192 79.6 192m-2-240.7c-11.1 7.9-24.3 16.7-78 16.7s-66.3-8.8-77.3-16.7c-1.5-1.3-2.4-3.1-2.4-5.1 0-4 3.6-7.2 8.2-7.5 13.6-2.3 23.8-13.8 23.8-25v-1.6c0-22.1 21.4-40.1 48-40.1h.9c26.1.4 47.1 18.2 47.1 40.1v1.6c0 11.2 10.2 22.7 23.8 25 4.6.4 8.2 3.6 8.2 7.5.1 2-.8 3.8-2.3 5.1" />',viewBox:"0 0 512 512"},tellAFriendIcon:{name:"tell-a-friend",content:'<path d="M383.5 64c-31.7 0-57.5 24-57.5 53.5v2.1c0 14.9-12.2 30.3-28.5 33.3-5.5.5-9.9 4.8-9.9 10.1 0 2.6 1.1 5 2.9 6.8 13.3 10.5 28.3 22.2 92.5 22.2s80.1-11.7 93.3-22.2c1.8-1.8 2.9-4.1 2.9-6.8 0-5.3-4.3-9.6-9.9-10.1-16.3-3-28.5-18.4-28.5-33.3v-2.1c0-29-25-52.7-55.9-53.5h-.5.2zc.2 0 0 0 0 0m.6 0h.9zM128 224c-64.9 0-96 70-96 128v96h192v-96c0-52.7-34-128-96-128m256 0c-96 0-96 224-96 224h192s0-224-96-224m-192-96c0 35.3-28.7 64-64 64s-64-28.7-64-64 28.7-64 64-64 64 28.7 64 64" />',viewBox:"0 0 512 512"},templateManagerIcon:{name:"template-manager",content:'<path d="M377.2 292.1c-5.5 5.3-7.2 6.4-7.4 6.6-.2.1-.4.2-.9.2-.1-.2-.3-.7-.5-1.7s-.5-4.2-.5-15.1v-31.7c0-9.9-.7-16.2-2.3-19.7-2.4-5.4-6.1-9.4-11.2-12-6.2-3.1-14-4.7-23.3-4.7-12.3 0-22.1 2.8-29 8.4-7.2 5.7-10.9 12.3-10.9 19.4 0 4.1 1.2 7.5 3.6 10 2.5 2.7 5.7 4 9.6 4s7.2-1.3 9.6-3.8c2.4-2.4 3.6-5.9 3.6-10.2l-.2-5.8c0-1.9.9-3.5 2.7-5.1s4.4-2.4 7.9-2.4c4.7 0 8.1 1.3 10.4 3.9 1.7 1.9 3.6 6.3 3.6 16.8v.9c-15.6 5.6-26.5 10.2-33.4 14.1-7.8 4.4-13.1 9.1-16.3 14.3-2.5 3.9-3.7 8.5-3.7 13.8 0 8.2 2.5 14.9 7.5 20 5 5.2 11.6 7.8 19.4 7.8 4.9 0 9.5-1 13.8-2.9 2.2-1 6.6-3.9 13.5-8.9.7 2.9 1.9 5.2 3.5 6.9 2.8 3.1 6.6 4.7 11.2 4.7 8.5 0 17.1-5.6 25.7-16.8l.8-1v-16.3zm-35.2-.2c-8.9 6.7-14.1 8.1-16.9 8.1h-.1c-2.8 0-5.1-1.1-7.4-3.6-2.3-2.4-3.5-5.6-3.5-9.5 0-3 .9-5.8 2.8-8.4 2.1-2.8 5.7-5.6 10.6-8.2 2.4-1.3 7.2-3.4 14.4-6.2zm-97.9 12.2c-1.3-1.4-4-5.6-7.9-17.9L195.6 160h-7.7l-41 124.9c-4.1 12.7-7 17.9-8.8 20.1-.3.4-1.8 1.8-7.4 3.1l-2.8.6V320h43v-11.7l-3.2-.3c-6.6-.6-8.3-2-8.6-2.3-.9-.9-1.3-1.9-1.3-3 0-1.6.5-4.8 2.6-11.5l5.3-16.2h42.1l4.6 14c2.6 8.1 3.1 12 3.1 13.8 0 1.3-.4 2.2-1.3 3.2-.3.4-1.9 1.6-7 1.9l-3.3.2V320h52v-11.8l-3.2-.3c-3.8-.3-6.6-1.5-8.6-3.8M172.5 254l14.7-44.6 14.4 44.6zM352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V128zm64 416H96V64h224v96h96zm-224-32h-64v-64h64zm96 0h-64v-64h64zm96 0h-64v-64h64z" />',viewBox:"0 0 512 512"},textClipIcon:{name:"text-clip",content:'<path d="M64 32v448h32V32zm384 448V32h-32v448zM320 320v-48H128v-32h192v-48l96 64z" />',viewBox:"0 0 512 512"},textOverflowIcon:{name:"text-overflow",content:'<path d="M288 304v176h32V304zm0-272v176h32V32zM64 32v448h32V32zm288 288v-48H128v-32h224v-48l96 64z" />',viewBox:"0 0 512 512"},textTruncateIcon:{name:"text-truncate",content:'<path d="M448 32v384h-32V64H95.92L96 480H64V32zm0 416h-32v32h32zm-64 .08h-31.92V480H384zm-64-.08h-32v32h32z" />',viewBox:"0 0 512 512"},textWrapArrowIcon:{name:"text-wrap-arrow",content:'<path d="M64 176v32h384v-32zm0-64v32h384v-32zm0 256v32h160v-32zm0-64v32h160v-32zm0 128v32h160v-32zm288-32v.12c5.22.04 10.43.04 16.04-.12zm94.44-64.64c-1.28 7.68-4.16 15.04-8 22.4-2.06 3.65-4.27 7.06-6.65 10.24-15.2 20.5-36.6 31.17-63.75 32H352v48l-96-64 96-64v48h14.12c18.88 0 33.28-7.68 43.2-23.68 2.24-3.84 3.84-7.68 5.12-11.52 2.24-8.32 2.24-16.96 0-24.96-2.88-10.56-9.28-20.48-18.88-26.88-8.64-6.08-18.24-8.96-28.8-8.96H64v-32h305.32c34.24.32 65.6 24.32 75.2 56.96.96 3.2 1.6 6.08 1.92 9.28 1.92 9.92 2.24 19.52 0 29.12M64 48v32h384V48z" />',viewBox:"0 0 512 512"},textWrapIcon:{name:"text-wrap",content:'<path d="M480 96v32H96V96zM352 256v224H32V256zm-32 32H64v160h256zm-32 32H96v32h192zm0 96v-32H96v32zM64 64h288V32H32v160h320v-32H64z" />',viewBox:"0 0 512 512"},textareaIcon:{name:"textarea",content:'<path d="M448 448h-32V256h32zM194 334c1.8 3.2 2.7 6.9 3 11.2h27c-.9-7.3-3.1-13.8-6.4-19.6s-7.6-10.5-12.7-14.2c-5.2-3.9-11.2-6.8-18-8.8-6.9-2-14.2-3-22.2-3-10.3 0-19.5 1.6-28 4.9s-15.7 8.1-21.8 14.4c-6 6.3-10.7 14.1-14 23.3S96 361.9 96 373.7c0 11.9 1.6 22.5 4.9 31.7 3.1 9.2 7.8 17 13.9 23.2 6 6.3 13.3 11.1 21.8 14.4 8.3 3.3 17.9 5 28.2 5 8 0 15.3-1 22.2-3 6.8-2 12.8-4.9 18-8.8 5.1-3.9 9.4-8.8 12.7-14.4s5.5-12.1 6.4-19.6h-27c-.3 4.2-1.2 7.9-3 11.2-1.8 3.2-4.2 5.9-7 8.1-3 2.2-6.3 3.9-10.1 4.9-3.9 1.2-7.9 1.7-12.2 1.7-6.3 0-11.9-1.2-17-3.5-5.2-2.3-9.7-5.8-13.4-10.4-3.7-4.5-6.6-10.2-8.5-17-2.1-6.8-3.1-14.7-3.1-23.6 0-9.1 1-17.1 3.1-23.9 2.1-6.9 5.1-12.5 8.8-17.1 3.7-4.5 8-7.8 13.3-10.1 5.1-2.3 10.7-3.5 16.8-3.5 4.3 0 8.3.6 12.2 1.7 3.9 1.2 7.2 2.7 10.1 4.9 2.8 2.4 5.2 5.1 6.9 8.4m14-252.4c-10.6-7.5-25.2-11.1-44.1-11.1-40.5 0-61.7 15-63.6 45.2h26.1c.7-16.8 12.8-25 36-25 11 0 19.2 1.6 24.4 4.8 2.6 1.6 4.6 3.3 6.2 5.1 1.5 1.9 2.5 4 3.2 6.6s1.2 5.6 1.4 9.4c.1 3.6.1 8.2.1 13.6h-12.8c-59.4 0-89.1 17.2-89.1 51.4 0 6.4 1.3 12 3.8 17.2 2.5 5.3 6 9.7 10.4 13.4 4.4 3.8 9.7 6.6 16 8.7 6.1 2.2 12.8 3.2 20 3.2 20.9 0 38.2-6.2 51.7-18.6v17.9H224v-97.8c0-22.1-5.4-36.7-16-44m-10.1 100.2c-2.3 3.3-5.1 6.2-8.4 9-3.2 2.6-6.8 4.9-10.7 6.8s-8 3.3-12.2 4.3-8.6 1.4-12.8 1.4c-9.6 0-17-2-22.5-5.9-5.5-4-8.3-9.8-8.3-17.2 0-20.7 18.9-30.9 56.9-30.9h18zM380 115.7c-2.7-9.3-6.6-17.2-11.8-23.8-5-6.4-11.4-11.5-18.7-15-7.5-3.4-16-5.2-25.5-5.2-16.4 0-30.2 6.9-41.7 20.5V32H256v192h26.2v-14.8c10.9 9.7 24.3 14.8 40 14.8 8.8 0 17-1.9 24.5-5.4 7.6-3.7 14.1-8.9 19.7-15.5 5.5-6.7 9.8-14.9 13-24.4 3-9.6 4.6-20.4 4.6-32.1 0-11.5-1.3-21.8-4-30.9m-32.6 73.6c-6.6 9.5-15.6 14.2-26.8 14.2-14.5 0-27.4-5.9-38.4-17.8v-69.1c11.9-16.6 25-24.9 39.4-24.9 11.4 0 20 4.6 26.2 13.9 6.2 9.2 9.3 22.9 9.3 41 .1 18.9-3.2 33.3-9.7 42.7M256 370.6c0 11.8 1.6 22.5 4.6 32.1 3.2 9.5 7.5 17.6 13 24.4 5.6 6.6 12.1 11.8 19.7 15.5 7.5 3.6 15.7 5.4 24.5 5.4 15.7 0 29.1-5 40-14.8V448H384V256h-26.2v60.1c-11.5-13.6-25.3-20.5-41.7-20.5-9.5 0-18 1.7-25.5 5.2-7.3 3.6-13.7 8.6-18.7 15-5.2 6.6-9.1 14.5-11.8 23.8-2.8 9.2-4.1 19.5-4.1 31m26.8 0c0-18.1 3.2-31.8 9.3-41 6.2-9.3 14.8-13.9 26.2-13.9 14.4 0 27.5 8.3 39.4 24.9v69.1c-11.1 11.9-23.9 17.8-38.4 17.8-11.2 0-20.2-4.7-26.8-14.2-6.4-9.4-9.7-23.8-9.7-42.7" />',viewBox:"0 0 512 512"},textboxHiddenIcon:{name:"textbox-hidden",content:'<path d="M0 160h32v64H0zm0-32h32V64H0zm0 288h32v-64H0zm160 96h64v-32h-64zm-96 0h64v-32H64zM352 0h-64v32h64zm-96 0h-64v32h64zM0 512h32v-64H0zM448 0h-64v32h64zM160 0H96v32h64zM64 0H0v32h64zM0 320h32v-64H0zm480 128h32v-64h-32zm0-96h32v-64h-32zm0-96h32v-64h-32zm0-96h32V96h-32zm0-160v64h32V0zm-32 512h64v-32h-64zm-192 0h64v-32h-64zm96 0h64v-32h-64zm-6-165.4c-7.4 3.6-15.6 5.4-24.3 5.4-15.6 0-28.9-5-39.7-14.8V352h-26V160h26v60.1c11.4-13.6 25.1-20.5 41.4-20.5 9.4 0 17.9 1.7 25.3 5.2 7.2 3.6 13.6 8.6 18.6 15 5.2 6.6 9 14.5 11.7 23.8 2.7 9.2 4 19.5 4 31 0 11.8-1.6 22.5-4.6 32.1-3.2 9.5-7.4 17.6-12.9 24.4-5.5 6.6-12 11.7-19.5 15.5m10.9-72c0-18.1-3.2-31.8-9.3-41-6.2-9.3-14.8-13.9-26.2-13.9-14.4 0-27.5 8.3-39.4 24.9v69.1c11.1 11.9 23.9 17.8 38.4 17.8 11.2 0 20.2-4.7 26.8-14.2 6.4-9.4 9.7-23.8 9.7-42.7M224 253.5V351h-26v-17.6S167.1 352 146.2 352c-7.3 0-13.9-1-20-3.2-6.2-2-11.6-4.9-16-8.7-4.5-3.8-8-8.1-10.4-13.4-2.5-5.2-3.8-10.8-3.8-17.2 0-34.2 29.8-51.4 89.1-51.5h12.8c0-5.2 0-9.9-.1-13.5-.3-3.8-.7-6.8-1.4-9.4s-1.7-4.8-3.2-6.6c-1.6-1.7-3.6-3.5-6.2-5.1-5.2-3.2-13.4-4.8-24.4-4.8-23.2 0-35.3 8.2-36 24.4h-26.1c1.9-29.6 23.1-44.6 63.6-44.6 18.9 0 33.5 3.6 44.1 11.1 10.4 7.4 15.8 22 15.8 44M198 277h-18c-38 0-56.9 10.3-56.9 30.9 0 7.4 2.8 13.1 8.3 17.2 5.5 3.9 12.9 5.9 22.5 5.9 4.2 0 8.6-.4 12.8-1.4s8.3-2.5 12.2-4.3c3.9-1.9 7.5-4.2 10.7-6.8 3.3-2.7 6.1-5.6 8.4-9zM448 64h-32v384h32z" />',viewBox:"0 0 512 512"},textboxIcon:{name:"textbox",content:'<path d="M208 209.6c-10.6-7.5-25.2-11.1-44.1-11.1-40.5 0-61.7 15-63.6 45.2h26.1c.7-16.8 12.8-25 36-25 11 0 19.2 1.6 24.4 4.8 2.6 1.6 4.6 3.3 6.2 5.1 1.5 1.9 2.5 4 3.2 6.6s1.2 5.6 1.4 9.4c.1 3.6.1 8.2.1 13.6h-12.8c-59.4 0-89.1 17.2-89.1 51.4 0 6.4 1.3 12 3.8 17.2 2.5 5.3 6 9.7 10.4 13.4 4.4 3.8 9.7 6.6 16 8.7 6.1 2.2 12.8 3.2 20 3.2 20.9 0 38.2-6.2 51.7-18.6v17.9H224v-97.8c0-22.1-5.4-36.7-16-44m-10.1 100.2c-2.3 3.3-5.1 6.2-8.4 9-3.2 2.6-6.8 4.9-10.7 6.8s-8 3.3-12.2 4.3-8.6 1.4-12.8 1.4c-9.6 0-17-2-22.5-5.9-5.5-4-8.3-9.8-8.3-17.2 0-20.7 18.9-30.9 56.9-30.9h18zm170.3-89.9c-5-6.4-11.4-11.5-18.7-15-7.5-3.4-16-5.2-25.5-5.2-16.4 0-30.2 6.9-41.7 20.5V160H256v192h26.2v-14.8c10.9 9.7 24.3 14.8 40 14.8 8.8 0 17-1.9 24.5-5.4 7.6-3.7 14.1-8.9 19.7-15.5 5.5-6.7 9.8-14.9 13-24.4 3-9.6 4.6-20.4 4.6-32.1 0-11.5-1.3-21.8-4-31-2.8-9.3-6.7-17.1-11.8-23.7m-20.8 97.4c-6.6 9.5-15.6 14.2-26.8 14.2-14.5 0-27.4-5.9-38.4-17.8v-69.1c11.9-16.6 25-24.9 39.4-24.9 11.4 0 20 4.6 26.2 13.9 6.2 9.2 9.3 22.9 9.3 41 .1 18.9-3.2 33.3-9.7 42.7M448 64v384h-32V64z" />',viewBox:"0 0 512 512"},thumbDownIcon:{name:"thumb-down",content:'<path d="M12.2 208a47.8 47.8 0 0 1 23.2-78.3 48 48 0 0 1 32-64A48 48 0 0 1 112 0h160c38 0 55 14 80 32v224c-29 47-53 99-64.3 149.5A48 48 0 0 1 192 400V288H48a48 48 0 0 1-35.8-80M384 32v224a32 32 0 0 0 32 32h64a32 32 0 0 0 32-32V32a32 32 0 0 0-32-32h-64a32 32 0 0 0-32 32" />',viewBox:"0 0 512 512"},thumbDownOutlineIcon:{name:"thumb-down-outline",content:'<path d="M0 240a48 48 0 0 0 48 48h144v112a48 48 0 0 0 95.7 5.5C299 355 323 303 352 256a32 32 0 0 0 32 32h96a32 32 0 0 0 32-32V32a32 32 0 0 0-32-32h-96a32 32 0 0 0-32 32c-25-18-42-32-80-32H112a48 48 0 0 0-44.6 65.7 48 48 0 0 0-32 64A48 48 0 0 0 12.2 208 47.8 47.8 0 0 0 0 240M383.8 31.7h96v224h-96zm-332 160h-6c-8.8 0-14-7.2-14-16s7.1-16 16-16h32a16 16 0 1 0 0-32h-2c-8.9 0-14-7.2-14-16s7.1-16 16-16h32a16 16 0 1 0 0-32 16 16 0 1 1 0-32h160c23 2 65 36 80 48v128c-49 50-85 142-96 192a16 16 0 1 1-32 0v-144h-176c-8.9 0-16-7.2-16-16s5.1-16 14-16h5.8c8-1 14.2-7.9 14.2-16s-6.2-15-14-16" />',viewBox:"0 0 512 512"},thumbUpIcon:{name:"thumb-up",content:'<path d="M499.8 240a47.8 47.8 0 0 1-23.2 78.3 48 48 0 0 1-32 64A48 48 0 0 1 400 448H240c-38 0-55-14-80-32V192c29-47 53-99 64.3-149.5A48 48 0 0 1 320 48v112h144a48 48 0 0 1 35.8 80M128 416V192a32 32 0 0 0-32-32H32a32 32 0 0 0-32 32v224a32 32 0 0 0 32 32h64a32 32 0 0 0 32-32" />',viewBox:"0 0 512 512"},thumbUpOutlineIcon:{name:"thumb-up-outline",content:'<path d="M512 208a48 48 0 0 0-48-48H320V48a48 48 0 0 0-95.7-5.5C213 93 189 145 160 192a32 32 0 0 0-32-32H32a32 32 0 0 0-32 32v224a32 32 0 0 0 32 32h96a32 32 0 0 0 32-32c25 18 42 32 80 32h160a48 48 0 0 0 44.6-65.7 48 48 0 0 0 32-64 48 48 0 0 0 23.2-78.3 47.8 47.8 0 0 0 12.2-32M128.2 416.3h-96v-224h96zm332-160h6c8.8 0 14 7.2 14 16s-7.2 16-16 16h-32a16 16 0 1 0 0 32h2c8.8 0 14 7.2 14 16s-7.2 16-16 16h-32a16 16 0 1 0 0 32 16 16 0 1 1 0 32h-160c-23-2-65-36-80-48v-128c49-50 85-142 96-192a16 16 0 1 1 32 0v144h176a16 16 0 0 1 16 16c0 8.9-5.2 16-14 16h-5.8a16.2 16.2 0 0 0-.1 32Z" />',viewBox:"0 0 512 512"},thumbnailsDownIcon:{name:"thumbnails-down",content:'<path d="M352 352h96v96h-96zm-160 0h96v96h-96zm-160 0h96v96H32zm0-320h416v256H32z" />',viewBox:"0 0 512 512"},thumbnailsLeftIcon:{name:"thumbnails-left",content:'<path d="M32 32v96h96V32zm160 0v416h256V32zM32 192v96h96v-96zm0 160v96h96v-96z" />',viewBox:"0 0 512 512"},thumbnailsRightIcon:{name:"thumbnails-right",content:'<path d="M352 352h96v96h-96zm0-160h96v96h-96zm0-160h96v96h-96zM32 32h256v416H32z" />',viewBox:"0 0 512 512"},thumbnailsUpIcon:{name:"thumbnails-up",content:'<path d="M352 32h96v96h-96zm-160 0h96v96h-96zM32 32h96v96H32zm0 160h416v256H32z" />',viewBox:"0 0 512 512"},tocSectionIcon:{name:"toc-section",content:'<path d="M96 32c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32zm320 416H96V64h320zm-32-288H224v-32h160zm-64 64h-96v-32h96zm0 64h-96v-32h96zm64 64H224v-32h160z" />',viewBox:"0 0 512 512"},tocSectionLevelIcon:{name:"toc-section-level",content:'<path d="M96 32c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32zm320 416H96V64h320zm-32-288H192v-32h192zm0 64h-96v-32h96zm0 64h-96v-32h96zm0 64h-96v-32h96zm-192-32v-96l64 48z" />',viewBox:"0 0 512 512"},toggleFullScreenModeIcon:{name:"toggle-full-screen-mode",content:'<path d="M448 32H64c-17.6 0-32 14.4-32 32v288c0 17.6 14.4 32 32 32h384c17.6 0 32-14.4 32-32V64c0-17.6-14.4-32-32-32m0 319.942a1 1 0 0 1-.058.058H64.058a.5.5 0 0 1-.058-.058V64.057a1 1 0 0 1 .057-.057h383.885q.031.027.058.057zM384 480H128c35.346 0 64-28.654 64-64h128c0 35.346 28.654 64 64 64m32-160H96c58.263-113.973 183.21-192 320-192z" />',viewBox:"0 0 512 512"},toolbarFloatIcon:{name:"toolbar-float",content:'<path d="M64 352h416v128H64zm96 32H96v64h96v-64zm160 0h-96v64h96zm32 0v64h96v-64zM63.961 131.844l90.51 90.51 45.255-45.255-90.51-90.51zm0 0 90.51 90.51 45.255-45.255-90.51-90.51zm158.392 67.882 67.882-67.882-22.627-22.627-22.627 22.627-90.51-90.51c-12.445-12.445-32.81-12.445-45.255 0l-67.882 67.882c-12.445 12.445-12.445 32.81 0 45.255l90.51 90.51-22.627 22.627 22.627 22.627 67.882-67.882L297.373 320 320 297.373zm-67.882 22.627-90.51-90.51 45.255-45.255 90.51 90.51zM480 256h-64v64h64z" />',viewBox:"0 0 512 512"},trackChangesAcceptAllIcon:{name:"track-changes-accept-all",content:'<path d="M128 160H96V96c0-17.7 14.3-32 32-32h224l64 64h-96V96H128zm264.5 51.6 67.9 67.9-141.6 141.6-28.1 26.9H224v-66.7l26.9-28.1zm22.6 67.9-22.6-22.6-135.8 135.8L268 404l11.3 11.3zM416 480H128v-96H96v96c0 17.7 14.3 32 32 32h288c17.7 0 32-14.3 32-32V337.155l-32 32zm86.7-288-22.6-22.6c-12.5-12.4-32.9-12.4-45.3 0L412.2 192l67.8 67.8 22.7-22.5c12.4-12.5 12.4-32.9 0-45.3M160 448h32v-32h-32zM64 32h256L288 0H64C46.3 0 32 14.3 32 32v128h32zm0 352H32v32c0 17.7 14.3 32 32 32zm179-253L112 262l-67-67-45 45 112 112 176-176z" />',viewBox:"0 0 512 512"},trackChangesAcceptIcon:{name:"track-changes-accept",content:'<path d="M128 128H96V64c0-17.7 14.3-32 32-32h224l64 64h-96V64H128zm122.9 193.2L224 349.3V416h66.7l28.1-26.9 141.6-141.6-67.9-67.9zm28.4 62.1L268 372l-11.3-11.3 135.8-135.8 22.6 22.6zM416 337.155l32-32V448c0 17.7-14.3 32-32 32H128c-17.7 0-32-14.3-32-32v-96h32v96h288zM502.7 205.3 480 227.8 412.2 160l22.6-22.6c12.4-12.4 32.8-12.4 45.3 0l22.6 22.6c12.4 12.4 12.4 32.8 0 45.3M288 144 112 320 0 208l45-45 67 67L243 99zm-96 272h-32v-32h32z" />',viewBox:"0 0 512 512"},trackChangesEnableIcon:{name:"track-changes-enable",content:'<path d="M502.7 173.3 480 195.8 412.2 128l22.6-22.6c12.4-12.4 32.8-12.4 45.3 0l22.6 22.6c12.4 12.4 12.4 32.8 0 45.3m-110.2-25.7 67.9 67.9-141.6 141.6-28.1 26.9H224v-66.7l26.9-28.1zm22.6 67.9-22.6-22.6-135.8 135.8L268 340l11.3 11.3zM160 320h32v-32h-32zm0-64h96v-32h-96zm128-96H160v32h128zM160 384h32v-32h-32zm256 64H96V64h224v96l80.11-79.89L352 32H96c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V273.155l-32 32z" />',viewBox:"0 0 512 512"},trackChangesIcon:{name:"track-changes",content:'<path d="m412.2 256 22.6-22.6c12.4-12.4 32.8-12.4 45.3 0l22.6 22.6c12.4 12.4 12.4 32.8 0 45.3L480 323.8zm-19.7 19.6L250.9 417.2 224 445.3V512h66.7l28.1-26.9 141.6-141.6zM279.3 479.3 268 468l-11.3-11.3 135.8-135.8 22.6 22.6zM288 160H160v32h128zm64 64H160v32h192zm-64 64H160v32h128zm-64 64h-64v32h64zm188.2-96 22.6-22.6c12.4-12.4 32.8-12.4 45.3 0l22.6 22.6c12.4 12.4 12.4 32.8 0 45.3L480 323.8zm-19.7 19.6L250.9 417.2 224 445.3V512h66.7l28.1-26.9 141.6-141.6zM279.3 479.3 268 468l-11.3-11.3 135.8-135.8 22.6 22.6zM96 416V64h224v96h96v32h32v-64l-96-96H96c-17.7 0-32 14.3-32 32v352c0 17.7 14.3 32 32 32h96v-32zM0 512h192v-32H0z" />',viewBox:"0 0 512 512"},trackChangesRejectAllIcon:{name:"track-changes-reject-all",content:'<path d="M102.627 272 160 329.373 137.373 352 80 294.627 22.627 352 0 329.373 57.373 272 0 214.627 22.627 192 80 249.373 137.373 192 160 214.627zM128 96h192v32h96l-64-64H128c-17.7 0-32 14.3-32 32v64h32zm264.5 115.6 67.9 67.9-141.6 141.6-28.1 26.9H224v-66.7l26.9-28.1zm22.6 67.9-22.6-22.6-135.8 135.8L268 404l11.3 11.3zM416 480H128v-96H96v96c0 17.7 14.3 32 32 32h288c17.7 0 32-14.3 32-32V337.155l-32 32zm86.7-288-22.6-22.6c-12.5-12.4-32.9-12.4-45.3 0L412.2 192l67.8 67.8 22.7-22.5c12.4-12.5 12.4-32.9 0-45.3M160 448h32v-32h-32zM64 32h256L288 0H64C46.3 0 32 14.3 32 32v128h32zm0 352H32v32c0 17.7 14.3 32 32 32z" />',viewBox:"0 0 512 512"},trackChangesRejectIcon:{name:"track-changes-reject",content:'<path d="M102.627 272 160 329.373 137.373 352 80 294.627 22.627 352 0 329.373 57.373 272 0 214.627 22.627 192 80 249.373 137.373 192 160 214.627zM192 384v-32h-32v32zm310.7-256-22.6-22.6c-12.5-12.4-32.9-12.4-45.3 0L412.2 128l67.8 67.8 22.7-22.5c12.4-12.5 12.4-32.9 0-45.3M96 64h224v96l80.11-79.89L352 32H96c-17.7 0-32 14.3-32 32v96h32zm296.5 83.6 67.9 67.9-141.6 141.6-28.1 26.9H224v-66.7l26.9-28.1zm22.6 67.9-22.6-22.6-135.8 135.8L268 340l11.3 11.3zM416 448H96v-64H64v64c0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32V273.155l-32 32z" />',viewBox:"0 0 512 512"},transparencyIcon:{name:"transparency",content:'<path d="M64 64v352h352V64zm32 32h96v96h96V96h96v96h-96v96h96v96h-96v-96h-96v96H96v-96h96v-96H96z" />',viewBox:"0 0 512 512"},trashIcon:{name:"trash",content:'<path d="M416 96h-96V64c0-17.6-14.4-32-32-32h-96c-17.6 0-32 14.4-32 32v32H64v64h32v288c0 17.6 14.4 32 32 32h224c17.6 0 32-14.4 32-32V160h32zM192 64h95.9l.1.1V96h-96c.1-.1.1-32.1 0-32m160 384H128.1l-.1-.1V160h32v256h32V160h32v256h32V160h32v256h32V160h32z" />',viewBox:"0 0 512 512"},tumblrBoxIcon:{name:"tumblr-box",content:'<path d="M448 32H64c-17.6 0-32 14.4-32 32v384c0 17.6 14.4 32 32 32h384c17.6 0 32-14.4 32-32V64c0-17.6-14.4-32-32-32m-96.1 366c-12.7 6.4-28.5 11.6-38.9 14.2s-21.6 3.9-33.7 3.9c-13.7 0-21.8-1.9-32.3-5.5-10.5-3.7-19.9-9-27.3-15.8-7.4-6.9-12.6-14.1-15.4-21.8-2.9-7.7-4.3-18.9-4.3-33.5V224h-40v-42.2c11.7-4.1 25.3-9.9 33.6-17.6 8.4-7.6 15.1-16.8 20.2-27.5s8.6-24.3 10.5-40.8H267v64h53v64h-53v85.2c0 18.6-.2 29.3 1.6 34.5s6.4 10.7 11.4 13.8c6.6 4.2 14.2 6.4 22.7 6.4 15.1 0 34.3-5.9 49.3-16.5V398z" />',viewBox:"0 0 512 512"},tumblrIcon:{name:"tumblr",content:'<path d="M192.6 32c-2.8 23.1-8.1 42.1-15.7 57.1s-17.7 27.8-30.3 38.5-33 18.9-50.6 24.6V224h61v148.7c0 20.5 2.1 36.1 6.4 46.9s12 21 23.1 30.6c11.1 9.5 25 16.9 40.7 22.1s27.8 7.7 48.3 7.7q27 0 50.4-5.4c15.5-3.6 39.1-10.9 58.2-19.9V384c-22.3 14.8-51 22.9-73.7 22.9-12.8 0-24-3-33.9-8.9-7.5-4.4-14.3-12-17-19.2-2.8-7.4-2.4-22.3-2.4-48.2V224h96v-96h-96V32z" />',viewBox:"0 0 512 512"},twitterBoxIcon:{name:"twitter-box",content:'<path d="M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32m-64.7 159.7c.1 2.8.2 5.6.2 8.4 0 85.4-66 183.9-186.8 183.9-37.1 0-71.6-10.7-100.6-29.1 5.1.6 10.4.9 15.7.9 30.8 0 59.1-10.4 81.5-27.7-28.7-.5-53-19.2-61.3-44.9 4 .7 8.1 1.2 12.4 1.2 6 0 11.8-.8 17.3-2.3-30-5.9-52.7-32-52.7-63.3v-.8c8.9 4.8 19 7.7 29.7 8.1-17.6-11.6-29.2-31.4-29.2-53.8 0-11.8 3.2-22.9 8.9-32.5 32.4 39.1 80.8 64.8 135.3 67.5-1.1-4.7-1.7-9.7-1.7-14.7 0-35.7 29.4-64.6 65.6-64.6 18.9 0 36 7.8 47.9 20.4 14.9-2.9 29-8.3 41.7-15.7-4.9 15.1-15.3 27.7-28.9 35.7 13.3-1.6 26-5.1 37.7-10.2-8.9 13.1-19.9 24.5-32.7 33.5" />',viewBox:"0 0 512 512"},twitterIcon:{name:"twitter",content:'<path d="M342 64c-50.8 0-91.9 41.2-91.9 91.9q0 10.8 2.4 21c-76.4-3.8-144.1-40.4-189.4-96-7.9 13.6-12.4 29.3-12.4 46.2 0 31.9 16.2 60 40.9 76.5-15.1-.5-29.2-4.6-41.6-11.5v1.2c0 44.5 31.7 81.7 73.7 90.1-7.7 2.1-15.8 3.3-24.2 3.3-5.9 0-11.7-.6-17.3-1.6 11.7 36.5 45.6 63.1 85.9 63.8-31.7 24.5-71.3 39.2-114.3 39.2-7.4 0-14.8-.4-22-1.3 40.7 26 89 41.3 140.9 41.3 169.1 0 261.5-140.1 261.5-261.5 0-4-.1-8-.2-11.9 18-12.9 33.5-29.1 45.9-47.6-16.5 7.3-34.2 12.3-52.8 14.5 19-11.4 33.6-29.4 40.4-50.8-17.8 10.5-37.4 18.2-58.4 22.3C392.3 75.1 368.4 64 342 64" />',viewBox:"0 0 512 512"},underlineIcon:{name:"underline",content:'<path d="M128 416h256v32H128zM320 64v224c0 11.6-3.5 16-10.3 20.3-11.8 7.4-31.3 11.7-53.7 11.7s-41.9-4.3-53.7-11.7c-6.8-4.3-10.3-8.7-10.3-20.3V64h-64v224c0 70.4 64.3 96 128 96s128-25.6 128-96V64z" />',viewBox:"0 0 512 512"},undoIcon:{name:"undo",content:'<path d="M479.9 416c-57.7-56.6-136.7-96-223.9-96v128L32 256 256 64v128c122.2 0 221.5 102.4 223.9 224" />',viewBox:"0 0 512 512"},ungroupIcon:{name:"ungroup",content:'<path d="M32 256h192v192H32zm32-64h128V64H64zm224 224h128V288H288zM256 32v192h192V32z" />',viewBox:"0 0 512 512"},unlinkIcon:{name:"unlink",content:'<path d="M384 384c-47.4 0-88.7-25.8-110.8-64H384c35.4 0 64-28.6 64-64s-28.7-64-64-64H273.2c22.1-38.2 63.5-64 110.8-64 70.7 0 128 57.3 128 128s-57.3 128-128 128M64 256c0 35.4 28.6 64 64 64h110.8c-22.1 38.2-63.5 64-110.8 64C57.3 384 0 326.7 0 256s57.3-128 128-128c47.4 0 88.7 25.8 110.8 64H128c-35.3 0-64 28.6-64 64M272 97.6V0h-32v97.6c5.2-1 10.5-1.6 16-1.6s10.8.6 16 1.6m-60.1 11.7-69-69-22.6 22.6 69 69c5.9-9 13.6-16.7 22.6-22.6m110.8 22.6 69-69-22.6-22.6-69 69c9 5.9 16.7 13.6 22.6 22.6M256 416c-5.5 0-10.8-.6-16-1.6V512h32v-97.6c-5.2 1-10.5 1.6-16 1.6m-66.7-35.9-69 69 22.6 22.6 69-69c-9-5.9-16.7-13.6-22.6-22.6m110.8 22.6 69 69 22.6-22.6-69-69c-5.9 9-13.6 16.7-22.6 22.6" />',viewBox:"0 0 512 512"},unlinkVerticalIcon:{name:"unlink-vertical",content:'<path d="M414.4 272H512v-32h-97.6c1 5.2 1.6 10.5 1.6 16s-.5 10.8-1.6 16m-11.6-60.1 69-69-22.6-22.6-69 69c8.9 5.9 16.6 13.6 22.6 22.6m-22.7 110.8 69 69 22.6-22.6-69-69c-5.9 9-13.6 16.7-22.6 22.6M96 256c0-5.5.6-10.8 1.6-16H0v32h97.6c-1-5.2-1.6-10.5-1.6-16m35.9-66.8-69-69-22.6 22.6 69 69c5.9-8.9 13.6-16.6 22.6-22.6m-22.6 110.9-69 69 22.6 22.6 69-69c-9-5.9-16.7-13.6-22.6-22.6M128 384c0-47.4 25.8-88.7 64-110.8V384c0 35.4 28.6 64 64 64s64-28.7 64-64V273.2c38.2 22.1 64 63.5 64 110.8 0 70.7-57.3 128-128 128s-128-57.3-128-128M256 64c-35.4 0-64 28.6-64 64v110.8c-38.2-22.1-64-63.5-64-110.8C128 57.3 185.3 0 256 0s128 57.3 128 128c0 47.4-25.8 88.7-64 110.8V128c0-35.4-28.6-64-64-64" />',viewBox:"0 0 512 512"},unlockIcon:{name:"unlock",content:'<path d="M416 224H224v-96c0-53-43-96-96-96s-96 43-96 96v128h32V128c0-35.3 28.7-64 64-64s64 28.7 64 64v96h-32c-17.6 0-32 14.4-32 32v192c0 17.6 14.4 32 32 32h256c17.6 0 32-14.4 32-32V256c0-17.6-14.4-32-32-32M288 384c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32" />',viewBox:"0 0 512 512"},unpinIcon:{name:"unpin",content:'<path d="M256 320h160c17.6 0 32-14.4 32-32v-96c0-17.6-14.4-32-32-32H256V96h-32v128H64v32h160v128h32zm0-128h160v64H256z" />',viewBox:"0 0 512 512"},unstickIcon:{name:"unstick",content:'<path d="M290.6 131.4c12.4-12.4 12.4-32.6 0-45l-45-45c-12.4-12.4-32.6-12.4-45 0L178 63.8l90.1 90zM268.1 334c-24.9 24.9-65.2 24.9-90.1 0s-24.9-65.2 0-90.1l67.5-67.5-90-90.1L88 153.9C13.4 228.5 13.4 349.4 88 424s195.5 74.6 270.1 0l67.5-67.5-90-90.1zm202.6-67.5-45-45c-12.4-12.4-32.6-12.4-45 0L358.2 244l90 90 22.5-22.5c12.4-12.4 12.4-32.6 0-45" />',viewBox:"0 0 512 512"},uploadIcon:{name:"upload",content:'<path d="M32 384v96h448v-96zm192-64h64V192h96L256 32 128 192h96z" />',viewBox:"0 0 512 512"},userIcon:{name:"user",content:'<path d="M352 128c0 53-43 96-96 96s-96-43-96-96 43-96 96-96 96 43 96 96m-96 128c-106 0-192 86-192 192 0 17.7 14.3 32 32 32h320c17.7 0 32-14.3 32-32 0-106-86-192-192-192" />',viewBox:"0 0 512 512"},userOutlineIcon:{name:"user-outline",content:'<path d="M256 224c53.02 0 96-42.98 96-96s-42.98-96-96-96-96 42.98-96 96 42.98 96 96 96m0-32c-35.348 0-64-28.654-64-64s28.652-64 64-64 64 28.654 64 64-28.652 64-64 64M96 480c-17.7 0-32-14.301-32-32 0-106 86-192 192-192s192 86 192 192c0 17.699-14.301 32-32 32zm160-192c-88.367 0-160 71.635-160 160h320c0-88.365-71.633-160-160-160" />',viewBox:"0 0 512 512"},validationDataIcon:{name:"validation-data",content:'<path d="m64 352 64-64 96 96 288-160-288 288zm48.6-193.6c0 13-2.5 24.4-7.6 34.4s-12.3 17.7-21.8 23.1Q69.1 224 50.5 224H0V96h49.5c42.1 0 63.1 20.8 63.1 62.4m-38 .3c0-6.3-1.2-12-3.5-17-2.4-5-5.7-8.9-10.1-11.7-4.4-2.7-9.6-4.1-15.6-4.1H36v68h10.1c8.6 0 15.6-3.2 20.7-9.5 5.2-6.4 7.8-14.9 7.8-25.7M216.2 224l-5.5-24h-37.2l-5.9 24H128l42.3-128h45.9L256 224zm-23.6-100h-.9c-.1 1.4-.5 3.8-1.2 7.1s-4.1 17.2-10.4 41.9h23.4l-8.6-34.7c-1.1-5-1.9-9.8-2.3-14.3m127.4 4v96h-32v-96h-32V96h98v32zm120.2 96-5.5-24h-37.2l-5.9 24H352l42.3-128h45.9L480 224zm-23.6-100h-.9c-.1 1.4-.5 3.8-1.2 7.1s-4.1 17.2-10.4 41.9h23.4l-8.6-34.7c-1.1-5-1.9-9.8-2.3-14.3" />',viewBox:"0 0 512 512"},validationXhtmlIcon:{name:"validation-xhtml",content:'<path d="M192 224h-54l-26.2-96L86 224H32L0 64h42l22 96 22-96h52l22 96 22-96h42zm272.5-121.8c4.7 4.2 7.4 9.8 8.5 16.8h38.9c-2-17.9-8.6-31.3-19.9-40.8-11.5-9.3-26.5-14-45.6-14-11.9 0-22.5 1.7-32 5.3-9.4 3.6-17.4 8.9-23.9 15.7-6.7 6.9-11.6 15.2-15.1 25-3.5 10-5.3 21.2-5.3 33.8 0 12.8 1.8 24 5.3 33.8 3.5 10 8.3 18.4 14.8 25.1s14.5 11.8 23.8 15.4c9.4 3.6 20 5.4 31.6 5.4 19.4 0 34.7-4.8 45.9-14.3q16.8-14.25 20.4-40.5H473c-.9 7-3.7 12.6-8.3 16.8-4.7 4.3-10.7 6.3-18.3 6.3-9.8 0-17.5-3.9-23.5-11.7-5.8-7.8-8.6-19.9-8.6-36.3 0-16.7 2.8-28.7 8.6-36.5 5.9-7.8 13.6-11.5 23.5-11.5 7.5 0 13.6 2 18.1 6.2M316.7 219.8c7.3-2.3 13.6-5.8 18.9-10.2l.1-.1c5.2-4.6 9.1-9.9 11.8-16.1 2.8-6 4.2-12.7 4.2-20.7 0-10-2.7-18.4-8-25.3q-5.25-6.6-13.2-10.5c.3-.3.7-.5 1-.8 3.1-2.4 5.5-5 7.6-8.1 2-3 3.5-6.2 4.5-9.4 1-3.5 1.5-6.9 1.5-10.4 0-6.6-1.3-12.6-3.9-18.1-2.6-5.4-6.4-10.3-11.4-14.2-4.8-4.2-10.5-7.2-17-9.1-6.3-1.8-13.7-2.8-22.1-2.8-7.4 0-14.3 1-20.8 3.1-6.3 2.1-11.7 5.2-16.9 9.3-5 4.1-9 9.2-11.9 15.1-3 5.9-4.9 12.7-5.6 20.3l-.5 5.1h38.2l.5-4.4c1.6-14.6 9.9-16.5 16.9-16.5 4.8 0 8.3 1.1 10.7 3.3l.1.1c2.7 2.5 3.3 7.1 3.3 10.4 0 5.6-1.2 9.4-3.8 11.4l-.1.1c-2.8 2.4-7.2 3.5-13.4 3.5H276v31h13.7c7.4 0 12.8 1.4 16.3 4 3.3 2.7 4.9 6.5 4.9 12.2 0 2.9-.5 5.6-1.4 8-.9 2.3-2.1 4.1-3.9 5.9-1.4 1.5-3.4 2.7-5.9 3.6-2.4.9-5.2 1.4-8.4 1.4-3.4 0-6.3-.4-9-1.3-2.2-.8-4.1-2-5.7-3.5-1.6-1.6-2.8-3.3-3.7-5.2-.8-1.9-1.2-4.1-1.5-6.7l-.4-4.2h-39.1l.3 5c.5 7.4 2.3 14.5 5.3 21 3.1 6.1 7.8 11.8 14.2 16.6 4.9 3.8 10.8 6.6 17.8 8.4h.4c6.4 1.5 13.8 2.3 22.1 2.3 9.5 0 17.5-1.2 24.7-3.5M64 352l64-64 96 96 288-160-288 288z" />',viewBox:"0 0 512 512"},vbIcon:{name:"vb",content:'<path d="m32 160 73.2 224h76.7L256 160h-71.1l-33.7 137c-2.6 10.3-4.3 19-4.9 25.9h-1.6c-.3-5.5-1.8-13.9-4.6-25L105.5 160zm252 0v224h104.6c29.3 0 51.9-6 67.7-17.9s23.7-28.9 23.7-50.8c0-8.1-2.4-16-7-23.5-4.7-7.6-11.4-13.9-20-18.9-8.7-5-18.4-8.2-29.3-9.5v-.6c9.4-1.8 18-5.1 25.8-10s13.7-10.6 17.5-17.1 5.8-13.7 5.8-21.5c0-36.1-30.5-54.2-91.4-54.2zm69.1 45.2h12.8c22.3 0 33.4 6.9 33.4 20.8 0 6.4-2.5 11.5-7.4 15.5s-11.2 6-18.9 6h-20zm0 87.6h27.2c7.9 0 14.3 2.1 19 6.2s7.2 9.5 7.2 15.9c0 7.3-2.7 13-8.1 17.2s-12.9 6.3-22.2 6.3h-23v-45.6z" />',viewBox:"0 0 512 512"},vbprojIcon:{name:"vbproj",content:'<path d="M64 32c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32zm160 32c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32m96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32m96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32M64 160h384v288H64zm32 64 51.6 160h54.1L254 224h-50.2L180 321.9c-1.9 7.4-3 13.5-3.5 18.5h-1.1c-.2-3.9-1.3-9.9-3.2-17.9L147.8 224zm183.3 0v160h73c20.4 0 36.2-4.3 47.2-12.8s16.5-20.6 16.5-36.3c0-5.8-1.6-11.4-4.9-16.8s-7.9-9.9-14-13.5-12.8-5.9-20.4-6.8v-.4c6.5-1.3 12.5-3.6 18-7.1s9.5-7.6 12.2-12.2 4-9.8 4-15.3c0-25.8-21.2-38.7-63.7-38.7h-67.9zm48.2 32.3h8.9c15.6 0 23.3 5 23.3 14.8 0 4.5-1.7 8.3-5.1 11.1s-7.8 4.3-13.2 4.3h-14zm0 62.5h19c5.5 0 9.9 1.5 13.3 4.4s5 6.8 5 11.4q0 7.8-5.7 12.3c-5.7 4.5-9 4.5-15.5 4.5h-16.1z" />',viewBox:"0 0 512 512"},videoExternalIcon:{name:"video-external",content:'<path d="M256 0C114.6 0 0 114.6 0 256s114.6 256 256 256 256-114.6 256-256S397.4 0 256 0m-64 384V128l192 128z" />',viewBox:"0 0 512 512"},vimeoBoxIcon:{name:"vimeo-box",content:'<path d="M448 32H64c-17.664 0-32 14.336-32 32v384c0 17.664 14.336 32 32 32h384c17.664 0 32-14.336 32-32V64c0-17.664-14.336-32-32-32m-.186 140.119c-1.714 37.08-27.831 87.809-78.295 152.123-52.206 67.294-96.402 100.901-132.563 100.901-22.366 0-41.304-20.462-56.786-61.493-10.339-37.625-20.652-75.303-30.991-112.849-11.491-41.058-23.813-61.573-37.018-61.573-2.866 0-12.884 5.987-30.107 17.961L64 184.066c18.938-16.458 37.581-33.022 55.956-49.519 25.206-21.7 44.143-33.048 56.786-34.232 29.813-2.874 48.188 17.389 55.099 60.668 7.393 46.765 12.616 75.835 15.456 87.237 8.598 38.743 18.08 58.087 28.419 58.087 8.009 0 20.036-12.506 36.134-37.559 16.071-25.106 24.67-44.184 25.822-57.315 2.277-21.66-6.321-32.423-25.822-32.423-9.188 0-18.67 1.929-28.42 5.974 18.964-61.001 55.099-90.63 108.456-88.914 39.562 1.105 58.205 26.516 55.928 76.049" />',viewBox:"0 0 512 512"},vimeoIcon:{name:"vimeo",content:'<path d="M479.783 152.805c-2 43.26-32.469 102.444-91.344 177.477C327.532 408.792 275.969 448 233.782 448c-26.094 0-48.188-23.873-66.25-71.742-12.063-43.896-24.094-87.854-36.157-131.657-13.407-47.901-27.782-71.835-43.188-71.835-3.344 0-15.032 6.985-35.125 20.955L32 166.744c22.094-19.201 43.844-38.526 65.282-57.773 29.407-25.316 51.5-38.556 66.25-39.938 34.782-3.353 56.219 20.287 64.282 70.78 8.625 54.559 14.719 88.475 18.032 101.777 10.031 45.2 21.093 67.769 33.156 67.769 9.344 0 23.375-14.591 42.157-43.818 18.75-29.29 28.782-51.548 30.125-66.868 2.656-25.27-7.375-37.827-30.125-37.827-10.719 0-21.782 2.251-33.157 6.969C310.126 96.647 352.283 62.08 414.533 64.082c46.156 1.289 67.906 30.935 65.25 88.723" />',viewBox:"0 0 512 512"},volumeDownIcon:{name:"volume-down",content:'<path d="M0 352h96l128 128V32L96 160H0zm288 28V132c55.2 14.2 96 64.3 96 124s-40.8 109.8-96 124" />',viewBox:"0 0 512 512"},volumeMuteIcon:{name:"volume-mute",content:'<path d="M96 160 224 32v448L96 352H0V160zm416 29.3L466.7 144 400 210.7 333.2 144 288 189.3l66.7 66.7-66.7 66.7 45.3 45.3 66.7-66.7 66.7 66.7 45.3-45.3-66.8-66.7z" />',viewBox:"0 0 512 512"},volumeUpIcon:{name:"volume-up",content:'<path d="M0 352h96l128 128V32L96 160H0zm288 28V132c55.2 14.2 96 64.3 96 124s-40.8 109.8-96 124m0-380v44.8c45.2 0 88.3 20.8 121.2 58.4C444.6 143.6 464 197.8 464 256s-19.4 112.4-54.8 152.8c-33 37.7-76 58.4-121.2 58.4V512c123.7 0 224-114.6 224-256S411.7 0 288 0" />',viewBox:"0 0 512 512"},walletSolidIcon:{name:"wallet-solid",content:'<path d="M448 160.24H64c-17.39 0-31.55 13.87-31.99 31.15-.01.17-.01.33-.01.5v256.14c0 17.67 14.33 31.98 32 31.98h384c17.67 0 32-14.31 32-31.98V192.22c0-17.67-14.33-31.98-32-31.98m0 95.93h-63.06c-34.31 0-63.25 26.62-64.87 60.88-1.73 36.65 27.62 67.03 63.93 67.03h64v31.98h-62.83c-51.93 0-95.36-40.75-97.11-92.61-1.84-54.49 41.82-99.25 95.94-99.25h64zm-66.08 95.86c-15.92-1-28.85-13.91-29.85-29.83-1.23-19.3 14.7-35.21 34.01-33.99 15.92 1 28.85 13.91 29.85 29.83 1.23 19.3-14.7 35.21-34.01 33.99M96 64.31v63.95h59l37.78-63.95zm153-32.3-9.34 15.87-.42.73-46.03 79.66h221.41l.52-.88z" />',viewBox:"0 0 512 512"},warningCircleIcon:{name:"warning-circle",content:'<path d="M256 480c123.7 0 224-100.3 224-224S379.7 32 256 32 32 132.3 32 256s100.3 224 224 224m-32-352h64v160h-64zm0 256v-64h64v64z" />',viewBox:"0 0 512 512"},warningTriangleIcon:{name:"warning-triangle",content:'<path d="M256 32 0 480h512zm-32 160h64v160h-64zm0 256v-64h64v64z" />',viewBox:"0 0 512 512"},wholeWordIcon:{name:"whole-word",content:'<path d="M379 243.6c-2.7-9.3-6.5-17.2-11.7-23.8-5-6.4-11.4-11.4-18.6-15-7.4-3.5-15.9-5.2-25.3-5.2-16.3 0-30 6.9-41.4 20.5V160h-26v192h26v-14.8c10.8 9.8 24.1 14.8 39.7 14.8 8.7 0 16.9-1.8 24.3-5.4 7.5-3.8 14-8.9 19.5-15.5 5.5-6.8 9.7-14.9 12.9-24.4 3-9.6 4.6-20.3 4.6-32.1 0-11.5-1.3-21.8-4-31m-31.8 73.7c-6.6 9.5-15.6 14.2-26.8 14.2-14.5 0-27.3-5.9-38.4-17.8v-69.1c11.9-16.6 25-24.9 39.4-24.9 11.4 0 20 4.6 26.2 13.9 6.1 9.2 9.3 22.9 9.3 41 0 18.9-3.3 33.3-9.7 42.7m-139-107.8c-10.6-7.5-25.2-11.1-44.1-11.1-40.5 0-61.7 15-63.6 44.6h26.1c.7-16.2 12.8-24.4 36-24.4 11 0 19.2 1.6 24.4 4.8 2.6 1.6 4.6 3.4 6.2 5.1 1.5 1.8 2.5 4 3.2 6.6s1.1 5.6 1.4 9.4c.1 3.6.1 8.3.1 13.5h-12.8c-59.3.1-89.1 17.3-89.1 51.5 0 6.4 1.3 12 3.8 17.2 2.4 5.3 5.9 9.6 10.4 13.4 4.4 3.8 9.8 6.7 16 8.7 6.1 2.2 12.7 3.2 20 3.2 20.9 0 51.8-18.6 51.8-18.6V351h26v-97.5c0-22-5.4-36.6-15.8-44m-10.2 100c-2.3 3.4-5.1 6.3-8.4 9-3.2 2.6-6.8 4.9-10.7 6.8-3.9 1.8-8 3.3-12.2 4.3s-8.6 1.4-12.8 1.4c-9.6 0-17-2-22.5-5.9-5.5-4.1-8.3-9.8-8.3-17.2 0-20.6 18.9-30.9 56.9-30.9h18zM448 96h-32v320h32zm0-32H64V32h384zm0 415.6H64v-32h384z" />',viewBox:"0 0 512 512"},windowIcon:{name:"window",content:'<path d="M96 96v320h320V96zm288 288H128V192h256z" />',viewBox:"0 0 512 512"},windowMinimizeIcon:{name:"window-minimize",content:'<path d="M416 288v64H96v-64z" />',viewBox:"0 0 512 512"},windowRestoreIcon:{name:"window-restore",content:'<path d="M448 32v288h-32V128H160V32zM64 192h288v288H64zm32 256h224V288H96z" />',viewBox:"0 0 512 512"},wrenchIcon:{name:"wrench",content:'<path d="M470.7 402.7 306 238.1c9-18.8 14-39.8 14-62.1 0-79.5-64.5-144-144-144-22.2 0-43.3 5-62.1 14l76.4 76.4c12.4 12.4 12.4 32.8 0 45.3l-22.6 22.6c-12.4 12.4-32.8 12.4-45.3 0L46 113.9c-9 18.8-14 39.9-14 62.1 0 79.5 64.5 144 144 144 22.3 0 43.4-5.1 62.2-14.1l164.7 164.7c12.3 12.5 32.7 12.5 45.1.1l22.7-22.7c12.4-12.4 12.4-32.8 0-45.3M448 425.5 425.4 448 265.8 288.5c8.3-6.7 15.9-14.3 22.6-22.6z" />',viewBox:"0 0 512 512"},xCircleIcon:{name:"x-circle",content:'<path d="M256 32C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32m128 306.7L338.7 384 256 301.3 173.3 384 128 338.7l82.7-82.7-82.7-82.7 45.3-45.3 82.7 82.7 82.7-82.7 45.3 45.3-82.7 82.7z" />',viewBox:"0 0 512 512"},xIcon:{name:"x",content:'<path d="M416 141.3 301.3 256 416 370.7 370.7 416 256 301.3 141.3 416 96 370.7 210.7 256 96 141.3 141.3 96 256 210.7 370.7 96z" />',viewBox:"0 0 512 512"},xLogoIcon:{name:"x-logo",content:'<path d="M448 64h-32L288.01 204 199.04 64H64l146.02 226L64.03 448h31.02l128.96-141 88.01 141h135.96L302.53 222.49zm-55.99 352h-66.09l-84.89-131-122-189h66.05l85.37 130.89 12.97 20.59z" />',viewBox:"0 0 512 512"},xOutlineIcon:{name:"x-outline",content:'<path d="M384 338.7 338.7 384 256 301.3 173.3 384 128 338.7l82.7-82.7-82.7-82.7 45.3-45.3 82.7 82.7 82.7-82.7 45.3 45.3-82.7 82.7zM256 32C132.3 32 32 132.3 32 256s100.3 224 224 224 224-100.3 224-224S379.7 32 256 32m0 416c-106 0-192-86-192-192S150 64 256 64s192 86 192 192-86 192-192 192" />',viewBox:"0 0 512 512"},yammerBoxIcon:{name:"yammer-box",content:'<path d="M448 32H64c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V64c0-17.7-14.3-32-32-32M332.5 148.6c15.4-15.4 30.7 0 30.7 0s15.8 15 .3 30.6-61.7 31.1-61.7 31.1 15.4-46.3 30.7-61.7m-54.7-26.4c-.1.3-.2.5-.3.8h.1c-.4 1.2-.9 2.4-1.4 3.8-3.5 8.8-75.5 223.1-75.5 223.1-13.7 39.3-34 66.2-75.6 66.2-5.5 0-11.6-.4-17.6-1.6-8.3-2.7-13.2-12.3-10.9-21.7 2-8.2 8.8-13.6 16.1-13.2.5.1 8.1.6 10.3.6 22.6 0 37.5-15.5 45.1-38.3l4.5-11.1s-68.2-186.3-75.5-207c-3-10.5 1.7-22 11-25.9 9.1-3.8 19.1.9 23.2 10.6l.8 2.4L191.3 279h.9s46.7-149.5 52.5-168c0-.1 0-.2.1-.3.2-.6.3-1.1.4-1.3 3.2-9.8 12.7-15.1 21.6-11.9 8.9 3.4 14 14.4 11 24.7m85.4 241.2s-15.3 15.5-30.7 0-30.8-61.7-30.8-61.7 46.1 15.4 61.7 31.1-.2 30.6-.2 30.6m30.3-84.6c-23.2 0-68.9-22.8-68.9-22.8s45.7-22.8 68.6-22.8S416 256 416 256s.7 22.8-22.5 22.8" />',viewBox:"0 0 512 512"},yammerIcon:{name:"yammer",content:'<path d="M263.9 32.1c-10.1-.2-19.6 6.8-23.2 18-.1.4-.3 1-.5 1.9 0 .1-.1.3-.1.4-8 25.9-73.6 235.6-73.6 235.6h-1.2l-84-239.2C75.6 35.3 61.6 28.7 48.9 34c-13 5.5-19.7 21.5-15.4 36.2 10.1 29 105.8 290.4 105.8 290.4l-6.3 15.6c-10.6 32.1-31.6 53.8-63.2 53.8-3.1 0-13.7-.7-14.4-.8-10.2-.6-19.7 6.9-22.5 18.4-3.1 13.1 3.7 26.6 15.3 30.4 8.4 1.6 17 2.2 24.7 2.2 58.3 0 86.8-37.7 106-92.8 0 0 101-300.5 105.8-312.9.8-2 1.4-3.7 2-5.4l-.1-.1c.1-.4.3-.7.4-1.1 4.1-14.5-3-29.9-15.8-34.5-2.5-.8-4.9-1.3-7.3-1.3M383.5 96c-6.3.1-13.3 2.5-20.4 9.6-21.5 21.6-43 86.4-43 86.4s64.6-21.6 86.4-43.5-.4-42.8-.4-42.8-9.7-9.8-22.6-9.7m64.6 128c-32 0-96 32-96 32s64 32 96.4 32 31.5-32 31.5-32 .1-32-31.9-32m-128 96s21.5 64.8 43 86.4 43-.1 43-.1 22.1-21 .4-42.8c-21.8-21.9-86.4-43.5-86.4-43.5" />',viewBox:"0 0 512 512"},youtubeBoxIcon:{name:"youtube-box",content:'<path d="M448 32H64c-17.664 0-32 14.336-32 32v384c0 17.664 14.336 32 32 32h384c17.664 0 32-14.336 32-32V64c0-17.664-14.336-32-32-32m0 237.749c0 29.454-3.835 58.909-3.835 58.909s-3.752 25.082-15.265 36.128c-14.602 14.497-30.97 14.569-38.476 15.417C336.689 383.885 256 384 256 384s-99.838-.864-130.559-3.656c-8.546-1.519-27.734-1.061-42.341-15.558-11.513-11.045-15.26-36.128-15.26-36.128S64 299.203 64 269.749v-27.614c0-29.454 3.84-58.909 3.84-58.909s3.747-25.082 15.26-36.128c14.607-14.497 30.969-14.569 38.476-15.417C175.313 128 255.917 128 255.917 128h.167s80.606 0 134.341 3.682c7.506.849 23.873.92 38.476 15.417 11.513 11.045 15.265 36.128 15.265 36.128S448 212.681 448 242.136zM192 176l144 80-144 80z" />',viewBox:"0 0 512 512"},youtubeIcon:{name:"youtube",content:'<path d="M475.5 165s-4.4-31.4-17.8-45.2c-17-18.1-36.1-18.2-44.9-19.3C350.1 96 256.1 96 256.1 96h-.2s-94 0-156.7 4.6c-8.8 1.1-27.8 1.2-44.9 19.3C40.9 133.7 36.5 165 36.5 165S32 201.9 32 238.7v34.5c0 36.8 4.5 73.6 4.5 73.6s4.4 31.4 17.8 45.2c17 18.1 39.4 17.5 49.4 19.4C139.5 414.9 256 416 256 416s94.1-.1 156.8-4.7c8.8-1.1 27.9-1.2 44.9-19.3 13.4-13.8 17.8-45.2 17.8-45.2s4.5-36.8 4.5-73.6v-34.5c0-36.8-4.5-73.7-4.5-73.7M192 336V176l144 80z" />',viewBox:"0 0 512 512"},zoomActualSizeIcon:{name:"zoom-actual-size",content:'<path d="M0 32v128L128 32zm384 0 128 128V32zm-260.6 96c-15.1 0-27.4 12.3-27.4 27.4v201.2c0 15.1 12.3 27.4 27.4 27.4h265.2c15.1 0 27.4-12.3 27.4-27.4V155.4c0-15.1-12.3-27.4-27.4-27.4zM384 160v160l-48-64-48 64-80-96-80 96V160zm-96 32c-17.7 0-32 14.3-32 32s14.3 32 32 32 32-14.3 32-32-14.3-32-32-32M0 352v128h128zm512 0L384 480h128z" />',viewBox:"0 0 512 512"},zoomBestFitIcon:{name:"zoom-best-fit",content:'<path d="M388.6 128H123.4c-15.1 0-27.4 12.3-27.4 27.4v201.2c0 15.1 12.3 27.4 27.4 27.4h265.2c15.1 0 27.4-12.3 27.4-27.4V155.4c0-15.1-12.3-27.4-27.4-27.4M384 320l-48-64-48 64-80-96-80 96V160h256zM0 160l96 96-96 96zm160 320 96-96 96 96zM352 32l-96 96-96-96zm160 128v192l-96-96zm-256 64c0-17.7 14.3-32 32-32s32 14.3 32 32-14.3 32-32 32-32-14.3-32-32" />',viewBox:"0 0 512 512"},zoomInIcon:{name:"zoom-in",content:'<path d="M288 224h-64v64h-64v-64H96v-64h64V96h64v64h64zm192 210.7L434.7 480 320 365.3v-22.7l-26.7-26.7C265.7 338.5 230.4 352 192 352c-88.4 0-160-71.6-160-160S103.6 32 192 32s160 71.6 160 160c0 38.4-13.5 73.7-36.1 101.3l26.7 26.7h22.7zM192 320c70.7 0 128-57.3 128-128S262.7 64 192 64 64 121.3 64 192s57.3 128 128 128" />',viewBox:"0 0 512 512"},zoomOutIcon:{name:"zoom-out",content:'<path d="M288 224H96v-64h192zm192 210.7L434.7 480 320 365.3v-22.7l-26.7-26.7C265.7 338.5 230.4 352 192 352c-88.4 0-160-71.6-160-160S103.6 32 192 32s160 71.6 160 160c0 38.4-13.5 73.7-36.1 101.3l26.7 26.7h22.7zM192 320c70.7 0 128-57.3 128-128S262.7 64 192 64 64 121.3 64 192s57.3 128 128 128" />',viewBox:"0 0 512 512"}});!function(e){var t=window.kendo,n=t.html,i=t.ui.Widget,r=e.extend,o=i.extend({init:function(r,o){var a=this;i.fn.init.call(a,r,o),delete o.name,a._icon=new n.HTMLFontIcon(r,e.extend({},o)),a.element=a.wrapper=a._icon.element,t.notify(a)},options:r({},n.HTMLFontIcon.fn.options,{name:"FontIcon"}),setOptions:function(t){var r=this;i.fn.setOptions.call(r,t),r._icon=new n.HTMLFontIcon(r.element,e.extend({},r.options))}}),a=i.extend({init:function(r,o){var a=this;i.fn.init.call(a,r,o),delete o.name,a._icon=new n.HTMLSvgIcon(r,e.extend({},o)),a.element=a.wrapper=a._icon.element,t.notify(a)},options:r({},n.HTMLSvgIcon.fn.options,{name:"SvgIcon"}),setOptions:function(t){var r=this;i.fn.setOptions.call(r,t),t.icon&&this.element.html(""),r._icon=new n.HTMLSvgIcon(r.element,e.extend({},r.options))}});t.ui.plugin(o),t.ui.plugin(a),t.setDefaults("iconType","svg"),t.ui.svgIcons=wh,t.ui.icon=n.renderIcon}(window.kendo.jQuery);kendo;window.kendo.jQuery,window.kendo.util=window.kendo.util||{},kendo.deepExtend(kendo.util,{LRUCache:Io,TextMetrics:Bo,measureText:Oo,objectKey:Ho,hashKey:Fo,normalizeText:Po,encodeBase64:lo}),function(e){window.kendo=window.kendo||{};let t=kendo.deepExtend({},pu);kendo.deepExtend(kendo,{drawing:e.extend(!0,{},kc,{Segment:La,pdf:t}),pdf:t,geometry:Oa}),kendo.drawing.exportPDF=function(e,t){let n=hu(e,t);return kendo.convertPromiseToDeferred(n)},kendo.drawing.drawText=Au,kendo.drawing.Color=qr,kendo.dataviz.drawing=kendo.drawing,kendo.dataviz.geometry=Oa}(window.kendo.jQuery),function(e){var t=".kendo",n=window.kendo,i=n.deepExtend,r=n.drawing.util,o=r.defined,a=r.limitValue,s=r.eventCoordinates,l=n._outerWidth,c=n._outerHeight,d=`<div class="k-tooltip-button">${n.ui.icon(e('<a href="#" title="Close"></a>'),{icon:"x"})}</div>`,u=n.Class.extend({init:function(t,n){this.element=e('<div class="k-tooltip"><div class="k-tooltip-content"></div></div>'),this.content=this.element.children(".k-tooltip-content"),n=n||{},this.options=i({},this.options,this._tooltipOptions(n)),this.popupOptions={appendTo:n.appendTo,animation:n.animation,copyAnchorStyles:!1,collision:"fit fit"},this._openPopupHandler=this._openPopup.bind(this),this.surface=t,this._bindEvents()},options:{position:"top",showOn:"mouseenter",offset:7,autoHide:!0,hideDelay:0,showAfter:100},_bindEvents:function(){this._showHandler=this._showEvent.bind(this),this._surfaceLeaveHandler=this._surfaceLeave.bind(this),this._mouseleaveHandler=this._mouseleave.bind(this),this._mousemoveHandler=this._mousemove.bind(this),this.surface.bind("click",this._showHandler),this.surface.bind("mouseenter",this._showHandler),this.surface.bind("mouseleave",this._mouseleaveHandler),this.surface.bind("mousemove",this._mousemoveHandler),this.surface.element.on("mouseleave"+t,this._surfaceLeaveHandler),this.element.on("click"+t,".k-tooltip-button",this._hideClick.bind(this)),this.element.on("mouseleave"+t,this._tooltipLeave.bind(this))},getPopup:function(){return this.popup||(this.popup=new n.ui.Popup(this.element,this.popupOptions)),this.popup},destroy:function(){var e=this.popup;this.surface.unbind("click",this._showHandler),this.surface.unbind("mouseenter",this._showHandler),this.surface.unbind("mouseleave",this._mouseleaveHandler),this.surface.unbind("mousemove",this._mousemoveHandler),this.surface.element.off("mouseleave"+t,this._surfaceLeaveHandler),this.element.off("click"+t),this.element.off("mouseleave"+t),e&&(e.destroy(),delete this.popup),delete this.popupOptions,clearTimeout(this._timeout),delete this.element,delete this.content,delete this.surface},_tooltipOptions:function(e){return{position:(e=e||{}).position,showOn:e.showOn,offset:e.offset,autoHide:e.autoHide,width:e.width,height:e.height,content:e.content,shared:e.shared,hideDelay:e.hideDelay,showAfter:e.showAfter}},_tooltipShape:function(e){for(;e&&!e.options.tooltip;)e=e.parent;return e},_updateContent:function(e,t,i){var r=i.content;if(n.isFunction(r)&&(r=r({element:t,target:e})),r)return this.content.html(r),!0},_position:function(e,t,n,i){var r=t.position,o=t.offset||0,l=this.surface,c=l._instance._elementOffset(),d=l.getSize(),u=l._instance._offset,h=e.bbox(),p=n.width,f=n.height,m=0,g=0;if(h.origin.translate(c.left,c.top),u&&h.origin.translate(-u.x,-u.y),"cursor"==r&&i){var v=s(i);m=v.x-p/2,g=v.y-f-o}else"left"==r?(m=h.origin.x-p-o,g=h.center().y-f/2):"right"==r?(m=h.bottomRight().x+o,g=h.center().y-f/2):"bottom"==r?(m=h.center().x-p/2,g=h.bottomRight().y+o):(m=h.center().x-p/2,g=h.origin.y-f-o);return{left:a(m,c.left,c.left+d.width),top:a(g,c.top,c.top+d.height)}},show:function(e,t){this._show(e,e,i({},this.options,this._tooltipOptions(e.options.tooltip),t))},hide:function(){var e=this.popup,t=this._current;delete this._current,clearTimeout(this._showTimeout),e&&e.visible()&&t&&!this.surface.trigger("tooltipClose",{element:t.shape,target:t.target,popup:e})&&e.close()},_hideClick:function(e){e.preventDefault(),this.hide()},_show:function(e,t,n,i,r){var o=this._current;if(clearTimeout(this._timeout),!o||!(o.shape===t&&n.shared||o.target===e)){clearTimeout(this._showTimeout);var a=this.getPopup();if(!this.surface.trigger("tooltipOpen",{element:t,target:e,popup:a})&&this._updateContent(e,t,n)){this._autoHide(n);var s=this._measure(n);a.visible()&&a.close(!0),this._current={options:n,elementSize:s,shape:t,target:e,position:this._position(n.shared?t:e,n,s,i)},r?this._showTimeout=setTimeout(this._openPopupHandler,n.showAfter||0):this._openPopup()}}},_openPopup:function(){var e=this._current.position;this.getPopup().open(e.left,e.top)},_autoHide:function(t){t.autoHide&&this._closeButton&&(this.element.removeClass("k-tooltip-closable"),this._closeButton.remove(),delete this._closeButton),t.autoHide||this._closeButton||(this.element.addClass("k-tooltip-closable"),this._closeButton=e(d).appendTo(this.element))},_showEvent:function(e){var t=this._tooltipShape(e.element);if(t){var n=i({},this.options,this._tooltipOptions(t.options.tooltip));n&&n.showOn==e.type&&this._show(e.element,t,n,e.originalEvent,!0)}},_measure:function(e){this.element.css({width:o(e.width)?e.width:"auto",height:o(e.height)?e.height:"auto"});const t=this.element.clone().appendTo(document.body).css({visibility:"hidden"}),n=l(t),i=c(t);return t.remove(),this.element.css({width:n,height:i}),{width:n,height:i}},_mouseleave:function(e){if(this.popup&&!this._popupRelatedTarget(e.originalEvent)){var t=this,n=t._current;n&&n.options.autoHide&&(t._timeout=setTimeout((function(){clearTimeout(t._showTimeout),t.hide()}),n.options.hideDelay||0))}},_mousemove:function(e){var t=this._current;if(t&&e.element){var n=t.options;if("cursor"==n.position){var i=this._position(e.element,n,t.elementSize,e.originalEvent);t.position=i,this.getPopup().wrapper.css({left:i.left,top:i.top})}}},_surfaceLeave:function(e){this.popup&&!this._popupRelatedTarget(e)&&(clearTimeout(this._showTimeout),this.hide())},_popupRelatedTarget:function(t){return t.relatedTarget&&e(t.relatedTarget).closest(this.popup.wrapper).length},_tooltipLeave:function(){var e=this,t=e._current;t&&t.options.autoHide&&(e._timeout=setTimeout((function(){e.hide()}),t.options.hideDelay||0))}});n.drawing.SurfaceTooltip=u,n.dataviz.drawing.SurfaceTooltip=u}(window.kendo.jQuery),function(){var e=window.kendo,t=e.drawing,n=t.Surface,i=e.ui.Widget,r=e.deepExtend;e.support.svg=n.support.svg,e.support.canvas=n.support.canvas;var o=i.extend({init:function(e,t){i.fn.init.call(this,e,{}),this.options=r({},this.options,t),this._instance=n.create(this.element[0],t),this._instance.translate&&(this.translate=a),this._triggerInstanceHandler=this._triggerInstanceEvent.bind(this),this._bindHandler("click"),this._bindHandler("mouseenter"),this._bindHandler("mouseleave"),this._bindHandler("mousemove"),this._enableTracking()},options:{name:"Surface",tooltip:{}},events:["click","mouseenter","mouseleave","mousemove","resize","tooltipOpen","tooltipClose"],_triggerInstanceEvent:function(e){this.trigger(e.type,e)},_bindHandler:function(e){this._instance.bind(e,this._triggerInstanceHandler)},draw:function(e){this._instance.draw(e)},clear:function(){this._instance&&this._instance.clear(),this.hideTooltip()},destroy:function(){this._instance&&(this._instance.destroy(),delete this._instance),this._tooltip&&(this._tooltip.destroy(),delete this._tooltip),i.fn.destroy.call(this)},exportVisual:function(){return this._instance.exportVisual()},eventTarget:function(e){return this._instance.eventTarget(e)},showTooltip:function(e,t){this._tooltip&&this._tooltip.show(e,t)},hideTooltip:function(){this._tooltip&&this._tooltip.hide()},suspendTracking:function(){this._instance.suspendTracking(),this.hideTooltip()},resumeTracking:function(){this._instance.resumeTracking()},getSize:function(){return{width:this.element.width(),height:this.element.height()}},setSize:function(e){this.element.css({width:e.width,height:e.height}),this._size=e,this._instance.currentSize(e),this._resize()},_resize:function(){this._instance.currentSize(this._size),this._instance._resize()},_enableTracking:function(){e.ui.Popup&&(this._tooltip=new t.SurfaceTooltip(this,this.options.tooltip||{}))}});function a(e){this._instance.translate(e)}e.ui.plugin(o),o.create=function(e,t){return new o(e,t)},e.drawing.Surface=o}(window.kendo.jQuery),window.kendo.drawing=window.kendo.drawing||{},function(e){var t=window.kendo,n=t.drawing;n.drawDOM=function(n,i){"string"==typeof i?.template&&(i.template=t.template(i.template));let r=Du(e(n)[0],i);return t.convertPromiseToDeferred(r)},n.drawDOM.drawText=Au,n.drawDOM.getFontFaces=Hu}(window.kendo.jQuery);!function(e){let t=window.kendo,n=t.ui.Widget,i=".kendoValidator",r="k-invalid-msg",o=new RegExp(r,"i"),a="k-invalid",s="k-valid",l="k-validation-summary",c="k-text-error",d="k-messagebox k-messagebox-error",u="aria-invalid",h=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/i,p=["http:","https:","ftp:","ftps:"],f=":input:not(:button,[type=submit],[type=reset],[disabled],[readonly])",m=":checkbox:not([disabled],[readonly])",g="[type=number],[type=range]",v="blur",_="name",b="form",y="novalidate",w="validate",k="change",x="validateInput",C=function(e,t){return"string"==typeof t&&(t=new RegExp("^(?:"+t+")$")),t.test(e)},S=function(e,t){return!!e.length&&null!=e[0].attributes[t]};function T(e){return e.replace(/&amp/g,"&amp;").replace(/&quot;/g,'"').replace(/&#39;/g,"'").replace(/&lt;/g,"<").replace(/&gt;/g,">")}function D(t){return e.parseHTML?e(e.parseHTML(t)):e(t)}function A(n,i){for(var r,a=e(),s=0,l=n.length;s<l;s++)r=n[s],o.test(r.className)&&r.getAttribute(t.attr("for"))===i&&(a=a.add(r));return a}function M(e,t){return!!e&&("string"==typeof e.nodeName&&"LABEL"===e.nodeName&&("string"==typeof e.getAttribute("for")&&"string"==typeof t.getAttribute("id")&&e.getAttribute("for")===t.getAttribute("id")))}t.ui.validator||(t.ui.validator={rules:{},messages:{},allowSubmit:e.noop,validateOnInit:e.noop});var E=({errors:e})=>{let t="<ul>";for(var n=0;n<e.length;n+=1)t+=`<li><a data-field="${e[n].field}" href="#">${e[n].message}</a></li>`;return t+="</ul>",t},I=n.extend({init:function(i,r){var o=this,a=function(n){var i,r=t.ui.validator.ruleResolvers||{},o={};for(i in r)e.extend(!0,o,r[i].resolve(n));return o}(i),s="["+t.attr("validate")+"!=false]";(r=r||{}).rules=e.extend({},t.ui.validator.rules,a.rules,r.rules),r.messages=e.extend({},t.ui.validator.messages,a.messages,r.messages),n.fn.init.call(o,i,r),o._errorTemplate=t.template(o.options.errorTemplate),o._summaryTemplate=t.template(o.options.validationSummary.template||E),o.element.is(b)&&o.element.attr(y,y),o._inputSelector=f+s,o._checkboxSelector=m+s,o._errors={},o._attachEvents(),o._isValidated=!1,o._validateOnInit()&&o.validate()},events:[w,k,x],options:{name:"Validator",errorTemplate:({message:e})=>`<span class="k-form-error">${e}</span>`,messages:{required:"{0} is required",pattern:"{0} is not valid",min:"{0} should be greater than or equal to {1}",max:"{0} should be smaller than or equal to {1}",step:"{0} is not valid",email:"{0} is not valid email",url:"{0} is not valid URL",date:"{0} is not valid date",dateCompare:"End date should be greater than or equal to the start date",captcha:"The text you entered doesn't match the image."},rules:{required:function(e){var t=!e.attr("name")&&!e.is(":checked"),n=e.attr("name"),i=n&&n.indexOf("'")>-1?'"':"'",r=e.attr("name")&&!this.element.find("input[name="+i+e.attr("name")+i+"]:checked").length,o=e.filter("[type=checkbox]").length&&(t||r),a=e.filter("[type=radio]").length&&!this.element.find("input[name="+i+e.attr("name")+i+"]:checked").length,s=e.val();return!(S(e,"required")&&(!s||""===s||0===s.length||o||a))},pattern:function(e){return!e.filter("[type=text],[type=email],[type=url],[type=tel],[type=search],[type=password]").filter("[pattern]").length||""===e.val()||C(e.val(),e.attr("pattern"))},min:function(e){return!e.filter(g+",["+t.attr("type")+"=number]").filter("[min]").length||""===e.val()||(parseFloat(e.attr("min"))||0)<=t.parseFloat(e.val())},max:function(e){return!e.filter(g+",["+t.attr("type")+"=number]").filter("[max]").length||""===e.val()||(parseFloat(e.attr("max"))||0)>=t.parseFloat(e.val())},step:function(e){if(e.filter(g+",["+t.attr("type")+"=number]").filter("[step]").length&&""!==e.val()){var n,i=parseFloat(e.attr("min"))||0,r=t.parseFloat(e.attr("step"))||1,o=parseFloat(e.val()),a=function(e){return(e=(e+"").split(".")).length>1?e[1].length:0}(r);return a?(n=Math.pow(10,a),Math.floor((o-i)*n)%(r*n)/Math.pow(100,a)==0):(o-i)%r==0}return!0},email:function(e){return function(e,t,n){var i=e.val();return!e.filter(t).length||""===i||C(i,n)}(e,"[type=email],["+t.attr("type")+"=email]",h)},url:function(e){if(e.filter("[type=url],["+t.attr("type")+"=url]").length&&""!==e.val())try{const t=new URL(e.val());return p.includes(t.protocol)}catch{return!1}return!0},date:function(e){return!e.filter("[type^=date],["+t.attr("type")+"=date]").length||""===e.val()||null!==t.parseDate(e.val(),e.attr(t.attr("format")))},captcha:function(e){if(e.filter("["+t.attr("role")+"=captcha]").length){var n=this,i=t.widgetInstance(e),r=function(e){return null!=e};if(e.data("captcha_validating")||r(i.isValid())||!i.getCaptchaId()||(e.data("captcha_validating",!0),n._validating=!0,i.validate().done((function(){n._validating=!1,n._checkElement(e)})).fail((function(e){n._validating=!1,e.error&&"handler_not_defined"===e.error&&window.console.warn("Captcha's validationHandler is not defined! You should either define a proper validation endpoint or declare a callback function to ensure the required behavior.")}))),r(i.isValid()))return e.removeData("captcha_validating"),i.isValid()}return!0}},validateOnBlur:!0,validationSummary:!1},_allowSubmit:function(){return t.ui.validator.allowSubmit(this.element,this.errors())},_validateOnInit:function(){return t.ui.validator.validateOnInit(this.element)},destroy:function(){n.fn.destroy.call(this),this.element.off(i),this.validationSummary&&(this.validationSummary.off(i),this.validationSummary=null)},value:function(){return!!this._isValidated&&0===this.errors().length},_submit:function(e){return!(!this.validate()&&!this._allowSubmit()||this._validating)||(e.stopPropagation(),e.stopImmediatePropagation(),e.preventDefault(),!1)},_checkElement:function(e){var t=this.value();this.validateInput(e),this.value()!==t&&this.trigger(k)},_attachEvents:function(){var t=this;t.element.is(b)&&t.element.on("submit"+i,t._submit.bind(t)),t.options.validateOnBlur&&(t.element.is(f)?(t.element.on(v+i,(function(){t._checkElement(t.element)})),t.element.is(m)&&t.element.on("click"+i,(function(){t._checkElement(t.element)}))):(t.element.on(v+i,t._inputSelector,(function(){t._checkElement(e(this))})),t.element.on("click"+i,t._checkboxSelector,(function(){t._checkElement(e(this))}))))},validate:function(){var e,t,n,i=!1,r=this.value();if(this._errors={},this.element.is(f))i=this.validateInput(this.element);else{var o=!1;for(t=0,n=(e=this.element.find(this._inputSelector)).length;t<n;t++)this.validateInput(e.eq(t))||(o=!0);i=!o}return this.options.validationSummary&&!r&&this.showValidationSummary(),this.trigger(w,{valid:i,errors:this.errors()}),r!==i&&this.trigger(k),i},validateInput:function(n){n=e(n),this._isValidated=!0;var i,o=this,l=o._errorTemplate,d=o._checkValidity(n),h=d.valid,p="."+r,f=n.attr(_)||"",m=o._findMessageContainer(f).add(n.next(p).filter((function(){var n=e(this);return!n.filter("["+t.attr("for")+"]").length||n.attr(t.attr("for"))===f}))).addClass("k-hidden"),g=h?"":o._extractMessage(n,d.key),v=h?"":D(l({message:T(g),field:f})),b=!n.attr(u),y=n.is(".k-input-inner"),w=n.parent(".k-input");if(n.removeAttr(u),n.hasClass("k-hidden")&&(i=t.widgetInstance(n.closest(".k-signature"))),n.is("[type=radio]")&&(i=t.widgetInstance(n.closest(".k-radio-list"))),n.is("[type=checkbox]")&&(i=t.widgetInstance(n.closest(".k-checkbox-list"))),h||n.data("captcha_validating"))delete o._errors[f];else{o._errors[f]=g;var k=m.attr("id");if(o._decorateMessageContainer(v,f),k&&v.attr("id",k),0!==m.length)m.replaceWith(v);else{i=i||t.widgetInstance(n);var C=n.parent().get(0),S=n.next().get(0),A=n.prev().get(0);!i&&n.is("[type=radio]")&&(i=t.widgetInstance(n.closest(".k-radio-list"))),!i&&n.is("[type=checkbox]")&&(i=t.widgetInstance(n.closest(".k-checkbox-list"))),i&&i.wrapper&&(i.element!==i.wrapper||["Signature","RadioGroup","CheckBoxGroup"].indexOf(i.options.name)>-1)?v.insertAfter(i.wrapper):C&&"LABEL"===C.nodeName?v.insertAfter(C):S&&M(S,n[0])?v.insertAfter(S):A&&M(A,n[0])?v.insertAfter(n):y&&w.length?v.insertAfter(w):v.insertAfter(n)}v.removeClass("k-hidden"),n.attr(u,!0)}if(b!==h&&this.trigger(x,{valid:h,input:n,error:g,field:f}),(!(i=i&&"Signature"==i.options.name?i:t.widgetInstance(n))||!i._inputWrapper&&!i.wrapper||n.is("[type=checkbox]")||n.is("[type=radio]"))&&(n.toggleClass(a,!h),n.toggleClass(s,h)),i){var E=i._inputWrapper||i.wrapper,I=i._inputLabel;!E||n.is("[type=checkbox]")||n.is("[type=radio]")||(E.toggleClass(a,!h),E.toggleClass(s,h)),I&&I.toggleClass(c,!h)}if(b!==h){var z=v?v.attr("id"):m.attr("id");o._associateMessageContainer(n,z),this.options.validationSummary&&this.options.validateOnBlur&&this.showValidationSummary()}return h},hideMessages:function(){var e="."+r,t=this.element;this._disassociateMessageContainers(),t.is(f)?t.next(e).addClass("k-hidden"):t.find(e).addClass("k-hidden")},reset:function(){var e=this,t=e.element.find("."+a),n=e.element.find("."+c);e._errors=[],e.hideMessages(),e.hideValidationSummary(),t.removeAttr(u),t.removeClass(a),n.removeClass(c)},_findMessageContainer:function(n){for(var i,r=t.ui.validator.messageLocators,o=e(),a=0,s=this.element.length;a<s;a++)o=o.add(A(this.element[a].getElementsByTagName("*"),n));for(i in r)o=o.add(r[i].locate(this.element,n));return o},_decorateMessageContainer:function(e,n){var i,o=t.ui.validator.messageLocators;for(i in e.addClass(r).attr(t.attr("for"),n||""),e.attr("id")||e.attr("id",n+"-error"),o)o[i].decorate(e,n)},_extractMessage:function(e,n){var i,r=this.options.messages[n],o=e.attr(_);return t.ui.Validator.prototype.options.messages[n]||(i=t.isFunction(r)?r(e):r),r=t.isFunction(r)?r(e):r,t.format(e.attr(t.attr(n+"-msg"))||e.attr("validationMessage")||i||r||e.attr("title")||"",o,e.attr(n)||e.attr(t.attr(n)))},_checkValidity:function(e){var t,n=this.options.rules;for(t in n)if(!n[t].call(this,e))return{valid:!1,key:t};return{valid:!0}},errors:function(){var e,t=[],n=this._errors;for(e in n)t.push(n[e]);return t},setOptions:function(e){e.validationSummary&&this.hideValidationSummary(),t.deepExtend(this.options,e),this.destroy(),this.init(this.element,this.options),this._setEvents(this.options)},_getInputNames:function(){for(var t=this.element.find(this._inputSelector),n=[],i=0,r=t.length;i<r;i++){var o=e(t[i]);S(o,_)&&(-1===n.indexOf(o.attr(_))||0===o.closest(".k-checkbox-list").length&&0===o.closest(".k-radio-list").length)&&n.push(o.attr(_))}return n},_associateMessageContainer:function(e,n){var i=t.getWidgetFocusableElement(e);i&&n&&t.toggleAttribute(i,"aria-describedby",n)},_disassociateMessageContainers:function(){for(var t,n,i=this,o=i.element.find("."+a).addBack(),s=0;s<o.length;s+=1)(t=e(o[s])).is("input")&&(n=i._findMessageContainer(t.attr(_)).add(t.next("."+r)).attr("id"),i._associateMessageContainer(t,n))},_errorsByName:function(){for(var e=this,t=e._getInputNames(),n=[],i=0;i<t.length;i+=1){var r=t[i];e._errors[r]&&n.push({field:r,message:e._errors[r]})}return n},_renderSummary:function(){var t,n=this,r=this.options.validationSummary,o=this.element.prev();return(t=r.container?e(r.container):o&&o.hasClass(l)?o:e("<div />").insertBefore(n.element)).addClass([l,d].join(" ")),t.attr("role","alert"),t.on("click"+i,n._summaryClick.bind(n)),t},_summaryClick:function(n){n.preventDefault();var i,r=e(n.target),o=this.element.find("[name='"+r.data("field")+"']");o.length&&(i=t.getWidgetFocusableElement(o))&&i.trigger("focus")},showValidationSummary:function(){var e,t=this,n=t.validationSummary,i=t._errorsByName();n||(n=t.validationSummary=t._renderSummary()),e=D(t._summaryTemplate({errors:i})),n.html(e),n.toggleClass("k-hidden",!i.length)},hideValidationSummary:function(){var e=this.validationSummary;e&&e.addClass("k-hidden")}});t.ui.plugin(I)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.support,i=t.Class,r=t.Observable,o=Date.now,a=e.extend,s=n.mobileOS,l=s&&s.android,c=800,d=n.browser.msie?5:0,u="press",h="hold",p="select",f="start",m="move",g="end",v="cancel",_="tap",b="doubleTap",y="release",w="gesturechange",k="gestureend",x="gesturetap",C={api:0,touch:0,mouse:9,pointer:9},S=!n.touch||n.mouseAndTouchPresent;function T(e,t){var n=e.x.location,i=e.y.location,r=t.x.location,o=t.y.location,a=n-r,s=i-o;return{center:{x:(n+r)/2,y:(i+o)/2},distance:Math.sqrt(a*a+s*s)}}function D(e){var t,i,r,o=[],a=e.originalEvent,s=e.currentTarget,l=0;if(e.api)o.push({id:2,event:e,target:e.target,currentTarget:e.target,location:e,type:"api"});else if(e.type.match(/touch/))for(t=(i=a?a.changedTouches:[]).length;l<t;l++)r=i[l],o.push({location:r,event:e,target:r.target,currentTarget:s,id:r.identifier,type:"touch"});else n.pointers||n.msPointers?o.push({location:a,event:e,target:e.target,currentTarget:s,id:a.pointerId,type:"pointer"}):o.push({id:1,event:e,target:e.target,currentTarget:s,location:e,type:"mouse"});return o}var A=i.extend({init:function(e,t){var n=this;n.axis=e,n._updateLocationData(t),n.startLocation=n.location,n.velocity=n.delta=0,n.timeStamp=o()},move:function(e){var t=this,n=e["page"+t.axis],i=o(),r=i-t.timeStamp||1;!n&&l||(t.delta=n-t.location,t._updateLocationData(e),t.initialDelta=n-t.startLocation,t.velocity=t.delta/r,t.timeStamp=i)},_updateLocationData:function(e){var t=this,n=t.axis;t.location=e["page"+n],t.client=e["client"+n],t.screen=e["screen"+n]}}),M=i.extend({init:function(e,t,n){a(this,{x:new A("X",n.location),y:new A("Y",n.location),type:n.type,useClickAsTap:e.useClickAsTap,threshold:e.threshold||C[n.type],userEvents:e,target:t,currentTarget:n.currentTarget,initialTouch:n.target,id:n.id,pressEvent:n,_clicks:e._clicks,supportDoubleTap:e.supportDoubleTap,_moved:!1,_finished:!1})},press:function(){this._holdTimeout=setTimeout(this._hold.bind(this),this.userEvents.minHold),this._trigger(u,this.pressEvent)},_tap:function(e){var t=this;t.userEvents._clicks++,1==t.userEvents._clicks&&(t._clickTimeout=setTimeout((function(){1==t.userEvents._clicks?t._trigger(_,e):t._trigger(b,e),t.userEvents._clicks=0}),300))},_hold:function(){this._trigger(h,this.pressEvent)},move:function(e){var t=this,n="api"!==e.type&&t.userEvents._shouldNotMove;if(!t._finished&&!n){if(t.x.move(e.location),t.y.move(e.location),!t._moved){if(t._withinIgnoreThreshold())return;if(I.current&&I.current!==t.userEvents)return t.dispose();t._start(e)}t._finished||t._trigger(m,e)}},end:function(e){this.endTime=o(),this._finished||(this._finished=!0,this._trigger(y,e),this._moved?this._trigger(g,e):this.useClickAsTap||(this.supportDoubleTap?this._tap(e):this._trigger(_,e)),clearTimeout(this._holdTimeout),this.dispose())},dispose:function(){var t=this.userEvents.touches;this._finished=!0,this.pressEvent=null,clearTimeout(this._holdTimeout),t.splice(e.inArray(this,t),1)},skip:function(){this.dispose()},cancel:function(){this.dispose()},isMoved:function(){return this._moved},_start:function(e){clearTimeout(this._holdTimeout),this.startTime=o(),this._moved=!0,this._trigger(f,e)},_trigger:function(e,t){var n=this,i=t.event,r={touch:n,x:n.x,y:n.y,target:n.target,event:i};n.userEvents.notify(e,r)&&i.preventDefault()},_withinIgnoreThreshold:function(){var e=this.x.initialDelta,t=this.y.initialDelta;return Math.sqrt(e*e+t*t)<=this.threshold}});function E(e){for(var n=t.eventMap.up.split(" "),i=0,r=n.length;i<r;i++)e(n[i])}var I=r.extend({init:function(i,o){var s,l=this,C=t.guid();if(o=o||{},s=l.filter=o.filter,l.threshold=o.threshold||d,l.minHold=o.minHold||c,l.touches=[],l._maxTouches=o.multiTouch?2:1,l.allowSelection=o.allowSelection,l.captureUpIfMoved=o.captureUpIfMoved,l.useClickAsTap=!o.fastTap&&!n.delayedClick(),l.eventNS=C,l._clicks=0,l.supportDoubleTap=o.supportDoubleTap,i=e(i).handler(l),r.fn.init.call(l),a(l,{element:i,surface:o.global&&S?e(i[0].ownerDocument.documentElement):e(o.surface||i),stopPropagation:o.stopPropagation,preventDefault:o.preventDefault,pressed:!1}),l.surface.handler(l).on(t.applyEventMap("move",C),"_move").on(t.applyEventMap("up cancel",C),"_end"),i.on(t.applyEventMap("down",C),s,"_start"),l.useClickAsTap&&i.on(t.applyEventMap("click",C),s,"_click"),n.pointers||n.msPointers)if(n.browser.version<11){var T="pinch-zoom double-tap-zoom";i.css("-ms-touch-action",o.touchAction&&"none"!=o.touchAction?T+" "+o.touchAction:T)}else i.css("touch-action",o.touchAction||"none");if(o.preventDragEvent&&i.on(t.applyEventMap("dragstart",C),t.preventDefault),i.on(t.applyEventMap("mousedown",C),s,{root:i},"_select"),l.captureUpIfMoved&&n.eventCapture){var D=l.surface[0],A=l.preventIfMoving.bind(l);E((function(e){D.addEventListener(e,A,!0)}))}l.bind([u,h,_,b,f,m,g,y,v,"gesturestart",w,k,x,p],o)},preventIfMoving:function(e){this._isMoved()&&e.preventDefault()},destroy:function(){var e=this;if(!e._destroyed){if(e._destroyed=!0,e.captureUpIfMoved&&n.eventCapture){var t=e.surface[0];E((function(n){t.removeEventListener(n,e.preventIfMoving)}))}e.element.kendoDestroy(e.eventNS),e.surface.kendoDestroy(e.eventNS),e.element.removeData("handler"),e.surface.removeData("handler"),e._disposeAll(),e.unbind(),delete e.surface,delete e.element,delete e.currentTarget}},capture:function(){I.current=this},cancel:function(){this._disposeAll(),this.trigger(v)},notify:function(e,t){var n=this.touches;if(this._isMultiTouch()){switch(e){case m:e=w;break;case g:e=k;break;case _:e=x}a(t,{touches:n},T(n[0],n[1]))}return this.trigger(e,a(t,{type:e}))},press:function(e,t,n){this._apiCall("_start",e,t,n)},move:function(e,t){this._apiCall("_move",e,t)},end:function(e,t){this._apiCall("_end",e,t)},_isMultiTouch:function(){return this.touches.length>1},_maxTouchesReached:function(){return this.touches.length>=this._maxTouches},_disposeAll:function(){for(var e=this.touches;e.length>0;)e.pop().dispose()},_isMoved:function(){return e.grep(this.touches,(function(e){return e.isMoved()})).length},_select:function(e){this.allowSelection&&!this.trigger(p,{event:e})||e.preventDefault()},_start:function(t){var n,i,r=this,o=0,a=r.filter,s=D(t),l=s.length,c=t.which;if(!(c&&c>1||r._maxTouchesReached()))for(I.current=null,r.currentTarget=t.currentTarget,r.preventDefault&&t.preventDefault(),r.stopPropagation&&t.stopPropagation();o<l&&!r._maxTouchesReached();o++)i=s[o],(n=a?e(i.currentTarget):r.element).length&&(i=new M(r,n,i),r.touches.push(i),i.press(),r._isMultiTouch()&&r.notify("gesturestart",{}))},_move:function(e){this._eachTouch("move",e)},_end:function(e){this._eachTouch("end",e)},_click:function(t){var n={touch:{initialTouch:t.target,target:e(t.currentTarget),endTime:o(),x:{location:t.pageX,client:t.clientX},y:{location:t.pageY,client:t.clientY}},x:t.pageX,y:t.pageY,target:e(t.currentTarget),event:t,type:"tap"};this.trigger("tap",n)&&t.preventDefault()},_eachTouch:function(e,t){var n,i,r,o,a={},s=D(t),l=this.touches;for(n=0;n<l.length;n++)a[(i=l[n]).id]=i;for(n=0;n<s.length;n++)(o=a[(r=s[n]).id])&&o[e](r)},_apiCall:function(t,n,i,r){this[t]({api:!0,pageX:n,pageY:i,clientX:n,clientY:i,target:e(r||this.element)[0],stopPropagation:e.noop,preventDefault:e.noop})}}),z=r.extend({init:function(n,i){var o,s=this,l=t.guid();i=i||{},o=s.filter=i.filter,s.touches=[],s._maxTouches=1,s.eventNS=l,s._downStarted=0,n=e(n).handler(s),r.fn.init.call(s),a(s,{element:n,surface:i.global&&S?e(n[0].ownerDocument.documentElement):e(i.surface||n),stopPropagation:i.stopPropagation,pressed:!1}),s.surface.handler(s).on(t.applyEventMap("move",l),"_move").on(t.applyEventMap("cancel up",l),"cancel"),n.on(t.applyEventMap("down",l),o,"_down").on(t.applyEventMap("up",l),o,"_up"),s.bind([f,m,g,h,v,p],i)},_down:function(e){e.which&&e.which>1?this.cancel():(this._downStarted=(new Date).getTime(),this._downTarget=e.target)},_up:function(e){var t=(new Date).getTime(),n=e.target;(!e.which||1===e.which)&&t<this._downStarted+300&&n===this._downTarget?(this.touches&&this.touches.length>0?this._end(e):this._start(e),this._preventCancel=!0):this.cancel(),this._downStarted=0,this._downTarget=null},destroy:function(){var e=this;e._destroyed||(e._destroyed=!0,e.element.kendoDestroy(e.eventNS),e.surface.kendoDestroy(e.eventNS),e.element.removeData("handler"),e.surface.removeData("handler"),e._disposeAll(),e.unbind(),delete e.surface,delete e.element,delete e.currentTarget)},capture:function(){z.current=this},cancel:function(){this._preventCancel?this._preventCancel=!1:this.touches&&this.touches.length>0&&(this._disposeAll(),this.trigger(v))},notify:function(e,t){return t.clickMoveClick=!0,this.trigger(e,a(t,{type:e}))},_maxTouchesReached:function(){return this.touches.length>=this._maxTouches},_disposeAll:function(){for(var e=this.touches;e.length>0;)e.pop().dispose()},_start:function(t){var n,i,r=this,o=0,a=r.filter,s=D(t),l=s.length,c=t.which;if(!(c&&c>1||r._maxTouchesReached()))for(z.current=null,r.currentTarget=t.currentTarget,r.stopPropagation&&t.stopPropagation();o<l&&!r._maxTouchesReached();o++)i=s[o],(n=a?e(i.currentTarget):r.element).length&&(i=new M(r,n,i),r.touches.push(i),i.press(),i._start(i))},_move:function(e){this._eachTouch("move",e)},_end:function(e){this._eachTouch("move",e),this._eachTouch("end",e)},_eachTouch:function(e,t){var n,i,r,o,a={},s=D(t),l=this.touches;for(n=0;n<l.length;n++)a[(i=l[n]).id]=i;for(n=0;n<s.length;n++)(o=a[(r=s[n]).id])&&(o.x.move(r.location),o.y.move(r.location),o[e](r))}});I.defaultThreshold=function(e){d=e},I.minHold=function(e){c=e},t.getTouches=D,t.touchDelta=T,t.UserEvents=I,t.ClickMoveClick=z}(window.kendo.jQuery);kendo;!function(e){var t,n=window.kendo,i=n.support,r=window.document,o=e(window),a=n.Class,s=n.ui.Widget,l=n.Observable,c=n.UserEvents,d=n.ClickMoveClick,u=e.extend,h=n.getOffset,p={},f={},m={},g=n.elementUnderCursor,v="keyup",_="change",b="dragstart",y="hold",w="drag",k="dragend",x="dragcancel",C="hintDestroyed",S="dragenter",T="dragleave",D="drop";function A(e,t){return parseInt(e.css(t),10)||0}function M(e,t){return Math.min(Math.max(e,t.min),t.max)}function E(e,t){var i=h(e),r=n._outerWidth,o=n._outerHeight,a=i.left+A(e,"borderLeftWidth")+A(e,"paddingLeft"),s=i.top+A(e,"borderTopWidth")+A(e,"paddingTop");return{x:{min:a,max:a+e.width()-r(t,!0)},y:{min:s,max:s+e.height()-o(t,!0)}}}var I,z=l.extend({init:function(t,i){var r=this,o=t[0];r.capture=!1,o.addEventListener?(e.each(n.eventMap.down.split(" "),(function(){o.addEventListener(this,r._press.bind(r),!0)})),e.each(n.eventMap.up.split(" "),(function(){o.addEventListener(this,r._release.bind(r),!0)}))):(e.each(n.eventMap.down.split(" "),(function(){o.attachEvent(this,r._press.bind(r))})),e.each(n.eventMap.up.split(" "),(function(){o.attachEvent(this,r._release.bind(r))}))),l.fn.init.call(r),r.bind(["press","release"],i||{})},captureNext:function(){this.capture=!0},cancelCapture:function(){this.capture=!1},_press:function(e){this.trigger("press"),this.capture&&e.preventDefault()},_release:function(e){var t=this;t.trigger("release"),t.capture&&(e.preventDefault(),t.cancelCapture())}}),P=l.extend({init:function(t){var n=this;l.fn.init.call(n),n.forcedEnabled=!1,e.extend(n,t),n.scale=1,n.horizontal?(n.measure="offsetWidth",n.scrollSize="scrollWidth",n.axis="x"):(n.measure="offsetHeight",n.scrollSize="scrollHeight",n.axis="y")},makeVirtual:function(){e.extend(this,{virtual:!0,forcedEnabled:!0,_virtualMin:0,_virtualMax:0})},virtualSize:function(e,t){this._virtualMin===e&&this._virtualMax===t||(this._virtualMin=e,this._virtualMax=t,this.update())},outOfBounds:function(e){return e>this.max||e<this.min},forceEnabled:function(){this.forcedEnabled=!0},getSize:function(){return this.container[0][this.measure]},getTotal:function(){return this.element[0][this.scrollSize]},rescale:function(e){this.scale=e},update:function(e){var t=this,n=t.virtual?t._virtualMax:t.getTotal(),i=n*t.scale,r=t.getSize();(0!==n||t.forcedEnabled)&&(t.max=t.virtual?-t._virtualMin:0,t.size=r,t.total=i,t.min=Math.min(t.max,r-i),t.minScale=r/n,t.centerOffset=(i-r)/2,t.enabled=t.forcedEnabled||i>r,e||t.trigger(_,t))}}),H=l.extend({init:function(e){var t=this;l.fn.init.call(t),t.x=new P(u({horizontal:!0},e)),t.y=new P(u({horizontal:!1},e)),t.container=e.container,t.forcedMinScale=e.minScale,t.maxScale=e.maxScale||100,t.bind(_,e)},rescale:function(e){this.x.rescale(e),this.y.rescale(e),this.refresh()},centerCoordinates:function(){return{x:Math.min(0,-this.x.centerOffset),y:Math.min(0,-this.y.centerOffset)}},refresh:function(){var e=this;e.x.update(),e.y.update(),e.enabled=e.x.enabled||e.y.enabled,e.minScale=e.forcedMinScale||Math.min(e.x.minScale,e.y.minScale),e.fitScale=Math.max(e.x.minScale,e.y.minScale),e.trigger(_)}}),F=l.extend({init:function(e){u(this,e),l.fn.init.call(this)},outOfBounds:function(){return this.dimension.outOfBounds(this.movable[this.axis])},dragMove:function(e){var t=this,n=t.dimension,i=t.axis,r=t.movable,o=r[i]+e;n.enabled&&((o<n.min&&e<0||o>n.max&&e>0)&&(e*=t.resistance),r.translateAxis(i,e),t.trigger(_,t))}}),R=a.extend({init:function(t){var n,i,r,o,a=this;u(a,{elastic:!0},t),r=a.elastic?.5:0,o=a.movable,a.x=n=new F({axis:"x",dimension:a.dimensions.x,resistance:r,movable:o}),a.y=i=new F({axis:"y",dimension:a.dimensions.y,resistance:r,movable:o}),a.userEvents.bind(["press","move","end","gesturestart","gesturechange"],{gesturestart:function(e){a.gesture=e,a.offset=a.dimensions.container.offset()},press:function(t){e(t.event.target).closest("a").is("[data-navigate-on-press=true]")&&t.sender.cancel()},gesturechange:function(e){var t,r=a.gesture,s=r.center,l=e.center,c=e.distance/r.distance,d=a.dimensions.minScale,u=a.dimensions.maxScale;o.scale<=d&&c<1&&(c+=.8*(1-c)),o.scale*c>=u&&(c=u/o.scale);var h=o.x+a.offset.left,p=o.y+a.offset.top;t={x:(h-s.x)*c+l.x-h,y:(p-s.y)*c+l.y-p},o.scaleWith(c),n.dragMove(t.x),i.dragMove(t.y),a.dimensions.rescale(o.scale),a.gesture=e,e.preventDefault()},move:function(e){e.event.target.tagName.match(/textarea|input/i)||(n.dimension.enabled||i.dimension.enabled?(n.dragMove(e.x.delta),i.dragMove(e.y.delta),e.preventDefault()):e.touch.skip())},end:function(e){e.preventDefault()}})}});I=i.hasHW3D?function(e,t,n){return"translate3d("+e+"px,"+t+"px,0) scale("+n+")"}:function(e,t,n){return"translate("+e+"px,"+t+"px) scale("+n+")"};var L=l.extend({init:function(t){var n=this;l.fn.init.call(n),n.element=e(t),n.element[0].style.webkitTransformOrigin="left top",n.x=0,n.y=0,n.scale=1,n._saveCoordinates(I(n.x,n.y,n.scale))},translateAxis:function(e,t){this[e]+=t,this.refresh()},scaleTo:function(e){this.scale=e,this.refresh()},scaleWith:function(e){this.scale*=e,this.refresh()},translate:function(e){this.x+=e.x,this.y+=e.y,this.refresh()},moveAxis:function(e,t){this[e]=t,this.refresh()},moveTo:function(e){u(this,{x:e.x,y:e.y}),this.refresh()},refresh:function(){var e,t=this,i=t.x,r=t.y;t.round&&(i=Math.round(i),r=Math.round(r)),(e=I(i,r,t.scale))!=t.coordinates&&(n.support.browser.msie&&n.support.browser.version<10?(t.element[0].style.position="absolute",t.element[0].style.left=t.x+"px",t.element[0].style.top=t.y+"px"):t.element[0].style.transform=e,t._saveCoordinates(e),t.trigger(_))},_saveCoordinates:function(e){this.coordinates=e}});function B(e,t){var n,i=t.options.group,r=e[i];if(s.fn.destroy.call(t),r.length>1){for(n=0;n<r.length;n++)if(r[n]==t){r.splice(n,1);break}}else r.length=0,delete e[i]}var O=s.extend({init:function(e,t){var n=this;s.fn.init.call(n,e,t);var i=n.options.group;i in f?f[i].push(n):f[i]=[n]},events:[S,T,D],options:{name:"DropTarget",group:"default"},destroy:function(){B(f,this)},_trigger:function(e,t){var n=p[this.options.group];if(n)return this.trigger(e,u({},t.event,{draggable:n,dropTarget:t.dropTarget}))},_over:function(e){this._trigger(S,e)},_out:function(e){this._trigger(T,e)},_drop:function(e){var t=p[this.options.group];t&&(t.dropped=!this._trigger(D,e))}});O.destroyGroup=function(e){var t,n=f[e]||m[e];if(n){for(t=0;t<n.length;t++)s.fn.destroy.call(n[t]);n.length=0,delete f[e],delete m[e]}},O._cache=f;var V=O.extend({init:function(e,t){var n=this;s.fn.init.call(n,e,t);var i=n.options.group;i in m?m[i].push(n):m[i]=[n]},destroy:function(){B(m,this)},options:{name:"DropTargetArea",group:"default",filter:null}}),N=s.extend({init:function(e,t){var i=this;s.fn.init.call(i,e,t),i._activated=!1,this.options.clickMoveClick&&(i.clickMoveClick=new d(i.element,{global:!0,filter:i.options.filter,start:i._startClickMoveClick.bind(i),move:i._drag.bind(i),end:i._end.bind(i),cancel:i._onCancel.bind(i)})),i.userEvents=new c(i.element,{global:!0,allowSelection:!0,filter:i.options.filter,threshold:i.options.distance,start:i._start.bind(i),hold:i._hold.bind(i),move:i._drag.bind(i),end:i._end.bind(i),cancel:i._onCancel.bind(i),select:i._select.bind(i),press:i._press.bind(i)}),n.support.touch&&i.element.find(i.options.filter).css("touch-action","none"),i._afterEndHandler=i._afterEnd.bind(i),i._captureEscape=i._captureEscape.bind(i)},events:[y,b,w,k,x,C],options:{name:"Draggable",distance:n.support.touch?0:5,group:"default",cursorOffset:null,axis:null,container:null,filter:null,ignore:null,holdToDrag:!1,showHintOnHold:!1,autoScroll:!1,dropped:!1,clickMoveClick:!1,preventOsHoldFeatures:!1},cancelHold:function(){this._activated=!1},_captureEscape:function(e){var t=this;e.keyCode===n.keys.ESC&&(t.userEvents.cancel(),t.clickMoveClick&&t.clickMoveClick.cancel(),this._trigger(x,{event:e}))},_updateHint:function(t){var i,r=this,o=r.options,a=r.boundaries,s=o.axis,l=r.options.cursorOffset,c=o.updateHint;if(l?i={left:t.x.location+l.left,top:t.y.location+l.top}:0!==t.x.delta||0!==t.y.delta?(r.hintOffset.left+=t.x.delta,r.hintOffset.top+=t.y.delta,i=e.extend({},r.hintOffset)):(r.hintOffset.left=t.x.startLocation+t.x.initialDelta,r.hintOffset.top=t.y.startLocation+t.y.initialDelta,i=e.extend({},r.hintOffset)),a&&(i.top=M(i.top,a.y),i.left=M(i.left,a.x)),"x"===s?delete i.top:"y"===s&&delete i.left,c&&n.isFunction(c))return e(c.call(r,r.hint,t));r.hint.css(i)},_shouldIgnoreTarget:function(t){var n=this.options.ignore;return n&&e(t).is(n)},_select:function(e){this._shouldIgnoreTarget(e.event.target)||e.preventDefault()},_startClickMoveClick:function(e){this._activated=!0,this._start(e)},_hint:function(){var t=this,i=t.options.hint;if(i){t.hint&&t.hint.stop(!0,!0).remove(),t.hint=n.isFunction(i)?e(i.call(t,t.currentTarget)):i;var o=h(t.currentTarget);t.hintOffset=o,t.hint.css({position:"absolute",zIndex:2e4,left:o.left,top:o.top}).appendTo(r.body)}},_start:function(t){var n=this,i=n.options,o=i.container?e(i.container):null,a=i.hint;this._shouldIgnoreTarget(t.touch.initialTouch)||i.holdToDrag&&!n._activated?n.userEvents.cancel():(n.currentTarget=t.target,n.currentTargetOffset=h(n.currentTarget),a&&n._hint(),p[i.group]=n,n.dropped=!1,o&&(n.boundaries=E(o,n.hint)),e(r).on(v,n._captureEscape),n._trigger(b,t)&&(n.userEvents.cancel(),n.clickMoveClick&&n.clickMoveClick.cancel(),n._afterEnd()),n.userEvents.capture())},_hold:function(e){this.currentTarget=e.target,this._trigger(y,e)?this.userEvents.cancel():(this._activated=!0,this.options.showHintOnHold&&this._hint())},_drag:function(t){t.preventDefault();var n=this._elementUnderCursor(t);if(this.options.autoScroll&&this._cursorElement!==n&&(this._scrollableParent=W(n),this._cursorElement=n),this._lastEvent=t,this._processMovement(t,n),this.options.autoScroll&&this._scrollableParent[0]){var i=j(t.x.location,t.y.location,$(this._scrollableParent));this._scrollCompenstation=e.extend({},this.hintOffset),this._scrollVelocity=i,0===i.y&&0===i.x?(clearInterval(this._scrollInterval),this._scrollInterval=null):this._scrollInterval||(this._scrollInterval=setInterval(this._autoScroll.bind(this),50))}this.hint&&this._updateHint(t)},_processMovement:function(n,i){this._withDropTarget(i,(function(i,r){if(i){if(t){if(r===t.targetElement)return;t._trigger(T,u(n,{dropTarget:e(t.targetElement)}))}i._trigger(S,u(n,{dropTarget:e(r)})),t=u(i,{targetElement:r})}else t&&(t._trigger(T,u(n,{dropTarget:e(t.targetElement)})),t=null)})),this._trigger(w,u(n,{dropTarget:t,elementUnderCursor:i}))},_autoScroll:function(){var e=this._scrollableParent[0],t=this._scrollVelocity,n=this._scrollCompenstation;if(e){var i,a,s=this._elementUnderCursor(this._lastEvent);this._processMovement(this._lastEvent,s);var l=e===U()[0];l?(i=r.body.scrollHeight>o.height(),a=r.body.scrollWidth>o.width()):(i=e.offsetHeight<=e.scrollHeight,a=e.offsetWidth<=e.scrollWidth);var c=e.scrollTop+t.y,d=i&&c>0&&c<e.scrollHeight,u=e.scrollLeft+t.x,h=a&&u>0&&u<e.scrollWidth;d?e.scrollTop+=t.y:i&&c<0&&(e.scrollTop=0),h?e.scrollLeft+=t.x:a&&u<0&&(e.scrollLeft=0),this.hint&&l&&(h||d)&&(d&&(n.top+=t.y),h&&(n.left+=t.x),this.hint.css(n))}},_press:function(e){this.options.preventOsHoldFeatures&&(e.target.css("-webkit-user-select","none"),e.target.attr("unselectable","on"),e.target.one("contextmenu",(e=>{e.preventDefault()})))},_end:function(n){this._withDropTarget(this._elementUnderCursor(n),(function(i,r){i&&(i._drop(u({},n,{dropTarget:e(r)})),t=null)})),clearInterval(this._scrollInterval),this._scrollInterval=null,this._cancel(this._trigger(k,n))},_onCancel:function(e){this._cancel(),this._trigger(x,{event:e})},_cancel:function(e){var t=this;t._scrollableParent=null,this._cursorElement=null,clearInterval(this._scrollInterval),t._activated=!1,t.hint&&!t.dropped?setTimeout((function(){t.hint.stop(!0,!0),e?t._afterEndHandler():t.hint.animate(t.currentTargetOffset,"fast",t._afterEndHandler)}),0):t._afterEnd()},_trigger:function(e,t){return this.trigger(e,u({},t.event,{x:t.x,y:t.y,currentTarget:this.currentTarget,initialTarget:t.touch?t.touch.initialTouch:null,dropTarget:t.dropTarget,elementUnderCursor:t.elementUnderCursor,clickMoveClick:t.clickMoveClick}))},_elementUnderCursor:function(t){var n=g(t),i=this.hint;return i&&function(t,n){try{return e.contains(t,n)||t==n}catch(e){return!1}}(i[0],n)&&(i.hide(),(n=g(t))||(n=g(t)),i.show()),n},_withDropTarget:function(t,n){var r,o=this.options.group,a=f[o],s=m[o];(a&&a.length||s&&s.length)&&(r=function(t,n,r){for(var o,a,s=0,l=n&&n.length,c=r&&r.length;t&&t.parentNode;){for(s=0;s<l;s++)if((o=n[s]).element[0]===t)return{target:o,targetElement:t};for(s=0;s<c;s++)if(a=r[s],e.contains(a.element[0],t)&&i.matchesSelector.call(t,a.options.filter))return{target:a,targetElement:t};t=t.parentNode}}(t,a,s),r?n(r.target,r.targetElement):n())},destroy:function(){var e=this;s.fn.destroy.call(e),e._afterEnd(),e.userEvents.destroy(),e.clickMoveClick&&e.clickMoveClick.destroy(),this._scrollableParent=null,this._cursorElement=null,clearInterval(this._scrollInterval),e.currentTarget=null},_afterEnd:function(){var t=this;t.hint&&t.hint.remove(),delete p[t.options.group],t.trigger("destroy"),t.trigger(C),e(r).off(v,t._captureEscape)}});function $(e){var t,n,i,r=U()[0];return e[0]===r?{top:n=r.scrollTop,left:i=r.scrollLeft,bottom:n+o.height(),right:i+o.width()}:((t=e.offset()).bottom=t.top+e.height(),t.right=t.left+e.width(),t)}function U(){return e(n.support.browser.edge||n.support.browser.safari?r.body:r.documentElement)}function W(t){var i=U();if(!t||t===r.body||t===r.documentElement)return i;for(var o=e(t)[0];o&&!n.isScrollable(o)&&o!==r.body;)o=o.parentNode;return o===r.body?i:e(o)}function j(e,t,n){var i={x:0,y:0},r=50;return e-n.left<r?i.x=-(r-(e-n.left)):n.right-e<r&&(i.x=r-(n.right-e)),t-n.top<r?i.y=-(r-(t-n.top)):n.bottom-t<r&&(i.y=r-(n.bottom-t)),i}n.ui.plugin(O),n.ui.plugin(V),n.ui.plugin(N),n.TapCapture=z,n.containerBoundaries=E,u(n.ui,{Pane:R,PaneDimensions:H,Movable:L}),n.ui.Draggable.utils={autoScrollVelocity:j,scrollableViewPort:$,findScrollableParent:W}}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.mobile,i=t.effects,r=n.ui,o=e.extend,a=r.Widget,s=t.Class,l=t.ui.Movable,c=t.ui.Pane,d=t.ui.PaneDimensions,u=i.Transition,h=i.Animation,p=Math.abs,f="km-scroller-release",m="km-scroller-refresh",g="change",v="scroll",_=h.extend({init:function(e){var t=this;h.fn.init.call(t),o(t,e),t.userEvents.bind("gestureend",t.start.bind(t)),t.tapCapture.bind("press",t.cancel.bind(t))},enabled:function(){return this.movable.scale<this.dimensions.minScale},done:function(){return this.dimensions.minScale-this.movable.scale<.01},tick:function(){var e=this.movable;e.scaleWith(1.1),this.dimensions.rescale(e.scale)},onEnd:function(){var e=this.movable;e.scaleTo(this.dimensions.minScale),this.dimensions.rescale(e.scale)}}),b=h.extend({init:function(e){var t=this;h.fn.init.call(t),o(t,e,{transition:new u({axis:e.axis,movable:e.movable,onEnd:function(){t._end()}})}),t.tapCapture.bind("press",(function(){t.cancel()})),t.userEvents.bind("end",t.start.bind(t)),t.userEvents.bind("gestureend",t.start.bind(t)),t.userEvents.bind("tap",t.onEnd.bind(t))},onCancel:function(){this.transition.cancel()},freeze:function(e){this.cancel(),this._moveTo(e)},onEnd:function(){var e=this;e.paneAxis.outOfBounds()?e._snapBack():e._end()},done:function(){return p(this.velocity)<1},start:function(e){var t,n=this;n.dimension.enabled&&(n.paneAxis.outOfBounds()?n.transition._started?(n.transition.cancel(),n.velocity=Math.min(e.touch[n.axis].velocity*n.velocityMultiplier,55),h.fn.start.call(n)):n._snapBack():(t=2===e.touch.id?0:e.touch[n.axis].velocity,n.velocity=Math.max(Math.min(t*n.velocityMultiplier,55),-55),n.tapCapture.captureNext(),h.fn.start.call(n)))},tick:function(){var e=this,t=e.dimension,n=e.paneAxis.outOfBounds()?.5:e.friction,i=e.velocity*=n,r=e.movable[e.axis]+i;!e.elastic&&t.outOfBounds(r)&&(r=Math.max(Math.min(r,t.max),t.min),e.velocity=0),e.movable.moveAxis(e.axis,r)},_end:function(){this.tapCapture.cancelCapture(),this.end()},_snapBack:function(){var e=this,t=e.dimension,n=e.movable[e.axis]>t.max?t.max:t.min;e._moveTo(n)},_moveTo:function(e){this.transition.moveTo({location:e,duration:500,ease:u.easeOutExpo})}}),y=h.extend({init:function(e){t.effects.Animation.fn.init.call(this),o(this,e,{origin:{},destination:{},offset:{}})},tick:function(){this._updateCoordinates(),this.moveTo(this.origin)},done:function(){return p(this.offset.y)<5&&p(this.offset.x)<5},onEnd:function(){this.moveTo(this.destination),this.callback&&this.callback.call()},setCoordinates:function(e,t){this.offset={},this.origin=e,this.destination=t},setCallback:function(e){e&&t.isFunction(e)?this.callback=e:e=undefined},_updateCoordinates:function(){this.offset={x:(this.destination.x-this.origin.x)/4,y:(this.destination.y-this.origin.y)/4},this.origin={y:this.origin.y+this.offset.y,x:this.origin.x+this.offset.x}}}),w=s.extend({init:function(t){var n=this,i="x"===t.axis,r=e('<div role="scrollbar" aria-controls="'+t.controlsId+'" class="km-touch-scrollbar km-'+(i?"horizontal":"vertical")+'-scrollbar" />');i&&r.attr("aria-orientation","horizontal"),o(n,t,{element:r,elementSize:0,movable:new l(r),scrollMovable:t.movable,alwaysVisible:t.alwaysVisible,size:i?"width":"height"}),n.scrollMovable.bind(g,n.refresh.bind(n)),n.container.append(r),t.alwaysVisible&&n.show()},refresh:function(){var e=this,t=e.axis,n=e.dimension,i=n.size,r=e.scrollMovable,o=i/n.total,a=Math.round(-r[t]*o),s=Math.round(i*o);o>=1?this.element.css("display","none"):this.element.css("display",""),a+s>i?s=i-a:a<0&&(s+=a,a=0),e.elementSize!=s&&(e.element.css(e.size,s+"px"),e.elementSize=s),e._ariaValue(a,n.size-e.elementSize),e.movable.moveAxis(t,a)},show:function(){this.element.css({opacity:.7,visibility:"visible"})},hide:function(){this.alwaysVisible||this.element.css({opacity:0})},_ariaValue:function(e,t){var n=this.element;e>t&&(e=t),n.attr("aria-valuemax",t),n.attr("aria-valuenow",e)}}),k=a.extend({init:function(n,i){var r=this;if(a.fn.init.call(r,n,i),n=r.element,r._native=r.options.useNative&&t.support.hasNativeScrolling,r._native)return n.addClass("km-native-scroller").prepend('<div class="km-scroll-header"/>'),void o(r,{scrollElement:n,fixedContainer:n.children().first()});n.css("overflow","hidden").addClass("km-scroll-wrapper").wrapInner('<div class="km-scroll-container"/>').prepend('<div class="km-scroll-header"/>');var s=n.children().eq(1),u=new t.TapCapture(n),h=new l(s),f=new d({element:s,container:n,forcedEnabled:r.options.zoom}),m=this.options.avoidScrolling,b=new t.UserEvents(n,{touchAction:"pan-y",fastTap:!0,allowSelection:!0,preventDragEvent:!0,captureUpIfMoved:!0,multiTouch:r.options.zoom,supportDoubleTap:r.options.supportDoubleTap,start:function(t){f.refresh();var n=p(t.x.velocity),i=p(t.y.velocity),o=2*n>=i,a=2*i>=n;!e.contains(r.fixedContainer[0],t.event.target)&&!m(t)&&r.enabled&&(f.x.enabled&&o||f.y.enabled&&a)?b.capture():b.cancel()}}),w=new c({movable:h,dimensions:f,userEvents:b,elastic:r.options.elastic}),k=new _({movable:h,dimensions:f,userEvents:b,tapCapture:u}),x=new y({moveTo:function(e){r.scrollTo(e.x,e.y)}});h.bind(g,(function(){r.scrollTop=-h.y,r.scrollLeft=-h.x,r.trigger(v,{scrollTop:r.scrollTop,scrollLeft:r.scrollLeft})})),r.options.mousewheelScrolling&&n.on("DOMMouseScroll mousewheel",this._wheelScroll.bind(this)),o(r,{movable:h,dimensions:f,zoomSnapBack:k,animatedScroller:x,userEvents:b,pane:w,tapCapture:u,pulled:!1,enabled:!0,scrollElement:s,scrollTop:0,scrollLeft:0,fixedContainer:n.children().first()}),r._initAxis("x"),r._initAxis("y"),r._wheelEnd=function(){r._wheel=!1,r.userEvents.end(0,r._wheelY)},f.refresh(),r.options.pullToRefresh&&r._initPullToRefresh()},_wheelScroll:function(e){if(!e.ctrlKey){this._wheel||(this._wheel=!0,this._wheelY=0,this.userEvents.press(0,this._wheelY)),clearTimeout(this._wheelTimeout),this._wheelTimeout=setTimeout(this._wheelEnd,50);var n=t.wheelDeltaY(e);n&&(this._wheelY+=n,this.userEvents.move(0,this._wheelY)),e.preventDefault()}},makeVirtual:function(){this.dimensions.y.makeVirtual()},virtualSize:function(e,t){this.dimensions.y.virtualSize(e,t)},height:function(){return this.dimensions.y.size},scrollHeight:function(){return this.scrollElement[0].scrollHeight},scrollWidth:function(){return this.scrollElement[0].scrollWidth},options:{name:"Scroller",zoom:!1,pullOffset:140,visibleScrollHints:!1,elastic:!0,useNative:!1,mousewheelScrolling:!0,avoidScrolling:function(){return!1},pullToRefresh:!1,messages:{pullTemplate:"Pull to refresh",releaseTemplate:"Release to refresh",refreshTemplate:"Refreshing"}},events:["pull",v,"resize"],_resize:function(){this._native||this.contentResized()},setOptions:function(e){a.fn.setOptions.call(this,e),e.pullToRefresh&&this._initPullToRefresh()},reset:function(){this._native?this.scrollElement.scrollTop(0):(this.movable.moveTo({x:0,y:0}),this._scale(1))},contentResized:function(){this.dimensions.refresh(),this.pane.x.outOfBounds()&&this.movable.moveAxis("x",this.dimensions.x.min),this.pane.y.outOfBounds()&&this.movable.moveAxis("y",this.dimensions.y.min)},zoomOut:function(){var e=this.dimensions;e.refresh(),this._scale(e.fitScale),this.movable.moveTo(e.centerCoordinates())},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},scrollTo:function(e,n){this._native?(t.scrollLeft(this.scrollElement,p(e)),this.scrollElement.scrollTop(p(n))):(this.dimensions.refresh(),this.movable.moveTo({x:e,y:n}))},animatedScrollTo:function(e,t,n){var i,r;this._native?this.scrollTo(e,t):(i={x:this.movable.x,y:this.movable.y},r={x:e,y:t},this.animatedScroller.setCoordinates(i,r),this.animatedScroller.setCallback(n),this.animatedScroller.start())},pullHandled:function(){var e=this;e.refreshHint.removeClass(m),e.hintContainer.html(e.pullTemplate({})),e.yinertia.onEnd(),e.xinertia.onEnd(),e.userEvents.cancel()},destroy:function(){a.fn.destroy.call(this),this.userEvents&&this.userEvents.destroy()},_scale:function(e){this.dimensions.rescale(e),this.movable.scaleTo(e)},_initPullToRefresh:function(){var e=this;e.dimensions.y.forceEnabled(),e.pullTemplate=t.template(e.options.messages.pullTemplate),e.releaseTemplate=t.template(e.options.messages.releaseTemplate),e.refreshTemplate=t.template(e.options.messages.refreshTemplate),e.scrollElement.prepend('<span class="km-scroller-pull"><span class="km-icon"></span><span class="km-loading-left"></span><span class="km-loading-right"></span><span class="km-template">'+e.pullTemplate({})+"</span></span>"),e.refreshHint=e.scrollElement.children().first(),e.hintContainer=e.refreshHint.children(".km-template"),e.pane.y.bind("change",e._paneChange.bind(e)),e.userEvents.bind("end",e._dragEnd.bind(e))},_dragEnd:function(){var e=this;e.pulled&&(e.pulled=!1,e.refreshHint.removeClass(f).addClass(m),e.hintContainer.html(e.refreshTemplate({})),e.yinertia.freeze(e.options.pullOffset/2),e.trigger("pull"))},_paneChange:function(){var e=this;e.movable.y/.5>e.options.pullOffset?e.pulled||(e.pulled=!0,e.refreshHint.removeClass(m).addClass(f),e.hintContainer.html(e.releaseTemplate({}))):e.pulled&&(e.pulled=!1,e.refreshHint.removeClass(f),e.hintContainer.html(e.pullTemplate({})))},_initAxis:function(e){var n,i=this,r=i.element.attr("id"),o=i.movable,a=i.dimensions[e],s=i.tapCapture,l=i.pane[e];r||(r=t.guid(),i.element.attr("id",r)),n=new w({axis:e,movable:o,dimension:a,container:i.element,alwaysVisible:i.options.visibleScrollHints,controlsId:r}),a.bind(g,(function(){n.refresh()})),l.bind(g,(function(){n.show()})),i[e+"inertia"]=new b({axis:e,paneAxis:l,movable:o,tapCapture:s,userEvents:i.userEvents,dimension:a,elastic:i.options.elastic,friction:i.options.friction||.96,velocityMultiplier:i.options.velocityMultiplier||10,end:function(){n.hide(),i.trigger("scrollEnd",{axis:e,scrollTop:i.scrollTop,scrollLeft:i.scrollLeft})}})}});r.plugin(k)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.html.HTMLBase,i=n.extend({init:function(e,t){n.fn.init.call(this,e,t),this._wrapper()},options:{name:"HTMLChip",size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base",attr:{},icon:"",iconClass:"",iconAttr:{},removable:!1,removableAttr:{},removeIcon:"x-circle",removeIconClass:"",content:"",text:"",actions:[],stylingOptions:["size","rounded","fillMode","themeColor"]},_wrapper:function(){var n=this,i=n.options;i.text=i.text||i.label,n.wrapper=n.element.wrap("<div class='k-chip'></div>").parent().attr(i.attr),n._addClasses(),i.icon?n.wrapper.prepend(e(t.ui.icon({icon:i.icon,size:"small",iconClass:"k-chip-icon"+(i.iconClass?` ${i.iconClass}`:"")})).attr(i.iconAttr)):i.iconClass?n.wrapper.prepend(e("<span class='"+i.iconClass+"'></span>").attr(i.iconAttr)):i.avatarClass&&n.wrapper.prepend(e("<span class='k-chip-avatar k-avatar k-avatar-md k-avatar-solid k-avatar-solid-primary k-rounded-full "+i.avatarClass+"'></span>").attr(i.iconAttr)),n.element.addClass("k-chip-content"),i.text&&n.element.html('<span class="k-chip-label">'+i.text+"</span>"),!1===i.visible&&n.wrapper.addClass("k-hidden"),!0===i.selected&&n.wrapper.addClass("k-selected"),!1===i.enabled&&n.wrapper.addClass("k-disabled"),(i.actions&&i.actions.length>0||i.removable)&&n._actions()},_actions:function(){var n=this,i=n.options;if(n.actionsWrapper=e("<span class='k-chip-actions'></span>"),n.actionsWrapper.appendTo(n.wrapper),i.actions&&i.actions.length>0)for(var r=0;r<i.actions.length;r++){var o=i.actions[r];n.actionsWrapper.append(e(`<span class='k-chip-action ${o.iconClass?o.iconClass:""}'>${t.ui.icon({icon:o.icon,size:"small"})}</span>`).attr(o.attr?o.attr:{}))}i.removable&&n.actionsWrapper.append(e(`<span class='k-chip-action k-chip-remove-action'>${t.ui.icon({icon:i.removeIcon,size:"small"})}</span>`).attr(i.removableAttr))}});e.extend(t.html,{renderChip:function(t,n){return t&&!e.isPlainObject(t)||(n=t,t=e("<span></span>")),new i(t,n).html()},HTMLChip:i}),t.cssProperties.registerPrefix("HTMLChip","k-chip-"),t.cssProperties.registerValues("HTMLChip",[{prop:"rounded",values:t.cssProperties.roundedValues.concat([["full","full"]])}])}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.html,o=n.ui,a=n.keys,s="select",l="click",c="remove",d=".kendoChip",u="k-chip-remove-action",h="k-selected",p="k-disabled",f=i.extend({init:function(o,a){var s=this;i.fn.init.call(s,o,a),r.renderChip(o,e.extend({},s.options)),a=s.options,s.wrapper=s.element.closest(".k-chip"),s._enabled=s.options.enabled=a.enabled!==t?a.enabled:!Boolean(s.element.is("[disabled]")),s._selected=s.options.selected,s._selectable=s.options.selectable,s._setTabIndex(),s._applyAriaAttributes(),s._bindEvents(),n.notify(s)},options:{name:"Chip",enabled:!0,selectable:!1,selected:!1,removable:!1,icon:"",iconClass:"",avatarClass:"",label:"",removeIcon:"x-circle",removeIconClass:"",fillMode:"solid",rounded:"medium",size:"medium",themeColor:"base"},events:[s,l,c],destroy:function(){this.wrapper.off(d),i.fn.destroy.call(this)},setOptions:function(e){var t=this;t.wrapper.off(d),t.element.insertBefore(t.wrapper),t.wrapper.remove(),i.fn.setOptions.call(t,e),t.element.empty(),r.renderChip(t.element,t.options),t.wrapper=t.element.closest(".k-chip"),t._setTabIndex(),t._applyAriaAttributes(),t._bindEvents()},enable:function(e){var n=this;if(e===t)return n._enabled;n._enabled=!1!==e,n.wrapper.toggleClass(p,!n._enabled),n.wrapper.attr("aria-disabled",!n._enabled)},select:function(e){var n=this;if(e==t)return n._selected;e=!1!==e,n._selectable&&(n._selected=e,n.wrapper.toggleClass(h,e)),n._applyAriaAttributes()},focus:function(){this._enabled&&this.wrapper.trigger("focus")},_bindEvents:function(){var e=this,t=e._click.bind(e),n=e._remove.bind(e),i=e._keydown.bind(e);e.wrapper.on(l+" touchend"+d,t).on(l+" touchend"+d,"."+u,n).on("keydown"+d,i)},_click:function(e){var t=this;t.enable()?t.trigger(l,{originalEvent:e})||t._triggerSelect(t,e):e.preventDefault()},_remove:function(e){e.preventDefault(),e.stopPropagation();this.enable()?this.trigger(c,{originalEvent:e}):e.preventDefault()},_triggerSelect:function(e,t){var n=this;n._selectable&&n._enabled&&!n.trigger(s,{originalEvent:t})&&n._toggleSelect()},_toggleSelect:function(){this.select(!this.select())},_keydown:function(t){var n=this,i=e(t.target),r=t.keyCode;if(r===a.ENTER||r===a.SPACEBAR){if(!n.enable())return void t.preventDefault();if(n.trigger(l,{originalEvent:t}))return;n._triggerSelect(i,t),r===a.SPACEBAR&&t.preventDefault()}else r!==a.DELETE&&r!==a.BACKSPACE||n.options.removable&&n.trigger(c,{originalEvent:t})},_setTabIndex:function(){var t=this,n=t.enable()?t.options.tabindex||"0":"-1";t.options.attributes&&t.options.attributes.class&&(t.options.attributes.class=`${t.wrapper.attr("class")||""} ${t.options.attributes.class}`),t.wrapper.attr(e.extend({},t.options.attributes,{tabindex:n,ariaSelectedAttributeName:null}))},_applyAriaAttributes:function(){var e=this,t=(e.options.attributes||{}).role||"button";e.wrapper.attr("role",t),e._selectable&&"button"==t&&e.wrapper.attr("aria-pressed",e._selected),e.wrapper.attr("aria-disabled",!1===e.enable())}});o.plugin(f)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.html.HTMLBase,i=n.extend({init:function(e,t){var i=this;n.fn.init.call(i,e,t),i.wrapper=i.element.addClass("k-chip-list"),i._applyAriaAttributes(t),i._addClasses()},options:{name:"HTMLChipList",size:"medium",stylingOptions:["size"]},_applyAriaAttributes:function(t){var n=this,i=((t=e.extend({selectable:"none"},t)).attributes||{})["aria-label"];"none"!==t.selectable?n.element.attr({"aria-multiselectable":"multiple"===t.selectable,role:"listbox","aria-label":i||n.element.attr("id")+" listbox","aria-orientation":"horizontal"}):n.element.removeAttr("role aria-label aria-multiselectable aria-orientation")}});e.extend(t.html,{renderChipList:function(t,n){return(undefined===arguments[0]||e.isPlainObject(arguments[0]))&&(n=t,t=e("<div></div>")),new i(t,n).html()},HTMLChipList:i}),t.cssProperties.registerPrefix("HTMLChipList","k-chip-list-")}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=n.Widget,r=t.keys,o=e.isPlainObject,a=e.isEmptyObject,s=".kendoChipList",l=".",c="select",d="remove",u=t.html,h={widget:"k-chip-list",item:"k-chip",selected:"k-selected",disabled:"k-disabled",enabledItemSelector:"k-chip:not(.k-disabled)"},p=i.extend({init:function(t,n){var r=this;n=n||{},i.fn.init.call(r,t,n),u.renderChipList(t,e.extend({},n)),r._selectable=r.options.selectable,r._bindEvents(),r._items()},options:{name:"ChipList",selectable:"none",items:[],fillMode:"solid",rounded:"medium",size:"medium",itemSize:"medium"},events:[c,d],destroy:function(){var e=this;e._keydownProxy&&(e.unbind(e._keydownProxy),e._keydownProxy=null),e._selectProxy&&(e.unbind(e._selectProxy),e._selectProxy=null),e._removeProxy&&(e.unbind(e._removeProxy),e._removeProxy=null),e.element.off(s),e.element.find("[data-role='chip']").each((function(){e._getChipFromElement(this).destroy()})),i.fn.destroy.call(this)},_updateCssClasses:function(){var e=this,n=e.options,i=h;e.element.removeClass((function(t,n){0===n.indexOf("k-")&&e.element.removeClass(n)})),e.element.addClass(i.widget),e.element.addClass(t.getValidCssClass("k-chip-list-","size",n.size))},_getInitializeChipOptions:function(t){var n=this,i=n.options,r=e.extend(t.attributes||{},{tabindex:"-1"});return"none"!==i.selectable&&(r.role="option",r["aria-selected"]=t.selected),(i.removable||t.removable)&&(r["aria-keyshortcuts"]="Enter Delete"),e.extend({fillMode:i.fillMode,size:i.itemSize,rounded:i.rounded,selectable:"none"!==i.selectable,removable:i.removable,remove:n._removeProxy,select:n._selectProxy},t,{attributes:r})},_getChipFromElement:function(t){return e(t).getKendoChip()||e(t).find("[data-role='chip']").getKendoChip()},_items:function(){for(var t,n,i,r,o=this,a=o.options.items,s=0;s<a.length;s++)t=o._getInitializeChipOptions(a[s]),i=e("<span></span>"),o.element.append(i),o._createChip(i,t);(r=o._getFirstNavigatableItem())&&o._applyTabIndex(o.items().index(r)),"single"===o._selectable&&(n=o.items().filter(l+h.selected)).each((function(e,t){if(e!==n.length-1){var i=o._getChipFromElement(t);i&&i.select(!1)}}))},_isItem:function(t){return(t=e(t)).is(l+h.item)&&!!this.element.find(t).length},_applyTabIndex:function(t){var n=this.item(+t?+t:0);this.items().each((function(t,n){e(n).attr("tabindex","-1")})),n.attr("tabindex","0")},_createChip:function(e,t){return e.kendoChip(t)},_bindEvents:function(){var e=this;e._keydownProxy=e._keydown.bind(e),e._selectProxy=e._select.bind(e),e._removeProxy=e._remove.bind(e),e.element.on("keydown"+s,l+h.item,e._keydownProxy)},_select:function(e){var t=e.sender;"none"!=this._selectable?this._triggerSelect(t,e):e.preventDefault()},_triggerSelect:function(e,t){var n,i=this;i.element.is(l+h.disabled)||i.trigger(c,{originalEvent:t,item:e})||"single"===i._selectable&&(n=i.select()).length>0&&n.each((function(t,n){var r=i._getChipFromElement(n);r&&r!==e&&r.select(!1)}))},_remove:function(e){var t=e.sender;this.trigger(d,{originalEvent:e,item:e.sender})||this._removeItem(t)},_removeItem:function(e){if(e){var t=e.wrapper;e.destroy(),t.remove(),this._focusNavigatableItem()}},_keydown:function(t){var n=e(t.target).closest(l+h.item),i=t.keyCode;i!==r.LEFT&&i!==r.RIGHT||this._focusNavigatableItem(i,n)},_focusNavigatableItem:function(e,t){var n=this,i=n._getNavigatableItem(e,t);i&&(n._applyTabIndex(n.items().index(i)),i.trigger("focus"))},_getFirstNavigatableItem:function(){return this.items().filter(l+h.enabledItemSelector).first()},_getLastNavigatableItem:function(){return this.items().filter(l+h.enabledItemSelector).last()},_getNavigatableItem:function(e,t){var n;return n=t||this._getFirstNavigatableItem(),e===r.LEFT&&t&&(n=t.prevAll(l+h.enabledItemSelector).first()),e===r.RIGHT&&t&&(n=t.nextAll(l+h.enabledItemSelector).first()),n.length?n:null},items:function(){return this.element.children()},select:function(e,t){var n,i=this,r=i.items().filter(l+h.selected);if(!e)return r;t=!1!==t,(n=i._getChipFromElement(e))&&("single"===i._selectable&&(r=i.select()).length>0&&r.each((function(t,n){var r=i._getChipFromElement(n);r&&r!==e&&r.select(!1)})),n.select(t))},enable:function(e,t){var n=this._getChipFromElement(e);t=!1!==t,n&&n.enable(t)},item:function(e){return isNaN(e)?null:this.items().eq(e)},itemById:function(e){return this.element.find("#"+e)},add:function(t,n){var i,r,s=this,l="append",c=s.element;n&&s._isItem(n)&&(l="before",c=e(n)),(i=s._getChipFromElement(t))?("none"!==s._selectable&&i.wrapper.attr("role","option"),c[l](i.wrapper)):t&&o(t)&&!a(t)&&(r=e("<span></span>"),c[l](r),s._createChip(r,s._getInitializeChipOptions(t)))},remove:function(e){e&&this._isItem(e)&&(t.destroy(e),e.remove(),this._focusNavigatableItem())},setOptions:function(e){var t=this;i.fn.setOptions.call(this,e),t._updateCssClasses(),e.items&&(t.element.empty(),t._items())}});n.plugin(p)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=t._outerWidth,r=t.attr,o=e.extend,a=e.each,s=!1,l="asc",c="group-sort",d="k-grouping-drop-container",u=function(n){var i=n.attr(t.attr("title"));return i&&(i=t.htmlEncode(i)),e('<div class="k-group-clue k-drag-clue" />').html(i||t.htmlEncode(n.attr(t.attr("field")))).prepend(t.ui.icon({icon:"cancel",iconClass:"k-drag-status"}))},h=e('<div class="k-grouping-dropclue"/>');function p(e){e.contents().filter((function(){return 3===this.nodeType})).remove()}var f=n.extend({init:function(r,a){var l,f,m=this,g=t.guid(),v=m._intializePositions.bind(m);m._dropCuePositions=[];n.fn.init.call(m,r,a),s=t.support.isRtl(r),f=s?"right":"left",m.draggable=l=m.options.draggable||new t.ui.Draggable(m.element,{filter:m.options.draggableElements,hint:u,group:g}),m.groupContainer=e(m.options.groupContainer,m.element).kendoDropTarget({group:l.options.group,dragenter:function(e){m._canDrag(e.draggable.currentTarget)&&(t.ui.icon(e.draggable.hint.find(".k-drag-status"),{icon:"plus"}),h.css(f,0).appendTo(m.groupContainer))},dragleave:function(e){t.ui.icon(e.draggable.hint.find(".k-drag-status"),{icon:"cancel"}),h.remove()},drop:function(n){var i,r=n.draggable.currentTarget,a=r.attr(t.attr("field")),l=r.attr(t.attr("title")),d=r.attr("id"),u=m.indicator(a),f=m._dropCuePositions,g=f[f.length-1],v="after",_=s||!g?0:g.element.parent().position().left,b=o({},m.options.sort,r.data(c)),y=b.dir;(r.hasClass("k-chip")||m._canDrag(r))&&(g?(i=m._dropCuePosition(t.getOffset(h).left+_+parseInt(g.element.css("marginLeft"),10)*(s?-1:1)+parseInt(g.element.css("marginRight"),10)))&&m._canDrop(e(u),i.element,i.left)&&(i.before&&(v="before"),i.element[v](u||m.buildIndicator(a,l,y,d).wrapper),m._setIndicatorSortOptions(a,b),m._change()):(p(m._messageContainer),m._list.element.show(),m._list.add(m.buildIndicator(a,l,y,d).element),m._setIndicatorSortOptions(a,b),m._change()))}}).kendoDraggable({filter:"div.k-chip",hint:u,group:l.options.group,dragcancel:m._dragCancel.bind(m),dragstart:function(e){var n=e.currentTarget,r=parseInt(n.css("marginLeft"),10),o=n.position(),a=s?o.left-r:o.left+i(n);v(),h.css("left",a).appendTo(m.groupContainer),t.ui.icon(this.hint.find(".k-drag-status"),{icon:"plus"})},dragend:function(){m._dragEnd(this)},drag:m._drag.bind(m)}),l.bind(["dragend","dragcancel","dragstart","drag"],{dragend:function(){m._dragEnd(this)},dragcancel:m._dragCancel.bind(m),dragstart:function(e){m.options.allowDrag||m._canDrag(e.currentTarget)?v():e.preventDefault()},drag:m._drag.bind(m)}),m.dataSource=m.options.dataSource,m._messageContainer=m.groupContainer.find("."+d),m._messageContainer.length||(m._messageContainer=e("<div/>").addClass(d).appendTo(m.groupContainer)),m._createList(),m.dataSource&&m._refreshHandler?m.dataSource.unbind("change",m._refreshHandler):m._refreshHandler=m.refresh.bind(m),m.dataSource&&(m.dataSource.bind("change",m._refreshHandler),m.refresh())},refresh:function(){var t=this,n=t.dataSource.group()||[],i=r("field"),s=r("title");t.groupContainer&&(t._list&&(t._list.remove(t._list.items()),t._list.element.hide()),n.length&&p(t._messageContainer),a(n,(function(n,r){var a=r.field,l=r.dir,c=t.element.find(t.options.filter).filter((function(){return e(this).attr(i)===a})),d=t.buildIndicator(a,c.attr(s),l,c.attr("id"));t._list.add(d.element),t._list.element.show(),t._setIndicatorSortOptions(a,o({},t.options.sort,{dir:l,compare:r.compare}))}))),t._invalidateGroupContainer()},destroy:function(){var e=this;n.fn.destroy.call(e),e.groupContainer.off(".kendoGroupable"),e.groupContainer.data("kendoDropTarget")&&e.groupContainer.data("kendoDropTarget").destroy(),e.groupContainer.data("kendoDraggable")&&e.groupContainer.data("kendoDraggable").destroy(),e.options.draggable||e.draggable.destroy(),e.dataSource&&e._refreshHandler&&(e.dataSource.unbind("change",e._refreshHandler),e._refreshHandler=null),e._list&&e._list.destroy(),e.groupContainer=e.element=e.draggable=null},events:["change","removeGroup"],options:{name:"Groupable",filter:"th",draggableElements:"th",messages:{empty:"Drag a column header and drop it here to group by that column"},sort:{dir:l,compare:null},enableContextMenu:!1},indicator:function(n){var i=e(".k-chip",this.groupContainer);return e.grep(i,(function(i){return e(i).attr(t.attr("field"))===n}))[0]},removeHandler:function(e){this._removeIndicator(e.sender.wrapper)},clickHandler:function(t){var n=t.sender.wrapper.find(".k-chip-icon"),i=n.attr(r("dir"))===l?"desc":l;e(t.originalEvent.target).closest(".k-groupable-context-menu").length||(n.attr(r("dir"),i),this._change())},buildIndicator:function(n,i,r,o){var a,s,c,d=this;return r=r||(d.options.sort||{}).dir||l,s=(c=(a=e("<div/>").kendoChip({icon:"sort-"+("asc"==(r||"asc")?"asc-small":"desc-small"),iconClass:"k-chip-icon",label:`${t.htmlEncode(i||n)}`,removable:!0,size:d.options.size||"medium",remove:d.removeHandler.bind(d),click:d.clickHandler.bind(d),actions:d.options.enableContextMenu?[{icon:"more-vertical",iconClass:"k-groupable-context-menu"}]:null}).data("kendoChip")).wrapper).find(".k-chip-icon").first(),c.attr(`data-${t.ns}field`,n),c.attr(`data-${t.ns}title`,i||""),o&&c.attr(`data-${t.ns}id`,o),s.attr("title",`(sorted ${"asc"==r?"ascending":"descending"})`),s.attr(`data-${t.ns}dir`,r),a},_setIndicatorSortOptions:function(t,n){e(this.indicator(t)).data(c,n)},aggregates:function(){var n,i,r;return this.element.find(this.options.filter).map((function(){var o=e(this),a=o.attr(t.attr("aggregates")),s=o.attr(t.attr("field"));if(a&&""!==a)for(n=a.split(","),a=[],i=0,r=n.length;i<r;i++)a.push({field:s,aggregate:n[i]});return a})).toArray()},descriptors:function(){var n,i=this,r=e(".k-chip",i.groupContainer),o=i.aggregates();return e.map(r,(function(r){r=e(r),n=r.attr(t.attr("field"));var a=i.options.sort||{},s=r.data(c)||{},l=r.find(".k-chip-icon");return{field:n,dir:l.attr(t.attr("dir")),aggregates:o||[],colID:r.attr(t.attr("id")),compare:s.compare||a.compare}}))},_removeIndicator:function(e){var n=this;n.trigger("removeGroup",{field:e.attr(t.attr("field")),colID:e.attr(t.attr("id"))}),n._list.remove(e),e.off(),e.removeData(),n._invalidateGroupContainer(),n._change()},_change:function(){var e=this;if(e.dataSource){var t=e.descriptors();if(e.trigger("change",{groups:t}))return void e.refresh();e.dataSource.group(t)}},_dropCuePosition:function(t){var n=this._dropCuePositions;if(h.is(":visible")&&0!==n.length){t=Math.ceil(t);var r=n[n.length-1],o=r.left,a=r.right,l=parseInt(r.element.css("marginLeft"),10),c=parseInt(r.element.css("marginRight"),10),d=r.element.parent().position().left-parseInt(this.groupContainer.css("paddingLeft"),10);return t>=a&&!s||t<o&&s?t={left:r.element.position().left+(s?d-l:i(r.element)+c),element:r.element,before:!1}:(t=e.grep(n,(function(e){return e.left<=t&&t<=e.right||s&&t>e.right}))[0])&&(t={left:s?t.element.position().left+i(t.element)+c+d:t.element.position().left-l,element:t.element,before:!0}),t}},_drag:function(e){var t=this._dropCuePosition(e.x.location);t&&h.css({left:t.left,right:"auto"})},_canDrag:function(e){var n=e.attr(t.attr("field"));return"false"!=e.attr(t.attr("groupable"))&&n&&(e.hasClass("k-chip")||!this.indicator(n))},_canDrop:function(e,t,n){var i=e.next();return e[0]!==t[0]&&(!i[0]||t[0]!==i[0]||!s&&n>i.position().left||s&&n<i.position().left)},_dragEnd:function(n){var i=this,r=n.currentTarget.attr(t.attr("field")),o=i.indicator(r);n!==i.options.draggable&&!n.dropped&&o&&i._removeIndicator(e(o)),i._dragCancel()},_dragCancel:function(){h.remove(),this._dropCuePositions=[]},_intializePositions:function(){var n,r=e(".k-chip",this.groupContainer);this._dropCuePositions=e.map(r,(function(r){return r=e(r),n=t.getOffset(r).left,{left:parseInt(n,10),right:parseInt(n+i(r),10),element:r}}))},_invalidateGroupContainer:function(){var e=this.groupContainer,t=this._list;e&&t&&t.element.is(":empty")&&this._messageContainer.text(this.options.messages.empty)},_createList:function(){var t=this;t.groupContainer.find(".k-chip-list").remove(),t._list=e("<div/>").kendoChipList({selectable:"none",size:t.options.size||"medium"}).data("kendoChipList"),t._list.element.insertBefore(t._messageContainer)}});t.ui.plugin(f)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t._outerWidth,i=t._outerHeight,r=t.getOffset,o=t.ui.Widget,a="change",s=o.extend({init:function(e,t){var s=this;o.fn.init.call(s,e,t),e=s.element,t=s.options,s._initDraggable(),s.options.dropFilter||(s.options.dropFilter=s.draggable.options.filter),s.reorderDropCue=s.options.reorderDropCue,e.find(t.dropFilter).kendoDropTarget({group:s.draggable.options.group,dragenter:function(e){var o=s._externalDraggable(e);if(s._draggable||o){o&&s._handleExternalDraggable(o);var a,l=this.element,c=!!s._isPartOfSortable(s._draggable)&&(!s._dropTargetAllowed(l)||s._isLastDraggable());if(s.toggleHintClass(e.draggable.hint,c),!c){var d={top:(a=r(l)).top,left:a.left},u="horizontal"===t.orientation;!t.smartPosition||t.inSameContainer&&!t.inSameContainer({source:l,target:s._draggable,sourceIndex:s._index(l),targetIndex:s._index(s._draggable)})?s._dropTarget=l:s._index(l)>s._index(s._draggable)&&t.smartPosition&&(d[u?"left":"top"]+=u?n(l):i(l)),s.reorderDropCue.css({height:i(l),top:d.top,left:d.left,zIndex:19e3}),t.positionDropCue&&t.positionDropCue(s.reorderDropCue,l),s.reorderDropCue.appendTo(document.body)}}},dragleave:function(e){s._dropTarget=null},drop:function(){if(s._dropTarget=null,s._draggable){var e=this.element,t=s._draggable,n=s._index(e),i="horizontal"===s.options.orientation?r(s.reorderDropCue).left>r(e).left:r(s.reorderDropCue).top>r(e).top;n=i?n+1:n,s._dropTargetAllowed(e)&&!s._isLastDraggable()&&s._index(t)!==n&&s.trigger(a,{element:s._draggable,target:e,oldIndex:s._index(t),newIndex:s._index(e),position:i?"after":"before"}),s.reorderDropCue&&s.reorderDropCue.remove()}}}),s.draggable.bind(["dragcancel","dragend","dragstart","drag"],{dragcancel:s._dragcancel.bind(s),dragend:s._dragend.bind(s),dragstart:s._dragstart.bind(s),drag:s._drag.bind(s)})},options:{name:"Reorderable",filter:"*",orientation:"horizontal",deniedIcon:"cancel",allowIcon:"plus",reorderDropCue:e('<div class="k-reorder-cue"></div></div>'),smartPosition:!0},events:[a],toggleHintClass:function(n,i){var r=this.options;(n=e(n)).find(".k-drag-status").length>0&&t.ui.icon(n.find(".k-drag-status").eq(0),{icon:i?r.deniedIcon:r.allowIcon})},_initDraggable:function(){let e=this,n=e.options;e.draggable=n.draggable||new t.ui.Draggable(e.element,{group:t.guid()+"-reorderable",autoScroll:!0,filter:n.filter,hint:n.hint});let i=e.draggable._elementUnderCursor;e.draggable._elementUnderCursor=function(t){let n=e.reorderDropCue&&e.reorderDropCue.is(":visible");n&&e.reorderDropCue.hide();let r=i.call(e.draggable,t);return n&&e.reorderDropCue.show(),r}},_handleExternalDraggable:function(e){var t=this,n=t.options.dropFilter.trimStart();n&&">"==n[0]&&(n=n.substring(1)),t._dragcancelHandler=t._dragcancel.bind(t),t._dragendHandler=t._dragend.bind(t),t._dragstartHandler=t._dragstart.bind(t),t._dragHandler=t._drag.bind(t),t._draggable=e.currentTarget.closest(n),t._draggableInstance=e,t._elements=t.element.find(t.options.dropFilter),e.bind(["dragcancel","dragend","dragstart","drag"],{dragcancel:t._dragcancelHandler,dragend:t._dragendHandler,dragstart:t._dragstartHandler,drag:t._dragHandler})},_dragcancel:function(){var e=this;e._draggableInstance&&(e._dragcancelHandler||e._dragendHandler||e._dragstartHandler||e._dragHandler)&&e._draggableInstance.unbind({dragcancel:e._dragcancelHandler,dragend:e._dragendHandler,dragstart:e._dragstartHandler,drag:e._dragHandler}),e.reorderDropCue&&e.reorderDropCue.remove(),e._draggable=null,e._elements=null},_dragend:function(){var e=this;e._draggableInstance&&(e._dragcancelHandler||e._dragendHandler||e._dragstartHandler||e._dragHandler)&&e._draggableInstance.unbind({dragcancel:e._dragcancelHandler,dragend:e._dragendHandler,dragstart:e._dragstartHandler,drag:e._dragHandler}),e.reorderDropCue&&e.reorderDropCue.remove(),e._draggable=null,e._elements=null},_dragstart:function(t){var n=this,i=e(t.currentTarget),r=n.options.dropFilter.trimStart();r&&">"==r[0]&&(r=r.substring(1)),n._draggable=i.is(r)?i:i.closest(r),n._elements=n.element.find(n.options.dropFilter)},_drag:function(t){var o,a,s,l,c=this,d={},u=c.options.dropFilter.trimStart();if(u&&">"==u[0]&&(u=u.substring(1)),l=e(t.currentTarget).closest(u),!(!c._dropTarget||c.options.smartPosition&&t.sender.hint.find(".k-drag-status").is(".k-i-cancel,.k-svg-i-cancel"))){if(a=(o=c._index(c._dropTarget))>(a=c._index(l))?a+1:a,"horizontal"===c.options.orientation){var h=r(c._dropTarget).left,p=n(c._dropTarget);t.pageX>h+p/2?(d.left=h+p,o+=1):d.left=h}else{var f=r(c._dropTarget).top,m=i(c._dropTarget);t.pageY>f+m/2?(d.top=f+m,o+=1):d.top=f}c.reorderDropCue.css(d),c.options.positionDropCue&&c.options.positionDropCue(c.reorderDropCue,c._dropTarget),c._isPartOfSortable(l)&&(s=a===o||c.options.dragOverContainers&&!c.options.dragOverContainers(a,o)||t.clickMoveClick&&t.currentTarget.hasClass("k-drag-cell")&&0===e(t.elementUnderCursor).closest(".k-drag-cell").length,c.toggleHintClass(t.sender.hint,s))}},_isPartOfSortable:function(e){return this._elements.index(e)>=0},_externalDraggable:function(e){var t=this.options;return!this._draggable&&t.externalDraggable?t.externalDraggable(e):null},_isLastDraggable:function(){var e,t=this.options.inSameContainer,n=this._draggable[0],i=this._elements.get(),r=!1;if(!t)return!1;for(;!r&&i.length>0;)r=n!==(e=i.pop())&&t({source:n,target:e,sourceIndex:this._index(n),targetIndex:this._index(e)});return!r},_dropTargetAllowed:function(e){var t=this.options.inSameContainer,n=this.options.dragOverContainers,i=this._draggable;return i[0]!==e[0]&&(!t||!n||(!!t({source:i,target:e,sourceIndex:this._index(i),targetIndex:this._index(e)})||n(this._index(i),this._index(e))))},_index:function(e){return this._elements.index(e)},destroy:function(){var t=this;o.fn.destroy.call(t),t.element.find(t.options.dropFilter).each((function(){var t=e(this);t.data("kendoDropTarget")&&t.data("kendoDropTarget").destroy()})),t.draggable&&(t.draggable.destroy(),t.draggable.element=t.draggable=null),t.reorderDropCue.remove(),t.elements=t.reorderDropCue=t._elements=t._draggable=null}});t.ui.plugin(s)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=i.Widget,o=n.isFunction,a=e.extend,s="horizontal",l="vertical",c="start",d="resize",u="resizeend",h=r.extend({init:function(e,t){var n=this;r.fn.init.call(n,e,t),n.orientation=n.options.orientation.toLowerCase()!=l?s:l,n._positionMouse=n.orientation==s?"x":"y",n._position=n.orientation==s?"left":"top",n._sizingDom=n.orientation==s?"outerWidth":"outerHeight",n.draggable=new i.Draggable(t.draggableElement||e,{distance:1,filter:t.handle,drag:n._resize.bind(n),dragcancel:n._cancel.bind(n),dragstart:n._start.bind(n),dragend:n._dragend.bind(n),clickMoveClick:t.clickMoveClick}),n.userEvents=n.draggable.userEvents},events:[d,u,c],options:{name:"Resizable",orientation:s,clickMoveClick:!1},resize:function(){},_max:function(e){var n=this,i=n.hint?n.hint[n._sizingDom]():0,r=n.options.max;return o(r)?r(e):r!==t?n._initialElementPosition+r-i:r},_min:function(e){var n=this.options.min;return o(n)?n(e):n!==t?this._initialElementPosition+n:n},_start:function(t){var n=this,i=n.options.hint,r=e(t.currentTarget);n._initialElementPosition=r.position()[n._position],n._initialMousePosition=t[n._positionMouse].startLocation,i&&(n.hint=o(i)?e(i(r)):i,n.hint.css({position:"absolute"}).css(n._position,n._initialElementPosition).appendTo(n.element)),n.trigger(c,t),n._maxPosition=n._max(t),n._minPosition=n._min(t),e(document.body).css("cursor",r.css("cursor"))},_resize:function(e){var n,i=this,r=i._maxPosition,o=i._minPosition,s=i._initialElementPosition+(e[i._positionMouse].location-i._initialMousePosition);n=o!==t?Math.max(o,s):s,i.position=n=r!==t?Math.min(r,n):n,i.hint&&i.hint.toggleClass(i.options.invalidClass||"",n==r||n==o).css(i._position,n),i.resizing=!0,i.trigger(d,a(e,{position:n}))},_dragend:function(e){this._stop(),this.trigger(u,a(e,{position:this.position}))},_stop:function(){var t=this;t.hint&&t.hint.remove(),t.resizing=!1,e(document.body).css("cursor","")},_cancel:function(e){var n=this;n.hint&&(n.position=t,n.hint.css(n._position,n._initialElementPosition),n._stop())},destroy:function(){var e=this;r.fn.destroy.call(e),e.draggable&&e.draggable.destroy()},press:function(e){if(e){var t=e.position(),n=this;n.userEvents.press(t.left,t.top,e[0]),n.targetPosition=t,n.target=e}},move:function(e){var n=this,i=n._position,r=n.targetPosition,o=n.position;o===t&&(o=r[i]),r[i]=o+e,n.userEvents.move(r.left,r.top)},end:function(){this.userEvents.end(),this.target=this.position=t}});n.ui.plugin(h)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=t._outerWidth,r=t._outerHeight,o="start",a="beforeMove",s="move",l="end",c="change",d="cancel",u="sort",h="remove",p="receive";function f(e){return e.clone()}function m(e){return e.clone().removeAttr("id").css("visibility","hidden")}var g=n.extend({init:function(e,t){var i=this;n.fn.init.call(i,e,t),i.options.placeholder||(i.options.placeholder=m),i.options.hint||(i.options.hint=f),i.draggable=i._createDraggable()},events:[o,a,s,l,c,d],options:{name:"Sortable",hint:null,placeholder:null,filter:">*",holdToDrag:!1,disabled:null,container:null,connectWith:null,handler:null,cursorOffset:null,axis:null,ignore:null,autoScroll:!1,cursor:"auto",moveOnDragEnter:!1},destroy:function(){this.draggable.destroy(),n.fn.destroy.call(this)},_createDraggable:function(){var n=this,i=n.element,r=n.options;return new t.ui.Draggable(i,{filter:r.filter,hint:t.isFunction(r.hint)?r.hint:e(r.hint),holdToDrag:r.holdToDrag,container:r.container?e(r.container):null,cursorOffset:r.cursorOffset,axis:r.axis,ignore:r.ignore,autoScroll:r.autoScroll,dragstart:n._dragstart.bind(n),dragcancel:n._dragcancel.bind(n),drag:n._drag.bind(n),dragend:n._dragend.bind(n)})},_dragstart:function(n){var i=this.draggedElement=n.currentTarget,r=this.options.disabled,a=this.options.handler,s=this.options.placeholder,l=this.placeholder=t.isFunction(s)?e(s.call(this,i)):e(s);r&&i.is(r)||a&&!e(n.initialTarget).is(a)||this.trigger(o,{item:i,draggableEvent:n})?n.preventDefault():(i.css("display","none"),i.before(l),this._setCursor())},_dragcancel:function(){this._cancel(),this.trigger(d,{item:this.draggedElement}),this._resetCursor()},_drag:function(t){var n,i,r,o,a,s=this.draggedElement,l=this._findTarget(t),c={left:t.x.location,top:t.y.location},d={x:t.x.delta,y:t.y.delta},u=this.options.axis,h=this.options.moveOnDragEnter,p={item:s,list:this,draggableEvent:t};if("x"!==u&&"y"!==u){if(l){if(n=this._getElementCenter(l.element),i={left:Math.round(c.left-n.left),top:Math.round(c.top-n.top)},e.extend(p,{target:l.element}),l.appendToBottom)return void this._movePlaceholder(l,null,p);if(l.appendAfterHidden&&this._movePlaceholder(l,"next",p),this._isFloating(l.element)?d.x<0&&h||!h&&i.left<0?r="prev":(d.x>0&&h||!h&&i.left>0)&&(r="next"):d.y<0&&h||!h&&i.top<0?r="prev":(d.y>0&&h||!h&&i.top>0)&&(r="next"),r){for(o=(a="prev"===r?jQuery.fn.prev:jQuery.fn.next).call(l.element);o.length&&!o.is(":visible");)o=a.call(o);o[0]!=this.placeholder[0]&&this._movePlaceholder(l,r,p)}}}else this._movementByAxis(u,c,d[u],p)},_dragend:function(t){var n,i,r,o,a=this.placeholder,s=this.draggedElement,d=this.indexOf(s),f=this.indexOf(a),m=this.options.connectWith;this._resetCursor(),r={action:u,item:s,oldIndex:d,newIndex:f,draggableEvent:t},f>=0?i=this.trigger(l,r):(n=a.parents(m).getKendoSortable(),r.action=h,o=e.extend({},r,{action:p,oldIndex:-1,newIndex:n.indexOf(a)}),i=!(!this.trigger(l,r)&&!n.trigger(l,o))),i||f===d?this._cancel():(a.replaceWith(s),s.show(),this.draggable.dropped=!0,r={action:-1!=this.indexOf(s)?u:h,item:s,oldIndex:d,newIndex:this.indexOf(s),draggableEvent:t},this.trigger(c,r),n&&(o=e.extend({},r,{action:p,oldIndex:-1,newIndex:n.indexOf(s)}),n.trigger(c,o)))},_findTarget:function(t){var n,i,r=this._findElementUnderCursor(t),o=this.options.connectWith;return e.contains(this.element[0],r)?(i=(n=this.items()).filter(r)[0]||n.has(r)[0])?{element:e(i),sortable:this}:null:this.element[0]==r&&this._isEmpty()?{element:this.element,sortable:this,appendToBottom:!0}:this.element[0]==r&&this._isLastHidden()?{element:i=this.items().eq(0),sortable:this,appendAfterHidden:!0}:o?this._searchConnectedTargets(r,t):void 0},_findElementUnderCursor:function(n){var i=t.elementUnderCursor(n),r=n.sender;return function(t,n){try{return e.contains(t,n)||t==n}catch(e){return!1}}(r.hint[0],i)&&(r.hint.hide(),(i=t.elementUnderCursor(n))||(i=t.elementUnderCursor(n)),r.hint.show()),i},_searchConnectedTargets:function(t,n){for(var i,r,o,a=e(this.options.connectWith),s=0;s<a.length;s++)if(i=a.eq(s).getKendoSortable(),e.contains(a[s],t)){if(i)return(o=(r=i.items()).filter(t)[0]||r.has(t)[0])?(i.placeholder=this.placeholder,{element:e(o),sortable:i}):null}else if(a[s]==t){if(i&&i._isEmpty())return{element:a.eq(s),sortable:i,appendToBottom:!0};if(this._isCursorAfterLast(i,n))return{element:o=i.items().last(),sortable:i}}},_isCursorAfterLast:function(e,n){var o,a=e.items().last(),s=n.x.location,l=n.y.location;return(o=t.getOffset(a)).top+=r(a),o.left+=i(a),(this._isFloating(a)?o.left-s:o.top-l)<0},_movementByAxis:function(t,n,i,r){var o,a="x"===t?n.left:n.top,s=i<0?this.placeholder.prev():this.placeholder.next(),l=this.items();s.length&&!s.is(":visible")&&(s=i<0?s.prev():s.next()),l.filter(s).length&&(e.extend(r,{target:s}),(o=this._getElementCenter(s))&&(o="x"===t?o.left:o.top),s.length&&i<0&&a-o<0?this._movePlaceholder({element:s,sortable:this},"prev",r):s.length&&i>0&&a-o>0&&this._movePlaceholder({element:s,sortable:this},"next",r))},_movePlaceholder:function(e,t,n){var i=this.placeholder;e.sortable.trigger(a,n)||(t?"prev"===t?e.element.before(i):"next"===t&&e.element.after(i):e.element.append(i),e.sortable.trigger(s,n))},_setCursor:function(){var t,n=this.options.cursor;n&&"auto"!==n&&(t=e(document.body),this._originalCursorType=t.css("cursor"),t.css({cursor:n}),this._cursorStylesheet||(this._cursorStylesheet=e("<style>* { cursor: "+n+" !important; }</style>")),this._cursorStylesheet.appendTo(t))},_resetCursor:function(){this._originalCursorType&&(e(document.body).css("cursor",this._originalCursorType),this._originalCursorType=null,this._cursorStylesheet.remove())},_getElementCenter:function(e){var n=e.length?t.getOffset(e):null;return n&&(n.top+=r(e)/2,n.left+=i(e)/2),n},_isFloating:function(e){var t=/left|right/.test(e.css("float")),n=/inline|table-cell/.test(e.css("display")),i=/flex/.test(e.parent().css("display"))&&(/row|row-reverse/.test(e.parent().css("flex-direction"))||!e.parent().css("flex-direction"));return t||n||i},_cancel:function(){this.draggedElement&&(this.draggedElement.show(),this.placeholder.remove(),this.draggable.dropped=!0)},_items:function(){var e=this.options.filter;return e?this.element.find(e):this.element.children()},indexOf:function(e){var t=this._items(),n=this.placeholder,i=this.draggedElement;return n&&e[0]==n[0]?t.not(i).index(e):t.not(n).index(e)},items:function(){var e=this.placeholder,t=this._items();return e&&(t=t.not(e)),t},_isEmpty:function(){return!this.items().length},_isLastHidden:function(){return 1===this.items().length&&this.items().is(":hidden")}});t.ui.plugin(g)}(window.kendo.jQuery);kendo;!function(e,t){let n=window.kendo,i=n.ui.Widget,r=n.support,o=Math.abs,a="aria-selected",s="k-selected",l="k-selecting",c="change",d="changing",u="unselect",h="k-unselecting",p="k-hover",f="k-range-mid",m="k-range-split-end",g="k-range-split-start",v="k-range-start",_="k-range-end",b="start",y="end",w="span.k-icon.k-i-caret-alt-down,span.k-icon.k-i-caret-alt-up,.k-icon.k-i-caret-alt-down,.k-icon.k-i-caret-alt-right,.k-icon.k-i-caret-alt-left",k=w.replaceAll("k-i","k-svg-i"),x=k.split(",").map((e=>e+" *")).join(","),C=`input,a,textarea,.k-multiselect-wrap,select,button,${w},${k},${x},.k-button>span,.k-button>span *,.k-button>img,label.k-checkbox-label.k-no-text,span.k-numeric-wrap,.k-focusable`,S=n.support.browser.msie,T=!1,D=e.extend;!function(e){e('<div class="parent"><span></span></div>').on("click",">*",(function(){T=!0})).find("span").trigger("click").end().off()}(e);const A=i.extend({init:function(t,r){let o,a,s,l=this;i.fn.init.call(l,t,r),s=l.selectableClass=l.options.selectableClass||"k-selectable",l._marquee=e("<div class='k-marquee'><div class='k-marquee-color'></div></div>"),l._lastActive=null,l.element.addClass(s),l.relatedTarget=l.options.relatedTarget,o=l.options.multiple,a=l.options.dragToSelect,l.userEvents=new n.UserEvents(l.element,{global:!0,allowSelection:!0,filter:(T?"":"."+s+" ")+l.options.filter,tap:l._tap.bind(l),touchAction:o?"none":"pan-x pan-y"}),o&&(a&&l.userEvents.bind("hold",l._hold.bind(l)).bind("start",l._start.bind(l)).bind("move",l._move.bind(l)).bind("end",l._end.bind(l)),l.userEvents.bind("select",l._select.bind(l)))},events:[c,d,u],options:{name:"Selectable",filter:">*",inputSelectors:C,multiple:!1,holdToDrag:!1,dragToSelect:!0,relatedTarget:e.noop,ignoreOverlapped:!1,addIdToRanges:!1,toggleable:!1,selectableClass:""},_isElement:function(e){var t,n=this.element,i=n.length,r=!1;for(e=e[0],t=0;t<i;t++)if(n[t]===e){r=!0;break}return r},_tap:function(t){let n,i=e(t.target),r=this,o=r.options,a=t.event.ctrlKey||t.event.metaKey,l=r.options.multiple,u=l&&t.event.shiftKey,h=r.options.selectedClass||s,p=t.event.which,f=t.event.button;!r._isElement(i.closest("."+r.selectableClass))||p&&3==p||f&&2==f||this._allowSelection(t.event.target)&&(r.trigger(d,{target:i,originalEvent:t.event})||(n=i.hasClass(h),i=i.add(r.relatedTarget(i)),l?u?(r._lastRange&&E(r._lastRange,i)||(r.selectRange(r._firstSelectee(),i,t),r._notify(c,t)),r._lastRange=i):(r._lastRange=null,n&&(a||o.toggleable)?(r._unselect(i),r._notify(c,t)):a||o.toggleable?(r.value(i,t),r._notify(c,t)):(!n||r.value().length>1)&&(r.clear(),r.value(i,t),r._notify(c,t)),r._lastActive=r._downTarget=i):n&&a?(r._unselect(i),r._notify(c,t)):n||(r.clear(),r.value(i,t),r._notify(c,t))))},_hold:function(e){this.options.holdToDrag&&this._tap(e),this._activated=!0},_isActivated:function(){return!this.options.holdToDrag||this._activated},_start:function(t){let n,i=this,r=e(t.target),o=i.options.selectedClass||s,a=r.hasClass(o),l=t.event.ctrlKey||t.event.metaKey;i._isActivated()&&this._allowSelection(t.event.target)&&(i.trigger(d,{target:r,originalEvent:t.event})?i.userEvents.cancel():(i._downTarget=r,i._isElement(r.closest("."+i.selectableClass))?(i.options.useAllItems?i._items=i.element.find(i.options.filter):(n=r.closest(i.element),i._items=n.find(i.options.filter)),t.sender.capture(),i._marquee.appendTo(document.body).css({left:t.x.client+1,top:t.y.client+1,width:0,height:0}),l||i.clear(),r=r.add(i.relatedTarget(r)),a&&(i._selectElement(r,!0),l&&r.addClass(h))):i.userEvents.cancel()))},_move:function(e){var t=this,n={left:e.x.startLocation>e.x.location?e.x.location:e.x.startLocation,top:e.y.startLocation>e.y.location?e.y.location:e.y.startLocation,width:o(e.x.initialDelta),height:o(e.y.initialDelta)};t._isActivated()&&(t._marquee.css(n),t._invalidateSelectables(n,e.event.ctrlKey||e.event.metaKey),e.preventDefault())},_end:function(t){var i=this,r=n.attr("range-selected"),o=n.guid();if(i._isActivated()){i._activated=!1,i._marquee.remove(),i._unselect(i.element.find(i.options.filter+"."+h)).removeClass(h);var a=i.element.find(i.options.filter+"."+l);if(a=a.add(i.relatedTarget(a)),i.options.addIdToRanges)for(var s=0;s<i._currentlyActive.length;s++)e(i._currentlyActive[s]).attr(r,o);i._lastRange&&E(i._lastRange,a)||(i.value(a,t),i._notify(c,t)),i._lastRange=a,i._lastActive=i._downTarget,i._items=null}},_invalidateSelectables:function(e,t){var n,i,r,o,a=this._downTarget[0],c=this._items,d=this.options.selectedClass||s;for(this._currentlyActive=[],n=0,i=c.length;n<i;n++)r=(o=c.eq(n)).add(this.relatedTarget(o)),I(o,e)?(o.hasClass(d)?t&&a!==o[0]&&r.removeClass(d).addClass(h):o.hasClass(l)||o.hasClass(h)||this._collidesWithActiveElement(r,e)||r.addClass(l),this._currentlyActive.push(r[0])):o.hasClass(l)?r.removeClass(l):t&&o.hasClass(h)&&r.removeClass(h).addClass(d)},_collidesWithActiveElement:function(e,t){if(!this.options.ignoreOverlapped)return!1;var i,r=this._currentlyActive,o=e[0].getBoundingClientRect(),a=!1,s=n.support.isRtl(e)?"right":"left",l={};t.right=t.left+t.width,t.bottom=t.top+t.height;for(var c=0;c<r.length;c++)if(z(o,i=r[c].getBoundingClientRect())){if(l[s]="left"===s?i.right:i.left,(o=D({},o,l)).left>o.right)return!0;a=!z(o,t)}return a},value:function(e){var t=this,n=t._selectElement.bind(t);if(!e)return t.element.find(t.options.filter+"."+(t.options.selectedClass||s));e.each((function(){n(this)}))},selectedRanges:function(){var t=n.attr("range-selected"),i={};return this.element.find("["+t+"]").each((function(n,r){var o=e(r).attr(t),a=i[o];a||(a=i[o]=[]),a.push(e(r))})),i},selectedSingleItems:function(){var t=this,i=n.attr("range-selected");return t.element.find(t.options.filter+"."+(t.options.selectedClass||s)+":not(["+i+"])").toArray().map((function(t){return e(t)}))},_firstSelectee:function(){var e,t=this;return null!==t._lastActive?t._lastActive:(e=t.value()).length>0?e[0]:t.element.find(t.options.filter)[0]},_selectElement:function(t,n){var i=e(t),r=this.options.selectedClass||s,o=!n&&this._notify("select",{element:t});i.removeClass(l),o||(i.addClass(r),this.options.aria&&i.attr(a,!0))},_notify:function(e,t){return t=t||{},this.trigger(e,t)},_unselect:function(e){if(!this.trigger(u,{element:e})){var t=n.attr("range-selected");return e.removeClass(this.options.selectedClass||s).removeAttr(t),this.options.aria&&e.attr(a,!1),e}},_select:function(t){this._allowSelection(t.event.target)&&(!S||S&&!e(n._activeElement()).is(this.options.inputSelectors))&&this._allowPreventDefault(t.event.target)&&t.preventDefault()},_allowPreventDefault:function(t){return!e(t).is(".k-table-td")||!this.options.allowPaste},_allowSelection:function(t){return!e(t).is(this.options.inputSelectors)||(this.userEvents.cancel(),this._downTarget=null,!1)},resetTouchEvents:function(){this.userEvents.cancel()},clear:function(){var e=this.element.find(this.options.filter+"."+(this.options.selectedClass||s));this._unselect(e)},selectRange:function(t,n){var i,r,o,a=this;for(a.clear(),a.element.length>1&&(o=a.options.continuousItems()),o&&o.length||(o=a.element.find(a.options.filter)),(t=e.inArray(e(t)[0],o))>(n=e.inArray(e(n)[0],o))&&(r=t,t=n,n=r),a.options.useAllItems||(n+=a.element.length-1),i=t;i<=n;i++)a._selectElement(o[i],!0)},destroy:function(){var e=this;i.fn.destroy.call(e),e.element.off(".kendoSelectable"),e.userEvents.destroy(),e._marquee=e._lastActive=e.element=e.userEvents=null}}),M=i.extend({init:function(e,t){let o,a,s=this;i.fn.init.call(s,e,t),s.widget=t.widget,o=t.ns,a=t.filter,s.userEvents=new n.UserEvents(s.element,{global:!0,allowSelection:!0,filter:s.options.filter,tap:s._tap.bind(s),touchAction:"none"}),r.touch?e.on("touchstart"+o,a,s._mouseEnter.bind(s)).on("touchend"+o+" touchmove"+o,a,s._mouseLeave.bind(s)):e.on("mouseenter"+o,a,s._mouseEnter.bind(s)).on("mouseleave"+o,a,s._mouseLeave.bind(s))},events:[c],options:{name:"RangeSelectable",filter:">*",inputSelectors:C,resetOnStart:!1,multiple:!1,dragToSelect:!0,cellSelector:"*",ns:"",reverse:!1,relatedTarget:e.noop},destroy:function(){let e=this;i.fn.destroy.call(e),e.userEvents.destroy(),e.widget=null,e._lastActive=e.element=e.userEvents=e._start=e._end=null},_allowSelection:function(t){return!e(t).is(this.options.inputSelectors)||(this.userEvents.cancel(),!1)},_mouseEnter:function(t){let n,i=this,r=e(t.currentTarget);r.addClass(p),n=i.widget.selectRange(),i.options.resetOnStart&&n.end||(n.target===b&&i._end&&i.range(r,i._end,!0,i.options.reverse),n.target===y&&i.range(i._start,r,!0,i.options.reverse))},_mouseLeave:function(t){e(t.currentTarget).removeClass(p)},start:function(e,n){if(e===t||null===e)return this._start;e.addClass(s+" "+v).attr(a,!0),n||(this._start=e)},end:function(e,n){if(e===t||null===e)return this._start;e.addClass(s+" "+_).attr(a,!0),n||(this._end=e)},mid:function(t){let n=this.element.find("table"),i=this.options;t.addClass(f).attr(a,!0),n.each((function(){let t=e(this),n=t.find(i.cellSelectorValid).last(),r=t.find(i.cellSelectorValid).first();n.hasClass(f)&&n.addClass(m),r.hasClass(f)&&r.addClass(g)}))},clear:function(e){let t=this.options;this.element.find(t.cellSelector).removeClass(f+" "+m+" "+g),this.clearStartEnd(),e&&(this._start=this._end=null)},clearStartEnd:function(){let e=this.options;this.element.find(e.cellSelector).removeClass(v+" "+s+" "+_).removeAttr(a)},selectFrom:function(t){let n,i,r=this,o=this.options;n=r.element.find(o.cellSelector),i=e.inArray(e(t)[0],n),r.clear(),r.start(t),n=n.filter((function(e){return e>i})),r.mid(n)},selectTo:function(t){let n,i,r=this,o=this.options;n=r.element.find(o.cellSelector),i=e.inArray(e(t)[0],n),r.clear(),n=n.filter((function(e){return e<i})),r.mid(n),r.end(e(t))},range:function(n,i,r,o){let a,s,l,c=this,d=this.options;if(n===t)return{start:c._start,end:c._end};c._clearFlags(),a=c.element.find(d.cellSelector),s=e.inArray(e(n)[0],a),l=e.inArray(e(i)[0],a),(!n||n&&!n.length)&&(c._useStart=!0),c.clear(),n&&c.start(e(n),r),a=a.filter((function(e){if(!(l<0||!n&&s<0))return e>s&&e<l||d.reverse&&e<s&&e>l})),c.mid(a),i?c.end(e(i),r):c._useEnd=!0,s>l&&o&&(c.clearStartEnd(),c.start(e(i),!0),c.end(e(n),!0))},change:function(){this.trigger(c)},_clearFlags:function(){this._useStart=this._useEnd=!1},_tap:function(t){let i=e(t.target),r=this,o=r.widget.selectRange()||{},a=o.start,s=o.end,l=n.calendar.toDateObject(e(i).find("span")),d=r.options,u=d.resetOnStart;if(r._lastActive=i,!a&&!s)return r.clear(!0),o.target===b&&r.start(i),o.target===y&&r.end(i),r._clearFlags(),void r.trigger(c);if(!a&&s)return o.target===y?r.end(i):+l>+o.end&&!d.reverse?(r.clear(!0),r.start(i)):r.range(i,r._end,!1,!0),r.trigger(c),void r._clearFlags();if(a&&!s)return o.target===y&&!d.reverse&&+a>+l?(r.clear(!0),u?r.start(i):r.end(i)):o.target===b?r.start(i):r.range(r._start,i,!1,!0),r.trigger(c),void r._clearFlags();if(a&&s){if(!d.reverse)return+a>+l&&o.target===y?(r.clear(!0),u?(r.start(i),r.end(null),o.target=b):(r.start(null),r.end(i)),void r.trigger(c)):+a<+l&&o.target===b?(+l>+o.end?(r.clear(!0),r.start(i),r.end(null)):r.range(i,r._end),void r.trigger(c)):(o.target===b&&r.range(i,r._end),o.target===y&&r.range(r._start,i),void r.trigger(c));u?o.target===b?r.range(i,r._end,!1,!0):r.range(r._start,i,!1,!0):o.target===b?r.start(i):r.end(i),r.trigger(c)}}});function E(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}function I(e,t){if(!e.is(":visible"))return!1;var i=n.getOffset(e),r=t.left+t.width,o=t.top+t.height;return i.right=i.left+n._outerWidth(e),i.bottom=i.top+n._outerHeight(e),!(i.left>r||i.right<t.left||i.top>o||i.bottom<t.top)}function z(e,t){return!(e.right<=t.left||e.left>=t.right||e.bottom<=t.top||e.top>=t.bottom)}A.parseOptions=function(e){var t=e.mode||e,n="string"==typeof t&&t.toLowerCase();return{multiple:n&&n.indexOf("multiple")>-1,cell:n&&n.indexOf("cell")>-1,range:n&&n.indexOf("range")>-1,single:n&&n.indexOf("single")>-1}},n.ui.plugin(A),n.ui.plugin(M)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.html.HTMLBase,i="k-button-icon",r=n.extend({init:function(e,t){var i=this;n.fn.init.call(i,e,t),i.wrapper=i.element.addClass("k-button"),!i.element.attr("type")&&i.options.type&&i.element.attr("type",i.options.type),i._addClasses(),i.iconElement(),i._textElement()},options:{name:"HTMLButton",type:"button",icon:"",iconClass:"",spriteCssClass:"",imageUrl:"",size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base",stylingOptions:["size","rounded","fillMode","themeColor"]},iconElement:function(){var n,r,o,a=this,s=a.element,l=a.options,c=l.icon,d=l.iconClass,u=l.spriteCssClass,h=l.imageUrl;(u||h||c||d)&&(o=!0,s.contents().filter((function(){return!(e(this).hasClass("k-sprite")||e(this).hasClass("k-icon")||e(this).hasClass("k-svg-icon")||e(this).hasClass("k-image"))})).each((function(e,n){(1==n.nodeType||3==n.nodeType&&t.trim(n.nodeValue).length>0)&&(o=!1)}))),o&&a.element.addClass("k-icon-button"),h?((r=s.children("img.k-image").first())[0]||(r=e('<img alt="icon" class="k-image" />').prependTo(s)),r.attr("src",h),r.addClass(i)):c||d?((n=s.children("span.k-icon, span.k-svg-icon").first())[0]?t.ui.icon(n,{icon:c,iconClass:d}):n=e(t.ui.icon({icon:c,iconClass:d})).prependTo(s),n.addClass(i)):u&&((n=s.children("span.k-sprite").first())[0]||(n=e('<span class="k-sprite"></span>').prependTo(s)),n.addClass(u+" "+i))},_textElement:function(){this.element.contents().filter((function(){return!(e(this).hasClass(i)||e(this).hasClass("k-sprite")||e(this).hasClass("k-icon")||e(this).hasClass("k-image"))})).each((function(e,n){if(1==n.nodeType||3==n.nodeType&&t.trim(n.nodeValue).length>0){if(3===n.nodeType){var i=document.createElement("span");n.parentNode.insertBefore(i,n),i.appendChild(n),n=i}n.classList.add("k-button-text")}}))}});e.extend(t.html,{renderButton:function(t,n){return(undefined===arguments[0]||e.isPlainObject(arguments[0]))&&(n=t,t=e("<button></button>")),new r(t,n).html()},HTMLButton:r}),t.cssProperties.registerPrefix("HTMLButton","k-button-"),t.cssProperties.registerValues("HTMLButton",[{prop:"fillMode",values:t.cssProperties.fillModeValues.concat(["link","clear"])},{prop:"rounded",values:t.cssProperties.roundedValues.concat([["full","full"]])}])}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=e.extend,r=".kendoChat",o=t.keys,a=n.extend({init:function(e,t){n.fn.init.call(this,e,t),this._wrapper(),this._attachEvents(),this._typing=!1},events:["focusToolbar","sendMessage","toggleToolbar","typingEnd","typingStart"],options:{messages:{placeholder:"Type a message...",toggleButton:"Toggle toolbar",sendButton:"Send message"}},destroy:function(){n.fn.destroy.call(this),this.input&&(this.input.off(r),this.input.remove(),this.input=null),this.element.off(r),this.element.empty()},_wrapper:function(){var n=a.styles,i=this.options,r=i.messages,o="inputId_"+t.guid();this.inputWrapper=this.element.addClass(n.inputWrapper).appendTo(this.element),this.input=e("<input type='text'>").addClass(n.input).attr("id",o).attr("aria-label",r.placeholder).attr("placeholder",r.placeholder).appendTo(this.inputWrapper),this.separator=e("<span></span>").addClass(n.separator).appendTo(this.inputWrapper),this.inputSuffix=e("<span></span>").addClass(n.inputSuffix).appendTo(this.inputWrapper),i.toolbar&&i.toolbar.toggleable&&i.toolbar.buttons&&i.toolbar.buttons.length&&e(t.html.renderButton(`<button class="${n.buttonToggle}" title="${r.toggleButton}" aria-label="${r.toggleButton}" aria-controls="${i.toolbarId}"></button>`,{icon:n.buttonToggleIcon,fillMode:"flat",size:"medium"})).appendTo(this.inputSuffix),e(t.html.renderButton(`<button class="${n.buttonSend}" title="${r.sendButton}" aria-label="${r.sendButton}"></button>`,{icon:n.buttonSendIcon,fillMode:"flat",size:"medium"})).appendTo(this.inputSuffix)},_attachEvents:function(){var e=a.styles;this.input.on("keydown"+r,this._keydown.bind(this)).on("input"+r,this._input.bind(this)).on("focusout"+r,this._inputFocusout.bind(this)),this.element.on("click"+r,"."+e.buttonSend,this._buttonClick.bind(this)),this.element.on("click"+r,"."+e.buttonToggle,this._toggleToolbar.bind(this))},_input:function(){var e=this.input.val().length>0;this._triggerTyping(e)},_keydown:function(e){switch(e.keyCode){case o.ENTER:e.preventDefault(),this._sendMessage();break;case o.F10:e.preventDefault(),this.trigger("focusToolbar")}},_buttonClick:function(e){e.preventDefault(),this._sendMessage()},_sendMessage:function(){var e=this.input.val();if(e.length){this._triggerTyping(!1);var t={text:e};this.trigger("sendMessage",t),this.input.val("")}},_inputFocusout:function(){this._triggerTyping(!1)},_triggerTyping:function(e){e?this._typing||(this.trigger("typingStart",{}),this._typing=!0):this._typing&&(this.trigger("typingEnd",{}),this._typing=!1)},_toggleToolbar:function(e){this.trigger("toggleToolbar",{originalEvent:e})}});i(!0,a,{styles:{input:"k-input-inner",inputWrapper:"k-textbox k-input k-input-md k-input-solid k-rounded-md",button:"k-button",buttonFlat:"k-button-lg k-button-flat k-button-flat-base",iconButton:"k-icon-button",buttonIcon:"k-button-icon",buttonSend:"k-chat-send",buttonSendIcon:"paper-plane",buttonToggle:"k-button-toggle",buttonToggleIcon:"more-horizontal",hidden:"k-hidden",inputSuffix:"k-input-suffix k-input-suffix-horizontal",separator:"k-input-separator k-input-separator-vertical"}}),i(t,{chat:{ChatMessageBox:a}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.ui.Widget,i=e.extend,r=".kendoChat",o="kButtonName",a="chatToolbarScrollLeft",s="chatToolbarScrollRight",l=":visible",c="tabindex",d={effects:"expand:vertical",duration:200},u={expand:{show:!0},collapse:{hide:!0}},h=n.extend({init:function(e,t){var o=(t=i({},t,{name:"ChatToolbar"})).toolbar,a=o.buttons&&o.buttons.length;n.fn.init.call(this,e,t),a&&this._createButtonList(),a&&o.scrollable&&this.buttonsWidth()>this.element.width()&&this._initScrolling(),this._setupAnimation(),a&&o.toggleable&&this.toggle(!0),this.element.on("click"+r,this._onClick.bind(this)).on("keydown"+r,this._onKeydown.bind(this))},events:["click"],destroy:function(){n.fn.destroy.call(this),this.element.off(r),this.element.empty()},_createButtonList:function(){for(var t=h.styles,n=this.options.toolbar.buttons,i=e("<div class='"+t.buttonList+"'></div>"),r=0;r<n.length;r++){var o=this._createButton(n[r]);i.append(o)}i.appendTo(this.element),this.buttonList=i,this.buttons().first().removeAttr(c)},_createButton:function(n){var i,r=h.styles,a=e("<button>");return"string"==typeof n&&(n={name:n}),i=e.extend({},n.attr||{},{title:n.text||n.name,"aria-label":n.text||n.name,type:"button",tabindex:-1}),a.attr(i).addClass(n.name).data(o,n.name).addClass(r.button).addClass(r.buttonDefaults),(n.icon||n.iconClass)&&(a.addClass(r.iconButton),a.prepend(t.html.renderIcon({icon:n.icon,iconClass:"k-button-icon"+(n.iconClass?` ${n.iconClass}`:"")}))),a},_onClick:function(t){var n=h.styles,i=e(t.target).closest("."+n.button);i.is("."+n.scrollButton)&&!this._scrolling&&this._scroll(i.data(o)),i.data(o)&&(this.buttons().attr(c,-1),i.removeAttr(c),this.trigger("click",{button:i[0],name:i.data(o),originalEvent:t}))},_onKeydown:function(e){var n=e.keyCode,i=t.keys;switch(n){case i.LEFT:this._focusButton(-1);break;case i.RIGHT:this._focusButton(1)}},_focusButton:function(e){var t=this.buttons(),n=t.not("[tabindex=-1]"),i=t[n.index()+e];i&&(n.attr(c,-1),i.removeAttribute(c),i.trigger("focus"))},_initScrolling:function(){var e=h.styles;this.scrollButtonLeft=this._createButton({name:a,icon:e.scrollButtonLeftIcon,attr:{class:e.scrollButton+" "+e.scrollButtonLeft}}),this.scrollButtonRight=this._createButton({name:s,icon:e.scrollButtonRightIcon,attr:{class:e.scrollButton+" "+e.scrollButtonRight}}),this.element.prepend(this.scrollButtonLeft),this.element.append(this.scrollButtonRight),this._refreshScrollButtons(),this.element.on("keydown"+r,this._refreshScrollButtons.bind(this))},_scroll:function(e){var n=this,i=n.buttonWidth(),r=this.maxScrollSize(),o=e===a?-1*i:i,l=this.currentScrollLeft()+o;l=Math.min(Math.max(l,0),r),e!==a&&e!==s||(t.scrollLeft(n.buttonList,l),n._refreshScrollButtons(l))},_refreshScrollButtons:function(e){var t=this.maxScrollSize(),n=undefined===e||isNaN(parseInt(e,10))?this.currentScrollLeft():e;(this.scrollButtonLeft||this.scrollButtonRight)&&(this.scrollButtonLeft.toggle(0!==n),this.scrollButtonRight.toggle(n!==t))},_setupAnimation:function(){var e=this.options.toolbar.animation,t=i({},d),n=i({reverse:!0,hide:!0},d);e=!1===e?i(!0,{},u):i(!0,{expand:t,collapse:n},e),this.options.toolbar.animation=e},_animationComplete:function(){this._refreshScrollButtons()},_animationCompleteExpand:function(){this._animationComplete(),this.buttons().not("[tabindex=-1]").trigger("focus")},currentScrollLeft:function(){return Math.round(t.scrollLeft(this.buttonList))},maxScrollSize:function(){return Math.round(this.buttonList[0].scrollWidth-this.buttonList[0].clientWidth)},buttons:function(){var e=h.styles;return this.buttonList?this.buttonList.children("."+e.button):null},buttonWidth:function(){return Math.round(this.buttons().last().outerWidth(!0))},buttonsWidth:function(){var e=0;return this.buttons()&&(e=this.buttonWidth()*this.buttons().length),e},toggle:function(e){var t=this.options.toolbar.animation;e&&(t=i(!0,{},u)),t.expand.complete=this._animationCompleteExpand.bind(this),t.collapse.complete=this._animationComplete.bind(this),this.element.is(l)?this.element.kendoStop().kendoAnimate(t.collapse):this.element.kendoStop().kendoAnimate(t.expand)},focus:function(){this.element.is(l)?this.buttons().not("[tabindex=-1]").trigger("focus"):this.toggle()}});i(!0,h,{styles:{button:"k-button",buttonDefaults:"k-button-md k-rounded-md k-button-solid k-button-solid-base",buttonList:"k-button-list k-toolbar-group",scrollButton:"k-scroll-button",scrollButtonLeft:"k-scroll-button-left",scrollButtonRight:"k-scroll-button-right",scrollButtonLeftIcon:"chevron-left",scrollButtonRightIcon:"chevron-right",iconButton:"k-icon-button"}}),i(t.chat,{ChatToolBar:h})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.htmlEncode,i=t.ui.Widget,r=e.extend,o=".",a=".kendoChat",s=({url:e,text:t,styles:i})=>'<div class="k-avatar k-avatar-md k-avatar-solid k-avatar-solid-primary k-rounded-full"><span class="k-avatar-image">'+(({url:e,text:t,styles:i})=>`<img src="${e}" alt="${n(t)}">`)({url:e,text:t,styles:i})+"</span></div>",l=({text:e,url:t,styles:i})=>`<div ${n(e)} class="${i.messageGroup} ${t?"":i.noAvatar}">\n            <p class="${i.author}">${n(e)}</p>\n            ${t?s({url:t,text:e,styles:i}):""}\n        </div>`,c=({url:e,text:t,styles:n})=>`<div me class="${n.messageGroup} ${n.self} ${e?"":n.noAvatar}">\n        ${e?s({url:e,text:t,styles:n}):""}\n    </div>`,d=({styles:e,text:i,timestamp:r})=>`<div class="${e.message}">\n        <time class="${e.messageTime}">${t.toString(t.parseDate(r),"HH:mm:ss")}</time>\n        <div class="${e.bubble}">${n(i)}</div>\n    </div>`,u=({styles:e,text:t})=>`<div class="${e.messageListContent} ${e.typingIndicatorBubble}">\n        <p class="${e.author}">${n(t)}</p>\n        <div class="${e.message}">\n            <div class="${e.bubble}">\n                <div class="${e.typingIndicator}">\n                    <span></span><span></span><span></span>\n                </div>\n            </div>\n        </div>\n    </div>`,h=({styles:e,buttons:t})=>`<div class="k-actions ${e.cardActions} ${e.cardActionsVertical}">\n        ${t.map((t=>(({button:e,styles:t})=>`<span class="${t.cardAction}"><button class="${t.button} ${t.buttonPrimary}" data-value="${n(e.value)}"><span class="k-button-text">${n(e.title)}</span></button></span>`)({styles:e,button:t}))).join("")}\n    </div>`,p=({styles:e,images:t,buttons:i,title:r,subtitle:o,text:a})=>`<div class="${e.card} ${e.cardRich}">\n        ${void 0!==t&&t.length>0?(({images:e,styles:t})=>`<img src="${n(e[0].url)}" alt="${e[0].alt}" class="${t.cardMedia}" />`)({images:t,styles:e}):""}\n        <div class="${e.cardBody}">\n            ${void 0!==r?`<h5 class="${e.cardTitle}">${n(r)}</h5>`:""}\n            ${void 0!==o?`<h6 class="${e.cardSubtitle}">${n(o)}</h6>`:""}\n            ${void 0!==a?`<p>${n(a)}</p>`:""}\n        </div>\n        ${void 0!==i&&i.length>0?h({buttons:i,styles:e}):""}\n    </div>`;r(t.chat,{Templates:{},Components:{}}),t.chat.registerTemplate=function(e,n){t.chat.Templates[e]=t.template(n)},t.chat.getTemplate=function(e){return t.chat.Templates[e]||d},t.chat.registerTemplate("text",d),t.chat.registerTemplate("message",d),t.chat.registerTemplate("typing",u),t.chat.registerTemplate("suggestedAction",(({styles:e,suggestedActions:t})=>`<div class="${e.suggestedActions}">\n        ${t.map((t=>(({styles:e,action:t})=>`<span role="button" tabindex="0" class="${e.suggestedAction}" data-value="${n(t.value)}">${n(t.title)}</span>`)({styles:e,action:t}))).join("")}\n    </div>`)),t.chat.registerTemplate("heroCard",p),t.chat.registerTemplate("application/vnd.microsoft.card.hero",p),t.chat.registerComponent=function(e,n){t.chat.Components[e]=n},t.chat.getComponent=function(e){return t.chat.Components[e]||null};var f=t.chat.Component=t.Class.extend({init:function(t,n){this.element=e("<div></div>"),this.options=t,this.view=n},destroy:function(){t.destroy(this.element)}}),m=f.extend({init:function(e,n){f.fn.init.call(this,e,n),this.element.kendoCalendar({change:function(){n.trigger("suggestedAction",{text:t.toString(this.value(),"d"),type:"message"})}})},destroy:function(){}});t.chat.registerComponent("calendar",m);var g={wrapper:"k-chat",messageList:"k-avatars",messageListContent:"k-message-list-content",messageTime:"k-message-time",messageGroup:"k-message-group",message:"k-message",only:"k-only",first:"k-first",middle:"k-middle",last:"k-last",author:"k-author",avatar:"k-avatar",noAvatar:"k-no-avatar",self:"k-alt",button:"k-button",buttonDefaults:"k-button-md k-rounded-md k-button-solid k-button-solid-base",iconButton:"k-icon-button",buttonIcon:"k-button-icon",buttonPrimary:"k-button-md k-rounded-md k-button-flat k-button-flat-primary",scrollButtonIconLeft:"chevron-left",scrollButtonIconRight:"chevron-right",typingIndicator:"k-typing-indicator",typingIndicatorBubble:"k-typing-indicator-bubble",bubble:"k-chat-bubble",suggestedActions:"k-quick-replies",suggestedAction:"k-quick-reply",cardWrapper:"k-card-container",cardDeckScrollWrap:"k-card-deck-scrollwrap",cardDeck:"k-card-deck",cardList:"k-card-list",card:"k-card",cardRich:"k-card-type-rich",cardBody:"k-card-body",cardMedia:"k-card-media",cardTitle:"k-card-title",cardSubtitle:"k-card-subtitle",cardActions:"k-card-actions",cardActionsVertical:"k-actions-vertical",cardActionsHorizontal:"k-actions-horizontal",cardActionsStart:"k-actions-start",cardActionsCenter:"k-actions-center",cardActionsEnd:"k-actions-end",cardActionsStretched:"k-actions-stretched",cardAction:"k-card-action",selected:"k-selected"},v=t.chat.ChatView=i.extend({init:function(e,t){i.fn.init.call(this,e,t),this._list(),this._lastSender=null,this.typingParticipants=[],this._attachEvents(),this._scrollable()},events:[],options:{messages:{isTyping:" is typing.",areTyping:" are typing.",and:" and "}},destroy:function(){i.fn.destroy.call(this),this._scrollDraggable&&this._scrollDraggable.destroy(),this.element.empty(),this.element.off(a),this.list=null,this._lastSender=null},_list:function(){var t=v.styles;this.element.addClass(t.messageList).attr("role","log").attr("aria-label",this.options.messages.messageListLabel),this.list=e("<div>").addClass(t.messageListContent).appendTo(this.element)},_attachEvents:function(){var e=v.styles;this.element.on("click"+a,this._listClick.bind(this)).on("click"+a,o+e.message,this._messageClick.bind(this)).on("click"+a,o+e.suggestedAction,this._suggestedActionClick.bind(this)).on("click"+a,o+e.cardAction+" "+o+e.button,this._cardActionClick.bind(this)),this.element.on("keydown"+a,o+e.suggestedAction,this._suggestedActionKeydown.bind(this))},_scrollable:function(){var e=v.styles;this.element.on("click"+a,o+e.cardDeckScrollWrap+" "+o+e.button,this._scrollButtonClick.bind(this))},_scrollButtonClick:function(n){var i=v.styles,r=e(n.currentTarget),a=0!==r.find(`${o+i.buttonIcon}[class*=${i.scrollButtonIconLeft}]`).length,s=r.siblings(o+i.cardDeck),l=s.find(o+i.card).last().outerWidth(!0);a?t.scrollLeft(s,t.scrollLeft(s)-l):t.scrollLeft(s,t.scrollLeft(s)+l)},getTemplate:function(e){return t.chat.getTemplate(e)},getComponent:function(e){return t.chat.getComponent(e)},renderMessage:function(e,t){e.timestamp||(e.timestamp=new Date),e.text||(e.text="");var n=this._renderTemplate(e.type,e);this._renderBubble(e.type,n,t),"typing"==e.type?this.typingParticipants.length>0&&this._removeTypingParticipant(t):this._lastSender=t.id},renderSuggestedActions:function(e){this._removeSuggestedActions();var t=this._renderTemplate("suggestedAction",{suggestedActions:e});this.list.append(t),this._scrollToBottom()},renderAttachments:function(e){var t=this._renderAttachmentWrapper(e.attachmentLayout),n="carousel"===e.attachmentLayout?t.find(o+v.styles.cardDeck):t,i=e.attachments;if(i.length){for(var r=0;r<i.length;r++){var a=this._renderTemplate(i[r].contentType,i[r].content);n.append(a)}this._removeSuggestedActions(),this._removeTypingIndicator(),this.list.append(t),this._lastSender=null}},renderComponent:function(e){var t=new(this.getComponent(e))({},this);this.list.append(t.element),this._scrollToBottom()},_renderAttachmentWrapper:function(t){var n=v.styles,i=e("<div>");if("carousel"===t){i.addClass(n.cardDeckScrollWrap);var r=this._renderScrollButton(n.scrollButtonIconLeft);i.append(r),i.append(e("<div>").addClass(n.cardDeck));var o=this._renderScrollButton(n.scrollButtonIconRight);i.append(o)}else i.addClass(n.cardList);return i},_renderScrollButton:function(n){var i=v.styles;return e("<button>").addClass(i.button).addClass(i.buttonDefaults).addClass(i.iconButton).append(t.html.renderIcon({icon:n,iconClass:i.buttonIcon}))},_removeSuggestedActions:function(){this.list.find(o+v.styles.suggestedActions).remove()},_listClick:function(t){var n=v.styles,i=e(t.target);i.hasClass(n.message)||i.parents(o+n.message).length||this._clearSelection()},_messageClick:function(t){this._clearSelection(),e(t.currentTarget).addClass(v.styles.selected)},_suggestedActionClick:function(t){var n=e(t.target).data("value")||"";this.trigger("actionClick",{text:n}),this._removeSuggestedActions()},_suggestedActionKeydown:function(e){e.keyCode!==t.keys.SPACEBAR&&e.keyCode!==t.keys.ENTER||this._suggestedActionClick(e)},_cardActionClick:function(t){var n=e(t.target).data("value")||"";this.trigger("actionClick",{text:n})},_renderBubble:function(e,t,n){this._removeSuggestedActions(),this._removeTypingIndicator();var i=this._getMessageGroup(n,e);this._appendToGroup(i,t,e),this._scrollToBottom()},_renderTemplate:function(t,n){var i,o=this.getComponent(t);if(o){i=new o(n,this).element}else{var a=this.getTemplate(t),s=r(!0,{},n,{styles:v.styles});i=e(a(s))}return i},_getMessageGroup:function(t,n){var i,r=v.styles,a=this._getMessageGroupTemplate(t,n),s="typing"==n?this.element:this.list;return t.id===this._lastSender&&null!==this._lastSender&&"typing"!==n&&(i=this.list.find(o+r.messageGroup).last()).length?i:e(a({text:t.name,url:t.iconUrl,styles:r})).appendTo(s)},_getMessageGroupTemplate:function(e,t){var n=e.id===this.options.user.id?c:l;return"typing"==t&&(n=u),n},_appendToGroup:function(e,t,n){var i=v.styles,r=e.find(o+i.message),a=r.length;this.element.find(o+i.typingIndicator).length&&"typing"==n||(t.addClass(0===a?i.only:i.last),r.filter(o+i.only).removeClass(i.only).addClass(i.first),r.filter(o+i.last).removeClass(i.last).addClass(i.middle),e.append(t))},_renderTypingIndicator:function(t){var n,i=this.element.find(o+g.typingIndicatorBubble);this._addTypingParticipant(t),i.length?(n=this._composeTypingParticipantsText(this.typingParticipants),i.find(o+g.author).first().text(n)):e(u({text:t.name+this.options.messages.isTyping,styles:g})).appendTo(this.element),this._scrollToBottom()},_addTypingParticipant:function(e){for(var t=!1,n=0;n<this.typingParticipants.length;n+=1)if(this.typingParticipants[n].id==e.id){t=!0;break}t||this.typingParticipants.push(e)},_removeTypingParticipant:function(e){var t,n=this.element.find(o+g.typingIndicatorBubble);if(n.length){for(var i=0;i<this.typingParticipants.length;i+=1)this.typingParticipants[i].id==e.id&&this.typingParticipants.splice(i,1);""===(t=this._composeTypingParticipantsText(this.typingParticipants))?n.remove():n.find(o+g.author).first().text(t)}},_composeTypingParticipantsText:function(e){var t=this.options.messages,n=1==e.length?t.isTyping:t.areTyping,i="";return 0===e.length?i:i=this.typingParticipants.map((function(e){return e.name})).join(", ").replace(/,(?!.*,)/gim,t.and.trimRight())+n},_removeTypingIndicator:function(){var e=this.element.find(o+g.typingIndicatorBubble);e.length&&(this.typingParticipants=[],e.remove())},_clearSelection:function(){var e=v.styles.selected;this.element.find(o+e).removeClass(e)},_scrollToBottom:function(){this.element.scrollTop(this.element.prop("scrollHeight"))}});r(!0,v,{styles:g})}(window.kendo.jQuery);!function(e,t){var n=window.kendo,i=n.ui.Widget,r=e.extend,o=".",a={wrapper:"k-chat",canvas:"k-chat-canvas",viewWrapper:"k-message-list",messageBoxWrapper:"k-message-box",toolbarBoxWrapper:"k-toolbar-box"},s=i.extend({init:function(e,t,r){i.fn.init.call(this,e,t),r&&(this._events=r),this._user(),this._wrapper(),this._view(),t&&t.toolbar&&t.toolbar.buttons&&this._toolbar(),this._messageBox(),n.notify(this)},events:["typingStart","typingEnd","post","sendMessage","actionClick","toolClick"],options:{user:{name:"User",iconUrl:""},name:"Chat",messages:{messageListLabel:"Message list",placeholder:"Type a message...",toggleButton:"Toggle toolbar",sendButton:"Send message"},toolbar:!1},setOptions:function(t){this._setEvents(t),e.extend(!0,this.options,t),this.toolbar&&"toolbar"in t&&(this.toolbar.destroy(),this.toolbar=null),this.messageBox&&(this.messageBox.unbind(),this.messageBox.destroy(),this.messageBox=null),this._messageBox(),"toolbar"in t&&(this._resetToolbarButtons(t),this._toolbar())},_resetToolbarButtons:function(e){var t=this.wrapper.find(o+a.toolbarBoxWrapper);t.is(":visible")||t.show(),e.toolbar&&"object"==typeof e.toolbar&&"buttons"in e.toolbar&&(this.options.toolbar.buttons=e.toolbar.buttons)},destroy:function(){this.view&&(this.view.unbind(),this.view.destroy(),this.view=null),this.messageBox&&(this.messageBox.unbind(),this.messageBox.destroy(),this.messageBox=null),this.toolbar&&(this.toolbar.destroy(),this.toolbar=null),i.fn.destroy.call(this)},_user:function(){this.options.user.id=n.guid()},getUser:function(){return r(!0,{},this.options.user)},_wrapper:function(){var t=s.styles,n=this.options,i=n.height,r=n.width,a="<div class='"+t.viewWrapper+"'></div><span class='"+t.messageBoxWrapper+"'></span>",l=e(`<div class="${t.toolbarBoxWrapper}" role="toolbar"></div>`).hide();this.wrapper=this.element.addClass(t.wrapper).append(a).append(l),n.toolbar&&n.toolbar.buttons&&n.toolbar.buttons.length&&this.wrapper.find(o+t.toolbarBoxWrapper).show(),i&&this.wrapper.height(i),r&&this.wrapper.css("max-width",r)},_view:function(){var e=this,t=s.styles,i=r(!0,{},this.options),a=this.wrapper.find(o+t.viewWrapper+"");this.view=new n.chat.ChatView(a,i),this.view.bind("actionClick",(function(t){e.trigger("actionClick",t),e.postMessage(t.text)}))},_messageBox:function(){let e=this,t=s.styles,i=r(!0,{},{name:e.options.name,messages:e.options.messages,toolbar:e.options.toolbar,toolbarId:e.options.toolbarId}),a=this.wrapper.find(o+t.messageBoxWrapper+"");this.messageBox=new n.chat.ChatMessageBox(a,i),this.messageBox.bind("typingStart",(function(t){e.trigger("typingStart",t)})).bind("typingEnd",(function(t){e.trigger("typingEnd",t)})).bind("sendMessage",(function(t){e.trigger("sendMessage",t),e.postMessage(t.text)})).bind("toggleToolbar",(function(){e.toggleToolbar()})).bind("focusToolbar",(function(){e.toolbar&&e.toolbar.focus()}))},_toolbar:function(){var e=this,i=s.styles,a=r(!0,{},e.options),l=e.wrapper.find(o+i.toolbarBoxWrapper+"");e.options.toolbarId=n.guid(),l.attr("id",e.options.toolbarId),a.toolbar.scrollable===t&&(this.options.toolbar.scrollable=a.toolbar.scrollable=!0),a.toolbar.toggleable===t&&(this.options.toolbar.toggleable=a.toolbar.toggleable=!1),e.toolbar=new n.chat.ChatToolBar(l,a),e.toolbar.bind("click",(function(t){e.trigger("toolClick",{sender:e,name:t.name,button:t.button,messageBox:e.messageBox.input[0],originalEvent:t.originalEvent})}))},postMessage:function(e){var t=r(!0,{},{text:e,type:"message",timestamp:new Date,from:this.getUser()});this.trigger("post",t),this.renderMessage(t,t.from)},renderMessage:function(e,t){this.view.renderMessage(e,t)},renderSuggestedActions:function(e){this.view.renderSuggestedActions(e)},renderAttachments:function(e,t){this.view.renderAttachments(e,t)},toggleToolbar:function(e){this.toolbar.toggle(e)},renderUserTypingIndicator:function(e){this.view._renderTypingIndicator(e)},clearUserTypingIndicator:function(e){this.view._removeTypingParticipant(e)},removeTypingIndicator:function(){this.view._removeTypingIndicator()}});n.ui.plugin(s),r(!0,s,{styles:a})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.ui,o=({icon:t})=>n.ui.icon(e("<span class='k-badge-icon'></span>"),{icon:t}),a=({icon:e})=>`<span class='k-badge-icon k-svg-icon k-icon'>${e}</span>`,s=i.extend({init:function(e,t){var r=this;i.fn.init.call(r,e,t),r._content(),r._appearance(),n.notify(r)},destroy:function(){i.fn.destroy.call(this)},options:{name:"Badge",cutoutBorder:!1,data:{},fillMode:"solid",icon:"",max:1/0,position:"inline",align:"",rounded:"medium",roundings:{small:"sm",medium:"md",large:"lg",full:"full"},sizes:{small:"sm",medium:"md",large:"lg"},size:"medium",template:null,text:"",themeColor:"secondary",visible:!0,_classNames:[]},_content:function(){var e=this,t=e.options.text,i=e.options.template,r=e.options.data,o=e.options.icon;if(null!==i)return e._text=t,e._template=n.template(i).bind(e),void e.element.html(e._template(r));""===o?""===t?e.text(e.element.html()):e.text(t):e.icon(o)},_appearance:function(){var e=this;e._themeColor=e.options.themeColor,e._shape=e.options.shape,e._sizes=e.options.sizes,e._size=e.options.size,e._fillMode=e.options.fillMode,e._rounded=e.options.rounded,e._roundings=e.options.roundings,e._cutoutBorder=e.options.cutoutBorder,e._align=e.options.align,e._position=e.options.position,e._visible=e.options.visible,e._updateClassNames()},_updateClassNames:function(){var e=this,n=["k-badge"],i=e.options._classNames,r=e._themeColor,o=e._shape,a=e._sizes,s=e._size,l=a[s]===t?s:a[s],c=e._fillMode,d=e._rounded,u=e._roundings,h=u[d]===t?d:u[d],p=e._cutoutBorder,f=e._align,m=e._position,g=e._visible;e.element.removeClass((function(t,n){0===n.indexOf("k-")&&-1===i.indexOf(n)&&e.element.removeClass(n)})),"string"==typeof c&&""!==c&&n.push("k-badge-"+c),"string"==typeof r&&""!==r&&n.push("k-badge-"+c+"-"+r),"string"==typeof s&&""!==s&&n.push("k-badge-"+l),"string"==typeof d&&""!==d&&n.push("k-rounded-"+h),"string"==typeof o&&""!==o&&n.push("k-badge-"+o),"boolean"==typeof p&&!0===p&&n.push("k-badge-border-cutout"),"string"==typeof m&&""!==m&&n.push("k-badge-"+m),"string"==typeof m&&""!==m&&"inline"!==m&&"string"==typeof f&&2==f.split(" ").length&&n.push("k-"+f.replace(" ","-")),!1===g&&n.push("k-hidden"),e.element.addClass(n.join(" "))},setOptions:function(e){var t=this;t.element.removeClass((function(e,n){n.indexOf("k-")>=0&&t.element.removeClass(n)})),i.fn.setOptions.call(t,e),t._content(),t._appearance()},text:function(e){var n=this,i=n.options.max;if(0===arguments.length||e===t)return n._text;n._text=e,!0!==e&&!1!==e&&null!==e?"string"!=typeof e?"number"!=typeof e?"object"==typeof e&&"toString"in e&&n.element.html(e.toString()):e>i?n.element.html(i+"+"):n.element.html(e):n.element.html(e):n.element.html("")},icon:function(e){var i,r=this;return 0===arguments.length||e===t?r._icon:(r._icon=e,0===e.indexOf("<svg")?(i=n.template(a),void r.element.html(i({icon:e}))):(i=n.template(o),void r.element.html(i({icon:e}))))},themeColor:function(e){var n=this;if(0===arguments.length||e===t)return n._themeColor;n._themeColor=e,n._updateClassNames()},rounded:function(e){var n=this;if(0===arguments.length||e===t)return n._rounded;n._rounded=e,n._updateClassNames()},hide:function(){this._visible=!1,this._updateClassNames()},show:function(){this._visible=!0,this._updateClassNames()}});r.plugin(s)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.html,o=n.ui,a=n.keys,s="click",l=n.support.mousedown,c=n.support.mouseup,d=".kendoButton",u="disabled",h="k-focus",p="k-active";n.setDefaults("button",{icon:"",iconClass:"",spriteCssClass:"",imageUrl:"",badge:null});var f=i.extend({init:function(t,o){var a=this;i.fn.init.call(a,t,o),t=a.wrapper=a.element,o=a.options,r.renderButton(t,e.extend({},o)),t.attr("role","button"),o.enable=o.enable&&o.enabled&&!t.attr(u),a.enable(o.enable),o.enable&&a._tabindex(),a._badge(),t.on(s+d,a._click.bind(a)).on("focus"+d,a._focus.bind(a)).on("blur"+d,a._blur.bind(a)).on("keydown"+d,a._keydown.bind(a)).on("keyup"+d,a._removeActive.bind(a)).on(l+d,a._addActive.bind(a)).on(c+d+" mouseout"+d,a._removeActive.bind(a)),n.notify(a)},destroy:function(){var e=this;e.wrapper.off(d),e.badge&&e.badge.destroy(),i.fn.destroy.call(e)},events:[s],options:{name:"Button",enable:!0,enabled:!0,icon:"",iconClass:"",spriteCssClass:"",imageUrl:"",badge:null,size:"medium",shape:"rectangle",rounded:"medium",fillMode:"solid",themeColor:"base"},_isNativeButton:function(){return"button"==this.element.prop("tagName").toLowerCase()},_click:function(e){this.options.enable&&this.trigger(s,{event:e,id:this.element.attr("id"),target:this.element})&&e.preventDefault()},_focus:function(){this.options.enable&&this.element.addClass(h)},_blur:function(){var e=this;e.element.removeClass(h),setTimeout((function(){e.element.removeClass(p)}))},_keydown:function(e){var t=this;e.keyCode!=a.ENTER&&e.keyCode!=a.SPACEBAR||(t._addActive(),t._isNativeButton()||(e.keyCode==a.SPACEBAR&&e.preventDefault(),t._click(e)))},_removeActive:function(){this.element.removeClass(p)},_addActive:function(){this.options.enable&&this.element.addClass(p)},enable:function(e){var n=this,i=n.element;e===t&&(e=!0),e=!!e,n.options.enable=e,i.toggleClass("k-disabled",!e).attr("aria-disabled",!e).attr(u,!e),e&&n._tabindex();try{i.trigger("blur")}catch(e){}},_badge:function(n){var i,r=this,a=n||r.options.badge;null!==a&&a!==t&&(a.constructor!==Object&&(a={text:a}),a.position!==t&&""!==a.position||(a.position="edge",a.align!==t&&""!==a.align||(a.align="top end")),a._classNames=["k-button-badge"],r.element.addClass("k-badge-container"),i=e("<span />").appendTo(r.element),r.badge=new o.Badge(i,a))}});!1===f.fn.hasOwnProperty("defaults")&&Object.defineProperty(f.fn,"defaults",{get:function(){return n.defaults.button}}),n.cssProperties.registerPrefix("Button","k-button-"),n.cssProperties.registerValues("Button",[{prop:"fillMode",values:n.cssProperties.fillModeValues.concat(["link","clear"])},{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),n.ui.plugin(f)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Button,r="click",o="toggle",a="aria-pressed",s="k-selected",l=i.extend({init:function(e,t){var r=this;i.fn.init.call(r,e,t),e=r.wrapper=r.element,t=r.options,r._selected=!0===t.selected,r.toggle(r._selected),t.group&&e.attr("data-group",t.group),n.notify(r)},destroy:function(){this.wrapper.off(".kendoToggleButton"),i.fn.destroy.call(this)},events:[r,o],options:{name:"ToggleButton",group:t,selected:!1},toggle:function(e){e===t&&(e=!this._selected),this._selected=e,!0===e?(this.element.attr(a,!0),this.element.addClass(s)):!1===e&&(this.element.attr(a,!1),this.element.removeClass(s))},_click:function(e){this.options.enable&&(this.trigger(r,{event:e,id:this.element.attr("id"),target:this.element})?e.preventDefault():(this.toggle(),this.trigger(o,{event:e,checked:this._selected,group:this.options.group,id:this.element.attr("id"),target:this.element})))}});n.cssProperties.registerPrefix("ToggleButton","k-button-"),n.cssProperties.registerValues("ToggleButton",[{prop:"fillMode",values:n.cssProperties.fillModeValues.concat(["link"])},{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),n.ui.plugin(l)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=n.Widget,r=n.ToggleButton,o=n.Button,a=t.keys,s=".kendoButtonGroup",l="k-button",c="k-selected",d="k-disabled",u="select",h="aria-disabled",p=".",f="none",m="single",g="multiple",v="focus",_=i.extend({init:function(e,t){var n=this;i.fn.init.call(n,e,t),n.wrapper=n.element,n.selectedIndices=[],n._buttons=n._renderItems(n.options.items);const r=t&&t.fillMode?t.fillMode:"solid";n.element.addClass(" k-button-group k-button-group-"+r).attr("role","group"),n._enable=!0,n.options.enable&&n.options.enabled||(n._enable=!1,n.element.attr(h,!0).addClass(d),n._buttons.forEach((e=>{e.enable(!1)}))),n.options.selection!==f&&n.select(n.options.index),n._attachEvents()},events:[u],options:{name:"ButtonGroup",selection:m,index:-1,enable:!0,enabled:!0,preventKeyNav:!1,size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"},badge:function(e,n){var i,r,o=this.element,a=isNaN(e)?o.find(e).getKendoToggleButton()||o.find(e).getKendoButton():this._buttons[e],s=n||0===n;if(a){if(!(i=a.badge)&&s)return a._badge({text:t.htmlEncode(n)}),t.htmlEncode(n);if(s)i.text(t.htmlEncode(n));else if(!1===n)return a.badge=null,r=i.element,i.destroy(),void r.empty().remove();return i?i.text():null}},current:function(){return this.element.find(p+c)},destroy:function(){var t=this;t.element.off(s),t.element.find(p+l).each((function(t,n){var i=e(n).getKendoToggleButton()||e(n).getKendoButton();i&&i.destroy()})),i.fn.destroy.call(t)},enable:function(e){void 0===e&&(e=!0),this.element.attr(h,!e).toggleClass(d,!e),this._buttons.forEach((t=>{var n=t.element.hasClass("k-focus")||t.element.is(":focus");t.enable(e),n&&t.element.removeAttr("disabled").addClass("k-focus").trigger("focus")})),this._enable=this.options.enable=e},select:function(t){var n=this,i=-1;this.options.selection!==f&&undefined!==t&&-1!==t&&(i="number"==typeof t?t:t.nodeType?(t=e(t)).index():t.index(),n._buttons[i]&&(n.options.selection===g?t.length>1?t.each(((t,i)=>{var r=e(i).index();n._buttons[r].toggle(),n._toggleIndex(r)})):(n._buttons[i].toggle(),n._toggleIndex(i)):n._resetIndexes(i)))},_addButton:function(e,t){if(this.options.selection===f||t.command&&!t.togglable)return delete t.selected,new o(e,t);var n=new r(e,t);return n.bind("toggle",this._select.bind(this,e)),n},_attachEvents:function(){this.options.preventKeyNav||this.element.on("keydown"+s,this._keyDown.bind(this))},_keyDown:function(n){var i=e(this.element),r=i.find(p+l),o=i.find(":focus"),s=r.index(o),c=t.support.isRtl(this.element);n.keyCode===a.LEFT&&!c||n.keyCode===a.RIGHT&&c?((0===s?r.eq(r.length-1):e(r[s-1])).trigger(v),n.preventDefault()):(n.keyCode===a.LEFT&&c||n.keyCode===a.RIGHT&&!c)&&((s+1===r.length?r.eq(0):e(r[s+1])).trigger(v),n.preventDefault())},_decorateButtons:function(t){t.length&&(e(t[0].element).addClass("k-group-start"),e(t[t.length-1].element).addClass("k-group-end"))},_renderItems:function(n){var i=this,r=i.options,o=i.element.children(),a=[];return o.length>0&&o.each((function(n){var o=e(this),s=o.find("img").addClass("k-image"),l=o.is("[disabled]")||o.hasClass(d),u={badge:t.attrValue(o,"badge"),icon:s[0]?null:t.attrValue(o,"icon"),disabled:l,selected:!l&&o.is(p+c),size:r.size,rounded:r.rounded,fillMode:r.fillMode,themeColor:r.themeColor};a.push(i._addButton(o,u)),u.selected&&i.selectedIndices.push(n)})),n?(n.forEach((function(n,o){var s=n.text?!1===n.encoded?n.text:t.htmlEncode(n.text):"",l=n.url?e("<a href="+n.url+">"):e("<button>");l.html(s),n.attributes&&l.attr(n.attributes),n=e.extend({},n,{size:r.size,rounded:r.rounded,fillMode:r.fillMode,themeColor:r.themeColor}),l.appendTo(i.element),a.push(i._addButton(l,n)),n.selected&&i.selectedIndices.push(o)})),i._decorateButtons(a),a):(i._decorateButtons(a),a)},_resetIndexes:function(e){this.selectedIndices=[],this._buttons.forEach((e=>{e.toggle(!1)})),this._buttons[e].toggle(!0),this.selectedIndices.push(e)},_select:function(e){var t=this.options.selection,n=e.index();this._enable&&!e.is(p+d)&&(t===g?this._toggleIndex(n):t===m&&this._resetIndexes(n),this.trigger(u,{indices:this.selectedIndices,target:e}))},_toggleIndex:function(e){-1===this.selectedIndices.indexOf(e)?this.selectedIndices.push(e):this.selectedIndices.splice(this.selectedIndices.indexOf(e),1)}});n.plugin(_)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=e.extend,o=(n.mediaQuery,e.isPlainObject),a=(n.support,n.htmlEncode),s=".kendoBreadcrumb",l="aria-hidden",c="click",d="blur",u="keydown",h="change",p=".",f={widget:"k-breadcrumb",overlay:"k-breadcrumb-container",textbox:"k-input-inner",textboxWrapper:"k-textbox k-input k-input-md k-rounded-md k-input-solid",link:"k-breadcrumb-link",item:"k-breadcrumb-item",delimiter:"k-breadcrumb-delimiter-icon",rootItem:"k-breadcrumb-root-item",rootLink:"k-breadcrumb-root-link",overflowIcon:"k-breadcrumb-overflow-icon",focused:"k-focus",hidden:"k-hidden",inputWrapper:"k-breadcrumb-input-container"},m=i.extend({init:function(e,t){var r=this;t=t||{},i.fn.init.call(r,e,t),r._wrapper(),t.editable&&(r._editable(),r._tabindex()),r.wrapper.on(c+s,"a:not(.k-disabled)",r._click.bind(r)),t.value||t.bindToLocation||!t.items?r._value():t.items&&r.items(t.items),r._applyCssClasses(),r._resizeHandler=n.onResize((function(){r.resize(!0)}))},options:{editable:!1,navigational:!1,bindToLocation:!1,items:null,name:"Breadcrumb",size:"medium",gap:0,rootIcon:"home",delimiterIcon:"chevron-right",messages:{rootTitle:"Go to root"}},events:[h,c],destroy:function(){var e=this;i.fn.destroy.call(e),n.unbindResize(e._resizeHandler),e.wrapper.add(e.wrapper.find("input")).add(e.wrapper.find("a")).off(s)},items:function(e){var n=this;if(e===t)return n.options.items;n.options.items=e,n._segments=e,n.refresh()},_update:function(e){var t=this;e!==t.value()&&(t._generateSegments(e),t.refresh(),t.trigger(h,{sender:this,value:e}))},_generateSegments:function(e){var t,n,i=this,r=i.options.items;if(n=i._split(e),r){i._segments=[];for(var o=0;o<n.length;o++)""!==(t=i._path(r.slice(0,o+1)))&&e.indexOf(t)>-1&&r[o]&&r[o].text===n[o]?i._segments.push(r[o]):i._segments.push(n[o])}else i.options.items=i._segments=n},_click:function(t){var n=this,i=n.options,r=e(t.target).closest(p+f.item),o=r.prevAll().addBack(),a=n._getItems(o),s=n._path(a),l=n._segments[r.index()];i.navigational||t.preventDefault(),n.trigger(c,{sender:n,originalEvent:t,isRoot:"rootitem"===l.type,item:l})||n._update(s)},_getItems:function(t){var n=this;return e.map(t,(function(t){return n._segments[e(t).index()]||t.innerText}))},_edit:function(){var e=this,t=e.input;e.oldValue=e.value(),e.inputWrapper.css("height",e.wrapper.height()),e.overlay.hide(),e.input.val(e.value()),e.input.attr(l,!1),e.inputWrapper.show(),setTimeout((function(){t.select()}))},_blur:function(e){var t=this,n=t.input,i=t.inputWrapper,r=t.wrapper,o=t.overlay,a=n.val().replace(/\/{2,}/g,"/");o.is(":visible")||(e&&(a=t.oldValue),n.attr(l,!0),i.hide(),o.show(),n.val(""),t._update(a),r.removeClass(f.focused))},_keydown:function(e){var t=this,i=e.keyCode,r=i===n.keys.ENTER,o=i===n.keys.ESC;(r||o)&&(t._blur(o),setTimeout((function(){t.overlay.find("a").first().trigger("focus")})))},isNavigational:function(e){var t=e.hasClass(f.textbox)||e.closest(p+f.item);return e[0]!==this.wrapper[0]&&(t&&!e.hasClass("k-breadcrumb-last-item"))},_wrapperKeydown:function(t){var i=e(t.target),r=this.isNavigational(i);t.keyCode!==n.keys.ENTER||r||this._edit()},_wrapperClick:function(t){var n=e(t.target);this.isNavigational(n)||this._edit()},_wrapperFocus:function(t){e(t.target).addClass(f.focused)},_wrapperBlur:function(t){e(t.target).removeClass(f.focused)},_wrapper:function(){var t=this,n=this.element,i=n.is("input"),r=e('<div class="'+f.inputWrapper+'"><span class="'+f.textboxWrapper+'"></span></div>');t.wrapper=i?n.wrap(e("<nav />")).parent():n,i?(t.element.wrap(r).addClass(f.textbox),t.inputWrapper=t.wrapper.find(p+f.inputWrapper).hide()):t.inputWrapper=t.wrapper.append(r).find(p+f.inputWrapper).hide(),t.wrapper.addClass(f.widget),t.wrapper.attr("aria-label","Breadcrumb"),t.overlay=t.wrapper.append(e("<ol />").addClass(f.overlay)).find(p+f.overlay)},_editable:function(){var t=this,n=t.element.is("input");t.input=n?t.element:e("<input />"),t.inputWrapper.find(p+f.textboxWrapper.split(" ")[0]).append(t.input),t.input.addClass(f.textbox).attr(l,!0),t.input.on(d+s,t._blur.bind(t,!1)).on(u+s,t._keydown.bind(t)),t.wrapper.on("focus"+s,t._wrapperFocus.bind(t)).on(d+s,t._wrapperBlur.bind(t)).on(u+s,t._wrapperKeydown.bind(t)).on(c+s,t._wrapperClick.bind(t))},_value:function(){var e=this,t=e.options;t.value?e.value(t.value):t.bindToLocation?e.value(window.location.href.replace(/http(s?):\/\//,"").replace(/\/$/,"")):e.value("")},_split:function(e){return e.split("/").filter((function(e,t){return!(t>0&&""===e)}))},isRtl:function(){return n.support.isRtl(this.wrapper)},refresh:function(){var i,a,s,l,c=this,d=c.options,u=d.messages,h=c.options.delimiterIcon,p="",m="",g=""===c.value(),v=c._segments;for("chevron-right"==h&&c.isRtl()&&(h="chevron-left"),a=0,s=v.length;a<s;a++)i=v[a],l=a===v.length-1,i!==t&&(p?m+=i.text||i||"":m="/","string"==typeof i?(i={type:p?"item":"rootitem",href:d.navigational?m:"#",text:i,showIcon:!p,showText:!!p,icon:p?"":d.rootIcon,itemClass:p?"":"k-breadcrumb-root-item",linkClass:p?"":f.rootLink,delimiterIcon:h,renderDelimiter:!l&&!g,lastSegment:l,iconClass:""},c._segments.splice(a,1,i)):o(i)&&(i=r({},i,{type:i.type?i.type.toLowerCase():"item"}),"rootitem"===(i=r({},i,{text:i.text||"",title:i.text||"",icon:i.icon||("rootitem"===i.type?d.rootIcon:""),iconClass:i.iconClass||"",lastSegment:l,renderDelimiter:!l&&v.length>1,href:d.navigational?i.href:"#",delimiterIcon:h,itemClass:i.itemClass||"",linkClass:i.linkClass||"",showIcon:i.showIcon===t?"rootitem"===i.type&&"item"!==i.type:i.showIcon,showText:i.showText===t?"item"===i.type&&"rootitem"!==i.type:i.showText})).type&&(i.itemClass+=" k-breadcrumb-root-item",i.linkClass+=" "+f.rootLink)),"rootitem"===i.type&&""===i.text&&(i.title=u.rootTitle),m+=m.match(/\/$/)?"":"/",p+=n.template(this.itemTemplate)(i));this.overlay.empty().append(e(p)),this.resize(!0)},itemTemplate:t=>{const i=t.showIcon?n.ui.icon(e(`<span class="${a(t.iconClass)}"></span>`),{icon:a(t.icon)}):"",r=t.renderDelimiter?n.ui.icon(e('<span class="k-breadcrumb-delimiter-icon" aria-hidden="true"></span>'),{icon:a(t.delimiterIcon),size:"xsmall"}):"",o=t.showText?`<span class="k-breadcrumb-item-text">${!1!==t.encoded?a(t.text):t.text}</span>`:"",s=`<a href="${a(t.href)}" class="${a(t.linkClass)} ${(()=>{let e={"k-breadcrumb-link":"rootitem"!==t.type,"k-breadcrumb-icontext-link":t.showText&&t.showIcon,"k-breadcrumb-icon-link":t.showIcon&&!t.showText,"k-disabled":t.lastSegment&&"rootitem"!==t.type};return Object.keys(e).filter((t=>e[t])).join(" ")})()}"\n                ${t.lastSegment?'aria-current="page"':""}\n                ${t.lastSegment&&"rootitem"!==t.type?'aria-disabled="true"':""}\n                title="${a(t.text||t.title)}">${i}${o}</a>`;return`<li class="k-breadcrumb-item ${a(t.itemClass)} ${t.lastSegment?"k-breadcrumb-last-item":""}">${s}${r}</li>`},_displayOverflowIcons:function(e){var t=this.wrapper.find(p+f.rootItem);e?t.find(p+f.delimiter).addClass(f.overflowIcon).removeClass(f.hidden):t.find(p+f.overflowIcon).removeClass(f.overflowIcon).last().addClass(f.hidden)},_shrinkItems:function(){var t,i,r=this,o=r.wrapper,a=r.overlay,s=r.overlay.find(p+f.item+":not(.k-breadcrumb-root-item)"),l=n._outerWidth(r.overlay.find(p+f.delimiter+":visible").first()),c=o.width()-r.options.gap-l;if(1!=s.length){for(var d=0;d<s.length;d+=1)if(i=e(s[d]),n._outerWidth(a)>=c){if(d==s.length-1)break;t=i,i.find(p+f.delimiter).hide(),i.find(p+f.link).hide(),r._displayOverflowIcons(!0)}t&&t.find(p+f.delimiter).show()}},_showItem:function(e,t,i){return!!(e.length&&i>t+n._outerWidth(e,!0))&&(e.find(p+f.link).show(),e.prev().find(p+f.delimiter).show(),!0)},_stretchItems:function(){var t,i,r=this,o=r.wrapper,a=r.overlay,s=r.overlay.find(p+f.item+":not(.k-breadcrumb-root-item)"),l=n._outerWidth(r.overlay.find(p+f.delimiter+":visible").first()),c=o.width()-r.options.gap-l;s.length||r._displayOverflowIcons(!1);for(var d=s.length-1;d>=0&&(t=e(s[d]),!((i=n._outerWidth(a))>c)&&this._showItem(t,i,c));d--);},_resize:function(){this._shrinkItems(),this._stretchItems()},getSize:function(){return n.dimensions(this.wrapper)},value:function(e){var n=this;return e!==t?(n._generateSegments(e),void n.refresh()):n._path(n._segments)},_path:function(t){return e.map(t,(function(e){var t=o(e)?e.text:e;return"/"===t?"":t})).join("/")}});n.cssProperties.registerPrefix("Breadcrumb","k-breadcrumb-"),n.ui.plugin(m)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=".kendoSwitch",o=i.Widget,a=n.support,s="change",l={widget:"k-switch",track:"k-switch-track",thumbWrapper:"k-switch-thumb-wrap",thumb:"k-switch-thumb",checked:"k-switch-on",checkedLabel:"k-switch-label-on",unchecked:"k-switch-off",uncheckedLabel:"k-switch-label-off",disabled:"k-disabled",readonly:"k-readonly",active:"k-active"},c="disabled",d="aria-disabled",u="readonly",h="aria-readonly",p="aria-hidden",f="checked",m=a.click+r,g=a.pointers?"pointerup":"touchend",v="keydown"+r,_=".",b=n.htmlEncode,y=n.template((({styles:e})=>`<span class="${e.widget}" role="switch"></span>`)),w=n.template((({styles:e,checked:t,unchecked:n})=>`<span class='${e.track}'><span class='${e.checkedLabel}'>${b(t)}</span><span class='${e.uncheckedLabel}'>${b(n)}</span></span>`)),k=n.template((({styles:e})=>`<span class='${e.thumbWrapper}'><span class='${e.thumb}'></span></span>`)),x=o.extend({init:function(e,t){var i=this;o.fn.init.call(i,e,t),i._wrapper(),i._initSettings(),i._aria(),i._attachEvents(),n.notify(i,n.ui)},_wrapper:function(){var t=this,n=t.options,i=t.element[0],r=e(y({styles:l}));i.type="checkbox",t.wrapper=t.element.wrap(r).parent(),t.wrapper[0].style.cssText=t.element[0].style.cssText,t.element.hide(),t.wrapper.append(e(w({styles:l,checked:n.messages.checked,unchecked:n.messages.unchecked}))).append(e(k({styles:l}))).addClass(i.className).removeClass("input-validation-error"),t.options.rounded=t.options.trackRounded,t._applyCssClasses(),t._applyRoundedClasses()},_applyRoundedClasses:function(e){var t=this,i=t.options,r=n.cssProperties.getValidClass({widget:i.name,propName:"rounded",value:i.trackRounded}),o=n.cssProperties.getValidClass({widget:i.name,propName:"rounded",value:i.thumbRounded});e=e||"addClass",t.wrapper.find(_+l.track)[e](r),t.wrapper.find(_+l.thumb)[e](o)},_attachEvents:function(){var e=this;e.wrapper.on(m,e._click.bind(e)).on(g,e._touchEnd.bind(e)).on(v,e._keydown.bind(e))},setOptions:function(n){let i,r,o=this,a=n.messages;o._clearCssClasses(n),o._applyRoundedClasses("removeClass"),o.options=e.extend(o.options,n),a&&a.checked!==t&&(i=o.wrapper.find(_+l.checkedLabel),i.text(b(a.checked))),a&&a.unchecked!==t&&(r=o.wrapper.find(_+l.uncheckedLabel),r.text(b(a.unchecked))),n.width&&o.wrapper.css({width:n.width}),n.enabled!==t&&o.enable(n.enabled),n.readonly!==t&&o.readonly(n.readonly),o.check(n.checked),o.options.rounded=o.options.trackRounded,o._applyCssClasses(),o._applyRoundedClasses()},_initSettings:function(){var e=this,t=e.element[0],n=e.options;n.enabled&&e._tabindex(),n.width&&e.wrapper.css({width:n.width}),null===n.checked&&(n.checked=t.checked),e.check(n.checked),n.enabled=n.enabled&&!e.element.attr(c),e.enable(n.enabled),n.readonly=n.readonly||!!e.element.attr(u),e.readonly(n.readonly)},_aria:function(){var t=this.element,i=this.wrapper,r=t.attr("id"),o=e('label[for="'+r+'"]'),a=t.attr("aria-label"),s=t.attr("aria-labelledby");if(a)i.attr("aria-label",a);else if(s)i.attr("aria-labelledby",s);else if(o.length){var l=o.attr("id");l||(l=(r||n.guid())+"_label",o.attr("id",l)),i.attr("aria-labelledby",l)}},events:[s],options:{name:"Switch",messages:{checked:"On",unchecked:"Off"},width:null,checked:null,enabled:!0,readonly:!1,size:"medium",rounded:"full",trackRounded:"full",thumbRounded:"full"},check:function(e){var n=this,i=n.element[0];if(e===t)return i.checked;i.checked!==e&&(n.options.checked=i.checked=e),n.wrapper.attr("aria-checked",e).toggleClass(l.checked,e).toggleClass(l.unchecked,!e).find("[aria-hidden='true']").removeAttr(p),e?(n.element.attr(f,f),n.wrapper.find(_+l.uncheckedLabel).attr(p,!0)):(n.element.prop(f,!1),n.wrapper.find(_+l.checkedLabel).attr(p,!0))},value:function(e){return"string"==typeof e?e="true"===e:null===e&&(e=!1),this.check.apply(this,[e])},destroy:function(){o.fn.destroy.call(this),this.wrapper.off(r)},toggle:function(){this.check(!this.element[0].checked)},enable:function(e){var t=this.element,n=this.wrapper;void 0===e&&(e=!0),this.options.enabled=e,e?(t.prop(c,!1),n.removeAttr(d)):(t.attr(c,c),n.attr(d,!0)),n.toggleClass(l.disabled,!e)},readonly:function(e){var t=this,n=t.element,i=t.wrapper;void 0===e&&(e=!0),t.options.readonly=e,e?(n.attr(u,!0),i.attr(h,!0)):(n.prop(u,!1),i.removeAttr(h)),i.toggleClass(l.readonly,e)},_check:function(){var e=this,t=e.element[0].checked=!e.element[0].checked;e.wrapper.trigger("focus"),!e.options.enabled||e.options.readonly||e.trigger(s,{checked:t})?e.element[0].checked=!t:e.check(t)},_keydown:function(e){e.keyCode===n.keys.SPACEBAR&&(this._check(),e.preventDefault())},_isTouch:function(e){return/touch/.test(e.type)||e.originalEvent&&/touch/.test(e.originalEvent.pointerType)},_click:function(e){this._isTouch(e)||1!==e.which||(e.target===this.element[0]&&(this.element[0].checked=!this.element[0].checked),this._check())},_touchEnd:function(e){this._isTouch(e)&&(this._check(),e.preventDefault())}});n.cssProperties.registerPrefix("Switch","k-switch-"),n.cssProperties.registerValues("Switch",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),i.plugin(x)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.ui,o=".kendoFloatingLabel",a="k-empty",s="k-focus",l="k-disabled",c="k-readonly",d=i.extend({init:function(r,o){var a=this;i.fn.init.call(a,r,o),o=e.extend(!0,{},o),a.widget=a.options.widget,a.widgetWrapper=a.widget.wrapper[0],a.refresh(),a._editable({readonly:a.options.widget.options.readonly!==t&&a.options.widget.options.readonly,disable:a.options.widget.options.enable!==t&&!a.options.widget.options.enable}),a.widgetWrapper.style.width&&(a.element.css("width",a.widgetWrapper.style.width),a.widgetWrapper.style.width="100%"),a.element.addClass("k-floating-label-container"),n.notify(a)},options:{name:"FloatingLabel",widget:null,floatCheck:({element:e})=>!e.val()},readonly:function(e){this._editable({readonly:e===t||e,disable:!1})},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)})},refresh:function(){var e=this,t=e.element,n=e.options.widget.wrapper.find(".k-input-inner");if(n.length>0){var i=e.element.find("> .k-floating-label").height(),r=n.position().left+Number.parseInt(n.css("padding-left")),o=n.position().top+Number.parseInt(n.css("padding-top"))+i;t[0].style.setProperty("--kendo-floating-label-offset-x",r+"px"),t[0].style.setProperty("--kendo-floating-label-offset-y",o+"px")}t.removeClass(a).removeClass(s),e.options.floatCheck({element:e.options.widget.element,floating:e.element})&&t.addClass(a),(document.activeElement===e.options.widget.element[0]||e.options.widget.input&&document.activeElement===e.options.widget.input[0])&&t.addClass(s)},destroy:function(){this.element.off(o),i.fn.destroy.call(this)},_editable:function(e){var t=this,n=t.element,i=e.disable,r=e.readonly;n.off(o),r||i?n.toggleClass(l,i).toggleClass(c,r):(n.removeClass(l).removeClass(c),n.on("focusin"+o,t.refresh.bind(t)),n.on("focusout"+o,t.refresh.bind(t)))}});r.plugin(d)}(window.kendo.jQuery);kendo;const kh=window.kendo,xh=kh.jQuery,Ch=kh.ui.Widget,Sh=kh.isFunction;var Th=Ch.extend({options:{name:"Label",widget:null},init:function(e,t){var n=this;e=e||xh("<label></label>"),Ch.fn.init.call(n,e,t),t=xh.extend(!0,{},t),n.widget=t.widget,t.floating&&n._floatingLabel(),n._label()},destroy:function(){this.floatingLabel&&this.floatingLabel.destroy(),Ch.fn.destroy.call(this)},_unwrapFloating:function(){var e=this;e.floatingLabel&&(e.floatingLabel.destroy(),e.widget.wrapper.unwrap(e._floatingLabelContainer))},setOptions:function(e){var t=this,n=!1;("string"==typeof e||xh.isPlainObject(e)&&!1===e.floating)&&(n=!0),e=xh.isPlainObject(e)?e:{content:e},Ch.fn.setOptions.call(t,e),n&&t.floatingLabel?(t._unwrapFloating(),t.floatingLabel.destroy(),delete t.floatingLabel):!0!==e.floating||t.floatingLabel||(t.element.remove(),t._floatingLabel()),t._label()},_label:function(){var e=this,t=e.widget.element,n=e.options,i=t.attr("id"),r=n.content,o=n.floating||!1;Sh(r)&&(r=r.call(e)),r||(r=""),i||(i=n.name+"_"+kh.guid(),t.attr("id",i)),e.element.addClass(o?"k-floating-label":"k-label k-input-label").attr("for",i).text(r)[o?"insertAfter":"insertBefore"](e.options.beforeElm||e.widget.wrapper),e.floatingLabel&&e.floatingLabel.refresh()},_floatingLabel:function(){var e=this,t=xh.extend({},e.options);delete t.name,(t.floating||!1)&&(e._floatingLabelContainer=e.widget.wrapper.wrap("<span></span>").parent(),e.floatingLabel=new kh.ui.FloatingLabel(e._floatingLabelContainer,xh.extend({},t)))}});kh.ui.plugin(Th);!function(e){var t=window.kendo,n=t.htmlEncode,i=t.ui.Widget,r=t.ui,o=".kendoActionSheet",a=r.Popup,s=t.keys,l=t.isFunction,c=a.TabKeyTrap,d=e(document.documentElement),u="open",h="close",p="activate",f="deactivate",m=":kendoFocusable:not([tabindex='-1'])",g="k-actionsheet-bottom",v="k-actionsheet-fullscreen",_=`.k-actionsheet-item:not(.${b}),.k-actions .k-button[ref-actionsheet-action-button]:not(.${b})`,b="k-disabled",y="aria-disabled",w="k-hidden",k=t.guid(),x=e.extend,C=t.template,S=/^#([a-fA-F0-9]{6}|[a-fA-F0-9]{3})$/,T=e=>'<div class="k-text-center k-actionsheet-titlebar" >'+(e.title?`<div class="k-actionsheet-titlebar-group k-hbox"><div id="${k}" class="k-actionsheet-title"><div class="k-text-center">${e.title}</div>`+(e.subtitle?`<div class="k-actionsheet-subtitle k-text-center">${e.subtitle||""}</div>`:"")+"</div>"+(e.closeButton?'<div class="k-actionsheet-actions">'+t.html.renderButton(`<button ${t.attr("ref-actionsheet-close-button")}></button>`,{icon:"x",fillMode:"flat",size:"large"})+"</div>":"")+"</div>":"")+"</div>",D=({disabled:e,icon:t,text:i,description:r})=>`<span role="button" tabindex="0" class="k-actionsheet-item ${e?b:""}"><span class="k-actionsheet-action">`+(t?`<span class="k-icon-wrap">${t}</span>`:"")+'<span class="k-actionsheet-item-text">'+`<span class="k-actionsheet-item-title">${n(i)}</span>`+(r?'<span class="k-actionsheet-item-description">'+n(r)+"</span>":"")+"</span></span></span>",A={text:"",description:"",iconClass:"",iconSize:0,iconColor:"",click:e.noop,group:"top",disabled:!1},M={text:"",icon:"",iconClass:"",click:e.noop,disabled:!1};function E(n){var i,r={};return n.iconClass||n.icon?(i=e(t.html.renderIcon({icon:n.icon,iconClass:n.iconClass+" k-actionsheet-item-icon"})),n.iconColor&&S.test(n.iconColor)?r.color=n.iconColor:n.iconColor&&i.addClass("k-text-"+n.iconColor),n.iconSize&&(r.fontSize=n.iconSize+"px"),Object.keys(r).length&&i.css(r),i):""}var I=i.extend({init:function(e,n){var r=this;n=n||{},i.fn.init.call(r,e,n),n.appendTo&&r.element.appendTo(n.appendTo),r._hasItems=n.items&&n.items.length,r._hasActionButtons=n.actionButtons&&n.actionButtons.length,r._mapItems(),r._mapActionButtons(),r._wrapper(),r._popup(),r._createContent(),r._createHeader(),r._createFooter(),r._applyAria(),r._tabKeyTrap=new c(r.wrapper),r.downEvent=t.applyEventMap("down",t.guid()),r.clickEvent=t.applyEventMap("click",t.guid()),r._mousedownProxy=r._mousedown.bind(r),r._clickProxy=r._click.bind(r),r.wrapper.on("keydown"+o,r,r._keydown.bind(r))},events:[u,h,p,f],options:{name:"ActionSheet",title:"",items:[],popup:null,fullscreen:!1,footerTemplate:null,headerTemplate:null,contentTemplate:null,actionButtons:[],closeButton:!1,adaptive:!1,focusOnActivate:!0},_mapItems:function(){var e=this;e._hasItems&&(e.options.items=e.options.items.map(P))},_mapActionButtons:function(){var e=this;e._hasActionButtons&&(e.options.actionButtons=e.options.actionButtons.map(H))},_wrapper:function(){var t,n=this,i=n.element,r=1==n.options.fullscreen?v:g;i.addClass("k-actionsheet "+r+(n.options.adaptive?" k-adaptive-actionsheet":" k-actionsheet-jq")),n.wrapper=t=i.wrap("<div class='k-actionsheet-container "+w+"'></div>").parent(),t.prepend(e("<div></div>").addClass("k-overlay"))},_applyAria:function(){var e=this,t=e.element,n=e.wrapper.find(".k-actionsheet-title").attr("id");t.attr({role:"dialog","aria-modal":!0,"aria-labelledby":e.options.title?n:null})},_popup:function(){var e=this,n=e.options,i=!!n.adaptive&&{open:{effects:"slideIn:up",transition:!0,duration:200}};n.open=null,n.close=null,n.activate=null,n.deactivate=null,e.popup=new a(e.element,x(n.popup,n,{name:"Popup",isRtl:t.support.isRtl(n.anchor),omitOriginOffsets:!0,appendTo:e.wrapper,modal:!0,animation:i,position:"top center",anchor:n.anchor||e.wrapper})),n.focusOnActivate&&e.popup.bind(p,e._openHandler.bind(e)),e.popup.bind(p,(t=>{e.trigger(p,t)})),e.popup.bind(f,(t=>{e.wrapper.addClass(w),d.off(e.downEvent,e._mousedownProxy),d.off(e.clickEvent,e._clickProxy),e.trigger(f,t)})),e.popup.bind(u,(t=>{e.trigger(u,t)})),e.popup.bind(h,(t=>{var n=e._closeButtonPressed;e._closeButtonPressed=!1,e.trigger(h,x({},t,{closeButton:n}))}))},_createHeader:function(){var e=this.options;(e.title||e.headerTemplate)&&this.element.prepend(C(e.headerTemplate||T)(e))},_items:function(){var e=this;if(e._hasItems){var t=e.options.items.reduce(((e,t)=>{const n=t.group||"top";return e[n]=e[n]||[],e[n].push(t),e}),new Map),n=t.top,i=t.bottom;e._createItems(n),n&&n.length&&i&&i.length&&e._content.append('<hr class="k-hr" />'),e._createItems(i)}},_createContent:function(){var t=this,n=t.options;t.element.wrapInner(e("<div class='k-actionsheet-content'></div>"));var i=t._content=t.element.find(".k-actionsheet-content");if(t._hasItems)return i.empty(),void t._items();(n.contentTemplate||n.hideOverflowContent)&&i.addClass("!k-overflow-hidden"),n.contentTemplate&&i.html(C(n.contentTemplate)(n))},_createItems:function(t){var n,i,r,o,a,s=this._content,l=e("<div class='k-list-ul' role='group'></div>");if(t&&t.length)for(s.append(l),r=C(D),n=0;n<t.length;n++)a=E(i=t[n]),o=e(r(x({},i,{icon:a&&a.prop("outerHTML")}))),l.append(o),i.click&&o.data("action",i.click)},_createActionButtons:function(){for(var n,i=this.options.actionButtons,r=this._footer,o=0;o<i.length;o++){var a=i[o],s=!0!==a.disabled;n=e(t.html.renderButton(`<button ref-actionsheet-action-button>${a.text||""}</button>`,e.extend({size:"large"},a))),r.append(n),n.toggleClass(b,!s),n.attr("disabled",!s),s?n.removeAttr(y):n.attr(y,!s),a.click&&n.data("action",a.click)}},_createFooter:function(){var t,n=this,i=n.options;if(n._hasActionButtons||i.footerTemplate){if((t=n._footer=e("<div class='k-actionsheet-footer'></div>")).insertAfter(n._content),n._hasActionButtons)return t.addClass("k-actions k-actions-stretched k-actions-horizontal"),void n._createActionButtons();i.footerTemplate&&n._footer.append(C(i.footerTemplate)(i))}},destroy:function(){var e=this;e.close(),i.fn.destroy.call(e),e._content=null,e._footer=null,e._header=null,e.element.off(o),e.wrapper.off(o),e.popup.destroy()},open:function(e){var t=this;t.altTarget=e&&e.altTarget,t.wrapper.removeClass(w),t._elementHeight=t._elementHeight||t.element.outerHeight(),t.options.adaptive&&t.wrapper.width("100%"),t.popup.open("auto",0),t.popup.wrapper.find(">.k-child-animation-container").css({bottom:0,width:"100%"}),d.off(t.downEvent,t._mousedownProxy).on(t.downEvent,t._mousedownProxy),d.off(t.clickEvent,t._clickProxy).on(t.clickEvent,t._clickProxy),t._tabKeyTrap.trap()},visible:function(){return this.popup.visible()},toggle:function(){this.visible()?this.close():this.open()},fullscreen:function(e){var t=this;t.element.toggleClass(v,!0===e),t.element.toggleClass(g,!0!==e),t.element.closest(".k-child-animation-container").css({height:e?"100%":"auto"})},close:function(){this.popup.close()},position:e.noop,_focusFirstFocusableElement:function(){var e=this.element.find(m).first();e.length&&e.trigger("focus")},_focusLastFocusableElement:function(){var e=this.element.find(m).last();e.length&&e.trigger("focus")},_openHandler:function(){var e=this;if(e._hasItems){var t=e._content.find(".k-actionsheet-item")[0];t&&t.focus()}else e._focusFirstFocusableElement()},_isActionableButton:function(t){return e(t).closest(_).length>0},_triggerAction:function(t){var n=e(t.target).closest(_).data("action");l(n)&&n(t),t.isDefaultPrevented()||this.close()},_keydown:function(n){var i=this,r=t.keys,o=n.keyCode,a=e(n.target);if(o==r.ESC)n.stopPropagation(),i.close();else if(i._isActionableButton(a)&&z(n))i._triggerAction(n);else if(n.keyCode===t.keys.TAB){var s=this.wrapper.find(m),l=s.first(),c=s.last();n.shiftKey?document.activeElement===l[0]&&(c.trigger("focus"),n.preventDefault()):document.activeElement===c[0]&&(l.trigger("focus"),n.preventDefault())}},_click:function(e){var n=t.eventTarget(e);this._isActionableButton(n)&&this._triggerAction(e)},_mousedown:function(n){var i=this,r=i.element[0],o=t.eventTarget(n);i.altTarget&&i.altTarget.is(e(o))||(!function(t,n){return!(!t||!n)&&(t===n||e.contains(t,n))}(r,o)||e(o).closest(`[${t.attr("ref-actionsheet-close-button")}]`,e(r).find("k-actionsheet-titlebar")).length>0)&&(i._closeButtonPressed=!0,i.close())}});function z(e){return e.keyCode==s.ENTER||e.keyCode==s.SPACEBAR}function P(e){return x({},A,e)}function H(e){return x({},M,e)}r.plugin(I)}(window.kendo.jQuery);kendo;let Dh=kendo.jQuery;const Ah="k-loading",Mh="k-input-inner",Eh="aria-busy";function Ih(){const e=this,t=Dh("<span></span>").addClass("k-icon k-i-loading k-input-loading-icon").attr("role","presentation");e._loading=t,e._showBusy=Hh.bind(e),e._hideBusy=Fh.bind(e),e._toggleLoader=zh.bind(e),e._showBusyHandler=Ph.bind(e)}function zh(e){const t=this,n=t.wrapper.hasClass(Ah),i=t.wrapper.find(".k-input-values"),r="multiselect"===t.options.name.toLowerCase();if(t._loading)if(e&&!n)if(t.wrapper.addClass(Ah),t._suffixContainer){const e=t.wrapper.find(".k-input-separator");Dh(e[e.length-1]).before(t._loading)}else if(t._arrow)t._arrow.before(t._loading);else if(i.length>0&&r)t._loading.insertAfter(i);else{const e=t.element.hasClass(Mh)?t.element:t.wrapper.find(`.${Mh}`);t._loading.insertAfter(e)}else n&&(t.wrapper.removeClass(Ah),t._loading.remove())}function Ph(){const e=this;if(e._focused)e._focused.attr(Eh,!0);else{(e.element.hasClass(Mh)?e.element:e.wrapper.find(`.${Mh}`)).attr(Eh,!0)}e._toggleLoader(!0),e._hideClear()}function Hh(e){const t=this;e&&e.isDefaultPrevented()||(t._request=!0,t._busy||(t._busy=setTimeout(t._showBusyHandler,100)))}function Fh(){const e=this;if(clearTimeout(e._busy),e._toggleLoader(!1),e._busy=null,e._request&&(e._request=!1),e._focused)e._focused.attr(Eh,!1);else{(e.element.hasClass(Mh)?e.element:e.wrapper.find(`.${Mh}`)).attr(Eh,!0)}e._toggleCloseVisibility?e._toggleCloseVisibility():e._showClear()}!function(e,t){var n=window.kendo,i=n.ui,r=n._outerHeight,o=/^\d+(\.\d+)?%$/i,a=i.Widget,s=n.keys,l=n.support,c=n.htmlEncode,d=n._activeElement,u=n._outerWidth,h=n.data.ObservableArray,p="id",f="change",m="k-focus",g="k-hover",v="k-selected",_="k-list-ul",b=".k-list-group-sticky-header",y=".k-list-item",w="open",k="close",x="cascade",C="select",S="click",T="mouseenter",D="activate",A="deactivate",M="dataBinding",E="dataBound",I="selectedItemChange",z="selected",P="requestStart",H="requestEnd",F="focus",R=e.extend,L=Array.isArray,B=l.browser,O="k-hidden",V="width",N="text",$=B.msie,U=/"/g,W={ComboBox:["DropDownList","MultiColumnComboBox"],DropDownList:["ComboBox","MultiColumnComboBox"],MultiColumnComboBox:["ComboBox","DropDownList"]},j="aria-labelledby",q="aria-label",G="aria-activedescendant",K="aria-expanded",Y="aria-hidden",Q="aria-selected",X=".k-table-group-row",Z=n.ui.DataBoundWidget.extend({init:function(t,i){var r,o=this;a.fn.init.call(o,t,i),t=o.element,i=o.options,o._isSelect=t.is(C),o._isSelect&&o.element[0].length&&(i.dataSource||(i.dataTextField=i.dataTextField||N,i.dataValueField=i.dataValueField||"value")),"auto"===i.adaptiveMode&&(o.largeMQL=n.mediaQuery("large"),o.mediumMQL=n.mediaQuery("medium"),o.smallMQL=n.mediaQuery("small")),o._bindLoader(),o._listSize=n.cssProperties.getValidClass({widget:"List",propName:"size",value:i.size}),o._filterHeader(),o.ul=e('<ul unselectable="on"/>').attr({tabIndex:-1,"aria-hidden":!0}),o.list=e("<div class='k-list'/>").addClass(o._listSize).append(o.ul),(r=t.attr(p))||(r=n.guid()),o.list.attr(p,r+"-list"),o.ul.attr(p,r+"_listbox"),i.columns&&i.columns.length&&(o.list.removeClass("k-list").addClass("k-data-table"),o.list.removeClass(o._listSize).addClass("k-table-md"),o.ul.removeClass(_).addClass("k-table"),o._columnsHeader()),o._header(),o._noData(),o._footer(),o._accessors(),o._initValue()},options:{valuePrimitive:!1,footerTemplate:"",headerTemplate:"",noDataTemplate:!0,size:"medium",messages:{noData:"No data found.",clear:"clear"},adaptiveMode:"none"},setOptions:function(e){a.fn.setOptions.call(this,e),e&&e.enable!==t&&(e.enabled=e.enable),e.columns&&e.columns.length&&this._columnsHeader(),this._header(),this._noData(),this._footer(),this._renderFooter(),this._renderNoData(),e.label&&this._inputLabel?this.label.setOptions(e.label):!1===e.label?(this.label._unwrapFloating(),this._inputLabel.remove(),delete this._inputLabel):e.label&&this._label()},_bindLoader:function(){const e=this;e._initLoader=Ih.bind(e),e._initLoader()},focus:function(){this._focused.trigger(F)},readonly:function(e){this._editable({readonly:e===t||e,disable:!1}),this.label&&this.label.floatingLabel&&this.label.floatingLabel.readonly(e===t||e)},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)}),this.label&&this.label.floatingLabel&&this.label.floatingLabel.enable(e=e===t||e)},_label:function(){var t=this,i=t.options,r=e.isPlainObject(i.label)?i.label:{content:i.label};t.label=new n.ui.Label(null,e.extend({},r,{widget:t,floatCheck:t._floatCheck.bind(t)})),t._inputLabel=t.label.element,t._refreshFloatingLabel()},_floatCheck:function(){return!this.listView||!(this.value()||!!this.text&&this.text())&&!this.popup.visible()},_refreshFloatingLabel:function(){var e=this;e.label&&e.label.floatingLabel&&e.label.floatingLabel.refresh()},_header:function(){var t=this,i=e(t.header),r=t.options.headerTemplate;if(n.destroy(i),i.remove(),r){var o="function"!=typeof r?n.template(r):r;i=e(o({})),t.header=i[0]?i:null,t.list.parent.length>0&&t.list.before(i)}else t.header=null},_filterHeader:function(){this.filterTemplate='<div class="k-list-filter"><span class="k-searchbox k-input k-input-md k-rounded-md k-input-solid" type="text" autocomplete="off">'+n.ui.icon({icon:"search",iconClass:"k-input-icon"})+"</span></div>",this.actionSheetFilterTemplate=`<div class="k-actionsheet-titlebar-group k-actionsheet-filter">${this.filterTemplate}</div>`,this._isFilterEnabled()&&(this.filterInput=e('<input class="k-input-inner" type="text" />').attr({placeholder:this.element.attr("placeholder"),title:this.options.filterTitle||this.element.attr("title"),role:"searchbox","aria-label":this.options.filterTitle,"aria-haspopup":"listbox","aria-autocomplete":"list"}))},_columnsHeader:function(){var t,i=this,r=e(i.columnsHeader);n.destroy(r),r.remove();for(var a="<div class='k-table-header'><div class='k-table-header-wrap'><table class='k-table' role='presentation'>",s="<colgroup>",l="<tr class='k-table-row'>",c=0;c<this.options.columns.length;c++){var d=this.options.columns[c],u=d.title||d.field||"",h=d.headerTemplate||(()=>u),p="function"!=typeof h?n.template(h):h,f=d.width,m=parseInt(f,10),g="";f&&!isNaN(m)&&(g+=`${n.attr("style-width")}="${m}${o.test(f)?"%":"px"}"`),s+="<col "+g+"/>",l+="<th class='k-table-th'>",l+=p(d),l+="</th>"}a+=s+="</colgroup>",a+="<thead class='k-table-thead'>",a+=l+="</tr>",t=e(a+="</thead></table></div></div>"),n.applyStylesFromKendoAttributes(t,["width"]),i.columnsHeader=r=t,i.list.prepend(r)},_noData:function(){var t=this,i=e(t.noData),r=!0===t.options.noDataTemplate?()=>c(t.options.messages.noData):t.options.noDataTemplate;n.destroy(i),i.remove(),r?(t.noData=e('<div class="k-no-data"></div>').hide().appendTo(t.list),t.noDataTemplate="function"!=typeof r?n.template(r):r):t.noData=null},_footer:function(){var t=this,i=e(t.footer),r=t.options.footerTemplate,o=this.options.columns&&this.options.columns.length?'<div class="k-table-footer"><span class="k-table-td"></span></div>':'<div class="k-list-footer"></div>';n.destroy(i),i.remove(),r?(t.footer=e(o).appendTo(t.list),t.footerTemplate="function"!=typeof r?n.template(r):r):t.footer=null},_listOptions:function(t){var i=this,r=i.options,o=r.virtual,a={change:i._listChange.bind(i)},s=i._listBound.bind(i),l=i._focused,d=i.element.attr("id"),u=e('label[for="'+i.element.attr("id")+'"]'),h=l.attr(j);return!h&&u.length&&(h=u.attr("id")||i._generateLabelId(u,d||n.guid())),o="object"==typeof o?o:{},(t=e.extend({autoBind:!1,selectable:!0,dataSource:i.dataSource,click:i._click.bind(i),activate:i._activateItem.bind(i),columns:r.columns,deactivate:i._deactivateItem.bind(i),dataBinding:function(){i.trigger(M)},dataBound:s,height:r.height,dataValueField:r.dataValueField,dataTextField:r.dataTextField,groupTemplate:r.groupTemplate,fixedGroupTemplate:r.fixedGroupTemplate,template:r.template,ariaLabel:l.attr(q),ariaLabelledBy:h,listSize:i._listSize},t,o,a)).template||(t.template=e=>c(n.getter(t.dataTextField)(e))),t},_initList:function(e){var t=this,i=e&&e.skipValueUpdate,r=t._listOptions({selectedItemChange:t._listChange.bind(t)});t.options.virtual?(t.listView=new n.ui.VirtualList(t.ul,Object.assign(r,{height:t._hasActionSheet()?362:t.options.height})),t.list.addClass("k-virtual-list")):t.listView=new n.ui.StaticList(t.ul,r),t.listView.bind("listBound",t._listBound.bind(t)),i||t._setListValue()},_setListValue:function(e){(e=e||this.options.value)!==t&&this.listView.value(e).done(this._updateSelectionState.bind(this))},_updateSelectionState:e.noop,_listMousedown:function(e){this.filterInput&&this.filterInput[0]===e.target||e.preventDefault()},_isFilterEnabled:function(){var e=this.options.filter;return e&&"none"!==e},_hideClear:function(){this._clear&&this._clear.addClass(O)},_showClear:function(){this._clear&&this._clear.removeClass(O)},_clearValue:function(){this._clearText(),this._accessor(""),this.listView.value([]),this._isSelect&&(this._customOption=t),this._isFilterEnabled()&&!this.options.enforceMinLength&&(this._filter({word:"",open:!1}),this.options.highlightFirst&&this.listView.focus(0)),this._change()},_clearText:function(){this.text("")},_clearFilter:function(){this.options.virtual||this.listView.bound(!1),this._filterSource()},_filterSource:function(t,n){var i=this,r=i.options,o=r.filterFields&&t&&t.logic&&t.filters&&t.filters.length,a=i.dataSource,s=R({},a.filter()||{}),l=t||s.filters&&s.filters.length&&!t,c=oe(s,r.dataTextField);if(this._clearFilterExpressions(s),(t||c)&&i.trigger("filtering",{filter:t}))return e.Deferred().reject().promise();var d={filters:[],logic:"and"};o?d.filters.push(t):this._pushFilterExpression(d,t),re(s)&&(d.logic===s.logic?d.filters=d.filters.concat(s.filters):d.filters.push(s)),i._cascading&&this.listView.setDSFilter(d);var u=R({},{page:l?1:a.page(),pageSize:l?a.options.pageSize:a.pageSize(),sort:a.sort(),filter:a.filter(),group:a.group(),aggregate:a.aggregate()},{filter:d});return a[n?"read":"query"](a._mergeState(u))},_pushFilterExpression:function(e,t){re(t)&&""!==t.value&&e.filters.push(t)},_clearFilterExpressions:function(e){if(e.filters){for(var t,n=0;n<e.filters.length;n++)"fromFilter"in e.filters[n]&&(t=n);isNaN(t)||e.filters.splice(t,1)}},_renderNoData:function(){var e=this,t=e.noData;t&&t.html(e.noDataTemplate({instance:e}))},_toggleNoData:function(t){e(this.noData).toggle(t)},_toggleHeader:function(e){this.listView.content.prev(b).toggle(e)},_renderFooter:function(){var e=this,t=e.footer?this.options.columns&&this.options.columns.length?e.footer.children().first():e.footer:null;t&&t.html(e.footerTemplate({instance:e}))},_allowOpening:function(){return this.options.noDataTemplate||this.dataSource.flatView().length},_initValue:function(){var e=this,t=e.options.value;null!==t?e.element.val(t):(t=e._accessor(),e.options.value=t),e._old=t},_ignoreCase:function(){var e,t=this,n=t.dataSource.reader.model;n&&n.fields&&(e=n.fields[t.options.dataTextField])&&e.type&&"string"!==e.type&&(t.options.ignoreCase=!1)},_focus:function(e){return this.listView.focus(e)},_filter:function(e){var t,n=this,i=n.options,r=e.word,o=i.filterFields,a=i.dataTextField;if(o&&o.length){t={logic:"or",filters:[],fromFilter:!0};for(var s=0;s<o.length;s++)this._pushFilterExpression(t,n._buildExpression(r,o[s]))}else t=n._buildExpression(r,a);n._open=e.open,n._filterSource(t)},_buildExpression:function(e,t){var n=this.options,i=n.ignoreCase,r=this.dataSource.options.accentFoldingFiltering;return{value:i?r?e.toLocaleLowerCase(r):e.toLowerCase():e,field:t,operator:n.filter,ignoreCase:i}},_clearButton:function(){var t=this,i=t.options.messages.clear;t._clear||(t._clear=e(`<span unselectable="on" class="k-clear-value" title="${i}">${n.ui.icon("x")}</span>`).attr({role:"button",tabIndex:-1})),t.options.clearButton||t._clear.remove(),this._hideClear()},search:function(e){var t=this.options;e="string"==typeof e?e:this._inputValue(),clearTimeout(this._typingTimeout),(!t.enforceMinLength&&!e.length||e.length>=t.minLength)&&(this._state="filter",this.listView&&(this.listView._emptySearch=!n.trim(e).length),this._isFilterEnabled()?this._filter({word:e,open:!0}):this._searchByWord(e))},current:function(e){return this._focus(e)},items:function(){return this.ul[0].children},destroy:function(){var e=this,t=e.ns;a.fn.destroy.call(e),e._unbindDataSource(),(e.largeMQL||e.mediumMQL||e.smallMQL)&&(e.largeMQL.destroy(),e.mediumMQL.destroy(),e.smallMQL.destroy()),e.listView.destroy(),e.list.off(t),e.popup.destroy(),e._form&&e._form.off("reset",e._resetHandler),e.label&&e.label.destroy()},dataItem:function(n){var i=this;if(n===t)return i.listView.selectedDataItems()[0];if("number"!=typeof n){if(i.options.virtual)return i.dataSource.getByUid(e(n).data("uid"));n=e(i.items()).index(n)}return i.dataSource.flatView()[n]},_activateItem:function(){var e=this.listView.focus();e&&this.popup.visible()&&this._focused.add(this.filterInput).attr(G,e.attr("id"))},_deactivateItem:function(){this._focused.add(this.filterInput).removeAttr(G)},_accessors:function(){var e=this,t=e.element,i=e.options,r=n.getter,o=t.attr(n.attr("text-field")),a=t.attr(n.attr("value-field"));!i.dataTextField&&o&&(i.dataTextField=o),!i.dataValueField&&a&&(i.dataValueField=a),e._text=r(i.dataTextField),e._value=r(i.dataValueField)},_aria:function(e){var n,i=this,r=i.options,o=i._focused;r.suggest!==t&&(n="none"===r.filter?!0===r.suggest?"inline":"none":!0===r.suggest?"both":"list",o.attr("aria-autocomplete",n)),e=e?e+" "+i.ul[0].id:i.ul[0].id,o.attr({"aria-controls":e}),i.filterInput&&i.filterInput.length>0&&i.filterInput.attr("aria-controls",e),i.ul.attr("aria-live",i._isFilterEnabled()?"polite":"off"),i._ariaLabel(i._focused)},_blur:function(){var e=this;e._change(),e.close(),e._userTriggered=!1},_isValueChanged:function(e){return e!==J(this._old,typeof e)},_change:function(){var e,n=this,i=n.selectedIndex,r=n.options.value,o=n.value();n._isSelect&&!n.listView.bound()&&r&&(o=r),n._isValueChanged(o)||n._valueBeforeCascade!==t&&n._isValueChanged(n._valueBeforeCascade)&&n._userTriggered?e=!0:i===t||i===n._oldIndex||n.listView.isFiltered()||n.options.virtual||(e=!0),e&&(null===n._old||""===n._old||""===o?n._valueBeforeCascade=n._old=o:n.dataItem()?n._valueBeforeCascade=n._old=n.options.dataValueField?n.dataItem()[n.options.dataValueField]:n.dataItem():n._valueBeforeCascade=n._old=null,n._oldIndex=i,n._typing||n.element.trigger(f),n.trigger(f)),n.typing=!1},_data:function(){return this.dataSource.view()},_enable:function(){var e=this,n=e.options,i=e.element.is("[disabled]");n.enable!==t&&(n.enabled=n.enable),!n.enabled||i?e.enable(!1):e.readonly(e.element.is("[readonly]"))},_dataValue:function(e){var n=this._value(e);return n===t&&(n=this._text(e)),n},_offsetHeight:function(){var t=0;return this.listView.content.parent().prevAll(":visible").each((function(){var n=e(this);t+=r(n,!0)})),t},_height:function(t){var n,i=this,o=i.list,a=i.options.height,s=i.popup.visible(),l=this.options.columns&&this.options.columns.length;if(t||i.options.noDataTemplate){if(n=o.parent().add(o.closest(".k-animation-container").add(o.closest(".k-child-animation-container"))).show(),!o.parent().is(":visible"))return void n.hide();a=i.listView.content[0].scrollHeight>a?a:"auto",n.height(a),"auto"!==a&&(a-=i._offsetHeight(),l&&(a=a-(r(e(i.footer))||0)-(r(e(i.columnsHeader))||0))),l?i.listView.content.outerHeight(a):i.listView.content.parent().outerHeight(a),s||o.parent().hide()}return a},_openHandler:function(e){var t;this._adjustListWidth(),this.trigger(w)?e.preventDefault():(this._focused.attr(K,!0),this.ul.attr(Y,!1),(t=this.listView.focus())&&this._focused.add(this.filterInput).attr(G,t.attr("id")))},_adjustListWidth:function(){var e,t,n=this,i=n.list.parent(),r=i[0].style.width,o=n.wrapper;if(!(!i.data(V)&&r||n._hasActionSheet()))return e=window.getComputedStyle?window.getComputedStyle(o[0],null):0,t=parseFloat(e&&e.width)||u(o),e&&B.msie&&(t+=parseFloat(e.paddingLeft)+parseFloat(e.paddingRight)+parseFloat(e.borderLeftWidth)+parseFloat(e.borderRightWidth)),r="border-box"!==i.css("box-sizing")?t-(u(i)-i.width()):t,i.css({fontFamily:o.css("font-family"),width:n.options.autoWidth?"auto":r,minWidth:r,whiteSpace:n.options.autoWidth?"nowrap":"normal"}).data(V,r),!0},_closeHandler:function(e){e.closeButton&&this._onCloseButtonPressed(),this.trigger(k)?e.preventDefault():(this._focused.attr(K,!1),this.ul.attr(Y,!0),this._focused.add(this.filterInput).removeAttr(G))},_focusItem:function(){var e=this.listView,n=!e.focus(),i=ne(e.select());i===t&&this.options.highlightFirst&&n&&(i=0),i!==t?e.focus(i):n&&e.scrollToIndex(0)},_calculateGroupPadding:function(e){var t=this.ul.children(".k-first").first(),i=this.listView.content.prev(b),r=0,o="right";i[0]&&"none"!==i[0].style.display&&("auto"!==e&&(r=n.support.scrollbar()),this.element.parents(".k-rtl").length&&(o="left"),r+=parseFloat(t.css("border-"+o+"-width"),10)+parseFloat(t.children(".k-list-item-group-label").css("padding-"+o),10),i.css("padding-"+o,r))},_calculatePopupHeight:function(e){var t=this._height(this.dataSource.flatView().length||e);this._calculateGroupPadding(t),this._calculateColumnsHeaderPadding(t)},_calculateColumnsHeaderPadding:function(e){if(this.options.columns&&this.options.columns.length){var t=l.isRtl(this.wrapper),i=n.support.scrollbar();this.columnsHeader.css(t?"padding-left":"padding-right","auto"!==e?i:0)}},_refreshScroll:function(){var e=this.listView,t=e.element.height()>e.content.height();this.options.autoWidth&&e.content.css({overflowX:"hidden",overflowY:t?"scroll":"auto"})},_hasActionSheet:function(){return"auto"===this.options.adaptiveMode&&(this.mediumMQL.mediaQueryList.matches||this.smallMQL.mediaQueryList.matches)},_resizePopup:function(e){this.options.virtual||this._hasActionSheet()||(this.popup.element.is(":visible")?this._calculatePopupHeight(e):(this.popup.one("open",function(e){return function(t){t.isDefaultPrevented()||this._calculatePopupHeight(e)}.bind(this)}.call(this,e)),this.popup.one(D,this._refreshScroll.bind(this))))},_popup:function(){var e=this;e.list.wrap("<div>"),"auto"===e.options.adaptiveMode?(e.largeMQL.onEnter(e._createPopup.bind(e)),e.mediumMQL.onEnter(e._createActionSheet.bind(e)),e.smallMQL.onEnter((()=>{e.popup&&e.popup.fullscreen||e._createActionSheet(),e.popup.fullscreen(!0)}))):e._createPopup()},_addFilterHeader:function(){var t=this;t._isFilterEnabled()&&(t._filterHeader(),"auto"===t.options.adaptiveMode&&(t.mediumMQL.mediaQueryList.matches||t.smallMQL.mediaQueryList.matches)?(t.popup.element.find(".k-actionsheet-titlebar").append(e(t.actionSheetFilterTemplate)).find(".k-searchbox").append(t.filterInput),t._enable()):t.options.popupFilter&&t.list.parent().prepend(e(t.filterTemplate)).find(".k-searchbox").append(t.filterInput),t._enable())},_createPopup:function(){var e=this;e.popup&&(e._cachedFilterValue=e.filterInput?e.filterInput.val():null,e.popup.destroy(),e._removeFilterHeader(),e._removeStaticHeader()),e.popup=new i.Popup(e.list.parent().addClass("k-list-container"),R({},e.options.popup,{anchor:e.wrapper,open:e._openHandler.bind(e),close:e._closeHandler.bind(e),animation:e.options.animation,isRtl:l.isRtl(e.wrapper),autosize:e.options.autoWidth,autowidth:e.options.autoWidth,activate:()=>{this._refreshFloatingLabel()},deactivate:()=>{this._refreshFloatingLabel()}})),e._postCreatePopup()},_onActionSheetCreate:e.noop,_onCloseButtonPressed:e.noop,_createActionSheet:function(){var e=this;e.popup&&(e._cachedFilterValue=e.filterInput?e.filterInput.val():null,e.popup.destroy(),e._removeFilterHeader(),e._removeStaticHeader(),e.list.parent().css({width:"",height:"",minWidth:""})),e.popup=new i.ActionSheet(e.list.parent(),{headerTemplate:t=>'<div class="k-text-center k-actionsheet-titlebar" ><div class="k-actionsheet-titlebar-group k-hbox"><div  class="k-actionsheet-title">'+(e.options.label?`<div class="k-text-center">${e.options.label}</div>`:"")+(e.options.placeholder?`<div class="k-actionsheet-subtitle k-text-center">${e.options.placeholder||""}</div>`:"")+"</div>"+(t.closeButton?'<div class="k-actionsheet-actions">'+n.html.renderButton(`<button tabindex="-1" ${n.attr("ref-actionsheet-close-button")}></button>`,{icon:"x",fillMode:"flat",size:"large"})+"</div>":"")+"</div></div>",open:e._openHandler.bind(e),close:e._closeHandler.bind(e),focusOnActivate:!1,adaptive:!0,appendTo:e.options.popup&&e.options.popup.appendTo||document.body,closeButton:!0,fullscreen:e.smallMQL.mediaQueryList.matches,activate:()=>{this._refreshFloatingLabel()},deactivate:()=>{this._refreshFloatingLabel()},popup:R({},e.options.popup,{autosize:e.options.autoWidth})}),e._postCreatePopup(),e._onActionSheetCreate()},_removeFilterHeader:function(){this.filterInput&&(this.filterInput.off(this.ns).closest(".k-list-filter").remove(),this.filterInput=null)},_removeStaticHeader:function(){this.listView.header.remove()},_postCreatePopup:function(){var e,t=this;t._addFilterHeader(),t.filterInput&&t._cachedFilterValue&&t.filterInput.val(t._cachedFilterValue),t.popup.element.prepend(t.header).on("mousedown"+this.ns,this._listMousedown.bind(this)),t.listView&&(e=t.listView.value(),t.listView._clean&&t.listView._clean(),t.tagList&&t.options.virtual&&t.tagList.empty(),t.listView.destroy(),t._initList({skipValueUpdate:!0}),t.listView.value(e))},_toggleHover:function(t){e(t.currentTarget).toggleClass(g,t.type===T)},_toggle:function(e,n){var i=this,r=l.mobileOS&&(l.touch||l.MSPointers||l.pointers);e=e!==t?e:!i.popup.visible(),n||r||i._focused[0]===d()||(i._prevent=!0,i._focused.trigger(F),i._prevent=!1),i[e?w:k]()},_triggerCascade:function(){var e=this;e._cascadeTriggered&&e.value()===J(e._cascadedValue,typeof e.value())||(e._cascadedValue=e.value(),e._cascadeTriggered=!0,e.trigger(x,{userTriggered:e._userTriggered}))},_triggerChange:function(){this._valueBeforeCascade!==this.value()&&this.trigger(f)},_unbindDataSource:function(){var e=this;e.dataSource.unbind(P,e._requestStartHandler).unbind(H,e._requestEndHandler).unbind("error",e._errorHandler)},requireValueMapper:function(e,t){if(((e.value instanceof Array?e.value.length:e.value)||(t instanceof Array?t.length:t))&&e.virtual&&"function"!=typeof e.virtual.valueMapper)throw new Error("ValueMapper is not provided while the value is being set. See http://docs.telerik.com/kendo-ui/controls/editors/combobox/virtualization#the-valuemapper-function")}});function J(e,n){return e!==t&&""!==e&&null!==e&&("boolean"===n?("boolean"!=typeof e&&(e="true"===e.toString().toLowerCase()),e=Boolean(e)):"number"===n?e=Number(e):"string"===n&&(e=e.toString())),e}R(Z,{inArray:function(e,t){var n,i,r=t.children;if(!e||e.parentNode!==t)return-1;for(n=0,i=r.length;n<i;n++)if(e===r[n])return n;return-1},unifyType:J}),n.ui.List=Z,i.Select=Z.extend({init:function(e,t){Z.fn.init.call(this,e,t),this._initial=this.element.val()},setDataSource:function(e){var t,n=this;n.options.dataSource=e,n._dataSource(),n.listView.bound()&&(n._initialIndex=null,n.listView._current=null),n.listView.setDataSource(n.dataSource),n.options.autoBind&&n.dataSource.fetch(),(t=n._parentWidget())&&n._cascadeSelect(t)},close:function(){this.popup.close()},select:function(e){var n=this;return e===t?n.selectedIndex:n._select(e).done((function(){n._cascadeValue=n._old=n._accessor(),n._oldIndex=n.selectedIndex,n._refreshFloatingLabel()}))},_accessor:function(e,t){return this[this._isSelect?"_accessorSelect":"_accessorInput"](e,t)},_accessorInput:function(e){var n=this.element[0];if(e===t)return n.value;null===e&&(e=""),n.value=e},_accessorSelect:function(e,n){var i=this.element[0];if(e===t)return ie(i).value||"";ie(i).selected=!1,n===t&&(n=-1),null!==e&&""!==e&&-1==n?this._custom(e):e?i.value=e:i.selectedIndex=n},_syncValueAndText:function(){return!0},_custom:function(t){var n=this,i=n.element,r=n._customOption;r||(r=e("<option/>"),n._customOption=r,i.append(r)),r.text(t),r[0].selected=!0},_dataSource:function(){var e,t=this,i=t.element,r=t.options,o=r.dataSource||{};o=Array.isArray(o)?{data:o}:o,t._isSelect&&((e=i[0].selectedIndex)>-1&&(r.index=e),o.select=i,o.fields=[{field:r.dataTextField},{field:r.dataValueField}]),t.dataSource?t._unbindDataSource():(t._requestStartHandler=t._showBusy,t._requestEndHandler=t._hideBusy,t._errorHandler=function(){t._hideBusy()}),t.dataSource=n.data.DataSource.create(o).bind(P,t._requestStartHandler).bind(H,t._requestEndHandler).bind("error",t._errorHandler)},_firstItem:function(){this.listView.focusFirst()},_lastItem:function(){this.listView.focusLast()},_nextItem:function(){return this.listView.focusNext()},_prevItem:function(){return this.listView.focusPrev()},_getNormalizedDataItem:function(e){var t,n=this,i=n.listView,r="number"==typeof e,o=n.optionLabel&&n.optionLabel.length;return t=r?o?--e:e:i.getElementIndex(e),i.dataItemByIndex(t)},_getNormalizedSelectCandidate:function(e){var t=e;return this.optionLabel&&this.optionLabel.length&&"number"==typeof e&&t++,t},_move:function(e){var t,n,i,r,o,a=this,l=a.listView,c=e.keyCode,u=c===s.DOWN,h=a.options.virtual;if(c===s.UP||u){if(e.altKey)a.toggle(u);else{if(!l.bound()&&!a.ul[0].firstChild)return a._fetch||(a.dataSource.one(f,(function(){a._fetch=!1,a._move(e)})),a._fetch=!0,a._filterSource()),e.preventDefault(),!0;i=a._focus(),a._fetch||i&&!i.hasClass(v)||(u?(r=a._nextItem(),(h&&r<=0||!a._focus()&&!r)&&a._lastItem()):(r=a._prevItem(),(h&&r>=l.dataSource.total()-1||!a._focus()&&!r)&&a._firstItem())),o=a._getNormalizedSelectCandidate(a._get(a._focus())||r||0),a._select(o,!0).done((function(){var e=function(){a.popup.visible()||a._blur(),null===a._cascadedValue?a._cascadedValue=a.value():a._cascadedValue=a.dataItem()?a.dataItem()[a.options.dataValueField]||a.dataItem():null};a.trigger(C,{dataItem:a._getNormalizedDataItem(o),item:a._focus()})?a._select(i).done(e):e()}))}e.preventDefault(),n=!0}else if(c===s.ENTER||c===s.TAB){a.popup.visible()&&e.preventDefault(),i=a._focus(),t=a.dataItem(),a.popup.visible()||t&&a.text()===a._text(t)||(i=null);var p,m=a.filterInput&&a.filterInput[0]===d();if(i){var g=!0;if((t=l.dataItemByIndex(l.getElementIndex(i)))&&(g=a._value(t)!==Z.unifyType(a.value(),typeof a._value(t))),g&&a.trigger(C,{dataItem:t,item:i}))return;p=a._select(i)}else a.input&&((a._syncValueAndText()||a._isSelect)&&a._accessor(a.input.val()),a.listView.value(a.input.val()));a._focusElement&&a._focusElement(a.wrapper),m&&c===s.TAB?a.wrapper.focusout():p&&"function"==typeof p.done?p.done((function(){a._blur()})):a._blur(),a.close(),n=!0}else if(c===s.ESC)a.popup.visible()&&(e.preventDefault(),e.stopPropagation()),a.close(),n=!0;else if(a.popup.visible()&&(c===s.PAGEDOWN||c===s.PAGEUP)){e.preventDefault();var _=c===s.PAGEDOWN?1:-1;l.scrollWith(_*l.screenHeight()),n=!0}return n},_fetchData:function(){var e=this,t=!!e.dataSource.view().length;e._request||e.options.cascadeFrom||e.listView.bound()||e._fetch||t||(e._fetch=!0,e.dataSource.fetch().done((function(){e._fetch=!1})))},_options:function(e,n,i){var r,o,a,s,l=this,d=l.element,u=d[0],h=e.length,p="",f=0;for(n&&(p=n);f<h;f++)r="<option",o=e[f],a=l._text(o),(s=l._value(o))!==t&&(-1!==(s+="").indexOf('"')&&(s=s.replace(U,"&quot;")),r+=' value="'+s+'"'),r+=">",a!==t&&(r+=c(a)),p+=r+="</option>";d.html(p),i!==t&&(u.value=i,u.value&&!i&&(u.selectedIndex=-1)),-1!==u.selectedIndex&&(r=ie(u))&&r.setAttribute(z,z)},_reset:function(){var t=this,n=t.element,i=n.attr("form"),r=i?e("#"+i):n.closest("form");r[0]&&(t._resetHandler=function(){setTimeout((function(){t.options._removeDataItems&&(t.listView._dataItems=[]),t.value(t._initial),t.options._shouldRefresh&&(t.text(t._initial),t.refresh())}))},t._form=r.on("reset",t._resetHandler))},_parentWidget:function(){var t=this.options.name;if(this.options.cascadeFrom){var n=e("#"+this.options.cascadeFrom),i=n.data("kendo"+t);if(!i)for(var r=0;r<W[t].length&&!(i=n.data("kendo"+W[t][r]));r+=1);return i}},_cascade:function(){var e,t=this,n=t.options;if(n.cascadeFrom){if(!(e=t._parentWidget()))return;t._cascadeHandlerProxy=t._cascadeHandler.bind(t),t._cascadeFilterRequests=[],n.autoBind=!1,e.bind("set",(function(){t.one("set",(function(e){t._selectedValue=e.value||t._accessor()}))})),e.first(x,t._cascadeHandlerProxy),e.listView.bound()?(t._toggleCascadeOnFocus(),t._cascadeSelect(e)):(e.one(E,(function(){t._toggleCascadeOnFocus(),e.popup.visible()&&e._focused.trigger(F)})),e.value()||t.enable(!1))}},_toggleCascadeOnFocus:function(){var e=this,t=e._parentWidget(),n=$&&t instanceof i.DropDownList?"blur":"focusout";t._focused.add(t.filterInput).on(F,(function(){t.unbind(x,e._cascadeHandlerProxy),t.unbind(f,e._cascadeHandlerProxy),t.first(f,e._cascadeHandlerProxy)})),t._focused.add(t.filterInput).on(n,(function(){t.unbind(f,e._cascadeHandlerProxy),t.unbind(x,e._cascadeHandlerProxy),t.first(x,e._cascadeHandlerProxy)}))},_cascadeHandler:function(e){var t=this._parentWidget(),n=this.value();this._userTriggered=e.userTriggered||t._userTriggered,this.listView.bound()&&this._clearSelection(t,!0),this._cascadeSelect(t,n)},_cascadeChange:function(e){var t=this,n=t._accessor()||t._selectedValue;t._cascadeFilterRequests.length||(t._selectedValue=null),t._userTriggered?t._clearSelection(e,!0):n?(n!==J(t.listView.value()[0],typeof n)&&t.value(n),t.dataSource.view()[0]&&-1!==t.selectedIndex||t._clearSelection(e,!0)):t.dataSource.flatView().length&&t.select(t.options.index),t.enable(),t._triggerCascade(),t._triggerChange(),t._userTriggered=!1},_cascadeSelect:function(e,n){var i=this,r=e.dataItem(),o=r?r[i.options.cascadeFromParentField]||e._value(r):null,a=i.options.cascadeFromField||e.options.dataValueField;if(!e.options.cascadeOnCustomValue||null!==o||i.options.cascadeFromParentField&&i.options.cascadeFromParentField!==e.options.dataValueField||(o=e.value()),i._valueBeforeCascade=n!==t?n:i.value(),o||0===o){oe(i.dataSource.filter()||{},a);var s=function(){var t=i._cascadeFilterRequests.shift();t&&i.unbind("dataBound",t),(t=i._cascadeFilterRequests[0])&&i.first("dataBound",t),i._cascadeChange(e)};i._cascadeFilterRequests.push(s),1===i._cascadeFilterRequests.length&&i.first("dataBound",s),i._cascading=!0,i._filterSource({field:a,operator:"eq",value:o}),i._cascading=!1}else i.enable(!1),i._clearSelection(e),i._triggerCascade(),i._triggerChange(),i._userTriggered=!1;i._refreshFloatingLabel()}});var ee=".StaticList",te=n.ui.DataBoundWidget.extend({init:function(t,i){if(a.fn.init.call(this,t,i),this.element.attr("role",i.aria&&i.aria.role||"listbox").on(S+ee,"li",this._click.bind(this)).on(T+ee,"li",(function(){e(this).addClass(g)})).on("mouseleave"+ee,"li",(function(){e(this).removeClass(g)})),i&&i.ariaLabel?this.element.attr(q,i.ariaLabel):i&&i.ariaLabelledBy&&this.element.attr(j,i.ariaLabelledBy),l.touch&&this._touchHandlers(),"multiple"===this.options.selectable&&this.element.attr("aria-multiselectable",!0),this.options.columns&&this.options.columns.length){var r=this.element.parent().find(".k-table-thead"),o=e('<tr class="k-table-group-row"><th class="k-table-th" colspan="'+this.options.columns.length+'"></th></tr>');r.append(o),this.header=o.find(".k-table-th"),this.content=this.element.wrap("<div class='k-table-body k-table-scroller' unselectable='on'></div>").parent(),this.element.addClass("k-table-list")}else this.content=this.element.wrap("<div class='k-list-content k-list-scroller' unselectable='on'></div>").parent(),this.header=this.content.before(e('<div class="k-list-group-sticky-header"></div>').hide()).prev(),this.element.addClass(_);this.bound(!1),this._optionID=n.guid(),this._selectedIndices=[],this._view=[],this._dataItems=[],this._values=[];var s=this.options.value;s&&(this._values=Array.isArray(s)?s.slice(0):[s]),this._getter(),this._templates(),this.setDataSource(this.options.dataSource),this._createOnScrollProxy()},options:{name:"StaticList",dataValueField:null,valuePrimitive:!1,selectable:!0,template:null,groupTemplate:null,fixedGroupTemplate:null,ariaLabel:null,ariaLabelledBy:null},events:[S,f,D,A,M,E,I],setDataSource:function(e){var t,i=this,r=e||{};r=Array.isArray(r)?{data:r}:r,r=n.data.DataSource.create(r),i.dataSource?(i.dataSource.unbind(f,i._refreshHandler),t=i.value(),i.value([]),i.bound(!1),i.value(t)):i._refreshHandler=i.refresh.bind(i),i.setDSFilter(r.filter()),i.dataSource=r.bind(f,i._refreshHandler),i._fixedHeader()},_touchHandlers:function(){var t,n,i=this,r=this.options.columns&&this.options.columns.length?".k-table-row":y,o=function(e){return(e.originalEvent||e).changedTouches[0].pageY};i.element.on("touchstart"+ee,(function(e){t=o(e)})),i.element.on("touchend"+ee,(function(a){a.isDefaultPrevented()||(n=o(a),Math.abs(n-t)<10&&(i._touchTriggered=!0,i._triggerClick(e(a.target).closest(r).get(0))))}))},skip:function(){return this.dataSource.skip()},setOptions:function(e){a.fn.setOptions.call(this,e),this._getter(),this._templates(),this._render(),this.label&&e.label?this.label.setOptions(e.label):this.label&&!1===e.label&&(this.label._unwrapFloating(),this._inputLabel.remove(),delete this._inputLabel)},destroy:function(){this.element.off(ee),this._refreshHandler&&this.dataSource.unbind(f,this._refreshHandler),clearTimeout(this._scrollId),a.fn.destroy.call(this)},dataItemByIndex:function(e){return this.dataSource.flatView()[e]},screenHeight:function(){return this.content[0].clientHeight},scrollToIndex:function(e){var t=this.element[0].children[e];t&&this.scroll(t)},scrollWith:function(e){this.content.scrollTop(this.content.scrollTop()+e)},scroll:function(e){if(e){e[0]&&(e=e[0]);var t=this.content[0],n=e.offsetTop,i=e.offsetHeight,r=t.scrollTop,o=t.clientHeight,a=n+i;r>n?r=n:a>r+o&&(r=a-o),t.scrollTop=r}},selectedDataItems:function(e){if(e===t)return this._dataItems.slice();this._dataItems=e,this._values=this._getValues(e)},_getValues:function(t){var n=this._valueGetter;return e.map(t,(function(e){return n(e)}))},focusNext:function(){var e=this.focus();e=e?e.next():0,this.focus(e)},focusPrev:function(){var e=this.focus();e=e?e.prev():this.element[0].children.length-1,this.focus(e)},focusFirst:function(){this.focus(this.element[0].children[0])},focusLast:function(){this.focus(ne(this.element[0].children))},focus:function(n){var i,r=this,o=r._optionID;if(n===t)return r._current;n=ne(r._get(n)),n=e(this.element[0].children[n]),r._current&&(r._current.removeClass(m).removeAttr(p),r.trigger(A)),(i=!!n[0])&&(n.addClass(m),r.scroll(n),n.attr("id",o)),r._current=i?n:null,r.trigger(D)},focusIndex:function(){return this.focus()?this.focus().index():t},skipUpdate:function(e){this._skipUpdate=e},select:function(n){var i,r,o=this,a=o.options.selectable,s="multiple"!==a&&!1!==a,l=o._selectedIndices,c=[this.element.find(".k-selected").index()],d=[];if(n===t)return l.slice();1===(n=o._get(n)).length&&-1===n[0]&&(n=[]);var u=e.Deferred().resolve(),h=o.isFiltered();return h&&!s&&o._deselectFiltered(n)?u:s&&!h&&-1!==e.inArray(ne(n),l)&&-1!==e.inArray(ne(n),c)?(o._dataItems.length&&o._view.length&&(o._dataItems=[o._view[l[0]].item]),u):(i=(r=o._deselect(n)).removed,(n=r.indices).length&&(s&&(n=[ne(n)]),d=o._select(n)),(d.length||i.length)&&(o._valueComparer=null,o.trigger(f,{added:d,removed:i})),u)},removeAt:function(e){return this._selectedIndices.splice(e,1),this._values.splice(e,1),this._valueComparer=null,{position:e,dataItem:this._dataItems.splice(e,1)[0]}},setValue:function(e){e=Array.isArray(e)||e instanceof h?e.slice(0):[e],this._values=e,this._valueComparer=null},value:function(n){var i,r=this,o=r._valueDeferred;return n===t?r._values.slice():(r.setValue(n),o&&"resolved"!==o.state()||(r._valueDeferred=o=e.Deferred()),r.bound()&&(i=r._valueIndices(r._values),"multiple"===r.options.selectable&&r.select(-1),r.select(i),o.resolve()),r._skipUpdate=!1,o)},items:function(){return this.element.children(y)},_click:function(e){this._touchTriggered?this._touchTriggered=!1:e.isDefaultPrevented()||this._triggerClick(e.currentTarget)},_createOnScrollProxy:function(){this._onScroll=function(){var e=this;clearTimeout(e._scrollId),e._scrollId=setTimeout((function(){e._renderHeader()}),50)}.bind(this)},_triggerClick:function(t){this.trigger(S,{item:e(t)})||this.select(t)},_valueExpr:function(e,t){var n,i=this,r=0,o=[];if(!i._valueComparer||i._valueType!==e){for(i._valueType=e;r<t.length;r++)o.push(J(t[r],e));n=(e,t)=>{for(var n=0;n<o.length;n++)if(e===t[n])return n;return-1},i._valueComparer=function(e){return n(e,o)}}return i._valueComparer},_dataItemPosition:function(e,t){var n=this._valueGetter(e);return this._valueExpr(typeof n,t)(n)},_getter:function(){this._valueGetter=n.getter(this.options.dataValueField)},_deselect:function(t){var n,i,r=this,o=r.element[0].children,a=r.options.selectable,s=r._selectedIndices,l=r._dataItems,c=r._values,d=[],u=0,h=0;if(t=t.slice(),!0!==a&&t.length){if("multiple"===a)for(;u<t.length;)if(n=t[u],e(o[n]).hasClass(v)){for(;h<s.length;){if((i=s[h])===n){e(o[i]).removeClass(v).attr(Q,!1);var p=this._view[n].item,f=this._dataItemPosition(p,this._values);d.push({position:f,dataItem:p}),l.splice(h,1),s.splice(h,1),t.splice(u,1),c.splice(h,1),u-=1,h-=1;break}h++}u++}else u++}else{for(;u<s.length;u++)e(o[s[u]]).removeClass(v).attr(Q,!1),d.push({position:u,dataItem:l[u]});r._values=[],r._dataItems=[],r._selectedIndices=[]}return{indices:t,removed:d}},_deselectFiltered:function(t){for(var n,i,r,o=this.element[0].children,a=[],s=0;s<t.length;s++)i=t[s],n=this._view[i].item,(r=this._dataItemPosition(n,this._values))>-1&&(a.push(this.removeAt(r)),e(o[i]).removeClass(v));return!!a.length&&(this.trigger(f,{added:[],removed:a}),!0)},_select:function(t){var n,i,r=this,o=r.element[0].children,a=r._view,s=[],l=0;for(-1!==ne(t)&&r.focus(t);l<t.length;l++)n=a[i=t[l]],-1!==i&&n&&(n=n.item,r._selectedIndices.push(i),r._dataItems.push(n),r._values.push(r._valueGetter(n)),e(o[i]).addClass(v).attr(Q,!0),s.push({dataItem:n}));return s},getElementIndex:function(t){return e(t).data("offset-index")},_get:function(e){return"number"==typeof e?e=[e]:L(e)||(e=[(e=this.getElementIndex(e))!==t?e:-1]),e},_templates:function(){var e,t=this.options,i={template:t.template,groupTemplate:t.groupTemplate,fixedGroupTemplate:t.fixedGroupTemplate};for(var r in t.columns&&t.columns.forEach(((e,t)=>{var r=e.field?e.field.toString():N;i["column"+t]=e.template||(e=>c(n.getter(r)(e)))})),i)(e=i[r])&&"function"!=typeof e&&(i[r]=n.template(e));this.templates=i},_normalizeIndices:function(e){for(var n=[],i=0;i<e.length;i++)e[i]!==t&&n.push(e[i]);return n},_valueIndices:function(e,t){var n,i=this._view,r=0;if(t=t?t.slice():[],!e.length)return[];for(;r<i.length;r++)-1!==(n=this._dataItemPosition(i[r].item,e))&&(t[n]=r);return this._normalizeIndices(t)},_firstVisibleItem:function(){var t=this.element[0],n=this.content[0].scrollTop,i=e(t.children[0]).height(),r=Math.floor(n/i)||0;if(0==t.childElementCount)return null;for(var o=t.children[r]||t.lastChild,a=o.offsetTop<n;o;)if(a){if(o.offsetTop+i>n||!o.nextSibling)break;o=o.nextSibling}else{if(o.offsetTop<=n||!o.previousSibling)break;o=o.previousSibling}return this._view[e(o).data("offset-index")]},_fixedHeader:function(){this.isGrouped()&&this.templates.fixedGroupTemplate?(this.header.closest(X).length?this.header.closest(X).show():this.header.show(),this.content.scroll(this._onScroll)):(this.header.closest(X).length?this.header.closest(X).hide():this.header.hide(),this.content.off("scroll",this._onScroll))},_renderHeader:function(){var e=this.templates.fixedGroupTemplate;if(e){var t=this._firstVisibleItem();t&&t.group.toString().length&&this.header.html(e(t.group))}},_renderItem:function(e){var t=`<li tabindex="-1" role="${this.options.aria&&this.options.aria.itemRole||"option"}" unselectable="on" `,n=e.item,i=0!==e.index,r=e.selected,o=this.isGrouped(),a=this.options.columns&&this.options.columns.length,s=e.index%2==1?" k-table-alt-row":"";return t+=a?'class="k-table-row'+s:'class="k-list-item',i&&e.newGroup&&(t+=" k-first"),e.isLastGroupedItem&&a&&(t+=" k-last"),r&&(t+=" k-selected"),t+='" aria-selected="'+(r?"true":"false")+'" data-offset-index="'+e.index+'">',a?t+=this._renderColumns(n):(t+='<span class="k-list-item-text">',t+=this.templates.template(n),t+="</span>"),i&&e.newGroup?t+=a?'<span class="k-table-td k-table-group-td"><span>'+this.templates.groupTemplate(e.group)+"</span></span>":'<div class="k-list-item-group-label">'+this.templates.groupTemplate(e.group)+"</div>":o&&a&&(t+='<span class="k-table-td k-table-spacer-td"></span>'),t+"</li>"},_renderColumns:function(e){for(var t="",i=0;i<this.options.columns.length;i++){var r=this.options.columns[i].width,a=parseInt(r,10),s="";r&&!isNaN(a)&&(s+=`${n.attr("style-width")}="${a}${o.test(r)?"%":"px"}"`),t+="<span class='k-table-td' "+s+">",t+=this.templates["column"+i](e),t+="</span>"}return t},_render:function(){var t,i,r,o,a,s="",l=0,c=0,d=[],u=this.dataSource.view(),h=this.value(),p=this.isGrouped();if(p)for(l=0;l<u.length;l++)for(r=u[l],o=!0,a=0;a<r.items.length;a++)i={selected:this._selected(r.items[a],h),item:r.items[a],group:r.value,newGroup:o,isLastGroupedItem:a===r.items.length-1,index:c},d[c]=i,c+=1,s+=this._renderItem(i),o=!1;else for(l=0;l<u.length;l++)i={selected:this._selected(u[l],h),item:u[l],index:l},d[l]=i,s+=this._renderItem(i);this._view=d,t=e(s),n.applyStylesFromKendoAttributes(t,["width","background-color"]),this.element.empty().append(t),p&&d.length&&this._renderHeader()},_selected:function(e,t){return(!this.isFiltered()||"multiple"===this.options.selectable)&&-1!==this._dataItemPosition(e,t)},setDSFilter:function(e){this._lastDSFilter=R({},e)},isFiltered:function(){return this._lastDSFilter||this.setDSFilter(this.dataSource.filter()),!n.data.Query.compareFilters(this.dataSource.filter(),this._lastDSFilter)},refresh:function(e){var t,n=this,i=e&&e.action,r=n.options.skipUpdateOnBind,o="itemchange"===i;n.trigger(M),n._fixedHeader(),n._render(),n.bound(!0),o||"remove"===i?(t=function(e,t){var n,i,r,o,a=t.length,s=e.length,l=[],c=[];if(s)for(r=0;r<s;r++){for(n=e[r],i=!1,o=0;o<a;o++)if(n===t[o]){i=!0,l.push({index:r,item:n});break}i||c.push(n)}return{changed:l,unchanged:c}}(n._dataItems,e.items)).changed.length&&(o?n.trigger(I,{items:t.changed}):n.value(n._getValues(t.unchanged))):n.isFiltered()||n._skipUpdate||n._emptySearch?(n.focus(0),n._skipUpdate&&(n._skipUpdate=!1,n._selectedIndices=n._valueIndices(n._values,n._selectedIndices))):r||i&&"add"!==i||n.value(n._values),n._valueDeferred&&n._valueDeferred.resolve(),n.trigger(E)},bound:function(e){if(e===t)return this._bound;this._bound=e},isGrouped:function(){return(this.dataSource.group()||[]).length}});function ne(e){return e[e.length-1]}function ie(e){var t=e.selectedIndex;return t>-1?e.options[t]:{}}function re(t){return!(!t||e.isEmptyObject(t))&&!(t.filters&&!t.filters.length)}function oe(t,n){var i,r=!1;return t.filters&&(i=e.grep(t.filters,(function(e){return r=oe(e,n),e.filters?e.filters.length:e.field!=n})),r||t.filters.length===i.length||(r=!0),t.filters=i),r}i.plugin(te),n.cssProperties.registerPrefix("List","k-list-")}(window.kendo.jQuery);kendo;kendo.jQuery;function Rh(e,t,n){return{value:"multiple"===e.selectable||e.checkboxes?t:t[0],success:function(e){n(e)}}}!function(e,t){var n=window.kendo,i=n.ui,r=n.htmlEncode,o=i.Widget,a=i.DataBoundWidget,s=/^\d+(\.\d+)?%$/i,l="k-list-item",c="k-table-row",d="k-list-item-group-label",u="k-selected",h="k-focus",p="k-hover",f="change",m="click",g="listBound",v="itemChange",_="activate",b="deactivate",y=".k-table-group-row",w=".VirtualList";function k(e){return e[e.length-1]}function x(e){return e instanceof Array?e:[e]}function C(e){return"string"==typeof e||"number"==typeof e||"boolean"==typeof e}function S(e,t,n){var i=document.createElement(n||"div");return t&&(i.className=t),e.appendChild(i),i}function T(i,r,o){var a=o.template,l=this.options.columns&&this.options.columns.length,c=r.index%2==1?"k-table-alt-row":"";if(i=e(i),r.item||(a=o.placeholderTemplate),0===r.index&&this.header&&r.group&&this.header.html(o.fixedGroupTemplate(r.group)),i.attr("data-uid",r.item?r.item.uid:"").attr("data-offset-index",r.index),l&&r.item){c.length>0?i.addClass(c):i.removeClass("k-table-alt-row");let t=e(function(e,t,i){for(var r="",o=0;o<e.columns.length;o++){var a=e.columns[o].width,l=parseInt(a,10),c="";if(a){let e=`${l}${s.test(a)?"%":"px"}`;c=`${n.attr("style-width")}="${e}" ${n.attr("style-max-width")}="${e}"`}r+="<span class='k-table-td' "+c+">",r+=i["column"+o](t),r+="</span>"}return r}(this.options,r.item,o));n.applyStylesFromKendoAttributes(t,["width","max-width"]),i.empty().append(t)}else i.find("."+d).remove(),i.find(".k-list-item-text").html(a(r.item||{}));i.toggleClass(h,r.current),i.toggleClass(u,r.selected),i.toggleClass("k-first",r.newGroup),i.toggleClass("k-last",r.isLastGroupedItem),i.toggleClass("k-loading-item",!r.item),0!==r.index&&r.newGroup?l?e('<span class="k-table-td k-table-group-td"><span>'+o.groupTemplate(r.group)+"</span></span>").appendTo(i):e("<div class="+d+"></div>").appendTo(i).html(o.groupTemplate(r.group)):r.group&&l&&i.append(e('<span class="k-table-td k-table-spacer-td"></span>')),r.top!==t&&function(e,t){e.style.webkitTransform="translateY("+t+"px)",e.style.transform="translateY("+t+"px)"}(i[0],r.top)}function D(e){return e&&"resolved"!==e.state()}var A=a.extend({init:function(t,i){var r,a,s,l=this,c=i.columns&&i.columns.length?"k-table-body k-table-scroller":"k-list-content k-virtual-content";l.bound(!1),l._fetching=!1,o.fn.init.call(l,t,i),l.options.itemHeight||(l.options.itemHeight=(r=i.listSize,(s=e('<div class="k-list '+r+' k-virtual-list"><div class="k-list-content k-virtual-content"><ul class="k-list-ul"><li class="k-list-item"><span class="k-list-item-text">test</span></li></ul></div></div>')).css({position:"absolute",left:"-200000px",visibility:"hidden"}),s.appendTo(document.body),a=parseFloat(n.getComputedStyles(s.find(".k-list-item")[0],["height"]).height),s.remove(),a)),i=l.options,l.element.attr("role","listbox");var d="."+c.split(" ").join("."),u=l.element.closest(d);if(l.content=l.wrapper=u.length?u:l.element.wrap("<div unselectable='on' class='"+c+"'></div>").parent(),l.options.columns&&l.options.columns.length){var h=l.element.closest(".k-data-table").find(".k-table-thead"),f=e('<tr class="k-table-group-row"><th class="k-table-th" colspan="'+l.options.columns.length+'"></th></tr>');h.append(f),l.header=f.find(".k-table-th"),l.element.addClass("k-table-list k-virtual-table")}else l.header=l.content.before("<div class='k-list-group-sticky-header'></div>").prev(),l.element.addClass("k-list-ul");i.ariaLabel?this.element.attr("aria-label",i.ariaLabel):i.ariaLabelledBy&&this.element.attr("aria-labelledby",i.ariaLabelledBy),l.element.on("mouseenter"+w,"li:not(.k-loading-item)",(function(){e(this).addClass(p)})).on("mouseleave"+w,"li",(function(){e(this).removeClass(p)})),l._values=x(l.options.value),l._selectedDataItems=[],l._selectedIndexes=[],l._rangesList={},l._promisesList=[],l._optionID=n.guid(),l._templates(),l.setDataSource(i.dataSource),l.content.on("scroll"+w,n.throttle((function(){l._renderItems(),l._triggerListBound()}),i.delay)),l._selectable()},options:{name:"VirtualList",autoBind:!0,delay:100,height:null,listScreens:4,threshold:.5,itemHeight:null,oppositeBuffer:1,type:"flat",selectable:!1,value:[],dataValueField:null,template:e=>r(e),placeholderTemplate:()=>"loading...",groupTemplate:e=>r(e),fixedGroupTemplate:e=>r(e),mapValueTo:"index",valueMapper:null,ariaLabel:null,ariaLabelledBy:null},events:[f,m,g,v,_,b],setOptions:function(e){var t=this.options.columns&&this.options.columns.length?c:l;o.fn.setOptions.call(this,e),this._selectProxy&&!1===this.options.selectable?this.element.off(m,"."+t,this._selectProxy):!this._selectProxy&&this.options.selectable&&this._selectable(),this._templates(),this.refresh()},items:function(){return e(this._items)},destroy:function(){this.wrapper.off(w),this.dataSource.unbind(f,this._refreshHandler),o.fn.destroy.call(this)},setDataSource:function(e){var t,i=this,r=e||{};r=Array.isArray(r)?{data:r}:r,r=n.data.DataSource.create(r),i.dataSource?(i.dataSource.unbind(f,i._refreshHandler),i._clean(),i.bound(!1),i._deferValueSet=!0,t=i.value(),i.value([]),i.mute((function(){i.value(t)}))):i._refreshHandler=i.refresh.bind(i),i.dataSource=r.bind(f,i._refreshHandler),i.setDSFilter(r.filter()),0!==r.view().length?i.refresh():i.options.autoBind&&r.fetch()},skip:function(){return this.dataSource.currentRangeStart()},_triggerListBound:function(){var e=this,t=e.skip();e.bound()&&!e._selectingValue&&e._skip!==t&&(e._skip=t,e.trigger(g))},_getValues:function(t){var n=this._valueGetter;return e.map(t,(function(e){return n(e)}))},_highlightSelectedItems:function(){for(var e=0;e<this._selectedDataItems.length;e++){var t=this._getElementByDataItem(this._selectedDataItems[e]);t.length&&t.addClass(u)}},refresh:function(e){var t,n=this,i=e&&e.action,r="itemchange"===i,o=this.isFiltered();n._mute||(n._deferValueSet=!1,n._fetching?(n._renderItems&&n._renderItems(!0),n._triggerListBound()):(o&&n.focus(0),n._createList(),i||!n._values.length||o||n.options.skipUpdateOnBind||n._emptySearch?(n.bound(!0),n._highlightSelectedItems(),n._triggerListBound()):(n._selectingValue=!0,n.bound(!0),n.value(n._values,!0).done((function(){n._selectingValue=!1,n._triggerListBound()})))),(r||"remove"===i)&&(t=function(e,t){var n,i,r,o,a=t.length,s=e.length,l=[],c=[];if(s)for(r=0;r<s;r++){for(n=e[r],i=!1,o=0;o<a;o++)if(n===t[o]){i=!0,l.push({index:r,item:n});break}i||c.push(n)}return{changed:l,unchanged:c}}(n._selectedDataItems,e.items)).changed.length&&(r?n.trigger("selectedItemChange",{items:t.changed}):n.value(n._getValues(t.unchanged))),n._fetching=!1)},removeAt:function(e){var t=this._values.splice(e,1)[0];return{position:e,dataItem:this._removeSelectedDataItem(t)}},_removeSelectedDataItem:function(e){var t=this,n=t._valueGetter;for(var i in t._selectedDataItems)if(n(t._selectedDataItems[i])===e)return t._selectedIndexes.splice(i,1),t._selectedDataItems.splice(i,1)[0]},setValue:function(e){this._values=x(e)},value:function(n,i){var r=this;return n===t?r._values.slice():(null===n&&(n=[]),n=x(n),r._valueDeferred&&"resolved"!==r._valueDeferred.state()||(r._valueDeferred=e.Deferred()),!("multiple"===r.options.selectable&&r.select().length&&n.length)&&n.length||r.select(-1),r._values=n,(r.bound()&&!r._mute&&!r._deferValueSet||i)&&r._prefetchByValue(n),r._valueDeferred)},_checkValuesOrder:function(e){if(this._removedAddedIndexes&&this._removedAddedIndexes.length===e.length){var t=this._removedAddedIndexes.slice();return this._removedAddedIndexes=null,t}return e},_prefetchByValue:function(e){for(var t,n=this,i=n._dataView,r=n._valueGetter,o=n.options.mapValueTo,a=[],s=0;s<e.length;s++)for(var l=0;l<i.length;l++)(t=i[l].item)&&(C(t)?e[s]===t:e[s]===r(t))&&a.push(i[l].index);if(a.length===e.length)return n._values=[],void n.select(a);if("function"==typeof n.options.valueMapper){const t="index"===o?n.mapValueToIndex:n.mapValueToDataItem;n.options.valueMapper(Rh(this.options,e,t.bind(n)))}else n.value()[0]?(n._selectingValue=!1,n._triggerListBound()):n.select([-1])},mapValueToIndex:function(e){if((e=e===t||-1===e||null===e?[]:x(e)).length){var n=this._deselect([]).removed;n.length&&this._triggerChange(n,[])}else e=[-1];this.select(e)},mapValueToDataItem:function(n){var i,r;if((n=n===t||null===n?[]:x(n)).length){i=e.map(this._selectedDataItems,(function(e,t){return{index:t,dataItem:e}})),r=e.map(n,(function(e,t){return{index:t,dataItem:e}})),this._selectedDataItems=n,this._selectedIndexes=[];for(var o=0;o<this._selectedDataItems.length;o++){var a=this._getElementByDataItem(this._selectedDataItems[o]);this._selectedIndexes.push(this._getIndecies(a)[0]),a.addClass(u)}this._triggerChange(i,r),this._valueDeferred&&this._valueDeferred.resolve()}else this.select([-1])},deferredRange:function(t){var n=this.dataSource,i=this.itemCount,r=this._rangesList,o=e.Deferred(),a=[],s=Math.floor(t/i)*i,l=Math.ceil(t/i)*i,c=l===s?[l]:[s,l];return e.each(c,(function(t,o){var s,l=o+i,c=r[o];c&&c.end===l?s=c.deferred:(s=e.Deferred(),r[o]={end:l,deferred:s},n._multiplePrefetch(o,i,(function(){s.resolve()}))),a.push(s)})),e.when.apply(e,a).done((function(){o.resolve()})),o},prefetch:function(t){var n=this,i=this.itemCount,r=!n._promisesList.length;return D(n._activeDeferred)||(n._activeDeferred=e.Deferred(),n._promisesList=[]),e.each(t,(function(e,t){n._promisesList.push(n.deferredRange(n._getSkip(t,i)))})),r&&e.when.apply(e,n._promisesList).done((function(){n._promisesList=[],n._activeDeferred.resolve()})),n._activeDeferred},_findDataItem:function(e,t){var n;if("group"===this.options.type)for(var i=0;i<e.length;i++){if(!((n=e[i].items).length<=t))return n[t];t-=n.length}return e[t]},_getRange:function(e,t){return this.dataSource._findRange(e,Math.min(e+t,this.dataSource.total()))},dataItemByIndex:function(t){var i=this,r=i.itemCount,o=i._getSkip(t,r),a=this._getRange(o,r);return i._getRange(o,r).length?("group"===i.options.type&&(n.ui.progress(e(i.wrapper),!0),i.mute((function(){i.dataSource.range(o,r,(function(){n.ui.progress(e(i.wrapper),!1)})),a=i.dataSource.view()}))),i._findDataItem(a,[t-o])):null},selectedDataItems:function(){return this._selectedDataItems.slice()},scrollWith:function(e){this.content.scrollTop(this.content.scrollTop()+e)},scrollTo:function(e){this.content.scrollTop(e)},scrollToIndex:function(e){this.scrollTo(e*this.options.itemHeight)},focus:function(n){var i,r,o,a,s=this.options.itemHeight,l=this._optionID,c=!0;if(n===t)return(a=this.element.find("."+h)).length?a:null;if("function"==typeof n){o=this.dataSource.flatView();for(var d=0;d<o.length;d++)if(n(o[d])){n=d;break}}if(n instanceof Array&&(n=k(n)),isNaN(n)?(i=e(n),r=parseInt(e(i).attr("data-offset-index"),10)):(r=n,i=this._getElementByIndex(r)),-1===r)return this.element.find("."+h).removeClass(h),void(this._focusedIndex=t);if(i.length){i.hasClass(h)&&(c=!1),this._focusedIndex!==t&&((a=this._getElementByIndex(this._focusedIndex)).removeClass(h).removeAttr("id"),c&&this.trigger(b)),this._focusedIndex=r,i.addClass(h).attr("id",l);var u=this._getElementLocation(r);"top"===u?this.scrollTo(r*s):"bottom"===u?this.scrollTo(r*s+s-this._screenHeight):"outScreen"===u&&this.scrollTo(r*s),c&&this.trigger(_)}else this._focusedIndex=r,this.items().removeClass(h),this.scrollToIndex(r)},focusIndex:function(){return this._focusedIndex},focusFirst:function(){this.scrollTo(0),this.focus(0)},focusLast:function(){var e=this.dataSource.total();this.scrollTo(this.heightContainer.offsetHeight),this.focus(e-1)},focusPrev:function(){var e,t=this._focusedIndex;return!isNaN(t)&&t>0?(t-=1,this.focus(t),(e=this.focus())&&e.hasClass("k-loading-item")&&(t+=1,this.focus(t)),t):(t=this.dataSource.total()-1,this.focus(t),t)},focusNext:function(){var e,t=this._focusedIndex,n=this.dataSource.total()-1;return!isNaN(t)&&t<n?(t+=1,this.focus(t),(e=this.focus())&&e.hasClass("k-loading-item")&&(t-=1,this.focus(t)),t):(t=0,this.focus(t),t)},_triggerChange:function(e,t){t=t||[],((e=e||[]).length||t.length)&&this.trigger(f,{removed:e,added:t})},select:function(n){var i,r,o,a,s,l=this,c="multiple"!==l.options.selectable,d=D(l._activeDeferred),u=this.isFiltered(),h=[];if(n===t)return l._selectedIndexes.slice();if(l._selectDeferred&&"resolved"!==l._selectDeferred.state()||(l._selectDeferred=e.Deferred()),i=l._getIndecies(n),o=c&&!u&&k(i)===k(this._selectedIndexes),(h=l._deselectCurrentValues(i)).length||!i.length||o)return l._triggerChange(h),l._valueDeferred&&l._valueDeferred.resolve().promise(),l._selectDeferred.resolve().promise();1===i.length&&-1===i[0]&&(i=[]),r=i,s=l._deselect(i),h=s.removed,i=s.indices,c&&(d=!1,i.length&&(i=[k(i)]));var p=function(){var e=l._select(i);(r.length===i.length||c)&&l.focus(i),l._triggerChange(h,e),l._valueDeferred&&l._valueDeferred.resolve(),l._selectDeferred.resolve()};return a=l.prefetch(i),d||(a?a.done(p):p()),l._selectDeferred.promise()},bound:function(e){if(e===t)return this._listCreated;this._listCreated=e},mute:function(e){this._mute=!0,e(),this._mute=!1},setDSFilter:function(t){this._lastDSFilter=e.extend({},t)},isFiltered:function(){return this._lastDSFilter||this.setDSFilter(this.dataSource.filter()),!n.data.Query.compareFilters(this.dataSource.filter(),this._lastDSFilter)},skipUpdate:e.noop,_getElementByIndex:function(t){return this.items().filter((function(n,i){return t===parseInt(e(i).attr("data-offset-index"),10)}))},_getElementByDataItem:function(t){for(var n,i=this._dataView,r=this._valueGetter,o=0;o<i.length;o++)if(i[o].item&&C(i[o].item)?i[o].item===t:i[o].item&&t&&r(i[o].item)==r(t)){n=i[o];break}return n?this._getElementByIndex(n.index):e()},_clean:function(){this.result=t,this._lastScrollTop=t,this._skip=t,e(this.heightContainer).remove(),this.heightContainer=t,this.element.empty()},_height:function(){var e=!!this.dataSource.view().length,t=this.options.height,n=this.options.itemHeight,i=this.dataSource.total();return e?t/n>i&&(t=i*n):t=0,t},setScreenHeight:function(){var e=this._height();this.content.height(e),this._screenHeight=e},screenHeight:function(){return this._screenHeight},_getElementLocation:function(e){var t=this.content.scrollTop(),n=this._screenHeight,i=this.options.itemHeight,r=e*i,o=r+i,a=t+n;return r===t-i||o>t&&r<t?"top":r===a||r<a&&a<o?"bottom":r>=t&&r<=t+(n-i)?"inScreen":"outScreen"},_templates:function(){var e=this.options,t={template:e.template,placeholderTemplate:e.placeholderTemplate,groupTemplate:e.groupTemplate,fixedGroupTemplate:e.fixedGroupTemplate};for(var i in e.columns&&e.columns.forEach(((e,i)=>{var o=e.field?e.field.toString():"text";t["column"+i]=e.template||(e=>r(n.getter(o)(e)))})),t)"function"!=typeof t[i]&&(t[i]=n.template(t[i]||""));this.templates=t},_generateItems:function(e,t){for(var n,i,r=[],o=this.options.itemHeight+"px",a=this.options.columns&&this.options.columns.length?c:l;t-- >0;)(i=document.createElement("span")).className="k-list-item-text",(n=document.createElement("li")).tabIndex=-1,n.className=a,n.setAttribute("role","option"),n.style.height=o,n.style.minHeight=o,n.appendChild(i),e.appendChild(n),r.push(n);return r},_saveInitialRanges:function(){var t=this.dataSource._ranges,n=e.Deferred();n.resolve(),this._rangesList={};for(var i=0;i<t.length;i++)this._rangesList[t[i].start]={end:t[i].end,deferred:n}},_createList:function(){var e,t,n,i,r=this,o=r.content.get(0),a=r.options,s=r.dataSource;r.bound()&&r._clean(),r._saveInitialRanges(),r._buildValueGetter(),r.setScreenHeight(),r.itemCount=(e=r._screenHeight,t=a.listScreens,n=a.itemHeight,Math.ceil(e*t/n)),r.itemCount>s.total()&&(r.itemCount=s.total()),r._items=r._generateItems(r.element[0],r.itemCount),r._setHeight(a.itemHeight*s.total()),r.options.type=(s.group()||[]).length?"group":"flat","flat"===r.options.type?r.header.closest(y).length?r.header.closest(y).hide():r.header.hide():r.header.closest(y).length?r.header.closest(y).show():r.header.show(),r.getter=r._getter((function(){r._renderItems(!0)})),r._onScroll=function(e,t){var n=r._listItems(r.getter);return r._fixedHeader(e,n(e,t))},r._renderItems=r._whenChanged(function(e,t){return function(n){return t(e.scrollTop,n)}}(o,r._onScroll),(i=r._reorderList(r._items,T.bind(r)),function(e,t){return i(e.items,e.index,t),e})),r._renderItems(),r._calculateGroupPadding(r._screenHeight),r._calculateColumnsHeaderPadding()},_setHeight:function(e){var t,n=this.heightContainer;if(n?t=n.offsetHeight:n=this.heightContainer=S(this.content[0],"k-height-container"),e!==t)for(n.innerHTML="";e>0;){var i=Math.min(e,25e4);S(n).style.height=i+"px",e-=i}},_getter:function(){var e=null,t=this.dataSource,n=t.skip(),i=this.options.type,r=this.itemCount,o={};return t.pageSize()<r&&this.mute((function(){t.pageSize(r)})),function(a,s){var l=this;if(t.inRange(s,r)){var c;if(n!==s&&this.mute((function(){t.range(s,r),n=s})),"group"===i){if(!o[s])for(var d=o[s]=[],u=t.view(),h=0,p=u.length;h<p;h++)for(var f=u[h],m=0,g=f.items.length;m<g;m++)d.push({item:f.items[m],group:f.value});c=o[s][a-s]}else c=t.view()[a-s];return c}return e!==s&&(e=s,n=s,l._getterDeferred&&l._getterDeferred.reject(),l._getterDeferred=l.deferredRange(s),l._getterDeferred.then((function(){var e=l._indexConstraint(l.content[0].scrollTop);l._getterDeferred=null,s<=e&&e<=s+r&&(l._fetching=!0,t.range(s,r))}))),null}},_fixedHeader:function(e,t){var n=this.currentVisibleGroup,i=this.options.itemHeight,r=Math.floor((e-t.top)/i),o=t.items[r];if(o&&o.item){var a=o.group;if(a!==n){var s=a||"";this.header.html(this.templates.fixedGroupTemplate(s)),this.currentVisibleGroup=a}}return t},_itemMapper:function(e,t,n){var i=this.options.type,r=this.options.itemHeight,o=this._focusedIndex,a=!1,s=!1,l=!1,c=null,d=this._valueGetter;if("group"===i&&(e&&(l=0===t||!1!==this._currentGroup&&this._currentGroup!==e.group,this._currentGroup=e.group),c=e?e.group:null,e=e?e.item:null),"dataItem"===this.options.mapValueTo&&this._selectedDataItems.length&&e){for(var u=0;u<this._selectedDataItems.length;u++)if(d(this._selectedDataItems[u])===d(e)){a=!0;break}}else if(!this.isFiltered()&&n.length&&e)for(var h=0;h<n.length;h++)if(C(e)?n[h]===e:n[h]===d(e)){n.splice(h,1),a=!0;break}return o===t&&(s=!0),{item:e||null,group:c,newGroup:l,selected:a,current:s,index:t,top:t*r}},_range:function(e){var t,n=this.itemCount,i=this._values.slice(),r=[];this._view={},this._currentGroup=!1;for(var o=e,a=e+n;o<a;o++)t=this._itemMapper(this.getter(o,e),o,i),r[r.length-1]&&(r[r.length-1].isLastGroupedItem=t.newGroup),r.push(t),this._view[t.index]=t;return this._dataView=r,r},_getDataItemsCollection:function(e,t){var n=this._range(this._listIndex(e,t));return{index:n.length?n[0].index:0,top:n.length?n[0].top:0,items:n}},_listItems:function(){var e=this._screenHeight,t=function(e,t){var n=(e.listScreens-1-e.threshold)*t,i=e.threshold*t;return function(e,t,r){return t>r?t-e.top<n:0===e.top||t-e.top>i}}(this.options,e);return function(e,n){var i=this.result,r=this._lastScrollTop;return!n&&i&&t(i,e,r)||(i=this._getDataItemsCollection(e,r)),this._lastScrollTop=e,this.result=i,i}.bind(this)},_whenChanged:function(e,t){var n;return function(i){var r=e(i);r!==n&&(n=r,t(r,i))}},_reorderList:function(t,i){var r,o,a=this,s=t.length,l=-1/0;return i=(r=i,o=this.templates,function(t,i){for(var a=0,s=t.length;a<s;a++)r(t[a],i[a],o),i[a].item&&this.trigger(v,{item:e(t[a]),data:i[a].item,ns:n.ui})}).bind(this),function(e,n,r){var o,c,d=n-l;r||Math.abs(d)>=s?(o=t,c=e):(o=function(e,t){var n;return t>0?(n=e.splice(0,t),e.push.apply(e,n)):(n=e.splice(t,-t),e.unshift.apply(e,n)),n}(t,d),c=d>0?e.slice(-d):e.slice(0,-d)),i(o,c,a.bound()),l=n}},_bufferSizes:function(){var e,t,n,i=this.options;return e=this._screenHeight,t=i.listScreens,n=i.oppositeBuffer,{down:e*n,up:e*(t-1-n)}},_indexConstraint:function(e){var t=this.itemCount,n=this.options.itemHeight,i=this.dataSource.total();return Math.min(Math.max(i-t,0),Math.max(0,Math.floor(e/n)))},_listIndex:function(e,t){var n,i=this._bufferSizes();return n=e-(e>t?i.down:i.up),this._indexConstraint(n)},_selectable:function(){var e=this.options.columns&&this.options.columns.length?c:l;this.options.selectable&&(this._selectProxy=this._clickHandler.bind(this),this.element.on(m+w,"."+e,this._selectProxy))},getElementIndex:function(e){return e instanceof jQuery?parseInt(e.attr("data-offset-index"),10):t},_getIndecies:function(e){var t,n=[];if("function"==typeof e){t=this.dataSource.flatView();for(var i=0;i<t.length;i++)if(e(t[i])){n.push(i);break}}"number"==typeof e&&n.push(e);var r=this.getElementIndex(e);return isNaN(r)||n.push(r),e instanceof Array&&(n=e),n},_deselect:function(n){var i,r,o,a=[],s=this._selectedIndexes,l=this._selectedDataItems,c=0,d=this.options.selectable,h=0,p=this._valueGetter,f=null;if(n=n.slice(),!0!==d&&n.length){if("multiple"===d){let d=0;for(;d<n.length;){if(f=null,c=e.inArray(n[d],s),r=this.dataItemByIndex(n[d]),-1===c&&r)for(var m=0;m<l.length;m++)(C(r)?l[m]===r:p(l[m])===p(r))&&(o=this._getElementByIndex(n[d]),f=this._deselectSingleItem(o,m,n[d],h));else(i=s[c])!==t&&(o=this._getElementByIndex(i),f=this._deselectSingleItem(o,c,i,h));f&&(n.splice(d,1),a.push(f),h++,d--),d++}}}else{for(var g=0;g<s.length;g++)s[g]!==t?this._getElementByIndex(s[g]).removeClass(u):l[g]&&this._getElementByDataItem(l[g]).removeClass(u),a.push({index:s[g],position:g,dataItem:l[g]});this._values=[],this._selectedDataItems=[],this._selectedIndexes=[]}return{indices:n,removed:a}},_deselectSingleItem:function(e,t,n,i){if(e.hasClass(u))return e.removeClass(u),this._values.splice(t,1),this._selectedIndexes.splice(t,1),{index:n,position:t+i,dataItem:this._selectedDataItems.splice(t,1)[0]}},_deselectCurrentValues:function(t){var n,i,r,o,a=this.element[0].children,s=this._values,l=[],c=0;if("multiple"!==this.options.selectable||!this.isFiltered())return[];if(-1===t[0])return e(a).removeClass(u),l=e.map(this._selectedDataItems.slice(0),(function(e,t){return{dataItem:e,position:t}})),this._selectedIndexes=[],this._selectedDataItems=[],this._values=[],l;for(;c<t.length;c++){for(r=-1,i=t[c],this.dataItemByIndex(i)&&(n=this._valueGetter(this.dataItemByIndex(i))),o=0;o<s.length;o++)if(n==s[o]){r=o;break}r>-1&&(l.push(this.removeAt(r)),e(a[i]).removeClass(u))}return l},_getSkip:function(e,t){return((e<t?1:Math.floor(e/t)+1)-1)*t},_select:function(t){var n,i,r=this,o="multiple"!==this.options.selectable,a=this.dataSource,s=this.itemCount,l=this._valueGetter,c=[];return o&&(r._selectedIndexes=[],r._selectedDataItems=[],r._values=[]),i=a.skip(),e.each(t,(function(e,t){var o=r._getSkip(t,s);r.mute((function(){a.range(o,s),n=r._findDataItem(a.view(),[t-o]),r._selectedIndexes.push(t),r._selectedDataItems.push(n),r._values.push(C(n)?n:l(n)),c.push({index:t,dataItem:n}),r._getElementByIndex(t).addClass(u),a.range(i,s)}))})),r._values=r._checkValuesOrder(r._values),c},_clickHandler:function(t){var n=e(t.currentTarget);!t.isDefaultPrevented()&&n.attr("data-uid")&&this.trigger(m,{item:n})},_buildValueGetter:function(){this._valueGetter=n.getter(this.options.dataValueField)},_calculateGroupPadding:function(e){var t=this.items().first(),i=this.header,r=0;i[0]&&"none"!==i[0].style.display&&("auto"!==e&&(r=n.support.scrollbar()),r+=parseFloat(t.css("border-right-width"),10)+parseFloat(t.children(".k-group").css("right"),10),i.css("padding-right",r))},_calculateColumnsHeaderPadding:function(){if(this.options.columns&&this.options.columns.length){var e=n.support.isRtl(this.wrapper),t=n.support.scrollbar(),i=this.content.parent().parent().find(".k-table-header"),r=this.dataSource.total();i.css(e?"padding-left":"padding-right",r?t:0)}}});n.ui.VirtualList=A,n.ui.plugin(A)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.htmlEncode,r=n.ui,o=n.html,a=r.List,s=r.Select,l=n.support,c=n._activeElement,d=n.data.ObservableObject,u=n.keys,h=".kendoDropDownList",p=h+"FocusEvent",f="disabled",m="readonly",g="change",v="k-focus",_="k-disabled",b="aria-disabled",y="aria-readonly",w="click"+h+" touchend"+h,k="mouseenter"+h+" mouseleave"+h,x="tabindex",C="filter",S="accept",T=s.extend({init:function(i,r){var o,a,l=this,c=r&&r.index;l.ns=h,r=Array.isArray(r)?{dataSource:r}:r,s.fn.init.call(l,i,r),r=l.options,i=l.element.on("focus"+h,l._focusHandler.bind(l)),l._focusInputHandler=l._focusInput.bind(l),l.optionLabel=e(),l._optionLabel(),l._inputTemplate(),l._reset(),l._prev="",l._word="",l._wrapper(),l._tabindex(),l.wrapper.data(x,l.wrapper.attr(x)),l._span(),l._popup(),l._mobile(),l._dataSource(),l._ignoreCase(),r.label&&this._label(),l._aria(),l._enable(),l._oldIndex=l.selectedIndex=-1,c!==t&&(r.index=c),l._initialIndex=r.index,l.requireValueMapper(l.options),l._initList(),l.listView.one("dataBound",l._attachAriaActiveDescendant.bind(l)),l._cascade(),l.one("set",(function(e){!e.sender.listView.bound()&&l.hasOptionLabel()&&l._textAccessor(l._optionLabelText())})),r.autoBind?l.dataSource.fetch():-1===l.selectedIndex&&((a=r.text||"")||((o=r.optionLabel)&&0===r.index?a=o:l._isSelect&&(a=i.children(":selected").text())),l._textAccessor(a)),e(l.element).parents("fieldset").is(":disabled")&&l.enable(!1),l.listView.bind("click",(function(e){e.preventDefault()})),n.notify(l),l._applyCssClasses()},options:{name:"DropDownList",enabled:!0,autoBind:!0,_allowFilterPaste:!0,index:0,text:null,value:null,delay:500,height:200,dataTextField:"",dataValueField:"",optionLabel:"",cascadeFrom:"",cascadeFromField:"",cascadeFromParentField:"",ignoreCase:!0,animation:{},filter:"none",minLength:1,enforceMinLength:!1,virtual:!1,template:null,valueTemplate:null,optionLabelTemplate:null,groupTemplate:e=>i(e),fixedGroupTemplate:e=>i(e),autoWidth:!1,popup:null,filterTitle:null,size:"medium",fillMode:"solid",rounded:"medium",label:null,popupFilter:!0},events:["open","close",g,"select","filtering","dataBinding","dataBound","cascade","set","kendoKeydown"],setOptions:function(e){s.fn.setOptions.call(this,e),this.listView.setOptions(this._listOptions(e)),this._optionLabel(),this._inputTemplate(),this._accessors(),this._removeFilterHeader(),this._addFilterHeader(),this._enable(),this._aria(),!this.value()&&this.hasOptionLabel()&&this.select(0)},destroy:function(){var e=this;s.fn.destroy.call(e),e.wrapper.off(h),e.wrapper.off(p),e.element.off(h),e._arrow.off(),e._arrow=null,e._arrowIcon=null,e.optionLabel.off(),e.filterInput&&e.filterInput.off(p)},open:function(){var e=this,t=!!e.dataSource.filter()&&e.dataSource.filter().filters.length>0,n=this.listView;e.popup.visible()||(e.listView.bound()&&e._state!==S?e._allowOpening()&&(e._focusFilter=!0,e.popup.one("activate",e._focusInputHandler),e.popup._hovered=!0,e.wrapper.attr("aria-activedescendant",n._optionID),e.popup.open(),e._resizeFilterInput(),e._focusItem()):(e._open=!0,e._state="rebind",e.filterInput&&(e.filterInput.val(""),e._prev=""),e.filterInput&&1!==e.options.minLength&&!t?(e.refresh(),e.popup.one("activate",e._focusInputHandler),e.wrapper.attr("aria-activedescendant",n._optionID),e.popup.open(),e._resizeFilterInput()):e._filterSource()))},close:function(){this._attachAriaActiveDescendant(),this.popup.close()},_attachAriaActiveDescendant:function(){var e=this.wrapper,t=e.find(".k-input-inner").attr("id");e.attr("aria-describedby",t)},_focusInput:function(){this._hasActionSheet()||this._focusElement(this.filterInput)},_resizeFilterInput:function(){var e=this.filterInput,t=this._prevent;if(e&&!this._hasActionSheet()){var i=this.filterInput[0]===c(),r=n.caret(this.filterInput[0])[0];this._prevent=!0,e.addClass("k-hidden"),e.closest(".k-list-filter").css("width",this.popup.element.width()),e.removeClass("k-hidden"),i&&(e.trigger("focus"),n.caret(e[0],r)),this._prevent=t}},_allowOpening:function(){return this.hasOptionLabel()||this.filterInput||s.fn._allowOpening.call(this)},toggle:function(e){this._toggle(e,!0)},current:function(e){var n;if(e===t)return!(n=this.listView.focus())&&0===this.selectedIndex&&this.hasOptionLabel()?this.optionLabel:n;this._focus(e)},dataItem:function(n){var i=this,r=null;if(null===n)return n;if(n===t)r=i.listView.selectedDataItems()[0];else{if("number"!=typeof n){if(i.options.virtual)return i.dataSource.getByUid(e(n).data("uid"));n=n.hasClass("k-list-optionlabel")?-1:e(i.items()).index(n)}else i.hasOptionLabel()&&(n-=1);r=i.dataSource.flatView()[n]}return r||(r=i._optionLabelDataItem()),r},refresh:function(){this.listView.refresh()},text:function(e){var n,i=this,r=i.options.ignoreCase;if((e=null===e?"":e)===t)return i._textAccessor();"string"==typeof e?(n=r?e.toLowerCase():e,i._select((function(e){return e=i._text(e),r&&(e=(e+"").toLowerCase()),e===n})).done((function(){i._textAccessor(i.dataItem()||e),i._refreshFloatingLabel()}))):i._textAccessor(e)},_clearFilter:function(){e(this.filterInput).val(""),s.fn._clearFilter.call(this)},value:function(e){var n=this,i=n.listView,r=n.dataSource;return e===t?(e=n._accessor()||n.listView.value()[0])===t||null===e?"":e:(n.requireValueMapper(n.options,e),!e&&n.hasOptionLabel()||(n._initialIndex=null),this.trigger("set",{value:e}),n._request&&n.options.cascadeFrom&&n.listView.bound()?(n._valueSetter&&r.unbind(g,n._valueSetter),n._valueSetter=function(){n.value(e)}.bind(n),void r.one(g,n._valueSetter)):(n._isFilterEnabled()&&i.bound()&&i.isFiltered()?n._clearFilter():n._fetchData(),void i.value(e).done((function(){n._old=n._valueBeforeCascade=n._accessor(),n._oldIndex=n.selectedIndex,n._refreshFloatingLabel()}))))},hasOptionLabel:function(){return this.optionLabel&&!!this.optionLabel[0]},_optionLabel:function(){var t=this,r=t.options,o=r.optionLabel,a=r.optionLabelTemplate;if(!o)return t.optionLabel.off().remove(),void(t.optionLabel=e());a||(a=e=>i("string"==typeof o?e:n.getter(r.dataTextField)(e))),"function"!=typeof a&&(a=n.template(a)),t.optionLabelTemplate=a,t.hasOptionLabel()||(t.optionLabel=e('<div role="option" class="k-list-optionlabel"></div>').prependTo(t.list)),t.optionLabel.html(a(o)).off().on(w,t._click.bind(t)).on(k,t._toggleHover)},_optionLabelText:function(){var e=this.options.optionLabel;return"string"==typeof e?e:this._text(e)},_optionLabelDataItem:function(){var n=this,i=n.options.optionLabel;return n.hasOptionLabel()?e.isPlainObject(i)?new d(i):n._assignInstance(n._optionLabelText(),""):t},_buildOptions:function(e){var n=this;if(n._isSelect){var i=n.listView.value()[0],r=n._optionLabelDataItem(),o=r&&n._value(r);i!==t&&null!==i||(i=""),r&&(o!==t&&null!==o||(o=""),r='<option value="'+o+'">'+n._text(r)+"</option>"),n._options(e,r,i),i!==a.unifyType(n._accessor(),typeof i)&&(n._customOption=null,n._custom(i))}},_listBound:function(){var e,t=this,n=t._initialIndex,i=t._state===C,r=t.dataSource.flatView();t._presetValue=!1,t._renderFooter(),t._renderNoData(),t._toggleNoData(!r.length),t._resizePopup(!0),t.popup.position(),t._buildOptions(r),i||(t._open&&t.toggle(t._allowOpening()),t._open=!1,t._fetch||(r.length?(!t.listView.value().length&&n>-1&&null!==n&&t.select(n),t._initialIndex=null,(e=t.listView.selectedDataItems()[0])&&t.text()!==t._text(e)&&t._selectValue(e)):t._textAccessor()!==t._optionLabelText()&&(t.listView.value(""),t._selectValue(null),t._oldIndex=t.selectedIndex))),t._hideBusy(),t.trigger("dataBound")},_listChange:function(){this._selectValue(this.listView.selectedDataItems()[0]),(this._presetValue||this._old&&-1===this._oldIndex)&&(this._oldIndex=this.selectedIndex)},_filterPaste:function(){this.options._allowFilterPaste&&this._search()},_attachFocusHandlers:function(){var e=this;e.wrapper.on("focusin"+p,e._focusinHandler.bind(e)).on("focusout"+p,e._focusoutHandler.bind(e)),e.filterInput&&e.filterInput.on("focusin"+p,e._focusinHandler.bind(e)).on("focusout"+p,e._focusoutHandler.bind(e))},_focusHandler:function(){this.wrapper.trigger("focus")},_focusinHandler:function(){this.wrapper.addClass(v),this._prevent=!1},_focusoutHandler:function(e){var t=this,n=window.self!==window.top;t.wrapper.find(e.relatedTarget).length>0||t._prevent||(clearTimeout(t._typingTimeout),l.mobileOS.ios&&n?t._change():t._blur(),t.wrapper.removeClass(v),t._prevent=!0,t._open=!1,t.element.trigger("blur"))},_wrapperMousedown:function(){this._prevent=!!this.filterInput},_wrapperClick:function(e){e.preventDefault(),this.popup.unbind("activate",this._focusInputHandler),this._focused=this.wrapper,this._prevent=!1,this._toggle()},_editable:function(e){var t=this,i=t.element,r=e.disable,o=e.readonly,a=t.wrapper.add(t.filterInput).off(h),s=t.wrapper.off(k);o||r?r?(a.removeAttr(x),s.addClass(_)):s.removeClass(_):(i.prop(f,!1).prop(m,!1),s.removeClass(_).on(k,t._toggleHover),a.attr(x,a.data(x)).attr(b,!1).attr(y,!1).on("keydown"+h,t,t._keydown.bind(t)).on(n.support.mousedown+h,t._wrapperMousedown.bind(t)).on("paste"+h,t._filterPaste.bind(t)),t.wrapper.on("click"+h,t._wrapperClick.bind(t)),t.filterInput?a.on("input"+h,t._search.bind(t)):a.on("keypress"+h,t._keypress.bind(t))),i.attr(f,r).attr(m,o),a.attr(b,r).attr(y,o)},_keydown:function(e){var t,n,i=this,r=e.keyCode,o=e.altKey,a=i.popup.visible();if(i.filterInput&&(t=i.filterInput[0]===c()),r===u.LEFT?(r=u.UP,n=!0):r===u.RIGHT&&(r=u.DOWN,n=!0),!n||!t)if(e.keyCode=r,(o&&r===u.UP||r===u.ESC)&&i._focusElement(i.wrapper),i._state===C&&r===u.ESC&&(i._clearFilter(),i._open=!1,i._state=S),r===u.ENTER&&i._typingTimeout&&i.filterInput&&a)e.preventDefault();else if(r!==u.SPACEBAR||t||(i.toggle(!a),e.preventDefault()),!(n=i._move(e))){if(!a||!i.filterInput){var s=i._focus();if(r===u.HOME?(n=!0,i._firstItem()):r===u.END&&(n=!0,i._lastItem()),n){if(i.trigger("select",{dataItem:i._getElementDataItem(i._focus()),item:i._focus()}))return void i._focus(s);i._select(i._focus(),!0).done((function(){a||i._blur()})),e.preventDefault()}}o||n||!i.filterInput||i._search()}},_matchText:function(e,n){var i=this.options.ignoreCase;return e!==t&&null!==e&&(e+="",i&&(e=e.toLowerCase()),0===e.indexOf(n))},_shuffleData:function(e,t){var n=this._optionLabelDataItem();return n&&(e=[n].concat(e)),e.slice(t).concat(e.slice(0,t))},_selectNext:function(){var e,t,n=this,i=n.dataSource.flatView(),r=i.length+(n.hasOptionLabel()?1:0),o=function(e,t){for(var n=0;n<e.length;n++)if(e.charAt(n)!==t)return!1;return!0}(n._word,n._last),a=n.selectedIndex;a=-1===a?0:A(a+=o?1:0,r),i=i.toJSON?i.toJSON():i.slice(),i=n._shuffleData(i,a);for(var s=0;s<r&&(t=n._text(i[s]),!o||!n._matchText(t,n._last))&&!n._matchText(t,n._word);s++);s!==r&&(e=n._focus(),n._select(A(a+s,r)).done((function(){var t=function(){n.popup.visible()||n._change()};n.trigger("select",{dataItem:n._getElementDataItem(n._focus()),item:n._focus()})?n._select(e).done(t):t()})))},_keypress:function(e){var t=this;if(0!==e.which&&e.keyCode!==n.keys.ENTER){var i=String.fromCharCode(e.charCode||e.keyCode);t.options.ignoreCase&&(i=i.toLowerCase())," "===i&&e.preventDefault(),t._word+=i,t._last=i,t._search()}},_popupOpen:function(e){var t=this.popup;e.isDefaultPrevented()||this._hasActionSheet()||(t.wrapper=n.wrap(t.element),t.element.closest(".km-root")[0]&&(t.wrapper.addClass("km-popup km-widget"),this.wrapper.addClass("km-widget")))},_popup:function(){s.fn._popup.call(this),this.popup.element.addClass("k-dropdownlist-popup"),this.popup.one("open",this._popupOpen.bind(this))},_postCreatePopup:function(){s.fn._postCreatePopup.call(this),this._attachFocusHandlers()},_getElementDataItem:function(e){return e&&e[0]?e[0]===this.optionLabel[0]?this._optionLabelDataItem():this.listView.dataItemByIndex(this.listView.getElementIndex(e)):null},_click:function(t){var n=this,i=t.item||e(t.currentTarget);t.preventDefault(),n.trigger("select",{dataItem:n._getElementDataItem(i),item:i})?n.close():(n._userTriggered=!0,n._select(i).done((function(){n._blur(),n._focusElement(n.wrapper)})))},_focusElement:function(e){var t=c(),n=this.wrapper,i=this.filterInput,r=e===i?n:i,o=l.mobileOS&&(l.touch||l.MSPointers||l.pointers);i&&i[0]===e[0]&&o||i&&(r[0]===t||this._focusFilter)&&(this._focusFilter=!1,this._prevent=!0,this._focused=e.trigger("focus"))},_searchByWord:function(e){if(e){var t=this;t.options.ignoreCase&&(e=e.toLowerCase()),t._select((function(n){return t._matchText(t._text(n),e)}))}},_inputValue:function(){return this.text()},_search:function(){var e=this,t=e.dataSource;if(clearTimeout(e._typingTimeout),e._isFilterEnabled())e._typingTimeout=setTimeout((function(){var t=e.filterInput.val();e._prev!==t&&(e._prev=t,e.search(t),e._resizeFilterInput()),e._typingTimeout=null}),e.options.delay);else{if(e._typingTimeout=setTimeout((function(){e._word=""}),e.options.delay),!e.listView.bound())return void t.fetch().done((function(){e._selectNext()}));e._selectNext()}},_get:function(t){var n,i,r,o="function"==typeof t,a=o?e():e(t);if(this.hasOptionLabel()&&("number"==typeof t?t>-1&&(t-=1):a.hasClass("k-list-optionlabel")&&(t=-1)),o){for(n=this.dataSource.flatView(),r=0;r<n.length;r++)if(t(n[r])){t=r,i=!0;break}i||(t=-1)}return t},_firstItem:function(){this.hasOptionLabel()?this._focus(this.optionLabel):this.listView.focusFirst()},_lastItem:function(){this._resetOptionLabel(),this.listView.focusLast()},_nextItem:function(){var e;return this.optionLabel.hasClass("k-focus")?(this._resetOptionLabel(),this.listView.focusFirst(),e=1):e=this.listView.focusNext(),e},_prevItem:function(){var e;if(!this.optionLabel.hasClass("k-focus"))return e=this.listView.focusPrev(),this.listView.focus()||this.options.virtual||this._focus(this.optionLabel),e},_focusItem:function(){var e=this.options,n=this.listView,i=n.focus(),r=n.select();(r=r[r.length-1])===t&&e.highlightFirst&&!i&&(r=0),r!==t?n.focus(r):!e.optionLabel||e.virtual&&"dataItem"===e.virtual.mapValueTo?n.scrollToIndex(0):(this._focus(this.optionLabel),this._select(this.optionLabel),this.listView.content.scrollTop(0))},_resetOptionLabel:function(e){this.optionLabel.removeClass("k-focus"+(e||"")).removeAttr("id")},_focus:function(e){var n=this.listView,i=this.optionLabel;if(e===t)return!(e=n.focus())&&i.hasClass("k-focus")&&(e=i),e;this._resetOptionLabel(),e=this._get(e),n.focus(e),-1===e&&(i.addClass("k-focus").attr("id",n._optionID),this.filterInput&&this.filterInput.removeAttr("aria-activedescendant").attr("aria-activedescendant",n._optionID))},_select:function(e,t){var n=this;return e=n._get(e),n.listView.select(e).done((function(){t||n._state!==C||(n._state=S),-1===e&&n._selectValue(null)}))},_selectValue:function(e){var n=this,i=n.options.optionLabel,r=n.listView.select(),o="",a="";(r=r[r.length-1])===t&&(r=-1),this._resetOptionLabel(" k-selected"),e||0===e?(a=e,o=n._dataValue(e),i&&(r+=1)):i&&(n._focus(n.optionLabel.addClass("k-selected")),a=n._optionLabelText(),o="string"==typeof i?"":n._value(i),r=0),n.selectedIndex=r,null===o&&(o=""),n._textAccessor(a),n._accessor(o,r),n._triggerCascade()},_mobile:function(){var e=this.popup,t=l.mobileOS;e.element.parents(".km-root").eq(0).length&&t&&(e.options.animation.open.effects=t.android||t.meego?"fadeIn":t.ios||t.wp?"slideIn:up":e.options.animation.open.effects)},_span:function(){var e,t,i=this,r=i.wrapper,a="span.k-input-value-text",s=n.guid(),l=i.options;(e=r.find(a))[0]||(t=o.renderButton('<button role="button" tabindex="-1" class="k-input-button" aria-label="select"></button>',{icon:"caret-alt-down",size:l.size,fillMode:l.fillMode,shape:"none",rounded:"none"}),r.append('<span id="'+s+'" unselectable="on" class="k-input-inner"><span class="k-input-value-text"></span></span>').append(t).append(i.element),e=r.find(a)),i.span=e,i._arrow=r.find(".k-input-button"),i._arrowIcon=i._arrow.find(".k-icon,.k-svg-icon")},_wrapper:function(){var e,t=this,n=t.element,i=n[0];(e=n.parent()).is("span.k-picker")||((e=n.wrap("<span />").parent())[0].style.cssText=i.style.cssText,e[0].title=i.title),t._focused=t.wrapper=e.addClass("k-picker k-dropdownlist").addClass(i.className).removeClass("input-validation-error").css("display","").attr({accesskey:n.attr("accesskey"),unselectable:"on",role:"combobox","aria-expanded":!1}),n.hide().removeAttr("accesskey")},_clearSelection:function(e){this.select(e.value()?0:-1)},_openHandler:function(e){this._adjustListWidth(),this.trigger("open")?e.preventDefault():(this.wrapper.attr("aria-expanded",!0),this.ul.attr("aria-hidden",!1))},_closeHandler:function(e){this.trigger("close")?e.preventDefault():(this.wrapper.attr("aria-expanded",!1),this.ul.attr("aria-hidden",!0))},_inputTemplate:function(){var e=this,t=e.options.valueTemplate;if(t=t?n.template(t):t=>i(e._text(t)),e.valueTemplate=t,e.hasOptionLabel()&&!e.options.optionLabelTemplate)try{e.valueTemplate(e._optionLabelDataItem())}catch(e){throw new Error("The `optionLabel` option is not valid due to missing fields. Define a custom optionLabel as shown here http://docs.telerik.com/kendo-ui/api/javascript/ui/dropdownlist#configuration-optionLabel")}},_textAccessor:function(n){var i=null,r=this.valueTemplate,o=this._optionLabelText(),a=this.span;if(n===t)return a.text();e.isPlainObject(n)||n instanceof d?i=n:o&&o===n&&(i=this.options.optionLabel),i||(i=this._assignInstance(n,this._accessor())),this.hasOptionLabel()&&(i!==o&&this._text(i)!==o||(r=this.optionLabelTemplate,"string"!=typeof this.options.optionLabel||this.options.optionLabelTemplate||(i=o)));try{a.html(r(i))}catch(e){a.html("")}},_preselect:function(e,t){e||t||(t=this._optionLabelText()),this._accessor(e),this._textAccessor(t),this._old=this._accessor(),this._oldIndex=this.selectedIndex,this.listView.setValue(e),this._initialIndex=null,this._presetValue=!0},_assignInstance:function(e,t){var n=this.options.dataTextField,i={};return n?(D(i,n.split("."),e),D(i,this.options.dataValueField.split("."),t),i=new d(i)):i=e,i}});function D(e,t,n){for(var i,r=0,o=t.length-1;r<o;++r)(i=t[r])in e||(e[i]={}),e=e[i];e[t[o]]=n}function A(e,t){return e>=t&&(e-=t),e}r.plugin(T),n.cssProperties.registerPrefix("DropDownList","k-picker-"),n.cssProperties.registerValues("DropDownList",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}])}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=i.Widget,o=n.keys,a=(n.mediaQuery,n.support,n.htmlEncode),s=n.template,l="caret-alt-to-left",c="caret-alt-to-right",d="caret-alt-left",u="caret-alt-right",h="caret-alt-to-left",p="caret-alt-to-right",f="caret-alt-left",m="caret-alt-right",g=":kendoFocusable:not([tabindex='-1'])",v="change",_=".kendoPager",b="click",y=Number.MAX_VALUE,w=!1;function k(e){return e.template({idx:e.idx,text:e.text,ns:n.ns,numeric:e.numeric,size:e.size,title:e.title||"",tabindex:e.navigatable?0:-1,navigatable:e.navigatable})}function x(e,t,n,i){return e({idx:t,text:n||t,selected:i||!1})}function C(t,i,r,o,a){return(({text:t,wrapClassName:i,className:r,size:o})=>`<button role="button" title="${t}" aria-label="${t}" class="k-pager-nav k-button k-button-flat k-button-flat-base k-icon-button ${i} ${o}">${n.ui.icon(e('<span class="k-button-icon"></span>'),r)}</button>`)({className:t,text:i,wrapClassName:r||"",id:o||"",size:a})}function S(e,t,i,r){e.find(`[class*="-i-${t}"]`).parent().attr(n.attr("page"),i).attr("tabindex",r?-1:0).attr("aria-disabled",r).toggleClass("k-disabled",r)}function T(e,t){S(e,l,1,t<=1)}function D(e,t){S(e,d,Math.max(1,t-1),t<=1)}function A(e,t,n){S(e,u,Math.min(n,t+1),t>=n)}function M(e,t,n){S(e,c,n,t>=n)}var E=r.extend({init:function(t,i){var o,s,g=this,y="",k="";if(r.fn.init.call(g,t,i),i=g.options,g._createDataSource(i),g.linkTemplate=n.template(g.options.linkTemplate),g.selectTemplate=n.template(g.options.selectTemplate),g.numericSelectItemTemplate=n.template(g.options.numericSelectItemTemplate),o=g.page(),s=g.totalPages(),g._refreshHandler=g.refresh.bind(g),g.dataSource.bind(v,g._refreshHandler),g.downEvent=n.applyEventMap("down",n.guid()),w=n.support.isRtl(t),g._numericWrap=g.element.find(".k-pager-numbers-wrap"),w?(l=p,c=h,d=m,u=f,g._numericWrap.length&&g._numericWrap.empty()):(l=h,c=p,d=f,u=m),i.size&&(y=n.getValidCssClass("k-button-","size",i.size),k="k-rounded-md "+n.getValidCssClass("k-picker-","size",i.size)),i.navigatable&&(g._id=g.element.attr("id")||n.guid()),g._template(),(i.previousNext||i.numeric)&&0===g._numericWrap.length&&(g._numericWrap=e("<div class='k-pager-numbers-wrap' />").appendTo(g.element)),i.previousNext&&(g._numericWrap.find("[class*='-i-"+l+"']").length||(g._numericWrap.append(C(l,i.messages.first,"k-pager-first",g._id,y)),T(g._numericWrap,o)),g._numericWrap.find("[class*='-i-"+d+"']").length||(g._numericWrap.append(C(d,i.messages.previous,null,g._id,y)),D(g._numericWrap,o))),i.numeric&&(g._numericSelect||(g._numericSelect=g._numericWrap.find(".k-dropdown"),0===g._numericSelect.length&&(g._numericSelect=e("<select aria-label='"+g.options.messages.numbersSelectLabel+"' class='k-dropdown k-picker k-picker-solid k-dropdown-list "+k+"' />").appendTo(g._numericWrap))),g.list||(g.list=g._numericWrap.find(".k-pager-numbers"),0===g.list.length&&(g.list=e('<div class="k-pager-numbers" />').appendTo(g._numericWrap))),i.dataSource&&!i.dataSource.total()&&(g._numericSelect.empty().append("<option value='0' />"),g.list.empty().append(g.selectTemplate({text:0,tabindex:i.navigatalbe?0:-1,navigatable:i.navigatable,title:n.format(i.messages.pageButtonLabel,0)})))),i.input&&(g.element.find(".k-pager-input").length||g.element.append('<span class="k-pager-input k-label">'+a(i.messages.page)+'<span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input class="k-input-inner" /></span>'+a(n.format(i.messages.of,s))+"</span>"),g.element.on("keydown"+_,".k-pager-input input",g._keydown.bind(g))),i.previousNext&&(g._numericWrap.find("[class*='-i-"+u+"']").length||(g._numericWrap.append(C(u,i.messages.next,null,g._id,y)),A(g._numericWrap,o,s)),g._numericWrap.find("[class*='-i-"+c+"']").length||(g._numericWrap.append(C(c,i.messages.last,"k-pager-last",g._id,y)),M(g._numericWrap,o,s))),i.pageSizes){if(!g.element.find(".k-pager-sizes").length){var x=i.pageSizes.length?i.pageSizes:["all",5,10,20],S=e.map(x,(function(e){return e.toLowerCase&&"all"===e.toLowerCase()?"<option value='all'>"+a(i.messages.allPages)+"</option>":"<option>"+e+"</option>"}));e('<span class="k-pager-sizes"><select></select><span>'+a(i.messages.itemsPerPage)+"</span></span>").appendTo(g.element).find("select").html(S.join("")).end().appendTo(g.element)}g.element.find(".k-pager-sizes select").val(g.pageSize()),n.ui.DropDownList&&g.element.find(".k-pager-sizes select").show().attr("aria-label",i.messages.pageSizeDropDownLabel).kendoDropDownList({size:i.size}),g.element.on(v+_,".k-pager-sizes select",g._change.bind(g))}i.refresh&&(g.element.find(".k-pager-refresh").length||g.element.append('<button role="button" href="#" class="k-pager-refresh k-button '+y+' k-button-flat k-button-flat-base k-icon-button" title="'+i.messages.refresh+'" aria-label="'+i.messages.refresh+'">'+n.ui.icon(e('<span class="k-button-icon"></span>'),"arrow-rotate-cw")+"</button>"),g.element.on(b+_,".k-pager-refresh",g._refreshClick.bind(g))),i.info&&(g.element.find(".k-pager-info").length||g.element.append('<span class="k-pager-info" />')),g.element.on(b+_,"button",g._click.bind(g)).on(v+_,"select.k-dropdown",g._numericSelectChange.bind(g)).addClass("k-pager"),i.size&&g.element.addClass(n.getValidCssClass("k-pager-","size",i.size)),i.autoBind&&g.refresh(),g._resizeHandler=g.resize.bind(g,!0),e(window).on("resize"+_,g._resizeHandler),g._navigatable(),g._responsive(),n.notify(g)},destroy:function(){var t=this;r.fn.destroy.call(t),t.element.off(_),t.dataSource.unbind(v,t._refreshHandler),t._refreshHandler=null,e(window).off("resize"+_,this._resizeHandler),n.destroy(t.element),t.element=t.list=null},events:[v],options:{name:"Pager",ARIATemplate:({page:e,totalPages:t})=>`Page navigation, page ${e} of ${t}`,selectTemplate:({text:e,title:t,tabindex:n,size:i})=>`<button role="button" aria-current="page" tabindex="${n}" aria-label="${t}" class="k-button ${i} k-button-flat k-button-flat-primary k-selected"><span class="k-button-text">${a(e)}</span></button>`,linkTemplate:({ns:e,idx:t,text:n,title:i,tabindex:r,size:o})=>`<button class="k-button ${o} k-button-flat k-button-flat-primary" tabindex="${r}" href="#" data-${e}page="${t}" ${""!==i?`title="${i}"`:""}><span class="k-button-text">${a(n)}</span></button>`,numericSelectItemTemplate:({idx:e,selected:t,text:n})=>`<option value="${e}" ${t?'selected="selected"':""}>${a(n)}</option>`,buttonCount:10,autoBind:!0,numeric:!0,info:!0,input:!1,previousNext:!0,pageSizes:!1,refresh:!1,responsive:!0,navigatable:!1,size:"medium",messages:{allPages:"All",display:"{0} - {1} of {2} items",empty:"No items to display",page:"Page",of:"of {0}",itemsPerPage:"items per page",pageButtonLabel:"Page {0}",pageSizeDropDownLabel:"Page sizes drop down",numbersSelectLabel:"Page select",first:"Go to the first page",previous:"Go to the previous page",next:"Go to the next page",last:"Go to the last page",refresh:"Refresh",morePages:"More pages"}},setDataSource:function(e){var t=this;t.dataSource.unbind(v,t._refreshHandler),t.dataSource=t.options.dataSource=e,e.bind(v,t._refreshHandler),t.options.autoBind&&e.fetch()},_aria:function(){this.element.attr({role:"application","aria-roledescription":"pager","aria-keyshortcuts":"Enter ArrowRight ArrowLeft"})},_adaptiveStep:function(e,t,n){var i=this;switch(e){case 0:return i._toggleButtons(t,n);case 1:return i._toggleRefresh(t,n);case 2:return i._togglePagerInfo(t,n);case 3:return i._toggleInputSizesLabel(t,n);case 4:return i._togglePageSizesLabel(t,n);case 5:return i._togglePageSizesDropDown(t,n);case 6:return i._togglePageInputs(t,n)}},_calculateNeededWidth:function(){var t=0,n=parseInt(this.element.css("gap"));return this.element.children().each((function(){const i=e(this),r=i.hasClass("k-pager-info");r&&i.removeClass("k-pager-info k-label"),t+=i.is(":visible")?i.width():0,t+=n,r&&i.addClass("k-pager-info k-label")})),t},_resize:function(e){var t=this;if(t._responsive(e),t.element.is(":visible")&&t._lastWidth&&t.options.responsive){if(t._lastWidth<e.width)for(let n=6;n>=0;n--){const i=t._calculateNeededWidth();if(e.width<i)break;if(t._adaptiveStep(n,!1,e.width-i))break}else if(t._lastWidth>e.width)for(let n=0;n<7&&!(e.width>t._calculateNeededWidth());n++)t._adaptiveStep(n,!0);t._lastWidth=e.width}},_toggleButtons:function(e,t){this._numericWrap&&this.list&&this._numericSelect&&(e?(this._numericSelect.show(),this.list.hide()):t&&this.list.width()-this._numericSelect.width()<t&&(this._numericSelect.hide(),this.list.show()))},_toggleRefresh:function(e,t){if(!this.options.refresh)return;const n=this.element.find(".k-pager-refresh");if(e)n.hide();else{if(!(t&&n.width()<t))return!0;n.show()}},_togglePagerInfo:function(e,t){if(!this.options.info)return;const n=this.element.find(".k-pager-info");if(e)n.hide();else if(t&&n.width()<t)n.show();else if(!n.is(":visible"))return!0},_toggleInputSizesLabel:function(e,t){if(!this.options.input)return;const n=this.element.find(".k-pager-input").children(),i=n.eq(0).add(n.eq(2));if(e)i.hide();else{if(!(t&&n.eq(0).width()+n.eq(2).width()<t))return!0;i.show()}},_togglePageSizesLabel:function(e,t){if(!this.options.pageSizes)return;const n=this.element.find(".k-pager-sizes").children().eq(1);if(e)n.hide();else{if(!(t&&n.width()<t))return!0;n.show()}},_togglePageSizesDropDown:function(e,t){if(!this.options.pageSizes)return;const n=this.element.find(".k-pager-sizes .k-picker");if(e)n.hide();else{if(!(t&&n.width()<t))return!0;n.show()}},_togglePageInputs:function(e,t){if(this.options.input&&this._numericSelect)if(e)this._numericSelect.hide();else{if(!(t&&this._numericSelect.width()<t)||this.list.is(":visible"))return!0;this._numericSelect.show()}},_createDataSource:function(e){this.dataSource=n.data.DataSource.create(e.dataSource)},_responsive:function(e){var t,n,i=this,r=i.options;r.responsive?(t=i.element.outerWidth(),e&&e.width>0&&(t=e.width),n=i.element.find(".k-pager-info"),t<=480?(n.hide(),i.element.find(".k-pager-sizes").children().hide(),r.numeric&&(i._numericSelect.show(),i.list.hide())):t<=600?(n.hide(),r.numeric&&(i._numericSelect.show(),i.list.hide())):r.numeric&&(i._numericSelect.hide(),i.list.show())):i._numericSelect&&i._numericSelect.hide()},refresh:function(t){var i,r,o,s=this,l=1,c=s.page(),d="",u="",h=s.options,p=s.pageSize(),f=s._collapsedTotal(),m=s.dataSource._isGroupPaged()?s.dataSource.groupsTotal(!0):s.dataSource.total(),g=s.totalPages(),v=s.linkTemplate,_=h.navigatable,b=s.numericSelectItemTemplate,w=h.size?n.getValidCssClass("k-button-","size",h.size):"",C=h.buttonCount;if(!t||"itemchange"!=t.action){if(h.numeric){for(c>C&&(l=0===(o=c%C)?c-C+1:c-o+1),r=Math.min(l+C-1,g),l>1&&(d+=k({template:v,navigatable:_,size:w,idx:l-1,text:"...",numeric:!1,title:h.messages.morePages}),u+=x(b,l-1,h.messages.morePages)),i=l;i<=r;i++)d+=k({template:i==c?s.selectTemplate:v,navigatable:_,idx:i,text:i,size:w,numeric:!0,title:n.format(h.messages.pageButtonLabel,i)}),u+=x(b,i,i,i==c);r<g&&(d+=k({template:v,navigatable:_,idx:i,size:w,text:"...",numeric:b,title:h.messages.morePages}),u+=x(b,i,h.messages.morePages)),""===d&&(d=s.selectTemplate({text:0,size:w,tabindex:_?0:-1,navigatable:_,title:n.format(h.messages.pageButtonLabel,0)}),u=e("<option value='0' />")),s.list.html(d),s._numericSelect.html(u)}if(h.info&&(d=m>0?n.format(h.messages.display,s.dataSource.options.endless?1:Math.min((c-1)*(s.dataSource.pageSize()||0)+1,f),Math.min(c*p,f),m):h.messages.empty,s.element.find(".k-pager-info").html(d)),h.input&&s.element.find(".k-pager-input").html("<span>"+a(s.options.messages.page)+'</span><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input class="k-input-inner" aria-label="'+s.options.messages.page+" "+c+'"></span><span>'+a(n.format(h.messages.of,g))+"</span>").find("input").val(c).attr("disabled",m<1).attr("aria-disabled",m<1).toggleClass("k-disabled",m<1),h.previousNext&&(T(s.element,c),D(s.element,c),A(s.element,c,g),M(s.element,c,g)),h.pageSizes){var S=p;s.element.find(".k-pager-sizes option[value='all']").length>0&&(p===this.dataSource.total()||p==y)&&(p="all",S=h.messages.allPages),s.element.find(".k-pager-sizes select").val(p).filter("["+n.attr("role")+"=dropdownlist]").kendoDropDownList("value",p).kendoDropDownList("text",S)}s._restoreFocus(l,r,g),s._excludeChildrenFromTab(),s._updateAria(),g?(s._lastWidth=n._outerWidth(s.element)+12,s.resize(!0)):s._lastWidth&&(s._lastWidth=n._outerWidth(s.element))}},_excludeChildrenFromTab:function(){var t=n._activeElement();!this.options.navigatable||t!==this.element[0]&&e.contains(this.element[0],t)||this.element.find(g).attr("tabindex",-1)},_restoreFocus:function(e,t,n){var i=this;i.options.navigatable&&(i._focusSelected&&(i.element.find(".k-selected").trigger("focus"),i._focusSelected=null),null!==i._focusMore&&(t<n&&i._focusMore&&i.list.find("li").last().find("a").trigger("focus"),!i._focusMore&&e>1&&i.list.find("li").first().find("a").trigger("focus"),i._focusMore=null))},_restoreTabIndexes:function(){this.element.find("[tabindex='-1']:not(.k-disabled):not(.k-dropdownlist > .k-icon-button)").attr("tabindex",0)},_collapsedTotal:function(){return this.dataSource.total()},_keydown:function(e){if(e.keyCode===n.keys.ENTER){var t=this.element.find(".k-pager-input").find("input"),i=parseInt(t.val(),10);(isNaN(i)||i<1||i>this.totalPages())&&(i=this.page()),t.val(i),this.page(i)}},_refreshClick:function(e){e.preventDefault(),this.dataSource.read()},_change:function(e){var n=e.currentTarget.value,i=parseInt(n,10),r=this.dataSource;isNaN(i)?"all"==(n+"").toLowerCase()&&(r._pageSize=t,r._take=t,r._skip=0,r.fetch()):r.pageSize(i)},_template:function(){this._ariaTemplate=s(this.options.ARIATemplate).bind(this)},_updateAria:function(){this.options.navigatable&&this.element.attr("aria-label",this._ariaTemplate({page:this.page(),totalPages:this.totalPages()}))},_navigatable:function(){var e=this;e.options.navigatable&&(e._aria(),e.element.attr("id",e._id),e._template(),e._updateAria(),e._tabindex(e.element),e.element.on("keydown"+_,e,e._keyDown.bind(e)),e.element.on("focusout"+_,(function(){e.element.removeClass("k-focus")})),e.element.on("focusin"+_,(function(t){e.element.addClass("k-focus"),t.target===e.element[0]?e.element.find(g).attr("tabindex",-1):e.element.removeClass("k-focus")})))},_keyDown:function(t){var n,i,r=this,a=e(t.target),s=!1;a[0]===r.element[0]&&t.keyCode==o.ENTER&&(r._restoreTabIndexes(),r.element.find(g).first().trigger("focus"),s=!0),a[0]!==r.element[0]&&t.keyCode==o.ESC&&(r.element.trigger("focus"),s=!0),a[0]===r.element[0]&&t.keyCode==o.HOME&&(r.page(1),s=!0),a[0]===r.element[0]&&t.keyCode==o.END&&(r.page(r.totalPages()),s=!0),a[0]!==r.element[0]||t.keyCode!=(w?o.LEFT:o.RIGHT)&&t.keyCode!=o.PAGEDOWN||(r.page(r.page()+1),s=!0),a[0]!==r.element[0]||t.keyCode!=(w?o.RIGHT:o.LEFT)&&t.keyCode!=o.PAGEUP||(r.page(r.page()-1||1),s=!0),a[0]!==r.element[0]&&t.keyCode==o.TAB&&(r.options._isToolbarItem&&r._restoreTabIndexes(),i=(n=r.element.find(g)).index(a),t.shiftKey?i-1<0?n.last().trigger("focus"):n.eq(i-1).trigger("focus"):i+1<n.length?n.eq(i+1).trigger("focus"):n.first().trigger("focus"),s=!0),s&&(t.preventDefault(),t.stopPropagation())},_numericSelectChange:function(e){var t=e.currentTarget.value,n=parseInt(t,10);this.page(n)},_click:function(t){const i=this,r=e(t.currentTarget);t.preventDefault(),i.options.navigatable&&(r.attr("title")==i.options.messages.morePages?i._focusMore=r.parent().index():r.hasClass("k-pager-refresh")||r.hasClass("k-pager-nav")||(i._focusSelected=!0),i._restoreTabIndexes()),r.is(".k-disabled")||i.page(parseInt(r.attr(n.attr("page")),10))},totalPages:function(){return Math.ceil((this.dataSource.total()||0)/(this.pageSize()||1))},pageSize:function(){return this.dataSource.pageSize()||this.dataSource.total()},page:function(e){if(!e)return this.dataSource.total()>0?this.dataSource.page():0;this.trigger("pageChange",{index:e})||(this.dataSource.page(e),this.trigger(v,{index:e}))}});i.plugin(E)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=e.extend,o=n.htmlEncode,a=window.setTimeout,s="click",l="show",c="hide",d="k-notification",u=".k-notification-actions .k-icon",h="k-hiding",p="info",f="success",m="warning",g="error",v={[p]:"info-circle",[g]:"x-outline",[m]:"exclamation-circle",[f]:"check-outline"},_="top",b="left",y="bottom",w="right",k=".kendoNotification",x=t=>({typeIcon:i,content:r,closeButton:a})=>n.ui.icon(e(`<span class="k-notification-status" title="${o(i)}"></span>`),{icon:v[o(i)]||o(i)})+`<div class="k-notification-content">${t?o(r):r}</div>`,C=x(!1),S=x(!0),T={close:{template:n.ui.icon(e('<span aria-hidden="true" title="Hide"></span>'),{icon:"x"})}},D=i.extend({init:function(t,r){let o=this;i.fn.init.call(o,t,r),r&&r.button&&!r.position&&o.options.position&&(o.options.position.right=40),(r=o.options).appendTo&&e(r.appendTo).is(t)||o.element.hide(),o._compileTemplates(r.templates),o._guid="_"+n.guid(),o._isRtl=n.support.isRtl(t),o._compileStacking(r.stacking,r.position.top,r.position.left),n.notify(o)},events:[l,c],options:{name:"Notification",position:{pinned:!0,top:null,left:null,bottom:20,right:20},stacking:"default",hideOnClick:!0,button:!1,allowHideAfter:0,autoHideAfter:5e3,appendTo:null,width:null,height:null,templates:[],title:null,animation:{open:{effects:"fade:in",duration:300},close:{effects:"fade:out",duration:600,hide:!0}}},_compileTemplates:function(t){var i=this,r=n.template;i._compiled={},e.each(t,(function(t,n){i._compiled[n.type]=r(n.template||e("#"+n.templateId).html())})),i._defaultCompiled=r(C),i._safeCompiled=r(S)},_getCompiled:function(e,t){var n=t?this._safeCompiled:this._defaultCompiled;return e&&this._compiled[e]||n},_compileStacking:function(e,t,n){var i,r,o=this,a={paddingTop:0,paddingRight:0,paddingBottom:0,paddingLeft:0},s=null!==n?b:w;switch(e){case"down":i=y+" "+s,r=_+" "+s,delete a.paddingBottom;break;case w:i=_+" "+w,r=_+" "+b,delete a.paddingRight;break;case b:i=_+" "+b,r=_+" "+w,delete a.paddingLeft;break;case"up":i=_+" "+s,r=y+" "+s,delete a.paddingTop;break;default:null!==t?(i=y+" "+s,r=_+" "+s,delete a.paddingBottom):(i=_+" "+s,r=y+" "+s,delete a.paddingTop)}o._popupOrigin=i,o._popupPosition=r,o._popupPaddings=a},_attachPopupEvents:function(e,t){var n,i=this,r=e.allowHideAfter,o=!isNaN(r)&&r>0;function l(e){e.on(s+k,(function(){i._hidePopup(t)}))}e.hideOnClick?t.bind("activate",(function(){o?a((function(){l(t.element)}),r):l(t.element)})):e.button&&(n=t.element.find(u),o?a((function(){l(n)}),r):l(n))},_showPopup:function(t,i){var o,s,l=this,c=i.autoHideAfter,d=i.position.left,p=i.position.top;s=e("."+l._guid+":not(."+h+")").last(),o=new n.ui.Popup(t,{anchor:s[0]?s:document.body,origin:l._popupOrigin,position:l._popupPosition,_resizeOnWrap:!0,animation:i.animation,copyAnchorStyles:!1,autosize:!0,modal:!0,collision:"",isRtl:l._isRtl,close:function(){l._triggerHide(this.element)},deactivate:function(e){e.sender.element.off(k),e.sender.element.find(u).off(k),e.sender.destroy()}}),l._attachPopupEvents(i,o),t.removeClass("k-group k-reset k-popup"),s[0]?o.open():(null===d&&(d=e(window).width()-t.outerWidth()-i.position.right),null===p&&(p=e(window).height()-t.outerHeight()-i.position.bottom),o.open(d,p)),t.removeClass("k-popup"),o.wrapper.addClass(l._guid).css(r({margin:0,zIndex:10050},l._popupPaddings)),i.position.pinned?(o.wrapper.css("position","fixed"),s[0]&&l._togglePin(o.wrapper,!0)):s[0]||l._togglePin(o.wrapper,!1),c>0&&a((function(){l._hidePopup(o)}),c)},_hidePopup:function(e){e.wrapper.addClass(h),e.close()},_togglePin:function(t,n){var i=e(window),r=n?-1:1;t.css({top:parseInt(t.css(_),10)+r*i.scrollTop(),left:parseInt(t.css(b),10)+r*i.scrollLeft()})},_attachStaticEvents:function(e,t){var n=this,i=e.allowHideAfter,r=!isNaN(i)&&i>0;function o(e){e.on(s+k,n._hideStatic.bind(n,t))}e.hideOnClick?r?a((function(){o(t)}),i):o(t):e.button&&(r?a((function(){o(t.find(u))}),i):o(t.find(u)))},_showStatic:function(t,i){var r=this,o=i.autoHideAfter,s=i.animation,l="up"==i.stacking||i.stacking==b?"prependTo":"appendTo";r._hideTimeouts||(r._hideTimeouts=[]),t.removeClass("k-popup").addClass(r._guid)[l](i.appendTo).hide().kendoAnimate(s.open||!1),t.css("display",""),r.getNotifications().each((function(t,s){r._attachStaticEvents(i,e(s)),o>0&&!e(s).attr(n.attr("has-hidetimeout"))&&(e(s).attr(n.attr("has-hidetimeout"),!0),r._hideTimeouts.push(a((function(){r._hideStatic(e(s))}),o)))}))},_hideStatic:function(e){e.kendoAnimate(r(this.options.animation.close||!1,{complete:function(){e.off(k).find(u).off(k),e.remove()}})),this._triggerHide(e)},_triggerHide:function(e){this.trigger(c,{element:e})},show:function(i,o,a){var s,c,u=this,h=u.options,f=e('<div role="alert" aria-live="polite" class="k-notification"></div>'),m=n.guid();return o||(o=p),f.attr("aria-label",o),null!==i&&i!==t&&""!==i&&(n.isFunction(i)&&(i=i()),c={typeIcon:o,content:"",closeButton:h.button},s=e.isPlainObject(i)?r(c,i):r(c,{content:i}),f.addClass(d+"-"+o).toggleClass(d+"-closable",h.button).attr({"data-role":"alert",title:h.title}).css({width:h.width,height:h.height}).append(u._getCompiled(o,a)(s)),u.options.button&&f.append(u.addActions("close")),f.find(".k-notification-content").attr("id",m),f.attr("aria-describedby",m),e(h.appendTo)[0]?u._showStatic(f,h):u._showPopup(f,h),u.trigger(l,{element:f})),u},showText:function(e,t){this.show(e,t,!0)},info:function(e){return this.show(e,p)},success:function(e){return this.show(e,f)},warning:function(e){return this.show(e,m)},error:function(e){return this.show(e,g)},hide:function(){var t=this,n=t.getNotifications();return t.options.appendTo?(t._hideTimeouts&&t._hideTimeouts.forEach(clearTimeout),t._hideTimeouts=[],n.each((function(n,i){t._hideStatic(e(i))}))):n.each((function(n,i){var r=e(i).data("kendoPopup");r&&t._hidePopup(r)})),t},getNotifications:function(){var t=e("."+this._guid+":not(."+h+")");return this.options.appendTo?t:t.find(">.k-child-animation-container >."+d)},setOptions:function(e){var n,r=this;i.fn.setOptions.call(r,e),n=r.options,e.templates!==t&&r._compileTemplates(n.templates),e.stacking===t&&e.position===t||r._compileStacking(n.stacking,n.position.top,n.position.left)},destroy:function(){i.fn.destroy.call(this),this.getNotifications().off(k).find(u).off(k)},addActions:function(t){var n=e('<span class="k-notification-actions"/>');return Array.isArray(t)||(t=[t]),t.forEach((function(t){e(T[t].template).wrap(`<span class="k-notification-action k-notification-${t}-action">`).parent().appendTo(n)})),n}});n.ui.plugin(D)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=t.ui.Popup,r=t.isFunction,o=e.isPlainObject,a=e.extend,s=e(document),l=t.isLocalUrl,c="_tb_active",d="aria-describedby",u="show",h="hide",p="error",f="contentLoad",m="requestStart",g="k-content-frame",v=({autoHide:n,callout:i,dir:r})=>`<div role="tooltip" class="k-tooltip${n?"":" k-tooltip-closable"}"><div class="k-tooltip-content"></div>`+(n?"":`<div class="k-tooltip-button">${t.ui.icon(e('<span title="Close"></span>'),{icon:"x"})}</div>`)+(i?`<div class="k-callout k-callout-${r}"></div>`:"")+"</div>",_=t.template((({content:e})=>`<iframe frameborder='0' class='${g}' src='${e.url}'>This page requires frames in order to show content</iframe>`)),b=".kendoTooltip",y={bottom:{origin:"bottom center",position:"top center"},top:{origin:"top center",position:"bottom center"},left:{origin:"center left",position:"center right",collision:"fit flip"},right:{origin:"center right",position:"center left",collision:"fit flip"},center:{position:"center center",origin:"center center"}},w={top:"bottom",bottom:"top",left:"right",right:"left",center:"center"},k={bottom:"n",top:"s",left:"e",right:"w",center:"n"},x={horizontal:{offset:"top",size:"outerHeight"},vertical:{offset:"left",size:"outerWidth"}};function C(e){for(;e.length&&!S(e);)e=e.parent()}function S(e){var n=e.data(t.ns+"title");if(n)return e.attr("title",n),e.removeData(t.ns+"title"),!0}function T(e){var n=e.attr("title");if(n)return e.data(t.ns+"title",n),e.attr("title",""),!0}function D(e){for(;e.length&&!e.is("body")&&!T(e);)e=e.parent()}var A=n.extend({init:function(e,i){var r,o=this;n.fn.init.call(o,e,i),r=o.options.position.match(/left|right/)?"horizontal":"vertical",o.dimensions=x[r],t.support.touch&&this._isShownOnMouseEnter()&&o.element.on(t.support.mousedown+b,o.options.filter,o._showOn.bind(o)),o.element.on(o.options.showOn+b,o.options.filter,o._showOn.bind(o)),"click"===o.options.showOn&&o.element.on("keydown"+b,o.options.filter,o._keydown.bind(o))},options:{name:"TooltipBase",filter:"",offset:0,showAfter:100,hideAfter:100,callout:!0,position:"bottom",showOn:"mouseenter",animation:{open:{effects:"fade:in",duration:0},close:{duration:40,hide:!0}}},destroy:function(){var e=this.popup;e&&(e.element.off(b),e.destroy()),clearTimeout(this.timeout),n.fn.destroy.call(this)},hide:function(){this.popup&&this.popup.close()},show:function(e){e=e||this.element,this._saveTitle(e),this._show(e)},target:function(){return this.popup?this.popup.options.anchor:null},_keydown:function(n){var i=e(n.currentTarget);n.keyCode==t.keys.ENTER&&this._show(i)},_showOn:function(t){const n=this,i=e(t.currentTarget);n._isShownOnClick()&&!n._isShownOnMouseEnter()?n._show(i):n._isShownOnFocus()?(n._saveTitle(i),n._show(i)):(clearTimeout(n.timeout),n.timeout=setTimeout((function(){n._show(i)}),n.options.showAfter))},_isShownOnFocus:function(){return this.options.showOn&&this.options.showOn.match(/focus/)},_isShownOnMouseEnter:function(){return this.options.showOn&&this.options.showOn.match(/mouseenter/)},_isShownOnClick:function(){return this.options.showOn&&this.options.showOn.match(/click/)},_recalculatePopupDimensions:function(){var e=this;e.popup.wrapper.css("height",t._outerHeight(e.popup.element)+"px"),e.popup.wrapper.css("width",t._outerWidth(e.popup.element)+"px"),e.popup.position(),e._positionCallout()},_positionCallout:function(){var t=this,n=t.options.position,i=t.dimensions,r=i.offset,o=t.popup,a=o.options.anchor,s=e(a).offset(),l=e(o.element).offset(),c=k[o.flipped?w[n]:n],d=s[r]-l[r]+e(a)[i.size]()/2;t._offset(n,t.options.offset),t.arrow.removeClass("k-callout-n k-callout-s k-callout-w k-callout-e").addClass("k-callout-"+c).css(r,d)},_offset:function(e,n,i){var r=this,o="top"==e||"left"==e,a=r.popup.flipped,s=o&&a||!o&&!a?1:-1,l=o?"margin-"+e:"margin-"+w[e],c=(i||t._outerWidth(r.arrow))/2+n;r.popup.wrapper.css(l,c*s+"px")},_addDescribedBy:function(){var e=this,n=e.popup.options.anchor,i=n[0].id||e.element[0].id||t.guid(),r=[];n.attr(d)&&r.push(n.attr(d)),i&&(r.push(i+c),n.attr(d,r.join(" ")),e.popup.element.attr("id",i+c))},_removeDescribedBy:function(e){var t,n,i,r=this.popup.element.attr("id"),o=e.attr(d);o&&((t=o.split(" "))&&t.length>0&&(n=t.filter((function(e){return e!==r}))),n&&n.length>0?(i=n.join(" "),e.attr(d,i)):e.removeAttr(d))},_openPopup:function(){this.popup&&(this.popup.visible()||(this.popup._hovered=!0),this.popup._shouldCorrectWidth=!1,this.popup.open())}});t.ui.plugin(A);var M=A.extend({init:function(e,n){var i,r=this;A.fn.init.call(r,e,n),i=r.options.position.match(/left|right/)?"horizontal":"vertical",r.dimensions=x[i],r._documentKeyDownHandler=r._documentKeyDown.bind(r),(this._isShownOnMouseEnter()||this._isShownOnClick())&&r.element.on("mouseenter"+b,r.options.filter,r._mouseenter.bind(r)),this.options.autoHide&&this._isShownOnMouseEnter()&&r.element.on("mouseleave"+b,r.options.filter,r._mouseleave.bind(r)),this.options.autoHide&&this._isShownOnFocus()&&r.element.on("blur"+b,r.options.filter,r._blur.bind(r)),t.support.touch&&r.element.on(t.support.mousedown+b,r.options.filter,r._mouseenter.bind(r))},options:{name:"Tooltip",filter:"",content:function(e){return e.target.data(t.ns+"title")},showAfter:100,callout:!0,offset:0,position:"bottom",showOn:"mouseenter",autoHide:!0,width:null,height:null,animation:{open:{effects:"fade:in",duration:0},close:{duration:40,hide:!0}}},events:[u,h,f,p,m],_mouseenter:function(t){D(e(t.currentTarget))},_saveTitle:function(e){D(e)},_appendContent:function(e){var n,i=this,a=i.options.content,s=i.content,c=i.options.iframe;o(a)&&a.url?("iframe"in i.options||(c=!l(a.url)),i.trigger(m,{options:a,target:e}),c?(s.hide(),(n=s.find("."+g)[0])?n.src=a.url||n.src:s.html(_({content:a})),s.find("."+g).off("load"+b).on("load"+b,(function(){i.trigger(f),s.show()}))):(s.empty(),t.ui.progress(s,!0),i._ajaxRequest(a))):a&&r(a)?(a=a({sender:this,target:e}),s.html(a||"")):s.html(a)},_verifyContentLoaded(){var e=this,t=e.content.find("[src]"),n=t.length,i=0;0!==n?t.on("load",(function(){i++,n===i&&e._recalculatePopupDimensions()})):e._recalculatePopupDimensions()},_ajaxRequest:function(e){var n=this;jQuery.ajax(a({type:"GET",dataType:"html",cache:!1,error:function(e,i){t.ui.progress(n.content,!1),n._recalculatePopupDimensions(),n.trigger(p,{status:i,xhr:e})},success:function(e){t.ui.progress(n.content,!1),n.content.html(e),n._verifyContentLoaded(),n.trigger(f)}.bind(n)},e))},_documentKeyDown:function(e){e.keyCode===t.keys.ESC&&this.hide()},refresh:function(){var e=this.popup;e&&e.options.anchor&&this._appendContent(e.options.anchor)},_show:function(e){var t=this,n=t.target();let i=!1;t.popup||(t._initPopup(),i=!0),n&&n[0]!=e[0]&&(t.popup.close(!0),t.popup.element.kendoStop(!0,!0)),n&&n[0]==e[0]||(t._appendContent(e),t.popup.options.anchor=e),t.popup.one("deactivate",(function(){C(e),t._removeDescribedBy(e),this.element.removeAttr("id").attr("aria-hidden",!0),s.off("keydown"+b,t._documentKeyDownHandler)})),t._openPopup(),i&&(t.options.autoHide&&this._isShownOnMouseEnter()?t.popup.wrapper.on("mouseleave"+b,t._mouseleave.bind(t)):t.popup.element.on("click"+b,".k-tooltip-button",t._closeButtonClick.bind(t)),i=!1)},_initPopup:function(){var n=this,r=n.options,o=e(t.template(v)({callout:r.callout&&"center"!==r.position,dir:k[r.position],autoHide:r.autoHide}));n.popup=new i(o,a({autosize:!0,activate:function(){n._addDescribedBy(),r.callout?n._positionCallout():n._offset(n.options.position,n.options.offset),this.element.removeAttr("aria-hidden"),s.on("keydown"+b,n._documentKeyDownHandler),n.trigger(u),n.popup._hovered=undefined},close:function(){n.trigger(h)},copyAnchorStyles:!1,animation:r.animation},y[r.position])),o.css({width:r.width,height:r.height}),n.content=o.find(".k-tooltip-content"),n.arrow=o.find(".k-callout")},_closeButtonClick:function(e){e.preventDefault(),this.hide()},_mouseleave:function(t){const n=this,i=e(t.relatedTarget).closest(".k-animation-container").length>0;let r=!e(t.relatedTarget).is(n.element);n.options.filter&&(r=r?!n.element.find(t.relatedTarget).length>0:!r);const o="center"!==n.options.position||r&&!i;clearTimeout(n.timeout),o&&(n.timeout=setTimeout((function(){n._closePopup(t.currentTarget)}),n.options.hideAfter))},_blur:function(e){this._closePopup(e.currentTarget)},_closePopup:function(t){this.popup&&!this.popup._hovered?this.popup.close():C(e(t))},destroy:function(){this.element.off(b),s.off("keydown"+b,this._documentKeyDownHandler),A.fn.destroy.call(this)}});t.ui.plugin(M)}(window.kendo.jQuery);kendo;!function(e,t){let n=window.kendo,i=n.support,r=n.ui,o=r.Widget,a=n.keys,s=n.parseDate,l=n.htmlEncode,c=n.date.adjustDST,d=n.date.weekInYear,u=n.ui.Selectable,h=n.ui.RangeSelectable,p=n._extractFormat,f=n.template,m=n.getCulture,g="transform-origin",v=f((e=>`<td class="${e.cssClass}" role="gridcell"><span tabindex="-1" class="k-link" data-href="#" data-${e.ns}value="${e.dateString}">${e.value}</span></td>`)),_=f((()=>'<td role="gridcell" class="k-calendar-td k-empty"></td>')),b=f((()=>'<td role="gridcell" class="k-calendar-td k-empty">&nbsp;</td>')),y=f((e=>`<td class="k-calendar-td k-alt">${e.weekNumber}</td>`)),w=n._outerWidth,k=".kendoCalendar",x="click"+k,C="keydown"+k,S="id",T="slideIn",D="month",A="century",M="change",E="navigate",I="value",z="k-disabled",P="k-focus",H="k-other-month",F="k-empty",R="td:has(.k-link)",L="start",B="td:has(.k-link):not(."+z+"):not(."+F+")",O="k-selected",V="blur"+k,N="focus",$=N+k,U=i.touch?"touchstart":"mouseenter",W=i.touch?"touchstart"+k:"mouseenter"+k,j=i.touch?"touchend"+k+" touchmove"+k:"mouseleave"+k,q=864e5,G="_prevArrow",K="_nextArrow",Y="aria-disabled",Q="aria-selected",X="aria-label",Z=e.extend,J=Date,ee={month:0,year:1,decade:2,century:3},te=".k-header, .k-calendar-header";var ne=o.extend({init:function(t,i){var r,a=this;(i=i||{}).componentType=i.componentType||"classic",o.fn.init.call(a,t,i),t=a.wrapper=a.element,(i=a.options).url=n.unescape(i.url),a.options.disableDates=be(a.options.disableDates),a._templates(),a._selectable(),a._header(),a._viewWrapper(),a.options.hasFooter?a._footer(a.footer):(a._today=a.element.find(".k-calendar-nav-today"),a._toggle()),t.addClass("k-calendar k-calendar-md "+(i.weekNumber?" k-week-number":"")).on(W+" "+j,R,fe).on(C,"table.k-calendar-table",a._move.bind(a)).on(x+" touchend",B,(function(t){var n=t.currentTarget.firstChild,i=we(n);-1!=e(n).data("href").indexOf("#")&&t.preventDefault(),"month"==a._view.name&&a.options.disableDates(i)||("month"!=a._view.name||a._isSingleSelection())&&a._click(e(n))})).on("mouseup"+k,"table.k-calendar-table, .k-calendar-footer",(function(){a._focusView(!1!==a.options.focusOnNav)})).attr(S),a.options.weekNumber&&t.on(x,"td:not(:has(.k-link))",(function(t){var n=e(t.currentTarget).closest("tr").find(B).first(),i=e(t.currentTarget).closest("tr").find(B).last();a._isMultipleSelection()&&(a.selectable._lastActive=i,a.selectable.selectRange(n,i),a.selectable.trigger(M,{event:t})),a._isRangeSelection()&&(a.rangeSelectable._lastActive=i,a.rangeSelectable.range(n,i),a.rangeSelectable.change()),a._current=a._value=we(i.find("span")),a._setCurrent(a._current)})),_e(i),r=s(i.value,i.format,i.culture),a._selectDates=[],a._index=ee[i.start],a._current=new J(+le(r,i.min,i.max)),a._addClassProxy=function(){if(a._active=!0,a._cell.hasClass(z)){var e=a._view.toDateString(se());a._cell=a._cellByDate(e)}a._cell.addClass(P)},a._removeClassProxy=function(){a._active=!1,a._cell&&a._cell.removeClass(P)},a.value(r),a._isMultipleSelection()&&i.selectDates.length>0&&a.selectDates(i.selectDates),a._range=i.range,a._isRangeSelection()&&a.selectRange(a._range),n.notify(a)},options:{name:"Calendar",value:null,min:new J(1900,0,1),max:new J(2099,11,31),dates:[],disableDates:null,allowReverse:!1,centuryCellsFormat:"long",url:"",culture:"",footer:"",format:"",month:{},weekNumber:!1,range:{start:null,end:null,target:L},selectable:"single",selectDates:[],start:D,depth:D,size:"medium",showOtherMonthDays:!0,animation:{horizontal:{effects:T,reverse:!0,duration:500,divisor:2},vertical:{effects:"zoomIn",duration:400}},messages:{weekColumnHeader:"",today:"Today",navigateTo:"Navigate to ",parentViews:{month:"year view",year:"decade view",decade:"century view"}},componentType:"classic"},events:[M,E],componentTypes:{classic:{header:{template:({actionAttr:e,size:t,isRtl:i})=>`<div class="k-header k-hstack">\n            <span tabindex="-1" data-href="#" ${e}="prev" role="button" class="k-calendar-nav-prev k-button ${t} k-rounded-md k-button-flat k-button-flat-base k-icon-button" ${X}="Previous">${n.ui.icon({icon:"caret-alt-"+(i?"right":"left"),iconClass:"k-button-icon"})}</span></span>\n            <span tabindex="-1" data-href="#" ${e}="nav-up" id="`+n.guid()+`" role="button" class="k-calendar-nav-fast k-button ${t} k-rounded-md k-button-flat k-button-flat-base  k-flex"></span>\n            <span tabindex="-1" data-href="#" ${e}="next" role="button" class="k-calendar-nav-next k-button ${t} k-rounded-md k-button-flat k-button-flat-base  k-icon-button" ${X}="Next">${n.ui.icon({icon:"caret-alt-"+(i?"left":"right"),iconClass:"k-button-icon"})}</span>\n        </div>`},hasFooter:!0,linksSelector:".k-button",contentClasses:"k-calendar-table"},modern:{header:{template:({actionAttr:e,size:t,messages:i,isRtl:r})=>`<div class="k-calendar-header">\n            <button ${e}="nav-up" id="`+n.guid()+`" class="k-calendar-title k-button ${t} k-button-flat k-button-flat-primary k-rounded-md">\n                <span class="k-button-text"></span>\n            </button>\n            <span class="k-spacer"></span>\n            <span class="k-calendar-nav">\n                <button tabindex="-1" ${e}=${r?"next":"prev"} class="k-calendar-nav-prev k-button ${t} k-button-flat k-button-flat-base k-rounded-md k-icon-button">\n                    ${n.ui.icon({icon:"chevron-"+(r?"right":"left"),iconClass:"k-button-icon"})}\n                </button>\n                <button tabindex="-1" ${e}="today" class="k-calendar-nav-today k-button ${t} k-button-flat k-button-flat-primary k-rounded-md" role="link">\n                    <span class="k-button-text">${n.htmlEncode(i.today)}</span>\n                </button>\n                <button tabindex="-1" ${e}=${r?"prev":"next"} class="k-calendar-nav-next k-button ${t} k-button-flat k-button-flat-base k-rounded-md k-icon-button">\n                    ${n.ui.icon({icon:"chevron-"+(r?"left":"right"),iconClass:"k-button-icon"})}\n                </button>\n            </span>\n        </div>`},hasFooter:!1,linksSelector:".k-button",contentClasses:"k-calendar-table"}},setOptions:function(t){let n,i=this;if(n=!!t.componentType,_e(t),t.disableDates=be(t.disableDates),i._destroySelectable(),t.messages&&(t.messages=e.extend({},!0,i.options.messages,t.messages)),o.fn.setOptions.call(i,t),i._templates(),i._selectable(),n){let e=ne.prototype.componentTypes;i.options.header=e[t.componentType].header,i.options.hasFooter=e[t.componentType].hasFooter;let n=i.element.find(te)[0];n&&n.remove(),i._header()}if(i._viewWrapper(),i.options.hasFooter?i._footer(i.footer):(i.element.find(".k-calendar-footer").hide(),i._toggle()),i._index=ee[i.options.start],i.navigate(),n){let e=s(i.options.value,t.format,t.culture);i._current=new J(+le(e,t.min,t.max)),i._cell=null,i._table=null,i.value(e)}t.weekNumber&&i.element.addClass("k-week-number")},destroy:function(){var e=this,t=e._today;e.element.off(k),e._title.off(k),e[G].off(k),e[K].off(k),e._destroySelectable(),n.destroy(e._table),t&&n.destroy(t.off(k)),o.fn.destroy.call(e)},current:function(){return this._current},view:function(){return this._view},focus:function(e){e=e||this._table,this._bindTable(e),e.trigger("focus")},min:function(e){return this._option("min",e)},max:function(e){return this._option("max",e)},navigateToPast:function(){this._navigate(G,-1)},navigateToFuture:function(){this._navigate(K,1)},navigateUp:function(){var e=this,t=e._index;e._title.hasClass(z)||e.navigate(e._current,++t)},navigateDown:function(e){var t=this,n=t._index,i=t.options.depth;e&&(n!==ee[i]?t.navigate(e,--n):ye(t._value,t._current)&&ye(t._value,e)||(t.value(e),t.trigger(M)))},navigate:function(n,i){i=isNaN(i)?ee[i]:i;var r,o,a,s,c=this,d=c.options,u=d.culture,h=d.min,p=d.max,f=c._title,m=c._table,g=c._oldTable,v=c._current,_=n&&+n>+v,b=i!==t&&i!==c._index,y=c.element.children(".k-calendar-view");if(n||(n=v),c._current=n=new J(+le(n,h,p)),i===t?i=c._index:c._index=i,c._view=o=ie.views[i],a=o.compare,s=i===ee[A],f.toggleClass(z,s).attr(Y,s),s=a(n,h)<1,c[G].toggleClass(z,s).attr(Y,s),s=a(n,p)>-1,c[K].toggleClass(z,s).attr(Y,s),m&&g&&g.data("animating")&&(g.kendoStop(!0,!0),m.kendoStop(!0,!0)),c._oldTable=m,!m||c._changeView){f.html('<span class="k-button-text">'+o.title(n,h,p,u)+"</span>"),c.options.messages.parentViews&&c._view.name!==A?f.attr("title",l(c.options.messages.navigateTo+c.options.messages.parentViews[c._view.name])):f.removeAttr("title"),c._table=r=e(o.content(Z({min:h,max:p,date:n,url:d.url,dates:d.dates,format:d.format,showOtherMonthDays:d.showOtherMonthDays,centuryCellsFormat:d.centuryCellsFormat,culture:u,disableDates:d.disableDates,isWeekColumnVisible:d.weekNumber,messages:d.messages,contentClasses:c.options.contentClasses},c[o.name]))),c._aria();var w=m&&m.data("start")===r.data("start");c._animate({from:m,to:r,vertical:b,future:_,replace:w}),y.removeClass("k-calendar-monthview k-calendar-yearview k-calendar-decadeview k-calendar-centuryview"),y.addClass("k-calendar-"+o.name+"view"),c.trigger(E),c._focus(n)}i===ee[d.depth]&&c._selectDates.length>0&&c._visualizeSelectedDatesInView(),c._isSingleSelection()&&i===ee[d.depth]&&c._value&&!c.options.disableDates(c._value)&&c._selectCell(c._value),c._setCurrent(n),!m&&c._cell&&c._cell.removeClass(P),c._changeView=!0},selectDates:function(n){var i,r,o=this;if(n===t)return o._selectDates;r=n.map((function(e){return e.getTime()})).filter((function(e,t,n){return n.indexOf(e)===t})).map((function(e){return new Date(e)})),i=e.grep(r,(function(e){if(e)return+o._validateValue(new Date(e.setHours(0,0,0,0)))==+e})),o._selectDates=i.length>0?i:0===r.length?r:o._selectDates,o._visualizeSelectedDatesInView()},value:function(e){var n=this,i=n._view,r=n._view;if(e===t)return n._value;if((e=n._validateValue(e))&&n._isMultipleSelection()){var o=new Date(+e);o.setHours(0,0,0,0),n._selectDates=[o],n.selectable._lastActive=null}i&&null===e&&n._cell?n._cell.removeClass(O):(n._changeView=!e||r&&0!==r.compare(e,n._current),n.navigate(e))},isRtl:function(){return n.support.isRtl(this.wrapper)},_aria:function(){var e=this._table;e.attr("aria-labelledby",this._title.attr("id")),"month"===this._view.name&&this._isMultipleSelection()&&e.attr("aria-multiselectable","true")},_validateValue:function(e){var n=this,i=n.options,r=i.min,o=i.max;return null===e&&(n._current=ge(n._current.getFullYear(),n._current.getMonth(),n._current.getDate())),null!==(e=s(e,i.format,i.culture))&&(ce(e=new J(+e),r,o)||(e=null)),null!==e&&n.options.disableDates(new Date(+e))?n._value===t&&(n._value=null):n._value=e,n._value},_visualizeSelectedDatesInView:function(){var t=this,i={};e.each(t._selectDates,(function(e,t){i[n.calendar.views[0].toDateString(t)]=t})),t.selectable.clear();var r=t._table.find(R).filter((function(t,r){return i[e(r.firstChild).attr(n.attr(I))]}));r.length>0&&t.selectable._selectElement(r,!0)},_isSingleSelection:function(){let e=this.options.selectable;return u.parseOptions(e).single},_isMultipleSelection:function(){let e=this.options.selectable;return u.parseOptions(e).multiple},_isRangeSelection:function(){let e=this.options.selectable;return u.parseOptions(e).range},_selectable:function(){let e=this,t=e.options.selectable,n=u.parseOptions(t);(e._isMultipleSelection()||e._isRangeSelection())&&(e.rangeSelectable&&(e.rangeSelectable.destroy(),e.rangeSelectable=null),n.range?(e.rangeSelectable=new h(e.wrapper,{widget:e,filter:".k-calendar-monthview table "+B,cellSelector:R,cellSelectorValid:B,change:e._onSelect.bind(e),reverse:e.options.allowReverse,resetOnStart:!0,ns:k}),e.element.addClass("k-calendar-range")):e.selectable=new u(e.wrapper,{aria:!0,inputSelectors:"input,textarea,.k-multiselect-wrap,select,button,.k-button>span,.k-button>img,span.k-icon.k-i-caret-alt-down,span.k-icon.k-i-caret-alt-up,span.k-svg-icon.k-svg-i-caret-alt-down,span.k-svg-icon.k-svg-i-caret-alt-up",multiple:n.multiple,filter:"table.k-calendar-table:eq(0) "+B,change:e._onSelect.bind(e),relatedTarget:e._onRelatedTarget.bind(e)}))},_restoreSelection:function(){const e=this;let t;if(e._preventChange=!0,e._isRangeSelection()){if(t=e.selectRange(),!t||!t.start)return void(e._preventChange=!1);e.selectRange(t)}e._preventChange=!1},selectRange:function(e){const n=this,i=n._view;let r,o,a;if(e===t)return n._range;n._range=e,e.start&&(a=n._visibleRange(),r=n._dateInViews(e.start),o=e.end&&n._dateInViews(e.end),!r&&o&&n.rangeSelectable.selectTo(n._cellByDate(i.toDateString(e.end))),r&&o&&n.rangeSelectable.range(n._cellByDate(i.toDateString(e.start)),n._cellByDate(i.toDateString(e.end)),!1,n.options.allowReverse),e.end&&r&&!o&&n.rangeSelectable.selectFrom(n._cellByDate(i.toDateString(e.start))),!e.end&&r&&n.rangeSelectable.start(n._cellByDate(i.toDateString(e.start))),+a.start>+e.start&&+a.end<+e.end&&n.rangeSelectable.mid(n.element.find(B)))},_onRelatedTarget:function(e){var t=this;t.selectable.options.multiple&&e.is(B)&&(t._current=we(e.find("span")),t._setCurrent(t._current))},_onSelect:function(t){let n,i,r,o,a,s,l=this,c=t,d=t.sender._useEnd,h=t.sender._useStart,p=u.parseOptions(l.options.selectable);if(l._isRangeSelection())return n=t.sender.range(),i=l.selectRange()||{},s=i.target,n.start&&n.start.length&&(r=we(n.start.find("span"))),n.end&&n.end.length&&(o=we(n.end.find("span"))),s="end"===s?L:"end",l._range={start:h?i.start:r,end:d?i.end:o,target:s},l._preventChange||l.trigger(M),a=o||r,o&&!l._dateInViews(o)&&(a=r),l.selectRange(l._range),void l.value(a);p.multiple?(c.event.ctrlKey||c.event.metaKey?e(c.event.currentTarget).is(B)?l._toggleSelection(e(c.event.currentTarget)):(l._cellsBySelector(B).each((function(t,n){var i=we(e(n).find("span"));l._deselect(i)})),l._addSelectedCellsToArray()):c.event.shiftKey?l._rangeSelection(l._cell):e(c.event.currentTarget).is(R)?l.value(we(e(c.event.currentTarget).find("span"))):(l._selectDates=[],l._addSelectedCellsToArray()),l.trigger(M)):e(c.event.currentTarget).is("td")&&!e(c.event.currentTarget).hasClass("k-selected")?e(c.event.currentTarget).addClass("k-selected"):l._click(e(c.event.currentTarget).find("span"))},_destroySelectable:function(){var e=this;e.selectable&&(e.selectable.destroy(),e.selectable=null),e.rangeSelectable&&(e.rangeSelectable.destroy(),e.rangeSelectable=null)},_toggleSelection:function(e){var t=we(e.find("span"));e.hasClass("k-selected")?this._selectDates.push(t):this._deselect(t)},_rangeSelection:function(e,t){var n,i=this,r=t||we(i.selectable.value().first().find("span")),o=we(e.find("span"));i.selectable._lastActive||i._value?r=i.selectable._lastActive?we(i.selectable._lastActive.find("span")):new Date(+i._value):i.selectable._lastActive=t?i._cellByDate(i._view.toDateString(t),B):i.selectable.value().first(),i._selectDates=[],n=he(r,o),pe(i._selectDates,n,r,i.options.disableDates),i._visualizeSelectedDatesInView()},_visibleRange:function(){let e=this.element.find(".k-calendar-view table");return{start:we(e.first().find(R).first().find("span")),end:we(e.last().find(R).last().find("span"))}},_cellsBySelector:function(e){return this._table.find(e)},_addSelectedCellsToArray:function(){var t=this;t.selectable.value().each((function(n,i){var r=we(e(i.firstChild));t.options.disableDates(r)||t._selectDates.push(r)}))},_deselect:function(e){var t=this._selectDates.map(Number).indexOf(+e);-1!=t&&this._selectDates.splice(t,1)},_dateInView:function(e){var t=we(this._cellsBySelector(B).first().find("span"));return+e<=+we(this._cellsBySelector(B).last().find("span"))&&+e>=+t},_isNavigatable:function(e,t){var n,i=this,r=i.options.disableDates;return"month"==i._view.name?!r(e):(n=i.wrapper.find("."+P).index(),i.wrapper.find(".k-calendar-table td").eq(n+t).is(B)||!r(e))},_dateInViews:function(e){let t=this.element.find(".k-calendar-view table"),n=we(t.first().find(R).first().find("span")),i=we(t.last().find(R).last().find("span"));return+(e=new Date(e.toDateString()))<=+i&&+e>=+n},_move:function(n){var i,r,o,s,l,c,d=this,u=d.options,h=n.keyCode,p=d._view,f=d._index,m=d.options.min,g=d.options.max,v=new J(+d._current),_=d.isRtl(),b=d.options.disableDates;if(n.target===d._table[0]&&(d._active=!0),h==a.RIGHT&&!_||h==a.LEFT&&_?(i=1,r=!0):h==a.LEFT&&!_||h==a.RIGHT&&_?(i=-1,r=!0):h==a.UP?(i=0===f?-7:-4,r=!0):h==a.DOWN?(i=0===f?7:4,r=!0):h==a.SPACEBAR?(i=0,r=!0):h==a.HOME||h==a.END?(s=p[o=h==a.HOME?"first":"last"](v),(v=new J(s.getFullYear(),s.getMonth(),s.getDate(),v.getHours(),v.getMinutes(),v.getSeconds(),v.getMilliseconds())).setFullYear(s.getFullYear()),r=!0):84===h&&(d._todayClick(n),r=!0),n.ctrlKey||n.metaKey){if(h==a.RIGHT&&!_||h==a.LEFT&&_)d.navigateToFuture(),r=!0;else if(h==a.LEFT&&!_||h==a.RIGHT&&_)d.navigateToPast(),r=!0;else if(h==a.UP)d.navigateUp(),r=!0;else if(h==a.DOWN)d._click(e(d._cell[0].firstChild)),r=!0;else if((h==a.ENTER||h==a.SPACEBAR)&&d._isMultipleSelection()){d._keyboardToggleSelection(n);var y=we(e(d._cell[0]).find("span"));d._setCurrent(y)}}else n.shiftKey?((i!==t||o)&&(o||p.setDate(v,i),ce(v,m,g)||(v=le(v,u.min,u.max)),b(v)&&(v=d._nextNavigatable(v,i)),m=ge(m.getFullYear(),m.getMonth(),m.getDate()),d._isMultipleSelection()?d._keyboardRangeSelection(n,v):d._isRangeSelection()?d._dateInViews(v)||(i>0?d.navigateToFuture():d.navigateToPast()):d._focus(v)),d.rangeSelectable&&(l=d._cellByDate(p.toDateString(v)),c=we((d.rangeSelectable._lastActive||undefined).find("span")),d._dateInViews(c)?(d.rangeSelectable._end&&d.rangeSelectable._end.is("."+P)?d.rangeSelectable._lastActive=d.rangeSelectable._start:d.rangeSelectable._lastActive=d._cellByDate(p.toDateString(c)),d.rangeSelectable.range(d.rangeSelectable._lastActive,l)):+c>+v?(d.rangeSelectable._end=d.rangeSelectable._lastActive,d.rangeSelectable.selectFrom(l)):d.rangeSelectable.selectTo(l),d.rangeSelectable.change(),d._setCurrent(v))):(h==a.ENTER||h==a.SPACEBAR?("month"==p.name&&d._isMultipleSelection()?(d.value(we(e(d._cell.find("span")))),d.selectable._lastActive=e(d._cell[0]),d.trigger(M)):d.rangeSelectable?d.rangeSelectable.change():d._click(e(d._cell[0].firstChild)),r=!0):h==a.PAGEUP?(r=!0,d.navigateToPast()):h==a.PAGEDOWN&&(r=!0,d.navigateToFuture()),(i||o)&&(o||p.setDate(v,i),ce(v,m=ge(m.getFullYear(),m.getMonth(),m.getDate()),g)||(v=le(v,u.min,u.max)),d._isNavigatable(v,i)||(v=d._nextNavigatable(v,i)),d._isMultipleSelection()?d._dateInView(v)?(d._current=v,d._setCurrent(v)):d.navigate(v):d._focus(v)));return r&&n.preventDefault(),d._current},_keyboardRangeSelection:function(e,t){var n,i,r=this;if(!r._dateInView(t))return r._selectDates=[],i=he(n=r.selectable._lastActive?we(r.selectable._lastActive.find("span")):t,new Date(+t)),pe(r._selectDates,i,n,r.options.disableDates),r.navigate(t),r._current=t,r.selectable._lastActive=r.selectable._lastActive||r._cellByDate(r._view.toDateString(t),B),void r.trigger(M);r.selectable.options.filter=r.wrapper.find("table").length>1&&+t>+r._current?"table.k-calendar-table:eq(1) "+B:"table.k-calendar-table:eq(0) "+B,r._setCurrent(t),r._current=t,r._rangeSelection(r._cellByDate(r._view.toDateString(t),B),t),r.trigger(M),r.selectable.options.filter="table.k-calendar-table:eq(0) "+B},_keyboardToggleSelection:function(t){var n=this;t.currentTarget=n._cell[0],n.selectable._lastActive=e(n._cell[0]),e(n._cell[0]).hasClass(O)?n.selectable._unselect(e(n._cell[0])):n.selectable.value(e(n._cell[0])),n.selectable.trigger(M,{event:t})},_nextNavigatable:function(e,t){var n=this,i=!0,r=n._view,o=n.options.min,a=n.options.max,s=n.options.disableDates,l=new Date(e.getTime());for(r.setDate(l,-t);i;){if(r.setDate(e,t),!ce(e,o,a)){e=l;break}i=s(e)}return e},_animate:function(e){var t=this,n=e.from,i=e.to,r=t._active,o=t.element.children(".k-calendar-view");n?n.parent().data("animating")?(n.off(k),n.parent().kendoStop(!0,!0).remove(),n.remove(),o.append(i),t._focusView(r)):!n.is(":visible")||!1===t.options.animation||e.replace?(i.insertAfter(n),n.off(k).remove(),t._focusView(r)):t[e.vertical?"_vertical":"_horizontal"](n,i,e.future):(o.append(i),t._bindTable(i))},_horizontal:function(e,t,n){var i=this,r=i._active,o=i.options.animation.horizontal,a=o.effects,s=w(e),l=w(e,!0)-s;a&&-1!=a.indexOf(T)&&(e.add(t).css({width:s}),e.wrap("<div/>"),i._focusView(r,e),e.parent().css({position:"relative",width:2*s+2*l,display:"flex",[n?"margin-right":"margin-left"]:-s-l}),t[n?"insertAfter":"insertBefore"](e),Z(o,{effects:T+":"+(n?"right":"left"),complete:function(){e.off(k).remove(),i._oldTable=null,t.unwrap(),i._focusView(r)}}),e.parent().kendoStop(!0,!0).kendoAnimate(o))},_vertical:function(e,t){var n,i,r=this,o=r.options.animation.vertical,a=o.effects,s=r._active;a&&-1!=a.indexOf("zoom")&&(t.insertBefore(e),e.css({position:"absolute",width:t.width()}),g&&(i=(i=(n=r._cellByDate(r._view.toDateString(r._current))).position()).left+parseInt(n.width()/2,10)+"px "+(i.top+parseInt(n.height()/2,10))+"px",t.css(g,i)),e.kendoStop(!0,!0).kendoAnimate({effects:"fadeOut",duration:600,complete:function(){e.off(k).remove(),r._oldTable=null,r._focusView(s)}}),t.kendoStop(!0,!0).kendoAnimate(o))},_cellByDate:function(t,i){return this._table.find(i||"td:not(."+H+")").filter((function(){return e(this.firstChild).attr(n.attr(I))===t}))},_selectCell:function(e){var t=this,n=t._selectedCell,i=t._view.toDateString(e);n&&n[0]&&(n[0].removeAttribute(Q),n.removeClass(O)),n=t._cellByDate(i,R),t._selectedCell=n,n.addClass(O).attr(Q,!0)},_setCurrent:function(e){var t=this,i=n.guid(),r=t._cell,o=t._view.toDateString(e);r&&r[0]&&(r.removeClass(P),r[0].removeAttribute(X),r[0].removeAttribute(S)),r=t._cellByDate(o,t._isMultipleSelection()?R:"td:not(."+H+")"),t._cell=r,r.attr(S,i).addClass(P),t._table[0]&&(t._table[0].removeAttribute("aria-activedescendant"),t._table.attr("aria-activedescendant",i))},_bindTable:function(e){e.on($,this._addClassProxy).on(V,this._removeClassProxy)},_click:function(e){var t=this,n=t.options,i=new Date(+t._current),r=we(e);c(r,0),"month"==t._view.name&&t.options.disableDates(r)&&(r=t._value),t._view.setDate(i,r),t.navigateDown(le(i,n.min,n.max))},_focus:function(e){var t=this;0!==t._view.compare(e,t._current)?t.navigate(e):(t._current=e,t._setCurrent(e))},_focusView:function(e,t){e&&this.focus(t)},_viewWrapper:function(){var t=this.element,n=t.children(".k-calendar-view");n[0]||(n=e("<div class='k-calendar-view k-align-items-start k-justify-content-center k-hstack' />").insertAfter(t.find(te)))},_footer:function(t){var i=this,r=se(),o=i.element,a=o.find(".k-calendar-footer");if(!t)return i._toggle(!1),void a.hide();a[0]||(a=e('<div class="k-calendar-footer">\n                    <button tabindex="-1" class="k-calendar-nav-today k-flex k-button k-button-md k-button-flat k-button-flat-primary k-rounded-md" role="link">\n                        <span class="k-button-text"></span>\n                    </button>\n                </div>').appendTo(o)),i._today=a.show().find(".k-button-flat-primary").attr("title",n.toString(r,"D",i.options.culture)),a.find(".k-button-text").html(t(r)),i._toggle()},_header:function(){var t=this,i=t.element,r=t.options.linksSelector;i.find(te)[0]||i.html(n.template(t.options.header.template)(e.extend(!0,{},t.options,{actionAttr:n.attr("action"),size:n.getValidCssClass("k-button-","size",t.options.size),isRtl:t.isRtl()}))),i.find(r).on(x+" touchend"+k,(function(){return!1})),t._title=i.find("["+n.attr("action")+'="nav-up"]').on(x+" touchend"+k,(function(){t._active=!1!==t.options.focusOnNav,t.navigateUp()})),t[G]=i.find("["+n.attr("action")+'="prev"]').on(x+" touchend"+k,(function(){t._active=!1!==t.options.focusOnNav,t.navigateToPast()})),t[K]=i.find("["+n.attr("action")+'="next"]').on(x+" touchend"+k,(function(){t._active=!1!==t.options.focusOnNav,t.navigateToFuture()})),i.find("["+n.attr("action")+'="today"]').on(x+" touchend"+k,t._todayClick.bind(t))},_navigate:function(e,t){var n=this,i=n._index+1,r=new J(+n._current);n._isMultipleSelection()&&(r=we(n._table.find("td:not(."+H+"):not(."+F+")").has(".k-link").first().find("span")),n._current=new Date(+r));(e=n[e]).hasClass(z)||(i>3?r.setFullYear(r.getFullYear()+100*t):ie.views[i].setDate(r,t),n.navigate(r),n._restoreSelection())},_option:function(e,n){var i,r=this,o=r.options,a=r._value||r._current;if(n===t)return o[e];(n=s(n,o.format,o.culture))&&(o[e]=new J(+n),((i="min"===e?n>a:a>n)||function(e,t){if(e)return e.getFullYear()===t.getFullYear()&&e.getMonth()===t.getMonth();return!1}(a,n))&&(i&&(r._value=null),r._changeView=!0),r._changeView||(r._changeView=!(!o.month.content&&!o.month.empty)),r.navigate(r._value),r._toggle())},_toggle:function(e){var n=this,i=n.options,r=n.options.disableDates(se()),o=n._today,a=n._todayClass();e===t&&(e=ce(se(),i.min,i.max)),o&&(o.off(x),e&&!r?o.addClass(a).removeClass(z).on(x,n._todayClick.bind(n)):o.removeClass(a).addClass(z).on(x,me))},_todayClass:function(){return"k-calendar-nav-today"},_todayClick:function(e){var t=this,n=ee[t.options.depth],i=t.options.disableDates,r=se();e.preventDefault(),i(r)||(0===t._view.compare(t._current,r)&&t._index==n&&(t._changeView=!1),t._isMultipleSelection()&&(t._selectDates=[r],t.selectable._lastActive=null),t._value=r,t.navigate(r,n),t.trigger(M))},_templates:function(){var e=this,t=e.options,i=t.footer,r=t.month,o=r.content,a=r.weekNumber,s=r.empty,l=e=>`${n.toString(e,"D",t.culture)}`;e.month={content:e=>`<td class="${e.cssClass}" role="gridcell"><span tabindex="-1" class="k-link ${e.linkClass}" data-href="${e.url}" ${n.attr(I)}="${e.dateString}" title="${e.title}">${ke(o,e)||e.value}</span></td>`,empty:e=>`<td role="gridcell">${ke(s,e)||"&nbsp;"}</td>`,weekNumber:e=>`<td class="k-calendar-td k-alt">${ke(a,e)||e.weekNumber}</td>`},e.year={content:f((e=>`<td class="${e.cssClass}" role="gridcell"><span tabindex="-1" class="k-link" data-href="#" data-${e.ns}value="${e.dateString}" aria-label="${e.label}">${e.value}</span></td>`))},i&&!0!==i&&(l=i),e.footer=!1!==i?f(l,{useWithBlock:!1}):null},_updateAria:function(e,t){var i,r=this,o=r._cell,a=r.view().valueType(),s=t||r.current();return i="month"===a?n.toString(s,"MMMM"):"date"===a?n.toString(s,"D"):o.text(),o.attr("aria-label",e({current:s,valueType:a,text:i})),o.attr("id")}});r.plugin(ne);var ie={firstDayOfMonth:function(e){return ge(e.getFullYear(),e.getMonth(),1)},firstVisibleDay:function(e,t){var i=(t=t||n.culture().calendar).firstDay,r=new J(e.getFullYear(),e.getMonth(),1,e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds());for(r.setFullYear(e.getFullYear());r.getDay()!=i;)ie.setTime(r,-864e5);return r},setTime:function(e,t){var n=e.getTimezoneOffset(),i=new J(e.getTime()+t),r=i.getTimezoneOffset()-n;e.setTime(i.getTime()+6e4*r)},views:[{name:D,title:function(e,t,n,i){return ve(i).months.names[e.getMonth()]+" "+e.getFullYear()},content:function(e){var t=this,i=0,r=e.min,o=e.max,a=e.date,s=e.dates,u=e.format,h=e.culture,p=e.url,f=e.showHeader,m=e.showOtherMonthDays,g=e.isWeekColumnVisible,v=p&&s[0],_=ve(h),b=_.firstDay,y=_.days,w=de(y.names,b),k=de(y.namesShort,b),x=ie.firstVisibleDay(a,_),C=t.first(a),S=t.last(a),T=t.toDateString,D=se(),A='<table tabindex="0" role="grid" class="'+e.contentClasses+'" cellspacing="0" data-start="'+T(x)+'">';for(f&&(A+='<caption class="k-calendar-caption k-month-header">'+this.title(a,r,o,h)+"</caption>"),A+='<thead class="k-calendar-thead"><tr role="row" class="k-calendar-tr">',g&&(A+='<th scope="col" class="k-calendar-th k-alt">'+l(e.messages.weekColumnHeader)+"</th>");i<7;i++)A+='<th scope="col" class="k-calendar-th" aria-label="'+w[i]+'">'+k[i]+"</th>";return c(D,0),D=+D,oe({cells:42,perRow:7,html:A+='</tr></thead><tbody class="k-calendar-tbody"><tr role="row" class="k-calendar-tr">',start:ge(x.getFullYear(),x.getMonth(),x.getDate()),isWeekColumnVisible:g,weekNumber:e.weekNumber,min:ge(r.getFullYear(),r.getMonth(),r.getDate()),max:ge(o.getFullYear(),o.getMonth(),o.getDate()),showOtherMonthDays:m,content:e.content,lastDayOfMonth:S,empty:e.empty,setter:t.setDate,disableDates:e.disableDates,build:function(e,t,i){var r=["k-calendar-td"],o=e.getDay(),a="",l="#";return(e<C||e>S)&&r.push(H),i(e)&&r.push(z),+e===D&&r.push("k-today"),0!==o&&6!==o||r.push("k-weekend"),v&&function(e,t){for(var n=0,i=t.length;n<i;n++)if(e===+t[n])return!0;return!1}(+e,s)&&(l=p.replace("{0}",n.toString(e,u,h)),a=" k-action-link"),{date:e,dates:s,ns:n.ns,title:n.toString(e,"D",h),value:e.getDate(),dateString:T(e),cssClass:r.join(" "),linkClass:a,url:l}},weekNumberBuild:function(e){return{weekNumber:d(e,n.culture().calendar.firstDay),currentDate:e}}})},first:function(e){return ie.firstDayOfMonth(e)},last:function(e){var t=ge(e.getFullYear(),e.getMonth()+1,0),n=ie.firstDayOfMonth(e),i=Math.abs(t.getTimezoneOffset()-n.getTimezoneOffset());return i&&t.setHours(n.getHours()+i/60),t},compare:function(e,t){var n=e.getMonth(),i=e.getFullYear(),r=t.getMonth(),o=t.getFullYear();return i>o?1:i<o?-1:n==r?0:n>r?1:-1},setDate:function(e,t){var n=e.getHours();t instanceof J?e.setFullYear(t.getFullYear(),t.getMonth(),t.getDate()):ie.setTime(e,t*q),c(e,n)},toDateString:function(e){return e.getFullYear()+"/"+e.getMonth()+"/"+e.getDate()},valueType:function(){return"date"}},{name:"year",title:function(e){return e.getFullYear()},content:function(e){var t=ve(e.culture).months,i=t.namesAbbr,r=t.names,o=this.toDateString,a=e.min,s=e.max,l="";return e.showHeader&&(l+='<table tabindex="0" role="grid" class="k-calendar-table" cellspacing="0">',l+='<caption class="k-calendar-caption k-meta-header">',l+=this.title(e.date),l+="</caption>",l+='<tbody class="k-calendar-tbody">',l+='<tr role="row" class="k-calendar-tr">'),oe({min:ge(a.getFullYear(),a.getMonth(),1),max:ge(s.getFullYear(),s.getMonth(),1),start:ge(e.date.getFullYear(),0,1),html:l,setter:this.setDate,content:e.content,build:function(e){return{value:i[e.getMonth()],label:r[e.getMonth()],ns:n.ns,dateString:o(e),cssClass:["k-calendar-td"].join(" ")}}})},first:function(e){return ge(e.getFullYear(),0,e.getDate())},last:function(e){return ge(e.getFullYear(),11,e.getDate())},compare:function(e,t){return ae(e,t)},setDate:function(e,t){var n,i=e.getHours();t instanceof J?(n=t.getMonth(),e.setFullYear(t.getFullYear(),n,e.getDate()),n!==e.getMonth()&&e.setDate(0)):(n=e.getMonth()+t,e.setMonth(n),n>11&&(n-=12),n>0&&e.getMonth()!=n&&e.setDate(0)),c(e,i)},toDateString:function(e){return e.getFullYear()+"/"+e.getMonth()+"/1"},valueType:function(){return"month"}},{name:"decade",title:function(e,t,n){return re(e,t,n,10)},content:function(e){var t=e.date.getFullYear(),i=this.toDateString,r="";return e.showHeader&&(r+='<table tabindex="0" role="grid" class="k-calendar-table" cellspacing="0">',r+='<caption class="k-meta-header">',r+=this.title(e.date,e.min,e.max),r+="</caption>",r+='<tbody class="k-calendar-thead">',r+='<tr role="row" class="k-calendar-tr">'),oe({start:ge(t-t%10,0,1),min:ge(e.min.getFullYear(),0,1),max:ge(e.max.getFullYear(),0,1),showOtherMonthDays:e.showOtherMonthDays,html:r,setter:this.setDate,build:function(e,t){var r=["k-calendar-td"];return 10!==t&&11!==t||r.push(F),{value:e.getFullYear(),ns:n.ns,dateString:i(e),cssClass:r.join(" ")}}})},first:function(e){var t=e.getFullYear();return ge(t-t%10,e.getMonth(),e.getDate())},last:function(e){var t=e.getFullYear();return ge(t-t%10+9,e.getMonth(),e.getDate())},compare:function(e,t){return ae(e,t,10)},setDate:function(e,t){ue(e,t,1)},toDateString:function(e){return e.getFullYear()+"/0/1"},valueType:function(){return"year"}},{name:A,title:function(e,t,n){return re(e,t,n,100)},content:function(e){var t=e.date.getFullYear(),i=e.min.getFullYear(),r=e.max.getFullYear(),o=this.toDateString,a=i,s=r,l="";return(s-=s%10)-(a-=a%10)<10&&(s=a+9),e.showHeader&&(l+='<table tabindex="0" role="grid" class="k-calendar-table" cellspacing="0">',l+='<caption class="k-calendar-caption k-meta-header">',l+=this.title(e.date,e.min,e.max),l+="</caption>",l+='<tbody class="k-calendar-tbody">',l+='<tr role="row" class="k-calendar-tr">'),oe({start:ge(t-t%100,0,1),min:ge(a,0,1),max:ge(s,0,1),showOtherMonthDays:e.showOtherMonthDays,html:l,setter:this.setDate,build:function(t,a){var s=["k-calendar-td"],l=t.getFullYear(),c=l+9;return 10!==a&&11!==a||s.push(F),l<i&&(l=i),c>r&&(c=r),{ns:n.ns,value:"long"===e.centuryCellsFormat?`${l} - ${c}`:l,dateString:o(t),cssClass:s.join(" ")}}})},first:function(e){var t=e.getFullYear();return ge(t-t%100,e.getMonth(),e.getDate())},last:function(e){var t=e.getFullYear();return ge(t-t%100+99,e.getMonth(),e.getDate())},compare:function(e,t){return ae(e,t,100)},setDate:function(e,t){ue(e,t,10)},toDateString:function(e){var t=e.getFullYear();return t-t%10+"/0/1"},valueType:function(){return"decade"}}]};function re(e,t,n,i){var r,o=e.getFullYear(),a=t.getFullYear(),s=n.getFullYear();return r=(o-=o%i)+(i-1),o<a&&(o=a),r>s&&(r=s),o+"-"+r}function oe(e){var t,n=0,i=e.min,r=e.max,o=e.start,a=e.setter,s=e.build,l=e.weekNumberBuild,d=e.cells||12,u=e.isWeekColumnVisible,h=e.perRow||4,p=e.showOtherMonthDays,f=e.lastDayOfMonth,m=e.weekNumber||y,g=e.content||v,w=e.empty||_,k=e.otherMonthCellTemplate||b,x=e.html||'<table tabindex="0" role="grid" class="k-calendar-table" cellspacing="0"><tbody class="k-calendar-tbody"><tr role="row" class="k-calendar-tr">';for(u&&(x+=m(l(o)));n<d;n++)n>0&&n%h==0&&(x+='</tr><tr role="row" class="k-calendar-tr">',u&&(x+=m(p||+o<=+f?l(o):{weekNumber:"&nbsp;"}))),o=ge(o.getFullYear(),o.getMonth(),o.getDate()),c(o,0),-1===(t=s(o,n,e.disableDates)).cssClass.indexOf(H)||p?ce(o,i,r)&&-1===t.cssClass.indexOf(F)?x+=g(t):x+=w(t):x+=k(t),a(o,1);return x+"</tr></tbody></table>"}function ae(e,t,n){var i=e.getFullYear(),r=t.getFullYear(),o=r,a=0;return n&&(o=(r-=r%n)-r%n+n-1),i>o?a=1:i<r&&(a=-1),a}function se(){var e=new J;return new J(e.getFullYear(),e.getMonth(),e.getDate())}function le(e,t,n){var i=se();return e&&(i=new J(+e)),t>i?i=new J(+t):n<i&&(i=new J(+n)),i}function ce(e,t,n){return+e>=+t&&+e<=+n}function de(e,t){return e.slice(t).concat(e.slice(0,t))}function ue(e,t,n){t=t instanceof J?t.getFullYear():e.getFullYear()+n*t,e.setFullYear(t)}function he(e,t){if(+t<+e){var i=+e;ie.views[0].setDate(e,t),ie.views[0].setDate(t,new Date(i))}var r=Date.UTC(e.getFullYear(),e.getMonth(),e.getDate()),o=Date.UTC(t.getFullYear(),t.getMonth(),t.getDate());return Math.ceil((+o-+r)/n.date.MS_PER_DAY)}function pe(e,t,n,i){for(var r=0;r<=t;r++){var o=new Date(n.getTime());i(o=new Date(o.setDate(o.getDate()+r)))||e.push(o)}}function fe(t){e(this).hasClass("k-disabled")||e(this).toggleClass("k-hover",U.indexOf(t.type)>-1||t.type==N)}function me(e){e.preventDefault()}function ge(e,t,n){var i=new J(e,t,n);return i.setFullYear(e,t,n),i}function ve(e){return m(e).calendars.standard}function _e(e){var n=ee[e.start],i=ee[e.depth],r=m(e.culture);e.format=p(e.format||r.calendars.standard.patterns.d),isNaN(n)&&(n=0,e.start=D),(i===t||i>n)&&(e.depth=D),null===e.dates&&(e.dates=[])}function be(t){return n.isFunction(t)?t:Array.isArray(t)?function(e){var t,n=[],i=["su","mo","tu","we","th","fr","sa"];e[0]instanceof J?(n=function(e){for(var t=[],n=0;n<e.length;n++)t.push(e[n].setHours(0,0,0,0));return t}(e),t=e=>!!(e&&n.indexOf(new Date(e).setHours(0,0,0,0))>-1)):(n=e.map((e=>{e=e.slice(0,2).toLowerCase();let t=i.indexOf(e);if(t>-1)return t})),t=e=>!!(e&&n.indexOf(new Date(e).getDay())>-1));return t}(t):e.noop}function ye(e,t){return e instanceof Date&&t instanceof Date&&(e=e.getTime(),t=t.getTime()),e===t}function we(t){var i=e(t).attr(n.attr(I)).split("/");return i=ge(i[0],i[1],i[2])}function ke(e,i){return e?n.isFunction(e)?e(i):f(e)(i):t}ie.isEqualDatePart=function(e,t){return!!e&&(e.getFullYear()===t.getFullYear()&&e.getMonth()===t.getMonth()&&e.getDate()===t.getDate())},ie.isEqualDate=ye,ie.restrictValue=le,ie.isInRange=ce,ie.normalize=_e,ie.viewsEnum=ee,ie.disabled=be,ie.toDateObject=we,ie.getToday=se,ie.createDate=ge,n.calendar=ie}(window.kendo.jQuery);kendo;var Lh,Bh=function(e){return e?new Date(e.getTime()):null},Oh=function(e,t){var n=Bh(e);return 0===t&&23===n.getHours()&&n.setHours(n.getHours()+2),n},Vh=function(e,t){var n=Bh(e);return n.setDate(n.getDate()+t),Oh(n,e.getHours())},Nh=function(e,t,n,i,r,o,a){void 0===i&&(i=0),void 0===r&&(r=0),void 0===o&&(o=0),void 0===a&&(a=0);var s=new Date(e,t,n,i,r,o,a);return e>-1&&e<100&&s.setFullYear(s.getFullYear()-1900),Oh(s,i)},$h=function(e){var t=Nh(e.getFullYear(),e.getMonth()+1,1,e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds());return Vh(t,-1)},Uh=function(e,t){var n=Bh(e),i=(12+(n.getMonth()+t)%12)%12;return n.setMonth(n.getMonth()+t),function(e,t){return e.getMonth()!==t?$h(Uh(e,-1)):e}(Oh(n,e.getHours()),i)};!function(e){e[e.Forward=1]="Forward",e[e.Backward=-1]="Backward"}(Lh||(Lh={}));var Wh,jh=function(e,t,n){void 0===n&&(n=Lh.Forward);var i=Bh(e),r=(t-i.getDay()+7*n)%7;return i.setDate(i.getDate()+r),Oh(i,e.getHours())};!function(e){e[e.Sunday=0]="Sunday",e[e.Monday=1]="Monday",e[e.Tuesday=2]="Tuesday",e[e.Wednesday=3]="Wednesday",e[e.Thursday=4]="Thursday",e[e.Friday=5]="Friday",e[e.Saturday=6]="Saturday"}(Wh||(Wh={}));var qh=function(e){return Nh(e.getFullYear(),e.getMonth(),1,e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())},Gh=function(e){return Nh(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0)},Kh=function(e,t){return!e&&!t||e&&t&&e.getTime()===t.getTime()},Yh={rules:{},titles:{},zones:{}},Qh={Jan:0,Feb:1,Mar:2,Apr:3,May:4,Jun:5,Jul:6,Aug:7,Sep:8,Oct:9,Nov:10,Dec:11},Xh={Sun:0,Mon:1,Tue:2,Wed:3,Thu:4,Fri:5,Sat:6},Zh=function(e,t,n){var i,r=t[3],o=t[4],a=t[5],s="u"===a[3]?6e4*-n:0;if(isNaN(o)){if(0===o.indexOf("last")){i=new Date(Date.UTC(e,Qh[r]+1,1,a[0]-24,a[1],a[2])+s);var l=Xh[o.substr(4,3)],c=i.getUTCDay();i.setUTCDate(i.getUTCDate()+l-c-(l>c?7:0))}else if(o.indexOf(">=")>=0){i=new Date(Date.UTC(e,Qh[r],o.substr(5),a[0],a[1],a[2],0)+s);l=Xh[o.substr(0,3)],c=i.getUTCDay();i.setUTCDate(i.getUTCDate()+l-c+(l<c?7:0))}}else i=new Date(Date.UTC(e,Qh[r],o,a[0],a[1],a[2])+s);return i},Jh=(new Date).getTime(),ep=function(e,t,n){void 0===t&&(t=Jh),void 0===n&&(n=0);var i=Yh.rules[e];if(!i){var r=e.split(":"),o=0;return r.length>1&&(o=60*r[0]+Number(r[1])),[-1e6,"max","-","Jan",1,[0,0,0],o,"-"]}var a=new Date(t).getUTCFullYear();(i=i.filter((function(e){var t=e[0],n=e[1];return t<=a&&(n>=a||t===a&&"only"===n||"max"===n)}))).push(t),i.sort((function(e,t){return"number"!=typeof e&&(e=Number(Zh(a,e,n))),"number"!=typeof t&&(t=Number(Zh(a,t,n))),e-t}));var s=i[i.indexOf(t)-1]||i[i.length-1];return isNaN(s)?s:null},tp="The required {0} timezone information is not provided!",np=/\{(\d+)}?\}/g,ip=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var i=t.reduce((function(e,t){return e.concat(t)}),[]);return e.replace(np,(function(e,t){return i[parseInt(t,10)]}))},rp=function(e,t){if(void 0===t&&(t=(new Date).getTime()),"Etc/UTC"===e||"Etc/GMT"===e)return[0,"-","UTC",null];for(var n=function(e){var t=Yh.zones;if(!t)throw new Error(ip(tp,e));var n=t[e],i="string"==typeof n?t[n]:n;if(!i)throw new Error(ip(tp,e));return i}(e),i=n.length-1;i>=0;i--){var r=n[i][3];if(r&&t>r)break}var o=n[i+1];if(!o)throw new Error(ip(tp,e));return o},op=function(e,t){var n=t.getTime(),i=rp(e,n);return{rule:ep(i[1],n,i[0]),zone:i}},ap=function(e,t){return void 0===t&&(t=2),(e<0?"-":"")+new Array(t).concat([Math.abs(e)]).join("0").slice(-t)},sp=function(e,t){if(void 0===t&&(t=new Date),"Etc/UTC"===e||"Etc/GMT"===e)return 0;if(""===e)return t.getTimezoneOffset();var n=op(e,t),i=n.rule,r=n.zone;return parseFloat(i?r[0]-i[6]:r[0])};var lp=function(e,t){return new Date(e.getTime()+6e4*t)},cp=function(e,t){return new Date(e.getTime()+36e5*t)},dp=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],up=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function hp(e,t){var n=sp(t,e),i=cp(e,-1);return n<sp(t,i)}function pp(e,t){var n=hp(e,t)?1:0;return cp(e,n)}function fp(e,t,n){if(t===n)return e;var i=sp(t,e),r=sp(n,e),o=i-r,a=lp(e,o),s=sp(n,a);return lp(e,o+(r-s))}!function(){function e(e,t){this._utcDate=Bh(e),this.timezone=t;var n=sp(t,e);this.timezoneOffset=n;var i=pp(e,t);this._localDate=fp(i,t,"Etc/UTC")}Object.defineProperty(e.prototype,"cachedLocalDate",{get:function(){return this._localDate},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"cachedUTCDate",{get:function(){return this._utcDate},enumerable:!0,configurable:!0}),e.fromLocalDate=function(t,n){void 0===n&&(n="");var i=fp(t,"Etc/UTC",n),r=hp(i,n),o=sp(n,i),a=0;r&&(a=o>0?-1:1);var s=cp(i,a);return e.fromUTCDate(s,n)},e.fromUTCDate=function(t,n){return void 0===n&&(n=""),new e(t,n)},e.prototype.toLocalDate=function(){return Bh(this._localDate)},e.prototype.toUTCDate=function(){return Bh(this._utcDate)},e.prototype.toTimezone=function(t){if(this.timezone===t)return this.clone();var n=sp(this.timezone,this._utcDate),i=lp(this._utcDate,n);return e.fromLocalDate(i,t)},e.prototype.clone=function(){return e.fromUTCDate(this._utcDate,this.timezone)},e.prototype.addDays=function(t){var n=new Date(this._utcDate.getTime());return n.setUTCDate(n.getUTCDate()+t),e.fromUTCDate(n,this.timezone)},e.prototype.addTime=function(t){var n=pp(new Date(this._utcDate.getTime()),this.timezone);n.setTime(n.getTime()+t);var i=pp(n,this.timezone);return e.fromUTCDate(i,this.timezone)},e.prototype.stripTime=function(){var t=this._utcDate,n=Date.UTC(t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate(),0,0,0);return e.fromUTCDate(new Date(n),this.timezone)},e.prototype.getTime=function(){return this._localDate.getTime()},e.prototype.getTimezoneOffset=function(){return this.timezoneOffset},e.prototype.getFullYear=function(){return this._utcDate.getUTCFullYear()},e.prototype.getMonth=function(){return this._utcDate.getUTCMonth()},e.prototype.getDate=function(){return this._utcDate.getUTCDate()},e.prototype.getDay=function(){return this._utcDate.getUTCDay()},e.prototype.getHours=function(){return this._utcDate.getUTCHours()},e.prototype.getMinutes=function(){return this._utcDate.getUTCMinutes()},e.prototype.getSeconds=function(){return this._utcDate.getUTCSeconds()},e.prototype.getMilliseconds=function(){return this._utcDate.getUTCMilliseconds()},e.prototype.getUTCDate=function(){return this._localDate.getUTCDate()},e.prototype.getUTCDay=function(){return this._localDate.getUTCDay()},e.prototype.getUTCFullYear=function(){return this._localDate.getUTCFullYear()},e.prototype.getUTCHours=function(){return this._localDate.getUTCHours()},e.prototype.getUTCMilliseconds=function(){return this._localDate.getUTCMilliseconds()},e.prototype.getUTCMinutes=function(){return this._localDate.getUTCMinutes()},e.prototype.getUTCMonth=function(){return this._localDate.getUTCMonth()},e.prototype.getUTCSeconds=function(){return this._localDate.getUTCSeconds()},e.prototype.setTime=function(e){throw new Error("Method not implemented.")},e.prototype.setMilliseconds=function(e){throw new Error("Method not implemented.")},e.prototype.setUTCMilliseconds=function(e){throw new Error("Method not implemented.")},e.prototype.setSeconds=function(e,t){throw new Error("Method not implemented.")},e.prototype.setUTCSeconds=function(e,t){throw new Error("Method not implemented.")},e.prototype.setMinutes=function(e,t,n){throw new Error("Method not implemented.")},e.prototype.setUTCMinutes=function(e,t,n){throw new Error("Method not implemented.")},e.prototype.setHours=function(e,t,n,i){throw new Error("Method not implemented.")},e.prototype.setUTCHours=function(e,t,n,i){throw new Error("Method not implemented.")},e.prototype.setDate=function(e){throw new Error("Method not implemented.")},e.prototype.setUTCDate=function(e){throw new Error("Method not implemented.")},e.prototype.setMonth=function(e,t){throw new Error("Method not implemented.")},e.prototype.setUTCMonth=function(e,t){throw new Error("Method not implemented.")},e.prototype.setFullYear=function(e,t,n){throw new Error("Method not implemented.")},e.prototype.setUTCFullYear=function(e,t,n){throw new Error("Method not implemented.")},e.prototype.toISOString=function(){return this._localDate.toISOString()},e.prototype.toJSON=function(){return this._localDate.toJSON()},e.prototype.toString=function(){var e,t=(e=this._utcDate,dp[e.getUTCDay()]+" "+up[e.getUTCMonth()]),n=this.toTimeString();return t+" "+this.getDate()+" "+this.getFullYear()+" "+n},e.prototype.toDateString=function(){return function(e){return new Date(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds())}(this._utcDate).toDateString()},e.prototype.toTimeString=function(){var e=ap(this.getHours())+":"+ap(this.getMinutes())+":"+ap(this.getSeconds()),t=function(e){var t=e<=0?"+":"-",n=Math.abs(e);return"GMT"+t+ap(Math.floor(n/60))+ap(n%60)}(this.timezoneOffset),n=function(e,t){if(void 0===t&&(t=new Date),"Etc/UTC"===e)return"UTC";if("Etc/GMT"===e)return"GMT";if(""===e)return"";var n=op(e,t),i=n.zone,r=n.rule,o=i[2];if(o.indexOf("/")>=0)return o.split("/")[r&&+r[6]?1:0];if(o.indexOf("%s")>=0)return o.replace("%s",r&&"-"!==r[7]?r[7]:"");if(o.indexOf("%z")>=0){var a=-1*Math.trunc(i[0]/60),s=ap(a,2),l=a>0?"+":"",c=Math.abs(Math.trunc(i[0]%60)),d=0===c?"":ap(c,2);return o.replace("%z",""+l+s+d)}return o}(this.timezone,this._utcDate);return n&&(n=" ("+n+")"),e+" "+t+n},e.prototype.toLocaleString=function(e,t){return this._localDate.toLocaleString(e,t)},e.prototype.toLocaleDateString=function(e,t){return this._localDate.toLocaleDateString(e,t)},e.prototype.toLocaleTimeString=function(e,t){return this._localDate.toLocaleTimeString(e,t)},e.prototype.toUTCString=function(){return this.toTimezone("Etc/UTC").toString()},e.prototype[Symbol.toPrimitive]=function(e){return"string"===e||"default"===e?this.toString():this._localDate.getTime()},e.prototype.valueOf=function(){return this.getTime()},e.prototype.getVarDate=function(){throw new Error("Not implemented.")},e.prototype.format=function(e){throw new Error("Not implemented.")},e.prototype.formatUTC=function(e){throw new Error("Not implemented.")}}();var mp=function(e,t){return mp=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},mp(e,t)};function gp(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}mp(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var vp=function(){return vp=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e},vp.apply(this,arguments)};function _p(e,t,n,i){return new(n||(n=Promise))((function(r,o){function a(e){try{l(i.next(e))}catch(e){o(e)}}function s(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){e.done?r(e.value):function(e){return e instanceof n?e:new n((function(t){t(e)}))}(e.value).then(a,s)}l((i=i.apply(e,t||[])).next())}))}Object.create;Object.create;function bp(e,t,n,i){if("a"===n&&!i)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!i:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?i:"a"===n?i.call(e):i?i.value:t.get(e)}function yp(e,t,n,i,r){if("m"===i)throw new TypeError("Private method is not writable");if("a"===i&&!r)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!r:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===i?r.call(e,n):r?r.value=n:t.set(e,n),n}"function"==typeof SuppressedError&&SuppressedError;var wp,kp,xp,Cp=function(){this.symbols="",this.partMap=[]},Sp="_",Tp=68,Dp="d",Ap="en",Mp="Delete",Ep="Backspace",Ip=" ",zp=function(e){return new Array(Math.max(e,0)).fill("0").join("")},Pp=function(e){return e.replace(/^0*/,"")},Hp=function(e,t){return e[t.pattern[0]]=t.type,e},Fp=function(e){return null!=e},Rp=function(e){return Fp(e)&&"number"==typeof e&&!Number.isNaN(e)},Lp=function(e){return parseInt(e,10)},Bp=function(e){return Rp(Lp(e))&&/^[0-9]+$/.test(e)},Op=function(e,t,n){return Math.min(n,Math.max(t,e))},Vp=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return Object.assign.apply(Object,e)},Np=(wp="setFullYear",function(e,t){var n=Bh(e);return n[wp](t),n}),$p=function(e,t,n,i,r,o,a,s){return!(!e||e.getFullYear()!==t||e.getMonth()!==n||e.getDate()!==i||e.getHours()!==r||e.getMinutes()!==o||e.getSeconds()!==a||e.getMilliseconds()!==s)},Up=function(e){return Fp(e)&&e.getTime&&Rp(e.getTime())},Wp=/d|M|H|h|m|s/,jp=function(){function e(e){var t=e.intlService,n=e.formatPlaceholder,i=e.format,r=e.cycleTime,o=void 0!==r&&r,a=e.twoDigitYearMax,s=void 0===a?Tp:a,l=e.value,c=void 0===l?null:l,d=e.autoCorrectParts,u=void 0===d||d;if(this.year=!0,this.month=!0,this.date=!0,this.hours=!0,this.minutes=!0,this.seconds=!0,this.milliseconds=!0,this.dayperiod=!0,this.leadingZero=null,this.typedMonthPart="",this.knownParts="adHhmMsEyS",this.symbols={E:"E",H:"H",M:"M",a:"a",d:"d",h:"h",m:"m",s:"s",y:"y",S:"S"},this._value=this.getDefaultDate(),this.cycleTime=!1,this._partiallyInvalidDate={startDate:null,invalidDateParts:{E:{value:null,date:null,startDateOffset:0},H:{value:null,date:null,startDateOffset:0},M:{value:null,date:null,startDateOffset:0},a:{value:null,date:null,startDateOffset:0},d:{value:null,date:null,startDateOffset:0},h:{value:null,date:null,startDateOffset:0},m:{value:null,date:null,startDateOffset:0},s:{value:null,date:null,startDateOffset:0},y:{value:null,date:null,startDateOffset:0},S:{value:null,date:null,startDateOffset:0}}},this.setOptions({intlService:t,formatPlaceholder:n,format:i,cycleTime:o,twoDigitYearMax:s,value:c,autoCorrectParts:u}),c)this._value=Bh(c);else{this._value=this.getDefaultDate();for(var h=this.dateFormatString(this.value,this.format).symbols,p=0;p<h.length;p++)this.setExisting(h[p],!1)}}return Object.defineProperty(e.prototype,"value",{get:function(){return this._value},set:function(e){(!e||e instanceof Date)&&(this._value=e,this.resetInvalidDate())},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"localeId",{get:function(){for(var e=Ap,t=Object.keys(this.intl.cldr),n=0;n<t.length;n++){var i=t[n],r=this.intl.cldr[i];if(r.name&&r.calendar&&r.numbers&&r.name!==Ap){e=r.name;break}}return e},enumerable:!0,configurable:!0}),e.prototype.setOptions=function(e){this.intl=e.intlService,this.formatPlaceholder=e.formatPlaceholder||"wide",this.format=e.format,this.cycleTime=e.cycleTime,this.monthNames=this.allFormattedMonths(this.localeId),this.dayPeriods=this.allDayPeriods(this.localeId),this.twoDigitYearMax=e.twoDigitYearMax,this.autoCorrectParts=e.autoCorrectParts},e.prototype.setValue=function(e){e?Kh(e,this._value)||(this._value=Bh(e),this.modifyExisting(!0)):(this._value=this.getDefaultDate(),this.modifyExisting(!1)),this.resetInvalidDate()},e.prototype.hasValue=function(){var e=this;return this.intl.splitDateFormat(this.format,this.localeId).reduce((function(t,n){return t||"literal"!==n.type&&"dayperiod"!==n.type&&e.getExisting(n.pattern[0])}),!1)},e.prototype.getValue=function(){for(var e=0;e<this.knownParts.length;e++)if(!this.getExisting(this.knownParts[e]))return null;return Bh(this.value)},e.prototype.createDefaultDate=function(){return Nh(2e3,0,31)},e.prototype.getDefaultDate=function(){return Gh(this.createDefaultDate())},e.prototype.getFormattedDate=function(e){return this.intl.formatDate(this.getValue(),e,this.localeId)},e.prototype.getTextAndFormat=function(e){void 0===e&&(e="");var t=e||this.format,n=this.intl.formatDate(this.value,t,this.localeId),i=this.dateFormatString(this.value,t);if(!this.autoCorrectParts&&this._partiallyInvalidDate.startDate){for(var r="",o=this.intl.formatDate(this.value,t,this.localeId),a=this.getFormattedInvalidDates(t),s=0;s<o.length;s++){var l=i.symbols[s];if("literal"===i.partMap[s].type)r+=n[s];else if(this.getInvalidDatePartValue(l)){var c=this.getPartsForSegment(i,s);if("M"===l){var d=(Lp(this.getInvalidDatePartValue(l))+1).toString();if(c.length>2)r+=a[l][s];else if(this.getInvalidDatePartValue(l))r+=zp(c.length-d.length)+d,s+=c.length-1;else r+=a[l][s]}else if(this.getInvalidDatePartValue(l)){d=this.getInvalidDatePartValue(l).toString();r+=zp(c.length-d.length)+d,s+=c.length-1}else r+=a[l][s]}else r+=n[s]}n=r}return this.merge(n,i)},e.prototype.getFormattedInvalidDates=function(e){var t=this;void 0===e&&(e="");var n=e||this.format,i={E:"",H:"",M:"",a:"",d:"",h:"",m:"",s:"",y:"",S:""};return Object.keys(this._partiallyInvalidDate.invalidDateParts).forEach((function(e){var r=t.getInvalidDatePart(e).date;if(r){var o=t.intl.formatDate(r,n,t.localeId);i[e]=o}})),i},e.prototype.modifyExisting=function(e){for(var t=this.dateFormatString(this.value,this.format).symbols,n=0;n<t.length;n++)this.setExisting(t[n],e)},e.prototype.getExisting=function(e){switch(e){case"y":return this.year;case"M":case"L":return this.month;case"d":return this.date;case"E":return this.date&&this.month&&this.year;case"h":case"H":return this.hours;case"t":case"a":return this.dayperiod;case"m":return this.minutes;case"s":return this.seconds;case"S":return this.milliseconds;default:return!0}},e.prototype.setExisting=function(e,t){switch(e){case"y":this.year=t,!1===t&&this._value.setFullYear(2e3);break;case"M":this.month=t,!1===t&&this.autoCorrectParts&&this._value.setMonth(0);break;case"d":this.date=t;break;case"h":case"H":this.hours=t;break;case"t":case"a":this.dayperiod=t;break;case"m":this.minutes=t;break;case"s":this.seconds=t;break;case"S":this.milliseconds=t}this.getValue()&&this.resetInvalidDate()},e.prototype.modifyPart=function(e,t){if(Fp(e)&&Fp(t)&&0!==t){var n,i=Bh(this.value),r=!1,o="M"===e,a="d"===e||"E"===e,s=this.getExisting(e);if(this.autoCorrectParts||!a&&!o)switch(e){case"y":i.setFullYear(i.getFullYear()+t);break;case"M":i=Uh(this.value,t);break;case"d":case"E":i.setDate(i.getDate()+t);break;case"h":case"H":i.setHours(i.getHours()+t),r=!0;break;case"m":i.setMinutes(i.getMinutes()+t),r=!0;break;case"s":i.setSeconds(i.getSeconds()+t),r=!0;break;case"S":i.setMilliseconds(i.getMilliseconds()+t);break;case"a":i.setHours(i.getHours()+12*t),r=!0}else{var l=this._partiallyInvalidDate.invalidDateParts||{},c=this.getInvalidDatePartValue(e),d=l.y.value||i.getFullYear(),u=l.M.value||i.getMonth(),h=l.d.value||l.E.value||i.getDate(),p=l.h.value||l.H.value||i.getHours(),f=l.m.value||i.getMinutes(),m=l.s.value||i.getSeconds(),g=l.S.value||i.getMilliseconds();switch(e){case"y":d+=t;break;case"M":u+=t;break;case"d":case"E":h+=t}if("M"===e){if((u<0||u>11)&&s)return this.setExisting(e,!1),void this.resetInvalidDateSymbol(e);if(!s){if(u<0)u=Op(u%11+1+11,0,11);else{var v=Fp(c)?u:(t-1)%12;u=Op(v,0,11)}u=Op(u,0,11)}u=Op(u,0,11)}else if("d"===e)if(s){if(h<=0||h>31)return this.setExisting(e,!1),void this.resetInvalidDateSymbol(e)}else if(!s){if(Fp(c)&&(h<=0||h>31))return this.setExisting(e,!1),void this.resetInvalidDateSymbol(e);if(t<0){var _=Fp(c)?h:31-Math.abs(t%31)+1;h=Op(_,1,31)}else{_=Fp(c)?h:t%31;h=Op(_,1,31)}h=Op(h,1,31)}var b=Nh(d,u,h,p,f,m,g),y=o||a?this.modifyDateSymbolWithValue(i,e,o?u:h):null,w=$p(b,d,u,h,p,f,m,g);this.getValue()&&$p(b,d,u,h,p,f,m,g)?(i=Bh(b),this.markDatePartsAsExisting()):o&&y?y.getMonth()===u?this.getExisting("d")?w?(i=Bh(b),this.resetInvalidDateSymbol(e)):(n=!0,this.setInvalidDatePart(e,{value:u,date:Bh(y),startDateOffset:t,startDate:Bh(this.value)}),this.setExisting(e,!1)):w?(this.resetInvalidDateSymbol(e),i=Bh(b),this.getExisting("M")&&this.getExisting("y")&&(this.setExisting("d",!0),this.resetInvalidDateSymbol("d"))):(this.resetInvalidDateSymbol(e),i=Bh(y)):(n=!0,this.setInvalidDatePart(e,{value:u,date:Bh(y),startDateOffset:t,startDate:Bh(this.value)}),this.setExisting(e,!1)):a&&y&&(y.getDate()===h?this.getExisting("M")?w?(i=Bh(b),this.resetInvalidDateSymbol(e)):(n=!0,this.setInvalidDatePart(e,{value:h,date:Bh(y),startDateOffset:t,startDate:Bh(this.value)}),this.setExisting(e,!1)):w?(i=Bh(b),this.resetInvalidDateSymbol(e),this.getExisting("d")&&this.getExisting("y")&&(this.setExisting("M",!0),this.resetInvalidDateSymbol("M"))):(this.resetInvalidDateSymbol(e),i=Bh(y)):(n=!0,this.setInvalidDatePart(e,{value:h,date:Bh(this.value),startDateOffset:t,startDate:Bh(this.value)}),this.setExisting(e,!1)))}this.shouldNormalizeCentury()&&(i=this.normalizeCentury(i)),r&&!this.cycleTime&&(i.getDate(),this._value.getDate()),n||(this.setExisting(e,!0),this._value=i,this.getValue()&&this.resetInvalidDate())}},e.prototype.parsePart=function(e){for(var t=e.symbol,n=e.currentChar,i=e.resetSegmentValue,r=e.cycleSegmentValue,o=e.rawTextValue,a=e.isDeleting,s=e.originalFormat,l=!r,c=this.dateFormatString(this.value,this.format),d=c.partMap.filter((function(e){return"literal"===e.type})).map((function(e,t){return{datePartIndex:t,type:e.type,pattern:e.pattern,literal:""}})),u=c.partMap.map((function(e){return{type:e.type,pattern:e.pattern,text:""}})),h=0;h<d.length;h++){for(var p=d[h],f=0;f<p.pattern.length;f++)d[h+f]&&(d[h+f].literal=p.pattern[f]);h+=p.pattern.length-1}for(h=0;h<u.length;h++){for(p=u[h],f=0;f<p.pattern.length;f++)u[h+f]&&(u[h+f].text=p.pattern[f]);h+=p.pattern.length-1}var m={value:null,switchToNext:!1,resetPart:l&&"M"===t&&c.partMap.filter((function(e){return"month"===e.type})).some((function(e){return e.pattern.length>2})),hasInvalidDatePart:!1};if(!n){if(!l)return this.resetLeadingZero(),this.setExisting(t,!1),this.resetInvalidDateSymbol(t),Vp(m,{value:null,switchToNext:!1});for(h=0;h<d.length;h++){var g=d[h].literal,v=o.startsWith(g),_=o.endsWith(g),b=o.indexOf(g+g)>=0;if(v||_||b)return this.resetLeadingZero(),this.setExisting(t,!1),this.resetInvalidDateSymbol(t),Vp(m,{value:null,switchToNext:!1})}}var y=this.intl.formatDate(this.value,this.format,this.localeId),w=c.symbols,k=!1,x="",C="",S="",T="",D="",A="",M="";for(h=0;h<u.length;h++)M+=u[h].text;var E=this.format===w||this.format===M||this.format===s||this.format.length===s.length,I=(E?M:s).indexOf(t),z=(E?M:s).lastIndexOf(t)-I+1,P=s.length-o.length;if(l||!l&&!this.autoCorrectParts){for(h=0;h<y.length;h++){if(w[h]===t)C+=this.getExisting(t)?y[h]:"0",P>0?S.length+P<z&&(S+=o[h]||""):S+=o[h]||"",k=!0;else k?(A+=y[h],D+=y[h]):(x+=y[h],T+=y[h])}if(E&&(M.length<o.length?S+=n:!a&&(s.length,o.length),S.length>z))return Vp(m,{value:null,switchToNext:!1});if(!E||E&&!this.autoCorrectParts){C="",S="",x="",A="",k=!1;for(h=0;h<s.length;h++){if(s[h]===t)C+=this.getExisting(t)?y[h]||"":"0",P>0?S.length+P<z&&(S+=o[h]||""):S+=o[h]||"",k=!0;else k?A+=o[h-P]||"":x+=o[h]||""}s.length<o.length&&(S+=n)}}if(!l)if(this.autoCorrectParts){C="",S="",x="",A="",k=!1;for(h=0;h<y.length;h++){if(w[h]===t)C+=this.getExisting(t)?y[h]:"0",k=!0;else k?A+=y[h]:x+=y[h]}}else C=i?S:C;var H=null,F=this.matchMonth(n),R=this.matchDayPeriod(n,t),L="0"===n,B=this.leadingZero||{};L?("0"===S&&(S=C),0!==Lp(i?n:(l?S:C)+n)||this.isAbbrMonth(c.partMap,t)||this.incrementLeadingZero(t)):this.resetLeadingZero();var O=this.partPattern(c.partMap,t),V=O?O.pattern:null,N=this.patternLength(V)||V.length;if(l&&a&&!S)return this.setExisting(t,!1),Vp(m,{value:null,switchToNext:!1});var $=C.length-3,U=!0,W=l?S:C;for(h=Math.max(0,$);h<=C.length&&U;h++){W=i?n:l?S:C.substring(h)+n,!l&&this.autoCorrectParts||(U=!1,W=Pp(W),W=zp(N-W.length)+W);var j=parseInt(W,10),q=x+W+A;H=this.intl.parseDate(q,this.format,this.localeId);var G=!1;l&&!Up(H)&&this.autoCorrectParts&&(H=this.intl.parseDate(T+W+D,this.format,this.localeId),G=!0);var K=!isNaN(parseInt(n,10))||l&&a&&""===n;if(!H&&!isNaN(j)&&K&&this.autoCorrectParts){if("M"===t&&!F){var Y=j-1;Y>-1&&Y<12&&((H=Bh(this.value)).setMonth(Y),H.getMonth()!==Y&&(H=$h(Uh(H,-1))))}"y"===t&&(H=Nh(parseInt(W,10),this.month?this.value.getMonth():0,this.date?this.value.getDate():1,this.hours?this.value.getHours():0,this.minutes?this.value.getMinutes():0,this.seconds?this.value.getSeconds():0,this.milliseconds?this.value.getMilliseconds():0),(l&&Up(H)||!l&&H)&&this.date&&H.getDate()!==this.value.getDate()&&(H=$h(Uh(H,-1))))}if(l&&Up(H)||!l&&H){var Q=this.isPeekDateOverflowingDatePart({useBasePrefixAndSuffix:G,middle:W,patternValue:V,basePrefix:T,baseSuffix:D,prefix:x,suffix:A,symbol:t,patternLength:N,leadingZero:B}),X=Q.switchToNext;return this.shouldNormalizeCentury()&&(H=this.normalizeCentury(H)),"H"===t&&H.getHours()>=12&&this.setExisting("a",!0),this._value=H,this.setExisting(t,!0),this.resetInvalidDateSymbol(t),this.autoCorrectParts||("M"===t?this.getExisting("M")&&this.getExisting("y")&&(this.setExisting("d",!0),this.resetInvalidDateSymbol("d")):"d"===t&&this.getExisting("d")&&this.getExisting("y")&&(this.setExisting("M",!0),this.resetInvalidDateSymbol("M")),this.hasInvalidDatePart()||(this.markDatePartsAsExisting(),Q.peekedDate||!Q.switchToNext||this.autoCorrectParts||"M"===t||"d"===t&&30===Q.parsedPeekedValue&&1===this.value.getMonth()&&(X=!1))),Vp(m,{value:this.value,switchToNext:X})}}if(F&&(H=this.intl.parseDate(x+F+A,this.format,this.localeId)))return this._value=H,this.setExisting(t,!0),Vp(m,{value:this.value,switchToNext:!1});if(R&&(H=this.intl.parseDate(x+R+A,this.format)||this.intl.parseDate(T+R+D,this.format)))return this._value=H,this.setExisting(t,!0),Vp(m,{value:this.value,switchToNext:!0});if(L&&this.setExisting(t,!1),!this.autoCorrectParts){var Z=void 0,J=l?S:W,ee=Lp(J);if(Rp(ee)&&Bp(J)){if("d"===t&&(ee<=0||ee>31)||"M"===t&&(ee<=0||ee>11)){if(l)return Vp(m,{value:null,switchToNext:!1});ee=Lp(J=n)}if(!Rp(ee)||!Bp(J))return Vp(m,{value:null,switchToNext:!1});Z="M"===t?ee-1:ee;var te="M"===t,ne="d"===t,ie=Bh(this._value),re=this._partiallyInvalidDate.invalidDateParts||{},oe=re.y.value||ie.getFullYear(),ae=te?Z:re.M.value||ie.getMonth(),se=ne?Z:re.d.value||re.E.value||ie.getDate(),le=re.h.value||re.H.value||ie.getHours(),ce=re.m.value||ie.getMinutes(),de=re.s.value||ie.getSeconds(),ue=re.S.value||ie.getMilliseconds(),he=Nh(oe,ae,se,le,ce,de,ue),pe=$p(he,oe,ae,se,le,ce,de,ue),fe=te||ne?this.modifyDateSymbolWithValue(ie,t,te?ae:se):null,me=!1;if(te&&fe?fe.getMonth()===ae?this.getExisting("d")?pe?(ie=Bh(he),this.resetInvalidDateSymbol(t)):(me=!0,this.setInvalidDatePart(t,{value:ae,date:Bh(fe),startDate:Bh(this.value)}),this.setExisting(t,!1)):pe?(this.resetInvalidDateSymbol(t),ie=Bh(he),this.getExisting("M")&&this.getExisting("y")&&(this.setExisting("d",!0),this.resetInvalidDateSymbol("d"))):(this.resetInvalidDateSymbol(t),ie=Bh(fe)):(me=!0,this.setInvalidDatePart(t,{value:ae,date:Bh(fe),startDate:Bh(this.value)}),this.setExisting(t,!1)):ne&&fe&&(fe.getDate()===se?this.getExisting("M")?pe?(ie=Bh(he),this.resetInvalidDateSymbol(t)):(me=!0,this.setInvalidDatePart(t,{value:se,date:Bh(fe),startDate:Bh(this.value)}),this.setExisting(t,!1)):pe?(ie=Bh(he),this.resetInvalidDateSymbol(t),this.getExisting("d")&&this.getExisting("y")&&(this.setExisting("M",!0),this.resetInvalidDateSymbol("M"))):(this.resetInvalidDateSymbol(t),ie=Bh(fe)):(me=!0,this.setInvalidDatePart(t,{value:se,date:Bh(this.value),startDate:Bh(this.value)}),this.setExisting(t,!1))),!me){if(this.setExisting(t,!0),l&&!Up(H)){var ge=this.intl.parseDate(T+W+D,this.format,this.localeId);Up(ge)&&(this._value=ge)}else this._value=ie;this.getValue()&&this.resetInvalidDate()}X=!1;if("M"===t)X=ee>=2||J.length>=2;else if(E)X=this.isPeekDateOverflowingDatePart({useBasePrefixAndSuffix:!this.autoCorrectParts,middle:W,patternValue:V,basePrefix:T,baseSuffix:D,prefix:x,suffix:A,symbol:t,patternLength:N,leadingZero:B}).switchToNext;else X=J.length>z;return Vp(m,{value:null,switchToNext:X,hasInvalidDatePart:me})}}return Vp(m,{value:null,switchToNext:!1})},e.prototype.symbolMap=function(e){return this.intl.splitDateFormat(this.format,this.localeId).reduce(Hp,{})[e]},e.prototype.resetLeadingZero=function(){var e=null!==this.leadingZero;return this.setLeadingZero(null),e},e.prototype.setLeadingZero=function(e){this.leadingZero=e},e.prototype.getLeadingZero=function(){return this.leadingZero||{}},e.prototype.normalizeCentury=function(e){if(!Fp(e))return e;var t=function(e){return!Fp(e)||isNaN(e.getTime())?0:Number(e.getFullYear().toString().slice(-2))}(e),n=this.getNormalizedCenturyBase(t);return Np(e,n+t)},e.prototype.incrementLeadingZero=function(e){var t=this.leadingZero||{};t[e]=(t[e]||0)+1,this.leadingZero=t},e.prototype.isAbbrMonth=function(e,t){var n=this.partPattern(e,t);return"month"===n.type&&n.names},e.prototype.partPattern=function(e,t){return e.filter((function(e){return-1!==e.pattern.indexOf(t)}))[0]},e.prototype.peek=function(e,t){var n=e.replace(/^0*/,"")+"0";return zp(t.length-n.length)+n},e.prototype.matchMonth=function(e){if(this.typedMonthPart+=e.toLowerCase(),0===this.monthNames.length)return"";for(;this.typedMonthPart.length>0;){for(var t=0;t<this.monthNames.length;t++)if(0===this.monthNames[t].toLowerCase().indexOf(this.typedMonthPart))return this.monthNames[t];var n=parseInt(this.typedMonthPart,10);if(n>=1&&n<=12&&n.toString()===this.typedMonthPart)return this.monthNames[n-1];this.typedMonthPart=this.typedMonthPart.substring(1,this.typedMonthPart.length)}return""},e.prototype.matchDayPeriod=function(e,t){var n=e.toLowerCase();if("a"===t&&this.dayPeriods){if(this.dayPeriods.am.toLowerCase().startsWith(n))return this.dayPeriods.am;if(this.dayPeriods.pm.toLowerCase().startsWith(n))return this.dayPeriods.pm}return""},e.prototype.allFormattedMonths=function(e){void 0===e&&(e="en");for(var t=this.intl.splitDateFormat(this.format,this.localeId),n=0;n<t.length;n++)if("month"===t[n].type&&t[n].names)return this.intl.dateFormatNames(e,t[n].names);return[]},e.prototype.allDayPeriods=function(e){void 0===e&&(e="en");for(var t=this.intl.splitDateFormat(this.format),n=0;n<t.length;n++)if("dayperiod"===t[n].type&&t[n].names)return this.intl.dateFormatNames(e,t[n].names);return null},e.prototype.patternLength=function(e){return"y"===e[0]?4:Wp.test(e)?2:0},e.prototype.dateFormatString=function(e,t){for(var n=this.intl.splitDateFormat(t,this.localeId),i=[],r=[],o=0;o<n.length;o++)for(var a=this.intl.formatDate(e,{pattern:n[o].pattern},this.localeId).length;a>0;)i.push(this.symbols[n[o].pattern[0]]||Sp),r.push(n[o]),a--;var s=new Cp;return s.symbols=i.join(""),s.partMap=r,s},e.prototype.merge=function(e,t){for(var n="",i="",r=t.symbols,o=!1,a=0,s=this.getFormattedInvalidDates(r),l=r.length-1;l>=0;l--){var c=this.getPartsForSegment(t,l);if(-1===this.knownParts.indexOf(r[l])||this.getExisting(r[l]))this.autoCorrectParts?n=e[l]+n:e.length!==r.length?o?n=e[l]+n:a>0?(n=e[l]+n,--a<=0&&(o=!0)):n=(e[l+e.length-r.length]||"")+n:n=e[l]+n,i=r[l]+i;else{var d=r[l],u=0;if(this.autoCorrectParts||!this.autoCorrectParts&&!this.getInvalidDatePartValue(d)){for(;l>=0&&d===r[l];)l--;l++}if(this.leadingZero&&this.leadingZero[d])n="0"+n;else if(!this.autoCorrectParts&&this.getInvalidDatePartValue(d)){var h=this.getInvalidDatePartValue(d).toString();if("M"===d)if(h=(Lp(this.getInvalidDatePartValue(d))+1).toString(),c.length>2)n=s[d][l]+n;else h=(Lp(this.getInvalidDatePartValue(d))+1).toString(),n=zp(c.length-h.length)+h+n,u=c.length-1,a=h.length-c.length;else n=zp(c.length-h.length)+h+n,u=c.length-1,a=h.length-c.length}else n=this.dateFieldName(t.partMap[l])+n;for(;i.length<n.length;)i=r[l]+i;0!==u&&(l=l-u+(e.length-r.length))}}return{text:n,format:i}},e.prototype.dateFieldName=function(e){var t=this.formatPlaceholder||"wide";return t[e.type]?t[e.type]:"formatPattern"===t?e.pattern:this.intl.dateFieldName(Object.assign(e,{nameType:t}))},e.prototype.getNormalizedCenturyBase=function(e){return e>this.twoDigitYearMax?1900:2e3},e.prototype.shouldNormalizeCentury=function(){return this.intl.splitDateFormat(this.format).some((function(e){return"yy"===e.pattern}))},e.prototype.resetInvalidDate=function(){var e=this;this._partiallyInvalidDate.startDate=null,Object.keys(this._partiallyInvalidDate.invalidDateParts).forEach((function(t){e.resetInvalidDatePart(t)}))},e.prototype.resetInvalidDateSymbol=function(e){var t=this;this.resetInvalidDatePart(e);var n=!0;Object.keys(this._partiallyInvalidDate.invalidDateParts).forEach((function(e){t._partiallyInvalidDate.invalidDateParts[e]&&Fp(t._partiallyInvalidDate.invalidDateParts[e].value)&&(n=!1)})),n&&this.resetInvalidDate()},e.prototype.resetInvalidDatePart=function(e){this._partiallyInvalidDate.invalidDateParts[e]&&(this._partiallyInvalidDate.invalidDateParts[e]={value:null,date:null,startDateOffset:0})},e.prototype.getInvalidDatePart=function(e){return this._partiallyInvalidDate.invalidDateParts[e]||{}},e.prototype.getInvalidDatePartValue=function(e){return(this._partiallyInvalidDate.invalidDateParts[e]||{}).value},e.prototype.setInvalidDatePart=function(e,t){var n=t.value,i=void 0===n?null:n,r=t.date,o=void 0===r?null:r,a=t.startDateOffset,s=void 0===a?0:a,l=t.startDate,c=void 0===l?null:l;this._partiallyInvalidDate.invalidDateParts[e]&&(this._partiallyInvalidDate.invalidDateParts[e].value=i,this._partiallyInvalidDate.invalidDateParts[e].date=o,this._partiallyInvalidDate.invalidDateParts[e].startDateOffset=s,this._partiallyInvalidDate.startDate=c)},e.prototype.hasInvalidDatePart=function(){var e=this,t=!1;return Object.keys(this._partiallyInvalidDate.invalidDateParts).forEach((function(n){e._partiallyInvalidDate.invalidDateParts[n]&&Fp(e._partiallyInvalidDate.invalidDateParts[n].value)&&(t=!0)})),t},e.prototype.modifyDateSymbolWithOffset=function(e,t,n){var i=Bh(e),r=!1;switch(t){case"y":i.setFullYear(i.getFullYear()+n);break;case"M":i=Uh(this.value,n);break;case"d":case"E":i.setDate(i.getDate()+n);break;case"h":case"H":i.setHours(i.getHours()+n),r=!0;break;case"m":i.setMinutes(i.getMinutes()+n),r=!0;break;case"s":i.setSeconds(i.getSeconds()+n),r=!0;break;case"S":i.setMilliseconds(i.getMilliseconds()+n);break;case"a":i.setHours(i.getHours()+12*n),r=!0}return{date:i,timeModified:r}},e.prototype.modifyDateSymbolWithValue=function(e,t,n){var i=Bh(e);switch(t){case"y":i.setFullYear(n);break;case"M":i=Uh(e,n-e.getMonth());break;case"d":case"E":i.setDate(n);break;case"h":case"H":case"a":i.setHours(n);break;case"m":i.setMinutes(n);break;case"s":i.setSeconds(n);break;case"S":i.setMilliseconds(n)}return i},e.prototype.markDatePartsAsExisting=function(){this.modifyExisting(!0)},e.prototype.getPartsForSegment=function(e,t){for(var n=e.partMap[t],i=[],r=t;r<e.partMap.length;r++){var o=e.partMap[r];if(n.type!==o.type||n.pattern!==o.pattern)break;i.push(o)}for(r=t-1;r>=0;r--){o=e.partMap[r];if(n.type!==o.type||n.pattern!==o.pattern)break;i.unshift(o)}return i},e.prototype.isPeekDateOverflowingDatePart=function(e){var t=e.useBasePrefixAndSuffix,n=e.middle,i=e.patternValue,r=e.basePrefix,o=e.baseSuffix,a=e.prefix,s=e.suffix,l=e.symbol,c=e.patternLength,d=e.leadingZero,u=this.peek(n,i),h=t?""+r+u+o:""+a+u+s,p=this.intl.parseDate(h,this.format,this.localeId),f=((this.leadingZero||{})[l]||0)+Pp(n).length>=c;return{peekedDate:p,peekedDateString:h,peekedValue:u,parsedPeekedValue:Lp(u),switchToNext:null===p||(d[l]?i.length<=n.length:f)}},e}(),qp=8,Gp=46,Kp=9,Yp=13,Qp=37,Xp=38,Zp=39,Jp=40,ef=35,tf=36,nf={events:{}},rf=function(){function e(e){this.options=Vp({},nf,e)}return e.prototype.destroy=function(){},e.prototype.trigger=function(e,t){void 0===t&&(t={});var n={defaultPrevented:!1,preventDefault:function(){n.defaultPrevented=!0}};return"function"==typeof this.options.events[e]&&(this.options.events[e](Vp(n,t,{sender:this})),n.defaultPrevented)},e}();!function(e){e.None="none",e.Caret="caret",e.Selection="selection"}(kp||(kp={}));var of="dragStart",af="drop",sf="touchstart",lf="mousedown",cf="mouseup",df="click",uf="input",hf="keydown",pf="focus",ff="blur",mf="paste",gf="DOMMouseScroll",vf="mousewheel",_f="valueChange",bf="inputEnd",yf="blurEnd",wf="focusEnd",kf="change",xf={format:"d",hasPlaceholder:!1,placeholder:null,cycleTime:!0,locale:null,steps:{millisecond:1,second:1,minute:1,hour:1,day:1,month:1,year:1},formatPlaceholder:null,events:(xp={},xp[_f]=null,xp[uf]=null,xp[bf]=null,xp[pf]=null,xp[wf]=null,xp[ff]=null,xp[yf]=null,xp[hf]=null,xp[vf]=null,xp[kf]=null,xp),selectNearestSegmentOnFocus:!1,selectPreviousSegmentOnBackspace:!1,enableMouseWheel:!1,allowCaretMode:!1,autoSwitchParts:!0,autoSwitchKeys:[],twoDigitYearMax:Tp,autoCorrectParts:!0,autoFill:!1},Cf=function(e){function t(t,n){var i=e.call(this,n)||this;return i.dateObject=null,i.currentText="",i.currentFormat="",i.interactionMode=kp.None,i.previousElementSelection={start:0,end:0},i.init(t,n),i}return gp(t,e),Object.defineProperty(t.prototype,"value",{get:function(){return this.dateObject&&this.dateObject.getValue()},enumerable:!0,configurable:!0}),t.prototype.init=function(e,t){var n=Up(this.options.value)?Bh(this.options.value):new Date(t.formattedValue);Up(n)||(n=null),this.element=e,this.options=Vp({},xf,t,{steps:vp({},xf.steps,t.steps)}),this.intl=this.options.intlService,this.dateObject=this.createDateObject(),this.dateObject.setValue(n),this.setTextAndFormat(),this.bindEvents(),this.resetSegmentValue=!0,this.interactionMode=kp.None,this.forceUpdate()},t.prototype.destroy=function(){this.unbindEvents(),this.dateObject=null,e.prototype.destroy.call(this)},t.prototype.bindEvents=function(){this.onElementDragStart=this.onElementDragStart.bind(this),this.element.addEventListener(of,this.onElementDragStart),this.onElementDrop=this.onElementDrop.bind(this),this.element.addEventListener(af,this.onElementDrop),this.onElementClick=this.onElementClick.bind(this),this.element.addEventListener(df,this.onElementClick),this.onElementMouseDown=this.onElementMouseDown.bind(this),this.element.addEventListener(lf,this.onElementMouseDown),this.element.addEventListener(sf,this.onElementMouseDown),this.onElementMouseUp=this.onElementMouseUp.bind(this),this.element.addEventListener(cf,this.onElementMouseUp),this.onElementInput=this.onElementInput.bind(this),this.element.addEventListener(uf,this.onElementInput),this.onElementKeyDown=this.onElementKeyDown.bind(this),this.element.addEventListener(hf,this.onElementKeyDown),this.onElementFocus=this.onElementFocus.bind(this),this.element.addEventListener(pf,this.onElementFocus),this.onElementBlur=this.onElementBlur.bind(this),this.element.addEventListener(ff,this.onElementBlur),this.onElementChange=this.onElementChange.bind(this),this.element.addEventListener(kf,this.onElementChange),this.onElementPaste=this.onElementPaste.bind(this),this.element.addEventListener(mf,this.onElementPaste),this.onElementMouseWheel=this.onElementMouseWheel.bind(this),this.element.addEventListener(gf,this.onElementMouseWheel),this.element.addEventListener(vf,this.onElementMouseWheel)},t.prototype.unbindEvents=function(){this.element.removeEventListener(of,this.onElementDragStart),this.element.removeEventListener(af,this.onElementDrop),this.element.removeEventListener(sf,this.onElementMouseDown),this.element.removeEventListener(lf,this.onElementMouseDown),this.element.removeEventListener(cf,this.onElementMouseUp),this.element.removeEventListener(df,this.onElementClick),this.element.removeEventListener(uf,this.onElementInput),this.element.removeEventListener(hf,this.onElementKeyDown),this.element.removeEventListener(pf,this.onElementFocus),this.element.removeEventListener(ff,this.onElementBlur),this.element.removeEventListener(kf,this.onElementChange),this.element.removeEventListener(mf,this.onElementPaste),this.element.removeEventListener(gf,this.onElementMouseWheel),this.element.removeEventListener(vf,this.onElementMouseWheel)},t.prototype.setOptions=function(e,t){void 0===t&&(t=!1),this.options=Vp({},this.options,e,{steps:vp({},xf.steps,e.steps)}),this.setDateObjectOptions(),t&&(this.unbindEvents(),this.init(this.element,this.options))},t.prototype.setDateObjectOptions=function(){if(this.dateObject){var e=this.getDateObjectOptions();this.dateObject.setOptions(e)}},t.prototype.resetLocale=function(){this.unbindEvents(),this.init(this.element,this.options)},t.prototype.isInCaretMode=function(){return this.interactionMode===kp.Caret},t.prototype.focus=function(){this.element.focus(),this.options.selectNearestSegmentOnFocus&&this.selectNearestSegment(0)},t.prototype.onElementDragStart=function(e){e.preventDefault()},t.prototype.onElementDrop=function(e){e.preventDefault()},t.prototype.onElementMouseDown=function(){this.mouseDownStarted=!0,this.focusedPriorToMouseDown=this.isActive},t.prototype.onElementMouseUp=function(e){this.mouseDownStarted=!1,e.preventDefault()},t.prototype.onElementClick=function(e){this.mouseDownStarted=!1,this.switchedPartOnPreviousKeyAction=!1;var t=this.selection;if(this.isInCaretMode()&&this.forceUpdate(),3===e.detail);else if(this.isActive&&this.options.selectNearestSegmentOnFocus){var n=this.element.selectionStart!==this.element.selectionEnd,i=Fp(this.options.placeholder)&&!this.dateObject.hasValue()&&!this.focusedPriorToMouseDown,r=!n&&i?0:this.caret()[0];this.selectNearestSegment(r)}else this.setSelection(this.selectionByIndex(t.start))},t.prototype.onElementInput=function(e){this.triggerInput({event:e});var t=this.elementValue;if(this.element&&this.dateObject){var n=this.switchedPartOnPreviousKeyAction;if(this.isPasteInProgress)return this.options.allowCaretMode&&(this.resetSegmentValue=!1),this.updateOnPaste(e),void(this.isPasteInProgress=!1);var i=this.keyDownEvent||{},r=i.keyCode===qp||i.key===Ep,o=i.keyCode===Gp||i.key===Mp,a=this.interactionMode;!this.options.allowCaretMode||a===kp.Caret||o||r||(this.resetSegmentValue=!0),this.options.allowCaretMode?this.interactionMode=kp.Caret:this.interactionMode=kp.Selection;var s=this.isInCaretMode();if(s&&this.keyDownEvent.key===Ip)this.restorePreviousInputEventState();else{var l=this.dateObject&&this.dateObject.getValue(),c=this.dateObject?this.dateObject.value:null,d=this.dateObject.getTextAndFormat(),u=d.text,h=d.format;this.currentFormat=h;var p=function(e){var t=e.oldText,n=e.newText,i=e.formatPattern,r=e.selectionStart,o=e.isInCaretMode,a=e.keyEvent,s=r+t.length-n.length,l=t[s],c=t.substring(0,s),d=n.substring(0,r),u=[];if(c===d&&r>0)return u.push([i[r-1],d[r-1]]),u;if(0===c.indexOf(d)&&o&&(a.key===Mp||a.key===Ep)||0===c.indexOf(d)&&!o&&(0===d.length||i[d.length-1]!==i[d.length])){var h="";o||1!==d.length||u.push([i[0],d[0]]);for(var p=d.length;p<c.length;p++)i[p]!==h&&i[p]!==Sp&&(h=i[p],u.push([h,""]));return u}if(o&&(0===d.indexOf(c)||i[r-1]===Sp)||!o&&(0===d.indexOf(c)||i[r-1]===Sp)){var f=i[0];for(p=Math.max(0,c.length-1);p<i.length;p++)if(i[p]!==Sp){f=i[p];break}return[[f,d[r-1]]]}return" "===d[d.length-1]||d[d.length-1]===l&&"_"===i[s]?[[i[r-1],Sp]]:[[i[r-1],d[r-1]]]}({oldText:s&&(r||o||a===kp.Caret)?this.previousElementValue:u,newText:this.elementValue,formatPattern:this.currentFormat,selectionStart:this.selection.start,isInCaretMode:s,keyEvent:this.keyDownEvent});if(p&&p.length&&p[0]&&p[0][1]!==Sp&&(this.switchedPartOnPreviousKeyAction=!1),!s||p&&0!==p.length){if(s&&1===p.length){if(!p[0]||!p[0][0])return void this.restorePreviousInputEventState();if(s&&p[0]&&(p[0][0]===Sp||p[0][1]===Sp))return void this.restorePreviousInputEventState()}var f=1===p.length&&p[0][1]===Sp,m=[],g=!1,v=null;if(!f)for(var _=0;_<p.length;_++){var b=this.dateObject.parsePart({symbol:p[_][0],currentChar:p[_][1],resetSegmentValue:this.resetSegmentValue,cycleSegmentValue:!this.isInCaretMode(),rawTextValue:this.element.value,isDeleting:r||o,originalFormat:this.currentFormat});m.push(b),b.value||(v={type:"parse"}),g=b.switchToNext}this.options.autoSwitchParts||(g=!1),this.resetSegmentValue=!1;var y,w=this.options.format===this.currentFormat||Fp(this.options.format)&&this.options.format.length>1,k=m[m.length-1],x=k&&!Fp(k.value),C=s&&(r||o)&&x,S=!!k&&k.resetPart,T=this.dateObject.getValue(),D=!Kh(l,T),A=this.dateObject.value,M=this.selection;if(s){var E=p&&p.length>0?p[0][0]:null,I=this.dateObject.getLeadingZero()[E];p.length&&p[0][0]!==Sp?g?(this.forceUpdateWithSelection(),this.switchDateSegment(1)):S?(y=this.currentFormat[M.start])?(this.forceUpdate(),this.setSelection(this.selectionBySymbol(y))):this.restorePreviousInputEventState():C?(this.forceUpdate(),p.length&&p[0][0]!==Sp&&this.setSelection(this.selectionBySymbol(p[0][0]))):x?"0"===e.data&&I||(Fp(l)&&!Fp(T)?this.restorePreviousInputEventState():!Fp(l)&&Fp(T)?this.forceUpdateWithSelection():Fp(l)&&Fp(T)?D?this.forceUpdateWithSelection():this.restorePreviousInputEventState():Fp(l)||Fp(T)?c!==A||this.restorePreviousInputEventState():this.forceUpdateWithSelection()):x||w||this.forceUpdateWithSelection():(this.options.autoSwitchParts||p[0][1]!==Sp)&&this.setSelection(this.selectionBySymbol(p[0][0]))}else s||(this.forceUpdate(),p.length&&p[0][0]!==Sp&&this.setSelection(this.selectionBySymbol(p[0][0])),this.options.autoSwitchParts?f?(this.resetSegmentValue=!0,n||this.switchDateSegment(1),this.switchedPartOnPreviousKeyAction=!0):g&&(this.switchDateSegment(1),this.switchedPartOnPreviousKeyAction=!0):k&&k.switchToNext?this.resetSegmentValue=!0:f&&(this.resetSegmentValue=!0,n||this.switchDateSegment(1),this.switchedPartOnPreviousKeyAction=!0),r&&this.options.selectPreviousSegmentOnBackspace&&this.switchDateSegment(-1));this.tryTriggerValueChange({oldValue:l,event:e}),this.triggerInputEnd({event:e,error:v,oldElementValue:t,newElementValue:this.elementValue}),s&&this.setTextAndFormat()}else this.restorePreviousInputEventState()}}},t.prototype.onElementFocus=function(e){this.triggerFocus({event:e})||(this.isActive=!0,this.interactionMode=kp.None,this.switchedPartOnPreviousKeyAction=!1,this.refreshElementValue(),this.mouseDownStarted||this.caret(0,this.elementValue.length),this.mouseDownStarted=!1,this.triggerFocusEnd({event:e}))},t.prototype.onElementBlur=function(e){this.resetSegmentValue=!0,this.isActive=!1,this.triggerBlur({event:e})||(this.options.autoFill&&this.autoFill(),this.interactionMode=kp.None,this.switchedPartOnPreviousKeyAction=!1,this.refreshElementValue(),this.triggerBlurEnd({event:e}))},t.prototype.onElementChange=function(e){this.triggerChange({event:e})},t.prototype.onElementKeyDown=function(e){if(!this.triggerKeyDown({event:e})){var t=this.selection,n=t.start,i=t.end,r=e;if(this.keyDownEvent=e,this.previousElementValue=this.element.value,this.previousElementSelection={start:n,end:i},this.keyEventMatchesAutoSwitchKeys(e)){var o=e.keyCode===Kp;if(!o)return e.preventDefault(),void this.switchDateSegment(1);var a=this.selection,s=a.start,l=a.end;if(e.shiftKey&&o?this.switchDateSegment(-1):this.switchDateSegment(1),s!==this.selection.start||l!==this.selection.end)return void e.preventDefault()}var c=this.currentFormat[this.selection.start],d=this.getStepFromSymbol(c),u=!1,h=this.elementValue;if(!(e.altKey||e.ctrlKey||e.metaKey||e.keyCode===Kp)){switch(e.keyCode){case Qp:this.switchDateSegment(-1),u=!0,this.switchedPartOnPreviousKeyAction=!1;break;case Xp:this.modifyDateSegmentValue(d,c,r),h!==this.elementValue&&this.triggerInputEnd({event:e,error:null,newElementValue:this.elementValue,oldElementValue:h}),u=!0,this.switchedPartOnPreviousKeyAction=!1;break;case Zp:this.switchDateSegment(1),u=!0,this.switchedPartOnPreviousKeyAction=!1;break;case Jp:this.modifyDateSegmentValue(-d,c,r),h!==this.elementValue&&this.triggerInputEnd({event:e,error:null,newElementValue:this.elementValue,oldElementValue:h}),u=!0,this.switchedPartOnPreviousKeyAction=!1;break;case Yp:break;case tf:this.selectNearestSegment(0),u=!0,this.switchedPartOnPreviousKeyAction=!1,this.resetSegmentValue=!0;break;case ef:this.selectNearestSegment(this.elementValue.length),u=!0,this.switchedPartOnPreviousKeyAction=!1,this.resetSegmentValue=!0;break;default:return}u&&e.preventDefault()}}},t.prototype.onElementPaste=function(){this.isPasteInProgress=!0},t.prototype.onElementMouseWheel=function(e){var t=this.elementValue;if(this.options.enableMouseWheel&&!this.triggerMouseWheel({event:e})&&this.isActive){var n=e;n.shiftKey?this.switchDateSegment((n.wheelDelta||-n.detail)>0?-1:1):this.modifyDateSegmentValue((n.wheelDelta||-n.detail)>0?1:-1),n.returnValue=!1,n.preventDefault&&n.preventDefault(),n.stopPropagation&&n.stopPropagation(),t!==this.elementValue&&this.triggerInputEnd({event:e,error:null,newElementValue:this.elementValue,oldElementValue:t})}},t.prototype.updateOnPaste=function(e){var t=this.intl.parseDate(this.elementValue,this.inputFormat)||this.value;Fp(t)&&this.dateObject.shouldNormalizeCentury()&&(t=this.dateObject.normalizeCentury(t));var n=this.dateObject&&this.dateObject.getValue();this.writeValue(t),this.tryTriggerValueChange({oldValue:n,event:e})},Object.defineProperty(t.prototype,"elementValue",{get:function(){return(this.element||{}).value||""},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"inputFormat",{get:function(){return this.options.format?"string"==typeof this.options.format?this.options.format:this.options.format.inputFormat:Dp},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"displayFormat",{get:function(){return this.options.format?"string"==typeof this.options.format?this.options.format:this.options.format.displayFormat:Dp},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"selection",{get:function(){var e={start:0,end:0};return null!==this.element&&void 0!==this.element.selectionStart&&(e={start:this.element.selectionStart,end:this.element.selectionEnd}),e},enumerable:!0,configurable:!0}),t.prototype.setSelection=function(e){this.element&&document.activeElement===this.element&&(this.element.setSelectionRange(e.start,e.end),e.start!==e.end&&(this.interactionMode=kp.Selection))},t.prototype.selectionBySymbol=function(e){for(var t=-1,n=0,i=0;i<this.currentFormat.length;i++)this.currentFormat[i]===e&&(n=i+1,-1===t&&(t=i));return t<0&&(t=0),this.options.autoCorrectParts||this.currentFormat.length===this.currentText.length||(this.currentFormat.length<this.currentText.length?n+=this.currentText.length-this.currentFormat.length:n=Math.max(0,n-(this.currentFormat.length-this.currentText.length))),{start:t,end:n}},t.prototype.selectionByIndex=function(e){for(var t={start:e,end:e},n=e,i=e-1;n<this.currentFormat.length||i>=0;n++,i--){if(n<this.currentFormat.length&&this.currentFormat[n]!==Sp){t=this.selectionBySymbol(this.currentFormat[n]);break}if(i>=0&&this.currentFormat[i]!==Sp){t=this.selectionBySymbol(this.currentFormat[i]);break}}return t},t.prototype.switchDateSegment=function(e){var t=this.selection;if(this.isInCaretMode()){var n=t.start,i=this.currentFormat[n-1],r="",o="";if(e<0){for(var a=n+e;a>=0;a--)if((o=this.currentFormat[a])!==Sp&&o!==i){n=a,r=o;break}}else for(a=n+e;a<this.currentFormat.length;a++)if((o=this.currentFormat[a])!==Sp&&o!==i){n=a,r=o;break}if(r)return this.forceUpdate(),this.setSelection(this.selectionBySymbol(r)),void(this.interactionMode=kp.Selection)}this.interactionMode=kp.None;var s=this.selection,l=s.start,c=s.end;if(l<c&&this.currentFormat[l]!==this.currentFormat[c-1])return this.setSelection(this.selectionByIndex(e>0?l:c-1)),this.resetSegmentValue=!0,void(this.interactionMode=kp.None);for(var d=this.currentFormat[l],u=l+e;u>0&&u<this.currentFormat.length&&(this.currentFormat[u]===d||this.currentFormat[u]===Sp);)u+=e;if(this.currentFormat[u]!==Sp){for(var h=u;h>=0&&h<this.currentFormat.length&&this.currentFormat[h]===this.currentFormat[u];)h+=e;u>h&&(h+1!==l||u+1!==c)?(this.setSelection({start:h+1,end:u+1}),this.resetSegmentValue=!0):u<h&&(u!==l||h!==c)&&(this.setSelection({start:u,end:h}),this.resetSegmentValue=!0),this.interactionMode=kp.None}},t.prototype.modifyDateSegmentValue=function(e,t,n){if(void 0===t&&(t=""),void 0===n&&(n={}),this.dateObject&&!this.options.readonly){var i,r=this.value,o=1,a=this.caret();if("S"===(t=t||this.currentFormat[a[0]])&&(!this.options.steps.millisecond||1===this.options.steps.millisecond)){var s=function(e){var t=e&&e.match(/S+(\1)/);return t?t[0].length:0}(this.inputFormat);i=s,o=Math.pow(10,3-i)}this.dateObject.modifyPart(t,o*e),this.tryTriggerValueChange({oldValue:r,event:n}),this.forceUpdate(),this.setSelection(this.selectionBySymbol(t))}},t.prototype.tryTriggerValueChange=function(e){if(void 0===e&&(e={oldValue:null,event:{}}),!Kh(this.value,e.oldValue))return this.triggerValueChange(e)},t.prototype.triggerValueChange=function(e){return void 0===e&&(e={oldValue:null,event:{}}),this.trigger(_f,Vp(e,{value:this.value}))},t.prototype.triggerInput=function(e){return void 0===e&&(e={event:{}}),this.trigger(uf,Vp(e,{value:this.value}))},t.prototype.triggerInputEnd=function(e){return void 0===e&&(e={event:{},error:null,oldElementValue:"",newElementValue:""}),this.trigger(bf,Vp(e,{value:this.value}))},t.prototype.triggerFocus=function(e){return void 0===e&&(e={event:{}}),this.trigger(pf,Vp({},e))},t.prototype.triggerFocusEnd=function(e){return void 0===e&&(e={event:{}}),this.trigger(wf,Vp({},e))},t.prototype.triggerBlur=function(e){return void 0===e&&(e={event:{}}),this.trigger(ff,Vp({},e))},t.prototype.triggerBlurEnd=function(e){return void 0===e&&(e={event:{}}),this.trigger(yf,Vp({},e))},t.prototype.triggerChange=function(e){return void 0===e&&(e={event:{}}),this.trigger(kf,Vp(e,{value:this.value}))},t.prototype.triggerKeyDown=function(e){return void 0===e&&(e={event:{}}),this.trigger(hf,Vp({},e))},t.prototype.triggerMouseWheel=function(e){return void 0===e&&(e={event:{}}),this.trigger(vf,Vp({},e))},t.prototype.forceUpdate=function(){this.setTextAndFormat(),this.refreshElementValue()},t.prototype.forceUpdateWithSelection=function(){var e=this.selection,t=e.start,n=e.end,i=this.elementValue.length;this.forceUpdate();var r=this.elementValue.length-i;this.setSelection({start:t+r,end:n+r})},t.prototype.setTextAndFormat=function(){var e=this.dateObject.getTextAndFormat(),t=e.text,n=e.format;this.currentFormat=n,this.currentText=t},t.prototype.setElementValue=function(e){this.element.value=e},t.prototype.getStepFromSymbol=function(e){switch(e){case"S":return Number(this.options.steps.millisecond);case"s":return Number(this.options.steps.second);case"m":return Number(this.options.steps.minute);case"h":case"H":return Number(this.options.steps.hour);case"M":return Number(this.options.steps.month);case"d":case"E":return Number(this.options.steps.day);case"y":return Number(this.options.steps.year);default:return 1}},t.prototype.restorePreviousInputEventState=function(){this.restorePreviousElementValue(),this.restorePreviousElementSelection()},t.prototype.restorePreviousElementValue=function(){this.setElementValue(this.previousElementValue||"")},t.prototype.restorePreviousElementSelection=function(){var e=this.previousElementSelection,t=e.start,n=e.end;this.setSelection({start:t||0,end:n||0})},t.prototype.writeValue=function(e){this.verifyValue(e),this.dateObject=this.getDateObject(e),this.refreshElementValue()},t.prototype.verifyValue=function(e){if(e&&!Up(e))throw new Error("The 'value' should be a valid JavaScript Date instance.")},t.prototype.refreshElementValue=function(){var e=this.element,t=this.isActive?this.inputFormat:this.displayFormat,n=this.dateObject.getTextAndFormat(t),i=n.text,r=n.format;this.currentFormat=r,this.currentText=i;var o=this.options.hasPlaceholder||Fp(this.options.placeholder),a=!this.isActive&&o&&!this.dateObject.hasValue();o&&Fp(this.options.placeholder)&&(e.placeholder=this.options.placeholder);var s=a?"":i;this.previousElementValue=this.elementValue,this.setElementValue(s)},t.prototype.caret=function(e,t){void 0===t&&(t=e);var n=void 0!==e,i=[e,e],r=this.element;if(!n||!this.options.disabled&&!this.options.readonly){try{void 0!==r.selectionStart&&(n&&(document&&document.activeElement!==r&&r.focus(),r.setSelectionRange(e,t)),i=[r.selectionStart,r.selectionEnd])}catch(e){i=[]}return i}},t.prototype.selectNearestSegment=function(e){for(var t=e,n=e-1;t<this.currentFormat.length||n>=0;t++,n--){if(t<this.currentFormat.length&&"_"!==this.currentFormat[t])return void this.selectDateSegment(this.currentFormat[t]);if(n>=0&&"_"!==this.currentFormat[n])return void this.selectDateSegment(this.currentFormat[n])}},t.prototype.selectDateSegment=function(e){for(var t=-1,n=0,i=0;i<this.currentFormat.length;i++)this.currentFormat[i]===e&&(n=i+1,-1===t&&(t=i));t<0&&(t=0),this.caret(0,0),this.caret(t,n)},t.prototype.getDateObject=function(e){var t=(this.dateObject||{}||null).leadingZero;this.options.value=e;var n=this.createDateObject();return n.setLeadingZero(this.isActive?t:null),n},t.prototype.createDateObject=function(){var e=this.getDateObjectOptions();return new jp(Vp({},e))},t.prototype.getDateObjectOptions=function(){return{intlService:this.options.intlService,formatPlaceholder:this.options.formatPlaceholder?this.options.formatPlaceholder:"formatPattern",format:this.inputFormat,cycleTime:this.options.cycleTime,twoDigitYearMax:this.options.twoDigitYearMax,autoCorrectParts:this.options.autoCorrectParts,value:this.options.value}},t.prototype.keyEventMatchesAutoSwitchKeys=function(e){var t=(this.options.autoSwitchKeys||[]).map((function(e){return e.toString().toLowerCase().trim()}));return t.indexOf(e.keyCode.toString())>=0||t.indexOf(e.keyCode)>=0||t.indexOf(e.key.toLowerCase().trim())>=0},t.prototype.autoFill=function(){var e,t,n,i,r,o,a=this.dateObject,s=new Date;(a.date||a.month||a.year||a.hours||a.minutes||a.seconds)&&(n=a.year?a.value.getFullYear():s.getFullYear(),t=a.month?a.value.getMonth():s.getMonth(),e=a.date?a.value.getDate():s.getDate(),i=a.hours?a.value.getHours():s.getHours(),r=a.minutes?a.value.getMinutes():s.getMinutes(),o=a.seconds?a.value.getSeconds():s.getSeconds(),a.setValue(new Date(n,t,e,i,r,o)),this.refreshElementValue(),this.triggerValueChange())},t}(rf);!function(e,t){var n=window.kendo,i=n.ui,r=i.Widget,o=".kendoDateInput",a={}.toString,s=e.isPlainObject,l="k-focus",c="k-disabled",d="k-invalid",u="disabled",h="readonly",p="change",f=n.Class.extend({init:function(e){const t=e.culture?n.getCulture(e.culture):n.culture();this.messages=e.messages,this.cldr={},this.cldr[t.name]={name:t.name,calendar:t.calendar||{},numbers:t.numberFormat}},parseDate:function(e,t,i){return n.parseDate(e,t,i,!0)},formatDate:function(e,t,i){return n.toString(e,t,i)},splitDateFormat:function(e){return n.date.splitDateFormat(e)},dateFormatNames:function(e,t){return n.date.dateFormatNames(t)},dateFieldName:function(e){return this.messages[e.type]||{}}});function m(){const e=n.culture();let t=[];return t.push(e.calendars.standard["/"]),t.push(e.calendars.standard[":"]),t}function g(e,t){if(!e)return t;return n.getCulture(e).calendars.standard.patterns[t]||t}var v=r.extend({init:function(t,i){var a=this;r.fn.init.call(a,t,i),t=a.element,(i=a.options).format=n._extractFormat(i.format||n.getCulture(i.culture).calendars.standard.patterns.d),i.min=n.parseDate(t.attr("min"))||n.parseDate(i.min),i.max=n.parseDate(t.attr("max"))||n.parseDate(i.max);var s=t.parent().attr("class")||"",c=s.indexOf("picker")>=0&&s.indexOf("rangepicker")<0,d=a.options.value||t.val();c?a.wrapper=a.element.parent():(a.wrapper=t.wrap("<span class='k-dateinput k-input'></span>").parent(),a.wrapper.addClass(t[0].className).removeClass("input-validation-error")),a.wrapper[0].style.cssText=t[0].style.cssText,t.css({height:t[0].style.height}),a._validationIcon=e(n.ui.icon({icon:"exclamation-circle",iconClass:"k-input-validation-icon k-hidden"})).insertAfter(t),a._form(),a.dateInputInstance=new Cf(t[0],{format:g(i.culture,i.format),autoCorrectParts:i.autoCorrectParts,autoSwitchKeys:i.autoSwitchKeys.length?i.autoSwitchKeys:m(),enableMouseWheel:i.enableMouseWheel,twoDigitYearMax:i.twoDigitYearMax,steps:i.steps,formatPlaceholder:i.messages,events:{inputEnd:function(e){e.error&&a._blinkInvalidState()},keydown:function(e){e.event.keyCode?e.event.keyCode!=n.keys.UP&&e.event.keyCode!=n.keys.DOWN||setTimeout((function(){a.element.trigger(p)})):e.preventDefault()},blur:function(e){a._change(),e.preventDefault()}},intlService:new f({culture:i.culture,messages:a.options.messages}),autoSwitchParts:i.autoSwitchParts,autoFill:i.autoFill}),a._emptyMask=this.element.val(),i.value&&a.value(i.value),a.element.addClass("k-input-inner").attr("autocomplete","off").on("focus"+o,(function(){a.wrapper.addClass(l)})).on("focusout"+o,(function(){a.wrapper.removeClass(l)}));try{t[0].setAttribute("type","text")}catch(e){t[0].type="text"}t.is("[disabled]")||e(a.element).parents("fieldset").is(":disabled")?a.enable(!1):a.readonly(t.is("[readonly]")),a.value(d),c||a._applyCssClasses(),i.label&&a._label(),a.element.removeAttr("style"),n.notify(a)},options:{name:"DateInput",autoAdjust:!0,autoCorrectParts:!0,autoSwitchKeys:[],autoSwitchParts:!1,enableMouseWheel:!0,culture:"",value:"",format:"",min:new Date(1900,0,1),max:new Date(2099,11,31),messages:{year:"year",month:"month",day:"day",weekday:"day of the week",hour:"hours",minute:"minutes",second:"seconds",milliseconds:"milliseconds",dayperiod:"AM/PM"},size:"medium",steps:{year:1,month:1,day:1,hour:1,minute:1,second:1,millisecond:1},fillMode:"solid",rounded:"medium",label:null,autoFill:!1},events:[p],min:function(e){if(e===t)return this.options.min;this.options.min=e},max:function(e){if(e===t)return this.options.max;this.options.max=e},setOptions:function(e){var t=this;r.fn.setOptions.call(t,e),t.dateInputInstance.destroy(),t.dateInputInstance=null,t.dateInputInstance=new Cf(this.element[0],{format:g(t.options.culture,t.options.format),autoSwitchKeys:t.options.autoSwitchKeys.length?t.options.autoSwitchKeys:m(),autoCorrectParts:t.options.autoCorrectParts,enableMouseWheel:t.options.enableMouseWheel,steps:t.options.steps,twoDigitYearMax:t.options.twoDigitYearMax,formatPlaceholder:t.options.messages,events:{inputEnd:function(e){e.error&&t._blinkInvalidState()},keydown:function(e){e.event.keyCode!=n.keys.UP&&e.event.keyCode!=n.keys.DOWN||setTimeout((function(){t.element.trigger(p)}))},blur:function(e){t._change(),e.preventDefault()}},intlService:new f({culture:t.options.culture,messages:t.options.messages}),autoSwitchParts:t.options.autoSwitchParts,autoFill:t.options.autoFill})},destroy:function(){var e=this;e.element.off(o),e.dateInputInstance.destroy(),e._formElement&&e._formElement.off("reset",e._resetHandler),e.label&&e.label.destroy(),e._validationIcon&&e._validationIcon.remove(),r.fn.destroy.call(e)},value:function(e){if(e===t)return this.dateInputInstance.value;null===e&&(e=""),"[object Date]"!==a.call(e)&&(e=n.parseDate(e,this.options.format,this.options.culture)),e&&!e.getTime()&&(e=null),this.dateInputInstance.writeValue(e),this._oldValue=e,this.label&&this.label.floatingLabel&&this.label.floatingLabel.refresh()},_hasDateInput:function(){return this._emptyMask!==this.element.val()},readonly:function(e){this._editable({readonly:e===t||e,disable:!1}),this.label&&this.label.floatingLabel&&this.label.floatingLabel.readonly(e===t||e)},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)}),this.label&&this.label.floatingLabel&&this.label.floatingLabel.enable(e=e===t||e)},_label:function(){var t=this,i=t.options,r=s(i.label)?i.label:{content:i.label};t.label=new n.ui.Label(null,e.extend({},r,{widget:t,floatCheck:()=>!(t.value()||t._hasDateInput()&&""!==t.element.val()||document.activeElement===t.element[0])&&(this.element.val(""),!0)})),t._inputLabel=t.label.element},_bindInput:function(){var e=this;e.element.on("focus"+o,(function(){e.wrapper.addClass(l)})).on("focusout"+o,(function(){e.wrapper.removeClass(l)})),this.dateInputInstance&&this.dateInputInstance.bindEvents()},_unbindInput:function(){this.element.off("focus"+o).off("focusout"+o),this.dateInputInstance&&this.dateInputInstance.unbindEvents()},_editable:function(e){var t=this,n=t.element,i=e.disable,r=e.readonly,o=t.wrapper;t._unbindInput(),r||i?(i&&(o.addClass(c),n.attr(u,i),n&&n.length&&n[0].removeAttribute(h)),r&&n.attr(h,r)):(o.removeClass(c),n&&n.length&&(n[0].removeAttribute(u),n[0].removeAttribute(h)),t._bindInput())},_change:function(){let e=this,t=e._oldValue,n=e.value(),i=e.options.autoAdjust;i&&n&&e.min()&&n<e.min()&&(e.value(e.min()),n=e.value()),i&&n&&e.max()&&n>e.max()&&(e.value(e.max()),n=e.value()),(t&&n&&n.getTime()!==t.getTime()||t&&!n||!t&&n)&&(e._oldValue=n,e.trigger(p,{blur:!0}),e.element.trigger(p))},_blinkInvalidState:function(){var e=this;e._addInvalidState(),clearTimeout(e._invalidStateTimeout),e._invalidStateTimeout=setTimeout(e._removeInvalidState.bind(e),100)},_addInvalidState:function(){this.wrapper.addClass(d),this._validationIcon.removeClass("k-hidden")},_removeInvalidState:function(){var e=this;e.wrapper.removeClass(d),e._validationIcon.addClass("k-hidden"),e._invalidStateTimeout=null},_form:function(){var t=this,n=t.element,i=n.attr("form"),r=i?e("#"+i):n.closest("form"),o=n[0].value;!o&&t.options.value&&(o=t.options.value),r[0]&&(t._resetHandler=function(){setTimeout((function(){t.value(o)}))},t._formElement=r.on("reset",t._resetHandler))},_paste:function(e){e.preventDefault()}});n.cssProperties.registerPrefix("DateInput","k-input-"),n.cssProperties.registerValues("DateInput",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),i.plugin(v)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=n.html,o=n.mediaQuery,a=i.Widget,s=n.parseDate,l=n.keys,c=n.support,d=n.template,u=n._activeElement,h="<div />",p=".kendoDatePicker",f="click"+p,m=c.mouseAndTouchPresent?n.applyEventMap("up",p.slice(1)):f,g="open",v="close",_="change",b="disabled",y="readonly",w="k-focus",k="k-selected",x="k-disabled",C="mouseenter"+p+" mouseleave"+p,S="mousedown"+p,T="navigate",D="id",A="month",M="aria-disabled",E="aria-readonly",I="aria-expanded",z="aria-hidden",P="aria-activedescendant",H=n.calendar,F=H.isInRange,R=H.restrictValue,L=H.isEqualDatePart,B=e.extend,O=Date;function V(t){var n=t.parseFormats,i=t.format;H.normalize(t),(n=Array.isArray(n)?n:[n]).length||n.push("yyyy-MM-dd"),-1===e.inArray(i,n)&&n.splice(0,0,t.format),t.parseFormats=n}function N(e){e.preventDefault()}var $=function(t){var r,a=this,s=document.body,l=e(h).attr(z,"true").addClass("k-calendar-container");a.options=t=t||{},r=t.id,a.bigScreenMQL=o("large"),a.smallScreenMQL=o("small"),"auto"==t.adaptiveMode&&a.smallScreenMQL.onChange((function(){a.popup&&n.isFunction(a.popup.fullscreen)&&a.popup.fullscreen(a.smallScreenMQL.mediaQueryList.matches)})),t.omitPopup?l=t.dateDiv:(l.appendTo(s),"auto"!=t.adaptiveMode||a.bigScreenMQL.mediaQueryList.matches?a.popup=new i.Popup(l,B(t.popup,t,{name:"Popup",isRtl:n.support.isRtl(t.anchor)})):a.popup=new i.ActionSheet(l,{adaptive:!0,title:"Set dates",subtitle:"DD / MM / YY",closeButton:!0,focusOnActivate:!1,fullscreen:a.smallScreenMQL.mediaQueryList.matches,popup:B(t.popup,t,{name:"Popup",isRtl:n.support.isRtl(t.anchor)})})),r&&(r+="_dateview",l.attr(D,r),a._dateViewID=r),a.div=l,a.value(t.value)};$.prototype={_calendar:function(){var t,r=this,o=r.calendar,a=r.options;if(!o){var s="auto"!=a.adaptiveMode||this.bigScreenMQL.mediaQueryList.matches?this.options.size:"large";t=e(h).attr(D,n.guid()).appendTo(a.omitPopup?a.dateDiv:r.popup._content||r.popup.element).on(S,N).on(f,"td:has(.k-link)",r._click.bind(r)),r.calendar=o=new i.Calendar(t,{componentType:a.componentType,size:s,messages:a.messages}),r._setOptions(a),t.addClass(n.getValidCssClass("k-calendar-","size",s)),o.navigate(r._value||r._current,a.start),r.value(r._value)}},_setOptions:function(e){this.calendar.setOptions({focusOnNav:!1,componentType:e.componentType,change:e.change,culture:e.culture,dates:e.dates,depth:e.depth,footer:e.footer,format:e.format,max:e.max,min:e.min,month:e.month,weekNumber:e.weekNumber,start:e.start,messages:e.messages,disableDates:e.disableDates})},setOptions:function(e){var t=this,n=t.options,i=e.disableDates;i&&(e.disableDates=H.disabled(i)),t.options=B(n,e,{change:n.change,close:n.close,open:n.open}),t.calendar&&t._setOptions(t.options)},destroy:function(){var e=this;this.popup&&this.popup.destroy(),e.bigScreenMQL&&(e.bigScreenMQL.destroy(),e.bigScreenMQL=null),e.smallScreenMQL&&(e.smallScreenMQL.destroy(),e.smallScreenMQL=null)},open:function(){var e,t=this;t._calendar(),e=t.popup._hovered,t.popup._hovered=!0,t.popup.open(),setTimeout((function(){t.popup._hovered=e}),1)},close:function(){this.popup&&this.popup.close()},min:function(e){this._option("min",e)},max:function(e){this._option("max",e)},toggle:function(){this[this.popup.visible()?v:g]()},move:function(e){var t=this,n=e.keyCode,i=t.calendar,r=e.ctrlKey&&n==l.DOWN||n==l.ENTER,o=!1;if(e.altKey)n==l.DOWN?(t.open(),e.preventDefault(),o=!0):n==l.UP&&(t.close(),e.preventDefault(),o=!0);else if(t.popup&&t.popup.visible()){if(n==l.ESC||r&&i._cell.hasClass(k))return t.close(),e.preventDefault(),!0;n!=l.SPACEBAR&&(t._current=i._move(e)),o=!0}return o},current:function(e){this._current=e,this.calendar&&this.calendar._focus(e)},value:function(e){var t=this,n=t.calendar,i=t.options,r=i.disableDates;r&&r(e)&&(e=null),t._value=e,t._current=new O(+R(e,i.min,i.max)),n&&n.value(e)},_click:function(e){-1!==e.currentTarget.className.indexOf(k)&&(this.calendar.trigger("change"),this.close())},_option:function(e,t){var n=this.calendar;this.options[e]=t,n&&n[e](t)}},$.normalize=V,n.DateView=$;var U=a.extend({init:function(i,r){var l,c=this;a.fn.init.call(c,i,r),i=c.element,(r=c.options).disableDates=n.calendar.disabled(r.disableDates),r.min=s(i.attr("min"))||s(r.min),r.max=s(i.attr("max"))||s(r.max),c.options.readonly=r.readonly!==t?r.readonly:Boolean(c.element.attr("readonly")),c.options.enable=r.enable!==t?r.enable:!Boolean(i.is("[disabled]")||e(i).parents("fieldset").is(":disabled")),V(r),c._initialOptions=B({},r),c._wrapper(),c._createDateView(),c._createDateViewProxy=c._createDateView.bind(c),c.bigScreenMQL=o("large"),"auto"==c.options.adaptiveMode&&c.bigScreenMQL.onChange((()=>{c._createDateViewProxy(),c.dateView.value(c._value)})),c._icon();try{i[0].setAttribute("type","text")}catch(e){i[0].type="text"}i.addClass("k-input-inner").attr({role:"combobox","aria-expanded":!1,"aria-haspopup":"grid","aria-controls":c.dateView._dateViewID,autocomplete:"off"}),c._reset(),c._template(),!c.options.enable?c.enable(!1):c.readonly(i.is("[readonly]")),l=s(r.value||c.element.val(),r.parseFormats,r.culture),c._createDateInput(r),c._old=c._update(l||c.element.val()),c._oldText=i.val(),c._applyCssClasses(),r.label&&c._label(),c.element.removeAttr("style"),n.notify(c)},events:[g,v,_],options:{name:"DatePicker",autoAdjust:!0,value:null,footer:"",format:"",culture:"",parseFormats:[],min:new Date(1900,0,1),max:new Date(2099,11,31),start:A,depth:A,animation:{},month:{},dates:[],disableDates:null,ARIATemplate:({valueType:e,text:t})=>`Current focused ${e} is ${t}`,dateInput:!1,weekNumber:!1,messages:{weekColumnHeader:""},componentType:"classic",adaptiveMode:"none",size:"medium",fillMode:"solid",rounded:"medium",label:null,autoFill:!1,autoCorrectParts:!0},_createDateView:function(){var e,t=this,n=t.options,i=t.element;t.dateView&&(t.dateView.destroy(),t.dateView=null),t.dateView=new $(B({},n,{id:i.attr(D),anchor:t.wrapper,change:function(){t._change(this.value()),t.close()},close:function(n){t.trigger(v)?n.preventDefault():(i.attr(I,!1),e.attr(z,!0),setTimeout((function(){i.removeAttr("aria-activedescendant")})))},open:function(n){var r,o=t.options;t.trigger(g)?n.preventDefault():(t.element.val()!==t._oldText&&(r=s(i.val(),o.parseFormats,o.culture),t.dateView[r?"current":"value"](r)),i.attr(I,!0),e.attr(z,!1),t._updateARIA(r))}})),e=t.dateView.div},setOptions:function(e){var i=this,r=i._value;a.fn.setOptions.call(i,e),(e=i.options).min=s(e.min),e.max=s(e.max),V(e),i._dateIcon.off(p),i._dateIcon.remove(),i.dateView.setOptions(e),i._icon(),i._editable({readonly:e.readonly===t?i.options.readonly:e.readonly,disable:!(e.enable===t?i.options.enable:e.enable)}),i._createDateInput(e),i._dateInput||i.element.val(n.toString(r,e.format,e.culture)),r&&i._updateARIA(r),e.label&&i._inputLabel?i.label.setOptions(e.label):!1===e.label?(i.label._unwrapFloating(),i._inputLabel.remove(),delete i._inputLabel):e.label&&i._label()},_editable:function(e){var t=this,n=t._dateIcon.off(p),i=t.element.off(p),r=t.wrapper.off(p),o=e.readonly,a=e.disable;o||a?(r.addClass(a?x:"").removeClass(a?"":x),i.attr(b,a).attr(y,o).attr(M,a).attr(E,o)):(r.removeClass(x).on(C,t._toggleHover),i&&i.length&&(i[0].removeAttribute(b),i[0].removeAttribute(y)),i.attr(M,!1).attr(E,!1).on("keydown"+p,t._keydown.bind(t)).on("focusout"+p,t._blur.bind(t)).on("focus"+p,(function(){t.wrapper.addClass(w)})),n.on(m,t._click.bind(t)).on(S,N))},readonly:function(e){this._editable({readonly:e===t||e,disable:!1}),this._dateInput&&this._dateInput._editable({readonly:e===t||e,disable:!1}),this.label&&this.label.floatingLabel&&this.label.floatingLabel.readonly(e===t||e)},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)}),this._dateInput&&this._dateInput._editable({readonly:!1,disable:!(e=e===t||e)}),this.label&&this.label.floatingLabel&&this.label.floatingLabel.enable(e=e===t||e)},_label:function(){var t=this,i=t.options,r=e.isPlainObject(i.label)?i.label:{content:i.label};t._dateInput&&(r.floatCheck=()=>!(t.value()||t._dateInput._hasDateInput()&&""!==t.element.val()||document.activeElement===t.element[0])&&(t.element.val(""),!0)),t.label=new n.ui.Label(null,e.extend({},r,{widget:t})),t._inputLabel=t.label.element},destroy:function(){var e=this;e.label&&e.label.destroy(),a.fn.destroy.call(e),e.dateView.calendar&&e._navigateCalendarHandler&&(e.dateView.calendar.unbind(T,e._navigateCalendarHandler),e._navigateCalendarHandler=null),e.dateView.destroy(),e.element.off(p),e._dateIcon.off(p),e._form&&e._form.off("reset",e._resetHandler),e.bigScreenMQL&&e.bigScreenMQL.destroy(),e._createDateViewProxy=null},open:function(){this.dateView.open(),this._navigateCalendar()},close:function(){this.dateView.close()},min:function(e){return this._option("min",e)},max:function(e){return this._option("max",e)},value:function(e){var n=this;if(e===t)return n._value;n._old=n._update(e),null===n._old&&(n._dateInput?n._dateInput.value(n._old):n.element.val("")),n._oldText=n.element.val(),n.label&&n.label.floatingLabel&&n.label.floatingLabel.refresh()},_toggleHover:function(t){e(t.currentTarget).toggleClass("k-hover","mouseenter"===t.type)},_isReset:function(e){var t=this;return t.options.dateInput&&t.options.autoFill&&t._dateInput._emptyMask==e},_blur:function(){var e=this,t=e.element.val();e.close(),t!==e._oldText&&(e.options.autoFill&&!e._isReset(t)&&(e._dateInput.dateInputInstance.autoFill(),t=e.element.val()),e._change(t),t||e.dateView.current(n.calendar.getToday())),e.wrapper.removeClass(w)},_click:function(e){var t=this;t.dateView.toggle(),t._navigateCalendar(),t._focusElement(e.type)},_focusElement:function(e){var t=this.element;c.touch&&(!c.mouseAndTouchPresent||(e||"").match(/touch/i))||t[0]===u()||t.trigger("focus")},_change:function(e){var t,i=this,r=i.element.val();e=i._update(e);var o=(t=!n.calendar.isEqualDate(i._old,e))&&!i._typing,a=r!==i.element.val();(o||a)&&i.element.trigger(_),t&&(i._old=e,i._oldText=i.element.val(),i.trigger(_)),i._typing=!1},_keydown:function(e){var t=this,n=t.dateView,i=t.element.val(),r=!1;n.popup.visible()||e.keyCode!=l.ENTER||i===t._oldText?(r=n.move(e),t._updateARIA(n._current),r?t._dateInput&&e.stopImmediatePropagation&&e.stopImmediatePropagation():t._typing=!0):t._change(i)},_icon:function(){var t,n=this,i=n.element,o=n.options;(t=i.next("button.k-input-button"))[0]||(t=e(r.renderButton('<button aria-label="select" tabindex="-1" class="k-input-button k-button k-icon-button"></button>',{icon:"calendar",size:o.size,fillMode:o.fillMode,shape:"none",rounded:"none"})).insertAfter(i)),n._dateIcon=t.attr({role:"button"})},_setCalendarAttribute:function(){var e=this;setTimeout((function(){e.element.attr(P,e.dateView.calendar._table.attr(P))}))},_navigateCalendar:function(){var e=this;e._navigateCalendarHandler||(e._navigateCalendarHandler=e._setCalendarAttribute.bind(e)),e.dateView.calendar&&e.dateView.calendar.unbind(T,e._navigateCalendarHandler).bind(T,e._navigateCalendarHandler)},_option:function(e,n){var i=this,r=i.options;if(n===t)return r[e];(n=s(n,r.parseFormats,r.culture))&&(r[e]=new O(+n),i.dateView[e](n),i._dateInput&&i._dateInput[e](n))},_update:function(e){var t,i=this,r=i.options,o=r.min,a=r.max,l=i._value,c=s(e,r.parseFormats,r.culture),d=null===c&&null===l||c instanceof Date&&l instanceof Date;return r.disableDates(c)&&(c=null,i._old||i.element.val()||(e=null)),+c==+l&&d?((t=n.toString(c,r.format,r.culture))===e||i._dateInput&&!c||i.element.val(null===c?e:t),c):(null!==c&&L(c,o)?c=R(c,o,a):F(c,o,a)||(c=null),i._value=c,i.dateView.value(c),i._dateInput&&c?i._dateInput.value(c||e):i.element.val(n.toString(c||e,r.format,r.culture)),i._updateARIA(c),c)},_wrapper:function(){var e,t=this.element;(e=t.parents(".k-datepicker"))[0]||(e=t.wrap("<span />").parent()),e[0].style.cssText=t[0].style.cssText,t.css({height:t[0].style.height}),this.wrapper=e.addClass("k-datepicker k-input").addClass(t[0].className).removeClass("input-validation-error")},_reset:function(){var t=this,i=t.element,r=i.attr("form"),o=t.options,a=o.disableDates,s=o.parseFormats.length?o.parseFormats:null,l=t._initialOptions.value,c=r?e("#"+r):i.closest("form"),d=i[0].defaultValue;l&&a&&a(l)&&(l=null),d&&n.parseDate(d,s,o.culture)||!l||i.attr("value",n.toString(l,o.format,o.culture)),c[0]&&(t._resetHandler=function(){t.value(l||i[0].defaultValue),t.max(t._initialOptions.max),t.min(t._initialOptions.min)},t._form=c.on("reset",t._resetHandler))},_template:function(){this._ariaTemplate=d(this.options.ARIATemplate).bind(this)},_createDateInput:function(e){this._dateInput&&(this._dateInput.destroy(),this._dateInput=null),e.dateInput&&(this._dateInput=new i.DateInput(this.element,{autoAdjust:e.autoAdjust,culture:e.culture,format:e.format,size:e.size,fillMode:e.fillMode,rounded:e.rounded,min:e.min,max:e.max,messages:e.messages.dateInput,autoFill:e.autoFill,autoCorrectParts:e.autoCorrectParts}))},_updateARIA:function(e){var t=this,n=t.dateView.calendar;t.element&&t.element.length&&t.element[0].removeAttribute(P),n&&t.element.attr(P,n._updateAria(t._ariaTemplate,e))}});n.cssProperties.registerPrefix("DatePicker","k-input-"),n.cssProperties.registerValues("DatePicker",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),i.plugin(U)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=".kendoDrawer",r="k-focus",o=t.keys,a="push",s="overlay",l="left",c="start",d="k-drawer-items",u=t.ui.Widget.extend({init:function(i,r){var o,s=this;n.fn.init.call(this,i,r),r=s.options,s._element(i),s._wrapper(i),s._navigatable(),s.position(),s._mode(),r.mini&&s._miniMode(),s._initDrawerItems(),r.mini&&r.mode!=a&&s._setBodyOffset(),o=this.userEvents=new t.UserEvents(r.mode!=a?e(document.body):this.drawerContainer,{fastTap:!0,allowSelection:!0}),s.tap=function(t){e.contains(s.drawerItemsWrapper.filter("."+d)[0],t.event.target)&&s._itemClick(t),r.autoCollapse&&s.visible&&!s.trigger("hide",{sender:this})&&(s.hide(),t.preventDefault())},this.options.swipeToOpen?(o.bind("start",(function(e){s._start(e)})),o.bind("move",(function(e){s._update(e)})),o.bind("end",(function(e){s._end(e)})),o.bind("tap",s.tap)):o.bind("press",s.tap),r.minHeight&&r.mode==a&&s.drawerContainer.css("min-height",r.minHeight),s._showWatermarkOverlay&&s._showWatermarkOverlay(s.drawerContainer[0]),r.expanded&&(s._removeTransition(),s.show())},_element:function(){var t=this,n=t.element,i=t.options;if(t.contentElement=n.children().wrapAll("<div class='k-drawer-content'></div>").parent(),i.template instanceof Function){let n=i.template();t.drawerElement=e(n)}else t.drawerElement=e(i.template);n.addClass("k-drawer")},_navigatable:function(){var e=this,t=e.element;t.find("[data-role='drawer-item']").first().parent().attr("role","menubar").attr("aria-orientation","vertical"),this.options.navigatable&&t.attr("tabIndex",0).on("focus"+i,e._focus.bind(e)).on("focusout"+i,e._blur.bind(e)).on("keydown"+i,e,e._keyDown.bind(e))},_blur:function(){this._current&&this._current.removeClass(r)},_focus:function(){var e=this;e._setCurrent(e._current?e._current:e.drawerItemsWrapper.find("[data-role='drawer-item']").eq(0))},_setCurrent:function(n){var i=this,o=t.guid(),a=e(n);i._current&&(e(i._current).removeClass(r).removeAttr("id"),i.drawerItemsWrapper.removeAttr("aria-activedescendant")),a.attr("id",o).addClass(r),i.drawerItemsWrapper.attr("aria-activedescendant",o),i._current=a},_keyDown:function(t){var n,i=this,r=!1,a=i._current;t.keyCode==o.UP&&(r=!0,(n=a.prevAll("[data-role='drawer-item']").first()).length?i._setCurrent(n):i._setCurrent(a.parent().find("[data-role='drawer-item']").last())),t.keyCode==o.DOWN&&(r=!0,(n=a.nextAll("[data-role='drawer-item']").first()).length?i._setCurrent(n):i._setCurrent(a.parent().find("[data-role='drawer-item']").first())),t.keyCode==o.HOME&&(r=!0,i._setCurrent(i.drawerItemsWrapper.find("[data-role='drawer-item']").eq(0))),t.keyCode==o.END&&(r=!0,i._setCurrent(i.drawerItemsWrapper.find("[data-role='drawer-item']").last())),t.keyCode!=o.SPACEBAR&&t.keyCode!=o.ENTER||(r=!0,i.tap({event:{target:a[0]},preventDefault:e.noop})),t.keyCode==o.ESC&&(r=!0,i.hide()),r&&t.preventDefault()},_wrapper:function(){var e=this.options,t=this.drawerElement,n=this.element,i=this.contentElement,r=this.drawerItemsWrapper=t,o=this.drawerWrapper=r.wrapAll("<div class='k-drawer-wrapper'></div>").parent(),a=this.drawerContainer=n.wrap("<div class='k-drawer-container'></div>").parent();t.filter("ul").addClass(d),e.mini?e.mini.width&&o.width(e.mini.width):o.width(0),a.append(i),n.append(o)},_addTransition:function(){this.drawerWrapper.css("transition","all .3s ease-out")},_removeTransition:function(){this.drawerWrapper.css("transition","none")},_setBodyOffset:function(){var t=this.element.outerWidth();this.leftPositioned?e(document.body).css("padding-left",t):e(document.body).css("padding-right",t)},_initDrawerItems:function(){var e=this.drawerItemsWrapper,t=e.find("[data-role='drawer-item']"),n=e.find("[data-role='drawer-separator']");t.addClass("k-drawer-item").attr("role","menuitem"),n.addClass("k-drawer-item k-drawer-separator").attr("role","separator"),this._toggleLevelClasses(!!this.visible),t.each(((e,t)=>{t.setAttribute("aria-label",t.textContent.trim())})),this._selectedItemIndex>=0&&(t.removeClass("k-selected"),t.eq(this._selectedItemIndex).addClass("k-selected"))},_toggleLevelClasses:function(t){let n,i;this.drawerItemsWrapper.find("[data-role='drawer-item']").each(((r,o)=>{n=e(o).data("level")||0,i="k-level-"+n,e(o).toggleClass(i,t)}))},_mode:function(){var t,n=this.options,i=this.drawerContainer;n.mode==a?i.addClass("k-drawer-"+a):(i.addClass("k-drawer-"+s),(t=this.overlayContainer=e('<div class="k-overlay"></div>')).hide(),i.prepend(t))},_miniMode:function(){var t=this.options,n=this.drawerContainer,i=t.mini.width,r=this._miniTemplate=t.mini.template,o=this.drawerItemsWrapper,a=this.drawerWrapper;if(n.addClass("k-drawer-mini"),r)if(r instanceof Function){let t=r();o.html(e(t))}else o.html(e(r));i&&a.width(i),this.minWidth=t.mini.width||this.drawerWrapper.width()},show:function(){var e=this.drawerWrapper,t=this.drawerContainer,n=this.options,i=t.hasClass("k-drawer-expanded"),r=this._miniTemplate,o=this.drawerItemsWrapper;i||(t.addClass("k-drawer-expanded"),this.visible=!0),r&&(o.html(r),this._initDrawerItems(),this._selectItem()),e.width(n.width),n.mini&&t.removeClass("k-drawer-mini"),n.mode===s&&(this.overlayContainer.show(),this.visible=!0),this._toggleLevelClasses(!0)},hide:function(){var e=this,t=e.drawerWrapper,n=e.drawerContainer,i=this.options,r=this.drawerItemsWrapper,o=this._miniTemplate,a=i.mini&&i.mini.width;this._addTransition(),this._miniTemplate&&(r.html(o),e._initDrawerItems(),this._selectItem()),i.mini?(n.addClass("k-drawer-mini"),a?t.width(a):t.width("")):t.width(0),this.visible&&(n.removeClass("k-drawer-expanded"),this.visible=!1),i.mode===s&&this.overlayContainer.hide(),this._toggleLevelClasses(!1)},position:function(e){var t=this,n=t.options,i=e||n.position;"right"==i?(t.element.removeClass("k-drawer-"+c),t.element.addClass("k-drawer-end")):(t.element.removeClass("k-drawer-end"),t.element.addClass("k-drawer-"+c)),this.leftPositioned=i===l},_start:function(e){var n=this.options,i=(this.drawerWrapper,this.drawerItemsWrapper),r=e.sender;Math.abs(e.x.velocity)<Math.abs(e.y.velocity)||t.triggeredByInput(e.event)?r.cancel():(this.drawerMini&&i.html(this.drawerElement),this._removeTransition(),n.mode!=a&&this.overlayContainer.show())},_update:function(e){this.options.mode==a?this._push(e):this._overlay(e)},_end:function(e){var t=e.x.velocity,n=this.options,i=this.drawerWrapper.width()>n.width/2,r=.8;this._addTransition(),(this.leftPositioned?t>-.8&&(t>r||i):t<r&&(t<-.8||i))?this.trigger("show",{sender:this})?(e.preventDefault(),this.hide()):this.show():this.trigger("hide",{sender:this})?(e.preventDefault(),this.show()):this.hide()},_overlay:function(e){var t,n,i=this.options,r=i.mini&&i.mini.width||this.minWidth||0,o=this.drawerWrapper;n=o.width()+(this.leftPositioned?e.x.delta:-e.x.delta),t=Math.min(Math.max(n,r),i.width),e.event.preventDefault(),e.event.stopPropagation(),o.width(t)},_push:function(e){var t,n,i=this.options,r=i.mini&&i.mini.width||this.minWidth||0,o=this.drawerWrapper;n=o.width()+(this.leftPositioned?e.x.delta:-e.x.delta),t=Math.min(Math.max(n,r),i.width),e.event.preventDefault(),e.event.stopPropagation(),o.width(t)},_selectItem:function(e){var t;if(e)return e.addClass("k-selected"),this.trigger("itemClick",{item:e,sender:this}),void(this._selectedItemIndex=e.index());(t=this._selectedItemIndex)&&this.drawerItemsWrapper.find("[data-role='drawer-item']").eq(t).addClass("k-selected")},_itemClick:function(t){var n,i=this;e(t.event.target).find(".k-drawer-item").length>0?n=e(t.event.target).find(".k-drawer-item"):e(t.event.target).closest(".k-drawer-item").length>0?n=e(t.event.target).closest(".k-drawer-item"):e(t.event.target).hasClass(".k-drawer-item")&&(n=e(t.event.target)),i.drawerItemsWrapper.find(".k-drawer-item").removeClass("k-selected"),i._selectItem(n),i.options.navigatable&&i._setCurrent(n)},destroy:function(){this.options.mode!=a&&(this.leftPositioned?e(document.body).css("padding-left",0):e(document.body).css("padding-right",0)),n.fn.destroy.call(this),this.userEvents.destroy(),t.destroy(this.element),this.element=this.drawerWrapper=this.drawerElement=this.drawerContainer=this.drawerItemsWrapper=this._miniTemplate=null},options:{name:"Drawer",autoCollapse:!0,expanded:!1,position:l,mode:"overlay",swipeToOpen:!0,width:280,mini:!1,navigatable:!1,template:""},events:["hide","show","itemClick"]});t.ui.plugin(u)}(window.kendo.jQuery);kendo;!function(e,t){let n=window.kendo,i=n.calendar,r=n.support,o=i.isInRange,a=i.toDateObject,s=i.createDate,l=i.isEqualDate,c=i.getToday,d=n.keys,u=n.ui,h=u.Widget,p=u.Selectable,f=u.RangeSelectable,m=n.template,g=r.mobileOS,v=".kendoMultiViewCalendar",_="click",b="id",y="month",w=".",k=" ",x="century",C="change",S="navigate",T="value",D="k-focus",A="k-selected",M="k-hover",E="k-disabled",I="k-calendar-nav-today",z="k-empty",P="k-calendar-view",H="td:has(.k-link):not(."+z+"):not(.k-alt)",F="td:has(.k-link):not(."+E+"):not(."+z+"):not(.k-alt)",R="blur",L="focus",B=r.touch?"touchstart":"mouseenter",O=r.touch?"touchend"+v+" touchmove"+v:"mouseleave"+v,V="_prevArrow",N="_nextArrow",$="start",U="end",W="table",j="tbody",q="thead",G="td:not(.k-alt)",K="th",Y="role",Q="none",X="aria-disabled",Z="aria-label",J="aria-activedescendant",ee=Date,te={month:0,year:1,decade:2,century:3};var ne=h.extend({init:function(t,r){var o,a,s=this;h.fn.init.call(s,t,r),t=s.wrapper=s.element,r=s.options,s.options.disableDates=i.disabled(s.options.disableDates),a=n.getCulture(r.culture),r.format=n._extractFormat(r.format||a.calendars.standard.patterns.d),s._templates(),s._header(),s._wrapper(),(o=t.addClass(`k-calendar k-calendar-range ${n.getValidCssClass("k-calendar-","size",s.options.size||"medium")}`+(r.weekNumber?" k-week-number":"")).on("keydown"+v,w+P,s._move.bind(s)).on(L+v,w+P,s._focus.bind(s)).on(R+v,w+P,s._blur.bind(s)).on(_+v,F,(function(t){var n=t.currentTarget.firstChild;-1!=e(n).data("href").indexOf("#")&&t.preventDefault(),s._click(e(n))})).attr(b))||(o=n.guid()),s._cellID=o+"_cell_selected",s._calendarWidth=s.element.width(),s._range=r.range,s._range&&s._range.start&&!s._range.end&&(s._range.target=U),s._initViews({viewName:r.start,value:r.value}),s._selectable(),s._footer(s.footer),s._selectDates=[],s.value(r.value),s._addSelectedCellsToArray(),s._isMultipleSelection()&&(s._selectDates=r.selectDates.length?r.selectDates:s._selectDates,s._restoreSelection()),s._isRangeSelection()&&s.selectRange(s._range),n.notify(s)},options:{name:"MultiViewCalendar",value:null,min:new ee(1900,0,1),max:new ee(2099,11,31),dates:[],allowReverse:!1,disableDates:null,showOtherMonthDays:!1,centuryCellsFormat:"long",culture:"",footer:"",format:"",month:{},range:{start:null,end:null,target:$},weekNumber:!1,views:2,showViewHeader:!1,selectable:"single",selectDates:[],start:y,depth:y,messages:{weekColumnHeader:""},size:"medium",orientation:"horizontal"},events:[C,S],setOptions:function(e){var t=this;i.normalize(e),e.disableDates=i.disabled(e.disableDates),h.fn.setOptions.call(t,e),t._selectable(),t._templates(),t._footer(t.footer);for(var n=0;n<t._views.length;n++)t._views[n].off(v).remove();t._initViews({viewName:e.start,value:e.value}),t._range=e.range||{start:null,end:null},t._restoreSelection(),t._isRangeSelection()&&t.selectRange(t._range)},destroy:function(){var e=this;if(e._cell=null,e._currentView=null,e._current=null,e._views)for(var t=0;t<e._views.length;t++)e._views[t].off(v).remove();e.element.off(v),e.header&&(e.header.off(v),e._title=null,e.header=null),e.selectable&&(e.selectable.destroy(),e.selectable=null),e.rangeSelectable&&(e.rangeSelectable.destroy(),e.rangeSelectable=null),e._today&&n.destroy(e._today.off(v)),e._views=null,h.fn.destroy.call(e)},current:function(){return this._current},focus:function(){this.tablesWrapper.trigger("focus")},min:function(e){return this._option("min",e)},max:function(e){return this._option("max",e)},view:function(){return this._currentView},navigateToPast:function(){this._navigate(V,-1)},navigateToFuture:function(){this._navigate(N,1)},navigateUp:function(){var e=this,t=e._index;e._title.hasClass(E)||e.navigate(e._current,++t)},navigateDown:function(e){var t=this,n=t._index,i=t.options.depth;e&&(n!==te[i]?t.navigate(e,--n):l(t._value,t._current)&&l(t._value,e)||(t.value(e),t.trigger(C)))},navigate:function(e,n){n=isNaN(n)?i.views[i.viewsEnum[n]]:i.views[n];var r=this,o=r.options,a=o.min,s=o.max;r._current=e||(e=new ee(+i.restrictValue(e,a,s))),n===t&&(n=r._currentView),r._currentView=n;for(var l=0;l<r._views.length;l++)r._views[l].off(v).remove();r._initViews({viewName:n.name,value:e}),r._restoreSelection()},_aria:function(){var e=this.tablesWrapper.find(W),t=e.first().find(q).add(e.find(j)),n=this._currentView.name;e.removeAttr("tabindex"),e.attr({role:Q}),t.attr({role:"rowgroup"}),n===y&&this._ariaMonth()},_ariaMonth:function(){var t=this.tablesWrapper.find(W),n=t.first().find(q).add(t.find(j)).find("tr"),i=t.not(":eq(0)").find(q+k+"tr"),r=i.find(K),o=t.first().find(q+k+K),a=t.find(j+k+"td.k-alt"),s=t.find(w+z);o.attr({role:"columnheader"}),a.attr({role:"rowheader"}),s.removeAttr(Y),i.removeAttr(Y),r.removeAttr(Z).removeAttr(Y),n.each((function(t,i){var r,o=e(i),a=o.find(w+z).length,s=[];1===t?o.children().filter(w+z).attr({"aria-hidden":"false",role:"gridcell"}):7===a?(o.removeAttr(Y),o.find(K).removeAttr(Y)):a>0&&a<7&&o.children().not(K).first().hasClass(z)&&(o.find(K).removeAttr(Y),(r=n.eq(t-1)).attr(Y)&&r.attr(Y)!==Q||(r=n.eq(t-2)),o.children().not(K).each((function(n,i){var r,o=e(i);o.hasClass(z)||(r="owned_"+t+"_"+n,o.attr(b,r),s.push(r))})),o.removeAttr(Y),r.attr("aria-owns",s.join(" ")))}))},_updateHeader:function(){let t,i,r,a,s=this,l=s._currentView,c=s._title,d=s._firstViewValue,u=s.options,h=s._visibleRange(),p=u.culture,f=u.min,m=u.max;"decade"===l.name||l.name===x?(t=re(d,l.name,u.views-1),o(t,f,m)||(t=m),c.html('<span class="k-button-text">'+l.first(d).getFullYear()+" - "+l.last(t).getFullYear()+"</span>")):c.html('<span class="k-button-text">'+l.title(d,f,m,p)+" - "+l.title(re(d,l.name,u.views-1),f,m,p)+"</span>"),i=l.name===x,c.toggleClass(E,i).attr(X,i),r=l.compare(h.start,s.options.min)<1,a=l.compare(h.end,s.options.max)>-1,r&&a?s._navContainer&&(s._navContainer.remove(),s._navContainer=null):(s._navContainer||(s._navContainer=e(`<span class="k-calendar-nav"><span tabindex="-1" data-href="#" role="button" class="k-button ${n.getValidCssClass("k-button-","size",s.options.size||"medium")} k-rounded-md k-button-flat k-button-flat-base k-icon-button k-calendar-nav-prev" `+Z+`="Previous">${n.ui.icon({icon:"chevron-left",iconClass:"k-button-icon"})}</span>`+`<span tabindex="-1" data-href="#" role="button" class="k-button ${n.getValidCssClass("k-button-","size",s.options.size||"medium")} k-rounded-md k-button-flat k-button-flat-base k-icon-button k-calendar-nav-next" `+Z+`="Next">${n.ui.icon({icon:"chevron-right",iconClass:"k-button-icon"})}</span></span>`).appendTo(s.header),s[V]=s._navContainer.find(".k-calendar-nav-prev"),s[N]=s._navContainer.find(".k-calendar-nav-next")),s[V].toggleClass(E,r).attr(X,r),s[V].hasClass(E)&&s[V].removeClass(M),s[N].toggleClass(E,a).attr(X,a),s[N].hasClass(E)&&s[N].removeClass(M))},_move:function(i){var r,l,c,u,h,p,f=this,m=f.options,g=i.keyCode,v=f._index,_=m.min,b=m.max,k=f.element.find(w+D),x=k.closest(W),T=new ee(+(f._current||a(k.find("span")))),M=n.support.isRtl(f.wrapper),I=!1;if(g==d.RIGHT&&!M||g==d.LEFT&&M?(r=1,l=!0):g==d.LEFT&&!M||g==d.RIGHT&&M?(r=-1,l=!0):g==d.UP?(r=0===v?-7:-4,l=!0):g==d.DOWN?(r=0===v?7:4,l=!0):g==d.SPACEBAR?(r=0,l=!0):g==d.HOME?(l=!0,(c=x.find(F).eq(0)).hasClass(D)?(x=x.prev()).length?f._focusCell(x.find(F).eq(0)):(I=f[V]&&!f[V].hasClass(E),f._navigate(V,-1),f._focusCell(f.element.find(W).first().find(F).first())):f._focusCell(c)):g==d.END?(l=!0,(c=x.find(F).last()).hasClass(D)?(x=x.next()).length?f._focusCell(x.find(F).last()):(I=f[N]&&!f[N].hasClass(E),f._navigate(N,1),f._focusCell(f.element.find(W).last().find(F).last())):f._focusCell(c)):84===g&&(f._todayClick(i),l=!0),i.ctrlKey||i.metaKey)g==d.RIGHT&&!M||g==d.LEFT&&M?(I=f[N]&&!f[N].hasClass(E),f._navigate(N,1),l=!0):g==d.LEFT&&!M||g==d.RIGHT&&M?(I=f[V]&&!f[V].hasClass(E),f._navigate(V,-1),l=!0):g==d.UP?(I=!f._title.hasClass(E),f.navigateUp(),f._focusCell(f._cellByDate(f._current)),l=!0):g==d.DOWN?(f._currentView.name===y?f.value(T):(f.navigateDown(T),f._focusCell(f._cellByDate(f._current)),I=!0),l=!0):g!=d.ENTER&&g!=d.SPACEBAR||f._isMultipleSelection()&&f._toggleSelection(i);else if(i.shiftKey&&!f._isSingleSelection()){if(r!==t){if(f._currentView.setDate(T,r),f._currentView.name!==y)return;m.disableDates(T)&&(T=f._nextNavigatable(T,r)),_=s(_.getFullYear(),_.getMonth(),_.getDate()),o(T,_,b)&&(f._dateInViews(T)||(r>0?(I=f[N]&&!f[N].hasClass(E),f._navigate(N,1)):(I=f[V]&&!f[V].hasClass(E),f._navigate(V,-1))),c=f._cellByDate(T),f._current=T,f.selectable&&(f._selectRange(a((f.selectable._lastActive||k).find("span")),T),f.selectable._lastActive||(f.selectable._lastActive=k),f.trigger(C),f._focusCell(c)),f.rangeSelectable&&(u=a((f.rangeSelectable._lastActive||k).find("span")),f._dateInViews(u)?(f.rangeSelectable._end&&f.rangeSelectable._end.is(w+D)?f.rangeSelectable._lastActive=f.rangeSelectable._start:f.rangeSelectable._lastActive=f._cellByDate(u),f.rangeSelectable.range(f.rangeSelectable._lastActive,c)):+u>+T?(f.rangeSelectable._end=f.rangeSelectable._lastActive,f.rangeSelectable.selectFrom(c)):f.rangeSelectable.selectTo(c),f.rangeSelectable.change(),f._focusCell(c)))}}else g==d.ENTER||g==d.SPACEBAR?(f._currentView.name===y?(p=!k.hasClass(A)||f.element.find(w+A).length>1,f.value(T),f.selectable&&(f.selectable._lastActive=f._cellByDate(T),p&&f.selectable.trigger(C,{event:i})),f.rangeSelectable&&f.rangeSelectable.change()):f._click(e(f._cell[0].firstChild)),l=!0):g!=d.PAGEUP&&g!=d.PAGEDOWN||(l=!0,h=x.find(F).index(k),(x=g==d.PAGEUP?x.prev():x.next()).length||(g==d.PAGEUP?(I=f[V]&&!f[V].hasClass(E),f.navigateToPast(),x=f.element.find(W).first()):(I=f[N]&&!f[N].hasClass(E),f.navigateToFuture(),x=f.element.find(W).last())),(c=x.find(F).eq(h)).length?f._focusCell(c):f._focusCell(x.find(F).last())),r&&(f._currentView.setDate(T,r),_=s(_.getFullYear(),_.getMonth(),_.getDate()),o(T,_,b)&&(f.selectable&&m.disableDates(T)&&(T=f._nextNavigatable(T,r)),f._dateInViews(T)||(r>0?(I=f[N]&&!f[N].hasClass(E),f._navigate(N,1)):(I=f[V]&&!f[V].hasClass(E),f._navigate(N,-1))),c=f._cellByDate(T),f._current=T,f._focusCell(c)));return I&&f.trigger(S),l&&i.preventDefault(),f._current},_visualizeSelectedDatesInView:function(){var t,i=this,r={};e.each(i._selectDates,(function(e,t){r[n.calendar.views[0].toDateString(t)]=t})),i.selectable.clear(),t=i.element.find(W).find(H).filter((function(t,i){return r[e(i.firstChild).attr(n.attr(T))]})),t.length>0&&i.selectable._selectElement(t,!0)},_nextNavigatable:function(e,t){var n=this,i=!0,r=n._currentView,a=n.options.min,s=n.options.max,l=n.options.disableDates,c=new Date(e.getTime());for(r.setDate(c,-t);i;){if(r.setDate(e,t),!o(e,a,s)){e=c;break}i=l(e)}return e},_toggleSelection:function(t){var n=this;n.selectable._lastActive=e(n._cell[0]),e(n._cell[0]).hasClass(A)?n.selectable._unselect(e(n._cell[0])):n.selectable.value(e(n._cell[0])),n.selectable.trigger(C,{event:t})},_option:function(e,i){var r=this,o=r.options,a=r._value||r._current;if(i===t)return o[e];(i=n.parseDate(i,o.format,o.culture))&&(o[e]=new ee(+i),("min"===e?i>a:a>i)&&(r._value=null),r.navigate(r._value),r._toggle())},_cellByDate:function(t){return t instanceof Date&&(t=this._currentView.toDateString(t)),this.element.find(W).find("td:not(.k-other-month)").filter((function(){return e(this.firstChild).attr(n.attr(T))===t}))},_selectable:function(){let e=this,n=e.options.selectable,i=p.parseOptions(n);e.selectable&&(e.selectable.destroy(),e.selectable=null),e.rangeSelectable&&(e.rangeSelectable.destroy(),e.rangeSelectable=null),i.range?e.rangeSelectable=new f(e.wrapper,{widget:e,filter:".k-calendar-monthview table "+F,cellSelector:H,cellSelectorValid:F,change:e._rangeSelection.bind(e),reverse:e.options.allowReverse,resetOnStart:n.resetOnStart===t||n.resetOnStart,ns:v,inputSelectors:"input,a,span,textarea,.k-multiselect-wrap,select,button,.k-button>span,.k-button>img,span.k-icon.k-i-caret-alt-down,span.k-icon.k-i-caret-alt-up,span.k-svg-icon.k-svg-i-caret-alt-down,span.k-svg-icon.k-svg-i-caret-alt-up"}):e.selectable=new p(e.wrapper,{aria:!0,dragToSelect:!1,multiple:i.multiple,filter:"table.k-calendar-table "+F,selectableClass:"k-calendar",change:e._selection.bind(e),relatedTarget:e._onRelatedTarget.bind(e),unselect:e._unselecting.bind(e)})},_onRelatedTarget:function(e){this.selectable.options.multiple&&e.is(F)&&e.length>1&&this._focusCell(e.first(),!0)},_getFirstViewDate:function(e){var t,n,i,r=this,o=r.options,a=[],s=new Date(+r._current);for(i=0;i<o.views;i++){if(t=e.first(s),+(n=e.last(s))>+o.max){+t<=+o.max&&a.push({start:t,end:new Date(+o.max)});break}a.push({start:t,end:n}),s=new Date(+re(n,e.name,1))}for(s=new Date(+r._current),i=0;i<o.views;i++){if(t=e.first(s),n=e.last(s),+t<+o.min){+n>=+o.min&&a.push({start:new Date(+o.min),end:n});break}a.push({start:t,end:n}),s=new Date(+re(t,e.name,-1))}for(t=a[0].start,i=0;i<o.views+1&&a[i];i++)+t>+a[i].start&&(t=a[i].start);return new Date(+t)},_canRenderNextView:function(e){var t=e.getFullYear(),n=e.getMonth(),i=e.getDate(),r=this.options.max,o=r.getFullYear(),a=r.getMonth();return t<o||(t===o&&n<a||(t===o&&n===a&&i<r.getDate()||t===o&&n===a&&i===r.getDate()))},_initViews:function(t){var n,r=this,o=r.options,a=i.viewsEnum[t.viewName],s=i.views[a];r._current=new ee(+i.restrictValue(t.value,o.min,o.max)),r._views=[],r._index=a,(n=r._getFirstViewDate(s)).setDate(1),r._firstViewValue=new Date(+n);for(var l=0;l<o.views&&((n=l?re(n,s.name,1):n).setDate(1),r._canRenderNextView(n));l++)r._table=e(s.content(e.extend({min:o.min,max:o.max,date:n,url:o.url,dates:o.dates,format:o.format,culture:o.culture,disableDates:o.disableDates,showHeader:o.showViewHeader,isWeekColumnVisible:o.weekNumber,showOtherMonthDays:o.showOtherMonthDays,centuryCellsFormat:o.centuryCellsFormat,messages:o.messages,contentClasses:"k-calendar-table"},r[s.name]))),r._table.appendTo(r.tablesWrapper),r._views.push(r._table);r._currentView=s,r.tablesWrapper.attr("class","k-calendar-view k-calendar-"+s.name+`view ${"vertical"!=r.options.orientation?"k-hstack":"k-vstack"} k-align-items-start k-justify-content-center`),r._updateHeader(),r._aria()},_rangeSelection:function(e){let t,n,i=this,r=e.sender.range(),o=e.sender._useEnd,s=e.sender._useStart,l=i.selectRange()||{},c=l.target;r.start&&r.start.length&&(t=a(r.start.find("span"))),r.end&&r.end.length&&(n=a(r.end.find("span"))),c=c===U?$:U,i._range={start:s?l.start:t,end:o?l.end:n,target:c},i._preventChange||i.trigger(C)},_selection:function(t){let n,i=this,r=t.sender.value(),o=t.event,s=e(o&&o.currentTarget),l=s.is(G);i._isSingleSelection()&&i._validateValue(r[0]?a(r.first().find("span")):t.sender._lastActive?a(t.sender._lastActive.find("span")):i.value()),i._isMultipleSelection()&&(l&&(n=a(s.find("span"))),o&&o.ctrlKey?l?s.hasClass(A)?i._selectDates.push(n):i._deselect(n):(i.element.find("table "+F).each((function(t,n){var r=a(e(n).find("span"));i._deselect(r)})),i._addSelectedCellsToArray()):o&&o.shiftKey?i._selectRange(a(t.sender._lastActive?t.sender._lastActive.find("span"):r.first().find("span")),n):l?(i._selectDates=[],i._selectDates.push(n)):(i._selectDates=[],i._addSelectedCellsToArray())),i._preventChange||i.trigger(C)},_addSelectedCellsToArray:function(){var t=this;t.selectable&&t.selectable.value().each((function(n,i){var r=a(e(i.firstChild));t.options.disableDates(r)||t._selectDates.push(r)}))},_deselect:function(e){var t=this._selectDates.map(Number).indexOf(+e);-1!=t&&this._selectDates.splice(t,1)},_unselecting:function(e){var t=e.element;this._isSingleSelection()&&!g&&t.hasClass(D)&&e.preventDefault()},_visibleRange:function(){var e=this.element.find(w+P+k+W);return{start:a(e.first().find(H).first().find("span")),end:a(e.last().find(H).last().find("span"))}},_dateInViews:function(e){var t=this.element.find(w+P+k+W),n=a(t.first().find(H).first().find("span")),i=a(t.last().find(H).last().find("span"));if(e)return+(e=new Date(e.toDateString()))<=+i&&+e>=+n},_fillRange:function(e,t){var r,o=this;o._selectDates=[],r=function(e,t){if(+t<+e){var r=+e;i.views[0].setDate(e,t),i.views[0].setDate(t,new Date(r))}var o=Date.UTC(e.getFullYear(),e.getMonth(),e.getDate()),a=Date.UTC(t.getFullYear(),t.getMonth(),t.getDate());return Math.ceil((+a-+o)/n.date.MS_PER_DAY)}(e,t),function(e,t,n,i){for(var r=0;r<=t;r++){var o=new Date(n.getTime());i(o=new Date(o.setDate(o.getDate()+r)))||e.push(o)}}(o._selectDates,r,e,o.options.disableDates)},_selectRange:function(e,t){var n;+t<+e&&(n=t,t=e,e=n),this._fillRange(e,t),this._visualizeSelectedDatesInView()},_header:function(){var t,i=this,r=i.element,o=r.find(".k-calendar-header");o.length||(o=e(`<div class="k-calendar-header"><span id="calendar-title" tabindex="-1" data-href="#" role="button" class="k-calendar-title k-button ${n.getValidCssClass("k-button-","size",i.options.size||"medium")} k-rounded-md k-button-flat k-button-flat-primary" aria-live="polite"></span><span class="k-spacer"></span><span class="k-calendar-nav"><span tabindex="-1" data-href="#" role="button" class="k-button ${n.getValidCssClass("k-button-","size",i.options.size||"medium")} k-rounded-md k-button-flat k-button-flat-base k-icon-button k-calendar-nav-prev" `+Z+`="Previous">${n.ui.icon({icon:"chevron-left",iconClass:"k-button-icon"})}</span>`+`<span tabindex="-1" data-href="#" role="button" class="k-button ${n.getValidCssClass("k-button-","size",i.options.size||"medium")} k-rounded-md k-button-flat k-button-flat-base k-icon-button k-calendar-nav-next" `+Z+`="Next">${n.ui.icon({icon:"chevron-right",iconClass:"k-button-icon"})}</span></span></div>`).prependTo(r)),i.header=o,o.on(B+v+" "+O+" "+L+v+" "+R+v,".k-button",ie).on(_,(function(){return!1})).on(_+v,".k-button.k-calendar-title",i._calendarTitleClick.bind(i)).on(_+v,".k-button.k-calendar-nav-prev",i._prevViewClick.bind(i)).on(_+v,".k-button.k-calendar-nav-next",i._nextViewClick.bind(i)),t=o.find(".k-button"),i._title=t.filter(".k-calendar-title"),i._navContainer=o.find(".k-calendar-nav"),i[V]=t.filter(".k-calendar-nav-prev"),i[N]=t.filter(".k-calendar-nav-next")},_calendarTitleClick:function(){this.navigateUp(),this.focus(),this.trigger(S)},_prevViewClick:function(e){e.preventDefault(),this.navigateToPast(),this.focus(),this.trigger(S)},_nextViewClick:function(e){e.preventDefault(),this.navigateToFuture(),this.focus(),this.trigger(S)},_wrapper:function(){this.tablesWrapper=e('<div tabindex="0" role="grid" class="k-calendar-view" aria-labelledby="calendar-title" />').insertAfter(this.element[0].firstChild)},_templates:function(){var e=this.options.month,t=e.content,i=e.weekNumber,r=e.empty;this.month={content:m((e=>`<td class="${e.cssClass}" role="gridcell"><span tabindex="-1" class="k-link${e.linkClass}" data-href="${e.url}" ${n.attr(T)}="${e.dateString}" title="${e.title}">${t?n.template(t,{useWithBlock:!!t})(e):e.value}</span></td>`),{useWithBlock:!!t}),empty:m((e=>`<td role="gridcell"${r?">":' class="k-calendar-td k-empty">'}${r?n.template(r,{useWithBlock:!!r})(e):"</span>"}</td>`),{useWithBlock:!!r}),weekNumber:m((e=>`<td class="k-calendar-td k-alt">${i?n.template(i,{useWithBlock:!!i})(e):e.weekNumber}</td>`),{useWithBlock:!!i})}},_footer:function(){var t=this,i=t.options,r=!1!==i.footer?n.template(t.options.footer||(e=>n.toString(e,"D",i.culture)),{useWithBlock:!1}):null,o=c(),a=t.element,s=a.find(".k-calendar-footer");if(!r)return t._toggle(!1),void s.hide();s[0]||(s=e(`<div class="k-calendar-footer">\n                    <button tabindex="-1" class="k-calendar-nav-today k-button ${n.getValidCssClass("k-button-","size",t.options.size||"medium")} k-button-flat k-button-flat-primary k-rounded-md">\n                        <span class="k-button-text"></span>\n                    </button>\n                </div>`).appendTo(a)),t._today=s.show().find(".k-button-flat-primary").attr("title",n.toString(o,"D",t.options.culture)),s.find(".k-button-text").html(r(o)),t._toggle()},_navigate:function(e,t){var n,r=this,o=r._index+1,a=new ee(+r._current),s=new ee(+r._current);e=r[e],n=r._cellByDate(a).closest(W).index(),t>0?n=1-n:n+=1,e&&e.hasClass(E)||(o>3?a.setFullYear(a.getFullYear()+t*n*100):i.views[o].setDate(a,t*n),r.navigate(a),r._dateInViews(s)?(r._focusCell(r._cellByDate(s)),r._current=s):(o>3?s.setFullYear(s.getFullYear()+100*t):i.views[o].setDate(s,t),r._focusCell(r._cellByDate(s)),r._current=s))},_toggle:function(e){var n=this,i=n.options,r="range"!==i.selectable&&n.options.disableDates(c()),a=n._today;e===t&&(e=o(c(),i.min,i.max)),a&&(a.off(_+v),e&&!r?a.addClass(I).removeClass(E).on(_+v,(function(e){n._todayClick(e),n.focus()})):a.removeClass(I).addClass(E).on(_+v,(function(e){e.preventDefault()})))},_click:function(e){var t=this,r=t.options,o=new Date(+t._current),s=a(e);n.date.adjustDST(s,0),t._currentView.setDate(o,s),t._current=s,t._currentView.name!==r.depth?(t.navigateDown(i.restrictValue(o,r.min,r.max)),t._focusCell(t._cellByDate(t._current)),t.trigger(S)):t._focusCell(e.closest(G)),t.focus()},_blur:function(){this._cell&&this._cell.removeClass(D)},_focus:function(){var t=this._cell;t&&e.contains(this.tablesWrapper[0],t[0])||(t=this._current&&this._dateInViews(this._current)?this._cellByDate(this._current):this.tablesWrapper.find(F).first()),this._focusCell(t)},_focusCell:function(e){var t=this,n=t._cellID;t._cell&&t._cell.length&&(t._cell[0].removeAttribute(Z),t._cell.removeClass(D),t.tablesWrapper.removeAttr(J),t._cell.attr(b)===n&&t._cell[0].removeAttribute(b)),t._cell=e,e.attr(b)?t.tablesWrapper.attr(J,e.attr(b)):n&&(e.attr(b,n),t.tablesWrapper.attr(J,n)),e.addClass(D),e.length&&t._currentView.name==y&&(t._current=a(e.find("span")))},_todayClick:function(e){var t=this,n=t.options.disableDates,i=c(),r=!1;e.preventDefault(),n(i)||(t._value=i,t._isMultipleSelection()&&(t._selectDates=[i]),t._isRangeSelection()&&(t.rangeSelectable.clear(!0),t._range={start:i,end:null}),t._currentView.name==y&&t._dateInViews(i)||(r=!0),t.navigate(i,t.options.depth),t._isSingleSelection()&&(t.selectable._lastActive=null),r&&t.trigger(S),t.trigger(C))},_validateValue:function(e){var i=this,r=i.options,a=r.min,s=r.max;return null!==(e=n.parseDate(e,r.format,r.culture))&&(e=new ee(+e),o(e,a,s)||(e=null)),null!==e&&i.options.disableDates(new Date(+e))?i._value===t&&(i._value=null):i._value=e,i._value},_updateAria:function(e,t){var i,r=this,o=r._cellByDate(t||r.current()),a=r.view().valueType(),s=t||r.current();return r._focusCell(o),i=a===y?n.toString(s,"MMMM"):"date"===a?n.toString(s,"D"):o.text(),o.attr(Z,e({current:s,valueType:a,text:i})),o.attr(b)},clearSelection:function(){var e=this;e.selectable&&e.element.find(w+A).removeClass(A).removeAttr("aria-selected"),e.rangeSelectable&&e.rangeSelectable.clear(!0)},_restoreSelection:function(){var e,t=this;if(t._currentView.name===t.options.depth){if(t._preventChange=!0,t._isRangeSelection()){if(!(e=t.selectRange())||!e.start)return void(t._preventChange=!1);t.selectRange(e)}t._isSingleSelection()&&t.value()&&t.selectable.value(t._cellByDate(t.value())),t._isMultipleSelection()&&t._visualizeSelectedDatesInView(),t._preventChange=!1}},_isMultipleSelection:function(){let e=this.options.selectable;return p.parseOptions(e).multiple},_isRangeSelection:function(){let e=this.options.selectable;return p.parseOptions(e).range},_isSingleSelection:function(){let e=this.options.selectable;return p.parseOptions(e).single},value:function(e){var n,i=this;if(e===t)return i._value;e=i._validateValue(e),i.clearSelection(),e&&!i._dateInViews(e)&&i.navigate(e),null!==e&&i._currentView.name===y&&(n=i._cellByDate(e),i.selectable&&i.selectable.value(n),i.rangeSelectable&&(i.rangeSelectable.start(n),i.rangeSelectable._lastActive=n))},selectDates:function(n){var i,r,o=this;if(n===t)return o._selectDates;r=n.map((function(e){return e.getTime()})).filter((function(e,t,n){return n.indexOf(e)===t})).map((function(e){return new Date(e)})),i=e.grep(r,(function(e){if(e)return+o._validateValue(new Date(e.setHours(0,0,0,0)))==+e})),o._selectDates=i.length>0?i:0===r.length?r:o._selectDates,o._visualizeSelectedDatesInView()},selectRange:function(e){let n,i,r,o=this;if(e===t)return o._range;o._range=e,r=o._visibleRange(),n=o._dateInViews(e.start),i=e.end&&o._dateInViews(e.end),n||(i?e.start?o.rangeSelectable.selectTo(o._cellByDate(e.end)):(o.rangeSelectable.clear(!0),o.rangeSelectable.end(o._cellByDate(e.end))):e.start&&o.rangeSelectable.start(o._cellByDate(e.start))),n&&i&&o.rangeSelectable.range(o._cellByDate(e.start),o._cellByDate(e.end),!1,o.options.allowReverse),e.end&&n&&!i&&o.rangeSelectable.selectFrom(o._cellByDate(e.start)),!e.end&&n&&(o.rangeSelectable.clear(!0),o.rangeSelectable.start(o._cellByDate(e.start))),+r.start>+e.start&&+r.end<+e.end&&o.rangeSelectable.mid(o.element.find(F))}});function ie(t){e(this).hasClass("k-disabled")||e(this).toggleClass(M,B.indexOf(t.type)>-1||t.type==L)}function re(e,t,n){var r;return t===y?((r=new ee(e.getFullYear(),e.getMonth()+n,e.getDate())).setFullYear(e.getFullYear()),(Math.abs(r.getMonth()-e.getMonth())>n||n>10)&&(r.setMonth(e.getMonth()+n),r=i.views[0].last(r)),r):"year"===t?((r=new ee(1,e.getMonth(),e.getDate())).setFullYear(e.getFullYear()+n),Math.abs(r.getFullYear()-e.getFullYear())>n&&((r=new ee(1,e.getMonth(),1)).setFullYear(e.getFullYear()+n),r=i.views[1].last(r)),r):"decade"===t?((r=new ee(1,e.getMonth(),e.getDate())).setFullYear(e.getFullYear()+10*n),Math.abs(r.getFullYear()-e.getFullYear())>10*n&&((r=new ee(1,e.getMonth(),1)).setFullYear(e.getFullYear()+10*n),r=i.views[2].last(r)),r):"century"===t?((r=new ee(1,e.getMonth(),e.getDate())).setFullYear(e.getFullYear()+100*n),Math.abs(r.getFullYear()-e.getFullYear())>100*n&&((r=new ee(1,e.getMonth(),1)).setFullYear(e.getFullYear()+100*n),r=i.views[3].last(r)),r):void 0}n.ui.plugin(ne)}(window.kendo.jQuery);kendo;let Sf=kendo.jQuery;function Tf({widget:e,wrapper:t,options:n,prefixInsertBefore:i,suffixInsertAfter:r}){var o,a,s=n.prefixOptions,l=n.suffixOptions,c=s.template||s.icon,d=l.template||l.icon,u=(r=r||i,n.layoutFlow),h=u?"vertical"==u?"horizontal":"vertical":"horizontal",p=`<span class="k-input-separator k-input-separator-${"vertical"==u?"horizontal":"vertical"}"></span>`;s&&c&&((o=t.children(".k-input-prefix"))[0]||(o=Sf(`<span class="k-input-prefix k-input-prefix-${h}" />`),i?o.insertBefore(i):o.prependTo(t)),s.icon&&o.html(kendo.html.renderIcon({icon:s.icon})),s.template&&o.html(kendo.template(s.template)({})),s.separator&&Sf(p).insertAfter(o)),l&&d&&((a=t.children(".k-input-suffix"))[0]||(a=Sf(`<span class="k-input-suffix k-input-suffix-${h}" />`).appendTo(t),r?a.insertAfter(r):a.appendTo(t)),l.icon&&a.html(kendo.html.renderIcon({icon:l.icon})),l.template&&a.html(kendo.template(l.template)({})),l.separator&&Sf(p).insertBefore(a)),e._prefixContainer=o,e._suffixContainer=a}!function(e,t){var n=window.kendo,i=n.htmlEncode,r=n.support,o=n.caret,a=n._activeElement,s=r.placeholder,l=n.ui,c=l.List,d=n.keys,u=n.data.DataSource,h="aria-disabled",p="aria-readonly",f="change",m="disabled",g="readonly",v="k-focus",_="k-disabled",b=".kendoAutoComplete",y="mouseenter"+b+" mouseleave"+b;function w(e,t,n){return n?t.substring(0,e).split(n).length-1:0}var k=c.extend({init:function(t,i){var r,o=this;o.ns=b,i=Array.isArray(i)?{dataSource:i}:i,c.fn.init.call(o,t,i),t=o.element,(i=o.options).placeholder=i.placeholder||t.attr("placeholder"),s&&t.attr("placeholder",i.placeholder),o._wrapper(),o._clearButton(),o._dataSource(),o._ignoreCase(),t[0].type="text",r=o.wrapper,o._popup(),t.addClass("k-input-inner").on("keydown"+b,o._keydown.bind(o)).on("keypress"+b,o._keypress.bind(o)).on("input"+b,o._search.bind(o)).on("paste"+b,o._search.bind(o)).on("focus"+b,(function(){o._prev=o._accessor(),o._oldText=o._prev,o._placeholder(!1),r.addClass(v)})).on("focusout"+b,(function(e){o.filterInput&&e.relatedTarget===o.filterInput[0]||(o._change(),o._placeholder(),o.close(),r.removeClass(v))})).attr({autocomplete:"off",role:"combobox","aria-expanded":!1}),o._clear.on("click"+b+" touchend"+b,o._clearValue.bind(o)),o._clear.on("mousedown"+b,o._clearValueMouseDownHandler.bind(o)),o._enable(),o._old=o._accessor(),o._placeholder(),o._initList(),e(o.element).parents("fieldset").is(":disabled")&&o.enable(!1),o.listView.bind("click",(function(e){e.preventDefault()})),o._resetFocusItemHandler=o._resetFocusItem.bind(o),Tf({widget:o,wrapper:o.wrapper,options:o.options,prefixInsertBefore:o._inputValuesContainer,suffixInsertAfter:i.clearButton?o._clear:o.element}),n.notify(o),o._toggleCloseVisibility(),o._applyCssClasses(),i.label&&o._label(),o._aria()},options:{name:"AutoComplete",enabled:!0,suggest:!1,template:"",groupTemplate:e=>i(e),fixedGroupTemplate:e=>i(e),prefixOptions:{separator:!0},suffixOptions:{separator:!0},dataTextField:"",minLength:1,enforceMinLength:!1,delay:200,height:200,filter:"startswith",ignoreCase:!0,highlightFirst:!1,separator:null,placeholder:"",animation:{},virtual:!1,value:null,clearButton:!0,autoWidth:!1,popup:null,size:"medium",fillMode:"solid",rounded:"medium",label:null},_clearValueMouseDownHandler:function(e){e&&e.currentTarget&&e.currentTarget.classList.contains("k-clear-value")?this._clearValueTrigger=!0:this._clearValueTrigger=!1},_onActionSheetCreate:function(){var e=this;e.filterInput&&(e.filterInput.on("keydown"+b,e._keydown.bind(e)).on("keypress"+b,e._keypress.bind(e)).on("input"+b,e._search.bind(e)).on("paste"+b,e._search.bind(e)).attr({autocomplete:"off",role:"combobox","aria-expanded":!1}),e.popup.bind("activate",(()=>{e.filterInput.val(e.element.val()),e.filterInput.trigger("focus")})),e.popup.bind("deactivate",(()=>{e.element.trigger("focus")})))},_onCloseButtonPressed:function(){var e=this;e.filterInput&&a()===e.filterInput[0]&&e.element.val(e.filterInput.val())},_popup:function(){c.fn._popup.call(this),this.popup.element.addClass("k-autocomplete-popup")},_dataSource:function(){var e=this;e.dataSource&&e._refreshHandler?e._unbindDataSource():(e._progressHandler=e._showBusy,e._errorHandler=e._hideBusy),e.dataSource=u.create(e.options.dataSource).bind("progress",e._progressHandler).bind("error",e._errorHandler)},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.listView.setDataSource(this.dataSource)},events:["open","close",f,"select","filtering","dataBinding","dataBound"],setOptions:function(e){var t=this._listOptions(e);c.fn.setOptions.call(this,e),this.listView.setOptions(t),this._accessors(),this._aria(),this._clearButton()},_listOptions:function(t){var n=c.fn._listOptions.call(this,e.extend(t,{skipUpdateOnBind:!0}));return n.dataValueField=n.dataTextField,n.selectedItemChange=null,n},_editable:function(e){var t=this,n=t.element,i=t.wrapper.off(b),r=e.readonly,o=e.disable;r||o?(i.addClass(o?_:"").removeClass(o?"":_),n.attr(m,o).attr(g,r).attr(h,o).attr(p,r)):(i.removeClass(_).on(y,t._toggleHover),n.prop(m,!1).prop(g,!1).attr(h,!1).attr(p,!1)),t._toggleCloseVisibility()},close:function(){var e=this,t=e.listView.focus();t&&t.removeClass("k-selected"),e.popup.close(),e._deactivateItem()},destroy:function(){var e=this;e.element.off(b),e._clear.off(b),e.wrapper.off(b),e.filterInput&&e.filterInput.off(b),c.fn.destroy.call(e)},refresh:function(){this.listView.refresh()},select:function(e){this._select(e)},search:function(e){let t,n,i=this,r=i.options,s=r.ignoreCase,l=i._separator(),c=i.dataSource.options.accentFoldingFiltering,d=i.filterInput&&a()===i.filterInput[0]?i.filterInput:i.element;e=e||i._accessor(),clearTimeout(i._typingTimeout),l&&(e=function(e,t,n){return t.split(n)[w(e,t,n)]}(o(d)[0],e,l)),t=e.length,(!r.enforceMinLength&&!t||t>=r.minLength)&&(i._open=!0,i._mute((function(){this.listView.value([])})),n=c?e.toLocaleLowerCase(c):e.toLowerCase(),i._filterSource({value:s?n:e,operator:r.filter,field:r.dataTextField,ignoreCase:s}),i.one("close",i._unifySeparators.bind(i))),i._toggleCloseVisibility()},suggest:function(e){var n,i=this,r=i._last,s=i._accessor(),l=i.value(),u=i.element[0],h=o(u)[0],p=i._separator(),f=s.split(p),m=w(h,s,p),g=h,v=i.dataSource.options.accentFoldingFiltering;if(r!=d.BACKSPACE&&r!=d.DELETE){if("string"!=typeof(e=e||"")&&(e[0]&&(e=i.dataSource.view()[c.inArray(e[0],i.ul[0])]),e=e?i._text(e):""),h<=0&&(h=(v?s.toLocaleLowerCase(v):s.toLowerCase()).indexOf(v?e.toLocaleLowerCase(v):e.toLowerCase())+1),n=(n=s.substring(0,h).lastIndexOf(i._defaultSeparator()))>-1?h-(n+i._defaultSeparator().length):h,s=f[m].substring(0,n),e&&(e=e.toString(),(n=(v?e.toLocaleLowerCase(v):e.toLowerCase()).indexOf(v?s.toLocaleLowerCase(v):s.toLowerCase()))>-1&&(g=h+(e=e.substring(n+s.length)).length,s+=e),p&&""!==f[f.length-1]&&f.push("")),f[m]=s,"object"==typeof i.options.separator&&null!=i.options.separator)if(l.length>1){let e=[...l.matchAll(p.source)].pop();e?i._accessor(f.slice(0,-1).join(i._defaultSeparator()||"")+e+f[f.length-1]):i._accessor(f.slice(0,-1).join(i._defaultSeparator()||""))}else i._accessor(f.join(this._defaultSeparator()||""));else i._accessor(f.join(p||""));u===a()&&o(u,h,g)}else i._last=t},value:function(e){if(e===t)return this._accessor();this.listView.value(e),this._accessor(e),this._old=this._accessor(),this._oldText=this._accessor(),this._toggleCloseVisibility(),this._refreshFloatingLabel()},_click:function(e){var t=e.item,n=this,i=n.element,r=n.listView.dataItemByIndex(n.listView.getElementIndex(t));e.preventDefault(),n._active=!0,n.trigger("select",{dataItem:r,item:t})?n.close():(n._oldText=i.val(),n._select(t).done((function(){n._blur(),o(i,i.val().length)})))},_clearText:e.noop,_highlightFirst:function(){var e=this.options.highlightFirst?0:-1;this.listView.focus(e)},_resetFocusItem:function(){this.options.virtual&&this.listView.scrollTo(0),this._highlightFirst()},_listBound:function(){var e,n=this,i=n.popup,r=n.options,o=n.dataSource.flatView(),s=o.length,l=n.dataSource._group?n.dataSource._group.length:0,c=n.element[0]===a()||n.filterInput&&n.filterInput[0]===a();n._renderFooter(),n._renderNoData(),n._toggleNoData(!s),n._toggleHeader(!!l&&!!s),n._resizePopup(),i.position(),s&&(r.suggest&&c&&n._inputValue()&&n.suggest(o[0]),n._highlightFirst()),n._open&&(n._open=!1,e=n._allowOpening()?"open":"close",n._typingTimeout&&!c&&(e="close"),s&&(n._resetFocusItem(),r.virtual&&n.popup.unbind("activate",n._resetFocusItemHandler).one("activate",n._resetFocusItemHandler)),i[e](),n._typingTimeout=t),n._touchScroller&&n._touchScroller.reset(),n._hideBusy(),n.trigger("dataBound")},_mute:function(e){this._muted=!0,e.call(this),this._muted=!1},_listChange:function(){(this._active||this.element[0]===a())&&!this._muted&&this._selectValue(this.listView.selectedDataItems()[0])},_selectValue:function(e){var t=this._separator(),n="";e&&(n=this._text(e)),null===n&&(n=""),t&&(n=function(e,t,n,i,r){var o=t.split(i);return o.splice(w(e,t,i),1,n),i&&""!==o[o.length-1]&&o.push(""),o.join(r)}(o(this.element)[0],this._accessor(),n,t,this._defaultSeparator())),this._prev=n,this._accessor(n),this._placeholder()},_unifySeparators:function(){return this._accessor(this.value().split(this._separator()).join(this._defaultSeparator())),this},_preselect:function(e,t){this._inputValue(t),this._accessor(e),this._old=this.oldText=this._accessor(),this.listView.setValue(e),this._placeholder()},_change:function(){var e=this,t=e._unifySeparators().value(),n=t!==c.unifyType(e._old,typeof t),i=n&&!e._typing,r=e._oldText!==t,o=e._clearValueTrigger;e._old=t,e._oldText=t,e.filterInput&&a()===e.filterInput[0]&&e.element.val(e.filterInput.val()),!i&&!r||o||e.element.trigger(f),n&&!o&&e.trigger(f),e.typing=!1,e._toggleCloseVisibility()},_accessor:function(e){var n=this,i=n.filterInput&&a()===n.filterInput[0]?n.filterInput[0]:n.element[0];if(e===t)return e=i.value,i.className.indexOf("k-readonly")>-1&&e===n.options.placeholder?"":e;i.value=null===e?"":e,n._placeholder()},_keydown:function(e){var t=this,n=e.keyCode,i=t.listView,r=t.popup.visible(),o=i.focus();if(t._last=n,n===d.DOWN)r?this._move(o?"focusNext":"focusFirst"):t.value()&&t._filterSource({value:t.ignoreCase?t.value().toLowerCase():t.value(),operator:t.options.filter,field:t.options.dataTextField,ignoreCase:t.ignoreCase}).done((function(){t._allowOpening()&&(t._resetFocusItem(),t.popup.open())})),e.preventDefault();else if(n===d.ESC)r?(e.preventDefault(),t.close()):t._clearValue();else if(e.altKey&&n===d.UP&&r)e.preventDefault(),t.close();else if(n===d.UP)r&&this._move(o?"focusPrev":"focusLast"),e.preventDefault();else if(n===d.HOME)this._move("focusFirst");else if(n===d.END)this._move("focusLast");else if(n===d.ENTER||n===d.TAB){if(n===d.ENTER&&r&&e.preventDefault(),r&&o){var a=i.dataItemByIndex(i.getElementIndex(o));if(t.trigger("select",{dataItem:a,item:o}))return;this._select(o)}this._blur()}else if(!t.popup.visible()||n!==d.PAGEDOWN&&n!==d.PAGEUP)t.popup._hovered=!0,t._search();else{e.preventDefault();var s=n===d.PAGEDOWN?1:-1;i.scrollWith(s*i.screenHeight())}},_keypress:function(){this._oldText=this.element.val(),this._typing=!0},_move:function(e){if(this.listView[e](),this.options.suggest&&null==this.listView.focus()&&"focusNext"==e)this.listView.focus(0),this.suggest(this.listView._view[0].item);else if(this.options.suggest&&null==this.listView.focus()&&"focusPrev"==e){let e=this.listView._view.length-1;this.listView.focus(e),this.suggest(this.listView._view[e].item)}else!this.options.suggest||"focusFirst"!=e&&"focusLast"!=e?this.options.suggest&&null!=this.listView.focus()&&this.suggest(this.listView.focus()):o(this.element)},_placeholder:function(e){if(!s){var n,i=this,r=i.element,a=i.options.placeholder;if(a){if(n=r.val(),e===t&&(e=!n),e||(a=n!==a?n:""),n===i._old&&!e)return;r.toggleClass("k-readonly",e).val(a),a||r[0]!==document.activeElement||o(r[0],0,0)}}},_separator:function(){var e=this.options.separator;return e instanceof Array?new RegExp(e.join("|"),"gi"):e},_defaultSeparator:function(){var e=this.options.separator;return e instanceof Array?e[0]:e},_inputValue:function(){return this.element.val()},_search:function(){var e=this;clearTimeout(e._typingTimeout),e._typingTimeout=setTimeout((function(){e._prev!==e._accessor()&&(e._prev=e._accessor(),e.search())}),e.options.delay)},_select:function(e){var t=this;return t._active=!0,t.listView.select(e).done((function(){t._active=!1}))},_clearButton:function(){c.fn._clearButton.call(this),this.options.clearButton&&this._clear.insertAfter(this.element)},_toggleHover:function(t){e(t.currentTarget).toggleClass("k-hover","mouseenter"===t.type)},_toggleCloseVisibility:function(){var e=this.element.is(":disabled")||this.element.is("[readonly]");this.value()&&!e?this._showClear():this._hideClear()},_wrapper:function(){var e,t=this,n=t.element,i=n[0];(e=n.parent()).is("span.k-autocomplete")||(e=n.wrap("<span />").parent()),e.attr("tabindex",-1),e[0].style.cssText=i.style.cssText,n.css({width:"",height:i.style.height}),t._focused=t.element,t.wrapper=e.addClass("k-autocomplete k-input").addClass(i.className).removeClass("input-validation-error")},_clearValue:function(){this._clearValueTrigger=!1,c.fn._clearValue.call(this),this.element.trigger("focus")}});l.plugin(k),n.cssProperties.registerPrefix("AutoComplete","k-input-"),n.cssProperties.registerValues("AutoComplete",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}])}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=e.extend,r="visibility",o="k-drag-status",a=`<span class="${o}"></span>`,s="k-hover";n.HierarchicalDragAndDrop=t.Class.extend({init:function(r,o){this.element=r,this.hovered=r,this.options=i({dragstart:e.noop,drag:e.noop,drop:e.noop,dragend:e.noop},o),this._draggable=new n.Draggable(r,{ignore:"input,a:not(.k-treeview-leaf),textarea,.k-multiselect-wrap,select,button,a.k-button>.k-icon,.k-button>.k-button-text,button.k-button>.k-icon,span.k-toggle-icon,a.k-button>.k-svg-icon,button.k-button>.k-svg-icon,.k-button>.k-svg-icon>svg,.k-button>.k-svg-icon>svg>path",filter:o.filter,autoScroll:o.autoScroll,cursorOffset:{left:10,top:t.support.mobileOS?-40/t.support.zoomLevel():10},hint:this._hint.bind(this),dragstart:this.dragstart.bind(this),dragcancel:this.dragcancel.bind(this),hintDestroyed:this.dragcancel.bind(this),drag:this.drag.bind(this),dragend:this.dragend.bind(this),holdToDrag:o.holdToDrag,clickMoveClick:o.clickMoveClick})},_hint:function(e){return"<div class='k-drag-clue'>"+a+this.options.hintText(e)+"</div>"},_removeTouchHover:function(){t.support.touch&&this.hovered&&(this.hovered.find("."+s).removeClass(s),this.hovered=!1)},_hintStatus:function(e){var t=this._draggable.hint.find(`.${o}`);e?(this.status=e,n.icon(t,{icon:e})):(this.status="",t.replaceWith(a))},dragstart:function(t){this.dropHint&&this.dropHint.remove(),this.source=t.currentTarget.closest(this.options.itemSelector),this.options.dragstart(this.source)&&t.preventDefault(),this.options.reorderable?this.dropHint=e("<div class='k-drop-hint k-drop-hint-h'><div class='k-drop-hint-start'></div><div class='k-drop-hint-line'></div></div>").css(r,"hidden").appendTo(this.element):this.dropHint=e()},drag:function(n){var i,o,a,l,c,d,u,h,p,f,m,g=this.options,v=this.source,_=this.dropTarget=e(t.eventTarget(n)),b=_.closest(g.allowedContainers);b.length?v[0]==_[0]||g.contains(v[0],_[0])||n.clickMoveClick&&n.currentTarget.hasClass("k-drag-cell")&&0===_.closest(".k-drag-cell").length||n.clickMoveClick&&n.currentTarget.hasClass("k-treeview-leaf")&&0===_.closest(".k-treeview-leaf").length?m="cancel":(m="insert-middle",(i=(p=g.itemFromTarget(_)).item).length?(this._removeTouchHover(),o=t._outerHeight(i),l=p.content,g.reorderable?(c=o/(l.length>0?4:2),a=t.getOffset(i).top,d=n.y.location<a+c,u=a+o-c<n.y.location,h=l.length&&!d&&!u):(h=!0,d=!1,u=!1),this.hovered=!!h&&b,this.dropHint.css(r,h?"hidden":"visible"),this._lastHover&&this._lastHover[0]!=l[0]&&this._lastHover.removeClass(s),this._lastHover=l.toggleClass(s,h),h?m="plus":((f=i.position()).top+=d?0:o,this.dropHint.css(f)[d?"prependTo":"appendTo"](g.dropHintContainer(i)),d&&p.first&&(m="insert-top"),u&&p.last&&(m="insert-bottom"))):_[0]!=this.dropHint[0]&&(this._lastHover&&this._lastHover.removeClass(s),m=e.contains(this.element[0],b[0])?"cancel":"plus")):(m="cancel",this._removeTouchHover()),this.options.drag({originalEvent:n.originalEvent,source:v,target:_,pageY:n.y.location,pageX:n.x.location,status:m,setStatus:function(e){m=e}}),0!==m.indexOf("insert")&&this.dropHint.css(r,"hidden"),this._hintStatus(m)},dragcancel:function(){this.dropHint&&this.dropHint.remove()},dragend:function(n){var i,o,a,l,c="over",d=this.source,u=this.dropHint,h=this.dropTarget||e(t.eventTarget(n));u&&"visible"==u.css(r)?(c=this.options.dropPositionFrom(u),i=u.closest(this.options.itemSelector),l=!0):h&&((i=h.closest(this.options.itemSelector)).length||(i=h.closest(this.options.allowedContainers))),!l||i.length?(o={originalEvent:n.originalEvent,source:d[0],destination:i[0],valid:"cancel"!=this.status,setValid:function(e){this.valid=e},dropTarget:h[0],position:c},a=this.options.drop(o),u.remove(),this._removeTouchHover(),this._lastHover&&this._lastHover.removeClass(s),o.valid&&!a?(this._draggable.dropped=!0,this.options.dragend({originalEvent:n.originalEvent,source:d,destination:i,position:c})):this._draggable.dropped=o.valid):this.dragcancel()},destroy:function(){this._lastHover=this.hovered=null,this._draggable.destroy()}})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.html.HTMLBase,r=i.extend({init:function(e,t){var n=this;i.fn.init.call(n,e,t),n._wrapper(),n._addClasses()},options:{label:null,labelPosition:"after",labelId:null,encoded:!0},_wrapper:function(){var t=this,i=t.element[0],r=t.options,o=i.id;t.wrapper=t.element.addClass(r.inputClass).prop("type",r.type),!o&&r.label&&(i.id=o=n.guid()),r.label&&(t.labelEl=e("<label for='"+o+"' class='"+r.labelClass+"'>"),r.encoded?t.labelEl.text(r.label):t.labelEl.html(r.label),r.labelId&&t.labelEl.attr("id",r.labelId),r.optional&&t.labelEl.append("<span class='"+r.optionalClass+"'>"+r.optionalText+"</span>"),t.element[r.labelPosition](t.labelEl))},html:function(){var e=this,t="after"===e.options.labelPosition,n=i.fn.html.call(e);return e.labelEl?t?n+e.labelEl[0].outerHTML:e.labelEl[0].outerHTML+n:n}}),o=r.extend({init:function(e,t){r.fn.init.call(this,e,t),this._addClasses()},options:{name:"HTMLCheckBox",inputClass:"k-checkbox",labelClass:"k-checkbox-label",optionalClass:"k-label-optional",optionalText:"(Optional)",type:"checkbox",rounded:"medium",size:"medium",stylingOptions:["size","rounded"]}}),a=r.extend({init:function(e,t){r.fn.init.call(this,e,t),this._addClasses()},options:{name:"HTMLRadioButton",inputClass:"k-radio",labelClass:"k-radio-label",optionalClass:"k-label-optional",optionalText:"(Optional)",type:"radio",size:"medium",stylingOptions:["size"]}});e.extend(n.html,{renderCheckBox:function(n,i){return(arguments[0]===t||e.isPlainObject(arguments[0]))&&(i=n,n=e("<input />")),new o(n,i).html()},renderRadioButton:function(n,i){return(arguments[0]===t||e.isPlainObject(arguments[0]))&&(i=n,n=e("<input />")),new a(n,i).html()},HTMLInput:r,HTMLCheckBox:o,HTMLRadioButton:a}),n.cssProperties.registerPrefix("HTMLCheckBox","k-checkbox-"),n.cssProperties.registerValues("HTMLCheckBox",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),n.cssProperties.registerPrefix("HTMLRadioButton","k-radio-")}(window.kendo.jQuery);kendo;!function(e,t){var n,i,r,o,a,s=window.kendo,l=s.ui,c=s.data,d=s.htmlEncode,u=e.extend,h=s.template,p=Array.isArray,f=l.Widget,m=c.HierarchicalDataSource,g=s.keys,v=".kendoTreeView",_=".kendoTreeViewTemp",b="select",y="check",w="navigate",k="change",x="error",C="checked",S="indeterminate",T="dragstart",D="progress",A="drag",M="drop",E="dragend",I="dataBound",z="itemsLoaded",P="loadCompleted",H="requestEnd",F="click",R="undefined",L="k-hover",B="k-treeview",O=".k-treeview-item",V="k-icon",N="<span></span>",$="string",U="aria-checked",W="aria-selected",j="aria-disabled",q="aria-expanded",G="aria-activedescendant",K="aria-busy",Y="k-disabled",Q={text:"dataTextField",url:"dataUrlField",spriteCssClass:"dataSpriteCssClassField",imageUrl:"dataImageUrlField",attr:"dataAttrField",imageAttr:"dataImageAttrField",contentAttr:"dataContentAttrField",linkAttr:"dataLinkAttrField"},X=function(e){return"object"==typeof HTMLElement?e instanceof HTMLElement:e&&"object"==typeof e&&1===e.nodeType&&typeof e.nodeName===$};const Z="k-treeview-item",J="k-image",ee="k-treeview-leaf-text";function te(e){return function(t){var n=t.children(".k-animation-container");return n.length||(n=t),n.children(e)}}function ne(e){return e.find(".k-checkbox-wrap:first input[type=checkbox]")}function ie(e){return function(t,n){var i,r=(n=n.closest(O)).parent();return r.parent().is("li")&&(i=r.parent()),this._dataSourceMove(t,r,i,(function(t,i){var r=this.dataItem(n),o=r&&n.parent().children().length!==r.parent().length?r.parent().indexOf(r):n.index();return this._insert(t.data(),i,o+e)}))}}function re(t){var n=t.children("div"),i=t.children("ul"),r=n.find(".k-treeview-toggle > span"),o=t.children("input[type=checkbox]"),l=n.children(".k-treeview-leaf");t.hasClass("k-treeview")||(n.length||(n=e("<div />").prependTo(t)),!r.length&&i.length?r=e(`<span class='k-treeview-toggle'>${N}</span>`).prependTo(n):i.length&&i.children().length||(r.parent().remove(),i.remove(),t.removeAttr(q)),o.length&&e("<span class='k-checkbox-wrap' />").appendTo(n).append(o),l.length||((l=t.children("a").eq(0).addClass("k-treeview-leaf k-link")).length||(l=e("<span class='k-treeview-leaf' />")),l.appendTo(n),n.length&&function(e,t){for(var n;e&&"ul"!=e.nodeName.toLowerCase();)n=e,e=e.nextSibling,3==n.nodeType&&(n.nodeValue=s.trim(n.nodeValue)),a.test(n.className)?t.insertBefore(n,t.firstChild):t.appendChild(n)}(n[0].nextSibling,l[0])))}i=te(".k-treeview-group"),r=te(".k-treeview-group,.k-content"),o=function(e){return e.children("div").find(".k-treeview-toggle > span:first")},a=/k-sprite/,n=s.ui.DataBoundWidget.extend({init:function(e,t){var n,i,r=this,o=t&&!!t.dataSource;p(t)&&(t={dataSource:t}),t&&typeof t.loadOnDemand==R&&p(t.dataSource)&&(t.loadOnDemand=!1),f.prototype.init.call(r,e,t),e=r.element,t=r.options,r._dataSourceUids={},i=e.is("ul")&&e||e.hasClass(B)&&e.children("ul"),(n=!o&&i.length)&&(t.dataSource.list=i),r._animation(),r._accessors(),r._templates(),e.hasClass(B)?(r.wrapper=e,r.root=e.children("ul").eq(0)):(r._wrapper(),i&&(r.root=e,r._group(r.wrapper))),r._applyCssClasses(),r._tabindex(),r.wrapper.find(">ul").attr("role","tree"),r._dataSource(n),r._attachEvents(),r._dragging(),n?r._syncHtmlAndDataSource():t.autoBind?(r._progress(!0),r.dataSource.fetch(this._attemptLoadCompleted.bind(this))):(r._progressHandler=r._requestStart.bind(r),r.dataSource.bind(D,r._progressHandler)),t.checkboxes&&t.checkboxes.checkChildren&&r.updateIndeterminate(),r.element[0].id?r._ariaId=s.format("{0}_tv_active",r.element[0].id):r._ariaId=s.guid()+"_tv_active",s.notify(r)},_attachEvents:function(){var t=this,n=".k-treeview-leaf:not(.k-selected,.k-disabled)",i="mouseenter";t._clickHandler=t._click.bind(t),t.wrapper.on(i+v,".k-treeview-leaf.k-selected",(function(e){e.preventDefault()})).on(i+v,n,(function(){e(this).addClass(L)})).on("mouseleave"+v,n,(function(){e(this).removeClass(L)})).on(F+v,n,t._clickHandler).on("dblclick"+v,".k-treeview-leaf:not(.k-disabled)",t._toggleButtonClick.bind(t)).on(F+v,`.k-treeview-toggle .${V}`,t._toggleButtonClick.bind(t)).on("keydown"+v,t,t._keydown.bind(t)).on("keypress"+v,t._keypress.bind(t)).on("focus"+v,t._focus.bind(t)).on("blur"+v,t._blur.bind(t)).on("mousedown"+v,`.k-treeview-leaf,.k-checkbox-wrap :checkbox,.k-treeview-toggle .${V}`,t._mousedown.bind(t)).on("change"+v,".k-checkbox-wrap :checkbox",t._checkboxChange.bind(t)).on("click"+v,".k-request-retry",t._retryRequest.bind(t)).on("click"+v,".k-link.k-disabled",(function(e){e.preventDefault()})).on("click"+v,(function(n){var i=e(n.target);i.is(":kendoFocusable")||i.find("input,select,textarea,button,object").is(":kendoFocusable")||t.focus()}))},_requestStart:function(){this._progress(!0)},_syncHtmlAndDataSource:function(e,t){e=e||this.root;var n,i,r,o,a,l=(t=t||this.dataSource).view(),c=s.attr("uid"),d=s.attr("expanded"),u=this.options.checkboxes,h=e.children("li");for(n=0;n<h.length;n++)o=(r=l[n]).uid,(i=h.eq(n)).attr("role","treeitem").attr(c,o).attr(W,i.hasClass("k-selected")),r.expanded="true"===i.attr(d),r.hasChildren&&i.attr(q,r.expanded),u&&(a=ne(i),r.checked=a.prop(C),a.attr("id","_"+o),a.next(".k-checkbox-label").attr("for","_"+o),i.attr(U,i.checked)),this._syncHtmlAndDataSource(i.children("ul"),r.children)},_animation:function(){var e=this.options,t=e.animation,n=t.collapse&&"effects"in t.collapse,i=u({},t.expand,t.collapse);n||(i=u(i,{reverse:!0})),!1===t&&(t={expand:{effects:{}},collapse:{hide:!0,effects:{}}}),t.collapse=u(i,{hide:!0}),e.animation=t},_dragging:function(){var t=this.options.dragAndDrop,n=this.dragging;if(t&&!n){var i=this;this.dragging=new l.HierarchicalDragAndDrop(this.element,{reorderable:!0,autoScroll:this.options.autoScroll,filter:"div:not(.k-disabled) .k-treeview-leaf",allowedContainers:".k-treeview",itemSelector:".k-treeview .k-treeview-item",hintText:this._hintText.bind(this),clickMoveClick:!0===this.options.dragAndDrop.clickMoveClick,contains:function(t,n){return e.contains(t,n)},dropHintContainer:function(e){return e},itemFromTarget:function(e){var t=e.closest(".k-treeview-top,.k-treeview-mid,.k-treeview-bot");return{item:t,content:e.closest(".k-treeview-leaf"),first:t.hasClass("k-treeview-top"),last:t.hasClass("k-treeview-bot")}},dropPositionFrom:function(e){return e.prevAll(".k-treeview-leaf").length>0?"after":"before"},dragstart:function(e){return i.wrapper.attr(s.attr("scrollable"),!1),i.trigger(T,{sourceNode:e[0]})},drag:function(e){i.trigger(A,{originalEvent:e.originalEvent,sourceNode:e.source[0],dropTarget:e.target[0],pageY:e.pageY,pageX:e.pageX,statusClass:e.status,setStatusClass:e.setStatus})},drop:function(t){var n=e(t.dropTarget).closest("a");return n&&n.attr("href")&&i._tempPreventNavigation(n),i.trigger(M,{originalEvent:t.originalEvent,sourceNode:t.source,destinationNode:t.destination,valid:t.valid,setValid:function(e){this.valid=e,t.setValid(e)},dropTarget:t.dropTarget,dropPosition:t.position})},dragend:function(e){var t=e.source,n=e.destination,r=e.position;function o(t){i.options.checkboxes&&i.options.checkboxes.checkChildren&&i.updateIndeterminate(),i.current(t),i.element.focus(),i.trigger(E,{originalEvent:e.originalEvent,sourceNode:t&&t[0],destinationNode:n[0],dropPosition:r})}i.wrapper.removeAttr(s.attr("scrollable")),"over"==r?i.append(t,n,o):("before"==r?t=i.insertBefore(t,n):"after"==r&&(t=i.insertAfter(t,n)),o(t))}})}else!t&&n&&(n.destroy(),this.dragging=null)},_tempPreventNavigation:function(e){e.on(F+v+_,(function(t){t.preventDefault(),e.off(F+v+_)}))},_hintText:function(e){return this.templates.dragClue({item:this.dataItem(e),treeview:this.options})},_templates:function(){let t=this,n=t.options,i=t._fieldAccessor.bind(t);n.template&&typeof n.template==$?n.template=h(n.template):n.template||(n.template=({item:e})=>{let n=i("text")(e),r=i("contentAttr")(e);return void 0!==e.encoded&&!1===e.encoded?`<span ${t.templates.contentCssAttributes(r)}>${n}</span>`:`<span ${t.templates.contentCssAttributes(r)}>${d(n)}</span>`}),t._checkboxes(),t.templates={setAttributes:function(e){return t.templates.setDefaultClasses(Z,e.attr)},cssClass:function(e,t){var n="",i=t.index,r=e.length-1;return e.firstLevel&&0===i&&(n+="k-treeview-top "),n+=0===i&&i!=r?-1!=n.indexOf("k-treeview-top")?"":"k-treeview-top":i==r?"k-treeview-bot":"k-treeview-mid"},textClass:function(e,t){var n="k-treeview-leaf";return t&&(n+=" k-link"),!1===e.enabled&&(n+=" k-disabled"),!0===e.selected&&(n+=" k-selected"),n},checkboxClass:function(e){var t="k-checkbox";return!1===e.enabled&&(t+=" k-disabled"),t},toggleButtonClass:function(e){var t="k-treeview-toggle";return!1===e.enabled&&(t+=" k-disabled"),t},toggleIcon:function(e,n){return!0!==n.expanded?l.icon(e,{icon:"caret-alt-"+(s.support.isRtl(t.element)?"left":"right")}):l.icon(e,{icon:"caret-alt-down"})},groupAttributes:function(e){var t="";return e.firstLevel||(t="role='group'"),t+(!0!==e.expanded?` ${s.attr("style-display")}="none"`:"")},groupCssClass:function(e){var t="k-treeview-group";return e.firstLevel&&(t+=" k-treeview-lines"),t},dragClue:e=>e.treeview.template(e),group:e=>`<ul class='${e.r.groupCssClass(e.group)}'${e.r.groupAttributes(e.group)}>`+e.renderItems(e)+"</ul>",itemContent:e=>{let n=i("imageUrl")(e.item),r=i("imageAttr")(e.item),o=i("spriteCssClass")(e.item),a="";return n&&(a+=`<img ${t.templates.imageCssAttributes(r)} alt='' src='${n}'>`),o&&(a+=`<span class='k-sprite ${o}'></span>`),a+=e.treeview.template(e),a},itemElement:t=>{let n=t.item,r=t.r,o=i("url")(n),a=o?"a":"span",s=o?' href="'+o+'"':"",l=`<div class="${r.cssClass(t.group,n)}">`;return n.hasChildren&&(l+=`<span class='${r.toggleButtonClass(n)}'>`+r.toggleIcon(e(N),n)+"</span>"),t.treeview.checkboxes&&(l+="<span class='k-checkbox-wrap' role='presentation'>"+t.treeview.checkboxes.template(t)+"</span>"),l+=`<${a} ${r.linkCssAttributes(n,!!o)} ${s}>`+r.itemContent(t)+`</${a}>`,l+="</div>",l},item:e=>{var t=e.item,n=e.r,i=`<li role='treeitem'${s.attr("uid")}="${t.uid}"${n.setAttributes(t.toJSON?t.toJSON():t)} `;return e.treeview.checkboxes&&(i+=`aria-checked="${t.checked?"true":"false"}" `),i+=`aria-selected="${t.selected?"true":"false"}" `+(!1===t.enabled?'aria-disabled="true"':""),t.hasChildren&&(i+=`aria-expanded="${t.expanded?"true":"false"}" `),i+=`data-expanded="${t.expanded?"true":"false"}" >`+n.itemElement(e)+"</li>"},loading:({messages:e})=>`<div class='k-icon k-i-loading'></div> ${d(e.loading)}`,retry:({messages:e})=>`${d(e.requestFailed)} <button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-request-retry'><span class='k-button-text'>${d(e.retry)}</span></button>`,imageCssAttributes:function(e){return t.templates.setDefaultClasses(J,e)},contentCssAttributes:function(e){return t.templates.setDefaultClasses(ee,e)},linkCssAttributes:function(e,n){return t.templates.setDefaultClasses(this.textClass(e,n),i("linkAttr")(e))},setDefaultClasses:function(e,n){return(n=n&&n.toJSON?n.toJSON():n||{}).class?n.class+=" "+e:n.class=e,t.templates.stringifyAttributes(n)},stringifyAttributes:function(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t+=n+'="'+e[n]+'" ');return t}}},items:function(){return this.element.find(".k-treeview-item > div:first-child")},setDataSource:function(e){var t=this.options;t.dataSource=e,this._dataSourceUids={},this._dataSource(),t.checkboxes&&t.checkboxes.checkChildren&&this.dataSource.one("change",this.updateIndeterminate.bind(this,null)),this.options.autoBind&&this.dataSource.fetch(this._attemptLoadCompleted.bind(this))},_bindDataSource:function(){var e=this;e._refreshHandler=e.refresh.bind(e),e._errorHandler=e._error.bind(e),e._loadCompletedHandler=e._loadCompleted.bind(e),e._requestEndHandler=e._dsRequestEnd.bind(e),e._loadedNodes=[],e.dataSource.bind(k,e._refreshHandler),e.dataSource.bind(x,e._errorHandler),e.dataSource.bind(z,e._loadCompletedHandler),e.dataSource.bind(H,e._requestEndHandler)},_dsRequestEnd:function(e){var t=this;setTimeout((function(){"read"!==e.type||t._loadCompletedFired||t._attemptLoadCompleted()}))},_loadCompleted:function(e){var t=this;t._loadedNodes=t._loadedNodes.concat(e.nodes),t.dataSource.loading()||!1!==t.options.loadOnDemand||(t.trigger(P,{nodes:t._loadedNodes}),t._loadedNodes=[])},_attemptLoadCompleted:function(){var e,t,n=this,i=n.dataSource.view();if(!1===n.options.loadOnDemand){for(t=0;t<i.length;t++)if((e=i[t]).hasChildren&&(!e.children||!e.children.data()||0===e.children.data().length))return;n._loadCompletedFired=!0,n.trigger(P,{nodes:[]})}},_unbindDataSource:function(){var e=this.dataSource;e&&(e.unbind(k,this._refreshHandler),e.unbind(D,this._progressHandler),e.unbind(x,this._errorHandler),e.unbind(z,this._loadCompletedHandler),e.unbind(H,this._requestEndHandler))},_dataSource:function(e){var t=this,n=t.options.dataSource;n=p(n)?{data:n}:n,t._unbindDataSource(),n.fields||(n.fields=[{field:"text"},{field:"url"},{field:"spriteCssClass"},{field:"imageUrl"}]),t.dataSource=n=m.create(n),e&&(n.fetch(),function e(t){for(var n=0;n<t.length;n++)t[n]._initChildren(),t[n].children.fetch(),e(t[n].children.view())}(n.view())),t._bindDataSource()},events:[T,A,M,E,I,P,"expand","collapse",b,k,w,y,"kendoKeydown"],options:{name:"TreeView",dataSource:{},animation:{expand:{effects:"expand:vertical",duration:200},collapse:{duration:100}},messages:{loading:"Loading...",requestFailed:"Request failed.",retry:"Retry"},dragAndDrop:!1,checkboxes:!1,autoBind:!0,autoScroll:!1,loadOnDemand:!0,template:"",dataTextField:null,size:"medium"},_accessors:function(){var e,t,n,i=this.options,r=this.element;for(e in Q)t=i[Q[e]],n=r.attr(s.attr(e+"-field")),!t&&n&&(t=n),t||(t=e),p(t)||(t=[t]),i[Q[e]]=t},_fieldAccessor:function(t){var n=this.options[Q[t]],i=n.length;return function(r){return 0===i?s.getter(t)(r):e.map(n,(function(e){return function(t){return s.getter(e)(t)}}))[Math.min(r.level(),i-1)](r)}},setOptions:function(e){f.fn.setOptions.call(this,e),this._animation(),this._dragging(),this._accessors(),this._templates()},_trigger:function(e,t){return this.trigger(e,{node:t.closest(O)[0]})},_setChecked:function(e,t){if(e&&s.isFunction(e.view))for(var n=0,i=e.view();n<i.length;n++)!1!==i[n].enabled&&this._setCheckedValue(i[n],t),i[n].children&&this._setChecked(i[n].children,t)},_setCheckedValue:function(e,t){e[C]=t},_setIndeterminate:function(e){var t,n,r,o=i(e),a=!0;if(o.length&&(n=(t=ne(o.children())).length)){if(n>1){for(r=1;r<n;r++)if(t[r].checked!=t[r-1].checked||t[r].indeterminate||t[r-1].indeterminate){a=!1;break}}else a=!t[0].indeterminate;return e.attr(U,a?t[0].checked:"mixed"),ne(e).data(S,!a).prop(S,!a).prop(C,a&&t[0].checked)}},updateIndeterminate:function(e){e=e||this.wrapper;var t,n,r,o=i(e).children();if(o.length){for(t=0;t<o.length;t++)this.updateIndeterminate(o.eq(t));if(e.is(".k-treeview"))return;n=this._setIndeterminate(e),r=this.dataItem(e),n&&n.prop(C)?r.checked=!0:r&&delete r.checked}},_bubbleIndeterminate:function(e,t){if(e.length){t||this.updateIndeterminate(e);var n,i=this.parent(e);i.length&&(this._setIndeterminate(i),n=i.children("div").find(".k-checkbox-wrap input[type=checkbox]"),this._skip=!0,!1===n.prop(S)?this.dataItem(i).set(C,n.prop(C)):this.dataItem(i).set(C,!1),this._skip=!1,this._bubbleIndeterminate(i,!0))}},_checkboxChange:function(t){var n=e(t.target),i=n.prop(C),r=n.closest(O),o=this.dataItem(r);this._preventChange||(o.checked!=i&&(o.set(C,i),r.attr(U,i),this._trigger(y,r)),n.is(":focus")&&(this._trigger(w,r),this.focus()))},_toggleButtonClick:function(t){var n=e(t.currentTarget).closest(O);n.is("[aria-disabled='true']")||this.toggle(n)},_mousedown:function(t){var n=this,i=e(t.currentTarget),r=e(t.currentTarget).closest(O),o=s.support.browser;r.is("[aria-disabled='true']")||((o.msie||o.edge)&&i.is(":checkbox")&&(i.prop(S)?(n._preventChange=!1,i.prop(C,!i.prop(C)),i.trigger(k),i.on(F+v,(function(e){e.preventDefault()})),n._preventChange=!0):(i.off(F+v),n._preventChange=!1)),n._clickTarget=r,n.current(r))},_focusable:function(e){return e&&e.length&&e.is(":visible")&&!e.find(".k-treeview-leaf").first().hasClass(Y)},_focus:function(){var t=this.select(),n=this._clickTarget;s.support.touch||(n&&n.length&&(t=n),this._focusable(t)||(t=this.current()),this._focusable(t)||(t=this._nextVisible(e())),this.current(t))},focus:function(){var e,t=this.wrapper,n=t[0],i=[],r=[],o=document.documentElement;do{(n=n.parentNode).scrollHeight>n.clientHeight&&(i.push(n),r.push(n.scrollTop))}while(n!=o);for(s.focusElement(t),e=0;e<i.length;e++)i[e].scrollTop=r[e]},_blur:function(){this.current().find(".k-treeview-leaf").first().removeClass("k-focus")},_enabled:function(e){return!e.children("div").children(".k-treeview-leaf").hasClass(Y)},parent:function(t){var n,i,r=/\bk-treeview\b(?!-)/,o=/\bk-treeview-item\b/;typeof t==$&&(t=this.element.find(t)),X(t)||(t=t[0]),i=o.test(t.className);do{t=t.parentNode,o.test(t.className)&&(i?n=t:i=!0)}while(!r.test(t.className)&&!n);return e(n)},_nextVisible:function(e){var t,n=this,r=n._expanded(e);function o(e){for(;e.length&&!e.next().length;)e=n.parent(e);return e.next().length?e.next():e}return e.length&&e.is(":visible")?r&&(t=i(e).children().first()).length||(t=o(e)):t=n.root.children().eq(0),t},_previousVisible:function(e){var t,n,r=this;if(!e.length||e.prev().length)for(n=e.length?e.prev():r.root.children().last();r._expanded(n)&&(t=i(n).children().last()).length;)n=t;else n=r.parent(e)||e;return n},scrollTo:function(e){e&&e.length>0&&e[0].scrollIntoView({block:"nearest"})},_keydown:function(n){var i,r=this,o=n.keyCode,a=r.current(),l=r._expanded(a),c=a.find(".k-checkbox-wrap").first().find(":checkbox"),d=s.support.isRtl(r.element);n.target==n.currentTarget&&(!d&&o==g.RIGHT||d&&o==g.LEFT?l?i=r._nextVisible(a):a.find(".k-treeview-leaf").first().hasClass(Y)||r.expand(a):!d&&o==g.LEFT||d&&o==g.RIGHT?l&&!a.find(".k-treeview-leaf").first().hasClass(Y)?r.collapse(a):(i=r.parent(a),r._enabled(i)||(i=t)):o==g.DOWN?i=r._nextVisible(a):o==g.UP?i=r._previousVisible(a):o==g.HOME?i=r._nextVisible(e()):o==g.END?i=r._previousVisible(e()):o!=g.ENTER||a.find(".k-treeview-leaf").first().hasClass(Y)?o==g.SPACEBAR&&c.length&&(a.find(".k-treeview-leaf").first().hasClass(Y)||(c.prop(C,!c.prop(C)).data(S,!1).prop(S,!1),r._checkboxChange({target:c})),i=a):a.find(".k-treeview-leaf").first().hasClass("k-selected")||r._trigger(b,a)||r.select(a),i&&(n.preventDefault(),a[0]!=i[0]&&(r._trigger(w,i),r.current(i),r.scrollTo(i))))},_keypress:function(e){var t,n=this,i=n.current().get(0),r=e.key;1===r.length&&(n._match||(n._match=""),n._match+=r,clearTimeout(n._matchTimer),n._matchTimer=setTimeout((function(){n._match=""}),300),(t=i&&n._matchNextByText(Array.prototype.indexOf.call(n.element.find(".k-treeview-item"),i),n._match)).length||(t=n._matchNextByText(-1,n._match)),t.get(0)&&t.get(0)!==i&&(n._trigger(w,t),n.current(t)))},_matchNextByText:function(t,n){return this.element.find(".k-treeview-leaf").filter((function(i,r){return i>t&&e(r).is(":visible")&&0===e(r).text().toLowerCase().indexOf(n)})).eq(0).closest(O)},_click:function(t){var n=e(t.currentTarget),i=r(n.closest(O)),o=n.attr("href");(o?"#"==o||o.indexOf("#"+this.element.id+"-")>=0:i.length&&!i.children().length)&&t.preventDefault(),n.hasClass(".k-selected")||this._trigger(b,n)||this.select(n)},_wrapper:function(){var e,t,n=this,i=n.element;i.is("ul")?(e=i.wrap("<div />").parent(),t=i):t=(e=i).children("ul").eq(0),n.wrapper=e.addClass("k-treeview"),n.root=t},_getSelectedNode:function(){return this.element.find(".k-selected").closest(O)},_group:function(e){var t=this,n=e.hasClass(B),i={firstLevel:n,expanded:n||t._expanded(e)},r=e.children("ul");r.addClass(t.templates.groupCssClass(i)).css("display",i.expanded?"":"none"),n||r.attr("role","group"),t._nodes(r,i)},_nodes:function(t,n){var i,r=this,o=t.children("li");n=u({length:o.length},n),o.each((function(t,o){o=e(o),i={index:t,expanded:r._expanded(o)},re(o),r._updateNodeClasses(o,n,i),r._group(o)}))},_checkboxes:function(){var t,n=this.options,i=n.checkboxes;i&&(t=(t=s.html.renderCheckBox(e("<input/>"),e.extend({},n,{rounded:"medium"}))).replace(">",""),typeof(i=u({template:({item:e})=>t+` id="_${e.uid}" aria-hidden="true" type="checkbox" tabindex="-1"`+(i.name?'name="'+i.name+'"':"")+" "+(!1===e.enabled?"disabled":"")+" "+(e.checked?"checked":"")+"/>"},n.checkboxes)).template==$&&(i.template=h(i.template)),n.checkboxes=i)},_updateNodeClasses:function(e,t,n){var i=e.children("div"),r=e.children("ul"),o=this.templates;if(!e.hasClass("k-treeview")){(n=n||{}).expanded=typeof n.expanded!=R?n.expanded:this._expanded(e),n.index=typeof n.index!=R?n.index:e.index(),n.enabled=typeof n.enabled!=R?n.enabled:!i.children(".k-treeview-leaf").hasClass("k-disabled"),(t=t||{}).firstLevel=typeof t.firstLevel!=R?t.firstLevel:e.parent().parent().hasClass(B),t.length=typeof t.length!=R?t.length:e.parent().children().length,e.addClass("k-treeview-item"),i.removeClass("k-treeview-top k-treeview-mid k-treeview-bot").addClass(o.cssClass(t,n)),i.find(".k-checkbox").removeClass("k-checkbox k-disabled").addClass(o.checkboxClass(n));var a=i.children(".k-treeview-leaf"),s=a[0]&&"a"==a[0].nodeName.toLowerCase();if(a.removeClass("k-treeview-leaf k-link k-disabled").addClass(o.textClass(n,s)),r.length||"true"==e.attr("data-hasChildren")){var l=i.find(".k-treeview-toggle"),c=l.children("span");l.removeClass("k-treeview-toggle k-disabled").addClass(o.toggleButtonClass(n)),o.toggleIcon(c,n),r.addClass("k-treeview-group")}}},_processNodes:function(t,n){for(var i=this.element.find(t),r=0;r<i.length;r++)n.call(this,r,e(i[r]).closest(O))},dataItem:function(t){var n=e(t).closest(O).attr(s.attr("uid")),i=this.dataSource;return i&&i.getByUid(n)},_dataItem:function(t){var n=e(t).closest(O).attr(s.attr("uid"));return this.dataSource&&this._dataSourceUids[n]},_insertNode:function(t,n,r,o,a){var l,c,d,u,h,p,f=this,m=i(r),g=m.children().length+1,v={firstLevel:r.hasClass(B),expanded:!a,length:g},_="",b=function(e,t){e.appendTo(t)};for(d=0;d<t.length;d++)(u=t[d]).index=n+d,_+=f._renderItem({group:v,item:u});if((c=e(_)).length){for(m.length||(m=e(f._renderGroup({group:v})),s.applyStylesFromKendoAttributes(m,["display"]),m.appendTo(r),r.attr(q,!0)),o(c,m),r.hasClass("k-treeview-item")&&(re(r),f._updateNodeClasses(r,v,{expanded:!a})),h=c.prev().first(),p=c.next().last(),f._updateNodeClasses(h,{},{expanded:"true"==h.attr(s.attr("expanded"))}),f._updateNodeClasses(p,{},{expanded:"true"==p.attr(s.attr("expanded"))}),d=0;d<t.length;d++)(u=t[d]).hasChildren&&(l=u.children.data()).length&&f._insertNode(l,u.index,c.eq(d),b,!u.expanded);return c}},_updateNodes:function(t,n){var i,o,a,c,d,u,h=this,p={treeview:h.options,item:c},f="expanded"!=n&&"checked"!=n;function m(e,t){e.is(".k-treeview-group")&&e.find(".k-treeview-item:not([aria-disabled])").attr(U,t),e.find(".k-checkbox-wrap input[type=checkbox]:not([disabled])").prop(C,t).data(S,!1).prop(S,!1)}if("selected"==n)c=t[0],(o=h.findByUid(c.uid)).find(".k-treeview-leaf").first().removeClass("k-hover").toggleClass("k-selected",c[n]).end(),c[n]&&h.current(o),o.attr(W,!!c[n]);else{var g=e.map(t,(function(e){return h.findByUid(e.uid).children("div")}));for(i=0;i<t.length;i++)p.item=c=t[i],o=(a=g[i]).parent(),f&&(s.unbind&&s.unbind(a),a.children(".k-treeview-leaf").html(h.templates.itemContent(p))),n==C?(m(a,d=c[n]),o.attr(U,d),h.options.checkboxes.checkChildren&&(m(o.children(".k-treeview-group"),d),h._setChecked(c.children,d),h._bubbleIndeterminate(o))):"expanded"==n?h._toggle(o,c,c[n]):"enabled"==n&&(o.find(".k-checkbox-wrap input[type=checkbox]").prop("disabled",!c[n]),u=!r(o).is(":visible"),o.removeAttr(j),c[n]||(c.selected&&c.set("selected",!1),c.expanded&&c.set("expanded",!1),u=!0,o.attr(W,!1).attr(j,!0)),h._updateNodeClasses(o,{},{enabled:c[n],expanded:!u})),a.length&&this.trigger("itemChange",{item:a,data:c,ns:l})}},_appendItems:function(e,t,n){var r=i(n).children(),o=!this._expanded(n);if(this.element===n){var a=this.dataSource.data(),s=this.dataSource.view(),l=s.length<a.length?s:a;e=l.indexOf(t[0])}else t.length&&(e=t[0].parent().indexOf(t[0]));typeof e==R&&(e=r.length),this._insertNode(t,e,n,(function(t,n){e>=r.length?t.appendTo(n):t.insertBefore(r.eq(e))}),o),this._updateNodeClasses(n,{},{expanded:!o}),o||i(n).css("display","block")},_refreshChildren:function(e,t,n){var r,o,a,s=this.options,c=s.loadOnDemand,d=s.checkboxes&&s.checkboxes.checkChildren;if(i(e).empty(),t.length)for(this._appendItems(n,t,e),o=i(e).children(),c&&d&&this._bubbleIndeterminate(o.last()),r=0;r<o.length;r++)a=o.eq(r),this.trigger("itemChange",{item:a.children("div"),data:t[r],ns:l});else re(e)},_refreshRoot:function(t){var n=this._renderGroup({items:t,group:{firstLevel:!0,expanded:!0}});if(this.root.length&&this.root[0].parentElement){var i=e(n);this.root.attr("class",i.attr("class")).html(i.html())}else this.root=this.wrapper.html(n).children("ul");for(var r=this.root.children(".k-treeview-item"),o=0;o<t.length;o++)this.trigger("itemChange",{item:r.eq(o),data:t[o],ns:l})},refresh:function(e){var n,i=e.node,r=e.action,o=e.items,a=this.wrapper,s=this.options,l=s.loadOnDemand,c=s.checkboxes&&s.checkboxes.checkChildren;if(!this._skip){for(n=0;n<o.length;n++)this._dataSourceUids[o[n].uid]=o[n];if(e.field){if(!o[0]||!o[0].level)return;return this._updateNodes(o,e.field)}if(i&&(a=this.findByUid(i.uid),this._progress(a,!1)),c&&"remove"!=r){var d=!1;for(n=0;n<o.length;n++)if("checked"in o[n]){d=!0;break}if(!d&&i&&i.checked)for(n=0;n<o.length;n++)o[n].checked=!0}if("add"==r?this._appendItems(e.index,o,a):"remove"==r?this._remove(this.findByUid(o[0].uid),!1):"itemchange"==r?this._updateNodes(o):"itemloaded"==r?this._refreshChildren(a,o,e.index):(this._refreshRoot(o),this.element.attr(K,!1)),"remove"!=r)for(n=0;n<o.length;n++)(!l||o[n].expanded||o[n]._loaded)&&o[n].load();this.wrapper.find(">ul").attr("role","tree"),this.trigger(I,{node:i?a:t}),this.dataSource.filter()&&this.options.checkboxes.checkChildren&&this.updateIndeterminate(a)}},_error:function(t){var n=t.node&&this.findByUid(t.node.uid),i=this.templates.retry({messages:this.options.messages});n?(this._progress(n,!1),this._expanded(n,!1),o(n).replaceWith(l.icon(e(N),{icon:"arrow-rotate-cw"})),t.node.loaded(!1)):(this._progress(!1),this.dataSource.data([]),this.element.html(i))},_retryRequest:function(e){e.preventDefault(),this.dataSource.fetch(this._attemptLoadCompleted.bind(this))},expand:function(e){this._processNodes(e,(function(e,t){this.toggle(t,!0)}))},collapse:function(e){this._processNodes(e,(function(e,t){this.toggle(t,!1)}))},enable:function(e,t){"boolean"==typeof e?(t=e,e=this.items()):t=2!=arguments.length||!!t,this._processNodes(e,(function(e,n){this.dataItem(n).set("enabled",t)}))},current:function(t){var n=this,i=n._current,r=n.element;return arguments.length>0&&t&&t.length?(i&&i.find(".k-treeview-leaf").first().removeClass("k-focus"),(i=n._current=e(t,r).closest(O)).find(".k-treeview-leaf").first().addClass("k-focus"),void n._updateActiveDescendant()):(i||(i=n._nextVisible(e())),i)},_updateActiveDescendant:function(){var e=this._current,t=e[0].id||this._ariaId,n=this.element.find("#"+this._ariaId);n.length>0&&n.removeAttr("id"),this.root.removeAttr(G),e.attr("id",t),this.root.attr(G,t)},select:function(t){var n=this,i=n.element;if(!arguments.length)return i.find(".k-selected").closest(O);t=e(t,i).closest(O),i.find(".k-selected").each((function(){var t=n.dataItem(this);t?(t.set("selected",!1),delete t.selected):e(this).removeClass("k-selected")})),t.length&&(n.dataItem(t).set("selected",!0),n._clickTarget=t),n.trigger(k)},_toggle:function(e,t,n){var i,o=this.options,a=r(e),s=n?"expand":"collapse";a.data("animating")||(i=t&&t.loaded(),n&&!i?(o.loadOnDemand&&this._progress(e,!0),a.remove(),t.load()):(this._updateNodeClasses(e,{},{expanded:n}),n||a.css("height",a.height()).css("height"),a.kendoStop(!0,!0).kendoAnimate(u({reset:!0},o.animation[s],{complete:function(){n&&a.css("height","")}}))))},toggle:function(t,n){t=e(t),o(t)&&(1==arguments.length&&(n=!this._expanded(t)),this._expanded(t,n))},destroy:function(){var e=this;f.fn.destroy.call(e),e.wrapper.off(v),e.wrapper.find(".k-checkbox-wrap :checkbox").off(v),e._clickHandler=null,e._unbindDataSource(),e.dragging&&e.dragging.destroy(),e._dataSourceUids={},s.destroy(e.element),e.root=e.wrapper=e.element=null},_expanded:function(e,t,n){var i,o=s.attr("expanded"),a=t,l=a?"expand":"collapse";if(e.children().hasClass("k-hidden")&&e.children().removeClass("k-hidden"),1==arguments.length)return i=this._dataItem(e),"true"===e.attr(o)||i&&i.expanded;i=this.dataItem(e),r(e).data("animating")||!n&&this._trigger(l,e)||(a?(e.attr(o,"true"),e.attr(q,"true")):(e.removeAttr(o),e.attr(q,"false")),i&&(i.set("expanded",a),a=i.expanded))},_progress:function(t,n){var i=this.element,r=this.templates.loading({messages:this.options.messages});1==arguments.length?((n=t)?i.html(r):i.empty(),this.element.attr(K,n)):(o(t).replaceWith(e(N).toggleClass("k-i-loading",n).toggleClass("k-icon",n)),t.attr(K,n))},text:function(e,t){var n=this.dataItem(e),i=this.options[Q.text],r=n.level(),o=i.length,a=i[Math.min(r,o-1)];if(!t)return n[a];n.set(a,t)},_objectOrSelf:function(t){return e(t).closest("[data-role=treeview]").data("kendoTreeView")||this},_dataSourceMove:function(t,n,i,r){var o,a=this._objectOrSelf(i||n),s=a.dataSource,l=e.Deferred().resolve().promise();return i&&i[0]!=a.element[0]&&((o=a.dataItem(i)).loaded()||(a._progress(i,!0),l=o.load()),i!=this.root&&((s=o.children)&&s instanceof m||(o._initChildren(),o.loaded(!0),s=o.children))),t=this._toObservableData(t),r.call(a,s,t,l)},_toObservableData:function(t){var n,i,r,o=t;return((r=t)instanceof s.jQuery||window.jQuery&&r instanceof window.jQuery||X(t))&&(n=this._objectOrSelf(t).dataSource,i=e(t).attr(s.attr("uid")),(o=n.getByUid(i))&&(o=n.remove(o))),o},_insert:function(e,t,n){t instanceof s.data.ObservableArray?t=t.toJSON():p(t)||(t=[t]);var i=e.parent();return i&&i._initChildren&&(i.hasChildren=!0,i._initChildren()),e.splice.apply(e,[n,0].concat(t)),this.findByUid(e[n].uid)},insertAfter:ie(1),insertBefore:ie(0),append:function(t,n,r){var o=this.root;if(!(n&&t instanceof jQuery&&n[0]===t[0]))return(n=n&&n.length?n:null)&&(o=i(n)),this._dataSourceMove(t,o,n,(function(t,i,o){var a,s=this;return o.done((function(){a=function(){n&&s._expanded(n,!0,!0);var e=t.data(),r=Math.max(e.length,0);return s._insert(e,i,r)}(),(r=r||e.noop)(a)})),a||null}))},_remove:function(t,n){var i,r,o,a=this;return(t=e(t,a.element)).attr("id")===a.root.attr(G)&&a.root.removeAttr(G),i=t.parent().parent(),r=t.prev(),o=t.next(),t[n?"detach":"remove"](),i.hasClass("k-treeview-item")&&(re(i),a._updateNodeClasses(i)),a._updateNodeClasses(r),a._updateNodeClasses(o),t},remove:function(e){var t=this.dataItem(e);t&&this.dataSource.remove(t)},detach:function(e){return this._remove(e,!0)},findByText:function(t){return e(this.element).find(".k-treeview-leaf").filter((function(n,i){return e(i).text()==t})).closest(O)},findByUid:function(t){for(var n,i=this.element.find(".k-treeview-item"),r=s.attr("uid"),o=0;o<i.length;o++)if(i[o].getAttribute(r)==t){n=i[o];break}return e(n)},expandPath:function(t,n){var i=this,r=t.slice(0),o=n||e.noop;function a(t){var n,r=e.Deferred(),o=i.dataSource.get(t),a=s.attr("expanded");return o?(n=i.findByUid(o.uid),o.loaded()?(o.set("expanded",!0),n.attr(a,!0),n.attr(q,!0),r.resolve()):(i._progress(n,!0),o.load().then((function(){o.set("expanded",!0),n.attr(a,!0),n.attr(q,!0),r.resolve()})))):r.resolve(),r.promise()}a(r[0]).then((function e(){r.shift(),r.length?a(r[0]).then(e):o.call(i)}))},_parentIds:function(e){for(var t=e&&e.parentNode(),n=[];t&&t.parentNode;)n.unshift(t.id),t=t.parentNode();return n},expandTo:function(e){e instanceof s.data.Node||(e=this.dataSource.get(e));var t=this._parentIds(e);this.expandPath(t)},_renderItem:function(e){return e.group||(e.group={}),e.treeview=this.options,e.r=this.templates,this.templates.item(e)},_renderGroup:function(e){var t=this;return e.renderItems=function(e){var n="",i=0,r=e.items,o=r?r.length:0,a=e.group;for(a.length=o;i<o;i++)e.group=a,e.item=r[i],e.item.index=i,n+=t._renderItem(e);return n},e.r=t.templates,t.templates.group(e)}}),s.cssProperties.registerPrefix("TreeView","k-treeview-"),l.plugin(n)}(window.kendo.jQuery);kendo;!function(e,t){var n,i=window.kendo,r=i.ui,o=i.keys,a="k-disabled",s="select",l="checked",c="indeterminate",d=r.TreeView;n=function(e){return function(t){var n=t.children(".k-animation-container");return n.length||(n=t),n.children(e)}}(".k-treeview-group");var u=d.extend({init:function(e,t,n){var i=this;i.dropdowntree=n,d.fn.init.call(i,e,t),i.dropdowntree._isMultipleSelection()&&i.wrapper.on("click.kendoTreeView",".k-treeview-leaf.k-selected",i._clickSelectedItem.bind(i))},_checkOnSelect:function(e){if(!e.isDefaultPrevented()){var t=this.dataItem(e.node);t.set("checked",!t.checked)}},_setCheckedValue:function(e,t){e.set(l,t)},_click:function(e){var t=this;t.dropdowntree._isMultipleSelection()&&t.one("select",t._checkOnSelect),d.fn._click.call(t,e)},_clickSelectedItem:function(t){var n=this,i=e(t.currentTarget);n.one("select",n._checkOnSelect),n._trigger(s,i)||n.dataItem(i).set("selected",!1)},defaultrefresh:function(e){var n,i=e.node,r=e.action,o=e.items,a=this.wrapper,s=this.options,l=s.loadOnDemand,c=s.checkboxes&&s.checkboxes.checkChildren;if(!this._skip){if(e.field){if(!o[0]||!o[0].level)return;return this._updateNodes(o,e.field)}if(i&&(a=this.findByUid(i.uid),this._progress(a,!1)),c&&"remove"!=r){var d=!1;for(n=0;n<o.length;n++)if("checked"in o[n]){d=!0;break}if(!d&&i&&i.checked)for(n=0;n<o.length;n++)o[n].checked=!0}if("add"==r?this._appendItems(e.index,o,a):"remove"==r?this._remove(this.findByUid(o[0].uid),!1):"itemchange"==r?this._updateNodes(o):"itemloaded"==r?this._refreshChildren(a,o,e.index):this._refreshRoot(o),"remove"!=r)for(n=0;n<o.length;n++)l&&!o[n].expanded||o[n].load();this.wrapper.find(">ul").attr("role","tree"),this.trigger("dataBound",{node:i?a:t}),this.dropdowntree._treeViewDataBound({node:i?a:t,sender:this}),this.options.checkboxes.checkChildren&&this.updateIndeterminate()}},_previousVisible:function(e){var t,i,r=this;if(!e.length||e.prev().length)for(i=e.length?e.prev():r.root.children().last();r._expanded(i)&&(t=n(i).children().last()).length;)i=t;else(i=r.parent(e)||e).length||(r.dropdowntree.checkAll&&r.dropdowntree.checkAll.is(":visible")?r.dropdowntree.checkAll.find(".k-checkbox").trigger("focus"):r.dropdowntree.filterInput?r.dropdowntree.filterInput.trigger("focus"):r.dropdowntree.wrapper.trigger("focus"));return i},_keydown:function(n){var r,d=this,u=n.keyCode,h=d.current(),p=d._expanded(h),f=h.find(".k-checkbox-wrap").first().find(":checkbox"),m=i.support.isRtl(d.element);n.target==n.currentTarget&&(!m&&u==o.RIGHT||m&&u==o.LEFT?p?r=d._nextVisible(h):h.find(".k-treeview-leaf").first().hasClass(a)||d.expand(h):!m&&u==o.LEFT||m&&u==o.RIGHT?p&&!h.find(".k-treeview-leaf").first().hasClass(a)?d.collapse(h):(r=d.parent(h),d._enabled(r)||(r=t)):u==o.DOWN?r=d._nextVisible(h):u!=o.UP||n.altKey?u==o.HOME?r=d._nextVisible(e()):u==o.END?r=d._previousVisible(e()):u!=o.ENTER||h.find(".k-treeview-leaf").first().hasClass(a)?u==o.SPACEBAR&&f.length&&!h.find(".k-treeview-leaf").first().hasClass(a)?(f.prop(l,!f.prop(l)).data(c,!1).prop(c,!1),d._checkboxChange({target:f}),r=h):n.altKey&&u===o.UP||u===o.ESC?d._closePopup():u===o.TAB&&(n.preventDefault(),d._closePopup()):h.find(".k-treeview-leaf").first().hasClass("k-selected")||d._trigger(s,h)||d.select(h):r=d._previousVisible(h),r&&(n.preventDefault(),h[0]!=r[0]&&(d._trigger("navigate",r),d.current(r),d.scrollTo(r))))},_closePopup:function(){this.dropdowntree.close(),this.dropdowntree.wrapper.trigger("focus")},refresh:function(e){this.defaultrefresh(e),this.dropdowntree.options.skipUpdateOnBind||("itemchange"===e.action?this.dropdowntree._isMultipleSelection()?"checked"===e.field&&this.dropdowntree._checkValue(e.items[0]):"checked"!==e.field&&"expanded"!==e.field&&e.items[0].selected&&this.dropdowntree._selectValue(e.items[0]):this.dropdowntree.refresh(e))}});i.ui._dropdowntree=u}(window.kendo.jQuery);!function(e,t){var n=window.kendo,i=n.ui,r=n.html,o=n.htmlEncode,a=n.mediaQuery,s=i.Widget,l=i._dropdowntree,c=n.data.ObservableArray,d=n.data.ObservableObject,u=e.extend,h=n._activeElement,p=".kendoDropDownTree",f=n.keys,m=n.support,g="k-hidden",v="width",_=m.browser,b=n._outerWidth,y=".",w="disabled",k="readonly",x="k-disabled",C="aria-disabled",S="k-focus",T="mouseenter"+p+" mouseleave"+p,D="tabindex",A="click",M="open",E="close",I="change",z=/"/g,P=".k-chip";function H(t){if(Array.isArray(t)){var i=t.length,r=e.map(t,(function(e){return function(t){return t[e]}}));return function(e){var t=e._level;if(t||0===t)return r[Math.min(t,i-1)](e)}}return n.getter(t)}var F=n.ui.Widget.extend({init:function(t,i){var r=this;r.ns=p,n.ui.Widget.fn.init.call(r,t,i),r._selection=r._getSelection(),r._focusInputHandler=r._focusInput.bind(r),r._initial=r.element.val(),r._values=[];var o=this.options.value;if(null!==o&&o.length||(this._noInitialValue=!0),this._isNullorUndefined(o)||(this._valueMethodCalled=!0,o=this._isArrayOfObjects(o)&&r.options.autoBind?o.map((e=>e[r.options.dataValueField])):o,this._values=Array.isArray(o)?o.slice(0):[o]),r.bigScreenMQL=a("large"),r.smallScreenMQL=a("small"),"auto"==r.options.adaptiveMode&&r.smallScreenMQL.onChange((function(){r.popup&&n.isFunction(r.popup.fullscreen)&&r.popup.fullscreen(r.smallScreenMQL.mediaQueryList.matches)})),this._bindLoader(),this._inputTemplate(),this._accessors(),this._setTreeViewOptions(this.options),this._dataSource(),this._selection._initWrapper(),this._applyCssClasses(),this._placeholder(!0),this._tabindex(),this.wrapper.data(D,this.wrapper.attr(D)),this.tree=e("<div/>").attr({tabIndex:-1,"aria-hidden":!0}),this.list=e("<div/>").append(this.tree),this._header(),this._noData(),this._footer(),this._reset(),this._popup(),"auto"==r.options.adaptiveMode&&r.bigScreenMQL.onChange((()=>{r.list=e("<div class='k-list-container'/>").append(r.tree),r._header.bind(r)(),r._noData.bind(r)(),r._footer.bind(r)(),r._reset.bind(r)(),r.popup&&(r.popup.destroy(),r.popup.element.remove(),r.popup=null),r.treeview&&r.treeview.destroy(),r._popup.bind(r)(),r._filterHeader.bind(r)(),r._treeview.bind(r)(),r._renderFooter.bind(r)(),r._checkAll.bind(r)(),r._enable.bind(r)(),r._toggleCloseVisibility.bind(r)(),r._aria.bind(r)()})),this._clearButton(),this._filterHeader(),this._treeview(),this._renderFooter(),this._checkAll(),this._enable(),this._toggleCloseVisibility(),!this.options.autoBind){var s=i.text||"";this._isNullorUndefined(i.value)?s?this._textAccessor(s):i.placeholder&&this._placeholder(!0):this._preselect(i.value)}e(this.element).parents("fieldset").is(":disabled")&&this.enable(!1),this._valueMethodCalled=!1,this.options.label&&this._label(),this.options.loadOnDemand&&this.options.loadOnDemand.valueMapper&&this.options.value&&this.one("dataBound",(()=>this.requireValueMapper(this.options))),this._aria(),n.notify(this)},_bindLoader:function(){const e=this;e._initLoader=Ih.bind(e),e._initLoader()},_label:function(){var t=this,i=t.options,r=e.isPlainObject(i.label)?i.label:{content:i.label};t.label=new n.ui.Label(null,e.extend({},r,{widget:t,floatCheck:t._floatCheck.bind(t)})),t._inputLabel=t.label.element},_floatCheck:function(){return!(this.value()&&!this._isMultipleSelection()||this.value().length||this.text())&&!this.popup.visible()},_refreshFloatingLabel:function(){var e=this;e.label&&e.label.floatingLabel&&e.label.floatingLabel.refresh()},_preselect:function(e,t){this._selection._preselect(e,t)},_setTreeViewOptions:function(t){var n={autoBind:t.autoBind,checkboxes:t.checkboxes,dataImageUrlField:t.dataImageUrlField,dataSpriteCssClassField:t.dataSpriteCssClassField,dataTextField:t.dataTextField,dataUrlField:t.dataUrlField,loadOnDemand:t.loadOnDemand,size:t.size};this.options.treeview=e.extend({},n,this.options.treeview),t.template&&(this.options.treeview.template=t.template),t.size&&(this.options.treeview.size=t.size)},_dataSource:function(){const t=this,i=t.options.dataSource;t._requestStartHandler=t._showBusy,t._requestEndHandler=t._hideBusy,t._errorHandler=function(){t._hideBusy()},t.dataSource=n.data.HierarchicalDataSource.create(i).bind("progress",t._requestStartHandler).bind("error",t._errorHandler).bind("requestEnd",t._requestEndHandler),i&&e.extend(t.options.treeview,{dataSource:t.dataSource})},_popupOpen:function(){var e=this.popup;e.wrapper=n.wrap(e.element)},_getSelection:function(){return this._isMultipleSelection()?(this.options._altname="MultiSelectTree",new i.DropDownTree.MultipleSelection(this)):new i.DropDownTree.SingleSelection(this)},setDataSource:function(e){this._isDataSourceSet=!0,this._tags&&(this._noInitialValue=!0,this.setValue([]),this._tags.empty(),this.span.show(),this._multipleTags.empty()),this.dataSource=e,this.treeview.setDataSource(e),this._isDataSourceSet=!1},_isMultipleSelection:function(){return this.options&&(this.options.treeview.checkboxes||this.options.checkboxes)},_isArrayOfObjects:function(e){return Array.isArray(e)&&e.map((e=>"object"==typeof e)).includes(!0)},options:{name:"DropDownTree",adaptiveMode:"none",animation:{},autoBind:!0,autoClose:!0,autoWidth:!1,clearButton:!0,dataTextField:"",dataValueField:"",dataImageUrlField:"",dataSpriteCssClassField:"",dataUrlField:"",delay:500,enabled:!0,enforceMinLength:!1,filter:"none",height:200,ignoreCase:!0,index:0,loadOnDemand:!1,messages:{singleTag:"item(s) selected",clear:"clear",deleteTag:"delete",noData:"No data found."},minLength:1,checkboxes:!1,noDataTemplate:!0,placeholder:"",checkAll:!1,checkAllTemplate:()=>"Check all",tagMode:"multiple",template:null,text:null,treeview:{},valuePrimitive:!1,footerTemplate:()=>"",headerTemplate:()=>"",value:null,valueTemplate:null,popup:null,filterLabel:null,size:"medium",fillMode:"solid",rounded:"medium",label:null},events:["open","close","dataBound",I,"select","filtering"],focus:function(){this.wrapper.trigger("focus")},dataItem:function(e){return this.treeview.dataItem(e)},readonly:function(e){this._editable({readonly:e===t||e,disable:!1}),this._toggleCloseVisibility(),this.label&&this.label.floatingLabel&&this.label.floatingLabel.readonly(e===t||e)},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)}),this._toggleCloseVisibility(),this.label&&this.label.floatingLabel&&this.label.floatingLabel.enable(e=e===t||e)},toggle:function(e){this._toggle(e)},open:function(){var e=this.popup;this.options.autoBind||this.dataSource.data().length||(this.treeview._progress(!0),this._isFilterEnabled()?this._search():this.dataSource.fetch()),!e.visible()&&this._allowOpening()&&(e.one("activate",this._focusInputHandler),e._hovered=!0,e.open())},close:function(){this.popup.close()},search:function(e){var t,n=this.options;if(clearTimeout(this._typingTimeout),!n.enforceMinLength&&!e.length||e.length>=n.minLength){if(t=this._getFilter(e),this.trigger("filtering",{filter:t})||Array.isArray(this.options.dataTextField))return;this._filtering=!0,this.treeview.dataSource.filter(t)}},_mapValuesToId:function(e){if("function"==typeof this.dataSource.options.schema.model)throw new Error("The valueMapper needs dataSource.schema");const t=this.dataSource.options.schema.model.id;return e.map((e=>e[t]))},requireValueMapper:function(e,t){const n=this;let i=t||e.value;if(i=i&&(i instanceof Array?i:[i]),i&&e.loadOnDemand&&"function"!=typeof e.loadOnDemand.valueMapper)throw new Error("ValueMapper is not provided while the value is being set. See http://docs.telerik.com/kendo-ui/controls/editors/combobox/virtualization#the-valuemapper-function");if(i.length){let e=0;n.options.loadOnDemand.valueMapper(Rh(n.options,i,n._useValueMapper.bind(n,i,e)))}},_useValueMapper:function(t,n,i){const r=this,o=e.Deferred();r._deferred=o,r._handleValueMapperData(n,i),o.done((()=>{++n<t.length&&r._useValueMapper(t,n,i)}))},_handleValueMapperData:function(e,t){const n=t[e]instanceof Array?t[e]:t;if(!n||!n.length)return;this._loadItem(n,0)},_loadItem:function(e,t){const n=this,i=n.dataSource.get(e[t]);i&&i.load().done((()=>{++t<e.length-1?n._loadItem(e,t):n._deferred.resolve()}))},_getFilter:function(e){return{field:this.options.dataTextField,operator:this.options.filter,value:e,ignoreCase:this.options.ignoreCase}},refresh:function(){var t=this.treeview.dataSource.flatView();this._renderFooter(),this._renderNoData(),this.filterInput&&this.checkAll&&this.checkAll.toggle(!this.filterInput.val().length),this.tree.toggle(!!t.length),e(this.noData).toggle(!t.length)},setOptions:function(e){this.options.checkboxes!=e.checkboxes&&(delete e.checkboxes,window.console.warn("setOptions method can not be used to set the checkboxes option in DropDownTree")),s.fn.setOptions.call(this,e),this._setTreeViewOptions(e),this._dataSource(),(this.options.treeview||e.size)&&(this.treeview.destroy(),this._treeview()),e.height&&this.tree&&this.tree.css("max-height",e.height),this._header(),this._noData(),this._footer(),this._renderFooter(),this._renderNoData(),this.span&&(this._isMultipleSelection()||this.span.hasClass("k-readonly"))&&this._placeholder(!0),this._inputTemplate(),this._accessors(),this._filterHeader(),this._checkAll(),this._enable(),e&&(e.enable||e.enabled)&&this.enable(!0),this._clearButton(),e!==t&&null!==e||(e={}),e.label&&this._inputLabel?this.label.setOptions(e.label):!1===e.label?(this.label._unwrapFloating(),this._inputLabel.remove(),delete this._inputLabel):e.label&&this._label(),this._aria()},destroy:function(){n.ui.Widget.fn.destroy.call(this),this.treeview&&this.treeview.destroy(),this.popup.destroy(),this.wrapper.off(p),this._clear.off(p),this.filterInput&&this.filterInput.off(p),this.tagList&&this.tagList.off(p),this.bigScreenMQL&&this.bigScreenMQL.destroy(),this.smallScreenMQL&&this.smallScreenMQL.destroy(),n.unbind(this.tagList),this.options.checkAll&&this.checkAll&&this.checkAll.off(p),this._form&&this._form.off("reset",this._resetHandler),this.label&&this.label.destroy()},setValue:function(e){e=Array.isArray(e)||e instanceof c?e.slice(0):[e],this._values=e},items:function(){return this.treeview.items()},_useValueMapperWithValue:function(e){const t=this;let n=e instanceof Array?e:[e];"object"==typeof n[0]&&(n=t._mapValuesToId(n)),t.requireValueMapper(this.options,n),t._deferred.done((()=>{t._selection._setValue(n)}))},value:function(e){const t=this,n=t.options.loadOnDemand;if(e)if(t.filterInput&&t.dataSource._filter)t._filtering=!0,t.dataSource.filter({});else{if(!t.dataSource.data().length||!t.treeview.dataSource.data().length)return void(n?n.valueMapper?t.one("dataBound",(()=>{t._useValueMapperWithValue(e)})):t.dataSource.fetch((function(){t._selection._setValue(e)})):(t.treeview.one("loadCompleted",(function(){t._selection._setValue(e)})),!t.options.autoBind&&t.options.valuePrimitive&&t.dataSource.fetch()));if(n&&n.valueMapper)return void t._useValueMapperWithValue(e)}return t._selection._setValue(e)},text:function(e){var n,i=this.options.ignoreCase;if((e=null===e?"":e)===t||this._isMultipleSelection())return this._textAccessor();"string"==typeof e?(n=i?e:e.toLowerCase(),this._selectItemByText(n),this._textAccessor(n),this._refreshFloatingLabel()):this._textAccessor(e)},_aria:function(){this.wrapper.find("span.k-input-inner");this.wrapper.attr({"aria-haspopup":"tree","aria-expanded":!1,"aria-controls":this.treeview.element.attr("id"),role:"combobox"}),this._activeId=n.guid(),this._ariaLabel(this.wrapper),this.filterInput&&this.options.filterLabel&&this.filterInput.attr("aria-label",this.options.filterLabel),this.options.checkboxes&&(this.wrapper.attr({"aria-describedby":this.tagList[0].id}),this.tagList.attr({role:"listbox","aria-orientation":"horizontal","aria-multiselectable":!0}),this._ariaLabel(this.tagList))},_header:function(){var t=this,i=e(t.header),r=t.options.headerTemplate;if(n.destroy(i),i.remove(),r){var o="function"!=typeof r?n.template(r):r;i=e(o({})),t.header=i[0]?i:null,t.list.prepend(i)}else t.header=null},_noData:function(){var t=this,i=e(t.noData),r=!0===t.options.noDataTemplate?o(t.options.messages.noData):t.options.noDataTemplate;n.destroy(i),i.remove(),r?(t.noData=e('<div class="k-no-data"></div>').hide().appendTo(t.list),t.noDataTemplate="function"!=typeof r?n.template((()=>r)):r):t.noData=null},_renderNoData:function(){var e=this,t=e.noData;t&&t.html(e.noDataTemplate({instance:e}))},_footer:function(){var t=this,i=e(t.footer),r=t.options.footerTemplate;n.destroy(i),i.remove(),r?(t.footer=e('<div class="k-footer"></div>').appendTo(t.list),t.footerTemplate="function"!=typeof r?n.template(r):r):t.footer=null},_renderFooter:function(){var e=this,t=e.footer;t&&t.html(e.footerTemplate({instance:e}))},_enable:function(){var e=this,n=e.options,i=e.element.is("[disabled]");n.enable!==t&&(n.enabled=n.enable),!n.enabled||i?e.enable(!1):e.readonly(e.element.is("[readonly]"))},_adjustListWidth:function(){var e,t,n=this,i=n.list,r=i[0].style.width,o=n.wrapper;if(i.data(v)||!r)return e=window.getComputedStyle?window.getComputedStyle(o[0],null):0,t=parseFloat(e&&e.width)||b(o),e&&_.msie&&(t+=parseFloat(e.paddingLeft)+parseFloat(e.paddingRight)+parseFloat(e.borderLeftWidth)+parseFloat(e.borderRightWidth)),r="border-box"!==i.css("box-sizing")?t-(b(i)-i.width()):t,i.css({fontFamily:o.css("font-family"),width:n.options.autoWidth?"auto":r,minWidth:r,whiteSpace:n.options.autoWidth?"nowrap":"normal"}).data(v,r),!0},_reset:function(){var t=this,n=t.element,i=n.attr("form"),r=i?e("#"+i):n.closest("form");r[0]&&(t._resetHandler=function(){setTimeout((function(){t.value(t._initial)}))},t._form=r.on("reset",t._resetHandler))},_hasActionSheet:function(){return"auto"===this.options.adaptiveMode&&!this.bigScreenMQL.mediaQueryList.matches},_popup:function(){var t=this,r=this;t.options.checkboxes?(t.options.checkAll&&t.list.attr("role","application"),t.list.addClass("k-multiselecttree-popup")):t.list.addClass("k-dropdowntree-popup"),"auto"!=r.options.adaptiveMode||r.bigScreenMQL.mediaQueryList.matches?(r.popup=new i.Popup(r.list,u({},r.options.popup,{anchor:r.wrapper,open:r._openHandler.bind(r),close:r._closeHandler.bind(r),animation:r.options.animation,isRtl:m.isRtl(r.wrapper),autosize:r.options.autoWidth,deactivate:()=>{this._refreshFloatingLabel()},activate:()=>{this._refreshFloatingLabel()}})),r.popup.one("open",r._popupOpen.bind(r))):(e(document.body).append(r.list),r.popup=new i.ActionSheet(r.list,{adaptive:!0,hideOverflowContent:!0,headerTemplate:e=>`<div class="k-text-center k-actionsheet-titlebar" ><div class="k-actionsheet-titlebar-group k-hbox"><div  class="k-actionsheet-title"><div class="k-text-center">${r.label?r.label.element.text():r.options.label||r.options.placeholder||"Select"}</div>`+(r.options.placeholder&&(r.label||r.options.label)?`<div class="k-actionsheet-subtitle k-text-center">${r.options.placeholder||""}</div>`:"")+"</div>"+(e.closeButton?'<div class="k-actionsheet-actions">'+n.html.renderButton(`<button tabindex="-1" ${n.attr("ref-actionsheet-close-button")}></button>`,{icon:"x",fillMode:"flat",size:"large"})+"</div>":"")+"</div>"+(this._isFilterEnabled()?'<div class="k-actionsheet-titlebar-group k-actionsheet-filter"></div>':"")+"</div>",closeButton:!0,focusOnActivate:!1,fullscreen:r.smallScreenMQL.mediaQueryList.matches,popup:u({},r.options.popup,{anchor:r.wrapper,open:r._openHandler.bind(r),close:r._closeHandler.bind(r),animation:r.options.animation,isRtl:m.isRtl(r.wrapper),autosize:r.options.autoWidth}),deactivate:()=>{this._refreshFloatingLabel()},activate:()=>{this._refreshFloatingLabel()}}))},_allowOpening:function(){return this.options.noDataTemplate||this.treeview.dataSource.flatView().length},_placeholder:function(e){this.span&&this.span.toggleClass("k-readonly",e).text(e?this.options.placeholder:"")},_currentValue:function(e){var t=this._value(e);return t||0===t||(t=e),t},_checkValue:function(t){var n="",i=-1,r=this.value(),o="multiple"===this.options.tagMode;if((t||0===t)&&(t.level&&(t._level=t.level()),n=this._currentValue(t),i=r.indexOf(n)),t.checked){if(e.grep(this._tags,(function(e){return e.uid===t._tagUid})).length)return;var a=new d(t.toJSON());t._tagUid=a.uid,this._tags.push(a),1===this._tags.length&&(this.span.hide(),o||this._multipleTags.push(a)),-1===i&&(r.push(n),this.setValue(r))}else{var s=this._tags.find((function(e){return e.uid===t._tagUid})),l=this._tags.indexOf(s);if(-1===l)return void this._treeViewCheckAllCheck(t);this._tags.splice(l,1),0===this._tags.length&&(this.span.show(),o||this._multipleTags.splice(0,1)),-1!==i&&(r.splice(i,1),this.setValue(r))}this._treeViewCheckAllCheck(t),this._preventChangeTrigger||this._valueMethodCalled||this._noInitialValue||this.trigger(I),this.options.autoClose&&this.popup.visible()&&(this.close(),this.wrapper.trigger("focus")),this.popup.position(),this._toggleCloseVisibility(),this._updateSelectedOptions()},_updateSelectedOptions:function(){if("select"===this.element[0].tagName.toLowerCase()){var e=this._tags,t="",n=null,i=null;if(e.length)for(var r=0;r<e.length;r++)n=e[r],i=this._value(n),t+=this._option(i,this._text(n),!0);this.element.html(t)}},_option:function(e,i,r){var o="<option";return e!==t&&(-1!==(e+="").indexOf('"')&&(e=e.replace(z,"&quot;")),o+=' value="'+e+'"'),r&&(o+=" selected"),o+=">",i!==t&&(o+=n.htmlEncode(i)),o+"</option>"},_selectValue:function(e){var t="",n="";(e||0===e)&&(e.level&&(e._level=e.level()),n=this._text(e)||e,t=this._currentValue(e)),null===t&&(t=""),this.setValue(t),this._textAccessor(n,e),this._accessor(t),this._preventChangeTrigger||this._valueMethodCalled||this.trigger(I),this._valueMethodCalled=!1,this.options.autoClose&&this.popup.visible()&&(this.close(),this.wrapper.trigger("focus")),this.popup.position(),this._toggleCloseVisibility()},_clearClick:function(e){e.stopPropagation(),this.wrapper.trigger("focus"),this._clearTextAndValue()},_clearTextAndValue:function(){var e=this._selection._clearValue();this.setValue([]),this._clearInput(),this._clearText(),this.popup.position(),this._toggleCloseVisibility(),this._refreshFloatingLabel(),e&&this.trigger(I)},_clearText:function(){this.options.placeholder?this._placeholder(!0):this.span&&this.span.html("")},_inputTemplate:function(){var e=this.options.valueTemplate;e=e?n.template(e):e=>o(this._text(e)),this.valueTemplate=e},_assignInstance:function(e,t){var n=this.options.dataTextField,i={};return n?(R(i,n.split(y),e),R(i,this.options.dataValueField.split(y),t),i=new d(i)):i=e,i},_textAccessor:function(n,i){var r=this.valueTemplate,o=this.span;if(n===t)return o.text();o.removeClass("k-readonly"),!i&&(e.isPlainObject(n)||n instanceof d)&&(i=n),i||(i=this._assignInstance(n,this._accessor()));try{o.html(r(i))}catch(e){o&&o.html("")}},_accessors:function(){var e=this.element,t=this.options,i=e.attr(n.attr("text-field")),r=e.attr(n.attr("value-field"));!t.dataTextField&&i&&(t.dataTextField=i),!t.dataValueField&&r&&(t.dataValueField=r),t.dataTextField=t.dataTextField||"text",t.dataValueField=t.dataValueField||"value",this._text=H(t.dataTextField),this._value=H(t.dataValueField)},_accessor:function(e,t){return this._accessorInput(e,t)},_accessorInput:function(e){var n=this.element[0];if(e===t)return n.value;null===e&&(e=""),n.value=e},_clearInput:function(){this.element[0].value=""},_clearButton:function(){var t=o(this.options.messages.clear);this._clear||(this._clear=e('<span unselectable="on" class="k-clear-value" title="'+t+'">'+n.ui.icon("x")+"</span>").attr({tabIndex:-1})),this.options.clearButton?this._clear.insertAfter(this.span.parent()):this.options.clearButton||this._clear.remove()},_toggleCloseVisibility:function(){var e=this.element.attr(k),t=this.value()&&!this._isMultipleSelection()||this.value().length,n=this.element.val()&&this.element.val()!==this.options.placeholder;e||!t&&!n?this._hideClear():this._showClear()},_showClear:function(){this._clear&&this._clear.removeClass(g)},_hideClear:function(){this._clear&&this._clear.addClass(g)},_openHandler:function(e){this._adjustListWidth(),this.trigger(M)?e.preventDefault():(this.wrapper.attr("aria-expanded",!0),this.tree.attr("aria-hidden",!1))},_closeHandler:function(e){this.trigger(E)?e.preventDefault():(this.wrapper.attr("aria-expanded",!1),this.tree.attr("aria-hidden",!0))},_treeview:function(){var e=this;"auto"!=e.options.adaptiveMode&&e.options.height&&e.tree.css("max-height",e.options.height),e.tree.attr("id",n.guid()),e.treeview=new l(e.tree,u({size:e.options.size},e.options.treeview),e),e.dataSource=e.treeview.dataSource,e.treeview.bind("select",(function(t){e.trigger("select",t)}))},_treeViewDataBound:function(e){if(e.node&&this._prev&&this._prev.length&&e.sender.expand(e.node),this._filtering)return e.node||(this._filtering=!1),void(this._isMultipleSelection()||this._deselectItem(e));if(this.treeview||(this.treeview=e.sender),e.node){var t=e.sender.dataItem(e.node);if(t){var n=t.children.data();this._checkLoadedItems(n)}}else{var i=e.sender.dataSource.data();this._checkLoadedItems(i),this._noInitialValue&&(this._noInitialValue=!1)}this.trigger("dataBound",e)},_deselectItem:function(e){var t=[];if(e.node){var n=e.sender.dataItem(e.node);n&&(t=n.children.data())}else t=e.sender.dataSource.data();for(var i=0;i<t.length;i++)t[i].selected&&!this._valueComparer(t[i],this.value())&&t[i].set("selected",!1)},_checkLoadedItems:function(e){var t=this.value();if(e)for(var n=0;n<e.length;n++)this._selection._checkLoadedItem(e[n],t)},_treeViewCheckAllCheck:function(e){this.options.checkAll&&this.checkAll&&(this._getAllChecked(),e.checked?this._checkCheckAll():this._uncheckCheckAll())},_checkCheckAll:function(){var e=this.checkAll.find(".k-checkbox");this._allItemsAreChecked?e.prop("checked",!0).prop("indeterminate",!1):e.prop("indeterminate",!0)},_uncheckCheckAll:function(){var e=this.checkAll.find(".k-checkbox");this._allItemsAreUnchecked?e.prop("checked",!1).prop("indeterminate",!1):e.prop("indeterminate",!0)},_filterHeader:function(){var t='<div class="k-list-filter"><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid" type="text" autocomplete="off">'+n.ui.icon({icon:"search",iconClass:"k-input-icon"})+"</span></div>";this.filterInput&&(this.filterInput.off(p).parent().remove(),this.filterInput=null),this._isFilterEnabled()&&(this._disableCheckChildren(),this.filterInput=e('<input class="k-input-inner" type="text" />').attr({placeholder:this.element.attr("placeholder"),title:this.element.attr("title"),role:"searchbox","aria-haspopup":"tree","aria-autocomplete":"list"}),this.filterInput.on("input",this._filterChange.bind(this)),this._hasActionSheet()?e(t).appendTo(this.popup.wrapper.find(".k-actionsheet-filter")).find(".k-textbox").append(this.filterInput):e(t).insertBefore(this.tree).find(".k-textbox").append(this.filterInput))},_filterChange:function(){this.filterInput&&this._search()},_disableCheckChildren:function(){this._isMultipleSelection()&&this.options.treeview.checkboxes&&this.options.treeview.checkboxes.checkChildren&&(this.options.treeview.checkboxes.checkChildren=!1)},_checkAll:function(){if(this.checkAll&&(this.checkAll.find(".k-checkbox-label, .k-checkbox").off(p),this.checkAll.remove(),this.checkAll=null),this._isMultipleSelection()&&this.options.checkAll){var t=r.renderCheckBox(u({},this.options,{label:"Check All",rounded:"medium"}));this.checkAll=e('<div class="k-check-all">'+t+"</div>").insertBefore(this.tree),this.checkAll.find(".k-checkbox-label").html(n.template(this.options.checkAllTemplate)({instance:this})),this.checkAll.find(".k-checkbox").on("change"+p,this._changeCheckAll.bind(this)).on("keydown"+p,this._keydownCheckAll.bind(this)),this._disabledCheckedItems=[],this._disabledUnCheckedItems=[],this._getAllChecked(),this._allItemsAreUnchecked||this._checkCheckAll()}},_changeCheckAll:function(){var e=this.checkAll.find(".k-checkbox").prop("checked");this._updateCheckAll(e)},_updateCheckAll:function(e){var t=this.checkAll.find(".k-checkbox");this._toggleCheckAllItems(e),t.prop("checked",e),this._disabledCheckedItems.length&&this._disabledUnCheckedItems.length?t.prop("indeterminate",!0):this._disabledCheckedItems.length?t.prop("indeterminate",!e):this._disabledUnCheckedItems.length?t.prop("indeterminate",e):t.prop("indeterminate",!1),this._disabledCheckedItems=[],this._disabledUnCheckedItems=[]},_keydownCheckAll:function(e){var t=e.keyCode;if(e.altKey&&t===f.UP||t===f.ESC||t===f.TAB)return this.close(),this.wrapper.trigger("focus"),void e.preventDefault();t===f.UP&&(this.filterInput?this.filterInput.trigger("focus"):this.wrapper.trigger("focus"),e.preventDefault()),t===f.DOWN&&(this.tree&&this.tree.is(":visible")&&this.tree.trigger("focus"),e.preventDefault()),t===f.SPACEBAR&&(_.msie||_.edge)&&(this._clickCheckAll(),e.preventDefault())},_clickCheckAll:function(){var e=this.checkAll.find(".k-checkbox"),t=e.prop("checked");this._updateCheckAll(!t),e.trigger("focus")},_dfs:function(e,t,n){for(var i=0;i<e.length&&this[t](e[i],n);i++)this._traverceChildren(e[i],t,n)},_uncheckItemByUid:function(e){this._dfs(this.dataSource.data(),"_uncheckItemEqualsUid",e)},_uncheckItemEqualsUid:function(e,t){return!1===e.enabled||e._tagUid!=t||(e.set("checked",!1),!1)},_selectItemByText:function(e){this._dfs(this.dataSource.data(),"_itemEqualsText",e)},_itemEqualsText:function(e,t){return!1===e.enabled||this._text(e)!==t||(this.treeview.select(this.treeview.findByUid(e.uid)),this._selectValue(e),!1)},_selectItemByValue:function(e){this._dfs(this.dataSource.data(),"_itemEqualsValue",e)},_itemEqualsValue:function(e,t){return!1===e.enabled||!this._valueComparer(e,t)||(this.treeview.select(this.treeview.findByUid(e.uid)),!1)},_checkItemByValue:function(e){for(var t=this.treeview.dataItems(),n=0;n<e.length;n++)this._dfs(t,"_checkItemEqualsValue",e[n])},_checkItemEqualsValue:function(e,t){return!1===e.enabled||!this._valueComparer(e,t)||(e.set("checked",!0),!1)},_valueComparer:function(e,t){var n,i=this._value(e);if(!this._isNullorUndefined(i)){if(this._isNullorUndefined(t))return!1;var r=this._value(t);return r?i==r:i==t}return!!(n=this._text(e))&&(this._text(t)?n==this._text(t):n==t)},_isNullorUndefined:function(e){return e===t||null===e},_getAllChecked:function(){return this._allCheckedItems=[],this._allItemsAreChecked=!0,this._allItemsAreUnchecked=!0,this._dfs(this.dataSource.data(),"_getAllCheckedItems"),this._allCheckedItems},_getAllCheckedItems:function(e){return this._allItemsAreChecked&&(this._allItemsAreChecked=e.checked),this._allItemsAreUnchecked&&(this._allItemsAreUnchecked=!e.checked),e.checked&&this._allCheckedItems.push(e),!0},_traverceChildren:function(e,t,n){var i=e[e._childrenOptions&&e._childrenOptions.schema?e._childrenOptions.schema.data:null]||e.items||e.children;i&&this._dfs(i,t,n)},_toggleCheckAllItems:function(e){this._dfs(this.dataSource.data(),"_checkAllCheckItem",e)},_checkAllCheckItem:function(e,t){return!1===e.enabled?e.checked?this._disabledCheckedItems.push(e):this._disabledUnCheckedItems.push(e):e.set("checked",t),!0},_isFilterEnabled:function(){var e=this.options.filter;return e&&"none"!==e},_editable:function(t){var n=this,i=n.element,r=t.disable,o=t.readonly,a=n.wrapper.add(n.filterInput).off(p),s=n.wrapper.off(T);n._isMultipleSelection()&&n.tagList.off(A+p),o||r?r?(a.removeAttr(D),s.addClass(x)):(a.attr(D,a.data(D)),s.removeClass(x),a.on("focusin"+p,n._focusinHandler.bind(n)).on("focusout"+p,n._focusoutHandler.bind(n))):(i.prop(w,!1).prop(k,!1),s.removeClass(x).on(T,n._toggleHover),n._clear.on("click"+p,n._clearClick.bind(n)),a.attr(D,a.data(D)).attr(C,!1).on("keydown"+p,n._keydown.bind(n)).on("focusin"+p,n._focusinHandler.bind(n)).on("focusout"+p,n._focusoutHandler.bind(n)),n.wrapper.on(A+p,n._wrapperClick.bind(n)),this._isMultipleSelection()&&(n.tagList.on(A+p,"div.k-chip",(function(t){e(t.currentTarget).addClass(S)})),n.tagList.on(A+p,".k-chip-remove-action .k-icon",(function(e){n._removeTagClick(e)})))),i.attr(w,r).attr(k,o),a.attr(C,r)},_focusinHandler:function(){this.wrapper.addClass(S),this._prevent=!1},_focusoutHandler:function(){var e=this;this._isMultipleSelection()&&this.tagList.find(y+S).removeClass(S),e._prevent||(this.wrapper.removeClass(S),e._prevent=!0,e.element.trigger("blur"))},_toggle:function(e){this[(e=e!==t?e:!this.popup.visible())?M:E]()},_wrapperClick:function(e){e.preventDefault(),this.popup.unbind("activate",this._focusInputHandler),this._focused=this.wrapper,this._prevent=!1,this._toggle()},_toggleHover:function(t){e(t.currentTarget).toggleClass("k-hover","mouseenter"===t.type)},_focusInput:function(){this.filterInput?this.filterInput.trigger("focus"):this.checkAll?this.checkAll.find(".k-checkbox").trigger("focus"):this.tree.is(":visible")&&(this.tree[0].focus({preventScroll:!0}),this._ie11PreventScrollOnFocus())},_ie11PreventScrollOnFocus:function(){if(_.msie&&11==_.version){var e=this.popup;e._toggleResize(!1),setTimeout((function(){e._toggleResize(!0)}),50)}},_keydown:function(e){var t,n,i,r,o=e.keyCode,a=e.altKey,s=this.popup.visible();if(this.filterInput&&(t=this.filterInput[0]===h()),this.wrapper&&(n=this.wrapper[0]===h()),n){if(o===f.ESC)return this._clearTextAndValue(),void e.preventDefault();if(this._isMultipleSelection()){if(o===f.LEFT)return this._focusPrevTag(),void e.preventDefault();if(o===f.RIGHT)return this._focusNextTag(),void e.preventDefault();if(o===f.HOME)return this._focusFirstTag(),void e.preventDefault();if(o===f.END)return this._focusLastTag(),void e.preventDefault();if(o===f.DELETE)return(i=this.tagList.find(y+S).first()).length&&(r=this._tags[i.index()],this._removeTag(r)),void e.preventDefault();if(o===f.BACKSPACE)return((i=this.tagList.find(y+S).first()).length||(i=this._focusLastTag()).length)&&(r=this._tags[i.index()],this._removeTag(r)),void e.preventDefault()}}return t&&(o===f.ESC&&this._clearFilter(),o!==f.UP||a||(this.wrapper.trigger("focus"),e.preventDefault()),_.msie&&_.version<10&&(o!==f.BACKSPACE&&o!==f.DELETE||this._search()),o===f.TAB)||a&&o===f.UP||o===f.ESC?(this.close(),this.wrapper.trigger("focus"),void e.preventDefault()):void(o===f.ENTER&&this._typingTimeout&&this.filterInput&&s?e.preventDefault():(o!==f.SPACEBAR||t||(this._toggle(!s),e.preventDefault()),a&&o===f.DOWN&&!s&&(this.open(),e.preventDefault()),o===f.DOWN&&s&&(this.filterInput&&!t?this.filterInput.trigger("focus"):this.checkAll&&this.checkAll.is(":visible")?this.checkAll.find("input").trigger("focus"):this.tree.is(":visible")&&(this.tree[0].focus({preventScroll:!0}),this._ie11PreventScrollOnFocus()),e.preventDefault()),o===f.TAB&&s&&(this.close(),this.wrapper.trigger("focus"),e.preventDefault())))},_focusPrevTag:function(){var e=this.tagList.find(y+S);if(e.length){var t=this._activeId;e.first().removeClass(S).removeAttr("id").prev(P).addClass(S).attr("id",t),this.wrapper.attr("aria-activedescendant",t)}else this._focusLastTag()},_focusNextTag:function(){var e=this.tagList.find(y+S);if(e.length){var t=this._activeId;e.first().removeClass(S).removeAttr("id").next(P).addClass(S).attr("id",t),this.wrapper.attr("aria-activedescendant",t)}else this._focusFirstTag()},_focusFirstTag:function(){var e=this._activeId;this._clearDisabledTag();var t=this.tagList.children(P).first().addClass(S).attr("id",e);return this.wrapper.attr("aria-activedescendant",e),t},_focusLastTag:function(){var e=this._activeId;this._clearDisabledTag();var t=this.tagList.children(P).last().addClass(S).attr("id",e);return this.wrapper.attr("aria-activedescendant",e),t},_clearDisabledTag:function(){this.tagList.find(y+S).removeClass(S).removeAttr("id")},_search:function(){var e=this;clearTimeout(e._typingTimeout),e._typingTimeout=setTimeout((function(){var t=e.filterInput.val();e._prev!==t&&(e._prev=t,e.search(t)),e._typingTimeout=null}),e.options.delay)},_clearFilter:function(){this.filterInput.val().length&&(this.filterInput.val(""),this._prev="",this._filtering=!0,this.treeview.dataSource.filter({}))},_removeTagClick:function(t){t.stopPropagation();var n=this._tags[e(t.currentTarget.closest(P)).index()];this._removeTag(n)},_removeTag:function(e){if(e){var t=e.uid;this._uncheckItemByUid(t)}}});function R(e,t,n){for(var i,r=0,o=t.length-1;r<o;++r)(i=t[r])in e||(e[i]={}),e=e[i];e[t[o]]=n}i.plugin(F),n.cssProperties.registerPrefix("DropDownTree","k-picker-"),n.cssProperties.registerValues("DropDownTree",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),n.cssProperties.registerPrefix("MultiSelectTree","k-input-"),n.cssProperties.registerValues("MultiSelectTree",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]);var L=n.Class.extend({init:function(e){this._dropdowntree=e},_initWrapper:function(){this._wrapper(),this._span()},_preselect:function(e){this._dropdowntree._selectValue(e)},_wrapper:function(){var e,t=this._dropdowntree,n=t.element,i=n[0];(e=n.parent()).is("span.k-dropdowntree")||((e=n.wrap("<span />").parent())[0].style.cssText=i.style.cssText,e[0].title=i.title),t._focused=t.wrapper=e.addClass("k-dropdowntree k-picker").addClass(i.className).removeClass("input-validation-error").removeClass("k-invalid").css("display","").attr({accesskey:n.attr("accesskey"),unselectable:"on"}),n.hide().removeAttr("accesskey")},_span:function(){var e,t=this._dropdowntree,n=t.wrapper,i="span.k-input-value-text";(e=n.find(i))[0]||(n.append('<span unselectable="on" class="k-input-inner"><span class="k-input-value-text"></span></span>'+r.renderButton('<button unselectable="on" class="k-input-button" aria-label="select" tabindex="-1"></button>',u({},t.options,{icon:"caret-alt-down",shape:"none",rounded:"none"}))).append(t.element),e=n.find(i)),t.span=e,t._arrow=n.find(".k-input-button"),t._arrowIcon=t._arrow.find(".k-icon,.k-svg-icon")},_setValue:function(e){var n,i=this._dropdowntree;return e===t||null===e?(e="object"==typeof(n=i._values.slice()[0])?n:i._accessor()||n)===t||null===e?"":e:(i._valueMethodCalled=!0,0===e.length?(i._clearTextAndValue(),void(i._valueMethodCalled=!1)):(i._selectItemByValue(e),i._toggleCloseVisibility(),void i._refreshFloatingLabel()))},_clearValue:function(){var e=this._dropdowntree,t=e.treeview.select(),n=e._values.length,i=!1;return e.treeview.dataItem(t)?(e.treeview.dataItem(t).set("selected",!1),i=!0):n>0&&(i=!0),!(e._valueMethodCalled||!i)},_checkLoadedItem:function(e,t){var n=this._dropdowntree;n._isNullorUndefined(t)||""===t?!t&&e.selected&&n.treeview.select(n.treeview.findByUid(e.uid)):n._valueComparer(e,t)?(n._preventChangeTrigger=!0,e.set("selected",!0),n._preventChangeTrigger=!1):e.selected&&n.treeview.select(n.treeview.findByUid(e.uid))}}),B=n.Class.extend({init:function(e){this._dropdowntree=e},_initWrapper:function(){var t=this._dropdowntree;this._tagTemplate(),t.element.attr("multiple","multiple").hide(),this._wrapper(),t._tags=new c([]),t._multipleTags=new c([]),this._tagList(),t.span=e('<span unselectable="on" class="k-input-inner"><span class="k-input-value-text"></span></span>').appendTo(t.wrapper).find(".k-input-value-text")},_preselect:function(t,i){var r=this._dropdowntree,o=i||r.options.value;Array.isArray(t)||t instanceof n.data.ObservableArray||(t=[t]),(e.isPlainObject(t[0])||t[0]instanceof n.data.ObservableObject||!r.options.dataValueField)&&(r.dataSource.data(t),r.value(o))},_tagTemplate:function(){var t=this._dropdowntree,i=t.options,a=i.valueTemplate,s="multiple"===i.tagMode,l=o(i.messages.singleTag);a=a?n.template(a):t.valueTemplate,t.valueTemplate=function(n){return r.renderChip('<span class="'+(!1===n.enabled?"k-disabled":"")+'"'+(!1===n.enabled?'aria-disabled="true"':"")+"></span>",e.extend({},i,{fillMode:"solid",themeColor:"base",rounded:"medium",attr:{unselectable:"on","aria-keyshortcuts":"Enter Delete",role:"option"},text:s?a(n):'<span unselectable="on" data-bind="text: tags.length"></span><span unselectable="on">&nbsp;'+l+"</span>",removable:s,removeIcon:"x-circle",removableAttr:{unselectable:"on","aria-hidden":!0,"aria-label":t.options.messages.deleteTag,title:t.options.messages.deleteTag}}))}},_wrapper:function(){var e=this._dropdowntree,t=e.element,n=t.parent(".k-multiselecttree");n[0]||((n=t.wrap('<span class="k-multiselecttree k-input" unselectable="on" />').parent())[0].style.cssText=t[0].style.cssText,n[0].title=t[0].title),e.wrapper=n.addClass(t[0].className).css("display","")},_tagList:function(){var t=this._dropdowntree,i=t.wrapper.children("div.k-input-values");if(!i[0]){var o="multiple"===t.options.tagMode?"tags":"multipleTag";i=e(r.renderChipList('<div unselectable="on" class="k-input-values k-selection-multiple" data-template="tagTemplate" data-bind="source: '+o+'" />',e.extend({selectable:"none"},t.options))).appendTo(t.wrapper)}t.tagList=i,t.tagList.attr("id",n.guid()+"_tagList"),t.wrapper.attr("aria-controls",t.tagList.attr("id"));var a=n.observable({multipleTag:t._multipleTags,tags:t._tags,tagTemplate:t.valueTemplate});n.bind(t.tagList,a),t.tagList.attr("data-stop",!0)},_refreshTagListAria:function(){var t=this;t.tagList&&r.renderChipList(t.tagList,e.extend({selectable:0===t.tagList.items().length?"none":"multiple"},t.options))},_setValue:function(e){var n=this._dropdowntree,i=n._values;if(e===t||null===e)return n._values.slice();n.setValue(e),n._valueMethodCalled=!0,e.length?(this._removeValues(i,e),n._checkItemByValue(e)):n._clearTextAndValue(),n._valueMethodCalled=!1,n._toggleCloseVisibility(),this._refreshTagListAria(),n._refreshFloatingLabel()},_removeValues:function(e,t){for(var n=this._dropdowntree,i=this._getNewValues(e,t),r=0;r<i.length;r++)for(var o=0;o<n._tags.length;o++)n._valueComparer(n._tags[o],i[r])&&n._uncheckItemByUid(n._tags[o].uid)},_getNewValues:function(e,t){for(var n=[],i=0;i<e.length;i++)-1===t.indexOf(e[i])&&n.push(e[i]);return n},_clearValue:function(){for(var e=this._dropdowntree,t=e._tags.slice(),n=0;n<t.length;n++){var i=t[n].uid;e._preventChangeTrigger=!0,e._uncheckItemByUid(i)}return!(!t.length||(e._preventChangeTrigger=!1,e._valueMethodCalled))},_checkLoadedItem:function(e,t){var n=this._dropdowntree;n._noInitialValue&&e.checked?n._checkValue(e):!t.length&&!this._isDataSourceSet||-1===(-1!==t.indexOf(n._currentValue(e))||t.indexOf(e))||this._findTag(n._currentValue(e))||(e.checked?n._checkValue(e):(n._preventChangeTrigger=!0,e.set("checked",!0),n._preventChangeTrigger=!1))},_findTag:function(e){var t=this._dropdowntree;return t._tags.find((function(n){return t._valueComparer(n,e)}))}});n.ui.DropDownTree.SingleSelection=L,n.ui.DropDownTree.MultipleSelection=B}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.htmlEncode,r=n.ui,o=n.html,a=r.List,s=r.Select,l=n.caret,c=n.support,d=c.placeholder,u=n._activeElement,h=n.keys,p=".kendoComboBox",f=p+"FocusEvent",m="click"+p,g="mousedown"+p,v="disabled",_="readonly",b="change",y="k-focus",w="k-disabled",k="aria-disabled",x="aria-readonly",C="filter",S="accept",T="rebind",D="mouseenter"+p+" mouseleave"+p,A=/(\r\n|\n|\r)/gm,M=[16,17,18,19,20,33,34,37,39,45,91,92,144,145],E=s.extend({init:function(t,i){var r,o=this;o.ns=p,i=Array.isArray(i)?{dataSource:i}:i,s.fn.init.call(o,t,i),i=o.options,t=o.element.on("focus"+p,o._focusHandler.bind(o)),i.placeholder=i.placeholder||t.attr("placeholder"),o._reset(),o._wrapper(),o._input(),o._clearButton(),o._tabindex(o.input),o._popup(),o._dataSource(),o._ignoreCase(),o._enable(),o._attachFocusEvents(),o._oldIndex=o.selectedIndex=-1,o._initialIndex=i.index,o.requireValueMapper(o.options),o._initList(),o._cascade(),i.autoBind?o._filterSource():(!(r=i.text)&&o._isSelect&&(r=t.children(":selected").text()),r&&o._setText(r)),r||o._placeholder(),e(o.element).parents("fieldset").is(":disabled")&&o.enable(!1),Tf({widget:o,wrapper:o.wrapper,options:o.options,prefixInsertBefore:o.input,suffixInsertAfter:o._clear.parent().length?o._clear:o.input}),n.notify(o),o._toggleCloseVisibility(),o._applyCssClasses(),i.label&&o._label(),o._aria()},options:{name:"ComboBox",enabled:!0,index:-1,text:null,value:null,autoBind:!0,delay:200,dataTextField:"",dataValueField:"",minLength:1,enforceMinLength:!1,height:200,highlightFirst:!0,filter:"none",placeholder:"",suggest:!1,cascadeFrom:"",cascadeFromField:"",cascadeFromParentField:"",cascadeOnCustomValue:!1,ignoreCase:!0,animation:{},virtual:!1,template:null,groupTemplate:e=>i(e),fixedGroupTemplate:e=>i(e),prefixOptions:{separator:!0},suffixOptions:{separator:!0},clearButton:!0,syncValueAndText:!0,autoWidth:!1,popup:null,size:"medium",fillMode:"solid",rounded:"medium",label:null,clearOnEscape:!0,_removeDataItems:!0,_shouldRefresh:!0},events:["open","close",b,"select","filtering","dataBinding","dataBound","cascade","set"],setOptions:function(e){var t=this._listOptions(e);s.fn.setOptions.call(this,e),this.listView.setOptions(t),this._accessors(),this._aria(),this._clearButton()},destroy:function(){var e=this;e.input.off(p),e.input.off(f),e.element.off(p),e.wrapper.off(p),clearTimeout(e._pasteTimeout),e.filterInput&&e.filterInput.off(p),e._arrow.off(m+" "+g),e._clear.off(m+" "+g),s.fn.destroy.call(e)},_popup:function(){s.fn._popup.call(this),this.popup.element.addClass("k-combobox-popup")},_onActionSheetCreate:function(){var e=this;e.filterInput&&(e.filterInput.on("keydown"+p,e._keydown.bind(e)).on("input"+p,e._search.bind(e)).on("paste"+p,e._inputPaste.bind(e)).attr({role:"combobox","aria-expanded":!1}),e.popup.bind("activate",(()=>{e.filterInput.val(e.input.val()),e.filterInput.trigger("focus")})),e.popup.bind("deactivate",(()=>{e.input.trigger("focus")})))},_onCloseButtonPressed:function(){var e=this,t=e.options.dataTextField||"text";if(!e.listView.focus()){if((e._syncValueAndText()||e._isSelect)&&(!e.dataItem()||e.dataItem()[t]!==e.input.val())){var n=e.filterInput&&u()===e.filterInput[0]?e.filterInput:e.input;e._accessor(n.val())}e.options.highlightFirst?(e.listView.value(e.input.val()),e._blur()):e._oldText=e.text()}},_isValueChanged:function(e){return e!==a.unifyType(this._old,typeof e)&&e!==a.unifyType(this._oldText,typeof e)},_change:function(){var e=this,t=e.text(),n=t&&t!==e._oldText&&t!==e.options.placeholder,i=e.selectedIndex,r=-1===i;if(e.filterInput&&u()===e.filterInput[0]&&r&&n&&e.input.val(e.filterInput.val()),!e.options.syncValueAndText&&!e.value()&&r&&n)return e._old="",e._oldIndex=i,e._oldText=t,e._typing||e.element.trigger(b),e.trigger(b),void(e._typing=!1);s.fn._change.call(e),e._oldText=e.text&&e.text(),e._toggleCloseVisibility()},_attachFocusEvents:function(){var e=this;e.input.on("focus"+f,e._inputFocus.bind(e)).on("focusout"+f,e._inputFocusout.bind(e))},_focusHandler:function(e){e.target===this.element[0]&&this.input.trigger("focus")},_arrowClick:function(){this._toggle()},_inputFocus:function(){this.wrapper.addClass(y),this._placeholder(!1)},_inputFocusout:function(t){var n=this,i=n.value();const r=!e(t.relatedTarget).closest(".k-clear-value").length||!e(t.relatedTarget).is(n._clear)&&e(t.relatedTarget).hasClass("k-clear-value");if(!n.filterInput||t.relatedTarget!==n.filterInput[0]){n._userTriggered=!0,n.wrapper.removeClass(y),clearTimeout(n._typingTimeout),n._typingTimeout=null,r&&n.text(n.text());var o=n._focus(),a=this.listView.dataItemByIndex(this.listView.getElementIndex(o)),s=n.select();i!==n.value()&&-1!==s&&n.trigger("select",{dataItem:a,item:o})?n.value(i):(n._placeholder(),n._valueBeforeCascade=n._old,r&&(n._blur(),n.element.trigger("blur")))}},_inputPaste:function(){var e=this;clearTimeout(e._pasteTimeout),e._pasteTimeout=null,e._pasteTimeout=setTimeout((function(){e.search()}))},_editable:function(e){var t=this,n=e.disable,i=e.readonly,r=t.wrapper.off(p),o=t.element.add(t.input.off(p)),a=t._arrow.off(m+" "+g),s=t._clear;i||n?(r.addClass(n?w:"").removeClass(n?"":w),o.attr(v,n).attr(_,i).attr(k,n).attr(x,i)):(r.removeClass(w).on(D,t._toggleHover),o.prop(v,!1).prop(_,!1).attr(k,!1).attr(x,!1),a.on(m,t._arrowClick.bind(t)).on(g,(function(e){e.preventDefault()})),s.on(m+" touchend"+p,t._clearValue.bind(t)),t.input.on("keydown"+p,t._keydown.bind(t)).on("input"+p,t._search.bind(t)).on("paste"+p,t._inputPaste.bind(t)),t.wrapper.on(m+p,t._focusHandler.bind(t))),t._toggleCloseVisibility()},open:function(){var e=this,t=e._state,n=!!e.dataSource.filter()&&e.dataSource.filter().filters.length>0,i=!e.ul.find(e.listView.focus()).length;e.popup.visible()||(!e.listView.bound()&&t!==C||t===S?(e._open=!0,e._state=T,1!==e.options.minLength&&!n||n&&e.value()&&-1===e.selectedIndex?(e.refresh(),e._openPopup(),this.options.virtual||e.listView.bound(!1)):e._filterSource()):e._allowOpening()&&(e.popup._hovered=!0,e._openPopup(),e.options.virtual?e._focusItem():i&&e.options.highlightFirst&&e.listView.focus(0)))},_scrollToFocusedItem:function(){var e=this.listView;e.scrollToIndex(e.getElementIndex(e.focus()))},_openPopup:function(){this.popup.one("activate",this._scrollToFocusedItem.bind(this)),this.popup.open()},_updateSelectionState:function(){var e=this,n=e.options.text,i=e.options.value;e.listView.isFiltered()||(-1===e.selectedIndex?(n!==t&&null!==n||(n=i),e._accessor(i),e.input.val(n||e.input.val()),e._placeholder()):-1===e._oldIndex&&(e._oldIndex=e.selectedIndex))},_buildOptions:function(e){var n=this;if(n._isSelect){var i=n._customOption;n._state===T&&(n._state=""),n._customOption=t,n._options(e,"",n.value()),i&&i[0].selected&&!n.listView._emptySearch&&n._custom(i.val())}},_updateSelection:function(){var t=this,n=t.listView,i=t._initialIndex,r=null!==i&&i>-1;if(t._state===C)e(n.focus()).removeClass("k-selected");else if(!t._fetch){n.value().length||(r?t.select(i):t._accessor()&&n.value(t._accessor())),t._initialIndex=null;var o=n.selectedDataItems()[0];o&&(t._value(o)!==t.value()?t._custom(t._value(o)):t._value(o)!==t.element[0].value&&t._accessor(t._value(o)),t.text()&&t.text()!==t._text(o)&&t._selectValue(o))}},_updateItemFocus:function(){var e=this.listView;this.options.highlightFirst?e.focus()||e.focusIndex()||e.focus(0):e.focus(-1)},_listBound:function(){var e=this,n=e.input[0]===u()||e.filterInput&&e.filterInput[0]===u(),i=e.dataSource.flatView(),r=e.listView.skip(),o=i.length,a=e.dataSource._group?e.dataSource._group.length:0,s=r===t||0===r;e._presetValue=!1,e._renderFooter(),e._renderNoData(),e._toggleNoData(!o),e._toggleHeader(!!a&&!!o),e._resizePopup(),e.popup.position(),e._buildOptions(i),e._updateSelection(),i.length&&s&&(e._updateItemFocus(),e.options.suggest&&n&&e.input.val()&&e.suggest(i[0])),e._open&&(e._open=!1,e._typingTimeout&&!n?e.popup.close():e.toggle(e._allowOpening()),e._typingTimeout=null),e._hideBusy(),e.trigger("dataBound")},_listChange:function(){this._selectValue(this.listView.selectedDataItems()[0]),this._presetValue&&(this._oldIndex=this.selectedIndex)},_get:function(e){var t,n,i;if("function"==typeof e){for(t=this.dataSource.flatView(),i=0;i<t.length;i++)if(e(t[i])){e=i,n=!0;break}n||(e=-1)}return this.dataSource.total()||e||(e=-1),e},_select:function(e,t){var n=this;return-1===(e=n._get(e))&&(n.input[0].value="",n._accessor("")),n.listView.select(e).done((function(){t||n._state!==C||(n._state=S),n._toggleCloseVisibility()}))},_selectValue:function(e){var n=this.listView.select(),i="",r="";(n=n[n.length-1])===t&&(n=-1),this.selectedIndex=n,this.listView.isFiltered()&&-1!==n&&(this._valueBeforeCascade=this._old),-1!==n||e?((e||0===e)&&(i=this._dataValue(e),r=this._text(e)),null===i&&(i="")):(this.options.syncValueAndText?i=r=this.options.dataTextField===this.options.dataValueField?this._accessor():this.input[0].value:r=this.text(),this.listView.focus(-1)),this._setDomInputValue(r),this._accessor(i!==t?i:r,n),this._placeholder(),this._triggerCascade()},_setDomInputValue:function(e){var t,n=this,i=l(this.input);if(i&&i.length&&(t=i[0]),this._prev=this.input[0].value=e,t&&-1===this.selectedIndex){var r=c.mobileOS;r.wp||r.android?setTimeout((function(){n.input[0].setSelectionRange(t,t)}),0):this.input[0].setSelectionRange(t,t)}},refresh:function(){this.listView.refresh()},_toggleCloseVisibility:function(){var e=this.element.is(":disabled")||this.element.is("[readonly]");this.text()&&!e?this._showClear():this._hideClear()},suggest:function(e){var n,i=this,r=i.input[0],o=i.text(),s=l(r)[0],c=i._last,d=i.dataSource.options.accentFoldingFiltering;c!=h.BACKSPACE&&c!=h.DELETE?("string"!=typeof(e=e||"")&&(e[0]&&(e=i.dataSource.view()[a.inArray(e[0],i.ul[0])]),e=e?i._text(e):""),s<=0&&(s=(d?o.toLocaleLowerCase(d):o.toLowerCase()).indexOf(d?e.toLocaleLowerCase(d):e.toLowerCase())+1),e?(e=e.toString(),(n=(d?e.toLocaleLowerCase(d):e.toLowerCase()).indexOf(d?o.toLocaleLowerCase(d):o.toLowerCase()))>-1&&(o+=e.substring(n+o.length))):o=o.substring(0,s),o.length===s&&e||(r.value=o,r===u()&&l(r,s,o.length))):i._last=t},text:function(e){e=null===e?"":e;var n,i,r=this,o=r.filterInput&&r.filterInput[0]===u()?r.filterInput[0]:r.input[0],s=r.options.ignoreCase,l=e;if(e===t)return o.value;!1!==r.options.autoBind||r.listView.bound()?(n=r.dataItem())&&r._text(n).replace&&r._text(n).replace(A,"")===e&&(i=r._value(n))===a.unifyType(r._old,typeof i)?r._triggerCascade():(s&&(l=l.toLowerCase()),r.dataItem()&&r._text(r.dataItem())===e||(r._select((function(e){return e=r._text(e),s&&(e=(e+"").toLowerCase()),e===l})).done((function(){r.selectedIndex<0&&(o.value=e,r.options.syncValueAndText&&r._accessor(e),r._isValueChanged(e)&&(r._cascadeTriggered=!0,r._triggerCascade()),r._refreshFloatingLabel()),r._prev=o.value})),r._toggleCloseVisibility())):r._setText(e)},toggle:function(e){this._toggle(e,!0)},value:function(e){var n=this,i=n.options,r=n.listView;if(e===t)return(e=n._accessor()||n.listView.value()[0])===t||null===e?"":e;n.requireValueMapper(n.options,e),n.trigger("set",{value:e}),(e!==i.value||n.input.val()!==i.text||n.options.cascadeFrom)&&(n._accessor(e),n._isFilterEnabled()&&r.bound()&&r.isFiltered()?n._clearFilter():n._fetchData(),r.value(e).done((function(){-1!==n.selectedIndex||r._selectedDataItems&&r._selectedDataItems.length||(n._accessor(e),n.input.val(e),n._placeholder(!0)),n._userTriggered?n._old=n._accessor():n._old=n._valueBeforeCascade=n._accessor(),n._oldIndex=n.selectedIndex,n._prev=n._oldText=n.input.val(),n._state===C&&(n._state=S),n._toggleCloseVisibility(),n._refreshFloatingLabel()})))},_click:function(e){var t=this,n=e.item,i=t.listView.dataItemByIndex(t.listView.getElementIndex(n)),r=!0;e.preventDefault(),i&&((r=t._value(i)!==a.unifyType(t.value(),typeof t._value(i)))||t.input.val(t._text(i))),r&&t.trigger("select",{dataItem:i,item:n})?t.close():(t._userTriggered=!0,t._select(n).done((function(){t._blur()})))},_syncValueAndText:function(){return this.options.syncValueAndText},_inputValue:function(){return this.text()},_searchByWord:function(e){var n=this,i=n.options,r=n.dataSource,o=i.ignoreCase;if(o&&(e=e.toLowerCase()),n.ul[0].firstChild){this.listView.focus(this._get((function(i){var r=n._text(i);if(r!==t)return(""==(r+="")||""!==e)&&(o&&(r=r.toLowerCase()),0===r.indexOf(e))})));var a=this.listView.focus();a&&(i.suggest&&n.suggest(a),this.open()),this.options.highlightFirst&&!e&&this.listView.focusFirst()}else r.one(b,(function(){r.view()[0]&&n.search(e)})).fetch()},_input:function(){var e,t,i,r=this,a=r.element.removeClass("k-input-inner")[0],s=a.accessKey,l=r.wrapper,c="input.k-input-inner",u=a.name||"",h=r.options;u&&(u='name="'+u+'_input" '),(e=l.find(c))[0]||(i=o.renderButton('<button type="button" class="k-input-button" aria-label="expand combobox"></button>',{icon:"caret-alt-down",size:h.size,fillMode:h.fillMode,shape:"none",rounded:"none"}),l.append("<input "+u+'class="k-input-inner" type="text" autocomplete="off"/>').append(i).append(r.element),e=l.find(c)),e[0].style.cssText=a.style.cssText,e[0].title=a.title,(t=parseInt(this.element.prop("maxlength")||this.element.attr("maxlength"),10))>-1&&(e[0].maxLength=t),e.addClass(a.className).css({width:"",height:a.style.height,position:""}).attr({role:"combobox","aria-expanded":!1}).show(),e.attr(n.attr("skip"),!0),d&&e.attr("placeholder",r.options.placeholder),s&&(a.accessKey="",e[0].accessKey=s),r._focused=r.input=e,r._arrow=l.find(".k-input-button").attr({role:"button",tabIndex:-1}),r._arrowIcon=r._arrow.find(".k-icon, .k-svg-icon")},_clearButton:function(){a.fn._clearButton.call(this),this.options.clearButton&&this._clear.insertAfter(this.input)},_keydown:function(e){var t=this,n=e.keyCode,i=t.options.dataTextField||"text",r=n>=112&&n<=135,o=M.indexOf(n)>-1;if(t._last=n,clearTimeout(t._typingTimeout),t._typingTimeout=null,n===h.HOME)t._firstItem();else if(n===h.END)t._lastItem();else if(n===h.ENTER||n===h.TAB&&t.popup.visible()){var s=t.listView.focus(),l=t.dataItem(),c=!0;if(t.popup.visible()||l&&t.text()===t._text(l)||(s=null),s){if(t.popup.visible()&&e.preventDefault(),(l=t.listView.dataItemByIndex(t.listView.getElementIndex(s)))&&(c=t._value(l)!==a.unifyType(t.value(),typeof t._value(l))),c&&t.trigger("select",{dataItem:l,item:s}))return;t._userTriggered=!0,t._select(s).done((function(){t._blur(),t._valueBeforeCascade=t._old=t.value()}))}else{if((t._syncValueAndText()||t._isSelect)&&(!t.dataItem()||t.dataItem()[i]!==t.input.val())){var d=t.filterInput&&u()===t.filterInput[0]?t.filterInput:t.input;t._accessor(d.val())}t.options.highlightFirst?(t.listView.value(t.input.val()),t._blur()):t._oldText=t.text()}}else n==h.TAB||t._move(e)||o||r||e.ctrlKey?t.options.clearOnEscape&&n===h.ESC&&!t.popup.visible()&&t.text()&&t._clearValue():t._search()},_placeholder:function(e){if(!d){var n,i=this,r=i.input,o=i.options.placeholder;if(o){if(n=i.value(),e===t&&(e=!n),r.toggleClass("k-readonly",e),!e){if(n)return;o=""}r.val(o),o||r[0]!==u()||l(r[0],0,0)}}},_search:function(){var e=this;clearTimeout(e._typingTimeout),e._typingTimeout=setTimeout((function(){var n=e.text();""!==n&&e._prev!==n?(e._prev=n,"none"===e.options.filter&&e.options.virtual&&e.listView.select(-1),e.search(n),e._toggleCloseVisibility()):""===n&&""!==e._prev&&e._prev!==t&&(e._clearValue(),e._open=!0,e._state=T),e._typingTimeout=null}),e.options.delay)},_setText:function(e){this.input.val(e),this._prev=e},_wrapper:function(){var e=this.element,t=e.parent();t.is("span.k-input")||((t=e.hide().wrap("<span />").parent())[0].style.cssText=e[0].style.cssText),this.wrapper=t.addClass("k-input k-combobox").addClass(e[0].className).removeClass("input-validation-error").css("display","")},_clearSelection:function(e,t){var n=e.value(),i=n&&-1===e.selectedIndex;-1==this.selectedIndex&&this.value()||(t||!n||i)&&(this.options.value="",this.value(""))},_preselect:function(e,t){this.input.val(t),this._accessor(e),this._old=this._accessor(),this._oldIndex=this.selectedIndex,this.listView.setValue(e),this._placeholder(),this._initialIndex=null,this._presetValue=!0,this._toggleCloseVisibility()},_clearText:function(){this._old=this.value(),this.text("")},_clearValue:function(){var e=this,t=e.filterInput&&e.filterInput[0]===u()?e.filterInput:e.input;s.fn._clearValue.call(this),t.trigger("focus")}});r.plugin(E),n.cssProperties.registerPrefix("ComboBox","k-input-"),n.cssProperties.registerValues("ComboBox",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}])}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=i.List,o=n.htmlEncode,a=n.html,s=e.extend({A:65},n.keys),l=n._activeElement,c=n.data.ObservableArray,d="id",u=".k-chip",h="accept",p="filter",f="rebind",m="open",g="close",v="change",_="select",b="deselect",y="aria-disabled",w="aria-readonly",k="aria-expanded",x="aria-hidden",C="aria-activedescendant",S="k-focus",T="k-selected",D="k-hover",A="k-disabled",M="k-no-click",E="disabled",I="readonly",z=".kendoMultiSelect",P="click"+z,H="keydown"+z,F="mouseenter"+z,R="mouseleave"+z,L=F+" "+R,B=/"/g,O=Array.isArray,V=["font-family","font-size","font-stretch","font-style","font-weight","letter-spacing","text-transform","line-height"],N=r.extend({init:function(t,i){var o,a=this;a.ns=z,r.fn.init.call(a,t,i),a._optionsMap={},a._customOptions={},a._wrapper(),a._inputValuesContainer(),a._tagList(),a._input(),a._textContainer(),a._clearButton(),a._arrowButton(),a._tabindex(a.input),t=a.element.attr("multiple","multiple").hide(),(i=a.options).placeholder||(i.placeholder=t.data("placeholder")),(o=t.attr(d))||(o=n.guid()),o&&(a._tagID=o+"_tag_active",o+="_taglist",a.tagList.attr(d,o)),a._initialOpen=!0,i.label&&this._label(),a._aria(),a._dataSource(),a._ignoreCase(),a._popup(),a._tagTemplate(),a.requireValueMapper(a.options),a._initList(),a._reset(),a._enable(),a._placeholder(),i.autoBind?a.dataSource.fetch():i.value&&a._preselect(i.value),e(a.element).parents("fieldset").is(":disabled")&&a.enable(!1),a._toggleCloseVisibility(),a._applyCssClasses(),Tf({widget:a,wrapper:a.wrapper,options:a.options,prefixInsertBefore:a._inputValuesContainer,suffixInsertAfter:i.clearButton?a._clear:a.element.find("k-input-values")}),a.floatingLabel&&a.floatingLabel.refresh(),n.notify(a)},options:{name:"MultiSelect",tagMode:"multiple",enabled:!0,autoBind:!0,autoClose:!0,highlightFirst:!0,dataTextField:"",dataValueField:"",filter:"startswith",ignoreCase:!0,minLength:1,messages:{singleTag:"item(s) selected",clear:"clear",deleteTag:"delete",noData:"No data found.",downArrow:"select"},enforceMinLength:!1,delay:100,value:null,maxSelectedItems:null,placeholder:"",height:200,animation:{},virtual:!1,itemTemplate:"",tagTemplate:"",groupTemplate:e=>o(e),fixedGroupTemplate:e=>o(e),prefixOptions:{separator:!0},suffixOptions:{separator:!0},clearButton:!0,autoWidth:!1,popup:null,size:"medium",fillMode:"solid",rounded:"medium",label:null},events:[m,g,v,_,b,"filtering","dataBinding","dataBound"],setDataSource:function(e){this.options.dataSource=e,this._state="",this._dataSource(),this.persistTagList=!1,this.listView.setDataSource(this.dataSource),this.options.autoBind&&this.dataSource.fetch()},setOptions:function(e){var t=this._listOptions(e);r.fn.setOptions.call(this,e),this.listView.setOptions(t),this._accessors(),this._aria(),this._tagTemplate(),this._placeholder(),this._clearButton(),this._arrowButton()},currentTag:function(e){var n=this;if(e===t)return n._currentTag;n._currentTag&&(n._currentTag.removeClass(S).removeAttr(d),n._currentTag.find(".k-chip-action").attr(x,!0),n.input.removeAttr(C)),e&&(e.addClass(S).attr(d,n._tagID),e.find(".k-chip-action").removeAttr(x),n.input.attr(C,n._tagID)),n._currentTag=e},dataItems:function(){return this.listView.selectedDataItems()},destroy:function(){var e=this,t=e.ns;clearTimeout(e._busy),clearTimeout(e._typingTimeout),e.filterInput&&e.filterInput.off(t),e.wrapper.off(t),e.tagList.off(t),e.input.off(t),e._clear.off(t),r.fn.destroy.call(e)},_onActionSheetCreate:function(){var e=this;e.filterInput.on("keydown"+z,e._keydown.bind(e)).on("input"+z,e._search.bind(e)).on("paste"+z,e._search.bind(e)).attr({role:"combobox","aria-expanded":!1,"aria-controls":e.input.attr("aria-controls"),"aria-autocomplete":e.input.attr("aria-autocomplete"),"aria-describedby":e.input.attr("aria-describedby")}),e.popup.bind("activate",(()=>{e.filterInput.val(e.input.val()),e.filterInput.trigger("focus")})),e.popup.bind("close",(()=>{e.input.trigger("focus")}))},_aria:function(){var e=this,t=e.ul[0].id,n="none"===this.options.filter?"none":"list",i=e.tagList.attr(d);e.input.attr({role:"combobox","aria-expanded":!1,"aria-controls":t,"aria-autocomplete":n,"aria-describedby":i}),e._ariaLabel(e._focused)},_activateItem:function(){this.popup.visible()&&r.fn._activateItem.call(this),this.currentTag(null)},_listOptions:function(t){var i=this,a=r.fn._listOptions.call(i,e.extend(t,{selectedItemChange:i._selectedItemChange.bind(i),selectable:"multiple"})),s=this.options.itemTemplate||this.options.template,l=a.itemTemplate||s||a.template;return l||(l=e=>o(n.getter(a.dataTextField)(e))),a.template=l,a},_setListValue:function(){r.fn._setListValue.call(this,this._initialValues.slice(0))},_listChange:function(e){var n=this.dataSource.flatView(),i=this._optionsMap,r=this._value;this._state===f&&(this._state="");for(var o=0;o<e.added.length;o++)if(i[r(e.added[o].dataItem)]===t){this._render(n);break}this._selectValue(e.added,e.removed)},_selectedItemChange:function(e){var t,n,i=e.items;for(n=0;n<i.length;n++)t=i[n],this.tagList.children(u).eq(t.index).children("span").first().html(this.tagTextTemplate(t.item))},_wrapperMousedown:function(t){var i=this,r="input"!==t.target.nodeName.toLowerCase(),o=e(t.target),a=o.closest(".k-input-button, .k-chip").children("[class*='-i-caret-alt-down']")[0],s=o.closest("[class*='-i-x']")[0];!r||s&&n.support.mobileOS||!t.cancelable||t.preventDefault(),s||(a&&i.popup.visible()?i.toggle(!1):(i.input[0]!==l()&&r&&i.input.trigger("focus"),1!==i.options.minLength||i.popup.visible()||i.open()))},_inputFocus:function(){this._placeholder(!1,!0),this.wrapper.addClass(S)},_inputFocusout:function(e){var t=this;t.filterInput&&e.relatedTarget===t.filterInput[0]||(clearTimeout(t._typingTimeout),t.wrapper.removeClass(S),t._placeholder(!t.listView.selectedDataItems()[0],!0),t.close(),t._state===p&&(t._state=h,t.listView.skipUpdate(!0)),t.listView.bound()&&t.listView.isFiltered()&&(t.persistTagList=!0,t._clearFilter()),t.element.trigger("blur"))},_removeTag:function(e,n){var i,r=this,o=r._state,a=e.index(),s=r.listView,l=s.value()[a],c=r.listView.selectedDataItems()[a],d=r._customOptions[l],u=s.element[0].children;if(r.trigger(b,{dataItem:c,item:e}))r._close();else{d!==t||o!==h&&o!==p||(d=r._optionsMap[l]);var f=function(){r.currentTag(null),n&&r._change(),r._refreshTagListAria(),r._close()};d===t&&s.select().length?(r.persistTagList=!1,s.select(s.select()[a]).done(f)):((i=r.element[0].children[d])&&(i.selected=!1),s.removeAt(a),s._removedAddedIndexes&&s._removedAddedIndexes.splice(a,1),u[d]&&u[d].classList.remove("k-selected"),"single"!==r.options.tagMode?e.remove():r._updateTagListHTML(),f())}},_tagListClick:function(t){t.preventDefault(),t.stopPropagation();var n=e(t.currentTarget);n.is("[class*='-i-x-circle']")&&this._removeTag(n.closest(u),!0)},_clearValue:function(){var t=this;"single"===t.options.tagMode?t._clearSingleTagValue():t.tagList.children(u).each((function(n,i){t._removeTag(e(i),!1)})),t.input.val(""),t._search(!0),t._change(),t.focus(),t._hideClear(),t._state===p&&(t._state=h)},_clearSingleTagValue:function(){for(var e=this,t=e.dataItems(),n=e.tagList.children(u),i=e.persistTagList,r=0;r<t.length;r+=1)if(e.trigger(b,{dataItem:t[r],item:n.first()}))return void e._close();i&&(e.persistTagList=!1),e.listView.value([]),e.persistTagList=i},_focusHandler:function(){var e=this.input,t=l();e[0]===t||this.input.trigger("focus")},_editable:function(t){var n=this,i=t.disable,r=t.readonly,o=n.wrapper.off(z),a=n.tagList.off(z),s=n.input.off(z);r||i?(o.toggleClass(A,i).toggleClass(M,r),s.attr(E,i).attr(I,r).attr(y,i).attr(w,r),n.element.prop(E,i)):(o.removeClass(A).removeClass(M).on(L,n._toggleHover).on("mousedown"+z+" touchend"+z,n._wrapperMousedown.bind(n)).on(P,n._focusHandler.bind(n)),n.input.on(H,n._keydown.bind(n)).on("paste"+z,n._search.bind(n)).on("input"+z,n._search.bind(n)).on("focus"+z,n._inputFocus.bind(n)).on("focusout"+z,n._inputFocusout.bind(n)),n._clear.on(P+" touchend"+z,n._clearValue.bind(n)),s.prop(E,!1).prop(I,!1).attr(y,!1).attr(w,!1),n.element.prop(E,!1),a.on(F,u,(function(){e(this).addClass(D)})).on(R,u,(function(){e(this).removeClass(D)})).on(P+" touchend"+z,".k-chip .k-icon,.k-chip .k-svg-icon",n._tagListClick.bind(n)))},_close:function(){var e=this;e.options.autoClose?e.close():e.popup.position()},_filterSource:function(e,t){t||(t=this._retrieveData),this._retrieveData=!1,r.fn._filterSource.call(this,e,t)},close:function(){this._activeItem=null,this.input.removeAttr(C),this.popup.close()},open:function(){var t=this,n=t.input.val().toLowerCase(),i=t.listView.dataSource.filter(),r="";i&&i.filters.length>0&&(r=(i.filters[0].value||"").toString().toLowerCase()),t._request&&(t._retrieveData=!1),t._retrieveData||!t.listView.bound()||t._state===h&&n!==r?(t._open=!0,t._state=f,t.listView.skipUpdate(!0),t.persistTagList=!(t._initialOpen&&!t.listView.bound()),t._filterSource(),t._focusItem()):t._allowOpening()&&(!t._initialOpen||t.options.autoBind||t.options.virtual||!t.options.value||e.isPlainObject(t.options.value[0])||t.value(t.value()||t._initialValues),t.popup._hovered=!0,t._initialOpen=!1,t.popup.open({altTarget:t.wrapper.add(t.element).add(t.input)}),t._focusItem())},toggle:function(e){this[(e=e!==t?e:!this.popup.visible())?m:g]()},refresh:function(){this.listView.refresh()},_floatCheck:function(){return!this.listView||!(this.value()&&this.value().length)&&!this.popup.visible()},_listBound:function(){var e=this,t=e.dataSource.flatView();e._render(t),e._renderFooter(),e._renderNoData(),e._toggleNoData(!t.length),e._resizePopup(),e._open&&(e._open=!1,e.toggle(e._allowOpening())),e.popup.position(),e._updateItemFocus(),e._touchScroller&&e._touchScroller.reset(),e._hideBusy(),e.trigger("dataBound")},_updateItemFocus:function(){var e=this,n=e.dataSource.flatView(),i=e.listView.skip(),r=i===t||0===i;n.length&&r&&(e.options.highlightFirst?e.listView.focusFirst():e.listView.focus(-1))},_inputValue:function(){var e=this,t=e.filterInput&&l()===e.filterInput[0]?e.filterInput.val():e.input.val();return e.options.placeholder===t&&(t=""),t},value:function(e){var n=this,i=n.listView,r=i.value().slice(),o=n.options.maxSelectedItems,a=i.bound()&&i.isFiltered();if(e===t)return r;n.persistTagList=!1,n.requireValueMapper(n.options,e),e=n._normalizeValues(e),null!==o&&e.length>o&&(e=e.slice(0,o)),a&&n._clearFilter(),i.value(e),n._old=n._valueBeforeCascade=e.slice(),a||n._fetchData(),n._toggleCloseVisibility()},_preselect:function(t,i){var r=this;O(t)||t instanceof n.data.ObservableArray||(t=[t]),(e.isPlainObject(t[0])||t[0]instanceof n.data.ObservableObject||!r.options.dataValueField)&&(r.dataSource.data(t),r.value(i||r._initialValues),r._retrieveData=!0)},_setOption:function(e,t){var n=this.element[0].children[this._optionsMap[e]];n&&(n.selected=t)},_fetchData:function(){var e=this,t=!!e.dataSource.view().length;0===e.listView.value().length||e._request||(e._retrieveData||!e._fetch&&!t)&&(e._fetch=!0,e._retrieveData=!1,e.dataSource.read().done((function(){e._fetch=!1})))},_isBound:function(){return this.listView.bound()&&!this._retrieveData},_dataSource:function(){var e=this,t=e.element,i=e.options,r=i.dataSource||{};(r=O(r)?{data:r}:r).select=t,r.fields=[{field:i.dataTextField},{field:i.dataValueField}],e.dataSource&&e._refreshHandler?e._unbindDataSource():(e._progressHandler=e._showBusy,e._endRequestHandler=e._hideBusy,e._errorHandler=function(){e._hideBusy()}),e.dataSource=n.data.DataSource.create(r).bind("progress",e._progressHandler).bind("requestEnd",e._endRequestHandler).bind("error",e._errorHandler)},_reset:function(){var t=this,n=t.element,i=n.attr("form"),r=i?e("#"+i):n.closest("form");r[0]&&(t._resetHandler=function(){setTimeout((function(){t.value(t._initialValues),t._placeholder()}))},t._form=r.on("reset",t._resetHandler))},_initValue:function(){var e=this.options.value||this.element.val();this._old=this._initialValues=this._normalizeValues(e)},_normalizeValues:function(t){var n=this;return null===t?t=[]:t&&e.isPlainObject(t)?t=[n._value(t)]:t&&e.isPlainObject(t[0])?t=e.map(t,(function(e){return n._value(e)})):O(t)||t instanceof c?O(t)&&(t=t.slice()):t=[t],t},_change:function(){var e=this,t=e.value();(function(e,t){var n;if(null===e&&null!==t||null!==e&&null===t)return!1;if((n=e.length)!==t.length)return!1;for(;n--;)if(e[n]!==t[n])return!1;return!0})(t,e._old)||(e._old=t.slice(),e.trigger(v),e.element.trigger(v)),e.popup.position(),e._toggleCloseVisibility()},_click:function(e){var t=this,n=e.item;e.preventDefault(),t._select(n).done((function(){t._activeItem=n,t._change(),t._close()}))},_getActiveItem:function(){return this._activeItem||e(this.listView.items()[this._getSelectedIndices().length-1])||this.listView.focus()},_getSelectedIndices:function(){return this.listView._selectedIndices||this.listView._selectedIndexes},_keydown:function(i){var r,o=this,a=i.keyCode,l=o._currentTag,c=o.listView,d=o.input.val(),p=n.support.isRtl(o.wrapper),f=o.popup.visible(),m=0,g=!1;if(a!==s.ENTER&&(this._multipleSelection=!1),a===s.DOWN){if(i.preventDefault(),!f)return o.open(),c.focus()||c.focusFirst(),void i.stopPropagation();c.focus()?(!o._activeItem&&i.shiftKey&&(o._activeItem=c.focus(),m=-1),r=c.getElementIndex(o._getActiveItem().first()),c.focusNext(),c.focus()?i.shiftKey&&!o.options.virtual&&(this._multipleSelection=!0,o._selectRange(r,c.getElementIndex(c.focus().first())+m)):c.focusLast()):c.focusFirst(),g=!0}else if(a===s.UP)f&&(!o._activeItem&&i.shiftKey&&(o._activeItem=c.focus(),m=1),r=c.getElementIndex(o._getActiveItem().first()),c.focusPrev(),c.focus()?i.shiftKey&&!o.options.virtual&&(this._multipleSelection=!0,o._selectRange(r,c.getElementIndex(c.focus().first())+m)):o.close()),g=!0,i.preventDefault();else if(a===s.LEFT&&!p||a===s.RIGHT&&p)d||(l=l?l.prev(u):o.tagList.children(u).last())[0]&&o.currentTag(l),g=!0;else if(a===s.RIGHT&&!p||a===s.LEFT&&p)!d&&l&&(l=l.next(u),o.currentTag(l[0]?l:null)),g=!0;else if(i.ctrlKey&&!i.altKey&&a===s.A&&f&&!o.options.virtual)this._multipleSelection=!0,this._getSelectedIndices().length===c.items().length&&(o._activeItem=null),c.items().length&&o._selectRange(0,c.items().length-1),g=!0;else if(a===s.ENTER&&f){if(!c.focus())return void i.stopPropagation();if(i.preventDefault(),this._multipleSelection&&(this._multipleSelection=!1,c.focus().hasClass(T)))return o._close(),void i.stopPropagation();o._select(c.focus()).done((function(){o._change(),o._close()})),g=!0}else if(a===s.SPACEBAR&&i.ctrlKey&&f)o._activeItem&&c.focus()&&c.focus()[0]===o._activeItem[0]&&(o._activeItem=null),e(c.focus()).hasClass(T)||(o._activeItem=c.focus()),o._select(c.focus()).done((function(){o._change()})),g=!0,i.preventDefault();else if(a===s.SPACEBAR&&i.shiftKey&&f&&!o.options.virtual){var v=c.getElementIndex(o._getActiveItem()),_=c.getElementIndex(c.focus());v!==t&&_!==t&&o._selectRange(v,_),g=!0,i.preventDefault()}else if(a===s.ESC)f?i.preventDefault():(o.tagList.children(u).each((function(t,n){o._removeTag(e(n),!1)})),o._change()),o.close(),g=!0;else if(a===s.HOME)f?c.focus()?(i.ctrlKey&&i.shiftKey&&!o.options.virtual&&o._selectRange(c.getElementIndex(c.focus()[0]),0),c.focusFirst()):o.close():d||(l=o.tagList.children(u).first()[0])&&o.currentTag(e(l)),g=!0;else if(a===s.END)f?c.focus()?(i.ctrlKey&&i.shiftKey&&!o.options.virtual&&o._selectRange(c.getElementIndex(c.focus()[0]),c.element.children().length-1),c.focusLast()):o.close():d||(l=o.tagList.children(u).last()[0])&&o.currentTag(e(l)),g=!0;else if(a!==s.DELETE&&a!==s.BACKSPACE||d)if(!o.popup.visible()||a!==s.PAGEDOWN&&a!==s.PAGEUP)clearTimeout(o._typingTimeout),o._search(),g=!0;else{i.preventDefault();var b=a===s.PAGEDOWN?1:-1;c.scrollWith(b*c.screenHeight()),g=!0}else{if(o._state=h,"single"===o.options.tagMode)return o._clearSingleTagValue(),o._change(),o._close(),void i.stopPropagation();a!==s.BACKSPACE||l||(l=o.tagList.children(u).last()),l&&l[0]&&o._removeTag(l,!0),g=!0}g&&i.stopPropagation()},_placeholder:function(e,i){var r=this,o=r.input,a=l(),s=r.options.placeholder,c=o.val(),d=o[0]===a,u=c.length;d&&!r.options.autoClose&&c!==s||(u=0,c=""),e===t&&(e=!1,o[0]!==a&&(e=!r.listView.selectedDataItems()[0])),r._prev=c,o.toggleClass("k-readonly",e).val(e?s:c),d&&!i&&n.caret(o[0],u,u)},_option:function(e,i,r){var o="<option";return e!==t&&(-1!==(e+="").indexOf('"')&&(e=e.replace(B,"&quot;")),o+=' value="'+e+'"'),r&&(o+=" selected"),o+=">",i!==t&&(o+=n.htmlEncode(i)),o+"</option>"},_render:function(e){var t,n,i,r,o=this.listView.selectedDataItems(),a=this.listView.value(),s=e.length,l="";a.length!==o.length&&(o=this._buildSelectedItems(a));var c={},d={};for(r=0;r<s;r++)n=e[r],i=this._value(n),-1!==(t=this._selectedItemIndex(i,o))&&o.splice(t,1),d[i]=r,l+=this._option(i,this._text(n),-1!==t);if(o.length)for(r=0;r<o.length;r++)n=o[r],c[i=this._value(n)]=s,d[i]=s,s+=1,l+=this._option(i,this._text(n),!0);this._customOptions=c,this._optionsMap=d,this.element.html(l)},_buildSelectedItems:function(e){for(var t,n=this.options.dataValueField,i=this.options.dataTextField,r=[],o=0;o<e.length;o++)(t={})[n]=e[o],t[i]=e[o],r.push(t);return r},_selectedItemIndex:function(e,t){for(var n=this._value,i=0;i<t.length;i++)if(e===n(t[i]))return i;return-1},_search:function(e){let t=this;!0!==e?(clearTimeout(t._typingTimeout),t._typingTimeout=setTimeout((function(){t._performSearch()}),t.options.delay)):t._performSearch()},_performSearch:function(){var e=this,t=e._inputValue();e._prev!==t&&(e._prev=t,e.search(t),e._toggleCloseVisibility())},_toggleCloseVisibility:function(){this.value().length||this.input.val()&&this.input.val()!==this.options.placeholder?this._showClear():this._hideClear()},_allowOpening:function(){return this._allowSelection()&&r.fn._allowOpening.call(this)},_allowSelection:function(){var e=this.options.maxSelectedItems;return null===e||e>this.listView.value().length},updatePersistTagList:function(e,t){this.persistTagList.added&&this.persistTagList.added.length===t.length&&this.persistTagList.removed&&this.persistTagList.removed.length===e.length?this.persistTagList=!1:(this.listView._removedAddedIndexes=this._old.slice(),this.persistTagList={added:e,removed:t})},_selectValue:function(e,t){var i,r,o,a=this,s=a.dataSource.total(),l=a.tagList,c=a._value;if(this.persistTagList)return this.updatePersistTagList(e,t),void a._refreshTagListAria();if("multiple"===a.options.tagMode){for(o=t.length-1;o>-1;o--)i=t[o],l.children(u).length&&(l[0].removeChild(l[0].children[i.position]),a._setOption(c(i.dataItem),!1));for(o=0;o<e.length;o++)r=e[o],a.tagList.append(a.tagTemplate(r.dataItem)),a._setOption(c(r.dataItem),!0);n.applyStylesFromKendoAttributes(a.tagList,["background-color"])}else{for((!a._maxTotal||a._maxTotal<s)&&(a._maxTotal=s),this._updateTagListHTML(),o=t.length-1;o>-1;o--)a._setOption(c(t[o].dataItem),!1);for(o=0;o<e.length;o++)a._setOption(c(e[o].dataItem),!0)}a._refreshTagListAria(),a._refreshFloatingLabel(),a._placeholder()},_refreshTagListAria:function(){var t=this;a.renderChipList(t.tagList,e.extend({selectable:0===t.value().length?"none":"multiple"},t.options))},_updateTagListHTML:function(){var t=this,i=t.value(),r=t.dataSource.total();t.tagList.children(u).each((function(t,n){e(n).remove()})),i.length&&(t.tagList.append(t.tagTemplate({values:i,dataItems:t.dataItems(),maxTotal:t._maxTotal,currentTotal:r})),n.applyStylesFromKendoAttributes(t.tagList,["background-color"])),t._refreshTagListAria()},_select:function(t){var n=e.Deferred().resolve();if(!t)return n;var i=this,r=i.listView,o=r.dataItemByIndex(r.getElementIndex(t)),a=t.hasClass("k-selected");return i._state===f&&(i._state=""),i._allowSelection()||a?i.trigger(a?b:_,{dataItem:o,item:t})?(i._close(),n):(i.persistTagList=!1,r.select(t).done((function(){i._placeholder(),i._state===p&&(i._state=h,r.skipUpdate(!0))}))):n},_selectIndices:function(t){let n=this.listView,i=this;n.select(t).done((function(){t.forEach((function(t){var r=n.dataItemByIndex(t),o=n.element.children()[t],a=e(o).hasClass("k-selected");i.trigger(a?_:b,{dataItem:r,item:e(o)})})),i._change()}))},_selectRange:function(e,t){var n,i=this,r=this.options.maxSelectedItems,o=this._getSelectedIndices().slice(),a=[];if(o.length-1==t-e)return i._selectIndices(o);if(e<t)for(n=e;n<=t;n++)a.push(n);else for(n=e;n>=t;n--)a.push(n);for(null!==r&&a.length>r&&(a=a.slice(0,r)),n=0;n<a.length;n++){var s=a[n];-1==this._getSelectedIndices().indexOf(s)?o.push(s):o.splice(o.indexOf(s),1)}return o.length?(i.persistTagList=!1,i._selectIndices(o)):void 0},_input:function(){var t=this,n=t.element,i=n[0].accessKey,r=t._inputValuesContainer.children("input.k-input-inner");r[0]||(r=e('<input class="k-input-inner" />').appendTo(t._inputValuesContainer)),n.removeAttr("accesskey"),r.attr("data-validate","false"),t._focused=t.input=r.attr({autocomplete:"off",title:n[0].title}),i&&t._focused.attr("accesskey",i)},_inputValuesContainer:function(){var t=this,n=t.wrapper.children(".k-input-values");n[0]||(n=e('<div class="k-input-values"></div>').appendTo(t.wrapper)),t._inputValuesContainer=n},_tagList:function(){var t=this,n=t.options,i=t._inputValuesContainer.children(".k-chip-list");i[0]||(i=e(a.renderChipList('<div unselectable="on" class="k-selection-multiple" />',e.extend({selectable:"none"},n))).appendTo(t._inputValuesContainer)),t.tagList=i},_tagTemplate:function(){var t,i,r=this,s=r.options,l=s.tagTemplate,c=s.dataSource,d="multiple"===s.tagMode,u=s.messages.singleTag;r.element[0].length&&!c&&(s.dataTextField=s.dataTextField||"text",s.dataValueField=s.dataValueField||"value"),i=({values:e})=>`${e.length} ${o(u)}`,t=d?e=>o(n.getter(s.dataTextField)(e)):i,r.tagTextTemplate=l=l?n.template(l):t,r.tagTemplate=function(t){return a.renderChip('<span unselectable="on"></span>',e.extend({},s,{fillMode:"solid",rounded:"medium",enabled:!0,themeColor:"base",text:l(t),attr:{unselectable:"on","aria-selected":!0,role:"option","aria-keyshortcuts":d?"Enter Delete":"Enter"},removable:d,removableAttr:{unselectable:"on","aria-hidden":!0,"aria-label":r.options.messages.deleteTag,title:r.options.messages.deleteTag},icon:d?"":"caret-alt-down",iconAttr:{unselectable:"on","aria-hidden":!0,"aria-label":"open"}}))}},_popup:function(){r.fn._popup.call(this),this.popup.element.addClass("k-multiselect-popup")},_clearButton:function(){r.fn._clearButton.call(this),this.options.clearButton&&this._clear.insertAfter(this._inputValuesContainer)},_arrowButton:function(){var t=o(this.options.messages.downArrow),n=e(a.renderButton('<button type="button" aria-label="'+t+'" class="k-input-button"></button>',e.extend({},this.options,{icon:"caret-alt-down",rounded:null})));this._arrow&&(this._arrow.remove(),this._arrow=null),this.options.downArrow&&(this._arrow=n.attr({tabIndex:-1}),this._arrow.appendTo(this.wrapper))},_textContainer:function(){var t=n.getComputedStyles(this.input[0],V);t.position="absolute",t.visibility="hidden",t.top=-3333,t.left=-3333,this._span=e("<span/>").css(t).appendTo(this.wrapper)},_wrapper:function(){var e=this.element,t=e.parent("span.k-multiselect");t[0]||((t=e.wrap('<span class="k-multiselect k-input" unselectable="on" />').parent())[0].style.cssText=e[0].style.cssText),this.wrapper=t.addClass(e[0].className).removeClass("input-validation-error").css("display","")},_closeHandler:function(e){this.trigger(g)?e.preventDefault():(this.input.attr(k,!1),this.ul.attr(x,!0))},_openHandler:function(e){this._adjustListWidth(),this.trigger(m)?e.preventDefault():(this.input.attr(k,!0),this.ul.attr(x,!1))}});i.plugin(N),n.cssProperties.registerPrefix("MultiSelect","k-input-"),n.cssProperties.registerValues("MultiSelect",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}])}(window.kendo.jQuery);kendo;!function(){var e=window.kendo,t=e.ui,n=t.ComboBox,i=t.Select,r=/^\d+(\.\d+)?%$/i,o=n.extend({init:function(e,t){n.fn.init.call(this,e,t),this.list.parent().addClass("k-dropdowngrid-popup"),this._allColumnsWidthsAreSet(this.options)?this.list.parent().width(this._calculateDropDownWidth(this.options)):this.options.dropDownWidth&&this.list.parent().width(this.options.dropDownWidth)},options:{name:"MultiColumnComboBox",ns:".kendoMultiColumnComboBox",columns:[],dropDownWidth:null,filterFields:[]},setOptions:function(e){n.fn.setOptions.call(this,e),this._allColumnsWidthsAreSet(e)?this.list.parent().width(this._calculateDropDownWidth(e)):this.options.dropDownWidth&&this.list.parent().width(this.options.dropDownWidth)},_popup:function(){i.fn._popup.call(this),this.popup.element.removeClass("k-list-container")},_allColumnsWidthsAreSet:function(e){var t=e.columns;if(!t||!t.length)return!1;for(var n=0;n<t.length;n++){var i=t[n].width;if(!i||isNaN(parseInt(i,10))||r.test(i))return!1}return!0},_calculateDropDownWidth:function(t){for(var n=t.columns,i=e.support.scrollbar(),r=0;r<n.length;r++){var o=n[r].width;i+=parseInt(o,10)}return i},_wrapper:function(){n.fn._wrapper.call(this),this.wrapper.addClass("k-dropdowngrid")}});t.plugin(o),e.cssProperties.registerPrefix("MultiColumnComboBox","k-input-"),e.cssProperties.registerValues("MultiColumnComboBox",[{prop:"rounded",values:e.cssProperties.roundedValues.concat([["full","full"]])}])}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.ui.Draggable,o=n._outerWidth,a=n._outerHeight,s=e.extend,l=n.format,c=n.parseFloat,d=Array.isArray,u=Math,h=n.support,p=h.pointers,f=h.msPointers,m="change",g="slide",v=".slider",_="touchstart"+v+" mousedown"+v,b=p?"pointerdown"+v:f?"MSPointerDown"+v:_,y="touchend"+v+" mouseup"+v,w=p?"pointerup":f?"MSPointerUp"+v:y,k="moveSelection",x="keydown"+v,C="click"+v,S="mouseover"+v,T="focus"+v,D="blur"+v,A=".k-draghandle",M=".k-slider-track",E=".k-tick",I="k-selected",z="k-focus",P="k-disabled",H="disabled",F="tabindex",R=n.getTouches,L="aria-valuetext",B="aria-valuenow",O=i.extend({init:function(e,t){var r=this;if(i.fn.init.call(r,e,t),t=r.options,r._isHorizontal="horizontal"==t.orientation,r._isRtl=r._isHorizontal&&n.support.isRtl(e),r._position=r._isRtl?"right":r._isHorizontal?"left":"bottom",r._sizeFn=r._isHorizontal?"width":"height",r._outerSize=r._isHorizontal?o:a,t.tooltip.format=t.tooltip.enabled&&t.tooltip.format||"{0}",t.smallStep<=0)throw new Error("Kendo UI Slider smallStep must be a positive number.");r._createHtml(),r._trackDiv=r.wrapper.find(M),r._maxSelection=r._trackDiv[r._sizeFn](),r._sliderItemsInit(),r._reset(),r._tabindex(r.wrapper.find(A)),r[t.enabled?"enable":"disable"]();var s=n.support.isRtl(r.wrapper)?-1:1;r._keyMap={37:N(-1*s*t.smallStep),40:N(-t.smallStep),39:N(1*s*t.smallStep),38:N(+t.smallStep),35:$(t.max),36:$(t.min),33:N(+t.largeStep),34:N(-t.largeStep)},r._ariaLabel(r.wrapper.find(A)),n.notify(r)},events:[m,g],options:{enabled:!0,min:0,max:10,smallStep:1,largeStep:5,orientation:"horizontal",tickPlacement:"both",tooltip:{enabled:!0,format:"{0}"}},_distance:function(){return W(this.options.max-this.options.min)},_resize:function(){this.wrapper.find(".k-slider-items").remove(),this._maxSelection=this._trackDiv[this._sizeFn](),this._sliderItemsInit(),this._refresh(),this.options.enabled&&this.enable(!0)},_sliderItemsInit:function(){var t=this,n=t.options,i=(t._maxSelection-2)/((n.max-n.min)/n.smallStep),r=t._calculateItemsWidth(u.floor(G(t._distance())/G(n.smallStep)));"none"!=n.tickPlacement&&i>=2&&(e(this.element).parent().find(".k-slider-items").remove(),t._trackDiv.before(function(e,t){var n,i="<ul class='k-reset k-slider-items' role='presentation'>",r=u.floor(W(t/e.smallStep))+1;for(n=0;n<r;n++)i+="<li class='k-tick'></li>";return i+="</ul>",i}(n,t._distance())),t._setItemsTitle()),t._calculateSteps(r),"none"!=n.tickPlacement&&i>=2&&n.largeStep>=n.smallStep&&(t._setItemsLargeTick(),t.wrapper.find(E).first().addClass("k-first"),t.wrapper.find(E).last().addClass("k-last"))},getSize:function(){return n.dimensions(this.wrapper)},_setItemsTitle:function(){for(var t=this.options,n=this.wrapper.find(E),i=t.min,r=n.length,o=0;o<=r;o+=1)e(n[o]).attr("title",l(t.tooltip.format,W(i))),i+=t.smallStep},_setItemsLargeTick:function(){var t,n=this,i=n.options,r=n.wrapper.find(E),o=0;if(G(i.largeStep)%G(i.smallStep)==0||n._distance()/i.largeStep>=3)for(n._isHorizontal||n._isRtl||(r=e.makeArray(r).reverse()),o=0;o<r.length;o++){t=e(r[o]);var a=W(G(n._values[o]-this.options.min));a%G(i.smallStep)==0&&a%G(i.largeStep)==0&&(t.addClass("k-tick-large").html("<span class='k-label'>"+t.attr("title")+"</span>"),0!==o&&o!==r.length-1&&t.css("line-height",t[n._sizeFn]()+"px"))}},_calculateItemsWidth:function(e){var t,n,i,r=this,o=r.options,a=parseFloat(r._trackDiv.css(r._sizeFn))+1,s=r._distance(),l=G(s)/G(o.smallStep),c=a/G(s);for(l-e>0&&(a-=G(s)%G(o.smallStep)*c),t=a/e,n=[],i=0;i<e-1;i++)n[i]=t;return n[e-1]=n[e]=t/2,r._roundWidths(n)},_roundWidths:function(e){var t,n=0,i=e.length;for(t=0;t<i;t++)n+=e[t]-u.floor(e[t]),e[t]=u.floor(e[t]);return n=u.round(n),this._addAdditionalSize(n,e)},_addAdditionalSize:function(e,t){if(0===e)return t;var n,i=parseFloat(t.length-1)/parseFloat(1==e?e:e-1);for(n=0;n<e;n++)t[parseInt(u.round(i*n),10)]+=1;return t},_calculateSteps:function(e){var t,n=this,i=n.options,r=i.min,o=0,a=n._distance(),s=u.ceil(G(a)/G(i.smallStep)),l=1;if(s+=G(a)/G(i.smallStep)%1==0?1:0,e.splice(0,0,2*e[s-2]),e.splice(s-1,1,2*e.pop()),n._pixelSteps=[o],n._values=[r],0!==s){for(;l<s;)o+=(e[l-1]+e[l])/2,n._pixelSteps[l]=o,r+=i.smallStep,n._values[l]=W(r),l++;t=G(a)%G(i.smallStep)==0?s-1:s,n._pixelSteps[t]=n._maxSelection,n._values[t]=i.max}},_getValueFromPosition:function(e,t){var n,i=this,r=i.options,o=u.max(r.smallStep*(i._maxSelection/i._distance()),0),a=0,s=o/2;if(i._isHorizontal?(a=e-t.startPoint,i._isRtl&&(a=i._maxSelection-a)):a=t.startPoint-e,i._maxSelection-(parseInt(i._maxSelection%o,10)-3)/2<a)return r.max;for(n=0;n<i._pixelSteps.length;n++)if(u.abs(i._pixelSteps[n]-a)-1<=s)return W(i._values[n])},_getFormattedValue:function(e,t){var i,r,o,a="",s=this.options.tooltip;return d(e)?(r=e[0],o=e[1]):t&&t.type&&(r=t.selectionStart,o=t.selectionEnd),t&&(i=t.tooltipTemplate),!i&&s.template&&(i=n.template(s.template)),d(e)||t&&t.type?a=i?i({selectionStart:r,selectionEnd:o}):(r=l(s.format,r))+" - "+(o=l(s.format,o)):(t&&(t.val=e),a=i?i({value:e}):l(s.format,e)),a},_getDraggableArea:function(){var e=this,t=n.getOffset(e._trackDiv);return{startPoint:e._isHorizontal?t.left:t.top+e._maxSelection,endPoint:e._isHorizontal?t.left+e._maxSelection:t.top}},_createHtml:function(){var e=this,n=e.element,i=e.options,r=n.find("input");2==r.length?(r.eq(0).prop("value",U(i.selectionStart)),r.eq(1).prop("value",U(i.selectionEnd))):n.prop("value",U(i.value)),e.wrapper=n.wrap(function(e,t,n){var i=n?" k-slider-horizontal":" k-slider-vertical",r=e.style?e.style:t.attr("style"),o=t.attr("class")?" "+t.attr("class"):"",a="";"bottomRight"==e.tickPlacement?a=" k-slider-bottomright":"topLeft"==e.tickPlacement&&(a=" k-slider-topleft");return"<div class='k-slider"+i+o+"'"+(r=r?" style='"+r+"'":"")+"><div class='k-slider-track-wrap"+a+"'></div></div>"}(i,n,e._isHorizontal)).hide().parents(".k-slider"),i.showButtons&&e.wrapper.find(".k-slider-track-wrap").after(V(i,"increase",e._isHorizontal,e._isRtl)).before(V(i,"decrease",e._isHorizontal,e._isRtl)),n.before(function(e,n,i){var r,o,a,s=n.is("input")?1:2,l=2==s?e.leftDragHandleTitle:e.dragHandleTitle,c=e.value,d=e.selectionStart,u=e.selectionEnd;1===s?null!==(r=n.val())&&r!==t&&"null"!==r&&(null!==c&&c!==t||(c=r)):(o=n.find("input").eq(0).val(),a=n.find("input").eq(1).val(),null!==o&&o!==t&&"null"!==o&&(null!==d&&d!==t||(d=o)),null!==a&&a!==t&&"null"!==a&&(null!==u&&u!==t||(u=a)));var h="<div class='k-slider-track'><div class='k-slider-selection'>\x3c!-- --\x3e</div><span tabindex='0' class='k-draghandle' title='"+l+"' role='slider' "+(!1===i?"aria-orientation='vertical' ":"")+"aria-valuemin='"+e.min+"' aria-valuemax='"+e.max+"' aria-valuenow='"+(s>1?d||e.min:c||e.min)+"'></span>"+(s>1?"<span tabindex='0' class='k-draghandle' title='"+e.rightDragHandleTitle+"'role='slider' "+(!1===i?"aria-orientation='vertical' ":"")+"aria-valuemin='"+e.min+"' aria-valuemax='"+e.max+"' aria-valuenow='"+(u||e.max)+"'></span>":"")+"</div>";return h}(i,n,e._isHorizontal))},_focus:function(t){var n=this,i=t.target,r=n.value(),o=n._drag;o||(i==n.wrapper.find(A).eq(0)[0]?(o=n._firstHandleDrag,n._activeHandle=0):(o=n._lastHandleDrag,n._activeHandle=1),r=r[n._activeHandle]),e(i).addClass(z+" "+I),o&&(n._activeHandleDrag=o,o.selectionStart=n.options.selectionStart,o.selectionEnd=n.options.selectionEnd,o._updateTooltip(r))},_focusWithMouse:function(t){t=e(t);var n=this,i=t.is(A)?t.index():0;window.setTimeout((function(){n.wrapper.find(A)[2==i?1:0].focus()}),1),n._setTooltipTimeout()},_blur:function(t){var n=this,i=n._activeHandleDrag;e(t.target).removeClass(z+" "+I),i&&(i._removeTooltip(),delete n._activeHandleDrag,delete n._activeHandle)},_setTooltipTimeout:function(){var e=this;e._tooltipTimeout=window.setTimeout((function(){var t=e._drag||e._activeHandleDrag;t&&t._removeTooltip()}),300)},_clearTooltipTimeout:function(){window.clearTimeout(this._tooltipTimeout);var e=this._drag||this._activeHandleDrag;e&&e.tooltipDiv&&e.tooltipDiv.stop(!0,!1).css("opacity",1)},_reset:function(){var t=this,n=t.element,i=n.attr("form"),r=i?e("#"+i):n.closest("form");r[0]&&(t._form=r.on("reset",t._formResetHandler.bind(t)))},min:function(e){if(!e)return this.options.min;this.setOptions({min:e})},max:function(e){if(!e)return this.options.max;this.setOptions({max:e})},setOptions:function(e){i.fn.setOptions.call(this,e),this._sliderItemsInit(),this._refresh()},destroy:function(){this._form&&this._form.off("reset",this._formResetHandler),i.fn.destroy.call(this)}});function V(e,t,i,r){var o="";return o=i?"increase"===t?r?"caret-alt-left":"caret-alt-right":r?"caret-alt-right":"caret-alt-left":"increase"==t?"caret-alt-up":"caret-alt-down","<button class='k-button k-button-md k-rounded-full k-button-solid k-button-solid-base k-icon-button k-button-"+t+"' title='"+e[t+"ButtonTitle"]+"' aria-label='"+e[t+"ButtonTitle"]+"'>"+n.ui.icon({icon:o,iconClass:"k-button-icon"})+"</button>"}function N(e){return function(t){return t+e}}function $(e){return function(){return e}}function U(e){return(e+"").replace(".",n.cultures.current.numberFormat["."])}function W(e){var t,n;return t=function(e){var t=e.toString(),n=0;return(t=t.split("."))[1]&&(n=t[1].length),n>10?10:n}(e=parseFloat(e,10)),n=u.pow(10,t||0),u.round(e*n)/n}function j(e,n){var i=c(e.getAttribute(n));return null===i&&(i=t),i}function q(e){return void 0!==e}function G(e){return 1e4*e}var K=O.extend({init:function(n,i){var r,o=this;n.type="text",i=s({},{value:j(n,"value"),min:j(n,"min"),max:j(n,"max"),smallStep:j(n,"step")},i),n=e(n),i&&i.enabled===t&&(i.enabled=!n.is("[disabled]")),O.fn.init.call(o,n,i),q((i=o.options).value)&&null!==i.value||(i.value=i.min,n.prop("value",U(i.min))),i.value=u.max(u.min(i.value,i.max),i.min),r=o.wrapper.find(A),o._selection=new K.Selection(r,o,i),o._drag=new K.Drag(r,"",o,i),o._refreshAriaAttr(i.value)},options:{name:"Slider",showButtons:!0,increaseButtonTitle:"Increase",decreaseButtonTitle:"Decrease",dragHandleTitle:"drag",tooltip:{format:"{0:#,#.##}"},value:null},enable:function(t){var i,r,o=this,a=o.options;o.disable(),!1!==t&&(o.wrapper.removeClass(P),o.wrapper.find("input").prop(H,!1),i=function(t){var n=R(t)[0];if(n){var i=o._isHorizontal?n.location.pageX:n.location.pageY,r=o._getDraggableArea(),a=e(t.target);a.hasClass("k-draghandle")?a.addClass(z+" "+I):(o._update(o._getValueFromPosition(i,r)),o._focusWithMouse(t.target),o._drag.dragstart(t),t.preventDefault())}},o.wrapper.find(E+", "+M).on(b,i).end().on(b,(function(){e(document.documentElement).one("selectstart",n.preventDefault)})).on(w,(function(){o._drag._end()})),o.wrapper.find(A).attr(F,0).on(y,(function(){o._setTooltipTimeout()})).on(C,(function(e){o._focusWithMouse(e.target),e.preventDefault()})).on(T,o._focus.bind(o)).on(D,o._blur.bind(o)),r=function(e){var t=o._nextValueByIndex(o._valueIndex+1*e);o._setValueInRange(t),o._drag._updateTooltip(t)},a.showButtons&&o.wrapper.find(".k-button").on(y,function(e){this._clearTimer(),o._focusWithMouse(e.target)}.bind(o)).on(S,(function(t){e(t.currentTarget).addClass("k-hover")})).on("mouseout"+v,function(t){e(t.currentTarget).removeClass("k-hover"),this._clearTimer()}.bind(o)).on(_,(function(t){var n=e(t.target).closest(".k-button").is(".k-button-increase")?1:-1;o._mouseDownHandler(t,n,r)})).on("click",n.preventDefault),o.wrapper.find(A).off(x,!1).on(x,this._keydown.bind(o)),a.enabled=!0)},disable:function(){var t=this;t.wrapper.addClass(P),e(t.element).prop(H,H),t.wrapper.find(".k-button").off(_).on(_,(function(t){t.preventDefault(),e(this).addClass("k-active")})).off(y).on(y,(function(t){t.preventDefault(),e(this).removeClass("k-active")})).off("mouseleave"+v).on("mouseleave"+v,n.preventDefault).off(S).on(S,n.preventDefault),t.wrapper.find(E+", "+M).off(b).off(w),t.wrapper.find(A).attr(F,-1).off(y).off(x).off(C).off(T).off(D),t.options.enabled=!1},_mouseDownHandler:function(e,t,n){let i=this;i._clearTooltipTimeout(),(1===e.which||h.touch&&0===e.which)&&(n(t),i.timeout=setTimeout((function(){i.timer=setInterval((function(){n(t)}),60)}),200))},_update:function(e){var t=this,n=t.value()!=e;t.value(e),n&&t.trigger(m,{value:t.options.value})},value:function(e){var t=this,n=t.options;if(e=W(e),isNaN(e))return n.value;e>=n.min&&e<=n.max&&n.value!=e&&(t.element.prop("value",U(e)),n.value=e,t._refreshAriaAttr(e),t._refresh())},_refresh:function(){this.trigger(k,{value:this.options.value})},_refreshAriaAttr:function(e){var t,n=this._drag;t=n&&n._tooltipDiv?n._tooltipDiv.text():this._getFormattedValue(e,null),this.wrapper.find(A).attr(B,e).attr(L,t)},_clearTimer:function(){clearTimeout(this.timeout),clearInterval(this.timer)},_keydown:function(e){var t=this;e.keyCode in t._keyMap&&(t._clearTooltipTimeout(),t._setValueInRange(t._keyMap[e.keyCode](t.options.value)),t._drag._updateTooltip(t.value()),e.preventDefault())},_setValueInRange:function(e){var t=this,n=t.options;e=W(e),isNaN(e)?t._update(n.min):(e=u.max(u.min(e,n.max),n.min),t._update(e))},_nextValueByIndex:function(e){var t=this._values.length;return this._values[u.max(0,u.min(e,t-1))]},_formResetHandler:function(){var e=this,t=e.options.min;setTimeout((function(){var n=e.element[0].value;e.value(""===n||isNaN(n)?t:n)}))},destroy:function(){var e=this;O.fn.destroy.call(e),e.wrapper.off(v).find(".k-button").off(v).end().find(A).off(v).end().find(E+", "+M).off(v).end(),e._drag.draggable.destroy(),e._drag._removeTooltip(!0)}});K.Selection=function(e,t,n){function i(i){var r=i-n.min,o=t._valueIndex=u.ceil(W(r/n.smallStep)),a=parseInt(t._pixelSteps[o],10);t._trackDiv.find(".k-slider-selection")[t._sizeFn](a),e.css(t._position,a)}i(n.value),t.bind([g,k],(function(e){i(parseFloat(e.value,10))})),t.bind(m,(function(e){i(parseFloat(e.sender.value(),10))}))},K.Drag=function(e,t,n,i){var o=this;o.owner=n,o.options=i,o.element=e,o.type=t,o.draggable=new r(e,{distance:0,dragstart:o._dragstart.bind(o),drag:o.drag.bind(o),dragend:o.dragend.bind(o),dragcancel:o.dragcancel.bind(o)}),e.click(!1),e.on("dragstart",(function(e){e.preventDefault()}))},K.Drag.prototype={dragstart:function(e){this.owner._activeDragHandle=this,this.draggable.userEvents.cancel(),this._dragstart(e),this.dragend()},_dragstart:function(t){var n=this,i=n.owner,r=n.options;r.enabled?(this.owner._activeDragHandle=this,i.element.off(S),i.wrapper.find("."+z).removeClass(z+" "+I),n.element.addClass(z+" "+I),e(document.documentElement).css("cursor","pointer"),n.draggableArea=i._getDraggableArea(),n.step=u.max(r.smallStep*(i._maxSelection/i._distance()),0),n.type?(n.selectionStart=r.selectionStart,n.selectionEnd=r.selectionEnd,i._setZIndex(n.type)):n.oldVal=n.val=r.value,n._removeTooltip(!0),n._createTooltip()):t.preventDefault()},_createTooltip:function(){var t,i=this,r=i.owner,o=i.options.tooltip,a="",s=e(window);o.enabled&&(o.template&&(i.tooltipTemplate=n.template(o.template)),e(".k-slider-tooltip").remove(),i.tooltipDiv=e("<div role='tooltip' class='k-tooltip k-slider-tooltip'>\x3c!-- --\x3e</div>").appendTo(document.body),a=r._getFormattedValue(i.val||r.value(),i),i.type||(t="k-callout-"+(r._isHorizontal?"s":"e"),i.tooltipInnerDiv="<div class='k-callout "+t+"'>\x3c!-- --\x3e</div>",a+=i.tooltipInnerDiv),i.tooltipDiv.html(a),i._scrollOffset={top:s.scrollTop(),left:n.scrollLeft(s)},i.moveTooltip())},drag:function(e){var t,n=this,i=n.owner,r=e.x.location,o=e.y.location,a=n.draggableArea.startPoint,s=n.draggableArea.endPoint;e.preventDefault(),i._isHorizontal?i._isRtl?n.val=n.constrainValue(r,a,s,r<s):n.val=n.constrainValue(r,a,s,r>=s):n.val=n.constrainValue(o,s,a,o<=s),n.oldVal!=n.val&&(n.oldVal=n.val,n.type?("firstHandle"==n.type?n.val<n.selectionEnd?n.selectionStart=n.val:n.selectionStart=n.selectionEnd=n.val:n.val>n.selectionStart?n.selectionEnd=n.val:n.selectionStart=n.selectionEnd=n.val,t={values:[n.selectionStart,n.selectionEnd],value:[n.selectionStart,n.selectionEnd]}):t={value:n.val},i.trigger(g,t)),n._updateTooltip(n.val)},_updateTooltip:function(e){var t=this,n="";t.options.tooltip.enabled&&(t.tooltipDiv||t._createTooltip(),n=t.owner._getFormattedValue(W(e),t),t.type||(n+=t.tooltipInnerDiv),t.tooltipDiv.html(n),t.moveTooltip())},dragcancel:function(){return this.owner._refresh(),e(document.documentElement).css("cursor",""),this._end()},dragend:function(){var t=this,n=t.owner;return e(document.documentElement).css("cursor",""),t.type?n._update(t.selectionStart,t.selectionEnd):(n._update(t.val),t.draggable.userEvents._disposeAll()),t.draggable.userEvents.cancel(),t._end()},_end:function(){var e=this.owner;return e._focusWithMouse(this.element),e.element.on(S),!1},_removeTooltip:function(t){var n=this,i=n.owner;n.tooltipDiv&&i.options.tooltip.enabled&&i.options.enabled&&(t?(n.tooltipDiv.remove(),n.tooltipDiv=null):n.tooltipDiv.fadeOut("slow",(function(){e(this).remove(),n.tooltipDiv=null})))},moveTooltip:function(){var t,i,r,s,l=this,c=l.owner,d=0,u=0,h=l.element,p=n.getOffset(h),f=e(window),m=l.tooltipDiv.find(".k-callout"),g=o(l.tooltipDiv),v=a(l.tooltipDiv);l.type?(t=c.wrapper.find(A),p=n.getOffset(t.eq(0)),i=n.getOffset(t.eq(1)),c._isHorizontal?(d=i.top,u=p.left+(i.left-p.left)/2):(d=p.top+(i.top-p.top)/2,u=i.left),s=o(t.eq(0))+16):(d=p.top,u=p.left,s=o(h)+16),c._isHorizontal?(u-=parseInt((g-c._outerSize(h))/2,10),d-=v+8+(m.length?m.height():0)):(d-=parseInt((v-c._outerSize(h))/2,10),u-=g+8+(m.length?m.width():0)),c._isHorizontal?(d+=r=l._flip(d,v,s,a(f)+l._scrollOffset.top),u+=l._fit(u,g,o(f)+l._scrollOffset.left)):(r=l._flip(u,g,s,o(f)+l._scrollOffset.left),d+=l._fit(d,v,a(f)+l._scrollOffset.top),u+=r),r>0&&m&&(m.removeClass(),m.addClass("k-callout k-callout-"+(c._isHorizontal?"n":"w"))),l.tooltipDiv.css({top:d,left:u})},_fit:function(e,t,n){var i=0;return e+t>n&&(i=n-(e+t)),e<0&&(i=-e),i},_flip:function(e,t,n,i){var r=0;return e+t>i&&(r+=-(n+t)),e+r<0&&(r+=n+t),r},constrainValue:function(e,t,n,i){var r=this;return t<e&&e<n?r.owner._getValueFromPosition(e,r.draggableArea):i?r.options.max:r.options.min}},n.ui.plugin(K);var Y=O.extend({init:function(n,i){var r=this,o=e(n).find("input"),a=o.eq(0)[0],l=o.eq(1)[0];a.type="text",l.type="text",i&&i.showButtons&&(window.console&&window.console.warn("showbuttons option is not supported for the range slider, ignoring"),i.showButtons=!1),(i=s({},{selectionStart:j(a,"value"),min:j(a,"min"),max:j(a,"max"),smallStep:j(a,"step")},{selectionEnd:j(l,"value"),min:j(l,"min"),max:j(l,"max"),smallStep:j(l,"step")},i))&&i.enabled===t&&(i.enabled=!o.is("[disabled]")),O.fn.init.call(r,n,i),q((i=r.options).selectionStart)&&null!==i.selectionStart||(i.selectionStart=i.min,o.eq(0).prop("value",U(i.min))),q(i.selectionEnd)&&null!==i.selectionEnd||(i.selectionEnd=i.max,o.eq(1).prop("value",U(i.max)));var c=r.wrapper.find(A);this._selection=new Y.Selection(c,r,i),r._firstHandleDrag=new K.Drag(c.eq(0),"firstHandle",r,i),r._lastHandleDrag=new K.Drag(c.eq(1),"lastHandle",r,i),r._refreshAriaAttr(i.selectionStart,i.selectionEnd)},options:{name:"RangeSlider",leftDragHandleTitle:"drag",rightDragHandleTitle:"drag",tooltip:{format:"{0:#,#.##}"},selectionStart:null,selectionEnd:null},enable:function(t){var i,r=this,o=r.options;r.disable(),!1!==t&&(r.wrapper.removeClass(P),r.wrapper.find("input").prop(H,!1),i=function(t){var n=R(t)[0];if(n){var i,a,s,l=r._isHorizontal?n.location.pageX:n.location.pageY,c=r._getDraggableArea(),d=r._getValueFromPosition(l,c),u=e(t.target);if(u.hasClass("k-draghandle"))return r.wrapper.find("."+z).removeClass(z+" "+I),void u.addClass(z+" "+I);d<o.selectionStart?(i=d,a=o.selectionEnd,s=r._firstHandleDrag):d>r.selectionEnd?(i=o.selectionStart,a=d,s=r._lastHandleDrag):d-o.selectionStart<=o.selectionEnd-d?(i=d,a=o.selectionEnd,s=r._firstHandleDrag):(i=o.selectionStart,a=d,s=r._lastHandleDrag),s.dragstart(t),r._setValueInRange(i,a),r._focusWithMouse(s.element)}},r.wrapper.find(E+", "+M).on(b,i).end().on(b,(function(){e(document.documentElement).one("selectstart",n.preventDefault)})).on(w,(function(){r._activeDragHandle&&r._activeDragHandle._end()})),r.wrapper.find(A).attr(F,0).on(y,(function(){r._setTooltipTimeout()})).on(C,(function(e){r._focusWithMouse(e.target),e.preventDefault()})).on(T,r._focus.bind(r)).on(D,r._blur.bind(r)),r.wrapper.find(A).off(x,n.preventDefault).eq(0).on(x,function(e){this._keydown(e,"firstHandle")}.bind(r)).end().eq(1).on(x,function(e){this._keydown(e,"lastHandle")}.bind(r)),r.options.enabled=!0)},disable:function(){var e=this;e.wrapper.addClass(P),e.wrapper.find("input").prop(H,H),e.wrapper.find(E+", "+M).off(b).off(w),e.wrapper.find(A).attr(F,-1).off(y).off(x).off(C).off(T).off(D),e.options.enabled=!1},_keydown:function(e,t){var n,i,r,o=this,a=o.options.selectionStart,s=o.options.selectionEnd;e.keyCode in o._keyMap&&(o._clearTooltipTimeout(),"firstHandle"==t?(r=o._activeHandleDrag=o._firstHandleDrag,(a=o._keyMap[e.keyCode](a))>s&&(s=a)):(r=o._activeHandleDrag=o._lastHandleDrag,a>(s=o._keyMap[e.keyCode](s))&&(a=s)),o._setValueInRange(W(a),W(s)),n=Math.max(a,o.options.selectionStart),i=Math.min(s,o.options.selectionEnd),r.selectionEnd=Math.max(i,o.options.selectionStart),r.selectionStart=Math.min(n,o.options.selectionEnd),r._updateTooltip(o.value()[o._activeHandle]),e.preventDefault())},_update:function(e,t){var n=this,i=n.value(),r=i[0]!=e||i[1]!=t;n.value([e,t]),r&&n.trigger(m,{values:[e,t],value:[e,t]})},value:function(e){return e&&e.length?this._value(e[0],e[1]):this._value()},_value:function(e,t){var n=this,i=n.options,r=i.selectionStart,o=i.selectionEnd;if(isNaN(e)&&isNaN(t))return[r,o];e=W(e),t=W(t),e>=i.min&&e<=i.max&&t>=i.min&&t<=i.max&&e<=t&&(r==e&&o==t||(n.element.find("input").eq(0).prop("value",U(e)).end().eq(1).prop("value",U(t)),i.selectionStart=e,i.selectionEnd=t,n._refresh(),n._refreshAriaAttr(e,t)))},values:function(e,t){return d(e)?this._value(e[0],e[1]):this._value(e,t)},_refresh:function(){var e=this,t=e.options;e.trigger(k,{values:[t.selectionStart,t.selectionEnd],value:[t.selectionStart,t.selectionEnd]}),t.selectionStart==t.max&&t.selectionEnd==t.max&&e._setZIndex("firstHandle")},_refreshAriaAttr:function(e,t){var n,i=this,r=i.wrapper.find(A),o=i._activeHandleDrag;n=i._getFormattedValue([e,t],o),r.eq(0).attr(B,e),r.eq(1).attr(B,t),r.attr(L,n)},_setValueInRange:function(e,t){var n=this.options;e=u.max(u.min(e,n.max),n.min),t=u.max(u.min(t,n.max),n.min),e==n.max&&t==n.max&&this._setZIndex("firstHandle"),this._update(u.min(e,t),u.max(e,t))},_setZIndex:function(t){this.wrapper.find(A).each((function(n){e(this).css("z-index","firstHandle"==t?1-n:n)}))},_formResetHandler:function(){var e=this,t=e.options;setTimeout((function(){var n=e.element.find("input"),i=n[0].value,r=n[1].value;e.values(""===i||isNaN(i)?t.min:i,""===r||isNaN(r)?t.max:r)}))},destroy:function(){var e=this;O.fn.destroy.call(e),e.wrapper.off(v).find(E+", "+M).off(v).end().find(A).off(v),e._firstHandleDrag.draggable.destroy(),e._lastHandleDrag.draggable.destroy()}});Y.Selection=function(e,t,n){function i(i){var r=(i=i||[])[0]-n.min,o=i[1]-n.min,a=u.ceil(W(r/n.smallStep)),s=u.ceil(W(o/n.smallStep)),l=t._pixelSteps[a],c=t._pixelSteps[s];e.eq(0).css(t._position,l).end().eq(1).css(t._position,c),function(e,n){var i,r,o=t._trackDiv.find(".k-slider-selection");i=u.abs(e-n),o[t._sizeFn](i),r=u.min(e,n),o.css(t._position,r-1)}(l,c)}i(t.value()),t.bind([m,g,k],(function(e){i(e.values)}))},n.ui.plugin(Y)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.ui,o=e.isPlainObject,a=".kendoTextBox",s="change",l="disabled",c="readonly",d="k-input-inner",u="input",h="k-focus",p="k-disabled",f="k-readonly",m="k-hidden",g="aria-disabled",v=i.extend({init:function(r,o){var s=this;i.fn.init.call(s,r,o),o=e.extend(!0,{},o),s.options.value=o.value||s.element.val(),s.options.readonly=o.readonly!==t?o.readonly:Boolean(s.element.attr("readonly")),s.options.enable=o.enable!==t?o.enable:!Boolean(s.element.attr("disabled")),s.options.placeholder=o.placeholder||s.element.attr("placeholder"),s.value(s.options.value),s._wrapper(),s._label(),s._editable({readonly:s.options.readonly,disable:!s.options.enable}),s.element.addClass(d).attr("placeholder",s.options.placeholder).attr("autocomplete","off"),o.icon&&s._icon(),Tf({widget:s,wrapper:s.wrapper,options:s.options}),s._clearButton(),s._clear&&s._clear.on("click"+a+" touchend"+a,s._clearValue.bind(s)),n.notify(s),s._applyCssClasses(),s.floatingLabel&&s.floatingLabel.refresh()},events:[s,u],options:{name:"TextBox",value:"",readonly:!1,clearButton:!1,enable:!0,placeholder:"",label:null,rounded:"medium",size:"medium",fillMode:"solid",icon:null,prefixOptions:{separator:!0},suffixOptions:{separator:!0}},value:function(e){var n=this;if(e===t)return n._value;n._value=e,n.element.val(e),e?n._showClear():n._hideClear(),n.floatingLabel&&n.floatingLabel.refresh()},readonly:function(e){this._editable({readonly:e===t||e,disable:!1}),this.floatingLabel&&this.floatingLabel.readonly(e===t||e)},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)}),this.floatingLabel&&this.floatingLabel.enable(e=e===t||e)},focus:function(){this.element[0].focus()},destroy:function(){var e=this;e.floatingLabel&&e.floatingLabel.destroy(),e._clear&&(e._clear.off(a),e._clear=null),e.element.off(a),e.element[0].style.width="",e.element.removeClass(d),i.fn.destroy.call(e)},setOptions:function(e){this.destroy(),this._inputLabel&&(this._inputLabel.remove(),this._inputLabel=null),this._floatingLabelContainer?(this.floatingLabel.destroy(),this.floatingLabel=null,this.element.unwrap(),this.element.unwrap(),this._floatingLabelContainer=null):this.element.unwrap(),n.deepExtend(this.options,e),this.init(this.element,this.options)},_clearValue:function(e){this.element.val(""),this.element.focus(),this.element.trigger(s,{value:"",originalEvent:e}),this._hideClear()},_hideClear:function(){this._clear&&this._clear.addClass(m)},_showClear:function(){this._clear&&this._clear.removeClass(m)},_clearButton:function(){let t=this;t._clear||(t._clear=e(`<span unselectable="on" class="k-clear-value" title="Clear">${n.ui.icon("x")}</span>`).attr({role:"button",tabIndex:-1}),t._clear.appendTo(t.wrapper)),t.options.clearButton||t._clear.remove(),t.element.val()||t._hideClear()},_editable:function(e){var t=this,n=t.element,i=t.wrapper,r=e.disable,o=e.readonly;n.off(a),o||r?(n.attr(l,r).attr(c,o).attr(g,r),i.toggleClass(p,r).toggleClass(f,o)):(n.prop(l,!1).prop(c,!1).attr(g,!1),i.removeClass(p).removeClass(f),n.on("focusin"+a,t._focusin.bind(t)),n.on("focusout"+a,t._focusout.bind(t)),n.on(s+a,t._change.bind(t)),n.on(u+a,t._input.bind(t)))},_icon:function(){this.wrapper.prepend(n.ui.icon({icon:this.options.icon,iconClass:"k-input-icon"}))},_input:function(e){var t=this.element.val();this.trigger(u,{value:t,originalEvent:e})},_label:function(){var t,i,r=this,a=r.element,s=r.options,l=a.attr("id");null!==s.label&&(t=!!o(s.label)&&s.label.floating,i=o(s.label)?s.label.content:s.label,t&&(r._floatingLabelContainer=r.wrapper.wrap("<span></span>").parent(),r.floatingLabel=new n.ui.FloatingLabel(r._floatingLabelContainer,{widget:r})),n.isFunction(i)&&(i=i.call(r)),i||(i=""),l||(l=s.name+"_"+n.guid(),a.attr("id",l)),r._inputLabel=e("<label class='"+(t?"k-floating-label":"k-label k-input-label")+"' for='"+l+"'>"+i+"</label>'")[t?"insertAfter":"insertBefore"](r.wrapper))},_focusin:function(){this.wrapper.addClass(h)},_focusout:function(){this.wrapper.removeClass(h)},_change:function(e){var t=this,n=t.element.val();t._value=n,t.trigger(s,{value:n,originalEvent:e}),n?t._showClear():t._hideClear()},_wrapper:function(){var e,t=this.element,n=t[0];(e=t.wrap("<span class='k-input k-textbox'></span>").parent())[0].style.cssText=n.style.cssText,n.style.width="100%",this.wrapper=e.addClass(n.className).removeClass("input-validation-error")}});n.cssProperties.registerPrefix("TextBox","k-input-"),n.cssProperties.registerValues("TextBox",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),r.plugin(v)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.caret,r=n.keys,o=n.html,a=n.ui,s=a.Widget,l=n._activeElement,c=n._extractFormat,d=n.parseFloat,u=n.support.placeholder,h=n.getCulture,p="change",f="disabled",m="readonly",g="k-input-inner",v="spin",_=".kendoNumericTextBox",b="mouseenter"+_+" "+("mouseleave"+_),y="k-focus",w="k-hover",k="focus",x=".",C="k-selected",S="k-disabled",T="k-invalid",D="aria-disabled",A=/^(-)?(\d*)$/,M=null,E=e.isPlainObject,I=e.extend,z=s.extend({init:function(i,r){var o,a,l,d,u,h=this,p=r&&r.step!==t;s.fn.init.call(h,i,r),r=h.options,i=h.element.on("focusout"+_,h._focusout.bind(h)).attr("role","spinbutton"),r.placeholder=r.placeholder||i.attr("placeholder"),o=h.min(i.attr("min")),a=h.max(i.attr("max")),l=h._parse(i.attr("step")),r.min===M&&o!==M&&(r.min=o),r.max===M&&a!==M&&(r.max=a),p||l===M||(r.step=l),h._initialOptions=I({},r),u=i.attr("type"),h._reset(),h._wrapper(),h._arrows(),h._validation(),h._input(),n.support.mobileOS?h._text.on("touchend"+_+" "+k+_,(function(){n.support.browser.edge?h._text.one(k+_,(function(){h._focusin()})):h._focusin(),h.selectValue()})):h._text.on(k+_,h._click.bind(h)),i.attr("aria-valuemin",r.min!==M?r.min*r.factor:r.min).attr("aria-valuemax",r.max!==M?r.max*r.factor:r.max),r.format=c(r.format),(d=r.value)==M&&(d="number"==u?parseFloat(i.val()):i.val()),h.value(d),!r.enable||i.is("[disabled]")||e(h.element).parents("fieldset").is(":disabled")?h.enable(!1):h.readonly(i.is("[readonly]")),h._label(),h._ariaLabel(h._text),h._applyCssClasses(),Tf({widget:h,wrapper:h.wrapper,options:h.options,prefixInsertBefore:h._text,suffixInsertAfter:h._validationIcon}),h.floatingLabel&&h.floatingLabel.refresh(),n.notify(h)},options:{name:"NumericTextBox",decimals:M,autoAdjust:!0,enable:!0,restrictDecimals:!1,min:M,max:M,value:M,step:1,round:!0,culture:"",format:"n",spinners:!0,placeholder:"",selectOnFocus:!1,factor:1,upArrowText:"Increase value",downArrowText:"Decrease value",label:null,size:"medium",fillMode:"solid",rounded:"medium",prefixOptions:{separator:!0},suffixOptions:{separator:!0}},events:[p,v],_editable:function(e){var t=this,n=t.element,i=e.disable,r=e.readonly,o=t._text.add(n),a=t.wrapper.off(b);t._toggleText(!0),t._upArrowEventHandler.unbind("press"),t._downArrowEventHandler.unbind("press"),n.off("keydown"+_).off("keyup"+_).off("input"+_).off("paste"+_),t._inputLabel&&t._inputLabel.off(_),r||i?(a.addClass(i?S:"").removeClass(i?"":S),o.attr(f,i).attr(m,r).attr(D,i)):(a.removeClass(S).on(b,t._toggleHover),o.prop(f,!1).prop(m,!1).attr(D,!1),t._upArrowEventHandler.bind("press",(function(e){e.preventDefault(),t._spin(1),t._upArrow.addClass(C)})),t._downArrowEventHandler.bind("press",(function(e){e.preventDefault(),t._spin(-1),t._downArrow.addClass(C)})),t.element.on("keydown"+_,t._keydown.bind(t)).on("keyup"+_,t._keyup.bind(t)).on("paste"+_,t._paste.bind(t)).on("input"+_,t._inputHandler.bind(t)),t._inputLabel&&t._inputLabel.on("click"+_,t.focus.bind(t)))},readonly:function(e){this._editable({readonly:e===t||e,disable:!1}),this.floatingLabel&&this.floatingLabel.readonly(e===t||e)},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)}),this.floatingLabel&&this.floatingLabel.enable(e=e===t||e)},setOptions:function(e){var n=this;s.fn.setOptions.call(n,e),n._text.prop("placeholder",n.options.placeholder),n._placeholder(n.options.placeholder),n.element.attr({"aria-valuemin":n.options.min!==M?n.options.min*n.options.factor:n.options.min,"aria-valuemax":n.options.max!==M?n.options.max*n.options.factor:n.options.max}),n.options.format=c(n.options.format),n._upArrowEventHandler.destroy(),n._upArrowEventHandler=null,n._downArrowEventHandler.destroy(),n._downArrowEventHandler=null,n._arrowsWrap.remove(),n._arrows(),n._applyCssClasses(),n._inputLabel&&(n._inputLabel.off(_),n._inputLabel.remove(),n.floatingLabel&&(n.floatingLabel.destroy(),n._floatingLabelContainer&&n.wrapper.unwrap())),n._label(),e.enable!==t||e.readonly!==t?n._editable({readonly:e.readonly,disable:!e.enable}):n._editable({readonly:n.element.attr("readonly")!==t?Boolean(n.element.attr("readonly")):n.options.readonly,disable:n.element.attr("disabled")!==t?Boolean(n.element.attr("disabled")):!n.options.enable}),e.value!==t?n.value(e.value):n._value!==t&&n.value(n._value)},destroy:function(){var e=this;e._inputLabel&&(e._inputLabel.off(_),e.floatingLabel&&e.floatingLabel.destroy()),e.element.add(e._text).add(e._upArrow).add(e._downArrow).off(_),e._upArrowEventHandler.destroy(),e._downArrowEventHandler.destroy(),e._form&&e._form.off("reset",e._resetHandler),s.fn.destroy.call(e)},min:function(e){return this._option("min",e)},max:function(e){return this._option("max",e)},step:function(e){return this._option("step",e)},value:function(e){var n=this;if(e===t)return n._value;(e=n._parse(e))!==n._adjust(e)&&(e=M),n._update(e),n._old=n._value,n.floatingLabel&&n.floatingLabel.refresh()},focus:function(){this._focusin(),this.selectValue()},_adjust:function(e){let t=this.options,n=t.min,i=t.max,r=t.autoAdjust;return e!==M&&r?(n!==M&&e<n?e=n:i!==M&&e>i&&(e=i),e):e},_arrows:function(){var t,i=this,r=function(){clearTimeout(i._spinning),t.removeClass(C)},o=i.options,a=o.spinners,s=i.element;(t=s.siblings(".k-icon-button"))[0]||(t=e(P("increase",o.upArrowText,o)+P("decrease",o.downArrowText,o)).appendTo(i.wrapper),i._arrowsWrap=t.wrapAll('<span class="k-input-spinner k-spin-button"/>').parent()),a||t.parent().toggle(a),i._upArrow=t.eq(0),i._upArrowEventHandler=new n.UserEvents(i._upArrow,{release:r}),i._downArrow=t.eq(1),i._downArrowEventHandler=new n.UserEvents(i._downArrow,{release:r})},_validation:function(){var t=this.element;this._validationIcon=e(n.ui.icon({icon:"exclamation-circle",iconClass:"k-input-validation-icon k-hidden"})).insertAfter(t)},_blur:function(){var e=this;e._toggleText(!0),e._change(e.element.val())},_click:function(e){var t=this;clearTimeout(t._focusing),t._focusing=setTimeout((function(){var n,r,o,a=e.target,s=i(a)[0],l=a.value.substring(0,s),c=t._format(t.options.format),d=c[","],u=0;d&&(r=new RegExp("\\"+d,"g"),o=new RegExp("(-)?("+c.symbol+")?([\\d\\"+d+"]+)(\\"+c[x]+")?(\\d+)?")),o&&(n=o.exec(l)),n&&(u=n[0].replace(r,"").length,-1!=l.indexOf("(")&&t._value<0&&u++),t._focusin(),i(t.element[0],u),t.selectValue()}))},selectValue:function(){this.options.selectOnFocus&&this.element[0].select()},_getFactorValue:function(e){var t=this.options.factor;return t&&1!==t&&null!==(e=n.parseFloat(e))&&(e/=t),e},_change:function(e){var t=this;e=t._getFactorValue(e),t._update(e),e=t._value,t._old!=e&&(t._old=e,t._typing||t.element.trigger(p),t.trigger(p)),t._typing=!1},_culture:function(e){return e||h(this.options.culture)},_focusin:function(){var e=this;e.wrapper.addClass(y),e._toggleText(!1),e.element[0].focus()},_focusout:function(){var e=this;clearTimeout(e._focusing),e.wrapper.removeClass(y).removeClass(w),e._blur(),e._removeInvalidState()},_format:function(e,t){var n=this._culture(t).numberFormat;return(e=e.toLowerCase()).indexOf("c")>-1?n=n.currency:e.indexOf("p")>-1&&(n=n.percent),n},_input:function(){var t,i=this,r=i.options,o=i.element.addClass(g).show()[0],a=o.accessKey;(t=i.wrapper.find(x+g).first()).length<2&&(t=e('<input type="text"/>').attr(n.attr("validate"),"false").insertBefore(o));try{o.setAttribute("type","text")}catch(e){o.type="text"}t[0].title=o.title,t[0].tabIndex=o.tabIndex,t[0].style.cssText=o.style.cssText,t.prop("placeholder",r.placeholder),a&&(t.attr("accesskey",a),o.accessKey=""),i._text=t.addClass(o.className).attr({role:"spinbutton","aria-valuemin":r.min!==M?r.min*r.factor:r.min,"aria-valuemax":r.max!==M?r.max*r.factor:r.max,autocomplete:"off"})},_keydown:function(e){var t=this,n=e.keyCode;n===r.NUMPAD_DOT&&(t._numPadDot=!0),n!=r.DOWN?n!=r.UP?n!=r.ENTER?(n!=r.TAB&&(t._typing=!0),t._cachedCaret=i(t.element)):t._change(t.element.val()):t._step(1):t._step(-1)},_keyup:function(){this._removeInvalidState()},_inputHandler:function(){var e=this.element,t=e.val(),n=this.options.min,r=this._format(this.options.format),o=r[x],a=null!==n&&n>=0&&"-"===t.charAt(0);this._numPadDot&&o!==x&&(t=t.replace(x,o),this.element.val(t),this._numPadDot=!1),this._isPasted&&this._parse(t)&&(t=this._parse(t).toString().replace(x,r[x])),this._numericRegex(r).test(t)&&!a?this._oldText=t:(this._blinkInvalidState(),this.element.val(this._oldText),this._cachedCaret&&(i(e,this._cachedCaret[0]),this._cachedCaret=null)),this._isPasted=!1},_blinkInvalidState:function(){var e=this;e._addInvalidState(),clearTimeout(e._invalidStateTimeout),e._invalidStateTimeout=setTimeout(e._removeInvalidState.bind(e),100)},_addInvalidState:function(){this.wrapper.addClass(T),this._validationIcon.removeClass("k-hidden")},_removeInvalidState:function(){var e=this;e.wrapper.removeClass(T),e._validationIcon.addClass("k-hidden"),e._invalidStateTimeout=null},_numericRegex:function(e){var t=this,n=e[x],i=t.options.decimals,r="*";return n===x&&(n="\\"+n),i===M&&(i=e.decimals),0===i&&t.options.restrictDecimals?A:(t.options.restrictDecimals&&(r="{0,"+i+"}"),t._separator===n&&t._oldPrecision===i||(t._separator=n,t._floatRegExp=new RegExp("^(-)?(((\\d+("+n+"\\d"+r+")?)|("+n+"\\d"+r+")))?$"),t._oldPrecision=i),t._floatRegExp)},_paste:function(e){var t=this,n=e.target,i=n.value,r=t._format(t.options.format);t._isPasted=!0,setTimeout((function(){var e=t._parse(n.value);e===M?t._update(i):(n.value=e.toString().replace(x,r[x]),t._adjust(e)===e&&t._numericRegex(r).test(n.value)||(i=t._getFactorValue(n.value),t._update(i)))}))},_option:function(e,n){var i=this,r=i.element,o=i.options;if(n===t)return o[e];((n=i._parse(n))||"step"!==e)&&(o[e]=n,r.add(i._text).attr("aria-value"+e,n),r.attr(e,n))},_spin:function(e,t){var n=this;t=t||500,clearTimeout(n._spinning),n._spinning=setTimeout((function(){n._spin(e,50)}),t),n._step(e)},_step:function(e){var t=this,n=t.element,i=t._value,r=t._parse(n.val())||0,o=t.options.decimals||2;l()!=n[0]&&t._focusin(),t.options.factor&&r&&(r/=t.options.factor),r=+(r+t.options.step*e).toFixed(o),r=t._adjust(r),t._update(r),t._typing=!1,i!==r&&t.trigger(v)},_toggleHover:function(t){e(t.currentTarget).toggleClass(w,"mouseenter"===t.type)},_toggleText:function(e){var t=this;t._text.toggle(e),e?t._text.removeAttr("aria-hidden"):t._text.attr("aria-hidden","true"),t.element.toggle(!e)},_parse:function(e,t){return d(e,this._culture(t),this.options.format)},_round:function(e,t){return(this.options.round?n._round:H)(e,t)},_update:function(e){var t,i,r=this,o=r.options,a=o.factor,s=o.format,l=o.decimals,c=r._culture(),d=r._format(s,c);l===M&&(l=d.decimals),(i=(e=r._parse(e,c))!==M)&&(e=parseFloat(r._round(e,l),10)),r._value=e=r._adjust(e),r._placeholder(n.toString(e,s,c)),i?(a&&(e=parseFloat(r._round(e*a,l),10)),-1!==(e=e.toString()).indexOf("e")&&(e=r._round(+e,l)),t=e,e=e.replace(x,d[x])):(e=null,t=null),r.element.val(e),r._oldText=e,r.element.add(r._text).attr("aria-valuenow",t)},_placeholder:function(e){var t=this._text;t.val(e),u||e||t.val(this.options.placeholder),t.attr("title",this.element.attr("title")||t.val())},_label:function(){var i,r,o=this,a=o.element,s=o.options,l=a.attr("id");null!==s.label&&(i=!!E(s.label)&&s.label.floating,r=E(s.label)?s.label.content:s.label,i&&(o._floatingLabelContainer=o.wrapper.wrap("<span></span>").parent(),o.floatingLabel=new n.ui.FloatingLabel(o._floatingLabelContainer,{widget:o})),n.isFunction(r)&&(r=r.call(o)),r||(r=""),l||(l=s.name+"_"+n.guid(),a.attr("id",l)),o._inputLabel=e("<label class='"+(i?"k-floating-label":"k-label k-input-label")+"' for='"+l+"'>"+r+"</label>'")[i?"insertAfter":"insertBefore"](o.wrapper),o.element.attr("disabled")===t&&o.element.attr("readonly")===t&&o._inputLabel.on("click"+_,o.focus.bind(o)))},_wrapper:function(){var e,t=this.element,n=t[0];(e=t.parents(".k-numerictextbox")).is("span.k-numerictextbox")||(e=t.hide().wrap("<span/>").parent()),e[0].style.cssText=n.style.cssText,n.style.width="",this.wrapper=e.addClass("k-numerictextbox k-input").addClass(n.className).removeClass("input-validation-error").css("display","")},_reset:function(){var t=this,n=t.element,i=n.attr("form"),r=i?e("#"+i):n.closest("form");r[0]&&(t._resetHandler=function(){setTimeout((function(){t.value(n[0].value),t.max(t._initialOptions.max),t.min(t._initialOptions.min)}))},t._form=r.on("reset",t._resetHandler))}});function P(e,t,n){var i="increase"===e?"caret-alt-up":"caret-alt-down",r="increase"===e?"increase":"decrease";return o.renderButton('<button role="button" tabindex="-1" unselectable="on" class="k-spinner-'+r+'" aria-label="'+t+'" title="'+t+'"></button>',I({},n,{icon:i,shape:null,rounded:null}))}function H(e,t){var n=parseFloat(e,10).toString().split(x);return n[1]&&(n[1]=n[1].substring(0,t)),n.join(x)}n.cssProperties.registerPrefix("NumericTextBox","k-input-"),n.cssProperties.registerValues("NumericTextBox",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),a.plugin(z)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=i.Widget,o=n.parseColor,a=n.ui.Popup.TabKeyTrap,s=e.extend,l=".kendoColorTools",c="keydown"+l,d=r.extend({init:function(e,t){var n=this;r.fn.init.call(n,e,t),e=n.element,t=n.options,e.is("input")?(n._initialValue(),n._preventDefaultLabelClick()):n._value=o(t.value),n._tabIndex=e.attr("tabIndex")||0,t._standalone&&(n._triggerSelect=n._triggerChange)},options:{name:"ColorSelector",ARIATemplate:e=>`Current selected color is ${e||"none"}`,value:null,_standalone:!0},events:["change","select","forceSelect","cancel"],color:function(e){return e!==t&&(this._value=o(e),this.element.is("input")&&this._updateInput(this._value),this._updateUI(this._value)),this._value},value:function(e){return(e=this.color(e))&&(e=this.options.opacity?e.toCssRgba():e.toCss()),e||null},enable:function(e){0===arguments.length&&(e=!0),this.element.is("input")&&this.element.attr("disabled",!e),this.wrapper.toggleClass("k-disabled",!e),this._onEnable(e)},_attachFocusEvents:function(){this.wrapper.on(c,this._navKeydown.bind(this)).on("focusout"+l,this._navFocusout.bind(this))},_initialValue:function(){var e=this.element,t=this.options.value||e.attr("value");t&&(this._value=o(t,!0)),this.element.val(t)},_innerTabindex:function(e){this.wrapper.find(".k-draghandle, .k-button, .k-input-inner").attr("tabindex",e)},_isInputTypeColor:function(){var e=this.element[0];return/^input$/i.test(e.tagName)&&/^color$/i.test(e.type)},_navFocusout:function(){var e=this,t=e.wrapper[0];setTimeout((function(){t.contains(document.activeElement)||e._releaseInnerFocus()}))},_navKeydown:function(e){var i=this.wrapper;e.keyCode===n.keys.ENTER&&i.attr("tabindex")?(e.preventDefault(),this._trapInnerFocus()):e.keyCode===n.keys.ESC&&i.attr("tabindex")===t&&(this._releaseInnerFocus(),this.wrapper.trigger("focus"))},_releaseInnerFocus:function(){this._tabKeyTrap.removeTrap(),this.wrapper.attr("tabindex",this._tabIndex),this._innerTabindex(-1)},_select:function(e,t){var n=this._value;e=this.color(e),t||(e&&(!n||!e.equals(n))||null===e&&e!==n?(null===e&&this.element.val&&this.element.val(e),this.element.trigger("change"),this.trigger("change",{value:this.value()})):this._standalone||this.trigger("cancel"))},_navigation:function(){var e=this.value();e&&e.indexOf("rgba")>-1&&(e=e.replace("rgba","RGBA")),this.options._otOfPicker?(this._innerTabindex(-1),this._attachFocusEvents(),this._tabKeyTrap=new a(this.wrapper),this._ariaTemplate=n.template(this.options.ARIATemplate),this.wrapper.attr({"aria-label":this._ariaTemplate(e||""),tabindex:this._tabIndex})):(this.wrapper.removeAttr("tabindex"),this.wrapper.removeAttr("aria-label"),this.wrapper.removeAttr("role"),this.wrapper.removeAttr("aria-keyshortcuts"))},_trapInnerFocus:function(){this._innerTabindex(0),this.wrapper.removeAttr("tabindex"),this.wrapper.find(".k-hsv-draghandle").trigger("focus"),this._tabKeyTrap.trap()},_triggerSelect:function(e){u(this,"select",e)},_triggerChange:function(e){u(this,"change",e)},destroy:function(){this.element&&this.element.off(l),this.wrapper&&(this.wrapper.off(c),this.wrapper.off(l).find("*").off(l),this.wrapper=null),r.fn.destroy.call(this)},_preventDefaultLabelClick:function(){var e=this.element,t=e.closest("label"),n=e.attr("id");n&&(t=t.add('label[for="'+n+'"]')),t.on("click",(function(e){e.preventDefault()}))},_updateUI:e.noop,_updateInput:function(e){var t,i="";e&&(i=this._isInputTypeColor()||1==e.a?e.toCss():e.toCssRgba(),this.element.val(i)),this.options._otOfPicker&&(this._ariaTemplate||(this._ariaTemplate=n.template(this.options.ARIATemplate)),(t=this.value())&&t.indexOf("rgba")>-1&&(t=t.replace("rgba","RGBA")),this.wrapper.attr("aria-label",this._ariaTemplate(t||"")))},_selectOnHide:function(){return null},_cancel:function(){this.trigger("cancel")}});function u(e,t,n){((n=o(n))&&!n.equals(e.color())||n!==e.color())&&("change"==t&&(e._value=n,e._updateInput(e._value)),n&&1!=n.a?n=n.toCssRgba():n&&(n=n.toCss()),e.trigger(t,{value:n}))}s(i,{colorpicker:{ColorSelector:d}})}(window.kendo.jQuery),function(e,t){var n=kendo.ui.colorpicker,i=e.extend,r=kendo.Color,o=kendo.parseColor;function a(e,t){return n=s(l(e,t)),i=s(l(t,{r:0,g:0,b:0,a:1})),(Math.max(n,i)+.05)/(Math.min(n,i)+.05);var n,i}function s(e){var t=[e.r,e.g,e.b].map((function(e){return(e/=255)<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4)}));return.2126*t[0]+.7152*t[1]+.0722*t[2]}function l(e,t){var n=c(e.r,0,255),i=c(e.g,0,255),r=c(e.b,0,255),o=c(e.a,0,1),a=c(t.r,0,255),s=c(t.g,0,255),l=c(t.b,0,255);return{r:Math.round((1-o)*a+o*n),g:Math.round((1-o)*s+o*i),b:Math.round((1-o)*l+o*r)}}function c(e,n,i){if(!function(e){return null!==e&&e!==t}(e)||isNaN(e))return n;return e<=n?n:e>=i?i:e}function d(e,t){if(0===e.length)return"";var n=e.reduce((function(e,n,i,r){return 0===i?kendo.format("M {0},{1}",n[0],n[1]):kendo.format("{0} {1}",e,t(n,i,r))}),"");return kendo.format('<path d="{0}" fill="none" stroke="white" stroke-width="1"/>',n)}function u(e,t){var n=t[0]-e[0],i=t[1]-e[1];return{length:Math.sqrt(Math.pow(n,2)+Math.pow(i,2)),angle:Math.atan2(i,n)}}i(n,{contrastToolUtils:{getContrastFromTwoRGBAs:a,renderSvgCurveLine:function(e,t,n){var s,l,h=function(s,l,d,u,p){var f=(d+u)/2,m=i({},t,{s:l/e.width,v:1-f/e.height}),g=a(o(function(e){var t=c(e.h,0,359.9),n=c(e.s,0,1),i=c(e.v,0,1),o=c(e.a,0,1);return r.fromHSV(t,n,i,o).toCssRgba()}(m)).toBytes(),o(n).toBytes());return d+.5>u?g<s+1&&g>s-1?f:null:p(g,s)?h(s,l,d,u-(u-d)/2,p):h(s,l,d+(u-d)/2,u,p)},p=function(e,t){return e>t},f=function(e,t){return e<t},m=function(t,n,i){for(var r=[],o=0;o<=e.width;o+=e.width/n){var a=h(t,o,0,e.height,i?f:p);null!==a&&r.push([o,a])}return r},g=(l=u,s=function(e,t,n,i){var r=.1,o=l(t||e,n||e),a=o.angle+(i?Math.PI:0),s=o.length*r;return[e[0]+Math.cos(a)*s,e[1]+Math.sin(a)*s]},function(e,t,n){var i=s(n[t-1],n[t-2],e),r=s(e,n[t-1],n[t+1],!0);return kendo.format("C {0},{1} {2},{3} {4},{5}",i[0],i[1],r[0],r[1],e[0],e[1])}),v=d(m(4.5,16,!1),g)+d(m(4.5,16,!0),g)+d(m(7,16,!1),g)+d(m(7,16,!0),g);return`<svg xmlns="http://www.w3.org/2000/svg" ${kendo.attr("style-position")}="absolute" ${kendo.attr("style-overflow")}="visible" ${kendo.attr("style-pointer-events")}="none" ${kendo.attr("style-left")}="0px" ${kendo.attr("style-top")}="0px" ${kendo.attr("style-z-index")}="3" >`+v+"</svg>"}}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.ui,i=t.Observable,r=t.parseColor,o=e.extend,a=t.htmlEncode,s=t.Color,l=t.keys,c="#ffffff",d="#000000",u="keydown.kendoColorTools",h=n.colorpicker.ColorSelector,p=n.colorpicker.contrastToolUtils;function f(e){e.preventDefault()}var m=i.extend({init:function(e,n){var r=this;r.element=e,r.options=n,r._viewModel=t.observable({switchMode:r.switchMode.bind(r),keydown:r.keydown.bind(r),isHEXMode:function(){return"hex"===this.get("format")},isRGBMode:function(){return"rgb"===this.get("format")},format:n.format,formats:n.formats,rgb:null,hex:function(){return null!==this.get("rgb")&&this.get("rgb").toCss({alpha:n.opacity})}}),r._changeHandler=r.change.bind(r),r._viewModel.bind("change",r._changeHandler),r._render(),r.element.on(u,r.keydown.bind(r)),i.fn.init.call(r)},_template:t.template((({options:e,ns:t})=>{let n=a(e.size),i=a(e.tabindex),r="";if(e.formats&&e.formats.length>1){r=`<div class="k-vstack"><button class="k-colorgradient-toggle-mode" data-${t}role="button" data-${t}icon="caret-alt-expand" data data-${t}bind="click: switchMode" data-${t}fill-mode="flat" data-${t}size="${n}" title="${a(e.messages.toggleFormat)}"></button></div>`}let o="";if(e.formats&&e.formats.indexOf("hex")>=0){o=`<div class="k-vstack" data-${t}bind="visible: isHEXMode"><input type="text" data-${t}bind="value: hex" data-${t}role="textbox" data-${t}size="${n}" tabindex="${i}"  aria-label="${a(e.messages.hex)}"/><label class="k-colorgradient-input-label">HEX</label></div>`}let s="";if(e.formats&&e.formats.indexOf("rgb")>=0){if(s=`<div class="k-vstack" data-${t}bind="visible: isRGBMode"><input tabindex="${i}" data-${t}bind="value: rgb.r" data-${t}role="numerictextbox" data-${t}size="${n}" data-${t}max="255" data-${t}min="0" data-${t}decimals="0" data-${t}spinners="false" data-${t}format="n0" aria-label="${a(e.messages.red)}" /><label class="k-colorgradient-input-label">R</label></div><div class="k-vstack" data-${t}bind="visible: isRGBMode"><input tabindex="${i}" data-${t}bind="value: rgb.g" data-${t}role="numerictextbox" data-${t}size="${n}" data-${t}max="255" data-${t}min="0" data-${t}decimals="0" data-${t}spinners="false" data-${t}format="n0" aria-label="${a(e.messages.green)}" /><label class="k-colorgradient-input-label">G</label></div><div class="k-vstack" data-${t}bind="visible: isRGBMode"><input tabindex="${i}" data-${t}bind="value: rgb.b" data-${t}role="numerictextbox" data-${t}size="${n}" data-${t}max="255" data-${t}min="0" data-${t}decimals="0" data-${t}spinners="false" data-${t}format="n0" aria-label="${a(e.messages.blue)}"/><label class="k-colorgradient-input-label">B</label></div>`,e.opacity){s+=`<div class="k-vstack" data-${t}bind="visible: isRGBMode"><input tabindex="${i}" data-${t}bind="value: rgb.a" data-${t}role="numerictextbox" data-${t}size="${n}" data-${t}step="0.1" data-${t}max="1" data-${t}min="0" data-${t}decimals="1" data-${t}spinners="false" data-${t}format="n1" aria-label="${e.messages.alpha}" /><label class="k-colorgradient-input-label">A</label></div>`}}return r+o+s})),destroy:function(){var e=this;e._viewModel.unbind("change",e._changeHandler),t.unbind(e.element),t.destroy(e.element),e.element.off(u),delete e._viewModel,delete e._changeHandler},change:function(e){var t=this;e.field.indexOf("rgb")>=0?(t._color=t._tryParseColor(t._viewModel.rgb.toCssRgba()),t._viewModel.set("hex",t._color.toCss({alpha:t.options.opacity}))):"hex"===e.field&&(t._color=t._tryParseColor(e.sender[e.field]),t._viewModel.set("rgb",t._color)),t._preventChangeEvent||t.trigger("change",{value:t._color})},keydown:function(t){var n=this,i=e(t.target).data("kendoTextBox");t.keyCode===l.ENTER&&e(t.target).is("input")&&(i&&i._change&&i._change(),n.trigger("change",{value:n._color}),n.trigger("select",{value:n._color}))},reset:function(){var e=this;e._preventChangeEvent=!0,e._viewModel.set("rgb",r(d)),delete e._preventChangeEvent},switchMode:function(){var e=this,t=e._viewModel,n=t.format,i=t.formats.indexOf(n)+1;i=i>=t.formats.length?0:i,e._preventChangeEvent=!0,e._viewModel.set("format",t.formats[i]),delete e._preventChangeEvent},value:function(e){var t=this;t._color=e&&e.toBytes()||r(d),t._preventChangeEvent=!0,t._viewModel.set("rgb",t._color),delete t._preventChangeEvent},_render:function(){var e=this;e.element.append(e._template({ns:t.ns,guid:t.guid(),options:e.options})).parent(),t.bind(e.element,e._viewModel),e.element.attr("data-"+t.ns+"stop","stop")},_tryParseColor:function(e){try{e=r(e)||this._color}catch(t){e=this._color}return e}}),g=h.extend({init:function(n,i){var r,o=this;h.fn.init.call(o,n,i),(i=o.options=t.deepExtend({},o.options,i)).messages.previewInput&&(i.messages.hex=i.messages.previewInput),i.messages=i.messages?e.extend(o.options.messages,i.messages):o.options.messages,o._wrapper(),o._sliders(),o._hsvArea(),r=o._value,o._gradientInputs(),o._updateUI(r),o._navigation()},options:{name:"ColorGradient",opacity:!1,hsvDragARIATemplate:e=>`Color well with two-dimensional slider for selecting saturation and value. Selected color is ${e||"none"}`,input:!0,format:"hex",formats:["rgb","hex"],contrastTool:!1,size:"medium",messages:{contrastRatio:"Contrast ratio:",fail:"Fail",pass:"Pass",hex:"HEX",toggleFormat:"Toggle format",red:"Red channel",green:"Green channel",blue:"Blue channel",alpha:"Alpha channel"},_otOfPicker:!0},_template:t.template((e=>'<div class="k-colorgradient-canvas k-hstack"><div class="k-hsv-rectangle"><div class="k-hsv-gradient"><div role="slider" aria-orientation="undefined" class="k-hsv-draghandle k-draghandle"></div></div></div><div class="k-hsv-controls k-hstack"><input class="k-hue-slider k-colorgradient-slider" />'+(e.opacity?'<input class="k-alpha-slider k-colorgradient-slider" />':"")+"</div></div>"+(e.input?'<div class="k-colorgradient-inputs k-hstack"></div>':"")+(e.contrastTool?'<div class="k-colorgradient-color-contrast k-vbox"></div>':""))),focus:function(){this._hsvHandle.trigger("focus")},setBackgroundColor:function(t){var n=this;n.options.contrastTool&&(n.options.contrastTool=e.isPlainObject(n.options.contrastTool)?o({},n.options.contrastTool,{backgroundColor:t}):{backgroundColor:t},n._updateColorContrast(n.color()||r(c)))},_getHSV:function(e,t,n,i){var o=this,a=o._hsvRect,l=a.width(),c=a.height(),u=this._hsvHandle.position();return l&&c?(null==e&&(e=o._hueSlider.value()),null==t&&(t=u.left/l),null==n&&(n=1-u.top/c),null==i&&(i=o._opacitySlider?o._opacitySlider.value()/100:1),s.fromHSV(e,t,n,i)):o.color()?o.color().toHSV():r(d)},_gradientInputs:function(){var e=this,t=e.options;e._colorgradientInputs.length&&(e._colorInput=new m(e._colorgradientInputs,o({},t,{tabindex:0})),e._colorInput.bind("change",(function(t){e._updateUI(t.value,!0)})),e._colorInput.bind("select",(function(t){var n=r(t.value);e._select(n),e.trigger("forceSelect",{value:e.value()})})))},_hsvArea:function(){var e,n,i=this,r=i.wrapper.find(".k-hsv-rectangle"),o=r.find(".k-draghandle").attr("tabIndex",0).on(u,(e=i._hsvKeydown,n=i,function(){return e.apply(n,arguments)})),a=this.value();function s(e,t){var n,r,o=this.offset,a=e-o.left,s=t-o.top,l=this.width,c=this.height;n=(a=a<0?0:a>l?l:a)/l,r=1-(s=s<0?0:s>c?c:s)/c,i._svChange(n,r)}a&&a.indexOf("rgba")>-1&&(a=a.replace("rgba","RGBA")),this._hsvDragAriaTemplate||(this._hsvDragAriaTemplate=t.template(this.options.hsvDragARIATemplate)),o.attr("aria-label",this._hsvDragAriaTemplate(a||"")),i._hsvEvents=new t.UserEvents(r,{global:!0,press:function(e){this.offset=t.getOffset(r),this.width=r.width(),this.height=r.height(),o.trigger("focus"),s.call(this,e.x.location,e.y.location)},start:function(){r.addClass("k-dragging"),o.trigger("focus")},move:function(e){e.preventDefault(),s.call(this,e.x.location,e.y.location)},end:function(){r.removeClass("k-dragging")}}),i._hsvRect=r,i._hsvHandle=o},_hsvKeydown:function(e){var t=this;function n(n,i){var r=t._getHSV();r[n]+=i*(e.shiftKey?.01:.05),r[n]<0&&(r[n]=0),r[n]>1&&(r[n]=1),t._updateUI(r),f(e)}function i(n){var i=t._getHSV();i.h+=n*(e.shiftKey?1:5),i.h<0&&(i.h=0),i.h>359&&(i.h=359),t._updateUI(i),f(e)}switch(e.keyCode){case l.LEFT:e.ctrlKey?i(-1):n("s",-1);break;case l.RIGHT:e.ctrlKey?i(1):n("s",1);break;case l.UP:n(e.ctrlKey&&t._opacitySlider?"a":"v",1);break;case l.DOWN:n(e.ctrlKey&&t._opacitySlider?"a":"v",-1);break;case l.ENTER:t._select(t._getHSV());break;case l.F2:t._colorInput.element.find("input").trigger("focus").select();break;case l.ESC:t._cancel()}},_onEnable:function(e){var t=this.wrapper;this._hueSlider.enable(e),this._opacitySlider&&this._opacitySlider.enable(e),t.find("input").attr("disabled",!e),this.options._standalone&&(e?t.removeAttr("aria-disabled"):t.attr("aria-disabled",!0))},_reset:function(){var e=this;e._colorInput&&e._colorInput.reset(),e._resetHsv(),e._resetColorContrast()},_resetColorContrast:function(){var e=this,t=e.options.contrastTool;e._contrastTool.length&&e._updateColorContrast(t.backgroundColor?r(t.backgroundColor):r(c))},_resetHsv:function(){var e=r(d);this._updateHsv(e)},_sliders:function(){var e=this,t=e.wrapper,n=t.find(".k-hue-slider"),i=t.find(".k-alpha-slider");function r(t){e._updateUI(e._getHSV(t.value,null,null,null))}function o(t){e._updateUI(e._getHSV(null,null,null,t.value/100))}n.attr("aria-label","hue"),e._hueSlider=n.kendoSlider({min:0,max:360,tickPlacement:"none",showButtons:!1,orientation:"vertical",slide:r,change:r}).data("kendoSlider"),i.attr("aria-label","opacity"),e._opacitySlider=i.kendoSlider({min:0,max:100,tickPlacement:"none",showButtons:!1,orientation:"vertical",slide:o,change:o}).data("kendoSlider")},_svChange:function(e,t){var n=this._getHSV(null,e,t,null);this._updateUI(n)},_updateColorContrast:function(e){var n=this,i=n.options.contrastTool,o=i.backgroundColor?r(i.backgroundColor):r(c),s=p.getContrastFromTwoRGBAs(r(e.toCssRgba()),o),l=t.template((({messages:e,ratio:n})=>`<div class="k-contrast-ratio"><span class="k-contrast-ratio-text">${a(e.contrastRatio)} ${a(t.toString(n,"n2"))}</span><span class="k-contrast-validation !k-text-success">`+(n>4.5?t.ui.icon("check"):"")+(n>7?t.ui.icon("check"):"")+"</span></div>")),d=t.template((({messages:e,ratio:n,limit:i,level:r})=>`<div><span>${a(r)}: ${a(i)} </span>`+(n>i?`<span class="k-contrast-validation !k-text-success">${a(e.pass)} ${t.ui.icon("check")}</span>`:`<span class="k-contrast-validation !k-text-error">${a(e.fail)} ${t.ui.icon("x")}</span>`)+"</div>")),u="";u+=l({messages:n.options.messages,ratio:s}),u+=d({messages:n.options.messages,ratio:s,limit:4.5,level:"AA"}),u+=d({messages:n.options.messages,ratio:s,limit:7,level:"AAA"}),n._contrastTool.find(".k-contrast-ratio, div").remove(),n._contrastTool.append(u),n._updateContrastSvg(o)},_updateContrastSvg:function(n){var i,r=this._hsvRect,o="k-color-contrast-svg",a={width:r.width(),height:r.height()};a.width&&a.height&&(i=e(p.renderSvgCurveLine(a,this._getHSV(),n)).addClass(o),t.applyStylesFromKendoAttributes(i,["position","overflow","pointer-events","left","top","z-index"]),r.find("."+o).remove(),r.append(i))},_updateHsv:function(e){var t=this,n=t._hsvRect;e=e.toHSV(),t._hsvHandle.css({left:e.s*n.width()+"px",top:(1-e.v)*n.height()+"px"}),t._hueElements.css("background-color",s.fromHSV(e.h,1,1,1).toCss()),t._hueSlider.value(e.h),t._opacitySlider&&(t._opacitySlider.wrapper.find(".k-slider-track").css("background","linear-gradient(to top, transparent, "+s.fromHSV(e.h,1,1,1).toCss()),t._opacitySlider.value(100*e.a)),t._updateHsvAria(e.s,e.v)},_updateHsvAria:function(e,t){var n=this.value();n&&n.indexOf("rgba")>-1&&(n=n.replace("rgba","RGBA")),this._hsvHandle.attr({"aria-label":this._hsvDragAriaTemplate(n||""),"aria-valuenow":Math.round(100*e),"aria-valuetext":"saturation: "+Math.round(100*e)+"%, value: "+Math.round(100*t)+"%"})},_updateUI:function(e,t){var n=this;e?(!t&&n._colorInput&&n._colorInput.value(e),n._triggerSelect(e),n._updateHsv(e),n._contrastTool.length&&n._updateColorContrast(e)):n._reset()},_wrapper:function(){var t,n=this.options;(t=this.element.is("input")?this.element.addClass("k-hidden").wrap("<div>").parent():this.element).addClass("k-colorgradient").attr({role:"textbox","aria-keyshortcuts":"Enter"}).append(this._template(n)),this._hueElements=e(".k-hsv-rectangle, .k-alpha-slider .k-slider-track",t),this._colorgradientInputs=e(".k-colorgradient-inputs",t),this._contrastTool=e(".k-colorgradient-color-contrast",t),this.wrapper=t},destroy:function(){this._hsvEvents.destroy(),this._hueSlider.destroy(),this._opacitySlider&&this._opacitySlider.destroy(),this._colorInput&&this._colorInput.destroy(),this._hueSlider=this._opacitySlider=this._hsvRect=this._hsvHandle=this._hueElements=this._selectedColor=this._colorAsText=this._contrastTool=null,h.fn.destroy.call(this)}});n.plugin(g)}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.ui,i=t.parseColor,r=t.keys,o=".",a="background-color",s="k-selected",l="k-focus",c="k-colorpalette-tile",d=".kendoColorTools",u="focus"+d,h="click"+d,p="keydown"+d,f="blur"+d,m=n.colorpicker.ColorSelector;function g(e){e.preventDefault()}function v(e,t){return function(){return e.apply(t,arguments)}}var _=m.extend({init:function(e,n){var i=this;m.fn.init.call(i,e,n),i._tabIndex=this.element.attr("tabindex")||0,i._wrapper(),n=i.options,i._selectedID=(n.ariaId||t.guid())+"_selected",i._ariaTemplate=t.template(i.options.ARIATemplate),i._value&&(i._updateUI(i._value),i.wrapper.find(o+l).removeClass(l)),i.wrapper.attr("aria-label",i._ariaTemplate(i.value()||"")),i._attachEvents()},focus:function(){this.wrapper&&!this.wrapper.is("[unselectable='on']")&&this.wrapper.trigger("focus")},options:{name:"ColorPalette",columns:10,tileSize:null,palette:"basic"},_attachEvents:function(){var e=this;e.wrapper.on(h,o+c,(function(t){e._select(t.currentTarget)})).on(p,v(e._keydown,e)).on(f,(function(){e.wrapper.find(o+c).removeClass(l)})).on(u,v(e._focus,e))},_colors:function(){var t=this.options,n=t.palette||"basic";return"websafe"==n?(n="FFFFFF,FFCCFF,FF99FF,FF66FF,FF33FF,FF00FF,CCFFFF,CCCCFF,CC99FF,CC66FF,CC33FF,CC00FF,99FFFF,99CCFF,9999FF,9966FF,9933FF,9900FF,FFFFCC,FFCCCC,FF99CC,FF66CC,FF33CC,FF00CC,CCFFCC,CCCCCC,CC99CC,CC66CC,CC33CC,CC00CC,99FFCC,99CCCC,9999CC,9966CC,9933CC,9900CC,FFFF99,FFCC99,FF9999,FF6699,FF3399,FF0099,CCFF99,CCCC99,CC9999,CC6699,CC3399,CC0099,99FF99,99CC99,999999,996699,993399,990099,FFFF66,FFCC66,FF9966,FF6666,FF3366,FF0066,CCFF66,CCCC66,CC9966,CC6666,CC3366,CC0066,99FF66,99CC66,999966,996666,993366,990066,FFFF33,FFCC33,FF9933,FF6633,FF3333,FF0033,CCFF33,CCCC33,CC9933,CC6633,CC3333,CC0033,99FF33,99CC33,999933,996633,993333,990033,FFFF00,FFCC00,FF9900,FF6600,FF3300,FF0000,CCFF00,CCCC00,CC9900,CC6600,CC3300,CC0000,99FF00,99CC00,999900,996600,993300,990000,66FFFF,66CCFF,6699FF,6666FF,6633FF,6600FF,33FFFF,33CCFF,3399FF,3366FF,3333FF,3300FF,00FFFF,00CCFF,0099FF,0066FF,0033FF,0000FF,66FFCC,66CCCC,6699CC,6666CC,6633CC,6600CC,33FFCC,33CCCC,3399CC,3366CC,3333CC,3300CC,00FFCC,00CCCC,0099CC,0066CC,0033CC,0000CC,66FF99,66CC99,669999,666699,663399,660099,33FF99,33CC99,339999,336699,333399,330099,00FF99,00CC99,009999,006699,003399,000099,66FF66,66CC66,669966,666666,663366,660066,33FF66,33CC66,339966,336666,333366,330066,00FF66,00CC66,009966,006666,003366,000066,66FF33,66CC33,669933,666633,663333,660033,33FF33,33CC33,339933,336633,333333,330033,00FF33,00CC33,009933,006633,003333,000033,66FF00,66CC00,669900,666600,663300,660000,33FF00,33CC00,339900,336600,333300,330000,00FF00,00CC00,009900,006600,003300,000000",t.columns=18):"basic"==n&&(n="000000,7f7f7f,880015,ed1c24,ff7f27,fff200,22b14c,00a2e8,3f48cc,a349a4,ffffff,c3c3c3,b97a57,ffaec9,ffc90e,efe4b0,b5e61d,99d9ea,7092be,c8bfe7"),"string"==typeof n&&(n=n.split(",")),Array.isArray(n)&&(n=e.map(n,(function(e){return i(e)}))),n},_current:function(t){this.wrapper.find(o+c).removeClass(l).removeAttr("id"),e(t).addClass(l).attr("id",this._selectedID),this.wrapper.removeAttr("aria-activedescendant").attr("aria-activedescendant",this._selectedID)},_focus:function(){var e=this.wrapper;0===e.find("#"+this._selectedID).length&&this._current(e.find(o+c).first())},_keydown:function(e){var t,n,i,a=this.wrapper.find(o+c),d=a.filter(o+l).get(0)||a.filter(o+s).get(0),u=e.keyCode;if(d&&(i=Array.prototype.indexOf.call(d.parentNode.children,d)),u==r.LEFT)t=d?d.previousSibling:a[a.length-1];else if(u==r.RIGHT)t=d?d.nextSibling:a[0];else if(u==r.DOWN)n=d&&d.parentNode.nextSibling?d.parentNode.nextSibling.children[i]:null,t=d?n:a[0];else if(u==r.UP)n=d&&d.parentNode.previousSibling?d.parentNode.previousSibling.children[i]:null,t=d?n:a.get[a.length-1];else if(u==r.ENTER){if(g(e),d)return this._select(d),void this.trigger("forceSelect",{value:this.value()})}else u==r.ESC&&this._cancel();t&&1!==t.nodeType&&(t=null),t&&(g(e),this._current(t))},_onEnable:function(e){this.options._standalone&&(e?(this.wrapper.attr("tabindex",this._tabIndex),this.wrapper.removeAttr("aria-disabled")):(this.wrapper.removeAttr("tabindex"),this.wrapper.attr("aria-disabled",!0)))},_select:function(t){var n=this.wrapper.find(o+c);t=e(t),m.fn._select.call(this,t.css(a)),n.removeClass(s).removeAttr("aria-selected"),t.addClass(s).attr("aria-selected",!0)},_template:t.template((({colors:e,columns:n,tileSize:i,value:r,id:o})=>{let a="";for(var l=0;l<e.length;++l){let i=e[l].equals(r);l&&l%n==0&&(a+='</tr><tr role="row">'),a+=`<td role="gridcell" unselectable="on" ${t.attr("style-background-color")}="${e[l].toCss()}"`+(i?" aria-selected=true":"")+" "+(o&&0===l?'id=\\"'+o+'\\" ':"")+" "+`class="k-colorpalette-tile${i?" "+s:""}" `+`aria-label="${e[l].toCss()}"></td>`}return'<table class="k-colorpalette-table" role="presentation"><tr role="row">'+a+"</tr></table>"})),_tileSize:function(){var e,t,n=this.options.tileSize;if(n){if(/number|string/.test(typeof n))e=t=parseFloat(n);else{if("object"!=typeof n)throw new Error("Unsupported value for the 'tileSize' argument");e=parseFloat(n.width),t=parseFloat(n.height)}this.wrapper.find(o+c).css({width:e,height:t})}},_updateUI:function(t){var n=null,r=this.wrapper.find(o+c);this.wrapper.find(o+c).each((function(){var r=i(e(this).css(a));if(r&&r.equals(t))return n=this,!1})),this._current(n),r.removeClass(s),n&&(e(n).addClass(s),this.wrapper.attr("aria-label",this._ariaTemplate(this.value()||"")))},_wrapper:function(){var n,i,r=this.options,o=this._colors();n=this.element.is("input")?this.element.addClass("k-hidden").wrap("<div>").parent():this.element,i=e(this._template({colors:o,columns:r.columns,tileSize:r.tileSize,value:this._value,id:r.ariaId})),t.applyStylesFromKendoAttributes(i,["background-color"]),n.addClass("k-colorpalette").attr("role","grid").append(i).attr("tabindex",this._tabIndex),this.wrapper=n,this._tileSize()}});n.plugin(_)}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.ui,i=t.html,r=t.Color,o=e.extend,a=t.htmlEncode,s="background-color",l=".kendoColorTools",c="click"+l,d="keydown"+l,u=n.colorpicker.ColorSelector,h=t.keys,p="k-no-color",f="k-selected",m=".k-color-preview-mask",g="aria-pressed",v="aria-disabled",_={gradient:n.ColorGradient,palette:n.ColorPalette};var b=u.extend({init:function(e,n){var i=this;n&&!1===n.autoupdate&&(n._standalone=!1),u.fn.init.call(i,e,n),n=i.options=t.deepExtend({},i.options,n),i._wrapper();var r=i.color();i._changeView(n.view),i._setViewSize(),r?(i._updateUI(r),i._previousColor.children(m).css(s,r.toDisplay()),i._selectedColor.children(m).css(s,r.toDisplay())):(i._selectedColor.addClass(p),i._previousColor.addClass(p)),i._attachEvents(),i._navigation()},destroy:function(){var e=this;u.fn.destroy.call(this),e._view&&(e._view.destroy(),e._viewsContainer.empty()),e.element.off(l),e._selectedColor=e._previousColor=e._viewsContainer=e._view=null},options:{name:"FlatColorPicker",opacity:!1,buttons:!1,input:!0,preview:!0,clearButton:!1,format:"hex",formats:["rgb","hex"],view:"gradient",views:["gradient","palette"],palette:null,autoupdate:!0,backgroundColor:null,columns:10,tileSize:24,messages:{apply:"Apply",cancel:"Cancel",noColor:"no color",clearColor:"Clear color",previewInput:null,contrastRatio:"Contrast ratio:",fail:"Fail",pass:"Pass",hex:"HEX",toggleFormat:"Toggle format",red:"Red",green:"Green",blue:"Blue",alpha:"Alpha",gradient:"Gradient view",palette:"Palette view"},size:"medium",_otOfPicker:!0},setBackgroundColor:function(e){var t=this;t._view&&t._view.setBackgroundColor&&t._view.setBackgroundColor(e)},_attachEvents:function(){var t,n,i=this;i.wrapper.on(d,(t=i._keydown,n=i,function(){return t.apply(n,arguments)})).on(c,".k-button[data-command]",(function(){i._clearColor=!0,i._updateUI(null),i._view.value(null)})).on(c,".k-coloreditor-apply",(function(){i._clearColor?i._select(null):i._select(i._view.color())})).on(c,".k-coloreditor-cancel",(function(){delete i._clearColor,i._updateUI(i.color()),i._cancel()})).on(c,".k-button[data-view]",(function(t){var n=e(t.target).closest("[data-view]");n.is("."+f)||(i.wrapper.find(".k-button[data-view]").removeClass(f).attr(g,!1),n.addClass(f).attr(g,!0),i._changeView(n.data("view")))}))},_select:function(e){u.fn._select.call(this,e),this._updatePreviousColor(e)},_updatePreviousColor:function(e){var t=this;e?(t._previousColor.removeClass(p),t._previousColor.children(m).css(s,e.toDisplay())):(t._previousColor.addClass(p),t._previousColor.children(m).css(s,""))},_changeView:function(t){var n,i,o=this,a=e.extend({},o.options),s=_[t];o._view&&o._view._colorInput&&(o.options.format=o._view._colorInput._viewModel.format),o.options.view=t,delete a.name,delete a.change,delete a.select,delete a.cancel,delete a._standalone,o._view&&(n=o._view.color(),o._view.destroy(),o._viewsContainer.empty()),n&&(n=n.toHSV(),i=r.fromHSV(o._cachedHue||0,n.s,n.v,n.a),o._cachedHue=n.toHSV().h,n=n.equals(i)?i:n),a._otOfPicker=!1,s&&(o._view=new _[t](e("<div></div>").appendTo(o._viewsContainer),a),o._view.value(n),o._view.bind("change",(function(e){delete o._clearColor,o._updateUI(e.sender.color(),!0)})),o._view.bind("forceSelect",(function(e){delete o._clearColor,o._select(e.sender.color())})))},_onEnable:function(e){var t=this;t._view&&t._view._onEnable(e),t.options._standalone&&(e?t.wrapper.removeAttr(v):t.wrapper.attr(v,!0))},focus:function(){this._view&&this._view.focus()},_updateUI:function(e,t){var n=this;e&&e.toDisplay?(n._selectedColor.removeClass(p),n._selectedColor.children(m).css(s,e.toDisplay())):(n._selectedColor.addClass(p),n._selectedColor.children(m).css(s,"")),n._triggerSelect(e),n.options.autoupdate&&n._updatePreviousColor(e),t||n._view.value(e)},_setViewSize:function(){var e=this,t=e.wrapper[0],n=parseInt(e.options.tileSize.width||e.options.tileSize,10),i=parseInt(e.options.tileSize.width||e.options.tileSize,10),r=e.options.columns;t.style.setProperty("--kendo-color-preview-columns",r),t.style.setProperty("--kendo-color-preview-width",n+"px"),t.style.setProperty("--kendo-color-preview-height",i+"px")},_keydown:function(e){e.keyCode==h.ESC&&this._cancel()},_template:function(){var e=this.options,n=o({},e,{fillMode:"flat",themeColor:"base",rounded:"medium"});return t.template(((e,t)=>'<div class="k-coloreditor-header k-hstack">'+(e.views&&e.views.length>1?'<div class="k-coloreditor-header-actions k-hstack"><div role="group" class="k-button-group k-button-group-flat">'+i.renderButton(`<button aria-pressed="false" data-view="gradient" title="${a(e.messages.gradient)}"></button>`,o({icon:"droplet-slider"},t))+i.renderButton(`<button aria-pressed="false" data-view="palette" title="${a(e.messages.palette)}"></button>`,o({icon:"palette"},t))+"</div></div>":"")+'<div class="k-spacer"></div><div class="k-coloreditor-header-actions k-hstack">'+(e.clearButton?i.renderButton(`<button data-command="reset" title="${a(e.messages.clearColor)}"></button>`,o({icon:"droplet-slash"},t)):"")+(e.preview?'<div class="k-coloreditor-preview k-vstack"><span class="k-coloreditor-preview-color k-color-preview"><span class="k-color-preview-mask"></span></span><span class="k-coloreditor-current-color k-color-preview"><span class="k-color-preview-mask"></span></span></div>':"")+'</div></div><div class="k-coloreditor-views k-vstack"></div>'+(e.buttons?'<div class="k-coloreditor-footer k-actions k-actions-end k-actions-horizontal">'+i.renderButton(`<button class="k-coloreditor-cancel" title="${a(e.messages.cancel)}">${a(e.messages.cancel)}</button>`,o({},t,{fillMode:"solid"}))+i.renderButton(`<button class="k-coloreditor-apply" title="${a(e.messages.apply)}">${a(e.messages.apply)}</button>`,o({},t,{fillMode:"solid",themeColor:"primary"}))+"</div>":"")))(e,n)},_wrapper:function(){var t,n=this.options;(t=this.element.is("input")?this.element.addClass("k-hidden").wrap("<div>").parent():this.element).addClass("k-flatcolorpicker k-coloreditor").attr({role:"textbox","aria-keyshortcuts":"Enter"}).append(this._template()),this._selectedColor=e(".k-coloreditor-preview-color",t),this._previousColor=e(".k-coloreditor-current-color",t),this._viewsContainer=e(".k-coloreditor-views",t),t.find(".k-button[data-view="+n.view+"]").addClass(f).attr(g,!0),this.wrapper=t}});n.plugin(b)}(window.kendo.jQuery);!function(e){var t=window.kendo,n=t.ui,i=n.Widget,r=t.Color,o=t.parseColor,a=t.keys,s=".kendoColorTools",l="click"+s,c="keydown"+s,d=n.colorpicker.ColorSelector,u=n.FlatColorPicker,h=i.extend({init:function(n,r){var a=this;r&&r.palette&&!r.view&&(r.view="palette"),i.fn.init.call(a,n,r),r=a.options=t.deepExtend({},a.options,r),n=a.element;let s=o(r.value||n.attr("value")||n.val(),!0);a._value=r.value=s;var l=t.html.renderButton('<button class="k-input-button" unselectable="on" aria-label="select" tabindex="-1"></button>',e.extend({},a.options,{icon:"caret-alt-down"})),c=a._inputWrapper=a.wrapper=e(a._template(e.extend({},a.options,{_buttonHtml:l})));a._applyCssClasses(),n.hide().after(c),n.is("input")&&(n.appendTo(c),a._preventDefaultLabelClick()),a._tabIndex=n.attr("tabIndex")||0,a.enable(!n.attr("disabled"));var d=n.attr("accesskey");d&&(n.attr("accesskey",null),c.attr("accesskey",d)),a.bind("activate",(function(e){e.isDefaultPrevented()||a.toggle()})),a._updateUI(s)},destroy:function(){this.wrapper.off(s).find("*").off(s),this._popup&&(this._selector.destroy(),this._popup.destroy()),this._selector=this._popup=this.wrapper=null,i.fn.destroy.call(this)},enable:function(e){var t=this,n=t.wrapper,i=n.find(".k-input-button");0===arguments.length&&(e=!0),t.element.attr("disabled",!e),n.attr("aria-disabled",!e),i.off(s).on("mousedown"+s,p),n.addClass("k-disabled").removeAttr("tabIndex").add("*",n).off(s),e?n.removeClass("k-disabled").attr("tabIndex",t._tabIndex).on("mouseenter"+s,(function(){n.addClass("k-hover")})).on("mouseleave"+s,(function(){n.removeClass("k-hover")})).on("focus"+s,(function(){n.addClass("k-focus")})).on("blur"+s,(function(){n.removeClass("k-focus")})).on(c,f(t._keydown,t)).on(l,".k-input-button",f(t.toggle,t)).on(l,".k-input-inner",(function(){t.trigger("activate")})):t.close()},_template:t.template((({toolIcon:e,_buttonHtml:n})=>`<span role="combobox" aria-haspopup="dialog" aria-expanded="false" class="k-colorpicker k-picker k-icon-picker"><span class="k-input-inner"><span class="k-value-icon k-color-preview ${e?"k-icon-color-preview":""}">`+(e?t.ui.icon({icon:e,iconClass:"k-color-preview-icon"}):"")+'<span class="k-color-preview-mask"></span></span></span >'+n+"</span>")),options:{name:"ColorPicker",closeOnSelect:!1,contrastTool:!1,palette:null,columns:10,toolIcon:null,value:null,messages:{apply:"Apply",cancel:"Cancel",noColor:"no color",clearColor:"Clear color",previewInput:null,contrastRatio:"Contrast ratio:",fail:"Fail",pass:"Pass",hex:"HEX",toggleFormat:"Toggle format",red:"Red",green:"Green",blue:"Blue",alpha:"Alpha",gradient:"Gradient view",palette:"Palette view"},opacity:!1,buttons:!0,preview:!0,clearButton:!1,input:!0,format:"hex",formats:["rgb","hex"],view:"gradient",views:["gradient","palette"],backgroundColor:null,ARIATemplate:e=>`Current selected color is ${e||"none"}`,size:"medium",rounded:"medium",fillMode:"solid"},events:["activate","change","select","open","close"],open:function(){this.element.prop("disabled")||this._getPopup().open()},close:function(){var e=this._selector&&this._selector.options||{};e._closing=!0,this._getPopup().close(),delete e._closing},toggle:function(){this.element.prop("disabled")||this._getPopup().toggle()},setBackgroundColor:function(e){var t=this,n=function(){t._selector.setBackgroundColor(e)};t.options.contrastTool.backgroundColor=e,t._selector&&t._popup&&t._popup.visible()?t._selector.setBackgroundColor(e):t._popup&&(t._popup.unbind("activate",n),t._popup.bind("activate",n))},_noColorIcon:function(){return this.wrapper.find(".k-color-preview")},color:d.fn.color,value:d.fn.value,_select:d.fn._select,_triggerSelect:d.fn._triggerSelect,_isInputTypeColor:d.fn._isInputTypeColor,_preventDefaultLabelClick:function(){var e=this,t=e.element,n=t.closest("label"),i=t.attr("id");i&&(n=n.add('label[for="'+i+'"]')),n.on("click",(function(t){e.open(),t.preventDefault()}))},_updateUI:function(e,t){this._updateInput(e),this._triggerSelect(e),this.wrapper.find(".k-color-preview-mask").css("background-color",e?e.toDisplay():""),this._noColorIcon().toggleClass("k-no-color",!e),this._selector&&!t&&this._selector.value(e)},_updateInput:function(e){var n="";e&&(n=this._isInputTypeColor()||1==e.a?e.toCss():e.toCssRgba(),this.element.val(n)),this._ariaTemplate||(this._ariaTemplate=t.template(this.options.ARIATemplate)),this.wrapper.attr("aria-label",this._ariaTemplate(n))},_keydown:function(e){var t=e.keyCode;this._getPopup().visible()?(t==a.ESC?this._selector._cancel():this._selector._keydown(e),p(e)):t!=a.ENTER&&t!=a.DOWN||(this.open(),p(e))},_getPopup:function(){var n=this,i=n._popup;if(!i){var a,s=n.options;a=u,s.autoupdate=!0!==s.buttons,delete s.select,delete s.change,delete s.cancel,s._otOfPicker=!1;var l=t.guid(),c=e('<div id="'+l+'" class="k-colorpicker-popup"></div>').appendTo(document.body),d=n._selector=new a(e("<div></div>").appendTo(c),s);n.wrapper.attr("aria-controls",l),n._popup=i=c.kendoPopup({anchor:n.wrapper,adjustSize:{width:5,height:0}}).data("kendoPopup"),d.bind({select:function(e){n._updateUI(o(e.value),!0)},change:function(e){n.options.buttons?n._select(d.color()):n._updateUI(o(e.value),!0),(n.options.buttons||"palette"===n._selector.options.view&&n.options.closeOnSelect)&&n.close()},cancel:function(){n.close()}}),i.bind({close:function(t){if(n.trigger("close"))t.preventDefault();else{n.wrapper.removeClass("k-focus");var i=d.color();n.options.buttons?n._select(n.color()):n._select(i),(i=n.color())&&i.h&&(n._cachedHue=i.h),event&&event instanceof MouseEvent&&0===e(event.target).parents(".k-colorpicker-popup").length||setTimeout((function(){n.wrapper&&!n.wrapper.is("[unselectable='on']")&&n.wrapper.trigger("focus")}),0),n.wrapper.attr("aria-expanded",!1)}},open:function(e){n.trigger("open")?e.preventDefault():(n.wrapper.addClass("k-focus"),n.wrapper.attr("aria-expanded",!0))},activate:function(){var e,t=n.color();t&&(t=t.toHSV(),e=r.fromHSV(n._cachedHue||0,t.s,t.v,t.a),t=t.equals(e)?e:t),d.value(t),d.focus(),n.wrapper.addClass("k-focus")}})}return i}});function p(e){e.preventDefault()}function f(e,t){return function(){return e.apply(t,arguments)}}n.plugin(h),t.cssProperties.registerPrefix("ColorPicker","k-picker-"),t.cssProperties.registerValues("ColorPicker",[{prop:"rounded",values:t.cssProperties.roundedValues.concat([["full","full"]])}])}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=n.keys,o=e.map,a=e.each,s=n.trim,l=e.extend,c=n.isFunction,d=(n.template,n._outerWidth),u=n._outerHeight,h=i.Widget,p=/^(a|div)$/i,f=".kendoTabStrip",m="href",g="prev",v="next",_="show",b="k-link",y="k-link-text",w="k-last",k="click",x="k-image",C="k-first",S="select",T="activate",D="k-tabstrip-content",A="contentUrl",M="mouseenter",E="contentLoad",I="k-disabled",z="k-active",P="k-focus",H="k-hover",F=".k-item:not(."+I+")",R=".k-item",L=".k-tabstrip-items > "+F+":not(."+z+")",B="aria-hidden",O="aria-controls",V="aria-disabled",N="aria-selected",$="aria-labelledby",U={content:e=>`<div class='k-tabstrip-content' ${e.contentAttributes(e)} tabindex='0'>${e.content(e.item)}</div>`,textWrapper:({tag:e,item:t,contentUrl:n,textAttributes:i,image:r,sprite:o,text:a})=>`<${e(t)} class='${b}' ${n(t)} ${i(t)}>${r(t)}${o(t)}<span class='${y}'>${a(t)}</span></${e(t)}>`,item:e=>U.itemWrapper(e,`${e.textWrapper(e)}`),itemWrapper:(e,t)=>`<li class='${e.wrapperCssClass(e.group,e.item)}' role='tab' ${e.item.active?"aria-selected='true'":""}>`+t+"</li>",image:({imageUrl:e})=>`<img class='k-image' alt='' src='${e}' />`,sprite:({spriteCssClass:e})=>`<span class='k-sprite ${e}'></span>`,empty:()=>""},W={wrapperCssClass:function(e,t){var n=["k-item"],i=t.index;return!1===t.enabled&&n.push("k-disabled"),0===i&&n.push("k-first"),i==e.length-1&&n.push("k-last"),n.join(" ")},textAttributes:function(e){return e.url?" href='"+e.url+"'":""},text:function(e){return!1===e.encoded?e.text:n.htmlEncode(e.text)},tag:function(e){return e.url?"a":"span"},contentAttributes:function(e){return!0!==e.active?` ${n.attr("style-display")}="none" aria-hidden='true'`:""},content:function(e){return e.content?e.content:e.contentUrl?"":"&nbsp;"},contentUrl:function(e){return e.contentUrl?n.attr("content-url")+'="'+e.contentUrl+'"':""}};function j(t){t.children("img").addClass(x),t.children("a").addClass(b).children("img").addClass(x),t.filter("li[disabled]").addClass(I).attr(V,"true").prop("disabled",!1),t.filter(":not([class*=k-state])").children("a").filter(":focus").parent().addClass(z),t.attr("role","tab"),t.each((function(){var t=e(this);t.attr(N,t.is("."+z)),t.children("."+b).length||t.contents().filter((function(){return!(this.nodeName.match(p)||3==this.nodeType&&!s(this.nodeValue))})).wrapAll("<span UNSELECTABLE='on' class='"+b+"'/>").wrapAll("<span UNSELECTABLE='on' class='"+y+"'/>")}))}function q(e){var t=e.children(".k-item");t.filter(".k-first:not(:first-child)").removeClass(C),t.filter(".k-last:not(:last-child)").removeClass(w),t.filter(":first-child").addClass(C),t.length>1&&t.filter(":last-child").addClass(w)}function G(e,t){return`<span aria-hidden='true' tabindex='-1' class='k-button k-button-md k-rounded-md k-button-flat k-button-flat-base k-icon-button k-tabstrip-${e}' unselectable='on'>${n.ui.icon({icon:t,iconClass:"k-button-icon"})}</span>`}function K(){var t=this,n=e.ajaxSettings.xhr(),i=t.progressUpload?"progressUpload":!!t.progress&&"progress";return n&&e.each([n,n.upload],(function(){this.addEventListener&&this.addEventListener("progress",(function(e){i&&t[i](e)}),!1)})),t.noProgress=!(window.XMLHttpRequest&&"upload"in new XMLHttpRequest),n}var Y=h.extend({init:function(e,t){var i,r=this;h.fn.init.call(r,e,t),r._animations(r.options),t=r.options,r._contentUrls=t.contentUrls||[],r._wrapper(),r._isRtl=n.support.isRtl(r.wrapper),r._updateClasses(),r._dataSource(),r._tabindex(r.tabGroup),r.tabGroup.attr("role","tablist"),t.dataSource&&r.dataSource.fetch(),r._tabPosition(),r._scrollable(),r._sortable(),r._processContentUrls(),r._attachEvents(),r.options.value&&(i=r.options.value),r._initialActivate(),r.value(i),n.notify(r),r._showWatermarkOverlay&&r._showWatermarkOverlay(r.element[0])},events:[S,T,_,"error",E,"change","dataBinding","dataBound"],options:{name:"TabStrip",dataEncodedField:"",dataTextField:"",dataContentField:"",dataImageUrlField:"",dataUrlField:"",dataSpriteCssClass:"",dataContentUrlField:"",tabPosition:"top",tabTemplate:null,animation:{open:{effects:"expand:vertical fadeIn",duration:200},close:{duration:200}},collapsible:!1,navigatable:!0,contentUrls:!1,applyMinHeight:!0,scrollable:{distance:200},sortable:!1},setDataSource:function(e){var t=this;t.options.dataSource=e,t._dataSource(),t.dataSource.fetch()},setOptions:function(e){var t=this,n=t.options.animation;t._animations(e),e.contentUrls&&(t._contentUrls=e.contentUrls),e.animation=l(!0,n,e.animation),e.navigatable?t.tabGroup.on("keydown"+f,t._keyDownProxy):t.tabGroup.off("keydown"+f,t._keyDownProxy),h.fn.setOptions.call(t,e)},activateTab:function(e){if(!this.tabGroup.children("[data-animating]").length){e=this.tabGroup.find(e);var t=this,i=t.options.animation,r=i.open,o=l({},i.close),a=o&&"effects"in o,s=e.parent().children(),c=s.filter("."+z),d=s.index(e);o=l(a?o:l({reverse:!0},r),{hide:!0}),n.size(r.effects)?(c.kendoRemoveClass(z,{duration:o.duration}),e.kendoRemoveClass(H,{duration:o.duration})):(c.removeClass(z),e.removeClass(H));var h=t.contentAnimators;if(t.inRequest&&(t.xhr.abort(),t.inRequest=!1),0===h.length)return t.tabGroup.find("."+z),e.addClass(z),t._current(e,!0),t.trigger("change"),t._scrollableModeActive&&t._scrollTabsToItem(e),!1;var p=h.filter("."+z),f=t.contentHolder(d),m=f.closest(".k-tabstrip-content");if(t.tabsHeight=u(t.tabGroup)+parseInt(t.wrapper.css("border-top-width"),10)+parseInt(t.wrapper.css("border-bottom-width"),10),0===f.length)return p.removeClass(z).attr(B,!0).kendoStop(!0,!0).kendoAnimate(o),!1;e.attr("data-animating",!0);var g=!(!e.children("."+b).data(A)&&!t._contentUrls[d])&&f.is(":empty"),v=function(){c.attr(N,!1),e.attr(N,!0),t.tabGroup.attr("aria-activedescendant",e.attr("id")),t._current(e,!0),m.addClass(z).removeAttr(B).kendoStop(!0,!0).kendoAnimate(l({init:function(){t.trigger(_,{item:e[0],contentElement:f[0]}),n.resize(f)}},r,{complete:function(){t.element.css("min-height",w),e.removeAttr("data-animating"),t.trigger(T,{item:e[0],contentElement:f[0]}),n.resize(f)}}))},y=function(){g?(e.removeAttr("data-animating"),t.ajaxRequest(e,f,(function(){e.attr("data-animating",!0),v(),t.trigger("change")}))):(v(),t.trigger("change")),t._scrollableModeActive&&t._scrollTabsToItem(e)},w=t.element.css("min-height");return t.options.applyMinHeight&&t.element.css("min-height",t.element.outerHeight()),p.removeClass(z),t.tabGroup.find("."+z),n.size(r.effects)?e.kendoAddClass(z,{duration:r.duration}):e.addClass(z),p.attr(B,!0),p.length?p.kendoStop(!0,!0).kendoAnimate(l({complete:y},o)):y(),!0}},ajaxRequest:function(t,i,r,o){t=this.tabGroup.find(t);var a=this,s=t.find("."+b);o=o||s.data(A)||a._contentUrls[t.index()]||s.attr(m),a.inRequest=!0;var l={type:"GET",cache:!1,url:o,dataType:"html",data:{},xhr:K,error:function(e,t){a.trigger("error",{xhr:e,status:t})&&this.complete()},complete:function(e){a.inRequest=!1},success:function(e){try{n.destroy(i),i.html(e)}catch(e){this.error(this.xhr,"error")}r&&r.call(a,i),a.trigger(E,{item:t[0],contentElement:i[0]})}};"object"==typeof o&&(l=e.extend(!0,{},l,o),c(l.url)&&(l.url=l.url()),c(l.data)&&(l.data=l.data())),a.xhr=e.ajax(l)},append:function(e){var t=this,n=t._create(e);return a(n.tabs,(function(e){var i=n.contents[e];t.tabGroup.append(this),"bottom"==t.options.tabPosition?t.tabWrapper.before(i):t.wrapper.append(i)})),q(t.tabGroup),t._updateContentElements(),t.resize(!0),t},contentElement:function(i){if(isNaN(i-0))return t;var r=this.contentElements&&this.contentElements[0]&&!n.kineticScrollNeeded?this.contentElements:this.contentAnimators,o=e(this.tabGroup.children()[i]).attr(O);if(r)for(var a=0,s=r.length;a<s;a++)if(r.eq(a).closest(".k-tabstrip-content")[0].id==o)return r[a];return t},contentHolder:function(t){var i=e(this.contentElement(t)),r=i.children(".km-scroll-container");return n.support.touch&&r[0]?r:i},deactivateTab:function(e){var t=this,i=t.options.animation,r=i.open,o=l({},i.close),a=o&&"effects"in o;e=t.tabGroup.find(e),o=l(a?o:l({reverse:!0},r),{hide:!0}),n.size(r.effects)?e.kendoRemoveClass(z,{duration:r.duration}):e.removeClass(z),e.attr(N,!1),t.tabGroup.removeAttr("aria-activedescendant"),t.contentAnimators.filter("."+z).kendoStop(!0,!0).kendoAnimate(o).removeClass(z).attr(B,!0)},destroy:function(){var e=this;h.fn.destroy.call(e),e._refreshHandler&&e.dataSource.unbind("change",e._refreshHandler),e.wrapper.off(f),e.tabGroup.off(f),e._scrollableModeActive&&(e._scrollPrevButton.off().remove(),e._scrollNextButton.off().remove()),n.destroy(e.wrapper)},disable:function(e){return this._toggleDisabled(e,!1),this},enable:function(e,t){return this._toggleDisabled(e,!1!==t),this},insertAfter:function(t,n){n=e(t).is(e(n))?this.tabGroup.find(n).prev():this.tabGroup.find(n);var i=this,r=i._create(t),o=i.element.find("[id='"+n.attr(O)+"']");return a(r.tabs,(function(t){var a=r.contents[t],s=r.newTabsCreated?i._contentUrls.length-(r.tabs.length-t):e(a).index()-1;n.after(this),o.after(a),i._moveUrlItem(s,e(this).index())})),q(i.tabGroup),i._updateContentElements(r.newTabsCreated),i.resize(!0),i},insertBefore:function(t,n){n=e(t).is(e(n))?this.tabGroup.find(n).next():this.tabGroup.find(n);var i=this,r=i._create(t),o=i.element.find("[id='"+n.attr(O)+"']");return a(r.tabs,(function(t){var a=r.contents[t],s=r.newTabsCreated?i._contentUrls.length-(r.tabs.length-t):e(a).index()-1;n.before(this),o.before(a),i._moveUrlItem(s,e(this).index())})),q(i.tabGroup),i._updateContentElements(r.newTabsCreated),i.resize(!0),i},items:function(){return this.tabGroup[0].children},refresh:function(e){var t,i,r,o=this,a=o.options,s=n.getter(a.dataEncodedField),l=n.getter(a.dataTextField),c=n.getter(a.dataContentField),d=n.getter(a.dataContentUrlField),u=n.getter(a.dataImageUrlField),h=n.getter(a.dataUrlField),p=n.getter(a.dataSpriteCssClass),f=[],m=o.dataSource.view();for((e=e||{}).action&&(m=e.items),t=0,r=m.length;t<r;t++)i={text:l(m[t])},a.tabTemplate&&(i.model=m[t],i.template=a.tabTemplate),a.dataEncodedField&&(i.encoded=s(m[t])),a.dataContentField&&(i.content=c(m[t])),a.dataContentUrlField&&(i.contentUrl=d(m[t])),a.dataUrlField&&(i.url=h(m[t])),a.dataImageUrlField&&(i.imageUrl=u(m[t])),a.dataSpriteCssClass&&(i.spriteCssClass=p(m[t])),f[t]=i;if("add"==e.action)e.index<o.tabGroup.children().length?o.insertBefore(f,o.tabGroup.children().eq(e.index)):o.append(f);else if("remove"==e.action)for(t=0;t<m.length;t++)o.remove(e.index);else"itemchange"==e.action?(t=o.dataSource.view().indexOf(m[0]),e.field===a.dataTextField&&o.tabGroup.children().eq(t).find(".k-link").text(m[0].get(e.field)),e.field===a.dataUrlField&&(o._contentUrls[t]=m[0].get(e.field))):(o.trigger("dataBinding"),o.remove("li"),o._contentUrls=[],o.append(f),o.trigger("dataBound"))},reload:function(t){t=this.tabGroup.find(t);var n=this,i=n._contentUrls;return t.each((function(){var t=e(this),r=t.find("."+b).data(A)||i[t.index()],o=n.contentHolder(t.index());r&&n.ajaxRequest(t,o,null,r)})),n},remove:function(t){var i,r=this,o=typeof t;return"string"===o?t=r.tabGroup.find(t):"number"===o&&(t=r.tabGroup.children().eq(t)),i=t.map((function(){var t=e(this).index(),i=r.contentElement(t);return n.destroy(i),r._removeUrlItem(t),i})),t.remove(),i.empty(),i.remove(),r._updateContentElements(),r.resize(!0),r},select:function(t){var n=this;return 0===arguments.length?n.tabGroup.children("li."+z):(isNaN(t)||(t=n.tabGroup.children().get(t)),t=n.tabGroup.find(t),e(t).each((function(t,i){(i=e(i)).hasClass(z)||n.trigger(S,{item:i[0],contentElement:n.contentHolder(i.index())[0]})||(n.activateTab(i),n.tabGroup.attr("aria-activedescendant",i.attr("id")))})),n)},value:function(i){var r=this;if(i===t)return r.select().text();i!=r.value()&&r.tabGroup.children().each((function(){n.trim(e(this).text())==i&&r.select(this)}))},_active:function(){var e=this;setTimeout((function(){var t=e.tabGroup.children().filter("."+z);(t=t[0]?t:e._endItem("first"))[0]&&e._current(t)}),100)},_animations:function(e){e&&"animation"in e&&!e.animation&&(e.animation={open:{effects:{}},close:{effects:{}}})},_appendUrlItem:function(e){this._contentUrls.push(e)},_attachEvents:function(){var e=this,t=e.options;e.tabGroup.on(k+f,".k-disabled .k-link",!1).on(k+f," > "+F,e._itemClick.bind(e)),e.wrapper.on("focus"+f,(function(){e.tabGroup.trigger("focus")})),e.tabGroup.on(M+f+" mouseleave"+f,L,e._toggleHover).on("focus"+f,e._active.bind(e)).on("blur"+f,(function(){e._current(null)})),e._keyDownProxy=e._keydown.bind(e),t.navigatable&&e.tabGroup.on("keydown"+f,e._keyDownProxy)},_click:function(e){var t,n,i=this,r=e.find("."+b),o=r.attr(m),a=i.options.collapsible,s=e.index(),l=i.contentHolder(s),c=e.parent().children().filter("."+P);if(e.closest(".k-tabstrip")[0]==i.wrapper[0]){if(e.is("."+I+(a?"":",."+z)))return c.removeClass(P),i._focused=e,e.addClass(P),i._current(e),i._scrollableModeActive&&i._scrollTabsToItem(e),!0;if(n=r.data(A)||i._contentUrls[s]||o&&("#"==o.charAt(o.length-1)||-1!=o.indexOf("#"+i.element[0].id+"-")),t=!o||n,i.tabGroup.children("[data-animating]").length)return t;if(i.trigger(S,{item:e[0],contentElement:l[0]}))return!0;if(!1!==t)return a&&e.is("."+z)?(i.deactivateTab(e),!0):(i.activateTab(e)&&(i._current(e),t=!0),t)}},_create:function(t){var i,r,a,s=this,c=!1;return t=t instanceof n.data.ObservableArray?t.toJSON():t,e.isPlainObject(t)||Array.isArray(t)?(t=Array.isArray(t)?t:[t],c=!0,i=o(t,(function(n,i){return s._appendUrlItem(t[i].contentUrl||null),e(Y.renderItem({group:s.tabGroup,item:l(n,{index:i})}))})),r=o(t,(function(t,i){if("string"==typeof t.content||t.contentUrl){let r=e(Y.renderContent({item:l(t,{index:i})}));return n.applyStylesFromKendoAttributes(r,["display"]),r}}))):(i="string"==typeof t&&"<"!=t[0]?s.element.find(t):e(t),r=e(),i.each((function(){if(/k-tabstrip-items/.test(this.parentNode.className)){var t=s.element.find("[id='"+this.getAttribute(O)+"']");a=t}else a=e("<div class='"+D+"'/>");r=r.add(a)})),j(i)),{tabs:i,contents:r,newTabsCreated:c}},_current:function(e,n){var i=this._focused;if(e===t)return i;i&&e&&i[0]===e[0]&&(i=!1),i&&i.removeClass(P),e&&!n&&e.addClass(P),this._focused=e},_dataSource:function(){var e=this;e.dataSource&&e._refreshHandler?e.dataSource.unbind("change",e._refreshHandler):e._refreshHandler=e.refresh.bind(e),e.dataSource=n.data.DataSource.create(e.options.dataSource).bind("change",e._refreshHandler)},_elementId:function(e,t,i){var r=e.attr("id"),o=this.element.attr("id"),a=n.guid();if(!r||r.indexOf(o+"-")>-1){var s=(o||a)+"-";return i&&(s+="tab-"),s+(t+1)}return r},_endItem:function(e){return this.tabGroup.children(F)[e]()},_getItem:function(e){return this.tabGroup.children(R)[e]()},_initialActivate:function(){var e=this,t=e.tabGroup.children("li."+z),n=e.contentHolder(t.index());t[0]&&n.length>0&&0===n[0].childNodes.length&&e.activateTab(t.eq(0))},_item:function(e,t){var n;return n=t===g?"last":"first",e?((e=e[t]())[0]||(e=this.tabGroup.children(R)[n]()),e.hasClass(I)&&e.addClass(P),(e.hasClass(I)||e.hasClass(z))&&(this._focused=e),e):this._endItem(n)},_itemClick:function(t){var i=this.tabGroup[0];if(i!==document.activeElement)if(n.support.browser.msie)try{i.setActive()}catch(e){i.focus()}else i.focus();this._click(e(t.currentTarget))&&t.preventDefault()},_keydown:function(e){var t,n=this,i=e.keyCode,o=n._current(),a=n._isRtl,s=/top|bottom/.test(n.options.tabPosition);if(e.target==e.currentTarget&&o){if(i!==r.DOWN||s)if(i!==r.UP||s)if(i===r.RIGHT&&s)t=a?g:v;else if(i===r.LEFT&&s)t=a?v:g;else if(i==r.ENTER||i==r.SPACEBAR)n._click(o),e.preventDefault();else{if(i==r.HOME)return n._click(n._getItem("first")),void e.preventDefault();if(i==r.END)return n._click(n._getItem("last")),void e.preventDefault()}else t=g;else t=v;t&&(n._click(n._item(o,t)),e.preventDefault())}},_moveUrlItem:function(e,t){this._contentUrls.splice(t,0,this._contentUrls.splice(e,1)[0])},_processContentUrls:function(){var t=this;t._contentUrls.length?t.tabGroup.children(".k-item").each((function(n,i){var r=t._contentUrls[n];"string"==typeof r&&e(i).find(">."+b).data(A,r)})):t._contentUrls.length=t.tabGroup.find("li.k-item").length},_removeUrlItem:function(e){this._contentUrls.splice(e,1)},_resize:function(){this._scrollable()},_scrollable:function(){var e,t,i,r,o=this,a=o.options;if(o._scrollableAllowed())if(o.wrapper.addClass("k-tabstrip-scrollable"),e=o.wrapper[0].offsetWidth,(t=o.tabGroup[0].scrollWidth)>e&&!o._scrollableModeActive){o._nowScrollingTabs=!1,o._isRtl=n.support.isRtl(o.element);var s=n.support.touch?"touchstart":"mousedown",l=n.support.touch?"touchend":"mouseup",c=n.support.browser,d=o._isRtl&&!c.msie&&!c.edge;o.tabWrapper.prepend(G("prev","caret-alt-left")),o.tabWrapper.append(G("next","caret-alt-right")),i=o._scrollPrevButton=o.tabWrapper.children(".k-tabstrip-prev"),r=o._scrollNextButton=o.tabWrapper.children(".k-tabstrip-next"),i.on(s+f,(function(){o._nowScrollingTabs=!0,o._scrollTabsByDelta(a.scrollable.distance*(d?1:-1))})),r.on(s+f,(function(){o._nowScrollingTabs=!0,o._scrollTabsByDelta(a.scrollable.distance*(d?-1:1))})),i.add(r).on(l+f,(function(){o._nowScrollingTabs=!1})),o._scrollableModeActive=!0,o._toggleScrollButtons()}else o._scrollableModeActive&&t<=e?(o._scrollableModeActive=!1,o.wrapper.removeClass("k-tabstrip-scrollable"),o._scrollPrevButton.off().remove(),o._scrollNextButton.off().remove()):o._scrollableModeActive?o._toggleScrollButtons():o.wrapper.removeClass("k-tabstrip-scrollable")},_scrollableAllowed:function(){var e=this.options;return e.scrollable&&!e.scrollable.distance&&(e.scrollable={distance:200}),e.scrollable&&!isNaN(e.scrollable.distance)&&("top"==e.tabPosition||"bottom"==e.tabPosition)},_scrollTabsToItem:function(e){var t,i=this,r=i.tabGroup,o=n.scrollLeft(r),a=d(e),s=i._isRtl?e.position().left:e.position().left-r.children().first().position().left,l=r[0].offsetWidth,c=n.support.browser;i._isRtl&&(c.mozilla||c.webkit&&c.version>=85)&&(o*=-1),i._isRtl?s<0?t=o+s-(l-o):s+a>l&&(t=o+s-a):o+l<s+a?t=s+a-l:o>s&&(t=s),r.finish().animate({scrollLeft:t},"fast","linear",(function(){i._toggleScrollButtons()}))},_scrollTabsByDelta:function(e){var t=this,i=t.tabGroup,r=n.scrollLeft(i),o=n.support.browser;t._isRtl&&(o.mozilla||o.webkit&&o.version>=85)&&(r*=-1),i.finish().animate({scrollLeft:r+e},"fast","linear",(function(){t._nowScrollingTabs&&!jQuery.fx.off?t._scrollTabsByDelta(e):t._toggleScrollButtons()}))},_sortable:function(){var e=this,t=e.options.tabPosition,i="left"===t||"right"===t?"y":"x";e.options.sortable&&(e.sortable=new n.ui.Sortable(e.tabGroup,{filter:"li.k-item",axis:i,container:e.tabWrapper,hint:e=>`<div id='hint' class='k-tabstrip k-tabstrip-${t}'>\n                                <div class= 'k-tabstrip-items-wrapper k-hstack'>\n                                    <ul class='k-tabstrip-items k-reset'>\n                                        <li class='k-item k-first k-active'>${e.html()}</li>\n                                    </ul>\n                                </div>\n                            </div>`,change:e._sortChange.bind(e),start:t=>e.activateTab(t.item)}))},_sortChange:function(e){var t=this,n=t.tabGroup.children().eq(e.newIndex);e.oldIndex<e.newIndex?t.insertAfter(e.item,n):t.insertBefore(e.item,n)},_tabPosition:function(){var e=this,t=e.options.tabPosition;e.wrapper.addClass("k-tabstrip-"+t),"bottom"==t&&e.tabWrapper.appendTo(e.wrapper),"left"!==t&&"right"!==t||e.tabGroup.attr("aria-orientation","vertical"),e.resize(!0)},_toggleHover:function(t){e(t.currentTarget).toggleClass(H,t.type==M)},_toggleDisabled:function(t,n){(t=this.tabGroup.find(t)).each((function(){e(this).toggleClass(I,!n).attr(V,!n)}))},_toggleScrollButtons:function(){var e=this,t=e.tabGroup,i=Math.floor(n.scrollLeft(t));const r=Math.abs(i-(t[0].scrollWidth-t[0].offsetWidth))<=1;e._scrollPrevButton.toggleClass("k-disabled",0===i),e._scrollNextButton.toggleClass("k-disabled",r)},_updateClasses:function(){var n,i,r,o=this,a=/top|bottom/.test(o.options.tabPosition);o.wrapper.addClass("k-tabstrip"),o.tabGroup||(o.tabGroup=o.wrapper.children("ul"),o.tabGroup.wrap("<div />"),o.tabWrapper=o.tabGroup.parent()),o.tabGroup[0]||(o.tabGroup=e("<ul />").prependTo(o.wrapper),o.tabGroup.wrap("<div />"),o.tabWrapper=o.tabGroup.parent()),o.tabWrapper.addClass("k-tabstrip-items-wrapper"),o.tabWrapper.addClass(a?"k-hstack":"k-vstack"),o.tabGroup.addClass("k-tabstrip-items k-reset"),(n=o.tabGroup.find("li").addClass("k-item")).length&&(r=(i=n.filter("."+z).index())>=0?i:t,o.tabGroup.contents().filter((function(){return 3==this.nodeType&&!s(this.nodeValue)})).remove()),o.contentElements=o.wrapper.children("div:not(.k-tabstrip-items-wrapper)"),o.contentElements.addClass(D).eq(r).addClass(z).css({display:"block"}),n.length&&(j(n),i=n.filter("."+z).index(),o.tabGroup.attr("aria-activedescendant",n.eq(i).attr("id")),q(o.tabGroup),o._updateContentElements(!0))},_updateContentElements:function(t){var i=this,r=i._contentUrls,o=i.tabGroup.children(".k-item"),a=i.wrapper.children("div:not(.k-tabstrip-items-wrapper)"),s=i._elementId.bind(i);a.length&&o.length>a.length?a.each((function(n){var i,r=s(e(this),n),a=o.filter("[aria-controls="+(r||0)+"]")[0];!a&&t&&(a=o[n]),a&&(a.setAttribute(O,r),i=a.id=s(e(a),n,!0),this.setAttribute($,i)),this.setAttribute("id",r)})):o.each((function(t){var n,o=a.eq(t),l=s(o,t);this.setAttribute(O,l),n=this.id=s(e(this),t,!0),!o.length&&r[t]?e("<div class='"+D+"'/>").appendTo(i.wrapper).attr("id",l):o.attr("id",l),o.attr("role","tabpanel"),o.attr("tabindex","0"),o.attr($,n),o.filter(":not(."+z+")").attr(B,!0)})),i.contentElements=i.contentAnimators=i.wrapper.children("div:not(.k-tabstrip-items-wrapper)"),i.tabsHeight=u(i.tabGroup)+parseInt(i.wrapper.css("border-top-width"),10)+parseInt(i.wrapper.css("border-bottom-width"),10),n.kineticScrollNeeded&&n.mobile.ui.Scroller&&(n.touchScroller(i.contentElements),i.contentElements=i.contentElements.children(".km-scroll-container"))},_wrapper:function(){var e=this;e.element.is("ul")?e.wrapper=e.element.wrapAll("<div />").parent():e.wrapper=e.element}});l(Y,{renderItem:function(e){e=l({tabStrip:{},group:{}},e);var t=U.empty,i=e.item,r=l(e,{image:i.imageUrl?U.image:t,sprite:i.spriteCssClass?U.sprite:t,textWrapper:U.textWrapper},W);return i.template?U.itemWrapper(r,n.template(i.template)(i.model)):U.item(r)},renderContent:function(e){return U.content(l(e,W))}}),n.ui.plugin(Y)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.roleSelector,i=t.ui,r=i.Widget,o=t.ViewEngine,a=t.View,s=e.extend,l="navigate",c="viewShow",d="sameViewRequested",u=t.support.mobileOS,h=u.ios&&!u.appMode&&u.flatVersion>=700,p="k-pane",f="k-pane-wrapper",m="k-collapsible-pane",g=r.extend({init:function(e,n){var i=this;r.fn.init.call(i,e,n),n=i.options,(e=i.element).addClass(p),i.options.collapsible&&e.addClass(m),this.history=[],this.historyCallback=function(e,t,n){var r=i.transition;return i.transition=null,h&&n&&(r="none"),i.viewEngine.showView(e,r,t)},this._historyNavigate=function(e){if("#:back"===e){if(1===i.history.length)return;i.history.pop(),e=i.history[i.history.length-1]}else e instanceof a&&(e=""),i.history.push(e);i.historyCallback(e,t.parseQueryStringParams(e))},this._historyReplace=function(e){var n=t.parseQueryStringParams(e);i.history[i.history.length-1]=e,i.historyCallback(e,n)},i.viewEngine=new o(s({},{container:e,transition:n.transition,modelScope:n.modelScope,rootNeeded:!n.initial,serverNavigation:n.serverNavigation,remoteViewURLPrefix:n.root||"",layout:n.layout,showStart:function(){i.closeActiveDialogs()},after:function(){},viewShow:function(e){i.trigger(c,e)},loadStart:function(){},loadComplete:function(){},sameViewRequested:function(){i.trigger(d)},viewTypeDetermined:function(e){e.remote&&i.options.serverNavigation||i.trigger(l,{url:e.url})}},this.options.viewEngine)),this._setPortraitWidth(),t.onResize((function(){i._setPortraitWidth()}))},closeActiveDialogs:function(){this.element.find(n("actionsheet popover modalview")).filter(":visible").each((function(){t.widgetInstance(e(this),i).close()}))},navigateToInitial:function(){var e=this.options.initial;return e&&this.navigate(e),e},options:{name:"Pane",portraitWidth:"",transition:"",layout:"",collapsible:!1,initial:null,modelScope:window},events:[l,c,d],append:function(e){return this.viewEngine.append(e)},destroy:function(){var e=this;r.fn.destroy.call(e),e.viewEngine&&e.viewEngine.destroy()},navigate:function(e,t){e instanceof a&&(e=e.id),this.transition=t,this._historyNavigate(e)},replace:function(e,t){e instanceof a&&(e=e.id),this.transition=t,this._historyReplace(e)},view:function(){return this.viewEngine.view()},_setPortraitWidth:function(){this.options.portraitWidth&&this.element.css("width",undefined)}});g.wrap=function(e,i){e.is(n("view"))||(e=e.wrap("<div data-"+t.ns+'role="view" data-stretch="true"></div>').parent());var r=e.wrap('<div class="'+f+' k-widget"><div></div></div>').parent(),o=new g(r,i);return o.navigate(""),o},t.Pane=g}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=n.support,o=n.htmlEncode,a=r.browser.chrome?"disabled":"off",s="kendoPopup",l="init",c="open",d="refresh",u="change",h=".kendoFilterMenu",p=".k-table-th",f="Is equal to",m="Is not equal to",g={number:"numerictextbox",date:"datepicker"},v={string:"text",number:"number",date:"date"},_=n.isFunction,b=i.Widget,y=({actionsCssClass:e,messages:t})=>`<div class="k-actions-stretched ${e||"k-actions"}">`+n.html.renderButton(`<button title="${t.filter}">${o(t.filter)}</button>`,{type:"submit",themeColor:"primary",icon:"filter"})+n.html.renderButton(`<button title="${t.clear}">${o(t.clear)}</button>`,{type:"reset",icon:"filter-clear"})+"</div>",w=({field:e,format:t,ns:n,messages:i,extra:r,operators:a,type:s,role:l,values:c,componentType:d})=>`<div class="k-filter-menu-container"><div class="k-filter-help-text">${o(i.info)}</div><label><input type="radio" data-${n}bind="checked: filters[0].value" value="true" name="filters[0].value"/>${o(i.isTrue)}</label><label><input type="radio" data-${n}bind="checked: filters[0].value" value="false" name="filters[0].value"/>${o(i.isFalse)}</label>`+y({messages:i})+"</div>",k=({field:e,format:t,ns:i,messages:r,extra:a,operators:s,type:l,role:c,values:d,componentType:u})=>{var h=n.guid(),p=n.guid();return`<div class="k-filter-menu-container"><div><ul class="k-radio-list k-reset"><li><input type="radio" class="k-radio k-radio-md" id="${h}" data-${i}bind="checked: filters[0].value" value="true" name="filters[0].value" /><label class="k-radio-label" for="${h}">${o(r.isTrue)}</label></li><li><input type="radio" class="k-radio k-radio-md" id="${p}" data-${i}bind="checked: filters[0].value" value="false" name="filters[0].value" /><label class="k-radio-label" for="${p}">${o(r.isFalse)}</label></li></ul>`+y({actionsCssClass:"k-columnmenu-actions",messages:r})+"</div></div>"},x=({field:e,format:t,ns:n,messages:i,extra:r,operators:a,type:s,role:l,values:c,componentType:d})=>`<div class="k-filter-menu-container"><div class="k-filter-help-text">${o(i.info)}</div><label><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input class="k-input-inner" data-${n}bind="value: filters[0].value" name="filters[0].value"/></span></label>`+y({messages:i})+"</div>",C=({field:e,format:t,ns:i,messages:r,extra:a,operators:s,type:l,role:c,values:d,componentType:u})=>'<div class="k-filter-menu-container">'+("classic"===u?`<div class="k-filter-help-text">${o(r.info)}</div>`:"")+`<select title="${r.operator}" data-${i}bind="value: filters[0].operator" data-${i}role="dropdownlist">`+`${Object.keys(s||{}).map((e=>`<option value="${e}">${s[e]}</option>`))}</select>`+(d?`<select title="${r.value}" data-${i}bind="value:filters[0].value" data-${i}text-field="text" data-${i}value-field="value" data-${i}source='${n.stringify(d).replace(/\'/g,"&#39;")}' data-${i}role="dropdownlist" data-${i}option-label="${r.selectValue}" data-${i}value-primitive="true"></select>`:`<input title="${r.value}" data-${i}bind="value:filters[0].value" class="k-input-inner" type="text" ${c?`data-${i}role="${c}"`:""} />`)+(a?("modern"===u?`<ul data-${i}role="buttongroup" data-bind="events: { select: onLogicChange }"><li data-${i}value="and">And</li><li data-${i}value="or">Or</li></ul>`:`<select title="${r.logic}" class="k-filter-and" data-${i}bind="value: logic" data-${i}role="dropdownlist"><option value="and">${o(r.and)}</option><option value="or">${o(r.or)}</option></select>`)+`<select title="${r.additionalOperator}" data-${i}bind="value: filters[1].operator" data-${i}role="dropdownlist">`+`${Object.keys(s||{}).map((e=>`<option value="${e}">${o(s[e])}</option>`))}</select>`+(d?`<select title="${r.additionalValue}" data-${i}bind="value:filters[1].value" data-${i}text-field="text" data-${i}value-field="value" data-${i}source='${n.stringify(d).replace(/\'/g,"&#39;")}' data-${i}role="dropdownlist" data-${i}option-label="${r.selectValue}" data-${i}value-primitive="true"></select>`:`<input title="${r.additionalValue}" data-${i}bind="value: filters[1].value" class="k-input-inner" type="text" ${c?`data-${i}role="${c}"`:""}/>`):"")+y({messages:r})+"</div>",S=({field:e,title:t,format:i,ns:r,messages:s,extra:l,operators:c,filterMenuGuid:d,type:u,role:h,inputType:p,values:f})=>`<div data-${r}role="view" class="k-grid-filter-menu"><div data-${r}role="header" class="k-appbar k-appbar-primary">`+n.html.renderButton(`<button class="k-header-cancel" title="${s.cancel}" aria-label="${s.cancel}"></button>`,{icon:"chevron-left",fillMode:"flat"})+'<span class="k-spacer"></span>'+`<span>${o(s.filter)} ${o(s.into)} ${o(t)}</span><span class="k-spacer"></span>`+n.html.renderButton(`<button class="k-header-done" title="${s.done}" aria-label="${s.done}"></button>`,{icon:"check",fillMode:"flat"})+"</div>"+`<form title="${s.title}" class="k-filter-menu"><ul class="k-reset"><li>`+`<span class="k-list-title k-filter-help-text">${o(s.info)}</span><ul class="k-listgroup k-listgroup-flush"><li class="k-item k-listgroup-item"><label class="k-listgroup-form-row k-label">`+`<span class="k-listgroup-form-field-label k-filter-operator-text">${s.operator}</span><span class="k-listgroup-form-field-wrapper">`+`<select id="operator_${d}" title="${s.operator}" class="k-filter-operator" data-${r}bind="value: filters[0].operator" autocomplete="${a}" >`+`${Object.keys(c||{}).map((e=>`<option value="${e}">${o(c[e])}</option>`))}</select></span></label></li><li class="k-item k-listgroup-item"><label class="k-listgroup-form-row k-label">`+`<span class="k-listgroup-form-field-label k-filter-input-text">${s.value}</span><span class="k-listgroup-form-field-wrapper">`+(f?`<select id="value_${d}" title="${s.value}" data-${r}bind="value:filters[0].value" autocomplete="${a}" ><option value="">${s.selectValue}</option>${Object.keys(f||{}).map((e=>`<option value="${f[e].value}">${o(f[e].text)}</option>`))}</select>`:`<input id="value_${d}" title="${s.value}" data-${r}bind="value:filters[0].value" class="k-value-input" type="${p}" autocomplete="${a}" />`)+"</span></label></li></ul>"+(l?`<ul class="k-listgroup k-listgroup-flush"><li class="k-item k-listgroup-item"><label class="k-listgroup-form-row k-label"><span class="k-listgroup-form-field-label k-filter-logic-and-text">${s.and}</span><span class="k-listgroup-form-field-wrapper"><input id="and_${d}" title="${s.and}" type="radio" name="logic"data-${r}bind="checked: logic" value="and" autocomplete="${a}" /></span></label></li><li class="k-item k-listgroup-item"><label class="k-listgroup-form-row k-label"><span class="k-listgroup-form-field-label k-filter-logic-or-text">${s.or}</span><span class="k-listgroup-form-field-wrapper"><input id="or_${d}" title="${s.or}" type="radio" name="logic" data-${r}bind="checked: logic" value="or" autocomplete="${a}" /></span></label></li></ul><ul class="k-listgroup k-listgroup-flush"><li class="k-item k-listgroup-item"><label class="k-listgroup-form-row k-label"><span class="k-listgroup-form-field-label k-filter-operator-text">${s.additionalOperator}</span><span class="k-listgroup-form-field-wrapper"><select id="additionalOperator_${d}" title="${s.additionalOperator}" class="k-filter-operator" data-${r}bind="value: filters[1].operator" autocomplete="${a}" >${Object.keys(c||{}).map((e=>`<option value="${e}">${c[e]}</option>`))}</select></span></label></li><li class="k-item k-listgroup-item"><label class="k-listgroup-form-row k-label"><span class="k-listgroup-form-field-label k-filter-input-text">${s.additionalValue}</span><span class="k-listgroup-form-field-wrapper">`+(f?`<select id="additionalValue_${d}" title="${s.additionalValue}" data-${r}bind="value:filters[1].value" autocomplete="${a}" ><option value="">${s.selectValue}</option>${Object.keys(f||{}).map((e=>`<option value="${f[e].value}">${o(f[e].text)}</option>`))}</select>`:`<input id="additionalValue_${d}" title="${s.additionalValue}" data-${r}bind="value:filters[1].value" class="k-value-input" type="${p}" autocomplete="${a}" />`)+"</span></label></li></ul>":"")+'</li><li class="k-item k-clear-wrap"><span class="k-list-title">&nbsp;</span><ul class="k-listgroup k-listgroup-flush"><li class="k-listgroup-item">'+`<span class="k-link k-label k-clear" title="${s.clear}" aria-label="${s.clear}">`+`${o(s.clear)}</span></li></ul></li></ul></form></div>`,T=({field:e,title:t,format:i,ns:r,messages:s,extra:l,operators:c,filterMenuGuid:d,type:u,role:h,inputType:p,values:f})=>`<div data-${r}role="view" class="k-grid-filter-menu"><div data-${r}role="header" class="k-appbar k-appbar-primary">`+n.html.renderButton(`<button class="k-header-cancel" title="${s.cancel}" aria-label="${s.cancel}"></button>`,{icon:"chevron-left",fillMode:"flat"})+'<span class="k-spacer"></span>'+`<span>${o(s.filter)} ${o(s.into)} ${o(t)}</span><span class="k-spacer"></span>`+n.html.renderButton(`<button class="k-header-done" title="${s.done}" aria-label="${s.done}"></button>`,{icon:"check",fillMode:"flat"})+"</div>"+`<form title="${s.title}" class="k-filter-menu"><ul class="k-reset"><li>`+`<span class="k-list-title k-filter-help-text">${o(s.info)}</span><ul class="k-listgroup k-listgroup-flush k-multicheck-bool-wrap"><li class="k-item k-listgroup-item"><label class="k-listgroup-form-row k-label">`+`<span class="k-listgroup-form-field-label k-item-title">${o(s.isTrue)}</span><span class="k-listgroup-form-field-wrapper"></span>`+`<input id="true_${d}" title="${s.isTrue}" type="radio" data-${r}bind="checked: filters[0].value" value="true" name="filters[0].value" autocomplete="${a}" /></span></label></li><li class="k-item k-listgroup-item"><label class="k-listgroup-form-row k-label">`+`<span for="false_${d}" class="k-listgroup-form-field-label k-item-title">${o(s.isFalse)}</span><span class="k-listgroup-form-field-wrapper">`+`<input id="false_${d}" title="${s.isFalse}" type="radio" data-${r}bind="checked: filters[0].value" value="false" name="filters[0].value" autocomplete="${a}" /></span></label></li></ul></li><li class="k-item k-clear-wrap"><span class="k-list-title">&nbsp;</span><ul class="k-listgroup k-listgroup-flush"><li class="k-listgroup-item">`+`<span class="k-link k-label k-clear" title="${s.clear}" aria-label="${s.clear}">`+`${o(s.clear)}</span></li></ul></li></ul></form></div>`;function D(t,n){t.filters&&(t.filters=e.grep(t.filters,(function(e){return D(e,n),e.filters?e.filters.length:e.field!=n})))}function A(e){var t,n,i,r,o,a;if(e&&e.length)for(a=[],t=0,n=e.length;t<n;t++)o=""!==(i=e[t]).text?i.text||i.value||i:i.text,r=null==i.value?i.text||i:i.value,a[t]={text:o,value:r};return a}var M=b.extend({init:function(t,i){var r,o,a,s,l=this,c="string";for(o in(i=i||{}).componentType=i.componentType||"classic",b.fn.init.call(l,t,i),r=l.operators=i.operators||{},t=l.element,i=l.options,l.dataSource=H.create(i.dataSource),l.field=i.field||t.attr(n.attr("field")),(s=e(t.closest(p))).length?l.appendTo=s.find(i.appendTo):l.appendTo=e(i.appendTo),l.link=l._createLink()||e(),l.model=l.dataSource.reader.model,l._parse=function(e){return null!=e?e+"":e},l.model&&l.model.fields&&(a=l.model.fields[l.field])&&(c=a.type||"string",a.parse&&(l._parse=a.parse.bind(a))),i.values&&(c="enums"),l.type=c,r=r[c]||i.operators[c])break;l._defaultFilter=function(){return{field:l.field,operator:o||"eq",value:""}},l._refreshHandler=l.refresh.bind(l),l.dataSource.bind(u,l._refreshHandler),i.appendToElement?l._init():l.refresh()},_init:function(){var t,i=this,r=i.options.ui,o=_(r),a=n.attr("role");i.pane=i.options.pane,i.pane&&(i._isMobile=!0),o||(t=r||g[i.type]),i._isMobile?i._createMobileForm(t):i._createForm(t),i.form.on("submit"+h,i._submit.bind(i)).on("reset"+h,i._reset.bind(i)),o?i.form.find(".k-input-inner").removeClass("k-input-inner").each((function(){r(e(this))})):(i.form.find(".k-input-inner["+a+"]").removeClass("k-input-inner"),i.form.find(".k-input-inner:not([data-role]):not(.k-numerictextbox>.k-input-inner)").wrap("<span class='k-textbox k-input k-input-md k-rounded-md k-input-solid'></span>")),i.refresh(),i.trigger(l,{field:i.field,container:i.form}),i.options.cycleForm&&n.cycleForm(i.form)},_createForm:function(t){var i=this,r=i.options,a=i.operators||{},l=i.type;a=a[l]||r.operators[l],i.form=e('<form title="'+o(i.options.messages.title)+'" class="k-filter-menu"/>').html(n.template(i._getTemplate())({field:i.field,format:r.format,ns:n.ns,messages:r.messages,extra:r.extra,operators:a,type:l,role:t,values:A(r.values),componentType:i.options.componentType})),r.appendToElement?(i.element.append(i.form),i.popup=i.element.closest(".k-column-menu.k-popup").data(s)):i.popup=i.form[s]({anchor:i.link,copyAnchorStyles:!1,open:i._open.bind(i),activate:i._activate.bind(i),close:function(){i.options.closeCallback&&i.options.closeCallback(i.element)}}).data(s),i.form.on("keydown"+h,i._keydown.bind(i))},_getTemplate:function(){var e=this,t=_(e.options.ui);return"boolean"===e.type?t?x:"modern"===e.options.componentType?k:w:C},_createMobileForm:function(t){var i=this,r=i.options,o=i.operators||{},a=n.guid(),s=i.type;o=o[s]||r.operators[s],i.form=e("<div />").html(n.template("boolean"===s?T:S)({field:i.field,title:r.title||i.field,format:r.format,ns:n.ns,messages:r.messages,extra:r.extra,operators:o,filterMenuGuid:a,type:s,role:t,inputType:v[s],values:A(r.values)})),i.view=i.pane.append(i.form.html()),i.form=i.view.element.find("form"),i.view.element.on("click",".k-header-done",(function(e){i.form.submit(),e.preventDefault()})).on("click",".k-header-cancel",(function(e){i._closeForm(),e.preventDefault()})).on("click",".k-clear",(function(e){i._mobileClear(),e.preventDefault()})),i.view.bind("showStart",(function(){i.refresh()}))},_createLink:function(){var e,t=this,i=t.element,r=t.appendTo.length?i.find(t.appendTo):i,o=t.options,a=n.format(o.messages.buttonTitle,t.options.title||t.field);if(!o.appendToElement)return(e=i.addClass("k-filterable").find(".k-grid-filter-menu"))[0]||(e=r.append('<a class="k-grid-filter-menu k-grid-header-menu" href="#" aria-hidden="true" title="'+a+'" >'+n.ui.icon("filter")+"</a>").find(".k-grid-filter-menu")),e.attr("tabindex",-1).on("click"+h,t._click.bind(t)),e},refresh:function(){var e=this,t=e.dataSource.filter()||{filters:[],logic:"and"},i=[e._defaultFilter()],r=e._defaultFilter().operator;(e.options.extra||"isnull"!==r&&"isnullorempty"!==r&&"isnotnullorempty"!==r&&"isnotnull"!==r&&"isempty"!==r&&"isnotempty"!==r)&&i.push(e._defaultFilter()),e.filterModel=n.observable({logic:"and",filters:i}),e.form&&(n.bind(e.form.children().first(),e.filterModel),"modern"===e.options.componentType&&e.options.extra&&"boolean"!==e.type&&!e._isMobile&&(e.filterModel.bind("change",(function(){var t=n.attr("role"),i=e.form.find("["+t+"='buttongroup']").data("kendoButtonGroup"),r="and"===this.logic?0:1;i.select(i.element.children().eq(r))})),e.filterModel.set("onLogicChange",e._logicChangeHandler))),e._bind(t)?e.link.addClass("k-active"):e.link.removeClass("k-active")},_logicChangeHandler:function(e){var t=n.attr("value"),i=e.sender.current().attr(t);this.set("logic",i)},destroy:function(){var e=this;b.fn.destroy.call(e),e.form&&(n.unbind(e.form),n.destroy(e.form),e.form.off(h),e.popup&&(e.popup.destroy(),e.popup=null),e.form=null),e.view&&(e.view.purge(),e.view=null),e.link.off(h),e._refreshHandler&&(e.dataSource.unbind(u,e._refreshHandler),e.dataSource=null),e.element=e.link=e._refreshHandler=e.filterModel=null},_bind:function(e){var t,n,i,r,o=this,a=e.filters,s=!1,l=0,c=o.filterModel;for(t=0,n=a.length;t<n;t++)(r=a[t]).field==o.field?(c.set("logic",e.logic),(i=c.filters[l])||(c.filters.push({field:o.field}),i=c.filters[l]),i.set("value",o._parse(r.value)),i.set("operator",r.operator),l++,s=!0):r.filters&&(s=s||o._bind(r));return s},_stripFilters:function(t){return e.grep(t,(function(e){return""!==e.value&&null!=e.value||"isnull"===e.operator||"isnotnull"===e.operator||"isempty"===e.operator||"isnotempty"===e.operator||"isnullorempty"==e.operator||"isnotnullorempty"==e.operator}))},_merge:function(e){var t,n,i,r=this,o=e.logic||"and",a=this._stripFilters(e.filters),s=r.dataSource.filter()||{filters:[],logic:"and"};for(D(s,r.field),n=0,i=a.length;n<i;n++)(t=a[n]).value=r._parse(t.value);return a.length&&(s.filters.length?(e.filters=a,"and"!==s.logic&&(s.filters=[{logic:s.logic,filters:s.filters}],s.logic="and"),a.length>1?s.filters.push(e):s.filters.push(a[0])):(s.filters=a,s.logic=o)),s},filter:function(e){var t=this._stripFilters(e.filters);t.length&&this.trigger("change",{filter:{logic:e.logic,filters:t},field:this.field})||(e=this._merge(e)).filters.length&&this.dataSource.filter(e)},clear:function(t){var n=this;t=t||e.extend(!0,{},{filters:[]},n.dataSource.filter())||{filters:[]},this.trigger("change",{filter:null,field:n.field})||n._removeFilter(t)},_mobileClear:function(){var t=this,n=t.view.element;if("boolean"===t.type){var i=n.find("[type='radio']:checked"),r=i.val();i.val(""),i.trigger("change"),i.val(r),i.prop("checked",!1)}else{if(n.find("select").each((function(t,n){var i=e(n);i.val(i.find("option").first().val()),i.trigger("change")})),"string"===t.type||"date"===t.type||"number"===t.type)n.find(".k-value-input").each((function(t,n){var i=e(n);i.val(""),i.trigger("change")}));if(t.options.extra){var o=n.find("[name=logic]").first();o.prop("checked",!0),o.trigger("change")}}},_removeFilter:function(t){var n=this;t.filters=e.grep(t.filters,(function(t){return t.filters?(t.filters=(i=t.filters,r=n.field,e.grep(i,(function(t){return t.filters?(t.filters=e.grep(t.filters,(function(e){return e.field!=r})),t.filters.length):t.field!=r}))),t.filters.length):t.field!=n.field;var i,r})),t.filters.length||(t=null),n.dataSource.filter(t)},_submit:function(t){t.preventDefault(),t.stopPropagation();var n=this.filterModel.toJSON(),i=e.grep(n.filters,(function(e){return""!==e.value&&null!==e.value}));if(this._checkForNullOrEmptyFilter(n)||i&&i.length)this.filter(n);else{var r=this.dataSource.filter();r&&(r.filters.push(n),n=r),this.clear(n)}this._closeForm()},_checkForNullOrEmptyFilter:function(e){if(!e||!e.filters||!e.filters.length)return!1;var t,n=!1,i=!1;return e.filters[0]&&(n="isnull"==(t=e.filters[0].operator)||"isnotnull"==t||"isnotempty"==t||"isempty"==t||"isnullorempty"==t||"isnotnullorempty"==t),e.filters[1]&&(i="isnull"==(t=e.filters[1].operator)||"isnotnull"==t||"isnotempty"==t||"isempty"==t||"isnullorempty"==t||"isnotnullorempty"==t),!this.options.extra&&n||this.options.extra&&(n||i)},_reset:function(){this.clear(),this.options.search&&this.container&&this.container.find("label").parent().show(),this._closeForm()},_closeForm:function(){this._isMobile?this.pane.navigate("",this.options.animations.right):this.popup.close()},_click:function(e){e.preventDefault(),e.stopPropagation(),this.popup||this.pane||this._init(),this._isMobile?this.pane.navigate(this.view,this.options.animations.left):this.popup.toggle()},_open:function(){var t;e(".k-filter-menu").not(this.form).each((function(){(t=e(this).data(s))&&t.close()}))},_activate:function(){this.form.find(":kendoFocusable").first().trigger("focus"),this.trigger(c,{field:this.field,container:this.form})},_keydown:function(t){var i,r=e(t.target);if(t.keyCode==n.keys.ESC){if(i=n.widgetInstance(r.find("select")),r.hasClass("k-picker")&&i&&i.popup.visible())return void t.stopPropagation();r.closest(".k-popup").getKendoPopup().close()}},events:[l,"change",c],options:{name:"FilterMenu",extra:!0,appendToElement:!1,type:"string",operators:{string:{eq:f,neq:m,startswith:"Starts with",contains:"Contains",doesnotcontain:"Does not contain",endswith:"Ends with",isnull:"Is null",isnotnull:"Is not null",isempty:"Is empty",isnotempty:"Is not empty",isnullorempty:"Has no value",isnotnullorempty:"Has value"},number:{eq:f,neq:m,gte:"Is greater than or equal to",gt:"Is greater than",lte:"Is less than or equal to",lt:"Is less than",isnull:"Is null",isnotnull:"Is not null"},date:{eq:f,neq:m,gte:"Is after or equal to",gt:"Is after",lte:"Is before or equal to",lt:"Is before",isnull:"Is null",isnotnull:"Is not null"},enums:{eq:f,neq:m,isnull:"Is null",isnotnull:"Is not null"}},messages:{info:"Show items with value that:",title:"Show items with value that:",isTrue:"is true",isFalse:"is false",filter:"Filter",clear:"Clear",and:"And",or:"Or",selectValue:"-Select value-",operator:"Operator",value:"Value",additionalValue:"Additional value",additionalOperator:"Additional operator",logic:"Filters logic",cancel:"Cancel",done:"Done",into:"in",buttonTitle:"{0} filter column settings"},animations:{left:"slide",right:"slide:right"},componentType:"classic",cycleForm:!0,appendTo:null}}),E=".kendoFilterMultiCheck";function I(t,n){t.filters&&(t.filters=e.grep(t.filters,(function(e){return I(e,n),e.filters?e.filters.length:e.field==n&&"eq"==e.operator})))}function z(n){return"and"==n.logic&&n.filters.length>1?[]:n.filters?e.map(n.filters,(function(e){return z(e)})):n.value!==t?[n.value]:[]}function P(e,i){for(var r=n.getter(i,!0),o=[],a=0,s={};a<e.length;){var l=e[a++],c=r(l);c===t||s.hasOwnProperty(c)||(o.push(l),s[c]=!0)}return o}var H=n.data.DataSource,F=({field:e,title:t,ns:i,messages:r,search:s,checkAll:l})=>`<div data-${i}role="view" class="k-grid-filter-menu"><div data-${i}role="header" class="k-appbar k-appbar-primary">`+n.html.renderButton(`<button class="k-header-cancel" title="${r.cancel}" aria-label="${r.cancel}"></button>`,{icon:"chevron-left",fillMode:"flat"})+'<span class="k-spacer"></span>'+`<span>${o(r.filter)} ${o(r.into)} ${o(t)}</span><span class="k-spacer"></span>`+n.html.renderButton(`<button class="k-header-done" title="${r.done}" aria-label="${r.done}"></button>`,{icon:"check",fillMode:"flat"})+'</div><div class="k-stretched-view k-content"><form class="k-filter-menu">'+(s?'<div class="k-list-filter"><span class="k-searchbox k-input k-input-md k-input-solid k-rounded-md"><span class="k-input-icon k-icon k-svg-icon k-svg-i-search">'+n.ui.icon("search")+"</span>"+`<input class="k-input-inner" placeholder="${r.search}" title="${r.search}" autocomplete="${a}"  /></span></div>`:"")+'<div class="k-filter-tools">'+(r.selectedItemsFormat?'<div class="k-filter-selected-items"></div>':"")+'<span class="k-spacer"></span>'+`<span ${l?"":`${n.attr("style-visibility")}="hidden"`} class="k-label k-select-all" title="${r.checkAll}" `+`aria-label="${r.checkAll}">${r.checkAll}</span>`+`<span class="k-label k-clear-all" title="${r.clearAll}" `+`aria-label="${r.clearAll}">${r.clearAll}</span></div><ul class="k-multicheck-wrap k-listgroup k-listgroup-flush"></ul></form></div></div>`,R=b.extend({init:function(t,i){var r;b.fn.init.call(this,t,i),i=this.options,this.element=e(t);var o,a,s=this.field=this.options.field||this.element.attr(n.attr("field")),l=i.checkSource;this._foreignKeyValues()?(this.checkSource=H.create(i.values),this.checkSource.fetch()):i.forceUnique?(delete(l=e.extend(!0,{},i.dataSource.options)).pageSize,this.checkSource=H.create(l),this.checkSource.reader.data=(o=this.checkSource.reader.data,a=this.field,function(e){return P(o(e),a)})):this.checkSource=H.create(l),this.dataSource=i.dataSource,this.model=this.dataSource.reader.model,this._parse=function(e){return e+""},this.model&&this.model.fields&&(s=this.model.fields[this.field])&&("number"==s.type?this._parse=function(e){return"string"==typeof e&&("null"===e.toLowerCase()||this._foreignKeyValues()&&""===e)?null:parseFloat(e)}:s.parse&&(this._parse=s.parse.bind(s)),this.type=s.type||"string"),(r=e(t.closest(p))).length?this.appendTo=r.find(i.appendTo):this.appendTo=e(i.appendTo),i.appendToElement?this._init():this._createLink(),this._refreshHandler=this.refresh.bind(this),this.dataSource.bind(u,this._refreshHandler)},_createLink:function(){var e=this.element,t=this.appendTo.length?e.find(this.appendTo):e,i=e.addClass("k-filterable").find(".k-grid-filter-menu"),r=o(n.format(this.options.messages.buttonTitle,this.options.title||this.field));i[0]||(i=t.append('<a class="k-grid-filter-menu k-grid-header-menu" href="#" title="'+r+'" aria-hidden="true"">'+n.ui.icon("filter")+"</a>").find(".k-grid-filter-menu")),this._link=i.attr("tabindex",-1).on("click"+h,this._click.bind(this))},_init:function(){var e=this,t=this.options.forceUnique,n=this.options;this.pane=n.pane,this.pane&&(this._isMobile=!0),this._createForm(),this._foreignKeyValues()?this.refresh():t&&!this.checkSource.options.serverPaging&&this.dataSource.data().length?(this.checkSource.data(P(this.dataSource.data(),this.field)),this.refresh()):(this._attachProgress(),this.checkSource.fetch((function(){e.refresh.call(e)}))),this.options.forceUnique||(this.checkChangeHandler=function(){e.container.empty(),e.refresh()},this.checkSource.bind(u,this.checkChangeHandler)),this.form.on("keydown"+E,this._keydown.bind(this)).on("submit"+E,this._filter.bind(this)).on("reset"+E,this._reset.bind(this)),this.trigger(l,{field:this.field,container:this.form})},_attachProgress:function(){var e=this;this._progressHandler=function(){i.progress(e.container,!0)},this._progressHideHandler=function(){i.progress(e.container,!1)},this.checkSource.bind("progress",this._progressHandler).bind("change",this._progressHideHandler)},_input:function(){var e=this;e._clearTypingTimeout(),e._typingTimeout=setTimeout((function(){e.search()}),100)},_clearSearch:function(){this.searchTextBox.val(""),this.search()},_clearTypingTimeout:function(){this._typingTimeout&&(clearTimeout(this._typingTimeout),this._typingTimeout=null)},search:function(){var e=this.options.ignoreCase,t=this.searchTextBox[0].value,n=this.container.find("label");e&&(t=t.toLowerCase());var i=0;for(this.options.checkAll&&n.length&&(this._isMobile?this.view.element.find(".k-select-all")[0].style.visibility=t?"hidden":"":(n[0].parentNode.style.display=t?"none":"",i++));i<n.length;){var r=n[i],o=r.textContent||r.innerText;e&&(o=o.toLowerCase()),r.parentNode.style.display=o.indexOf(t)>=0?"":"none",i++}},_activate:function(){this.form.find(":kendoFocusable").first().trigger("focus"),this.trigger(c,{field:this.field,container:this.form})},_createForm:function(){var t=this.options,i="",r=this;if(this._isMobile||(i+="<div class='k-filter-menu-container'>",t.search&&(i+="<span class='k-searchbox k-textbox k-input k-input-md k-rounded-md k-input-solid'>"+n.ui.icon(e('<span class="k-input-icon"></span>'),"search")+"<input class='k-input-inner' type='text' placeholder='"+o(t.messages.search)+"' /><span class='k-input-suffix'><span class='k-clear-value'>"+n.ui.icon("x")+"</span></span></span>"),i+="<ul class='k-reset k-multicheck-wrap'></ul>",t.messages.selectedItemsFormat&&(i+="<div class='k-filter-selected-items'>"+n.format(t.messages.selectedItemsFormat,0)+"</div>"),i+="<div class='k-actions'>",i+="<button type='submit' class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary'><span class='k-button-text'>"+o(t.messages.filter)+"</span></button>",i+="<button type='reset' class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base'><span class='k-button-text'>"+o(t.messages.clear)+"</span></button>",i+="</div>",i+="</div>",this.form=e('<form class="k-filter-menu"/>').html(i),this.container=this.form.find(".k-multicheck-wrap")),this._isMobile){let i=e(n.template(F)({field:r.field,title:t.title||r.field,ns:n.ns,messages:t.messages,search:t.search,checkAll:t.checkAll}));n.applyStylesFromKendoAttributes(i,["visibility"]),r.form=e("<div />").append(i),r.view=r.pane.append(r.form.html()),r.form=r.view.element.find("form");var a=this.view.element;this.container=a.find(".k-multicheck-wrap"),a.on("click",".k-header-done",(function(e){r.form.submit(),e.preventDefault()})).on("click",".k-header-cancel",(function(e){r._closeForm(),e.preventDefault()})).on("click",".k-clear-all",(function(e){r._mobileCheckAll(!1),e.preventDefault()})).on("click",".k-select-all",(function(e){r._mobileCheckAll(!0),e.preventDefault()})),r.view.bind("showStart",(function(){r.refresh()}))}else t.appendToElement?(this.popup=this.element.closest(".k-column-menu.k-popup").data(s),this.element.append(this.form)):r.popup=r.form.kendoPopup({anchor:r._link,copyAnchorStyles:!1,open:r._open.bind(r),activate:r._activate.bind(r),close:function(){r.options.closeCallback&&r.options.closeCallback(r.element)}}).data(s);t.search&&(this.searchTextBox=this.form.find(".k-searchbox input"),this.searchTextBox.on("input"+E,this._input.bind(this)),this.clearSearchButton=this.form.find(".k-searchbox .k-clear-value"),this.clearSearchButton.on("click"+E,this._clearSearch.bind(this)))},_open:function(){var t;e(".k-filter-menu").not(this.form).each((function(){(t=e(this).data(s))&&t.close()}))},createCheckAllItem:function(){var t=this.options,i=n.template(t.itemTemplate({field:"all",mobile:this._isMobile})),r=e(i({all:t.messages.checkAll}));this.container.prepend(r),r.addClass("k-check-all-wrap"),this.checkBoxAll=r.find(":checkbox").eq(0).addClass("k-check-all"),this.checkAllHandler=this.checkAll.bind(this),this.checkBoxAll.on(u+E,this.checkAllHandler)},updateCheckAllState:function(){if(this.options.messages.selectedItemsFormat&&this.form.find(".k-filter-selected-items").text(n.format(this.options.messages.selectedItemsFormat,this.container.find(":checked:not(.k-check-all)").length)),this.checkBoxAll){var e=this.container.find(":checkbox:not(.k-check-all)").length==this.container.find(":checked:not(.k-check-all)").length;this.checkBoxAll.prop("checked",e)}},createIsNullItem:function(){var t=this.options,i=n.template(t.itemTemplate({field:"isNull",mobile:this._isMobile,valueField:"value"})),r=e(i({isNull:t.messages.isNull,value:null}));this.container.append(r)},refresh:function(e){var t=this.options.forceUnique,n=this.dataSource,i=this.getFilterArray();this._link&&this._link.toggleClass("k-active",0!==i.length),this.form&&(e&&t&&e.sender===n&&!n.options.serverPaging&&("itemchange"==e.action||"add"==e.action||"remove"==e.action||n.options.autoSync&&"sync"===e.action)&&!this._foreignKeyValues()&&(this.checkSource.data(P(this.dataSource.data(),this.field)),this.container.empty()),this.container.is(":empty")&&this.createCheckBoxes(),this.checkValues(i),this.trigger(d))},getFilterArray:function(){var t=e.extend(!0,{},{filters:[],logic:"and"},this.dataSource.filter());return I(t,this.field),z(t)},createCheckBoxes:function(){var e,t=this.options,i={field:this.field,format:t.format,mobile:this._isMobile,type:this.type},r=L.bind(this);this.options.forceUnique?this._foreignKeyValues()?(e=this.checkSource.data(),i.valueField="value",i.field="text"):e=this.checkSource._isServerGrouped()?P(this.checkSource._flatData(this.checkSource.data()),this.field):this.checkSource.data():e=this.checkSource.view(),"boolean"===this.type&&(this.createIsNullItem(),e=e.filter(r));var o=n.template(t.itemTemplate(i)),a=n.render(o,e);this.container.on(u+E,":checkbox",this.updateCheckAllState.bind(this)),this.container.prepend(a),t.checkAll&&!this._isMobile&&this.createCheckAllItem()},checkAll:function(){var e=this.checkBoxAll.is(":checked");this.container.find(":checkbox").prop("checked",e)},checkValues:function(t){var n=this;e(e.grep(this.container.find(":checkbox").prop("checked",!1),(function(i){var r=!1;if(!e(i).is(".k-check-all"))for(var o=n._parse(e(i).val()),a=0;a<t.length;a++)if(r="date"==n.type?t[a]&&o?t[a].getTime()==o.getTime():null===t[a]&&null===o:t[a]==o)return r}))).prop("checked",!0),this.updateCheckAllState()},_mobileCheckAll:function(t){this.container.find(":checkbox").each((function(n,i){var r=e(i);r.prop("checked",t),r.trigger("change")}))},_filter:function(t){t.preventDefault(),t.stopPropagation();var n={logic:"or"},i=this;n.filters=e.map(this.form.find(":checkbox:checked:not(.k-check-all)"),(function(t){return{value:e(t).val(),operator:"eq",field:i.field}})),this.trigger("change",{filter:n,field:i.field})||((n=this._merge(n)).filters.length?this.dataSource.filter(n):i._removeFilter(i.dataSource.filter()||{filters:[]}),this._closeForm())},_stripFilters:function(t){return e.grep(t,(function(e){return null!=e.value}))},_foreignKeyValues:function(){var e=this.options;return e.values&&!e.checkSource},destroy:function(){var e=this;b.fn.destroy.call(e),e.form&&(n.unbind(e.form),n.destroy(e.form),e.form.off(E),e.popup&&(e.popup.destroy(),e.popup=null),e.form=null,e.container&&(e.container.off(E),e.container=null),e.checkBoxAll&&e.checkBoxAll.off(E)),e.view&&(e.view.purge(),e.view=null),e._link&&e._link.off(h),e._refreshHandler&&(e.dataSource.unbind(u,e._refreshHandler),e.dataSource=null),e.checkChangeHandler&&e.checkSource.unbind(u,e.checkChangeHandler),e._progressHandler&&e.checkSource.unbind("progress",e._progressHandler),e._progressHideHandler&&e.checkSource.unbind("change",e._progressHideHandler),this._clearTypingTimeout(),this.searchTextBox&&(this.searchTextBox.off(E),this.searchTextBox=null),this.clearSearchButton&&(this.clearSearchButton.off(E),this.clearSearchButton=null),e.element=e.checkSource=e.container=e.checkBoxAll=e._link=e._refreshHandler=e.checkAllHandler=null},options:{name:"FilterMultiCheck",itemTemplate:({field:e,mobile:i,valueField:r,format:a,type:s})=>{var l="";return r===t&&(r=e),"date"==s&&(l=":yyyy-MM-ddTHH:mm:sszzz"),i?t=>`<li class='k-item k-listgroup-item'><label class='k-label k-listgroup-form-row k-checkbox-label'><span class='k-listgroup-form-field-label k-item-title '>${o(n.format(a||"{0}",n.getter(e)(t)))}</span><span class="k-listgroup-form-field-wrapper"><input type='checkbox' class='k-checkbox k-checkbox-md k-rounded-md' value='${o(n.format(`{0${l}}`,n.getter(r)(t)))}'/></span></label></li>`:t=>`<li class='k-item'><label class='k-label k-checkbox-label'><span class="k-checkbox-wrap"><input type='checkbox' class='k-checkbox k-checkbox-md k-rounded-md' value='${o(n.format(`{0${l}}`,n.getter(r)(t)))}'/></span><span>${o(n.format(a||"{0}",n.getter(e)(t)))}</span></label></li>`},checkAll:!0,search:!1,ignoreCase:!0,appendToElement:!1,messages:{checkAll:"Select All",isNull:"is empty",clearAll:"Clear All",clear:"Clear",filter:"Filter",search:"Search",cancel:"Cancel",selectedItemsFormat:"{0} items selected",done:"Done",into:"in",buttonTitle:"{0} filter column settings"},forceUnique:!0,animations:{left:"slide",right:"slide:right"},appendTo:null},events:[l,d,"change",c]});function L(e){return null!==e[this.field]}e.extend(R.fn,{_click:M.fn._click,_keydown:M.fn._keydown,_reset:M.fn._reset,_closeForm:M.fn._closeForm,_removeFilter:M.fn._removeFilter,clear:M.fn.clear,_merge:M.fn._merge}),i.plugin(M),i.plugin(R)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=n._activeElement,o=n.support.touch&&n.support.mobileOS,a=Array.isArray,s=n.data.HierarchicalDataSource,l="mousedown",c="click",d=e.extend,u=e.each,h=n.htmlEncode,p=n.template,f=n.keys,m=i.Widget,g=/^(ul|a|div)$/i,v=".kendoMenu",_="open",b="k-menu",y="k-link k-menu-link",w=".k-link",k=".k-menu-expand-arrow",x="k-last",C="close",S="timer",T="k-first",D="k-image",A="select",M="zIndex",E="activate",I="deactivate",z="touchstart"+v+" MSPointerDown"+v+" pointerdown"+v,P=n.support.pointers,H=n.support.msPointers,F=H||P,R="change",L="error",B=n.support.touch?"touchstart":"",O=P?"pointerover":H?"MSPointerOver":"mouseenter",V=P?"pointerout":H?"MSPointerOut":"mouseleave",N="DOMMouseScroll"+v+" mousewheel"+v,$=n.support.resize+v,U="group",W="groupparent",j=e(document.documentElement),q="kendoPopup",G="k-hover",K="k-focus",Y="k-disabled",Q=".k-menu",X=".k-animation-container",Z=".k-child-animation-container",J=".k-menu-popup ,"+X,ee=":not(.k-list) > .k-item:not([role='treeitem'])",te=".k-item",ne=".k-item:not(.k-disabled)",ie=":not(.k-item.k-separator):visible",re=".k-menu-scroll-button",oe={2:1,touch:1},ae="dataBound",se="aria-expanded",le="role",ce={text:"dataTextField",url:"dataUrlField",spriteCssClass:"dataSpriteCssClassField",imageUrl:"dataImageUrlField",imageAttr:"dataImageAttrField",content:"dataContentField"},de={wrapperCssClass:function(e,t){var n="k-item k-menu-item",i=t.index;return t.separator&&(n+=" k-separator"),!1===t.enabled&&(n+=" k-disabled"),e.firstLevel&&0===i&&(n+=" k-first"),i==e.length-1&&(n+=" k-last"),t.cssClass&&(n+=" "+t.cssClass),t.attr&&t.attr.hasOwnProperty("class")&&(n+=" "+t.attr.class),t.selected&&(n+=" k-selected"),n},itemCssAttributes:function(e){var t="",n=e.attr||{};for(var i in n)n.hasOwnProperty(i)&&"class"!==i&&(t+=i+'="'+n[i]+'" ');return t},imageCssAttributes:function(e){var t="",n=e&&e.toJSON?e.toJSON():{};for(var i in n.class?n.class+=" "+D:n.class=D,n)n.hasOwnProperty(i)&&(t+=i+'="'+n[i]+'" ');return t},contentCssAttributes:function(e){var t="",n=e.contentAttr||{},i="k-content k-menu-group k-menu-group-md";for(var r in n.class?n.class+=" "+i:n.class=i,n)n.hasOwnProperty(r)&&(t+=r+'="'+n[r]+'" ');return t},textClass:function(){return y},groupAttributes:function(e){return!0!==e.expanded?`${n.attr("style-display")}="none"`:""},groupCssClass:function(){return"k-menu-group k-menu-group-md"},groupWrapperCssClass:function(){return"k-menu-popup"},content:function(e){return e.content?e.content:"&nbsp;"}};function ue(t,n){try{return e.contains(t,n)}catch(e){return!1}}function he(t){(t=e(t)).attr(n.attr("omit-wrap"))||(t.addClass("k-item k-menu-item").children("img").addClass(D),t.children("a").addClass(y).children("img").addClass(D),t.filter(":not([disabled])"),t.filter(".k-separator").removeClass("k-menu-item").addClass("k-menu-separator").empty().append("&nbsp;"),t.filter("li[disabled]").addClass(Y).prop("disabled",!1).attr("aria-disabled",!0),t.filter("[role]").length||t.attr(le,"menuitem"),t.children(w).length||t.contents().filter((function(){return!(this.nodeName.match(g)||3===this.nodeType&&!n.trim(this.nodeValue))})).wrapAll("<span class='"+y+"' role='none'></span>").filter((function(e,t){return 3===t.nodeType})).wrap("<span class='k-menu-link-text' role='none'></span>"),pe(t),me(t))}function pe(t){(t=e(t)).find("> .k-link > .k-menu-expand-arrow > [class*=k-i-caret]:not(.k-sprite),> .k-link > .k-menu-expand-arrow > [class*=k-svg-i-caret]:not(.k-sprite)").parent().remove(),t.filter(":has(.k-menu-group)").children(".k-link:not(:has([class*=k-i-caret]:not(.k-sprite))),.k-link:not(:has([class*=k-svg-i-caret]:not(.k-sprite)))").each((function(){var t=e(this);t.append(`<span aria-hidden='true' class='k-menu-expand-arrow'>${n.ui.icon({icon:fe(t)})}</span>`)}))}function fe(e){var t=e.parent().parent(),i=n.support.isRtl(t);return t.hasClass(b+"-horizontal")?"caret-alt-down":i?"caret-alt-left":"caret-alt-right"}function me(t){(t=e(t)).filter(".k-first:not(:first-child)").removeClass(T),t.filter(".k-last:not(:last-child)").removeClass(x),t.filter(":first-child").addClass(T),t.filter(":last-child").addClass(x)}function ge(e){if(e&&e.length)for(var t in e){var n=e.eq(t);n.find("ul").length?n.attr("aria-haspopup",!0):n.removeAttr("aria-haspopup")}}function ve(e){if(!e.hasClass(b))return e.parentsUntil("."+b,"li")}function _e(t,i){var r=function(e){var t=e.select,i=n.isFunction;if(t&&i(t))return t;return null}(i);r&&function(t,n){e(t).children(".k-link").data({selectHandler:n})}(t,r),i.items&&e(t).children("div").children("ul").children("li").each((function(e){_e(this,i.items[e])}))}function be(e){return e?"li[data-groupparent='"+e+"']":"li[data-groupparent]"}function ye(e){var t=e?"[data-group='"+e+"']":"[data-group]";return"ul"+t+",div"+t}function we(t,n){var i=t.find(be()),r=[];return i.each((function(i,o){for(var a=(o=e(o)).data(W),s=t;a;)(s=n.find(ye(a)+":visible")).length&&r.push(s),a=(o=s.find(be())).data(W)})),r}function ke(t,n){var i=t.data(U);return i?n.find(be(i)):e([])}function xe(t,n){var i=t.data(W);return i?n.children(X).find(ye(i)):e([])}function Ce(e,t){for(var n=0,i=e.parentNode;i&&!isNaN(i[t]);)n+=i[t],i=i.parentNode;return n}function Se(e){return F&&e.originalEvent&&e.originalEvent.pointerType in oe}function Te(e){e.contents().filter((function(){return"LI"!=this.nodeName})).remove()}var De=n.ui.DataBoundWidget.extend({init:function(e,t){var i=this;m.fn.init.call(i,e,t),e=i.wrapper=i.element,t=i.options,i._accessors(),i._templates(),i._dataSource(),i._updateClasses(),i._wrapGroups(),i._animations(t),i.nextItemZIndex=100,i._tabindex(),i._initOverflow(t),i._attachMenuEventsHandlers(),t.openOnClick&&(i.clicked=!1),e.attr(le,"menubar"),e[0].id?i._ariaId=n.format("{0}_mn_active",e[0].id):i._ariaId=n.format("{0}_mn_active",n.guid()),n.notify(i)},events:[_,C,E,I,A,ae],options:{name:"Menu",animation:{open:{duration:200},close:{duration:100}},orientation:"horizontal",direction:"default",openOnClick:!1,closeOnClick:!0,hoverDelay:100,scrollable:!1,popupCollision:null},_initData:function(){var e=this;e.dataSource&&(e.element.empty(),e.append(e.dataSource.view(),e.element))},_attachMenuEventsHandlers:function(){var t=this,n=t.element,i=t.options,r=t._overflowWrapper();t._checkActiveProxy=t._checkActiveElement.bind(t),(r||n).on(z,te,t._focusHandler.bind(t)).on(c+v,".k-item.k-disabled",!1).on(c+v,te,t._click.bind(t)).on(z+" "+l+v,".k-content",t._preventClose.bind(t)).on(O+v,ne,t._mouseenter.bind(t)).on(V+v,ne,t._mouseleave.bind(t)).on(l+v,ne,t._mousedown.bind(t)).on(B+v+" "+O+v+" "+V+v+" "+l+v+" "+c+v,".k-item:not(.k-disabled) > .k-link",t._toggleHover.bind(t)),n.on("keydown"+v,t._keydown.bind(t)).on("focus"+v,t._focus.bind(t)).on("focus"+v,".k-content",t._focus.bind(t)).on("blur"+v,t._removeFocusItem.bind(t)).on("blur"+v,"[tabindex]",t._checkActiveProxy),r&&r.on(V+v,J,t._mouseleavePopup.bind(t)).on(O+v,J,t._mouseenterPopup.bind(t)),i.openOnClick&&(t._documentClickHandler=t._documentClick.bind(t),e(document).on("click",t._documentClickHandler))},_detachMenuEventsHandlers:function(){var t=this,n=t._overflowWrapper();n&&n.off(v),t.element.off(v),t._documentClickHandler&&e(document).off("click",t._documentClickHandler)},_getNeededSpaceForChildren:function(e,t){const i=e.children();let r=0;return i.length>0&&i.each(((e,i)=>{r+=t?n._outerWidth(i):n._outerHeight(i)})),r},_initOverflow:function(t){var i,r,o=this,a="horizontal"==t.orientation;const s=n.support.isRtl(o.wrapper);if(o._openedPopups={},t.scrollable){o._scrollWrapper=o.element.wrap(`<div class="k-menu-scroll-wrapper${"vertical"===t.orientation?" k-menu-scroll-wrapper-vertical":""}"></div>`).parent(),a&&Te(o.element);let n=a?s?"right":"left":"up",d=a?s?"left":"right":"down";i=e(o.templates.scrollButton({direction:n})),r=e(o.templates.scrollButton({direction:d})),i.prependTo(o._scrollWrapper),r.appendTo(o._scrollWrapper),o._initScrolling(o.element,i,r,a,s);var l=o.element.outerWidth(),c=o.element[0].style.width;c="auto"===c?"":c,a&&e(window).on($,(function(){setTimeout((function(){o._setOverflowWrapperWidth(l,c),o._toggleScrollButtons(o.element,i,r,a)}),300)})),o._setOverflowWrapperWidth(l,c),o._toggleScrollButtons(o.element,i,r,a)}},_overflowWrapper:function(){return this._scrollWrapper||this._popupsWrapper},_setOverflowWrapperWidth:function(e,t){var n=this,i=n._scrollWrapper.css("width");n._scrollWrapper.css({width:""});var r=n._scrollWrapper.outerWidth();n._scrollWrapper.css({width:i});var o=n.element.outerWidth(),a=n.element[0].offsetWidth-n.element[0].clientWidth;if(o!=r&&r>0){var s=t?Math.min(e,r):r;n.element.width(s-a),n._scrollWrapper.width(s)}},_reinitOverflow:function(e){var t=this;(e.scrollable&&!t.options.scrollable||!e.scrollable&&t.options.scrollable||e.scrollable&&t.options.scrollable&&e.scrollable.distance!=t.options.scrollable.distance||e.orientation!=t.options.orientation)&&(t._detachMenuEventsHandlers(),t._destroyOverflow(),t._initOverflow(e),t._attachMenuEventsHandlers())},_destroyOverflow:function(){var n=this,i=n._overflowWrapper();i&&(i.off(v),i.find(re).off(v).remove(),i.children(X).each((function(t,n){var r=e(n).find(".k-child-animation-container > .k-menu-popup");r.off(N);var o=ke(r,i);o.length&&o.append(n)})),i.find(be()).removeAttr("data-groupparent"),i.find(ye()).removeAttr("data-group"),n.element.off(N),e(window).off($),i.contents().unwrap(),n._scrollWrapper=n._popupsWrapper=n._openedPopups=t)},_initScrolling:function(t,i,r,a,s){var l=this,c=l.options.scrollable,d=l.isNumeric(c.distance)?c.distance:50,u=d/2,h="-="+d,p="+="+d,f="-="+2*d,m="+="+2*d,g=!1,_=!1,b=function(e){var n=a?{scrollLeft:e}:{scrollTop:e};t.finish().animate(n,"fast","linear",(function(){g&&b(e)})),l._toggleScrollButtons(t,i,r,a,s)},y=function(e){g||_||(b(e.data.direction),g=!0)},w=function(n){var c=a?{scrollLeft:n.data.direction}:{scrollTop:n.data.direction};_=function(e){var t=e.originalEvent;return o&&/touch/i.test(t.type||"")}(n)||Se(n),t.stop().animate(c,"fast","linear",(function(){_?(l._toggleScrollButtons(t,i,r,a,s),g=!0):e(n.currentTarget).trigger(O)})),g=!1,n.stopPropagation(),n.preventDefault()};i.on(O+v,{direction:s&&a?p:h},y).on(n.eventMap.down+v,{direction:s&&a?m:f},w),r.on(O+v,{direction:s&&a?h:p},y).on(n.eventMap.down+v,{direction:s&&a?f:m},w),i.add(r).on(V+v,(function(){t.stop(),g=!1,l._toggleScrollButtons(t,i,r,a,s)})),t.on(N,(function(e){if(!e.ctrlKey&&!e.shiftKey&&!e.altKey){var n=function(e){var t=0;return e.wheelDelta&&(t=(t=-e.wheelDelta/120)>0?Math.ceil(t):Math.floor(t)),e.detail&&(t=Math.round(e.detail/3)),t}(e.originalEvent),o=(n>0?"+=":"-=")+Math.abs(n)*u,s=a?{scrollLeft:o}:{scrollTop:o};l._closeChildPopups(t),t.finish().animate(s,"fast","linear",(function(){l._toggleScrollButtons(t,i,r,a)})),e.preventDefault()}}))},isNumeric:function(e){return!isNaN(parseFloat(e))&&isFinite(e)},_toggleScrollButtons:function(e,t,i,r){const o=this._getNeededSpaceForChildren(e,r),a=r?n._outerWidth(this.element):n._outerHeight(this.element);t.toggle(o>a),i.toggle(o>a);const s=r?n.scrollLeft(e):e.scrollTop(),l=e.is(J)||e.parent().is(Z);let c=Math.abs(s-(e[0].scrollWidth-e[0].offsetWidth))<=1;r||(c=Math.abs(s-(e[0].scrollHeight-e[0].offsetHeight))<=1),l&&(c=Math.abs(s-(e[0].scrollHeight-e[0].offsetHeight)-1)<=1),t.toggleClass(Y,0===Math.floor(s)),i.toggleClass(Y,c)},setOptions:function(e){var t=this.options.animation;this._animations(e),e.animation=d(!0,t,e.animation),"dataSource"in e&&this._dataSource(e),this._updateClasses(),this._wrapGroups(),this._reinitOverflow(e),m.fn.setOptions.call(this,e)},destroy:function(){var e=this;m.fn.destroy.call(e),e._detachMenuEventsHandlers(),e._destroyOverflow(),n.destroy(e.element)},enable:function(e,t){return this._toggleDisabled(e,!1!==t),this},disable:function(e){return this._toggleDisabled(e,!1),this},attemptGetItem:function(t){t=t||this.element;var n=this.element.find(t),i=this._overflowWrapper();return n.length||t===this.element?n:i?i.find(t):e()},append:function(e,t){t=this.attemptGetItem(t);var n=this._insert(e,t,t.length?this._childPopupElement(t).children().eq(0):null);return u(n.items,(function(t){n.group.append(this),pe(this),_e(this,e[t]||e)})),pe(t),me(n.group.find(".k-first, .k-last").add(n.items)),ge(ve(n.group)),this},insertBefore:function(e,t){t=this.attemptGetItem(t);var n=this._insert(e,t,t.parent());return u(n.items,(function(n){t.before(this),pe(this),me(this),_e(this,e[n]||e)})),me(t),this},insertAfter:function(e,t){t=this.attemptGetItem(t);var n=this._insert(e,t,t.parent());return u(n.items,(function(n){t.after(this),pe(this),me(this),_e(this,e[n]||e)})),me(t),this},_insert:function(t,i,r){var o,s,l=this;i&&i.length||(r=l.element);var c=e.isPlainObject(t)||t instanceof n.data.ObservableObject,u={firstLevel:r.hasClass(b),horizontal:r.hasClass(b+"-horizontal"),expanded:!0,length:r.children().length};return i&&!r.length&&(r=e(l.renderGroup({group:u,options:l.options})).css("display","none").appendTo(i),n.applyStylesFromKendoAttributes(r,["display"])),c||a(t)||t instanceof n.data.ObservableArray?o=e(e.map(c?[t]:t,(function(t,i){if("string"==typeof t)return e(t).get();{let r=e(l.renderItem({group:u,item:d(t,{index:i})}));return n.applyStylesFromKendoAttributes(r,["display"]),r.get()}}))):(s=(o="string"==typeof t&&"<"!=t.charAt(0)?l.element.find(t):e(t)).find("> ul").addClass("k-menu-group k-menu-group-md").attr(le,"menu"),(o=o.filter("li")).add(s.find("> li")).each((function(){he(this)}))),{items:o,group:r=r.is(J)?r.find(".k-menu-group").first():r}},remove:function(e){var t=(e=this.attemptGetItem(e)).parentsUntil(this.element,ee),n=e.parent("ul:not(.k-menu)");if(e.remove(),n&&!n.children(ee).length){var i=ve(n),r=n.parent(X);r.length?r.remove():n.remove(),ge(i)}return t.length&&(pe(t=t.eq(0)),me(t)),this},_openAfterLoad:function(e,t){var n=this;t.loaded()?(n.open(e),n._loading=!1):t.one(R,(function(){e.find(k).children().removeClass("k-i-loading"),n._loading&&(n.open(e),n._loading=!1)}))},_createPopup:function(e,t){let i=this,r=i._overflowWrapper();return e.kendoPopup(d({activate:function(){i._triggerEvent({item:this.wrapper.parent(),type:E})},deactivate:function(e){i._closing=!1,e.sender.element.removeData("targetTransform").css({opacity:""}),i._triggerEvent({item:this.wrapper.parent(),type:I})},open:i._popupOpen.bind(i),close:function(e){i._closing=e.sender.element;var t=e.sender.wrapper.parent();if(r){var a=e.sender.element.data(U);a&&(t=(r||i.element).find(be(a))),e.sender.wrapper.children(re).hide()}i._triggerEvent({item:t[0],type:C})?e.preventDefault():(t.css(M,t.data(M)),t.removeData(M),i.options.scrollable&&t.parent().siblings(re).css({zIndex:""}),(o||F||n.support.mouseAndTouchPresent)&&(t.removeClass(G),i._removeHoverItem()))}},t)).data(q)},open:function(i){var r=this,o=r.options,a="horizontal"==o.orientation,s=o.direction,l=n.support.isRtl(r.wrapper),c=r._overflowWrapper();i=(c||r.element).find(i);var u=r.dataSource&&r.dataSource.getByUid(i.data(n.ns+"uid"));if(u&&u.hasChildren&&!u.loaded()&&!r._loading)return r._loading=!0,i.find(k).children().addClass("k-i-loading"),u.load(),void r._openAfterLoad(i,u);/^(top|bottom|default)$/.test(s)&&(s=l?a?(s+" left").replace("default","bottom"):"left":a?(s+" right").replace("default","bottom"):"right");var h=">.k-popup:visible,>.k-animation-container > .k-child-animation-container > .k-menu-popup:visible",p=function(){e(this).data(q)&&r.close(e(this).closest("li.k-item"),!0)};return i.siblings().find(h).each(p),c&&i.find(h).each(p),r.options.openOnClick&&(r.clicked=!0),i.each((function(){var i=e(this);clearTimeout(i.data(S)),clearTimeout(r._timerTimeout),r._timerTimeout=setTimeout((function(){var u,h,p=i.find("> .k-menu-popup, > .k-animation-container > .k-child-animation-container > .k-menu-popup").filter(":hidden").first();if(!p[0]&&c&&(p=(h=r._getPopup(i))&&h.element),!p.is(":visible")&&p[0]&&!1===r._triggerEvent({item:i[0],type:_})){const h=p.children(".k-menu-scroll-wrapper").length?p.children(".k-menu-scroll-wrapper"):p,_=r._groupElementsInitialSpace.find((({element:e})=>h.children("ul").is(e)));let x="";_&&Object.keys(_).length>0&&(_.height>0&&(x=_.height),r._popupToBeOpened=_,_.inlineHeight?e(_.element).css({height:_.inlineHeight}):e(_.element).css({height:""})),p.css({maxHeight:o.scrollable?"":x,overflow:"visible"}),i.data(M,i.css(M));var f=r.nextItemZIndex++;i.css(M,f),r.options.scrollable&&i.parent().siblings(re).css({zIndex:++f}),u=p.data(q);var m,g=i.parent().hasClass(b),v=g&&a,y=function(e,t,i){e=e.split(" ")[!t+0]||e;var r={origin:["bottom",i?"right":"left"],position:["top",i?"right":"left"]};return/left|right/.test(e)?(r.origin=["top",e],r.position[1]=n.directions[e].reverse):(r.origin[0]=e,r.position[0]=n.directions[e].reverse),r.origin=r.origin.join(" "),r.position=r.position.join(" "),r}(s,g,l),w=o.animation.open.effects,k=w!==t?w:"slideIn:"+function(e,t){return(e=e.split(" ")[!t+0]||e).replace("top","up").replace("bottom","down")}(s,g);m=null!==o.popupCollision?o.popupCollision:v?"fit":"fit flip",u?((u=p.data(q)).options.origin=y.origin,u.options.position=y.position,u.options.animation.open.effects=k):(u=r._createPopup(p,{origin:y.origin,position:y.position,collision:m,anchor:i,appendTo:c||i,animation:{open:d(!0,{effects:k},o.animation.open),close:o.animation.close}}),p.closest(X).removeAttr(le)),p.removeAttr("aria-hidden"),i.attr(se,!0),r._configurePopupOverflow(u,i),u._hovered=!0,u.open(),r._initPopupScrolling(u)}}),r.options.hoverDelay),i.data(S,r._timerTimeout)})),r},_configurePopupOverflow:function(e,t){if(this.options.scrollable&&(this._wrapPopupElement(e),!t.attr("data-groupparent"))){var n=(new Date).getTime();t.attr("data-groupparent",n),e.element.attr("data-group",n)}},_wrapPopupElement:function(e){e.element.parent().is(Z)||(e.wrapper=n.wrap(e.element,e.options.autosize).css({overflow:"hidden",display:"block",position:"absolute"}))},_initPopupScrolling:function(t,i,r){var o=this;const a=t.element,s=a.children(".k-menu-scroll-wrapper"),l=s.length?e(s.children("ul")):e(a.children("ul"));let c=o._getNeededSpaceForChildren(l,i),d=!1;d=i?n._outerWidth(a)<c:n._outerHeight(a)<c,o.options.scrollable&&(a[0].scrollHeight>a[0].offsetHeight||d)?o._initPopupScrollButtons(t,i,r):s.length&&(s.find(re).remove(),l.unwrap())},_scrollButtonsMouseEnter:function(){let t=this,n=t.popup,i=t._overflowWrapper();e(we(n.element,i)).each((function(e,n){let r=i.find(be(n.data(U)));t.close(r)}))},_scrollButtonsMouseLeave:function(){let t=this,n=t.popup;setTimeout((function(){e.isEmptyObject(t._openedPopups)&&t._closeParentPopups(n.element)}),30)},_initPopupScrollButtons:function(t,i,r){let o=this,a=t.wrapper.find(re),s=t.element,l=s.children(".k-menu-scroll-wrapper"),c=s.children("ul");o._denyOpening=!0,!c.length&&l.length&&(c=l.children("ul")),i||c.css({overflow:"hidden"});const d=l.length>0?l:c.wrap(`<div class="k-menu-scroll-wrapper${i?"":" k-menu-scroll-wrapper-vertical"}"></div>`).parent();if(a.length)a.is(":hidden")&&a.show();else{let n=e(o.templates.scrollButton({direction:i?"left":"up"})),s=e(o.templates.scrollButton({direction:i?"right":"down"}));a=n.add(s),a.css({width:!i&&"100%"}),n.prependTo(d),s.appendTo(d),o._initScrolling(c,n,s,i),r||a.on(O+v,(function(){let n=o._overflowWrapper();e(we(t.element,n)).each((function(e,t){let i=n.find(be(t.data(U)));o.close(i)}))})).on(V+v,(function(n){setTimeout((function(){e.isEmptyObject(o._openedPopups)&&!t.element.find(n.relatedTarget).length&&o._closeParentPopups(t.element)}),30)}))}if(a.length>0&&!i){const e=o._popupToBeOpened?o._popupToBeOpened.inlineHeight:"";c.css({height:""!==e?e:n._outerHeight(t.wrapper)-2*n._outerHeight(a)+"px"})}o._toggleScrollButtons(c,a.first(),a.last(),i),o._denyOpening=!1},_popupOpen:function(e){this._keyTriggered||e.sender.element.find("."+K).removeClass(K),this.options.scrollable&&this._setPopupHeight(e.sender)},_setPopupHeight:function(t,n){let i=t.element,r=i.add(i.parent(Z));r.height(i.hasClass(b)&&this._initialHeight||"");let o=t._location(n),a=e(window).height(),s=o.height,l=n?0:Math.max(o.top,0),c=n?0:Ce(this._overflowWrapper()[0],"scrollTop"),d=a+(window.innerHeight-a);if(!(d+c>s+l)){let e=.05*a,t=Math.min(d,d-l-e+c);r.css({height:t+"px"}),i.css({overflow:"hidden"})}},close:function(t,n){var i=this,r=i._overflowWrapper(),o=r||i.element;(t=o.find(t)).length||(t=o.find(">.k-item"));return t.each((function(){var o=e(this);o.attr(se,!1),!n&&i._isRootItem(o)&&(i.clicked=!1),clearTimeout(o.data(S)),o.data(S,setTimeout((function(){var n,a=i._getPopup(o);if(a&&(n=o.data(W),!r||!n||!i._openedPopups[n.toString()]||i._forceClose)){if(!i._forceClose&&function(t){var n=!1;return e.isEmptyObject(i._openedPopups)||e(we(t,r)).each((function(e,t){return!(n=!!i._openedPopups[t.data(U).toString()])})),n}(a.element))return;a.close(),a.element.attr("aria-hidden",!0),r&&i._forceClose&&t.last().is(o[0])&&delete i._forceClose}}),i.options.hoverDelay))})),i},_getPopup:function(e){var t=e.find(".k-menu-popup:not(.k-list-container):not(.k-calendar-container):visible").first().data(q),n=this._overflowWrapper();if(!t&&n){var i=e.data(W);if(i)t=n.find(ye(i)).data(q)}return t},_toggleDisabled:function(t,n){this.element.find(t).each((function(){e(this).toggleClass(Y,!n).attr("aria-disabled",!n)}))},_toggleHover:function(t){var i=e(n.eventTarget(t)||t.target).closest(ee),r=t.type==O||-1!==l.indexOf(t.type);i.siblings().removeClass(G),i.parents("li."+Y).length||i.toggleClass(G,r||"mousedown"==t.type||"pointerover"==t.type||t.type==B)},_preventClose:function(){this.options.closeOnClick||(this._closurePrevented=!0)},_checkActiveElement:function(t){var i=this,r=e(t?t.currentTarget:this._focusItem()),o=i._findRootParent(r)[0];this._closurePrevented||setTimeout((function(){document.hasFocus()&&(ue(o,n._activeElement())||!t||ue(o,t.currentTarget))||i.close(o)}),0),this._closurePrevented=!1},_removeFocusItem:function(){var e=this._focusItem();e&&e.hasClass(K)&&(e.removeClass(K),this._oldFocusItem=null)},_wrapGroups:function(){var t=this;const i=t.element.find("li > ul");t._groupElementsInitialSpace=Array.from(i).map((e=>({element:e,width:n._outerWidth(e),height:n._outerHeight(e),inlineHeight:e.style&&e.style.height?e.style.height:""}))),i.filter((function(){return!e(this).parent().hasClass("k-menu-popup")})).wrap("<div class='k-menu-popup k-popup'></div>").parent("div").attr("aria-hidden",t.element.is(":visible")).hide(),t.element.find("ul").each((function(){var t=e(this),i=n.guid();t.attr("id",i).closest("li").attr("aria-controls",i)}))},_updateClasses:function(){var e,t=this.element;t.removeClass("k-menu-horizontal k-menu-vertical"),t.addClass("k-reset k-header k-menu-init "+b).addClass(b+"-"+this.options.orientation),"vertical"===this.options.orientation?t.attr("aria-orientation","vertical"):t.attr("aria-orientation","horizontal"),t.find("li > ul").filter((function(){return!n.support.matchesSelector.call(this,".k-menu-init div ul")})).addClass("k-menu-group k-menu-group-md").attr(le,"menu").parent("li").attr("aria-haspopup","true").end().find("li > div").addClass("k-content").attr("tabindex","-1"),t.find("li[aria-haspopup]").attr(se,!1),e=t.find("> li,.k-menu-group > li"),t.removeClass("k-menu-init"),e.each((function(){he(this)}))},_mouseenter:function(t){var n=this,i=e(t.currentTarget),r=n._itemHasChildren(i),a=i.data(W)||i.closest(J).data(U),s=Se(t),l=!1;n._denyOpening||(a&&(n._openedPopups[a.toString()]=!0),n._closing&&(l=!!n._closing.find(i).length),l||(n._keyTriggered=!1,n.options.openOnClick.rootMenuItems&&n._isRootItem(i.closest(ee))||n.options.openOnClick.subMenuItems&&!n._isRootItem(i.closest(ee))||(!(!1===n.options.openOnClick||!1===n.options.openOnClick.rootMenuItems&&n._isRootItem(i.closest(ee))||!1===n.options.openOnClick.subMenuItems&&!n._isRootItem(i.closest(ee))||n.clicked)||o||s&&n._isRootItem(i.closest(ee))||!ue(t.currentTarget,t.relatedTarget)&&r&&n.open(i),(!0===n.options.openOnClick&&n.clicked||o)&&i.siblings().each((function(e,t){n.close(t,!0)})))))},_mousedown:function(t){var n=this,i=e(t.currentTarget);n._mousedownedElement=i,(n.options.openOnClick.subMenuItems&&!n._isRootItem(i)||o)&&i.siblings().each((function(e,t){n.close(t,!0)}))},_mouseleave:function(t){var i=this,r=e(t.currentTarget),a=r.data(W),s=r.children(J).length||a,l=e(window);if(a&&delete i._openedPopups[a.toString()],!r.parentsUntil(X,".k-list-container,.k-calendar-container")[0])return!1!==i.options.openOnClick&&(i.options.openOnClick.rootMenuItems||!i._isRootItem(r))&&(i.options.openOnClick.subMenuItems||i._isRootItem(r))||o||Se(t)||ue(t.currentTarget,t.relatedTarget||t.target)||!s||ue(t.currentTarget,n._activeElement())?void((n.support.browser.msie&&!t.toElement&&!t.relatedTarget&&!Se(t)||t.clientX<0||t.clientY<0||t.clientY>l.height()||t.clientX>l.width())&&i.close(r)):(i.close(r,!0),void(i._loading=!1));t.stopImmediatePropagation()},_mouseenterPopup:function(t){var n=e(t.currentTarget);if(!n.parent().is(Z)){var i=(n=n.find(J)).data(U);i&&(this._openedPopups[i.toString()]=!0)}},_mouseleavePopup:function(t){var n=e(t.currentTarget);!Se(t)&&n.is(X)&&this._closePopups(n.find(J))},_closePopups:function(t){var n=this,i=n._overflowWrapper(),r=t.data(U);if(r){delete n._openedPopups[r.toString()];var o=i.find(be(r));setTimeout((function(){if(n.options.openOnClick)n._closeChildPopups(t);else if(e.isEmptyObject(n._openedPopups)){var i=n._innerPopup(t);n._closeParentPopups(i)}else n.close(o,!0)}),0)}},_closeChildPopups:function(t){var n=this,i=n._overflowWrapper();e(we(t,i)).each((function(){var e=i.find(be(this.data(U)));n.close(e,!0)}))},_innerPopup:function(e){var t=we(e,this._overflowWrapper());return t[t.length-1]||e},_closeParentPopups:function(e){var t=this,n=t._overflowWrapper(),i=e.data(U);var r=(n??t.element).find(be(i));for(i=r.closest(J).data(U),t.close(r,!0);i&&!t._openedPopups[i]&&!r.parent().is(Q);)r=n.find(be(i)),t.close(r,!0),i=r.closest(J).data(U)},_click:function(t){var i,r,o,a,s=this,l=s.options,c=e(n.eventTarget(t)),d=c[0],u=c[0]?c[0].nodeName.toUpperCase():"",h="INPUT"==u||"SELECT"==u||"BUTTON"==u||"LABEL"==u,p=c.closest(w),f=c.closest(ee),m=f[0],g=p.attr("href"),v=c.attr("href"),b=e("<a href='#' />").attr("href"),y=!!g&&g!==b,k=y&&!!g.match(/^#/),x=!!v&&v!==b,S=s._overflowWrapper();if(!d||d.parentNode&&m){for(e(c).closest("span").parent().hasClass("k-menu-expand-arrow")&&(this._lastClickedElement=m);d&&d.parentNode!=m;)d=d.parentNode;if(!e(d).is("div:not(.k-animation-container,.k-list-container)"))if(f.hasClass(Y))t.preventDefault();else{if(t.handled||!s._triggerSelect(c,m)||h||t.preventDefault(),t.handled=!0,r=f.children(J),S){var T=f.data(W);T&&(r=S.find(ye(T)))}if(o=r.is(":visible"),a=l.openOnClick&&o&&s._isRootItem(f),l.closeOnClick&&(!y||k)&&(!r.length||a)){f.removeClass(G).css("height"),s._oldFocusItem=s._findRootParent(f);var D=s._parentsUntil(p,s.element,ee);return s._forceClose=!!S,s.close(D),void(s.clicked=!1)}y&&t.enterKey&&p[0].click(),(s._isRootItem(f)&&!1!==l.openOnClick||l.openOnClick.subMenuItems||n.support.touch||Se(t)&&s._isRootItem(f.closest(ee)))&&(y||h||x||t.preventDefault(),s.clicked=!0,i=r.is(":visible")?C:_,(l.closeOnClick||i!=C)&&s[i](f))}}},_parentsUntil:function(t,n,i){var r=this._overflowWrapper();if(r){var o=function(t,n){var i=[],r=function(e){for(;e.parentNode&&!n.is(e.parentNode);)i.push(e.parentNode),e=e.parentNode},o=t[0]||t;r(o);for(var a=i[i.length-1];e(a).is(X)&&(o=ke(e(a).find(J),n)[0]);)i.push(o),r(o),a=i[i.length-1];return i}(t,r),a=[];return e(o).each((function(){var t=e(this);if(t.is(n))return!1;t.is(i)&&a.push(this)})),e(a)}return t.parentsUntil(n,i)},_triggerSelect:function(e,t){var n,i=(e=e.is(".k-link")?e:e.closest(".k-link")).data("selectHandler");i&&(n=this._getEventData(e),i.call(this,n));var r=n&&n.isDefaultPrevented(),o=this._triggerEvent({item:t,type:A});return r||o},_getEventData:function(e){return{sender:this,target:e,_defaultPrevented:!1,preventDefault:function(){this._defaultPrevented=!0},isDefaultPrevented:function(){return this._defaultPrevented}}},_documentClick:function(n){var i=this,r=e(n.target).closest("span").parent().hasClass("k-menu-expand-arrow")?i._lastClickedElement:n.target;ue((i._overflowWrapper()||i.element)[0],r)?i._lastClickedElement=t:i.clicked=!1},_focus:function(t){var n=this,i=t.target,o=n._focusItem(),a=r();if(!n._mousedownedElement)return i==n.wrapper[0]||e(i).is(":kendoFocusable")?void(a===t.currentTarget&&(o.length?n._moveFocus([],o):n._oldFocusItem||n._moveFocus([],n.wrapper.children().first()))):(t.stopPropagation(),e(i).closest(".k-content").closest(".k-menu-popup").closest(".k-item").addClass(K),void n.wrapper.trigger("focus"));n._mousedownedElement=null},_keydown:function(e){var t,i,r,o=this,a=e.keyCode,s=o._oldFocusItem,l=n.support.isRtl(o.wrapper);if(e.target==e.currentTarget||a==f.ESC){if(s||(s=o._oldFocusItem=o._focusItem()),i=o._itemBelongsToVertival(s),r=o._itemHasChildren(s),o._keyTriggered=!0,a==f.RIGHT)t=o[l?"_itemLeft":"_itemRight"](s,i,r);else if(a==f.LEFT)t=o[l?"_itemRight":"_itemLeft"](s,i,r);else if(a==f.DOWN)t=o._itemDown(s,i,r);else if(a==f.UP)t=o._itemUp(s,i,r);else if(a==f.HOME)o._moveFocus(s,s.parent().children(":visible").first()),e.preventDefault();else if(a==f.END)o._moveFocus(s,s.parent().children(":visible").last()),e.preventDefault();else if(a==f.ESC)t=o._itemEsc(s,i);else if(a==f.ENTER||a==f.SPACEBAR)(t=s.children(".k-link")).length>0&&(o._click({target:t[0],preventDefault:function(){},enterKey:!0}),r&&!s.hasClass(Y)?(o.open(s),o._moveFocus(s,o._childPopupElement(s).children().find("li").first())):s.is("li")&&"menuitemcheckbox"===s.attr("role")?s.find(".k-checkbox").attr("checked",!0):o._moveFocusToRoot(s,o._findRootParent(s)));else if(a==f.TAB)return t=o._findRootParent(s),o._moveFocus(s,t),void o._checkActiveElement();t&&t[0]&&(e.preventDefault(),e.stopPropagation())}},_focusItem:function(){return this.wrapper.find(".k-item.k-focus").filter(":visible")},_itemBelongsToVertival:function(e){var t=this.wrapper.hasClass("k-menu-vertical");return e.length&&e.parent().hasClass("k-menu-group")||t},_itemHasChildren:function(e){return!!(e&&e.length&&e[0].nodeType)&&(e.children(".k-menu-group, .k-menu-popup, div.k-animation-container").length>0||!!e.data(W)&&!!this._overflowWrapper().children(ye(e.data(W))))},_moveFocus:function(t,n){var i=this,r=i._ariaId;t.length&&n.length&&t.removeClass(K),n.length&&(n[0].id&&(r=n[0].id),i.wrapper.find("."+K).removeClass(K),n.addClass(K),i._oldFocusItem=n,r&&(i.element.removeAttr("aria-activedescendant"),e("#"+r).removeAttr("id"),n.attr("id",r),i.element.attr("aria-activedescendant",r)),i._scrollToItem(n))},_moveFocusToRoot:function(e,t){this._moveFocus(e,t)},_findRootParent:function(e){return this._isRootItem(e)?e:this._parentsUntil(e,Q,"li.k-item").last()},_isRootItem:function(e){return e.parent().hasClass(b)},_itemRight:function(e,t,n){var i,r,o,a=this;if(t){if(n&&!e.hasClass(Y))a.open(e),i=a._childPopupElement(e).children().find("li").first();else if("horizontal"==a.options.orientation){if(r=a._findRootParent(e),o=a._overflowWrapper()){var s=xe(r,o);a._closeChildPopups(s)}a.close(r),i=r.nextAll(te+ie).eq(0)}}else(i=e.nextAll(te+ie).eq(0)).length||(i=e.prevAll(te+ie).last()),a.close(e);return i&&!i.length?i=a.wrapper.children(".k-item").first():i||(i=[]),a._moveFocus(e,i),i},_itemLeft:function(e,t){var n,i,r=this;return t?(n=e.parent().closest(".k-item"),i=r._overflowWrapper(),!n.length&&i&&(n=ke(e.parent(),i)),r.close(n),r._isRootItem(n)&&"horizontal"==r.options.orientation&&(n=n.prevAll(te+ie).eq(0))):((n=e.prevAll(te+ie).eq(0)).length||(n=e.nextAll(te+ie).last()),r.close(e)),n.length||(n=r.wrapper.children(".k-item").last()),r._moveFocus(e,n),n},_itemDown:function(e,t,n){var i,r=this;if(t)i=e.nextAll(te+ie).eq(0);else{if(!n||e.hasClass(Y))return;r.open(e),i=r._childPopupElement(e).children().find("li").first()}return!i.length&&e.length?i=e.parent().children(":visible").first():e.length||(i=r.wrapper.children(".k-item").first()),r._moveFocus(e,i),i},_itemUp:function(e,t){var n;if(t)return!(n=e.prevAll(te+ie).eq(0)).length&&e.length?n=e.parent().children(":visible").last():e.length||(n=this.wrapper.children(".k-item").last()),this._moveFocus(e,n),n},_scrollToItem:function(e){var t=this;if(t.options.scrollable&&e&&e.length){var i,r=e.parent(),o=!!r.hasClass(b)&&"horizontal"==t.options.orientation,a=o?"scrollLeft":"scrollTop",s=o?n._outerWidth:n._outerHeight,l=r[a](),c=s(e),d=e[0][o?"offsetLeft":"offsetTop"],u=s(r),h=r.siblings(re),p=h.length?s(h.first()):0;if(l+u<d+c+p?i=d+c-u+p:l>d-p&&(i=d-p),!isNaN(i)){var f={};f[a]=i,r.finish().animate(f,"fast","linear",(function(){t._toggleScrollButtons(r,h.first(),h.last(),o)}))}}},_itemEsc:function(e,t){var n,i,r=this;return t?(0===(n=e.parent().closest(".k-item")).length&&(i=e.closest(".k-menu-popup").data("group"),n=r.wrapper.find(".k-item[data-groupparent='"+i+"']")),r.close(n),r._moveFocus(e,n),n):e},_childPopupElement:function(e){var t=e.find(".k-menu-popup"),n=this._overflowWrapper();return!t.length&&n&&(t=xe(e,n)),t},_triggerEvent:function(e){return this.trigger(e.type,{type:e.type,item:e.item})},_focusHandler:function(t){var i=this,r=e(n.eventTarget(t)).closest(ee);r.hasClass(Y)||setTimeout((function(){i._moveFocus([],r),r.children(".k-content")[0]&&r.parent().closest(".k-item").removeClass(K)}),200)},_animations:function(e){e&&"animation"in e&&!e.animation&&(e.animation={open:{effects:{}},close:{hide:!0,effects:{}}})},_dataSource:function(e){var t=this,n=e?e.dataSource:t.options.dataSource;n&&(n=a(n)?{data:n}:n,t._unbindDataSource(),n.fields||(n.fields=[{field:"uid"},{field:"text"},{field:"url"},{field:"cssClass"},{field:"spriteCssClass"},{field:"imageUrl"},{field:"imageAttr"},{field:"attr"},{field:"contentAttr"},{field:"content"},{field:"encoded"},{field:"items"},{field:"select"}]),t.dataSource=s.create(n),t._bindDataSource(),t.dataSource.fetch())},_bindDataSource:function(){this._refreshHandler=this.refresh.bind(this),this._errorHandler=this._error.bind(this),this.dataSource.bind(R,this._refreshHandler),this.dataSource.bind(L,this._errorHandler)},_unbindDataSource:function(){var e=this.dataSource;e&&(e.unbind(R,this._refreshHandler),e.unbind(L,this._errorHandler))},_error:function(){},findByUid:function(e){return(this._overflowWrapper()||this.element).find("["+n.attr("uid")+"="+e+"]")},refresh:function(e){var t=this,n=e.node,i=e.action,r=n?t.findByUid(n.uid):t.element,o=e.items,a=e.index,s=t._updateItem.bind(t),l=t._removeItem.bind(t);"add"==i?t._appendItems(o,a,r):"remove"==i?o.forEach(l):"itemchange"==i?o.forEach(s):"itemloaded"===i?t.append(e.items,r):this._initData(),this.trigger(ae,{item:r,dataItem:n})},_appendItems:function(e,t,n){var i=n.find(te).eq(t);i.length?this.insertBefore(e,i):this.append(e,n)},_removeItem:function(e){var t=this.findByUid(e.uid);this.remove(t)},_updateItem:function(e){var t=this,n=t.findByUid(e.uid),i=n.next(),r=e.parentNode();t.remove(n),i.length?t.insertBefore(e,i):t.append(e,r&&t.findByUid(r.uid))},_accessors:function(){var e,t,i,r=this.options,o=this.element;for(e in ce)t=r[ce[e]],i=o.attr(n.attr(e+"-field")),!t&&i&&(t=i),t||(t=e),a(t)||(t=[t]),r[ce[e]]=t},_fieldAccessor:function(t){var i=this.options[ce[t]]||[],r=i.length;return 0===r?function(e){return e[t]}:function(t){var o=e.map(i,n.getter);return t.level?o[Math.min(t.level(),r-1)](t):o[r-1](t)}},_templates:function(){var t=this,i=t.options,r=t._fieldAccessor.bind(t);i.template&&"string"==typeof i.template?i.template=p(i.template):i.template||(i.template=p((e=>{var t=r("text")(e.item);return void 0!==e.item.encoded&&!1===e.item.encoded||(t=h(t)),`<span class='k-menu-link-text' role='none'>${t}</span>`}))),t.templates={content:p((e=>{var t=e.item,n=r("content")(t),i=e.contentCssAttributes(t.toJSON?t.toJSON():t);return`<div class='${e.groupWrapperCssClass(e.group)}' ${e.groupAttributes(e.group)}><div ${i} tabindex='-1'>${n||""}</div></div>`})),group:p((e=>`<div class='${e.groupWrapperCssClass(e.group)}' ${e.groupAttributes(e.group)}><ul class='${e.groupCssClass(e.group)}' id='${e.groupId}' role='menu'>${e.renderItems(e)}</ul></div>`)),itemWrapper:p((e=>{var t=e.item,n=r("url")(t),i=r("imageUrl")(t),o=r("imageAttr")(t),a=n?"a":"span";return`<${a} class='${de.textClass(t)}' role='none' ${n?`href='${n}'`:""} >`+(i?`<img ${de.imageCssAttributes(o)}  alt='' src='${i}' />`:"")+this.templates.sprite(t)+this.options.template(e)+e.arrow(e)+`</${a}>`})),item:p((t=>{var i=t.item,o=t.menu,a=t.group,s=t.subGroup,l=r("content")(i),c=n.guid();return`<li class='${de.wrapperCssClass(a,i)}' ${i.hasChildren||i.items||i.content?'aria-controls="'+c+'"':""} ${de.itemCssAttributes(i.toJSON?i.toJSON():i)} role='menuitem'  ${i.items||i.content?"aria-haspopup='true'":""}`+(!1===i.enabled?"aria-disabled='true'":"")+n.attr("uid")+`='${i.uid}' `+(i.items&&i.items.length>0||i.content?i.expanded?" aria-expanded='true'":" aria-expanded='false'":"")+">"+`${i.separator?"":this.templates.itemWrapper(t)}`+(i.hasChildren||i.items?`${s({items:i.items,menu:o,group:{expanded:i.expanded},groupId:c})}`:i.content||i.contentUrl||l?`${t.renderContent(e.extend({},t,{group:{expanded:i.expanded}}))}`:"")+"</li>"})),scrollButton:p((({direction:e})=>`<span class='k-button k-button-md k-button-flat k-button-flat-base k-icon-button k-menu-scroll-button k-menu-scroll-button-${"left"===e||"up"===e?"prev":"next"}' unselectable='on'>`+n.ui.icon({icon:`caret-alt-${e}`,iconClass:"k-button-icon"})+"</span>")),arrow:p((({item:e,group:t})=>`<span aria-hidden='true' class='k-menu-expand-arrow'>${n.ui.icon({icon:t.horizontal?"caret-alt-down":"caret-alt-right"})}</span>`)),sprite:p((e=>{var t=r("spriteCssClass")(e);return t?`<span class='k-sprite ${t}'></span>`:""})),empty:p((()=>""))}},renderItem:function(e){var t=this;e=d({menu:t,group:{}},e);var n=t.templates.empty,i=e.item;return t.templates.item(d(e,{separator:i.separator?t.templates.separator:n,sprite:t.templates.sprite,itemWrapper:t.templates.itemWrapper,renderContent:t.renderContent,arrow:i.items||i.content||i[t.options.dataContentField[0]]?t.templates.arrow:n,subGroup:t.renderGroup.bind(t)},de))},renderGroup:function(e){return(this.templates||e.menu.templates).group(d({renderItems:function(e){for(var t="",n=0,i=e.items,r=i?i.length:0,o=d({length:r},e.group);n<r;n++)t+=e.menu.renderItem(d(e,{group:o,item:d({index:n},i[n])}));return t}},e,de))},renderContent:function(e){return e.menu.templates.content(d(e,de))}}),Ae=De.extend({init:function(t,i){var r=this;De.fn.init.call(r,t,i),r.element.attr(le,"menu"),r._initialInlineHeight=r.element[0].style&&r.element[0].style.height?r.element[0].style.height:"",r._marker=n.guid().substring(0,8),r.target=e(r.options.target),r._popup(),r._wire()},_initOverflow:function(t){var n=this;n._openedPopups={},t.scrollable&&!n._overflowWrapper()&&(n._popupsWrapper=(n.element.parent().is(Z)?n.element.closes(X):n.element).wrap(`<div class="k-menu-scroll-wrapper${"vertical"===t.orientation?" k-menu-scroll-wrapper-vertical":""}"></div>`).parent(),"horizontal"==n.options.orientation&&Te(n.element),t.appendTo&&(t.appendTo=e(t.appendTo),t.appendTo.append(n._popupsWrapper)),n._initialHeight=n.element[0].style.height,n._initialWidth=n.element[0].style.width)},options:{name:"ContextMenu",filter:null,showOn:"contextmenu",orientation:"vertical",alignToAnchor:!1,copyAnchorStyles:!0,target:"body",origin:t,position:t},events:[_,C,E,I,A],setOptions:function(t){var n=this;De.fn.setOptions.call(n,t),n.target.off(n.showOn+v+n._marker,n._showProxy),n.userEvents&&n.userEvents.destroy(),n.target=e(n.options.target),t.orientation&&n.popup.wrapper[0]&&n.popup.element.unwrap(),n._wire(),De.fn.setOptions.call(this,t)},destroy:function(){var e=this;e.target.off(e.options.showOn+v+e._marker),j.off(n.support.mousedown+v+e._marker,e._closeProxy),e.userEvents&&e.userEvents.destroy(),De.fn.destroy.call(e),e.popup&&e.popup.destroy()},open:function(i,r){var o=this;const a="horizontal"===o.options.orientation;if("number"==typeof(i=e(i)[0])&&(o._initialInlineHeight?e(o.element).css({height:o._initialInlineHeight}):e(o.element).css({height:""})),ue(o.element[0],e(i)[0])||o._itemHasChildren(e(i)))De.fn.open.call(o,i);else if(!1===o._triggerEvent({item:o.element,type:_})){if(o.popup.visible()&&o.options.filter&&(o.popup.close(!0),o.popup.element.parent().kendoStop(!0)),o._triggerFocusOnActivate||(o._triggerFocusOnActivate=o._focusMenu.bind(o)),o.bind(E,o._triggerFocusOnActivate),r!==t){var s=o._overflowWrapper();if(s){var l=s.offset();i-=l.left,r-=l.top}o.popup.wrapper.hide(),o._configurePopupScrolling(i,r),o.popup.open(i,r)}else o.popup.options.anchor=i||o.popup.anchor||o.target,o.popup.element.kendoStop(!0),o._configurePopupScrolling(),o.popup.open();o._initPopupScrolling(o.popup,a),o.popup.element.siblings(re).hide(),j.off(o.popup.downEvent,o.popup._mousedownProxy),j.on(n.support.mousedown+v+o._marker,o._closeProxy)}return o},_focusMenu:function(){var e=this;e.unbind(E,e._triggerFocusOnActivate),e.element.trigger("focus")},_configurePopupScrolling:function(e,n){var i=this,r=i.popup,o="horizontal"==i.options.orientation;i.options.scrollable&&(i._wrapPopupElement(r),r.element.parent().css({position:"",height:""}),r.element.css({visibility:"hidden",display:"",position:""}),o?i._setPopupWidth(r,isNaN(e)?t:{isFixed:!0,x:e,y:n}):i._setPopupHeight(r,isNaN(e)?t:{isFixed:!0,x:e,y:n}),r.element.css({visibility:"",display:"none",position:"absolute"}))},_setPopupWidth:function(t,i){var r=t.element,o=r.add(r.parent(Z));o.width(this._initialWidth||"");var a=t._location(i),s=e(window).width(),l=a.width,c=Math.max(a.left,0),d=i?0:Ce(this._overflowWrapper()[0],"scrollLeft"),u=n.getShadows(r),h=s-u.left-u.right;h+d>l+c||o.css({overflow:"hidden",width:h-c+d+"px"})},close:function(){var t=this;ue(t.element[0],e(arguments[0])[0])||t._itemHasChildren(arguments[0])?De.fn.close.call(t,arguments[0]):t.popup.visible()&&!1===t._triggerEvent({item:t.element,type:C})&&(t._removeFocusItem(),t.element.find("#"+t._ariaId).removeAttr("id"),t.popup.close(),j.off(n.support.mousedown+v+t._marker,t._closeProxy),t.unbind(A,t._closeTimeoutProxy),t.popup.options.anchor.focus())},_showHandler:function(t){var i,r=t,o=this,a=o.options,s=n.support.mobileOS?e(r.target):e(r.currentTarget);t.event&&((r=t.event).pageX=t.x.location,r.pageY=t.y.location),ue(o.element[0],t.relatedTarget||t.target)||(o._eventOrigin=r,r.preventDefault(),r.stopImmediatePropagation(),o.element.find("."+K).removeClass(K),(a.filter&&s.is(a.filter)||!a.filter)&&(a.alignToAnchor?(o.popup.options.anchor=r.currentTarget,o.open(r.currentTarget)):(o.popup.options.anchor=r.currentTarget,o._targetChild?(i=o.target.offset(),o.open(r.pageX-i.left,r.pageY-i.top)):o.open(r.pageX,r.pageY))))},_closeHandler:function(t){var n=this,i=e(t.relatedTarget||t.target),r=i.closest(n.target.selector)[0]==n.target[0],o=i.closest(te),a=n._itemHasChildren(o),s=n._overflowWrapper(),l=ue(n.element[0],i[0])||s&&ue(s[0],i[0]);n._eventOrigin=t;var c=3!==t.which;n.popup.visible()&&(c&&r||!r)&&(n.options.closeOnClick&&!a&&l||!l)&&(l?(this.unbind(A,this._closeTimeoutProxy),n.bind(A,n._closeTimeoutProxy)):n.close())},_wire:function(){var e=this,t=e.options,i=e.target;e._preventProxy=null,e._showProxy=e._showHandler.bind(e),e._closeProxy=e._closeHandler.bind(e),e._closeTimeoutProxy=e.close.bind(e),i[0]&&(n.support.mobileOS&&"contextmenu"==t.showOn&&(e.userEvents=new n.UserEvents(i,{filter:t.filter,allowSelection:!1}),e._preventProxy=function(){return!1},e.userEvents.bind("hold",e._showProxy)),t.filter?i.on(t.showOn+v+e._marker,t.filter,e._preventProxy||e._showProxy):i.on(t.showOn+v+e._marker,e._preventProxy||e._showProxy),i.on("keydown",(t=>{t.keyCode===n.keys.F10&&t.shiftKey&&(t.preventDefault(),e.open(t.target))})))},_triggerEvent:function(n){var i=this,r=e(i.popup.options.anchor)[0],o=i._eventOrigin;return i._eventOrigin=t,i.trigger(n.type,d({type:n.type,item:n.item||this.element[0],target:r},o?{event:o}:{}))},_popup:function(){var t=this,n=t._overflowWrapper(),i=t.element.addClass("k-context-menu");t._triggerProxy=t._triggerEvent.bind(t),t.popup=e("<div></div>").append(i).kendoPopup({origin:t.options.origin,position:t.options.position,autosize:"horizontal"===t.options.orientation,anchor:t.target||"body",copyAnchorStyles:t.options.copyAnchorStyles,collision:t.options.popupCollision||"fit",animation:t.options.animation,activate:t._triggerProxy,deactivate:t._triggerProxy,appendTo:n||t.options.appendTo,close:n?function(t){e(we(t.sender.element,n)).each((function(e,t){var n=t.data(q);n&&n.close(!0)}))}:e.noop}).data(q),t._targetChild=ue(t.target[0],t.popup.element[0])},_moveFocusToRoot:function(e,t){this._moveFocus(e,t),this.close()},_focus:function(e){var t=this._oldFocusItem=this._focusItem()||[];De.fn._focus.call(this,e),r()===e.currentTarget&&this._moveFocus(t,this.wrapper.children().filter(":visible").not(".k-separator").first())}});i.plugin(De),i.plugin(Ae)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=t.ui,r=t.keys,o=e.extend,a=t.htmlEncode,s=".kendoExpansionPanel",l="expand",c="collapse",d="complete",u="k-disabled",h="aria-disabled",p="aria-expanded",f="aria-hidden",m="k-expanded",g="k-d-none",v=".k-expander-indicator",_="k-focus",b=({title:e,subTitle:n,iconClass:i,useBareTemplate:r,ns:o,elementId:s})=>`<div ${r?"":'class="k-expander-header"'} data-${o}expander-header role="button" tabindex="0" aria-controls="${a(s)}">`+(r?e:`<div class="k-expander-title">${a(e)}</div>`)+'<span class="k-spacer"></span>'+(r?"":`<div class="k-expander-sub-title">${a(n)}</div>`)+'<span class="k-expander-indicator">'+(i&&i.includes("k-icon")?`<span class="${a(i)}"></span>`:t.ui.icon({icon:i}))+"</span></div>",y=n.extend({init:function(i,r){var o=this,a=t.attr("expander-header");n.fn.init.call(o,i,r),r=e.extend(!0,{},r),o._getCollapseIconSelector(),o._wrapper(),o._animations(r),o.element.attr(f,!r.expanded),o.options.useBareTemplate||o.element.addClass("k-expander-content"),o.wrapper.on("click"+s,"["+a+"]",o._click.bind(o)).on("focusin"+s,o._focus.bind(o)).on("focusout"+s,o._blur.bind(o)).on("keydown"+s,o._keydown.bind(o)),o.toggle(o.options.expanded,!1),t.notify(o)},events:[l,c,d],options:{name:"ExpansionPanel",disabled:!1,expanded:!1,animation:{expand:{effects:"expand:vertical",duration:200},collapse:{duration:200}},height:null,toggleable:!0,hideExpanderIndicator:!1,expandIconClass:"chevron-down",collapseIconClass:"chevron-up",title:"",subTitle:"",headerClass:null,wrapperClass:null,useBareTemplate:!1},_wrapper:function(){var n,i,r=this,o=r.element,a=o[0],s=o.attr("id");s||(s=t.guid(),o.attr("id",s)),n=o.wrap("<div class='k-expander"+(r.options.expanded?" "+m:"")+"'></div>").parent(),i=t.template(b)({title:r.options.title,subTitle:r.options.subTitle,iconClass:r.options.expanded?r.options.expandIconClass:r.options.collapseIconClass,useBareTemplate:r.options.useBareTemplate,ns:t.ns,elementId:s+"_wrapper"}),r.header=e(i),n.prepend(r.header),r._indicator=n.find(v+" span"),r.options.hideExpanderIndicator&&n.find(v).hide(),n[0].style.cssText=a.style.cssText,a.style.width="100%",r.wrapper=n.addClass(r.options.disabled?u:""),r.contentWrapper=r.element.wrap('<div id="'+s+'_wrapper"></div>').parent().addClass("k-expander-content-wrapper").toggleClass(g,!r.options.expanded),r.header.attr(h,r.options.disabled).attr(p,r.options.expanded),r.options.useBareTemplate||n.addClass(a.className),r.options.height&&r.wrapper.css("height",r.options.height),r.options.headerClass&&r.header.addClass(r.options.headerClass),r.options.wrapperClass&&r.header.addClass(r.options.wrapperClass)},_animations:function(e){e&&"animation"in e&&!e.animation&&(e.animation={expand:{effects:{}},collapse:{hide:!0,effects:{}}})},_getCollapseIconSelector:function(){let e=this.options.collapseIconClass;e=e.replace("k-i-",""),this.collapseIconSelector=`[class*='-i-${e}']`},_click:function(e){var t=this,n=t._indicator.is(t.collapseIconSelector),i=t.element;e.stopPropagation(),t.options.toggleable?t.trigger(n?c:l,{item:i[0]})||t.toggle():e.preventDefault()},toggle:function(e,n){var i=this,r=i.options.animation,a=r.expand,s=r.collapse&&"effects"in r.collapse,l=o({},r.expand,r.collapse),c=i.element,d=i.wrapper;undefined!==e?!1===n&&(l=null):e=!i._indicator.is(i.collapseIconSelector),s||(l=o(l,{reverse:!0})),e?a=o({complete:i._completeHandler.bind(i)},a):(a=o(l,{hide:!0})).complete=i._completeHandler.bind(i),e?(i.options.collapseIconClass.includes("k-icon")?(i._indicator.removeClass(this.options.expandIconClass),i._indicator.addClass(this.options.collapseIconClass)):t.ui.icon(i._indicator,{icon:this.options.collapseIconClass}),d.addClass(m)):(i.options.expandIconClass.includes("k-icon")?(i._indicator.removeClass(this.options.collapseIconClass),i._indicator.addClass(this.options.expandIconClass)):t.ui.icon(i._indicator,{icon:this.options.expandIconClass}),d.removeClass(m)),i.contentWrapper.toggleClass(g,!e),c.attr(f,!e),i.header.attr(p,e),i.contentWrapper.kendoStop(!0,!0).kendoAnimate(a)},setOptions:function(e){let n=this;n.destroy(),n.header&&n.header.remove(),n.contentWrapper&&(n.element.removeAttr("class"),n.element.unwrap()),t.deepExtend(n.options,e),this.init(n.element,n.options)},_completeHandler:function(){this.trigger(d)},_keydown:function(t){var n=t.keyCode;n!=r.ENTER&&n!=r.SPACEBAR||!e(t.target).is("[data-expander-header]")||(this._click(t),t.preventDefault())},destroy:function(){this.wrapper.off(s),n.fn.destroy.call(this)},enable:function(e){this.wrapper.toggleClass(u,!e),this.header.attr(h,!e)},_blur:function(){this.header&&this.wrapper.removeClass(_)},_focus:function(){this.wrapper&&this.wrapper.addClass(_)}});i.plugin(y)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.htmlEncode,r=n.ui,o=e.extend,a=e.grep,s=(i=n.htmlEncode,e.map),l=e.inArray,c=n.data.Comparer,d="k-selected",u="asc",h="desc",p="change",f="init",m="open",g="select",v="stick",_="unstick",b="kendoPopup",y="kendoTabStrip",w="kendoMenu",k="kendoExpansionPanel",x=".kendoColumnMenu",C=r.Widget;function S(e){return n.trim(e).replace(/&nbsp;/gi,"")}function T(e){return this.columns.indexOf(e.title)>=0||this.columns.indexOf(e.field)>=0}function D(e){for(var t=[],n=0;n<e.length;n++)e[n].columns?t=t.concat(D(e[n].columns)):t.push(e[n]);return t}var A=C.extend({init:function(t,i){var r,o=this;(i=i||{}).componentType=i.componentType||"classic",C.fn.init.call(o,t,i),t=o.element,i=o.options,o.owner=i.owner,o.dataSource=i.dataSource,o.field=t.attr(n.attr("field")),o.title=t.attr(n.attr("title")),(r=e(t.closest(".k-table-th"))).length?o.appendTo=r.find(i.appendTo):o.appendTo=e(i.appendTo),o.link=o._createLink(),o.wrapper=e("<div />"),o._applyCssClasses(),o._refreshHandler=o.refresh.bind(o),o.dataSource.bind(p,o._refreshHandler)},_init:function(){var e=this;e.pane=e.options.pane,e.pane&&(e._isMobile=!0),e._isMobile?e._createMobileMenu():e._createMenu(),e._sort(),e._columns(),e._filter(),e._lockColumns(),e._reorderColumns(),e._stickyColumns(),e._sizeColumns(),e._clearAllFilters(),e._groupColumn(),e.trigger(f,{field:e.field,container:e.wrapper})},events:[f,m,"sort","filtering",v,_],options:{name:"ColumnMenu",messages:{sortAscending:"Sort Ascending",sortDescending:"Sort Descending",filter:"Filter",clearAllFilters:"Clear All Filters",column:"Column",columns:"Columns",columnVisibility:"Column Visibility",clear:"Clear",cancel:"Cancel",done:"Done",settings:"Edit Column Settings",lock:"Lock Column",unlock:"Unlock Column",stick:"Stick Column",unstick:"Unstick Column",setColumnPosition:"Set Column Position",apply:"Apply",reset:"Reset",buttonTitle:"{0} edit column settings",movePrev:"Move previous",moveNext:"Move next",groupColumn:"Group column",ungroupColumn:"Ungroup column",autoSizeColumn:"Autosize This Column",autoSizeAllColumns:"Autosize All Columns"},filter:"",columns:!0,sortable:!0,filterable:!0,clearAllFilters:!1,autoSize:!1,hideAutoSizeColumn:!1,animations:{left:"slide"},encodeTitles:!1,componentType:"classic",appendTo:null},_applyCssClasses:function(){var e=this.options.componentType,t=this.wrapper;"tabbed"===e&&t.addClass("k-column-menu-tabbed"),t.addClass("k-column-menu k-column-menu-popup")},_createMenu:function(){var t,i,r,o=this,a=o.options,s=o._ownerColumns();const l=o.owner&&o.owner.options&&("Grid"===o.owner.options.name||"TreeList"===o.owner.options.name);o._hasGroups()&&(s=o._groupColumns(s),(t=o._flattenMenuCols(s)).length!==o.owner.columns.length&&o._syncMenuCols(t,o.owner.columns)),i=o._isModernComponentType()?n.template(F):o._isTabbedComponentType()?n.template(R):n.template(O),r=e(i({uid:n.guid(),ns:n.ns,messages:a.messages,sortable:a.sortable,filterable:a.filterable,columns:s,showColumns:a.columns,hasLockableColumns:a.hasLockableColumns,hasStickableColumns:a.hasStickableColumns,encodeTitles:a.encodeTitles,omitWrapAttribute:n.attr("omit-wrap"),reorderable:a.reorderable,groupable:a.groupable,autoSize:a.autoSize,hideAutoSizeColumn:a.hideAutoSizeColumn,clearAllFilters:a.clearAllFilters})),n.applyStylesFromKendoAttributes(r,["display"]),o.wrapper.empty().append(r),o.popup=o.wrapper[b]({anchor:o.link,copyAnchorStyles:!1,open:o._open.bind(o),activate:o._activate.bind(o),deactivate:o._deactivate.bind(o),close:function(e){if(o._preventMenuCloseOnColumnVisibilityChange)return e.preventDefault(),void(o._preventMenuCloseOnColumnVisibilityChange=!1);o.menu&&(o.menu._closing=e.sender.element),o.options.closeCallback&&o.options.closeCallback(o.element)}}).data(b),(o._isModernComponentType()||o._isTabbedComponentType()||l)&&(o.popup.element.addClass("k-grid-columnmenu-popup"),o.popup.element.removeClass("k-column-menu-popup")),o._isModernComponentType()||o._isTabbedComponentType()?o._createExpanders():o.menu=o.wrapper.children()[w]({orientation:"vertical",closeOnClick:!1,open:function(){o._updateMenuItems()}}).data(w),o._isTabbedComponentType()&&(o.tabStrip=r[y]({applyMinHeight:!1,animation:{open:{effects:"fadeIn"}}}).data(y),o.tabStrip.activateTab(o.tabStrip.tabGroup.find("li:first")))},_createLink:function(){var e=this,t=e.element,r=e.appendTo.length?t.find(e.appendTo):t,o=t.is(".k-grid-column-menu")?t:t.find(".k-grid-column-menu"),a=i(n.format(e.options.messages.buttonTitle,e.title||e.field));return o[0]||(t.addClass("k-filterable"),o=r.append('<a class="k-grid-column-menu k-grid-header-menu" href="#" aria-hidden="true" title="'+a+'">'+n.ui.icon("more-vertical")+"</a>").find(".k-grid-column-menu")),o.attr("tabindex",-1).on("click"+x,e._click.bind(e)),o},_createExpanders:function(){var t=this,r=t.options,o=t.options.columnsExpanderOptions||{},a={expanded:!1,headerClass:"k-columnmenu-item",useBareTemplate:!0};t._isModernComponentType()&&(t.wrapper.find(".k-columns-item")[k](e.extend(!0,{},a,o,{title:n.ui.icon("columns")+"<span>"+i(r.messages.columnVisibility)+"</span>"})),t.wrapper.find(".k-column-menu-filter")[k](e.extend(!0,{},a,{title:n.ui.icon("filter")+"<span>"+i(r.messages.filter)+"</span>"}))),t.wrapper.find(".k-column-menu-position")[k](e.extend(!0,{},a,{title:n.ui.icon("set-column-position")+"<span>"+i(r.messages.setColumnPosition)+"</span>"}))},_syncMenuCols:function(e,t){for(var n,i=t.length,r=e.map((function(e){return e.field})),o=0;o<i;o++)n=t[o],r.indexOf(n.field)<0&&(n.menu=!1)},_flattenMenuCols:function(e){for(var t=[],n=e.length,i=0;i<n;i++)e[i].columns?t=t.concat(this._flattenMenuCols(e[i].columns)):e[i].groupHeader||t.push(e[i]);return t},_groupColumns:function(e,t){var n,i,r,o,a,s=[],l=this.options.columns.groups,c=l.length;for(n=0;n<c;n++)i=l[n],r=T.bind(i),o={title:i.title,groupHeader:!0},a=e.filter(r),s.push(o),t?o.columns=a:s=s.concat(a);return s},_hasGroups:function(){return this.options.columns&&this.options.columns.groups&&this.options.columns.groups.length},_isModernComponentType:function(){return"modern"===this.options.componentType&&!this._isMobile},_isTabbedComponentType:function(){return"tabbed"===this.options.componentType&&!this._isMobile},_deactivate:function(){this.menu&&(this.menu._closing=!1)},_createMobileMenu:function(){var e,t,i=this,r=i.options,o=i._ownerColumns();i._hasGroups()&&(e=i._groupColumns(o,!0),(t=i._flattenMenuCols(e)).length!==i.owner.columns.length&&i._syncMenuCols(t,i.owner.columns));var a=n.template(N)({ns:n.ns,field:i.field,title:i.title||i.field,messages:r.messages,sortable:r.sortable,filterable:r.filterable,columns:o,showColumns:r.columns,hasLockableColumns:r.hasLockableColumns,hasStickableColumns:r.hasStickableColumns,hasGroups:i._hasGroups(),groups:e,reorderable:r.reorderable,groupable:r.groupable});i.view=i.pane.append(a),i.view.state={columns:{}},i.wrapper=i.view.element.find(".k-column-menu"),i.menu=new $(i.wrapper.children(),{pane:i.pane,columnMenu:i}),i.menu.element.on("transitionend"+x,(function(e){e.stopPropagation()}));var s=i.view.wrapper&&i.view.wrapper[0]?i.view.wrapper:i.view.element;s.on("click",".k-header-done",(function(e){e.preventDefault(),i.menu._applyChanges(),i.menu._cancelChanges(!1),i.close()})),s.on("click",".k-header-cancel",(function(e){e.preventDefault(),i.menu._cancelChanges(!0),i.close()})),i.view.bind("showStart",(function(){var e=i.view||{columns:{}};i.options.hasLockableColumns&&i._updateLockedColumns(),i.options.hasStickableColumns&&i._updateStickyColumns(),i.options.reorderable&&i._updateReorderColumns(),i.options.groupable&&i._updateGroupColumns(),e.element.find(".k-sort-asc.k-selected").length?e.state.initialSort="asc":e.element.find(".k-sort-desc.k-selected").length&&(e.state.initialSort="desc")}))},destroy:function(){var e=this;C.fn.destroy.call(e),e.filterMenu&&e.filterMenu.destroy(),e._refreshHandler&&e.dataSource.unbind(p,e._refreshHandler),e.options.columns&&e.owner&&(e._updateColumnsMenuHandler&&(e.owner.unbind("columnShow",e._updateColumnsMenuHandler),e.owner.unbind("columnHide",e._updateColumnsMenuHandler)),e._updateColumnsLockedStateHandler&&(e.owner.unbind("columnLock",e._updateColumnsLockedStateHandler),e.owner.unbind("columnUnlock",e._updateColumnsLockedStateHandler))),e.menu&&(e.menu.element.off(x),e.menu.destroy()),e.wrapper.off(x),e.popup&&e.popup.destroy(),e.view&&e.view.purge(),e.link.off(x),e.owner=null,e.wrapper=null,e.element=null},close:function(){this._preventMenuCloseOnColumnVisibilityChange=!1,this.menu&&this.menu.close(),this.popup&&(this.popup.close(),this.popup.element.off("keydown"+x))},_click:function(e){e.preventDefault(),e.stopPropagation();var t=this.options;t.filter&&this.element.is(!t.filter)||(this.popup||this.pane?this._updateMenuItems():this._init(),this._isMobile?this.pane.navigate(this.view,this.options.animations.left):this.popup.toggle())},_updateMenuItems:function(){var e=this;e.options.columns&&(e._setMenuItemsVisibility(),e.options.columns.sort||e.options.columns.groups?e._updateDataIndexes():e._reorderMenuItems())},_setMenuItemsVisibility:function(){this._eachRenderedMenuItem((function(e,t,n){!1===t.matchesMedia?n.hide():n.show()}))},_reorderMenuItems:function(){this._eachRenderedMenuItem((function(e,t,n,i){n[0]&&n.index()!==e&&function(e,t,n){e>0?t.insertAfter(n.children().eq(e-1)):n.prepend(t)}(e,n,i)})),this._updateDataIndexes()},_updateDataIndexes:function(){var t=this,i=t._isMobile&&t.view?e(t.view.element).find(".k-columns-item").children("ul"):e(t.wrapper).find(".k-menu-group").first(),r=t._ownerColumns(!0).map((function(e){return e.title||e.field}));i.find("span."+(this._isMobile?"k-listgroup-form-field-wrapper":"k-menu-link")+" input").each((function(i){var o,a;t.options.columns.sort?(o=t._ownerColumns(),a=r.indexOf(o[i].title),e(this).attr(n.attr("index"),a)):e(this).attr(n.attr("index"),i)}))},_eachRenderedMenuItem:function(t){for(var i,r,o,s,l,c,d=this,u=a(D(d.owner.columns),(function(e){var t=!0,n=S(e.title||"");return!1!==e.menu&&(e.field||n.length)||(t=!1),t})).map((function(e){return{field:e.field,title:e.title,matchesMedia:e.matchesMedia}})),h=d._getRenderedList(),p=d._getRenderedListElements(h),f=function(e,t){for(var i,r,o,a,s,l=n.attr("index"),c=n.attr("field"),d={},u=0;u<e.length;u++)r=t.eq(u),o=parseInt(r.attr(l),10),a=r.attr(c),s=r.attr("title"),d[i=a||s]?d[i].push(o):d[i]=[o];return d}(p,h.find("input[type=checkbox]")),m=function(e){for(var t,n={},i=0;i<e.length;i++)n[t=JSON.stringify(e[i])]?n[t].push(i):n[t]=[i];return n}(u),g=0;g<u.length;g++){r=(o=u[g]).field?o.field:o.title,i=e.inArray(g,m[JSON.stringify(o)]),s=e();for(var v=0;v<f[r].length;v++)s=s.add(p.eq(f[r][v]));t(g,o,s.find((l="field",c=r,"["+n.attr(l)+"='"+(c||"").replace(/'/g,'"')+"']")).closest(d._isModernComponentType()?"label":"li").eq(i),h)}},_getRenderedList:function(){var t=this;return t._isModernComponentType()||t._isTabbedComponentType()?e(t.wrapper).find(".k-columns-item"):t._isMobile&&t.view?e(t.view.element).find(".k-columns-item").children("ul"):e(t.wrapper).find(".k-menu-group").first()},_getRenderedListElements:function(e){return this._isModernComponentType()||this._isTabbedComponentType()?e.find("label"):e.find("span."+(this._isMobile?"k-listgroup-form-field-wrapper":"k-menu-link"))},_open:function(){var t,i,r=this;e(".k-column-menu").not(r.wrapper).each((function(){let t=e(this).data(b);t&&t.close()})),r.popup.element.off("keydown"+x).on("keydown"+x,(function(o){var a=e(o.target);if((r._isModernComponentType()||r._isTabbedComponentType())&&o.keyCode===n.keys.ENTER&&a.click(),o.keyCode==n.keys.ESC){if(t=n.widgetInstance(a.find("select")),a.hasClass("k-picker")&&t&&t.popup.visible())return void o.stopPropagation();(i=a.closest(".k-popup").closest(".k-menu-item")).length>0&&(i.addClass("k-focus"),r.menu?r.menu.element.trigger("focus"):r.popup.element.find("[tabindex=0]").eq(0).trigger("focus")),a.closest(".k-popup").getKendoPopup().close()}})),r.options.hasLockableColumns&&r._updateLockedColumns(),r.options.hasStickableColumns&&r._updateStickyColumns(),r.options.reorderable&&r._updateReorderColumns(),r.options.groupable&&r._updateGroupColumns()},_activate:function(){this.menu?this.menu.element.trigger("focus"):this.popup.element.find("[tabindex=0]").eq(0).trigger("focus"),this.trigger(m,{field:this.field,container:this.wrapper})},_checkItemClass:function(e,t){return e.is("svg,path")&&(e=e.closest(`.${t}`)),e.hasClass(t)},_ownerColumns:function(e){var t,n=D(this.owner.columns),i=a(n,(function(e){var t=!0,n=S(e.title||"");return!1!==e.menu&&(e.field||n.length)||(t=!1),t})),r=this.options.columns.sort;return t=s(i,(function(e){return{originalField:e.field,field:e.field||e.title,title:e.title||e.field,hidden:e.hidden,matchesMedia:e.matchesMedia,index:l(e,n),locked:!!e.locked,_originalObject:e,uid:e.headerAttributes.id}})),r&&!e&&t.sort(c.create({field:"title",dir:r})),t},_sort:function(){var e=this;e.options.sortable&&(e.refresh(),e._isModernComponentType()||e._isTabbedComponentType()?e.wrapper.on("click"+x,".k-sort-asc, .k-sort-desc",e._sortHandler.bind(e)):e.menu.bind(g,e._sortHandler.bind(e)))},_sortHandler:function(t){var n,i=this,r=t.item?e(t.item):e(t.target);i._checkItemClass(r,"k-sort-asc")?n=u:i._checkItemClass(r,"k-sort-desc")&&(n=h),n&&(i._getSortItemsContainer(r).find(".k-sort-"+(n==u?h:u)).removeClass(d),i._sortDataSource(r,n),i._isMobile||i.close())},_getSortItemsContainer:function(e){return this._isModernComponentType()||this._isTabbedComponentType()?e.parents(".k-columnmenu-item-wrapper").first():e.parent()},_sortDataSource:function(e,n){var i,r,o=this,a=o.options.sortable,s=null===a.compare?t:a.compare,l=o.dataSource,c=l.sort()||[],u=e.hasClass(d)&&a&&!1!==a.allowUnsort;if(n=u?t:n,!o.trigger("sort",{sort:{field:o.field,dir:n,compare:s}})){if(u?e.removeClass(d):e.addClass(d),"multiple"===a.mode){for(i=0,r=c.length;i<r;i++)if(c[i].field===o.field){c.splice(i,1);break}c.push({field:o.field,dir:n,compare:s})}else c=[{field:o.field,dir:n,compare:s}];l.sort(c)}},_columns:function(){var t=this;t.options.columns&&(t._updateColumnsMenu(),t._updateColumnsMenuHandler=t._updateColumnsMenu.bind(t),t.owner.bind(["columnHide","columnShow"],t._updateColumnsMenuHandler),t._updateColumnsLockedStateHandler=t._updateColumnsLockedState.bind(t),t.owner.bind(["columnUnlock","columnLock"],t._updateColumnsLockedStateHandler),t._isModernComponentType()||t._isTabbedComponentType()?(t.wrapper.on("click"+x,".k-columns-item .k-button:not(.k-button-solid-primary)",(function(){t._updateColumnsMenu()})),t.wrapper.on("click"+x,".k-columns-item .k-button.k-button-solid-primary",t._applyColumnVisibility.bind(t)),t.wrapper.on("click"+x,".k-columns-item .k-checkbox",(function(){t._updateColumnsMenu(!0)}))):t.menu.bind(g,(function(i){var r,o,s,l=e(i.item),c=n.attr("uid"),d=a(D(t.owner.columns),(function(e){var t=!0,n=S(e.title||"");return!1!==e.menu&&(e.field||n.length)||(t=!1),t}));t._isMobile&&i.preventDefault(),l.parent().closest("li.k-columns-item")[0]&&((r=l.find(":checkbox")).attr("disabled")||(s=d.map((function(e){return e.headerAttributes.id})).indexOf(r.attr(c)),!0===(o=d[s]).hidden?t.owner.showColumn(o):t.owner.hideColumn(o),t._preventMenuCloseOnColumnVisibilityChange=!0))})))},_applyColumnVisibility:function(){var t,i,r,o,s=this,l=n.attr("field"),c=n.attr("uid"),d=s.wrapper.find(".k-columns-item input["+l+"]"),u=a(D(this.owner.columns),(function(e){var t=!0,n=S(e.title||"");return!1!==e.menu&&(e.field||n.length)||(t=!1),t})),h=d.length;for(s.owner.unbind("columnShow",s._updateColumnsMenuHandler),s.owner.unbind("columnHide",s._updateColumnsMenuHandler),t=0;t<h;t++)r=e(d[t]),i=u.map((function(e){return e.headerAttributes.id})).indexOf(r.attr(c)),o=u[i],r.is(":checked")&&o.hidden?s.owner.showColumn(o):r.is(":not(:checked)")&&!o.hidden&&s.owner.hideColumn(o);s.popup.close(),s.owner.bind(["columnHide","columnShow"],s._updateColumnsMenuHandler)},_sizeColumns:function(){var e=this;e._isModernComponentType()||e._isTabbedComponentType()?e.wrapper.on("click"+x,".k-auto-size-column, .k-auto-size-all",e._autoSizeHandler.bind(e)):e.menu.bind(g,e._autoSizeHandler.bind(e))},_clearAllFilters:function(){var e=this;e._isModernComponentType()||e._isTabbedComponentType()?e.wrapper.on("click"+x,".k-clear-all-filters",e._clearAllFiltersHandler.bind(e)):e.menu.bind(g,e._clearAllFiltersHandler.bind(e))},_clearAllFiltersHandler:function(t){var n=this;(t.item?e(t.item):e(t.target)).hasClass("k-clear-all-filters")&&n.owner&&n.owner.dataSource&&n.owner.dataSource.filter({})},_autoSizeHandler:function(t){var n=this,i=t.item?e(t.item):e(t.target);n._checkItemClass(i,"k-auto-size-column")?n.owner.autoFitColumn(n.field):n._checkItemClass(i,"k-auto-size-all")&&n.owner.autoFitColumns()},_updateColumnsMenu:function(e){var t,i,r,o,s,l=this,c=n.attr("field"),d=n.attr("locked"),u=n.attr("uid"),h={},p=0,f=0;e=!0===e;var m=a(D(this.owner.columns),(function(e,t){var n=!0,i=S(e.title||"");return!1!==e.menu&&(e.field||i.length)||(n=!1),n&&(h[t]=p,p++),n})),g=a(this._ownerColumns(),(function(t){return e?l.wrapper.find("[role='menuitemcheckbox'] ["+u+"='"+t.uid+"']").prop("checked"):!t.hidden&&!1!==t.matchesMedia})),v=a(g,(function(e){return e.originalField})),_=a(v,(function(e){return!0===e.locked})).length,b=a(v,(function(e){return!0!==e.locked})).length,y=a(this.owner.columns,(function(e){return!1===e.menu})),w=a(y,(function(e){return e.hidden}));this.wrapper.find("[role='menuitemcheckbox']").attr("aria-checked",!1);var k,x=this.wrapper.find(".k-columns-item input["+c+"]").prop("disabled",!1);for(e||x.prop("checked",!1),t=0,i=x.length;t<i;t++)s="true"===(r=x.eq(t)).attr(d),!1,k=r.data("kendoSwitch"),f=m.map((function(e){return e.headerAttributes.id})).indexOf(r.attr(u)),o=e?r.prop("checked"):!m[f].hidden&&!1!==m[f].matchesMedia,r.prop("checked",o),k&&(k.enable(!0),k.check(o)),r.closest("[role='menuitemcheckbox']").attr("aria-checked",o),o&&(1==_&&s&&(r.prop("disabled",!0),k&&k.enable(!1)),0!==y.length&&y.length!==w.length||1!=b||s||(r.prop("disabled",!0),k&&k.enable(!1)))},_updateColumnsLockedState:function(){var e,t,i,r,o=n.attr("field"),a=n.attr("locked"),s=function(e,t){var n,i,r,o={};for(n=0,i=e.length;n<i;n++)o[(r=e[n])[t]]=r;return o}(this._ownerColumns(),"field"),l=this.wrapper.find(".k-columns-item input[type=checkbox]");for(e=0,t=l.length;e<t;e++)(r=s[(i=l.eq(e)).attr(o)])&&i.attr(a,r.locked?.toString());this._updateColumnsMenu()},_filter:function(){var t=this,n="kendoFilterMenu",i=t.options;!1!==i.filterable&&(i.filterable.multi&&(n="kendoFilterMultiCheck",i.filterable.dataSource&&(i.filterable.checkSource=i.filterable.dataSource,delete i.filterable.dataSource)),t.filterMenu=t.wrapper.find(".k-filterable")[n](o(!0,{},{appendToElement:!0,dataSource:i.dataSource,values:i.values,field:t.field,title:t.title,change:function(e){t.trigger("filtering",{filter:e.filter,field:e.field})&&e.preventDefault()},componentType:t.options.componentType,cycleForm:!t._isModernComponentType()&&!t._isTabbedComponentType()},i.filterable)).data(n),t._isMobile&&t.menu.bind(g,(function(n){e(n.item).hasClass("k-filter-item")&&t.pane.navigate(t.filterMenu.view,t.options.animations.left)})))},_lockColumns:function(){var e=this;e._isModernComponentType()||e._isTabbedComponentType()?e.wrapper.on("click"+x,".k-lock, .k-unlock",e._lockableHandler.bind(e)):e.menu.bind(g,e._lockableHandler.bind(e))},_lockableHandler:function(t){var n=this,i=t.item?e(t.item):e(t.target);n._checkItemClass(i,"k-lock")?(n.owner.lockColumn(n.field),n._isMobile||n.close()):n._checkItemClass(i,"k-unlock")&&(n.owner.unlockColumn(n.field),n._isMobile||n.close())},_reorderColumns:function(){var e=this;e._isModernComponentType()||e._isTabbedComponentType()?e.wrapper.on("click"+x,".k-move-prev, .k-move-next",e._reorderHandler.bind(e)):e.menu.bind(g,e._reorderHandler.bind(e))},_reorderHandler:function(t){var n=this,i=t.item?e(t.item):e(t.target);i.hasClass("k-move-prev")?(n.owner._moveColumn(n.element,!0),n._isMobile||n.close()):i.hasClass("k-move-next")&&(n.owner._moveColumn(n.element,!1),n._isMobile||n.close())},_groupColumn:function(){var e=this;e._isModernComponentType()||e._isTabbedComponentType()?e.wrapper.on("click"+x,".k-group, .k-ungroup",e._groupHandler.bind(e)):e.menu.bind(g,e._groupHandler.bind(e))},_groupHandler:function(t){var n=this,i=t.item?e(t.item):e(t.target);(i.hasClass("k-group")||i.hasClass("k-ungroup"))&&(n.owner._handleSpaceKey(n.element,!0),n._isMobile||n.close())},_stickyColumns:function(){var e=this;e._isModernComponentType()||e._isTabbedComponentType()?e.wrapper.on("click"+x,".k-stick, .k-unstick",e._stickableHandler.bind(e)):e.menu.bind(g,e._stickableHandler.bind(e))},_stickableHandler:function(t){var n=this,i=t.item?e(t.item):e(t.target),r=n.field,o=n.owner.columns,s=a(o,(function(e){return e.field==r||e.title==r}))[0];n._checkItemClass(i,"k-stick")?(n.owner.stickColumn(n.field),n.trigger(v,{column:s}),n._isMobile||n.close()):n._checkItemClass(i,"k-unstick")&&(n.owner.unstickColumn(n.field),n.trigger(_,{column:s}),n._isMobile||n.close())},_updateLockedColumns:function(){var e=this.field,t=this.owner.columns,n=a(t,(function(t){return t.field==e||t.title==e}))[0];if(n){var i=!0===n.locked,r=a(t,(function(e){return!e.hidden&&(e.locked&&i||!e.locked&&!i)})).length,o=!1===n.lockable,s=this.wrapper.find(".k-lock").removeClass("k-disabled").removeAttr("aria-disabled"),l=this.wrapper.find(".k-unlock").removeClass("k-disabled").removeAttr("aria-disabled");(i||1==r||o)&&s.addClass("k-disabled").attr("aria-disabled","true"),i&&1!=r&&!o||l.addClass("k-disabled").attr("aria-disabled","true"),this._updateColumnsLockedState()}},_updateStickyColumns:function(){var e=this.field,t=this.owner.columns,n=a(t,(function(t){return t.field==e||t.title==e}))[0];if(n){var i=!0===n.sticky,r=!0===n.stickable,o=!0===n.locked,s=a(t,(function(e){return!e.hidden&&(e.locked&&o||!e.locked&&!o)})).length,l=this.wrapper.find(".k-stick").removeClass("k-disabled").removeAttr("aria-disabled"),c=this.wrapper.find(".k-unstick").removeClass("k-disabled").removeAttr("aria-disabled");(i||!r||o&&1===s)&&l.addClass("k-disabled").attr("aria-disabled","true"),i&&r||c.addClass("k-disabled").attr("aria-disabled","true")}},_updateReorderColumns:function(){var e=this.element,t=e.index(),n=e.parent().children().length,i=this.wrapper.find(".k-move-prev").removeClass("k-disabled").removeAttr("aria-disabled"),r=this.wrapper.find(".k-move-next").removeClass("k-disabled").removeAttr("aria-disabled");0===this.element.index()&&i.addClass("k-disabled").attr("aria-disabled","true"),t+1===n&&r.addClass("k-disabled").attr("aria-disabled","true")},_updateGroupColumns:function(){var e=this.element,t=this.wrapper,n=t.find(".k-menu-item.k-group"),i=t.find(".k-menu-item.k-ungroup");this.owner.groupable._canDrag(e)?(n.removeClass("k-hidden"),i.addClass("k-hidden")):(n.addClass("k-hidden"),i.removeClass("k-hidden"))},refresh:function(){var e,t,n,i=this,r=i.options.dataSource.sort()||[],o=i.field;for(i.wrapper.find(".k-sort-asc, .k-sort-desc").removeClass(d),t=0,n=r.length;t<n;t++)o==(e=r[t]).field&&i.wrapper.find(".k-sort-"+e.dir).addClass(d);i.link[i._filterExist(i.dataSource.filter())?"addClass":"removeClass"]("k-active")},_filterExist:function(e){var t,n=!1;if(e){for(var i=0,r=(e=e.filters).length;i<r;i++)(t=e[i]).field==this.field?n=!0:t.filters&&(n=n||this._filterExist(t));return n}}});const M=({messages:e,hideAutoSizeColumn:t})=>`<div class="k-columnmenu-item-wrapper">${t?"":`<div class="k-columnmenu-item k-auto-size-column" tabindex="0">${n.ui.icon("max-width")}${i(e.autoSizeColumn)}</div>`}\n<div class="k-columnmenu-item k-auto-size-all" tabindex="0">${n.ui.icon("display-inline-flex")}${i(e.autoSizeAllColumns)}</div></div>`,E=({messages:e})=>`<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item k-clear-all-filters" tabindex="0">${n.ui.icon("filter-clear")}${i(e.clearAllFilters)}</div></div>`,I=({messages:e})=>`<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item k-sort-asc" tabindex="0">${n.ui.icon("sort-asc-small")}${i(e.sortAscending)}</div><div class="k-columnmenu-item k-sort-desc" tabindex="0">${n.ui.icon("sort-desc-small")}${i(e.sortDescending)}</div></div>`,z=({columns:e,messages:t,encodeTitles:r,ns:o})=>`<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item-content k-columns-item"><div class="k-column-list-wrapper"><div class="k-column-list" role="menu">${function(e,t,r){return e.map((e=>e.groupHeader?`<span class="k-column-menu-group-header"><span class="k-column-menu-group-header-text">${e.title}</span></span>`:`<label class="k-column-list-item" role="menuitemcheckbox" aria-checked="false" ${!1===e.matchesMedia?`${n.attr("style-display")}="none"`:""}><input class="k-checkbox k-checkbox-md k-rounded-md" type="checkbox" title="${t?i(e.title):e.title}" data-${r}field="${e.field.replace(/\"/g,"&#34;")}" data-${r}index="${e.index} data-${r}locked="${e.locked}" data-${r}uid="${e.uid}" /><span class="k-checkbox-label">${t?i(e.title):e.title}</span></label>`)).join("")}(e,r,o)}</div><div class="k-actions-stretched k-columnmenu-actions">`+n.html.renderButton(`<button>${i(t.apply)}</button>`,{themeColor:"primary",icon:"check"})+n.html.renderButton(`<button>${i(t.reset)}</button>`,{icon:"undo"})+"</div></div></div></div>",P=({messages:e})=>`<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item k-group" tabindex="0">${n.ui.icon("group")}${i(e.groupColumn)}</div></div>\n<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item k-ungroup" tabindex="0">${n.ui.icon("ungroup")}${i(e.ungroupColumn)}</div></div>`,H=({hasLockableColumns:e,hasStickableColumns:t,messages:r,reorderable:o})=>`<div class="k-columnmenu-item-wrapper"><div class="k-column-menu-position">${e?(({messages:e})=>`<div class="k-columnmenu-item k-lock" tabindex="0">${n.ui.icon("lock")}${i(e.lock)}</div><div class="k-columnmenu-item k-unlock" tabindex="0">${n.ui.icon("unlock")}${i(e.unlock)}</div>`)({messages:r}):""}${t?(({messages:e})=>`<div class="k-columnmenu-item k-stick" tabindex="0">${n.ui.icon("stick")}${i(e.stick)}</div><div class="k-columnmenu-item k-unstick" tabindex="0">${n.ui.icon("unstick")}${i(e.unstick)}</div>`)({messages:r}):""}${o?(({messages:e})=>`<div class="k-columnmenu-item k-move-prev" tabindex="0">${n.ui.icon("caret-alt-left")}${i(e.movePrev)}</div><div class="k-columnmenu-item k-move-next" tabindex="0">${n.ui.icon("caret-alt-right")}${i(e.moveNext)}</div>`)({messages:r}):""}</div></div>`;var F=({autoSize:e,hideAutoSizeColumn:t,sortable:n,filterable:i,clearAllFilters:r,showColumns:o,messages:a,columns:s,hasLockableColumns:l,hasStickableColumns:c,encodeTitles:d,ns:u,reorderable:h,groupable:p})=>`${n?I({messages:a}):""}${o?z({columns:s,messages:a,encodeTitles:d,ns:u}):""}${i?'<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item-content k-column-menu-filter"><div class="k-filterable"></div></div></div>':""}${p?P({messages:a}):""}${e?M({messages:a,hideAutoSizeColumn:t}):""}${r?E({messages:a}):""}${l||c||h?H({hasLockableColumns:l,hasStickableColumns:c,messages:a,reorderable:h}):""}`;var R=({sortable:e,filterable:t,clearAllFilters:i,showColumns:r,messages:o,columns:a,hasLockableColumns:s,hasStickableColumns:l,encodeTitles:c,ns:d,reorderable:u,groupable:h,autoSize:p,hideAutoSizeColumn:f})=>`<div>\n                            <ul>\n                                ${t?`<li>${n.ui.icon("filter")}</li>`:""}\n                                ${e||s||l||u||h||p?`<li>${n.ui.icon("sliders")}</li>`:""}\n                                ${r?`<li>${n.ui.icon("columns")}</li>`:""}\n                            </ul>\n                            ${t?'<div><div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item-content k-column-menu-filter"><div class="k-filterable"></div></div></div></div>':""}\n                            ${e||s||l||u||h||p?function(e,t,n,i,r,o,a,s,l){var c="<div>";return e&&(c+=I({messages:a})),r&&(c+=P({messages:a})),(t||n||i)&&(c+=H({hasLockableColumns:t,hasStickableColumns:n,messages:a,reorderable:i})),o&&(c+=M({messages:a,hideAutoSizeColumn:s})),l&&(c+=E({messages:a})),c+"</div>"}(e,s,l,u,h,p,o,f,i):""}\n                            ${r?`<div>${z({columns:a,messages:o,encodeTitles:c,ns:d})}</div>`:""}\n                        </div>`;const L=({columns:e,messages:t,encodeTitles:r,ns:o,omitWrapAttribute:a,filterable:s,hasLockableColumns:l,hasStickableColumns:c})=>`<li class="k-item k-menu-item k-columns-item" aria-haspopup="true"><span class="k-link k-menu-link">${n.ui.icon("columns")}<span class="k-menu-link-text">${i(t.columns)}</span></span><ul>${function(e,t,r,o){return e.map((e=>e.groupHeader?`<li class="k-column-menu-group-header" ${o}="true" ><span class="k-column-menu-group-header-text">${e.title}</span></li>`:`<li role="menuitemcheckbox" aria-checked="false" ${!1===e.matchesMedia?`${n.attr("style-display")}="none"`:""}><input type="checkbox" class="k-checkbox k-checkbox-md k-rounded-md" title="${t?i(e.title):e.title}" data-${r}field="${e.field.replace(/\"/g,"&#34;")}" data-${r}index="${e.index}" data-${r}locked="${e.locked}" data-${r}uid="${e.uid}"/>${t?i(e.title):e.title}</li>`)).join("")}(e,r,o,a)}</ul></li>${s||l||c?'<li class="k-separator k-menu-separator" role="presentation"></li>':""}`,B=({messages:e,hasLockableColumns:t,hasStickableColumns:r,reorderable:o})=>`<li class="k-item k-menu-item k-position-item" aria-haspopup="true"><span class="k-link k-menu-link">${n.ui.icon("set-column-position")}<span class="k-menu-link-text">${i(e.setColumnPosition)}</span></span><ul>${t?(({messages:e,hasStickableColumns:t})=>`<li class="k-item k-menu-item k-lock"><span class="k-link k-menu-link">${n.ui.icon("lock")}<span class="k-menu-link-text">${i(e.lock)}</span></span></li><li class="k-item k-menu-item k-unlock"><span class="k-link k-menu-link">${n.ui.icon("unlock")}<span class="k-menu-link-text">${i(e.unlock)}</span></span></li>${t?'<li class="k-separator k-menu-separator" role="presentation"></li>':""}`)({messages:e,hasStickableColumns:r}):""}${r?(({messages:e})=>`<li class="k-item k-menu-item k-stick"><span class="k-link k-menu-link">${n.ui.icon("stick")}<span class="k-menu-link-text">${i(e.stick)}</span></span></li><li class="k-item k-menu-item k-unstick"><span class="k-link k-menu-link">${n.ui.icon("unstick")}<span class="k-menu-link-text">${i(e.unstick)}</span></span></li>`)({messages:e}):""}${o?(({messages:e})=>`<li class="k-item k-menu-item k-move-prev"><span class="k-link k-menu-link">${n.ui.icon("caret-alt-left")}<span class="k-menu-link-text">${i(e.movePrev)}</span></span></li><li class="k-item k-menu-item k-move-next"><span class="k-link k-menu-link">${n.ui.icon("caret-alt-right")}<span class="k-menu-link-text">${i(e.moveNext)}</span></span></li>`)({messages:e}):""}</ul></li>`;var O=({uid:e,sortable:t,filterable:r,showColumns:o,messages:a,columns:s,hasLockableColumns:l,hasStickableColumns:c,encodeTitles:d,ns:u,omitWrapAttribute:h,reorderable:p,groupable:f})=>`<ul id="${e}">${t?(({messages:e,showColumns:t,filterable:r})=>`<li class="k-item k-menu-item k-sort-asc"><span class="k-link k-menu-link">${n.ui.icon("sort-asc-small")}<span class="k-menu-link-text">${i(e.sortAscending)}</span></span></li><li class="k-item k-menu-item k-sort-desc"><span class="k-link k-menu-link">${n.ui.icon("sort-desc-small")}<span class="k-menu-link-text">${i(e.sortDescending)}</span></span></li>${t||r?'<li class="k-separator k-menu-separator" role="presentation"></li>':""}`)({messages:a,showColumns:o,filterable:r}):""}${o?L({columns:s,messages:a,encodeTitles:d,ns:u,omitWrapAttribute:h,filterable:r,hasLockableColumns:l,hasStickableColumns:c}):""}${r?(({messages:e,hasLockableColumns:t,hasStickableColumns:r,reorderable:o})=>`<li class="k-item k-menu-item k-filter-item" aria-haspopup="true"><span class="k-link k-menu-link">${n.ui.icon("filter")}<span class="k-menu-link-text">${i(e.filter)}</span></span><ul><li><div class="k-filterable"></div></li></ul></li>${t||r||o?'<li class="k-separator k-menu-separator" role="presentation"></li>':""}`)({messages:a,hasLockableColumns:l,hasStickableColumns:c,reorderable:p}):""}${f?(({messages:e,hasLockStickMove:t})=>`<li class="k-item k-menu-item k-group"><span class="k-link k-menu-link">${n.ui.icon("group")}<span class="k-menu-link-text">${i(e.groupColumn)}</span></span></li><li class="k-item k-menu-item k-ungroup"><span class="k-link k-menu-link">${n.ui.icon("ungroup")}<span class="k-menu-link-text">${i(e.ungroupColumn)}</span></span></li>${t?'<li class="k-separator k-menu-separator" role="presentation"></li>':""}`)({messages:a,hasLockStickMove:l||c||p}):""}${l||c||p?B({messages:a,hasLockableColumns:l,hasStickableColumns:c,reorderable:p}):""}\n</ul>`;const V=({messages:e,hasGroups:t,columns:r,groups:o,ns:a})=>`<li class="k-columns-item"><span class="k-list-title">${e.columnVisibility}</span>${function(e,t,r,o){var a="";if(o)for(var s=0;s<t.length;s++){a+=`<span class="k-list-group-header k-pb-1">${i(t[s].title)}</span><ul class="k-listgroup k-listgroup-flush k-mb-4">`;for(var l=0;l<t[s].columns.length;l++)a+=`<li id="${n.guid()}" class="k-item k-listgroup-item"><span class="k-listgroup-form-row"><span class="k-listgroup-form-field-label k-item-title">${t[s].columns[l].title}</span><span class="k-listgroup-form-field-wrapper"><input type="checkbox" title="${t[s].columns[l].title}" data-${r}field="${t[s].columns[l].field.replace(/\"/g,"&#34;")}" data-${r}index="${t[s].columns[l].index}" data-${r}uid="${t[s].columns[l].uid}" data-${r}locked="${t[s].columns[l].locked}"/></span></span></li>"`;a+="</ul>"}else{for(a+='<ul class="k-listgroup k-listgroup-flush k-mb-4">',l=0;l<e.length;l++)a+=`<li id="${n.guid()}" class="k-item k-listgroup-item"><span class="k-listgroup-form-row"><span class="k-listgroup-form-field-label k-item-title">${e[l].title}</span><span class="k-listgroup-form-field-wrapper"><input type="checkbox" title="${e[l].title}" data-${r}field="${e[l].field.replace(/\"/g,"&#34;")}" data-${r}index="${e[l].index}" data-${r}uid="${e[l].uid}" data-${r}locked="${e[l].locked}"/></span></span></li>`;a+="</ul>"}return a}(r,o,a,t)}</li>`;var N=({messages:e,title:t,sortable:r,filterable:o,showColumns:a,hasLockableColumns:s,hasStickableColumns:l,hasGroups:c,columns:d,groups:u,ns:h,reorderable:p,groupable:f})=>`<div data-${h}role="view" class="k-grid-column-menu"><div data-${h}role="header" class="k-appbar k-appbar-primary">${n.html.renderButton(`<button class="k-header-cancel" title="${e.cancel}" aria-label="${e.cancel}"></button>`,{icon:"chevron-left",fillMode:"flat"})}<span class="k-spacer"></span><span>${i(e.settings)}</span><span class="k-spacer"></span>${n.html.renderButton(`<button class="k-header-done" title="${e.done}" aria-label="${e.done}"></button>`,{icon:"check",fillMode:"flat"})}</div><div class="k-column-menu"><ul class="k-reset"><li><span class="k-list-title">${i(e.column)}: ${t}</span><ul class="k-listgroup k-listgroup-flush k-mb-4">${r?(({messages:e})=>`<li id="${n.guid()}" class="k-item k-listgroup-item k-sort-asc"><span class="k-link">${n.ui.icon("sort-asc-small")}<span class="k-item-title">${i(e.sortAscending)}</span></span></li><li id="${n.guid()}" class="k-item k-listgroup-item k-sort-desc"><span class="k-link">${n.ui.icon("sort-desc-small")}<span class="k-item-title">${i(e.sortDescending)}</span></span></li>`)({messages:e}):""}${s?(({messages:e})=>`<li id="${n.guid()}" class="k-item k-listgroup-item k-lock"><span class="k-link">${n.ui.icon("lock")}<span class="k-item-title">${i(e.lock)}</span></span></li><li id="${n.guid()}" class="k-item k-listgroup-item k-unlock"><span class="k-link">${n.ui.icon("unlock")}<span class="k-item-title">${i(e.unlock)}</span></span></li>`)({messages:e}):""}${l?(({messages:e})=>`<li id="${n.guid()}" class="k-item k-listgroup-item k-stick"><span class="k-link">${n.ui.icon("stick")}<span class="k-item-title">${i(e.stick)}</span></span></li><li id="${n.guid()}" class="k-item k-listgroup-item k-unstick"><span class="k-link">${n.ui.icon("unstick")}<span class="k-item-title">${i(e.unstick)}</span></span></li>`)({messages:e}):""}${p?(({messages:e})=>`<li id="${n.guid()}" class="k-item k-listgroup-item k-move-prev"><span class="k-link">${n.ui.icon("caret-alt-left")}<span class="k-item-title">${i(e.movePrev)}</span></span></li><li id="${n.guid()}" class="k-item k-listgroup-item k-move-next"><span class="k-link">${n.ui.icon("caret-alt-right")}<span class="k-item-title">${i(e.moveNext)}</span></span></li>`)({messages:e}):""}${o?(({messages:e})=>`<li id="${n.guid()}" class="k-item k-listgroup-item k-filter-item"><span class="k-link k-filterable">${n.ui.icon("filter")}<span class="k-item-title">${i(e.filter)}</span><span class="k-select">${n.ui.icon("chevron-right")}</span></span></li>`)({messages:e}):""}${f?(({messages:e})=>`<li id="${n.guid()}" class="k-item k-listgroup-item k-group"><span class="k-link">${n.ui.icon("group")}<span class="k-item-title">${i(e.groupColumn)}</span></span></li><li id="${n.guid()}" class="k-item k-listgroup-item k-ungroup"><span class="k-link">${n.ui.icon("ungroup")}<span class="k-item-title">${i(e.ungroupColumn)}</span></span></li>`)({messages:e}):""}</ul></li>${a?V({messages:e,hasGroups:c,columns:d,groups:u,ns:h}):""}<li class="k-item k-clear-wrap"><ul class="k-listgroup k-listgroup-flush"><li class="k-listgroup-item"><span class="k-link k-label k-clear" title="${e.clear}" aria-label="${e.clear}">${i(e.clear)}</span></li></ul></li></ul></div></div>`,$=C.extend({init:function(e,t){var n=this;C.fn.init.call(n,e,t),n._createCheckBoxes(),n.element.on("click"+x,"li.k-item:not(.k-separator):not(.k-disabled):not(:has(.k-switch))","_click")},events:[g],_click:function(t){var n=this;if(e(t.target).is("[type=checkbox]")||t.preventDefault(),!e(t.target).hasClass("k-clear"))return e(t.target).hasClass("k-filterable")?(n._cancelChanges(!0),void n.trigger(g,{item:t.currentTarget})):void n._updateSelectedItems(t.currentTarget);n._cancelChanges(!0)},_updateSelectedItems:function(t){var n=this,i=e(t),r=n.options.columnMenu.view.state||{columns:{}},o=i.prop("id");if(!i.hasClass("k-filter-item")){var a,s,l;if(r[o]?r[o]=!1:r[o]=!0,i.hasClass("k-sort-asc")||i.hasClass("k-sort-desc"))i.hasClass("k-sort-asc")?(a="asc",s=n.element.find(".k-sort-desc")):(a="desc",s=n.element.find(".k-sort-asc")),l=s.prop("id"),a!==r.initialSort||i.hasClass("k-selected")||(r[o]=!1),r[l]&&(r[l]=!1),s.removeClass(d);i.hasClass(d)?i.removeClass(d):i.addClass(d)}},_cancelChanges:function(e){var t=this,n=t.options.columnMenu,i=n.view,r=(i.state||{columns:{}}).columns;if(t.element.find("."+d).removeClass(d),n.refresh(),e){var o=[];for(var a in r)if(r.hasOwnProperty(a)&&!0===r[a]){var s=i.element.find("#"+a);o.push(s[0])}for(var l=o.length-1;l>=0;l--)t.trigger(g,{item:o[l]});n.options.hasLockableColumns&&n._updateLockedColumns(),n.options.hasStickableColumns&&n._updateStickyColumns(),n.options.reorderable&&n._updateReorderColumns(),n.options.groupable&&n._updateGroupColumns()}t.options.columnMenu.view.state={columns:{}}},_applyChanges:function(){var e=this.options.columnMenu.view,t=e.state||{columns:{}};for(var n in t)if(t.hasOwnProperty(n)&&"initialSort"!==n&&"columns"!==n&&!0===t[n]){var i=e.element.find("#"+n);i.hasClass(d)?i.removeClass(d):i.addClass(d),this.trigger(g,{item:i[0]})}},_createCheckBoxes:function(){var e=this;e.element.find(".k-columns-item").find("[type='checkbox']").kendoSwitch({messages:{checked:"",unchecked:""},change:function(t){var n=t.sender.element.closest(".k-item"),i=e.options.columnMenu.view.state||{columns:{}},r=n.prop("id");i.columns[r]?i.columns[r]=!1:i.columns[r]=!0,e.trigger(g,{item:n})}})},_destroyCheckBoxes:function(){for(var e,t=this.element.find(".k-columns-item").find("[type='checkbox']"),n=0;n<t.length;n++)(e=t.eq(n).data("kendoSwitch"))&&e.destroy()},close:function(){this.options.pane.navigate("")},destroy:function(){var e=this;C.fn.destroy.call(e),e.element.off(x),e._destroyCheckBoxes()}});r.plugin(A)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=i.Widget,o="dir",a="asc",s="single",l="mixed",c="field",d="desc",u=".kendoColumnSorter",h=".k-link",p="aria-sort",f=r.extend({init:function(e,t){var n,i=this;r.fn.init.call(i,e,t),i._refreshHandler=i.refresh.bind(i),i.dataSource=i.options.dataSource.bind("change",i._refreshHandler),i.directions=i.options.initialDirection===a?[a,d]:[d,a],(n=i.element.find(h))[0]||(n=i.element.wrapInner('<a class="k-link" href="#"/>').find(h)),i.link=n,i.element.on("click"+u,i._click.bind(i))},options:{name:"ColumnSorter",mode:s,allowUnsort:!0,compare:null,filter:"",initialDirection:a,showIndexes:!1},events:["change"],destroy:function(){var e=this;r.fn.destroy.call(e),e.element.off(u),e.dataSource.unbind("change",e._refreshHandler),e._refreshHandler=e.element=e.link=e.dataSource=null},refresh:function(i){if(!i||"itemchange"!==i.action&&"sync"!==i.action){var r,s,l,u,h,f,m,g,v=this,_=v.dataSource.sort()||[],b=v.element,y=b.attr(n.attr(c)),w=(v.dataSource._sortFields||{})[y];b.removeAttr(n.attr(o)),b.removeAttr(p),w&&(r=w.dir,b.attr(n.attr(o),r),u=w.index),b.is("th")&&w&&(s=function(e){var t=null;e.is("th")&&((t=e.closest("table")).parent().hasClass("k-grid-header-wrap")?t=t.closest(".k-grid").find(".k-grid-content > table"):t.parent().hasClass("k-grid-header-locked")&&(t=t.closest(".k-grid").find(".k-grid-content-locked > table")));return t}(b),s&&(b.attr(n.attr("index"))?(h=b.closest("table"),f=h.find("tr:not(.k-filter-row)"),m=n.attr("index"),g=f.find("th["+m+"]:visible"),l=[].sort.call(g,(function(n,i){n=e(n),i=e(i);var r=n.attr(m),o=i.attr(m);return r===t&&(r=e(n).index()),o===t&&(o=e(i).index()),(r=parseInt(r,10))>(o=parseInt(o,10))?1:r<o?-1:0})).index(b)):l=b.parent().children(":visible").index(b),s.find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(l).toggleClass("k-sorted",r!==t))),b.toggleClass("k-sorted",r!==t),b.find(".k-i-sort-asc-small,.k-i-sort-desc-small,.k-svg-i-sort-asc-small,.k-svg-i-sort-desc-small,.k-sort-order,.k-sort-icon").remove(),r===a?(e('<span class="k-sort-icon">'+n.ui.icon("sort-asc-small")+"</span>").appendTo(v.link),b.attr(p,"ascending")):r===d?(e('<span class="k-sort-icon">'+n.ui.icon("sort-desc-small")+"</span>").appendTo(v.link),b.attr(p,"descending")):b.attr(p,"none"),v.options.showIndexes&&_.length>1&&u&&e('<span class="k-sort-order" />').html(u).appendTo(v.link)}},_toggleSortDirection:function(e){var n=this.directions;return e===n[n.length-1]&&this.options.allowUnsort?t:n[0]===e?n[1]:n[0]},_click:function(e){var i,r,a=this,d=a.element,u=d.attr(n.attr(c)),h=d.attr(n.attr(o)),p=a.options,f=null===a.options.compare?t:a.options.compare,m=a.dataSource.sort()||[],g=e.ctrlKey||e.metaKey;if(e.preventDefault(),(!p.filter||d.is(p.filter))&&(h=this._toggleSortDirection(h),!this.trigger("change",{sort:{field:u,dir:h,compare:f}}))){if(p.mode===s||p.mode===l&&!g)m=[{field:u,dir:h,compare:f}];else if("multiple"===p.mode||p.mode===l&&g){for(i=0,r=m.length;i<r;i++)if(m[i].field===u){m.splice(i,1);break}m.push({field:u,dir:h,compare:f})}this.dataSource.options.endless&&d.closest(".k-grid").getKendoGrid()._resetEndless(),this.dataSource.sort(m)}}});i.plugin(f)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=n.Widget,r="change",o="disabled",a="checked",s=i.extend({init:function(e,n){var r=this;i.fn.init.call(r,e,n),r._wrapper(),r._initSettings(),r._attachEvents(),t.notify(r,t.ui)},events:[r],options:{name:"ToggleInputBase"},NS:".kendoToggleInputBase",RENDER_INPUT:e.noop,check:function(e){var t=this,n=t.element[0];if(undefined===e)return n.checked;n.checked!==e&&(t.options.checked=n.checked=e),e?t.element.attr(a,a):t.element.prop(a,!1)},destroy:function(){i.fn.destroy.call(this),this.wrapper.off(this.NS)},enable:function(e){var t=this.element;void 0===e&&(e=!0),this.options.enabled=e,e?t.prop(o,!1):t.attr(o,o)},toggle:function(){this.check(!this.element[0].checked)},_attachEvents:function(){this.element.on(r+this.NS,this._change.bind(this))},_change:function(){var e=this.element[0].checked;this.trigger(r,{checked:e})},_initSettings:function(){var e=this,t=e.element[0],n=e.options;null===n.checked&&(n.checked=t.checked),e.check(n.checked),n.enabled=n.enabled&&!e.element.attr(o),e.enable(n.enabled)},_wrapper:function(){var t=this,n=t.options;(0,t.RENDER_INPUT)(t.element,e.extend({},n)),t.element.removeClass("input-validation-error"),t.wrapper=t.element.wrap(`<span class="${n.wrapperClass}"></span>`).parent()},setOptions:function(t){this._clearCssClasses(t,this.element),this._setEvents(t),e.extend(this.options,t),this._applyCssClasses(this.element)}});n.plugin(s)}(window.kendo.jQuery);kendo;!function(){var e=window.kendo,t=e.ui,n=t.ToggleInputBase.extend({options:{name:"CheckBox",checked:null,enabled:!0,encoded:!0,label:null,rounded:"medium",size:"medium",wrapperClass:"k-checkbox-wrap"},RENDER_INPUT:e.html.renderCheckBox,NS:".kendoCheckBox",value:function(e){return"string"==typeof e&&(e="true"===e),this.check.apply(this,[e])}});e.cssProperties.registerPrefix("CheckBox","k-checkbox-"),e.cssProperties.registerValues("CheckBox",[{prop:"rounded",values:e.cssProperties.roundedValues.concat([["full","full"]])}]),t.plugin(n)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=n.Widget,r=e.extend,o=t.isFunction,a=e.isPlainObject,s=e.inArray,l=/("|\%|'|\[|\]|\$|\.|\,|\:|\;|\+|\*|\&|\!|\#|\(|\)|<|>|\=|\?|\@|\^|\{|\}|\~|\/|\||`)/g,c="change",d="equalSet",u=["url","email","number","date","boolean"];function h(e){return(e=null!=e?e:"").type||t.type(e)||"string"}function p(e){var n,i,r=(e.model.fields||e.model)[e.field],l=h(r),c=r?r.validation:{},d=r?r.attributes:{},p=t.attr("type"),f=t.attr("bind"),m={id:e.id||e.field,name:e.field,title:e.title?e.title:e.field};for(n in c){if(i=c[n],s(n,u)>=0)m[p]=n;else if(!o(i)){var g=t.getCulture();if("number"==typeof i&&g.name.length){var v=g.numberFormat,_=i.toString().replace(".",v["."]);m[n]=_}else m[n]=a(i)?i.value||n:i}m[t.attr(n+"-msg")]=i.message,m.autocomplete="off"}for(var b in d)m[b]=d[b];return s(l,u)>=0&&(m[p]=l),m[f]=("boolean"===l?"checked:":"value:")+e.field,m}function f(e,t){var n=e.attr("id");return n&&(t.id=n,e.removeAttr("id")),t}var m=["AutoComplete","CheckBox","CheckBoxGroup","ColorGradient","ColorPicker","ColorPalette","ComboBox","DateInput","DatePicker","DateTimePicker","DropDownTree","Editor","FlatColorPicker","MaskedTextBox","MultiColumnComboBox","MultiSelect","NumericTextBox","RadioGroup","Rating","Slider","Switch","TimePicker","DropDownList","TextBox","TextArea","Captcha","Signature","TimeDurationPicker"],g={hidden:function(t,n){var i=p(n);e('<input type="hidden"/>').attr(i).appendTo(t)},number:function(n,i){var o=p(i);e('<input type="text"/>').attr(o).appendTo(n).kendoNumericTextBox(r({},i.editorOptions,{format:i.format})),e("<span "+t.attr("for")+'="'+i.field+'" class="k-invalid-msg k-hidden"/>').appendTo(n)},date:function(n,i){var o=p(i),a=i.format;a&&(a=t._extractFormat(a)),o[t.attr("format")]=a,e('<input type="text"/>').attr(o).appendTo(n).kendoDatePicker(r({},i.editorOptions,{format:i.format})),e("<span "+t.attr("for")+'="'+i.field+'" class="k-invalid-msg k-hidden"/>').appendTo(n)},string:function(t,n){var i=p(n);e('<input type="text"/>').attr(i).appendTo(t).kendoTextBox(n.editorOptions)},boolean:function(n,i){var r=p(i),o=e('<input type="checkbox" />').attr(r).appendTo(n).kendoCheckBox(i.editorOptions);e("<span "+t.attr("for")+'="'+i.field+'" class="k-invalid-msg k-hidden"/>').appendTo(n),b(o,n,i)},values:function(n,i){var r=p(i),o=t.stringify(function(e){var t,n,i,r,o,a;if(e&&e.length)for(a=[],t=0,n=e.length;t<n;t++)o=(i=e[t]).text||i.value||i,r=null==i.value?i.text||i:i.value,a[t]={text:o,value:r};return a}(i.values));e("<select "+t.attr("text-field")+'="text"'+t.attr("value-field")+'="value"'+t.attr("source")+"='"+(o?o.replace(/\'/g,"&apos;"):o)+"'"+t.attr("size")+'="'+i.editorOptions.size+'"'+t.attr("role")+'="dropdownlist"/>').attr(r).appendTo(n),e("<span "+t.attr("for")+'="'+i.field+'" class="k-invalid-msg  k-hidden"/>').appendTo(n)},kendoEditor:function(t,n){var i=p(n),r=n.editor,o="kendo"+r,a=n.editorOptions,s=function(e,t){if(e.length)return"DropDownTree"===e&&t&&t.checkboxes||"MultiSelect"===e?"<select />":"RadioGroup"===e||"CheckBoxGroup"===e?"<ul />":"Signature"===e?"<div></div>":"Editor"===e||"TextArea"===e?"<textarea />":"<input />"}(r,a);b(e(s).attr(i).appendTo(t)[o](a),t,n)}},v={number:function(t,n){var i=p(n);i=f(t,i),e('<input type="number"/>').attr(i).appendTo(t)},date:function(t,n){var i=p(n);i=f(t,i),e('<input type="date"/>').attr(i).appendTo(t)},string:function(t,n){var i=p(n);i=f(t,i),e('<input type="text" />').attr(i).appendTo(t)},boolean:function(t,n){var i=p(n);i=f(t,i),e('<input type="checkbox" />').attr(i).appendTo(t)},values:function(t,n){var i=p(n),r=n.values,o=e("<select />");for(var a in i=f(t,i),r)e('<option value="'+r[a].value+'">'+r[a].text+"</option>").appendTo(o);o.attr(i).appendTo(t)}};function _(e,t){var n,i,r=e&&e.validation||{};for(n in r)i=r[n],a(i)&&i.value&&(i=i.value),o(i)&&(t[n]=i)}function b(t,n,i){(i&&i.shouldRenderHidden||!1)&&(t.val(!0),n.append(e("<input type='hidden' name='"+i.field+"' value='false' data-skip='true' data-validate='false'/>")))}var y=i.extend({init:function(e,t){var n=this;t.target&&t.target.pane&&(n._isMobile=!0),i.fn.init.call(n,e,t),n._validateProxy=n._validate.bind(n),n.refresh()},events:[c],options:{name:"Editable",editors:g,mobileEditors:v,clearContainer:!0,validateOnBlur:!0,validationSummary:!1,errorTemplate:({message:e})=>'<div class="k-tooltip k-tooltip-error k-validator-tooltip">'+t.ui.icon({icon:"exclamation-circle",iconClass:"k-tooltip-icon"})+`<span class="k-tooltip-content">${e}</span><span class="k-callout k-callout-n"></span></div>`,skipFocus:!1,size:"medium"},editor:function(n,i){var o,s=this,c=s._isMobile?v:s.options.editors,d=a(n),u=d?n.field:n,p=s.options.model||{},f=d&&n.values?"values":h(i),g=d&&"string"==typeof n.editor&&"hidden"===n.editor,_=d&&!g&&n.editor,b=d&&-1!==e.inArray(n.editor,m),y=_?n.editor:c[g?"hidden":f],w=s.element.find("["+t.attr("container-for")+"="+u.replace(l,"\\$1")+"]");y=y||c.string,b?y=c.kendoEditor:_&&"string"==typeof n.editor&&(y=function(e){e.append(n.editor)}),d?(n.editorOptions||(n.editorOptions={}),n.editorOptions=r({},{size:s.options.size},n.editorOptions),o=n):o={field:u,editorOptions:{size:s.options.size}},y(w=w.length?w:s.element,r(!0,{},o,{model:p}))},_validate:function(n){var i,r=this,o=n.value,a=r._validationEventInProgress,s={},d=t.attr("bind"),u=n.field.replace(l,"\\$1"),h=new RegExp("(value|checked)\\s*:\\s*"+u+"\\s*(,|$)");s[n.field]=n.value,(i=e(":input["+d+'*="'+u+'"]',r.element).filter("["+t.attr("validate")+"!='false']").filter((function(){return h.test(e(this).attr(d))}))).length>1&&(i=i.filter((function(){var t=e(this);return!t.is(":radio")||t.val()==o})));try{r._validationEventInProgress=!0,(!r.validatable.validateInput(i)||!a&&r.trigger(c,{values:s}))&&n.preventDefault()}finally{r._validationEventInProgress=!1}},end:function(){return this.validatable.validate()},destroy:function(){var e=this;i.fn.destroy.call(e),e.options.model.unbind("set",e._validateProxy),e.options.model.unbind(d,e._validateProxy),t.unbind(e.element),e.validatable&&e.validatable.destroy(),t.destroy(e.element),e.element.removeData("kendoValidator"),e.element.is("["+t.attr("role")+"=editable]")&&e.element.removeAttr(t.attr("role"))},refresh:function(){var n,i,r,o,s,l,c=this,u=c.options.fields||[],h=c._container=c.options.clearContainer?c.element.empty():c.element,p=c.options.model||{},f={};for(Array.isArray(u)||(u=[u]),n=0,i=u.length;n<i;n++)r=u[n],o=a(r)?r.field:r,_(s=(p.fields||p)[o],f),c.editor(r,s);if(!i)for(o in l=p.fields||p)_(l[o],f);!function(n){n.find(":input:not(:button, .k-checkbox-list .k-checkbox, .k-radio-list .k-radio, ["+t.attr("role")+"=listbox], ["+t.attr("role")+"=upload], ["+t.attr("skip")+"], [type=file]), ["+t.attr("role")+"=radiogroup]").each((function(){var n=t.attr("bind"),i=this.getAttribute(n)||"",r="checkbox"===this.type||"radio"===this.type?"checked:":"value:",o=this.getAttribute("name")===y.antiForgeryTokenName,a=this.attributes.name&&this.attributes.name.value;-1===i.indexOf(r)&&a&&!o&&(i+=(i.length?",":"")+r+a,e(this).attr(n,i))}))}(h),c.validatable&&c.validatable.destroy(),t.bind(h,c.options.model),c.options.validateOnBlur&&(c.options.model.unbind("set",c._validateProxy).bind("set",c._validateProxy),c.options.model.unbind(d,c._validateProxy).bind(d,c._validateProxy)),c.validatable=new t.ui.Validator(h,{validateOnBlur:c.options.validateOnBlur,validationSummary:c.options.validationSummary,errorTemplate:c.options.errorTemplate||undefined,rules:f}),c.options.skipFocus||queueMicrotask((()=>{c._focusEditor()}))},_focusEditor:function(){this._container.find(":kendoFocusable").eq(0).trigger("focus")}});y.antiForgeryTokenName="__RequestVerificationToken",n.plugin(y)}(window.kendo.jQuery);kendo;!function(e,t){var n,i=window.kendo,r=i.ui.Widget,o=i.ui.Popup.TabKeyTrap,a=i.ui.Draggable,s=e.isPlainObject,l=i._activeElement,c=i._outerWidth,d=i._outerHeight,u=e.extend,h=e.each,p=i.template,f="body",m=".kendoWindow",g=".kendoWindowModal",v=".k-window",_=".k-window-title",b=_+"bar",y=".k-window-content",w=".k-resize-handle",k=".k-overlay",x="k-window-minimized",C="k-content-frame",S="k-i-loading",T="k-hover",D="k-focus",A="k-window-maximized",M="k-display-inline-flex",E=":visible",I="k-hidden",z="hidden",P="cursor",H="open",F="activate",R="deactivate",L="close",B="refresh",O="resizeStart",V="resizeEnd",N="dragstart",$="dragend",U="restore",W="error",j="overflow",q="original-overflow-rule",G="zIndex",K=".k-window-titlebar-actions .k-i-window-minimize,.k-window-titlebar-actions .k-i-window,.k-window-titlebar-actions .k-svg-i-window-minimize,.k-window-titlebar-actions .k-svg-i-window",Y=".k-i-pin,.k-svg-i-pin",Q=".k-i-unpin,.k-svg-i-unpin",X=Y+","+Q,Z=".k-window-titlebar .k-window-titlebar-action",J=".k-window-titlebar .k-i-arrow-rotate-cw,.k-window-titlebar .k-svg-i-arrow-rotate-cw",ee="WindowEventsHandled",te=/^0[a-z]*$/i,ne=i.isLocalUrl,ie={small:"k-window-sm",medium:"k-window-md",large:"k-window-lg"};function re(e){return void 0!==e}function oe(e,t){return parseInt(e.css(t),10)||0}function ae(e,t,n){return e&&isNaN(e)&&e.toString().indexOf("px")<0?e:Math.max(Math.min(parseInt(e,10),n===1/0?n:parseInt(n,10)),t===-1/0?t:parseInt(t,10))}function se(){return!this.type||this.type.toLowerCase().indexOf("script")>=0}function le(t){for(var n={top:t.offsetTop,left:t.offsetLeft},i=t.offsetParent;i;){n.top+=i.offsetTop,n.left+=i.offsetLeft;var r=e(i).css("overflowX"),o=e(i).css("overflowY");"auto"!==o&&"scroll"!==o||(n.top-=i.scrollTop),"auto"!==r&&"scroll"!==r||(n.left-=i.scrollLeft),i=i.offsetParent}return n}var ce=r.extend({init:function(n,a){var l,c,d,u,h,p,f,g,w=this,k={},x=a&&a.actions&&!a.actions.length;r.fn.init.call(w,n,a),u=(a=w.options).position,n=w.element,h=a.content,f=e(window),x&&(a.actions=[]),w.appendTo=e(a.appendTo),w.containment=a.draggable.containment?e(a.draggable.containment).first():null,h&&!s(h)&&(h=a.content={url:h}),n.find("script").filter(se).remove(),n.parent().is(w.appendTo)||w.containment||u.top!==t&&u.left!==t||(n.is(E)?(k=n.offset(),!0):(c=n.css("visibility"),d=n.css("display"),n.css({visibility:z,display:""}),k=document.body.contains(n[0])?n.offset():{top:0,left:0},n.css({visibility:c,display:d})),u.top===t&&(u.top=k.top),u.left===t&&(u.left=k.left)),re(a.visible)&&null!==a.visible||(a.visible=n.is(E)),l=w.wrapper=n.closest(v),n.is(".k-window-content")&&l[0]||(n.addClass("k-window-content"),n.attr("tabindex",0),w._createWindow(n,a),l=w.wrapper=n.closest(v),w.title(w.options.title),w._dimensions(),a._footerTemplate&&w.wrapper.append(i.template(a._footerTemplate)(a._footerMessages))),a.themeColor&&"none"!==a.themeColor&&l.addClass(i.getValidCssClass("k-window-","themeColor",a.themeColor)),w.minTop=w.minLeft=-1/0,w.maxTop=w.maxLeft=1/0,w._position(),h&&w.refresh(h),a.visible&&w.toFront(null,!a.modal),p=l.children(y),a.visible&&a.modal&&w._overlay(l.is(E)).css({opacity:.5}),l.on("mouseenter"+m,Z,w._buttonEnter.bind(w)).on("mouseleave"+m,Z,w._buttonLeave.bind(w)).on("click"+m,"> "+Z,w._windowActionHandler.bind(w)).on("keydown"+m,w,w._keydown.bind(w)).on("focus"+m,w._focus.bind(w)).on("blur"+m,w._blur.bind(w)),p.on("keydown"+m,w,w._keydownContent.bind(w)),p.find("."+C)[0]&&!f.data(ee)&&(f.on("blur"+m,(function(){var t=e(document.activeElement).parent(y);t.length&&i.widgetInstance(t)._focus()})),f.on("focus"+m,(function(){e(y).not(".k-dialog-content").each((function(t,n){i.widgetInstance(e(n))._blur()}))})),f.data(ee,!0)),this._resizable(),this._draggable(),a.pinned&&this.wrapper.is(":visible")&&w.pin(),(g=n.attr("id"))&&(g+="_wnd_title",l.attr({role:"dialog","aria-labelledby":g}).children(b).children(_).attr("id",g)),l.add(l.children(".k-resize-handle,"+b)).on(i.support.mousedown+m,w.toFront.bind(w)),w.touchScroller=i.touchScroller(n),w._resizeHandler=w._onDocumentResize.bind(w),w._marker=i.guid().substring(0,8),e(window).on("resize"+m+w._marker,w._resizeHandler),a.visible&&(w.trigger(H),w.trigger(F)),i.notify(w),this.options.modal&&(this._tabKeyTrap=new o(l),this._tabKeyTrap.trap(),this._tabKeyTrap.shouldTrap=function(){return l.data("isFront")}),w._showWatermarkOverlay&&w._showWatermarkOverlay(w.wrapper[0])},_buttonEnter:function(t){e(t.currentTarget).addClass(T)},_buttonLeave:function(t){e(t.currentTarget).removeClass(T)},_focus:function(){this.wrapper.addClass(D)},_blur:function(){this.wrapper.removeClass(D)},_dimensions:function(){var e=this.wrapper,t=this.options,n=t.width,i=t.height,r=t.maxHeight,o=t.size,a=["minWidth","minHeight","maxWidth","maxHeight"],s="content-box"==e.css("box-sizing"),l=s?oe(e,"border-left-width")+oe(e,"border-right-width"):0,c=s?oe(e,"border-top-width")+oe(e,"border-bottom-width"):0,d=s?oe(e,"padding-top"):0;this.containment&&!this._isPinned&&(this._updateBoundaries(),t.maxHeight=Math.min(this.containment.height-(c+d),r),t.maxWidth=Math.min(this.containment.width-l,t.maxWidth));for(var u=0;u<a.length;u++){var h=t[a[u]]||"";h!=1/0&&e.css(a[u],h)}r!=1/0&&this.element.css("maxHeight",r),n?e.outerWidth(ae(n,t.minWidth,t.maxWidth)):e.outerWidth(""),i?e.outerHeight(ae(i,t.minHeight,t.maxHeight)):e.outerHeight(""),t.visible||e.removeClass(M).hide(),o&&ie[o]&&e.addClass(ie[o])},_position:function(){var e,t,n=this.wrapper,i=this.options.position;this._updateBoundaries(),this.containment&&(i.top=i.top||0,i.left=i.left||0,e=i.top.toString().indexOf("%")>0?parseInt(this.containment.height*(parseFloat(i.top)/100),10):i.top,t=i.left.toString().indexOf("%")>0?parseInt(this.containment.width*(parseFloat(i.left)/100),10):i.left,i.top=ae(e,this.minTop,this.maxTop),i.left=ae(t,this.minLeft,this.maxLeft)),i.top&&i.top.toString().indexOf("px")>0&&(i.top=Number(i.top.replace("px",""))),i.left&&i.left.toString().indexOf("px")>0&&(i.left=Number(i.left.replace("px",""))),0===i.top&&(i.top=i.top.toString()),0===i.left&&(i.left=i.left.toString()),n.css({top:i.top||"",left:i.left||""})},_updateBoundaries:function(){var e=this.containment;if(!e)return null;e.width=e.innerWidth(),e.height=e.innerHeight(),parseInt(e.width,10)>e[0].clientWidth&&(e.width-=i.support.scrollbar()),parseInt(e.height,10)>e[0].clientHeight&&(e.height-=i.support.scrollbar()),e.position=le(e[0]),this._isPinned?(this.minTop=this.minLeft=-1/0,this.maxTop=this.maxLeft=1/0):(this.minTop=e.scrollTop(),this.minLeft=e.scrollLeft(),this.maxLeft=this.minLeft+e.width-c(this.wrapper,!0),this.maxTop=this.minTop+e.height-d(this.wrapper,!0))},_animationOptions:function(e){var t=this.options.animation;return t&&t[e]||{open:{effects:{}},close:{hide:!0,effects:{}}}[e]},_resize:function(){i.resize(this.element.children())},_resizable:function(){var t=this.options.resizable,i=this.wrapper;this.resizing&&(i.off("dblclick"+m).children(w).remove(),this.resizing.destroy(),this.resizing=null),t&&(i.on("dblclick"+m,b,function(t){e(t.target).closest(".k-window-titlebar-action").length||this.toggleMaximization()}.bind(this)),h("n e s w se sw ne nw".split(" "),(function(e,t){i.append(n.resizeHandle(t))})),this.resizing=new de(this)),i=null},_draggable:function(){var e=this.options.draggable;this.dragging&&(this.dragging.destroy(),this.dragging=null),e&&(this.dragging=new ue(this,e.dragHandle||b,e.clickMoveClick))},_actions:function(){var t,r=this.options,o=r.actions,a=r.pinned,s=this.wrapper.children(b).find(".k-window-titlebar-actions"),l=["minimize","maximize"],c={maximize:"window",refresh:"arrow-rotate-cw",custom:"gear"};o=e.map(o,(function(e){return e=a&&"pin"===e.toLowerCase()?"unpin":e,t=c[e.toLowerCase()]||"",{name:l.indexOf(e.toLowerCase())>-1?"window-"+e:e,icon:"close"==e.toLowerCase()?"x":t}})),s.html(i.render(n.action,o))},setOptions:function(t){var n=this,o=n.options.size,a=this.containment&&!n._isPinned?this.containment:e(document),s=JSON.parse(JSON.stringify(t));n.wrapper.removeClass(i.getValidCssClass("k-window-","themeColor",n.options.themeColor)),u(t.position,n.options.position),u(t.position,s.position),n._containerScrollTop=a.scrollTop(),n._containerScrollLeft=a.scrollLeft(),r.fn.setOptions.call(n,t);var l=!1!==n.options.scrollable;if(n.restore(),void 0!==t.title&&n.title(t.title),n.wrapper.removeClass(ie[o]),n._dimensions(),n._position(),n._resizable(),n._draggable(),n._actions(),n.options.themeColor&&"none"!==n.options.themeColor&&n.wrapper.addClass(i.getValidCssClass("k-window-","themeColor",n.options.themeColor)),void 0!==t.modal){var c=!1!==n.options.visible;n._enableDocumentScrolling(),n._overlay(t.modal&&c)}n.element.css(j,l?"":"hidden")},events:[H,F,R,L,"minimize","maximize",B,U,O,"resize",V,N,$,"kendoKeydown",W],options:{name:"Window",animation:{open:{effects:{zoom:{direction:"in"},fade:{direction:"in"}},duration:350},close:{effects:{zoom:{direction:"out",properties:{scale:.7}},fade:{direction:"out"}},duration:350,hide:!0}},title:"",themeColor:"",actions:["Close"],autoFocus:!0,modal:!1,size:"auto",resizable:!0,draggable:!0,minWidth:90,minHeight:50,maxWidth:1/0,maxHeight:1/0,pinned:!1,scrollable:!0,position:{},content:null,visible:null,height:null,width:null,appendTo:"body",isMaximized:!1,isMinimized:!1},_closable:function(){return e.inArray("close",e.map(this.options.actions,(function(e){return e.toLowerCase()})))>-1},_keydownContent:function(e){var t=i.keys;e.keyCode==t.ESC&&this._closable()&&(e.stopPropagation(),this._close(!1))},_keydown:function(e){var t,n,r,o,a,s,l=this,c=l.options,d=i.keys,u=e.keyCode,h=l.wrapper,p=10,f=c.isMaximized,m=c.isMinimized;u==d.ESC&&l._closable()&&(e.stopPropagation(),l._close(!1)),e.target!=e.currentTarget||l._closing||(e.altKey&&82==u&&l.refresh(),e.altKey&&80==u&&(l.options.pinned?l.unpin():l.pin()),e.altKey&&u==d.UP?m?(l.restore(),l.wrapper.trigger("focus")):f||(l.maximize(),l.wrapper.trigger("focus")):e.altKey&&u==d.DOWN&&(m||f?f&&(l.restore(),l.wrapper.trigger("focus")):(l.minimize(),l.wrapper.trigger("focus"))),t=i.getOffset(h),l.containment&&!l._isPinned&&(t=l.options.position),!c.draggable||e.ctrlKey||e.altKey||f||(l._updateBoundaries(),u==d.UP?(t.top=ae(t.top-p,l.minTop,l.maxTop),n=h.css("top",t.top)):u==d.DOWN?(t.top=ae(t.top+p,l.minTop,l.maxTop),n=h.css("top",t.top)):u==d.LEFT?(t.left=ae(t.left-p,l.minLeft,l.maxLeft),n=h.css("left",t.left)):u==d.RIGHT&&(t.left=ae(t.left+p,l.minLeft,l.maxLeft),n=h.css("left",t.left))),c.resizable&&e.ctrlKey&&!f&&!m&&(u==d.UP?(n=!0,o=h.outerHeight()-p):u==d.DOWN?(n=!0,o=l.containment&&!l._isPinned?Math.min(h.outerHeight()+p,l.containment.height-t.top-oe(h,"padding-top")-oe(h,"borderBottomWidth")-oe(h,"borderTopWidth")):h.outerHeight()+p):u==d.LEFT?(n=!0,r=h.outerWidth()-p):u==d.RIGHT&&(n=!0,r=l.containment&&!l._isPinned?Math.min(h.outerWidth()+p,l.containment.width-t.left-oe(h,"borderLeftWidth")-oe(h,"borderRightWidth")):h.outerWidth()+p),n&&(a=ae(r,c.minWidth,c.maxWidth),s=ae(o,c.minHeight,c.maxHeight),isNaN(a)||(h.outerWidth(a),l.options.width=a+"px"),isNaN(s)||(h.outerHeight(s),l.options.height=s+"px"),l.resize())),n&&e.preventDefault())},_overlay:function(t){var n=this.containment?this.containment.children(k):this.appendTo.children(k),i=this.wrapper,r=t?"inline-flex":"none",o=parseInt(i.css(G),10)-1;return n.length||(n=e("<div class='k-overlay' />")),n.insertBefore(i[0]).css({zIndex:o,display:r}),this.options.modal.preventScroll&&!this.containment&&this._stopDocumentScrolling(),n},_actionForIcon:function(e){return{x:"_close",window:"maximize","window-minimize":"minimize","window-restore":"restore","arrow-rotate-cw":"refresh",pin:"pin",unpin:"unpin"}[/\bk(-svg)?-i(-\w+)+\b/.exec(e[0].className)[0].replace(/(k-i-|k-svg-i-)/,"")]},_windowActionHandler:function(t){if(!this._closing){var n=e(t.target).closest(".k-window-titlebar-action").find(".k-icon,.k-svg-icon"),i=this._actionForIcon(n);return i?(t.preventDefault(),this[i](),!1):void 0}},_modals:function(){for(var t,n=this,i=e(v+E),r=[],o=0;o<i.length;o+=1)(t=n._object(e(i[o])))&&t.options&&t.options.modal&&t.options.visible&&t.options.appendTo===n.options.appendTo&&(!t.containment||n.containment&&t.containment[0]===n.containment[0])&&r.push(t.wrapper[0]);return r.sort((function(e,t){return e.style.zIndex-t.style.zIndex})),n=null,e(r)},_object:function(e){var n=e.children(y).getKendoWindow();return n||t},center:function(){var t,n,i=this,r=i.options.position,o=i.wrapper,a=e(window),s=0,l=0;return i.options.isMaximized||(i.options.pinned&&!i._isPinned&&i.pin(),i.options.pinned||(s=a.scrollTop(),l=a.scrollLeft()),this.containment&&!i.options.pinned?(t=this.minTop+(this.maxTop-this.minTop)/2,n=this.minLeft+(this.maxLeft-this.minLeft)/2):(i._scrollIsAppended=!0,n=l+Math.max(0,(a.width()-o.outerWidth())/2),t=s+Math.max(0,(a.height()-o.outerHeight()-oe(o,"paddingTop"))/2)),o.css({left:n,top:t}),r.top=t,r.left=n),i},title:function(t){var r,o=this,a=!0,s=o.wrapper,l=s.children(b),c=l.children(_);return arguments.length?(e.isPlainObject(t)?(r=void 0!==t.text?t.text:"",a=!1!==t.encoded):r=t,!1===r?(s.addClass("k-window-titleless"),s.css("padding-top",0),l.remove()):l.length?c.html(a?i.htmlEncode(r):r):(s.prepend(n.titlebar({title:a?i.htmlEncode(r):r})),o._actions(),l=s.children(b)),o.options.title=r,o):c.html()},content:function(e,t){var n=this.wrapper.children(y),r=n.children(".km-scroll-container");return n=r[0]?r:n,re(e)?(i.destroy(this.element.children()),n.empty().html(e),this):n.html()},open:function(){var t,n,r=this,o=r.wrapper,a=r.options,s=this._animationOptions("open"),l=o.children(y),c=this.containment&&!r._isPinned?this.containment:e(document);if(!r.trigger(H)){if(r._closing&&o.kendoStop(!0,!0),r._closing=!1,r.toFront(),a.autoFocus&&r.wrapper.trigger("focus"),a.visible=!0,a.modal){if(n=!!r._modals().length,(t=r._overlay(n)).kendoStop(!0,!0),s.duration&&i.effects.Fade&&!n){var d=i.fx(t).fadeIn();d.duration(s.duration||0),d.endValue(.5),d.play()}else t.css("opacity",.5);t.show(),e(window).on("focus"+g,(function(){o.data("isFront")&&!e(document.activeElement).closest(o).length&&r.wrapper.trigger("focus")}))}o.is(E)||(l.css(j,z),r.wrapper.find(Z).addClass("k-button-flat"),o.css({display:"inline-flex"}),o.kendoStop().kendoAnimate({effects:s.effects,duration:s.duration,complete:this._activate.bind(this)}))}return a.isMaximized&&(r._containerScrollTop=c.scrollTop(),r._containerScrollLeft=c.scrollLeft(),r._stopDocumentScrolling()),this.options.pinned&&!this._isPinned&&this.pin(),r},_activate:function(){var e=!1!==this.options.scrollable;this.options.autoFocus&&this.wrapper.trigger("focus"),this.element.css(j,e?"":"hidden"),i.resize(this.element.children()),this.trigger(F)},_removeOverlay:function(n){var r=this._modals(),o=this.options,a=o.modal&&!r.length,s=this._animationOptions("close");if(a){if(!n&&s.duration&&i.effects.Fade){var l=i.fx(o.modal?this._overlay(!0):e(t)).fadeOut();l.duration(s.duration||0),l.startValue(.5),l.play()}else this._overlay(!1).remove();o.modal.preventScroll&&this._enableDocumentScrolling()}else r.length&&(this._object(r.last())._overlay(!0),o.modal.preventScroll&&this._stopDocumentScrolling())},_close:function(t){var n,i=this,r=i.wrapper,o=i.options,a=this._animationOptions("open"),s=this._animationOptions("close"),l=this.containment&&!i._isPinned?this.containment:e(document);i._closing||(n=i.trigger(L,{userTriggered:!t}),i._closing=!n,r.is(E)&&!n&&(o.visible=!1,e(v).each((function(t,n){var i=e(n).children(y);n!=r&&i.find("> ."+C).length>0&&i.children(k).remove()})),this._removeOverlay(),i.wrapper.find(Z).removeClass("k-button-flat"),r.kendoStop().kendoAnimate({effects:s.effects||a.effects,reverse:!0===s.reverse,duration:s.duration,complete:this._deactivate.bind(this)}),e(window).off(g)),i.options.isMaximized&&(i._enableDocumentScrolling(),i._containerScrollTop&&i._containerScrollTop>0&&l.scrollTop(i._containerScrollTop),i._containerScrollLeft&&i._containerScrollLeft>0&&l.scrollLeft(i._containerScrollLeft)),i.options.iframe&&i.wrapper.trigger("blur"))},_deactivate:function(){var e=this;if(e.wrapper.removeClass(M).hide().css("opacity",""),e.trigger(R),e.options.modal){var t=e._object(e._modals().last());t&&t.toFront()}},close:function(){return this._close(!0),this},_actionable:function(t){return e(t).is(`${Z}, :input, a, .k-input, .k-icon, .k-svg-icon, .k-svg-icon>svg, .k-svg-icon>svg>path, .k-icon-button, [role='gridcell'], .k-input-inner, .k-input-value-text`)},_shouldFocus:function(t){var n=l(),i=this.wrapper;return this.options.autoFocus&&!e(n).is(i)&&!this._actionable(t)&&(!i.find(n).length||!i.find(t).length)},toFront:function(t,i){var r=this,o=r.wrapper,a=o[0],s=r.containment&&!r._isPinned,l=this._animationOptions("open"),c=+o.css(G),d=c,u=t&&t.target||null;if(e(v).each((function(t,i){var r=e(i),s=r.css(G),l=r.children(y);isNaN(s)||(c=Math.max(+s,c)),o.data("isFront",i==a),i!=a&&l.find("."+C).length&&!l.find(k).length&&l.append(n.overlay)})),(!o[0].style.zIndex||d<c)&&o.css(G,c+2),r.element.find("> .k-overlay").remove(),r._shouldFocus(u)){i||setTimeout((function(){r.wrapper.trigger("focus")}),l?l.duration:0);var h=s?r.containment.scrollTop():e(window).scrollTop(),p=parseInt(o.position().top,10);!r.options.pinned&&p>0&&p<h&&(h>0?e(window).scrollTop(p):o.css("top",h))}return o=null,r},toggleMaximization:function(){return this._closing?this:this[this.options.isMaximized?"restore":"maximize"]()},restore:function(){var t=this,n=t.options,i=n.minHeight,r=t.restoreOptions,o=t.containment&&!t._isPinned?t.containment:e(document);return n.isMaximized||n.isMinimized?(i&&i!=1/0&&t.wrapper.css("min-height",i),r&&!n.isMaximized&&(r.height=ae(r.height,t.options.minHeight,t.options.maxHeight),n.position.top+parseInt(r.height,10)>t.maxTop&&(n.position.top=ae(n.position.top,t.minTop,t.maxTop-parseInt(r.height,10)),u(r,{left:n.position.left,top:n.position.top}))),t.wrapper.css({position:n.pinned?"fixed":"absolute",left:r.left,top:r.top,width:r.width,height:r.height}).removeClass(A).removeClass(x).find(".k-window-content,.k-resize-handle").show().end().find(".k-window-titlebar .k-i-window-restore,.k-window-titlebar .k-svg-i-window-restore").parent().remove().end().end().find(K).parent().show().end().end().find(X).parent().show(),n.isMaximized?t.wrapper.find(".k-i-window,.k-svg-i-window").parent().trigger("focus"):n.isMinimized&&t.wrapper.find(".k-i-window-minimize,.k-svg-i-window-minimize").parent().trigger("focus"),t.options.width=r.width,t.options.height=r.height,t.options.modal.preventScroll||t._enableDocumentScrolling(),t._containerScrollTop&&t._containerScrollTop>0&&o.scrollTop(t._containerScrollTop),t._containerScrollLeft&&t._containerScrollLeft>0&&o.scrollLeft(t._containerScrollLeft),n.isMaximized=n.isMinimized=!1,t.wrapper.removeAttr("aria-labelled-by"),t.resize(),t.trigger(U),t):t},_sizingAction:function(e,t){var i=this,r=i.wrapper,o=r[0].style,a=i.options;return a.isMaximized||a.isMinimized||(i.restoreOptions={width:o.width,height:o.height},r.children(w).hide().end().children(b).find(K).parent().hide().eq(0).before(n.action({name:"window-restore"})),t.call(i),i.wrapper.children(b).find(X).parent().toggle("maximize"!==e),i.trigger(e),r.find(".k-i-window-restore,.k-svg-i-window-restore").parent().trigger("focus")),i},maximize:function(){return this._sizingAction("maximize",(function(){var t=this,n=t.wrapper,i=this.containment&&!t._isPinned,r=n.position(),o=e(document);u(t.restoreOptions,{left:r.left+(i?this.containment.scrollLeft():0),top:r.top+(i?this.containment.scrollTop():0)}),this._containerScrollTop=i?this.containment.scrollTop():o.scrollTop(),this._containerScrollLeft=i?this.containment.scrollLeft():o.scrollLeft(),t._stopDocumentScrolling(),n.css({top:i?this.containment.scrollTop():0,left:i?this.containment.scrollLeft():0,position:i?"absolute":"fixed"}).addClass(A),t.options.isMaximized=!0,t._onDocumentResize()})),this},_stopDocumentScrolling:function(){var t=this,n=t.containment;if(n&&!t._isPinned)return t._storeOverflowRule(n),n.css(j,z),void t.wrapper.css({maxWidth:n.innerWidth(),maxHeight:n.innerHeight()});var i=e("body");t._storeOverflowRule(i),i.css(j,z);var r=e("html");t._storeOverflowRule(r),r.css(j,z)},_enableDocumentScrolling:function(){var t=this,n=t.containment;if(n&&!t._isPinned)return t._restoreOverflowRule(n),void t.wrapper.css({maxWidth:n.width,maxHeight:n.height});t._restoreOverflowRule(e(document.body)),t._restoreOverflowRule(e("html"))},_storeOverflowRule:function(e){if(!this._isOverflowStored(e)){var t=e.get(0).style.overflow;"string"==typeof t&&e.data(q,t)}},_isOverflowStored:function(e){return"string"==typeof e.data(q)},_restoreOverflowRule:function(e){var n=e.data(q);null!==n&&n!==t?(e.css(j,n),e.removeData(q)):e.css(j,"")},isMaximized:function(){return this.options.isMaximized},minimize:function(){return this._sizingAction("minimize",(function(){var e=this;e.wrapper.css({height:"",minHeight:""}),e.element.hide(),e.options.isMinimized=!0})),this.wrapper.attr("aria-labelled-by",this.element.attr("aria-labelled-by")),this.wrapper.addClass(x),this._updateBoundaries(),this},isMinimized:function(){return this.options.isMinimized},pin:function(){var t=this,n=e(window),r=t.wrapper,o=t.options,a=o.position,s=this.containment?le(r[0]).top+oe(this.containment,"borderTopWidth"):oe(r,"top"),l=this.containment?le(r[0]).left+oe(this.containment,"borderLeftWidth"):oe(r,"left");if(!t.options.isMaximized){a.top=s,a.left=l,!t._scrollIsAppended||this.containment&&"fixed"===this.containment.css("position")||(a.top-=n.scrollTop(),a.left-=n.scrollLeft(),t._scrollIsAppended=!1),r.css(u(a,{position:"fixed"}));var c=r.children(b).find(Y).eq(0);c.length>0&&i.ui.icon(c,{icon:"unpin"}),t._isPinned=!0,t.options.pinned=!0,this.containment&&(o.maxWidth=o.maxHeight=1/0,r.css({maxWidth:"",maxHeight:""}))}},unpin:function(){var t=this,n=e(window),r=t.wrapper,o=t.options,a=t.options.position,s=t.containment,l=parseInt(r.css("top"),10)+n.scrollTop(),c=parseInt(r.css("left"),10)+n.scrollLeft();if(!t.options.isMaximized){t._isPinned=!1,t._scrollIsAppended=!0,t.options.pinned=!1,s&&(t._updateBoundaries(),o.maxWidth=Math.min(s.width,o.maxWidth),o.maxHeight=Math.min(s.height-oe(r,"padding-top"),o.maxHeight),r.css({maxWidth:o.maxWidth,maxHeight:o.maxHeight}),l=l<s.position.top?t.minTop:l>s.position.top+s.height?t.maxTop:l+s.scrollTop()-(s.position.top+oe(s,"border-top-width")),c=c<s.position.left?t.minLeft:c>s.position.left+s.width?t.maxLeft:c+s.scrollLeft()-(s.position.left+oe(s,"border-left-width"))),a.top=ae(l,t.minTop,t.maxTop),a.left=ae(c,t.minLeft,t.maxLeft),r.css(u(a,{position:""}));var d=r.children(b).find(Q).eq(0);d.length>0&&i.ui.icon(d,{icon:"pin"})}},_onDocumentResize:function(){var t,n,r=this,o=r.wrapper,a=e(window),s=i.support.zoomLevel(),l="content-box"==o.css("box-sizing");if(r.options.isMaximized){var c=l?oe(o,"border-left-width")+oe(o,"border-right-width"):0,d=l?oe(o,"border-top-width")+oe(o,"border-bottom-width"):0,u=l?oe(o,"padding-top"):0;r.containment&&!r._isPinned?(t=r.containment.innerWidth()-c,n=r.containment.innerHeight()-(d+u)):(t=a.width()/s-c,n=a.height()/s-(d+u)),o.css({width:t,height:n}),r.options.width=t,r.options.height=n,r.resize()}},refresh:function(t){var i,r,o,a=this,l=a.options,c=e(a.element);return s(t)||(t={url:t}),t=u(l.content,t),r=re(l.iframe)?l.iframe:t.iframe,(o=t.url)?(re(r)||(r=!ne(o)),r?((i=c.find("."+C)[0])?i.src=o||i.src:c.html(n.contentFrame(u({},l,{content:t}))),c.find("."+C).off("load"+m).on("load"+m,this._triggerRefresh.bind(this))):a._ajaxRequest(t)):(t.template&&a.content(p(t.template)({})),a.trigger(B)),c.toggleClass("k-window-iframecontent",!!r),a},_triggerRefresh:function(){this.trigger(B)},_ajaxComplete:function(){clearTimeout(this._loadingIconTimeout),this.wrapper.find(J).removeClass(S)},_ajaxError:function(e,t){this.trigger(W,{status:t,xhr:e})},_ajaxSuccess:function(e){return function(t){var n=t;e&&(n=p(e)(t||{})),this.content(n,t),this.element.prop("scrollTop",0),this.trigger(B)}},_showLoading:function(){this.wrapper.find(J).addClass(S)},_ajaxRequest:function(t){this._loadingIconTimeout=setTimeout(this._showLoading.bind(this),100),e.ajax(u({type:"GET",dataType:"html",cache:!1,error:this._ajaxError.bind(this),complete:this._ajaxComplete.bind(this),success:this._ajaxSuccess(t.template).bind(this)},t))},_destroy:function(){this.resizing&&this.resizing.destroy(),this.dragging&&this.dragging.destroy(),this.wrapper.off(m).children(y).off(m).end().find(".k-resize-handle,.k-window-titlebar").off(m),e(window).off("resize"+m+this._marker),e(window).off(g),e(window).off(m),clearTimeout(this._loadingIconTimeout),r.fn.destroy.call(this),this.unbind(t),i.destroy(this.wrapper)},destroy:function(){this._destroy(),this.options.modal&&this._removeOverlay(!0),this.wrapper.empty().remove(),this.wrapper=this.appendTo=this.element=e()},_createWindow:function(){var t,r,o=this.element,a=this.options,s=i.support.isRtl(o);!1===a.scrollable&&o.css("overflow","hidden"),r=e(n.wrapper(a)),t=o.find("iframe:not(.k-content-frame)").map((function(){var e=this.getAttribute("src");return this.src="",e})),r.toggleClass("k-rtl",s).attr("tabindex",0).append(o).find("iframe:not(.k-content-frame)").each((function(e){this.src=t[e]})),this.containment?this.containment.prepend(r):this.appendTo&&r.appendTo(this.appendTo),r.find(".k-window-title").css(s?"left":"right",c(r.find(".k-window-titlebar-actions"))+10),o.css("visibility","").show(),e(o).hasClass(I)&&e(o).removeClass(I),o.find("[data-role=editor]").each((function(){var t=e(this).data("kendoEditor");t&&t.refresh()})),r=o=null}});function de(e){var t=this;t.owner=e,t._preventDragging=!1,t._draggable=new a(e.wrapper,{filter:">"+w,group:e.wrapper.id+"-resizing",dragstart:t.dragstart.bind(t),drag:t.drag.bind(t),dragend:t.dragend.bind(t)}),t._draggable.userEvents.bind("press",t.addOverlay.bind(t)),t._draggable.userEvents.bind("release",t.removeOverlay.bind(t))}function ue(e,t,n){var i=this;i.owner=e,i._preventDragging=!1,i._draggable=new a(e.wrapper,{filter:t,group:e.wrapper.id+"-moving",clickMoveClick:n,dragstart:i.dragstart.bind(i),drag:i.drag.bind(i),dragend:i.dragend.bind(i),dragcancel:i.dragcancel.bind(i)}),i._draggable.userEvents.stopPropagation=!1}n={wrapper:p((()=>"<div class='k-window'></div>")),action:p((({name:e,icon:t})=>{let n=(t||"").toLowerCase()||e.toLowerCase();return"restore"==n&&(n="window-restore"),i.html.renderButton(`<button role='button' class='k-window-titlebar-action' aria-label='${e}'></button>`,{icon:n,fillMode:"flat"})})),titlebar:p((({title:e})=>`<div class='k-window-titlebar'><span class='k-window-title'>${e}</span><div class='k-window-titlebar-actions'></div></div>`)),overlay:"<div class='k-overlay'></div>",contentFrame:p((({title:e,content:t})=>`<iframe frameborder='0' title='${e}' class='${C}' src='${t.url}'>This page requires frames in order to show content</iframe>`)),resizeHandle:p((e=>`<div aria-hidden='true' class='k-resize-handle k-resize-${e}'></div>`))},de.prototype={addOverlay:function(){this.owner.wrapper.append(n.overlay)},removeOverlay:function(){this.owner.wrapper.find(k).remove()},dragstart:function(t){var n=this,r=n.owner,o=r.wrapper;if(n._preventDragging=r.trigger(O),!n._preventDragging){n.elementPadding=parseInt(o.css("padding-top"),10),n.initialPosition=i.getOffset(o,"position"),n.resizeDirection=t.currentTarget.prop("className").replace("k-resize-handle k-resize-",""),n.initialSize={width:o.outerWidth(),height:o.outerHeight()},r._updateBoundaries(),n.containerOffset=r.containment?r.containment.position:i.getOffset(r.appendTo);var a=o.offsetParent();if(a.is("html"))n.containerOffset.top=n.containerOffset.left=0;else{var s=a.css("margin-top"),l=a.css("margin-left");if(!te.test(s)||!te.test(l)){var c=le(o[0]),d=c.left-n.containerOffset.left-n.initialPosition.left,u=c.top-n.containerOffset.top-n.initialPosition.top;n._relativeElMarginLeft=d>1?d:0,n._relativeElMarginTop=u>1?u:0,n.initialPosition.left+=n._relativeElMarginLeft,n.initialPosition.top+=n._relativeElMarginTop}}o.children(w).not(t.currentTarget).hide(),e(f).css(P,t.currentTarget.css(P))}},drag:function(t){if(!this._preventDragging){var n,r,o,a,s=this,l=s.owner,c=l.wrapper,d=l.options,u=d.position,h=s.resizeDirection,p=s.containerOffset,f=s.initialPosition,m=s.initialSize,g=l.containment&&!l._isPinned,v=i.support.isRtl(l.containment),_=g&&v&&l.containment.innerWidth()>l.containment.width?i.support.scrollbar():0,b=g?{top:l.containment.scrollTop(),left:l.containment.scrollLeft()}:{top:0,left:0},y=Math.max(t.x.location,0),w=Math.max(t.y.location,0);h.indexOf("e")>=0?(n=l.containment&&y-m.width>=l.maxLeft-b.left+p.left+_?l.maxLeft+_-f.left+m.width-b.left:y-f.left-p.left,c.outerWidth(ae(n,d.minWidth,d.maxWidth))):h.indexOf("w")>=0&&(n=ae((a=f.left+m.width+p.left)-y,d.minWidth,d.maxWidth),u.left=a-n-p.left-_-(s._relativeElMarginLeft||0)+b.left,l.containment&&u.left<=l.minLeft&&(u.left=l.minLeft,n=ae(a-_-u.left-p.left+b.left,d.minWidth,d.maxWidth)),c.css({left:u.left,width:n}));var k=w;l.options.pinned&&(k-=e(window).scrollTop()),h.indexOf("s")>=0?(r=k-f.top-s.elementPadding-p.top,k-m.height-s.elementPadding>=l.maxTop+p.top-b.top&&(r=l.maxTop-f.top+m.height-b.top),c.outerHeight(ae(r,d.minHeight,d.maxHeight))):h.indexOf("n")>=0&&(r=ae((o=f.top+m.height+p.top)-k,d.minHeight,d.maxHeight),u.top=o-r-p.top-(s._relativeElMarginTop||0)+b.top,u.top<=l.minTop&&l.containment&&(u.top=l.minTop,r=ae(o-u.top-p.top+b.top,d.minHeight,d.maxHeight)),c.css({top:u.top,height:r})),n&&(l.options.width=n+"px"),r&&(l.options.height=r+"px"),l.resize()}},dragend:function(t){if(!this._preventDragging){var n=this,i=n.owner,r=i.wrapper;return r.children(w).not(t.currentTarget).show(),e(f).css(P,""),i.touchScroller&&i.touchScroller.reset(),27==t.keyCode&&r.css(n.initialPosition).css(n.initialSize),i.trigger(V),!1}},destroy:function(){this._draggable&&this._draggable.destroy(),this._draggable=this.owner=null}},ue.prototype={dragstart:function(t){var r=this.owner,o=r.options.draggable,a=r.element,s=a.find(".k-window-titlebar-actions"),l=i.getOffset(r.appendTo);this._preventDragging=r.trigger(N)||!o,this._preventDragging||r.isMaximized()||(r.initialWindowPosition=i.getOffset(r.wrapper,"position"),r.initialPointerPosition||(r.options.position.left=ae(r.initialWindowPosition.left,r.minLeft,r.maxLeft),r.options.position.top=ae(r.initialWindowPosition.top,r.minTop,r.maxTop)),r.initialPointerPosition={left:r.options.position.left,top:r.options.position.top},r.startPosition={left:t.x.client-r.initialWindowPosition.left,top:t.y.client-r.initialWindowPosition.top},r._updateBoundaries(),r.containment||(s.length>0?r.minLeft=c(s)+parseInt(s.css("right"),10)-c(a):r.minLeft=20-c(a),r.minLeft-=l.left,r.minTop=-l.top),e(n.overlay).appendTo(r.wrapper).css({opacity:0}),r.wrapper.children(w).hide(),e(f).css(P,t.currentTarget.css(P)))},drag:function(t){var n,i,r=this.owner,o=r.options.position,a=r.options.draggable.axis;this._preventDragging||r.isMaximized()||(a&&"x"!==a.toLowerCase()||(n=t.x.client-r.startPosition.left,r.containment&&!r._isPinned&&(n+=r.containment.scrollLeft()),o.left=ae(n,r.minLeft,r.maxLeft)),a&&"y"!==a.toLowerCase()||(i=t.y.client-r.startPosition.top,r.containment&&!r._isPinned&&(i+=r.containment.scrollTop()),o.top=ae(i,r.minTop,r.maxTop)),e(r.wrapper).css("transform","translate("+(o.left-r.initialPointerPosition.left)+"px, "+(o.top-r.initialPointerPosition.top)+"px)"))},_finishDrag:function(){var t=this.owner;t.wrapper.children(w).toggle(!t.options.isMinimized).end().find(k).remove(),e(f).css(P,"")},dragcancel:function(e){this._preventDragging||(this._finishDrag(),e.currentTarget.closest(v).css(this.owner.initialWindowPosition))},dragend:function(){var t=this.owner;if(!this._preventDragging&&!t.isMaximized())return e(t.wrapper).css(t.options.position).css("transform",""),this._finishDrag(),t.trigger($),!1},destroy:function(){this._draggable&&this._draggable.destroy(),this._draggable=this.owner=null}},i.ui.plugin(ce)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=n.data.DataSource,o=i.Widget,a="change",s="boolean",l="enums",c="string",d="Is equal to",u="Is not equal to",h=["isnull","isnotnull","isempty","isnotempty","isnullorempty","isnotnullorempty"];function p(t){var n="string"==typeof t?t:t.operator;return e.inArray(n,h)>-1}function f(t,n){var i=[];if(e.isPlainObject(t))if(t.hasOwnProperty("filters"))i=t.filters;else if(t.field==n)return t;Array.isArray(t)&&(i=t);for(var r=0;r<i.length;r++){var o=f(i[r],n);if(o)return o}}function m(t,n){t.filters&&(t.filters=e.grep(t.filters,(function(e){return m(e,n),e.filters?e.filters.length:e.field!=n})))}var g=o.extend({init:function(i,r){i=e(i).addClass("k-filtercell");var d,u,h,f,m=this.wrapper=e("<div />").addClass("k-filtercell-wrapper").appendTo(i),g=this,v=r,_=g.operators=r.operators||{},b=g.input=e("<input/>").attr(n.attr("bind"),"value: value").appendTo(m),y=r?r.suggestDataSource:null;y&&(r=e.extend({},r,{suggestDataSource:{}})),o.fn.init.call(g,i[0],r),y&&(g.options.suggestDataSource=y),r=g.options,d=g.dataSource=r.dataSource,g.model=d.reader.model,f=r.type=c;var w=(n.getter("reader.model.fields",!0)(d)||{})[r.field];if(w&&w.type&&(f=r.type=w.type),r.values&&(r.type=f=l),_=_[f]||r.operators[f],!v.operator)for(h in _){r.operator=h;break}if(g._parse=function(e){return null!=e?e+"":e},g.model&&g.model.fields){var k=g.model.fields[r.field];k&&k.parse&&(g._parse=k.parse.bind(k))}g.defaultOperator=r.operator,g.viewModel=u=n.observable({operator:r.operator,value:null,operatorVisible:function(){var e=this.get("value");return null!==e&&e!==t&&"undefined"!=e||p(this.get("operator"))&&g.dataSource.filter()&&!g._clearInProgress}}),g._prevOperator=r.operator,u.bind(a,g.updateDsFilter.bind(g)),f==c&&g.initSuggestDataSource(r),null!==r.inputWidth&&(b.addClass("k-sized-input"),b.width(r.inputWidth)),b.attr("aria-label",g._getColumnTitle()),b.attr("title",g._getColumnTitle()),b.attr(n.attr("size"),g.options.size||"medium"),g._setInputType(r,f),f!=s&&!1!==r.showOperators?g._createOperatorDropDown(_):(e('<div unselectable="on" />').css("display","none").text("eq").appendTo(m),m.addClass("k-operator-hidden")),g._createClearIcon(),n.bind(this.wrapper,u),f==c&&(r.template||g.setAutoCompleteSource()),f==l&&g.setComboBoxSource(g.options.values),g._refreshUI(),g._refreshHandler=g._refreshUI.bind(g),g.dataSource.bind(a,g._refreshHandler)},_setInputType:function(t,i){var r=this,o=r.input;if("function"==typeof t.template)t.template.call(r.viewModel,{element:r.input,dataSource:r.suggestDataSource});else if(i==c)o.attr(n.attr("role"),"autocomplete").attr(n.attr("text-field"),t.dataTextField||t.field).attr(n.attr("filter"),t.suggestionOperator).attr(n.attr("delay"),t.delay).attr(n.attr("min-length"),t.minLength).attr(n.attr("value-primitive"),!0);else if("date"==i)o.attr(n.attr("role"),"datepicker").attr("id",n.guid());else if(i==s){o.remove();var a=e("<input type='radio'/>"),d=r.wrapper,u=n.guid(),h=e("<label/>").text(n.htmlEncode(t.messages.isTrue)).append(a);a.attr(n.attr("bind"),"checked:value").attr("name",u).val("true");var p=h.clone().text(n.htmlEncode(t.messages.isFalse));a.clone().val("false").appendTo(p),d.append([h,p])}else"number"==i?o.attr(n.attr("role"),"numerictextbox").attr("title",r._getColumnTitle()):i==l&&o.attr(n.attr("role"),"combobox").attr(n.attr("text-field"),"text").attr(n.attr("suggest"),!0).attr(n.attr("filter"),"contains").attr(n.attr("value-field"),"value").attr(n.attr("value-primitive"),!0)},_getColumnTitle:function(){var e=this.options.column;return e?e.title||e.field:""},_createOperatorDropDown:function(t){var i,r=[],o=this.viewModel;for(var a in t)r.push({text:t[a],value:a});this.filterCellOperatorWrapper=e("<div class='k-filtercell-operator'>");var s=e('<input class="k-dropdown-operator" '+n.attr("bind")+'="value: operator"/>');s.attr("aria-label",this._getColumnTitle()),s.appendTo(this.filterCellOperatorWrapper),this.filterCellOperatorWrapper.append("&nbsp;"),this.filterCellOperatorWrapper.appendTo(this.wrapper),this.operatorDropDown=s.kendoDropDownList({dataSource:r,size:this.options.size||"medium",dataTextField:"text",dataValueField:"value",open:function(){this.popup.element.width(150)},valuePrimitive:!0}).data("kendoDropDownList"),o.bind("change",(function(){var e=t[o.operator];s.attr("aria-label",e)})),i=this.operatorDropDown.wrapper.attr("aria-label",this._getColumnTitle()).find('span[class*="i-caret-alt-down"]'),n.ui.icon(i,{icon:"filter"})},initSuggestDataSource:function(e){var i=e.suggestDataSource;i instanceof r||(!e.customDataSource&&i&&(i.group=t,i.filter=t),i=this.suggestDataSource=r.create(i)),e.customDataSource||(i._pageSize=t,i.reader.data=function(e,t){var i=n.getter(t,!0);return function(t){for(var n=e(t),r=[],o=0,a={};o<n.length;){var s=n[o++],l=i(s);a.hasOwnProperty(l)||(r.push(s),a[l]=!0)}return r}}(i.reader.data,this.options.field)),this.suggestDataSource=i},setAutoCompleteSource:function(){var e=this.input.data("kendoAutoComplete");e&&e.setDataSource(this.suggestDataSource)},setComboBoxSource:function(e){var t=r.create({data:e}),n=this.input.data("kendoComboBox");n&&!this.options.template&&n.setDataSource(t)},_refreshUI:function(){var t=this,n=f(t.dataSource.filter(),this.options.field)||{},i=t.viewModel;t.manuallyUpdatingVM=!0,n=e.extend(!0,{},n),t.options.type==s&&i.value!==n.value&&t.wrapper.find(":radio").prop("checked",!1),n.operator&&i.set("operator",n.operator),i.set("value",n.value),e.isEmptyObject(n)&&i.trigger(a,{field:"operatorVisible"}),t.manuallyUpdatingVM=!1},_applyFilter:function(e){e.filters.length?this.dataSource.filter(e):this.dataSource.filter({})},updateDsFilter:function(n){var i,r=this,o=r.viewModel;if("operator"==n.field&&o.value===t&&!p(o)&&p(r._prevOperator))return m(i=r.dataSource.filter()||{filters:[],logic:"and"},r.options.field),r._prevOperator=o.operator,void r._applyFilter(i);if(!(r.manuallyUpdatingVM||"operator"==n.field&&o.value===t&&!p(o)||"operator"==n.field&&r._clearInProgress&&null!==o.value)){var s=e.extend({},r.viewModel.toJSON(),{field:r.options.field});r._prevOperator=s.operator;var l={logic:"and",filters:[]},c=!1;if((s.value!==t&&null!==s.value||p(s)&&!this._clearInProgress)&&(l.filters.push(s),c=r.trigger(a,{filter:l,field:r.options.field})),(r._clearInProgress||null===s.value)&&(c=r.trigger(a,{filter:null,field:r.options.field})),!c){var d=r._merge(l);r._applyFilter(d)}}},_merge:function(t){var n,i,r,o=this,a=t.logic||"and",s=t.filters,l=o.dataSource.filter()||{filters:[],logic:"and"};for(m(l,o.options.field),i=0,r=s.length;i<r;i++)(n=s[i]).value=o._parse(n.value);return s=e.grep(s,(function(e){return""!==e.value&&null!==e.value||p(e)})),s.length&&(l.filters.length?(t.filters=s,"and"!==l.logic&&(l.filters=[{logic:l.logic,filters:l.filters}],l.logic="and"),s.length>1?l.filters.push(t):l.filters.push(s[0])):(l.filters=s,l.logic=a)),l},_createClearIcon:function(){var t=this,i=n.getValidCssClass("k-button-","size",this.options.size||"medium"),r=n.htmlEncode(t.options.messages.clear);t.filterCellOperatorWrapper&&t.filterCellOperatorWrapper.length>0||(t.filterCellOperatorWrapper=e("<div class='k-filtercell-operator'>").appendTo(t.wrapper)),e(`<button type='button' class='k-button ${i} k-rounded-md k-button-solid k-button-solid-base k-icon-button' title = '`+r+"'/>").attr("aria-label",r).attr(n.attr("bind"),"visible:operatorVisible").html(n.ui.icon({icon:"filter-clear",iconClass:"k-button-icon"})).on("click",t.clearFilter.bind(t)).appendTo(t.filterCellOperatorWrapper)},clearFilter:function(){this._clearInProgress=!0,p(this.viewModel.operator)&&this.viewModel.set("operator",this.defaultOperator),this.viewModel.set("value",null),this._clearInProgress=!1},destroy:function(){var e=this;e.filterModel=null,e.operatorDropDown=null,e._refreshHandler&&(e.dataSource.bind(a,e._refreshHandler),e._refreshHandler=null),n.unbind(e.element),o.fn.destroy.call(e),n.destroy(e.element)},events:[a],options:{name:"FilterCell",delay:200,minLength:1,inputWidth:null,values:t,customDataSource:!1,field:"",dataTextField:"",type:"string",suggestDataSource:null,suggestionOperator:"startswith",operator:"eq",showOperators:!0,template:null,messages:{isTrue:"is true",isFalse:"is false",filter:"Filter",clear:"Clear",operator:"Operator"},operators:{string:{eq:d,neq:u,startswith:"Starts with",contains:"Contains",doesnotcontain:"Does not contain",endswith:"Ends with",isnull:"Is null",isnotnull:"Is not null",isempty:"Is empty",isnotempty:"Is not empty",isnullorempty:"Has no value",isnotnullorempty:"Has value"},number:{eq:d,neq:u,gte:"Is greater than or equal to",gt:"Is greater than",lte:"Is less than or equal to",lt:"Is less than",isnull:"Is null",isnotnull:"Is not null"},date:{eq:d,neq:u,gte:"Is after or equal to",gt:"Is after",lte:"Is before or equal to",lt:"Is before",isnull:"Is null",isnotnull:"Is not null"},enums:{eq:d,neq:u,isnull:"Is null",isnotnull:"Is not null"}}}});i.plugin(g)}(window.kendo.jQuery);kendo;kendo.pdf=kendo.pdf||{},kendo.pdf.supportsDeflate=function(){return window.pako&&"function"==typeof window.pako.deflate},kendo.pdf.deflate=function(e){return window.pako.deflate(e)},window.kendo.jQuery,function(e){kendo.PDFMixin={extend:function(e){e.events.push("pdfExport"),e.options.pdf=this.options,e.saveAsPDF=this.saveAsPDF,e._drawPDF=this._drawPDF,e._drawPDFShadow=this._drawPDFShadow},options:{fileName:"Export.pdf",proxyURL:"",paperSize:"auto",allPages:!1,landscape:!1,margin:null,title:null,author:null,subject:null,keywords:null,creator:"Kendo UI PDF Generator v."+kendo.version,date:null},saveAsPDF:function(){var t=new e.Deferred,n=t.promise(),i={promise:n};if(!this.trigger("pdfExport",i)){var r=this.options.pdf;return r.multiPage=r.multiPage||r.allPages,this._drawPDF(t).then((function(e){return kendo.drawing.exportPDF(e,r)})).done((function(e){kendo.saveAs({dataURI:e,fileName:r.fileName,proxyURL:r.proxyURL,forceProxy:r.forceProxy,proxyTarget:r.proxyTarget}),t.resolve()})).fail((function(e){t.reject(e)})),n}},_drawPDF:function(t){var n=new e.Deferred;return kendo.drawing.drawDOM(this.wrapper).done((function(e){var i={page:e,pageNumber:1,progress:1,totalPages:1};t.notify(i),n.resolve(i.page)})).fail((function(e){n.reject(e)})),n},_drawPDFShadow:function(t,n){t=t||{};var i=this.wrapper,r=e("<div class='k-pdf-export-shadow'>");t.width&&r.css({width:t.width,overflow:"visible"}),i.before(r),r.append(t.content||i.clone(!0,!0));var o=e.Deferred();return setTimeout((function(){kendo.drawing.drawDOM(r,n).always((function(){r.remove()})).then((function(){o.resolve.apply(o,arguments)})).fail((function(){o.reject.apply(o,arguments)})).progress((function(){o.progress.apply(o,arguments)}))}),15),o.promise()}}}(window.kendo.jQuery);!function(e,t){var n,i=window.kendo,r=i.ui.Widget,o=i.ui.Popup.TabKeyTrap,a=i.template,s=i.keys,l=i.isFunction,c=i.htmlEncode,d="kendoWindow",u=".k-dialog-wrapper",h=".k-window",p="[data-role='close']",f=".k-window-content",m="k-scroll",g=".k-dialog-title",v=".k-dialog-titlebar",_=".k-dialog-actions",b=".k-button",y=":visible",w="zIndex",k="body",x="initOpen",C="touchstart",S="touchmove",T="open",D="close",A="show",M="hide",E={small:"k-window-sm",medium:"k-window-md",large:"k-window-lg"},I="hidden",z="overflow",P="original-overflow-rule",H="tap-y",F=Math.ceil;function R(e){return void 0!==e}function L(e,t,n){return Math.max(Math.min(parseInt(e,10),n===1/0?n:parseInt(n,10)),parseInt(t,10))}function B(e){return e.keyCode==s.ENTER||e.keyCode==s.SPACEBAR}var O=r.extend({init:function(e,t){var n=this;r.fn.init.call(n,e,t),n._init(n.element,n.options),i.notify(n),n._showWatermarkOverlay&&n._showWatermarkOverlay(n.wrapper[0])},_init:function(i,r){var a,s=this;s._centerCallback=s._center.bind(s),s.appendTo=e(k),R(r.visible)&&null!==r.visible||(r.visible=i.is(y)),s.wrapperTemplate===t&&(s.wrapperTemplate=n.wrapper),s._createDialog(),a=s.wrapper=i.closest(".k-dialog"),s.dialogWrapper=a.closest(u),r._defaultFocus===t&&(s._defaultFocus=i[0]),s._tabindex(i),s._dimensions(),!r.modal&&s._isDialog()&&(s.dialogWrapper.width(s.wrapper.width()),s.dialogWrapper.height(s.wrapper.height()),s.wrapper[0].style.width.indexOf("%")>-1&&(s.wrapper[0].style.width="100%"),s.wrapper[0].style.height.indexOf("%")>-1&&(s.wrapper[0].style.height="100%")),this._tabKeyTrap=new o(a),s.options.visible?s._triggerOpen():s.dialogWrapper.hide()},setOptions:function(n){var o=this,a=o.options.size;o.wrapper.removeClass(i.getValidCssClass("k-dialog-","themeColor",o.options.themeColor)),n=e.extend(o.options,n),r.fn.setOptions.call(o,n),n.title!==t&&o.title(n.title),n.content&&(i.destroy(o.element.children()),o.element.html(n.content)),n.actions&&(o.wrapper.children(_).remove(),o._createActionbar(o.wrapper)),o.dialogWrapper.show(),o._closable(o.wrapper),o.wrapper.removeClass(E[a]),o._dimensions(),n.visible?o._triggerOpen():o.dialogWrapper.hide(),n.themeColor&&"none"!==n.themeColor&&o.wrapper.addClass(i.getValidCssClass("k-dialog-","themeColor",o.options.themeColor)),void 0!==n.modal&&o._enableDocumentScrolling()},_isDialog:function(){return"Dialog"===this.options.name},_dimensions:function(){for(var e=this.wrapper,t=this.options,n=t.width,i=t.height,r=t.size,o=["minWidth","minHeight","maxWidth","maxHeight"],a=0;a<o.length;a++){var s=t[o[a]];s&&s!=1/0&&e.css(o[a],s)}this._setElementMaxHeight(),n&&(n.toString().indexOf("%")>0?e.width(n):e.outerWidth(L(n,t.minWidth,t.maxWidth))),i&&(i.toString().indexOf("%")>0?e.height(i):e.outerHeight(L(i,t.minHeight,t.maxHeight)),this._setElementHeight()),r&&E[r]&&e.addClass(E[r])},_setElementMaxHeight:function(){var e,t=this,n=t.element,i=t.options.maxHeight;i!=1/0&&(e=parseFloat(i,10)-t._uiHeight())>0&&n.css({maxHeight:F(e)+"px"})},_setElementHeight:function(){var e=this,t=e.element,n=e.wrapper.outerHeight(!0),i=parseFloat(n,10)-e._uiHeight();i<0&&(i=0),t.css({height:F(i)+"px"}),this._applyScrollClassName(t)},_applyScrollClassName:function(e){e.get(0).scrollHeight>e.outerHeight()?e.addClass(m):e.removeClass(m)},_uiHeight:function(){var e=this.wrapper,t=e.children(_),n=t[0]&&t[0].offsetHeight||0,i=e.children(v);return n+(i[0]&&i[0].offsetHeight||0)},_closeClick:function(e){e.preventDefault(),this.close(!1)},_closeKeyHandler:function(e){(B(e)||e.keyCode==s.ESC)&&this.close(!1)},_keydown:function(e){var t=this,n=t.options;e.keyCode==s.ESC&&!t._closing&&n.closable&&t.close(!1)},_createDialog:function(){var t=this,r=t.element,o=t.options,a=i.support.isRtl(r),s=e(n.titlebar(o)),l=(r.id||i.guid())+"_title",c=e(t.wrapperTemplate(o));r.addClass("k-window-content k-dialog-content"),t.appendTo.append(c),(c=c.find(".k-dialog")).toggleClass("k-rtl",a),!1!==o.title&&(c.append(s),s.attr("id",l),c.attr("aria-labelledby",l)),t._closable(c),c.append(r),o.themeColor&&"none"!==o.themeColor&&c.addClass(c.addClass(i.getValidCssClass("k-dialog-","themeColor",o.themeColor))),o.content&&(i.destroy(r.children()),r.html(o.content)),o.actions.length&&t._createActionbar(c)},_closable:function(e){var t=this,i=t.options,r=e.children(v).find(".k-window-titlebar-actions");(r.length?r.find(p):e.find(p)).remove(),!1!==i.closable&&(!1!==i.title&&r.length?r.append(n.close(i)):e.prepend(n.close(i)),e.autoApplyNS(d),t.element.autoApplyNS(d),e.find(p).on("click",t._closeClick.bind(t)).on("keydown",t._closeKeyHandler.bind(t)),t.element.on("keydown",t._keydown.bind(t)))},_createActionbar:function(t){var i="stretched"===this.options.buttonLayout?"stretched":"end",r=e(n.actionbar({buttonLayout:i}));this._addButtons(r),t.append(r)},_addButtons:function(t){for(var i,r,o=this,a=o._actionClick.bind(o),s=o._actionKeyHandler.bind(o),l=o.options.actions,c=l.length,u=0;u<c;u++)i=l[u],r=o._mergeTextWithOptions(i),e(n.action(i,r)).autoApplyNS(d).appendTo(t).addClass(i.cssClass).data("action",i.action).on("click",a).on("keydown",s)},_mergeTextWithOptions:function(e){var t=e.text;return l(t)?t(this.options):t||""},_tabindex:function(e){var t=this.wrapper,n=t.find(p),i=t.find(_+" "+b);r.fn._tabindex.call(this,e);var o=e.attr("tabindex");n.attr("tabIndex",o),i.attr("tabIndex",o)},_actionClick:function(e){this.dialogWrapper.is(y)&&this._runActionBtn(e.currentTarget)},_actionKeyHandler:function(e){B(e)?(e.preventDefault(),this._runActionBtn(e.currentTarget)):e.keyCode==s.ESC&&this.close(!1)},_runActionBtn:function(t){var n=this;if(!n._closing){var i=e(t).data("action");l(i)&&!1===i({sender:n})||n.close(!1)}},_triggerOpen:function(){var e=this,t=e.options;e.toFront(),e._triggerInitOpen(),e.trigger(T),t.modal&&(t.modal.preventScroll&&e._stopDocumentScrolling(),e._focusDialog())},open:function(){var e,t=this,n=t.dialogWrapper,r=this._animationOptions(T),o=t.options;if(this._triggerInitOpen(),!t.trigger(T)){if(t._closing&&n.kendoStop(!0,!0),t._closing=!1,t.toFront(),o.visible=!0,o.modal){if(e=t.dialogWrapper.find(".k-overlay"),o.modal.preventScroll&&t._stopDocumentScrolling(),e.kendoStop(!0,!0),r.duration&&i.effects.Fade){var a=i.fx(e).fadeIn();a.duration(r.duration||0),a.endValue(.5),a.play()}t.dialogWrapper.show()}(o.modal?t.wrapper:t.dialogWrapper).show().kendoStop().kendoAnimate({effects:r.effects,duration:r.duration,complete:t._openAnimationEnd.bind(t)}),n.show()}return t},_animationOptions:function(e){var t=this.options.animation;return t&&t[e]||{open:{effects:{}},close:{hide:!0,effects:{}}}[e]},_openAnimationEnd:function(){this.options.modal&&this._focusDialog(),this.trigger(A)},_triggerInitOpen:function(){R(this._initOpenTriggered)||(this._initOpenTriggered=!0,this.trigger(x))},toFront:function(){var t=this,n=t.dialogWrapper,i=+n.css(w),r=i;return t.center(),e(h+","+u).each((function(t,n){var r=e(n).css(w);isNaN(r)||(i=Math.max(+r,i))})),(!n[0].style.zIndex||r<i)&&n.css(w,i+1),n=null,t},close:function(e){return arguments.length||(e=!0),this._close(e),this._stopCenterOnResize(),this},_close:function(e){var t=this,n=t.dialogWrapper,i=t.options,r=this._animationOptions("open"),o=this._animationOptions("close");if(n.is(y)&&!t.trigger(D,{userTriggered:!e})){if(t._closing)return;t._closing=!0,i.visible=!1,this._handleDocumentScrolling(),(i.modal?t.wrapper:t.dialogWrapper).kendoStop().kendoAnimate({effects:o.effects||r.effects,reverse:!0===o.reverse,duration:o.duration,complete:this._closeAnimationEnd.bind(this)})}return t},center:function(){this._center(),this._centerOnResize()},_center:function(){var t=this.dialogWrapper,n=e(window),i=0+Math.max(0,(n.width()-t.width())/2),r=0+Math.max(0,(n.height()-t.height()-parseInt(t.css("paddingTop"),10))/2);return t.css({left:i,top:r}),this},_centerOnResize:function(){this._trackResize||(i.onResize(this._centerCallback),this._trackResize=!0)},_stopCenterOnResize:function(){i.unbindResize(this._centerCallback),this._trackResize=!1},_handleDocumentScrolling:function(){var e=this._modals(),t=this.options;t.modal&&!e.length&&t.modal.preventScroll?this._enableDocumentScrolling():e.length&&t.modal.preventScroll&&this._stopDocumentScrolling()},_stopDocumentScrolling:function(){var t=this,n=e("body");t._storeOverflowRule(n),n.css(z,I);var r=e("html"),o=r[0];t._storeOverflowRule(r),r.css(z,I),i.support.mobileOS.ios&&(o.addEventListener(C,t._touchStart,{passive:!1}),o.addEventListener(S,t._touchMove,{passive:!1}))},_touchStart:function(t){e(this).data(H,t.changedTouches[0].pageY)},_touchMove:function(t){var n=t.target,i=e(t.target),r=t.changedTouches[0].pageY-e(this).data(H)>0,o=i.is(f)&&r&&0===i.scrollTop()||!r&&i.scrollTop()===n.scrollHeight-n.clientHeight;i.is(f)&&!o||t.preventDefault()},_enableDocumentScrolling:function(){var t=this,n=e(document.body),r=e("html"),o=r[0];t._restoreOverflowRule(n),t._restoreOverflowRule(r),i.support.mobileOS.ios&&(r.removeData(H),o.removeEventListener(C,t._touchStart,{passive:!1}),o.removeEventListener(S,t._touchMove,{passive:!1}))},_storeOverflowRule:function(e){if(!this._isOverflowStored(e)){var t=e.get(0).style.overflow;"string"==typeof t&&e.data(P,t)}},_isOverflowStored:function(e){return"string"==typeof e.data(P)},_restoreOverflowRule:function(e){var n=e.data(P);null!==n&&n!==t?(e.css(z,n),e.removeData(P)):e.css(z,"")},_closeAnimationEnd:function(){var e=this,t=e._previousFocus;if(e._closing=!1,e.dialogWrapper.hide().css("opacity",""),e.trigger(M),e.options.modal){var n=e._object(e._modals().last());n?n.toFront():t&&(e._previousFocus=null,setTimeout((function(){t.focus()})))}},_modals:function(){var t=this,n=e(h+","+u).filter((function(){var n=t._object(e(this));return n&&n.options&&n.options.modal&&n.options.visible&&n.options.appendTo===t.options.appendTo&&!n.containment&&e(n.element).is(y)}));return n=[].sort.call(n,(function(t,n){return+e(t).css("zIndex")-+e(n).css("zIndex")})),t=null,n},_object:function(e){var n=e.find(f),r=i.widgetInstance(n);return r||t},destroy:function(){var t=this;t._destroy(),r.fn.destroy.call(t),i.destroy(t.wrapper),t.dialogWrapper.remove(),t.dialogWrapper=t.wrapper=t.element=e()},_destroy:function(){var e=this,t="."+d;e.wrapper.off(t),e.element.off(t),e.wrapper.find(p+","+_+" > "+b).off(t),e._stopCenterOnResize()},title:function(t){var i=this,r=i.wrapper,o=i.options,a=r.children(v),s=a.children(g),l=c(t);return arguments.length?(!1===t?a.remove():(a.length||(s=(a=e(n.titlebar(o)).prependTo(r)).children(g)),s.html(l)),i.options.title=l,i):s.html()},content:function(e){var t=this,n=t.wrapper.children(f);return R(e)?(i.destroy(n.children()),n.html(e),t.options.content=e,t):n.html()},_focusDialog:function(){var e=this._object(this._modals().first());this._previousFocus=e&&e._previousFocus?e._previousFocus:document.activeElement,this._defaultFocus&&this._focus(this._defaultFocus),this._tabKeyTrap.trap()},_focus:function(e){e&&e.focus()},events:[x,T,D,A,M],options:{title:"",buttonLayout:"stretched",themeColor:"",actions:[],modal:!0,size:"auto",width:null,height:null,minWidth:0,minHeight:0,maxWidth:1/0,maxHeight:1/0,content:null,visible:null,appendTo:k,closable:!0}}),V=O.extend({options:{name:"Dialog",messages:{close:"Close"}}});i.ui.plugin(V);var N=O.extend({_init:function(e,t){var i=this;i.wrapperTemplate=n.alertWrapper,t._defaultFocus=null,i._ensureContentId(e),O.fn._init.call(i,e,t),i.bind(M,i.destroy.bind(i)),i._ariaDescribedBy(),i._initFocus()},_ensureContentId:function(t){var n=e(t);n.attr("id")||n.attr("id",i.guid()+"_k-popup")},_ariaDescribedBy:function(){this.wrapper.attr("aria-describedby",this.element.attr("id"))},_initFocus:function(){var e=this.options;this._defaultFocus=this._chooseEntryFocus(),this._defaultFocus&&e.visible&&e.modal&&this._focusDialog()},_chooseEntryFocus:function(){return this.wrapper.find(_+" > "+b)[0]},options:{title:window.location.host,closable:!1,messages:{okText:"OK",cancel:"Cancel",promptInput:"Input"}}}),$=N.extend({_init:function(e,t){N.fn._init.call(this,e,t)},options:{name:"Alert",modal:!0,actions:[{text:({messages:e})=>`${c(e.okText)}`}]}});i.ui.plugin($);var U=N.extend({_init:function(t,n){N.fn._init.call(this,t,n),this.result=e.Deferred()},options:{name:"Confirm",modal:!0,actions:[{text:({messages:e})=>`${c(e.okText)}`,primary:!0,action:function(e){e.sender.result.resolve()}},{text:({messages:e})=>`${c(e.cancel)}`,action:function(e){e.sender.result.reject()}}]}});i.ui.plugin(U);var W=N.extend({_init:function(t,n){var i=this;N.fn._init.call(i,t,n),i._createPrompt(),i.result=e.Deferred()},_createPrompt:function(){var t=this.options.value,r=e(n.promptInputContainer(this.options)).insertAfter(this.element);this.input=new i.ui.TextBox(r.find("input")),t&&this.input.value(t),this._defaultFocus=this._chooseEntryFocus(),this._focusDialog()},_chooseEntryFocus:function(){return this.wrapper.find(".k-input-inner")[0]},options:{name:"Prompt",modal:!0,value:"",actions:[{text:({messages:e})=>`${c(e.okText)}`,primary:!0,action:function(e){var t=e.sender,n=t.input.value();t.result.resolve(n)}},{text:({messages:e})=>`${c(e.cancel)}`,action:function(e){var t=e.sender.input.value();e.sender.result.reject(t)}}]}});i.ui.plugin(W);n={wrapper:a((e=>`<div class='k-dialog-wrapper'>${e.modal?'<div class="k-overlay"></div>':""}<div class='k-window k-dialog' role='dialog'></div></div>`)),action:a(((e,t)=>`<button type='button' class='k-button k-button-md k-rounded-md k-button-solid ${e.primary?"k-button-solid-primary":"k-button-solid-base"}'><span class="k-button-text">${c(t)}</span></button>`)),titlebar:a((({title:e})=>`<div class='k-window-titlebar k-dialog-titlebar'><span class='k-window-title k-dialog-title'>${c(e)}</span><div class='k-window-titlebar-actions k-dialog-titlebar-actions'></div></div>`)),close:a((({messages:e})=>`<button class="k-window-titlebar-action k-dialog-titlebar-action k-button k-button-md k-button-flat k-button-flat-base k-rounded-md k-icon-button" data-role="close" title='${c(e.close)}' aria-label='${c(e.close)}' tabindex='-1'>\n                                                    ${i.ui.icon({icon:"x",iconClass:"k-button-icon"})}\n                                                </button>`)),actionbar:a((({buttonLayout:e})=>`<div class='k-dialog-actions k-actions k-actions-horizontal k-window-actions k-actions-${c(e)}'></div>`)),alertWrapper:a((()=>"<div class='k-dialog-wrapper'><div class='k-overlay'></div><div class='k-window k-dialog' role='alertdialog'></div></div>")),alert:"<div></div>",confirm:"<div></div>",prompt:"<div></div>",promptInputContainer:a((({messages:e})=>`<div class='k-prompt-container'><input type='text' title='${c(e.promptInput)}' aria-label='${c(e.promptInput)}' /></div>`))},i.alert=function(t){return e(n.alert).kendoAlert({content:t}).data("kendoAlert").open()},i.confirm=function(t){return e(n.confirm).kendoConfirm({content:t}).data("kendoConfirm").open().result},i.prompt=function(t,i){return e(n.prompt).kendoPrompt({content:t,value:i}).data("kendoPrompt").open().result}}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=".kendoForm",r=n.Widget,o=e.extend,a=t.htmlEncode,s="validate",l="validateField",c="change",d="click"+i,u="submit",h="clear",p="equalSet",f="group",m="aria-describedby",g="data-stop",v="data-role",_=".",b={form:"k-form",horizontal:"k-form-horizontal",vertical:"",field:"k-form-field",fieldsContainer:"k-form-fields-container",fieldWrap:"k-form-field-wrap",fieldError:"k-form-field-error",fieldHint:"k-form-hint",fieldset:"k-form-fieldset",layout:"k-form-layout",legend:"k-form-legend",label:"k-label k-form-label",emptyLabel:"k-label-empty",optional:"k-label-optional",buttonsContainer:"k-form-buttons",buttonsEnd:"k-buttons-end",submit:"k-form-submit",clear:"k-form-clear",invalid:"k-invalid",hidden:"k-hidden"},y="horizontal",w="vertical",k=r.extend({init:function(e,n){var i=this;r.fn.init.call(i,e,n),i.options=t.deepExtend({},i.options,n),n&&n.formData&&(i.options.formData=n.formData),i._wrapper(),i._setFields(),i._setModel(),i._renderContainers(),i.options.renderButtons&&i._renderButtons(),i._editable(),i._renderBoolLabels(),i._renderFieldsHints(),i._setEvents(),i._applyCssClasses()},events:[l,s,c,u,h],options:{name:"Form",orientation:w,validatable:{validateOnBlur:!0,validationSummary:!1,errorTemplate:null},buttonsTemplate:null,messages:{submit:"Submit",clear:"Clear",optional:"(Optional)"},layout:"",grid:{},formData:{},items:[],formatLabel:null,focusFirst:!1,renderButtons:!0,size:"medium"},_noLabelfieldTemplate:({styles:e,colSpan:t,hidden:n,field:i})=>`<div class='${a(e.field)} ${t?`k-col-span-${a(t)}`:""} ${n?a(e.hidden):""}'><span class='${a(e.label)} ${a(e.emptyLabel)}'></span><div class='k-form-field-wrap' data-container-for='${a(i)}'></div></div>`,_fieldTemplate:({styles:e,colSpan:t,hidden:n,field:i,label:r,id:o,optional:s})=>`<div class='${a(e.field)} ${t?`k-col-span-${a(t)}`:""} ${n?`${a(e.hidden)}`:""}'>`+(r&&!n?`<label class='${a(e.label)}' for='${a(o)}' id='${a(o)}-form-label'>`+(void 0!==r.encoded&&!1===r.encoded?r.text||r:a(r.text||r))+(r.optional?`<span class='${a(e.optional)}'>${a(s)}</span>`:"")+"</label>":"")+`<div class='k-form-field-wrap' data-container-for='${a(i)}'></div></div>`,_boolLabelTemplate:({styles:e,colSpan:t,hidden:n,field:i,label:r,id:o,optional:s})=>`<label class='k-checkbox-label' for='${a(o)}' id='${a(o)}-form-label'>`+(void 0!==r.encoded&&!1===r.encoded?r.text||r:a(r.text||r))+(r.optional?`<span class='${a(e.optional)}'>${a(s)}</span>`:"")+"</label>",_groupTemplate:({styles:e,colSpan:t,label:n})=>`<fieldset class='${a(e.fieldset)} ${t?`k-col-span-${a(t)}`:""}'><legend class='${a(e.legend)}'>${a(n.text||n)}</legend></fieldset>`,_errorTemplate:({field:e,message:t})=>`<span class='k-form-error' id='${e}-form-error'><div>${t}</div></span>`,_hintTemplate:({id:e,message:t})=>`<div class='k-form-hint' id='${e}-form-hint'><span>${t}</span></div>`,_wrapper:function(){var e=this,t=e.options,n=k.styles,i=t.width,r=t.height;e.wrapper=e.element.addClass(n.form).addClass(n[t.orientation]),r&&e.wrapper.height(r),i&&e.wrapper.css("max-width",i),e.layoutWrapper=e._setupLayoutContainer(e.wrapper,{grid:t.grid,layout:t.layout})},_flattenFields:function(e){for(var t=[].concat(e),n=t.shift(),i=[],r=[].push;n;)n.items?r.apply(t,n.items):r.call(i,n),n=t.shift();return i},_defaultLabel:function(e){var n=this.options.formatLabel;if(e.length)return t.isFunction(n)?n(e):e.split(/(.*[a-z])(?=[A-Z])/).join(" ").trim()+":"},_formatLabel:function(t,n){return undefined!==(e.isPlainObject(n)?n.text:n)?n:this._defaultLabel(t)},_defaultFields:function(){var e,t=this.options,n=Object.keys(t.formData||{}),i=t.items||{},r=[];if(i.length)return i;for(var o=0;o<n.length;o+=1)e=n[o],r.push({field:e,id:e});return r},_setFields:function(){var e,i,r,a,s,l=this,c=l._flattenFields(l._defaultFields()),d=l.options.formData||{};for(var u in l._fields=[],c)i=d[(e=c[u]).field],r="string"==typeof e.editor?e.editor:t.type(i&&t.parseDate(i.toString())||i),a=t.isFunction(e.editor)?e.editor:n.Editable.fn.options.editors[r]?"":e.editor,l._isHidden(e.editor)||(e.label?s={"aria-labelledby":e.id||e.field+"-form-label"}:e.attributes&&e.attributes["aria-label"]||(s={"aria-label":e.name||e.field})),e=o(!0,{label:e.label||e.name||e.field,optionalText:l.options.messages.optional},e,{id:e.id||e.field,name:e.name||e.field,type:r,editor:a,attributes:s,isHidden:l._isHidden(e.editor)||l._isAntiForgeryToken(e.name||e.field)}),l._fields[u]=e},_setModel:function(){var e=this,n=e.options,i=n.formData||{};if(n.formData instanceof t.data.ObservableObject)e._model=i;else{var r=t.data.Model.define({fields:e._fields});e._model=new r(i)}},_editable:function(){var e=this,t=e.options,n=e.options.validatable;e._addEditableMvvmAttributes(),e.editable=e.wrapper.kendoEditable({model:e._model,fields:e._fields||[],validateOnBlur:n.validateOnBlur,validationSummary:n.validationSummary,errorTemplate:n.errorTemplate||e._errorTemplate,clearContainer:!1,skipFocus:!t.focusFirst,target:e,size:t.size}).getKendoEditable(),e.validator=e.editable.validatable,e._removeEditableMvvmAttributes()},_addEditableMvvmAttributes:function(){this.wrapper.attr(v,"editable")},_removeEditableMvvmAttributes:function(){this.wrapper.attr(g,!0).attr(v,"form")},_getItemTemplate:function(e){return e===f?this._groupTemplate:this._fieldTemplate},_isHidden:function(e){return"string"==typeof e&&"hidden"===e},_isAntiForgeryToken:function(e){return e===n.Editable.antiForgeryTokenName},_renderField:function(e){var n,i=this,r=k.styles,o=i.options.orientation===y,a=i._model.fields&&i._model.fields[e.field]&&i._model.fields[e.field].type,s=a&&"boolean"===a;return n=s&&o&&!e.editor?i._noLabelfieldTemplate:i._fieldTemplate,t.template(n)({styles:r,id:e.id||e.field||"",field:e.field||"",label:s&&!e.editor?null:i._formatLabel(e.field,e.label),colSpan:e.colSpan||"",optional:i.options.messages.optional,hidden:i._isHidden(e.editor)||i._isAntiForgeryToken(e.field)})},_toggleFieldErrorState:function(e,t){var n=e.closest(_+b.field);n.length&&n.toggleClass(b.fieldError,t)},_renderBoolLabels:function(){for(var e,n,i=this,r=k.styles,o=i._fields,a=0;a<o.length;a+=1)e=o[a],(n=i.wrapper.find("[name='"+e.name+"']:not([type='hidden'])"))&&e.label&&!e.isHidden&&"boolean"===e.type&&!e.editor&&n.parent().after(t.template(i._boolLabelTemplate)({styles:r,id:e.id||e.field||"",optional:i.options.messages.optional,label:i._formatLabel(e.field,e.label)}))},_renderFieldsHints:function(){for(var n,i,r,o,a,s=this,l=s._fields,c=0;c<l.length;c+=1)n=l[c],(r=s.wrapper.find(`[name='${n.name}'],[id='${n.name}']`))&&n.hint&&!n.isHidden&&(a=e(t.template(s._hintTemplate)({message:n.hint||"",id:n.id})),s._associateHintContainer(r,a.attr("id")),(i=t.widgetInstance(r))&&(r=(o=i.element.next("label[for='"+i.element.attr("id")+"']")).length?o:i.wrapper),s.validator._errorsByName(n.name).length&&(a.toggleClass(b.hidden),t.removeAttribute(r,m,a.attr("id"))),a.insertAfter(r))},_associateHintContainer:function(e,n){var i=t.getWidgetFocusableElement(e);i&&n&&t.toggleAttribute(i,m,n)},_toggleHint:function(e,t){var n,i=e.closest(_+b.field);i.length&&(n=i.find(_+b.fieldHint)).length&&(n.toggleClass(b.hidden,t),this._associateHintContainer(e,n.attr("id")))},_renderGroup:function(n){var i,r,o,a=this,s=n.type;o=r=e(t.template(a._getItemTemplate(s))({styles:b,label:n.label||"",colSpan:n.colSpan})),o=a._setupLayoutContainer(r,{grid:n.grid,layout:n.layout})||r;for(var l=0;l<n.items.length;l+=1)i=n.items[l],o.append(a._renderField(i));return r},_renderContainers:function(){for(var e,t,n=this,i=n._defaultFields(),r="grid"===n.options.layout?n.layoutWrapper:n.wrapper,o=0;o<i.length;o+=1)t=(e=i[o]).type===f?n._renderGroup(e):n._renderField(e),r.append(t)},_buttonsTemplate:function(){var n,i,r,o=this.options,s=o.messages,l=k.styles;return null!==o.buttonsTemplate?n=t.template(o.buttonsTemplate)({styles:l,messages:s}):(i=e("<button class='"+l.submit+"'>"+a(s.submit)+"</button>").kendoButton({type:"submit",themeColor:"primary",size:o.size}),r=e("<button class='"+l.clear+"'>"+a(s.clear)+"</button>").kendoButton({size:o.size}),n=i.add(r)),n},_renderButtons:function(){var t,n=this,i=n.wrapper,r=n.options,o=k.styles,a=r.orientation===y,s=i.find(_+o.buttonsContainer);s.length||(s=e("<div />").addClass(o.buttonsContainer).addClass(a?o.buttonsEnd:"")),t=n._buttonsTemplate(),s.append(t),n.element.append(s)},_setupLayoutContainer:function(t,n){var i,r=n.layout,o=n.grid,a=[];return"string"==typeof r&&""!==r&&(i=e("<div></div>").appendTo(t).addClass(b.layout),a.push("k-d-"+r)),"grid"===r&&"object"==typeof o&&("number"==typeof o.cols?a.push("k-grid-cols-"+o.cols):"string"==typeof o.cols&&i.css("grid-template-columns",o.cols),a.push("k-gap-x-"+o.cols)),i&&i.addClass(a.join(" ")),i},_setEvents:function(){var e=this;e.validator.bind("validateInput",e._validateField.bind(e)).bind(s,e._validate.bind(e)),e.wrapper.on(u+i,e._submit.bind(e)).on(h+i,e._clear.bind(e)).on(d+i,_+b.clear,e._clear.bind(e)),e._changeHandler||(e._changeHandler=e._change.bind(e)),e._model.bind(c,e._changeHandler)},_validateField:function(e){var t=this,n={model:t._model.toJSON(),valid:e.valid,field:e.field,error:e.error,input:e.input};t._toggleFieldErrorState(n.input,!n.valid),t._toggleHint(n.input,!n.valid),t.trigger(l,n)&&e.preventDefault()},_validate:function(e){var t={model:this._model.toJSON(),valid:e.valid,errors:e.errors};this.trigger(s,t)},_change:function(e){var t=e.field,n={field:t,value:this._model[t]};this.trigger(c,n)},_submit:function(e){var t=this._model.toJSON();this.trigger(u,{model:t})&&e.preventDefault()},_clear:function(e){e.preventDefault(),this.clear(),this.trigger(h)},validate:function(){var e=this.validator;if(e)return e.validate()},clear:function(){var e=this,n=e._fields,i=e._model,r=e.editable,o=e.validator.options.validateOnBlur;e.validator.reset(),o&&i.unbind("set").unbind(p);for(var a=0;a<n.length;a+=1){var s=n[a].field,l=e.wrapper.find("[name='"+s+"']"),c=t.widgetInstance(l),d=l.is("input[type=hidden]");l.is("[data-role='checkboxgroup']")||l.is("[data-role='radiogroup']")||d||l.val(""),!c&&l.hasClass("k-hidden")&&(c=t.widgetInstance(l.closest(".k-signature"))),c&&(t.ui.Upload&&c instanceof t.ui.Upload?c.clearAllFiles():c.value(null)),e._toggleHint(l,!1),"boolean"==typeof i[s]?(l.val("false"),i.set(s,!1)):d||i.set(s,null)}e.wrapper.find(_+b.fieldError).removeClass(b.fieldError),o&&i.bind("set",r._validateProxy).bind(p,r._validateProxy)},setOptions:function(e){var t=this;t.destroy(),t.wrapper.removeClass(b.horizontal).removeAttr(g).empty(),t.init(t.element,e)},destroy:function(){var e=this;e.wrapper.off(i),e._model&&(e._model.unbind(c,e._changeHandler),e._changeHandler=null),r.fn.destroy.call(e.editable),r.fn.destroy.call(e),e.editable&&(e.editable.destroy(),e.editable=null)}});t.cssProperties.registerPrefix("Form","k-form-"),n.plugin(k),o(!0,k,{styles:b})}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=".kendoButtonMenu",r=t.ui,o=t.keys,a=t.htmlEncode,s=e.extend,l=".",c="id",d="next",u="k-disabled",h="k-hidden",p="aria-disabled",f="tabindex",m="click",g="menuClick",v="menuOpen",_="menuClose",b="keydown",y="focus",w={down:{origin:"bottom left",position:"top left"},up:{origin:"top left",position:"bottom left"}},k="k-menu-popup",x="k-menu-group",C="k-item k-menu-item",S="k-menu-item",T="k-menu-link-text",D="k-link k-menu-link",A="k-sprite",M="k-image",E={text:null,icon:null,url:null,attributes:null,enabled:!0,hidden:!1,id:null,imageUrl:null,spriteCssClass:null},I=({imageUrl:e})=>""+(e?`<img alt="icon" class="${M}" src="${a(e)}" />`:""),z=({spriteCssClass:e})=>""+(e?`<span class="${A} ${a(e)}"></span>`:""),P=({icon:e})=>`${e?t.ui.icon(a(e)):""}`,H=({text:e})=>""+(e?`<span class="${T}">${a(e)}</span>`:""),F=({imageUrl:e,spriteCssClass:t,icon:n,text:i})=>`<span class="${D}">${I({imageUrl:e})}${z({spriteCssClass:t})}${P({icon:n})}${H({text:i})}</span>`,R=({url:e,imageUrl:t,spriteCssClass:n,icon:i,text:r,attributes:o})=>`<a href="${a(e)}" ${o.target?`target="${o.target}"`:""} class="${D}">${I({imageUrl:t})}${z({spriteCssClass:n})}${P({icon:i})}${H({text:r})}</a>`;function L(t,n){var i=n===d?e.fn.next:e.fn.prev,r=n===d?e.fn.first:e.fn.last,o=i.call(t),a=":kendoFocusable";return o.length||(o=r.call(t.parent().find(l+S))),o.is(a)||!o.length?o:o.find(a).length?r.call(o.find(a)):L(o,n)}var B=n.extend({init:function(e,t){var i=this;n.fn.init.call(i,e,t),i.mainButton=t.mainButton,i._clickHandlers={},i._renderList(),i._initPopup(),i._attachEvents(),i._applyCssClasses(i.list)},options:{name:"ButtonMenu",direction:"down",element:null,items:[],size:"medium"},events:[g,v,_],_renderList:function(){var n=this,i=n.options.items,r=n.element.addClass(k),o=n.mainButton.attr(c)||t.guid(),a=e('<ul role="menu"></ul>').addClass(x);n.list=a.appendTo(r),n.list.attr(c,o+"_buttonmenu"),i.forEach(n._renderListItem.bind(n)),n.list.find(l+S+":first-child").addClass("k-first"),n.list.find(l+S+":last-child").addClass("k-last")},_renderListItem:function(n){var i,r,o=this,a=n.attributes?n.attributes.id:null;i=(n=s({},E,n,{enabled:n.enable&&n.enabled})).id||a||t.guid(),r=e('<li id="'+i+'" role="menuitem" class="'+C+'">'+o._renderItemButton(n)+"</li>"),n.click&&(o._clickHandlers[i]=n.click),n.attributes&&(delete n.attributes.target,n.attributes.class&&(r.addClass(n.attributes.class),delete n.attributes.class),r.attr(n.attributes)),n.data&&t.isFunction(n.data)&&r.data(n.data(n)),o.list.append(r),o.enable(n.enabled,r),o._hide(n.hidden,r)},_renderItemButton:function(e){var n=this.options;return n.itemTemplate?t.template(n.itemTemplate)(e):e.url?t.template(R)(e):t.template(F)(e)},_initPopup:function(){var e=this,t=e.options,n=t.direction||"down";e._popup=new r.Popup(e.element,s({},t.popup,{anchor:e.mainButton,isRtl:e._isRtl,toggleTarget:t.toggleTarget,copyAnchorStyles:!1,animation:t.animation,open:e._popupOpenHandler.bind(e),close:e._popupCloseHandler.bind(e),activate:e._popupExpandHandler.bind(e)},w[n]))},_popupOpenHandler:function(e){this.trigger(v)?e.preventDefault():this.list.find(l+S).attr(f,0)},_popupCloseHandler:function(e){this.trigger(_)&&e.preventDefault(),this.list.find(l+S).attr(f,-1)},_popupExpandHandler:function(){this.list.find(":kendoFocusable").first().trigger(y)},adjustPopupWidth:function(e){this.element.css({"min-width":e})},_attachEvents:function(){var e=this;e.list.on(m+i,l+S,e._click.bind(e)).on(b+i,l+S,e.listItemKeydown.bind(e)),e.mainButton.on(b+i,e._keydown.bind(e))},_keydown:function(t){if(!e(t.target).is(l+u)&&!e(t.target).parents(l+u).length)return t.altKey&&t.keyCode===o.DOWN?(this.open(),void t.preventDefault()):void 0},listItemKeydown:function(t){var n=this,i=e(t.target);t.preventDefault(),t.keyCode===o.ESC||t.keyCode===o.TAB||t.altKey&&t.keyCode===o.UP?(n.close(),n.mainButton.trigger(y)):t.keyCode===o.DOWN?L(i,d).trigger(y):t.keyCode===o.UP?L(i,"prev").trigger(y):i.is(l+u)||t.keyCode!==o.SPACEBAR&&t.keyCode!==o.ENTER?t.keyCode===o.HOME?n.list.find(":kendoFocusable").filter(l+S).first().trigger(y):t.keyCode===o.END&&n.list.find(":kendoFocusable").filter(l+S).last().trigger(y):i.trigger(m)},_click:function(t){var n=this,i=e(t.target).closest(l+S),r=i.attr(c);n._clickHandlers[r]&&n._clickHandlers[r](t),n.trigger(g,{id:r,target:i,type:"menu-click",originalEvent:t})},toggle:function(){this._popup.toggle()},enable:function(e,t){(t=t&&t.length?this.list.find(t):this.items()).toggleClass(u,!e),e?t.removeAttr(p):t.attr(p,!e)},_hide:function(e,t){(t=t&&t.length?this.list.find(t):this.items()).toggleClass(h,e)},hide:function(e){this._hide(!0,e)},show:function(e){this._hide(!1,e)},open:function(){0!==this.items().length&&(0!==this.items().filter(`:not(.${h})`).length&&this._popup.open())},close:function(){this._popup.close()},items:function(){return this.list.children(l+S)},destroyPopup:function(){var e=this;e._popup&&(e._popup.destroy(),e._popup=null,e.list.off(i),e.list.remove(),e.list=null)},destroy:function(){var e=this;delete e._clickHandlers,e.destroyPopup(),e.mainButton.off(i),n.fn.destroy.call(e)}});t.cssProperties.registerPrefix("ButtonMenu","k-menu-group-"),r.plugin(B)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=".kendoSplitButton",r=t.ui,o=e.extend,a=t.html,s=t._outerWidth,l=t.keys,c="id",d="aria-disabled",u="aria-label",h="aria-expanded",p="disabled",f="k-disabled",m="k-focus",g="click",v="open",_="close",b="focus",y="k-split-button k-button-group",w=n.extend({init:function(i,r){var o=this;(r=r||{}).enabled=!1!==r.enabled&&!e(i).prop(p),n.fn.init.call(o,i,r),o._wrapper(),o._renderButtons(),o._renderMenu(),o._enable(o.options.enabled),o._aria(),o._attachEvents(),t.notify(o),o._applyCssClasses()},options:{name:"SplitButton",enabled:!0,items:[],rounded:"medium",size:"medium",fillMode:"solid",themeColor:"base",icon:null,popup:null,arrowIcon:"caret-alt-down",messages:{labelSuffix:"splitbutton"}},events:[g,v,_],_wrapper:function(){var n=this,i=(n.element.attr(c)||t.guid())+"_wrapper";n.wrapper=n.element.wrap('<div id="'+i+'" class="'+y+'"></div>').parent(".k-split-button"),n.arrowButton=e('<button tabindex="-1" aria-label="arrow-button" class="k-split-button-arrow"></button>').appendTo(n.wrapper)},_applyCssClasses:function(){this.wrapper.addClass(this._getAppearanceClasses())},_clearCssClasses:function(){this.wrapper.removeClass(this._getAppearanceClasses())},_getAppearanceClasses:function(){var e=this.__proto__.options.name;return t.cssProperties.getValidClass({widget:e,propName:"rounded",value:this.options.rounded})},_renderButtons:function(){this._mainButton(),this._arrowButton()},_mainButton:function(){var e=this,t=o({},e.options,{type:e.element.attr("type")||"button"});delete t.click,a.renderButton(e.element,t)},_arrowButton:function(){var e=this,t=o({},e.options,{type:"button",icon:e.options.arrowIcon});delete t.text,delete t.imageUrl,delete t.click,delete t.iconClass,a.renderButton(e.arrowButton,t)},_aria:function(){var e=this,t=e.element,n=e.menu;t.attr("aria-haspopup",n?"menu":null),t.attr(h,!n&&null),t.attr("aria-controls",n?n.list.attr(c):null),t.attr(u)||t.attr(u,t.text()+" "+e.options.messages.labelSuffix)},_renderMenu:function(){var t=this,n=o({},t.options),i=e("<div></div>");delete n.click,delete n.name,n.items.length&&(t.menu=i.appendTo(t.wrapper).kendoButtonMenu(o({mainButton:t.element,toggleTarget:t.arrowButton,menuOpen:t.menuOpenHandler.bind(t),menuClose:t.menuCloseHandler.bind(t),menuClick:t._click.bind(t)},n)).data("kendoButtonMenu"))},menuOpenHandler:function(e){var t=this,n=s(t.wrapper);t.trigger(v,{target:t.element})?e.preventDefault():(e.sender.adjustPopupWidth(n),t.element.attr(h,!0))},menuCloseHandler:function(e){var t=this;t.trigger(_,{target:t.element})?e.preventDefault():(t.element.attr(h,!1),t.element.trigger(b))},_attachEvents:function(){var e=this;e.element.on(g+i,e._click.bind(e)),e.element.on("keydown"+i,e._keydown.bind(e)),e.element.on(b+i,e._focus.bind(e)),e.element.on("blur"+i,e._blur.bind(e))},_focus:function(){this.wrapper.addClass(m)},_blur:function(){this.wrapper.removeClass(m)},_click:function(t){var n=e(t.target).closest(".k-button"),i=n.attr(c),r=t;"menu-click"===t.type&&(i=t.id,n=t.target,r=t.originalEvent),this.menu.close(),this.trigger(g,{id:i,target:n,originalEvent:r})},_keydown:function(e){!this.element.is("."+f)||e.keyCode!==l.ENTER&&e.keyCode!==l.SPACEBAR||e.preventDefault()},focus:function(){this.element.trigger(b)},_enable:function(e,t){this.element.add(this.arrowButton).toggleClass(f,!e),e?this.element.removeAttr(d):this.element.attr(d,!e),t||this.element.attr(p,!e),this.arrowButton.attr(p,!e)},enable:function(e,t,n){var i=this;undefined===e&&(e=!0),t&&t.length?i.menu.enable(e,t):(i.options.enabled=e,i._enable(e,n),i.menu.enable(e))},hide:function(e){e&&e.length&&this.menu.hide(e)},show:function(e){e&&e.length&&this.menu.show(e)},open:function(){this.menu._popup.open()},close:function(){this.menu._popup.close()},items:function(){return this.menu.items()},setOptions:function(e){var t=this;n.fn.setOptions.call(t,e),(e.popup||e.items||e.size)&&(t.menu.destroy(),t._renderMenu()),t._renderButtons(),t._aria()},destroy:function(){var e=this;e.menu&&e.menu.destroy(),e.element.off(i),n.fn.destroy.call(e)}});t.cssProperties.registerPrefix("SplitButton","k-splitbutton-"),t.cssProperties.registerValues("SplitButton",[{prop:"rounded",values:t.cssProperties.roundedValues.concat([["full","full"]])}]),r.plugin(w)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=".kendoDropDownButton",r=t.ui,o=t.keys,a=e.extend,s=t.html,l=t._outerWidth,c="aria-disabled",d="aria-label",u="aria-expanded",h="disabled",p="k-disabled",f="click",m="open",g="close",v="focus",_="k-menu-button",b=n.extend({init:function(i,r){var o=this;r.enabled=!1!==r.enabled&&!e(i).prop(h),n.fn.init.call(o,i,r),o.wrapper=o.element,o._mainButton(),o._renderMenu(),o._enable(o.options.enabled),o._aria(),o._attachEvents(),t.notify(o),o._applyCssClasses()},options:{name:"DropDownButton",direction:"down",enabled:!0,items:[],rounded:"medium",size:"medium",fillMode:"solid",themeColor:"base",showArrowButton:!1,icon:null,popup:null,messages:{labelSuffix:"dropdownbutton"}},events:[f,m,g],_mainButton:function(){var n=this,i=a({},n.options,{type:n.element.attr("type")||"button"});if(delete i.click,n.element.addClass(_),s.renderButton(n.element,i),n.options.showArrowButton)e("<span></span>").addClass("k-button-arrow").addClass("k-menu-button-arrow").append(t.ui.icon(t.htmlEncode("caret-alt-down"))).appendTo(n.element);else{const e=n.element.find(".k-button-arrow");e&&e.remove()}},_aria:function(){var e=this,t=e.element,n=e.menu;t.attr("aria-haspopup",n?"menu":null),t.attr(u,!n&&null),t.attr("aria-controls",n?n.list.attr("id"):null),t.attr(d)||t.attr(d,t.text()+" "+e.options.messages.labelSuffix)},_renderMenu:function(){var t=this,n=a({},t.options),i=e("<div></div>");delete n.click,delete n.name,t.menu=i.appendTo(document.body).kendoButtonMenu(a({mainButton:t.element,toggleTarget:t.element,menuOpen:t.menuOpenHandler.bind(t),menuClose:t.menuCloseHandler.bind(t),menuClick:t._click.bind(t)},n)).data("kendoButtonMenu")},menuOpenHandler:function(e){var t=this,n=l(t.element);t.trigger(m,{target:t.element})?e.preventDefault():(e.sender.adjustPopupWidth(n),t.element.attr(u,!0))},menuCloseHandler:function(e){var t=this;t.trigger(g,{target:t.element})?e.preventDefault():(t.element.attr(u,!1),t.element.trigger(v))},_attachEvents:function(){var e=this;e.element.on("keydown"+i,e._keydown.bind(e))},_click:function(e){var t=e.id,n=e.target,i=e.originalEvent;this.menu.close(),this.trigger(f,{id:t,target:n,originalEvent:i})},_keydown:function(e){!this.element.is("."+p)||e.keyCode!==o.ENTER&&e.keyCode!==o.SPACEBAR||e.preventDefault()},focus:function(){this.element.trigger(v)},_enable:function(e,t){this.element.toggleClass(p,!e),e?this.element.removeAttr(c):this.element.attr(c,!e),t||this.element.attr(h,!e)},enable:function(e,t,n){var i=this;undefined===e&&(e=!0),t&&t.length?i.menu.enable(e,t):(i.options.enabled=e,i._enable(e,n),i.menu.enable(e))},hide:function(e){e&&e.length&&this.menu.hide(e)},show:function(e){e&&e.length&&this.menu.show(e)},open:function(){this.menu.open()},close:function(){this.menu.close()},items:function(){return this.menu.items()},setOptions:function(e){var t=this;n.fn.setOptions.call(t,e),(e.popup||e.items||e.size)&&(t.menu.destroy(),t._renderMenu()),t._mainButton(),t._aria()},destroy:function(){var e=this;e.menu.destroy(),e.element.off(i),n.fn.destroy.call(e)}});r.plugin(b)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.isFunction,o=n.keys,a=n._outerWidth,s=".kendoToolBar",l="toolbar",c="k-button",d="k-button-group",u="k-split-button",h="k-menu-button",p="k-spacer",f="k-selected",m="k-hidden",g="k-force-hidden",v="k-group-start",_="k-group-end",b="k-menu-link",y="k-menu-item",w="k-toolbar-overflow-button",k="k-toolbar-item",x="k-menu-link-toggle",C="k-dropdownlist",S="k-input-button",T="k-focus",D="[tabindex=-1]",A="toolbar-tool",M="aria-checked",E="aria-label",I="change",z="click",P="toggle",H="open",F="close",R="focus",L="keydown",B="spacer",O="role",V="ref-",N="separator",$="overflow",U="tabindex",W="input",j="select",q="group",G="data-uid",K="[data-role]",Y="[data-toggle]",Q="[data-role=buttonmenu]",X="[ref-toolbar-tool]",Z=":kendoFocusable:not([class*='pager'])",J="overflowOpen",ee="overflowClose",te="never",ne="auto",ie="always",re=n.attr("uid"),oe="",ae="_",se=" ",le=".",ce=",",de="id",ue="uid",he="kendoDropDownButton",pe="kendoSplitButton",fe="kendoToggleButton",me="kendoButtonGroup";n.toolbar={};var ge={button:"Button",splitButton:"SplitButton",dropDownButton:"DropDownButton",buttonGroup:"ButtonGroup",popupButton:"Button",open:"Button"},ve={Button:"k-toolbar-button",ToggleButton:"k-toolbar-toggle-button",SplitButton:"k-toolbar-split-button",DropDownButton:"k-toolbar-menu-button",ButtonGroup:"k-toolbar-button-group",ColorPicker:"k-toolbar-color-picker",Switch:"k-toolbar-switch"},_e=["Button","SplitButton","DropDownButton","ButtonGroup","Switch","ColorPicker"],be=`<button class="k-popup-button"><span class="k-button-icon k-icon"></span><span class="k-button-text">${n.ui.icon("caret-alt-down")}</span></button>`,ye=i.extend({init:function(e,t){i.fn.init.call(this,e,t),t=this.options,this._isRtl=n.support.isRtl(e),this.uid=n.guid(),(e=this.wrapper=this.element).attr(re,this.uid),e.addClass("k-toolbar"),e.attr(O,l),t.resizable&&this._resizable(),t.tools&&t.tools.length>0&&(t.items=this._extendToolsOptions()),t.items&&t.items.length&&this._items(),this._attachEvents(),this._tabIndex(),this._applyCssClasses(),t.resizable&&(this._shrink(this.element.innerWidth()),this.overflowAnchor.appendTo(this.wrapper),this._toggleOverflowAnchor()),n.notify(this)},events:[z,P,H,F,J,ee,I],options:{name:"ToolBar",items:[],resizable:!0,navigateOnTab:!1,evaluateTemplates:!1,size:"medium",fillMode:"solid"},destroy:function(){var t=this;t.options.resizable&&(n.unbindResize(t._resizeHandler),t.overflowMenu.destroy()),t.element.find(".k-popup-button").each(((t,n)=>{var i,r,o,a=e(n).getKendoButton();a&&(o=a.chooser,r=(i=a.popup).wrapper,o.destroy(),i.destroy(),r.remove())})),n.destroy(t.element.children()),i.fn.destroy.call(t)},add:function(e){this._add(e),this.options.resizable&&this.resize(!0)},enable:function(t,i){var r,o,a=this,s=this._getUid(t),l=this._getItem(t,s),c=l.component;void 0===i&&(i=!0),l.component?(r=(o=c.wrapper).hasClass(T)||o.is(":focus"),c.enable(i),o.find("[disabled]").removeAttr("disabled"),o.removeAttr("disabled"),r&&o.addClass(T).trigger(R)):l.buttonsPopupItem.length>0&&n.widgetInstance(l.buttonsPopupItem.closest(".k-menu-popup")).enable(i,l.buttonsPopupItem),this.overflowMenu&&(this.overflowMenu.enable(l.menuItem,i),this.overflowMenu.element.find("[data-parentuid="+s+"]").each(((t,n)=>{a.overflowMenu.enable(e(n),i)})))},getSelectedFromGroup:function(e){return this.element.find("[data-group='"+e+"']").filter(le+f)},hide:function(t){var n,i,r=this,o=this._getUid(t),a=r._getItem(t,o);a&&((n=a.templateEl.add(a.toolbarEl).add(a.buttonsPopupItem).add(a.menuItem)).addClass(m),n.addClass(g),this.overflowMenu&&this.overflowMenu.element.find("[data-parentuid="+o+"]").each(((t,n)=>{e(n).addClass(g),e(n).addClass(m)})),(i=a.toolbarEl.parent().closest(le+d)).data(me)&&(0===i.children(":not(.k-hidden)").length?r.hide(i):r._groupVisibleButtons(i)),n.find("[tabindex=0]").addBack("[tabindex=0]").length>0&&this._resetTabIndex(r._getAllItems().first()),this.options.resizable&&this.resize(!0))},remove:function(t){var n,i=this,r=this._getUid(t),o=this._getItem(t,r);o&&(o.component&&((n=o.toolbarEl.closest('[data-role="buttongroup"]')).length>0&&0===o.toolbarEl.siblings().length?(n.data(me).destroy(),n.remove(),o.toolbarEl=e(oe)):o.component.destroy()),o.templateEl.length>0?o.templateEl.remove():o.toolbarEl.length>0&&o.toolbarEl.remove(),o.buttonsPopupItem.length>0&&o.buttonsPopupItem.remove(),this.overflowMenu&&(this.overflowMenu.remove(o.menuItem),this.overflowMenu.element.find("[data-parentuid="+r+"]").each(((t,n)=>{i.overflowMenu.remove(e(n))}))),this.options.resizable&&this.resize(!0))},show:function(t){var n,i,r=this._getUid(t),o=this._getItem(t,r);o&&((n=o.templateEl.add(o.toolbarEl).add(o.buttonsPopupItem)).removeClass(g),n.removeClass(m),o.menuItem.removeClass(g),this.overflowMenu&&this.overflowMenu.element.find("[data-parentuid="+r+"]").each(((t,n)=>{e(n).removeClass(g)})),(i=o.toolbarEl.parent().closest(le+d)).data(me)&&(i.hasClass("k-hidden")&&i.children(":not(.k-hidden)").length>0?this.show(i):this._groupVisibleButtons(i)),this.options.resizable&&this.resize(!0))},toggle:function(n,i){var r,o,a,s=this._getItem(n),l=s.toolbarEl,c=s.menuItem;i===t&&(i=!0),r=l.data(fe),(s.component||0!==c.find(le+x).length)&&(a=l.data(q),s.component&&((o=l.closest(le+d).data(me))&&l.hasClass(f)!==i&&o._toggleIndex(l.index()),r.toggle(i),i&&this.element.find("[data-group="+a+"]").each(((t,n)=>{n!==l[0]&&e(n).data(fe).toggle(!1)}))),c&&(c.attr(M,i).find(le+x).toggleClass(f,i),i&&this.overflowMenu&&this.overflowMenu.element.find("[data-group="+a+"]").each(((t,n)=>{n!==c[0]&&e(n).attr(M,!1).find(le+x).removeClass(f)}))))},toggleTools:function(t){var i=this,r=i.element.find(Y),o=i.element.find(Z).not(D);r.each((function(r,o){var a=e(o),s=null,l=a.data(P),c=t&&t[l];a.is(K)&&(s=n.widgetInstance(a)),s&&s.enable?s.enable(c||!1):i.enable(a,c)})),i.element.find(Y+"[disabled]").removeAttr("disabled"),i.element.find(Z).not(D).attr("tabindex",-1),o.attr(U,0)},_add:function(e){var t,i=this._processOptions(e),r=i.template,o=i.overflowTemplate,a=ge[i.type];r||o?t=this._addTemplate(i):n.ui[i.component]?t=this._addCustomWidget(i):a?t=this._addDefaultTool(a,i):i.type===B?this._addSpacer():i.type===N&&this._addSeparator(i),t&&(this.overflowAnchor?t.insertBefore(this.overflowAnchor):t.appendTo(this.element),t.find("[disabled]").removeAttr("disabled"),t.is("[disabled]")&&t.removeAttr("disabled"))},_addAttributes:function(e,t){var n=e.attributes,i=oe;n||(n={}),e.hidden&&(i=m+se+g),e.align&&(i=i+" k-align-"+e.align),n&&(n.class&&(i=i+se+n.class,delete n.class),t.attr(n)),t.addClass(i),t.attr(re,e.uid),e.id&&t.attr(de,e.id),e.overflow===te&&t.attr("data-overflow",te),e.items&&e.items.forEach((e=>{e&&e.groupClass&&!t.hasClass(e.groupClass)&&t.addClass(e.groupClass)}))},_addCustomWidget:function(t){var i,r,o,a=e(t.element||"<input>");return t.overflowComponent&&this._addMenuItem(t.overflowComponent.type,e.extend({},t,t.overflowComponent)),t.attributes&&(o=t.attributes.class,delete t.attributes.class,a.attr(t.attributes),delete t.attributes[E]),t.componentOptions||(t.componentOptions={}),t.componentOptions.size=this.options.size,i=new n.ui[t.component](a,t.componentOptions),_e.indexOf(t.component)>-1?(i.wrapper.addClass(ve[t.component]).attr(V+A,""),r=i.wrapper):r=(i.wrapper||i.element).wrap("<span class='k-toolbar-item' tabindex='0' ref-toolbar-tool >").parent(),t.attributes&&(t.attributes.class=o),this._addAttributes(t,r),r},_addDefaultTool:function(t,n){var i,r;return n.overflow!==ie&&(i=this._addToolbarTool(t,e.extend(!0,{},n))),this.overflowMenu&&n.overflow!==te&&(n.overflowComponent?(delete(r=e.extend(!0,{},n,n.overflowComponent))["data-command"],this._addMenuItem("Button",r)):this._addMenuItem(t,e.extend(!0,{},n))),i},_addMenuItem:function(i,r){var o,a=this,s=r.selected;return delete r.selected,r.id&&(r.id=r.id+ae+$),r.showIcon===l&&(delete r.imageUrl,delete r.icon),r.showText===l?(r.attributes||(r.attributes={}),r.attributes[E]=r.text,r.text=oe):r.text!==t&&r.text!==oe||(r.text="&nbsp;",r.encoded=!1),a.overflowMenu.append(r),o=a.overflowMenu.element.find(le+y).last(),r.icon&&o.find(le+b).prepend(n.ui.icon(r.icon)),"ToggleButton"===i||"Button"===i&&!0===r.togglable?(o.find(le+b).addClass(x),s&&o.find(le+b).addClass(f),r.group&&o.attr("data-group",r.group)):r.menuButtons?r.menuButtons.forEach((e=>{e.overflow=r.overflow,a._addMenuItem(null,e)})):r.buttons&&(o.remove(),o=null,r.buttons.forEach((t=>{var n=t.attributes;t.overflow=r.overflow,t.attributes=e.extend(n,r.attributes),a._addMenuItem("Button",t)}))),"DropDownButton"===i&&(o.addClass("k-disabled"),o.attr("aria-disabled",!0)),o&&(a._addAttributes(r,o),r.overflow===ne&&o.addClass(m),(r.click||r.toggle)&&a.overflowMenu.bind(j,(e=>{e.item===o[0]&&this._onMenuItemSelect(e,r.click,r.toggle)}))),o},_addPopupButton:function(t){var n,i,r=this,o=e(be),a=t.popupComponent;return o.attr(E,t.text),n=e("<div/>").appendTo(e("<body>")).kendoPopup({anchor:o}).data("kendoPopup"),o.on(z+" touchend",(e=>{n.toggle(),e.preventDefault()})),(i=new a(n.element)).bind(t.commandOn,(e=>{r.trigger(I,{target:o,value:e.value||e}),n.close()})),{widgetElement:o,chooser:i,popup:n}},_addSeparator:function(t){var n=e('<div role="separator">&nbsp;</div>'),i=e("<li role='separator' class='k-separator k-menu-separator k-hidden'></li>");n.addClass("k-separator"),n.attr(O,N),this.overflowAnchor?n.insertBefore(this.overflowAnchor):n.appendTo(this.element),this._addAttributes(t,n),t.id&&(t.id=t.id+ae+$),this._addAttributes(t,i),this.overflowMenu&&this.overflowMenu.element.append(i)},_addSpacer:function(){var t=e("<div>&nbsp;</div>");t.addClass(p),this.overflowAnchor?t.insertBefore(this.overflowAnchor):t.appendTo(this.element)},_addTemplate:function(t){var i,o,a=t.template,s=t.overflowTemplate,l=e(oe);return s&&this.overflowMenu&&t.overflow!==te&&(s=r(s)?s(t)[0]:s,this.overflowMenu.append({}),o=this.overflowMenu.element.find(le+y).last().find(le+b).html(s).parent()),a&&t.overflow!==ie&&(this.options.evaluateTemplates&&(a=n.template(a)),a=r(a)?a(t):a,(i=e("<div class='k-toolbar-item' aria-keyshortcuts='Enter'></div>")).html(a),o&&o.addClass(m)),i&&(l=i.find(W+ce+j),this._addAttributes(t,i)),o&&(l.add(o.find(W+ce+j)),this._addAttributes(t,o)),!this.options.navigateOnTab&&l.length>0&&(i.attr(U,0),i.attr(V+A,""),l.attr(U,-1)),i},_addToolbarTool:function(t,i){var r,o,a,s=e("<button>"),l=!1;return!0===i.primary&&(i.themeColor="primary"),i.url&&(s=e("<a href='"+i.url+"'>")),i.showIcon===$&&(delete i.imageUrl,delete i.icon),i.showText!==$?s.text(i.text):s.attr(E,i.text),"popupButton"===i.type?s=(a=this._addPopupButton(i)).widgetElement:"Button"===t&&!0===i.togglable?t="ToggleButton":i.menuButtons?(i.items=i.menuButtons,delete i.menuButtons,i.attributes&&i.attributes.class&&s.addClass(i.attributes.class),s.attr(G,i.uid),delete i.uid):i.buttons&&(s=e("<span></span>"),l=!0,i.items=i.buttons,delete i.buttons,i.preventKeyNav=!0,i.items.forEach((e=>{e.showIcon===$&&(delete e.imageUrl,delete e.icon),e.showText===$&&(e.attributes||(e.attributes={}),e.attributes[E]=e.text,delete e.text)}))),i.id&&(s.attr(de,i.id),delete i.id),i.name&&delete i.name,i.size=this.options.size,(o=(r=new n.ui[t](e(s),i)).wrapper||r.element).addClass(ve[t]),this._addAttributes(i,o),i.url&&s.removeAttr(O),l?(o.find(le+c).attr(V+A,""),this._groupVisibleButtons(o)):r.element.attr(V+A,""),"popupButton"!==i.type&&"open"!==i.type?this._attachWidgetEvents(r):"open"===i.type?(s.addClass("k-upload-button"),this._resetOpen(s,i.extensions),o=s.parent()):(r.chooser=a.chooser,r.popup=a.popup),o},_attachEvents:function(){var e=this;e.element.on(L+s,e._keydown.bind(e)).on("focusin"+s,e._focusIn.bind(e)).on("focusout"+s,e._focusOut.bind(e))},_attachWidgetEvents:function(t){var n=this;t.bind(z,n._onClick.bind(n)),t.bind(P,n._onToggle.bind(n)),t.bind(j,n._onSelect.bind(n)),t.bind(H,n._onOpen.bind(n)),t.bind(F,n._onClose.bind(n)),t.wrapper.find(le+c).each(((t,i)=>{var r=e(i);r.data("kendoButton")&&r.data("kendoButton").bind(z,(e=>{n.trigger(z,{id:e.id,target:e.target,originalEvent:e.originalEvent||e.event})}))}))},_childrenWidth:function(){var t=parseInt(this.element.css("gap"),10)||0,n=t;return this.element.children(":visible:not(."+p+")").each((function(){n+=a(e(this),!1)+t})),Math.ceil(n)},_extendToolsOptions:function(){var e=this.options,t=e.tools.flatMap((t=>this._mapTool(t,e.parentMessages,e.defaultTools)));return this.options.items=t,t},_focusIn:function(t){var n=e(t.target).closest(le+c);n.length>0&&(this._resetTabIndex(n),n.addClass(T))},_focusOut:function(e){this.wrapper.find(le+c+le+T).removeClass(T)},_getAllItems:function(){return this.wrapper.find(X).filter(":visible").filter(((e,t)=>"hidden"!==t.style.visibility))},_getItem:function(t,i){var r,o,a=i||this._getUid(t),s=e(Q);return a?(r="[data-uid="+a+"]",{toolbarEl:o=this.element.find(r),templateEl:o.closest(le+k+ce+le+u),component:n.widgetInstance(o),menuItem:this.overflowMenu?this.overflowMenu.element.find(r):e(oe),buttonsPopupItem:s.find(r)}):{toolbarEl:this.element.find(t),templateEl:e(oe),menuItem:this.overflowMenu?this.overflowMenu.element.find(t):e(oe),buttonsPopupItem:e(oe)}},_getNextElement:function(e,t){var n=this._getAllItems(),i=-1===n.index(e)?n.index(e.parentElement):n.index(e),r=n[i+t];return r||(r=-1===t?n.last():n.first()),r},_getUid:function(t){var n;return(n=this.element.find(t)).length||(n=e(Q).find(t)),!n.length&&this.overflowMenu&&(n=this.overflowMenu.element.find(t)),n.length?n.data(ue)||n.closest(X).data(ue):null},_groupVisibleButtons:function(e){var t,n=e.children();n.removeClass(_).removeClass(v),(t=n.filter(":not('."+m+"')")).first().addClass(v),t.last().addClass(_)},_hideItem:function(t){var n=this;t.addClass(m),n.overflowMenu&&(t.hasClass(u)||t.hasClass(h)?((t.hasClass(u)?(t=t.children().eq(0)).data(pe):t.data(he)).menu.list.children().each(((t,i)=>{n._showMenuItem(e(i))})),n._showMenuItem(t)):t.hasClass(d)?t.children().each(((t,i)=>{n._showMenuItem(e(i))})):n._showMenuItem(t))},_hideMenuItem:function(e){this.overflowMenu.element.find(">li[data-uid='"+e.data(ue)+"']").addClass(m)},_items:function(){let e=this.options;for(var t=0;t<e.items.length;t++)this._add(e.items[t])},_keydown:function(t){var n=e(t.target),i=t.keyCode,r=n.closest(le+k),a=n.is(le+w);if(!this.options.navigateOnTab&&!n.is(X)&&i===o.ESC&&r.length>0)return t.stopPropagation(),void this._keyDeactivateTemplate(r);n.is(X)&&(!this.options.navigateOnTab&&i===o.ENTER&&n.hasClass(k)?this._keyActivateTemplate(n):a&&(t.altKey&&i===o.DOWN||i===o.SPACEBAR)?this._keyOpenOverflow(t,i):i===o.HOME?this._keyFocusFirst(n,t):i===o.END?this._keyFocusLast(n,t):this.options.navigateOnTab||i!==o.RIGHT&&i!==o.LEFT||this._keyFocusNext(i,t))},_keyActivateTemplate:function(e){var t=e.find(Z+":not('"+le+S+"')"+ce+le+C);const n=e.find(".k-pager");n.length>0?n.trigger(R):t.length>0&&(e.attr(U,-1),t.attr(U,0),t.first().trigger(R))},_keyDeactivateTemplate:function(e){var t,i=e.find(K),r=e.find(Z+":not('"+le+S+"')"+ce+le+C);if(i.length>0&&(t=n.widgetInstance(i))){if(t.overflowMenu&&t.overflowMenu.visible())return;e.attr(U,0),e.trigger(R),e.find(Z).attr(U,-1)}r.length>0&&(e.attr(U,0),e.trigger(R),r.attr(U,-1))},_keyFocusFirst:function(e,t){var n=this._getAllItems();e.is(le+C)||e.is(W)||(this._resetTabIndex(n.first()),n.first().trigger(R),t.preventDefault())},_keyFocusLast:function(e,t){var n,i=this._getAllItems();e.is(le+C)||e.is(W)||(0===(n=i.last()).width()&&(n=i.eq(i.length-2)),this._resetTabIndex(n),n.trigger(R),t.preventDefault())},_keyFocusNext:function(t,n){var i,r=this._isRtl?-1:1;t===o.LEFT&&(r*=-1),i=e(this._getNextElement(n.target,r)),this._resetTabIndex(i),i.trigger(R),n.preventDefault()},_keyOpenOverflow:function(e,t){t===o.SPACEBAR&&e.preventDefault(),this.overflowMenu.open()},_mapAttributes:function(e,t){return{"aria-label":t[e.name||e.property],title:t[e.name||e.property],"data-command":e.command,"data-options":e.options,"data-dialog":e.dialog,"data-property":e.property,"data-value":e.value,"data-toggle":e.toggleCondition}},_mapComponent:function(t,n){var i,r=this,o=t.componentOptions,a=o.messages,s=o.placeholder,l=e.extend({},r._mapAttributes(t,n),t.attributes);return t.overflowComponent&&(i=t.options||{},t.componentOptions.dataSource&&(i.options=t.componentOptions.dataSource),t.componentOptions.value&&(i.default=t.componentOptions.value),Object.keys(i).length>0&&(t.overflowComponent.options=JSON.stringify(i)),t.overflowComponent=r._mapTool(t.overflowComponent,n)),a&&Object.keys(a).forEach((e=>{t.componentOptions.messages[e]=n[a[e]]||a[e]})),s&&(t.componentOptions.placeholder=n[s]||s),Object.keys(o).forEach((e=>{"commandOn"===e&&(t.componentOptions[o[e]]=e=>{r.trigger(I,{target:e.target||e.sender.element})})})),o.dataSource&&o.dataSource.length&&(t.componentOptions.dataSource=o.dataSource.map((e=>(e.name&&n[e.name]&&(e.text=n[e.name]),e)))),t.attributes=l,t},_mapTool:function(t,i,r){let o,a,s,l,c=this,d=Array.isArray(t),u=e.isPlainObject(t),h=u&&Object.keys(t).length;return d?{type:"buttonGroup",buttons:t.map((e=>c._mapTool(e,i,r)))}:(o=u&&(1===h||2===h)&&t.name,l=o?t:{},t=o?t.name:t,a=e.isPlainObject(t)?t:e.extend({},r[t]),s=e.extend({},c._mapAttributes(a,i),a.attributes),n.deepExtend(a,{text:l.text||i[a.name||a.property],attributes:s}),"component"===a.type?a.items?a.items.map((e=>c._mapComponent(e,i))):c._mapComponent(a,i):("buttonGroup"===a.type?(delete a.attributes[E],a.buttons=a.buttons.map((e=>c._mapTool(e,i,r)))):"splitButton"===a.type?(delete a.attributes[E],a.menuButtons=a.menuButtons.flatMap((e=>c._mapTool(e,i,r)))):"popupButton"===a.type&&a.overflowComponent&&(a.overflowComponent=c._mapTool(a.overflowComponent,i)),delete a.name,a))},_menuItemSelect:function(t){var n,i,r=e(t.item),o=r.attr(de),a=r.find(le+x),s=r.data(q);o&&o.indexOf(ae+$)>-1&&(o=o.replace(ae+$,oe)),a.length?(s&&this.overflowMenu.element.find("[data-group="+s+"]").each(((t,n)=>{var i=e(n);i.attr(M,!1),i.find(le+x).removeClass(f)})),n=!!s||!a.hasClass(f),a.toggleClass(f,n),r.attr(M,n),(i=this.element.find("[data-uid="+r.data(ue)+"]")).length&&(i.closest(le+d).length?i.closest(le+d).data(me).select(i):(s&&this.element.find("[data-group="+s+"]").each(((t,n)=>{e(n).data(fe).toggle(!1)})),i.data(fe).toggle(!0))),this.trigger(P,{id:r.attr(de),target:r,checked:n})):this.trigger(z,{id:o,target:r})},_onClick:function(e){var t=e.target,n=t.hasClass("k-toolbar-toggle-button"),i=t.data(q);n||this.trigger(z,{id:e.id,target:e.target,originalEvent:e.originalEvent||e.event}),i&&this.element.find("[data-group="+i+"]").length>1&&t.hasClass(f)&&e.preventDefault()},_onClose:function(e){this.trigger(F,{widget:e.sender})&&e.preventDefault()},_onMenuItemSelect:function(t,n,i){var r=e(t.item),o=r.find(le+x).length>0,a=r.attr(de);a&&a.indexOf(ae+$)>-1&&(a=a.replace(ae+$,oe)),n&&n.bind(this)({event:t.event,id:a,target:r}),o&&i&&setTimeout((()=>{i.bind(this)({event:t.event,id:a,target:r,checked:r.find(le+f).length>0})}))},_onOpen:function(e){this.trigger(H,{widget:e.sender})&&e.preventDefault()},_onSelect:function(t){var n=this.overflowMenu?this.overflowMenu.element:e(oe);t.sender.element.children().each(((t,i)=>{var r=e(i),o=r.data(ue),a=r.hasClass(f);n.find("[data-uid="+o+"]").attr(M,a).find(le+x).toggleClass(f,a)})),this.trigger(P,{id:t.target.attr(de),target:t.target,checked:t.target.hasClass(f)})},_onToggle:function(t){var n,i=this,r=t.target,o=r.data(q);i.overflowMenu&&(n=i.overflowMenu.element.find("[data-uid="+r.attr(G)+"]"),i.overflowMenu.element.find("[data-group="+o+"]").attr(M,!1).find(le+x).removeClass(f),n.attr(M,!0).find(le+x).addClass(f)),o&&i.element.find("[data-group="+o+"]").each(((t,n)=>{n!==r[0]&&e(n).data(fe).toggle(!1)})),this.trigger(P,{id:t.id,target:t.target,checked:t.checked,originalEvent:t.originalEvent||t.event})},_processInner(e,t){for(var i,r=0;r<e.length;r++)(i=e[r]).attributes||(e[r].attributes={}),e[r].attributes[G]=n.guid(),e[r].attributes["data-parentuid"]=t,i.id&&(e[r].attributes[de]=e[r].id),i.hidden&&(e[r].attributes.class||(e[r].attributes.class=oe),e[r].attributes.class+=se+m+se+g);return e},_processOptions:function(i){let r,o=i.template,a=i.overflowTemplate,s=n.guid();return e.extend(i,{uid:s,fillMode:i.fillMode?i.fillMode:this.options.fillMode,rootUid:this.uid}),i.menuButtons?i.menuButtons=this._processInner(i.menuButtons,s):i.buttons&&i.buttons.length&&(i.buttons=this._processInner(i.buttons,s),i.buttons.some((e=>e.togglable))?(r=i.buttons[0].group,r&&i.buttons.every((e=>e.group===r))?i.selection="single":i.selection="multiple"):i.selection="none"),o&&!a||i.type===B?i.overflow=te:i.overflow||(i.overflow=ne),i.enable!==t&&(i.enabled=i.enable),i},_renderOverflow:function(){var t=this,i=t._isRtl?"left":"right";t.overflowAnchor=e("<button class='k-toolbar-overflow-button' title='More tools'>"),t.overflowAnchor.attr(V+A,""),t.element.append(t.overflowAnchor),t.overflowAnchor.kendoButton({icon:"more-vertical",fillMode:"flat",size:t.options.size}),t.options.navigateOnTab||t.overflowAnchor.attr(U,-1),t.overflowMenu=new n.ui.ContextMenu(e("<ul>"),{size:t.options.size,showOn:"click tap",origin:"bottom "+i,position:"top "+i,alignToAnchor:!0,target:t.overflowAnchor,open:function(e){t.trigger(J)&&e.preventDefault()},close:function(e){t.trigger(ee)?e.preventDefault():(t._resetTabIndex(t.overflowAnchor),t.overflowAnchor.trigger(R))}}),t.overflowMenu.element.attr(re,this.uid),setTimeout((()=>{t.overflowMenu.bind(j,t._menuItemSelect.bind(t))}))},_resetOpen:function(t,i){var r,o,a=this;t.closest(".k-upload-button-wrap").find("input").remove(),r=t.wrap("<div class='k-upload-button-wrap'></span>").parent(),o=e("<input type='file' autocomplete='off' accept='"+i+"'/>").attr("aria-hidden",!0).one("change",(e=>{a.trigger(I,{target:t,value:e.target.files[0]}),a._resetOpen(t,i)})).appendTo(r),t.off(L).on(L,(e=>{e.keyCode===n.keys.ENTER&&o.trigger(z)}))},_resetTabIndex:function(e){!0!==this.options.navigateOnTab&&(this.wrapper.find(Z).attr(U,-1),e.attr(U,0))},_resizable:function(){var e=this,t=e.element;e._renderOverflow(),t.addClass("k-toolbar-resizable"),e._resizeHandler=n.onResize((function(){e.resize()}))},_resize:function(t){var i=t.width,r=this.element,o=r.find('[data-role="splitbutton"]').add(r.find('[data-role="dropdownbutton"]'));this.options.resizable&&(this.overflowMenu.close(),o.length>0&&o.each(((t,i)=>{n.widgetInstance(e(i)).close()})),this._shrink(i),this._stretch(i),this._toggleOverflowAnchor())},_shrink:function(t){var n,i,r;if(t<this._childrenWidth())for(var o=(i=this.element.children(":visible:not([data-overflow='never'], ."+w+")")).length-1;o>=0&&(n=i.eq(o),!(t>this._childrenWidth()));o--)(r=n.find("[tabindex=0]")||n.is("[tabindex=0]")?n:e(oe)).length>0&&(r.attr(U,-1),this.element.children(le+w).attr(U,0)),this._hideItem(n)},_showItem:function(t,n){var i=this,r=parseInt(this.element.css("gap"),10)||0;t.removeClass(m);var o=a(t,!0)+r;return t.addClass(m),!(!t.length||!(t.hasClass(p)||n>this._childrenWidth()+o))&&(t.removeClass(m),!0!==this.options.navigateOnTab?t.find(Z).attr(U,-1):t.is("[tabindex=-1]")&&t.removeAttr(U),this.overflowMenu&&(t.hasClass(u)||t.hasClass(h)?((t.hasClass(u)?(t=t.children().eq(0)).data(pe):t.data(he)).menu.list.children().each(((t,n)=>{i._hideMenuItem(e(n))})),i._hideMenuItem(t)):t.hasClass(d)?t.children().each(((t,n)=>{i._hideMenuItem(e(n))})):i._hideMenuItem(t)),!0)},_showMenuItem:function(e){var t=this.overflowMenu.element.find(">li[data-uid='"+e.data(ue)+"']");t.hasClass(g)||t.removeClass(m)},_stretch:function(e){var t,n,i=this.element.children(le+w);if(e>this._childrenWidth()){n=this.element.children(le+m+":not("+le+g+")");for(var r=0;r<n.length&&(t=n.eq(r),!(e<this._childrenWidth())&&this._showItem(t,e));r++);}!this.options.navigateOnTab&&i.is("[tabindex=0]")&&(i.attr(U,-1),this._resetTabIndex(this._getAllItems().first()))},_tabIndex:function(){var e=this.wrapper.find(Z+":not('"+D+"')"),t=e.first();!0!==this.options.navigateOnTab?(e.attr(U,-1),t.attr(U,0)):this.wrapper.find(".k-toolbar-item").removeAttr(U)},_toggleOverflowAnchor:function(){this.overflowMenu.element.children(":not(."+m+", .k-popup)").length>0?this.overflowAnchor.removeClass(m):this.overflowAnchor.addClass(m)}});n.toolbar={Item:n.Class,OverflowButton:n.Class,TemplateItem:n.Class,ToolBarButton:n.Class,registerComponent:()=>null},n.cssProperties.registerPrefix("ToolBar","k-toolbar-"),n.cssProperties.registerValues("ToolBar",[{prop:"fillMode",values:["solid","flat"]}]),n.ui.plugin(ye)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.ui,o="k-loader",a="k-loader-canvas",s="k-loader-segment",l={pulsing:{className:"pulsing-2",segments:2},"infinite-spinner":{className:"spinner-3",segments:3},"converging-spinner":{className:"spinner-4",segments:4}},c=i.extend({init:function(e,t){var r=this;i.fn.init.call(r,e,t),r._render(),r._appearance(),n.notify(r)},destroy:function(){i.fn.destroy.call(this)},options:{name:"Loader",themeColor:"primary",sizes:{small:"sm",medium:"md",large:"lg"},size:"medium",type:"pulsing",visible:!0,messages:{loading:"Loading"},_classNames:[]},_render:function(){var n=this,i=n.element,r=n.options.type,o=l[r]===t?r:l[r],c=[];if(i.empty().attr("aria-label",n.options.messages.loading).attr("role","alert").attr("aria-live","polite"),o.segments)for(var d=0;d<o.segments;d+=1)c.push(e("<span/>").addClass(s));e("<div>").addClass(a).append(c).appendTo(i)},_appearance:function(){var e=this;e._themeColor=e.options.themeColor,e._sizes=e.options.sizes,e._size=e.options.size,e._type=e.options.type,e._visible=e.options.visible,e._updateClassNames()},_updateClassNames:function(){var n=this,i=[o],r=n.options._classNames,a=n._themeColor,s=n._sizes,c=n._size,d=n._type,u=l[d]===t?d:l[d],h=s[c]===t?c:s[c],p=n._visible;n.element.removeClass((function(e,t){0===t.indexOf("k-")&&-1===r.indexOf(t)&&n.element.removeClass(t)})),"string"==typeof a&&""!==a&&"inherit"!==a&&i.push("k-loader-"+a),"string"==typeof c&&""!==c&&""!==h&&i.push("k-loader-"+h),"string"==typeof d&&""!==d&&i.push("k-loader-"+(e.isPlainObject(u)?u.className:d)),!1===p&&i.push("k-hidden"),n.element.attr("aria-hidden",!p),n.element.addClass(i.join(" "))},setOptions:function(e){var t=this;i.fn.setOptions.call(t,e),t._render(),t._appearance()},themeColor:function(e){var n=this;if(0===arguments.length||e===t)return n._themeColor;n._themeColor=e,n._updateClassNames()},hide:function(){this._visible=!1,this._updateClassNames()},show:function(){this._visible=!0,this._updateClassNames()}});r.plugin(c)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.html.HTMLBase,i=n.extend({init:function(t,i){var r=this;n.fn.init.call(r,t,i),r.options=e.extend({},r.options,i),r._wrapper(),r._overlay(),r._innerContainer()},options:{name:"HTMLLoaderContainer",themeColor:"base",overlayColor:"dark",cssClass:"",message:"Loading...",loaderPosition:"start"},_wrapper:function(){var t,n=this.options;t=e(`<div class="k-loader-container k-loader-container-lg k-loader-${n.loaderPosition}${n.cssClass?` ${n.cssClass}`:""}"></div>`),this.wrapper=t},_overlay:function(){var t,n="k-overlay-"+this.options.overlayColor;t=e(`<div class='k-loader-container-overlay ${n}'></div>`),this.wrapper.append(t)},_innerContainer:function(){var t,n,i=this;n=e("<div class='k-loader-container-inner k-loader-container-panel'></div>"),i.loaderContainer=n,t=i._initMessage(),n.append(t),i.wrapper.append(n)},_initMessage:function(){var t=this.options,n=this.options.message;return e(`<div class='k-loader-container-label !k-text-${t.themeColor}'>${n}</div>`)}});e.extend(t.html,{renderLoaderContainer:function(t,n){return t&&!e.isPlainObject(t)||(n=t,t=e("<div></div>")),new i(t,n).html()},HTMLLoaderContainer:i})}(window.kendo.jQuery);kendo;let Df=kendo.jQuery;function Af(e,t){var n=this,i=n.wrapper;if(e&&n.loader){if(!n.wrapper.find(".k-loader-container").length){var r={message:"Loading...",overlayColor:"dark",themeColor:"primary"};r=Df.extend({},r,t);const e=kendo.html.renderLoaderContainer(Df("<div></div>"),r),o=n.wrapper.width(),a=Df("<div class='k-loading-pdf-mask'></div>"),s=n.wrapper.clone().removeAttr("id").addClass("k-loading-pdf-progress").width(o);a.append(s),a.append(e),n.mask=a,i.append(a),n.wrapperClone=a.find(".k-pivotgrid"),n.loaderOverlay=a.find(".k-loader-container"),n.loader.element.insertBefore(a.find(".k-loader-container-label"))}}else n.loaderOverlay.length&&(kendo.destroy(n.loaderOverlay),n.mask.remove())}!function(e){var t=window.kendo,n=t.ui.ContextMenu,i=e.extend,r=t.htmlEncode,o="action",a=n.extend({init:function(e,t){var i=this;n.fn.init.call(i,e,t),i._overrideTemplates(),i._extendItems(),i.bind("select",i._onSelect.bind(i)),i.bind("open",i._onOpen.bind(i))},_overrideTemplates:function(){this.templates.sprite=({icon:e,spriteCssClass:n})=>`${e||n?t.ui.icon({icon:r(e||""),iconClass:r(n||"")}):""}`},defaultItems:{separator:{name:"separator",separator:!0},create:{name:"create",text:"Add",icon:"plus",command:"AddCommand",rules:"isEditable"},edit:{name:"edit",text:"Edit",icon:"pencil",command:"EditCommand",rules:"isEditable"},destroy:{name:"destroy",text:"Delete",icon:"trash",command:"DeleteCommand",rules:"isEditable"},select:{name:"select",text:"Select",icon:"table-body",rules:"isSelectable",items:[{name:"selectRow",text:"Row",icon:"table-row-groups",command:"SelectRowCommand"},{name:"selectAllRows",text:"All rows",icon:"grid",command:"SelectAllRowsCommand"},{name:"clearSelection",text:"Clear selection",icon:"table-unmerge",softRules:"hasSelection",command:"ClearSelectionCommand"}]},copySelection:{name:"copySelection",text:"Copy selection",icon:"page-header-section",rules:"isSelectable",softRules:"hasSelection",command:"CopySelectionCommand",options:"withHeaders"},copySelectionNoHeaders:{name:"copySelectionNoHeaders",text:"Copy selection (No Headers)",icon:"file-txt",rules:"isSelectable",softRules:"hasSelection",command:"CopySelectionCommand"},paste:{name:"paste",text:"Paste (use CTRL/⌘ + V)",rules:"allowPaste",softRules:"alwaysDisabled",icon:"clipboard"},reorderRow:{name:"reorderRow",text:"Reorder row",icon:"caret-alt-expand",rules:"isRowReorderable",softRules:"isSorted",items:[{name:"reorderRowUp",text:"Up",icon:"caret-alt-up",command:"ReorderRowCommand",options:"dir:up"},{name:"reorderRowDown",text:"Down",icon:"caret-alt-down",command:"ReorderRowCommand",options:"dir:down"},{name:"reorderRowTop",text:"Top",icon:"caret-alt-to-top",command:"ReorderRowCommand",options:"dir:top"},{name:"reorderRowBottom",text:"Bottom",icon:"caret-alt-to-bottom",command:"ReorderRowCommand",options:"dir:bottom"}]},exportPDF:{name:"exportPDF",text:"Export to PDF",icon:"file-pdf",command:"ExportPDFCommand"},exportExcel:{name:"exportExcel",text:"Export to Excel",icon:"file-excel",items:[{name:"exportToExcelAll",text:"All",command:"ExportExcelCommand"},{name:"exportToExcelSelection",text:"Selection",command:"ExportExcelCommand",softRules:"hasSelection",options:"selection,withHeaders"},{name:"exportToExcelSelectionNoHeaders",text:"Selection (No Headers)",softRules:"hasSelection",command:"ExportExcelCommand",options:"selection"}]},sortAsc:{name:"sortAsc",text:"Sort Ascending",icon:"sort-asc-small",rules:"isSortable",command:"SortCommand",options:"dir:asc"},sortDesc:{name:"sortDesc",text:"Sort Descending",icon:"sort-desc-small",rules:"isSortable",command:"SortCommand",options:"dir:desc"},moveGroupPrevious:{name:"moveGroupPrevious",text:"Move previous",icon:"arrow-left",rules:"isGroupable",softRules:"canMoveGroupPrev",command:"MoveGroupCommand",options:"dir:prev"},moveGroupNext:{name:"moveGroupNext",text:"Move next",icon:"arrow-right",rules:"isGroupable",softRules:"canMoveGroupNext",command:"MoveGroupCommand",options:"dir:next"}},events:n.fn.events.concat([o]),_onSelect:function(t){var n=e(t.item).data("command"),i=e(t.item).data("options");i=i?i.split(",").map((e=>{if(e.indexOf(":")>-1){var[t,e]=e.split(":");return{[t||"_"]:e}}return{[e]:!0}})).reduce(((e,t)=>Object.assign(e,t)),{}):{};var r=e(t.target);n&&this.action({command:n,options:Object.assign(i,{target:r})})},_onOpen:function(n){var i=n.sender,r=i.options.items,o=e(n.event?n.event.target:null);!r&&e.isEmptyObject(this.defaultItems)||o.closest(".k-grid-column-menu").length?n.preventDefault():(this._toggleSeparatorVisibility(),i.element.find(`[${t.attr("soft-rules")}]`).each(((n,r)=>{var a=e(r).attr(t.attr("soft-rules")).split(";");i.enable(r,this._validateSoftRules(a,o))})))},_toggleSeparatorVisibility:function(){this.element.find(".k-item.k-separator").filter(((t,n)=>{var i=e(n).prev(".k-item:not(.k-separator)"),r=e(n).next(".k-item:not(.k-separator)");return!(i.length&&r.length)})).hide()},_extendItems:function(){var t,n=this,i=n.options.items;if(i&&i.length)for(var r=0;r<i.length;r++)t=i[r],e.isPlainObject(t)&&1===Object.keys(t).length&&t.name&&(t=t.name),e.isPlainObject(t)?n._append(t):n.defaultItems[t]?(t=n.defaultItems[t],n._append(t)):"string"==typeof t&&(t={name:t,text:t,spriteCssClass:t,command:t+"Command"},n._append(t));else for(var o in n.defaultItems)t=n.defaultItems[o],n._append(t)},_extendItem:function(e){var n=this,r=n.options.messages,o=e.attr||{};if(e.command&&(o[t.attr("command")]=e.command),e.options&&(o[t.attr("options")]=e.options),e.softRules&&(o[t.attr("soft-rules")]=e.softRules),e.items)for(var a=0;a<e.items.length;a++)e.items.forEach((e=>{n._extendItem(e)}));i(e,{text:r.commands[e.name],icon:e.icon||"",spriteCssClass:e.spriteCssClass||"",attr:o,uid:t.guid()})},_validateSoftRules:function(e,t){if(!e||!e||!e.length)return!0;for(var n=0;n<e.length;n++)if(!this._readState(e[n],t))return!1;return!0},_validateRules:function(e){var t=e.rules?e.rules.split(";"):[];if(!t.length)return!0;for(var n=0;n<t.length;n++)if(!this._readState(t[n]))return!1;return!0},_readState:function(e,n){var i=this.options.states;return t.isFunction(i[e])?i[e](n):i[e]},_append:function(e){var t=this;t._extendItem(e),t._validateRules(e)&&t.append(e)},action:function(e){this.trigger(o,e)}});t.ui.grid=t.ui.grid||{},i(t.ui.grid,{ContextMenu:a})}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.Class.extend({init:function(e){this.options=e,this.grid=e.grid}}),r=i.extend({exec:function(){var e=this.grid.groupable,t=this.options,n=t.target.closest(".k-chip"),i="next"===t.dir?"after":"before";("next"===t.dir?n.next():n.prev())[i](n),e._change()}}),o=i.extend({exec:function(){var e,t,n=this.grid,i=n.dataSource,r=i.sort()||[],o=this.options,a=o.dir,s=n._getCellField(o.target),l=n.options.sortable.mode&&"multiple"===n.options.sortable.mode,c=n.options.compare;if(l){for(t=0,e=r.length;t<e;t++)if(r[t].field===s){r.splice(t,1);break}r.push({field:s,dir:a,compare:c})}else r=[{field:s,dir:a,compare:c}];i.sort(r)}}),a=i.extend({exec:function(){this.grid.addRow()}}),s=i.extend({exec:function(){var e=this,t=e.grid,n="incell"===t._editMode(),i=n?e.options.target:e.options.target.closest("tr");n?t.editCell(i):t.editRow(i)}}),l=i.extend({exec:function(){var e=this.grid,t=this.options.target.closest("tr");e.removeRow(t)}}),c=i.extend({exec:function(){var e=this.grid,t=this.options.withHeaders;e.copySelectionToClipboard(t)}}),d=i.extend({exec:function(){var e=this.grid,n=t.ui.Selectable.parseOptions(e.options.selectable),i=this.options.target.closest("tr");e.select(n.cell?i.find("td"):i)}}),u=i.extend({exec:function(){var e=this.grid,n=t.ui.Selectable.parseOptions(e.options.selectable),i=e.items();e.select(n.cell?i.find("td"):i)}}),h=i.extend({exec:function(){this.grid.clearSelection()}}),p=i.extend({exec:function(){var e,t=this,n=t.grid,i=t.options.dir,r=t.options.target.closest("tr"),o=r.index();switch(i){case"up":e=o-1;break;case"down":e=o+2;break;case"top":e=0;break;case"bottom":e=n.items().length}n.reorderRowTo(r,e)}}),f=i.extend({exec:function(){this.grid.saveAsPDF()}}),m=i.extend({exec:function(){var e=this,t=e.options.selection,n=e.options.withHeaders,i=e.grid;t?i.exportSelectedToExcel(n):i.saveAsExcel()}});t.ui.grid=t.ui.grid||{},n(t.ui.grid,{GridCommand:i,commands:{SortCommand:o,AddCommand:a,EditCommand:s,DeleteCommand:l,CopySelectionCommand:c,SelectRowCommand:d,SelectAllRowsCommand:u,ClearSelectionCommand:h,ReorderRowCommand:p,ExportPDFCommand:f,ExportExcelCommand:m,MoveGroupCommand:r}})}(window.kendo.jQuery);!function(e,t){let n=window.kendo,i=n.ui,r=n.data.DataSource,o=n.data.ObservableObject,a=n.support.tbodyInnerHtml,s=n._activeElement,l=i.Widget,c=n._outerWidth,d=n._outerHeight,u=n.keys,h=n.type,p=e.isPlainObject,f=e.extend,m=e.map,g=e.grep,v=Array.isArray,_=e.inArray,b=Array.prototype.push,y=n.isFunction,w=n.htmlEncode,k=e.isEmptyObject,x=e.contains,C=Math,S=".",T="progress",D="error",A=":not(.k-group-cell):not(["+n.attr("virtual")+"]):not(.k-hierarchy-cell:not(:has(.k-icon.k-i-caret-alt-down,.k-icon.k-i-caret-alt-right,.k-svg-icon.k-svg-i-caret-alt-down,.k-svg-icon.k-svg-i-caret-alt-right,.k-svg-icon.k-svg-i-caret-alt-left,.k-icon.k-i-caret-alt-left))):visible",M=":not(["+n.attr("virtual")+"]):not(.k-hierarchy-cell:not(:has(.k-icon.k-i-caret-alt-down,.k-icon.k-i-caret-alt-right,.k-svg-icon.k-svg-i-caret-alt-down,.k-svg-icon.k-svg-i-caret-alt-right,.k-svg-icon.k-svg-i-caret-alt-left,.k-icon.k-i-caret-alt-left)))",E="tr:not(.k-footer-template):visible",I=":not(.k-group-cell):not(.k-detail-cell):not(.k-hierarchy-cell):visible",z="tr:not(.k-grouping-row):not(.k-detail-row):not(.k-footer-template):not(.k-group-footer):visible",P="col:not(.k-group-col, .k-hierarchy-col)",H="th.k-header:not(.k-group-cell):not(.k-hierarchy-cell)",F="a[class*='-i-caret-alt-down']",R="a[class*='-i-caret-alt-right']",L=R,B=".kendoGrid",O="edit",V="beforeEdit",N="save",$="remove",U="detailInit",W="filterMenuInit",j="columnMenuInit",q="filterMenuOpen",G="columnMenuOpen",K="cellClose",Y="changing",Q="change",X="columnHide",Z="columnShow",J="saveChanges",ee="dataBound",te="detailExpand",ne="detailCollapse",ie="itemchange",re="page",oe="paging",ae="paste",se="scroll",le="sync",ce="loadStart",de="loadEnd",ue="requestEnd",he="k-focus",pe="k-hover",fe="k-active",me=":kendoFocusable",ge="k-selected",ve="k-checkbox",_e="input[data-role='checkbox'].k-select-checkbox."+ve,be="k-grid-norecords",ye="k-link",we="k-icon",ke="k-svg-icon",xe="k-sort-order",Ce="k-sorted",Se="k-header",Te="k-grid-column-menu",De="k-grid-filter-menu",Ae="k-grid-content-sticky",Me="k-grid-header-sticky",Ee="k-grid-footer-sticky",Ie="k-grid-no-left-border",ze="k-grouping-row",Pe="resize",He="rowResize",Fe="columnResize",Re="columnReorder",Le="columnLock",Be="columnUnlock",Oe="columnStick",Ve="columnUnstick",Ne="rowReorder",$e="navigate",Ue="click",We="mousedown",je="mouseup",qe="mouseenter",Ge="mouseleave",Ke="mousemove",Ye="dblclick",Qe="height",Xe="width",Ze="auto",Je="tabIndex",et="function",tt="string",nt="bottom",it="container-for",rt="field",ot="input",at="incell",st="inline",lt="overflow",ct="sort",dt="group-sort",ut="Collapse",ht="Expand",pt="id",ft="px",mt="tr",gt="div",vt="aria-label",_t="aria-owns",bt="aria-rowcount",yt="aria-colcount",wt="aria-colindex",kt="aria-rowindex",xt="aria-expanded",Ct="aria-checked",St="aria-activedescendant",Tt="role",Dt="none",At="row",Mt="rowgroup",Et="columnheader",It="gridcell",zt=/(\}|\#)/gi,Pt="[\\x20\\t\\r\\n\\f]",Ht=(new RegExp("(\\s*left\\s*:\\s*\\d*px;?)*","ig"),new RegExp("(\\s*right\\s*:\\s*\\d*px;?)*","ig"),new RegExp("(^|"+Pt+")(k-group-cell|k-hierarchy-cell)("+Pt+"|$)")),Ft=new RegExp("(^|"+Pt+")(k-filter-row)("+Pt+"|$)"),Rt=({className:e,attr:t,text:i})=>`<button type="button" class="${e}" ${t}>${n.htmlEncode(i)}</button>`,Lt=(e,t)=>`<span class="k-checkbox-wrap"><input tabindex="-1" class="k-select-checkbox ${ve} ${e} k-rounded-md" data-role="checkbox" aria-label="${t}" aria-checked="false" type="checkbox"></span>`,Bt=({size:e})=>Lt(e,"Select row"),Ot=({size:e})=>Lt(e,"Select all rows"),Vt=()=>n.ui.icon("reorder"),Nt=({text:e})=>`<span class="k-cell-inner"><span class="k-link"><span class="k-column-title">${e}</span></span></span>`,$t=!1,Ut=n.support.browser;var Wt,jt=Ut.msie&&11===Ut.version,qt=/Mac OS/.test(navigator.userAgent),Gt="k-content",Kt="k-scroll-container",Yt="k-cell-inner",Qt=["copySelection","copySelectionNoHeaders","paste","separator","create","edit","destroy","select","separator","reorderRow","exportPDF","exportExcel","separator"],Xt=["sortAsc","sortDesc","separator"],Zt=["moveGroupPrevious","moveGroupNext","separator"];i.Pager&&(Wt=i.Pager.extend({init:function(e,t){i.Pager.fn.init.call(this,e,f(!0,{},t)),this.dataSource.options.useRanges=!0,this.dataSource._omitPrefetch=!0},options:{name:"GroupsPager"},totalPages:function(){return Math.ceil((this._collapsedTotal()||0)/(this.pageSize()||1))},_collapsedTotal:function(){var e=this.dataSource;return e&&e.groupsTotal(!0)||0}}));var Jt=l.extend({init:function(e,t){var n=this;l.fn.init.call(n,e,t),n._refreshHandler=n.refresh.bind(n),n.setDataSource(t.dataSource),n.wrap()},setDataSource:function(e){var t=this;t.dataSource&&t.dataSource.unbind(Q,t._refreshHandler),t.dataSource=e,t.dataSource.bind(Q,t._refreshHandler),t.dataSource.options.useRanges=!0,t.dataSource.options.virtual=!0},options:{name:"VirtualScrollable",itemHeight:e.noop,prefetch:!0,maxScrollHeight:25e4},events:[oe,re,se,ce,de],destroy:function(){var e=this;l.fn.destroy.call(e),e.dataSource.unbind(Q,e._refreshHandler),e.wrapper.add(e.verticalScrollbar).off(B),clearTimeout(e._timeout),e._scrollingTimeout&&clearTimeout(e._scrollingTimeout),e.drag&&(e.drag.destroy(),e.drag=null),e.wrapper=e.element=e.verticalScrollbar=null,e._refreshHandler=null},wrap:function(){var t,i=this,r=n.support.scrollbar()+1,o=i.element;o.css({width:Ze,overflow:"hidden"}).css($t?"padding-left":"padding-right",r),i.content=o.children().first(),t=i.wrapper=i.content.wrap('<div class="k-virtual-scrollable-wrap"/>').parent().on("DOMMouseScroll"+B+" mousewheel"+B,i._wheelScroll.bind(i)),i._wrapper(),(n.support.kineticScrollNeeded||n.support.touch)&&(i.wrapper.css("touch-action",Dt),i.drag=new n.UserEvents(i.wrapper,{global:!0,allowSelection:!0,start:function(e){e.sender.capture()},move:function(e){i.verticalScrollbar.scrollTop(i.verticalScrollbar.scrollTop()-e.y.delta),n.scrollLeft(t,n.scrollLeft(t)-e.x.delta),e.preventDefault()}})),i.verticalScrollbar=e('<div class="k-scrollbar k-scrollbar-vertical" tabindex="-1"/>').css({width:r}).appendTo(o).on("scroll"+B,i._scroll.bind(i))},_wrapper:function(){jt&&(this.wrapper.css({"overflow-y":se}),this.element.css($t?"padding-left":"padding-right",0))},_wheelScroll:function(e){if(!e.ctrlKey){var t=this.verticalScrollbar,i=t.scrollTop(),r=n.wheelDeltaY(e);!r||r>0&&0===i||r<0&&i+t[0].clientHeight==t[0].scrollHeight||(e.preventDefault(),this.verticalScrollbar.scrollTop(i+-r))}},_scroll:function(e){var t=this,n=!t.options.prefetch,i=e.currentTarget.scrollTop,r=t.dataSource,o=t.itemHeight,a=r.skip()||0,s=t._rangeStart||a,l=t.element.innerHeight(),c=!!(t._scrollbarTop&&t._scrollbarTop>i),d=C.max(C.floor(i/o),0),u=c?C.ceil(l/o):C.floor(l/o),h=C.max(d+u,0);t._preventScroll?t._preventScroll=!1:(t._prevScrollTop=t._scrollTop,t._scrollTop=i-s*o,t._scrollbarTop=i,t._scrolling=n,t._fetch(d,h,c)||(t.wrapper[0].scrollTop=t._scrollTop),t.trigger(se),n&&(t._scrollingTimeout&&clearTimeout(t._scrollingTimeout),t._scrollingTimeout=setTimeout((function(){t._scrolling=!1,t._page(t._rangeStart,t.dataSource.take())}),100)))},scrollToTop:function(){this._scrollTo(0)},scrollToBottom:function(){var e=this.verticalScrollbar;this._scrollTo(e[0].scrollHeight-e.height())},_scrollWrapperToTop:function(){this.wrapper.scrollTop(0)},_scrollWrapperToBottom:function(){this.wrapper.scrollTop(this.wrapper[0].scrollHeight)},_scrollWrapperOnColumnResize:function(){var e=this,t=this.wrapper,i=t.scrollTop();t[0].scrollWidth>t[0].clientWidth?(!e._wrapperScrolled&&i||e._isScrolledToBottom())&&(t.scrollTop(i+n.support.scrollbar()),e._scrollTop=t.scrollTop(),e._wrapperScrolled=!0):e._wrapperScrolled&&(e._isWrapperScrolledToBottom()||(t.scrollTop(i-n.support.scrollbar()),e._scrollTop=t.scrollTop()),e._wrapperScrolled=!1)},_scrollTo:function(e,t){var n=this,i=n.verticalScrollbar;i.scrollTop()!==e&&(n._preventScroll=!0),n.wrapper.scrollTop(e),n._scrollTop=n.wrapper.scrollTop(),i.scrollTop(t??e),n._scrollbarTop=i.scrollTop()},_isScrolledToTop:function(){return 0===this.verticalScrollbar.scrollTop()},_isScrolledToBottom:function(){var e=this.verticalScrollbar,t=e.scrollTop();return t>0&&t>=parseInt(e[0].scrollHeight-e.height(),10)},_isWrapperScrolledToBottom:function(){var e=this.wrapper;return e.scrollTop()>=parseInt(e[0].scrollHeight-e.height(),10)},itemIndex:function(e){return(this._rangeStart||this.dataSource.skip()||0)+e},position:function(e){var t,n=this._rangeStart||this.dataSource.skip()||0,i=this.dataSource.pageSize();return(t=e>n?e-n:n-e-1)>i?i:t},scrollIntoView:function(e){var t=this.wrapper[0],n=t.clientHeight,i=this._isScrolledToBottom()?t.scrollTop:this._scrollTop||t.scrollTop,r=e[0].offsetTop,o=e[0].offsetHeight;i>r?this.verticalScrollbar[0].scrollTop-=n/2:r+o>=i+n&&(this.verticalScrollbar[0].scrollTop+=n/2)},_fetch:function(t,n,i){var r=this,o=r.dataSource,a=r.itemHeight,s=o.take(),l=r._rangeStart||o.skip()||0,c=C.floor(t/s)*s,d=!1,u=r.verticalScrollbar,h=Ut.webkit?1:0,p=o._isGroupPaged()?o.groupsTotal(!0):o.total();return t<l?(d=!0,r._alwaysScrollTop?(l=C.min(t,p-s),r._scrollTop=0):(l=C.max(0,n-s),r._scrollTop=u.scrollTop()-l*a),r._page(l,s)):n>=l+s&&!i?(d=!0,l=C.min(t,p-s),u.scrollTop()>=u[0].scrollHeight-u[0].offsetHeight-h?r._scrollTop=r.wrapper[0].scrollHeight-r.wrapper[0].offsetHeight:r.dataSource._isGroupPaged()&&t>=p-s?r._scrollTop=r.wrapper[0].scrollHeight-r.wrapper[0].offsetHeight-(r._scrollTop-r._prevScrollTop):r._alwaysScrollTop?r._scrollTop=0:r._scrollTop=a,r._page(l,s)):!r._fetching&&r.options.prefetch&&(t<c+s-.33*s&&t>s&&o.prefetch(c-s,s,e.noop),n>c+.33*s&&o.prefetch(c+s,s,e.noop)),d},fetching:function(){return this._fetching},_page:function(t,n,i){var r=this,o=!r.options.prefetch,a=r.dataSource,s=a._isGroupPaged();i=y(i)?i:e.noop,r.trigger(oe,{skip:t,take:n})||(clearTimeout(r._timeout),r._fetching=!0,r._rangeStart=t,s&&a._groupRangeExists(t,t+n)||!s&&a.inRange(t,n)?(r.trigger(ce),a.range(t,n,(function(){r.trigger(de),i(),r.trigger(re)}),"page")):(o||r.trigger(ce),r._timeout=setTimeout((function(){r._scrolling||(o&&r.trigger(ce),a.range(t,n,(function(){r.trigger(de),i(),r.trigger(re)})))}),100)))},repaintScrollbar:function(t){var i,r,o=this,a=o.options.maxScrollHeight,s=o.dataSource,l=n.support.kineticScrollNeeded?0:n.support.scrollbar(),c=o.wrapper[0],d=o._isScrolledToBottom();r=o.itemHeight=o.options.itemHeight()||0;var u=c.scrollWidth>c.offsetWidth?l:0;i=(s._isGroupPaged()?s.groupsTotal(!0):s.total())*r+u;var h=e(new Array(C.floor(i/a)+1).join("<div></div>")).css({width:"1px",height:`${a}px`});i%a&&(h=h.add(e("<div></div>").css({width:"1px",height:i%a+"px"}))),o.verticalScrollbar.empty().append(h),!d||o._isScrolledToBottom()||o.dataSource._isGroupPaged()||o.scrollToBottom(),void 0!==o._scrollTop&&t&&(c.scrollTop=o._scrollTop,o._scrollWrapperOnColumnResize())},refresh:function(e){var t=this,n=t.dataSource,i=t._rangeStart,r=(e||{}).action,o=t._isScrolledToBottom()||!r||r!==ie&&r!==$&&r!==le;t.trigger(de),clearTimeout(t._timeout),t.repaintScrollbar(o),t.drag&&t.drag.cancel(),void 0===i||t._fetching||((!r||r!==le&&r!==ie&&"expandGroup"!==r)&&(t._rangeStart=n.skip()),1!==n.page()||r&&(r===le||r===ie||"expandGroup"===r||"collapseGroup"===r)||(t.verticalScrollbar[0].scrollTop=0)),t._programmaticallyScrolling&&"resolved"!==t._programmaticallyScrolling.state()&&t._programmaticallyScrolling.resolve(),t._alwaysScrollTop&&delete t._alwaysScrollTop,t._fetching=!1}});function en(e,t){return"["+n.attr(e)+"="+t+"]"}function tn(e){return new Array(e+1).join('<td class="k-group-cell k-table-group-td k-table-td">&nbsp;</td>')}function nn(e){var t,n=" ";if(e){if(typeof e===tt)return e;for(t in e)""!==e[t]&&(n+=t+'="'+e[t]+'"')}return n}var rn={create:{text:"Add new record",className:"k-grid-add",iconClass:"k-i-plus"},cancel:{text:"Cancel changes",className:"k-grid-cancel-changes",iconClass:"k-i-cancel"},save:{text:"Save changes",className:"k-grid-save-changes",iconClass:"k-i-check"},destroy:{text:"Delete",className:"k-grid-remove-command",iconClass:"k-i-x"},edit:{text:"Edit",className:"k-grid-edit-command",iconClass:"k-i-pencil",themeColor:"primary"},update:{text:"Save",className:"k-grid-save-command",iconClass:"k-i-save",themeColor:"primary"},canceledit:{text:"Cancel",className:"k-grid-cancel-command",iconClass:"k-i-cancel"},excel:{text:"Export to Excel",className:"k-grid-excel",iconClass:"k-i-file-excel"},pdf:{text:"Export to PDF",className:"k-grid-pdf",iconClass:"k-i-file-pdf"},search:{text:"Search...",className:"k-grid-search"},columns:{text:"Columns",type:"button",icon:"columns",fillMode:"flat",overflow:"never",className:"k-grid-column-menu",attr:{"aria-haspopup":"menu"}}};function on(t,n){e("th, th .k-grid-filter-menu, th .k-link",t).add(document.body).css("cursor",n)}function an(t,n,i,r,o){var a=n;n=e(),o=o||1;for(var s=0;s<o;s++)n=n.add(t.eq(a+s));"number"==typeof i?n[r?"insertBefore":"insertAfter"](t.eq(i)):n.appendTo(i)}function sn(t,n,i){return e(t).add(n).find(i)}function ln(e,t,n){var i,r,o,a;for(i=0,r=(n=v(n)?n:[n]).length;i<r;i++)o=n[i],p(o)&&o.click&&(a=o.name||o.text,t.on(Ue+B,".k-grid-"+(a||"").replace(/\s/g,""),{commandName:a},o.click.bind(e)))}function cn(e,i,r,o,a){return m(e,(function(e){var s;(e=typeof e===tt?{field:e}:e).parentIds=a,e.attributes instanceof Function&&(e._attributesFunction=e.attributes),!bn(e)||r?(e.attributes=si(e.attributes),e.footerAttributes=si(e.footerAttributes),e.headerAttributes=si(e.headerAttributes),s=!0):!bn(e)&&r||(e.attributes=li(e.attributes),e.footerAttributes=li(e.footerAttributes),e.headerAttributes=li(e.headerAttributes),s=t);var l=n.guid();return o&&!e.locked&&(e.locked=o),e.headerAttributes=f({headers:a},e.headerAttributes),e.headerAttributes.id?e.uid=l=e.headerAttributes.id:(e.headerAttributes=f({id:l},e.headerAttributes),e.uid=l),e.columns&&(e.columns=cn(e.columns,i,s,e.locked,a?a+" "+l:l)),f({encoded:i,hidden:s,locked:o},e)}))}function dn(e,t){var n=[];return un(e,t,n),n[n.length-1]}function un(e,t,n){n=n||[];for(var i=0;i<t.length;i++){if(e===t[i])return!0;if(t[i].columns){var r=n.length;if(n.push(t[i]),un(e,t[i].columns,n))return!0;n.splice(r,n.length-r)}}return!1}function hn(e,t){pn(e,t,t)}function pn(e,t,n){var i=n?li:si;e.hidden=!t,e.attributes=i(e.attributes),e.footerAttributes=i(e.footerAttributes),e.headerAttributes=i(e.headerAttributes)}function fn(e,t){mn(e),pn(e,t,e._hideByMedia?e.matchesMedia:t)}function mn(e){e.matchesMedia=gn(e)}function gn(e){return e&&(kn(e.media)||!kn(e.media)&&n.matchesMedia(e.media))}function vn(){return this.style.display!==Dt&&!this.classList.contains("k-hidden")}function _n(t){return e(t)[0].style.display!==Dt&&!e(t)[0].classList.contains("k-hidden")}function bn(e){return yn([e]).length>0}function yn(e){return g(e,(function(e){var t=!e.hidden&&!1!==e.matchesMedia;return t&&e.columns&&(t=yn(e.columns).length>0),t}))}function wn(e){for(var t,n=[],i=0;i<e.length;i++){if(!kn((t=e[i]).media)){if(!kn(t.minScreenWidth))throw new Error("Using 'media' and 'minScreenWidth' options at the same time is not supported.");n.push(t)}t.columns&&(n=n.concat(wn(t.columns)))}return n}function kn(e){return void 0===e}function xn(t){return e(t).map((function(){return this.toArray()}))}function Cn(e,t){for(var n=0;n<e.length;n++)if(e[n].field==t)return e[n]}function Sn(t,n,i,r,o,a,s,l){var c=Dn(t),d=Dn([n]);if(c>d){var u=new Array(s+1).join('<th class="k-group-cell k-header k-table-th" scope="col">&nbsp;</th>'),h=a.children(":not(.k-filter-row)");e(new Array(c-d+1).join("<tr class='k-table-row'>"+u+"</tr>")).insertAfter(h.last())}!function(e,t){for(var n=e.find("tr:not(.k-filter-row) th:not(.k-group-cell,.k-hierarchy-cell)"),i=0;i<n.length;i++)n[i].rowSpan+=t}(a,c-d),An(i,r,o,a,l)}function Tn(t,i,r){var o;r=r||0;var a=i;i=ei(i);for(var s={},l=t.find(">tr:not(.k-filter-row)"),c=function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")},d=0,u=i.length;d<u;d++)s[(o=Mn(i[d],a)).row]||(s[o.row]=l.eq(o.row).find(S+Se).filter(c)),s[o.row].eq(o.cell).attr(n.attr("index"),r+d);return i.length}function Dn(e){for(var t=0,n=0;n<e.length;n++)if(e[n].columns){var i=Dn(e[n].columns);i>t&&(t=i)}return 1+t}function An(t,n,i,r,o){var a,s=zn(t[0],n),l=i.find(">tr:not(.k-filter-row)").eq(s.row).children("th.k-header:not(.k-group-cell)"),c=e(),d=s.cell;for(a=0;a<t.length;a++)c=c.add(l.eq(d+a));r.find(">tr:not(.k-filter-row)").eq(s.row)[o](c);var u=[];for(a=0;a<t.length;a++)t[a].columns&&(u=u.concat(t[a].columns));u.length&&An(u,n,i,r,o)}function Mn(e,t,n,i){var r,o;for((i=i||{})[n=n||0]=i[n]||0,o=0;o<t.length;o++){if(t[o]==e){r={cell:i[n],row:n};break}if(t[o].columns&&(r=Mn(e,t[o].columns,n+1,i)))break;i[n]++}return r}function En(e){let t=e,n=t.match(/class=["][^"]+/g);if(n){const e=n[0].split('"').pop();t=t.replace(e,e+" k-table-td")}else t=t.replace("<td","<td class='k-table-td'");return t}function In(e,t,n,i,r){if(t.columns)return(t=t.columns)[i?0:t.length-1];var o,a=dn(t,e);o=a?a.columns:e;var s=_(t,o);0===s&&i?s++:s==o.length-1&&!i||!n.locked&&!t.columns&&!i?s--:(s>0||0===s&&!i)&&s++,t=function(e,t,n,i){var r,o,a=!!n.locked;do{r=e[t],t+=i?1:-1,o=!!r.locked}while(r&&t>-1&&t<e.length&&r!=n&&!r.columns&&o===a);return r}(o,s,n,_(n,o)>s);var l=_(t,r);return(!t.columns||l&&l!==o.length-1)&&t&&t!=n&&t.columns?In(e,t,n,i,r):null}function zn(e,t,n,i){var r,o;for((i=i||{})[n=n||0]=i[n]||0,o=0;o<t.length;o++){if(t[o]==e){r={cell:i[n],row:n};break}if(t[o].columns&&(r=zn(e,t[o].columns,n+1,i)))break;t[o].hidden||i[n]++}return r}function Pn(e){return Fn(jn(e)).concat(Fn(qn(e)))}function Hn(e,t,n,i){var r=e[n],o=e[i],a=dn(r,t);return t=a?a.columns:t,_(o,t)}function Fn(e){for(var t=[],n=[],i=0;i<e.length;i++)t.push(e[i]),e[i].columns&&(n=n.concat(e[i].columns));return n.length&&(t=t.concat(Fn(n))),t}function Rn(e){for(var t,n=0,i=0;i<e.length;i++)(t=e[i]).columns?n+=Rn(t.columns):t.hidden&&n++;return n}function Ln(e){for(var t=0,n=0,i=e.length;n<i;n++)e[n].hidden||(t+=parseInt(e[n].width,10));return t}function Bn(e){for(var t,n=0,i=0,r=e.length;i<r;i++)(t=e[i].style.width)&&-1==t.indexOf("%")&&(n+=parseInt(t,10));return n}function On(t){for(var n=t.find("tr:not(.k-filter-row)"),i=n.filter((function(){return!e(this).children().length})).remove().length,r=n.find("th:not(.k-group-cell,.k-hierarchy-cell)"),o=0;o<r.length;o++)r[o].rowSpan>1&&(r[o].rowSpan-=i);return n.length-i}function Vn(e,t,n,i,r){var o,a,s,l=[];for(o=0,s=e.length;o<s;o++)(a=n[i]||[]).push(t.eq(r+o)),n[i]=a,e[o].columns&&(l=l.concat(e[o].columns));l.length&&Vn(l,t,n,i+1,r+e.length)}function Nn(e,t,n){e.css({left:t,right:n})}function $n(e,t,n){e[t]=e[t]||{},e[t][n]=e[t][n]||""}function Un(e,t,n,i){$n(e,t,n),""!==e[t][n]?e[t][n]+=" "+i:e[t][n]=i}function Wn(e,t,n,i,r){$n(e,t,n),r?delete e[t][n]:e[t][n]=e[t][n].replace(i,"")}function jn(e){return g(e,(function(e){return e.locked}))}function qn(e){return g(e,(function(e){return!e.locked}))}function Gn(e){return g(e,(function(e){return e.sticky&&!e.locked}))}function Kn(e){return g(e,(function(e){return!e.locked&&bn(e)}))}function Yn(e){return g(e,(function(e){return e.locked&&bn(e)}))}function Qn(e){for(var t=[],n=0;n<e.length;n++)e[n].hidden||(e[n].columns?t=t.concat(Qn(e[n].columns)):t.push(e[n]));return t}function Xn(e){for(var t=[],n=0;n<e.length;n++)e[n].hidden||(e[n].columns?t=t.concat(Qn(e[n].columns)):t.push({field:e[n].field,width:e[n].width,values:e[n].values,title:e[n].title}));return t}function Zn(e){for(var t=[],n=0;n<e.length;n++)e[n].columns&&(t=t.concat(e[n].columns));return t}function Jn(e){var t=Zn(e);return t=t.filter((function(e){return!e.hidden}))}function ei(e){for(var t=[],n=0;n<e.length;n++)e[n].columns?t=t.concat(ei(e[n].columns)):t.push(e[n]);return t}function ti(e){var t=[];e=ei(e);for(var n=0;n<e.length;n++)"string"==typeof e[n]?t.push(e[n]):e[n].field&&t.push(e[n].field);return t}function ni(e){return{field:e.field,title:e.title,format:e.format,editor:e.editor,values:e.values,editorOptions:f(!0,{format:e.format},e.editorOptions),label:e.title||e.field||""}}function ii(i){var r=i.find(">tr:not(.k-filter-row)"),o=function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")},a=e();r.length>1&&(a=r.find("th").filter(o).filter((function(){return this.rowSpan>1}))),a=a.add(r.last().find("th").filter(o));var s=n.attr("index");return[].sort.call(a,(function(n,i){n=e(n),i=e(i);var r=n.attr(s),o=i.attr(s);return r===t&&(r=e(n).index()),o===t&&(o=e(i).index()),(r=parseInt(r,10))>(o=parseInt(o,10))?1:r<o?-1:0}))}function ri(t){var n=t.closest("table"),i=e().add(t),r=t.closest(mt),o=n.find("tr:not(.k-filter-row)"),a=o.index(r);if(a>0){for(var s=o.eq(a-1).find("th:not(.k-group-cell,.k-hierarchy-cell)").filter((function(){return!e(this).attr("rowspan")})),l=0,c=r.find("th:not(.k-group-cell,.k-hierarchy-cell)").index(t),d=t.prevAll(":not(.k-group-cell,.k-hierarchy-cell)").filter((function(){return this.colSpan>1})),u=0;u<d.length;u++)l+=d[u].colSpan||1;for(c+=Math.max(l-1,0),l=0,u=0;u<s.length;u++){var h=s.eq(u);if(h.attr("data-colspan")?l+=h[0].getAttribute("data-colspan"):l+=1,c>=u&&c<l){i=ri(h).add(i);break}}}return i}function oi(t){var i=t.closest("thead"),r=e().add(t),o=t.closest(mt),a=i.find("tr:not(.k-filter-row)"),s=a.index(o)+t[0].rowSpan,l=n.attr("colspan");if(s<=a.length-1){var c,d=o.next(),u=t.prevAll(":not(.k-group-cell,.k-hierarchy-cell)");u=u.filter((function(){return!this.rowSpan||1===this.rowSpan}));var h=0;for(c=0;c<u.length;c++)h+=parseInt(u.eq(c).attr(l),10)||1;var p=d.find("th:not(.k-group-cell,.k-hierarchy-cell)"),f=parseInt(t.attr(l),10)||1;for(c=0;c<f;){d=p.eq(c+h),r=r.add(oi(d));var m=parseInt(d.attr(l),10);m>1&&(f-=m-1),c++}}return r}function ai(t,i,r,o){var s,l=t;if(a){let i=e(r);n.applyStylesFromKendoAttributes(i,["display","left","right"]),t.empty(),i.each(((e,n)=>t[0].appendChild(n)))}else(s=document.createElement(gt)).innerHTML="<table class='k-grid-table k-table'><tbody class='k-table-tbody'>"+r+"</tbody></table>",e(s).find("table").addClass(n.getValidCssClass("k-table-","size",o)),t=s.firstChild.firstChild,i[0].replaceChild(t,l[0]),t=e(t);return t}function si(e){e=e||{};let t={};return t[n.attr("style-display")]="none",f({},e,t)}function li(e){return delete(e=e||{})[n.attr("style-display")],e}function ci(t,i,r,o){var a,s=t.find(">colgroup"),l=m(i,(function(e){return(a=e.width)&&0!==parseInt(a,10)?n.format(`<col ${n.attr("style-width")}="{0}" ${e.draggable?"class=k-drag-col":""} />`,typeof a===tt?a:a+ft):e.draggable?"<col class='k-drag-col' />":"<col />"}));(r||s.find(".k-hierarchy-col").length)&&l.splice(0,0,'<col class="k-hierarchy-col" />'),s.length&&s.remove(),s=e(new Array(o+1).join('<col class="k-group-col">')+l.join("")),n.applyStylesFromKendoAttributes(s,["width"]),s.is("colgroup")||(s=e("<colgroup/>").append(s)),t.prepend(s)}function di(e){var t,n,i,r={};for(n=0,i=e.length;n<i;n++)r[(t=e[n]).value]=t.text;return r}function ui(e,t,i,r){let o=i&&i.length&&p(i[0])&&"value"in i[0]?di(i)[e]:e;o=null!=o?o:"";let a=!1===r?o:n.htmlEncode(o);return t?n.format(t,a):a}function hi(e,t,n){for(var i,r=0,o=e[r];o;){if(i=!!n||o.style.display!==Dt,n&&o.classList.contains("k-hidden")&&o.classList.remove("k-hidden"),i&&!Ht.test(o.className)&&--t<0){o.style.display=n?"":Dt;break}o=e[++r]}}function pi(t,n){for(var i,r,o=0,a=t.length;o<a;o+=1)(r=t.eq(o)).is(".k-grouping-row,.k-detail-row")?(i=r.children(":not(.k-group-cell):first,.k-detail-cell").last()).attr("colspan",parseInt(i.attr("colspan"),10)-1):(r.hasClass("k-grid-edit-row")&&(i=r.children(".k-edit-container")[0])&&((i=e(i)).attr("colspan",parseInt(i.attr("colspan"),10)-1),i.find("col").eq(n).remove(),r=i.find(mt).first()),hi(r[0].cells,n,!1))}function fi(e){for(var t,n=[],i=0;i<e.length&&("field"in(t=e[i])&&"value"in t&&"items"in t);i++)n.push(t),t.hasSubgroups&&(n=n.concat(fi(t.items)));return n}function mi(t,n){for(var i,r,o=0,a=t.length;o<a;o+=1)(r=t.eq(o)).is(".k-grouping-row,.k-detail-row")?(i=r.children(":not(.k-group-cell):first,.k-detail-cell").last()).attr("colspan",parseInt(i.attr("colspan"),10)+1):(r.hasClass("k-grid-edit-row")&&(i=r.children(".k-edit-container")[0])&&((i=e(i)).attr("colspan",parseInt(i.attr("colspan"),10)+1),ci(i.find(">form>table"),yn(undefined),!1,0),r=i.find(mt).first()),hi(r[0].cells,n,!0))}function gi(e,t,n){var i,r,o;for(n=n||1,r=0,o=e.length;r<o;r++)(i=e.eq(r).children(":not([hidden])").last()).attr("colspan",parseInt(i.attr("colspan"),10)+n),(i=t.eq(r).children(":not([hidden])").last()).attr("colspan",parseInt(i.attr("colspan"),10)-n)}function vi(e){var t,n,i=0,r=e.find(">colgroup>col");for(t=0,n=r.length;t<n;t+=1)i+=parseInt(r[t].style.width,10);return i}var _i=n.ui.DataBoundWidget.extend({init:function(t,i,r){var o=this;i=v(i)?{dataSource:i}:i,l.fn.init.call(o,t,i),r&&(o._events=r),$t=n.support.isRtl(t),R=$t?"a[class*='-i-caret-alt-left']":L,o._element(),o._ariaId(),o._columns(e.extend(!0,[],o.options.columns)),o._foreignKeyPromises?e.when.apply(null,o._foreignKeyPromises).then((function(){o._foreignKeyPromises=null,o._continueInit()})):o._continueInit()},_continueInit:function(){var t=this;t._dataSource(),t._stickyColumns(),t._tbody(),t._thead(),t._rowResizing(),t._groupable(),t._toolbar();let i=t.wrapper.find(".k-grid-toolbar .k-toolbar-button.k-grid-column-menu[ref-toolbar-tool]");i.length>0&&t._globalColumnsMenu(i),t._pageable(),t._setContentHeight(),t._templates(),t._navigatable(),t._initSelectableAggregates(),t._selectable(),t._statusBar(),t._clipboard(),t._paste(),t._details(),t._editable(),t._attachCustomCommandsEvent(),t._adaptiveColumns(),t._minScreenSupport(),t.options.autoBind?t.dataSource.fetch():(t._group=t._groups()>0,t._footer()),t.options.contextMenu&&t._initContextMenu(),t.lockedContent&&(t.wrapper.addClass("k-grid-lockedcolumns"),t._resizeHandler=function(){t.resize()},e(window).on("resize"+B,t._resizeHandler)),t._initLoader(),n.notify(t),t._showWatermarkOverlay&&t._showWatermarkOverlay(t.wrapper[0])},events:[Q,Y,"dataBinding","cancel",ee,te,ne,U,W,q,j,G,O,V,N,$,J,K,He,Fe,Re,Z,X,Le,Be,Oe,Ve,Ne,$e,ae,"page","sort","filter","group","groupExpand","groupCollapse","kendoKeydown"],setDataSource:function(e){var t,i=this,r=i.options.scrollable;i.options.dataSource=e,i._dataSource(),i._pageable(),i._thead(),i._rowResizing(),r&&(r.virtual?(t=i.content.find(">.k-virtual-scrollable-wrap"),n.scrollLeft(t,Ti(t,$t))):(t=i.tbody,n.scrollLeft(i.content,Ti(t,$t)))),i.options.groupable&&i._groupable(),i.virtualScrollable&&i.virtualScrollable.setDataSource(i.options.dataSource),i.options.navigatable&&i._navigatable(),i.options.selectable&&i._selectable(),i.options.autoBind?i.dataSource.fetch():i._footer()},options:{name:"Grid",columns:[],toolbar:null,autoBind:!0,filterable:!1,scrollable:!0,sortable:!1,selectable:!1,allowCopy:!1,allowPaste:!1,navigatable:!1,pageable:!1,persistSelection:!1,editable:!1,encodeTitles:!1,groupable:!1,rowTemplate:"",altRowTemplate:"",statusBarTemplate:null,search:!1,noRecords:!1,dataSource:{},height:null,resizable:!1,reorderable:!1,columnMenu:!1,detailTemplate:null,contextMenu:!1,columnResizeHandleWidth:3,size:"medium",mobile:"",loaderType:"loadingPanel",messages:{loader:{loading:"Loading...",exporting:"Exporting..."},editable:{cancelDelete:"Cancel",confirmation:"Are you sure you want to delete this record?",confirmDelete:"Delete"},commands:{create:rn.create.text,cancel:rn.cancel.text,save:rn.save.text,destroy:rn.destroy.text,edit:rn.edit.text,update:rn.update.text,canceledit:rn.canceledit.text,excel:rn.excel.text,pdf:rn.pdf.text,search:rn.search.text,columns:rn.columns.text,select:"Select",selectRow:"Select Row",selectAllRows:"All rows",clearSelection:"Clear selection",copySelection:"Copy selection",copySelectionNoHeaders:"Copy selection (No Headers)",paste:"Paste (use CTRL/⌘ + V)",reorderRow:"Reorder row",reorderRowUp:"Up",reorderRowDown:"Down",reorderRowTop:"Top",reorderRowBottom:"Bottom",exportPdf:"Export to PDF",exportExcel:"Export to Excel",exportToExcelAll:"All",exportToExcelSelection:"Selection",exportToExcelSelectionNoHeaders:"Selection (No Headers)",sortAsc:"Sort Ascending",sortDesc:"Sort Descending",moveGroupPrevious:"Move previous",moveGroupNext:"Move next"},noRecords:"No records available.",expandCollapseColumnHeader:"",groupHeader:"Press ctrl + space to group",ungroupHeader:"Press ctrl + space to ungroup",itemsSelected:"items selected",dragHandleLabel:"Drag row",toolbarLabel:"grid toolbar",groupingHeaderLabel:"grid grouping header",filterCellTitle:"filter cell"},width:null},destroy:function(){var t,i,r=this;if(r._destroyColumnAttachments(),l.fn.destroy.call(r),this._navigatableTables&&(this._navigatableTables.off(B),this._navigatableTables=null,this._headertables=null),r._resizeHandler&&e(window).off("resize"+B,r._resizeHandler),r.pager&&r.pager.element&&r.pager.destroy(),r.timer&&clearTimeout(r.timer),r._progressTimeOut&&clearTimeout(r._progressTimeOut),r._collapseGroupsTimeOut&&clearTimeout(r._collapseGroupsTimeOut),r._endlessFetchTimeOut&&clearTimeout(r._endlessFetchTimeOut),r.pager=null,r._destroyGroupable(),(i=r.wrapper.data("kendoReorderable"))&&i.destroy(),(i=r.tbody?r.tbody.data("kendoReorderable"):null)&&i.destroy(),r.allowPaste){(r.content||r.table).off(ae+B,r.pasteHandler),r.unbind(r.pasteHandler)}r.pasteActionsDropDownList&&(r.pasteActionsDropDownList.destroy(),r.pasteActionsDropDownList=null),r.selectable&&r.selectable.element&&(r.selectable.destroy(),r.clearArea(),r._selectedIds=null,r.copyHandler&&(r.wrapper.off("keydown",r.copyHandler),r.unbind(r.copyHandler)),r.updateClipBoardState&&(r.unbind(r.updateClipBoardState),r.updateClipBoardState=null),r.clearAreaHandler&&r.wrapper.off("keyup",r.clearAreaHandler)),r.selectable=null,r._selectableAggregatesOptions=null,r.resizable&&(r.resizable.destroy(),r._resizeUserEvents&&(r._resizeHandleDocumentClickHandler&&e(document).off("click",r._resizeHandleDocumentClickHandler),r._resizeUserEvents.destroy(),r._resizeUserEvents=null),r.resizable=null),r._destroyRowResizing(),r._destroyVirtualScrollable(),r.editableUserEvents&&(r.editableUserEvents.destroy(),r.editableUserEvents=null),r._lockedContentUserEvents&&(r._lockedContentUserEvents.destroy(),r._lockedContentUserEvents=null),r._destroyEditable(),r.dataSource&&(r.dataSource.unbind(Q,r._refreshHandler).unbind(T,r._progressHandler).unbind(D,r._errorHandler).unbind(ct,r._clearSortClasses),r._refreshHandler=r._progressHandler=r._errorHandler=r._sortHandler=null),t=r.element.add(r.wrapper).add(r.table).add(r.thead).add(r.wrapper.find(">.k-grid-toolbar")),r.content&&(t=t.add(r.content).add(r.content.find(">.k-virtual-scrollable-wrap"))),r.scrollables&&r.scrollables.first()&&(t=t.add(r.scrollables.first())),r.lockedHeader&&r._removeLockedContainers(),r.pane&&r.pane.destroy(),r._isMobile&&(r.wrapper.off("transitionend"+B),r.wrapper.off("contextmenu"+B)),r.minScreenResizeHandler&&e(window).off("resize",r.minScreenResizeHandler),r._detachColumnMediaResizeHandler(),r._draggableInstance&&r._draggableInstance.element&&r._draggableInstance.destroy(),r._draggableInstance=null,r._draggableRowsInstance&&r._draggableRowsInstance.element&&r._draggableRowsInstance.destroy(),r.tbodyContextMenu&&r.tbodyContextMenu.destroy(),r.theadContextMenu&&r.theadContextMenu.destroy(),r.loader&&r.loader.destroy(),r._draggableRowsInstance=null,t.off(B),n.destroy(r.wrapper),r.rowTemplate=r.altRowTemplate=r.lockedRowTemplate=r.lockedAltRowTemplate=r.detailTemplate=r.footerTemplate=r.groupFooterTemplate=r.lockedGroupFooterTemplate=r.noRecordsTemplate=null,r.scrollables=r.thead=r.tbody=r.element=r.table=r.content=r.statusBar=r.footer=r.wrapper=r.lockedTable=r.lockedContent=r.lockedHeader=r.lockedFooter=r._groupableClickHandler=r._groupRows=r._setContentWidthHandler=r.loaderOverlay=r.wrapperClone=null},getOptions:function(){this.options.dataSource=null;var t=f(!0,{},this.options);t.columns=n.deepExtend([],this.columns);var i=this.dataSource,r=i.options.data&&i._data;return i.options.data=null,t.dataSource=e.extend(!0,{},i.options),i.options.data=r,t.dataSource.data=r,t.dataSource.page=i.page(),t.dataSource.filter=e.extend(!0,{},i.filter()),t.dataSource.pageSize=i.pageSize(),t.dataSource.sort=i.sort(),t.dataSource.group=i.group(),t.dataSource.aggregate=i.aggregate(),t.dataSource.transport&&(t.dataSource.transport.dataSource=null),t.pageable&&t.pageable.pageSize&&(t.pageable.pageSize=i.pageSize()),t},setOptions:function(e){var t=this.getOptions();n.deepExtend(t,e),e.dataSource?e.dataSource.filter&&(t.dataSource.filter=e.dataSource.filter):t.dataSource=this.dataSource;var i=this.wrapper,r=this._events,o=this.element;if(this.destroy(),this.options=null,this._isMobile){var a=i.closest(n.roleSelector("pane")).parent();a.after(i),a.remove(),i.removeClass("k-grid-mobile")}i[0]!==o[0]&&(i.before(o),i.remove()),o.empty(),this.init(o,t,r),this._setEvents(t)},items:function(){return this.lockedContent?this._items(this.tbody).add(this._items(this.lockedTable.children("tbody"))):this._items(this.tbody)},_items:function(t,n){return t.children().filter((function(){var t=e(this);return!((n?t.hasClass("k-detail-row"):t.hasClass(ze))||t.hasClass("k-detail-row")||t.hasClass("k-group-footer"))}))},dataItems:function(){var e=n.ui.DataBoundWidget.fn.dataItems.call(this);if(this.lockedContent){for(var t=e.length,i=new Array(2*t),r=t;--r>=0;)i[r]=i[r+t]=e[r];e=i}return e},_destroyColumnAttachments:function(){var t=this;t.resizeHandle=null,t.thead&&t.thead.add(t.lockedHeader).find("th").each((function(){var t=e(this),n=t.data("kendoFilterMenu"),i=t.data("kendoColumnSorter"),r=t.data("kendoColumnMenu");n&&n.destroy(),i&&i.destroy(),r&&r.destroy()}))},_attachCustomCommandsEvent:function(){var e,t,n,i=this,r=ei(i.columns||[]);for(t=0,n=r.length;t<n;t++)(e=r[t].command)&&ln(i,i.wrapper,e)},_aria:function(){var e,t,i,r,o,a=this.wrapper,s=this._hasDetails()?"treegrid":this.options.navigatable?"grid":null,l=this.table,c=a.find(".k-grid-toolbar"),d=a.find(".k-grouping-header"),u=this._ariaGridId(),h=l.attr(Je),p=this.thead.find(mt).length+this.wrapper.find(".k-grid-footer-wrap table tr").length,f=this._trailingColumns(),m=this.virtualScroll,g=this.options.pageable;l.attr(Je,h>=0?h:0),s&&l.attr(Tt,s),l.find("tbody, thead, tfoot").attr(Tt,Mt),l.find(mt).attr(Tt,At),l.find("th").attr(Tt,Et),l.find("td").attr(Tt,It),g&&this.dataSource.totalPages()>1||m&&m.rows?(o=this._groups()>0?-1:this._hasDetails()?p+2*this.dataSource.total():p+this.dataSource.total(),l.attr(bt,o)):this._hasDetails()&&(o=this._groups()>0?-1:p+2*this.dataSource.total(),l.attr(bt,o)),o&&o>0&&this._ariaRowIndex(),(m&&m.columns||!l.attr(yt)&&(l.find("td:not([group-header-spanned-hidden]):hidden").length>0||a.find(".k-grid-content-locked td:not([group-header-spanned-hidden]):hidden").length>0))&&(l.attr(yt,f+ei(this.columns).length),this._ariaColumnIndex()),this.pager&&this.pager.element.attr("aria-controls",u),c.attr({role:"toolbar","aria-label":this.options.messages.toolbarLabel,"aria-controls":u}),d.attr({role:"toolbar","aria-label":this.options.messages.groupingHeaderLabel,"aria-controls":u}),t=this._ariaHeaderFooter("header","thead","th, td",Et),i=this._ariaHeaderFooter("footer","tfoot","td",It),a.find(".k-grid-content-locked").length>0&&this._ariaLockedContent(),(t||i)&&(r=[t,e=this.tbody.attr(pt)||n.guid(),i].join(" "),this.tbody.attr(pt,e),l.attr(_t,r)),this.options.groupable&&this._ariaGroupTitles()},_ariaColumnIndex:function(){var t,n,i,r,o=this._trailingColumns(),a=this.tbody.find(">tr").last().find("> td[data-virtual]"),s=this.thead.find(">tr").not(".k-filter-row"),l=this.wrapper.find(".k-grid-header-locked thead > tr").not(".k-filter-row"),c=Number.MAX_VALUE,d=0,u=0,h=0,p=0,f=function(n,i){var r=i.getAttribute("data-index"),o=Number(r),a=e(i).closest(".k-grid-header-locked");0===a.length&&o<c&&(c=o),a.length>0&&u<o&&(u=o),0===a.length&&d<o&&(d=o),null!==r?(i.setAttribute(wt,Number(o)+1),t=Number(o)+1+i.getAttribute("colspan")):(i.setAttribute(wt,t+1),t+=i.getAttribute("colspan"))};for(2===a.length?(h=Number(a[0].getAttribute("colspan")),p=Number(a[1].getAttribute("colspan"))):1===a.length&&0===a.prev().length?h=Number(a[0].getAttribute("colspan")):1===a.length&&1===a.prev().length&&(p=Number(a[0].getAttribute("colspan"))),n=0;n<l.length;n++)t=0,l.eq(n).find("th").each(f);for(n=0;n<s.length;n++)t=0,s.eq(n).find("th").each(f);for(n=0;n<=u;n++)i=n+o,this.wrapper.find(".k-grid-content-locked tbody > tr > td:nth-child("+(n+1)+")").attr(wt,i+1);for(n=h;n<=d-c-p;n++)r=0===h?n+1:n-h+2,i=c+n+o,this.tbody.find("> tr > td:nth-child("+r+")").attr(wt,i+1)},_ariaGroupTitles:function(){var e=this,t=e.dataSource.group(),i=e.wrapper.find(".k-grid-header th");i.each((function(t,n){n.getAttribute("title")===e.options.messages.ungroupHeader&&n.setAttribute("title",e.options.messages.groupHeader)})),t&&t.length>0&&t.forEach((function(t){var r=t.field,o=i.filter("["+n.attr("field")+"='"+r+"']");o.attr("title")===e.options.messages.groupHeader&&o.attr("title",e.options.messages.ungroupHeader)}))},_ariaHeaderFooter:function(e,t,i,r){var o,a=this.wrapper,s=a.find(".k-grid-"+e+" .k-grid-"+e+"-wrap table"),l=a.find(".k-grid-"+e+" .k-grid-"+e+"-locked table"),c="";return s.length>0&&(c=(o=s.find(t+", tbody")).attr(pt)||n.guid(),s.attr(Tt,Dt),s.find(mt).attr(Tt,At),s.find(i).attr(Tt,r),o.attr({role:Mt,id:c})),l.length>0&&this._ariaLocked(e,t,i,r),l.find("td").attr(Tt,It),s.find("td").attr(Tt,It),c},_ariaId:function(){var e=this.element.attr(pt)||"aria";e&&(this._cellId=e+"_active_cell")},_ariaGridId:function(){var e=this.table,t=e.attr(pt);return t||(t=n.guid(),e.attr(pt,t)),t},_ariaLocked:function(t,n,i,r){var o=this,a=o.wrapper,s=a.find(".k-grid-"+t+" .k-grid-"+t+"-wrap table"),l=a.find(".k-grid-"+t+" .k-grid-"+t+"-locked table"),c=s.find(mt),d=l.find(mt);l.attr(Tt,Dt),l.find(n+", tbody").attr(Tt,Dt),d.attr(Tt,Dt),l.find(i).attr(Tt,r),c.each((function(n,r){var a=[];a=(a=o._cellsIds(d.eq(n).find(i),"locked_"+t,n)).concat(o._cellsIds(e(r).find(i),t,n)),r.setAttribute(_t,a.join(" "))}))},_ariaLockedContent:function(){var t=this,n=t.table.find(mt),i=t.wrapper.find(".k-grid-content-locked table"),r=i.find(mt);i.attr(Tt,Dt),i.find("tbody").attr(Tt,Dt),r.attr(Tt,Dt),i.find("td").attr(Tt,It),n.each((function(n,i){var o=[];o=(o=t._cellsIds(r.eq(n).find("td"),"locked_datacell",n)).concat(t._cellsIds(e(i).find("td"),"datacell",n)),i.setAttribute(_t,o.join(" "))}))},_ariaAddHiddenColIndex:function(){var e=this.virtualScroll||{},t=this.columns,n=this.table,i=ei(t).length;e.columns||n.attr(yt)||(this._ariaColumnIndex(),n.attr(yt,i))},_ariaRemoveHiddenColIndex:function(){var e=this.virtualScroll||{},t=ei(this.columns).length;e.columns||t!==Qn(this.columns).length||(this.wrapper.find("td, th").removeAttr(wt),this.table.removeAttr(yt))},_ariaRowIndex:function(){var e,t,n=this.thead.find(">tr"),i=n.length,r=this.tbody.find(">tr"),o=this.wrapper.find(".k-grid-footer-wrap tfoot > tr"),a=this.dataSource.total(),s=this.dataSource.skip()||0,l=1,c=!1;for(this._hasDetails()&&(a*=2,s*=2),e=0;e<i;e++)n.eq(e).attr(kt,l+e);for(l=i+s,e=0;e<r.length;e++)t=r.eq(e),this._hasDetails()&&t.hasClass("k-master-row")?(l+=c?2:1,c=!0):(l+=1,c=!1),t.attr(kt,l);for(l=i+a+1,e=0;e<o.length;e++)o.eq(e).attr(kt,l+e)},_cellsIds:function(e,t,n){var i=[],r=this._ariaGridId();return e.each((function(e,o){var a=o.getAttribute(pt)||r+"_"+t+"_"+n+"_"+e;o.setAttribute(pt,a),i.push(a)})),i},_trailingColumns:function(){return this._groups()+(this._hasDetails()?1:0)},_element:function(){const t=this;let i=t.element;i.is("table")||(i=t.options.scrollable?t.element.find("> .k-grid-content > table"):t.element.children("table"),i.length||(i=e("<table />").appendTo(t.element))),i.addClass("k-grid-table k-table"),i.addClass(n.getValidCssClass("k-table-","size",t.options.size)),t.table=i,t._wrapper()},_createResizeHandle:function(t,i){var r,o,a,s,l,c,u,h=this,p=h.options.columnResizeHandleWidth,f=h.options.scrollable,m=h.resizeHandle,g=3*p/2,v=0;m&&h.lockedContent&&m.data("th")[0]!==i[0]&&(m.off(B).remove(),m=null),m||(m=h.resizeHandle=e('<div class="k-resize-handle"><div class="k-resize-handle-inner"></div></div>'),t.append(m)),l=n.scrollLeft(t),$t&&(Ut.mozilla||Ut.webkit&&Ut.version>=85)&&(l*=-1),s=parseFloat(t.css("borderLeftWidth")),c=i.offset().left+l-parseFloat(i.css("marginLeft"))-(t.offset().left+s),$t?f&&(v=c<=l?g:0,(r=i.closest(".k-grid-header-wrap, .k-grid-header-locked"))[0].scrollWidth-r[0].offsetWidth,a=parseFloat(r.css("marginLeft")),o=Ut.msie?2*n.scrollLeft(r)+s-a-v:0,c-=-v+(Ut.mozilla?s-a-v:0)+o):c+=i[0].offsetWidth,u=i.offset().top-parseFloat(i.css("marginTop"))-(t.offset().top+parseFloat(t.css("borderTopWidth"))),m.css({top:u,left:c-g,height:d(i),width:3*p-v}).data("th",i).show(),m.off(Ye+B).on(Ye+B,(function(){h._autoFitLeafColumn(parseInt(i.attr(n.attr("index")),10))}))},_positionColumnResizeHandle:function(){var t=this,i=t.lockedHeader?t.lockedHeader.find("thead").first():e();t.thead.add(i).on(Ke+B,"tr:not(.k-filter-row) > th:not([data-resizable=false])",(function(i){var r=void 0!==i.buttons?i.buttons:i.which||i.button,o=e(this);o.hasClass("k-group-cell")||o.hasClass("k-hierarchy-cell")||void 0!==r&&0!==r||o[0].hasAttribute(n.attr("colSpan"))||t._createResizeHandle(o.closest(gt),o)}))},_resizeHandleDocumentClick:function(t){e(t.target).closest(".k-column-active").length||(e(document).off(t),this._resetResizeHandleHeader(),this._hideResizeHandle())},_resetResizeHandleHeader:function(){var t;this.resizeHandle&&(t=e(this.resizeHandle).data("th"))&&(t.find(S+ye).find(S+we+","+S+ke).show(),t.find(S+xe).show(),t.find(S+Te).show(),t.find(S+De).show())},_hideResizeHandle:function(){this.resizeHandle&&(this.resizeHandle.data("th").removeClass("k-column-active"),this.lockedContent&&!this._isMobile?(this.resizeHandle.off(B).remove(),this.resizeHandle=null):this.resizeHandle.hide())},_positionColumnResizeHandleTouch:function(){var t=this,i=t.lockedHeader?t.lockedHeader.find("thead").first():e();t._resizeUserEvents=new n.UserEvents(i.add(t.thead),{filter:"th:not(.k-group-cell):not(.k-hierarchy-cell)",threshold:10,minHold:500,hold:function(n){var i=e(n.target);n.preventDefault(),t.resizeHandle&&(t.resizeHandle.data("th").removeClass("k-column-active"),t._resetResizeHandleHeader()),i.addClass("k-column-active"),i.find(S+ye).find(S+we+","+S+ke).hide(),i.find(S+xe).hide(),i.find(S+Te).hide(),i.find(S+De).hide(),t._createResizeHandle(i.closest(gt),i),t._resizeHandleDocumentClickHandler||(t._resizeHandleDocumentClickHandler=t._resizeHandleDocumentClick.bind(t)),e(document).on("click",t._resizeHandleDocumentClickHandler)}})},resizeColumn:function(t,i){var r,o=this,a=!!t.locked,s=!!t.hidden,l=this.options,d=n.support.mobileOS?0:n.support.scrollbar(),u=_(t,a?Yn(Qn(o.columns)):Kn(Qn(o.columns))),h=a?o.lockedTable:o.table,p=o.footer||e(),f=a?o.lockedHeader.find("table"):o.thead.closest("table"),m=t.minResizableWidth||10,g=c(a?h.find("tbody"):o.tbody);if(s)t.width=i>m?i:m;else{if(o.footer&&o.lockedContent&&(p=a?o.footer.children(".k-grid-footer-locked"):o.footer.children(".k-grid-footer-wrap")),r=l.scrollable?f.find("col:not(.k-group-col,.k-hierarchy-col)").eq(u).add(h.children("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(u)).add(p.find("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(u)):h.find("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(u),l.scrollable){var v=!1,b=o.wrapper.width()-d,y=i=i>m?i:m;a&&g-i+y>b&&((y=i+(b-g-2*d))<0&&(y=i),v=!0),y>10&&y>=m&&(r.css("width",y),g&&(y=v?b-2*d:g+(i-t.width),h.add(f).add(p).css("width",y),a||(o._footerWidth=y))),o._scrollVirtualWrapperOnColumnResize()}else i>10&&i>=m&&r.css("width",i);t.width=i,o._applyLockedContainersWidth(),o._syncLockedContentHeight(),o._syncLockedHeaderHeight(),o._updateStickyColumns()}},_adjustColWidths:function(t,n,i,r){const o={};t.add(n).add(i).css("width",r),t.add(n).add(i).find("col").each(((t,n)=>{o[t]=e(n).css("width")})),t.add(n).add(i).find("col").each(((t,n)=>{e(n).css("width",o[t])}))},_resizable:function(){var t,r,o,a,s,l,u,h,p=this,f=p.options,m=this._isMobile,g=n.support.mobileOS?0:n.support.scrollbar();(!0===f.resizable||f.resizable&&!0===f.resizable.columns)&&(t=f.scrollable?p.wrapper.find(".k-grid-header-wrap").first():p.wrapper,m?p._positionColumnResizeHandleTouch(t):p._positionColumnResizeHandle(t),p.resizable&&p.resizable.destroy(),p.resizable=new i.Resizable(t.add(p.lockedHeader),{handle:(f.scrollable?"":">")+".k-resize-handle",hint:function(t){return e('<div class="k-grid-resize-indicator" />').css({height:d(t.data("th"))+p.tbody.attr("clientHeight")})},start:function(t){h=e(t.currentTarget).data("th"),m&&p._hideResizeHandle();let n=h.closest("table"),i=e.inArray(h[0],ii(h.closest("thead")).filter(":visible")),d=(l=n.parent().hasClass("k-grid-header-locked"))?p.lockedTable:p.table,g=p.footer||e();p.footer&&p.lockedContent&&(g=l?p.footer.children(".k-grid-footer-locked"):p.footer.children(".k-grid-footer-wrap"));let v=g.find("table");on(p.wrapper,"col-resize"),u=f.scrollable?n.find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(i).add(d.children("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(i)).add(g.find("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(i)):d.children("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(i);let _=e.map(p.columns,(function(e){return!e.hidden&&(l&&e.locked||!l&&!e.locked)?e:null}));r=t.x.location,o=c(h),a=ei(_)[i].minResizableWidth||10,s=c(l?d.children("tbody"):p.tbody),Ut.webkit&&p.wrapper.addClass("k-grid-column-resizing"),p._adjustColWidths(d,n,v,s)},resize:function(t){var n=$t?-1:1,i=o+t.x.location*n-r*n;if(f.scrollable){var c;l&&p.lockedFooter?c=p.lockedFooter.children("table"):p.footer&&(c=p.footer.find(">.k-grid-footer-wrap>table")),c&&c[0]||(c=e());var d=h.closest("table"),m=l?p.lockedTable:p.table,v=!1,_=p.wrapper.width()-g,b=i;l&&s-o+b>_&&((b=o+(_-s-2*g))<0&&(b=i),v=!0),b>10&&b>=a&&(u.css("width",b),s&&(b=v?_-2*g:s+t.x.location*n-r*n,m.add(d).add(c).css("width",b),l||(p._footerWidth=b))),p._scrollVirtualWrapperOnColumnResize()}else i>10&&i>=a&&u.css("width",i)},resizeend:function(){var e,t,i=c(h);if(on(p.wrapper,""),Ut.webkit&&p.wrapper.removeClass("k-grid-column-resizing"),h&&o!=i){t=p.lockedHeader?p.lockedHeader.find("thead").first().find(mt).first().add(p.thead.find(mt).first()):h.parent();var r=h.attr(n.attr("index"));r||(r=t.find("th:not(.k-group-cell):not(.k-hierarchy-cell)").index(h)),(e=ei(p.columns)[r]).width=i,p.trigger(Fe,{column:e,oldWidth:o,newWidth:i}),p._applyLockedContainersWidth(!0),p._syncLockedContentHeight(),p._syncLockedHeaderHeight(),p._updateStickyColumns()}p._resetResizeHandleHeader(),p._hideResizeHandle(),h=null}}))},_addLockedRowResizing:function(e){var t=e.index();return this.lockedTable.find(mt).eq(t).add(this.tbody.find(mt).eq(t))},_getMinRowHeight:function(e){var t=0;return e.each(((e,n)=>{var i;n.style.height="",(i=d(n))>t&&(t=i)})),t},_cacheRowHeight:function(e,t){var n=this;n._cachedRowsHeight||(n._cachedRowsHeight={}),e.each(((e,i)=>{var r=i.getAttribute("data-uid");n._cachedRowsHeight[r]=t}))},_clearCachedRowsHeight:function(e){var t=this;e&&t._cachedRowsHeight?e.each(((e,n)=>{var i=n.getAttribute("data-uid");delete t._cachedRowsHeight[i]})):t._cachedRowsHeight=null},_mapCachedRowsHeight:function(e,t){var n=this._cachedRowsHeight,i=this.dataSource,r={};Object.keys(n).forEach((o=>{var a=i[e](o);r[a[t]]=n[o]})),this._cachedRowsHeight=r},_rowResizerDblClick:function(){var t,n,i=this,r=i.rowResizer,o=r.data(mt),a=d(o);n=o.hasClass(ge)?i.select():o,i.lockedTable?(n=(o=i._addLockedRowResizing(o)).hasClass(ge)?i.lockedTable.find(S+ge):i.lockedTable.find(mt).eq(o.index())).each(((t,n)=>{var r=n.rowIndex,o=e(n).add(i.tbody.find(mt).eq(r)),a=i._getMinRowHeight(o);o.css(Qe,a)})):n.css(Qe,Ze),i._clearCachedRowsHeight(n),r.removeClass(pe),r.removeClass(fe),a!=(t=d(o))&&i.trigger(He,{row:o,rows:n,oldHeight:a,newHeight:t})},_setupRowResizer(e,t,n){e.data(mt,t).css({top:n})},_attachRowResizerEvents:function(){var e=this.rowResizer,t=!1;e.on(We+B,(t=>{0===t.button&&(e.removeClass(pe),e.addClass(fe))})).on(je+B,(t=>{0===t.button&&(e.removeClass(fe),e.addClass(pe))})).on(qe+B,(()=>{t=!0,setTimeout((()=>{t&&e.addClass(pe)}),200)})).on(Ge+B,(()=>{t=!1,e.removeClass(pe)}))},_getResizerTop:function(e,t){var n=this.rowResizer,i=n.find(".k-row-resizer")[0],r=parseInt(getComputedStyle(n[0]).paddingTop);return e.offset().top-parseFloat(e.css("marginTop"))-(t.offset().top+parseFloat(t.css("borderTopWidth")))-i.clientHeight-r+t.scrollTop()},_getResizerContainer:function(){var e=this.tbody.closest(gt);return this.lockedTable&&(e=e.closest(".k-grid-container")),e},_createRowResizer:function(t){var n,i=this,r=e(t.currentTarget),o=t.currentTarget.clientHeight,a=t.offsetY,s=i.rowResizer,l=r.prev("tr:visible"),c=i._getResizerContainer();s||(s=i.rowResizer=e('<div class="k-resizer-wrap"><div class="k-row-resizer"></div></div>'),c.append(s),i._attachRowResizerEvents(),s.off(Ye+B).on(Ye+B,i._rowResizerDblClick.bind(i))),n=i._getResizerTop(r,c),0!==l.length&&o/2>a?l.hasClass(ze)||i._setupRowResizer(s,l,n):r.hasClass(ze)||i._setupRowResizer(s,r,n+o)},_detachRowResizerEvents:function(){this.rowResizer.off(We+B).off(je+B).off(qe+B).off(Ge+B)},_mapResizedRows:function(t,n,i){var r=this;t.each(((t,o)=>{var a;if(n){var s=o.rowIndex,l=i,c=0,u=e(o).add(r.tbody.find(mt).eq(s));u.each(((e,t)=>{var n;t.style.height="",(n=d(t))>c&&(c=n)})),l<c?(l=c,r._clearCachedRowsHeight(u.eq(0))):r._cacheRowHeight(u.eq(0),l),u.css(Qe,l)}else o.style.height="",a=d(o),i>a?(o.style.height=i+ft,r._cacheRowHeight(e(o),i)):r._clearCachedRowsHeight(e(o))}))},_rowResizing:function(){var t,n,r,o,a=this,s=a.options;s.resizable&&!0===s.resizable.rows&&(a.tbody.parent().add(a.lockedTable).on(Ke+B,".k-grid-footer tr, .k-table-tbody tr",a._createRowResizer.bind(a)),a.rowResizing&&a.rowResizing.destroy(),t=a._getResizerContainer(),a.rowResizing=new i.Resizable(t,{handle:".k-resizer-wrap",start:function(t){o=e(t.currentTarget).data(mt),a.lockedTable&&(o=a._addLockedRowResizing(o)),o.addClass(pe),a._detachRowResizerEvents(),n=t.y.location,r=d(o)},resize:function(e){var i=r+e.y.location-n,s=0;o.length>1&&(s=a._getMinRowHeight(o)),i<s&&(i=s),o.css("height",i),a._setupRowResizer(a.rowResizer,o,a._getResizerTop(o,t)+i)},resizeend:function(){var e,t=d(o),n=!1;o.hasClass(ge)?(e=a.select(),o.length>1&&e.length>o.length&&(e=a.lockedTable.find(S+ge).not(o),n=!0)):e=o,a._mapResizedRows(e,n,t),o.removeClass(pe),a.rowResizer.removeClass(fe),a.rowResizer.addClass(pe),a._attachRowResizerEvents(),n&&(e=a.select()),r!=t&&a.trigger(He,{row:o,rows:e,oldHeight:r,newHeight:t}),o=null}}))},_draggable:function(){var t=this,i=t.options.reorderable;if(!0===i||i&&i.columns){t._draggableInstance&&t._draggableInstance.destroy();var r=t.wrapper.children(".k-grid-header");t._draggableInstance=t.wrapper.kendoDraggable({group:n.guid(),autoScroll:!0,filter:t.content?".k-grid-header:first "+H:"table:first>.k-grid-header "+H,dragstart:function(){r.children(".k-grid-header-wrap").off("scroll"+B+"scrolling").on("scroll"+B+"scrolling",(function(e){t.virtualScrollable?n.scrollLeft(t.content.find(">.k-virtual-scrollable-wrap"),this.scrollLeft):n.scrollLeft(t.scrollables.not(e.currentTarget),this.scrollLeft)}))},dragend:function(){t._resetResizeHandleHeader(),r.children(".k-grid-header-wrap").off("scroll"+B+"scrolling")},drag:function(){t._hideResizeHandle()},hint:function(t){var i=t.attr(n.attr("title"));return i&&(i=n.htmlEncode(i)),e('<div class="k-reorder-clue k-drag-clue" />').html(i||t.attr(n.attr("field"))||t.text()).prepend(n.ui.icon({icon:"cancel",iconClass:"k-drag-status"}))}}).data("kendoDraggable")}},_reorderable:function(){let t=this,n=t.options.reorderable;(!0===n||n&&n.columns)&&(t.wrapper.data("kendoReorderable")&&t.wrapper.data("kendoReorderable").destroy(),t.wrapper.kendoReorderable({draggable:t._draggableInstance,dropFilter:H,dragOverContainers:function(e,n){let i=Pn(t.columns);return!1!==i[e].lockable&&Hn(i,t.columns,e,n)>-1},inSameContainer:function(n){let i=e(n.source).parent()[0],r=e(n.target).parent()[0],o=n.sourceIndex,a=n.targetIndex,s=Pn(t.columns),l=s&&s[o]&&!!s[o].lockable;return t._isLocked()&&l&&(i=e(n.source.closest(".k-grid-header"))[0],r=e(n.target.closest(".k-grid-header"))[0]),i===r&&Hn(s,t.columns,o,a)>-1},change:function(e){let n=Pn(t.columns),i=n[e.oldIndex],r=Hn(n,t.columns,e.oldIndex,e.newIndex);t.trigger(Re,{newIndex:r,oldIndex:_(i,n),column:i}),t.reorderColumn(r,i,"before"===e.position)}}))},_reorderHeader:function(e,t,n,i){for(var r,o,a=this,s=Mn(e[0],a.columns),l=Mn(t,a.columns),c=[],d=0;d<e.length;d++)e[d].columns&&(c=c.concat(e[d].columns));o=i?sn(i,i,"tr:eq("+s.row+")>th.k-header:not(.k-group-cell,.k-hierarchy-cell)"):sn(a.lockedHeader,a.thead,"tr:eq("+s.row+")>th.k-header:not(.k-group-cell,.k-hierarchy-cell)");var u,h,p,f,m,g,v=jn(e).length,_=jn([t]).length;c.length?(v>0&&0===_?(r="prepend",Sn(e,t,c,a.columns,a.lockedHeader.find("thead"),a.thead,this._groups(),r)):0===v&&_>0&&(r=0!==l.cell||!e[0].columns||t.columns||a._group?"append":"prepend",Sn(e,t,c,qn(a.columns),a.thead,a.lockedHeader.find("thead"),this._groups(),r)),(t.columns||s.cell-l.cell>1||l.cell-s.cell>1)&&(t=In(a.columns,t,e[0],n,a.columns))&&(v>0&&0===_?a._reorderHeader(c,t,n,a.thead):0===v&&_>0?a._reorderHeader(c,t,n,a.lockedHead):a._reorderHeader(c,t,n))):v!==_&&(u=o[s.cell],h=a.columns,p=v,f=Dn(jn(h)),m=Dn(qn(h)),g=u.rowSpan,u.rowSpan=p?f>m?g-(f-m)||1:g+(m-f):f>m?g+(f-m):g-(m-f)||1),an(o,s.cell,l.cell,n,e.length)},_reorderContent:function(t,n,i){var r,o,a,s=this,l=e(),c=t[0],d=yn(t),u=_(c,ei(s.columns)),h=_(n,ei(s.columns)),p=_(d[0],Qn(s.columns)),f=_(n,Qn(s.columns)),m=jn(s.columns).length,g=!!n.locked,v=s.footer||s.wrapper.find(".k-grid-footer");if(r=o=f,n.hidden){var b=g?jn(s.columns):qn(s.columns);yn(b).length>0?(r=o=f=this._findClosestVisibleColumnIndex(b,h),a=yn(b.slice(h)).length>0):g?(f=s.lockedTable.find("colgroup"),r=s.lockedHeader.find("colgroup"),o=e(s.lockedFooter).find(">table>colgroup")):(f=s.tbody.prev(),r=s.thead.prev(),o=v.find(".k-grid-footer-wrap").find(">table>colgroup"))}s._hasFilterRow()&&an(s.wrapper.find(".k-filter-row td:not(.k-group-cell,.k-hierarchy-cell)"),u,h,i,t.length),p>=0&&an(sn(s.lockedHeader,s.thead.prev(),P),p,r,a||i,d.length),s.options.scrollable&&p>=0&&!s._hasVirtualColumns()&&an(sn(s.lockedTable,s.tbody.prev(),P),p,f,a||i,d.length),v&&v.length&&(p>=0&&an(sn(s.lockedFooter,v.find(".k-grid-footer-wrap"),">table>colgroup>col:not(.k-group-col,.k-hierarchy-col)"),p,o,a||i,d.length),an(v.find(".k-footer-template>td:not(.k-group-cell,.k-hierarchy-cell)"),u,h,i,t.length));var y=s.tbody.children(":not(.k-grouping-row,.k-detail-row)");s.lockedTable&&(m>h?m<=u&&gi(s.lockedTable.find(">tbody>tr.k-grouping-row:not([hidden])"),s.table.find(">tbody>tr.k-grouping-row:not([hidden])"),t.length):m>u&&gi(s.table.find(">tbody>tr.k-grouping-row:not([hidden])"),s.lockedTable.find(">tbody>tr.k-grouping-row:not([hidden])"),t.length),l=s.lockedTable.find(">tbody>tr:not(.k-grouping-row,.k-detail-row)"));for(var w=0,k=y.length;w<k;w+=1)an(sn(l[w],y[w],">td:not(.k-group-cell,.k-hierarchy-cell)"),u,h,i,t.length)},_findClosestVisibleColumnIndex:function(e,t){var n=yn(e.slice(t)).length>0?e.slice(t):e.slice(0,t+1).reverse(),i=yn(n)[0];return _(i,yn(this.columns))},_autoFitLeafColumn:function(e){this.autoFitColumn(ei(this.columns)[e])},_hasReorderableRows:function(){return this.options.reorderable&&this.options.reorderable.rows},_draggableRows:function(){var t=this,i=t._checkBoxSelection||t.options.selectable&&!n.ui.Selectable.parseOptions(t.options.selectable).cell,r=!1,o=!(!t._isMobile&&!n.support.mobileOS);t._draggableRowsInstance&&t._draggableRowsInstance.destroy(),!1!==this.options.reorderable.rows.clickMoveClick&&this._hasDragHandleColumn&&(r=!0),t._draggableRowsInstance=t.tbody.kendoDraggable({holdToDrag:o,showHintOnHold:o,preventOsHoldFeatures:o,group:"row-draggable",autoScroll:!0,filter:(i?" > .k-selected":" > "+z)+(t._hasDragHandleColumn?" > .k-drag-cell":""),hint:function(r){var o=e('<div class="k-reorder-clue k-drag-clue">'+n.ui.icon({icon:"cancel",iconClass:"k-drag-status"})+"</div>");if(i&&t.select().length>1&&t.lockedContent)o.append("<span>"+t.select().length/2+" "+w(t.options.messages.itemsSelected)+"</span>");else if(i&&t.select().length>1&&!t.lockedContent)o.append("<span>"+t.select().length+" "+w(t.options.messages.itemsSelected)+"</span>");else{var a=r.closest(z).clone();a.find("td.k-command-cell").remove(),a.find("td").each((function(e,t){o.append("<span>"+t.innerText+"&nbsp;</span>")}))}return o},clickMoveClick:r,cursorOffset:{top:0,left:0}}).data("kendoDraggable")},_reorderableRows:function(){var t=this,i=t._checkBoxSelection||t.options.selectable&&!n.ui.Selectable.parseOptions(t.options.selectable).cell;t.tbody.data("kendoReorderable")&&t.tbody.data("kendoReorderable").destroy(),t.tbody.kendoReorderable({smartPosition:!1,draggable:t._draggableRowsInstance,dragOverContainers:function(n,r){var o=!0,a=e(z,t.content).eq(r);return i&&(o=!a.is(".k-selected")),o},inSameContainer:function(t){return!i||!e(t.target).is(".k-selected")},dropFilter:"> "+z,allowIcon:"insert-middle",orientation:"vertical",reorderDropCue:e('<div class="k-drop-hint k-drop-hint-h"><div class="k-drop-hint-start"></div><div class="k-drop-hint-line"></div></div>'),positionDropCue:function(e,t){var i=n.getOffset(t.children(A).eq(0)).left;e.css({transform:"translate(0,-50%)",left:i})},externalDraggable:function(e){var t=e.draggable;if(t)return t},change:function(e){t._triggerRowRorder(e)}})},_triggerRowRorder:function(e){var t=this,i={newIndex:"after"===e.position?e.newIndex+1:e.newIndex,oldIndex:e.oldIndex},r=e.element,o=t._checkBoxSelection||t.options.selectable&&!n.ui.Selectable.parseOptions(t.options.selectable).cell;i=o&&t.select().length>1?f(i,{rows:t.select()}):f(i,{row:r}),t.trigger(Ne,i)||t.reorderRows(o?t.select():r,i.newIndex)},reorderRowTo:function(e,t){var n=this,i=n.dataItem(e),r=e.index();t<0||t===r||n.trigger(Ne,{row:e,oldIndex:e.index(),newIndex:t})||n.dataSource.pushMove(t,[i])},reorderRows:function(e,t){var n=this,i=n.dataSource,r=n.tbody.children(z).length,o=n.dataItem(n.tbody.children(z).eq(t)),a=e.toArray().map((function(e){return n.dataItem(e)}));o?t=i.indexOf(o):(o=n.dataItem(n.tbody.children(z).eq(r-1)),t=i.indexOf(o)+1),t>=0&&(n._rowDropping=!0,i.pushMove(t,a),n._rowDropping=!1)},autoFitColumns:function(e){var t=this;e=e||t.columns;for(var n=0;n<e.length;n++){var i=e[n];i.columns?t.autoFitColumns(i.columns):t.autoFitColumn(i)}},autoFitColumn:function(t){var i,r,o,a,s,l,d,u,h,f,m=this,v=m.options,b=m.columns,y=m.lockedHeader?ii(m.lockedHeader.find(">table>thead")).filter(vn).length:0,w="col:not(.k-group-col):not(.k-hierarchy-col)",k="td:visible:not(.k-group-cell):not(.k-hierarchy-cell)";if((t="number"==typeof t?b[t]:p(t)?g(Fn(b),(function(e){return e===t}))[0]:g(Fn(b),(function(e){return e.field===t}))[0])&&bn(t)){a=ei(b),d=t.minResizableWidth,i=_(t,a),(r=(o=(s=t.locked)?m.lockedHeader.children("table"):m.thead.parent()).find("[data-index='"+i+"']")).find("a.k-grid-column-menu, a.k-grid-filter-menu");var x=s?m.lockedTable:m.table,C=m.footer||e();m.footer&&m.lockedContent&&(C=s?m.footer.children(".k-grid-footer-locked"):m.footer.children(".k-grid-footer-wrap"));var S=C.find("table").first();m.lockedHeader&&!s&&(i-=y);for(var T=0;T<a.length&&a[T]!==t;T++)a[T].hidden&&i--;v.scrollable?(l=o.find(w).eq(i).add(x.children("colgroup").find(w).eq(i)).add(S.find("colgroup").find(w).eq(i)),s||(u=x.parent(),h=n.scrollLeft(u))):l=x.children("colgroup").find(w).eq(i);var D=o.add(x).add(S);Ut.safari&&r.css("white-space","initial");var A=c(r);l.width(""),D.css("table-layout","fixed"),l.width(Ze),D.addClass("k-autofitting"),D.css("table-layout",""),f=c(r);var M=Math.ceil(Math.max(f,c(x.find("tr:not(.k-grouping-row)").eq(0).children(k).eq(i)),c(S.find(mt).eq(0).children(k).eq(i))))+1;if(d&&d>M&&(M=d),l.width(M),t.width=M,Ut.safari&&r.css("white-space",""),v.scrollable){for(var E,I=o.find("col"),z=0,P=0,H=I.length;P<H;P+=1)if((E=I[P].style.width)&&-1==E.indexOf("%"))z+=parseInt(E,10);else{if(!I.eq(P).hasClass("k-group-col")){z=0;break}z+=parseInt(I.eq(P).width(),10)}z&&D.each((function(){this.style.width=z+ft}))}D.removeClass("k-autofitting"),h&&n.scrollLeft(u,h),m.trigger(Fe,{column:t,oldWidth:A,newWidth:M}),m._applyLockedContainersWidth(),m._syncLockedContentHeight(),m._syncLockedHeaderHeight(),m._updateStickyColumns()}},reorderColumn:function(e,n,i){var r,o=this,a=dn(n,o.columns),s=a?a.columns:o.columns,l=_(n,s),c=s[e],d=o.virtualScroll||{},u=!!c.locked,h=jn(o.columns).length,p=g(ei(o.columns),(function(e){return e.groupHeaderColumnTemplate}));if(l!==e&&(n.locked||!u||1!=qn(o.columns).length)&&(!n.locked||u||1!=h)){o._hideResizeHandle(),i===t&&(i=e<l);var f=[n];o._reorderHeader(f,c,i),o.lockedHeader&&(On(o.thead),On(o.lockedHeader)),c.columns&&(c=(c=ei(c.columns))[i?0:c.length-1]),n.columns&&(f=ei(n.columns)),o._reorderContent(f,c,i),r=(r=!!n.locked)!=u,n.locked=u,s.splice(i?e:e+1,0,n),s.splice(l<e?l:l+1,1),o._updateLockedCols(),o._updateCols(),o._templates(),o._updateColumnCellIndex(),o._updateColumnSorters(),p.length>0&&o._renderGroupRows(),o._updateTablesWidth(),o._applyLockedContainersWidth(),o._syncLockedHeaderHeight(),o._syncLockedContentHeight(),o._updateFirstColumnClass(),o._updateStickyColumns(),d.columns&&o.refresh(),r&&(u?o.trigger(Le,{column:n}):o.trigger(Be,{column:n}))}},_updateColumnCellIndex:function(){var e=0;this.lockedHeader&&(e=Tn(this.lockedHeader.find("thead"),jn(this.columns))),Tn(this.thead,qn(this.columns),e)},lockColumn:function(e){var t=this.columns;if((e="number"==typeof e?t[e]:g(t,(function(t){return t.field===e}))[0])&&!e.locked&&!e.hidden){e.sticky&&this.unstickColumn(t.indexOf(e));var n=jn(t).length-1;this.reorderColumn(n,e,!1)}},unlockColumn:function(e){var t=this.columns;if((e="number"==typeof e?t[e]:g(t,(function(t){return t.field===e}))[0])&&e.locked&&!e.hidden){var n=jn(t).length;this.reorderColumn(n,e,!0)}},stickColumn:function(e){var t=this.columns;!(e="number"==typeof e?t[e]:g(t,(function(t){return t.field===e}))[0])||e.sticky||e.hidden||e.locked&&(this.unlockColumn(t.indexOf(e)),e.locked)||(e.sticky=!0,this._updateStickyColumns())},unstickColumn:function(e){var t=this.columns;(e="number"==typeof e?t[e]:g(t,(function(t){return t.field===e}))[0])&&e.sticky&&!e.locked&&!e.hidden&&(this._removeStickyAttributes([e]),this._removeStickyStyles(Gn(t)),e.sticky=!1,this._updateStickyColumns(),0===this._anyStickyColumns()&&(this._templates(),this._hasFilterRow()&&this._updateStickyFilterCells()))},cellIndex:function(t){var n=0;return this.lockedTable&&!e.contains(this.lockedTable[0],t[0])&&(n=ei(jn(this.columns)).length),e(t).parent().children("td:not(.k-group-cell,.k-hierarchy-cell)").index(t)+n},_modelForContainer:function(t){(t=e(t)).is(mt)||"popup"===this._editMode()||(t=t.closest(mt));var i=t.attr(n.attr("uid"))||t.find(".k-popup-edit-form").attr(n.attr("uid"));return this.dataSource.getByUid(i)},_calculateColumnIndex:function(t){var n=this.cellIndex(t),i=0;return this._hasVirtualColumns()&&(i=(i=parseInt(e(t).closest(mt).find("td").first().attr("colspan"),10))>1?i-1:0),n+i},_editable:function(){let i=this,r=i.options.editable,o=n.support.mobileOS,a=!(!i._isMobile&&!o),l=o&&o.ios&&("chrome"===o.browser||"edge"===o.browser);if(i._isEditableEnabled=i._isEditableEnabled!==t?i._isEditableEnabled:!r.readonly,i._isEditableEnabled||i._removeEditableClickHandlers(),r&&i._isEditableEnabled){"incell"===i._editMode()?(i.table.add(i.lockedTable).on(We+B,E+">"+I,(function(t){let r=e(t.target);"incell"===i._editMode()&&r.hasClass("k-checkbox")&&r.prev().attr(n.attr("bind"))&&t.preventDefault()})),!1!==r.update&&(qt&&i.wrapper.on(Ue+B,".k-edit-cell > input[type='checkbox']",(function(t){e(t.target).trigger("focus")})).on(Ue+B,".k-edit-cell",(function(t){e(t.target).is("input")||e(t.currentTarget).find("input[type='checkbox']").trigger("focus")})).on(We+B,"tr:not(.k-grouping-row) > td",(function(t){var n=i._editContainer;n&&n[0]&&(e.contains(n[0],t.target)||n[0]===t.target)?i._mousedownOnEditCell=!0:i._mousedownOnEditCell=!1})),i.editableUserEvents=new n.UserEvents(i.wrapper,{filter:"tr:not(.k-grouping-row) > td",allowSelection:!0,preventDefault:l,supportDoubleTap:a,fastTap:a,[a?"doubleTap":"tap"]:function(t){var n=e(t.target),r=i.lockedTable&&n.closest("table")[0]===i.lockedTable[0];i._mousedownOnEditCell=!1,n.hasClass("k-hierarchy-cell")||n.hasClass("k-detail-cell")||n.hasClass("k-group-cell")||n.hasClass("k-edit-cell")||n.has(".k-grid-remove-command").length||n.closest("tbody")[0]!==i.tbody[0]&&!r||e(t.target).is(":input")||(i.editable?i.editable.end()?(e(s()).trigger("blur"),i.closeCell(),i._requestInProgress||i.editCell(n)):i._scrollVirtualWrapper():i.editCell(n))}}),i.wrapper.on("focusin"+B,(function(){e.contains(this,s())||(clearTimeout(i.timer),i.timer=null)})).on("focusout"+B,(function(t){var n=!0;(qt&&i._mousedownOnEditCell||i._virtualColScroll)&&(n=!1),i._mousedownOnEditCell=!1,n&&(i.timer=setTimeout((function(){!function(){let t=s(),n=i._editContainer;n&&n[0]&&!e.contains(n[0],t)&&n[0]!==t&&!e(t).closest(".k-animation-container").length&&(i.editable.end()?i.closeCell():i._scrollVirtualWrapper())}()}),1))})))):!1!==r.update&&(i._editCommandClickHandler=i._editCommandClick.bind(i),i.wrapper.on(Ue+B,"tbody>tr:not(.k-detail-row,.k-grouping-row):visible .k-grid-edit-command",i._editCommandClickHandler),i._isVirtualInlineEditable()&&i.wrapper.on("focusout"+B,"tr:not(.k-grouping-row) > td",(function(){i.editable&&!i.editable.end()&&i._scrollVirtualWrapper()}))),i._removeCommandClickHandler=i._removeCommandClick.bind(i),i.wrapper.on(Ue+B,"tbody>tr:not(.k-detail-row,.k-grouping-row):visible .k-grid-remove-command",i._removeCommandClickHandler)}},_editCommandClick:function(t){let n=e(t.currentTarget);this._belongsToGrid(n)&&(t.preventDefault(),this.editRow(n.closest(mt)))},_removeCommandClick:function(t){let n=this,i=n.options.editable,r=e(t.currentTarget);n._belongsToGrid(r)&&(!1!==i.destroy?(t.preventDefault(),t.stopPropagation(),n.removeRow(r.closest(mt))):(t.stopPropagation(),n._confirmation()||t.preventDefault()))},editCell:function(t){t=e(t);let n=this,i=ei(n.columns)[n._calculateColumnIndex(t)],r=n._modelForContainer(t);if(n.closeCell(),r&&xi(i,r)&&!i.command){if(n.trigger(V,{model:r}))return;n._attachModelChange(r),n._editContainer=t,n._shouldClearEditableState&&n._clearEditableState(),n.editable=t.addClass("k-edit-cell").kendoEditable({fields:ni(i),model:r,size:n.options.size,target:n,change:function(e){n.trigger(N,{values:e.values,container:t,model:r})&&e.preventDefault()},skipFocus:!(!n._isVirtualIncellEditable()&&!n._hasVirtualColumns()||!n._editableState)}).data("kendoEditable");let e=t.parent().addClass("k-grid-edit-row");!0===r.new&&(e.addClass("k-grid-add-row"),delete r.new),n.lockedContent&&(bi(e[0],n._relatedRow(e).addClass("k-grid-edit-row")[0]),e.hasClass("k-grid-add-row")&&n._relatedRow(e).addClass("k-grid-add-row"),n._syncLockedScroll()),n.trigger(O,{container:t,model:r})}},enableEditing:function(){let e=this,t=e.wrapper.find(".k-grid-toolbar");if(!e._isEditableEnabled){e._isEditableEnabled=!0,e._editable();let n=t.find(".k-grid-add").getKendoButton();n&&n.bind("click",e._createClickHandler)}},disableEditing:function(){let e=this;e._isEditableEnabled&&("incell"===e._editMode()?e.closeCell():e.cancelRow(),e._clearEditableState(),e._destroyEditable(),e.editableUserEvents&&(e.editableUserEvents.destroy(),e.editableUserEvents=null),e._removeEditableClickHandlers(),e._isEditableEnabled=!1)},_removeEditableClickHandlers:function(){let e=this,t=e.wrapper.find(".k-grid-toolbar");e.wrapper.off(Ue+B,"tbody>tr:not(.k-detail-row,.k-grouping-row):visible .k-grid-edit-command",e._editCommandClickHandler),e.wrapper.off(Ue+B,"tbody>tr:not(.k-detail-row,.k-grouping-row):visible .k-grid-remove-command",e._removeCommandClickHandler),t.off(Ue+B,".k-grid-add",e._createClickHandler);let n=t.find(".k-grid-add").getKendoButton();n&&n.unbind("click"),e._editCommandClickHandler=null,e._removeCommandClickHandler=null},_adjustLockedHorizontalScrollBar:function(){var e=this.table,t=e.parent(),i=e[0].offsetWidth>t[0].clientWidth?n.support.scrollbar():0;this.lockedContent.height(t[0].offsetHeight-i)},_syncLockedScroll:function(){this.lockedContent[0].scrollTop=this.content[0].scrollTop,this.virtualScrollable&&(this.lockedContent[0].scrollTop=this.wrapper.find(".k-virtual-scrollable-wrap")[0].scrollTop)},_syncLockedContentHeight:function(){this.lockedTable&&(this.touchScroller||this._adjustLockedHorizontalScrollBar(),this._adjustRowsHeight(this.table,this.lockedTable))},_syncLockedHeaderHeight:function(){if(this.lockedHeader){var e=this.lockedHeader.children("table"),t=this.thead.parent();this._adjustRowsHeight(e,t),function(e,t){if(e=e[0],t=t[0],e.rows.length!==t.rows.length){var n,i,r=e.offsetHeight,o=t.offsetHeight;r>o?(n=t.rows[t.rows.length-1],Ft.test(n.className)&&(n=t.rows[t.rows.length-2]),i=r-o):(n=e.rows[e.rows.length-1],Ft.test(n.className)&&(n=e.rows[e.rows.length-2]),i=o-r),n.style.height=n.offsetHeight+i+ft}}(e,t)}},_syncLockedFooterHeight:function(){this.lockedFooter&&this.footer&&this.footer.length&&this._adjustRowsHeight(this.lockedFooter.children("table"),this.footer.find(".k-grid-footer-wrap > table"))},_destroyEditable:function(){let e=this,t=function(){if(e.editable){let t=e.editView?e.editView.element:e._editContainer,n=e._editContainer.data("kendoWindow");t&&(n&&(t=n.wrapper),t.off(Ue+B,".k-grid-cancel-command, button[ref-cancel-button]",e._editCancelClickHandler),t.off(Ue+B,".k-grid-save-command, button[ref-update-button]",e._editUpdateClickHandler)),e._detachModelChange(),e.editable.destroy(),e.editable=null,n&&n.destroy(),e._editContainer=null,e._destroyEditView(),e._editableIsClosing=null}};e.editable&&("popup"!==e._editMode()||e._isMobile?t():e._editableIsClosing?e._editContainer.data("kendoWindow").bind("deactivate",t):(e._editableIsClosing=!0,e._editContainer.data("kendoWindow").bind("deactivate",t).close())),e._confirmDialog&&(e._confirmDialog.close(),e._confirmDialog.destroy(),e._confirmDialog=null)},_destroyEditView:function(){this.editView&&(this.editView.purge(),this.editView=null,this.pane.navigate(""))},_attachModelChange:function(e){var t=this;t._modelChangeHandler=function(e){t._modelChange({field:e.field,model:this})},e.bind("change",t._modelChangeHandler)},_detachModelChange:function(){var e=this,t=e._editContainer,n=e._modelForContainer(t);n&&n.unbind(Q,e._modelChangeHandler)},closeCell:function(e){let t,n,r,o,a=this,s=a._editContainer;if(s&&(r=a._modelForContainer(s),!e||!a.trigger("cancel",{container:s,model:r}))){if(a.trigger(K,{type:e?"cancel":"save",model:r,container:s}),s.removeClass("k-edit-cell"),t=ei(a.columns)[a._calculateColumnIndex(s)],o=a.editable&&a.editable.validatable&&a.editable.validatable.errors(),e&&r.dirtyFields&&r.dirtyFields[t.field]&&o.length&&delete r.dirtyFields[t.field],n=s.parent().removeClass("k-grid-edit-row"),n.hasClass("k-grid-add-row")&&n.removeClass("k-grid-add-row"),a.lockedContent){const e=a._relatedRow(n);e.removeClass("k-grid-edit-row"),e.hasClass("k-grid-add-row")&&e.removeClass("k-grid-add-row")}a._destroyEditable(),a._displayCell(s,t,r),a._shouldClearEditableState&&a._clearEditableState(),a.trigger("itemChange",{item:n,data:r,ns:i}),a.lockedContent&&bi(n.css(Qe,"")[0],a._relatedRow(n).css(Qe,"")[0])}},_displayCell:function(e,t,i){var r={storage:{},count:0},o=f({},n.Template,this.options.templateSettings),a=n.template(this._cellTmpl(t,r),o);r.count>0&&(a=a.bind(r.storage)),e.empty().html(a(i))},removeRow:function(e){this._confirmation(e)&&this._removeRow(e)},_removeRow:function(t){var n,i,r,o=this,a=o._editMode();"incell"!==a&&o.cancelRow(),t=e(t),o.lockedContent&&(t=t.add(o._relatedRow(t))),t=t.hide(),o.dataSource._isGroupPaged()&&o._removeGroupIfEmpty(t),(n=o._modelForContainer(t))&&!o.trigger($,{row:t,model:n})?(r=o.dataSource.options.schema,o._selectedIds&&r&&r.model&&(i=n[o._getSchemaIdField()],delete o._selectedIds[i]),o.dataSource.remove(n),"inline"!==a&&"popup"!==a||o.dataSource.sync()):"incell"===a&&o._destroyEditable()},_editMode:function(){let e="incell",t=this.options.editable;return!0!==t&&(e="string"==typeof t?t:t.mode||e),e},editRow:function(t){let i,r=this;t instanceof o?i=t:(t=e(t),i=r._modelForContainer(t));let a,s=r._editMode();r.cancelRow(),i&&(t=r.tbody.children("["+n.attr("uid")+"="+i.uid+"]"),r._attachModelChange(i),"popup"===s?r._createPopupEditor(i):"inline"===s?r._createInlineEditor(t,i):"incell"===s&&e(t).children(A).each((function(){let t=e(this),n=ei(r.columns)[r._calculateColumnIndex(t)];if(i=r._modelForContainer(t),i&&(!i.editable||i.editable(n.field))&&n.field&&!n.selectable)return r.editCell(t),!1})),a=r.editView?r.editView.element:"popup"===s?r._editContainer.parent():r._editContainer,a&&(this._editCancelClickHandler||(this._editCancelClickHandler=this._editCancelClick.bind(this)),a.on(Ue+B,".k-grid-cancel-command, button[ref-cancel-button]",this._editCancelClickHandler),this._editUpdateClickHandler||(this._editUpdateClickHandler=this._editUpdateClick.bind(this)),a.on(Ue+B,".k-grid-save-command, button[ref-update-button]",this._editUpdateClickHandler)))},_editUpdateClick:function(e){e.preventDefault(),e.stopPropagation(),this.saveRow()},_editCancelClick:function(t){var n=this,i=n.options.navigatable,r=n.editable.options.model,o=n.editView?n.editView.element:n._editContainer;if(t.preventDefault(),t.stopPropagation(),!n.trigger("cancel",{container:o,model:r})){var a=n.items().index(e(n.current()).parent());n.cancelRow(),i&&(n._setCurrent(n.items().eq(a).children().filter(I).first()),wi(n.table,!0))}},_editFields:function(e,t){for(var n,i=[],r=0;r<e.length;r++)(n=e[r]).selectable||n.command||xi(n,t)&&i.push(ni(n));return i},_createPopupEditor:function(t){var r,o,a,s,l,c,d,u,h,m,g,v,_,b=this,y="<div "+n.attr("uid")+'="'+t.uid+'" class="k-popup-edit-form"><'+(b._isMobile?'ul class="k-edit-form-container k-listgroup k-listgroup-flush">':'div class="k-edit-form-container">'),k=ei(b.columns),x=n.guid(),C=b.options.editable,S=C.template,T=p(C)?C.window:{},D=f({},n.Template,b.options.templateSettings);if(!b.trigger(V,{model:t})){if(T=T||{},S)for(typeof S===tt&&(S=n.unescape(S)),y+=n.template(S,D)(t),a=0,s=k.length;a<s;a++)(r=k[a]).command&&(m=yi(r.command,"edit"))&&(o=m);else for(a=0,s=k.length;a<s;a++)(r=k[a]).selectable||(r.command?r.command&&(m=yi(r.command,"edit"))&&(o=m):b._isMobile&&(y+='<li class="k-item k-listgroup-item">',xi(r,t)?(y+='<label class="k-label k-listgroup-form-row">',y+='<span class="k-item-title k-listgroup-form-field-label">'+(r.title&&(b.options.encodeTitles?Ii(r.title,!0):r.title)||r.field||"")+"</span>",y+='<div class="k-listgroup-form-field-wrapper" id="'+r.field+"_"+x+'" '+n.attr("container-for")+'="'+r.field+'"></div>',y+="</label>"):(v={storage:{},count:0},l=n.template(b._cellTmpl(r,v),D),v.count>0&&(l=l.bind(v.storage)),y+='<label class="k-label k-listgroup-form-row k-no-click">',y+='<span class="k-item-title k-listgroup-form-field-label">'+(r.title&&(b.options.encodeTitles?Ii(r.title,!0):r.title)||r.field||"")+"</span>",y+='<span class="k-no-editor k-listgroup-form-field-wrapper">'+l(t)+"</span>",y+="</label>"),y+="</li>"));if(o&&p(o)&&(p(o.text)&&(c=o.text.update,d=o.text.cancel),p(o.iconClass)&&(u=o.iconClass.update,h=o.iconClass.cancel),o.attr&&(g=o.attr)),b._isMobile){y+="</ul></div>";let e=w(b.options.messages.commands.cancel),t=w(b.options.messages.commands.update);b.editView=b.pane.append("<div data-"+n.ns+'role="view" class="k-grid-edit-form"><div data-'+n.ns+' class="k-appbar k-appbar-primary">'+n.html.renderButton(`<button class="k-header-cancel k-grid-cancel-command" title="${e}" aria-label="${e}"></button>`,{fillMode:"flat",icon:"chevron-left"})+'<span class="k-spacer"></span>'+`<span>${w(b.options.messages.commands.edit||"Edit")}</span><span class="k-spacer"></span>`+n.html.renderButton(`<button class="k-header-done k-grid-save-command" title="${t}" aria-label="${t}"></button>`,{fillMode:"flat",icon:"check"})+"</div><div data-"+n.ns+'role="content" class="'+Gt+'">'+y+"</div></div>"),_=b._editContainer=b.editView.element.find(".k-popup-edit-form")}else{let n=e(b._createButton({name:"update",text:c,attr:g,iconClass:u,size:"medium",skipCommandClass:!0})).attr("ref-update-button",""),i=e(b._createButton({name:"canceledit",text:d,attr:g,iconClass:h,size:"medium",skipCommandClass:!0})).attr("ref-cancel-button","");y+="</div>",_=b._editContainer=e(y).appendTo(b.wrapper).eq(0).kendoWindow(f({modal:!0,resizable:!1,draggable:!0,title:b.options.messages.commands.edit||"Edit",_footerTemplate:()=>'<div class="k-actions k-actions-start k-actions-horizontal k-window-actions">'+n[0].outerHTML+i[0].outerHTML+"</div>",visible:!1,close:function(n){if(n.userTriggered){if(n.sender.element.trigger("focus"),b.trigger("cancel",{container:_,model:t}))return void n.preventDefault();var i=b.items().index(e(b.current()).parent());b._editableIsClosing=!0,b.cancelRow(),b.options.navigatable&&(b._setCurrent(b.items().eq(i).children().filter(I).first()),wi(b.table,!0))}}},T))}S||b._isMobile?b.editable=b._editContainer.kendoEditable({fields:b._isMobile&&!S?b._editFields(k,t):null,model:t,clearContainer:!1,target:b,skipFocus:!0}).data("kendoEditable"):(b.editable=new i.Form(b._editContainer.find(".k-edit-form-container"),{items:b._editFields(k,t),buttonsTemplate:()=>"",formData:t}).editable,b._editContainer.append(undefined)),b._openPopUpEditor(),b.trigger(O,{container:_,model:t})}},_openPopUpEditor:function(){var e=this,t=e._editContainer?e._editContainer.data("kendoWindow"):null,n=(e.options.editable||{}).window||{};this._isMobile?this.pane.navigate(this.editView,this._editAnimation):t&&(n.position||t.center(),t.open())},_createInlineEditor:function(t,i){var r,o,a,s=this,l=[];s.trigger(V,{model:i})||(s.lockedContent&&(t=t.add(s._relatedRow(t))),t.children(":not(.k-group-cell,.k-hierarchy-cell)").each((function(){if(o=e(this),!(r=ei(s.columns)[s._calculateColumnIndex(o)]).command&&xi(r,i))l.push(ni(r)),o.attr(n.attr("container-for"),r.field),o.empty();else if(r.command){var t,c,d,u,h;if(a=yi(r.command,"edit"))o.empty(),p(a)&&(p(a.text)&&(t=a.text.update,c=a.text.cancel),p(a.iconClass)&&(d=a.iconClass.update,u=a.iconClass.cancel),a.attr&&(h=a.attr)),e(s._createButton({name:"update",text:t,attr:h,iconClass:d})+s._createButton({name:"canceledit",text:c,attr:h,iconClass:u})).appendTo(o)}})),s._editContainer=t,s._editContainer.addClass("k-grid-edit-row"),!0===i.new&&(s._editContainer.addClass("k-grid-add-row"),delete i.new),s._shouldClearEditableState&&s._clearEditableState(),s.editable=new n.ui.Editable(s._editContainer,{target:s,fields:l,size:s.options.size,model:i,skipFocus:s._isVirtualInlineEditable()&&s._editableState&&!!s._editableState.field||s._hasVirtualColumns(),clearContainer:!1}),t.length>1&&(bi(t[0],t[1]),s._applyLockedContainersWidth(!0)),s.trigger(O,{container:t,model:i}))},cancelRow:function(e){var t,i=this,r=i._editContainer;if(r){if(!(t=i._modelForContainer(r))||e&&i.trigger("cancel",{container:r,model:t}))return;i._destroyEditable(),i.dataSource.cancelChanges(t),i._clearEditableState(),"popup"!==i._editMode()?i._displayRow(r):i._displayRow(i.tbody.find("["+n.attr("uid")+"="+t.uid+"]")),i._aria()}},saveRow:function(){var t,n=this,i=this._editContainer,r=this._modelForContainer(i),o=e.Deferred();return i&&this.editable?!(t=n.editable&&n.editable.end())||this.trigger(N,{container:i,model:r})?(t||n._scrollVirtualWrapper(),o.reject().promise()):(n._clearEditableState(),this.dataSource.sync()):o.resolve().promise()},_displayRow:function(t){var r,o,a,s=this,l=s._modelForContainer(t),c=t.hasClass(ge),d=t.hasClass("k-alt");l&&(s.lockedContent&&(r=e((d?s.lockedAltRowTemplate:s.lockedRowTemplate)(l)),n.applyStylesFromKendoAttributes(r,["display"]),s._relatedRow(t.last()).replaceWith(r)),o=e((d?s.altRowTemplate:s.rowTemplate)(l)),t.is(":visible")||o.hide(),n.applyStylesFromKendoAttributes(o,["display"]),s._anyStickyColumns()&&n.applyStylesFromKendoAttributes(o,["left","right"]),t.replaceWith(o),s.trigger("itemChange",{item:o,data:l,ns:i}),r&&r.length&&s.trigger("itemChange",{item:r,data:l,ns:i}),c&&(s.options.selectable||s._checkBoxSelection)&&s.select(o.add(r)),r&&bi(o[0],r[0]),(a=o.next()).hasClass("k-detail-row")&&a.is(":visible")&&n.ui.icon(o.find(".k-hierarchy-cell .k-icon,.k-hierarchy-cell .k-svg-icon"),{icon:"caret-alt-down"}))},_showMessage:function(t,i){var r=this;return r._isMobile?((r._confirmDialog=new n.ui.Confirm(e("<div />").appendTo(document.body),{modal:{preventScroll:!0},closable:!1,title:!1,content:t.title,messages:{okText:t.confirmDelete,cancel:t.cancelDelete},open:function(){r.content&&(r.content.data(lt,r.content.css(lt)),r.content.css(lt,"hidden"))},close:function(){r.content&&r.content.css(lt,r.content.data(lt))}})).result.done((function(){r._removeRow(i)})).fail((function(){var e=r._confirmDialog;e&&(e.close(),e.destroy())})),!1):window.confirm(t.title)},_confirmation:function(e){var t=this,n=t.options.editable,i=!0===n||typeof n===tt?t.options.messages.editable.confirmation:n.confirmation;return p(n)&&typeof n.mode===tt&&typeof i!==et&&typeof i!==tt&&!1!==i&&(i=t.options.messages.editable.confirmation),!1===i||null==i||(typeof i===et&&(i=i(t._modelForContainer(e))),t._showMessage({confirmDelete:n.confirmDelete||t.options.messages.editable.confirmDelete,cancelDelete:n.cancelDelete||t.options.messages.editable.cancelDelete,title:!0===i?t.options.messages.editable.confirmation:i},e))},cancelChanges:function(){var e=this;e._cachedRowsHeight&&(e._mapCachedRowsHeight("getByUid","id"),e._shouldMapHights=!0),e.dataSource.cancelChanges(),e._isVirtualEditable()&&e._virtualPageToTop((function(){e.virtualScrollable.scrollToTop()}))},saveChanges:function(){var e=this,t=e.editable&&e.editable.end();!t&&e.editable||e.trigger(J)?t||e._scrollVirtualWrapper():e.dataSource.sync()},addRow:function(){var e,t,n=this,i=n.dataSource,r=n._editMode(),o=n.options.editable.createAt||"",a=i.pageSize(),s=i.view()||[],l=o.toLowerCase()===nt,c=n._isVirtualEditable();n.editable&&n.editable.end()||!n.editable?("incell"!=r&&n.cancelRow(),e=i.indexOf(s[0]),l&&(e+=s.length,a&&!i.options.serverPaging&&a<=s.length&&(e-=1)),e<0&&(e=i.page()>i.totalPages()?(i.page()-1)*a:0),n.options.navigatable&&"incell"==r&&n._removeCurrent(),c?n._virtualAddRow():((t=i.insert(e,{})).new=!0,n._editModel(t))):n._scrollVirtualWrapper()},_editModel:function(e){var t=this,i=t.options.editable.createAt||"",r=t._editMode();if(e){var o=e.uid,a=(t.lockedContent?t.lockedTable:t.table).find("tr["+n.attr("uid")+"="+o+"]"),s=a.children("td:not(.k-group-cell,.k-hierarchy-cell)").eq(t._firstEditableColumnIndex(a));"inline"===r&&a.length?t.editRow(a):"popup"===r?t.editRow(e):s.length&&t.editCell(s),"bottom"==i.toLowerCase()&&t.lockedContent&&(t.lockedContent[0].scrollTop=t.content[0].scrollTop=t.table[0].offsetHeight)}},_virtualAddRow:function(){var e=this,t=(e.options.editable.createAt||"").toLowerCase()===nt;e._clearEditableState(),t?e._virtualAddRowAtBottom():e._virtualAddRowAtTop()},_virtualAddRowAtTop:function(){var e,t=this,n=t.dataSource,i=t.virtualScrollable;1===n.page()?((e=n.insert(0,{})).new=!0,t._editModel(e),i.scrollToTop()):t._virtualPageToTop((function(){(e=n.insert(0,{})).new=!0,t._editModel(e),i.scrollToTop()}))},_virtualAddRowAtBottom:function(){var e,t=this,n=t.dataSource,i=t.virtualScrollable,r=n.total();n.at(r-1)instanceof o?((e=n.insert(r,{})).new=!0,t._virtualPageToBottom((function(){t._editModel(e),i.scrollToBottom()}))):t._virtualPageToBottom((function(){(e=n.insert(r,{})).new=!0,t._editModel(e),i.scrollToBottom()}))},_virtualPageToTop:function(e){this._virtualPage(0,this.dataSource.take(),(function(){e()}))},_virtualPageToBottom:function(e){var t=this.dataSource,n=t.take(),i=t.total(),r=i>n?i-n:0;this._virtualPage(r,n,(function(){e()}))},_virtualPage:function(e,t,n){var i=this;i._isVirtualEditable()&&(i.virtualScrollable._preventScroll=!0,i.virtualScrollable._page(e,t,n))},_firstEditableColumnIndex:function(e){var t,n,i,r=ei(this.columns),o=this._modelForContainer(e);for(n=0,i=r.length;n<i;n++)if(t=r[n],o&&(!o.editable||o.editable(t.field))&&!t.command&&t.field&&!0!==t.hidden)return n;return-1},_clickAdd:function(e){e.preventDefault&&e.preventDefault(),this.addRow()},_clickCancel:function(e){e.preventDefault&&e.preventDefault(),this.cancelChanges()},_clickExcel:function(t){var n=this,i=e.Deferred();t.preventDefault&&t.preventDefault(),n._isExport=!0,n._progress(!0),setTimeout((()=>{n.saveAsExcel(i),i.always((()=>{n._progress(!1),n._isExport=!1}))}),1)},_clickPdf:function(e){var t=this;e.preventDefault&&e.preventDefault(),t._isExport=!0,t._pdfInitialized=!0,t._progress(!0);var n=t.saveAsPDF();n&&n.done((function(){t._progress(!1),t._isExport=!1,t._pdfInitialized=!1}))},_clickSave:function(e){e.preventDefault&&e.preventDefault(),this.saveChanges()},_searchInput:function(e){var t=this,n=e.currentTarget;clearTimeout(t._searchTimeOut),t._searchTimeOut=setTimeout((function(){t._searchTimeOut=null;var e=t.options,i=e.search?e.search.fields:null,r={filters:[],logic:"or"},o=n.value;if(i||(i=ti(e.columns)),t.dataSource.options.endless&&(t.dataSource.options.endless=null,t._endlessPageSize=t.dataSource.options.pageSize),o)for(var a=0;a<i.length;a++)t._pushExpression(r.filters,i[a],o);else r={};t.dataSource.filter(r)}),300)},_pasteToolbarDropDown:function(){var e=this;e.wrapper.find(".k-grid-paste-action").length&&(e.pasteActionsDropDownList=e.wrapper.find(".k-grid-paste-action").kendoDropDownList({dataSource:[{value:"insert",text:"Paste (Insert)"},{value:"replace",text:"Paste (Replace)"}],dataTextField:"text",dataValueField:"value",_allowFilterPaste:!1}).data("kendoDropDownList"))},_pushExpression:function(e,t,i){var r=this,o=r.dataSource.options.serverFiltering,a={string:"contains",number:"gte",date:"gte",enums:"eq",boolean:"eq"},s=t.name||t,l=t.operator,c=r.dataSource.reader.model&&r.dataSource.reader.model.fields,d=c&&c[s],u=d&&d.parse,h={field:s,operator:l||a.string,value:i};(l||o)&&d&&n.isFunction(u)&&null!==u(i)&&f(h,{operator:l||a[d.type],value:u(i)}),o&&d&&n.isFunction(u)&&null===u(i)||e.push(h)},_toolbar:function(){var t,i,r=this,o=r.wrapper,a=r.options.toolbar;a&&(r._createClickHandler=r._addClickHandler=r._clickAdd.bind(r),r._cancelClickHandler=r._clickCancel.bind(r),r._saveClickHandler=r._clickSave.bind(r),r._excelClickHandler=r._clickExcel.bind(r),r._pdfClickHandler=r._clickPdf.bind(r),r._serachHandler=r._searchInput.bind(r),(t=r.wrapper.find(".k-grid-toolbar")).length?r._attachToolbarClicks():(t=e('<div class="k-grid-toolbar k-toolbar" />').prependTo(o),typeof a===tt||y(a)?(typeof a===tt&&(a=n.template(a).bind(r)),t.html(a({grid:r})),r._attachToolbarClicks()):v(a)&&(i=r._processItems(a),t.kendoToolBar({navigateOnTab:!r.options.navigatable,size:r.options.size,items:i}))),t.on(ot+B,".k-grid-search input",this._serachHandler))},_attachToolbarClicks:function(){var e=this.options.editable,t=this.wrapper.find(".k-grid-toolbar");e&&!1!==e.create&&t.on(Ue+B,".k-grid-add",this._createClickHandler).on(Ue+B,".k-grid-cancel-changes",this._cancelClickHandler).on(Ue+B,".k-grid-save-changes",this._saveClickHandler),t.on(Ue+B,".k-grid-excel",this._excelClickHandler),t.on(Ue+B,".k-grid-pdf",this._pdfClickHandler)},_processItems:function(e){var i=this,r=i.options,o=[],a=this.options.messages.commands,s=!1;return e.map((e=>{var l,c,d,u,h="";if("string"==typeof e?(l=e.toLowerCase(),(e={}).text=a[l]||l):(l=(e.name||e.text||"").toLowerCase(),e.text=e.text||a[l]||l),s||"search"!==l&&"columns"!==l||(s=!0,o.push({type:"spacer"})),"search"===l)c=Ii(e.text||a.search,!0),d=e.icon||e.iconClass||"search",h+=`<span class='k-searchbox k-input ${n.getValidCssClass("k-input-","size",i.options.size)} k-rounded-md k-input-solid k-grid-search'>`,h+=n.ui.icon({icon:d,iconClass:"k-input-icon"}),h+="<input autocomplete='off' placeholder='"+c+"' title='"+c+"' aria-label='"+c+"' class='k-input-inner' />",h+="</span>",o.push({name:"search",overflow:"never",template:h});else if("paste"===l&&r.allowPaste)o.push({template:"<input class='k-grid-paste-action' />"});else{if(!(l||p(e)&&e.template))throw new Error("Custom commands should have name specified");u=(e=f({type:"button"},rn[l],e)).className||"k-grid-"+(l||"").replace(/\s/g,""),e.spriteCssClass=e.icon?null:e.iconClass,e.attributes=i._processAttr(e.attr),delete e.attr,u&&(e.attributes.class===t&&(e.attributes.class=""),e.attributes.class+=" "+u),e.template&&delete e.type,i["_"+l+"ClickHandler"]&&(e.click=i["_"+l+"ClickHandler"]),o.push(e)}})),o},_processAttr:function(e){var t={};return typeof e===tt&&e.length>0?e.split(" ").map((e=>{var n=e.split("=");2===n.length&&(t[n[0]]=n[1].replaceAll('"',"").replaceAll("'",""))})):p(e)&&(t=e),t},_createButton:function(i){var r,o,a=i.template||Rt,s=typeof i===tt?i:i.name||i.text,l=rn[s]?rn[s].className:"k-grid-"+(s||"").replace(/\s/g,""),c={className:i.skipCommandClass?"":l,text:s,attr:"",iconClass:"",size:i.size||this.options.size},d=this.options.messages.commands;if(!(s||p(i)&&i.template))throw new Error("Custom commands should have name specified");if(p(i)){if((i=f(!0,{},i)).className&&_(c.className,i.className.split(" "))<0?i.className+=" "+c.className:i.className===t&&(i.className=c.className),i.className.indexOf("k-primary")>-1&&(i.className=i.className.replace("k-primary",""),i.themeColor="primary"),"edit"===s&&((i=f(!0,{},i)).text=p(i.text)?i.text.edit:i.text,i.iconClass=p(i.iconClass)?i.iconClass.edit:i.iconClass),i.attr){if(p(i.attr)&&(i.attr=nn(i.attr)),i.attr instanceof Function){let e=i.attr(i);i.attr=nn(e)}typeof i.attr===tt&&(o=i.attr.match(/class="(.+?)"/))&&_(o[1],i.className.split(" "))<0&&(i.className+=" "+o[1])}c=f(!0,c,rn[s],{text:d[s]},i)}else c=f(!0,c,rn[s],{text:d[s]});return r=n.template(a)(c),i.template?r:n.html.renderButton(e(r),c)},_hasFooters:function(){return!!this.footerTemplate||!!this.groupFooterTemplate||this.footer&&this.footer.length>0||this.wrapper.find(".k-grid-footer").length>0},_groupable:function(){var t=this;t._groupableClickHandler?t.table.add(t.lockedTable).off(Ue+B,t._groupableClickHandler):t._groupableClickHandler=function(n){var i=e(this),r=i.closest(mt),o=t._groupRows?t._groupRows[t.wrapper.find(S+ze).index(r)]:{};i.is(F)?t.trigger("groupCollapse",{group:o,element:r})||t.collapseGroup(r):t.trigger("groupExpand",{group:o,element:r})||t.expandGroup(r),n.preventDefault(),n.stopPropagation()},t._isLocked()?t.lockedTable.on(Ue+B,".k-grouping-row "+R+", .k-grouping-row "+F,t._groupableClickHandler):t.table.on(Ue+B,".k-grouping-row "+R+", .k-grouping-row "+F,t._groupableClickHandler),t._attachGroupable()},_attachGroupable:function(){var t=this,r=t.wrapper,o=t.options.groupable,a=H+"["+n.attr("field")+"]",s=t.content?".k-grid-header:first "+a:"table:first>.k-grid-header "+a;o&&!1!==o.enabled&&(r.has("div.k-grouping-header")[0]||e("<div/>").addClass("k-grouping-header").prependTo(r),t.groupable&&t._destroyGroupable(),Ut.chrome&&(r.find("div.k-grouping-header").css("touch-action",Dt),r.find(s).css("touch-action",Dt)),t.groupable=new i.Groupable(r,f({},o,{draggable:t._draggableInstance,groupContainer:">div.k-grouping-header",dataSource:t.dataSource,draggableElements:s,filter:s,size:t.options.size,allowDrag:t.options.reorderable,enableContextMenu:!!t.options.contextMenu,removeGroup:function(e){t._showUngroupedColumn(e)},change:function(e){t.trigger("group",{groups:e.groups})?e.preventDefault():(t._clearEditableState(),t._hideGroupedColumns(e.groups),t.dataSource.options.endless&&t._resetEndless())}})),t._addGroupableOptionsToHeader())},_showUngroupedColumn:function(e){var t,n=ei(this.columns);for(t=0;t<n.length;t++)n[t].uid==e.colID&&n[t].hideOnGroup&&this.showColumn(n[t])},_hideGroupedColumns:function(e){if(e){var t,n=ei(this.columns),i=[];for(t=0;t<e.length;t++)e[t].colID&&i.push(e[t].colID);for(t=0;t<n.length;t++)i.indexOf(n[t].uid)>=0&&n[t].hideOnGroup&&this.hideColumn(n[t])}},_resetEndless:function(){var e=this;e.dataSource.options.endless=null,e._endlessPageSize=e.dataSource.options.pageSize,e.dataSource._skip=0,e.dataSource._pageSize=e.dataSource._take=e._endlessPageSize,e.dataSource._page=1},_addGroupableOptionsToHeader:function(){var e,t,i,r=Fn(this.columns),o={},a=this._headerCells();for(i=0;i<r.length;i++)r[i].field,o[r[i].field]=r[i];for(i=0;i<a.length;i++)(t=o[(e=a.eq(i)).attr(n.attr(rt))])&&t.groupable&&t.groupable.sort&&e.data(dt,t.groupable.sort)},_destroyGroupable:function(){var e=this;e.groupable&&e.groupable.element&&e.groupable.element.kendoGroupable("destroy"),e.groupable=null,e._removeGroupableOptionsFromHeader()},_removeGroupableOptionsFromHeader:function(){for(var e=this._headerCells(),t=0;t<e.length;t++)e.eq(t).removeData(dt)},_continuousItems:function(t,n){if(this.lockedContent){for(var i=this,r=i.table.add(i.lockedTable),o=e(t,r[0]),a=e(t,r[1]),s=n?jn(ei(i.columns)).length:1,l=n?ei(i.columns).length-s:1,c=[],d=0;d<o.length;d+=s)b.apply(c,o.slice(d,d+s)),b.apply(c,[].splice.call(a,0,l));return c}},_selectable:function(){var t,i,r=this,o=[],a=r._isLocked(),s=r.options.selectable,l="skeleton"===r.options.loaderType;if(s&&!s.checkboxSelection){r.selectable&&r.selectable.destroy(),r._selectedIds={},s=n.ui.Selectable.parseOptions(s),t=s.multiple,i=s.cell,r._hasDetails()&&(o[o.length]=".k-detail-row"),(r.options.groupable||r._hasFooters()||r._groups())&&(o[o.length]=".k-grouping-row,.k-group-footer"),l&&(o[o.length]="[data-skeleton-row]"),""!==(o=o.join(","))&&(o=":not("+o+")");var c=r.table;a&&(c=c.add(r.lockedTable));var d=">"+(i?"tbody>tr:not(.k-grouping-row):not(.k-detail-row):not(.k-group-footer):not([data-skeleton-row]) > td:not(.k-group-cell):not(.k-hierarchy-cell)":"tbody>tr"+o);r.selectable=new n.ui.Selectable(c,{allowPaste:r.options.allowPaste,filter:d,aria:!0,multiple:t,holdToDrag:!(!r._isMobile&&!n.support.mobileOS),toggleable:!(!r._isMobile&&!n.support.mobileOS),dragToSelect:r.options.selectable&&r.options.selectable.dragToSelect,changing:function(e){r.trigger(Y,{target:e.target,originalEvent:e.originalEvent})&&e.preventDefault()},change:function(e){var t;i||r._persistSelectedRows(),r._checkBoxSelection&&(t=r.selectable.value(),r._uncheckCheckBoxes(),r._checkRows(t),t.length&&t.length===r.items().length?r._toggleHeaderCheckState(!0):r._toggleHeaderCheckState(!1)),r._calculateAggregatesForSelected(),e.event&&r.trigger(Q,{cellAggregates:r._cellAggregates})},useAllItems:a&&t&&i,relatedTarget:function(t){if(!i&&a){for(var n,o=e(),s=0,l=t.length;s<l;s++)n=r._relatedRow(t[s]),_(n[0],t)<0&&(o=o.add(n));return o}},continuousItems:function(){return r._continuousItems(d,i)},ignoreOverlapped:r.options.selectable&&r.options.selectable.ignoreOverlapped,addIdToRanges:!0}),r.options.navigatable&&c.on("keydown"+B,(function(n){var o,s,l=r.current(),d=n.target,h={event:n};if(l)if(n.keyCode===u.SPACEBAR&&!n.shiftKey&&e.inArray(d,c)>-1&&!l.is(".k-edit-cell,.k-header")&&l.parent().is(":not(.k-grouping-row,.k-detail-row,.k-group-footer)")){if(n.preventDefault(),n.stopPropagation(),((o=!(l=i?l:l.parent()).hasClass(ge)||r.selectable.value().length>1)||t&&l.hasClass(ge)&&n.ctrlKey)&&r.trigger(Y,{target:l,originalEvent:n}))return;if(a&&!i&&(l=l.add(r._relatedRow(l))),t)if(n.ctrlKey){if(l.hasClass(ge))return r._deselectCheckRows(l),r._calculateAggregatesForSelected(),void r.trigger(Q,{cellAggregates:r._cellAggregates})}else r.selectable.clear();else r.selectable.clear();i||(r.selectable._lastActive=l),r.selectable.value(l),o&&(r._calculateAggregatesForSelected(),r.trigger(Q,{cellAggregates:r._cellAggregates}))}else if(!i&&(e(d).is("td")||e(d).is("table")&&_(d,this._navigatableTables))&&(n.shiftKey&&n.keyCode==u.LEFT||n.shiftKey&&n.keyCode==u.RIGHT||n.shiftKey&&n.keyCode==u.UP||n.shiftKey&&n.keyCode==u.DOWN||n.keyCode===u.SPACEBAR&&n.shiftKey)){if(n.preventDefault(),n.stopPropagation(),l=l.parent(),r.trigger(Y,{target:l,originalEvent:n}))return;s=r.selectable.value(),a&&(l=l.add(r._relatedRow(l))),t?(r.selectable._lastActive||(r.selectable._lastActive=l),r.selectable.selectRange(r.selectable._firstSelectee(),l),function(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}(s,r.selectable.value())||r.trigger(Q,h)):l.hasClass(ge)||(r.selectable.clear(),r.selectable.value(l),r._calculateAggregatesForSelected(),r.trigger(Q,{cellAggregates:r._cellAggregates}))}}))}},_pasteReplaceHandler:function(t){var n,i,r,o,a,s=this,l=[];(i=s.select().first()).length&&(i.is(mt)&&(i=i.children("td").first()),n=t.split("\n").filter((e=>e)),r=i.closest("tr"),a=s.thead.find("th:eq("+i.index()+")").data("field"),o=r.data("uid"),l.push(o),r.nextAll(z).slice(0,n.length-1).each(((t,n)=>{l.push(e(n).data("uid"))})),s._executePaste(n,l,null,a))},_pasteInsertHandler:function(e){var t,n,i,r,o,a=this,s=a.dataSource;(n=a.select().first()).length&&(n.is(mt)&&(n=n.children("td").first()),t=e.split("\n").filter((e=>e)),i=n.closest("tr"),o=a.dataItem(i),r=s.indexOf(o)+1,a._executePaste(t,null,r,null))},_executePaste:function(e,t,n,i){var r,o,a,s,l,c=this,d=c.dataSource,u=t||!1,h=c._getSelectedRowUids(),p=c._getSelectedColumnFields(),f=[],m=Qn(c.columns).filter((e=>!e.selectable&&!e.draggable&!e.command)),g=i&&m.map((e=>e.field)).indexOf(i);if(1===e.length&&1===e[0].split("\t").length&&u)for(let t=0;t<h.length;t++){const n=h[t];r=d.getByUid(n),a=e[0].split("\t")[0];for(let e=0;e<p.length;e++)l=p[e],r&&a&&r.set(l,a);r&&r.dirty&&f.push(r)}else for(let i=0;i<e.length;i++){o=e[i].split("\t"),r=u?d.getByUid(t[i]):d.insert(n+i,{});for(let e=0;e<o.length;e++)a=o[e].replace(/\r/,""),(s=m[e+g||0])&&r&&a&&(l=s.field,r.set(l,a));r&&r.dirty&&f.push(r)}c.trigger(ae,{items:f,type:u?"replace":"insert"})},_pasteKeyboardHandler:function(t){var n,i,r,o=this,a=o.current(),s=t.originalEvent.clipboardData,l=o.pasteActionsDropDownList&&o.pasteActionsDropDownList.value()||"insert";e(t.target).is(".k-edit-cell input:visible")||s&&(t.preventDefault(),function(e){return!/\S/.test(e)}(r=s.getData("text").trimEnd())&&(r=" "),a&&a.length&&(i=a.index(),n=a.closest(mt).data("uid")),"replace"===l&&o._pasteReplaceHandler(r),"insert"===l&&o._pasteInsertHandler(r),i&&n&&(o._currentRowIndex=o.wrapper.find("tr[data-uid='"+n+"']").index(),o._restoreCurrent(i)))},_paste:function(){var e=this,t=e.options,n=t.selectable;if(t.allowPaste&&n){e.pasteHandler=e._pasteKeyboardHandler.bind(e);(e.content||e.table).on(ae+B,e.pasteHandler),e.options.toolbar&&e._pasteToolbarDropDown()}},_clipboard:function(){var e=this.options;if(e.selectable&&e.allowCopy){var t=this;e.navigatable||(t.table.attr(Je,0),t.table.add(t.lockedTable).on(We+B+" keydown"+B,".k-detail-cell",(function(e){e.target!==e.currentTarget&&e.stopImmediatePropagation()})).on(We+B,E+">"+I,Si.bind(t))),t.copyHandler=t.copySelection.bind(t),t.updateClipBoardState=function(){t.areaClipBoard&&t.areaClipBoard.val(t.getTSV()).trigger("focus").select()};const n=t.content||t.table;t.bind("change",t.updateClipBoardState),n.on("keydown",t.copyHandler),t.clearAreaHandler=t.clearArea.bind(t),n.on("keyup",t.clearAreaHandler)}},copySelectionToClipboard:function(e){this._createAreaClipBoard(),this.areaClipBoard.val(this.getTSV(e)).trigger("focus").select(),document.execCommand("copy")},copySelection:function(t){t instanceof jQuery.Event&&!t.ctrlKey&&!t.metaKey||67!==t.keyCode||!t.ctrlKey&&!t.metaKey||e(t.target).is("input:visible,textarea:visible")||window.getSelection&&window.getSelection().toString()||document.selection&&document.selection.createRange().text||(this._createAreaClipBoard(),this.areaClipBoard.val(this.getTSV()).trigger("focus").select())},_createAreaClipBoard:function(){this.areaClipBoard||(this.areaClipBoard=e("<textarea />").css({position:"fixed",top:"50%",left:"50%",opacity:0,width:0,height:0}).appendTo(this.wrapper))},getTSV:function(n){var i=this,r=i.select(),o="\t",a=i.options.allowCopy,s=i._isLocked()&&jn(i.columns).length;e.isPlainObject(a)&&a.delimeter&&(o=a.delimeter);var l="";if(r.length){r.eq(0).is(mt)&&(r=r.find("td:not(.k-group-cell)")),r.filter(":visible");var c,d=[],u=this.columns.length,h=i._isLocked()&&jn(i.columns).length,p=!0,f=[],m=Qn(this.columns);e.each(r,(function(t,n){if(n=e(n),c=i._getCellField(n,s),-1!==m.findIndex((e=>e.field===c))){var r=n.closest(mt).index(),o=n.index();o-=n.prevAll(":hidden").length,h&&p&&(p=e.contains(i.lockedTable[0],n[0])),i._groups()&&p&&(o-=i._groups()),o=p?o:o+h,c&&(f[o]=c),u>o&&(u=o);var a=n.text();d[r]||(d[r]=[]),d[r][o]=a}}));var g=d.length;if(d=e.each(d,(function(e,t){t&&(d[e]=t.slice(u),g>e&&(g=e))})),n&&f.length){d.splice(g,0,f.map((function(e){return function(e,t){return t.filter((function(t){return t.field===e}))[0].title||e}(e,m)})));var v=d.findIndex((function(e){return e!==t}));d[v]=d[v].slice(u)}e.each(d.slice(g),(function(e,t){l+=t?t.join(o)+"\r\n":"\r\n"}))}return l},clearArea:function(e){this.areaClipBoard&&e&&e.target===this.areaClipBoard[0]&&wi(this.table,!0),this.areaClipBoard&&(this.areaClipBoard.remove(),this.areaClipBoard=null)},_adaptiveColumns:function(){var e=this;e._anyColumnHasMediaQuery()&&(e._setColumnsMediaVisibility(e.columns),e._attachColumnMediaResizeHandler())},_anyColumnHasMediaQuery:function(){return this._columnsWithMediaQuery().length},_columnsWithMediaQuery:function(){return wn(this.columns)},_attachColumnMediaResizeHandler:function(){var t=this;t._detachColumnMediaResizeHandler(),t._columnMediaResizeHandler=t._onColumnMediaResize.bind(t),e(window).on(Pe+B,t._columnMediaResizeHandler)},_detachColumnMediaResizeHandler:function(){this._columnMediaResizeHandler&&e(window).off(Pe+B,this._columnMediaResizeHandler)},_onColumnMediaResize:function(){var e=this;e._setColumnsMediaVisibility(e.columns),e._setContentMediaWidth()},_setColumnsMediaVisibility:function(e){for(var t=e||[],n=0;n<t.length;n++)this._setColumnMediaVisibility(t[n])},_setColumnMediaVisibility:function(e){var t=this;kn(e.media)?t._setColumnsMediaVisibility(e.columns):gn(e)?(t._showColumnByMedia(e),e.hidden||t._setColumnsMediaVisibility(e.columns)):t._hideColumnByMedia(e)},_showColumnByMedia:function(e){e.hidden||this.showColumn(e),mn(e)},_hideColumnByMedia:function(e){var t=e.hidden;t||(e._hideByMedia=!0,this.hideColumn(e),e._hideByMedia=!1,e.hidden=t),mn(e)},_setContentMediaWidth:function(){var t,n=this,i=n.options,r=n._isLocked();if(i.scrollable&&(!0===i.resizable||i.resizable&&!0===i.resizable.columns)){r&&n.lockedFooter?t=n.lockedFooter.children("table"):n.footer&&(t=n.footer.find(">.k-grid-footer-wrap>table")),t&&t[0]||(t=e());var o=r?n.wrapper.find(".k-grid-header-locked").find("table"):n.wrapper.find(".k-grid-header").find("table"),a=r?n.lockedTable:n.table,s=o.find("th"),l=o.find("colgroup"),d=s.length,u=s.filter(vn).length,h=s.length-u,p=0;if(""!==o[0].style.width&&parseFloat(o[0].style.width)!==p){for(var f=o.css(Xe),m=0;m<d;m++)if(_n(s[m])){var g,v=Math.max(m,m-h),_=l.children()[v],b=_?_.style.width:"";""!==b?g=parseFloat(b):(o.css(Xe,Ze),g=c(s.eq(m)),o.css(Xe,f)),p+=g}a.css("width",p-1),o.css("width",p),t.css("width",p),n._updateStickyColumns()}}},_minScreenSupport:function(){this.hideMinScreenCols()&&(this.minScreenResizeHandler=this.hideMinScreenCols.bind(this),e(window).on("resize",this.minScreenResizeHandler))},hideMinScreenCols:function(){var e=this.columns,t=window.innerWidth>0?window.innerWidth:screen.width;return this._iterateMinScreenCols(e,t)},_iterateMinScreenCols:function(e,n){for(var i=!1,r=0;r<e.length;r++){var o=e[r],a=o.minScreenWidth;a!==t&&null!==a&&(i=!0,a>n?this.hideColumn(o):this.showColumn(o)),!o.hidden&&o.columns&&(i=this._iterateMinScreenCols(o.columns,n)||i)}return i},_stickyColumns:function(){this._anyStickyColumns()&&this._setStickyColumns(!1)},_updateStickyColumns:function(){var e=this,t=g(ei(e.columns),(function(e){return e.groupHeaderColumnTemplate}));e._anyStickyColumns()&&(e._setStickyColumns(!0),e._templates(),t.length>0&&e._renderGroupRows(),e._hasFilterRow()&&e._updateStickyFilterCells())},_updateStickyFilterCells:function(){var t=this.thead.find(".k-filter-row").find("td:not(.k-group-cell,.k-hierarchy-cell)");t.length&&t.each((function(){var t=e(this),n=t.data("column");n.sticky?(p(n.stickyStyle)&&t.css({left:n.stickyStyle.left||"",right:n.stickyStyle.right||""}),t.addClass(Me)):(t.css({left:"",right:""}),t.removeClass(Me))}))},_anyStickyColumns:function(){return Gn(this.columns).length},_setStickyColumns:function(e){var t=this,n=Gn(t.columns),i=function(e){return g(e,(function(e){return e.sticky&&!e.locked&&bn(e)}))}(t.columns),r=t._calculateStickyWidths(i);t._removeStickyAttributes(n),t._setStickyClassAttributes(n),t._setStickyStyleAttributes(i,r,e),e&&t._setStickyStyles(i,r)},_calculateStickyWidths:function(e,t,n){var i,r,o,a,s=$t?"right":"left",l=$t?"left":"right",c={left:new Array(e.length).fill(t||0),right:new Array(e.length).fill(n||0)};for(i=0;i<e.length-1;i++)r=e[i],o=this._sumColumnWidth(r)+c[s][i],c[s][i+1]=o;for(i=e.length-1;i>0;i--)r=e[i],a=this._sumColumnWidth(r)+c[l][i],c[l][i-1]=a;return c},_setStickyClassAttributes:function(e,t){var n,i;for(n=0;n<e.length;n++)(i=e[n]).columns&&(!t&&n&&(t=n),this._setStickyClassAttributes(Zn([i]),t)),t&&Un(i,"headerAttributes","class",Ie),Un(i,"attributes","class",Ae),Un(i,"headerAttributes","class",Me),Un(i,"footerAttributes","class",Ee)},_setStickyStyleAttributes:function(e,t,i){var r,o,a,s,l,c,d,u=this;for(r=0;r<e.length;r++)o=e[r],l={left:(a=t.left[r])+"px",right:(s=t.right[r])+"px"},o.columns&&(c=Jn([o]),d=u._calculateStickyWidths(c,a,s),u._setStickyStyleAttributes(c,d,i),i&&u._setStickyStyles(c,d)),Un(o,"attributes",n.attr("style-left"),l.left),Un(o,"attributes",n.attr("style-right"),l.right),Un(o,"headerAttributes",n.attr("style-left"),l.left),Un(o,"headerAttributes",n.attr("style-right"),l.right),Un(o,"footerAttributes",n.attr("style-left"),l.left),Un(o,"footerAttributes",n.attr("style-right"),l.right),o.stickyStyle=l},_removeStickyAttributes:function(e){var t,i,r=new RegExp("(\\s*"+Ae+")*","ig"),o=new RegExp("(\\s*"+Me+")*","ig"),a=new RegExp("(\\s*"+Ee+")*","ig"),s=new RegExp("(\\s*"+Ie+")*","ig");for(t=0;t<e.length;t++)(i=e[t]).columns&&this._removeStickyAttributes(Zn([i])),Wn(i,"attributes","class",r),Wn(i,"attributes",n.attr("style-left"),"",!0),Wn(i,"attributes",n.attr("style-right"),"",!0),Wn(i,"headerAttributes","class",o),Wn(i,"headerAttributes","class",s),Wn(i,"headerAttributes",n.attr("style-left"),"",!0),Wn(i,"headerAttributes",n.attr("style-right"),"",!0),Wn(i,"footerAttributes","class",a),Wn(i,"footerAttributes",n.attr("style-left"),"",!0),Wn(i,"footerAttributes",n.attr("style-right"),"",!0)},_setStickyStyles:function(t,n){var i,r,o,a,s,l,c,d,u,h,p,f=this,m=ei(qn(f.columns)),g=f.tbody.children(":not(.k-detail-row)");for(i=0;i<t.length;i++)if(a=t[i],l=n.left[i],c=n.right[i],s=m.indexOf(a),(d=f._getColumnHeader(a)).addClass(Me),a.headerAttributes.class&&-1!==a.headerAttributes.class.indexOf(Ie)&&d.addClass(Ie),Nn(d,l,c),!a.columns)for(f.footer&&((u=f.footer.find(".k-grid-footer-wrap tr.k-footer-template").children().filter(":not(.k-group-cell,.k-hierarchy-cell)").eq(s)).addClass(Ee),Nn(u,l,c)),r=0;r<g.length;r++)(o=e(g[r])).hasClass(ze)?((h=o.find("."+a.groupHeaderColumnTemplateClass)).addClass(Ae),Nn(h,l,c)):((p=o.children().filter(":not(.k-group-cell,.k-hierarchy-cell)").eq(s)).addClass(Ae),Nn(p,l,c))},_removeStickyStyles:function(t){var n,i,r,o,a,s,l,c,d,u=this,h=ei(qn(u.columns)),p=u.tbody.children(":not(.k-detail-row)");for(n=0;n<t.length;n++)if(o=t[n],a=h.indexOf(o),(s=u._getColumnHeader(o)).removeClass(Me),s.removeClass(Ie),Nn(s,"",""),o.columns)u._removeStickyStyles(o.columns);else for(o.footerTemplate&&u.footer&&((l=u.footer.find(".k-grid-footer-wrap tr.k-footer-template").children().filter(":not(.k-group-cell,.k-hierarchy-cell)").eq(a)).removeClass(Ee),Nn(l,"","")),i=0;i<p.length;i++)(r=e(p[i])).hasClass(ze)?((c=r.find("."+o.groupHeaderColumnTemplateClass)).removeClass(Ae),Nn(c,"","")):((d=r.children().filter(":not(.k-group-cell,.k-hierarchy-cell)").eq(a)).removeClass(Ae),Nn(d,"",""))},_getColumnHeader:function(t){return e("#"+t.headerAttributes.id).length?e("#"+t.headerAttributes.id):e("#"+this._cellId)},_sumColumnWidth:function(e){return e.columns?this._sumCurrentWidths(ei([e])):this._sumCurrentWidths([e])},_sumCurrentWidths:function(e){var t,n,i,r=0,o=0,a=e.length;for(i=0;i<a;i++)t=e[i],n=this._getColumnHeader(t),!t.hidden&&gn(t)&&(r+=(o=n.is(":visible")?n.outerWidth():t.width)?parseInt(o,10):0);return r},_belongsToGrid:function(e){return this.wrapper[0]===e.closest(".k-grid")[0]},getSelectedData:function(){for(var e=this,t=e.selectable.selectedRanges(),n=Object.keys(t),i=e.selectable.selectedSingleItems(),r=[],o=Qn(e.columns),a=0;a<n.length;a++)r=r.concat(e._mapSelectionToData(t[n[a]],o,null,!0));return i.length&&(r=r.concat(e._mapSelectionToData(i,o,null,!0))),r},getSelectedDataByKeys:function(){var t,n,i=this,r=i.dataSource,o=i.selectedKeyNames(),a=Qn(i.columns),s={},l=function(e){var t={};if(e.field)return t[e.field]=n[e.field],t};for(let i=0;i<o.length;i++)t=o[i],(n=r.get(t))&&(s[n.uid]=e.extend.apply({},a.map(l)));return Object.keys(s).map((function(e){return s[e]}))},exportSelectedToExcel:function(e){if(!n.excel||!n.ooxml)throw new Error("The excel export functionality depends on both kendo.excel.js and kendo.ooxml.js scripts, please make sure they are included.");var t,i=this,r=this.options.excel||{},o=Qn(i.columns),a=new n.excel.ExcelExporter({}),s={sheets:[{columns:Array.apply(0,Array(o.length)).map((function(){return{autoWidth:!0}})),rows:[],freezePane:{},filter:!1}]},l=i.selectable.selectedRanges(),c=Object.keys(l),d=i.selectable.selectedSingleItems(),u=[],h=i._isLocked()&&jn(i.columns).length,p=zi.bind(i);for(t=0;t<c.length;t++)u=u.concat(i._mapSelectionToData(l[c[t]],o,Pi));if(u.length&&i._addRangeSelectionRows(s,a,u,e),(u=d.length?i._mapSelectionToData(d,o,Pi):[]).length&&(h&&(u=u.sort(p)),i._addSingleSelectionRows(s,a,u,e)),s.sheets[0].rows.length){var f=new n.ooxml.Workbook(s);f.options||(f.options={}),f.options.skipCustomHeight=!0,f.toDataURLAsync().then((function(e){n.saveAs({dataURI:e,fileName:s.fileName||r.fileName,proxyURL:r.proxyURL,forceProxy:r.forceProxy})}))}},_addSingleSelectionRows:function(e,t,n,i){var r,o=0,a=Xn(this.columns);const s=t._instance??t;for(o=0;o<n.length;o++)r=n[o],t.data=[r],this._setExporterColumns(s,a,r),this._createExportRows(e,s,i)},_addRangeSelectionRows:function(e,t,n,i){var r=Xn(this.columns);const o=t._instance??t;t.data=n,this._setExporterColumns(o,r,n[0]),this._createExportRows(e,o,i)},_createExportRows:function(e,t,n){const i=t._instance??t;e.sheets[0].rows=e.sheets[0].rows.concat(n?i._rows():i._dataRows(i.data,0))},_setExporterColumns:function(t,n,i){const r=t._instance??t;r.columns=r.options.columns=e.map(n.filter((function(e){return Object.keys(i).indexOf(e.field)>=0})),r._prepareColumn)},_mapSelectionToData:function(t,n,i,r){for(var o,a,s,l,c,d=this,u="TR"===t[0][0].nodeName,h={},p=function(e){var t={};if(e.field&&(!i||i(e)))return t[e.field]=o[e.field],t},f=d._isLocked()&&jn(d.columns).length,m=0;m<t.length;m++)if(a=t[m],o=d.dataItem(u?a:a.parent()),u)h[o.uid]=e.extend.apply({},n.map(p));else{if(!(l=d._getCellField(a,f,r)))continue;if((s=h[o.uid])||(s=h[o.uid]={}),!(c=Cn(n,l))||i&&!i(c))continue;s[l]=o[l]}return Object.keys(h).map((function(e){return h[e].uid=e,h[e]}))},_getCellField:function(t,i,r){var o=this,a=i&&e.contains(o.lockedTable[0],t[0]),s=n.attr("field"),l=n.attr("index"),c=0;return r&&(c=o._trailingColumns()),i?o.element.find(".k-grid-header-"+(a?"locked":"wrap")+" th["+l+"='"+t.index()+"']").attr(s):o.thead.find("th["+l+"='"+(t.index()-c)+"']").attr(s)},_relatedRow:function(t){var n=this.lockedTable;if(t=e(t),!n)return t;var i=t.closest(this.table.add(this.lockedTable)),r=i.find(">tbody>tr").index(t);return(i=i[0]===this.table[0]?n:this.table).find(">tbody>tr").eq(r)},_relatedCell:function(t){var n=this.lockedTable;if(t=e(t),!n)return t;var i=t.closest(this.table.add(this.lockedTable)),r=i.find(">tbody>tr>td").index(t);return(i=i[0]===this.table[0]?n:this.table).find(">tbody>tr>td").index(r)},clearSelection:function(){var e=this;e.selectable&&!e._checkBoxSelection&&e.selectable.clear(),e._checkBoxSelection?e._deselectCheckRows(e.select()):e.options.persistSelection?e._persistSelectedRows():e._selectedIds={}},select:function(e){var t=this,i=t.selectable,r=n.ui.Selectable.parseOptions(this.options.selectable).cell;return(e=t.table.add(t.lockedTable).find(e)).length?(i&&!i.options.multiple&&(i.clear(),e=e.first()),t._isLocked()&&(e=e.add(e.map((function(){return r?t._relatedCell(this):t._relatedRow(this)})))),i&&!t._checkBoxSelection?i.value(e):(t._checkRows(e),t.select().length===t.items().length&&t._toggleHeaderCheckState(!0)),void(r||t._persistSelectedRows())):i?i.value():t.items().filter("."+ge)},_initSelectableAggregates:function(){var e=this;e.options.selectable&&(e._selectableAggregatesOptions||(e._selectableAggregatesOptions=e._parseSelectableAggregatesOptions()),e._selectableAggregatesOptions.count&&(e._cellAggregates={count:0}))},_calculateAggregatesForSelected:function(){var t,i,r,o,a,s,l,c,d,u,p,f=this,m=f.options,g=f.getSelectedDataByKeys(),v=f.options.selectable,_=v.cellAggregates,b=Qn(f.columns).filter((e=>!e.selectable&&!e.draggable&!e.command)).length,y=ti(m.columns),w=n.ui.Selectable.parseOptions(v).cell,k=[],x=[],C=[];if(_){w&&(g=f.getSelectedData()),_=f._selectableAggregatesOptions;for(let e=0;e<g.length;e++){t=g[e];for(let e=0;e<y.length;e++)switch(i=t[y[e]],h(i)){case"number":k.push(i);break;case"date":x.push(i);break;case"boolean":C.push(i)}}var S;_.count&&(r=w?(S=f.select(),S.filter(((t,n)=>{const i=e(n),r=i.children(".k-select-checkbox").length>0,o=i.find("> .k-checkbox-wrap > .k-select-checkbox").length>0;return!(i.hasClass("k-drag-cell")||i.hasClass("k-command-cell")||r||o)}))).length:g.length*b),k.length&&(a=_.max?k.reduce(((e,t)=>Math.max(e,t))):null,o=_.min?k.reduce(((e,t)=>Math.min(e,t))):null,s=_.sum?k.reduce(((e,t)=>e+t)):null,l=_.average?k.reduce(((e,t)=>e+t))/k.length:null),x.length&&(c=_.earliest?x.reduce(((e,t)=>new Date(Math.min(e,t)))):null,d=_.latest?x.reduce(((e,t)=>new Date(Math.max(e,t)))):null),C.length&&(u=_.isTrue?C.filter((e=>!0===e)).length:null,p=_.isFalse?C.filter((e=>!1===e)).length:null),f._cellAggregates={count:r,max:a,min:o,sum:s,average:l,earliest:c,latest:d,isTrue:u,isFalse:p},f.statusBar&&f._statusBar()}},_parseSelectableAggregatesOptions:function(){var e=this.options.selectable.cellAggregates,t={};if(v(e)){for(let n=0;n<e.length;n++)t[e[n]]=!0;return t}return{count:!0,min:!0,max:!0,sum:!0,average:!0,earliest:!0,latest:!0,isTrue:!0,isFalse:!0}},_toggleHeaderCheckState:function(e){var t=this;e?t.thead.add(t.lockedHeader).find("tr "+_e).prop("checked",!0).attr(Ct,!0).attr(vt,"Deselect all rows"):t.thead.add(t.lockedHeader).find("tr "+_e).prop("checked",!1).attr(Ct,!1).attr(vt,"Select all rows")},_uncheckCheckBoxes:function(){this.table.add(this.lockedTable).find("tbody "+_e).attr(Ct,!1).prop("checked",!1).attr(vt,"Select row")},_deselectCheckRows:function(t){var i=this,r=n.attr("range-selected");t=i.table.add(i.lockedTable).find(t),i._isLocked()&&(t=t.add(t.map((function(){return i._relatedRow(this)})))),t.each((function(){e(this).removeClass(ge).removeAttr(r).find(_e).attr(Ct,!1).prop("checked",!1).attr(vt,"Select row")})),i._toggleHeaderCheckState(!1),i._persistSelectedRows()},_checkRows:function(t){t.each((function(){e(this).addClass(ge).find(_e).prop("checked",!0).attr(vt,"Deselect row").attr(Ct,!0)}))},_persistSelectedRows:function(){var e,t,i,r=this,o=r.items(),a=r.dataSource.options.schema,s={};if(a&&a.model&&r._data&&(i=r._getSchemaIdField())){n.ui.Selectable.parseOptions(r.options.selectable).multiple||r._checkBoxSelection||(r._selectedIds={}),r.select().each((function(){t=r.dataItem(this),s[t[i]]=!0}));for(var l=0;l<o.length;l++)e=(t=r.dataItem(o[l]))[i],s[e]?r._selectedIds[e]=!0:delete r._selectedIds[e]}},selectedKeyNames:function(){var e=[];for(var t in this._selectedIds)e.push(t);return e.sort(),e},_updateCurrentAttr:function(t,n){var i,r,o=e(t).data("headerId");e(t).removeClass(he),this.table.removeAttr(St),o?(o=o.replace(this._cellId,""),e(t).attr(pt,o)):e(t).removeAttr(pt),(i=n.attr(pt))!=this._cellId&&n.data("headerId",i),i?r=i:n.attr(pt,this._cellId),n.addClass(he),this.table.attr(St,r||this._cellId),this._current=n},_scrollCurrent:function(){const t=this._current,n=this.options.scrollable;if(t&&n){var i=t.parent(),r=i.closest("table").parent(),o=r.is(".k-grid-content-locked,.k-grid-header-locked"),a=r.is(".k-grid-content-locked,.k-grid-content,.k-virtual-scrollable-wrap"),s=e(this.content).find(">.k-virtual-scrollable-wrap").addBack().last()[0];if(a)if(this.virtualScroll){var l=Math.max(_(i[0],this._items(i.parent())),0);this.virtualScroll.rows?(this._rowVirtualIndex=this.virtualScrollable.itemIndex(l),this.virtualScrollable.scrollIntoView(i)):(this._rowVirtualIndex=l,this._scrollTo(this._relatedRow(i)[0],s))}else this._scrollTo(this._relatedRow(i)[0],s);this.lockedContent&&(this.lockedContent[0].scrollTop=s.scrollTop),o||this._scrollTo(t[0],s)}},_findGroupedItem:function(e,t,n){const i=this;let r;for(let o=0;o<e.length;o++){const a=e[o];if(a.field===n?a.value===t&&(r=a.items[0].uid&&a.items[0][n]?a.items[0]:i._findGroupedItem(a.items,t,n)):r=a.items[0].uid&&a.items[0][n]?a.items.find((e=>e[n]===t)):i._findGroupedItem(a.items,t,n),r)return r}},_findClosestGroupingRow:function(t,n,i){const r=this;let o=n||0,a=i||0;if(!(r.options.groupable&&r.dataSource.group().length>0)||!t)return{targetRow:t,rowsToTarget:o,hiddenGroupingRows:a};const s=e(t.previousSibling);if(s&&s.hasClass(ze)){let e={targetRow:s,rowsToTarget:o,hiddenGroupingRows:a};return"none"===s.css("display")&&(e=r._findClosestGroupingRow(s[0],o,a+1)),e}{const e=r._findClosestGroupingRow(s[0],o+1,a);if(e)return{targetRow:e.targetRow,rowsToTarget:e.rowsToTarget,hiddenGroupingRows:a}}},_checkItemAlreadyLoaded:function(e,t){const n=this.dataSource._ranges;let i;for(let r=0;r<n.length;r++){if(i=n[r].data.find((n=>n[t]===e)),i)return{loadedItem:i,page:r}}},scrollToItem:function(t,i){const r=this,o=r.options,a=r.dataSource,s=a.group(),l=a.pageSize(),c=r._getSchemaIdField(),d=o.scrollable,u=r.wrapper.find(".k-grid-content.k-auto-scrollable"),h=n._outerHeight(r.tbody.find(`tr:not(.${ze})`));let p=o.groupable&&r.wrapper.find(`.${ze}:first-child`),f={};r._scrolledItems&&(f=r._scrolledItems);let m=0,g=!1;if(d&&d.virtual&&0===s.length&&(r.virtualScrollable._alwaysScrollTop=!0),!t||!c)return;const v=a.view();let _=v.find((e=>e[c]==t));if(s.length>0&&(_=r._findGroupedItem(v,t,c),m=n._outerHeight(p[0])),!_&&o.scrollable.virtual)return r.virtualScrollable._programmaticallyScrolling&&"resolved"!==r.virtualScrollable._programmaticallyScrolling.state()||(r.virtualScrollable._programmaticallyScrolling=e.Deferred()),void(i&&"function"==typeof i&&i({success:e=>{let n=e;if(n="number"!=typeof n?Number(n):n,isNaN(n))return;const i=a.options.serverPaging;let o=C.floor(n/l);if(i){const e=r._checkItemAlreadyLoaded(t,c);e&&(o=e.page)}const s=u.find(mt),d=s[s.length-1].offsetTop,p=o*(l/s.length*d)+(n-o*l-1)*h;return r._scrollingUp=r.virtualScrollable.verticalScrollbar.scrollTop()>p,r._scrollOffset=p,r.virtualScrollable._scrollTo(p),r.virtualScrollable.verticalScrollbar.trigger(se),r.virtualScrollable._programmaticallyScrolling.done((()=>{r.scrollToItem(t)}))}}));const b=_&&_.uid;if(!b)return;let y=e(`[data-uid=${b}]`),{targetRow:w,rowsToTarget:k,hiddenGroupingRows:x}=r._findClosestGroupingRow(y[0]);if(!y||!w)return;s.length>0&&"none"===y.css("display")&&(y=w,g=!0);const S=g?x*m+h:0;let T=y[0].offsetTop-((k+s.length)*m-S),D=T;if(o.scrollable.virtual){if(f&&f[t]){const e=Math.floor(r.virtualScrollable.verticalScrollbar.scrollTop()),n=Math.floor(f[t].scrollingDownOffset),i=Math.floor(f[t].scrollingUpOffset);if(e===i||e===n)return;r._scrollingUp=e>D,D=r._scrollingUp?i??D:n??D}r._scrollOffset&&(r._scrollingUp?(r._scrollOffset===T&&(r._scrollOffset+=h),D=T-r.virtualScrollable._scrollTop+r._scrollOffset):D+=r._scrollOffset),r.virtualScrollable._scrollTo(T,D),f[t]||(f[t]={}),r._scrollingUp?f[t]&&!f[t].scrollingUpOffset&&(f[t].scrollingUpOffset=D):f[t]&&!f[t].scrollingDownOffset&&(f[t].scrollingDownOffset=D)}else u.scrollTop(D);r.virtualScrollable&&(r._scrollOffset&&delete r._scrollOffset,r._scrollingUp&&delete r._scrollingUp),r._scrolledItems=f},current:function(e){return this._setCurrent(e,!0)},_setCurrent:function(t,n,i){var r=this._current;if(t=e(t),r&&t&&r.length&&t.length&&r.closest(".k-filter-row").length>0&&0===t.closest(".k-filter-row").length&&this._filterFocusable().attr(Je,-1),t.length&&(!r||r[0]!==t[0])){var o=t.parent(),a=o.children(A),s=parseInt(o.children().first().attr("colspan"),10);this._hasVirtualColumns()&&(this._virtualCellIndex=(s>1?s:0)+a.index(t)),this._updateCurrentAttr(r,t),i||this._scrollCurrent(),n||this.trigger($e,{element:t})}return t&&t.length&&(this._lastCellIndex=t.parent().children(".k-group-cell,"+M).index(t)),this._updateSelctCheckbox(r,t),this._current},_removeCurrent:function(){this._current&&(this._current.removeClass(he),this._current=null)},_updateSelctCheckbox:function(e,t){var n;t&&t.length&&((n=t.find(".k-select-checkbox")).length>0?n.trigger("focus"):e&&e.find(".k-select-checkbox").length>0&&wi(this.table,!0))},_scrollTo:function(t,i){var r=t.tagName.toLowerCase(),o="td"===r||"th"===r,a=e(t).closest("table")[0],s=t[o?"offsetWidth":"offsetHeight"],l=i[o?"scrollLeft":"scrollTop"],c=i[o?"clientWidth":"clientHeight"],d="relative"===e(t).css("position")&&$t&&o?Math.abs(a.offsetLeft-t.offsetLeft):t[o?"offsetLeft":"offsetTop"],u=d+s,h=0,p=0,f=0;$t&&o&&(Ut.msie||Ut.edge?p=a.offsetLeft:(Ut.mozilla||Ut.webkit&&Ut.version>85)&&(f=a.offsetLeft-n.support.scrollbar())),h=(l=Math.abs(l+p-f))>d?d:u>l+c?s<=c?u-c:d:l,h=Math.abs(h+p)+f,i[o?"scrollLeft":"scrollTop"]=h},_navigatable:function(){var t=this;if(t.options.navigatable){var i=t.table.add(t.lockedTable),r=t.thead.parent().add(e(">table",t.lockedHeader)),o=i;t.options.scrollable&&(o=o.add(r)),this._navigatableTables=o,this._headertables=r,o.off(We+B+" focus"+B+" focusout"+B+" keydown"+B),r.find("a.k-link").attr("tabIndex",-1),i.on("keydown"+B,".k-detail-cell",(function(e){e.target!==e.currentTarget&&e.stopImmediatePropagation()})),o.on(n.support.touch?"touchstart"+B:We+B,E+">"+I,Si.bind(t)).on("focus"+B,t._tableFocus.bind(t)).on("focusout"+B,t._tableBlur.bind(t)).on("keydown"+B,t,t._tableKeyDown.bind(t)),t._filterFocusable().on("focus",t._filterFocus.bind(t))}},_filterFocus:function(t){var n=t.target.closest("th");this._filterFocusable().attr(Je,0),this._setCurrent(n),e(n).removeClass(he)},_tableFocus:function(){var e=this.current(),t=this.lockedTable?this.lockedTable:this.table;e&&e.is(":visible")?e.addClass(he):this._virtualColScroll?this._setCurrent(t.find(E).first().children(I).first(),!0,!0):this._setCurrent(t.find(E).first().children(I).first()),this.table.attr(Je,0)},_tableBlur:function(){var e=this.current();e&&e.removeClass(he)},_findCellIndex:function(e,t,n){var i,r;if(n)for(r=t;r>=0&&(i=r,e[r].hidden);r--);else for(r=t;r<e.length&&(i=r,e[r].hidden);r++);return i},_scrollToColumn:function(e,i){if(this._virtualCellIndex===t)return!1;var r=this,o=r._virtualCellIndex,a=ei(qn(r.columns)),s=0;e==($t?u.LEFT:u.RIGHT)&&o!==a.length-1?o=r._findCellIndex(a,o+1):e==($t?u.RIGHT:u.LEFT)&&o?o=r._findCellIndex(a,o-1,!0):e==u.HOME?o=r._findCellIndex(a,0):e==u.END&&(o=r._findCellIndex(a,a.length-1,!0));for(var l=0;l<o;l++)s+=a[l].width;return r._virtualCellIndex=o,i&&(i.preventDefault(),i.stopPropagation()),n.scrollLeft(r.content,s),!0},_tableKeyDown:function(t){let n=this.current(),i=n&&n.closest(".k-grid-table")[0],r=this.virtualScroll||{},o=this.virtualScrollable&&this.virtualScrollable.fetching(),a=e(t.target),s=!t.isDefaultPrevented()&&!a.is(":button,a,:input:not(.k-select-checkbox),a>.k-icon,a>.k-svg-icon");if(t.altKey&&t.keyCode==u.DOWN)return this.current().find(".k-grid-filter-menu, .k-grid-column-menu").click(),void t.stopImmediatePropagation();if(o)t.preventDefault();else if((!r.columns||n&&document.body.contains(n[0])||!this._scrollToColumn(t.keyCode,t))&&(n||(n=e(this.lockedTable).add(this.options.scrollable?this.table:this.tbody).find(E).first().children(I).first()),n.length)){var l=!1;t.isDefaultPrevented()||t.keyCode!==u.F10||(l=this._focusToolbar()),s&&t.keyCode==u.UP&&(l=this._moveUp(n,t.shiftKey,t.ctrlKey)),s&&t.keyCode==u.DOWN&&(l=this._moveDown(n,t.shiftKey,t.ctrlKey)),s&&t.keyCode==($t?u.LEFT:u.RIGHT)&&(l=this._moveRight(n,t.altKey,t.shiftKey,t.ctrlKey,i)),s&&t.keyCode==($t?u.RIGHT:u.LEFT)&&(l=this._moveLeft(n,t.altKey,t.shiftKey,t.ctrlKey,i)),s&&t.keyCode==u.PAGEDOWN&&(l=this._handlePageDown()),s&&t.keyCode==u.PAGEUP&&(l=this._handlePageUp()),s&&t.keyCode==u.HOME&&(l=this._handleHome(n,t.ctrlKey)),s&&t.keyCode==u.END&&(l=this._handleEnd(n,t.ctrlKey)),s&&t.keyCode==u.SPACEBAR&&(l=this._handleSpaceKey(n,t.ctrlKey)),t.keyCode!=u.ENTER&&t.keyCode!=u.F2||(l=this._handleEnterKey(n,i,a)),t.keyCode==u.ESC&&(l=this._handleEscKey(n,i)),t.keyCode==u.TAB&&(l=this._handleTabKey(n,i,t.shiftKey,a)),l&&(t.preventDefault(),t.stopPropagation())}},_focusToolbar:function(){var e=this.wrapper.find(".k-grid-toolbar [tabindex=0]");return e.length>0&&(e.first().addClass(".k-focus").trigger("focus"),!0)},_moveLeft:function(t,n,i,r,o){var a,s,l=t.parent(),c=l.parent();return n?l.hasClass(ze)?this.collapseGroup(l):this.collapseRow(l):r&&t.is(S+Se)&&this.options.reorderable?this._moveColumn(t,!0):(s=c.find(E).index(l),(a=this._prevHorizontalCell(c,t,s))[0]||(i?this.lockedTable?(a=this._relatedRow(l),e.contains(this.lockedTable[0],l[0])&&(a=a.prevAll(z).first()),a=a.children(A).last()):a=this._tabNext(t,o,!0):(c=this._horizontalContainer(c),(a=this._prevHorizontalCell(c,t,s))[0]!==t[0]&&wi(this.table,!0))),this._setCurrent(a)),!0},_moveRight:function(t,n,i,r,o){var a,s,l=t.parent(),c=l.parent();return n?l.hasClass(ze)?this.expandGroup(l):this.expandRow(l):r&&t.is(S+Se)&&this.options.reorderable?this._moveColumn(t,!1):(s=c.find(E).index(l),(a=this._nextHorizontalCell(c,t,s))[0]||(i?this.lockedTable?(a=this._relatedRow(l),e.contains(this.table[0],l[0])&&(a=a.nextAll(z).first()),a=a.children(A).first()):a=this._tabNext(t,o,!1):(c=this._horizontalContainer(c,!0),(a=this._nextHorizontalCell(c,t,s))[0]!==t[0]&&wi(this.table,!0))),this._setCurrent(a)),!0},_moveUp:function(e,t,n){var i,r,o,a,s=e.parent().parent();t?(i=(i=e.parent()).prevAll(z).first(),i=e.parent().is(z)?i.children().eq(e.index()):i.children(A).last()):n&&e.parent().is(z)&&this._hasReorderableRows()?(r=e.index(),i=(i=e.parent()).prevAll(z).first(),o=this.tbody.children(z).index(i),a=this.tbody.children(z).index(e.parent()),o>=0&&!this.trigger(Ne,{oldIndex:a,newIndex:o,row:e.parent()})&&(this.reorderRows(e.parent(),o),i=this.tbody.children(z).eq(o).children().eq(r))):(i=this._prevVerticalCell(s,e))[0]||(this._lastCellIndex=0,s=this._verticalContainer(s,!0),(i=this._prevVerticalCell(s,e)).is(":hidden")&&(i=i.nextAll().not(":hidden").first()),i[0]&&wi(this.table,!0));var l=this._lastCellIndex||0;return this._setCurrent(i),this._lastCellIndex=l,!0},_moveDown:function(e,t,n){var i,r,o,a,s=e.parent().parent();t?(i=(i=e.parent()).nextAll(z).first(),i=e.parent().is(z)?i.children().eq(e.index()):i.children(A).first()):n&&e.parent().is(z)&&this._hasReorderableRows()?(r=e.index(),i=(i=e.parent()).nextAll(z).first(),o=this.tbody.children(z).index(i),a=this.tbody.children(z).index(e.parent()),o>=0&&!this.trigger(Ne,{oldIndex:a,newIndex:o,row:e.parent()})&&(this.reorderRows(e.parent(),o+1),i=this.tbody.children(z).eq(o).children().eq(r))):(i=this._nextVerticalCell(s,e))[0]||(this._lastCellIndex=0,s=this._verticalContainer(s),(i=this._nextVerticalCell(s,e))[0]&&wi(this.table,!0));var l=this._lastCellIndex||0;return this._setCurrent(this._findVisibleCell(i)),this._lastCellIndex=l,!0},_moveColumn:function(t,n){var i=this.wrapper.data().kendoReorderable.element.find(this._draggableInstance.options.filter+":visible"),r=yn(Pn(this.columns)),o=i.index(e(t)),a=n?-1:1,s=r[o],l=Hn(r,this.columns,o,o+a);l>=0&&(this.reorderColumn(l,s,n),this.trigger(Re,{newIndex:l,oldIndex:o,column:s}))},_handleHome:function(e,t){var n,i=e.parent(),r=i.parent(),o=this.lockedTable&&this.lockedTable.children("tbody")[0]===r[0],a=r[0]===this.tbody[0];return this._hasVirtualColumns()?(this._scrollToColumn(u.HOME),!0):(t?n=this.lockedTable?this.lockedTable.find(z).first().children(I).first():this.table.find(z).first().children(I).first():(a||o)&&(a&&this.lockedTable&&(i=this._relatedRow(i)),n=i.children(A).first()),n&&n.length?(this._setCurrent(n),!0):void 0)},_handleEnd:function(e,t){var n,i=e.parent(),r=i.parent(),o=this.lockedTable&&this.lockedTable.children("tbody")[0]===r[0],a=r[0]===this.tbody[0];return this._hasVirtualColumns()?(this._scrollToColumn(u.END),!0):(t?n=this.table.find(z).last().children(I).last():(a||o)&&(!a&&this.lockedTable&&(i=this._relatedRow(i)),n=i.children(A).last()),n&&n.length?(this._setCurrent(n),!0):void 0)},_handlePageDown:function(){return!!this.options.pageable&&(this.dataSource.page(this.dataSource.page()+1),!0)},_handlePageUp:function(){return!!this.options.pageable&&(this.dataSource.page(this.dataSource.page()-1),!0)},_handleTabKey:function(t,n,i,r){var o,a;if(!(this.options.editable&&"incell"==this._editMode())||t.is("th")||(this.options.scrollable?this._headertables.filter(n).length:this.thead.filter(r).length)){if(t.parent().hasClass("k-filter-row")){if(a=this._filterFocusable(),!i&&a[a.length-1]===document.activeElement)return a.first().trigger("focus"),!0;if(i&&a[0]===document.activeElement)return a.last().trigger("focus"),!0}return!1}return(o=e(s()).closest(".k-edit-cell"))[0]&&o[0]!==t[0]&&(t=o),(o=this._tabNext(t,n,i))[0]!==t[0]&&(!!o.length&&(this._handleEditing(t,o,o.closest("table")),!0))},_handleEscKey:function(t){var n,i=s(),r="incell"==this._editMode();if(!(n=t)||!n.hasClass("k-edit-cell")&&!n.parent().hasClass("k-grid-edit-row"))return t.has(i).length?(wi(this.table,!0),!0):!!t.parent().hasClass("k-filter-row")&&(this._filterFocusable().attr(Je,-1),wi(this.table,!0),!0);if(r)this.closeCell(!0);else{var o=e(t).parent().index();i&&i.blur(),this.cancelRow(!0),o>=0&&this._setCurrent(this.items().eq(o).children(I).first())}return wi(this.table,!0),!0},_toggleCurrent:function(e,t,n){var i=e.parent();return!e.is(".k-command-cell")&&(!i.is(".k-filter-row")&&((i.is(S+ze)||!(t||!n))&&(i.find(".k-icon,.k-svg-icon").first().click(),!0)))},_handleSpaceKey:function(t,i){var r=this;if(i&&r.groupable&&t.hasClass(Se)){var o=r.groupable.descriptors(),a=t.attr(n.attr("field")),s=r.groupable.aggregates();return r.groupable._canDrag(t)?o.push({field:a,dir:"asc",aggregates:s||[]}):o=e.grep(o,(function(e){return e.field!==a})),r.dataSource.group(o),!0}},_handleEnterKey:function(t,n,i){var r,o=this.options.editable&&!1!==this.options.editable.update,a=i.closest("td"),l=this._hasDetails();if(i.is("table")||e.contains(t[0],i[0])||(t=a),t.is("th"))return r=t.find(".k-link"),!(t.has(e(s())).length>0)&&(r.length?r.click():t.parent().hasClass("k-filter-row")?(this._filterFocusable().attr(Je,0),t.find(":kendoFocusable").first().trigger("focus")):t.find(_e).trigger("focus"),!0);if(this._toggleCurrent(t,o,l))return!0;var c=t.find(":kendoFocusable").first();return c[0]&&!t.hasClass("k-edit-cell")&&t.hasClass("k-focus")?(c.trigger("focus"),!0):!(!o||i.is(":button,.k-button,textarea"))&&(a[0]||(a=t),this._handleEditing(a,!1,n),!0)},_nextHorizontalCell:function(e,t,n){if(!t.nextAll(A).length){var i=e.find(E);if(-1==i.index(t.parent())){if(t.hasClass(Se)){var r=[];return Vn([jn(this.columns)[0]],oi(i.eq(0).children(":visible").first()),r,0,0),r[n]?r[n][0]:t}return t.parent().hasClass("k-filter-row")?i.last().children(A).first():this._findVisibleCell(i.eq(n).children(M).first())}}return this._findVisibleCell(t.nextAll(A+",[hidden]").eq(0))},_prevHorizontalCell:function(e,t,n){var i=t.prevAll(A);if(!i.length){var r=e.find(E);if(-1==r.index(t.parent())){if(t.hasClass(Se)){var o=[],a=jn(this.columns);return Vn([a[a.length-1]],oi(r.eq(0).children().last()),o,0,0),o[n]?o[n][0]:t}return t.parent().hasClass("k-filter-row")?r.last().children(A).last():r.eq(n).children(A).last()}}i=t.prevAll(A+",[hidden]");let s=this._findVisibleCell(i.first());return s.is(".k-group-cell")?s.next(A):s},_currentDataIndex:function(e,n){var i=n.attr("data-index");if(!i)return t;var r=jn(this.columns).length;return r&&!e.closest(gt).hasClass("k-grid-content-locked")[0]?i-r:i},_findVisibleCell:function(e){var t,n=e.index(),i=e.closest("tr").index();if(e.is("[hidden]")){t=e.prevAll(":not([hidden])").first();var r=e.prevUntil(":not([hidden])","[hidden]").length;if(!t.attr("colspan")||t.attr("colspan")>1&&t.attr("colspan")<=r+1){if(0===(t=e.prevAll("[hidden]").last()).length)return e.closest("tr").prevAll().find(`td:nth-of-type(${n+1}):visible`).last();for(;!(t.attr("rowspan")||t.attr("rowspan")>1&&t.attr("rowspan")!=i-t.closest("tr").index()||Math.abs(t.index()-n)==t.attr("colspan"));)if(0===(t=t.closest("tr").prevAll().find("td, th").eq(n).first()).length){t=e;break}}}else t=e;return t},_prevVerticalCell:function(t,n){var i,r=n.parent(),o=t.children(E),a=o.index(r),s=this._currentDataIndex(t,n);if(s||n.hasClass(Se))return(i=ri(n)).eq(i.length-2);if(s=Math.max(r.children(M).index(n),this._lastCellIndex||0),r.hasClass("k-filter-row")){let e=o.last().children(".k-group-cell").length;return ii(t).filter(vn).eq(Math.max(0,s-e))}if(-1==a){if(this._hasVirtualColumns()&&(s=this._virtualCellIndex),!(r=t.find("tr.k-filter-row:visible"))[0]){(this._hasDetails()||n.parent().find(".k-hierarchy-cell").length)&&s&&s--;let e=0;return n.parent().is(".k-table-group-row")&&(e=o.last().children(".k-group-cell").length),ii(t).eq(Math.max(0,s-e))}this._hasDetails()&&s--}else r=0===a?e():o.eq(a-1);if((i=r.children(M)).length>s){let e=i.eq(s);return e.is(".k-group-cell")&&(e=e.nextAll("td").not(".k-group-cell").not(":hidden").first()),this._findVisibleCell(e)}return i.eq(0)},_nextVerticalCell:function(e,n){var i,r,o,a=r=n.parent(),s=e.children(E),l=s.index(a),c=this._currentDataIndex(e,n),d=this.virtualScroll||{};if(-1!=l&&c===t&&n.hasClass(Se))return oi(n).eq(1);c=c?parseInt(c,10):a.children(M).index(n),c=Math.max(c,this._lastCellIndex||0),-1==l?(a=s.eq(0),d.columns&&(o=parseInt(a.children().first().attr("colspan"),10),c=this._virtualCellIndex-(o>1?o:0)),(this._hasDetails()||a.find(".k-hierarchy-cell").length)&&c++,a.hasClass("k-table-group-row")&&(c+=r.children(".k-group-cell").length)):a=s.eq(l+n[0].rowSpan);let u=(i=a.children(".k-group-cell,"+M)).eq(0);return i.length>c&&(u=i.eq(c)),u.is(".k-group-cell")&&(u=u.nextAll("td").not(".k-group-cell").not(":hidden").first()),u},_verticalContainer:function(e,t){var n=e.parent(),i=this._navigatableTables.length,r=Math.floor(i/2),o=_(n[0],this._navigatableTables);return t&&(r*=-1),((o+=r)>=0||o<i)&&(n=this._navigatableTables.eq(o)),n.find(t?">thead":">tbody")},_filterFocusable:function(){return this.wrapper.find(".k-filter-row").find(".k-dropdownlist, .k-input .k-input-inner:visible, input[type='radio']:visible, input[type='checkbox']:visible")},_horizontalContainer:function(e,t){var n=this._navigatableTables.length;if(n<=2)return e;var i=e.parent(),r=_(i[0],this._navigatableTables);return r+=t?1:-1,!t||2!=r&&r!=n?!t&&(1==r||r<0)?e:this._navigatableTables.eq(r).find("thead, tbody"):e},_tabNext:function(e,t,n){var i=!0,r=n?e.prevAll(A).first():e.nextAll(":visible").first();if(!r.length){if(r=e.parent(),this.lockedTable&&(i=n&&t==this.lockedTable[0]||!n&&t==this.table[0],r=this._relatedRow(r)),i){if(this._hasVirtualColumns())return e;r=r[n?"prevAll":"nextAll"]("tr:not(.k-grouping-row):not(.k-detail-row):visible").first()}r=n?r.children(A).last():r.children(A).first()}return r},_handleEditing:function(t,n,i){var r,o,a=this,l=e(s()),c=a._editMode(),d=Ut.msie,u=a._editContainer,h=a.options.editable&&!1!==a.options.editable.update;if(i=e(i),o="incell"==c?t.hasClass("k-edit-cell"):t.parent().hasClass("k-grid-edit-row"),a.editable){if(e.contains(u[0],l[0])&&(l.trigger("blur"),d&&l.trigger("blur")),!a.editable)return void wi(a.table);if(!a.editable.end())return"incell"==c?a._setCurrent(u):a._setCurrent(u.children().filter(A).first()),void((r=u.find(":kendoFocusable").first()[0])&&r.focus());"incell"==c?a.closeCell():(a.saveRow(),o=!0)}n&&a._setCurrent(n),wi(a.table,!0),h&&(!o&&!n||n)&&(c===at?e(a.current()).hasClass("k-hierarchy-cell")||a.editCell(a.current()):a.editRow(a.current().parent()))},_wrapper:function(){var e=this,t=e.table,i=e.options.height,r=e.options.width,o=e.element;o.is(gt)||(o=o.wrap("<div/>").parent()),e.wrapper=o.addClass("k-grid "+n.getValidCssClass("k-grid-","size",e.options.size)),i&&(e.wrapper.css(Qe,i),t.css(Qe,Ze)),r&&e.wrapper.css(Xe,r),e._initMobile()},_initContextMenu:function(){var e=this,t=e.options,n=p(t.contextMenu)&&v(t.contextMenu.groups)?{items:t.contextMenu.groups}:{items:Zt},r=p(t.contextMenu)&&v(t.contextMenu.body)?{items:t.contextMenu.body}:{items:Qt},o=p(t.contextMenu)&&v(t.contextMenu.head)?{items:t.contextMenu.head}:{items:Xt},a=p(t.contextMenu)?t.contextMenu:{};r=f({},{messages:t.messages,target:e.tbody,filter:".k-table-td",action:e._action.bind(e),states:e._buildStates()},a,r),o=f({},{messages:t.messages,target:e.thead,filter:".k-table-th",action:e._action.bind(e),states:e._buildStates()},a,o),e.groupable&&(n=f({},{showOn:"click",target:e.groupable.groupContainer,filter:".k-groupable-context-menu",messages:t.messages,action:e._action.bind(e),states:e._buildStates()},a,n)),e.tbodyContextMenu=new i.grid.ContextMenu("<ul></ul>",r),e.theadContextMenu=new i.grid.ContextMenu("<ul></ul>",o),e.groupsContextMenu=!!e.groupable&&new i.grid.ContextMenu("<ul></ul>",n)},_buildStates:function(){var t=this;return{isEditable:t.options.editable,isSelectable:t.options.selectable,isSortable:t.options.sortable,isRowReorderable:p(t.options.reorderable)?t.options.reorderable.rows:t.options.reorderable,isGroupable:t.options.groupable,allowPaste:t.options.allowPaste,alwaysDisabled:!1,hasSelection:()=>!!this.select()&&this.select().length>0,isSorted:()=>!(this.dataSource.sort()&&this.dataSource.sort().length>0),canMoveGroupPrev:t=>e(t).closest(".k-chip").index()>0,canMoveGroupNext:t=>{var n=e(t).closest(".k-chip-list").children().length-1;return e(t).closest(".k-chip").index()<n}}},_action:function(e){var t=e.command,n=f({grid:this},e.options);return new i.grid.commands[t](n).exec()},_initMobile:function(){var e=this.options,t=this;if(this._isMobile=!0===e.mobile&&n.support.mobileOS||"phone"===e.mobile||"tablet"===e.mobile,this._isMobile){var i=this.wrapper.addClass("k-grid-mobile").wrap("<div data-"+n.ns+'stretch="true" data-'+n.ns+'role="view" data-'+n.ns+'init-widgets="false"></div>').parent();this.pane=this._createPane(i),this.view=this.pane.view(),e.height?this.pane.element.parent().css(Qe,e.height):this.pane.element.parent().css(Qe,this.wrapper[0].style.height),this._editAnimation="slide",t.wrapper.on("transitionend"+B,(function(e){e.stopPropagation()})),t.wrapper.on("contextmenu"+B,"th a",(function(e){return e.preventDefault(),!1})),this.view.bind("showStart",(function(){t._isLocked()&&(t._updateTablesWidth(),t._applyLockedContainersWidth(),t._syncLockedContentHeight(),t._syncLockedHeaderHeight(),t._syncLockedFooterHeight())}))}},_createPane:function(e){return n.Pane.wrap(e,{viewEngine:{viewOptions:{renderOnInit:!0,wrap:!1,wrapInSections:!0,detachOnHide:!1,detachOnDestroy:!1}}})},_initLoader:function(t){var n=this,i={size:"medium",messages:{exporting:"Exporting..."}};i=e.extend({},i,t);const r=e("<div></div>").kendoLoader(i).data("kendoLoader");n.loader=r,n._loaderContainer=Af.bind(n)},_tbody:function(){var t,n=this.table;(t=n.find(">tbody")).length||(t=e("<tbody/>").appendTo(n)),t.addClass("k-table-tbody"),this.tbody=t},_scrollable:function(){var t,i,r,o=this,a=o.options,s=a.scrollable,l=!0!==s&&s.virtual?function(e){var t;if("string"==typeof e)return"true"===(t=e.toLowerCase())?{rows:!0}:{rows:t.indexOf("rows")>-1,columns:t.indexOf("columns")>-1};if(!0===e)return{rows:!0}}(s.virtual):null,c=!n.support.kineticScrollNeeded||l&&l.rows?n.support.scrollbar():0;if(s){(t=o.wrapper.children(".k-grid-header"))[0]||(t=e('<div class="k-grid-header" />').insertBefore(o.table)),t.css($t?"padding-left":"padding-right",s.virtual?c+1:c),(i=e('<table role="none" class="k-grid-header-table k-table"/>')).addClass(n.getValidCssClass("k-table-","size",a.size)),i.width(o.table[0].style.width),i.append(o.thead),t.empty().append(e('<div class="k-grid-header-wrap k-auto-scrollable" />').append(i)),o.content=o.table.parent(),o.virtualScroll=l,o.content.is(".k-virtual-scrollable-wrap, ."+Kt)&&(o.content=o.content.parent()),o.content.is(".k-grid-content, .k-virtual-scrollable-wrap")||(o.content=o.table.wrap('<div class="k-grid-content k-auto-scrollable" />').parent()),o.content.parent().hasClass("k-grid-container")||o.content.wrap("<div class='k-grid-container' />").parent(),l&&l.rows&&!o.virtualScrollable&&o._createVirtualScrollable(),l&&l.columns&&o.table.css({width:Ln(Qn(Kn(o.columns)))}),r=t.children(".k-grid-header-wrap"),o.scrollables=r.add(o.content);var d=o.wrapper.find(".k-grid-footer");if(d.length&&(o.scrollables=o.scrollables.add(d.children(".k-grid-footer-wrap"))),r.off("scroll"+B).on("scroll"+B,(function(e){o._scrollLeft!==this.scrollLeft&&n.scrollLeft(o.scrollables.not(e.currentTarget),this.scrollLeft)})),l&&l.rows)o.content.find(">.k-virtual-scrollable-wrap").off("scroll"+B).on("scroll"+B,(function(){var e=this.scrollLeft!=o._scrollLeft;o._scrollLeft=this.scrollLeft,n.scrollLeft(o.scrollables,this.scrollLeft),o.lockedContent&&(o.lockedContent[0].scrollTop=this.scrollTop),l.columns&&e&&o.refresh()}));else{var u=s.endless,h=o.dataSource.options.pageSize;u&&(o._endlessPageSize=h),o.content.off("scroll"+B).on("scroll"+B,(function(e){var t=this.scrollLeft!=o._scrollLeft;o._scrollLeft=this.scrollLeft,n.scrollLeft(o.scrollables.not(e.currentTarget),o._scrollLeft),o.lockedContent&&e.currentTarget==o.content[0]&&(o.lockedContent[0].scrollTop=this.scrollTop),u&&this.scrollTop+this.clientHeight-this.scrollHeight>=-10&&!o._endlessFetchInProgress&&o._endlessPageSize<o.dataSource.total()&&(o._skipRerenderItemsCount=o._endlessPageSize,o._endlessPageSize=o._endlessPageSize+h,o.dataSource.options.endless=!0,o._endlessFetchInProgress=!0,o.dataSource.pageSize(o._endlessPageSize)),l&&l.columns&&t&&(o._virtualColScroll=!0,o._cacheEditableState(),o.refresh(),o._restoreEditableState(),o._virtualColScroll=!1),o.rowResizer&&o.rowResizer.css("left",e.currentTarget.scrollLeft+"px")}));var p=o.content.data("kendoTouchScroller");p&&p.destroy(),(p=n.touchScroller(o.content))&&p.movable&&(o.touchScroller=p,p.movable.bind("change",(function(e){n.scrollLeft(o.scrollables,-e.sender.x),o.lockedContent&&o.lockedContent.scrollTop(-e.sender.y)})),o.one(ee,(function(e){e.sender.wrapper.addClass("k-grid-backface")})))}}},_createVirtualScrollable:function(){var e=this;e.virtualScrollable&&e.virtualScrollable.destroy(),e.virtualScrollable=new Jt(e.content,{dataSource:e.dataSource,itemHeight:function(){return e._averageRowHeight()},page:function(){e._restoreEditableState()},scroll:function(){e._focusEditable()},loadStart:function(){e._progress(!0)},loadEnd:function(){e._progress(!1)}}),e.virtualScrollable.bind(oe,e._onVirtualPaging.bind(e))},_onVirtualPaging:function(){var e=this;e._cacheEditableState(),e._isVirtualIncellEditable()&&(e._shouldClearEditableState=!1,e.closeCell(),e._shouldClearEditableState=!0)},_isVirtualEditable:function(){return this._isVirtualIncellEditable()||this._isVirtualInlineEditable()||this._isVirtualPopupEditable()},_isVirtualInlineEditable:function(){return this.virtualScrollable&&this._editMode()===st},_isVirtualIncellEditable:function(){return this.virtualScrollable&&this._editMode()===at},_isVirtualPopupEditable:function(){return this.virtualScrollable&&"popup"===this._editMode()},_hasVirtualColumns:function(){return!!(this.virtualScroll||{}).columns},_scrollVirtualWrapper:function(){var e=this,t=e.virtualScrollable;(e._isVirtualInlineEditable()||e._isVirtualIncellEditable())&&(t._isScrolledToBottom()?t._scrollWrapperToBottom():t._isScrolledToTop()&&t._scrollWrapperToTop())},_scrollVirtualWrapperOnColumnResize:function(){var e=this.virtualScrollable;e&&e._scrollWrapperOnColumnResize()},_restoreEditableState:function(){var t,n,i=this,r=i._editableState||{},o=r.model,a=i.dataSource,s=i._isVirtualInlineEditable(),l=i._isVirtualIncellEditable(),c=i._hasVirtualColumns();(s||l||c)&&o&&a._getByUid(o.uid,a.view())&&(i._editMode()===st?(i._shouldClearEditableState=!1,i.editRow(o),c||i._focusEditable()):i._editMode()===at&&(t=i.tbody.children(en("uid",o.uid)),(n=e(t).children(en(rt,r.field)))[0]&&(i._shouldClearEditableState=!1,i.editCell(n),c||i._focusEditable()))),i._shouldClearEditableState=!0},_focusEditable:function(){var e=this,t=(e._editableState||{}).field,n=e._editContainer;n&&n.length&&!x(n[0],s())&&e._canFocusEditable()&&(e._isVirtualInlineEditable()||e._hasVirtualColumns()?n.find(en(it,t)).find(me).eq(0).trigger("focus"):(e._isVirtualIncellEditable()||e._hasVirtualColumns())&&n.find(me).eq(0).trigger("focus"))},_canFocusEditable:function(){var e=this;return(e._isVirtualIncellEditable()||e._isVirtualInlineEditable()||e._hasVirtualColumns())&&(Di((e.virtualScrollable||{}).wrapper,e._editContainer)||Di(e.content,e._editContainer))},_cacheEditableState:function(){var t,i,r,o=this,a=o._editContainer,l=a?o._modelForContainer(a):null,c=o._isVirtualInlineEditable(),d=o._isVirtualIncellEditable(),u=o._hasVirtualColumns();(c||d||u)&&l&&(o._clearEditableState(),t=e(s()),a&&t[0]&&x(a[0],t[0])&&(t.change(),(i=n.widgetInstance(t,n.ui))&&y(i.value)&&t.is(ot)&&(r=t.val(),t.is("[type='checkbox'")&&(r=t.is(":checked")),i.value(r),i.trigger(Q))),o._editMode()===st?o._editableState={model:l,field:t.closest("["+n.attr(it)+"]").attr(n.attr(it))}:o._editMode()===at&&(o._editableState={model:l,field:a.attr(n.attr(rt))}))},_clearSortClasses:function(){var e=this,t=e.content||e.table,n=e.lockedContent;t&&t.find(P).removeClass(Ce),n&&n.find(P).removeClass(Ce)},_clearEditableState:function(){var e=this;(e.virtualScrollable||e.virtualScroll&&e._hasVirtualColumns())&&(e._editableState=null)},_destroyVirtualScrollable:function(){var e=this;e._clearEditableState(),e.virtualScrollable&&e.virtualScrollable.element&&e.virtualScrollable.destroy(),e.virtualScrollable=null},_destroyRowResizing:function(){this.rowResizing&&(this.rowResizing.destroy(),this.rowResizing=null),this.rowResizer&&(this._detachRowResizerEvents(),this.rowResizer.off(Ye+B),this.rowResizer=null,this._clearCachedRowsHeight())},_renderNoRecordsContent:function(){var t=this;if(t.options.noRecords){var i=t.table.parent().children("."+be);i.length&&i.remove(),t.dataSource&&t.dataSource.view().length||(i=e(t.noRecordsTemplate({grid:t})),n.applyStylesFromKendoAttributes(i,["margin","position"]),i.insertAfter(t.table))}},_setContentWidth:function(t){var i,r=this,o="k-grid-content-expander",a='<div class="'+o+'"></div>',s=r.resizable;r.options.scrollable&&r.wrapper.is(":visible")&&(i=r.table.parent().children("."+o),r._setContentWidthHandler=r._setContentWidth.bind(r),r.dataSource&&r.dataSource.view().length?i[0]&&(i.remove(),s&&s.unbind("resize",r._setContentWidthHandler)):(i[0]||(i=e(a).appendTo(r.table.parent()),s&&s.bind("resize",r._setContentWidthHandler)),r.thead&&(i.width(r.thead.width()),isNaN(parseFloat(t,10))||n.scrollLeft(r.content,t))),r._applyLockedContainersWidth(!0),r._syncLockedContentHeight(),r.lockedHeader&&0===r.table[0].clientWidth&&(r.table[0].style.width="1px"))},_applyLockedContainersWidth:function(e){if(this.options.scrollable&&this.lockedHeader){let t,i=this.thead.parent(),r=i.parent(),o=this.wrapper[0].clientWidth,a=this._groups(),s=n.support.scrollbar(),l=this.lockedHeader.find(">table>colgroup>col:not(.k-group-col, .k-hierarchy-col)"),d=i.find(">colgroup>col:not(.k-group-col, .k-hierarchy-col)"),u=Bn(l),h=Bn(d);a>0&&e&&(u+=c(this.lockedHeader.find(".k-group-cell").first())*a),u>=o&&(u=o-3*s),this.lockedHeader.add(this.lockedContent).width(u),r[0].style.width=r.parent().width()-u-2+ft,i.add(this.table).width(h),this.virtualScrollable&&!jt&&(o-=s),this.content[0].style.width=o-u-1+ft,this.lockedFooter&&this.lockedFooter.length&&(this.lockedFooter.width(u),t=this.footer.find(".k-grid-footer-wrap"),t[0].style.width=r[0].clientWidth+ft,t.children().first().width(h))}},_setContentHeight:function(){var e,t,i,r=this,o=r.options,a=r.wrapper.children(".k-grid-header"),s=n.support.scrollbar(),l=(o.scrollable||{}).height;if(o.scrollable&&r.wrapper.is(":visible")){l&&""===r.content[0].style.height&&(r.content[0].style.height=l),e=r.wrapper.innerHeight(),e-=d(a),r.pager&&r.pager.element.is(":visible")&&(e-=d(r.pager.element)),o.groupable&&(e-=d(r.wrapper.children(".k-grouping-header"))),o.toolbar&&(e-=d(r.wrapper.children(".k-grid-toolbar"))),r.footerTemplate&&(e-=d(r.wrapper.children(".k-grid-footer"))),r.statusBar&&(e-=d(r.wrapper.children(".k-selection-aggregates")));((t=r.wrapper)[0].style.height||(i=t.height(),t.height(Ze),i!=t.height()?(t.height(""),1):(t.height(""),0)))&&(e>2*s?(r.lockedContent&&(s=r.table[0].offsetWidth>r.table.parent()[0].clientWidth?s:0,r.lockedContent.height(e-s)),r.content.height(e)):r.content.height(2*s+1))}},_averageRowHeight:function(){var e=this,t=e._items(e.tbody,!0).length,n=e._rowHeight;if(0===t)return n;e._rowHeight||(e._rowHeight=n=d(e.table)/t,e._sum=n,e._measures=1);var i=d(e.table)/t;return n!==i&&(e._measures++,e._sum+=i,e._rowHeight=e._sum/e._measures),n},_dataSource:function(){var e,n=this,i=n.options,o=i.dataSource;o=v(o)?{data:o}:o,p(o)&&(f(o,{table:n.table,fields:n.columns}),e=i.pageable,p(e)&&e.pageSize!==t&&(o.pageSize=e.pageSize)),n.dataSource&&n._refreshHandler?n.dataSource.unbind(Q,n._refreshHandler).unbind(T,n._progressHandler).unbind(ue,n._requestEndHandler).unbind(D,n._errorHandler).unbind(ct,n._sortHandler):(n._refreshHandler=n.refresh.bind(n),n._progressHandler=n._requestStart.bind(n),n._requestEndHandler=n._requestEnd.bind(n),n._errorHandler=n._error.bind(n),n._sortHandler=n._clearSortClasses.bind(n)),n.dataSource=r.create(o).bind(Q,n._refreshHandler).bind(T,n._progressHandler).bind(ue,n._requestEndHandler).bind(D,n._errorHandler).bind(ct,n._sortHandler)},_error:function(){this._progress(!1),this._requestInProgress=!1},_requestStart:function(){this._progress(!0),this._requestInProgress=!0},_requestEnd:function(){this._requestInProgress=!1},_modelChange:function(t){var r,o,a,s,l,c,d,u,h,p=this,f=p.tbody,m=t.model,g=p.tbody.find("tr["+n.attr("uid")+"="+m.uid+"]"),v=g.hasClass("k-alt"),_=p._items(f).index(g),b=p.lockedContent;if(b&&(r=p._relatedRow(g)),g.add(r).children(".k-edit-cell").length&&!p.options.rowTemplate)g.add(r).children(":not(.k-group-cell,.k-hierarchy-cell)").each((function(){o=e(this),(a=ei(p.columns)[p._calculateColumnIndex(o)]).field===t.field&&(o.hasClass("k-edit-cell")?o.addClass("k-dirty-cell"):p._displayCell(o,a,m))}));else if(!g.hasClass("k-grid-edit-row")){c=e().add(g),b&&(s=(v?p.lockedAltRowTemplate:p.lockedRowTemplate)(m),c=c.add(r),r.replaceWith(s)),s=(v?p.altRowTemplate:p.rowTemplate)(m);let t=e(s);for(n.applyStylesFromKendoAttributes(t,["display"]),g.replaceWith(t),s=p._items(f).eq(_),b&&(g=g.add(r),r=p._relatedRow(s)[0],bi(s[0],r),s=s.add(r)),((l=p.options.selectable)||p._checkBoxSelection)&&g.hasClass(ge)&&p.select(s),u=c.children(":not(.k-group-cell,.k-hierarchy-cell)"),d=s.children(":not(.k-group-cell,.k-hierarchy-cell)"),_=0,h=p.columns.length;_<h;_++)a=p.columns[_],o=d.eq(_),l&&u.eq(_).hasClass(ge)&&o.addClass(ge);p.trigger("itemChange",{item:s,data:m,ns:i})}},_pageable:function(){var t,i=this,r=i.options.pageable,o=i.options.size,a=i.options.navigatable;r&&((t=i.wrapper.children("div.k-grid-pager")).length||(t=e('<div class="k-pager k-grid-pager"/>')),"top"===r.position?t.prependTo(i.wrapper).addClass("k-grid-pager-top"):t.appendTo(i.wrapper),i.pager&&i.pager.destroy(),"object"==typeof r&&r instanceof n.ui.Pager?i.pager=r:i.dataSource._groupPaging?i.pager=new Wt(t,f({},r,{dataSource:i.dataSource,navigatable:a,size:o})):i.pager=new n.ui.Pager(t,f({},r,{dataSource:i.dataSource,navigatable:a,size:o})),i.pager.bind("pageChange",(function(e){i.trigger("page",{page:e.index})&&e.preventDefault()})),i._togglePagerVisibility())},_statusBar:function(){var t=this,n=t.options,i=t.wrapper,r=n.statusBarTemplate,o="";r&&(t.statusBar?t.statusBar.html(r({aggregates:t._cellAggregates})):(o+='<div class="k-selection-aggregates k-grid-selection-aggregates">',o+=r({aggregates:t._cellAggregates}),o+="</div>",n.scrollable?t.statusBar=e(o).insertAfter(i.find(".k-grid-container")):t.statusBar=e(o).insertAfter(i.find(".k-grid-table"))))},_footer:function(){var t,i=this,r=i.dataSource.aggregates(),o="",a=i.footerTemplate,s=i.options,l=i.footer||i.wrapper.find(".k-grid-footer");if(a)if(o=e(i._wrapFooter(a(r))),n.applyStylesFromKendoAttributes(o,["display","left","right"]),l.length){var c=o;l.replaceWith(c),l=i.footer=c}else s.scrollable?(i.statusBar?i.footer=o.insertBefore(i.statusBar):s.pageable&&"top"!==s.pageable.position?i.footer=o.insertBefore(i.wrapper.children("div.k-grid-pager")):i.footer=o.appendTo(i.wrapper),l=i.footer):l=i.footer=o.insertAfter(i.tbody);else l&&!i.footer&&(i.footer=l);if(l.length&&(s.scrollable&&(t=l.attr(Je,-1).children(".k-grid-footer-wrap"),i.scrollables=e(i.scrollables.filter((function(){return!e(this).is(".k-grid-footer-wrap")})).toArray()).add(t)),i._footerWidth&&l.find("table").css("width",i._footerWidth),t)){var d=n.scrollLeft(i.content);!0!==s.scrollable&&i.virtualScroll&&i.virtualScroll.rows&&(d=n.scrollLeft(i.wrapper.find(".k-virtual-scrollable-wrap"))),n.scrollLeft(t,d)}i.lockedContent&&(i._appendLockedColumnFooter(),i._applyLockedContainersWidth(),i._syncLockedFooterHeight())},_wrapFooter:function(t){var i,r=this,o="",a=n.support.mobileOS?0:n.support.scrollbar();return r.options.scrollable?((i=(o=e('<div class="k-grid-footer"><div class="k-grid-footer-wrap"><table class="k-table k-grid-footer-table"><tfoot class="k-table-tfoot">'+t+"</tfoot></table></div></div>")).find("table")).addClass(n.getValidCssClass("k-table-","size",r.options.size)),r._appendCols(i),o.css($t?"padding-left":"padding-right",a),o):'<tfoot class="k-grid-footer k-table-tfoot">'+t+"</tfoot>"},_globalColumnsMenu:function(e){var t,n,i=this,r=ei(i.columns),o=i.options.columnMenu;if(o){"boolean"==typeof o&&(o={}),i._setColumnsMediaVisibility(r);let a=!(!o.autoSize&&!o.clearAllFilters);(t=e.data("kendoColumnMenu"))&&t.destroy();let s={toggleable:a,expanded:o.expanded||!0,animation:!1,hideExpanderIndicator:!a};n={dataSource:i.dataSource,columns:o.columns,sortable:!1,filterable:!1,clearAllFilters:o.clearAllFilters,messages:o.messages,hideAutoSizeColumn:!0,owner:i,closeCallback:function(){e.trigger("focus")},init:function(e){i.trigger(j,{field:e.field,container:e.container})},open:function(e){i.trigger(G,{field:e.field,container:e.container})},pane:i.pane,autoSize:o.autoSize,encodeTitles:i.options.encodeTitles,componentType:"modern",columnsExpanderOptions:s},e.kendoColumnMenu(n)}},_columnMenu:function(){var e,i,r,o,a,s,l=this,c=ei(l.columns),d=l.options,u=d.columnMenu,h=g(l.columns,(function(e){return e.columns!==t})).length>0,p=g(l.columns,(function(e){return!1!==e.lockable})).length>0,m=g(l.columns,(function(e){return!0===e.stickable})).length>0,v=this._isMobile,_=function(e){l.trigger(j,{field:e.field,container:e.container})},b=function(e){l.trigger(G,{field:e.field,container:e.container})},y=function(){wi(l.table,!0)},w=function(e){l.trigger(Oe,{column:e.column})},k=function(e){l.trigger(Ve,{column:e.column})},x=function(e){l.trigger("sort",{sort:e.sort})?e.preventDefault():(l._clearEditableState(),l.dataSource.options.endless&&l._resetEndless())},C=function(e){l.trigger("filter",{filter:e.filter,field:e.field})?e.preventDefault():(l._clearEditableState(),l.dataSource.options.endless&&l._resetEndless())};if(u){"boolean"==typeof u&&(u={}),l._setColumnsMediaVisibility(c);for(var T=0,D=(s=ii(l.thead)).length;T<D;T++){i=c[T];var A=s.eq(T);!1===i.columnMenu||i.command||!i.field&&!A.attr("data-"+n.ns+"field")||((e=A.data("kendoColumnMenu"))&&e.destroy(),o=!1!==i.sortable&&!1!==u.sortable&&!1!==d.sortable&&f({},d.sortable,{compare:(i.sortable||{}).compare}),a=!(!d.filterable||!1===i.filterable||!1===u.filterable)&&f(!0,{pane:l.pane},d.filterable,i.filterable),i.filterable&&i.filterable.dataSource&&(a.forceUnique=!1,a.checkSource=i.filterable.dataSource),a&&(a.format=i.format),r={dataSource:l.dataSource,values:i.values,columns:u.columns,sortable:o,filterable:a,messages:u.messages,owner:l,closeCallback:y,init:_,open:b,stick:w,unstick:k,pane:l.pane,sort:x,filtering:C,filter:v?":not(.k-column-active)":"",autoSize:u.autoSize,hasLockableColumns:jn(c).length>0&&p&&!h,hasStickableColumns:m&&!h,encodeTitles:l.options.encodeTitles,componentType:u.componentType,appendTo:S+Yt,reorderable:!0===d.reorderable||d.reorderable&&d.reorderable.columns,groupable:l.options.groupable&&!1!==l.options.groupable.enabled&&!1!==i.groupable},A.kendoColumnMenu(r))}}},_headerCells:function(){return e(this.thead).find("th").filter((function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")}))},_hasFilterMenu:function(){var e=this.options.filterable;return(!e||typeof e.mode!=tt||-1!=e.mode.indexOf("menu"))&&e},_filterable:function(){var e,t,i,r=this,o=ei(r.columns),a=function(e){r.trigger(W,{field:e.field,container:e.container})},s=function(){wi(r.table,!0)},l=function(e){r.trigger("filter",{filter:e.filter,field:e.field})?e.preventDefault():(r._clearEditableState(),r.dataSource.options.endless&&r._resetEndless())},c=function(e){r.trigger(q,{field:e.field,container:e.container})},d=r._hasFilterMenu();if(d&&!r.options.columnMenu)for(var u=0,h=(t=ii(r.thead)).length;u<h;u++)if(i=t.eq(u),!1!==o[u].filterable&&!o[u].command&&(o[u].field||i.attr("data-"+n.ns+"field"))){(e=i.data("kendoFilterMenu"))&&e.destroy(),(e=i.data("kendoFilterMultiCheck"))&&e.destroy();var p=o[u].filterable,m=f({},d,p,{dataSource:r.dataSource,values:o[u].values,format:o[u].format,closeCallback:s,title:o[u].title||o[u].field,init:a,open:c,pane:r.pane,change:l,appendTo:S+Yt});p&&p.messages&&(m.messages=f(!0,{},d.messages,p.messages)),p&&p.dataSource&&(m.forceUnique=!1,m.checkSource=p.dataSource),p&&p.multi?i.kendoFilterMultiCheck(m):i.kendoFilterMenu(m)}},_filterRow:function(){var t=this;if(t._hasFilterRow()){var i,o=ei(t.columns),a=t.options.filterable,s=t.thead.find(".k-filter-row"),l=function(e){t.trigger("filter",{filter:e.filter,field:e.field})?e.preventDefault():(t._clearEditableState(),t.dataSource.options.endless&&t._resetEndless())};this._updateHeader(t._groups());for(var c=0;c<o.length;c++){var d,u=o[c],h=t.options.filterable.operators,p=!1,m=e("<td class='k-table-td' title='"+t.options.messages.filterCellTitle+"'/>"),g=u.field;if(u.hidden&&m.hide(),s.append(m),g&&!1!==u.filterable){var v=u.filterable&&u.filterable.cell||{};(d=t.options.dataSource)instanceof r&&(d=t.options.dataSource.options);var _=f(!0,{},a.messages);if(u.filterable&&f(!0,_,u.filterable.messages),!1===v.enabled){m.html("&nbsp;");continue}v.dataSource&&(d=v.dataSource,p=!0),u.filterable&&u.filterable.operators&&(h=u.filterable.operators),i={column:u,dataSource:t.dataSource,suggestDataSource:d,customDataSource:p,field:g,messages:_,size:t.options.size,values:u.values,template:v.template,delay:v.delay,inputWidth:v.inputWidth,suggestionOperator:v.suggestionOperator,minLength:v.minLength,dataTextField:v.dataTextField,operator:v.operator,operators:h,showOperators:v.showOperators,change:l},e("<span/>").attr(n.attr("field"),g).appendTo(m).kendoFilterCell(i)}else m.html("&nbsp;");m.data("column",u)}this._filterFocusable().attr(Je,-1)}},_sortable:function(){var e,t,i,r=this,o=ei(r.columns),a=r.options.sortable,s=function(e){r.trigger("sort",{sort:e.sort})?e.preventDefault():r._clearEditableState()};if(a){for(var l=ii(r.thead),c=0,d=l.length;c<d;c++)!1!==(e=o[c]).sortable&&!e.command&&e.field&&((t=(i=l.eq(c)).data("kendoColumnSorter"))&&t.destroy(),i.attr("data-"+n.ns+"field",e.field).kendoColumnSorter(f({},a,e.sortable,{dataSource:r.dataSource,aria:!0,filter:":not(.k-column-active)",change:s})));l=null}},_columns:function(t){var i,r,o,a=this,s=a.table,l=s.find("col"),c=a.element.find("thead tr"),d=a.options.dataSource;if(t=t.length?t:m(s.find("th:not(.k-group-cell):not(.k-hierarchy-cell)"),(function(t,i){var r=(t=e(t)).attr(n.attr("sortable")),o=t.attr(n.attr("filterable")),a=t.attr(n.attr("type")),s=t.attr(n.attr("groupable")),c=t.attr(n.attr("field")),d=t.attr(n.attr("title")),u=t.attr(n.attr("column-menu")),h=t.attr(n.attr("menu"));return c||(c=t.text().replace(/\s|[^A-z0-9]/g,"")),{field:c,type:a,title:d,sortable:"false"!==r,filterable:"false"!==o,groupable:"false"!==s,menu:"false"!==h,columnMenu:"false"!==u,template:t.attr(n.attr("template")),width:l.eq(i).css(Xe)}})),i=!(a.table.find("tbody tr").length>0&&(!d||!d.transport)),a.options.scrollable){var u=t;if(r=jn(t),t=qn(t),r.length>0&&0===t.length)throw new Error("There should be at least one non locked column");!function(e,t){var n,i,r=0,o=e.find("th:not(.k-group-cell)");for(n=0,i=t.length;n<i;n++)t[n].locked&&(o.eq(n).insertBefore(o.eq(r)),o=e.find("th:not(.k-group-cell)"),r++)}(a.element.find("tr:has(th)").first(),u),t=r.concat(t)}if(c.length&&t.length&&a._updateColumnIDs(t,c.first()),a.columns=cn(t,i),e.grep(ei(a.columns),(function(e){return e.selectable})).length&&(a._selectedIds={},a._checkBoxSelection=!0,a.wrapper.on(Ue+B,"tbody > tr "+_e,a._checkboxClick.bind(a)),a.wrapper.on(Ue+B,"thead > tr "+_e,a._headerCheckboxClick.bind(a))),(o=e.grep(ei(a.columns),(function(e){return e.draggable}))).length){a._hasDragHandleColumn=!0;for(var h=0;h<o.length;h++)o[h].headerAttributes=e.extend({"aria-label":a.options.messages.dragHandleLabel},o[h].headerAttributes)}a._foreignKeyBindings(a.columns)},_foreignKeyBindings:function(e){for(var t,n=e.length,i=0;i<n;i++)(t=e[i]).dataSource&&this._fetchForeignKeyValues(t)},_fetchForeignKeyValues:function(t){var n=this,i=e.Deferred();n._hasBoundForeignKey=!0,t.dataSource=r.create(t.dataSource),n._foreignKeyPromises||(n._foreignKeyPromises=[]),n._foreignKeyPromises.push(i),t.dataSource.fetch().then((function(){var e=t.dataSource.data();t.values=e.map((function(e){return{value:e[t.dataValueField],text:e[t.dataTextField]}})),i.resolve()}))},_updateColumnIDs:function(e,t){if(e.length){for(var n,i=t.find("th:not(.k-group-cell):not(.k-hierarchy-cell)"),r=0;r<e.length;r++)(n=i.eq(r).attr(pt))&&(e[r].headerAttributes=f(e[r].headerAttributes,{id:n}));this._updateColumnIDs(Zn(e),t.next())}},_headerCheckboxClick:function(t){var n=this,i=e(t.target),r=i.prop("checked");n._belongsToGrid(i)&&(n.trigger(Y,{target:i,originalEvent:t})?t.preventDefault():(r?n.select(n.items()):n.clearSelection(),n._calculateAggregatesForSelected(),n.trigger(Q,{cellAggregates:n._cellAggregates})))},_checkboxClick:function(t){var n=this,i=e(t.target).closest(mt),r=!i.hasClass(ge);n._belongsToGrid(i)&&(n.trigger(Y,{target:i,originalEvent:t})?t.preventDefault():(r?n.select(i):n._deselectCheckRows(i),n._calculateAggregatesForSelected(),n.trigger(Q,{cellAggregates:n._cellAggregates})))},_groups:function(){var e=this.dataSource.group();return e?e.length:0},_tmpl:function(t,i,r,o){var a,s,l,c,d,u,h=this,p=f({},n.Template,h.options.templateSettings),m=(p.paramName,i.length),g={storage:{},count:0},v=h._hasDetails(),_=h._groups(),b=n.attr("field");let y;return t||(y=t=>{var p=m?` ${n.attr("uid")}="${n.getter("uid")(t)}"`:"",y=`<tr class="${r?"k-alt k-table-row k-table-alt-row ":"k-table-row "}k-master-row"${p}>`;for(_>0&&!o&&(y+=tn(_)),v&&(y+='<td class="k-hierarchy-cell k-table-td" aria-expanded="false">'+n.ui.icon(e(`<a href="#" ${vt}="${ht}" tabindex="-1"></a>`),{icon:"caret-alt-"+($t?"left":"right")})+"</td>"),a=0;a<m;a++){let e;l=i[a],s=l.template,c=l.field,u={},h._editMode()&&c&&(l.attributes=l.attributes||{},h.virtualScroll&&(l.attributes[b]=c),e=h._dirtyCellTemplate(c)(t)),l.colSpan&&l.colSpan>0&&(l.attributes||{})[n.attr("style-display")]?l.attributes=li(l.attributes):!l.colSpan&&l.hidden&&(l.attributes=si(l.attributes)),l.command&&(l.attributes=l.attributes||{},void 0!==(d=l.attributes.class)?d.indexOf("k-command-cell")<0&&(l.attributes.class+=" k-command-cell"):l.attributes.class="k-command-cell"),l.draggable&&(l.attributes=l.attributes||{},void 0!==l.attributes.class?l.attributes.class.indexOf("k-drag-cell k-touch-action-none")<0&&(l.attributes.class+=" k-drag-cell k-touch-action-none"):l.attributes.class="k-drag-cell k-touch-action-none",void 0===l.attributes[vt]&&(l.attributes[vt]=h.options.messages.dragHandleLabel),void 0!==l.attributes.style?l.attributes.style.indexOf("cursor: move;")<0&&(l.attributes.style+=" cursor: move;"):l.attributes.style="cursor: move;"),l._attributesFunction&&(u=l._attributesFunction(t));let r=f({},l.attributes,u);e&&(r.class=r.class||"",r.class+=e);let o=nn(r),p="";l.colSpan&&(l.colSpan>1&&(p+=" "+n.attr("virtual")),p+=` colSpan="${l.colSpan}"`),y+=En(`<td${o}${p}>`),y+=l.selectable?n.template(Bt)({size:n.getValidCssClass("k-checkbox-","size",h.options.size)}):h._cellTmpl(l,g)(t),y+="</td>"}return y+="</tr>"}),t=n.template(t||y,p),g.count>0?t.bind(g.storage):t},_dirtyCellTemplate:function(e){return t=>{if(e&&t&&t.dirty&&t.dirtyFields){return("["===e.charAt(0)?n.getter(e)(t.dirtyFields):t.dirtyFields[e])?" k-dirty-cell":""}return""}},_headerCellText:function(e){var t=f({},n.Template,this.options.templateSettings),i=e.headerTemplate,r=typeof i,o=e.title&&(this.options.encodeTitles?Ii(e.title):e.title)||Ii(e.field||"");return r===et?o=n.template(i,t)({}):r===tt&&(o=i),o},_cellTmpl:function(e,t){var i,r,o=this,a=f({},n.Template,o.options.templateSettings),s=e.template,l=e.field,c=e.format,d=typeof s,u=e.values;return e.command?v(e.command)?t=>{let n="";for(i=0,r=e.command.length;i<r;i++)e.command[i].visible?n+=e.command[i].visible(t)?o._createButton(e.command[i]):"":n+=o._createButton(e.command[i]);return n}:()=>o._createButton(e.command):e.selectable?Bt:e.draggable?Vt:i=>{let r=o._dirtyIndicatorTemplate(l)(i);if(d===et)t.storage["tmpl"+t.count]=s,r+=s(i),t.count++;else if(d===tt)r+=n.template(s,a)(i);else if(u&&u.length&&p(u[0])&&"value"in u[0]&&l){var h=di(u)[a.useWithBlock?n.getter(l)(i):l];r+=w(null!=h?h:"")}else{let t="";l&&(t=null==(l=n.getter(l)(i))?"":l),c&&(t=n.format(c.replace(zt,"$1"),t)),r+=e.encoded?w(t):t}return r}},_dirtyIndicatorTemplate:function(e){return t=>{if(e&&t&&t.dirty&&t.dirtyFields){return("["===e.charAt(0)?n.getter(e)(t.dirtyFields):t.dirtyFields[e])?'<span class="k-dirty"></span>':""}return""}},_virtualCols:function(t){var i,r=this,o=e.map(t,(function(e){return e.hidden?0:parseInt(e.width,10)})),a=r.virtualScrollable?n.scrollLeft(r.content.find(">.k-virtual-scrollable-wrap")):n.scrollLeft(r.content),s=c(r.content),l=Ln(t),d=[],u=0,h=0,p=0,f=0,m=0;for(f=0;f<t.length;f++){if(i=f<o.length-1?o[f+1]:0,!(m+o[f]+2*i<a)){u=1+p;break}o[f]&&p++,m+=o[f]}p=0,m=0;for(var g=t.length-1;g>=0;g--){if(!(m+3*o[g]<l-s-a)){h=1+p;for(var v=f;v<=g;v++)t[v].locked||(d.push(t[v]),t[v].colSpan&&delete t[v].colSpan);d[0].colSpan=u,d[d.length-1].colSpan=h;break}o[g]&&p++,m+=o[g]}return d[0].hidden&&d[0].colSpan--,r.virtualCols=d,d},_templates:function(){var t=this,n=t.options,i=t.dataSource,r=i.group(),o=t.footer||t.wrapper.find(".k-grid-footer"),a=i.aggregate(),s=ei(t.columns),l=ei(jn(t.columns)),c=n.scrollable?ei(qn(t.columns)):s,d=(t.virtualScroll||{}).columns?t._virtualCols(c):c,u=g(yn(l),(function(e,t){return e.groupHeaderColumnTemplate&&0!==t})),h=g(yn(d),(function(e){return e.groupHeaderColumnTemplate}));if(n.scrollable&&l.length){if(n.rowTemplate||n.altRowTemplate)throw new Error("Having both row template and locked columns is not supported");t.rowTemplate=t._tmpl(n.rowTemplate,d,!1,!0),t.altRowTemplate=t._tmpl(n.altRowTemplate||n.rowTemplate,d,!0,!0),t.lockedRowTemplate=t._tmpl(n.rowTemplate,l),t.lockedAltRowTemplate=t._tmpl(n.altRowTemplate||n.rowTemplate,l,!0)}else t.rowTemplate=t._tmpl(n.rowTemplate,d),t.altRowTemplate=t._tmpl(n.altRowTemplate||n.rowTemplate,d,!0);t._hasDetails()&&(t.detailTemplate=t._detailTmpl(n.detailTemplate||(()=>""))),(t._group&&!k(a)||!k(a)&&!o.length||g(s,(function(e){return e.footerTemplate})).length)&&(t.footerTemplate=t._footerTmpl(s,a,"footerTemplate","k-footer-template k-table-row")),r&&g(s,(function(e){return e.groupFooterTemplate})).length&&(a=e.map(r,(function(e){return e.aggregates})),t.groupFooterTemplate=t._footerTmpl(d,a,"groupFooterTemplate","k-group-footer k-table-row",l.length),n.scrollable&&l.length&&(t.lockedGroupFooterTemplate=t._footerTmpl(l,a,"groupFooterTemplate","k-group-footer k-table-row"))),r&&(u.length||h.length)?(a=e.map(r,(function(e){return e.aggregates})),t.groupHeaderColumnTemplate=t._groupHeaderTmpl(yn(d),a,"groupHeaderColumnTemplate","k-table-group-row k-grouping-row k-table-row",l.length,h),n.scrollable&&l.length&&(t.lockedGroupHeaderColumnTemplate=t._groupHeaderTmpl(yn(l),a,"groupHeaderColumnTemplate","k-table-group-row k-grouping-row k-table-row",0,u))):(t.groupHeaderColumnTemplate=null,t.lockedGroupHeaderColumnTemplate=null),t.options.noRecords&&(t.noRecordsTemplate=t._noRecordsTmpl())},_noRecordsTmpl:function(){var t,i,r,o='<div class="{0}">{1}</div>',a=this.options.scrollable&&!this.wrapper[0].style.height?` ${n.attr("style-margin")}="0 auto" ${n.attr("style-position")}="static"`:"",s={storage:{},count:0},l=e.extend({},n.Template,this.options.templateSettings);l.paramName;let c;if("function"===(i=typeof(t=this.options.noRecords.template?this.options.noRecords.template:n.format('<div class="k-grid-norecords-template"{1}>{0}</div>',this.options.messages.noRecords,a)))){let e=s.storage["tmpl"+s.count]=t;s.count++,c=t=>n.format(o,be,e(t))}else"string"===i&&(c=this.options.noRecords.template?n.format(o,be,t):()=>n.format(o,be,t));return r=n.template(c,l),s.count>0&&(r=r.bind(s.storage)),r},_footerTmpl:function(e,t,i,r,o){var a,s,l,c,d,u=this,h=f({},n.Template,u.options.templateSettings),p=h.paramName,m={},g=0,v={},_=u._groups(),b=u.dataSource._emptyAggregates(t);let y=n.template((t=>{let y='<tr class="'+r+'">';for(_>0&&!o&&(y+=tn(_)),u._hasDetails()&&(y+='<td class="k-hierarchy-cell k-table-td">&nbsp;</td>'),a=0,s=e.length;a<s;a++)d=e[a],l=d[i],c=typeof l,y+=En("<td"+nn(d.footerAttributes)+">"),l?(c!==et&&(v=b[d.field]?f({},h,{paramName:p+"['"+d.field+"']"}):{},l=n.template(l,v)),m["tmpl"+g]=l,y+=l(t),g++):y+="&nbsp;",y+="</td>";return y+="</tr>",y}),h);return g>0?y.bind(m):y},_groupHeaderTmpl:function(e,t,i,r,o,a){var s,l,c,d,u,h,m=this,g=f({},n.Template,m.options.templateSettings),v=g.paramName,b="",y={},w=0,k={},x=m.dataSource._emptyAggregates(t),C=a.length?_(a[0],e):-1;if(!(C<0)){return b=n.template((t=>{var _='<tr data-group-uid="'+t.uid+'" class="'+r+'">';if(!o)for(var b=0;b<t.groupCells;b++)_+='<td class="k-table-td k-group-cell">&nbsp;</td>';if(m._hasDetails()&&(_+='<td class="k-table-td k-hierarchy-cell">&nbsp;</td>'),C<1&&a.length<=1&&!o)return _+=o?"":Ai(e.length)(t);for(C<1?(C=o?0:1,_+=o?"":Ai(C)(t)):_+=o?function(e){return'<td class="k-table-td" colspan="'+e+'">'+`<p class="k-reset">&nbsp;</p></td>${new Array(e).join("<td hidden group-header-spanned-hidden></td>")}`}(C):Ai(C)(t),s=C,l=e.length;s<l;s++){if(u=e[s],c=u[i],d=typeof c,u.sticky){let e="";if((h=u.groupHeaderColumnTemplateClass||"")||(h=u.groupHeaderColumnTemplateClass="group-header-column-template-"+n.guid()),p(u.stickyStyle)){e=`${u.stickyStyle.left?`${n.attr("style-left")}="${u.stickyStyle.left}"`:""} ${u.stickyStyle.right?`${n.attr("style-right")}="${u.stickyStyle.right}"`:""}`}_+=`<td class="k-table-td ${Ae} ${h}" ${e}>`}else _+="<td class='k-table-td'>";c?(d!==et&&(k=x[u.field]?f({},g,{paramName:v+"['"+u.field+"']"}):{},c=n.template(c,k)),y["tmpl"+w]=c,_+=y["tmpl"+w](t),w++):_+="&nbsp;",_+="</td>"}return _+="</tr>"}),g),w>0?b.bind(y):b}},_detailTmpl:function(e){var t=this,i=f({},n.Template,t.options.templateSettings),r=(i.paramName,{}),o=0,a=t._groups(),s=yn(ei(t.columns)).length,l=typeof e;let c=n.template((t=>{let c='<tr role="row" class="k-detail-row k-table-row">';return a>0&&(c+=tn(a)),c+=`<td role="gridcell" class="k-hierarchy-cell k-table-td"></td><td role="gridcell" class="k-table-td k-detail-cell"${s?` colspan="${s}"`:""}>`,l===et?(r["tmpl"+o]=e,c+=e(t),o++):c+=n.template(e,i)(t),c+="</td></tr>",c}),i);return o>0?c.bind(r):c},_hasDetails:function(){return null!==this.options.detailTemplate||(this._events[U]||[]).length},_hasFilterRow:function(){var t=this.options.filterable,n=t&&typeof t.mode==tt&&-1!=t.mode.indexOf(At),i=this.columns,r=e.grep(i,(function(e){return!1===e.filterable}));return i.length&&r.length==i.length&&(n=!1),n},_details:function(){var t=this;if(t.options.scrollable&&t._hasDetails()&&jn(t.columns).length)throw new Error("Having both detail template and locked columns is not supported");t.table.on(Ue+B,".k-hierarchy-cell "+R+", .k-hierarchy-cell "+F,(function(n){var i=e(this);return t._toggleDetails(i),n.preventDefault(),!1}))},_toggleDetails:function(t,i){var r,o,a,s=this,l=t.closest("td.k-hierarchy-cell"),c=t.is(R),d=t.closest("tr.k-master-row"),u=d.attr(kt),h=s.detailTemplate,p=s._hasDetails(),f=c?ut:ht,m=!!c;c?n.ui.icon(t,{icon:"caret-alt-down"}):n.ui.icon(t,{icon:"caret-alt-"+($t?"left":"right")}),t.attr(vt,f),l.attr(xt,m),(r=d.next()).hasClass("k-hidden")&&r.removeClass("k-hidden"),p&&!r.hasClass("k-detail-row")&&(o=s.dataItem(d),r=e(h(o)).addClass(d.hasClass("k-alt")?"k-alt":"").insertAfter(d),(u||0===u)&&r.attr(kt,Number(u)+1),s.trigger(U,{masterRow:d,detailRow:r,data:o,detailCell:r.find(".k-detail-cell")})),s.trigger(c?te:ne,{masterRow:d,detailRow:r}),i?(a=c,e(r)[0].style.display=a?"":Dt):r.toggle(c)},dataItem:function(t){if(!(t=e(t)[0]))return null;var n,i,r=this.tbody.children(),o=/k-grouping-row|k-detail-row|k-group-footer/,a=t.sectionRowIndex;for(i=a,n=0;n<a;n++)o.test(r[n].className)&&i--;return this._data[i]},expandRow:function(t,n){var i=e(t).find("> td "+R);i.length&&this._toggleDetails(i,n)},collapseRow:function(t,n){var i=e(t).find("> td "+F);i.length&&this._toggleDetails(i,n)},_createHeaderCells:function(i,r){var o,a,s,l,c,d,u,h=this,p="",f=h.options.columnMenu,m=(h.options.sortable,h._hasFilterMenu()),g=h.options.messages,v=ei(h.columns),b=h.dataSource.group();for(o=0,l=i.length;o<l;o++){a=i[o].column||i[o],s=h._headerCellText(a),c=a.title,d="";let l=_(a,v),y="";a.selectable?(y+="<th scope='col'"+nn(a.headerAttributes),r&&!i[o].colSpan&&(y+=" rowspan='"+r+"'"),l>-1&&(y+=n.attr("index")+"='"+l+"'"),y+=">"+(s=a.headerTemplate?s:n.template(Ot)({size:n.getValidCssClass("k-checkbox-","size",h.options.size)}))+"</th>"):a.draggable?(y+="<th class='k-header k-drag-cell' scope='col'"+nn(a.headerAttributes),r&&!i[o].colSpan&&(y+=" rowspan='"+r+"'"),l>-1&&(y+=n.attr("index")+"='"+l+"'"),y+=">"+(s=a.headerTemplate?s:"")+"</th>"):a.command?(y+="<th scope='col'"+nn(a.headerAttributes),r&&!i[o].colSpan&&(y+=" rowspan='"+r+"'"),l>-1&&(y+=n.attr("index")+"='"+l+"'"),y+=">"+(s&&"&nbsp;"!==s?n.template(Nt)({text:s}):s)+"</th>"):(a.field&&(d=n.attr("field")+"='"+a.field+"' "),y+="<th scope='col' "+d,f&&a.field&&!1!==a.menu?y+=" aria-haspopup='menu'":m&&!1!==a.filterable&&!a.command&&(y+=" aria-haspopup='dialog'"),r&&!i[o].colSpan&&(y+=" rowspan='"+r+"'"),i[o].colSpan>1?(y+='colspan="'+(i[o].colSpan-Rn(a.columns))+'" ',y+=n.attr("colspan")+"='"+i[o].colSpan+"'"):1===i[o].colSpan&&(y+=n.attr("colspan")+"='"+i[o].colSpan+"'"),c&&(c=c&&(h.options.encodeTitles?Ii(c,!0):c),y+=n.attr("title")+'="'+c+'" '),a.groupable!==t&&(y+=n.attr("groupable")+"='"+a.groupable+"' "),u=a,!h.options.groupable||!u.groupable&&u.groupable!==t||a.headerAttributes&&a.headerAttributes.title||(y+="title='",y+=ki(b,a.field)?g.ungroupHeader:g.groupHeader,y+="' "),a.aggregates&&a.aggregates.length&&(y+=n.attr("aggregates")+"='"+a.aggregates+"'"),l>-1&&(y+=n.attr("index")+"='"+l+"'"),y+=nn(a.headerAttributes),y+=">"+(s=n.template(Nt)({text:s}))+"</th>"),h.options.resizable?p+=e(y).attr("data-resizable",(!1!==a.resizable).toString()).addClass("k-table-th")[0].outerHTML:p+=e(y).addClass("k-table-th")[0].outerHTML}return p},_appendLockedColumnContent:function(){var t,i,r,o,a,s=this.columns,l=this.table.find("colgroup"),c=l.find(P),d=e(),u=0,h=0;for(t=0,i=s.length;t<i;t++)if(s[t].locked)if(bn(s[t])){for(o=1,s[t].columns&&(o=ei(s[t].columns).length-Rn(s[t].columns)),o=o||1,a=0;a<o;a++)d=d.add(c.eq(t+h+a-u));h+=o-1}else u++;r=e('<div class="k-grid-content-locked"><table class="k-grid-table k-table"><colgroup></colgroup><tbody class="k-table-tbody"></tbody></table></div>'),l.detach(),r.find("colgroup").append(d),l.insertBefore(this.table.find("tbody")),this.lockedContent=r.insertBefore(this.content),this.lockedTable=r.children("table"),this.lockedTable.addClass(n.getValidCssClass("k-table-","size",this.options.size))},_appendLockedColumnFooter:function(){var t,i,r=this,o=r.footer,a=o.find(".k-footer-template>td"),s=o.find(".k-grid-footer-wrap>table>colgroup>col"),l=e('<div class="k-grid-footer-locked"><table class="k-grid-footer-table k-table"><colgroup></colgroup><tfoot class="k-table-tfoot"><tr class="k-footer-template k-table-row"></tr></tfoot></table></div>'),c=r._groups(),d=e(),u=e();for(l.find("table").addClass(n.getValidCssClass("k-table-","size",this.options.size)),d=d.add(a.filter(".k-group-cell")),t=0,i=ei(jn(r.columns)).length;t<i;t++)d=d.add(a.eq(t+c));for(u=u.add(s.filter(".k-group-col")),t=0,i=yn(ei(Yn(r.columns))).length;t<i;t++)u=u.add(s.eq(t+c));d.appendTo(l.find(mt)),u.appendTo(l.find("colgroup")),r.lockedFooter=l.prependTo(o)},_appendLockedColumnHeader:function(t){var i,r,o,a,s,l,c,d,u,h=this,p=this.columns,f=[],m=0,g=e(),v=h._hasFilterRow(),_=0,b=e(),y=0,w=e();a=h.thead.prev().find(P),c=h.thead.find(mt).first().find(".k-header:not(.k-group-cell,.k-hierarchy-cell)"),d=h.thead.find(".k-filter-row").find("td:not(.k-group-cell,.k-hierarchy-cell)");var k=0;for(i=0,o=p.length;i<o;i++){if(p[i].locked){if(u=c.eq(i),y=ei(p[i].columns||[]).length,bn(p[i])){var x=null;p[i].columns&&(x=y-Rn(p[i].columns)),x=x||1;for(var C=0;C<x;C++)g=g.add(a.eq(i+k+C-m));k+=x-1}Vn([p[i]],oi(u),f,0,0),y=y||1;for(var S=0;S<y;S++)b=b.add(d.eq(_+S));_+=y}p[i].columns&&(m+=Rn(p[i].columns)),bn(p[i])||m++}if(f.length){for(r='<div class="k-grid-header-locked"><table class="k-grid-header-table k-table"><colgroup></colgroup><thead class="k-table-thead">',r+=new Array(f.length+1).join("<tr class='k-table-row'></tr>"),(l=e(r+=(v?'<tr class="k-filter-row k-table-row"></tr>':"")+"</thead></table></div>")).find(".k-grid-header-locked").css("width","1px"),l.find("table").addClass(n.getValidCssClass("k-table-","size",h.options.size)),(a=l.find("colgroup")).append(h.thead.prev().find("col.k-group-col").add(g)),s=l.find("thead tr:not(.k-filter-row)"),i=0,o=f.length;i<o;i++)w=xn(f[i]),s.eq(i).append(h.thead.find(mt).eq(i).find(".k-group-cell").add(w));var T=On(this.thead);return f.length<T&&function(e,t){for(var n,i=e.find("tr:not(.k-filter-row) th:not(.k-group-cell,.k-hierarchy-cell)"),r=0;r<i.length;r++)(n=i[r].rowSpan)>1&&(i[r].rowSpan=n-t||1)}(l,T-f.length),l.find(".k-filter-row").append(h.thead.find(".k-filter-row .k-group-cell").add(b)),this.lockedHeader=l.prependTo(t),this.thead.find(".k-group-cell").remove(),!0}return!1},_removeLockedContainers:function(){var e=this.lockedHeader.add(this.lockedContent).add(this.lockedFooter);n.destroy(e),e.off(B).remove(),this.lockedHeader=this.lockedContent=this.lockedFooter=null,this.selectable=null},_thead:function(){var t,i,r,o=this,a=o.columns,s=o._hasDetails()&&a.length,l=o._hasFilterRow(),c="",d=o.table.find(">thead"),u=o.element.find("thead").first().length>0,h=o.options.messages.expandCollapseColumnHeader;if(d.length||(d=e("<thead/>").insertBefore(o.tbody)),d.addClass("k-table-thead").attr("role","rowgroup"),o.lockedHeader&&o.thead?((i=o.thead.find("tr:has(th):not(.k-filter-row)").html("")).remove(),i=e(),o._removeLockedContainers()):i=u?o.element.find("thead").first().find("tr:has(th):not(.k-filter-row)"):o.element.find("tr:has(th)").first(),i.length){for(t=0;t<a.length;t++){var p=_(a[t],ei(a)),f=ii(i.parent()).filter("th:not(.k-group-cell):not(.k-hierarchy-cell)").eq(p);f.addClass("k-table-th"),a[t].hidden&&p>=0&&(f[0].style.display=Dt)}o._updateHeadersAttr(Zn(a))}else if(!(i=d.children().first()).length){var m=[{rowSpan:1,cells:[],index:0}];for(o._prepareColumns(m,a),t=0;t<m.length;t++)c+="<tr class='k-table-row'>",s&&(c+='<th class="k-hierarchy-cell k-table-th" scope="col">'+h+"</th>"),c+=o._createHeaderCells(m[t].cells,m[t].rowSpan),c+="</tr>";i=e(c),n.applyStylesFromKendoAttributes(i,["display","left","right"])}if(l){var g=e("<tr/>");g.addClass("k-filter-row k-table-row"),(s||i.find(".k-hierarchy-cell").length)&&g.prepend('<td class="k-table-td k-hierarchy-cell">&nbsp;</td>');var v=(o.thead||d).find(".k-filter-row");v.length&&(n.destroy(v),v.remove()),d.append(g)}i.children().length?s&&!i.find(".k-hierarchy-cell")[0]&&i.prepend('<th class="k-hierarchy-cell k-table-th" scope="col">'+(h||"&nbsp;")+"</th>"):(c="",s&&(c+='<th class="k-hierarchy-cell k-table-th" scope="col">&nbsp;</th>'),c+=o._createHeaderCells(a),i.html(c)),i.find("th").addClass(Se),o.options.scrollable||d.addClass("k-grid-header"),i.find("script").remove().end().prependTo(d),o.thead&&o._destroyColumnAttachments(),o.thead=d,o._sortable(),o._filterable(),o._filterRow(),o._scrollable(),o._columnMenu();var b=this.options.scrollable&&jn(this.columns).length;b&&(r=o._appendLockedColumnHeader(o.thead.closest(".k-grid-header")),o._appendLockedColumnContent(),o.lockedContent.on("DOMMouseScroll"+B+" mousewheel"+B,o._wheelScroll.bind(o)),n.support.touch&&(o._lockedContentUserEvents=new n.UserEvents(o.lockedContent,{move:function(e){o.content.scrollTop(o.content.scrollTop()+-e.y.delta),e.preventDefault()}})),o._updateLockedCols()),o._updateCols(),o._updateColumnCellIndex(),o._updateFirstColumnClass(),o._resizable(),o._draggable(),o._reorderable(),o._updateHeader(o._groups()),o._updateStickyColumns(),b&&(r&&o._syncLockedHeaderHeight(),o._applyLockedContainersWidth())},_retrieveFirstColumn:function(t,n){var i=e();if(n.length&&t[0]){for(var r=t[0];r.columns&&r.columns.length;)r=r.columns[0],n=n.filter(":not(:first)");i=i.add(n)}return i},_updateFirstColumnClass:function(){var t=this,n=t.columns||[];if(!(t._hasDetails()&&n.length)&&!t._groups()){var i=t.thead.find(">tr:not(.k-filter-row):not(:first)");n=qn(n);var r=t._retrieveFirstColumn(n,i);t._isLocked()&&(i=t.lockedHeader.find("thead>tr:not(.k-filter-row):not(:first)"),n=jn(t.columns),r=r.add(t._retrieveFirstColumn(n,i))),r.each((function(){var t=e(this).find("th");t.removeClass("k-first"),t.eq(0).addClass("k-first")}))}},_prepareColumns:function(e,t,n,i){for(var r=i||e[e.length-1],o=e[r.index+1],a=0,s=0;s<t.length;s++){var l={column:t[s],colSpan:0};r.cells.push(l),t[s].columns&&t[s].columns.length&&(o||(o={rowSpan:0,cells:[],index:e.length},e.push(o)),l.colSpan=t[s].columns.length,this._prepareColumns(e,t[s].columns,l,o),a+=l.colSpan-1,r.rowSpan=e.length-r.index)}n&&(n.colSpan+=a)},_wheelScroll:function(e){if(!e.ctrlKey){var t=this.content;this.virtualScroll&&this.virtualScroll.rows&&(t=this.virtualScrollable.verticalScrollbar);var i=t.scrollTop(),r=n.wheelDeltaY(e);r&&(t[0].scrollHeight>t[0].clientHeight&&(t[0].scrollTop<t[0].scrollHeight-t[0].clientHeight&&r<0||t[0].scrollTop>0&&r>0)&&e.preventDefault(),t.scrollTop(i+-r))}},_isLocked:function(){return null!=this.lockedHeader},_updateHeaderCols:function(){var e=this.thead.parent().add(this.table);this._isLocked()?ci(e,Qn(Kn(this.columns)),this._hasDetails(),0):ci(e,Qn(yn(this.columns)),this._hasDetails(),0)},_updateColumnSorters:function(){var e,t,n=this,i=ii(n.thead),r=ei(n.columns);if(n.options.sortable)for(var o=0,a=i.length;o<a;o++)!1!==(e=r[o]).sortable&&!e.command&&e.field&&(t=i.eq(o).data("kendoColumnSorter"))&&t.refresh()},_updateHeadersAttr:function(e){if(e.length){for(var t=0;t<e.length;t++){if(e[t].headerAttributes)this.element.find("[id='"+e[t].headerAttributes.id+"']").attr("headers",e[t].headerAttributes.headers)}this._updateHeadersAttr(Zn(e))}},_updateCols:function(e){e=e||this.thead.parent().add(this.table),this._appendCols(e,this._isLocked())},_updateLockedCols:function(e){this._isLocked()&&ci(e=e||this.lockedHeader.find("table").add(this.lockedTable),Qn(Yn(this.columns)),this._hasDetails(),this._groups())},_appendCols:function(e,t){t?ci(e,Qn(Kn(this.columns)),this._hasDetails(),0):ci(e,Qn(yn(this.columns)),this._hasDetails(),this._groups())},_autoColumns:function(e){if(e&&e.toJSON){var t,i,r=this;for(t in e=e.toJSON(),i=!(r.table.find("tbody tr").length>0&&(!r.dataSource||!r.dataSource.transport)),e)r.columns.push({field:t,encoded:i,headerAttributes:{id:n.guid()}});r._thead(),r._templates()}},_setRowCachedHeight:function(t,n){var i,r=this._cachedRowsHeight[n];return r&&((i=e(t))[0].style.height=r+"px",t=i.prop("outerHTML")),t},_rowsHtml:function(e,t){var n,i,r,o=this,a="",s=t.rowTemplate,l=t.altRowTemplate,c=o._cachedRowsHeight;for(n=0,i=e.length;n<i;n++)o._skipRerenderItemsCount>0?o._skipRerenderItemsCount--:(r=n%2?l(e[n]):s(e[n]),c&&(r=o._setRowCachedHeight(r,e[n].uid)),a+=r),o._data.push(e[n]);return a},_groupData:function(e,t,n){var i=this._groupAggregatesDefaultObject||{},r=e.items,o=f({},i,e.aggregates),a=f({},{field:e.field,value:e.value,items:r,aggregates:o},e.aggregates[n?n.field:e.field]),s={};if(!t)for(var l in o)s[l]=f({},o[l],{group:{field:e.field,value:e.value,items:r}});return f({},s,a)},_removeGroupIfEmpty:function(e){for(var t,n,i=this.dataSource._group.length,r=0;r<i;r++)t=+(e=e.prev()).attr("data-group-item-count"),n=+e.attr("data-sub-group-count"),1!=t&&1!=n||e.hide()},_groupRowHtml:function(e,t,i,r,o,a,s,l){var c,d,u,h=this,p="",m=null!=h.lockedContent,v=e.field,b=g(ei(h.columns),(function(e){return e.field==v}))[0]||{},y=yn(h.columns)[0],w=y?y.groupHeaderColumnTemplate:null,k=b.groupHeaderTemplate?b.groupHeaderTemplate:w,x=(b.title&&(h.options.encodeTitles?Ii(b.title,!0):b.title)||Ii(v,!0))+": "+ui(e.value,b.format,b.values,b.encoded),C=e.currentItems||e.items,S=h._groups(),T=o.groupFooterTemplate,D=o.groupHeaderColumnTemplate,A=h.dataSource._isGroupPaged(),M=!A||h.dataSource._groupsState[e.uid];if(h.options.editable&&e.items&&e.items[0]&&e.items[0].isNew&&e.items[0].isNew()&&(M=!0),(o.groupFooterTemplate||o.groupHeaderColumnTemplate||b.groupHeaderTemplate)&&(u=h._groupData(e,!1,!(b.groupHeaderTemplate||!yn(h.columns)[0].groupHeaderColumnTemplate)&&yn(h.columns)[0])),k&&!a&&(x=typeof k===et?k(u):n.template(k)(u)),h._skipRerenderItemsCount?r(t,i,x,M,e.uid,A):e.excludeHeader?e.excludeHeader=!!m&&!l:p+=function(e,t,n,i,r,o,a,s,l,c){var d;d=e?e(f({},r,{groupCells:o,colspan:i,text:a,expanded:s,isRtl:$t,uid:l.uid})):t(n,o,a,s,l.uid,c,$t);return d}(D,r,t,S-i,u,i,x,M,e,A),M)if(e.hasSubgroups)for(c=0,d=C.length;c<d;c++)p+=h._groupRowHtml(C[c],a?t:t-1,i+1,r,o,a,s&&c===C.length-1,l);else p+=h._rowsHtml(C,o);return T&&(s?_(e.value,h._skippedGroups)||h._skippedGroups.push(e.value):(h._skippedGroups.length&&h._skippedGroups[0]===e.value&&h._skippedGroups.shift(),h._skipRerenderItemsCount||(p+=T(u)))),p},collapseGroup:function(t){var i,r,o,a,s,l=this,c=t,d=this.options.groupable.showFooter?0:1,u=e();if(i=(t=e(t)).find(".k-group-cell").length,this.dataSource._isGroupPaged()){var h,p=t.attr("data-group-uid"),f=l.dataSource._getGroupByUid(p),m=l.dataSource._calculateGroupsTotal([f],!0);return l.dataSource._groupsState[p]=!1,h=l.dataSource._calculateGroupsTotal([f],!0),l.dataSource._serverGroupsTotal-=m-h,l._progress(!0),void l.dataSource.range(l.dataSource._currentRangeStart,l.dataSource.take(),(function(){l._progress(!1)}),"collapseGroup")}this._isLocked()&&(t.closest(gt).hasClass("k-grid-content-locked")?u=this.tbody.children(mt).eq(t.index()).nextAll(mt):(u=t.nextAll(mt),t=this.lockedTable.find(">tbody>tr").eq(t.index()))),t.find(F).length&&n.ui.icon(t.find(F),{icon:"caret-alt-"+($t?"left":"right")}),t.find("td[aria-expanded='true']").first().attr(xt,!1).find("a").attr(vt,ht);var g=[];for(o=0,a=(t=t.nextAll(mt)).length;o<a&&(r=(s=t.eq(o)).find(".k-group-cell").length,s.hasClass(ze)?d++:s.hasClass("k-group-footer")&&d--,!(r<=i||s.hasClass("k-group-footer")&&d<0));o++)u.length&&g.push(u[o]),g.push(s[0]);e(g).hide(),this.options.scrollable.endless&&this.content&&(clearTimeout(l._collapseGroupsTimeOut),l._collapseGroupsTimeOut=setTimeout((function(){l.content.scroll(),l._groupToCollapse=c})))},expandGroup:function(t){t=e(t);var i,r,o,a,s,l=this,c=l.options.groupable.showFooter,d=e(),u=[],h=1;if(i=t.find(".k-group-cell").length,this.dataSource._isGroupPaged()){var p,f=t.attr("data-group-uid"),m=l.dataSource._getGroupByUid(f),g=l.dataSource._calculateGroupsTotal([m],!0);return l.dataSource._groupsState[f]=!0,m.items&&m.items.length&&(p=l.dataSource._calculateGroupsTotal([m],!0),l.dataSource._serverGroupsTotal+=p-g),l._progress(!0),void l.dataSource.range(l.dataSource._currentRangeStart,l.dataSource.take(),(function(){l._progress(!1)}),"expandGroup")}for(this._isLocked()&&(t.closest(gt).hasClass("k-grid-content-locked")?d=this.tbody.children(mt).eq(t.index()).nextAll(mt):(d=t.nextAll(mt),t=this.lockedTable.find(">tbody>tr").eq(t.index()))),t.find(R).length&&n.ui.icon(t.find(R),{icon:"caret-alt-down"}),t.find("td[aria-expanded='false']").first().attr(xt,!0).find("a").attr(vt,ut),a=0,s=(t=t.nextAll(mt)).length;a<s&&!((o=(r=t.eq(a)).find(".k-group-cell").length)<=i);a++)if(o!=i+1||r.hasClass("k-detail-row")||(r.show(),d.eq(a).show(),r.hasClass(ze)&&r.find(".k-icon,.k-svg-icon").is(F)&&l.expandGroup(r),r.hasClass("k-master-row")&&r.find(".k-icon,.k-svg-icon").is(F)&&(r.next().show(),d.eq(a+1).show())),r.hasClass(ze)&&(c&&u.push(r.is(":visible")),h++),r.hasClass("k-group-footer")){if(c){var v=u.pop();r.toggle(v),d.eq(a).toggle(v)}1==h?(r.show(),d.eq(a).show()):h--}(0===i&&l.options.scrollable.endless&&this._isLocked()||!l.options.scrollable.endless&&this._isLocked())&&l._syncLockedContentHeight()},_updateHeader:function(t){var n=this,i=n._isLocked()?n.lockedHeader.find("thead"):n.thead,r=i.find("tr.k-filter-row").find("td.k-group-cell").length,o=i.find(mt).first().find("th.k-group-cell").length,a=i.children("tr:not(:first)").filter((function(){return!e(this).children(":visible").length}));t>o?(e(new Array(t-o+1).join('<th class="k-group-cell k-header k-table-th" scope="col">'+w(n.options.messages.expandCollapseColumnHeader)+"</th>")).prependTo(i.children("tr:not(.k-filter-row)")),n.element.is(":visible")&&a.find("th.k-group-cell").hide()):t<o&&i.find(mt).each((function(){e(this).find(".k-group-cell").eq(t).remove(),e(this).find(".k-group-cell").slice(t).remove()})),t>r&&e(new Array(t-r+1).join('<td class="k-group-cell k-table-group-td k-table-td">&nbsp;</td>')).prependTo(i.find(".k-filter-row"))},_firstDataItem:function(e,t){return e&&t&&(e=e.hasSubgroups?this._firstDataItem(e.items[0],t):e.items[0]),e},_updateTablesWidth:function(){var t,n=this;n._isLocked()&&(t=e(">.k-grid-footer>.k-grid-footer-wrap>table",n.wrapper).add(n.thead.parent()).add(n.table),n._footerWidth=vi(t.eq(0)),t.width(n._footerWidth),(t=e(">.k-grid-footer>.k-grid-footer-locked>table",n.wrapper).add(n.lockedHeader.find(">table")).add(n.lockedTable)).width(vi(t.eq(0))))},hideColumn:function(t){var n,i,r,o,a,s,l,d,u,h=this,f=0,m=h.footer||h.wrapper.find(".k-grid-footer"),v=h.virtualScroll||{},b=h.columns,y=h.lockedHeader?ii(h.lockedHeader.find(">table>thead")).filter(vn).length:0;(Array.isArray(t)?t:[t]).forEach((t=>{if(u=g(ei(h.columns),(function(e){return e.groupHeaderColumnTemplate})),(t="number"==typeof t?b[t]:p(t)?g(Fn(b),(function(e){return e===t}))[0]:g(Fn(b),(function(e){return e.field===t}))[0])&&bn(t)){var w=h._columnVisibilitySetter(t);if(t.columns&&t.columns.length){for(a=zn(t,b),w(t,!1),hi(sn(e(">table>thead",h.lockedHeader),h.thead,">tr:eq("+a.row+")>th"),a.cell,!1),i=0;i<t.columns.length;i++)this.hideColumn(t.columns[i]);return h._ariaAddHiddenColIndex(),void h.trigger(X,{column:t})}d=_(t,yn(ei(b))),w(t,!1),h._setParentsVisibility(t,!1),h._templates(),h._updateCols(),h._updateLockedCols();var k=h.thead;if(s=d,h.lockedHeader&&y>d?k=h.lockedHeader.find(">table>thead"):s-=y,ii(k).filter(vn).eq(s)[0].style.display=Dt,hi(sn(e(">table>thead",h.lockedHeader),h.thead,">tr.k-filter-row>td"),d,!1),m[0]&&(h._updateCols(m.find(">.k-grid-footer-wrap>table")),h._updateLockedCols(m.find(">.k-grid-footer-locked>table")),hi(m.find(".k-footer-template>td"),d,!1)),v.columns&&!t.locked)return h._updateContentWidth(),void h.trigger(X,{column:t});if(h.lockedTable&&y>d?pi(h.lockedTable.find(">tbody>tr"),d):pi(h.tbody.children(),d-y),h.lockedTable)h._updateTablesWidth(),h._applyLockedContainersWidth(),h._syncLockedContentHeight(),h._syncLockedHeaderHeight(),h._syncLockedFooterHeight();else{for(r=h.thead.prev().find("col"),i=0,l=r.length;i<l;i+=1)if(o=r[i].style.width,r[i].className.indexOf("k-hierarchy-col")>-1)f+=c(r[i]);else if(r[i].className.indexOf("k-group-col")>-1)f+=c(r[i]);else{if(!o||-1!=o.indexOf("%")){f=0;break}f+=parseInt(o,10)}n=h.wrapper.find(">.k-grid-header table").first().add(h.wrapper.find(">.k-grid-footer table").first()).add(h.table),h._footerWidth=null,f&&(n.each((function(){this.style.width=f+ft})),h._footerWidth=f,h._setContentWidth())}h._updateFirstColumnClass(),h._updateStickyColumns(),u.length>0&&h._renderGroupRows(),h._ariaAddHiddenColIndex(),h.trigger(X,{column:t})}}))},_setParentsVisibility:function(t,i){var r,o,a,s,l,c=this.columns,d=[],u=this._columnVisibilitySetter(t),h=i?function(e){return yn(e.columns).length&&e.hidden}:function(e){return!yn(e.columns).length&&!e.hidden};if(un(t,c,d)&&d.length)for(r=d.length-1;r>=0;r--)a=Mn(o=d[r],c),s=sn(e(">table>thead",this.lockedHeader),this.thead,">tr:eq("+a.row+")>th:not(.k-group-cell):not(.k-hierarchy-cell)").eq(a.cell),h(o)&&(u(o,i),s[0].style.display=i?"":Dt),s.filter("["+n.attr("colspan")+"]").length&&(l=parseInt(s.attr(n.attr("colspan")),10),s[0].colSpan=l-Rn(o.columns)||1)},_updateContentWidth:function(){var e=this;e.table.add(e.thead.parent()).css({width:Ln(Qn(Kn(e.columns)))}),e.refresh()},showColumn:function(t){var n,i,r,o,a,s,l,d,u,h,f,m,v,b=this,y=b.columns,w=b.virtualScroll||{},k=b.footer||b.wrapper.find(".k-grid-footer"),x=b.lockedHeader?ii(b.lockedHeader.find(">table>thead")).length:0;(Array.isArray(t)?t:[t]).forEach((t=>{if(v=g(ei(b.columns),(function(e){return e.groupHeaderColumnTemplate})),"number"==typeof t?(h=t,t=y[t]):p(t)?e.each(Fn(y),(function(e,n){if(n===t)return t=n,h=e,!1})):e.each(Fn(y),(function(e,n){if(n.field===t)return t=n,h=e,!1})),t&&!bn(t)){var C=b._columnVisibilitySetter(t);if(t.columns&&t.columns.length){for(l=Mn(t,y),f=Fn(b.options.columns)[h],C(t,!0),hi(sn(e(">table>thead",b.lockedHeader),b.thead,">tr:eq("+l.row+")>th"),l.cell,!0),n=0;n<t.columns.length;n++)f.columns[n].hidden||this.showColumn(t.columns[n]);return b._ariaRemoveHiddenColIndex(),void b.trigger(Z,{column:t})}m=_(t,ei(y)),C(t,!0),b._setParentsVisibility(t,!0),b._templates(),b._updateCols(),b._updateLockedCols();var S=b.thead;if(s=m,b.lockedHeader&&x>m?S=b.lockedHeader.find(">table>thead"):s-=x,(r=ii(S).eq(s))[0].style.display="",r[0].classList.remove("k-hidden"),hi(sn(e(">table>thead",b.lockedHeader),b.thead,">tr.k-filter-row>td"),m,!0),k[0]&&(b._updateCols(k.find(">.k-grid-footer-wrap>table")),b._updateLockedCols(k.find(">.k-grid-footer-locked>table")),hi(k.find(".k-footer-template>td"),m,!0)),w.columns&&!t.locked)return b._updateContentWidth(),void b.trigger(Z,{column:t});if(b.lockedTable&&x>m?mi(b.lockedTable.find(">tbody>tr"),m):mi(b.tbody.children(),m-x),b.lockedTable)b._updateTablesWidth(),b._applyLockedContainersWidth(),b._syncLockedContentHeight(),b._syncLockedHeaderHeight();else if(o=b.wrapper.find(">.k-grid-header table").first().add(b.wrapper.find(">.k-grid-footer table").first()).add(b.table),t.width){for(a=0,u=b.thead.prev().find("col"),n=0,i=u.length;n<i;n+=1)if(d=u[n].style.width,u[n].className.indexOf("k-hierarchy-col")>-1)a+=c(u[n]);else if(u[n].className.indexOf("k-group-col")>-1)a+=c(u[n]);else{if(d.indexOf("%")>-1){a=0;break}a+=parseInt(d,10)}b._footerWidth=null,a&&(o.each((function(){this.style.width=a+ft})),b._footerWidth=a,b._setContentWidth())}else o.width("");b._updateFirstColumnClass(),b._updateStickyColumns(),v.length>0&&b._renderGroupRows(),b._ariaRemoveHiddenColIndex(),b.trigger(Z,{column:t})}}))},_columnVisibilitySetter:function(e){return kn((e||{}).media)?hn:fn},_buildSkeleton:function(){var e,t=this.virtualCols?this.virtualCols:Qn(this.columns),n=this.dataSource.pageSize()||this.dataSource.total(),i="",r=this._groups(),o=t.length+r;this._hasDetails()&&o++,this._hasVirtualColumns()&&(e=parseInt(this.content.find(mt).first().find("td").first().attr("colspan"),10));for(var a=0;a<n;a++){i+="<tr class='k-table-row' data-skeleton-row>";for(var s=0;s<o;s++)i+=e&&!s?"<td colspan='"+e+"'><span class='k-skeleton k-skeleton-text k-skeleton-pulse k-table-td'></span></td>":"<td><span class='k-skeleton k-skeleton-text k-skeleton-pulse k-table-td'></span></td>";i+="</tr>"}return i},_progress:function(e){var t,i=this.element,r=this.options.scrollable&&this.options.scrollable.endless,o=this.options.loaderType;this.options.scrollable&&this.options.scrollable.virtual?i=this.content:this._editContainer&&"popup"===this._editMode()?i=this._editContainer:this.lockedContent||r?i=this.wrapper:this.element.is("table")?i=this.element.parent():this.content&&this.content.length&&(i=this.content),"skeleton"!=o||this._isExport?this._isExport?this._loaderContainer(e,{message:this.options.messages.loader.exporting}):r&&e?n.ui.progress(i,e,{height:this.content.height(),top:this.content.parent()[0].offsetTop,opacity:!0}):n.ui.progress(i,e):e?(t=this._buildSkeleton(),i.find("tbody").empty().append(t)):i.find(".k-skeleton").closest("tbody").empty()},_resize:function(e,t){this._syncLockedContentHeight(),this._syncLockedHeaderHeight(),this.content&&(this._setContentWidth(),this._setContentHeight()),this.lockedTable&&this._syncLockedScroll(),this.virtualScrollable&&(t||this._rowHeight)&&(t&&(this._rowHeight=null),this.virtualScrollable.repaintScrollbar()),this.pager&&this.pager.element&&this.pager.resize(t),this._anyStickyColumns()&&this._updateStickyColumns(!1)},_isActiveInTable:function(){var t=s();return!!t&&(this.table[0]===t||e.contains(this.table[0],t)||this._isLocked()&&(this.lockedTable[0]===t||e.contains(this.lockedTable[0],t)))},refresh:function(i){var r,o,a,s=this,l=s.dataSource.view(),c=s.options.navigatable,d=s.virtualScroll||{},u=e(s.current()),h=!1,p=s._groups(),f=p+Qn(yn(s.columns)).length,m=g(s.columns,(function(e){return e.columns!==t})).length>0,v=0;i&&"itemchange"===i.action&&(s.editable||s.options.scrollable.endless)&&("popup"!=this._editMode()||"popup"===this._editMode()&&!s._editableIsClosing)||(s._shouldMapHights&&(s._mapCachedRowsHeight("get","uid"),s._shouldMapHights=!1),d.columns&&s._templates(),i&&"remove"===i.action&&s.editable&&s.editable.options.model&&_(s.editable.options.model,i.items)>-1&&s.editable.options.model.unbind(Q,s._modelChangeHandler),i=i||{},s.trigger("dataBinding",{action:i.action||"rebind",index:i.index,items:i.items})||(i.action===le&&s._isVirtualEditable()&&(s._destroyEditable(),s._clearEditableState()),s._endlessFetchInProgress||(c&&(s._isActiveInTable()||s._editContainer&&s._editContainer.data("kendoWindow"))&&(r=(h=u.is("th"))?u.parent().children(":not(.k-group-cell)").index(u[0]):Math.max(s.cellIndex(u),0),h&&m&&(v=u.parent().index())),s._destroyEditable()),s.options.scrollable&&s.options.scrollable.endless&&!s._pdfInitialized?(clearTimeout(s._progressTimeOut),s._progressTimeOut=setTimeout((function(){s._endlessFetchInProgress||s._progress(!1)}),250)):s._isExport||s._progress(!1),u.length&&(s._currentRowIndex=u.parent().index()),s._hideResizeHandle(),s._data=[],s.columns.length||(s._autoColumns(s._firstDataItem(l[0],p)),f=p+s.columns.length),s._group=p>0||s._group,s._group&&(s._templates(),s._updateCols(),s._updateLockedCols(),s._virtualColScroll||s._updateHeader(p),s._group=p>0,s._groupRows=fi(l)),s.content&&(o=n.scrollLeft(s.content)),"skeleton"!==s.options.loaderType&&i&&"sync"===i.action&&i.partialUpdate&&i.changedItems&&i.changedItems.length?(s._data=s.dataSource.flatView(),i.changedItems.forEach((e=>{s._displayRow(s.tbody.find("["+n.attr("uid")+"="+e.uid+"]"))})),s._progress(!1),s._destroyEditable()):(a=s._skipRerenderItemsCount,s._renderContent(l,f,p),s.options.scrollable&&s.options.scrollable.endless&&this.lockedContent&&(s._skipRerenderItemsCount=a),s._renderLockedContent(l,f,p)),s._virtualColScroll||(s._footer(),s._renderNoRecordsContent(),s._togglePagerVisibility(),s._setContentHeight(),s._setContentWidth(s.content&&o)),s.lockedTable&&(d.rows?s.content.find(">.k-virtual-scrollable-wrap").trigger("scroll"):s.touchScroller?s.touchScroller.movable.trigger("change"):(s.wrapper.one("scroll",(function(e){e.stopPropagation()})),s.content.trigger("scroll"))),s._endlessFetchInProgress||s._rowDropping||s._restoreCurrent(r,h,v),s.touchScroller&&s.touchScroller.contentResized(),s.selectable&&s.selectable.resetTouchEvents(),s._checkBoxSelection&&s._toggleHeaderCheckState(!1),s.options.persistSelection&&(s.selectable&&!n.ui.Selectable.parseOptions(s.options.selectable).cell||s._checkBoxSelection)&&(s.items().length||s.dataSource._isGroupPaged())&&s._restoreSelection(),s.options.persistSelection||(s._selectedIds={}),s._hasReorderableRows()&&(s._draggableRows(),s._reorderableRows()),s.options.selectable&&s.options.selectable.cellAggregates&&s._calculateAggregatesForSelected(),s._aria(),s.trigger(ee)))},_getSchemaIdField:function(){const e=this.dataSource.options.schema.model;return y(e)?e.fn.idField:e&&e.id},_restoreCurrent:function(n,i,r){if(!(n===t||n<0)){if(this._removeCurrent(),i)this._setCurrent(this.thead.find(`tr:eq(${r}) th:not(.k-group-cell)`).eq(n),!1,this._hasVirtualColumns());else{var o=0,a=this.virtualScroll||{};this._rowVirtualIndex?o=a.rows?this.virtualScrollable.position(this._rowVirtualIndex):this._rowVirtualIndex:this._currentRowIndex?o=this._currentRowIndex:n=0;var s,l=e();this.lockedTable&&(l=this.lockedTable.find(">tbody>tr").eq(o)),l=l.add(this.tbody.children().eq(o)),this._hasVirtualColumns()&&(s=parseInt(l.find("td").first().attr("colspan"),10),n=this._virtualCellIndex-(s>1?s-1:0));var c=l.find(">td:not(.k-group-cell):not(.k-hierarchy-cell)").eq(n);if(!c.length||n<0)return;this._hasVirtualColumns()?this._setCurrent(c,!0,!0):this._setCurrent(c)}this._current&&wi(this.table,!0)}},_restoreSelection:function(){var e,t=this,n=t.items(),i=t._getSchemaIdField();e=g(n,(function(e){var n=t.dataItem(e)[i];if(t._selectedIds[n])return e})),t.select(e)},_getSelectedRowUids:function(){var t,i,r=this.select(),o=[];for(let a=0;a<r.length;a++)t=e(r[a]),n.ui.Selectable.parseOptions(this.options.selectable).cell&&(t=t.closest(mt)),i=t.data("uid"),-1===o.indexOf(i)&&o.push(i);return o},_getSelectedColumnFields:function(){var t,i,r=this,o=r.select(),a=Qn(r.columns).filter((e=>!e.selectable&&!e.draggable&!e.command)),s=[];if(!n.ui.Selectable.parseOptions(r.options.selectable).cell)return a.map((e=>e.field));for(let n=0;n<o.length;n++)i=e(o[n]).index(),t=r.thead.find("th:eq("+i+")").data("field"),-1===s.indexOf(t)&&s.push(t);return s},_cleanupDetailItems:function(){this._hasDetails()&&this.tbody.find(".k-detail-cell").empty()},_renderContent:function(e,t,i){var r,o,a,s,l,c=this,d="",u=null!=c.lockedContent,h=c.options.scrollable,p={rowTemplate:c.rowTemplate,altRowTemplate:c.altRowTemplate,groupFooterTemplate:c.groupFooterTemplate,groupHeaderColumnTemplate:c.groupHeaderColumnTemplate};if(h&&h.endless&&!c.dataSource.options.endless&&(c._skipRerenderItemsCount=0,c.content&&(c.content[0].scrollTop=0)),a=c._skipRerenderItemsCount>0,t=u?t-Qn(Yn(c.columns)).length:t,i>0)for(t=u?t-i:t,c.detailTemplate&&t++,c.groupFooterTemplate&&(c._groupAggregatesDefaultObject=c.dataSource.aggregates()),c.options.scrollable.endless&&(l=c.dataSource.flatView().length),r=0,o=e.length;r<o;r++)c._skippedGroups||(c._skippedGroups=[]),s=l&&r===e.length-1&&l!==c.dataSource.total(),d+=c._groupRowHtml(e[r],t,0,u?Ei:Mi,p,u,s,!1);else d+=c._rowsHtml(e,p);a?(c.tbody.append(d),n.applyStylesFromKendoAttributes(c.tbody,["display","left","right"]),clearTimeout(c._endlessFetchTimeOut),c._endlessFetchTimeOut=setTimeout((function(){c._groupToCollapse&&(c.collapseGroup(c._groupToCollapse),c._groupToCollapse=null)})),c._endlessFetchInProgress=null):c.tbody=ai(c.tbody,c.table,d,this.options.size)},_renderGroupRows:function(){var t,i,r,o,a,s,l,c,d,u,h,p,m,v,_,b,y,w=this,k=w._groupRows,x=w.wrapper.find(S+ze),C=w._groups(),T=null!=w.lockedContent;x.each((function(x,S){v=e(S),u=v.closest("table").parent(),h=u.is(".k-grid-content-locked"),i=Qn(yn(h?jn(w.columns):qn(w.columns))),_=v.find(".k-group-cell").length,T?(t=h?Mi:Ei,r=h?i.length+C-_:i.length):(t=Mi,r=i.length+C-_),o=x>=k.length?k[x-k.length]:k[x],a=o.field,s=g(ei(w.columns),(function(e){return e.field==a}))[0]||{},y=!(s.groupHeaderTemplate||!yn(w.columns)[0].groupHeaderColumnTemplate)&&yn(w.columns)[0],l=s.groupHeaderTemplate?s.groupHeaderTemplate:yn(w.columns)[0].groupHeaderColumnTemplate,c=(s.title&&(w.options.encodeTitles?Ii(s.title,!0):s.title)||Ii(a,!0))+": "+ui(o.value,s.format,s.values,s.encoded),d=w._groupData(o,!1,y),b=h?w.lockedGroupHeaderColumnTemplate:w.groupHeaderColumnTemplate,l&&(c=typeof l===et?l(d):n.template(l)(d)),p=v.prev().length?v.prev():v.parent(),m=e(b?b(f({},d,{groupCells:_,colspan:C-_,text:c})):t(r,_,c,null,null,null,$t)),n.applyStylesFromKendoAttributes(m,["display","left","right"]),p.is("tbody")?p.prepend(m):p.after(m),v.remove()}))},_renderLockedContent:function(e,t,n){var i,r,o,a,s="",l=null,c={rowTemplate:this.lockedRowTemplate,altRowTemplate:this.lockedAltRowTemplate,groupFooterTemplate:this.lockedGroupFooterTemplate,groupHeaderColumnTemplate:this.lockedGroupHeaderColumnTemplate};if(this.lockedContent){var d=this.lockedTable;if(l=this._skipRerenderItemsCount>0,n>0)for(t-=yn(ei(qn(this.columns))).length,this.options.scrollable.endless&&(a=this.dataSource.flatView().length),i=0,r=e.length;i<r;i++)o=a&&i===e.length-1&&a!==this.dataSource.total(),s+=this._groupRowHtml(e[i],t,0,Mi,c,!1,o,!0);else s=this._rowsHtml(e,c);l?d.children("tbody").append(s):ai(d.children("tbody"),d,s,this.options.size),this._syncLockedContentHeight()}},_togglePagerVisibility:function(){!1===this.options.pageable.alwaysVisible&&this.wrapper.find(".k-grid-pager").toggle(this.dataSource.total()>=this.dataSource.pageSize())},_adjustRowsHeight:function(e,t){var n,i=e[0].rows,r=i.length,o=t[0].rows,a=e.add(t),s=a.length,l=[];for(n=0;n<r&&o[n];n++)i[n].style.height&&(i[n].style.height=o[n].style.height="");for(n=0;n<r&&o[n];n++){var c=i[n].offsetHeight,d=o[n].offsetHeight,u=0;c>d?u=c:c<d&&(u=d),l.push(u)}for(n=0;n<s;n++)a[n].style.display=Dt;for(n=0;n<r;n++)l[n]&&(i[n].style.height=o[n].style.height=l[n]+1+ft);for(n=0;n<s;n++)a[n].style.display=""}});function bi(e,t){var n,i=e.offsetHeight,r=t.offsetHeight;i>r?n=i+ft:i<r&&(n=r+ft),n&&(e.style.height=t.style.height=n)}function yi(e,t){var n,i,r;if(typeof e===tt&&e===t)return e;if(p(e)&&e.name===t)return e;if(v(e))for(n=0,i=e.length;n<i;n++)if(typeof(r=e[n])===tt&&r===t||r.name===t)return r;return null}function wi(t,i){if(t&&0!==t.length)if(!0===i){t=e(t);var r=n.scrollLeft(t.parent());n.focusElement(t),n.scrollLeft(t.parent(),r)}else e(t).one("focusin",(function(e){e.preventDefault()})).trigger("focus")}function ki(t,n){return!!e.grep(t,(function(e){return e.field===n})).length}function xi(e,t){return!(!e.field||e.selectable)&&(!(t.editable&&!t.editable(e.field))&&!(e.editable&&!e.editable(t)))}function Ci(t){return e(t).is(":button,a,:input,a>.k-icon,a>.k-svg-icon,textarea,span.k-select,span.k-icon,span.k-svg-icon,span.k-svg-icon>svg,span.k-svg-icon>svg>path,span.k-link,label.k-checkbox-label,.k-input,.k-multiselect-wrap,.k-picker-wrap,.k-picker-wrap>.k-selected-color,.k-tool-icon,.k-dropdownlist,.k-switch-thumb,.k-switch-track,.k-switch-label-off,.k-switch-label-on")}function Si(t){var i=this,r=e(t.currentTarget),o=r.is("th"),a=this.table.add(this.lockedTable),s=this.thead.parent().add(e(">table",this.lockedHeader)),l=Ci(t.target),c=e(t.target).is(".k-checkbox"),d=e(t.target),u=r.closest("table")[0];l&&r.find(n.roleSelector("filtercell")).length?this._setCurrent(r):u!==a[0]&&u!==a[1]&&u!==s[0]&&u!==s[1]||d.is(R+","+F)||(this.options.navigatable&&this._setCurrent(r,!1,c),!o&&l||setTimeout((function(){var t=e(n._activeElement());(t.hasClass("k-widget")||t.hasClass("k-dropdownlist")||t.is(".k-upload .k-upload-button"))&&!t.hasClass("k-grid-pager")||!i.table||!t.is(_e)&&Ci(n._activeElement())&&e.contains(u,n._activeElement())||wi(i.table[0],!0)})),o&&!n.support.touch&&t.preventDefault())}function Ti(e,t){if(!t)return 0;var i=0;return n.support.browser.webkit&&(i=e.width()),i}function Di(t,n){var i,r;return!!t&&!!((n=e(n))[0]&&x(t[0],n[0])&&(i=n.offset().top-t.offset().top,r=n.outerHeight()/2,(i>=0||C.abs(i)<=r)&&C.floor(i+r)<=t.height()))}function Ai(t){return({colspan:i,text:r,expanded:o,isRtl:a})=>{let s="caret-alt-"+(a?"left":"right");return`<td class="k-table-td" colspan="${i+t}"><p class="k-reset">`+n.ui.icon(e(`<a href="\\#" tabindex="-1" ${vt}="${o?ut:ht}"></a>`),{icon:o?"caret-alt-down":s})+r+`</p></td>${new Array(i+t).join("<td hidden group-header-spanned-hidden></td>")}`}}function Mi(t,i,r,o,a,s,l){return"<tr "+(s?'data-group-uid="'+a+'"':"")+'class="k-table-group-row k-grouping-row k-table-row">'+tn(i)+'<td class="k-table-td" colspan="'+t+'" aria-expanded="'+!!o+'"><p class="k-reset">'+n.ui.icon(e('<a href="#" tabindex="-1" '+vt+'="'+(o?ut:ht)+'"></a>'),{icon:o?"caret-alt-down":"caret-alt-"+(l?"left":"right")})+r+`</p></td>${new Array(t).join("<td hidden group-header-spanned-hidden></td>")}</tr>`}function Ei(e){return'<tr class="k-table-group-row k-grouping-row k-table-row"><td class="k-table-td" colspan="'+e+'" aria-expanded="true">'+`<p class="k-reset">&nbsp;</p></td>${new Array(e).join("<td hidden group-header-spanned-hidden></td>")}</tr>`}function Ii(e,t){return(""+e).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,(function(e){return t?"\\"+e:"&quot;"})).replace(/'/g,"&#39;")}function zi(e,t){return this.dataSource.indexOf(this.dataSource.getByUid(e.uid))-this.dataSource.indexOf(this.dataSource.getByUid(t.uid))}function Pi(e){return!(!1===e.exportable||e.exportable&&!1===e.exportable.excel)}n.ExcelMixin&&n.ExcelMixin.extend(_i.prototype),n.PDFMixin&&(n.PDFMixin.extend(_i.prototype),_i.prototype._drawPDF_autoPageBreak=function(i){var r,o=this,a=new e.Deferred,s=o.dataSource,l=o.options.pdf.allPages,c=o.wrapper.find("> table > tbody, .k-grid-content > table > tbody").first(),d=e("<div>").css({position:"absolute",left:-1e4,top:-1e4});o.toggleUnexportableColumns(o.columns),(r=o.wrapper.clone().css({height:Ze,width:Ze}).appendTo(d)).find(".k-grid-content").css({height:Ze,width:Ze,overflow:"visible"}),r.find("> table, .k-grid-header table, .k-grid-content > table, .k-grid-footer table").css({height:Ze,width:"100%",overflow:"visible"}),r.find(".k-grid-pager, .k-grid-toolbar, .k-grouping-header").remove(),r.find(".k-grid-header, .k-grid-footer, .k-auto-scrollable").css({paddingRight:0});var u=r.find("> table > tbody, .k-grid-content > table > tbody").first().empty(),h=s.page();function p(){d.appendTo(document.body);var t=e.extend({},o.options.pdf,{_destructive:!0,progress:function(e){i.notify({page:e.page,pageNumber:e.pageNum,progress:.5+e.pageNum/e.totalPages/2,totalPages:e.totalPages})}});n.drawing.drawDOM(r,t).always((function(){d.remove()})).then((function(e){a.resolve(e),o.toggleUnexportableColumns(o.columns,!0)})).fail((function(e){a.reject(e)}))}function f(){var e=s.page(),n=l?s.totalPages():1;u.append(c.children("tr:not(.k-detail-row)")),e<n?s.page(e+1):(s.unbind("change",f),l&&h!==t?(s.one("change",p),s.page(h)):(o.refresh(),p()))}return l?(s.bind("change",f),s.page(1)):f(),a.promise()},_i.prototype.toggleUnexportableColumns=function(e,t){for(var n,i,r,o,a=e.length,s=0;s<a;s++)i=(n=e[s]).exportable,t?n._toggledDuringExport?(n._toggledDuringExport=!1,n.hidden?this.showColumn(n):this.hideColumn(n)):n.columns&&this.toggleUnexportableColumns(n.columns,t):("object"==typeof n.exportable&&(i=n.exportable.pdf),r=!n.hidden&&!1!==i,o=n.hidden&&!0===i,(i=r||o)||n.hidden?i&&n.hidden?(n._toggledDuringExport=!0,this.showColumn(n)):i&&n.columns&&this.toggleUnexportableColumns(n.columns):(n._toggledDuringExport=!0,this.hideColumn(n)))},_i.prototype._drawPDF=function(i){var r=this;if(r.options.pdf.paperSize&&r.options.pdf.paperSize!=Ze)return r._drawPDF_autoPageBreak(i);var o=new e.Deferred,a=r.dataSource,s=r.options.pdf.allPages,l=new n.drawing.Group,c=a.page();function d(){r.toggleUnexportableColumns(r.columns),r._drawPDFShadow({width:r.wrapper.width()},{avoidLinks:r.options.pdf.avoidLinks}).done((function(e){var n=a.page(),u=s?a.totalPages():1,h={page:e,pageNumber:n,progress:n/u,totalPages:u};r.toggleUnexportableColumns(r.columns,!0),i.notify(h),l.append(h.page),n<u?a.page(n+1):s&&c!==t?(a.unbind("change",d),a.one("change",(function(){o.resolve(l)})),a.page(c)):o.resolve(l)})).fail((function(e){o.reject(e)}))}return s?(a.bind("change",d),a.page(1)):d(),o.promise()}),i.plugin(_i),i.plugin(Jt),f(n.ui.grid,{defaultBodyContextMenu:Qt,defaultHeadContextMenu:Xt,defaultGroupsContextMenu:Zt})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i="change",r="cancel",o="dataBound",a="dataBinding",s=n.ui.Widget,l=n.keys,c=()=>"",d="> *:not(.k-loading-mask)",u="progress",h="error",p="k-focus",f="k-selected",m="k-edit-item",g="k-listview-pager",v="k-listview-item",_="role",b="aria-label",y="aria-multiselectable",w="aria-activedescendant",k="edit",x="remove",C="save",S="touchstart",T=".kendoListView",D=n._activeElement,A=n.ui.progress,M=n.data.DataSource,E=n.ui.DataBoundWidget.extend({init:function(e,t){var i=this;t=Array.isArray(t)?{dataSource:t}:t,s.fn.init.call(i,e,t),t=i.options,i.wrapper=e=i.element,e[0].id?i._itemId=e[0].id+"_lv_active":i._itemId=n.guid()+"_lv_active",i._element(),i._layout(),i._dataSource(),i._setContentHeight(),i._templates(),i._navigatable(),i._selectable(),i._pageable(),i._crudHandlers(),i._scrollable(),i.options.autoBind&&i.dataSource.fetch(),n.notify(i)},events:[i,r,a,o,k,x,C,"kendoKeydown"],options:{name:"ListView",ariaLabel:null,autoBind:!0,selectable:!1,navigatable:!1,pageable:!1,height:null,template:c,altTemplate:null,editTemplate:null,contentTemplate:()=>"<div data-content='true' />",contentElement:"div",bordered:!0,borders:"",layout:"",flex:{direction:"row",wrap:"nowrap"},grid:{},scrollable:!1},setOptions:function(e){s.fn.setOptions.call(this,e),this._layout(),this._templates(),this.selectable&&(this.selectable.destroy(),this.selectable=null),this._selectable()},_templates:function(){var e=this.options;this.template=n.template(e.template||c),this.altTemplate=n.template(e.altTemplate||e.template||c),this.editTemplate=n.template(e.editTemplate||c)},_item:function(e){return this.content.children()[e]()},items:function(){return this.content.children(":not(.k-loading-mask)")},dataItem:function(t){var i=n.attr("uid"),r=e(t).closest("["+i+"]").attr(i);return this.dataSource.getByUid(r)},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this._pageable(),this.options.autoBind&&e.fetch(),"endless"===this.options.scrollable&&this._bindScrollable()},_unbindDataSource:function(){var e=this;e.dataSource.unbind(i,e._refreshHandler).unbind(u,e._progressHandler).unbind(h,e._errorHandler)},_dataSource:function(){var n=this,r=n.options.pageable,o=n.options.dataSource||{};e.isPlainObject(r)&&r.pageSize!==t&&(o.pageSize=r.pageSize),n.dataSource&&n._refreshHandler?n._unbindDataSource():(n._refreshHandler=n.refresh.bind(n),n._progressHandler=n._progress.bind(n),n._errorHandler=n._error.bind(n)),n.dataSource=M.create(o).bind(i,n._refreshHandler).bind(u,n._progressHandler).bind(h,n._errorHandler)},_progress:function(e){var t=this.wrapper;e&&this.content.height()&&(t=this.content),A(t,e,{opacity:!0})},_error:function(){A(this.content,!1)},_element:function(){var t=this.options,n=t.height;this.element.addClass("k-listview"),t.contentElement?this.content=e(document.createElement(t.contentElement)).appendTo(this.element):this.content=this.element,n&&this.element.css("height",n)},_layout:function(){var e=this,n=e.options,i=n.flex,r=n.grid,o=e.element,a=["k-listview"],s=e.content,l=["k-listview-content"];o.add(s).removeClass((function(e,t){if(t.indexOf("k-")>=0)return!0})),!0===n.bordered&&a.push("k-listview-bordered"),"string"==typeof n.borders&&""!==n.borders&&a.push("k-listview-borders-"+n.borders),"string"==typeof n.contentPadding&&""!==n.contentPadding&&l.push("k-listview-content-padding-"+n.contentPadding),"string"==typeof n.layout&&""!==n.layout&&l.push("k-d-"+n.layout),"flex"===n.layout&&"object"==typeof i&&("string"==typeof i.direction&&""!==i.direction&&l.push("k-flex-"+i.direction),"string"==typeof i.wrap&&""!==i.wrap&&l.push("k-flex-"+i.wrap)),"grid"===n.layout&&"object"==typeof r&&("number"==typeof r.cols?s.css("grid-template-columns","repeat("+r.cols+", 1fr)"):"string"==typeof r.cols&&s.css("grid-template-columns",r.cols),"number"==typeof r.rows?s.css("grid-template-rows","repeat("+r.rows+", "+(r.rowHeight!==t?r.rowHeight:"1fr")+")"):"string"==typeof r.rows&&s.css("grid-template-rows",r.rows),("number"==typeof r.gutter||"string"==typeof r.gutter)&&s.css("grid-gap",r.gutter)),e.element.addClass(a.join(" ")),e.content.addClass(l.join(" "))},_setContentHeight:function(){var e,t=this;t.options.scrollable&&t.wrapper.is(":visible")&&(e=t.wrapper.innerHeight(),t.content.height(e))},refresh:function(e){var t,i,r,s,l,c=this,d=c.dataSource.view(),u="",h=c.template,p=c.altTemplate,f=c.options.selectable?"option":"listitem",m=D(),g=c._endlessFetchInProgress,b=g?c._skipRerenderItemsCount:0,y=c.options.scrollable;if("itemchange"!==(e=e||{}).action){if(!c.trigger(a,{action:e.action||"rebind",items:e.items,index:e.index})){for(g||c._destroyEditable(),s=b,l=d.length;s<l;s++)u+=s%2?p(d[s]):h(d[s]);for(g?c.content.append(u):c.content.html(u),i=c.items().not(".k-loading-mask"),c._ariaAttributes(d.length),s=b,l=d.length;s<l;s++)(r=i.eq(s)).addClass(v),r.attr(n.attr("uid"),d[s].uid).attr(_,f),c.options.selectable&&r.attr("aria-selected","false"),c.options.pageable&&(r.attr("aria-setsize",c.dataSource.total()),r.attr("aria-posinset",c.dataSource.indexOf(c.dataItem(r))+1));c.content[0]===m&&c.options.navigatable&&(c._focusNext?c.current(c.current().next()):y||c.current(i.eq(0))),c.element.attr(w)&&0===c.element.find("#"+c.element.attr(w)).length&&c.element.removeAttr(w),c._setContentHeight(),c._progress(!1),c._endlessFetchInProgress=null,c.trigger(o,{action:e.action||"rebind",items:e.items,index:e.index})}}else c._hasBindingTarget()||c.editable||(t=e.items[0],(r=c.items().filter("["+n.attr("uid")+"="+t.uid+"]")).length>0&&(s=r.index(),r.replaceWith(h(t)),(r=c.items().eq(s)).attr(n.attr("uid"),t.uid),c.trigger("itemChange",{item:r,data:t})))},_ariaAttributes:function(e){var t=this.content,i=this.options.selectable;this._ariaLabelValue=this._ariaLabelValue||this.options.ariaLabel,0===e?(t.removeAttr(_),t.removeAttr(y),t.attr(b)&&(this._ariaLabelValue=t.attr(b),t.removeAttr(b))):(t.attr(_,i?"listbox":"list"),i&&n.ui.Selectable.parseOptions(i).multiple&&t.attr(y,!0),this._ariaLabelValue&&t.attr(b,this._ariaLabelValue))},_pageable:function(){var t,i,r=this,o=r.options.pageable,a=r.options.navigatable;o&&((t=r.wrapper.find("."+g)).length||(t=e("<div />").addClass(g)),"top"===o.position?t.addClass(n.format("{0}-{1}",g,o.position)).prependTo(r.wrapper):t.appendTo(r.wrapper),r.pager&&r.pager.destroy(),"object"==typeof o&&o instanceof n.ui.Pager?r.pager=o:(t=o.pagerId?e("#"+o.pagerId):t,i=e.extend({},o,{dataSource:r.dataSource,navigatable:a,pagerId:null}),r.pager=new n.ui.Pager(t,i)))},_selectable:function(){var t,r,o=this,a=o.options.selectable,s=o.options.navigatable;a&&(t=n.ui.Selectable.parseOptions(a).multiple,o.selectable=new n.ui.Selectable(o.element,{aria:!0,multiple:t,filter:o.options.contentElement?".k-listview-content "+d:d,change:function(){o.trigger(i)}}),s&&o.element.on("keydown"+T,(function(n){if(e(n.target).is(o.element)&&n.keyCode===l.SPACEBAR){if(r=o.current(),n.target==n.currentTarget&&n.preventDefault(),t)if(n.ctrlKey){if(r&&r.hasClass(f))return r.removeClass(f),void o.trigger(i)}else o.selectable.clear();else o.selectable.clear();o.selectable.value(r),o.trigger(i)}})))},_scrollable:function(){var e=this,t=e.options.scrollable;t&&(e.content.css({"overflow-y":"scroll",position:"relative","-webkit-overflow-scrolling":"touch"}),"endless"===t&&e._bindScrollable())},_bindScrollable:function(){var e=this,t=e._endlessPageSize=e.dataSource.options.pageSize;e.content.off("scroll"+T).on("scroll"+T,(function(){this.scrollTop+this.clientHeight-this.scrollHeight>=-15&&!e._endlessFetchInProgress&&e._endlessPageSize<e.dataSource.total()&&(e._skipRerenderItemsCount=e._endlessPageSize,e._endlessPageSize=e._skipRerenderItemsCount+t,e.dataSource.options.endless=!0,e._endlessFetchInProgress=!0,e.dataSource.pageSize(e._endlessPageSize))}))},current:function(e){var n=this,i=n.element,r=n._current,o=n._itemId;if(e===t)return r;r&&r[0]&&(r[0].id===o&&r.removeAttr("id"),r.removeClass(p),i.removeAttr(w)),e&&e[0]&&(o=e[0].id||o,n._scrollTo(e[0]),i.attr(w,o),e.addClass(p).attr("id",o)),n._current=e},_scrollTo:function(t){var n,i=this.content,r=!1,o="scroll";"auto"===i.css("overflow")||i.css("overflow")===o||i.css("overflow-y")===o?n=i[0]:(n=window,r=!0);var a=function(i,a){var s=r?e(t).offset()[i.toLowerCase()]:t["offset"+i],l=t["client"+a],c=e(n)[o+i](),d=e(n)[a.toLowerCase()]();s+l>c+d?e(n)[o+i](s+l-d):s<c&&e(n)[o+i](s)};a("Top","Height"),a("Left","Width")},_navigatable:function(){var t=this,i=t.options.navigatable,r=t.element,o=t.content;i&&(t._tabindex(),r.on("focus"+T,(function(){var e=t._current;e&&e.is(":visible")||(e=t._item("first")),t.current(e)})).on("focusout"+T,(function(){t._current&&t._current.removeClass(p)})).on("keydown"+T,t,(function(i){var r,a=i.keyCode,s=t.current(),c=e(i.target),d=!c.is(":button, textarea, a, a > .t-icon, input"),u=c.is(":text, :password"),h=n.preventDefault,p=o.find("."+m),f=D(),v=t.options.scrollable;if(!(c.hasClass(g)||!d&&!u&&a!==l.ESC||u&&a!==l.ESC&&a!==l.ENTER)){if(a!==l.UP&&a!==l.LEFT||(s&&s[0]&&(s=s.prev()),s&&s[0]?t.current(s):v||t.current(t._item("last")),h(i)),a!==l.DOWN&&a!==l.RIGHT||(v?"endless"!==t.options.scrollable||s.next().length?(s=s.next())&&s[0]&&t.current(s):(t.content[0].scrollTop=t.content[0].scrollHeight,t._focusNext=!0):(s=s.next(),t.current(s&&s[0]?s:t._item("first"))),h(i)),a===l.PAGEUP&&(t.current(null),t.dataSource.page(t.dataSource.page()-1),h(i)),a===l.PAGEDOWN&&(t.current(null),t.dataSource.page(t.dataSource.page()+1),h(i)),a===l.HOME&&(t.current(t._item("first")),h(i)),a===l.END&&(t.current(t._item("last")),h(i)),a===l.ENTER)if(0!==p.length&&(d||u)){r=t.items().index(p),f&&f.blur(),t.save();t.one("dataBound",(function(){t.element.trigger("focus"),t.current(t.items().eq(r))}))}else t.options.editTemplate&&t.edit(s);if(a===l.ESC){if(0===(p=o.find("."+m)).length)return;r=t.items().index(p),t.cancel(),t.element.trigger("focus"),t.current(t.items().eq(r))}}})),r.on("mousedown"+T+" "+S+T,t.options.contentElement?".k-listview-content "+d:d,function(i){t.current(e(i.currentTarget)),e(i.target).is(":button, a, :input, a > .k-icon, a > k-svg-icon, textarea")||n.focusElement(r)}.bind(t)))},clearSelection:function(){this.selectable.clear()},select:function(t){var n=this.selectable;return(t=e(t)).length?(n.options.multiple||(n.clear(),t=t.first()),void n.value(t)):n.value()},_destroyEditable:function(){var e=this;e.editable&&(e.editable.destroy(),delete e.editable)},_modelFromElement:function(e){var t=e.attr(n.attr("uid"));return this.dataSource.getByUid(t)},_closeEditable:function(){var e,t,i,r=this,o=r.editable,a=r.options.selectable?"option":"listitem",s=r.template;return o&&(o.element.index()%2&&(s=r.altTemplate),e=r._modelFromElement(o.element),r._destroyEditable(),i=o.element.index(),o.element.replaceWith(s(e)),(t=r.items().eq(i)).addClass(v),t.attr(n.attr("uid"),e.uid),t.attr(_,a),r._hasBindingTarget()&&n.bind(t,e)),!0},edit:function(e){var t,i,r=this,o=r._modelFromElement(e),a=o.uid;r.cancel(),i=(e=r.items().filter("["+n.attr("uid")+"="+a+"]")).index(),e.replaceWith(r.editTemplate(o)),t=r.items().eq(i).addClass(m).attr(n.attr("uid"),o.uid),r.editable=t.kendoEditable({model:o,clearContainer:!1,errorTemplate:!1,target:r}).data("kendoEditable"),r.trigger(k,{model:o,item:t})},save:function(){var e,t=this,n=t.editable;if(n){var i=n.element;e=t._modelFromElement(i),n.end()&&!t.trigger(C,{model:e,item:i})&&(t._closeEditable(),t.dataSource.sync())}},remove:function(e){var t=this,n=t.dataSource,i=t._modelFromElement(e);t.editable&&(n.cancelChanges(t._modelFromElement(t.editable.element)),t._closeEditable()),t.trigger(x,{model:i,item:e})||(e.attr("id")===t.element.attr(w)&&t.element.removeAttr(w),e.hide(),n.remove(i),n.sync())},add:function(){var e,t=this,n=t.dataSource,i=n.indexOf((n.view()||[])[0]);i<0&&(i=0),t.cancel(),e=n.insert(i,{}),t.edit(t.element.find("[data-uid='"+e.uid+"']"))},cancel:function(){var e=this,t=e.dataSource;if(e.editable){var n=e.editable.element,i=e._modelFromElement(n);e.trigger(r,{model:i,container:n})||(t.cancelChanges(i),e._closeEditable())}},_crudHandlers:function(){var t=this,i=S+T,r="click"+T;t.content.on(i+" "+r,".k-edit-button",(function(i){i.preventDefault();var r=e(this).closest("["+n.attr("uid")+"]");setTimeout((function(){t.edit(r)}))})),t.content.on(i+" "+r,".k-delete-button",(function(i){i.preventDefault();var r=e(this).closest("["+n.attr("uid")+"]");setTimeout((function(){t.remove(r)}))})),t.content.on(r,".k-update-button",(function(e){t.save(),e.preventDefault()})),t.content.on(r,".k-cancel-button",(function(e){t.cancel(),e.preventDefault()}))},destroy:function(){var e=this;s.fn.destroy.call(e),e._unbindDataSource(),e._destroyEditable(),e.element.off(T),e.content.off(T),e._endlessFetchInProgress=e._endlessPageSize=e._skipRerenderItemsCount=e._focusNext=null,e.pager&&e.pager.destroy(),n.destroy(e.element)}});n.ui.plugin(E)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.attr,r=n.data,o=n.keys,a=n.template,s=n.ui.Widget,l=r.DataSource,c=n.ui.Selectable,d=n.ui.DataBoundWidget,u=n.Class,h=e.extend,p=e.noop,f="-",m="kendoListBox",g="."+m,v="k-disabled",_="k-selected",b=".k-list-item:not(.k-disabled)",y=".k-list-ul:not(.k-disabled) >"+b,w="k-listbox-actions",k=".k-button",x="k-focus",C="click"+g,S="keydown"+g,T="blur"+g,D=n._outerWidth,A=n._outerHeight,M="change",E="dataBound",I="add",z="remove",P="reorder",H="moveUp",F="moveDown",R="transferTo",L="transferFrom",B="transferAllTo",O="transferAllFrom",V="caret-alt-right",N="caret-alt-left",$="caret-double-alt-right",U="caret-double-alt-left",W="k-ghost",j="id",q="tabindex",G="dragstart",K="drag",Y="drop",Q="dragend",X="right",Z="aria-activedescendant",J="aria-busy",ee="aria-label",te=[w+f+"left",w+f+X,w+f+"top",w+f+"bottom"];function ne(t){return e.map(t,(function(t){return e(t).index()}))}function ie(e){return void 0===e}function re(e){return e.clone().attr("class","").addClass("k-drag-clue")}function oe(){return e("<li>").addClass("k-drop-hint")}var ae=d.extend({init:function(e,t){var n=this;s.fn.init.call(n,e,t),n._wrapper(),n._list(),n._ariaLabel(n._getList()),(e=n.element.attr("multiple","multiple").hide())[0]&&!n.options.dataSource&&(n.options.dataTextField=n.options.dataTextField||"text",n.options.dataValueField=n.options.dataValueField||"value"),n._templates(),n._selectable(),n._dataSource(),n._createToolbar(),n._createDraggable(),n._createNavigatable()},destroy:function(){var e=this;d.fn.destroy.call(e),isNaN(e._listTabIndex)||(e._getList().off(),e._listTabIndex=null),e._unbindDataSource(),e._destroySelectable(),e._destroyToolbar(),e.wrapper.off(g),e._target&&(e._target=null),e._draggable&&(e._draggable.destroy(),e.placeholder=null),n.destroy(e.element)},setOptions:function(e){s.fn.setOptions.call(this,e),this._templates(),this._dataSource()},events:[M,E,I,z,P,G,K,Y,Q],options:{name:"ListBox",autoBind:!0,template:"",dataTextField:"",dataValueField:"",selectable:"single",draggable:null,dropSources:[],connectWith:"",navigatable:!0,toolbar:{position:X,tools:[]},messages:{tools:{remove:"Delete",moveUp:"Move Up",moveDown:"Move Down",transferTo:"Transfer To",transferFrom:"Transfer From",transferAllTo:"Transfer All To",transferAllFrom:"Transfer All From"}}},add:function(e){var t,n=this,i=e&&e.length?e:[e],r=i.length,o=n._getList();for(n._unbindDataSource(),n._unbindDataChange(),t=0;t<r;t++)n._addItem(i[t],o);n._bindDataChange(),n._bindDataSource(),n._syncElement()},_addItem:function(t,n){var i=this,r=e(i.templates.itemTemplate({item:t,r:i.templates.itemContent}));i._setItemId(r,t.uid),r.appendTo(n),"string"==typeof t?i.dataSource._data.push(t):i.dataSource.add(t)},_addItemAt:function(t,n){var i=this,r=e(i.templates.itemTemplate({item:t,r:i.templates.itemContent}));i._unbindDataSource(),"string"==typeof t?(i._insertElementAt(r,n),i.dataSource._data.push(t)):(i._setItemId(r,t.uid),i._insertElementAt(r,n),i.dataSource.add(t)),i._bindDataSource(),i._syncElement()},_insertElementAt:function(t,n){var i=this._getList();n>0?e(t).insertAfter(i.children().eq(n-1)):e(i).prepend(t)},_createNavigatable:function(){var e=this;e.options.navigatable&&e._getList().on(C,b,e._click.bind(e)).on(S,e._keyDown.bind(e)).on(T,e._blur.bind(e))},_getTabIndex:function(){var e,t=this;return isNaN(t._listTabIndex)?(e=t.element.attr(q),t._listTabIndex=isNaN(e)?0:e,t.element.removeAttr(q),t._listTabIndex):t._listTabIndex},_blur:function(){this._target&&(this._target.removeClass(x),this._getList().removeAttr(Z)),this._target=null},_click:function(t){var i=this,r=e(t.currentTarget),o=i._target,a=i._getList(),s=n._activeElement(),l=e.contains(a,s);o&&o.removeClass(x),i._target=r,r.addClass(x),a.attr(Z,r.attr(j)),a[0]===s||l&&function(t){return e(t).is(":button,a,:input,a>.k-icon,a>.k-svg-icon,textarea,span.k-select,span.k-icon,span.k-svg-icon,span.k-link,label.k-checkbox-label,.k-input,.k-multiselect-wrap,.k-picker-wrap,.k-picker-wrap>.k-selected-color,.k-tool-icon,.k-dropdownlist")}(s)||i.focus()},_getNavigatableItem:function(e){var t,n=this;return t=n._target?n._target:n.items().filter(b).first(),e===o.UP&&n._target&&(t=n._target.prevAll(b).first()),e===o.DOWN&&n._target&&(t=n._target.nextAll(b).first()),t.length?t:null},_scrollIntoView:function(e){if(e){e[0]&&(e=e[0]);var t=this._getList().parent()[0],n=e.offsetTop,i=t.scrollTop,r=t.clientHeight,o=n+e.offsetHeight;i>n?i=n:o>i+r&&(i=o-r),t.scrollTop=i}},_keyDown:function(e){var t,n=this,i=e.keyCode,r=n._getNavigatableItem(i);if((!e.shiftKey||e.ctrlKey||i!==o.DOWN&&i!==o.UP)&&(n._shiftSelecting=!1),i==o.DELETE)n._executeCommand(z),n._target&&(n._target.removeClass(x),n._getList().removeAttr(Z),n._target=null),t=!0;else if(i===o.DOWN||i===o.UP){if(!r)return void e.preventDefault();if(e.shiftKey&&!e.ctrlKey)n._target&&n._target.removeClass(x),n._shiftSelecting||(n.clearSelection(),n._shiftSelecting=!0),n._target&&r.hasClass("k-selected")?n._target.removeClass(_):"single"==n.options.selectable?n.select(r):n.select(r.add(n._target)),n._updateToolbar(),n._updateAllToolbars(),n.trigger(M);else{if(e.shiftKey&&e.ctrlKey)return n._executeCommand(i===o.DOWN?F:H),n._scrollIntoView(n._target),void e.preventDefault();e.shiftKey||e.ctrlKey||(n._target&&n._target.removeClass(x),"multiple"===n.options.selectable&&n.clearSelection(),n.select(r),n._updateToolbar(),n._updateAllToolbars(),n.trigger(M))}r&&n._target&&n._target[0]!==r[0]&&n._target.removeClass(x),n._target=r,n._target?(n._target.addClass(x),n._scrollIntoView(n._target),n._getList().attr(Z,n._target.attr(j))):n._getList().removeAttr(Z),t=!0}else i==o.SPACEBAR?(e.ctrlKey&&n._target?(n._target.hasClass(_)?n._target.removeClass(_):n.select(n._target),n.trigger(M)):(n.clearSelection(),n.select(n._target),n.trigger(M)),n._updateToolbar(),n._updateAllToolbars(),t=!0):e.ctrlKey&&i==o.RIGHT?(e.shiftKey?n._executeCommand(B):n._executeCommand(R),n._target=n.select().length?n.select():null,t=!0):e.ctrlKey&&i==o.LEFT?(e.shiftKey?n._executeCommand(O):n._executeCommand(L),t=!0):i===o.F10&&n.toolbar&&(n.toolbar.element.find(k).not("[tabindex=-1]").trigger("focus"),t=!0);t&&e.preventDefault()},focus:function(){n.focusElement(this._getList())},_createDraggable:function(){var t,i=this,r=i.options.draggable;if(r){if(t=r.hint,!i.options.selectable)throw new Error("Dragging requires selection to be enabled");t||(t=re),i._draggable=new n.ui.Draggable(i.wrapper,{filter:r.filter?r.filter:"ul.k-list-ul>li.k-list-item",hint:n.isFunction(t)?t:e(t),dragstart:i._dragstart.bind(i),dragcancel:i._clear.bind(i),drag:i._drag.bind(i),dragend:i._dragend.bind(i)})}},_dragstart:function(t){var i=this,r=i.draggedElement=t.currentTarget,o=i.options.draggable.placeholder,a={dataItems:i.dataItem(r),items:e(r),draggableEvent:t};!1!==i.options.draggable.enabled?(o||(o=oe),i.placeholder=n.isFunction(o)?e(o.call(i,r)):e(o),r.is("."+v)||i.trigger(G,a)?t.preventDefault():(i.clearSelection(),i.select(r),r.addClass(W))):t.preventDefault()},_clear:function(){this.draggedElement.removeClass(W),this.placeholder.remove()},_findElementUnderCursor:function(t){var i=n.elementUnderCursor(t),r=t.sender;return(e.contains(r.hint[0],i)||r.hint[0]===i)&&(r.hint.hide(),i=n.elementUnderCursor(t),r.hint.show()),i},_findTarget:function(t){var n,i,r=this,o=r._findElementUnderCursor(t),a=e(o),s=r._getList();return e.contains(s[0],o)?(n=r.items(),o=a.is("li")?o:a.closest("li")[0],(i=n.filter(o)[0]||n.has(o)[0])?(i=e(i)).hasClass(v)?null:{element:i,listBox:r}:null):s[0]==o||s.parent()[0]==o?{element:e(s),appendToBottom:!0,listBox:r}:r._searchConnectedListBox(a)},_getElementCenter:function(e){var t=e.length?n.getOffset(e):null;return t&&(t.top+=A(e)/2,t.left+=D(e)/2),t},_searchConnectedListBox:function(t){var n,i,r,o,a=t;return(o=t.hasClass("k-list-scroller k-selectable")?t:t.closest(".k-list-scroller.k-selectable")).length&&(n=o.parent().find("[data-role='listbox']").getKendoListBox())&&-1!==e.inArray(this.element[0].id,n.options.dropSources)?(i=n.items(),t=t.is("li")?t[0]:t.closest("li")[0],(r=i.filter(t)[0]||i.has(t)[0])?(r=e(r)).hasClass(v)?null:{element:r,listBox:n}:!i.length||a.hasClass("k-list-scroller k-selectable")||a.hasClass("k-list-content")?{element:n._getList(),listBox:n,appendToBottom:!0}:null):null},_drag:function(t){var n,i,r,o=this,a=o.draggedElement,s=o._findTarget(t),l=t.x.location,c=t.y.location,d={dataItems:[o.dataItem(a)],items:e(a),draggableEvent:t};if(o.trigger(K,d))t.preventDefault();else if(s){if(n=this._getElementCenter(s.element),i={left:Math.round(l-n.left),top:Math.round(c-n.top)},s.appendToBottom)return void o._movePlaceholder(s,null,a);i.top<0?r="prev":i.top>0&&(r="next"),r&&s.element[0]!=o.placeholder[0]&&o._movePlaceholder(s,r,a)}else o.placeholder.parent().length&&o.placeholder.remove()},_movePlaceholder:function(t,i,r){var o=this,a=o.placeholder,s=t.listBox.options.draggable;a.parent().length&&(o.placeholder.remove(),s&&s.placeholder?o.placeholder=n.isFunction(s.placeholder)?e(s.placeholder.call(o,r)):e(s.placeholder):o.placeholder=e(oe.call(o,r))),i?"prev"===i?t.element.before(o.placeholder):"next"===i&&t.element.after(o.placeholder):t.element.append(o.placeholder)},_dragend:function(t){var n=this,i=n.draggedElement,r=n.items(),o=r.not(n.draggedElement).index(n.placeholder),a=r.not(n.placeholder).index(n.draggedElement),s=n.dataItem(i),l={dataItems:[s],items:e(i)},c=n.placeholder.closest(".k-listbox").find("[data-role='listbox']").getKendoListBox();if(n.trigger(Y,h({},l,{draggableEvent:t})))return t.preventDefault(),void this._clear();o>=0?o===a||n.trigger(P,h({},l,{offset:o-a}))||(i.removeClass(W),n.reorder(i,o)):c&&(n.trigger(z,l)||n.remove(e(i)),c.trigger(I,l)||c._addItemAt(s,c.items().index(n.placeholder))),n._clear(),n._draggable.dropped=!0,n.trigger(Q,h({},l,{draggableEvent:t})),n._updateToolbar(),n._updateAllToolbars()},reorder:function(t,n){var i=this,r=i.dataSource,o=i.dataItem(t),a=r.at(n),s=i.items()[n],l=e(t);o&&s&&a&&(i._removeElement(l),i._insertElementAt(l,n),i._updateToolbar())},remove:function(t){var n,i=this,r=i._getItems(t),o=r.length;for(i._unbindDataSource(),i._unbindDataChange(),n=0;n<o;n++)i._removeItem(e(r[n]));i._bindDataChange(),i._bindDataSource(),i._syncElement(),i._updateToolbar(),i._updateAllToolbars()},_removeItem:function(e){var t=this,n=t.dataSource,i=t.dataItem(e),r=n.transport;if(i&&n){if("string"==typeof i){for(var o=n._data,a=0;a<o.length;a++)if(i===o[a]){o[a]=o[o.length-1],o.pop();break}}else n.remove(i),!r||!r.destroy&&!(r.options||{}).destroy||i.isNew&&i.isNew()||n._destroyed.push(i);t._removeElement(e)}},_removeElement:function(t){n.destroy(t),e(t).off().remove()},dataItem:function(t){var n=i("uid"),r=e(t).attr(n)||e(t).closest("["+n+"]").attr(n);return r?this.dataSource.getByUid(r):e(t).find(".k-list-item-text").html()},_dataItems:function(t){var n,i=[],r=e(t),o=r.length;for(n=0;n<o;n++)i.push(this.dataItem(r.eq(n)));return i},items:function(){return this._getList().children()},select:function(e){const t=this,n=t.selectable;let i;if(ie(e))return n.value();i=t.items().filter(e).filter(y),n.options.multiple||(n.clear(),i=i.first());const r=n.value(i);return t._updateAllToolbars(),r},clearSelection:function(){const e=this.selectable;e&&e.clear(),this._updateAllToolbars()},enable:function(t,n){var i,r=this,o=!!ie(n)||!!n,a=r._getItems(t),s=a.length;for(i=0;i<s;i++)r._enableItem(e(a[i]),o);r._updateAllToolbars()},_enableItem:function(t,n){this.dataItem(t)&&(n?e(t).removeClass(v):e(t).addClass(v).removeClass(_))},setDataSource:function(e){this.options.dataSource=e,this._dataSource()},_dataSource:function(){var e=this,t=e.options,n=t.dataSource||{};(n=Array.isArray(n)?{data:n}:n).select=e.element,n.fields=[{field:t.dataTextField},{field:t.dataValueField}],e._unbindDataSource(),e.dataSource=l.create(n),e._bindDataSource(),e.options.autoBind&&(e.wrapper.attr(J,!0),e.dataSource.fetch())},_bindDataChange:function(){var e=this.dataSource;e._data&&e._changeHandler&&(e._data.bind(M,e._changeHandler),e._data.trigger(M))},_unbindDataChange:function(){var e=this.dataSource;e._data&&e._changeHandler&&e._data.unbind(M,e._changeHandler)},_bindDataSource:function(){var e=this,t=e.dataSource;e._dataChangeHandler=e.refresh.bind(e),t&&t.bind(M,e._dataChangeHandler)},_unbindDataSource:function(){var e=this.dataSource;e&&e.unbind(M,this._dataChangeHandler)},_wrapper:function(){var t=this,n=t.element,i=n.parent("div.k-listbox");i[0]||((i=n.wrap('<div class="k-listbox" unselectable="on" />').parent())[0].style.cssText=n[0].style.cssText,i[0].title=n[0].title,e('<div class="k-list-scroller"><div class="k-list k-list-md"><div class="k-list-content"></div></div></div>').insertBefore(n)),t.wrapper=i.addClass(n[0].className).css("display",""),t._innerWrapper=e(i[0].firstChild)},_list:function(){var t=this,n=e("<ul class='k-list-ul' role='listbox'></ul>"),i=t.options.selectable;c.parseOptions(i).multiple&&n.attr("aria-multiselectable","true"),n.appendTo(t.wrapper.find(".k-list-content")),t.options.navigatable&&t._getList().attr(q,t._getTabIndex())},_templates:function(){var e,t=this.options;e=t.template&&"string"==typeof t.template?n.template(t.template):t.template?t.template:n.template((e=>`${n.getter(t.dataTextField)(e)}`)),this.templates={itemTemplate:n.template((({item:e,r:t})=>`<li class='k-list-item' role='option' aria-selected='false'><span class='k-list-item-text'>${t(e)}</span></li>`)),itemContent:e,toolbar:`<div role='toolbar' class='${w}'></div>`}},refresh:function(){for(var e=this,t=e.dataSource.view(),n=e.templates.itemTemplate,i="",r=0;r<t.length;r++)i+=n({item:t[r],r:e.templates.itemContent});e._getList().html(i),e._setItemIds(),e.toolbar||e._createToolbar(),e._syncElement(),e._updateToolbar(),e._updateAllToolbars(),e.trigger(E),e.wrapper.attr(J,!1)},_syncElement:function(){for(var e="",t=this.dataSource.view(),n=0;n<t.length;n++)e+=this._option(t[n][this.options.dataValueField]||t[n],t[n][this.options.dataTextField]||t[n],!0);this.element.html(e)},_option:function(e,i){var r="<option";return e!==t&&(-1!==(e+="").indexOf('"')&&(e=e.replace(/"/g,"&quot;")),r+=' value="'+e+'"'),r+=" selected>",i!==t&&(r+=n.htmlEncode(i)),r+"</option>"},_setItemId:function(e,t){e.length&&e.attr(i("uid"),t).attr(j,t)},_setItemIds:function(){var e,t=this,n=t.items(),i=t.dataSource.view(),r=i.length;for(e=0;e<r;e++)t._setItemId(n.eq(e),i[e].uid)},_selectable:function(){var e=this,t=e.options.selectable,n=c.parseOptions(t);e.selectable=new c(e._innerWrapper,{aria:!0,selectedClass:"k-selected",multiple:n.multiple,filter:b,change:e._onSelect.bind(e)})},_onSelect:function(){var e=this;e._updateToolbar(),e._updateAllToolbars(),e.trigger(M)},_destroySelectable:function(){var e=this;e.selectable&&e.selectable.element&&(e.selectable.destroy(),e.selectable=null)},_getList:function(){return this.wrapper.find(".k-list-ul")},_getItems:function(e){return this.items().filter(e)},_createToolbar:function(){var t=this,n=t.options.toolbar,i=n.position||X,r=n.tools||[],o=t.options.messages;if(t._destroyToolbar(),t.wrapper.removeClass(te.join(" ")),r.length&&r.length>0){var a=e(t.templates.toolbar).insertBefore(t._innerWrapper);t.toolbar=new _e(a,h({},n,{listBox:t,messages:o})),t.wrapper.addClass(w+f+i)}},_destroyToolbar:function(){var e=this;e.toolbar&&(e.toolbar.destroy(),e.toolbar=null)},_executeCommand:function(e){var t=this,n=se.current.create(e,{listBox:t});n&&(n.execute(),t._updateToolbar(),t._updateAllToolbars())},_updateToolbar:function(){var e=this.toolbar;e&&e._updateToolStates()},_updateAllToolbars:function(){var t,n,i=e("select[data-role='listbox']"),r=i.length;for(n=0;n<r;n++)(t=e(i[n]).data(m))&&t._updateToolbar()}});n.ui.plugin(ae);var se=u.extend({init:function(){this._commands=[]},register:function(e,t){this._commands.push({commandName:e,commandType:t})},create:function(e,t){var n,i,r,o=this._commands,a=o.length,s=e?e.toLowerCase():"";for(r=0;r<a;r++)if((i=o[r]).commandName.toLowerCase()===s){n=i;break}if(n)return new n.commandType(t)}});se.current=new se;var le=u.extend({init:function(e){var t=this;t.options=h({},t.options,e),t.listBox=t.options.listBox},options:{listBox:null},getItems:function(){return e(this.listBox.select())},execute:p,canExecute:p}),ce=le.extend({execute:function(){var e=this.listBox,t=this.getItems();e.trigger(z,{dataItems:e._dataItems(t),items:t})||e.remove(t)},canExecute:function(){return this.listBox.select().length>0}});se.current.register(z,ce);var de=le.extend({execute:function(){this.canExecute()&&this.moveItems()},canExecute:p,moveItems:function(){var t,n=this,i=n.listBox,r=n.options,o=n.getItems(),a=r.offset,s=ne(o),l=e.makeArray([].sort.call(o,n.itemComparer)),c=r.moveAction;if(!i.trigger(P,{dataItems:i._dataItems(l),items:e(l),offset:a}))for(;l.length>0&&s.length>0;)t=l[c](),i.reorder(t,s[c]()+a)},options:{offset:0,moveAction:"pop"},itemComparer:function(t,n){var i=e(t).index(),r=e(n).index();return i===r?0:i>r?1:-1}}),ue=de.extend({options:{offset:-1,moveAction:"shift"},canExecute:function(){var e=ne(this.getItems());return e.length>0&&e[0]>0}});se.current.register(H,ue);var he=de.extend({options:{offset:1,moveAction:"pop"},canExecute:function(){var t=ne(this.getItems());return t.length>0&&e(t).last()[0]<this.listBox.items().length-1}});se.current.register(F,he);var pe=le.extend({options:{filter:b},execute:function(){var e=this,t=e.getSourceListBox(),n=e.getItems().filter(e.options.filter),i=t?t._dataItems(n):[],r=e.getDestinationListBox(),o=e.getUpdatedSelection(n);r&&n.length>0&&(r.trigger(I,{dataItems:i,items:n})||r.add(i),t.trigger(z,{dataItems:i,items:n})||(t.remove(n),e.updateSelection(o)))},getUpdatedSelection:function(t){if(1!==t.length)return null;var n=this.options.filter,i=this.getSourceListBox(),r=i?i.items().filter(n).last():null,o=e(t).filter(r).length>0?e(t).prevAll(n)[0]:e(t).nextAll(n)[0];return o||null},updateSelection:function(t){var n=this.getSourceListBox();n&&t&&(n.select(e(t)),n.selectable.trigger(M),n._scrollIntoView(t))},getSourceListBox:p,getDestinationListBox:p}),fe=pe.extend({canExecute:function(){var e=this.getSourceListBox();return!!e&&e.select().length>0},getSourceListBox:function(){return this.listBox},getDestinationListBox:function(){var t=this.getSourceListBox();return t&&t.options.connectWith?e("#"+t.options.connectWith).data(m):null},getItems:function(){var t=this.getSourceListBox();return t?e(t.select()):e()}});se.current.register(R,fe);var me=pe.extend({canExecute:function(){var e=this.getSourceListBox();return!!e&&e.select().length>0},getSourceListBox:function(){var t=this.getDestinationListBox();return t&&t.options.connectWith?e("#"+t.options.connectWith).data(m):null},getDestinationListBox:function(){return this.listBox},getItems:function(){var t=this.getSourceListBox();return t?e(t.select()):e()}});se.current.register(L,me);var ge=fe.extend({canExecute:function(){var e=this.getSourceListBox();return!!e&&e.wrapper.find(y).length>0},getItems:function(){var t=this.getSourceListBox();return t?t.items():e()},getUpdatedSelection:p,updateSelection:p});se.current.register(B,ge);var ve=me.extend({canExecute:function(){var e=this.getSourceListBox();return!!e&&e.wrapper.find(y).length>0},getItems:function(){var t=this.getSourceListBox();return t?t.items():e()},getUpdatedSelection:p,updateSelection:p});se.current.register(O,ve);var _e=u.extend({init:function(t,n){var i=this;i.element=e(t).addClass(w),i.options=h({},i.options,n),i.listBox=i.options.listBox,i._initTemplates(),i._createTools(),i._updateToolStates(),i._attachEventHandlers(),i._aria(),i._tabindex()},destroy:function(){var e=this;e._detachEventHandlers(),n.destroy(e.element),e.element.remove(),e.element=null},options:{position:X,tools:[]},_aria:function(){var t=this.listBox._getList(),i=t.attr("aria-labelledby"),r=i?e("#"+i).text():t.attr(ee),o=t.attr("id")||n.guid();t.attr("id",o),this.element.attr("aria-controls",o),r&&this.element.attr(ee,r+" toolbar.")},_attachEventHandlers:function(){var e=this;e.element.on(C,"button.k-button:not(.k-disabled)",e._onToolClick.bind(e)).on(S,e._keyDown.bind(e))},_createTools:function(){var t,i,r=this,o=n.support.isRtl(r.element),a=r.options.tools,s=a.length,l=r.options.messages.tools,c=r.element;for(_e.defaultTools=n.deepExtend({},_e.defaultTools,{transferTo:{icon:o?N:V},transferFrom:{icon:o?V:N},transferAllTo:{icon:o?U:$},transferAllFrom:{icon:o?$:U}}),i=0;i<s;i++)(t=h({},_e.defaultTools[a[i]],{text:l[a[i]]}))&&c.append(e(r.templates.tool(t)));r.element.append(c)},_detachEventHandlers:function(){this.element.off(g).find("*").off(g)},_executeToolCommand:function(e){var t=this.listBox;t&&t._executeCommand(e)},_focusTool:function(){this.element.find(k).not("[tabindex=-1]").trigger("focus")},_initTemplates:function(){this.templates={tool:a((({icon:e,iconClass:t,command:i,text:r})=>n.html.renderButton(`<button data-command='${i}' title='${r}' aria-label='${r}'></button>`,{icon:e,iconClass:t})))}},_keyDown:function(t){var i=t.keyCode,r=e(t.target),o=r.is(k)?r:r.closest("li");i===n.keys.UP||i===n.keys.LEFT?(t.preventDefault(),o.prev().length&&this._tabindex(o.prev()),this._focusTool()):i!==n.keys.DOWN&&i!==n.keys.RIGHT||(t.preventDefault(),o.next()&&this._tabindex(o.next()),this._focusTool())},_onToolClick:function(t){t.preventDefault();var n=e(t.currentTarget);this._tabindex(n),this._executeToolCommand(n.data("command")),this._focusTool()},_tabindex:function(e){var t,n=this.element.find(k);t=e&&e.length?e:n.first(),n.attr(q,-1),t.removeAttr(q)},_updateToolStates:function(){var e,t=this,n=t.options.tools,i=n.length,r=t.element.find(k).not("[tabindex=-1]");for(e=0;e<i;e++)t._updateToolState(n[e]);t._tabindex(r)},_updateToolState:function(e){var t=se.current.create(e,{listBox:this.listBox}),n=this.element.find("[data-command='"+e+"']");n[0]&&t&&t.canExecute&&(t.canExecute()?n.removeClass(v).removeAttr(q):n.addClass(v).attr(q,"-1"))}});_e.defaultTools={remove:{command:z,icon:"x"},moveUp:{command:H,icon:"caret-alt-up"},moveDown:{command:F,icon:"caret-alt-down"},transferTo:{command:R,icon:V},transferFrom:{command:L,icon:N},transferAllTo:{command:B,icon:$},transferAllFrom:{command:O,icon:U}},h(ae,{ToolBar:_e})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r="horizontal",o="vertical",a="k-progressbar",s="k-progressbar-indeterminate",l="k-complete",c="k-selected",d="k-progress-status",u="k-progress-end",h="k-selected",p="k-disabled",f="k-progressbar-value",m="k-progressbar-chunk",g={VALUE:"value",PERCENT:"percent",CHUNK:"chunk"},v="change",_="complete",b=Math,y=e.extend,w={progressStatus:"<span class='k-progress-status-wrap "+u+"'><span class='k-progress-status'></span></span>",noProgressStatus:"<span class='k-progress-status-wrap "+u+"'></span>",announceElement:'<span aria-live="polite" class="k-sr-only k-progress-announce"></span>'},k=i.extend({init:function(e,t){var n=this;i.fn.init.call(this,e,t),t=n.options,n._progressProperty=t.orientation===r?"width":"height",n._fields(),t.value=n._validateValue(t.value),n._validateType(t.type),n._wrapper(),t.ariaRole&&n._aria(),n._progressAnimation(),t.value!==t.min&&!1!==t.value&&n._updateProgress()},setOptions:function(e){var t=this,n=t.wrapper;i.fn.setOptions.call(t,e),e.hasOwnProperty("reverse")&&n.toggleClass("k-progressbar-reverse",e.reverse),e.hasOwnProperty("enable")&&t.enable(e.enable),e.ariaRole&&t._aria(),t._progressAnimation(),t._validateValue(),t._updateProgress()},events:[v,_],options:{name:"ProgressBar",orientation:r,reverse:!1,min:0,max:100,value:0,enable:!0,type:g.VALUE,chunkCount:5,showStatus:!0,animation:{},label:null,labelId:null,ariaRole:!1},_aria:function(){var t=this,n=t.options,i=t.wrapper;i.attr({role:"progressbar","aria-valuemin":n.min,"aria-valuemax":n.max}),n.labelId?i.attr("aria-labelledby",n.labelId):n.label&&i.attr("aria-label",n.label),t.announce=e(w.announceElement),t.announce.appendTo(e("body")),!1!==n.value&&(i.attr("aria-valuenow",n.value),t.announce.text(t._calculatePercentage().toFixed()+"%"))},_fields:function(){var t=this;t._isStarted=!1,t.progressWrapper=t.progressStatus=e()},_validateType:function(t){var i=!1;if(e.each(g,(function(e,n){if(n===t)return i=!0,!1})),!i)throw new Error(n.format("Invalid ProgressBar type '{0}'",t))},_wrapper:function(){var e=this,t=e.wrapper=e.element,n=e.options,i=n.orientation,l=!1!==n.value?n.value:n.min;t.addClass(a),t.addClass(a+"-"+(i===r?r:o)),!1===n.enable&&t.addClass(p),n.reverse&&t.addClass("k-progressbar-reverse"),!1===n.value&&t.addClass(s),n.type===g.CHUNK?e._addChunkProgressWrapper():n.showStatus?(e.progressStatus=e.wrapper.prepend(w.progressStatus).find("."+d),n.type===g.VALUE?e.progressStatus.text(l):e.progressStatus.text(e._calculatePercentage(l).toFixed()+"%")):e.wrapper.prepend(w.noProgressStatus)},value:function(e){return this._value(e)},_value:function(e){var n,i=this,r=i.options;if(e===t)return r.value;"boolean"!=typeof e?(e=i._roundValue(e),isNaN(e)||(n=i._validateValue(e))!==r.value&&(i.wrapper.removeClass(s),r.value=n,i._isStarted=!0,i._updateProgress())):e||(i.wrapper.addClass(s),i.wrapper.removeAttr("aria-valuenow"),r.value=!1,i.announce&&i.announce.text(""))},_roundValue:function(e){e=parseFloat(e);var t=b.pow(10,3);return n._round(e*t)/t},_validateValue:function(e){var t=this.options;if(!1!==e){if(e<=t.min||!0===e)return t.min;if(e>=t.max)return t.max}else if(!1===e)return!1;return isNaN(this._roundValue(e))?t.min:e},_updateProgress:function(){var e=this,t=e.options,n=e._calculatePercentage();t.type===g.CHUNK?(e._updateChunks(n),e._onProgressUpdateAlways(t.value)):e._updateProgressWrapper(n),t.ariaRole&&(e.wrapper.attr("aria-valuenow",e.options.value),e.announce&&e.announce.text(n.toFixed()+"%"))},_updateChunks:function(e){var t,i=this,a=i.options,s=a.chunkCount,l=parseInt(100/s*100,10)/100,c=parseInt(100*e,10)/100,d=b.floor(c/l);t=a.orientation===r&&!a.reverse||a.orientation===o&&a.reverse?i.wrapper.find("li."+m).slice(0,d):0===d?n.jQuery():i.wrapper.find("li."+m).slice(-1*d),i.wrapper.find("."+h).removeClass(h+" "+f),t.addClass(h+" "+f)},_updateProgressWrapper:function(e){var t=this,n=t.options,i=t.wrapper.find("."+c),r=t._isStarted?t._animation.duration:0,o={};0===i.length&&t._addRegularProgressWrapper(),o[t._progressProperty]=e+"%",t.progressWrapper.animate(o,{duration:r,start:t._onProgressAnimateStart.bind(t),progress:t._onProgressAnimate.bind(t),complete:t._onProgressAnimateComplete.bind(t,n.value),always:t._onProgressUpdateAlways.bind(t,n.value)})},_onProgressAnimateStart:function(){this.progressWrapper.show()},_onProgressAnimate:function(e){var t,n=this,i=n.options,r=parseFloat(e.elem.style[n._progressProperty],10);i.showStatus&&(t=1e4/parseFloat(n.progressWrapper[0].style[n._progressProperty]),n.progressWrapper.find(".k-progress-status-wrap").css(n._progressProperty,t+"%")),i.type!==g.CHUNK&&r<=98&&n.progressWrapper.removeClass(l)},_onProgressAnimateComplete:function(e){var t,n=this,i=n.options,r=parseFloat(n.progressWrapper[0].style[n._progressProperty]);i.type!==g.CHUNK&&r>98&&n.progressWrapper.addClass(l),i.showStatus&&(t=i.type===g.VALUE?e:i.type==g.PERCENT?n._calculatePercentage(e).toFixed()+"%":b.floor(n._calculatePercentage(e))+"%",n.progressStatus.text(t)),e===i.min&&n.progressWrapper.hide()},_onProgressUpdateAlways:function(e){var t=this,n=t.options;t._isStarted&&t.trigger(v,{value:e}),e===n.max&&t._isStarted&&t.trigger(_,{value:n.max})},enable:function(e){var t=this.options;t.enable=void 0===e||e,this.wrapper.toggleClass(p,!t.enable)},destroy:function(){var e=this;e.announce&&e.announce.remove(),i.fn.destroy.call(e)},_addChunkProgressWrapper:function(){var e=this,t=e.options,n=e.wrapper,i=100/t.chunkCount,r="";t.chunkCount<=1&&(t.chunkCount=1),e.element.addClass("k-chunk-progressbar"),r+="<ul class='k-reset k-progressbar-chunks'>";for(var o=t.chunkCount-1;o>=0;o--)r+="<li class='"+m+"'></li>";r+="</ul>",n.append(r).find("."+m).css(e._progressProperty,i+"%").first().addClass("k-first").end().last().addClass("k-last"),e._normalizeChunkSize()},_normalizeChunkSize:function(){var e=this,t=e.options,n=e.wrapper.find("."+m).last(),i=parseFloat(n[0].style[e._progressProperty]),r=100-t.chunkCount*i;r>0&&n.css(e._progressProperty,i+r+"%")},_addRegularProgressWrapper:function(){var t=this;t.progressWrapper=e("<div class='"+c+" "+f+"'></div>").appendTo(t.wrapper),t.options.showStatus?(t.progressWrapper.append(w.progressStatus),t.progressStatus=t.wrapper.find("."+d)):t.progressWrapper.prepend(w.noProgressStatus)},_calculateChunkSize:function(){var e=this,t=e.options.chunkCount,n=e.wrapper.find("ul.k-reset");return(parseInt(n.css(e._progressProperty),10)-(t-1))/t},_calculatePercentage:function(e){var n=this,i=n.options,r=e!==t?e:i.value,o=i.min,a=i.max;return n._onePercent=b.abs((a-o)/100),b.abs((r-o)/n._onePercent)},_progressAnimation:function(){var e=this,t=e.options,n=t.animation;e._animation=!1===n?{duration:0}:y({duration:400},t.animation)}});n.ui.plugin(k)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=t.antiForgeryTokens,r=t.logToConsole,o=/\.([^\.]+)$/,a=".kendoUpload",s="select",l="upload",c="success",d="error",u="complete",h="cancel",p="clear",f="pause",m="resume",g="progress",v="remove",_="validationErrors",b="invalidMaxFileSize",y="invalidMinFileSize",w="invalidFileExtension",k="k-hover",x="k-focus",C="k-progressbar",S="."+C,T="tabindex",D="upload",A="exclamation-circle",M="check",E=n.extend({init:function(e,i){var r=this;r.progressbars=[],n.fn.init.call(r,e,i),r.name=e.name,r.multiple=r.options.multiple,r.directory=r.options.directory,r.localization=r.options.localization;var o=r.element;r.wrapper=o.closest(".k-upload"),0===r.wrapper.length&&(r.wrapper=r._wrapInput(o)),r._activeInput(o),r.element.addClass("k-hidden"),r.toggle(r.options.enabled);var s=r._ns=a+"-"+t.guid();o.closest("form").on("submit"+s,r._onParentFormSubmit.bind(r)).on("reset"+s,r._onParentFormReset.bind(r)),r._initUploadModule(),r._toggleDropZone(),r.wrapper.on("keydown",".k-upload-button",r._onUploadButtonKeydown.bind(r)).on("click",".k-upload-action",r._onFileAction.bind(r)).on("click",".k-clear-selected",r._onClearSelected.bind(r)).on("click",".k-upload-button",(function(e){e.preventDefault(),r.element.click()})).on("click",".k-upload-selected",r._onUploadSelected.bind(r)).on("keydown",r._onKeyDown.bind(r)).on("focusout",r._focusout.bind(r)),r.element.val()&&r._onInputChange({target:r.element})},events:[s,l,c,d,u,h,p,g,v,f,m],options:{name:"Upload",enabled:!0,multiple:!0,directory:!1,showFileList:!0,template:"",files:[],async:{autoRetryAfter:0,bufferChunkSize:1e7,maxAutoRetries:1,removeVerb:"POST",autoUpload:!0,withCredentials:!0,accept:"*/*; q=0.5, application/json",useArrayBuffer:!1},localization:{select:"Select files...",cancel:"Cancel",retry:"Retry",remove:"Remove",pause:"Pause",resume:"Resume",clearSelectedFiles:"Clear",uploadSelectedFiles:"Upload",dropFilesHere:"Drop files here to upload",invalidFiles:"Invalid file(s). Please check file upload requirements.",statusUploading:"uploading",statusUploaded:"uploaded",statusWarning:"warning",statusFailed:"failed",headerStatusUploading:"Uploading...",headerStatusPaused:"Paused",headerStatusUploaded:"Done",uploadSuccess:"File(s) uploaded successfully.",uploadFail:"File(s) failed to upload.",invalidMaxFileSize:"File size too large.",invalidMinFileSize:"File size too small.",invalidFileExtension:"File type not allowed."},validation:{allowedExtensions:[],maxFileSize:0,minFileSize:0},dropZone:""},_initUploadModule:function(){var e=this,t=e.options;if(t.async.saveUrl){e._module=e._supportsFormData()?new P(e):new z(e),e._async=!0;var n=t.files;n.length>0&&e._renderInitialFiles(n)}else e._module=new I(e)},setOptions:function(t){var i=this,r=i.element;e(i.options.dropZone).off(i._ns),n.fn.setOptions.call(i,t),i.multiple=i.options.multiple,i.directory=i.options.directory,r.attr("multiple",!!i._supportsMultiple()&&i.multiple),i.directory&&(r.attr("webkitdirectory",i.directory),r.attr("directory",i.directory)),i.toggle(i.options.enabled),i._initUploadModule(),i._toggleDropZone()},enable:function(e){e=void 0===e||e,this.toggle(e)},disable:function(){this.toggle(!1)},toggle:function(e){e=void 0===e?e:!e,this.wrapper.toggleClass("k-disabled",e),this.element.prop("disabled",e)},focus:function(){this.wrapper.find(".k-upload-button").trigger("focus")},destroy:function(){var t=this,i=e(t.options.dropZone);e(document).add(e(".k-dropzone",t.wrapper)).add(t.wrapper.closest("form")).off(t._ns),i.length>0&&i.off(t._ns),e(t.element).off(a),t.progressbars&&t.progressbars.forEach((e=>{e.destroy()})),n.fn.destroy.call(t)},pause:function(n){this._module.onPause({target:e(n,this.wrapper)});var i=n.find(".k-i-pause-sm,.k-svg-i-pause-sm"),r=t.htmlEncode(this.localization.resume);t.ui.icon(i,{icon:"play-sm"}),i.attr("title",r),e(i).parent().attr("aria-label",r)},resume:function(n){this._module.onResume({target:e(n,this.wrapper)});var i=n.find(".k-i-play-sm,.k-svg-i-play-sm"),r=t.htmlEncode(this.localization.pause);t.ui.icon(i,{icon:"pause-sm"}),i.attr("title",r),e(i).parent().attr("aria-label",r)},upload:function(){this._module.onSaveSelected()},getFiles:function(){for(var t,n=[],i=this.wrapper.find(".k-file"),r=0;r<i.length;r++)if(t=e(i[r]).data("fileNames"))for(var o=0;o<t.length;o++)n.push(t[o]);return n},clearAllFiles:function(){var e=this;e.wrapper.find(".k-file").each((function(t,n){e._removeFileByDomElement(n,!1)}))},removeAllFiles:function(){var e=this;e.wrapper.find(".k-file").each((function(t,n){e._removeFileByDomElement(n,!0)}))},removeFileByUid:function(e){this._removeFileByUid(e,!0)},clearFileByUid:function(e){this._removeFileByUid(e,!1)},_removeFileByUid:function(n,i){var r;"string"==typeof n&&(r=e(".k-file["+t.attr("uid")+'="'+n+'"]',this.wrapper)).length>0&&this._removeFileByDomElement(r,i)},clearFile:function(e){this._removeFile(e,!1)},removeFile:function(e){this._removeFile(e,!0)},_removeFile:function(t,n){var i,r=this,o=r.wrapper.find(".k-file");"function"==typeof t&&o.each((function(o,a){i=e(a).data("fileNames"),t(i)&&r._removeFileByDomElement(a,n)}))},_removeFileByDomElement:function(t,n){var i=this,r={target:e(t,i.wrapper)};i.options.async.saveUrl?(e(t).hasClass("k-file-progress")?i._module.onCancel(r):i._module.onRemove(r,{},n),0===e(".k-file",i.wrapper).length?i._hideHeaderUploadstatus():i._updateHeaderUploadStatus()):i._module.onRemove(r,{},n)},_addInput:function(t){if(t[0].nodeType){var n=this,i=t.clone().val("");i.insertAfter(n.element).data("kendo"+n.options.prefix+n.options.name,n),e(n.element).attr(T,"-1").removeAttr("id").off(a),n._activeInput(i),n.wrapper.find(".k-upload-button").trigger("focus")}},_activeInput:function(e){var t=this,n=t.wrapper;t.element=e,t.directory&&(e.attr("webkitdirectory",t.directory),e.attr("directory",t.directory)),e.attr("multiple",!!t._supportsMultiple()&&t.multiple).attr("autocomplete","off").on("click"+a,(function(e){n.hasClass("k-disabled")&&e.preventDefault()})).on("change"+a,t._onInputChange.bind(t))},_adjustFocusState:function(e,t){e.removeClass(x),e.attr(T,-1),t.addClass(x),t.attr(T,0)},_arrowKeyNavigation:function(e,n,i){var r,o=this,a=t.keys;n===a.DOWN?(e.preventDefault(),e.stopPropagation(),r=o.wrapper.find(".k-upload-files .k-file").first(),i.length>0&&(i.hasClass("k-upload-action")&&(i.removeClass(x),i=i.closest(".k-file")),r=i.next()),o._adjustFocusState(i,r),r&&0!==r.length||(r=o.wrapper.find(".k-clear-selected"))):n===a.UP?(e.preventDefault(),e.stopPropagation(),r=o.wrapper.find(".k-upload-files .k-file:last"),i.length>0&&(i.hasClass("k-upload-action")&&(i.removeClass(x),i=i.closest(".k-file")),r=i.prev()),o._adjustFocusState(i,r)):n===a.RIGHT?(i.hasClass("k-upload-action")?(r=i.next(".k-upload-action"))&&0!==r.length||(r=i.parent().find(".k-upload-action:first")):i.length>0&&(r=i.find(".k-upload-action:first")),r&&r.length>0&&(i.removeClass(x),r.addClass(x))):n===a.LEFT&&(i.hasClass("k-upload-action")?(r=i.prev(".k-upload-action"))&&0!==r.length||(r=i.parent().find(".k-upload-action:last")):i.length>0&&(r=i.find(".k-upload-action:last")),r&&r.length>0&&(i.removeClass(x),r.addClass(x))),r&&0!==r.length||n!==a.UP&&n!==a.DOWN||(r=o.wrapper.find(".k-upload-button")),r&&r.length>0&&(o._preventFocusRemove=!0,r.trigger("focus"))},_asyncCommandKeyNavigation:function(n,i,r){var o=this,a=t.keys,s=e(i,o.wrapper);if(o._retryClicked=!1,n===a.ESC&&i.find(".k-i-cancel,.k-svg-i-cancel").length>0)o.trigger(h,r),o._module.onCancel({target:s}),o._checkAllComplete(),o._updateHeaderUploadStatus(),o._preventFocusRemove=!0,o.wrapper.find(".k-upload-button").trigger("focus");else if(n===a.SPACEBAR)i.find(".k-i-pause-sm,.k-svg-i-pause-sm").length>0?(o.trigger(f,r),o.pause(i),o._updateHeaderUploadStatus()):i.find(".k-i-play-sm,.k-svg-i-play-sm").length>0&&(o.trigger(m,r),o.resume(i));else if(n===a.ENTER&&!i.is(".k-file-progress, .k-file-success, .k-file-invalid")){if(o.options.async.chunkSize&&!o.options.async.concurrent&&e(".k-file-progress",o.wrapper).length>0)return;e(".k-i-exclamation-circle,.k-svg-i-exclamation-circle",i).remove(),e(S,i).finish().show(),o._module.metaData[s.data("uid")]||o._module.prepareChunk(s),o._module.onRetry({target:s}),o._retryClicked=!0}},_commandKeyNavigation:function(n,i){var r=this,o=t.keys,a=i.data("fileNames"),s=r._filesContainValidationErrors(a),l={files:a,headers:{}};n===o.DELETE?r.trigger(v,l)||(r._module.onRemove({target:e(i,r.wrapper)},l,!s),r._preventFocusRemove=!0,r.wrapper.find(".k-upload-button").trigger("focus")):n===o.TAB?(i.removeClass(x),i.attr(T,-1)):r.options.async.saveUrl&&r._asyncCommandKeyNavigation(n,i,l)},_focusout:function(){var e=this.wrapper.find(".k-upload-files .k-file."+x);this._preventFocusRemove?this._preventFocusRemove=!1:(e.removeClass(x),e.attr(T,-1))},_onKeyDown:function(e){var n=this,i=n.wrapper.find(".k-upload-files .k-file."+x+",.k-upload-action."+x),r=t.keys,o=[r.DELETE,r.ESC,r.ENTER,r.SPACEBAR,r.TAB],a=e.keyCode;a===r.DOWN||a===r.UP||a===r.LEFT||a===r.RIGHT?n._arrowKeyNavigation(e,a,i):i.length>0&&i.hasClass("k-file")&&o.indexOf(a)>-1&&!n.wrapper.hasClass("k-disabled")&&(a===r.SPACEBAR&&(e.preventDefault(),e.stopPropagation()),n._commandKeyNavigation(a,i))},_onInputChange:function(t){var n=this,i=e(t.target),r=O(n._inputFiles(i),n._isAsyncNonBatch());V(r,n.options.validation),n.trigger(s,{files:r})?(n._addInput(i),i.remove()):n._module.onSelect({target:i},r),n.focus()},_onUploadButtonKeydown:function(e){var n=e.keyCode,i=t.keys;n!==i.ENTER&&n!==i.SPACEBAR||this.wrapper.find(".k-upload-button-wrap input").last().trigger("click")},_readDirectory:function(t){var n=new e.Deferred,i=t.createReader(),r=[],o=function(){i.readEntries((function(e){e.length?(r=r.concat(e),o()):n.resolve(r)}),n.reject)};return o(),n.promise()},_readFile:function(e){var t=this,n=e.fullPath;e.file((function(e){e.relativePath=n.slice(1),t.droppedFolderFiles.push(e),t.droppedFolderCounter--,0===t.droppedFolderCounter&&setTimeout((function(){0===t.droppedFolderCounter&&t.droppedFolderFiles.length&&(t._proceedDroppedItems(t.droppedFolderFiles),t.droppedFolderFiles=[])}),0)}),(function(){r("File error.")}))},_traverseFileTree:function(e,t){var n=this;t||n.droppedFolderCounter--,this._readDirectory(e).then((function(e){n.droppedFolderCounter+=e.length;for(var t=0;t<e.length;t++)e[t].isFile?n._readFile(e[t]):e[t].isDirectory&&n._traverseFileTree(e[t])}))},_onDrop:function(e){var t,n=e.originalEvent.dataTransfer,i=this,r=n.files;if(K(e),i.options.directoryDrop&&n.items){t=n.items.length,i.droppedFolderCounter=0,i.droppedFolderFiles=[];for(var o=0;o<t;o++)if(n.items[o].webkitGetAsEntry){var a=n.items[o].webkitGetAsEntry();a.isDirectory?i._traverseFileTree(a,!0):a.isFile&&i.droppedFolderFiles.push(n.files[o])}else i._proceedDroppedItems(r)}else i._proceedDroppedItems(r)},_proceedDroppedItems:function(t){var n=this,i=O(R(t),n._isAsyncNonBatch());t.length>0&&!n.wrapper.hasClass("k-disabled")&&(!n.multiple&&i.length>1&&i.splice(1,i.length-1),V(i,n.options.validation),n.trigger(s,{files:i})||n._module.onSelect({target:e(".k-dropzone",n.wrapper)},i))},_filesContainValidationErrors:function(t){var n=!1;return e(t).each((function(e,t){if(t[_]&&t[_].length>0)return n=!0,!1})),n},_isAsyncNonBatch:function(){return this._async&&!this.options.async.batch||!1},_renderInitialFiles:function(e){var t=this,n=0;for(e=O(e,!0),n=0;n<e.length;n++){var i=e[n],r=t._enqueueFile(i.name,{fileNames:[i]});r.addClass("k-file-success").data("files",[e[n]]),t._supportsRemove()&&t._fileAction(r,v)}},_prepareTemplateData:function(e,t){var n=t.fileNames,i={},r=0,o=0;for(o=0;o<n.length;o++)r+=n[o].size;return i.name=e,i.size=r,i.files=t.fileNames,i},_createProgressbarWapper:function(){return"<div class='"+C+" k-hidden'></div>"},_createFileIconWrapper:function(e){return"<span class='k-file-icon-wrapper'>"+t.ui.icon({icon:e,iconClass:"k-file-icon",size:"xxlarge"})+"<span class='k-file-state'></span></span>"},_progressbarInit:function(e){let t=e.kendoProgressBar({animation:!1,showStatus:!1}).data("kendoProgressBar");this.progressbars.push(t)},_prepareDefaultSingleFileEntryTemplate:function(n){var i=n.fileNames[0],r=U(n.fileNames),o=t.getFileGroup(i.extension,!0),a=i[_],s=a&&a.length>0,l=s?" k-file-invalid k-file-error":"",c=s?"<span class='k-file-validation-message' aria-live='polite'>"+t.htmlEncode(this.localization[a[0]])+"</span>":"<span class='k-file-size'>"+r+"</span>";let d=t.htmlEncode(i.name,!0);var u="";return u+="<li class='k-file"+l+"'><div class='k-file-single'>"+this._createProgressbarWapper()+this._createFileIconWrapper(o)+"<span class='k-file-info'><span class='k-file-name' title='"+d+"'>"+d+"</span>"+c+"</span>",e(u+="<span class='k-upload-actions'></span></div>")},_prepareDefaultMultipleFileEntriesTemplate:function(n){var i,r,o=n.fileNames,a=this._filesContainValidationErrors(o),s=U(o),l="";for(l+="<li class='k-file"+(a?" k-file-invalid k-file-error":"")+"'><div class='k-file-multiple'>"+this._createProgressbarWapper()+this._createFileIconWrapper("copy"),o.sort((function(e,t){return e[_]?-1:t[_]?1:0})),l+="<span class='k-multiple-files-wrapper'>",i=0;i<o.length;i++){var c=U([r=o[i]]);let e=t.htmlEncode(r.name,!0);l+="<span class='k-file-info'>",r[_]&&r[_].length>0?l+="<span class='k-file-name k-file-name-invalid' title='"+e+"'>"+e+"</span>":l+="<span class='k-file-name' title='"+e+"'>"+e+"</span>",l+="<span class='k-file-size'>"+c+"</span></span>"}return l+=a?"<span class='k-file-validation-message' aria-live='polite'>"+t.htmlEncode(this.localization.invalidFiles)+"</span>":"<span class='k-file-summary'>Total: "+o.length+" files, "+s+"</span>",e(l+="</span><span class='k-upload-actions'></span></div>")},_enqueueFile:function(n,i){var r,o,a,s,l,c,d=this,u=i.fileNames[0].uid,h=e(".k-upload-files",d.wrapper),p=d.options.template,f=p?".k-progress":S;return 0===h.length&&(h=e("<ul class='k-upload-files'></ul>").appendTo(d.wrapper),d.options.showFileList||h.hide(),d.wrapper.removeClass("k-upload-empty")),r=e(".k-file",h),p?(a=d._prepareTemplateData(n,i),p=t.template(p),(o=e("<li class='k-file'>"+p(a)+"</li>")).find(".k-upload-action").addClass("k-button k-icon-button k-button-md k-rounded-md k-button-flat k-button-flat-base")):o=1===i.fileNames.length?d._prepareDefaultSingleFileEntryTemplate(i):d._prepareDefaultMultipleFileEntriesTemplate(i),(c=(l=e(f,o[0])).length>0)&&d._progressbarInit(l),o.attr(t.attr("uid"),u).appendTo(h).data(i),!d._async&&c&&l.data("kendoProgressBar").value(100),!d.multiple&&r.length>0&&(s={files:r.data("fileNames"),headers:{}},d.trigger(v,s)||d._module.onRemove({target:e(r,d.wrapper)},s)),o},_removeFileEntry:function(t){var n,i=this,r=t.closest(".k-upload-files");t.remove(),n=e(".k-file",r),e(".k-file-success, .k-file-error",r).length===n.length&&this._hideActionButtons(),0===n.length?(r.remove(),i.wrapper.addClass("k-upload-empty"),i._hideHeaderUploadstatus()):i._updateHeaderUploadStatus()},_fileAction:function(n,i,r){var o,a={remove:"x",cancel:"cancel",retry:"arrow-rotate-cw-small",pause:"pause-sm"};let s=t.htmlEncode(this.localization[i]);if(a.hasOwnProperty(i))if(r||this._clearFileAction(n),this.options.template)if((o=n.find(".k-upload-action").first()).find(".k-icon,.k-svg-icon").length){if(o.next(".k-upload-action").length){let n=t.ui.icon(e(`<span title="${s}" aria-label="${s}"></span>`),{icon:a[i],iconClass:"k-button-icon"+("retry"==i?" k-i-retry":"")});o.next(".k-upload-action").addClass("k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-icon-button").append(n).show()}}else{let n=t.ui.icon(e(`<span title="${s}" aria-label="${s}"></span>`),{icon:a[i],iconClass:"k-button-icon"+("retry"==i?" k-i-retry":"")});o.addClass("k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-icon-button").append(n).show()}else r||n.find(".k-upload-action").remove(),n.find(".k-upload-actions").append(this._renderAction(a[i],s,"retry"==i?"k-i-retry":""))},_fileState:function(n,i){var r=this.localization,o={uploading:{text:r.statusUploading},uploaded:{text:r.statusUploaded},failed:{text:r.statusFailed}}[i];o&&e("span.k-file-state",n).text(t.htmlEncode(o.text))},_renderAction:function(n,i,r){return""!==n?e("<button type='button' class='k-button k-icon-button k-button-md k-rounded-md k-button-flat k-button-flat-base k-upload-action' aria-hidden='true' aria-label='"+i+"' tabindex='-1'>"+t.ui.icon(e(`<span title="${i}"></span>`),{icon:n,iconClass:"k-button-icon"+(r?` ${r}`:"")})+"</button>").on("focus",(function(){e(this).addClass(x)})).on("blur",(function(){e(this).removeClass(x)})):e("<button type='button' class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base'><span class=\"k-button-text\">"+i+"</span></button>")},_clearFileAction:function(t){e(".k-upload-action",t).empty().hide()},_onFileAction:function(t){var n=this;if(!n.wrapper.hasClass("k-disabled")){var i=e(t.target).closest(".k-upload-action"),r=i.find(".k-icon,.k-svg-icon"),o=i.closest(".k-file"),a=o.data("fileNames"),s=n._filesContainValidationErrors(a),l={files:a,headers:{}};n._retryClicked=!1,r.is(".k-i-x,.k-svg-i-x")?n.trigger(v,l)||(n._module.onRemove({target:e(o,n.wrapper)},l,!s),n.wrapper.find(".k-upload-button").trigger("focus")):r.is(".k-i-cancel,.k-svg-i-cancel")?(n.trigger(h,l),n._module.onCancel({target:e(o,n.wrapper)}),n._checkAllComplete(),n._updateHeaderUploadStatus(),n.wrapper.find(".k-upload-button").trigger("focus")):r.is(".k-i-pause-sm,.k-svg-i-pause-sm")?(n.trigger(f,l),n.pause(o),n._updateHeaderUploadStatus()):r.is(".k-i-play-sm,.k-svg-i-play-sm")?(n.trigger(m,l),n.resume(o)):r.hasClass("k-i-retry")&&(e(".k-i-exclamation-circle",o).remove(),e(S,o).finish().show(),n._module.onRetry({target:e(o,n.wrapper)}),n._retryClicked=!0),o.addClass(x)}return!1},_onUploadSelected:function(){return this.wrapper.hasClass("k-disabled")||this._module.onSaveSelected(),!1},_onClearSelected:function(){var e=this;return e.wrapper.hasClass("k-disabled")||e.trigger(p,{})||e.clearAllFiles(),!1},_onFileProgress:function(t,n){var i=e(S,t.target).data("kendoProgressBar");n>100&&(n=100),e(S,t.target).removeClass("k-hidden"),this.options.template||(0===e(".k-upload-pct",t.target).length&&e(".k-upload-actions",t.target).prepend("<span class='k-upload-pct'></span>"),100!==n?e(".k-upload-pct",t.target).text(n+"%"):e(".k-upload-pct",t.target).remove()),i&&i.value(n),this.trigger(g,{files:X(t).data("fileNames"),percentComplete:n})},_onUploadSuccess:function(e,n,i){var r=this,o=X(e),a=o.data("fileNames"),s=o.find(".k-file-summary"),l=o.find(".k-file-size");r.trigger(c,{files:o.data("fileNames"),response:n,operation:"upload",XMLHttpRequest:i})?r._setUploadErrorState(o):(r._fileState(o,"uploaded"),o.removeClass("k-file-progress").addClass("k-file-success"),s.length>0?s.addClass("k-hidden").after('<span class="k-file-validation-message" aria-live="polite">'+a.length+" "+t.htmlEncode(r.localization.uploadSuccess)+"</span>"):l.length>0&&l.addClass("k-hidden").after('<span class="k-file-validation-message" aria-live="polite">'+t.htmlEncode(r.localization.uploadSuccess)+"</span>"),r._updateHeaderUploadStatus(),r._supportsRemove()?r._fileAction(o,v):r._clearFileAction(o)),r._hideUploadProgress(o),r._checkAllComplete()},_onUploadError:function(e,t){var n=this,i=n._module,o=X(e),a=o.data("uid");n._setUploadErrorState(o),n.trigger(d,{operation:"upload",files:o.data("fileNames"),XMLHttpRequest:t}),r("Server response: "+t.responseText),n.options.async.chunkSize?i._decreasePosition&&i._decreasePosition(a):n._hideUploadProgress(o),n._checkAllComplete(),this.options.async.autoRetryAfter&&this._autoRetryAfter(o)},_autoRetryAfter:function(e){var t=this,n=this._module.retries;n&&(n[e.data("uid")]||(n[e.data("uid")]=1),n[e.data("uid")]<=this.options.async.maxAutoRetries&&(n[e.data("uid")]++,setTimeout((function(){t._module.performUpload(e)}),this.options.async.autoRetryAfter)))},_setUploadErrorState:function(n){var i,r=this,o=n.data("fileNames"),a=n.find(".k-file-summary"),s=n.find(".k-file-size");r._fileState(n,"failed"),n.removeClass("k-file-progress").addClass("k-file-error"),a.length>0?a.addClass("k-hidden").after('<span class="k-file-validation-message" aria-live="polite">'+o.length+" "+t.htmlEncode(r.localization.uploadFail)+"</span>"):s.length>0&&s.addClass("k-hidden").after('<span class="k-file-validation-message" aria-live="polite">'+t.htmlEncode(r.localization.uploadFail)+"</span>"),r._updateUploadProgress(n),(i=e(".k-upload-pct",n)).length>0&&i.remove(),this._updateHeaderUploadStatus(),this._fileAction(n,"retry"),this._fileAction(n,v,!0),r._retryClicked&&n.trigger("focus")},_updateUploadProgress:function(t){var n=this,i=e(S,t),r=i.length>0;if(!n.options.async.chunkSize&&r)i.data("kendoProgressBar").value(100);else{var o=t.data("uid");if(n._module.metaData){var a=n._module.metaData[o];if(a){var s=a.totalChunks?Math.round(a.chunkIndex/a.totalChunks*100):100;n._onFileProgress({target:e(t,n.wrapper)},s)}}}},_hideUploadProgress:function(t){e(S,t).delay(1e3).fadeOut(2e3,(function(){e(this).data("kendoProgressBar")&&e(this).data("kendoProgressBar").value(0)}))},_showActionButtons:function(){var n=this,i=e(".k-actions",n.wrapper),r=e(".k-upload-selected",n.wrapper),o=e(".k-clear-selected",n.wrapper);0===r.length&&(r=e(t.html.renderButton(`<button class='k-upload-selected'>${t.htmlEncode(this.localization.uploadSelectedFiles)}</button>`,{icon:"upload",themeColor:"primary"})),o=e(t.html.renderButton(`<button class='k-clear-selected'>${t.htmlEncode(this.localization.clearSelectedFiles)}</button>`,{icon:"x"}))),i.length||(i=e("<div />").addClass("k-actions").append(r,o)),this.wrapper.append(i)},_hideActionButtons:function(){e(".k-actions",this.wrapper).remove()},_showHeaderUploadStatus:function(n){var i=this,r=i.localization,o=e(".k-dropzone",i.wrapper),a=e(".k-upload-status",i.wrapper);0!==a.length&&a.remove(),e(".k-dropzone-hint",i.wrapper).addClass("k-hidden"),a='<span class="k-upload-status"><span class="k-icon"></span></span>',n?(a=e(a).append(t.htmlEncode(r.headerStatusUploading)),t.ui.icon(a.find(".k-icon,.k-svg-icon"),{icon:D})):(a=e(a).append(t.htmlEncode(r.headerStatusUploaded)),t.ui.icon(a.find(".k-icon,.k-svg-icon"),{icon:A})),o.length>0?o.append(a):e(".k-upload-button",i.wrapper).after(a)},_updateHeaderUploadStatus:function(){var n,i=this,r=e(".k-upload-status",this.wrapper),o=e(".k-file",i.wrapper).not(".k-file-success, .k-file-error"),a=e(".k-file-error",i.wrapper),s=e(".k-file",i.wrapper).find(".k-i-play-sm,.k-svg-i-play-sm");!s.length||s.length!==o.length&&i.options.async.concurrent?(0===o.length||a.length>0)&&(r=e(".k-upload-status",i.wrapper),(n=e(".k-icon,.k-svg-icon",r).removeClass()).length&&(t.ui.icon(n,{icon:0!==a.length?A:M}),r.html(n).append(t.htmlEncode(i.localization.headerStatusUploaded)))):(n=e(".k-icon,.k-svg-icon",r).removeClass()).length&&(t.ui.icon(n,{icon:"pause-sm"}),r.html(n).append(t.htmlEncode(i.localization.headerStatusPaused)))},_hideHeaderUploadstatus:function(){var t=this.options.dropZone;e(".k-upload-status",this.wrapper).remove(),""===t&&e(".k-dropzone-hint",this.wrapper).removeClass("k-hidden")},_onParentFormSubmit:function(){var t=this.element;if(void 0!==this._module.onAbort&&this._module.onAbort(),!t.value){var n=e(t);n.attr("disabled","disabled"),window.setTimeout((function(){n.prop("disabled",!1)}),0)}},_onParentFormReset:function(){e(".k-upload-files",this.wrapper).remove()},_supportsFormData:function(){return"undefined"!=typeof FormData},_supportsMultiple:function(){var e=this._userAgent().indexOf("Windows")>-1;return!(t.support.browser.opera||t.support.browser.safari&&e)},_supportsDrop:function(){var e=this._userAgent().toLowerCase();return!(!/chrome/.test(e)&&/safari/.test(e)&&/windows/.test(e))&&this._supportsFormData()&&this.options.async.saveUrl},_userAgent:function(){return navigator.userAgent},_setupDropZone:function(){var n=this,i=n._ns,r=e(".k-dropzone",n.wrapper).on("dragenter"+i,K).on("dragover"+i,(function(e){e.originalEvent&&(e.originalEvent.dataTransfer.dropEffect="copy"),e.preventDefault()})).on("drop"+i,n._onDrop.bind(n));r.find(".k-dropzone-hint").length||r.append(e("<span class='k-dropzone-hint'>"+t.htmlEncode(n.localization.dropFilesHere)+"</span>")),Y(r,i,(function(){r.closest(".k-upload").hasClass("k-disabled")||r.addClass(k)}),(function(){r.removeClass(k)})),n._bindDocumentDragEventWrappers(r)},_setupCustomDropZone:function(){var n=this,i=e(n.options.dropZone);n.wrapper.find(".k-dropzone-hint").length?e(".k-dropzone-hint",n.wrapper).addClass("k-hidden"):e(".k-dropzone",n.wrapper).append(e("<span class='k-dropzone-hint k-hidden'>"+t.htmlEncode(n.localization.dropFilesHere)+"</span>"));var r=n._ns;i.on("dragenter"+r,K).on("dragover"+r,(function(e){e.originalEvent&&(e.originalEvent.dataTransfer.dropEffect="copy"),e.preventDefault()})).on("drop"+r,n._onDrop.bind(n)),Y(i,r,(function(t){n.wrapper.hasClass("k-disabled")||(i.removeClass(k),i.addClass(k),e(t.target).addClass(k))}),(function(){i.removeClass(k)})),n._bindDocumentDragEventWrappers(i)},_bindDocumentDragEventWrappers:function(t){var n=this,i=n._ns;Y(e(document),i,(function(){n.wrapper.hasClass("k-disabled")||(t.addClass("k-dropzone-active"),t.closest(".k-upload").removeClass("k-upload-empty"),t.find(".k-dropzone-hint").removeClass("k-hidden"))}),(function(){t.removeClass("k-dropzone-active"),t.find(".k-dropzone-hint").addClass("k-hidden"),0===e("li.k-file",t.closest(".k-upload")).length&&t.closest(".k-upload").addClass("k-upload-empty")}))},_toggleDropZone:function(){var t=this,n=t.options.dropZone;t._supportsDrop()&&(e(n).off(t._ns),e(".k-dropzone",t.wrapper).off(t._ns),""!==n?t._setupCustomDropZone():t._setupDropZone())},_supportsRemove:function(){return!!this.options.async.removeUrl},_submitRemove:function(t,n,r,o){var a=this.options.async.removeField||"fileNames",s=e.extend(n.data,i());s[a]=t,jQuery.ajax({type:this.options.async.removeVerb,dataType:"json",dataFilter:G,url:this.options.async.removeUrl,traditional:!0,data:s,headers:n.headers,success:r,error:o,xhrFields:{withCredentials:this.options.async.withCredentials}})},_wrapInput:function(n){var i=this.options,r=!!n.attr("id")&&e("[for='"+n.attr("id")+"']").length>0,o=t.htmlEncode(this.localization.select),a=e("<div class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-upload-button' tabindex='0' role='button'><span class='k-button-text'></span></div>");return a.find(".k-button-text").text(o),n.wrap("<div class='k-upload' role='application'><div class='k-dropzone k-upload-dropzone'><div class='k-upload-button-wrap'></div></div></div>"),a.prependTo(n.parent()),i.async.saveUrl?n.closest(".k-upload").addClass("k-upload-async"):n.closest(".k-upload").addClass("k-upload-sync"),n.closest(".k-upload").addClass("k-upload-empty"),r||n.attr("aria-label")||n.attr("aria-label",o),n.attr({tabindex:-1,"aria-hidden":!0}),n.closest(".k-upload")},_checkAllComplete:function(){0===e(".k-file.k-file-progress",this.wrapper).length&&this.trigger(u)},_inputFiles:function(e){return F(e)}}),I=function(e){this.name="syncUploadModule",this.element=e.wrapper,this.upload=e,this.element.closest("form").attr("enctype","multipart/form-data").attr("encoding","multipart/form-data")};I.prototype={onSelect:function(t,n){var i=this.upload,r=e(t.target),o=i._filesContainValidationErrors(n);i._addInput(r);var a={fileNames:n};o?r.remove():a.relatedInput=r;var s=i._enqueueFile(H(r),a);o&&i._hideUploadProgress(s),i._fileAction(s,v)},onRemove:function(e){var t=X(e),n=t.data("relatedInput");n&&n.remove(),this.upload._removeFileEntry(t)}};var z=function(e){this.name="iframeUploadModule",this.element=e.wrapper,this.upload=e,this.iframes=[]};E._frameId=0,z.prototype={onSelect:function(t,n){var i=this.upload,r=e(t.target),o=i._filesContainValidationErrors(n),a=this.prepareUpload(r,n,o);i.options.async.autoUpload?o?(i._fileAction(a,v),i._showHeaderUploadStatus(!1)):this.performUpload(a):(i._fileAction(a,v),o?i._updateHeaderUploadStatus():i._showActionButtons()),o&&i._hideUploadProgress(a)},prepareUpload:function(t,n,i){var r,o,a,s,l=this.upload,c=e(l.element),d=l.options.async.saveField||t.attr("name");return l._addInput(t),t.attr("name",d),i?(t.remove(),o={fileNames:n}):(a=this.createFrame(l.name+"_"+E._frameId++),this.registerFrame(a),s=this.createForm(l.options.async.saveUrl,a.attr("name")).append(c),o={frame:a,relatedInput:c,fileNames:n}),r=l._enqueueFile(H(t),o),a&&a.data({form:s,file:r}),r},performUpload:function(t){var n={files:t.data("fileNames")},r=t.data("frame"),o=this.upload,a=t.find(".k-file-validation-message"),s=t.find(".k-file-summary"),c=t.find(".k-file-size");if(o.trigger(l,n))o._removeFileEntry(r.data("file")),this.cleanupFrame(r),this.unregisterFrame(r);else{o._hideActionButtons(),o._showHeaderUploadStatus(!0),r.appendTo(document.body);var d=r.data("form").attr("action",o.options.async.saveUrl).appendTo(document.body);for(var u in n.data=e.extend({},n.data,i()),n.data){var p=d.find("input[name='"+u+"']");0===p.length&&(p=e("<input>",{type:"hidden",name:u}).prependTo(d)),p.val(n.data[u])}o._fileAction(t,h),o._fileState(t,"uploading"),e(t).removeClass("k-file-error").addClass("k-file-progress"),a.length>0&&a.remove(),s.length>0?s.removeClass("k-hidden"):c.length>0&&c.removeClass("k-hidden"),r.one("load",this.onIframeLoad.bind(this)),d[0].submit()}},onSaveSelected:function(){var t=this,n=t.upload;e(".k-file",this.element).each((function(){var i=e(this),r=Q(i),o=n._filesContainValidationErrors(i.data("fileNames"));r||o||t.performUpload(i)}))},onIframeLoad:function(t){var n,i=e(t.target);try{n=i.contents().text()}catch(e){n="Error trying to get server response: "+e}this.processResponse(i,n)},processResponse:function(t,n){var i=t.data("file"),r=this,o={responseText:n};q(n,(function(n){e.extend(o,{statusText:"OK",status:"200"}),r.upload._onFileProgress({target:e(i,r.upload.wrapper)},100),r.upload._onUploadSuccess({target:e(i,r.upload.wrapper)},n,o),r.cleanupFrame(t),r.unregisterFrame(t)}),(function(){e.extend(o,{statusText:"error",status:"500"}),r.upload._onUploadError({target:e(i,r.upload.wrapper)},o)}))},onCancel:function(t){var n=e(t.target).data("frame");this.stopFrameSubmit(n),this.cleanupFrame(n),this.unregisterFrame(n),this.upload._removeFileEntry(n.data("file"))},onRetry:function(e){var t=X(e);this.performUpload(t)},onRemove:function(e,t,n){var i=this,r=i.upload,o=X(e),a=o.data("frame");a?(i.unregisterFrame(a),r._removeFileEntry(o),i.cleanupFrame(a)):o.hasClass("k-file-success")?j(o,r,t,n):r._removeFileEntry(o)},onAbort:function(){var t=this.element,n=this;e.each(this.iframes,(function(){e("input",this.data("form")).appendTo(t),n.stopFrameSubmit(this[0]),this.data("form").remove(),this.remove()})),this.iframes=[]},createFrame:function(t){return e("<iframe name='"+t+"' id='"+t+"' />").hide()},createForm:function(t,n){return e("<form enctype='multipart/form-data' method='POST' action='"+t+"' target='"+n+"'/>")},stopFrameSubmit:function(e){void 0!==e.stop?e.stop():e.document&&e.document.execCommand("Stop")},registerFrame:function(e){this.iframes.push(e)},unregisterFrame:function(t){this.iframes=e.grep(this.iframes,(function(e){return e.attr("name")!=t.attr("name")}))},cleanupFrame:function(e){var t=e.data("form");e.data("file").data("frame",null),setTimeout((function(){t.remove(),e.remove()}),1)}};var P=function(e){this.name="formDataUploadModule",this.element=e.wrapper,this.upload=e,this.position={},this.metaData={},this.cancelled={},this.resume={},this.paused={},this.retries={}};function H(t){return e.map(F(t),(function(e){return e.name})).join(", ")}function F(e){var t=e[0];return t.files?R(t.files):[{name:B(t.value),extension:L(t.value),size:null}]}function R(n){return e.map(n,(function(e){return i=(n=e).name||n.fileName,{name:t.htmlEncode(i),extension:L(i),size:"number"==typeof n.size?n.size:n.fileSize,rawFile:n};var n,i}))}function L(e){var t=e.match(o);return t?t[0]:""}function B(e){var t=e.lastIndexOf("\\");return-1!=t?e.substr(t+1):e}function O(n,i){var r=t.guid();return e.map(n,(function(e){return e.uid=i?t.guid():r,e}))}function V(t,n){for(var i=function(t){var n=e.map(t,(function(e){return("."===e.substring(0,1)?e:"."+e).toLowerCase()}));return n}(n.allowedExtensions),r=n.maxFileSize,o=n.minFileSize,a=0;a<t.length;a++)N(t[a],i),$(t[a],o,r)}function N(t,n){n.length>0&&n.indexOf(t.extension.toLowerCase())<0&&(t.validationErrors=t.validationErrors||[],-1===e.inArray(w,t.validationErrors)&&t.validationErrors.push(w))}function $(t,n,i){0!==n&&t.size<n&&(t.validationErrors=t.validationErrors||[],-1===e.inArray(y,t.validationErrors)&&t.validationErrors.push(y)),0!==i&&t.size>i&&(t.validationErrors=t.validationErrors||[],-1===e.inArray(b,t.validationErrors)&&t.validationErrors.push(b))}function U(e){var t=0;if("number"!=typeof e[0].size)return"";for(var n=0;n<e.length;n++)e[n].size&&(t+=e[n].size);return(t/=1024)<1024?t.toFixed(2)+" KB":(t/1024).toFixed(2)+" MB"}function W(t){return!t.multiple&&e(".k-file",t.wrapper).length>1}function j(t,n,i,o){if(n._supportsRemove()){var a=t.data("fileNames"),s=e.map(a,(function(e){return e.name}));!1!==o?n._submitRemove(s,i,(function(e,i,r){n.trigger(c,{operation:"remove",files:a,response:e,XMLHttpRequest:r})||n._removeFileEntry(t)}),(function(e){W(n)&&n._removeFileEntry(t),n.trigger(d,{operation:"remove",files:a,XMLHttpRequest:e}),r("Server response: "+e.responseText)})):n._removeFileEntry(t)}else!W(n)&&o||n._removeFileEntry(t)}function q(e,t,n){var i=!1,r="";try{r=JSON.parse(G(e)),i=!0}catch(e){n()}i&&t(r)}function G(e){return void 0!==e&&""!==e||(e="{}"),e}function K(e){e.originalEvent&&(e.originalEvent.dataTransfer.dropEffect="copy"),e.stopPropagation(),e.preventDefault()}function Y(e,t,n,i){var r,o;e.on("dragenter"+t,(function(e){n(e),o=new Date,r||(r=setInterval((function(){new Date-o>100&&(i(),clearInterval(r),r=null)}),100))})).on("dragover"+t,(function(){o=new Date}))}function Q(e){return e.is(".k-file-progress, .k-file-success, .k-file-error:not(.k-file-invalid)")}function X(t){return e(t.target).closest(".k-file")}P.prototype={onSelect:function(t,n){var i,r,o=this.upload,a=this,s=e(t.target),l=this.prepareUpload(s,n);e.each(l,(function(t){i=o._filesContainValidationErrors(e(this.data("fileNames"))),o.options.async.autoUpload?i?(o._fileAction(this,v),o._showHeaderUploadStatus(!1)):o.options.async.chunkSize?(a.prepareChunk(this),r=this.prev(),(o.options.async.concurrent||0===t&&!r.length||0===t&&r.hasClass("k-file-success"))&&a.performUpload(this)):a.performUpload(this):(o._fileAction(this,v),i?o._updateHeaderUploadStatus():(o._showActionButtons(),this.addClass("k-toupload"))),i&&o._hideUploadProgress(this)}))},prepareUpload:function(t,n){var i=this.enqueueFiles(n);return t.is("input")&&(e.each(i,(function(){e(this).data("relatedInput",t)})),t.data("relatedFileEntries",i),this.upload._addInput(t)),i},enqueueFiles:function(t){var n,i,r,o,a=this.upload,s=t.length,l=[];if(!0===a.options.async.batch)n=e.map(t,(function(e){return e.name})).join(", "),(a.directory||a.options.directoryDrop)&&e(t).each((function(){(this.rawFile.webkitRelativePath||this.rawFile.relativePath)&&(this.name=this.rawFile.webkitRelativePath||this.rawFile.relativePath)})),(o=a._enqueueFile(n,{fileNames:t})).data("files",t),l.push(o);else for(i=0;i<s;i++)n=(r=t[i]).name,(a.directory||a.options.directoryDrop)&&(r.rawFile.webkitRelativePath||r.rawFile.relativePath)&&(r.name=r.rawFile.webkitRelativePath||r.rawFile.relativePath),(o=a._enqueueFile(n,{fileNames:[r]})).data("files",[r]),l.push(o);return l},performUpload:function(t){var n,r=this.upload,o=this.createFormData(),a=this.createXHR(),s={files:t.data("fileNames"),XMLHttpRequest:a},c=t.find(".k-file-validation-message"),d=t.find(".k-file-summary"),u=t.find(".k-file-size");if(r.trigger(l,s))this.removeFileEntry(t);else{if(0===t.find(".k-i-cancel,.k-svg-i-cancel").length&&(r.options.async.chunkSize&&r._fileAction(t,f),r._fileAction(t,h,r.options.async.chunkSize)),r.wrapper.find(".k-toupload").length||r._hideActionButtons(),r._showHeaderUploadStatus(!0),s.formData)o=s.formData;else{for(var p in s.data=e.extend({},s.data,i()),s.data)o.append(p,s.data[p]);(n=t.data("files"))&&this.populateFormData(o,n)}r._fileState(t,"uploading"),e(t).removeClass("k-file-error").addClass("k-file-progress"),c.length>0&&c.remove(),d.length>0?d.removeClass("k-hidden"):u.length>0&&u.removeClass("k-hidden"),r.options.async.useArrayBuffer&&window.FileReader?this._readFile(r.options.async.saveUrl,o,t,a):this.postFormData(r.options.async.saveUrl,o,t,a)}},_readFile:function(t,n,i,r){var o=this,a=o.upload,s=i.data("files")[0],l=new FileReader;l.onload=function(l){try{o.fileArrayBuffer?o.fileArrayBuffer=o._appendBuffer(o.fileArrayBuffer,l.target.result):o.fileArrayBuffer=l.target.result}catch(t){return void a._onUploadError({target:e(i,a.wrapper)},r)}o.position[s.uid]>s.size?(o.postFormData(a.options.async.saveUrl,o.fileArrayBuffer,i,r),o.fileArrayBuffer=null):o._readFile(t,n,i,r)},l.onerror=function(){a._onUploadError({target:e(i,a.wrapper)},r)},l.readAsArrayBuffer(o._getCurrentChunk(s.rawFile,s.uid))},_appendBuffer:function(e,t){var n=new Uint8Array(e.byteLength+t.byteLength);return n.set(new Uint8Array(e),0),n.set(new Uint8Array(t),e.byteLength),n.buffer},onSaveSelected:function(){var t=this,n=t.upload;e(".k-toupload",this.element).filter((function(){var t=e(this),i=Q(t),r=n._filesContainValidationErrors(t.data("fileNames"));return!i&&!r})).each((function(i){var r=e(this),o=r.prev();r.removeClass("k-toupload"),n.options.async.chunkSize?(t.prepareChunk(r),(n.options.async.concurrent||0===i&&!o.length||0===i&&o.hasClass("k-file-success")||o.hasClass("k-file-error:not(k-file-invalid)"))&&t.performUpload(r)):t.performUpload(r)}))},onCancel:function(e){var t=X(e);this.upload.options.async.chunkSize&&(this.cancelled[t.data("uid")]=!0),this.stopUploadRequest(t),this.removeFileEntry(t)},onPause:function(e){var t=X(e).data("uid"),n=this.upload.options.async;n.chunkSize&&(this.retries[t]=n.maxAutoRetries+1,this.paused[t]=!0,this.resume[t]=!1)},onResume:function(e){var t=X(e),n=t.data("uid");this.upload.options.async.chunkSize&&(delete this.paused[n],this.resume[n]=!0,this.retries[t.data("uid")]=1,this._increaseChunkIndex(n),this.performUpload(t))},onRetry:function(e){var t=X(e),n=this.upload.options.async;n.chunkSize&&(this.retries[t.data("uid")]=n.maxAutoRetries+1,delete this.paused[t.data("uid")]),this.performUpload(t)},onRemove:function(e,t,n){var i=this.upload,r=X(e),o=this.upload.options.async;o.chunkSize&&(this.retries[r.data("uid")]=o.maxAutoRetries+1),r.hasClass("k-file-success")?j(r,i,t,n):this.removeFileEntry(r)},createXHR:function(){return new XMLHttpRequest},postFormData:function(e,t,n,i){var r=this;n.data("request",i),i.addEventListener("load",(function(e){r.onRequestSuccess.call(r,e,n)}),!1),i.addEventListener(d,(function(e){r.onRequestError.call(r,e,n)}),!1),i.upload.addEventListener("progress",(function(e){r.onRequestProgress.call(r,e,n)}),!1),i.open("POST",e,!0),i.withCredentials=this.upload.options.async.withCredentials;var o=this.upload.options.async.accept;o&&i.setRequestHeader("Accept",o),i.send(t)},createFormData:function(){return new FormData},populateFormData:function(e,t){var n,i,r,o=t.length,a=this.upload;if(a.options.async.chunkSize){r=t[0].uid,n=this._getCurrentChunk(t[0].rawFile,r),e.append(a.options.async.saveField||a.name,n);var s=JSON.stringify(this.metaData[r]);e.append("metadata",s)}else for(i=0;i<o;i++)e.append(a.options.async.saveField||a.name,t[i].rawFile);return e},onRequestSuccess:function(t,n){var i=t.target,r=this;function o(){r.upload._onUploadError({target:e(n,r.upload.wrapper)},i)}i.status>=200&&i.status<=299?q(i.responseText,(function(t){var o=r.upload.options.async.batch,a=r.upload.options.async.chunkSize,s=r.upload.options.async.concurrent,l=t.fileUid;r.paused[l]||r.cancelled[l]||(delete r.retries[l],!a||o||t.uploaded?!a||o||s||!n.next().length||n.next().hasClass("k-toupload")?(r.upload._onFileProgress({target:e(n,r.upload.wrapper)},100),r.upload._onUploadSuccess({target:e(n,r.upload.wrapper)},t,i),r.cleanupFileEntry(n)):(r.upload._onFileProgress({target:e(n,r.upload.wrapper)},100),r._resetChunkIndex(l),r.upload._onUploadSuccess({target:e(n,r.upload.wrapper)},t,i),r.performUpload(n.next())):(r._increaseChunkIndex(l),r.performUpload(n)))}),o):o()},onRequestError:function(t,n){var i=t.target;this.upload._onUploadError({target:e(n,this.upload.wrapper)},i)},cleanupFileEntry:function(t){var n=t.data("relatedInput"),i=!0;n&&(e.each(n.data("relatedFileEntries")||[],(function(){this.parent().length>0&&this[0]!=t[0]&&(i=i&&this.hasClass("k-file-success"))})),i&&n.remove())},removeFileEntry:function(e){var t=this.upload.options.async.chunkSize,n=this.upload.options.async.concurrent,i=this.upload.wrapper.find(".k-upload-selected").length>0;this.cleanupFileEntry(e),!t||n||i||e.next().length&&this.performUpload(e.next()),this.upload._removeFileEntry(e)},onRequestProgress:function(t,n){var i,r=Math.round(100*t.loaded/t.total),o=n.data("uid");this.upload.options.async.chunkSize&&(r=(i=this.metaData[o])&&i.totalChunks?Math.round(i.chunkIndex/i.totalChunks*100):100),this.upload._onFileProgress({target:e(n,this.upload.wrapper)},r)},stopUploadRequest:function(e){e.data("request")&&e.data("request").abort()},prepareChunk:function(e){var t=e.data("files")[0],n=t.rawFile,i=t.uid,r=this.upload.options.async.chunkSize;this.position[i]=0,this.metaData[i]={chunkIndex:0,contentType:n.type,fileName:n.name,relativePath:t.name,totalFileSize:n.size,totalChunks:Math.ceil(n.size/r),uploadUid:i}},_decreaseChunkIndex:function(e){this.metaData[e].chunkIndex--},_increaseChunkIndex:function(e){this.metaData[e].chunkIndex++},_resetChunkIndex:function(e){this.metaData[e].chunkIndex=0},_decreasePosition:function(e){this.position[e]-=this.upload.options.async.chunkSize},_getCurrentChunk:function(e,t){var n,i=this.position[t],r=this.upload.options.async,o=r.chunkSize||r.bufferChunkSize;return this.position[t]||(this.position[t]=0),this.position[t]+=o,(n=this._getChunker(e))?e[n](i,this.position[t]):e},_getChunker:function(e){return e.slice?"slice":e.mozSlice?"mozSlice":e.webkitSlice?"webkitSlice":null}},t.ui.plugin(E)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=e.isPlainObject,o=e.extend,a=n.htmlEncode,s=n.support.placeholder,l=n.isFunction,c=/(^\/|\/$)/g,d="change",u="apply",h="error",p="click",f=".kendoFileBrowser",m=".kendoSearchBox",g="name",v="size",_="type",b={field:_,dir:"asc"},y=n.template((({text:e})=>`<div class="k-listview-item k-listview-item-empty"><span class="k-file-preview"><span class="k-file-icon k-icon k-svg-icon k-i-none"></span></span><span class="k-file-name">${n.htmlEncode(e)}</span></div>`)),w=({showCreate:e,showUpload:t,showDelete:i,messages:r})=>'<div class="k-widget k-filebrowser-toolbar k-toolbar k-toolbar-md k-floatwrap">'+(e?'<button type="button" class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-icon-button">'+n.ui.icon({icon:"folder-add",iconClass:"k-button-icon"})+"</button>":"")+`${t?(({messages:e})=>'<div class="k-upload k-upload-button-wrap"><div class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-upload-button">'+n.ui.icon({icon:"plus",iconClass:"k-button-icon"})+`<span class="k-button-text">${n.htmlEncode(e.uploadFile)}</span></div><input type="file" name="file" /></div>`)({messages:r}):""}`+(i?'<button type="button" class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-icon-button k-disabled">'+n.ui.icon({icon:"x",iconClass:"k-button-icon"})+"</button>":"")+'<div class="k-tiles-arrange">'+`<label>${n.htmlEncode(r.orderBy)}: <select></select></label></div><span class="k-toolbar-spacer"></span><input data-role="searchbox" /></div>`;function k(e,n){return e!==t&&e.match(/\/$/)||(e=(e||"")+"/"),e+n}o(!0,n.data,{schemas:{filebrowser:{data:function(e){return e.items||e||[]},model:{id:"name",fields:{name:"name",size:"size",type:"type"}}}}}),o(!0,n.data,{transports:{filebrowser:n.data.RemoteTransport.extend({init:function(t){n.data.RemoteTransport.fn.init.call(this,e.extend(!0,{},this.options,t))},_call:function(t,i){i.data=e.extend({},i.data,{path:this.options.path()}),l(this.options[t])?this.options[t].call(this,i):n.data.RemoteTransport.fn[t].call(this,i)},read:function(e){this._call("read",e)},create:function(e){this._call("create",e)},destroy:function(e){this._call("destroy",e)},update:function(){},options:{read:{type:"POST"},update:{type:"POST"},create:{type:"POST"},destroy:{type:"POST"}}})}});var x=i.extend({init:function(e,t){var n=this;t=t||{},i.fn.init.call(n,e,t),n.element.addClass("k-filebrowser"),n.element.on(p+f,".k-filebrowser-toolbar button:not(.k-disabled):has(.k-i-x,.k-svg-i-x)",n._deleteClick.bind(n)).on(p+f,".k-filebrowser-toolbar button:not(.k-disabled):has(.k-i-folder-add,.k-svg-i-folder-add)",n._addClick.bind(n)).on("keydown"+f,".k-listview-item.k-selected input",n._directoryKeyDown.bind(n)).on("blur"+f,".k-listview-item.k-selected input",n._directoryBlur.bind(n)),n._dataSource(),n.refresh(),n.path(n.options.path)},options:{name:"FileBrowser",messages:{uploadFile:"Upload",orderBy:"Arrange by",orderByName:"Name",orderBySize:"Size",directoryNotFound:"A directory with this name was not found.",emptyFolder:"Empty Folder",deleteFile:"Are you sure you want to delete {0}?",invalidFileType:"The selected file {0} is not valid. Supported file types are {1}.",overwriteFile:"A file with name {0} already exists in the current directory. Do you want to overwrite it?",dropFilesHere:"drop file here to upload",search:"Search"},transport:{},path:"/",fileTypes:"*.*"},events:[h,d,u],destroy:function(){var e=this;i.fn.destroy.call(e),e.dataSource.unbind(h,e._errorHandler),e.element.add(e.list).add(e.toolbar).off(f),n.destroy(e.element)},value:function(){var e,t=this,i=t._selectedItem(),r=t.options.transport.fileUrl;if(i&&"f"===i.get(_))return e=k(t.path(),i.get(g)).replace(c,""),r&&(e=l(r)?r(e):n.format(r,encodeURIComponent(e))),e},_selectedItem:function(){var e=this.listView.select();if(e.length)return this.dataSource.getByUid(e.attr(n.attr("uid")))},_toolbar:function(){var t=this,i=n.template(w),r=t.options.messages,o=[{text:r.orderByName,value:"name"},{text:r.orderBySize,value:"size"}];t.toolbar=e(i({messages:r,showUpload:t.options.transport.uploadUrl,showCreate:t.options.transport.create,showDelete:t.options.transport.destroy})).appendTo(t.element).find(".k-upload input").kendoUpload({multiple:!1,localization:{dropFilesHere:r.dropFilesHere},async:{saveUrl:t.options.transport.uploadUrl,autoUpload:!0},upload:t._fileUpload.bind(t),error:function(e){t._error({xhr:e.XMLHttpRequest,status:"error"})}}).end(),t.upload=t.toolbar.find(".k-upload input").data("kendoUpload"),t.arrangeBy=t.toolbar.find(".k-tiles-arrange select").kendoDropDownList({dataSource:o,dataTextField:"text",dataValueField:"value",change:function(){t.orderBy(this.value())}}).data("kendoDropDownList"),t.searchBox=t.toolbar.find("input[data-role='searchbox']").kendoSearchBox({label:t.options.messages.search,change:function(){t.search(this.value())}}).data("kendoSearchBox"),t._attachDropzoneEvents()},_attachDropzoneEvents:function(){var t=this;t.options.transport.uploadUrl&&(!function(e,t,n){var i,r;e.on("dragenter"+f,(function(){t(),r=new Date,i||(i=setInterval((function(){new Date-r>100&&(n(),clearInterval(i),i=null)}),100))})).on("dragover"+f,(function(){r=new Date}))}(e(document.documentElement),t._dropEnter.bind(t),t._dropLeave.bind(t)),t._scrollHandler=t._positionDropzone.bind(t))},_dropEnter:function(){this._positionDropzone(),e(document).on("scroll"+f,this._scrollHandler)},_dropLeave:function(){this._removeDropzone(),e(document).off("scroll"+f,this._scrollHandler)},_positionDropzone:function(){var e=this.element,t=e.offset();this.toolbar.find(".k-dropzone").addClass("k-filebrowser-dropzone").offset(t).css({width:e[0].clientWidth,height:e[0].clientHeight,lineHeight:e[0].clientHeight+"px"})},_removeDropzone:function(){this.toolbar.find(".k-dropzone").removeClass("k-filebrowser-dropzone").css({width:"",height:"",lineHeight:"",top:"",left:""})},_deleteClick:function(){var e=this,t=e.listView.select(),i=a(n.format(e.options.messages.deleteFile,t.find(".k-file-name").text()));t.length&&e._showMessage(i,"confirm")&&e.listView.remove(t)},_addClick:function(){this.createDirectory()},_getFieldName:function(e){return function(e,t){var n=e[t];return r(n)?n.from||n.field||t:n}(this.dataSource.reader.model.fields,e)},_fileUpload:function(e){var t,i=this,r=i.options,o=r.fileTypes,s=new RegExp(("("+o.split(",").join(")|(")+")").replace(/\*\./g,".*."),"i"),l=e.files[0].name,c=e.files[0].size,d=g,u=v;s.test(l)?(e.data={path:i.path()},(t=i._createFile(l,c))?i.upload.one("success",(function(e){var r=i._insertFileToList(t);r._override&&(r.set(d,e.response[i._getFieldName(d)]),r.set(u,e.response[i._getFieldName(u)]),i.listView.dataSource.pushUpdate(r)),i._tiles=i.listView.items().filter("["+n.attr("type")+"=f]")})):e.preventDefault()):(e.preventDefault(),i._showMessage(a(n.format(r.messages.invalidFileType,l,o))))},_findFile:function(e){var t,n,i,r=this.dataSource.data(),o=_,a=g;for(e=e.toLowerCase(),t=0,i=r.length;t<i;t++)if("f"===r[t].get(o)&&r[t].get(a).toLowerCase()===e){n=r[t];break}return n},_createFile:function(e,t){var i=this,r={},o=_,s=i._findFile(e);return s?i._showMessage(a(n.format(i.options.messages.overwriteFile,e)),"confirm")?(s._override=!0,s):null:(r[o]="f",r[g]=e,r[v]=t,r)},_insertFileToList:function(e){var t;if(e._override)return e;for(var n=this.dataSource,i=n.view(),r=0,o=i.length;r<o;r++)if("f"===i[r].get(_)){t=r;break}return n.insert(++t,e)},createDirectory:function(){var e,t,i=this,r=0,o=_,a=g,s=i.dataSource.data(),l=i._nameDirectory(),c=new i.dataSource.reader.model;for(e=0,t=s.length;e<t;e++)"d"===s[e].get(o)&&(r=e);c.set(o,"d"),c.set(a,l),i.listView.one("dataBound",(function(){var e=i.listView.items().filter("["+n.attr("uid")+"="+c.uid+"]");e.length&&this.edit(e),this.element.scrollTop(e.attr("offsetTop")-this.element[0].offsetHeight),setTimeout((function(){i.listView.element.find(".k-edit-item input").select()}))})).one("save",(function(e){var t=e.model.get(a);t?e.model.set(a,i._nameExists(t,c.uid)?i._nameDirectory():t):e.model.set(a,l)})),i.dataSource.insert(++r,c)},_directoryKeyDown:function(e){13==e.keyCode&&e.currentTarget.blur()},_directoryBlur:function(){this.listView.save()},_nameExists:function(e,t){var n,i,r=this.dataSource.data(),o=_,a=g;for(n=0,i=r.length;n<i;n++)if("d"===r[n].get(o)&&r[n].get(a).toLowerCase()===e.toLowerCase()&&r[n].uid!==t)return!0;return!1},_nameDirectory:function(){var t,n,i,r="New folder",o=this.dataSource.data(),a=[],s=_,l=g;for(n=0,i=o.length;n<i;n++)"d"===o[n].get(s)&&o[n].get(l).toLowerCase().indexOf(r.toLowerCase())>-1&&a.push(o[n].get(l));if(e.inArray(r,a)>-1){n=2;do{t=r+" ("+n+")",n++}while(e.inArray(t,a)>-1);r=t}return r},orderBy:function(e){this.dataSource.sort([{field:_,dir:"asc"},{field:e,dir:"asc"}])},search:function(e){this.dataSource.filter({field:g,operator:"contains",value:e})},_content:function(){var t=this;t.list=e('<div class="k-filemanager-listview" />').appendTo(t.element).on("dblclick"+f,".k-listview-item",t._dblClick.bind(t)),t.listView=new n.ui.ListView(t.list,{layout:"flex",flex:{direction:"row",wrap:"wrap"},dataSource:t.dataSource,template:t._itemTmpl(),editTemplate:t._editTmpl(),selectable:!0,autoBind:!1,dataBinding:function(e){t.toolbar.find(".k-i-x,.k-svg-i-x").parent().addClass("k-disabled"),"remove"!==e.action&&"sync"!==e.action||(e.preventDefault(),n.ui.progress(t.listView.content,!1),n.ui.progress(t.listView.wrapper,!1))},dataBound:function(){t.dataSource.view().length?t._tiles=this.items().filter("["+n.attr("type")+"=f]"):this.content.append(y({text:t.options.messages.emptyFolder}))},change:t._listViewChange.bind(t)})},_dblClick:function(t){var i=this,r=e(t.currentTarget);if(r.hasClass("k-edit-item")&&i._directoryBlur(),r.filter("["+n.attr("type")+"=d]").length){var o=i.dataSource.getByUid(r.attr(n.attr("uid")));o&&(i.path(k(i.path(),o.get(g))),i.breadcrumbs.value("/"+i.path()))}else r.filter("["+n.attr("type")+"=f]").length&&i.trigger(u)},_listViewChange:function(){var e=this._selectedItem();e&&(this.toolbar.find(".k-i-x,.k-svg-i-x").parent().removeClass("k-disabled"),this.trigger(d,{selected:e}))},_dataSource:function(){var e=this,t=e.options,i=t.transport,a=o({},b),s={field:g,dir:"asc"},l={type:i.type||"filebrowser",sort:[a,s]};r(i)&&(i.path=e.path.bind(e),l.transport=i),r(t.schema)?l.schema=t.schema:i.type&&r(n.data.schemas[i.type])&&n.data.schemas[i.type],e.dataSource&&e._errorHandler?e.dataSource.unbind(h,e._errorHandler):e._errorHandler=e._error.bind(e),e.dataSource=n.data.DataSource.create(l).bind(h,e._errorHandler)},_navigation:function(){var t=this,n=e('<div class="k-floatwrap"><nav></nav></div>').appendTo(this.element);t.breadcrumbs=n.find("nav").first().kendoBreadcrumb({editable:!0,gap:50,value:t.options.path||"/",change:function(){t.path(this.value())}}).data("kendoBreadcrumb")},_error:function(e){var t,i=this;if(!i.trigger(h,e)){t=e.xhr.status,"error"==e.status?"404"==t?i._showMessage(n.htmlEncode(i.options.messages.directoryNotFound)):"0"!=t&&i._showMessage("Error! The requested URL returned "+t+" - "+e.xhr.statusText):"timeout"==t&&i._showMessage("Error! Server timeout.");var r=i.dataSource;r.hasChanges()&&r.cancelChanges()}},_showMessage:function(e,t){return window[t||"alert"](e)},refresh:function(){var e=this;e._navigation(),e._toolbar(),e._content()},_editTmpl:function(){return n.template((e=>`<div class="k-listview-item k-selected" ${n.attr("uid")}="${e.uid}">`+("d"===e[_]?'<div class="k-file-preview">'+n.ui.icon({icon:"folder",iconClass:"k-file-icon",size:"xxxlarge"})+"</div>":'<div class="k-file-preview"><span class="k-file-icon k-icon k-i-loading"></span></div>')+("d"===e[_]?`<span class="k-file-name">\n                            <span class="k-textbox k-input k-input-md k-rounded-md k-input-solid">\n                                <input class="k-input-inner" ${n.attr("bind")}="value:${g}"/>\n                            </span>\n                        </span>`:"")+"</div>"))},_itemTmpl:function(){return n.template((e=>`<div class="k-listview-item" ${n.attr("uid")}="${e.uid}" ${n.attr("type")}="${e[_]}">`+("d"===e[_]?'<div class="k-file-preview">'+n.ui.icon({icon:"folder",iconClass:"k-file-icon",size:"xxxlarge"})+"</div>":'<div class="k-file-preview">'+n.ui.icon({icon:"file",iconClass:"k-file-icon",size:"xxxlarge"})+"</div>")+`<span class="k-file-name">${e[g]}</span>`+("f"===e[_]?`<span class="k-file-size">${function(e){if(!e)return"";var t=" bytes";return e>=1073741824?(t=" GB",e/=1073741824):e>=1048576?(t=" MB",e/=1048576):e>=1024&&(t=" KB",e/=1024),Math.round(100*e)/100+t}(e[v])}</span>`:"")+"</div>"))},path:function(e){var n=this,i=n._path||"";return e!==t?(n._path=e.replace(c,"")+"/",void n.dataSource.read({path:n._path})):(i&&(i=i.replace(c,"")),"/"===i||""===i?"":i+"/")}}),C=i.extend({init:function(e,t){var n=this;t=t||{},i.fn.init.call(n,e,t),s&&n.element.attr("placeholder",n.options.label),n._wrapper(),n.element.on("keydown"+m,n._keydown.bind(n)).on("change"+m,n._updateValue.bind(n)),n.wrapper.on(p+m,"a",n._click.bind(n)),s||n.element.on("focus"+m,n._focus.bind(n)).on("blur"+m,n._blur.bind(n))},options:{name:"SearchBox",label:"Search",value:""},events:[d],destroy:function(){var e=this;e.wrapper.add(e.element).add(e.label).off(m),i.fn.destroy.call(e)},_keydown:function(e){13===e.keyCode&&this._updateValue()},_click:function(e){e.preventDefault(),this._updateValue()},_updateValue:function(){var e=this,t=e.element.val();t!==e.value()&&(e.value(t),e.trigger(d))},_blur:function(){this._updateValue(),this._toggleLabel()},_toggleLabel:function(){s||this.label.toggle(!this.element.val())},_focus:function(){this.label.hide()},_wrapper:function(){var t=this.element,i=t.parents(".k-search-wrap");t[0].style.width="",t.addClass("k-input-inner"),i.length||(i=t.wrap(e('<div class="k-widget k-search-wrap"><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"></span></div>')).parents(".k-search-wrap"),s||e("<label>"+this.options.label+"</label>").css("display","block").insertBefore(t),e('<span class="k-input-suffix">'+n.ui.icon(e('<a href="#" />'),{icon:"search",iconClass:"k-search"})+"</span>").appendTo(i.find(".k-textbox"))),this.wrapper=i,this.label=i.find(">label")},value:function(e){var n=this;return e!==t?(n.options.value=e,n.element.val(e),void n._toggleLabel()):n.options.value}});n.ui.plugin(x),n.ui.plugin(C)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.FileBrowser,r=e.isPlainObject,o=e.extend,a=n.isFunction,s=/(^\/|\/$)/g,l="error",c=".kendoImageBrowser",d="name",u="size",h="type",p={field:h,dir:"asc"},f=n.template((({text:e})=>`<div class="k-listview-item k-listview-item-empty"><span class="k-file-preview">${n.ui.icon({icon:"none",iconClass:"k-file-icon"})}</span><span class="k-file-name">${n.htmlEncode(e)}</span></div>`));o(!0,n.data,{schemas:{imagebrowser:{data:function(e){return e.items||e||[]},model:{id:"name",fields:{name:"name",size:"size",type:"type"}}}}}),o(!0,n.data,{transports:{imagebrowser:n.data.RemoteTransport.extend({init:function(t){n.data.RemoteTransport.fn.init.call(this,e.extend(!0,{},this.options,t))},_call:function(t,i){i.data=e.extend({},i.data,{path:this.options.path()}),a(this.options[t])?this.options[t].call(this,i):n.data.RemoteTransport.fn[t].call(this,i)},read:function(e){this._call("read",e)},create:function(e){this._call("create",e)},destroy:function(e){this._call("destroy",e)},update:function(){},options:{read:{type:"POST"},update:{type:"POST"},create:{type:"POST"},destroy:{type:"POST"}}})}});var m=i.extend({init:function(e,t){t=t||{},i.fn.init.call(this,e,t),this.element.addClass("k-imagebrowser")},options:{name:"ImageBrowser",fileTypes:"*.png,*.gif,*.jpg,*.jpeg"},value:function(){var e,i=this,r=i._selectedItem(),o=i.options.transport.imageUrl;if(r&&"f"===r.get(h))return e=function(e,n){return e!==t&&e.match(/\/$/)||(e=(e||"")+"/"),e+n}(i.path(),r.get(d)).replace(s,""),o&&(e=a(o)?o(e):n.format(o,encodeURIComponent(e))),e},_fileUpload:function(e){var i,r=this,o=r.options,a=o.fileTypes,s=new RegExp(("("+a.split(",").join(")|(")+")").replace(/\*\./g,".*."),"i"),l=e.files[0].name,c=e.files[0].size,h=d,p=u;s.test(l)?(e.data={path:r.path()},(i=r._createFile(l,c))?(i._uploading=!0,r.upload.one("error",(function(){i=t})),r.upload.one("success",(function(e){if(i){delete i._uploading;var t=r._insertFileToList(i);t.set(h,e.response[r._getFieldName(h)]),t.set(p,e.response[r._getFieldName(p)]),r._tiles=r.listView.items().filter("["+n.attr("type")+"=f]"),r._scroll()}}))):e.preventDefault()):(e.preventDefault(),r._showMessage(n.htmlEncode(n.format(o.messages.invalidFileType,l,a))))},_content:function(){var t=this;t.list=e('<div class="k-filemanager-listview" />').appendTo(t.element).on("dblclick"+c,".k-listview-item",t._dblClick.bind(t)),t.listView=new n.ui.ListView(t.list,{layout:"flex",flex:{direction:"row",wrap:"wrap"},dataSource:t.dataSource,template:t._itemTmpl(),editTemplate:t._editTmpl(),selectable:!0,autoBind:!1,dataBinding:function(e){t.toolbar.find(".k-i-x,.k-svg-i-x").parent().addClass("k-disabled"),"remove"!==e.action&&"sync"!==e.action||(e.preventDefault(),n.ui.progress(t.listView.content,!1),n.ui.progress(t.listView.wrapper,!1))},dataBound:function(){t.dataSource.view().length?(t._tiles=this.items().filter("["+n.attr("type")+"=f]"),t._scroll()):this.content.append(f({text:t.options.messages.emptyFolder}))},change:t._listViewChange.bind(t)}),t.listView.content.on("scroll"+c,t._scroll.bind(t))},_dataSource:function(){var e=this,t=e.options,i=t.transport,a=o({},p),s={field:d,dir:"asc"},c={type:i.type||"imagebrowser",sort:[a,s]};r(i)&&(i.path=e.path.bind(e),c.transport=i),r(t.schema)?c.schema=t.schema:i.type&&r(n.data.schemas[i.type])&&n.data.schemas[i.type],e.dataSource&&e._errorHandler?e.dataSource.unbind(l,e._errorHandler):e._errorHandler=e._error.bind(e),e.dataSource=n.data.DataSource.create(c).bind(l,e._errorHandler)},_loadImage:function(t){var i=this,r=e(t),o=i.dataSource.getByUid(r.attr(n.attr("uid"))),s=o.get(d),l=i.options.transport.thumbnailUrl,u=e("<img />",{alt:s}),h="?";o._uploading||(u.hide().on("load"+c,(function(){e(this).prev().remove().end().addClass("k-image k-file-image").fadeIn()})),r.find(".k-i-loading").after(u),a(l)?l=l(i.path(),encodeURIComponent(s)):(l.indexOf("?")>=0&&(h="&"),l=l+h+"path="+encodeURIComponent(i.path()+s),o._override&&(l+="&_="+(new Date).getTime(),delete o._override)),u.attr("src",l),t.loaded=!0)},_scroll:function(){var t=this;t.options.transport&&t.options.transport.thumbnailUrl&&(clearTimeout(t._timeout),t._timeout=setTimeout((function(){var i=n._outerHeight(t.listView.content),r=t.listView.content.scrollTop(),o=r+i;t._tiles.each((function(){var n=function(t){return t.offsetTop-e(t).height()}(this),i=n+this.offsetHeight;if((n>=r&&n<o||i>=r&&i<o)&&t._loadImage(this),n>o)return!1})),t._tiles=t._tiles.filter((function(){return!this.loaded}))}),250))},_itemTmpl:function(){var e=this;return n.template((t=>{const i=e.options.transport&&e.options.transport.thumbnailUrl;return`<div class="k-listview-item" ${n.attr("uid")}="${t.uid}" ${n.attr("type")}="${t[h]}">`+("d"===t[h]?`<div class="k-file-preview">${n.ui.icon({icon:"folder",iconClass:"k-file-icon"})}</div>`:`<div class="k-file-preview">${i?'<span class="k-file-icon k-icon k-i-loading"></span>':n.ui.icon({icon:"file",iconClass:"k-file-icon"})}</div>`)+`<span class="k-file-name">${t[d]}</span>`+("f"===t[h]?`<span class="k-file-size">${function(e){if(!e)return"";var t=" bytes";return e>=1073741824?(t=" GB",e/=1073741824):e>=1048576?(t=" MB",e/=1048576):e>=1024&&(t=" KB",e/=1024),Math.round(100*e)/100+t}(t[u])}</span>`:"")+"</div>"}))}});n.ui.plugin(m)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.ui,o=e.isPlainObject,a=".kendoTextArea",s="change",l="disabled",c="readonly",d="k-focus",u="k-disabled",h="k-readonly",p="aria-disabled",f=i.extend({init:function(r,o){var a=this;i.fn.init.call(a,r,o),o=e.extend(!0,{},o),a.options.value=o.value||a.element.val(),a.options.readonly=o.readonly!==t?o.readonly:Boolean(a.element.attr("readonly")),a.options.enable=o.enable!==t?o.enable:!Boolean(a.element.attr("disabled")),a.options.placeholder=o.placeholder||a.element.attr("placeholder"),a.options.maxLength=o.maxLength||a.element.attr("maxlength"),a.options.value.replace(/\s/g,"").length||(a.options.value="",a.element.val("")),a.value(a.options.value),a._wrapper(),a._label(),a._editable({readonly:a.options.readonly,disable:!a.options.enable}),a._applyAttributes(),a._applyCssClasses(),a.element.attr("autocomplete","off"),Tf({widget:a,wrapper:a.wrapper,options:a.options}),a.floatingLabel&&a.floatingLabel.refresh(),n.notify(a)},events:[s],attributes:["maxLength","rows","placeholder"],options:{name:"TextArea",value:"",readonly:!1,enable:!0,placeholder:"",label:null,resizable:"none",maxLength:null,cols:20,rows:1,rounded:"medium",size:"medium",fillMode:"solid",resize:"none",overflow:"auto",layoutFlow:"vertical",prefixOptions:{separator:!0},suffixOptions:{separator:!0}},_applyCssClasses:function(e){var t=this,r=t.options,o=n.cssProperties.getValidClass({widget:r.name,propName:"resize",value:r.resize}),a=n.cssProperties.getValidClass({widget:r.name,propName:"overflow",value:r.overflow}),s=n.cssProperties.getValidClass({widget:r.name,propName:"layoutFlow",value:r.layoutFlow});i.fn._applyCssClasses.call(t),o||"none"!==r.resize||(o="k-resize-none"),a&&(a="!"+a),e=e||"addClass",t.element[e](o),t.element[e](a),t.element[e]("k-input-inner"),t.wrapper[e](s),"vertical"==r.layoutFlow&&t.element[e]("!k-flex-none")},_applyAttributes:function(){var e,t=this,n={};for(e in t.attributes)n[t.attributes[e]]=t.options[t.attributes[e]];t.element.attr(n)},value:function(e){var n=this;if(e===t)return n._value;n._value=e,n.element.val(e)},readonly:function(e){this._editable({readonly:e===t||e,disable:!1}),this.floatingLabel&&this.floatingLabel.readonly(e===t||e)},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)}),this.floatingLabel&&this.floatingLabel.enable(e=e===t||e)},focus:function(){this.element[0].focus()},destroy:function(){var e=this;e._applyCssClasses("removeClass"),e.floatingLabel&&e.floatingLabel.destroy(),e._inputLabel&&(e._inputLabel.remove(),e._inputLabel=null),e.element[0].style.cssText=e.wrapper[0].style.cssText,e.element.off(a),e.element.unwrap(),e.wrapper=null,i.fn.destroy.call(e)},setOptions:function(e){var t=this;t.destroy(),t.init(t.element,e)},_editable:function(e){var t=this,n=t.element,i=t.wrapper,r=e.disable,o=e.readonly;n.off(a),o||r?(n.attr(l,r).attr(c,o).attr(p,r),i.toggleClass(u,r).toggleClass(h,o)):(n.prop(l,!1).prop(c,!1).attr(p,!1),i.removeClass(u).removeClass(h),n.on("focusin"+a,t._focusin.bind(t)),n.on("focusout"+a,t._focusout.bind(t)))},_label:function(){var t,i,r=this,a=r.element,s=r.options,l=a.attr("id");null!==s.label&&(t=!!o(s.label)&&s.label.floating,i=o(s.label)?s.label.content:s.label,t&&(r._floatingLabelContainer=r.wrapper.wrap("<span></span>").parent(),r.floatingLabel=new n.ui.FloatingLabel(r._floatingLabelContainer,{widget:r}),r._floatingLabelContainer.addClass("k-textarea-container")),n.isFunction(i)&&(i=i.call(r)),i||(i=""),l||(l=s.name+"_"+n.guid(),a.attr("id",l)),r._inputLabel=e("<label class='"+(t?"k-floating-label":"k-label k-input-label")+"' for='"+l+"'>"+i+"</label>'")[t?"insertAfter":"insertBefore"](r.wrapper))},_focusin:function(){this.wrapper.addClass(d)},_focusout:function(){var e=this,t=e._value,n=e.element.val();e.wrapper.removeClass(d),null===t&&(t=""),t!==n&&(e._value=n,e.trigger(s))},_wrapper:function(){var e,t=this.element,n=t[0];(e=t.wrap("<span class='k-input k-textarea'></span>").parent())[0].style.cssText=n.style.cssText,n.style.width="",this.wrapper=e.addClass(n.className).removeClass("input-validation-error")}});n.cssProperties.registerPrefix("TextArea","k-input-"),n.cssProperties.registerValues("TextArea",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),r.plugin(f)}(window.kendo.jQuery);kendo;!function(e){var t=e.Observable.extend({init:function(t){e.Observable.fn.init.call(this,t),this.clear()},events:["undo","redo"],push:function(e){this.stack=this.stack.slice(0,this.currentCommandIndex+1),this.currentCommandIndex=this.stack.push(e)-1},undo:function(){if(this.canUndo()){var e=this.stack[this.currentCommandIndex--];e.undo(),this.trigger("undo",{command:e})}},redo:function(){if(this.canRedo()){var e=this.stack[++this.currentCommandIndex];e.redo(),this.trigger("redo",{command:e})}},clear:function(){this.stack=[],this.currentCommandIndex=-1},canUndo:function(){return this.currentCommandIndex>=0},canRedo:function(){return this.currentCommandIndex!=this.stack.length-1}});e.deepExtend(e,{util:{UndoRedoStack:t}})}(kendo),function(e,t){var n=window.kendo,i=n.Class,r=n.ui.Widget,o=n.support.mobileOS,a=n.support.browser,s=e.extend,l=n.deepExtend,c=n.keys,d=n._outerWidth,u=n._outerHeight;const h="formatting-marks-style",p="formatting-marks-overlay",f="formatting-marks-overlay-wrapper";var m="select",g="k-placeholder",v="placeholder",_=["insertLineBreak","insertParagraph","redo","undo","autoLink"];var b={editorWrapperTemplate:()=>'<div class="k-editor"><div class="k-editor-toolbar" role="toolbar"></div><div class="k-editable-area k-editor-content"></div></div>',formatByName:function(t,n){for(var i=0;i<n.length;i++)if(e.inArray(t,n[i].tags)>=0)return n[i]},getToolCssClass:function(e,t){var n={superscript:"supscript",subscript:"subscript",justifyLeft:"align-left",justifyCenter:"align-center",justifyRight:"align-right",justifyFull:"align-justify",insertUnorderedList:"list-unordered",insertOrderedList:"list-ordered",insertUpperRomanList:"list-roman-upper",insertLowerRomanList:"list-roman-lower",import:"import",indent:"indent",outdent:"outdent",createLink:"link",unlink:"unlink",insertImage:"image",insertFile:"file-add",viewHtml:"code",foreColor:"foreground-color",backColor:"droplet",createTable:"table-add",addColumnLeft:"table-column-insert-left",addColumnRight:"table-column-insert-right",addRowAbove:"table-row-insert-above",addRowBelow:"table-row-insert-below",deleteRow:"table-row-delete",deleteColumn:"table-column-delete",mergeCellsHorizontally:"cells-merge-horizontally",mergeCellsVertically:"cells-merge-vertically",splitCellHorizontally:"cell-split-horizontally",splitCellVertically:"cell-split-vertically",tableProperties:"table-properties",tableCellProperties:"table-cell-properties",tableWizardInsert:"table-wizard",tableAlignLeft:"table-position-start",tableAlignCenter:"table-position-center",tableAlignRight:"table-position-end",cleanFormatting:"clear-css",copyFormat:"copy-format",applyFormat:"apply-format",pdf:"file-pdf"}[e];return n||(t||b.nameToKebab(e))},nameToKebab:function(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase()},registerTool:function(e,t){t.name||(t.options.name=e,t.name=e.toLowerCase()),t.options.ui||(t.options.ui={}),t.options.ui.command=e,k.defaultTools[e]=t},registerFormat:function(e,t){k.fn.options.formats[e]=t},cacheComments:function(e,t){for(var n in t)e=e.replace(t[n],"{"+n+"}");return e},retrieveComments:function(e,t){for(var n in t)e=e.replace("{"+n+"}",t[n]);return e}},y=void 0!==document.documentElement.contentEditable,w={basic:["bold","italic","underline","strikethrough"],undo:["undo","redo"],scripts:["subscript","superscript"],alignment:["justifyLeft","justifyCenter","justifyRight","justifyFull"],lines:["lineHeight"],symbols:["formattingMarks"],links:["insertImage","insertFile","createLink","unlink"],lists:["insertUnorderedList","insertOrderedList","insertUpperRomanList","insertLowerRomanList"],dent:["indent","outdent"],tablesWizard:["tableProperties","tableCellProperties"],tablesInsert:["createTable"],tablesAddDelete:["addColumnLeft","addColumnRight","addRowAbove","addRowBelow","deleteRow","deleteColumn"],tablesMerge:["mergeCellsHorizontally","mergeCellsVertically","splitCellHorizontally","splitCellVertically"],tablesPosition:["tableAlignLeft","tableAlignCenter","tableAlignRight"],formatPainter:["copyFormat","applyFormat"]},k=r.extend({__suppressEditableCheck:!1,init:function(e,i){var o,a,s,c=this,d=n.ui.editor,u=d.Dom;(y||c.__suppressEditableCheck)&&(r.fn.init.call(c,e,i),c.options=l({},c.options,i),s=(e=c.element)[0],a=u.name(s),this._registerHandler(e.closest("form"),"submit",c.update.bind(c,t)),o=c._setupType(e),c._initToolbar(o),c._setupHeight(a),c._resizable(),c._initializeContentElement(c),c._setupKeyboard(),c.clipboard=new d.Clipboard(this),c.undoRedoStack=new n.util.UndoRedoStack,c._populateValue(i,s),c._registerHandler(document,{mousedown:function(){c._endTyping()},mouseup:function(e){c._mouseup(e)}}),c._registerHandler(window,"resize",c._handleSpaceAndNewLines.bind(c)),c._initializeImmutables(),"textarea"==a&&c._ariaLabel(c.wrapper.find("iframe")),c.toolbar.resize(),c._initInlineOverflowWrapper(),n.notify(c),c._showWatermarkOverlay&&c._showWatermarkOverlay(c.wrapper&&c.wrapper[0]||c.element[0]))},events:["select","change","execute","error","paste","keydown","keyup"],options:{name:"Editor",messages:{auto:"Auto",bold:"Bold",italic:"Italic",underline:"Underline",strikethrough:"Strikethrough",superscript:"Superscript",subscript:"Subscript",fitToCell:"Fit to cell",justifyCenter:"Center text",justifyLeft:"Align text left",justifyRight:"Align text right",justifyFull:"Justify",insertUnorderedList:"Insert unordered list",insertOrderedList:"Insert ordered list",lineHeight:"Set line height",formattingMarks:"Toggle formatting marks",indent:"Indent",outdent:"Outdent",createLink:"Insert hyperlink",unlink:"Remove hyperlink",insertImage:"Insert image",insertFile:"Insert file",insertHtml:"Insert HTML",viewHtml:"View HTML",fontName:"Select font family",fontNameInherit:"(inherited font)",fontSize:"Select font size",fontSizeInherit:"(inherited size)",formatBlock:"Format",formatting:"Format",foreColor:"Color",backColor:"Background color",style:"Styles",emptyFolder:"Empty Folder",editAreaTitle:"Editable area. Press F10 for toolbar.",uploadFile:"Upload",overflowAnchor:"More tools",orderBy:"Arrange by:",orderBySize:"Size",orderByName:"Name",invalidFileType:"The selected file {0} is not valid. Supported file types are {1}.",deleteFile:"Are you sure you want to delete {0}?",overwriteFile:"A file with name {0} already exists in the current directory. Do you want to overwrite it?",directoryNotFound:"A directory with this name was not found.",imageWebAddress:"Web address",imageAltText:"Alternate text",imageWidth:"Width (px)",imageHeight:"Height (px)",fileWebAddress:"Web address",fileTitle:"Title",fileText:"Text",linkWebAddress:"Web address",linkText:"Text",linkToolTip:"ToolTip",linkOpenInNewWindow:"Open link in new window",dialogUpdate:"Update",dialogInsert:"Insert",dialogOk:"Confirm",dialogCancel:"Cancel",cleanFormatting:"Clean formatting",createTable:"Create a table",createTableHint:"Create a {0} x {1} table",addColumnLeft:"Add column on the left",addColumnRight:"Add column on the right",addRowAbove:"Add row above",addRowBelow:"Add row below",deleteRow:"Delete row",deleteColumn:"Delete column",mergeCellsHorizontally:"Merge cells horizontally",mergeCellsVertically:"Merge cells vertically",splitCellHorizontally:"Split cells horizontally",splitCellVertically:"Split cells vertically",tableAlignLeft:"Table Align Left",tableAlignCenter:"Table Align Center",tableAlignRight:"Table Align Right",tableWizard:"Table Wizard",tableProperties:"Table Properties",tableCellProperties:"Cell Properties",tableTab:"General",cellTab:"Cell",accessibilityTab:"Advanced",caption:"Caption",summary:"Summary",width:"Width",height:"Height",units:"Units",cellSpacing:"Cell Spacing",cellPadding:"Cell Padding",topPadding:"Top",leftPadding:"Left",bottomPadding:"Bottom",rightPadding:"Right",independentCellPaddings:"Independent Cell Paddings",cellMargin:"Cell Margin",alignment:"Alignment",captionAlignment:"Caption alignment",position:"Position",background:"Background",tableBackground:"Table background",cssClass:"CSS Class",id:"ID",border:"Border",borderStyle:"Border Style",borderWidth:"Border Width",borderColor:"Border Color",collapseBorders:"Collapse borders",wrapText:"Wrap text",associateCellsWithHeaders:"Associate headers",alignLeft:"Align Left",alignCenter:"Align Center",alignRight:"Align Right",alignLeftTop:"Align Left Top",alignCenterTop:"Align Center Top",alignRightTop:"Align Right Top",alignLeftMiddle:"Align Left Middle",alignCenterMiddle:"Align Center Middle",alignRightMiddle:"Align Right Middle",alignLeftBottom:"Align Left Bottom",alignCenterBottom:"Align Center Bottom",alignRightBottom:"Align Right Bottom",alignRemove:"Remove Alignment",columns:"Columns",rows:"Rows",selectAllCells:"Apply to all cells",applyToColumn:"apply to column",applyToRow:"apply to row",exportAs:"Export As",import:"Import",print:"Print",headerRows:"Header Rows",headerColumns:"Header Cols",tableSummaryPlaceholder:"Summary attribute is not HTML5 compatible.",associateNone:"None",associateScope:"Associate using 'scope' attribute",associateIds:"Associate using Ids",copyFormat:"Copy format",applyFormat:"Apply format",borderNone:"None",undo:"Undo",redo:"Redo"},placeholder:"",nonce:"",unsafeInline:!0,formats:{},encoded:!0,formattingMarksRefreshDelay:250,domain:null,resizable:!1,deserialization:{custom:null},serialization:{entities:!0,semantic:!0,scripts:!1,optimizeTags:!1,keepEOL:!1},pasteCleanup:{all:!1,css:!1,custom:null,keepNewLines:!1,msAllFormatting:!1,msConvertLists:!0,msTags:!0,none:!1,span:!1},stylesheets:[],dialogOptions:{modal:!0,resizable:!1,draggable:!0,animation:!1},imageBrowser:null,fileBrowser:null,navigateOnTab:!1,fontName:[{text:"Arial",value:"Arial, Helvetica, sans-serif"},{text:"Courier New",value:'"Courier New", Courier, monospace'},{text:"Georgia",value:"Georgia, serif"},{text:"Impact",value:"Impact, Charcoal, sans-serif"},{text:"Lucida Console",value:'"Lucida Console", Monaco, monospace'},{text:"Tahoma",value:"Tahoma, Geneva, sans-serif"},{text:"Times New Roman",value:'"Times New Roman", Times, serif'},{text:"Trebuchet MS",value:'"Trebuchet MS", Helvetica, sans-serif'},{text:"Verdana",value:"Verdana, Geneva, sans-serif"}],fontSize:[{text:"1 (8pt)",value:"xx-small"},{text:"2 (10pt)",value:"x-small"},{text:"3 (12pt)",value:"small"},{text:"4 (14pt)",value:"medium"},{text:"5 (18pt)",value:"large"},{text:"6 (24pt)",value:"x-large"},{text:"7 (36pt)",value:"xx-large"}],formatBlock:[{text:"Paragraph",value:"p"},{text:"Quotation",value:"blockquote"},{text:"Heading 1",value:"h1"},{text:"Heading 2",value:"h2"},{text:"Heading 3",value:"h3"},{text:"Heading 4",value:"h4"},{text:"Heading 5",value:"h5"},{text:"Heading 6",value:"h6"}],tools:["formatting","bold","italic","underline","undo","redo","justifyLeft","justifyCenter","justifyRight","copyFormat","applyFormat","insertUnorderedList","insertOrderedList","indent","outdent","createLink","unlink","insertImage","tableProperties","tableCellProperties","createTable","addRowAbove","addRowBelow","addColumnLeft","addColumnRight","deleteRow","deleteColumn","mergeCellsHorizontally","mergeCellsVertically","splitCellHorizontally","splitCellVertically","tableAlignLeft","tableAlignCenter","tableAlignRight"]},destroy:function(){var e=this;r.fn.destroy.call(this),this._endTyping(!0),this._deregisterHandlers(),clearTimeout(this._spellCorrectTimeout),this._focusOutside(),this.toolbar.destroy(),this.windowInstance&&this.windowInstance.destroy(),this.tablePopup&&this.tablePopup.destroy(),e._destroyUploadWidget(),this.interSectionObserver&&(this.interSectionObserver.disconnect(),this.interSectionObserver=null),this.resizeObserver&&(this.resizeObserver.disconnect(),this.resizeObserver=null,this.wrapper.css("min-height",""),this.wrapper.css("max-height","")),e._destroyResizings(),e._destroyFormattingMarksOverlay(),n.destroy(this.wrapper)},setOptions:function(e){r.fn.setOptions.call(this,e),e.tools&&this._setOptionsTools(e.tools),this._initializePlaceholder()},createRange:function(e){return n.ui.editor.RangeUtils.createRange(e||this.document)},encodedValue:function(){return n.ui.editor.Dom.encode(this.value())},exec:function(e,t){var i,r,o=this,a=null,l=n.ui.Editor.defaultTools;if(!e)throw new Error("kendoEditor.exec(): `name` parameter cannot be empty");if("true"!==o.body.getAttribute("contenteditable")&&"print"!==e&&"pdf"!==e&&"exportAs"!==e)return!1;if(o.keyboard.isTypingInProgress()||(o._focusBody(),o.selectRange(o._range||o.getRange())),(r=o.tools[e]||l[e])||Object.keys(l).map((t=>{t.toLowerCase()===e&&(r=l[t])})),r){if(i=o.getRange(),r.command&&(a=r.command(s({range:i,body:o.body,immutables:!!o.immutables},t))),o.trigger("execute",{name:e,command:a}))return;if(/^(undo|redo)$/i.test(e))o.undoRedoStack[e]();else if(a&&(o.execCommand(a),a.async))return void(a.change=o._commandChange.bind(o));"formattingMarks"!==e&&o._handleSpaceAndNewLines(),o._selectionChange()}},_commandChange:function(){this._selectionChange(),this._handleSpaceAndNewLines()},execCommand:function(e){e.managesUndoRedo||this.undoRedoStack.push(e),e.editor=this,e.exec()},focus:function(){this.restoreSelection()},getRange:function(){var e=this.getSelection(),t=e&&e.rangeCount>0?e.getRangeAt(0):this.createRange(),n=this.document;return t.startContainer!=n||t.endContainer!=n||t.startOffset||t.endOffset||(t.setStart(this.body,0),t.collapse(!0)),t},getSelection:function(){return n.ui.editor.SelectionUtils.selectionFromDocument(this.document)},paste:function(t,i){this.focus();var r=new n.ui.editor.InsertHtmlCommand(e.extend({range:this.getRange(),html:t},i));r.editor=this,r.exec()},refresh:function(){var e=this;if(e.textarea){e._destroyResizings();var t=e.value();e.textarea.val(t),e.wrapper.find("iframe").remove(),e._initializeContentElement(e),e.value(t)}},restoreSelection:function(){this._focusBody(),this.selectionRestorePoint&&this.selectRange(this.selectionRestorePoint.toRange())},saveSelection:function(t){var i=(t=t||this.getRange()).commonAncestorContainer,r=this.body;(i==r||e.contains(r,i))&&(this.selectionRestorePoint=new n.ui.editor.RestorePoint(t,r))},selectedHtml:function(){return n.ui.editor.Serializer.domToXhtml(this.getRange().cloneContents())},selectRange:function(e){this._focusBody();var t=this.getSelection();t.removeAllRanges(),t.addRange(e),this.saveSelection(e)},state:function(e){var t,i,r=n.ui.Editor.defaultTools[e],o=r&&(r.options.finder||r.finder),a=n.ui.editor.RangeUtils;return!!o&&(t=this.getRange(),!(i=a.textNodes(t)).length&&t.collapsed&&(i=[t.startContainer]),o.getFormat?o.getFormat(i):o.isFormatted(i))},update:function(e){e=e||this.options.encoded?this.encodedValue():this.value(),this.textarea?(this.textarea.val(e),this._togglePlaceholder(!e.trim())):this._oldValue=e},value:function(e){var i=this.body,r=n.ui.editor,o=this.options,a=r.Serializer.domToXhtml(i,o.serialization);if(e===t)return a;e!=a&&(r.Serializer.htmlToDom(e,i,o.deserialization),this.selectionRestorePoint=null,this.update(),this._refreshTools())},_bindTools:function(){var t=this,n=this.tools;t.unbind("select",t.toolbar.resize.bind(t.toolbar)),t.toolbar.element.find("[data-command]").filter(((t,n)=>0===e(n).find("[data-command]").length)).each(((i,r)=>{var o=r.getAttribute("data-command"),a=n[o];a&&a.initialize&&a.initialize(e(r),t)})),t.bind("select",t.toolbar.resize.bind(t.toolbar))},_blur:function(){var e=this.textarea,t=e?e.val():this._oldValue,n=this.options.encoded?this.encodedValue():this.value();this.update(),e&&e.trigger("blur"),n!=t&&(this.trigger("change"),e&&e.trigger("change"))},_containsRange:function(e){var t=n.ui.editor.Dom,i=this.body;return e&&t.isAncestorOrSelf(i,e.startContainer)&&t.isAncestorOrSelf(i,e.endContainer)},_createContentElement:function(t){var i,r,s,l,c=this,d=c.textarea,u=c.options.domain,h=u||document.domain,p="",f='javascript:""';d.hide(),i=e("<iframe />",{title:c.options.messages.editAreaTitle,frameBorder:"0"})[0],e(i).css("display","").addClass("k-content k-iframe").attr("tabindex",d[0].tabIndex).insertBefore(d),(u||h!=location.hostname)&&(f="javascript:document.write('"+(p=`<script ${c.options.nonce?`nonce="${c.options.nonce}"`:""}>document.domain="${h}"<\/script>`)+"')",i.src=f),i.src||(i.src=""),r=i.contentWindow||i,s=r.document||i.contentDocument;const m=c.interSectionObserver=new IntersectionObserver((e=>{for(const t of e)t.isIntersecting&&(c._decorateFormatting(s.body),m.unobserve(i))}));return m.observe(i),l=document.getElementsByTagName("html")[0].getAttribute("lang")||"en",s.open(),s.write("<!DOCTYPE html><html lang='"+l+"'><head><meta charset='utf-8' /><title>Kendo UI Editor content</title>"+`<style ${c.options.nonce?`nonce="${c.options.nonce}"`:""}>html{padding:0;margin:0;height:100%;min-height:100%;cursor:text;}body{padding:0;margin:0;}body{box-sizing:border-box;font-size:12px;font-family:Verdana,Geneva,sans-serif;margin-top:-1px;padding:5px .4em 0;word-wrap: break-word;-webkit-nbsp-mode: space;-webkit-line-break: after-white-space;`+(n.support.isRtl(d)?"direction:rtl;":"")+(o.ios?"word-break:keep-all;":"")+(a.edge||a.chrome?"height:100%;":"")+"}h1{font-size:2em;margin:.67em 0}h2{font-size:1.5em}h3{font-size:1.16em}h4{font-size:1em}h5{font-size:.83em}h6{font-size:.7em}p{margin:0 0 1em;}.k-marker{display:none;}.k-paste-container,.Apple-style-span{position:absolute;left:-10000px;width:1px;height:1px;overflow:hidden}ul,ol{padding-left:2.5em}span{-ms-high-contrast-adjust:none;}a{color:#00a}code{font-size:1.23em}telerik\\3Ascript{display: none;}.k-table{width:100%;border-spacing:0;margin: 0 0 1em;}.k-table td{min-width:1px;padding:.2em .3em;}.k-table,.k-table td{outline:0;border: 1px dotted #ccc;}.k-table th{outline:0;border: 1px dotted #999;}.k-table p{margin:0;padding:0;}.k-column-resize-handle-wrapper {position: absolute; height: 10px; width:10px; cursor: col-resize; z-index: 2;}.k-column-resize-handle {width: 100%; height: 100%;}.k-column-resize-handle > .k-column-resize-marker {width:2px; height:100%; margin:0 auto; background-color:#00b0ff; display:none; opacity:0.8;}.k-row-resize-handle-wrapper {position: absolute; cursor: row-resize; z-index:2; width: 10px; height: 10px;}.k-row-resize-handle {display: table; width: 100%; height: 100%;}.k-row-resize-marker-wrapper{display: table-cell; height:100%; width:100%; margin:0; padding:0; vertical-align: middle;}.k-row-resize-marker{margin: 0; padding:0; width:100%; height:2px; background-color: #00b0ff; opacity:0.8; display:none;}.k-element-resize-handle-wrapper {position: absolute; background-color: #fff; border: 1px solid #000; z-index: 100; width: 5px; height: 5px;}.k-element-resize-handle {width: 100%; height: 100%;}.k-element-resize-handle.k-resize-east{cursor:e-resize;}.k-element-resize-handle.k-resize-north{cursor:n-resize;}.k-element-resize-handle.k-resize-northeast{cursor:ne-resize;}.k-element-resize-handle.k-resize-northwest{cursor:nw-resize;}.k-element-resize-handle.k-resize-south{cursor:s-resize;}.k-element-resize-handle.k-resize-southeast{cursor:se-resize;}.k-element-resize-handle.k-resize-southwest{cursor:sw-resize;}.k-element-resize-handle.k-resize-west{cursor:w-resize;}.k-table.k-element-resizing{opacity:0.6;}.k-placeholder{color:grey}k\\:script{display:none;}</style>"+p+e.map(t,(function(e){return`<link rel='stylesheet' href='${e}' ${c.options.nonce?`nonce="${c.options.nonce}"`:""}>`})).join("")+`</head><body id='${c.element.attr("id")}' autocorrect='off' contenteditable='true'></body></html>`),s.close(),r},_deleteSavedRange:function(){"_range"in this&&delete this._range},_decorateFormatting:function(t){var i,r,o,a,s,l,c,d=this.toolbar.element.find("input[data-command=formatting]"),u=n.ui.editor.Dom;if(d.length){if(!(i=d.getKendoDropDownList()))return;if(o=(r=i.dataSource).data(),t&&i.list.css("background-color",u.getEffectiveBackground(e(t))),!1!==this.options.unsafeInline)for(a=0;a<o.length;a++)s=o[a].tag||"span",l=o[a].className,c=(c=u.inlineStyle(t,s,{className:l})).replace(/"/g,"'"),o[a].style=c+";display:inline-block";r.trigger("change")}},_appendFormattingMarksStyles:function(){const t=this,n=t.element.attr("id");let i,r;i=`<style id='${h+"-"+n}' ${t.options.nonce?`nonce="${t.options.nonce}"`:""} >\n                #${n} p::after,\n                #${n} li::after,\n                #${n} h1::after,\n                #${n} h2::after,\n                #${n} h3::after,\n                #${n} h4::after,\n                #${n} h5::after,\n                #${n} h6::after {content: '\\00B6'; color: #6098f2;}\n                #${f+"-"+n} {\n                    position: absolute;\n                    top: 0;\n                    left: 0;\n                    width: 100%;\n                    z-index: 9999;\n                    pointer-events: none;\n                }\n                #${p+"-"+n} {\n                    width: 100%;\n                    height: 100%;\n                  }\n            </style>`,r=e(t.document.head),r.find("#"+h+"-"+n).remove(),r.append(i)},_appendFormattingMarksOverlay:function(){const t=this,n=t.element.attr("id");t._formattingMarksOverlayWrapper=e(`<div id='${f+"-"+n}'></div>`),t._formattingMarksOverlay=e(`<svg id='${p+"-"+n}'></svg>`).appendTo(t._formattingMarksOverlayWrapper),t._bodyTopBottomPaddings=parseFloat(e(t.body).css("padding-top"))+parseFloat(e(t.body).css("padding-bottom")),t._isInlineEditor()?t._formattingMarksOverlayWrapper.insertAfter(t.element):t._formattingMarksOverlayWrapper.appendTo(e(t.document).find("html"))},_destroyFormattingMarksOverlay:function(){const t=this,n=t.element.attr("id");e(t.document).find("#"+f+"-"+n).remove(),e(t.document.head).find("#"+h+"-"+n).remove()},_updateFormattingMarksOverlayHeight:function(){const t=this;t._isInlineEditor()?t._formattingMarksOverlayWrapper.height(e(t.body).outerHeight()):t._formattingMarksOverlayWrapper.height(t.body.scrollHeight-t._bodyTopBottomPaddings)},_initInlineOverflowWrapper:function(){const e=this,t=e.options.inlineHeight;e._isInlineEditor()&&t>-1&&(e._inlineOverflowWrapper=e.element.wrap("<div class='k-inline-editor-overflow-wrapper k-pos-relative k-overflow-auto'></div>").parent(),e._inlineOverflowWrapper.height(t))},_deregisterHandlers:function(){for(var e=this._handlers,t=0;t<e.length;t++){var n=e[t];n.element.off(n.type,n.handler)}this._handlers=[]},_destroyUploadWidget:function(){var e=this;e._uploadWidget&&(e._uploadWidget.destroy(),e._uploadWidget=null)},_endTyping:function(){var e=this.keyboard;try{e.isTypingInProgress()&&(e.endTyping(!0),this.saveSelection())}catch(e){}},_focusBody:function(){var e,t=this.body,i=this.wrapper&&this.wrapper.find("iframe")[0],r=this.document.documentElement,o=n._activeElement();!i&&t.scrollHeight>t.clientHeight?(e=t.scrollTop,t.focus(),t.scrollTop=e):o!=t&&o!=i&&(e=r.scrollTop,t.focus(),r.scrollTop=e)},_focusOutside:function(){n.support.browser.msie&&this.textarea&&e("<input />").css({position:"fixed",left:"1px",top:"1px",width:"1px",height:"1px","font-size":"0",border:"0",opacity:"0"}).appendTo(document.body).trigger("focus").trigger("blur").remove()},_handleToolbarClick:function(e){var t=e.target.data("command");t&&"createTable"!==t&&this.exec(t)},_immutablesContext:function(e){var t=n.ui.editor;if(this.options.immutables)return e.collapsed?t.Immutables.immutablesContext(e):0===t.RangeUtils.editableTextNodes(e).length},_initializeContentElement:function(){var i,r,o,a=this;if(a.textarea){if(a.window=a._createContentElement(a.options.stylesheets),!(i=a.document=a.window.contentDocument||a.window.document).body){var s=i.createElement("body");s.setAttribute("contenteditable","true"),s.setAttribute("autocorrect","off"),i.getElementsByTagName("html")[0].appendChild(s);var l=setInterval((function(){e(a.document).find("body").length>1&&(e(a.document).find("body").last().remove(),window.clearInterval(l))}),10)}a.body=i.body,r=a.window,o=i,this._registerHandler(i,"mouseup",this._mouseup.bind(this))}else a.window=window,i=a.document=document,a.body=a.element[0],r=a.body,o=a.body,setTimeout((()=>{a._decorateFormatting(a.body)}));this._registerHandler(r,"blur",this._blur.bind(this)),a._registerHandler(o,"down",a._mousedown.bind(a));try{i.execCommand("enableInlineTableEditing",null,!1)}catch(e){}n.support.touch&&this._registerHandler(i,{keydown:function(){n._activeElement()!=i.body&&a.window.focus()}}),this._initializePlaceholder(),this._spellCorrect(a),this._registerHandler(a.document,{"mouseover dragenter":function(t){var n=e(a.body).height();e(a.body.parentElement).height()>n&&"html"===t.target.nodeName.toLowerCase()&&(a._cachedHeight=""+a.body.style.height,a.body.style.height="100%")},"mouseout dragleave drop contextmenu":function(e){var n=function(){a._cachedHeight!==t&&e.target===a.body&&(a.body.style.height=a._cachedHeight,delete a._cachedHeight)};"contextmenu"===e.type?setTimeout((function(){n()}),10):n()}}),this._registerHandler(a.body,{keydown:function(e){var t;if((e.keyCode===c.BACKSPACE||e.keyCode===c.DELETE)&&"true"!==a.body.getAttribute("contenteditable"))return!1;if(e.keyCode===c.F10)return a.toolbar.element.find("[tabindex=0]").first().trigger("focus"),a.toolbar.preventPopupHide=!0,void e.preventDefault();if(e.keyCode==c.LEFT||e.keyCode==c.RIGHT){t=a.getRange();var n=e.keyCode==c.LEFT,i=t[n?"startContainer":"endContainer"],r=t[n?"startOffset":"endOffset"],o=r+(n?-1:1),s=n?o:r;3==i.nodeType&&"\ufeff"==i.nodeValue[s]&&(t.setStart(i,o),t.collapse(!0),a.selectRange(t))}var l=a.tools,d=a.keyboard.toolFromShortcut(l,e),u=d?l[d].options:{};if(d&&!u.keyPressCommand)return e.preventDefault(),/^(undo|redo)$/.test(d)||a.keyboard.endTyping(!0),a.trigger("keydown",e),a.exec(d),a._runPostContentKeyCommands(e),!1;a.keyboard.clearTimeout(),a.keyboard.keydown(e)},keypress:function(e){setTimeout((function(){a._runPostContentKeyCommands(e),a._showElementResizeHandles()}),0)},keyup:function(t){var n=[c.BACKSPACE,c.TAB,c.PAGEUP,c.PAGEDOWN,c.END,c.HOME,c.LEFT,c.UP,c.RIGHT,c.DOWN,c.INSERT,c.DELETE];(e.inArray(t.keyCode,n)>-1||65==t.keyCode&&t.ctrlKey&&!t.altKey&&!t.shiftKey)&&(window.clearTimeout(this._refreshInterval),this._refreshInterval=window.setTimeout((function(){a._selectionChange()}),200)),t.keyCode!==c.BACKSPACE&&t.keyCode!==c.DELETE||a._handleSpaceAndNewLines(),a.keyboard.keyup(t)},click:function(e){var t;"img"===n.ui.editor.Dom.name(e.target)&&((t=a.createRange()).selectNode(e.target),a.selectRange(t))},"cut copy paste drop dragover":function(e){a.clipboard["on"+e.type](e),a._handleSpaceAndNewLines()},focusin:function(){a.body.hasAttribute("contenteditable")&&(e(this).addClass("k-active"),a._showWindow(),a._togglePlaceholder(!1))},focusout:function(){setTimeout((function(){var t=n._activeElement(),i=a.body,r=a.toolbar;if(r.options.popup){var o=a.windowInstance.element.get(0);o&&!e.contains(o,t)&&o!=t&&(r.preventPopupHide=!1)}t==i||e.contains(i,t)||a._toolbarFocused()||r.preventPopupHide||e(t).hasClass("k-context-menu")||e(t).hasClass("k-colorpalette")||(e(i).removeClass("k-active"),a._hideWindow()),a._togglePlaceholder(!a.value().trim())}),10)}}),a._initializeColumnResizing(),a._initializeRowResizing(),a._initializeElementResizing()},_initializeImmutables:function(){var e=this,t=n.ui.editor;e.options.immutables&&(e.immutables=new t.Immutables(e))},_initializePlaceholder:function(){var t,n,i=this,r=i.options.placeholder;i.textarea&&r&&(t=`<style id='${v}' ${i.options.nonce?`nonce="${i.options.nonce}"`:""} >.`+g+":before { content: '"+r+"'; }</style>",(n=e(i.document.head)).find("#"+v).remove(),n.append(t),i._togglePlaceholder(!i.value().trim()))},_initToolbar:function(t){var i,r,o,a=this;a.tools=[],[i,r]=a._processToolbarItems(a.options.tools),a._setNativeTools(),o={tools:i,defaultTools:r,parentMessages:a.options.messages,resizable:a.options.resizable&&a.options.resizable.toolbar,toggle:a._handleToolbarClick.bind(this),click:a._handleToolbarClick.bind(this),navigateOnTab:a.options.navigateOnTab,evaluateTemplates:!0},a.toolbar=new n.ui.ToolBar(t,o),a._bindTools(),a.bind("select",a._refreshTools.bind(a)),t.on("mousedown.kendoEditor","[ref-toolbar-tool]",(function(t){e(t.target).is("input")||t.preventDefault()})),a.textarea||a._initToolbarWindow(t)},_initToolbarWindow:function(t){var i=this;this.windowInstance=t.wrap("<div class='editorToolbarWindow k-editor-window' />").parent().prepend("<span class='k-editortoolbar-dragHandle'>"+n.ui.icon("handle-drag")+"</span>").kendoWindow({title:!1,resizable:!1,draggable:{dragHandle:".k-editortoolbar-dragHandle"},animation:{open:{effects:"fade:in"},close:{effects:"fade:out"}},minHeight:42,visible:!1,autoFocus:!1,actions:[],dragend:function(){this._moved=!0}}).on("mousedown",(function(t){e(t.target).is(".k-icon,.k-svg-icon,svg,path,.k-editor-window,.k-editor-toolbar,.k-editortoolbar-dragHandle,[ref-toolbar-tool],[ref-toolbar-tool] *")||(i.toolbar.preventPopupHide=!0)})).on("focusout",(function(){i.element.focusout()})).data("kendoWindow")},_mousedown:function(t){var n=this;if(n._selectionStarted=!0,e(n.body).parents(".k-window").length&&t.stopPropagation(),!a.gecko){var i=e(t.target).closest("a[href]");(2==t.which||1==t.which&&t.ctrlKey)&&i&&i.is("a[href]")&&window.open(i.attr("href"),"_new"),t.target.tagName&&"html"===t.target.tagName.toLowerCase()&&setTimeout((function(){n.body.focus()}),0)}},_mouseup:function(t){var i=this;n.support.mobileOS.ios&&t&&e(t.target).is("select.k-select-overlay")||i._selectionStarted&&setTimeout((function(){i._selectionChange()}),1)},_populateValue:function(t,i){var r,o,a=this,s=n.ui.editor,l=s.Dom;if(t&&t.value)r=t.value;else if(a.textarea){(r=i.value).replace(/\s/g,"").length||(r=r.replace(/\s/g,"")),a.options.encoded&&i.defaultValue&&i.defaultValue.trim().length&&(r=i.defaultValue);var c=s.Serializer.htmlToDom(r,e("<div></div>")[0],a.options.deserialization);o=l.getAllComments(c),r=(r=b.cacheComments(r,o)).replace(/[\r\n\v\f\t ]+/gi," "),r=b.retrieveComments(r,o)}else r=i.innerHTML;a.value(r||"\ufeff")},_resetGroups:function(e){var t={};return Object.keys(e).map((n=>{t[n+"_"]=e[n]})),t},_processToolbarItems:function(i){var r,o,a,s,l,c,d={},u={},h=e.extend(!0,{},w);for(o=0;o<i.length;o++)if(s=i[o],Array.isArray(s))for(c=n.guid(),a=0;a<s.length;a++)[d,l]=this._processToolOptions(s[a],d),l&&(d[l].gr=c);else{if([d,l]=this._processToolOptions(s,d),!l)continue;"separator"===l&&(h=this._resetGroups(h)),Object.keys(h).map((e=>{h[e].includes(l)&&(d[l].gr=e)}))}return Object.values(d).map((e=>{var n=e.gr;delete e.gr,n===t?u[e.name]=e:(u[n]||(u[n]=[]),u[n].push(e))})),r=Object.values(u).map((e=>{var t;return 1===(t=e.length?e.map((e=>e.name)):e.name).length&&(t=t[0]),t})),[r,d]},_processDefaultTool:function(t,n){var i,r=t.name,o={};if(e.isPlainObject(t))r&&n[r]?(o=s({},n[r]),s(o.options,t)):((i=s({icon:"gear",type:"button"},t)).name||(i.name="custom"),i.cssClass="k-"+i.name,o={options:i},r=i.name);else{if(!n[t])return null;o=n[r=t]}return this.tools[r]=o,o},_processToolOptions:function(i,r){var o,a,s,l,c,d,u,h,p,f,m=this,g=n.deepExtend({},n.ui.Editor.defaultTools);return(o=this._processDefaultTool(i,g))?(a=(c=o.options).name,d=c.ui||{},u=b.getToolCssClass(c.name,c.icon),delete(p=e.isPlainObject(i)?e.extend({},i):{}).items,h=e.extend({name:c.name,command:c.command,template:c.template,type:"button",icon:u,showText:"overflow",showIcon:"both"},d,p),c.tooltip&&(h.attributes||(h.attributes={}),h.attributes.title=c.tooltip),c.exec&&(h.click=c.exec.bind(m),delete h.exec),"ColorPicker"===h.component&&(c.palette===t&&d.palette===n.ui.editor.ColorTool.fn.options.palette||(f=c.palette||n.ui.editor.ColorTool.fn.options.palette,s=c.palette===t||c.palette?"palette":"gradient",h.componentOptions.palette="palette"===s?f:t,h.componentOptions.views=[s],h.componentOptions.preview="gradient"===s,h.componentOptions.input="gradient"===s,h.componentOptions.buttons="gradient"===s,"gradient"===s&&delete h.componentOptions.columns),"palette"===s&&c.columns&&(h.componentOptions.columns=c.columns)),"DropDownList"!==h.component&&"ComboBox"!==h.component||(h.componentOptions||(h.componentOptions={}),h.componentOptions.dataSource||(m.options[a]&&Array.isArray(m.options[a])?h.componentOptions.dataSource=m.options[a]:h.componentOptions.dataSource=c.items)),h.template&&delete h.type,""!==(l=this._shortcutSequence(a))&&(h.attributes||(h.attributes={}),h.attributes["aria-keyshortcuts"]=l),r[a]=h,[r,a]):[r,null]},_refreshTools:function(){var t=this,i=t.getRange(),r=n.ui.editor,o=r.RangeUtils.textNodes(i),a=t.options.immutables,s=t._immutablesContext(i),l=t.tools;(o=r.Dom.filterBy(o,r.Dom.htmlIndentSpace,!0)).length||(o=[i.startContainer]),t.toolbar.element.find("[data-command]").filter(((t,n)=>0===e(n).find("[data-command]").length)).each((function(){var n,i=this.getAttribute("data-command"),r=l[i];r&&(n=e(this),r.update&&r.update(n,o,t.undoRedoStack),a&&t._updateImmutablesState(r,n,s))}))},_registerHandler:function(t,i,r){var o,a,s=".kendoEditor";if(t=e(t),this._handlers||(this._handlers=[]),t.length)if(e.isPlainObject(i))for(var l in i)i.hasOwnProperty(l)&&this._registerHandler(t,l,i[l]);else for(o=n.applyEventMap(i).split(" "),a=0;a<o.length;a++)this._handlers.push({element:t,type:o[a]+s,handler:r}),t.on(o[a]+s,r)},_runPostContentKeyCommands:function(e){for(var t=this.getRange(),n=this.keyboard.toolsFromShortcut(this.tools,e),i=0;i<n.length;i++){var r=n[i],o=r.options;if(o.keyPressCommand)new o.command({range:t}).changesContent()&&(this.keyboard.endTyping(!0),this.exec(r.name))}this._handleSpaceAndNewLines()},_handleSpaceAndNewLines:function(){const e=this,t=e.options.formattingMarksRefreshDelay,i=n.ui.editor,r=i.applyFormattingMarks,o=i.clearFormattingMarksOverlay;e._toggledFormattingMarks&&(e._formattingMarksOverlay.children().length&&o(e),t?(clearTimeout(e._formattingMarksTimeout),e._formattingMarksTimeout=setTimeout((()=>r(e)),t)):r(e))},_selectionChange:function(){this._selectionStarted=!1,this.saveSelection(),this.trigger("select",{})},_setOptionsTools:function(e){var t,i,r,o=this,a=o.toolbar,s=a.element;a.destroy(),s.empty(),o.tools=[],[t,i]=o._processToolbarItems(e),o._setNativeTools(),r={tools:t,defaultTools:i,parentMessages:o.options.messages,resizable:o.options.resizable&&o.options.resizable.toolbar,toggle:o._handleToolbarClick.bind(this),click:o._handleToolbarClick.bind(this)},o.toolbar=new n.ui.ToolBar(s,r),o._bindTools()},_setNativeTools:function(){var e,t=n.deepExtend({},n.ui.Editor.defaultTools);for(e=0;e<_.length;e++)this.tools[_[e]]||(this.tools[_[e]]=t[_[e]])},_setupHeight:function(e){var t=this;"textarea"==e&&setTimeout((function(){var e=t.wrapper[0].style.height,n=parseInt(e,10),i=t.wrapper.height();e.indexOf("px")>0&&!isNaN(n)&&i>n&&t.wrapper.height(n-(i-n))}))},_setupKeyboard:function(){var e=this,t=n.ui.editor;e.keyboard=new t.Keyboard([new t.BackspaceHandler(e),new t.TypingHandler(e),new t.SystemHandler(e),new t.SelectAllHandler(e)])},_setupType:function(t){var i,r=t[0],o=n.ui.editor.Dom.name(r),a=r.id;return a||(a=n.guid(),r.setAttribute("id",a)),"textarea"==o?(this._wrapTextarea(),(i=this.wrapper.find(".k-editor-toolbar")).attr("aria-controls",a)):(e(r).attr("contenteditable",!0).addClass("k-editor k-editor-inline"),i=e('<div class="k-editor-toolbar"/>').insertBefore(t)),i},_isInlineEditor:function(){return this.element.hasClass("k-editor-inline")},_shortcutSequence:function(e){var t,i=n.ui.Editor.defaultTools[e],r="";return i&&i.options?((t=i.options).ctrl&&(r+="Ctrl+"),t.shift&&(r+="Shift+"),t.alt&&(r+="Alt+"),t.key&&(r+=t.key),r):r},_spellCorrect:function(e){var t,i=!1;this._registerHandler(e.body,{contextmenu:function(){e.one("select",(function(){t=null})),e._spellCorrectTimeout=setTimeout((function(){t=new n.ui.editor.RestorePoint(e.getRange(),e.body),i=!1}),10)},input:function(){t&&(!n.support.browser.mozilla||i?n.ui.editor._finishUpdate(e,t):i=!0)}})},_togglePlaceholder:function(t){var n=this,i=n.body,r=e(i),o=n.options.placeholder;n.textarea&&o&&(r.attr("aria-label",(function(){return t?o:""})),r.toggleClass(g,t))},_toolbarFocused:function(){var t=n._activeElement(),i=this.windowInstance,r=this.overflowPopup;return i&&e(t).closest(i.wrapper).length||r&&r.visible()},_updateImmutablesState:function(i,r,o){var a=this.toolbar,s=i.name,l=r.closest("[ref-toolbar-tool]"),c=i.options.trackImmutables,d=n.ui.editor;c===t&&(c=e.inArray(s,d.Immutables.toolsToBeUpdated)>-1),c&&(o?a.hide(l):a.show(l))},_wrapTextarea:function(){var t=this,n=t.element,i=n[0].style.width,r=n[0].style.height,o=b.editorWrapperTemplate(),a=e(o).insertBefore(n),s=a.find(".k-editable-area");a.css({width:i,height:r}),n.attr("autocomplete","off").appendTo(s).addClass("k-content k-raw-content").css("display","none"),t.textarea=n,t.wrapper=a},_resizable:function(){let n=this,i=this.options.resizable,r=e.isPlainObject(i)?i.content===t||!0===i.content:i,o=e.isPlainObject(i.min)?i.min:{minHeight:i.min},a=e.isPlainObject(i.max)?i.max:{maxHeight:i.max};r&&this.textarea&&(n.wrapper.addClass("k-editor-resizable"),o.minHeight&&n.wrapper.css("min-height",o.minHeight),a.maxHeight&&n.wrapper.css("max-height",a.maxHeight),o.minWidth&&n.wrapper.css("min-width",o.minWidth),a.maxWidth&&n.wrapper.css("max-width",a.maxWidth),n.resizeObserver=new ResizeObserver((()=>{clearTimeout(n._resizeTimeOut),n._resizeTimeOut=setTimeout((function(){n.toolbar.resize(),n._handleSpaceAndNewLines()}),50)})),n.resizeObserver.observe(n.wrapper[0]))},_destroyResizings:function(){var e=this;e._destroyElementResizing(),n.ui.editor.ElementResizingFactory.current.dispose(e),e._destroyRowResizing(),n.ui.editor.RowResizing.dispose(e),e._destroyColumnResizing(),n.ui.editor.ColumnResizing.dispose(e)},_initializeElementResizing:function(){var e=this;n.ui.editor.ElementResizingFactory.current.create(e),e._showElementResizeHandlesProxy=e._showElementResizeHandles.bind(e),e.bind(m,e._showElementResizeHandlesProxy)},_destroyElementResizing:function(){var e=this,t=e.elementResizing;t&&(t.destroy(),e.elementResizing=null),e._showElementResizeHandlesProxy&&e.unbind(m,e._showElementResizeHandlesProxy)},_showElementResizeHandles:function(){var e=this.elementResizing;e&&e.element&&e.element.parentNode?e.showResizeHandles():!e||e.element&&e.element.parentNode||this._destroyElementResizing()},_initializeColumnResizing:function(){n.ui.editor.ColumnResizing.create(this)},_destroyColumnResizing:function(){var e=this;e.columnResizing&&(e.columnResizing.destroy(),e.columnResizing=null)},_initializeRowResizing:function(){n.ui.editor.RowResizing.create(this)},_destroyRowResizing:function(){var e=this;e.rowResizing&&(e.rowResizing.destroy(),e.rowResizing=null)},_getWindowWidth:function(){var e=this.windowInstance.wrapper,t=this.element;return d(t)-parseInt(e.css("border-left-width"),10)-parseInt(e.css("border-right-width"),10)},_hideWindow:function(){this.windowInstance&&this.windowInstance.close()},_overlapsWindow:function(e){var t=this.windowInstance.wrapper,n=t.offset(),i=n.left,r=n.top,o=e.offset(),a=o.left,s=o.top;return!(a+e.width()<i||a>i+t.width()||s+e.height()<r||s>r+t.height())},_showWindow:function(){var e,t,i,r=this,o=r.windowInstance,a=n.support.browser;o&&(e=o.wrapper,t=r.element,e.is(":visible")&&r.windowInstance.options.visible||(e[0].style.width||e.width(this._getWindowWidth()),o._moved||(i=t.offset(),e.css({top:Math.max(0,parseInt(i.top,10)-u(e)-parseInt(r.windowInstance.element.css("padding-bottom"),10)),left:Math.max(0,parseInt(i.left,10))})),(a.msie||a.edge)&&r._overlapsWindow(t)?setTimeout((function(){o.open()}),0):o.open()))}});k.defaultTools={},n.ui.plugin(k);var x=i.extend({init:function(e){this.options=e},command:function(e){return new this.options.command(e)},update:e.noop});x.exec=function(e,t,n){e.exec(t,{value:n})};var C=x.extend({command:e.noop,update:function(e,t,n){var i=this.options.name,r=e.closest(".k-toolbar").data("kendoToolBar");switch(i){case"undo":r.enable(e,n.canUndo());break;case"redo":r.enable(e,n.canRedo())}e.removeAttr("disabled")}});b.registerTool("separator",new x({ui:{type:"separator"}})),b.registerTool("undo",new C({key:"Z",ctrl:!0})),b.registerTool("redo",new C({key:"Y",ctrl:!0}));var S="\ufeff",T=S;(a.msie||a.edge)&&(T=S="&nbsp;"),s(n.ui,{editor:{EditorUtils:b,Tool:x,emptyElementContent:S,emptyTableCellContent:T}}),n.PDFMixin&&(n.PDFMixin.extend(k.prototype),k.prototype._drawPDF=function(){return n.drawing.drawDOM(this.body,this.options.pdf)},k.prototype.saveAsPDF=function(){var t=new e.Deferred,i=t.promise(),r={promise:i};if(!this.trigger("pdfExport",r)){var o=this.options.pdf;return this._drawPDF(t).then((function(e){return n.drawing.exportPDF(e,o)})).done((function(e){n.saveAs({dataURI:e,fileName:o.fileName,proxyURL:o.proxyURL,proxyTarget:o.proxyTarget,forceProxy:o.forceProxy}),t.resolve()})).fail((function(e){t.reject(e)})),i}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.map,i=e.extend,r=t.support.browser,o="style",a="float",s="cssFloat",l="styleFloat",c="class",d="k-marker";function u(e){var t,n,i={};for(t=0,n=e.length;t<n;t++)i[e[t]]=!0;return i}var h=u("area,base,basefont,br,col,frame,hr,img,input,isindex,link,meta,param,embed".split(",")),p="p,div,h1,h2,h3,h4,h5,h6,address,applet,blockquote,button,center,dd,dir,dl,dt,fieldset,form,frameset,hr,iframe,isindex,map,menu,noframes,noscript,object,pre,script,table,tbody,td,tfoot,th,thead,tr,header,article,nav,footer,section,aside,main,figure,figcaption".split(","),f=p.concat(["ul","ol","li"]),m=u(f),g=u("area,base,br,col,command,embed,hr,img,input,keygen,link,menuitem,meta,param,source,track,wbr".split(",")),v="span,em,a,abbr,acronym,applet,b,basefont,bdo,big,br,button,cite,code,del,dfn,font,i,iframe,img,input,ins,kbd,label,map,object,q,s,samp,script,select,small,strike,strong,sub,sup,textarea,tt,u,var,data,time,mark,ruby".split(","),_=u(v),b=u("checked,compact,declare,defer,disabled,ismap,multiple,nohref,noresize,noshade,nowrap,readonly,selected".split(",")),y=["hgroup","ol","ul","dl","object","video","audio","table","colgroup","tbody","thead","tfoot","tr","select","optgroup"],w=function(e){1==e.nodeType&&e.normalize()};r.msie&&r.version>=8&&(w=function(e){if(1==e.nodeType&&e.firstChild){var t=e.firstChild,n=t;for(w(n);n=n.nextSibling;)w(n),3==n.nodeType&&3==t.nodeType&&(n.nodeValue=t.nodeValue+n.nodeValue,z.remove(t)),t=n}});var k,x=/^\s+$/,C=/^[\n\r\t]+$/,S=/rgb\s*\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\)/i,T=/\ufeff/g,D=/^(\s+|\ufeff)$/,A="color,padding-left,padding-right,padding-top,padding-bottom,background-color,background-attachment,background-image,background-position,background-repeat,border-top-style,border-top-width,border-top-color,border-bottom-style,border-bottom-width,border-bottom-color,border-left-style,border-left-width,border-left-color,border-right-style,border-right-width,border-right-color,font-family,font-size,font-style,font-variant,font-weight,line-height".split(","),M=/[<>&]/g,E=/[\u00A0-\u2666<>&]/g,I={34:"quot",38:"amp",39:"apos",60:"lt",62:"gt",160:"nbsp",161:"iexcl",162:"cent",163:"pound",164:"curren",165:"yen",166:"brvbar",167:"sect",168:"uml",169:"copy",170:"ordf",171:"laquo",172:"not",173:"shy",174:"reg",175:"macr",176:"deg",177:"plusmn",178:"sup2",179:"sup3",180:"acute",181:"micro",182:"para",183:"middot",184:"cedil",185:"sup1",186:"ordm",187:"raquo",188:"frac14",189:"frac12",190:"frac34",191:"iquest",192:"Agrave",193:"Aacute",194:"Acirc",195:"Atilde",196:"Auml",197:"Aring",198:"AElig",199:"Ccedil",200:"Egrave",201:"Eacute",202:"Ecirc",203:"Euml",204:"Igrave",205:"Iacute",206:"Icirc",207:"Iuml",208:"ETH",209:"Ntilde",210:"Ograve",211:"Oacute",212:"Ocirc",213:"Otilde",214:"Ouml",215:"times",216:"Oslash",217:"Ugrave",218:"Uacute",219:"Ucirc",220:"Uuml",221:"Yacute",222:"THORN",223:"szlig",224:"agrave",225:"aacute",226:"acirc",227:"atilde",228:"auml",229:"aring",230:"aelig",231:"ccedil",232:"egrave",233:"eacute",234:"ecirc",235:"euml",236:"igrave",237:"iacute",238:"icirc",239:"iuml",240:"eth",241:"ntilde",242:"ograve",243:"oacute",244:"ocirc",245:"otilde",246:"ouml",247:"divide",248:"oslash",249:"ugrave",250:"uacute",251:"ucirc",252:"uuml",253:"yacute",254:"thorn",255:"yuml",402:"fnof",913:"Alpha",914:"Beta",915:"Gamma",916:"Delta",917:"Epsilon",918:"Zeta",919:"Eta",920:"Theta",921:"Iota",922:"Kappa",923:"Lambda",924:"Mu",925:"Nu",926:"Xi",927:"Omicron",928:"Pi",929:"Rho",931:"Sigma",932:"Tau",933:"Upsilon",934:"Phi",935:"Chi",936:"Psi",937:"Omega",945:"alpha",946:"beta",947:"gamma",948:"delta",949:"epsilon",950:"zeta",951:"eta",952:"theta",953:"iota",954:"kappa",955:"lambda",956:"mu",957:"nu",958:"xi",959:"omicron",960:"pi",961:"rho",962:"sigmaf",963:"sigma",964:"tau",965:"upsilon",966:"phi",967:"chi",968:"psi",969:"omega",977:"thetasym",978:"upsih",982:"piv",8226:"bull",8230:"hellip",8242:"prime",8243:"Prime",8254:"oline",8260:"frasl",8472:"weierp",8465:"image",8476:"real",8482:"trade",8501:"alefsym",8592:"larr",8593:"uarr",8594:"rarr",8595:"darr",8596:"harr",8629:"crarr",8656:"lArr",8657:"uArr",8658:"rArr",8659:"dArr",8660:"hArr",8704:"forall",8706:"part",8707:"exist",8709:"empty",8711:"nabla",8712:"isin",8713:"notin",8715:"ni",8719:"prod",8721:"sum",8722:"minus",8727:"lowast",8730:"radic",8733:"prop",8734:"infin",8736:"ang",8743:"and",8744:"or",8745:"cap",8746:"cup",8747:"int",8756:"there4",8764:"sim",8773:"cong",8776:"asymp",8800:"ne",8801:"equiv",8804:"le",8805:"ge",8834:"sub",8835:"sup",8836:"nsub",8838:"sube",8839:"supe",8853:"oplus",8855:"otimes",8869:"perp",8901:"sdot",8968:"lceil",8969:"rceil",8970:"lfloor",8971:"rfloor",9001:"lang",9002:"rang",9674:"loz",9824:"spades",9827:"clubs",9829:"hearts",9830:"diams",338:"OElig",339:"oelig",352:"Scaron",353:"scaron",376:"Yuml",710:"circ",732:"tilde",8194:"ensp",8195:"emsp",8201:"thinsp",8204:"zwnj",8205:"zwj",8206:"lrm",8207:"rlm",8211:"ndash",8212:"mdash",8216:"lsquo",8217:"rsquo",8218:"sbquo",8220:"ldquo",8221:"rdquo",8222:"bdquo",8224:"dagger",8225:"Dagger",8240:"permil",8249:"lsaquo",8250:"rsaquo",8364:"euro"},z={block:m,inline:_,findNodeIndex:function(e,t){var n=0;if(!e)return-1;for(;e=e.previousSibling;)t&&3==e.nodeType||n++;return n},isDataNode:function(e){return e&&null!==e.nodeValue&&null!==e.data},isAncestorOf:function(t,n){try{return!z.isDataNode(t)&&(e.contains(t,z.isDataNode(n)?n.parentNode:n)||n.parentNode==t)}catch(e){return!1}},isAncestorOrSelf:function(e,t){return z.isAncestorOf(e,t)||e==t},findClosestAncestor:function(e,t){if(z.isAncestorOf(e,t))for(;t&&t.parentNode!=e;)t=t.parentNode;return t},getAllComments:function(e){for(var t=[],n=document.createNodeIterator(e,NodeFilter.SHOW_COMMENT,(function(){return NodeFilter.FILTER_ACCEPT}),!1),i=n.nextNode();i;)t.push(i.nodeValue),i=n.nextNode();return t},getNodeLength:function(e){return z.isDataNode(e)?e.length:e.childNodes.length},splitDataNode:function(e,t){for(var n,i=e.cloneNode(!1),r="",o=e.nextSibling;o&&3==o.nodeType&&o.nodeValue;)r+=o.nodeValue,n=o,o=o.nextSibling,z.remove(n);e.deleteData(t,e.length),i.deleteData(0,t),i.nodeValue+=r,z.insertAfter(i,e)},attrEquals:function(e,n){for(var i in n){var r=e[i];if(i==a&&(r=e[t.support.cssFloat?s:l]),"object"==typeof r){if(!z.attrEquals(r,n[i]))return!1}else if(r!=n[i])return!1}return!0},blockParentOrBody:function(e){return z.parentOfType(e,f)||e.ownerDocument.body},blockParents:function(t){var n,i,r=[];for(n=0,i=t.length;n<i;n++){var o=z.parentOfType(t[n],z.blockElements);o&&e.inArray(o,r)<0&&r.push(o)}return r},windowFromDocument:function(e){return e.defaultView||e.parentWindow},normalize:w,blockElements:f,nonListBlockElements:p,inlineElements:v,empty:h,fillAttrs:b,nodeTypes:{ELEMENT_NODE:1,ATTRIBUTE_NODE:2,TEXT_NODE:3,CDATA_SECTION_NODE:4,ENTITY_REFERENCE_NODE:5,ENTITY_NODE:6,PROCESSING_INSTRUCTION_NODE:7,COMMENT_NODE:8,DOCUMENT_NODE:9,DOCUMENT_TYPE_NODE:10,DOCUMENT_FRAGMENT_NODE:11,NOTATION_NODE:12},toHex:function(e){var t=S.exec(e);return t?"#"+n(t.slice(1),(function(e){return(e=parseInt(e,10).toString(16)).length>1?e:"0"+e})).join(""):e},encode:function(e,t){var n=!t||t.entities?E:M;return e.replace(n,(function(e){var t=e.charCodeAt(0),n=I[t];return n?"&"+n+";":e}))},isBom:function(e){return e&&3===e.nodeType&&/^[\ufeff]+$/.test(e.nodeValue)},stripBom:function(e){return(e||"").replace(T,"")},stripBomNode:function(e){z.isBom(e)&&e.parentNode.removeChild(e)},insignificant:function(e){var t=e.attributes;return"k-marker"==e.className||z.is(e,"br")&&("k-br"==e.className||t._moz_dirty||t._moz_editor_bogus_node)||z.is(e,"span")&&"k-br"==e.className},tableCell:function(e){return z.is(e,"td")||z.is(e,"th")},significantNodes:function(t){return e.grep(t,(function(e){var t=z.name(e);return!("br"==t||z.insignificant(e)||z.emptyTextNode(e)||1==e.nodeType&&!h[t]&&z.emptyNode(e))}))},emptyTextNode:function(e){return e&&3==e.nodeType&&D.test(e.nodeValue)},emptyNode:function(e){return 1==e.nodeType&&!z.significantNodes(e.childNodes).length},name:function(e){return e.nodeName.toLowerCase()},significantChildNodes:function(t){return e.grep(t.childNodes,(function(e){return 3!=e.nodeType||!z.isWhitespace(e)}))},getTextNodes:function(e,t){const n=e.childNodes;t=t||[];for(const i of n)i.nodeType===this.nodeTypes.TEXT_NODE&&(f.includes(z.name(i.parentNode))||v.includes(z.name(i.parentNode))||i.parentNode===e)?t.push(i):i.nodeType===this.nodeTypes.ELEMENT_NODE&&this.getTextNodes(i,t);return t},lastTextNode:function(e){var t=null;if(3==e.nodeType)return e;for(var n=e.lastChild;n;n=n.previousSibling)if(t=z.lastTextNode(n))return t;return t},is:function(e,t){return e&&z.name(e)==t},isMarker:function(e){return e.className==d},isWhitespace:function(e){return x.test(e.nodeValue)},allowsTextContent:function(e){var t=!0;return y.every((function(n){return!z.is(e,n)||(t=!1,!1)})),t},allWhitespaceContent:function(e){for(var t=e.firstChild;t&&z.isWhitespace(t);)t=t.nextSibling;return!t},isEmptyspace:function(e){return C.test(e.nodeValue)},htmlIndentSpace:function(t){if(!z.isDataNode(t)||!z.isWhitespace(t))return!1;if(C.test(t.nodeValue))return!0;var n=function(e,t){for(;e[t];)if(e=e[t],z.significantNodes([e]).length>0)return e},i=t.parentNode,r=n(t,"previousSibling"),o=n(t,"nextSibling");if(T.test(t.nodeValue))return!(!r&&!o);if(e(i).is("tr,tbody,thead,tfoot,table,ol,ul"))return!0;if(z.isBlock(i)||z.is(i,"body")){var a=r&&z.isBlock(r),s=o&&z.isBlock(o);if(!o&&a||!r&&s||a&&s)return!0}return!1},isBlock:function(e){return m[z.name(e)]},isSelfClosing:function(e){return g[z.name(e)]},isEmpty:function(e){return h[z.name(e)]},isInline:function(e){return _[z.name(e)]},isImg:function(e){return"img"==z.name(e)},isBr:function(e){return"br"==z.name(e)},list:function(e){var t=e?z.name(e):"";return"ul"==t||"ol"==t||"dl"==t},scrollContainer:function(e){var t=z.windowFromDocument(e),n=(t.contentWindow||t).document||t.ownerDocument||t;return n="BackCompat"==n.compatMode?n.body:n.scrollingElement||n.documentElement},scrollTo:function(t,n){var i,r,o,a,s=t.ownerDocument,l=z.windowFromDocument(s).innerHeight,c=z.scrollContainer(s);z.isDataNode(t)?n?(a=z.create(s,"span",{innerHTML:"&#xfeff;"}),z.insertBefore(a,t),i=e(a)):i=e(t.parentNode):i=e(t),r=i.offset().top,o=i[0].offsetHeight,!n&&o||(o=parseInt(i.css("line-height"),10)||Math.ceil(1.2*parseInt(i.css("font-size"),10))||15),a&&z.remove(a),o+r>c.scrollTop+l&&(c.scrollTop=o+r-l)},persistScrollTop:function(e){k=z.scrollContainer(e).scrollTop},offset:function(e,t){for(var n={top:e.offsetTop,left:e.offsetLeft},i=e.offsetParent;i&&(!t||z.isAncestorOf(t,i));)n.top+=i.offsetTop,n.left+=i.offsetLeft,i=i.offsetParent;return n},restoreScrollTop:function(e){"number"==typeof k&&(z.scrollContainer(e).scrollTop=k,k=void 0)},insertAt:function(e,t,n){e.insertBefore(t,e.childNodes[n]||null)},insertBefore:function(e,t){return t.parentNode?t.parentNode.insertBefore(e,t):t},insertAfter:function(e,t){return t.parentNode.insertBefore(e,t.nextSibling)},remove:function(e){e.parentNode&&e.parentNode.removeChild(e)},removeChildren:function(e){for(;e.firstChild;)e.removeChild(e.firstChild)},removeTextSiblings:function(e){for(var t=e.parentNode;e.nextSibling&&3==e.nextSibling.nodeType;)t.removeChild(e.nextSibling);for(;e.previousSibling&&3==e.previousSibling.nodeType;)t.removeChild(e.previousSibling)},trim:function(e){for(var t=e.childNodes.length-1;t>=0;t--){var n=e.childNodes[t];z.isDataNode(n)?z.stripBom(n.nodeValue).length||z.remove(n):n.className!=d&&(z.trim(n),(!z.isEmpty(n)&&0===n.childNodes.length||z.isBlock(n)&&z.allWhitespaceContent(n))&&z.remove(n))}return e},closest:function(e,t){for("string"==typeof t&&(t=[t]);e&&t.indexOf(z.name(e))<0;)e=e.parentNode;return e},closestBy:function(e,t,n){for(;e&&!t(e);){if(n&&n(e))return null;e=e.parentNode}return e},sibling:function(e,t){do{e=e[t]}while(e&&1!=e.nodeType);return e},next:function(e){return z.sibling(e,"nextSibling")},prev:function(e){return z.sibling(e,"previousSibling")},parentOfType:function(e,t){do{e=e.parentNode}while(e&&!z.ofType(e,t));return e},ofType:function(t,n){return e.inArray(z.name(t),n)>=0},changeTag:function(e,t,n){var i,r,a,s,l,d=z.create(e.ownerDocument,t),u=e.attributes;if(!n)for(i=0,r=u.length;i<r;i++)(l=u[i]).specified&&(a=l.nodeName,s=l.nodeValue,a==c?d.className=s:a==o?d.style.cssText=e.style.cssText:d.setAttribute(a,s));for(;e.firstChild;)d.appendChild(e.firstChild);return z.insertBefore(d,e),z.remove(e),d},editableParent:function(e){for(;e&&(3==e.nodeType||"true"!==e.contentEditable);)e=e.parentNode;return e},wrap:function(e,t){return z.insertBefore(t,e),t.appendChild(e),t},unwrap:function(e){for(var t=e.parentNode;e.firstChild;)t.insertBefore(e.firstChild,e);t.removeChild(e)},wrapper:function(t){var n=z.closestBy(t,(function(e){return e.parentNode&&z.significantNodes(e.parentNode.childNodes).length>1}));return e(n).is("body,.k-editor")?void 0:n},isChildOfBaseContainer:function(t){return e(t).parent().is("body,.k-editor")},create:function(e,t,n){return z.attr(e.createElement(t),n)},createEmptyNode:function(e,t,n){var i=z.attr(e.createElement(t),n);return i.innerHTML="\ufeff",i},attr:function(e,t){for(var n in(t=i({},t))&&o in t&&(z.style(e,t.style),delete t.style),t)null===t[n]?(e.removeAttribute(n),delete t[n]):"className"==n&&(e[n]=t[n]);return i(e,t)},mergeAttributes:function(t,n,i){t.attributes.length&&e.each(t.attributes,(function(){"contenteditable"===this.name||i&&this.name===o||e(n).attr(this.name,this.value),i&&this.name===o&&e.each(t.style,(function(){n.style[this]=t.style[this]}))}))},style:function(t,n){e(t).css(n||{})},unstyle:function(e,n){for(var i in n)i==a?e.style[t.support.cssFloat?s:l]="":e.style[i]="";""===e.style.cssText&&e.removeAttribute(o)},inlineStyle:function(t,i,o){var a,s=e(z.create(t.ownerDocument,i,o));return t.appendChild(s[0]),a=n(A,(function(e){return r.msie&&"line-height"==e&&"1px"==s.css(e)?"line-height:1.5":e+":"+s.css(e)})).join(";"),s.remove(),a},getEffectiveBackground:function(e){var t=e.css("background-color")||"";return t.indexOf("rgba(0, 0, 0, 0")<0&&"transparent"!==t?t:"html"===e[0].tagName.toLowerCase()?"Window":z.getEffectiveBackground(e.parent())},innerText:function(e){var t=e.innerHTML;return t=(t=t.replace(/<!--(.|\s)*?-->/gi,"")).replace(/<\/?[^>]+?\/?>/gm,"")},removeClass:function(e,n){var i,r,o=" "+e.className+" ",a=n.split(" ");for(i=0,r=a.length;i<r;i++)o=o.replace(" "+a[i]+" "," ");(o=t.trim(o)).length?e.className=o:e.removeAttribute(c)},commonAncestor:function(){var e,t,n,i,r,o=arguments.length,a=[],s=1/0,l=null;if(!o)return null;if(1==o)return arguments[0];for(e=0;e<o;e++){for(t=[],n=arguments[e];n;)t.push(n),n=n.parentNode;a.push(t.reverse()),s=Math.min(s,t.length)}if(1==o)return a[0][0];for(e=0;e<s;e++){for(i=a[0][e],r=1;r<o;r++)if(i!=a[r][e])return l;l=i}return l},closestSplittableParent:function(t){var i;(i=1==t.length?z.parentOfType(t[0],["ul","ol"]):z.commonAncestor.apply(null,t))||(i=z.parentOfType(t[0],["p","td"])||t[0].ownerDocument.body),z.isInline(i)&&(i=z.blockParentOrBody(i));var r=n(t,z.editableParent),o=z.commonAncestor(r)[0];return e.contains(i,o)&&(i=o),i},closestEditable:function(t,n){var i,r=z.editableParent(t);return((i=z.ofType(t,n)?t:z.parentOfType(t,n))&&r&&e.contains(i,r)||!i&&r)&&(i=r),i},closestEditableOfType:function(t,n){var i=z.closestEditable(t,n);if(i&&z.ofType(i,n)&&!e(i).is(".k-editor"))return i},filter:function(e,t,n){return z.filterBy(t,(function(t){return z.name(t)==e}),n)},filterBy:function(e,t,n){for(var i,r=0,o=e.length,a=[];r<o;r++)((i=t(e[r]))&&!n||!i&&n)&&a.push(e[r]);return a},ensureTrailingBreaks:function(t){var n=e(t).find("p,td,th"),i=n.length,r=0;if(i)for(;r<i;r++)z.ensureTrailingBreak(n[r]);else z.ensureTrailingBreak(t)},removeTrailingBreak:function(t){e(t).find("br[type=_moz],.k-br").remove()},ensureTrailingBreak:function(e){z.removeTrailingBreak(e);var t,n=e.lastChild,i=n&&z.name(n);(!i||"br"!=i&&"img"!=i||"br"==i&&"k-br"!=n.className)&&((t=e.ownerDocument.createElement("br")).className="k-br",e.appendChild(t))},reMapTableColumns:function(e,t){z._mapColIndices(e,t)},clearTableMappings:function(t,n){e(t).find("["+n+"]").removeAttr(n)},_mapColIndices:function(e,t){for(var n={},i=0;i<e.rows.length;i++)for(var r=e.rows[i].cells,o=0,a=0;a<r.length;a++){var s=r[a];if(s.rowSpan>1&&this._mapColspan(s,i,o,n),n[i])for(;n[i][o];)o++;s.setAttribute(t,o),s.colSpan>1&&(o=o+s.colSpan-1),o++}},_mapColspan:function(e,t,n,i){for(var r,o=e.rowSpan,a=e.colSpan,s=0;s<a;s++){r=n+s;for(var l=t+1;l<t+o;l++){if(i[l]||(i[l]={},i[l].length=0),i[t])for(;i[t][r];)r++;i[l][r]=!0,i[l].length++}}},associateWithIds:function(e){var t,n,i=this,r=0,o=e.rows,a=o.length,s=[],l=[];if(e.tHead)r=(t=e.tHead.rows).length;else for(r=i._getNumberOfHeaderRows(e),t=[],n=0;n<r;n++)t.push(o[n]);for(n=0;n<r;n++)s.push([]);for(n=0;n<a;n++)l.push([]);i._generateIdsForColumns(s,t),i._generateIdsForRows(s,l,r,o),i._assignIds(s,l,r,o)},_generateIdsForColumns:function(e,t){var n,i,r,o,a,s,l,c,d,u,h=(new Date).getTime(),p=t?t.length:0;for(l=0;l<p;l++)for(n=t[l].cells,r=0,c=0;c<n.length;c++){for(o="table"+l+c+ ++h,(i=n[c]).setAttribute("id",o),a=i.getAttribute("colspan")||1,s=i.getAttribute("rowspan")||1;e[l][c+r];)r+=1;for(d=0;d<s;d++)for(u=0;u<a;u++)e[l+d][c+r+u]=o}},_generateIdsForRows:function(t,n,i,r){var o,a,s,l,c,d,u,h,p,f,m,g,v,_=(new Date).getTime(),b=r.length,y=function(e){v.push(e[g])};for(h=i;h<b;h++)for(o=r[h],a=e(o.cells).filter("th"),l=0,p=0;p<a.length;p++){for(c="table"+h+p+ ++_,(s=a[p]).setAttribute("id",c),d=s.getAttribute("colspan")||1,u=s.getAttribute("rowspan")||1;n[h][p+l];)l+=1;for(f=0;f<u;f++)for(m=0;m<d;m++)n[h+f][p+l+m]=c;g=s.getAttribute("col-index"),v=[],t.forEach(y),v=v.filter(this._onlyUnique),s.setAttribute("headers",v.join(" ").trim())}},_assignIds:function(t,n,i,r){var o,a,s,l,c,d,u,h=r.length,p=function(e){u.push(e[d])};for(l=i;l<h;l++)for(o=r[l],a=e(o.cells).filter("td"),c=0;c<a.length;c++)s=a[c],d=s.getAttribute("col-index"),u=n[l].slice(),t.forEach(p),u=u.filter(this._onlyUnique),s.setAttribute("headers",u.join(" ").trim())},_getNumberOfColumns:function(t){var n,i,r,o=e(t).find("th, td"),a=0;for(i=0;i<o.length;i++)n=o[i],(r=Number(n.getAttribute("col-index"))+1)>a&&(a=r);return a},_getNumberOfHeaderColumns:function(e,t){var n,i,r,o,a,s=e.rows,l=0;for(r=t;r<s.length;r++)for(i=s[r],o=0;o<i.cells.length;o++)a=i.cells[o],this.is(a,"th")&&(n=Number(a.getAttribute("col-index"))+1)>l&&(l=n);return l},_getNumberOfHeaderRows:function(e){var t,n,i,r,o=e.rows,a=e.tHead&&e.tHead.rows?e.tHead.rows.length:0;if(0===a)for(r=(n=o[0]).cells&&n.cells.length;n&&r&&this.is(n.cells[0],"th");){for(t=0;t<r;t++)i=n?n.cells[t]:null,this.is(i,"th")||(n=null);n&&(a+=1,r=(n=this.next(n))&&n.cells&&n.cells.length)}return a},_onlyUnique:function(e,t,n){return n.indexOf(e)===t}};t.ui.editor.Dom=z}(window.kendo.jQuery),function(e,t){var n=window.kendo,i=n.ui.editor,r=i.Dom,o=e.extend,a="xx-small,x-small,small,medium,large,x-large,xx-large".split(","),s=/"/g,l=/<br[^>]*>/i,c=/^\d+(\.\d*)?(px)?$/i,d=/<p>(?:&nbsp;)?<\/p>/i,u=/(\*?[-#\/\*\\\w]+(?:\[[0-9a-z_-]+\])?)\s*:\s*((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^\)]*?\)|[^};])+)/g,h=/^sizzle-\d+/i,p=/^k-script-/i,f=/\s*onerror\s*=\s*(?:'|")?([^'">\s]*)(?:'|")?/i,m='<br class="k-br">',g="<span class='k-br'>\ufeff</span>",v=document.createElement("div");v.innerHTML=" <hr>";var _=3===v.firstChild.nodeType;v=null;var b=n.isFunction,y={toEditableHtml:function(e){return(e||"").replace(/<!\[CDATA\[(.*)?\]\]>/g,"\x3c!--[CDATA[$1]]--\x3e").replace(/<(\/?)script([^>]*)>/gi,"<$1k:script$2>").replace(/<img([^>]*)>/gi,(function(e){return e.replace(f,"")})).replace(/(<\/?img[^>]*>)[\r\n\v\f\t ]+/gi,"$1").replace(/^<(table|blockquote)/i,m+"<$1").replace(/^[\s]*(&nbsp;|\u00a0)/i,"$1").replace(/<\/(table|blockquote)>$/i,"</$1>"+m)},_toEditableImmutables:function(t){for(var n=i.Immutables.immutable,o=r.emptyTextNode,a=t.firstChild,s=t.lastChild;o(a);)a=a.nextSibling;for(;o(s);)s=s.previousSibling;a&&n(a)&&e(g).prependTo(t),s&&n(s)&&e(g).appendTo(t)},_fillEmptyElements:function(t){e(t).find("p,td").each((function(){var t=e(this);if(/^\s*$/g.test(t.text())&&!t.find("img,input").length){for(var i=this;i.children[0]&&3!=i.children[0].nodeType;)i=i.children[0];1!=i.nodeType||r.empty[r.name(i)]||(r.is(i,"td")?i.innerHTML=n.ui.editor.emptyTableCellContent:i.innerHTML=n.ui.editor.emptyElementContent)}}))},_removeSystemElements:function(t){e(".k-paste-container",t).remove()},_resetOrderedLists:function(e){var t,n,i,r=e.getElementsByTagName("ol");for(t=0;t<r.length;t++)i=(n=r[t]).getAttribute("start"),n.setAttribute("start",1),i?n.setAttribute("start",i):n.removeAttribute(i)},_preventScriptExecution:function(t){e(t).find("*").each((function(){var e,t,n,i,r=this.attributes,o=[];for(t=0,n=r.length;t<n;t++)i=(e=r[t]).nodeName,e.specified&&/^on/i.test(i)&&(this.setAttribute("k-script-"+i,e.value),o.push(i));for(t=0,n=o.length;t<n;t++)this.removeAttribute(o[t])}))},htmlToDom:function(t,i,o){var a=n.support.browser.msie,s=o||{},l=s.immutables;return t=y.toEditableHtml(t),b(s.custom)&&(t=s.custom(t)||t),i.innerHTML=t,l&&l.deserialize(i),a&&(r.normalize(i),y._resetOrderedLists(i)),y._preventScriptExecution(i),y._fillEmptyElements(i),y._removeSystemElements(i),y._toEditableImmutables(i),e("table",i).addClass("k-table"),i},domToXhtml:function(o,f){var m=[],g=f&&f.immutables;function v(t){return e.grep(t,(function(e){return"style"!=e.name}))}function b(e,t){m.push("<"+t),x(e),m.push(">")}var y={iframe:{start:function(e){b(e,"iframe")},end:function(){m.push("</iframe>")}},"k:script":{start:function(e){b(e,"script")},end:function(){m.push("<\/script>")},skipEncoding:!0},span:{canOptimize:!0,semantic:!0,start:function(t){var n=t.style,i=v(k(t));i.length&&(m.push("<span"),x(t,i),m.push(">")),"underline"==n.textDecoration&&m.push("<u>");var o=[];if(n.color&&o.push('color="'+r.toHex(n.color)+'"'),n.fontFamily&&o.push('face="'+n.fontFamily+'"'),n.fontSize){var s=e.inArray(n.fontSize,a);o.push('size="'+s+'"')}var l=[],c=["text-decoration","color","font"];for(let e=0;e<n.length;e++){var d=n[e];c.filter((e=>d.startsWith(e))).length<=0&&l.push(`${d}: ${n[d]}`)}l.length&&o.push('style="'+l.join(";")+'"'),o.length&&m.push("<font "+o.join(" ")+">")},end:function(e){var t=e.style;(t.color||t.fontFamily||t.fontSize)&&m.push("</font>"),"underline"==t.textDecoration&&m.push("</u>"),v(k(e)).length&&m.push("</span>")}},strong:{semantic:!0,start:function(e){b(e,"b")},end:function(){m.push("</b>")}},em:{semantic:!0,start:function(e){b(e,"i")},end:function(){m.push("</i>")}},b:{semantic:!1,start:function(e){b(e,"strong")},end:function(){m.push("</strong>")}},i:{semantic:!1,start:function(e){b(e,"em")},end:function(){m.push("</em>")}},u:{semantic:!1,start:function(t){m.push("<span");var n=k(t),i=e(n).filter((function(e,t){return"style"==t.name}))[0],r={nodeName:"style",value:"text-decoration:underline;"};i&&(r.value=i.value,/text-decoration/i.test(r.value)||(r.value="text-decoration:underline;"+r.value),n.splice(e.inArray(i,n),1)),n.push(r),x(t,n),m.push(">")},end:function(){m.push("</span>")}},font:{canOptimize:!0,semantic:!1,start:function(e){m.push('<span style="');var t=e.getAttribute("color"),n=a[e.getAttribute("size")],i=e.getAttribute("face");t&&(m.push("color:"),m.push(r.toHex(t)),m.push(";")),i&&(m.push("font-family:"),m.push(i),m.push(";")),n&&(m.push("font-size:"),m.push(n),m.push(";")),m.push('">')},end:function(){m.push("</span>")}}};function w(e){var t,i=function(e){var t,i,o,a=n.trim,l=a(e),c=[];for(u.lastIndex=0;t=u.exec(l);)i=a(t[1].toLowerCase()),o=a(t[2]),"font-size-adjust"!=i&&"font-stretch"!=i&&(i.indexOf("color")>=0?o=r.toHex(o):i.indexOf("font")>=0?o=o.replace(s,"'"):/\burl\(/g.test(o)&&(o=o.replace(s,"")),c.push({property:i,value:o}));return c}(e);for(t=0;t<i.length;t++)m.push(i[t].property),m.push(":"),m.push(i[t].value),m.push(";")}function k(e){var t,n,i,o,a,s,l=[],c=e.attributes;for(n=0,i=c.length;n<i;n++)o=(t=c[n]).nodeName,a=t.value,s=t.specified,"value"==o&&"value"in e&&e.value||"type"==o&&"text"==a?s=!0:"class"!=o||a?h.test(o)||"complete"==o||"altHtml"==o||"start"==o&&r.is(e,"ul")||"start"==o&&r.is(e,"ol")&&"1"==a||o.indexOf("_moz")>=0?s=!1:p.test(o)?s=!!f.scripts:"data-role"==o&&"resizable"==a&&(r.is(e,"tr")||r.is(e,"td"))&&(s=!1):s=!1,s&&l.push(t);return l}function x(i,o){var a,s,l,d,u;if(o=o||k(i),r.is(i,"img")){var h=i.style.width,f=i.style.height,g=e(i);h&&c.test(h)&&(g.attr("width",parseInt(h,10)),r.unstyle(i,{width:t})),f&&c.test(f)&&(g.attr("height",parseInt(f,10)),r.unstyle(i,{height:t}))}if(o.length)for(a=0,s=o.length;a<s;a++)d=(l=o[a]).nodeName,u=l.value,"class"==d&&"k-table"==u||(d=d.replace(p,""),m.push(" "),m.push(d),m.push('="'),"style"==d?w(u||i.style.cssText):"src"==d||"href"==d?m.push(n.htmlEncode(i.getAttribute(d,2))):m.push(r.fillAttrs[d]?d:u),m.push('"'))}function C(e,t,n){for(var i=e.firstChild;i;i=i.nextSibling)T(i,t,n)}function S(e){return e.nodeValue.replace(/\ufeff/g,"")}function T(t,n,o){var a,s,l,c,d,u,h=t.nodeType;if(g&&i.Immutables.immutable(t))m.push(g.serialize(t));else if(1==h){if(a=r.name(t),(u=e(t)).hasClass("k-element-resize-handle-wrapper")||u.hasClass("k-column-resize-handle-wrapper")||u.hasClass("k-row-resize-handle-wrapper"))return;if(!a||r.insignificant(t))return;if(!f.scripts&&("script"==a||"k:script"==a))return;if(s=y[a]){if(s.canOptimize&&f.optimizeTags&&function(e){return 0===e.attributes.length}(t))return void C(t,!1,s.skipEncoding);if(void 0===s.semantic||f.semantic^s.semantic)return s.start(t),C(t,!1,s.skipEncoding),void s.end(t)}m.push("<"),m.push(a),x(t),r.empty[a]?m.push(" />"):(m.push(">"),C(t,n||r.is(t,"pre")),m.push("</"),m.push(a),m.push(">"))}else if(3==h){if(function(e){if(r.isBom(e)){do{if(e=e.parentNode,r.is(e,"td")&&1===e.childNodes.length)return!0;if(1!==e.childNodes.length)return!1}while(!r.isBlock(e));return!0}return!1}(t))return void m.push("&nbsp;");c=S(t),!n&&_&&(l=t.parentNode,(d=t.previousSibling)||(d=(r.isInline(l)?l:t).previousSibling),d&&""!==d.innerHTML&&!r.isBlock(d)||(c=f.keepEOL?c.replace(/[\r\n\v\f\t ]+/," "):c.replace(/^[\r\n\v\f\t ]+/,"")),c=c.replace(/ +/," ")),m.push(o?c:r.encode(c,f))}else 4==h?(m.push("<![CDATA["),m.push(t.data),m.push("]]>")):8==h&&(t.data.indexOf("[CDATA[")<0?(m.push("\x3c!--"),m.push(t.data),m.push("--\x3e")):(m.push("<!"),m.push(t.data),m.push(">")))}function D(){n.isFunction(f.custom)&&(m=f.custom(m)||m)}return y.script=y["k:script"],void 0===(f=f||{}).semantic&&(f.semantic=!0),function(e){var t=e.childNodes.length;return t&&3==e.firstChild.nodeType&&(1==t||2==t&&r.insignificant(e.lastChild))}(o)?(m=r.encode(S(o.firstChild).replace(/[\r\n\v\f\t ]+/," "),f),D(),m):(C(o),m=m.join(""),D(),""===m.replace(l,"").replace(d,"")?"":m)}};o(i,{Serializer:y})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Class,i=e.extend,r=t.ui.editor,o=t.support.browser,a=r.Dom,s=a.findNodeIndex,l=a.isDataNode,c=a.findClosestAncestor,d=a.getNodeLength,u=a.normalize,h={selectionFromWindow:function(e){if(e)return"getSelection"in e?e.getSelection():new v(e.document)},selectionFromRange:function(e){var t=T.documentFromRange(e);return h.selectionFromDocument(t)},selectionFromDocument:function(e){return h.selectionFromWindow(a.windowFromDocument(e))}},p=n.extend({init:function(t){e.extend(this,{ownerDocument:t,startContainer:t,endContainer:t,commonAncestorContainer:t,startOffset:0,endOffset:0,collapsed:!0})},setStart:function(e,t){this.startContainer=e,this.startOffset=t,m(this),f(this,!0)},setEnd:function(e,t){this.endContainer=e,this.endOffset=t,m(this),f(this,!1)},setStartBefore:function(e){this.setStart(e.parentNode,s(e))},setStartAfter:function(e){this.setStart(e.parentNode,s(e)+1)},setEndBefore:function(e){this.setEnd(e.parentNode,s(e))},setEndAfter:function(e){this.setEnd(e.parentNode,s(e)+1)},selectNode:function(e){this.setStartBefore(e),this.setEndAfter(e)},selectNodeContents:function(e){this.setStart(e,0),this.setEnd(e,e[1===e.nodeType?"childNodes":"nodeValue"].length)},collapse:function(e){var t=this;e?t.setEnd(t.startContainer,t.startOffset):t.setStart(t.endContainer,t.endOffset)},deleteContents:function(){var e=this,t=e.cloneRange();e.startContainer!=e.commonAncestorContainer&&e.setStartAfter(c(e.commonAncestorContainer,e.startContainer)),e.collapse(!0),function e(t){for(;t.next();)t.hasPartialSubtree()?e(t.getSubtreeIterator()):t.remove()}(new g(t))},cloneContents:function(){var e=T.documentFromRange(this);return function t(n){for(var i,r=e.createDocumentFragment();i=n.next();)i=i.cloneNode(!n.hasPartialSubtree()),n.hasPartialSubtree()&&i.appendChild(t(n.getSubtreeIterator())),r.appendChild(i);return r}(new g(this))},extractContents:function(){var e=this,t=e.cloneRange();e.startContainer!=e.commonAncestorContainer&&e.setStartAfter(c(e.commonAncestorContainer,e.startContainer)),e.collapse(!0);var n=T.documentFromRange(e);return function t(i){for(var r,o=n.createDocumentFragment();r=i.next();)i.hasPartialSubtree()?(r=r.cloneNode(!1)).appendChild(t(i.getSubtreeIterator())):i.remove(e.originalRange),o.appendChild(r);return o}(new g(t))},insertNode:function(e){var t=this;l(t.startContainer)?(t.startOffset!=t.startContainer.nodeValue.length&&a.splitDataNode(t.startContainer,t.startOffset),a.insertAfter(e,t.startContainer)):a.insertAt(t.startContainer,e,t.startOffset),t.setStart(t.startContainer,t.startOffset)},cloneRange:function(){return e.extend(new p(this.ownerDocument),{startContainer:this.startContainer,endContainer:this.endContainer,commonAncestorContainer:this.commonAncestorContainer,startOffset:this.startOffset,endOffset:this.endOffset,collapsed:this.collapsed,originalRange:this})},toString:function(){var e=this.startContainer.nodeName,t=this.endContainer.nodeName;return["#text"==e?this.startContainer.nodeValue:e,"(",this.startOffset,") : ","#text"==t?this.endContainer.nodeValue:t,"(",this.endOffset,")"].join("")}});function f(e,t){(function(e){try{return function(e,t,n,i){if(e==t)return i-n;for(var r=t;r&&r.parentNode!=e;)r=r.parentNode;if(r)return s(r)-n;for(r=e;r&&r.parentNode!=t;)r=r.parentNode;if(r)return i-s(r)-1;for(var o=a.commonAncestor(e,t),l=e;l&&l.parentNode!=o;)l=l.parentNode;l||(l=o);for(var c=t;c&&c.parentNode!=o;)c=c.parentNode;return c||(c=o),l==c?0:s(c)-s(l)}(e.startContainer,e.endContainer,e.startOffset,e.endOffset)<0}catch(e){return!0}})(e)&&(t?(e.commonAncestorContainer=e.endContainer=e.startContainer,e.endOffset=e.startOffset):(e.commonAncestorContainer=e.startContainer=e.endContainer,e.startOffset=e.endOffset),e.collapsed=!0)}function m(e){e.collapsed=e.startContainer==e.endContainer&&e.startOffset==e.endOffset;for(var t=e.startContainer;t&&t!=e.endContainer&&!a.isAncestorOf(t,e.endContainer);)t=t.parentNode;e.commonAncestorContainer=t}p.fromNode=function(e){return new p(e.ownerDocument)};var g=n.extend({init:function(t){if(e.extend(this,{range:t,_current:null,_next:null,_end:null}),!t.collapsed){var n=t.commonAncestorContainer;this._next=t.startContainer!=n||l(t.startContainer)?c(n,t.startContainer):t.startContainer.childNodes[t.startOffset],this._end=t.endContainer!=n||l(t.endContainer)?c(n,t.endContainer).nextSibling:t.endContainer.childNodes[t.endOffset]}},hasNext:function(){return!!this._next},next:function(){var e=this,t=e._current=e._next;return e._next=e._current&&e._current.nextSibling!=e._end?e._current.nextSibling:null,l(e._current)&&(e.range.endContainer==e._current&&(t=t.cloneNode(!0)).deleteData(e.range.endOffset,t.length-e.range.endOffset),e.range.startContainer==e._current&&(t=t.cloneNode(!0)).deleteData(0,e.range.startOffset)),t},traverse:function(e){var t,n=this;for(;n._current=n._next,n._next=n._current&&n._current.nextSibling!=n._end?n._current.nextSibling:null,t=n._current;)n.hasPartialSubtree()?n.getSubtreeIterator().traverse(e):e(t);return t},remove:function(e){var t,n,i,r=this,o=r.range.startContainer==r._current,c=r.range.endContainer==r._current;if(l(r._current)&&(o||c))t=o?r.range.startOffset:0,i=(n=c?r.range.endOffset:r._current.length)-t,e&&(o||c)&&(r._current==e.startContainer&&t<=e.startOffset&&(e.startOffset-=i),r._current==e.endContainer&&n<=e.endOffset&&(e.endOffset-=i)),r._current.deleteData(t,i);else{var d=r._current.parentNode;if(e&&(r.range.startContainer==d||r.range.endContainer==d)){var u=s(r._current);d==e.startContainer&&u<=e.startOffset&&(e.startOffset-=1),d==e.endContainer&&u<e.endOffset&&(e.endOffset-=1)}a.remove(r._current)}},hasPartialSubtree:function(){return!l(this._current)&&(a.isAncestorOrSelf(this._current,this.range.startContainer)||a.isAncestorOrSelf(this._current,this.range.endContainer))},getSubtreeIterator:function(){return new g(this.getSubRange())},getSubRange:function(){var e=this,t=e.range.cloneRange();return t.selectNodeContents(e._current),a.isAncestorOrSelf(e._current,e.range.startContainer)&&t.setStart(e.range.startContainer,e.range.startOffset),a.isAncestorOrSelf(e._current,e.range.endContainer)&&t.setEnd(e.range.endContainer,e.range.endOffset),t}}),v=n.extend({init:function(e){this.ownerDocument=e,this.rangeCount=1},addRange:function(e){var t=this.ownerDocument.body.createTextRange();_(t,e,!1),_(t,e,!0),t.select()},removeAllRanges:function(){var e=this.ownerDocument.selection;"None"!=e.type&&e.empty()},getRangeAt:function(){var e,t,n=new p(this.ownerDocument),i=this.ownerDocument.selection;try{if(((e=i.createRange()).item?e.item(0):e.parentElement()).ownerDocument!=this.ownerDocument)return n}catch(e){return n}if("Control"==i.type)n.selectNode(e.item(0));else{t=function(e){var t=e.duplicate(),n=e.duplicate();return t.collapse(!0),n.collapse(!1),a.commonAncestor(e.parentElement(),t.parentElement(),n.parentElement())}(e),b(e,n,t,!0),b(e,n,t,!1),9==n.startContainer.nodeType&&n.setStart(n.endContainer,n.startOffset),9==n.endContainer.nodeType&&n.setEnd(n.startContainer,n.endOffset),0===e.compareEndPoints("StartToEnd",e)&&n.collapse(!1);var r=n.startContainer,o=n.endContainer,c=this.ownerDocument.body;if(!(n.collapsed||0!==n.startOffset||n.endOffset!=d(n.endContainer)||r==o&&l(r)&&r.parentNode==c)){for(var u=!1,h=!1;0===s(r)&&r==r.parentNode.firstChild&&r!=c;)r=r.parentNode,u=!0;for(;s(o)==d(o.parentNode)-1&&o==o.parentNode.lastChild&&o!=c;)o=o.parentNode,h=!0;r==c&&o==c&&u&&h&&(n.setStart(r,0),n.setEnd(o,d(c)))}}return n}});function _(e,t,n){var i,r=t[n?"startContainer":"endContainer"],o=t[n?"startOffset":"endOffset"],s=0,c=l(r),d=c?r:r.childNodes[o]||null,u=c?r.parentNode:r,h=t.ownerDocument,p=h.body.createTextRange();3!=r.nodeType&&4!=r.nodeType||(s=o),u||(u=h.body),"img"==u.nodeName.toLowerCase()?(p.moveToElementText(u),p.collapse(!1),e.setEndPoint(n?"StartToStart":"EndToStart",p)):(i=u.insertBefore(a.create(h,"a"),d),p.moveToElementText(i),a.remove(i),p[n?"moveStart":"moveEnd"]("character",s),p.collapse(!1),e.setEndPoint(n?"StartToStart":"EndToStart",p))}function b(e,t,n,i){var r,o,c,d,u,h,p,f=a.create(t.ownerDocument,"a"),m=e.duplicate(),g=i?"StartToStart":"StartToEnd",v=!1;f.innerHTML="\ufeff",m.collapse(i),o=m.parentElement(),a.isAncestorOrSelf(n,o)||(o=n);do{v?o.insertBefore(f,f.previousSibling):(o.appendChild(f),v=!0),m.moveToElementText(f)}while((r=m.compareEndPoints(g,e))>0&&f.previousSibling);c=f.nextSibling,-1==r&&l(c)?(m.setEndPoint(i?"EndToStart":"EndToEnd",e),a.remove(f),h=[c,m.text.length]):(d=!i&&f.previousSibling,u=i&&f.nextSibling,l(u)?h=[u,0]:l(d)?h=[d,d.length]:(p=s(f),h=o.nextSibling&&p==o.childNodes.length-1?[o.nextSibling,0]:[o,p]),a.remove(f)),t[i?"setStart":"setEnd"](...h)}var y=n.extend({init:function(e){this.enumerate=function(){var t=[];return new g(e).traverse((function e(n){if(a.is(n,"img")||3==n.nodeType&&(!a.isEmptyspace(n)||"\ufeff"==n.nodeValue))t.push(n);else for(n=n.firstChild;n;)e(n),n=n.nextSibling})),t}}}),w=g.extend({hasPartialSubtree:function(){var e=r.Immutables&&r.Immutables.immutable;return e&&!e(this._current)&&g.fn.hasPartialSubtree.call(this)},getSubtreeIterator:function(){return new w(this.getSubRange())}}),k=n.extend({init:function(e){this.enumerate=function(){var t=[],n=r.Immutables&&r.Immutables.immutable;return new w(e).traverse((function e(i){if(n&&!n(i))if(a.is(i,"img")||3==i.nodeType&&(!a.isEmptyspace(i)||"\ufeff"==i.nodeValue))t.push(i);else for(i=i.firstChild;i;)e(i),i=i.nextSibling})),t}}}),x=n.extend({init:function(e,t,n){var i=this;i.range=e,i.rootNode=T.documentFromRange(e),i.body=t||i.getEditable(e),"body"!=a.name(i.body)&&(i.rootNode=i.body),i.startContainer=i.nodeToPath(e.startContainer),i.endContainer=i.nodeToPath(e.endContainer),i.startOffset=i.offset(e.startContainer,e.startOffset),i.endOffset=i.offset(e.endContainer,e.endOffset),i.immutables=n&&n.immutables,i.immutables&&(i.serializedImmutables=r.Immutables.removeImmutables(i.body)),i.html=i.body.innerHTML,i.immutables&&!i.serializedImmutables.empty&&r.Immutables.restoreImmutables(i.body,i.serializedImmutables)},index:function(e){for(var t=0,n=e.nodeType;e=e.previousSibling;){var i=e.nodeType;3==i&&n==i||t++,n=i}return t},getEditable:function(e){for(var t=e.commonAncestorContainer;t&&(3==t.nodeType||t.attributes&&(!t.attributes.contentEditable||"false"==t.attributes.contentEditable.nodeValue.toLowerCase()));)t=t.parentNode;return t},restoreHtml:function(){var e=this;a.removeChildren(e.body),e.body.innerHTML=e.html,e.immutables&&!e.serializedImmutables.empty&&r.Immutables.restoreImmutables(e.body,e.serializedImmutables)},offset:function(e,t){if(3==e.nodeType)for(;(e=e.previousSibling)&&3==e.nodeType;)t+=e.nodeValue.length;return t},nodeToPath:function(e){for(var t=[];e!=this.rootNode;)t.push(this.index(e)),e=e.parentNode;return t},toRangePoint:function(e,t,n,i){for(var r=this.rootNode,o=n.length,a=i;o--&&r;)r=r.childNodes[n[o]];for(;r&&3==r.nodeType&&r.nodeValue.length<a;)a-=r.nodeValue.length,r=r.nextSibling;r&&a>=0&&e[t?"setStart":"setEnd"](r,a)},toRange:function(){var e=this,t=e.range.cloneRange();return e.toRangePoint(t,!0,e.startContainer,e.startOffset),e.toRangePoint(t,!1,e.endContainer,e.endOffset),t}}),C=n.extend({init:function(){this.caret=null},addCaret:function(e){var t=this.caret=a.create(T.documentFromRange(e),"span",{className:"k-marker"});return e.insertNode(t),a.stripBomNode(t.previousSibling),a.stripBomNode(t.nextSibling),e.selectNode(t),t},removeCaret:function(e){var t=this,n=t.caret.previousSibling,i=0;n&&(i=l(n)?n.nodeValue.length:s(n));var r=t.caret.parentNode,c=n?s(n):0;a.remove(t.caret),u(r);var d=r.childNodes[c];if(l(d))e.setStart(d,i);else if(d){var h=a.lastTextNode(d);h?e.setStart(h,h.nodeValue.length):e[n?"setStartAfter":"setStartBefore"](d)}else o.msie||r.innerHTML||(r.innerHTML='<br _moz_dirty="" />'),e.selectNodeContents(r);e.collapse(!0)},add:function(e,t){var n=this,i=e.collapsed&&!T.isExpandable(e),r=T.documentFromRange(e);t&&e.collapsed&&(n.addCaret(e),e=T.expand(e));var o=e.cloneRange();if(o.collapse(!1),n.end=a.create(r,"span",{className:"k-marker"}),o.insertNode(n.end),(o=e.cloneRange()).collapse(!0),n.start=n.end.cloneNode(!0),o.insertNode(n.start),n._removeDeadMarkers(n.start,n.end),i){var s=r.createTextNode("\ufeff");a.insertAfter(s.cloneNode(),n.start),a.insertBefore(s,n.end)}return u(e.commonAncestorContainer),e.setStartBefore(n.start),e.setEndAfter(n.end),e},_removeDeadMarkers:function(e,t){e.previousSibling&&"\ufeff"==e.previousSibling.nodeValue&&a.remove(e.previousSibling),t.nextSibling&&"\ufeff"==t.nextSibling.nodeValue&&a.remove(t.nextSibling)},_normalizedIndex:function(e){for(var t=s(e),n=e;n.previousSibling;)3==n.nodeType&&3==n.previousSibling.nodeType&&t--,n=n.previousSibling;return t},remove:function(e){var t,n,i=this,r=i.start,o=i.end;for(u(e.commonAncestorContainer);!r.nextSibling&&r.parentNode;)r=r.parentNode;for(;!o.previousSibling&&o.parentNode;)o=o.parentNode;t=r.previousSibling&&3==r.previousSibling.nodeType&&r.nextSibling&&3==r.nextSibling.nodeType,n=o.previousSibling&&3==o.previousSibling.nodeType&&o.nextSibling&&3==o.nextSibling.nodeType;var s=(r=r.nextSibling)===(o=o.previousSibling)&&a.isBom(r);s&&r.length>1&&(r.nodeValue=r.nodeValue.charAt(0));var c=s,d=!1;if(r==i.end&&(d=!!i.start.previousSibling,r=o=i.start.previousSibling||i.end.nextSibling,c=!0),a.remove(i.start),a.remove(i.end),!r||!o)return e.selectNodeContents(e.commonAncestorContainer),void e.collapse(!0);var h=c?l(r)?r.nodeValue.length:r.childNodes.length:0,p=l(o)?o.nodeValue.length:o.childNodes.length;if(3==r.nodeType)for(;r.previousSibling&&3==r.previousSibling.nodeType;)h+=(r=r.previousSibling).nodeValue.length;if(3==o.nodeType)for(;o.previousSibling&&3==o.previousSibling.nodeType;)p+=(o=o.previousSibling).nodeValue.length;var f=r.parentNode,m=o.parentNode,g=this._normalizedIndex(r),v=this._normalizedIndex(o);u(f),3==r.nodeType&&(r=f.childNodes[g]),u(m),3==o.nodeType&&(o=m.childNodes[v]),c?(3==r.nodeType?e.setStart(r,h):e[d?"setStartAfter":"setStartBefore"](r),e.collapse(!0)):(3==r.nodeType?e.setStart(r,h):e.setStartBefore(r),3==o.nodeType?e.setEnd(o,p):e.setEndAfter(o)),i.caret&&i.removeCaret(e)}}),S=/[\u0009-\u000d]|\u0020|\u00a0|\ufeff|\.|,|;|:|!|\(|\)|\?/,T={nodes:function(e){var t=T.textNodes(e);return t.length||(e.selectNodeContents(e.commonAncestorContainer),(t=T.textNodes(e)).length||(t=a.significantChildNodes(e.commonAncestorContainer))),t},textNodes:function(e){return new y(e).enumerate().filter((function(e){return a.allowsTextContent(e.parentElement)}))},editableTextNodes:function(e){var t=r.Immutables&&r.Immutables.immutableParent,n=[];return t&&!t(e.commonAncestorContainer)&&(n=new k(e).enumerate().filter((function(e){return a.allowsTextContent(e.parentElement)}))),n},documentFromRange:function(e){var t=e.startContainer;return 9==t.nodeType?t:t.ownerDocument},createRange:function(e){return e.createRange()},selectRange:function(e){var t=T.image(e);t&&(e.setStartAfter(t),e.setEndAfter(t));var n=h.selectionFromRange(e);n.removeAllRanges(),n.addRange(e)},stringify:function(e){return t.format("{0}:{1} - {2}:{3}",a.name(e.startContainer),e.startOffset,a.name(e.endContainer),e.endOffset)},split:function(e,t,n){function i(i){var r=e.cloneRange();r.collapse(i),r[i?"setStartBefore":"setEndAfter"](t);var o=r.extractContents();n&&(o=a.trim(o)),a[i?"insertBefore":"insertAfter"](o,t)}i(!0),i(!1)},mapAll:function(t,n){var i=[];return new g(t).traverse((function(t){var r=n(t);r&&e.inArray(r,i)<0&&i.push(r)})),i},getAll:function(e,t){var n=t;return"string"==typeof t&&(t=function(e){return a.is(e,n)}),T.mapAll(e,(function(e){if(t(e))return e}))},getMarkers:function(e){return T.getAll(e,(function(e){return"k-marker"==e.className}))},image:function(e){var t=T.getAll(e,"img");if(1==t.length)return t[0]},isStartOf:function(e,t){if(0!==e.startOffset)return!1;for(var n=e.cloneRange();0===n.startOffset&&n.startContainer!=t;){for(var i=a.findNodeIndex(n.startContainer),r=n.startContainer.parentNode;i>0&&r[i-1]&&a.insignificant(r[i-1]);)i--;n.setStart(r,i)}return 0===n.startOffset&&n.startContainer==t},isEndOf:function(e,t){var n=e.cloneRange();n.collapse(!1);var i=n.startContainer;a.isDataNode(i)&&n.startOffset==a.getNodeLength(i)&&(n.setStart(i.parentNode,a.findNodeIndex(i)+1),n.collapse(!0)),n.setEnd(t,a.getNodeLength(t));var r=[];return new g(n).traverse((function(e){a.insignificant(e)||a.isDataNode(e)&&/^[\ufeff]*$/.test(e.nodeValue)||r.push(e)})),!r.length},wrapSelectedElements:function(e){for(var t=a.editableParent(e.startContainer),n=a.editableParent(e.endContainer);0===e.startOffset&&e.startContainer!=t;)e.setStart(e.startContainer.parentNode,a.findNodeIndex(e.startContainer));function i(e,t){var n=a.getNodeLength(t);if(e==n)return!0;for(var i=e;i<n;i++)if(!a.insignificant(t.childNodes[i]))return!1;return!0}for(;i(e.endOffset,e.endContainer)&&e.endContainer!=n;)e.setEnd(e.endContainer.parentNode,a.findNodeIndex(e.endContainer)+1);return e},expand:function(e){var t=e.cloneRange(),n=t.startContainer.childNodes[0===t.startOffset?0:t.startOffset-1],i=t.endContainer.childNodes[t.endOffset];if(!l(n)||!l(i))return t;var r=n.nodeValue,o=i.nodeValue;if(!r||!o)return t;var a=r.split("").reverse().join("").search(S),s=o.search(S);return a&&s?(s=-1==s?o.length:s,a=-1==a?0:r.length-a,t.setStart(n,a),t.setEnd(i,s),t):t},isExpandable:function(e){var t=e.startContainer,n=T.documentFromRange(e);if(t==n||t==n.body)return!1;var i=e.cloneRange(),r=t.nodeValue;if(!r)return!1;var o=r.substring(0,i.startOffset),a=r.substring(i.startOffset),s=0,l=0;return o&&(s=o.split("").reverse().join("").search(S)),a&&(l=a.search(S)),s&&l}};i(r,{SelectionUtils:h,W3CRange:p,RangeIterator:g,W3CSelection:v,RangeEnumerator:y,RestorePoint:x,Marker:C,RangeUtils:T})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Class,i=t.ui.editor,r=i.Dom,o=t.template,a=i.RangeUtils,s=["ul","ol","tbody","thead","table"],l="k-immutable",c="["+l+"]",d=function(t){return e(t).is("body,.k-editor")},u=function(e){return e.getAttribute&&"false"==e.getAttribute("contenteditable")},h=function(e){return r.closestBy(e,u,d)},p=function(e){return!!h(e.commonAncestorContainer)||!(!h(e.startContainer)&&!h(e.endContainer)||0!==a.editableTextNodes(e).length)},f=function(e){for(var t="",n="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ",i=e||10;i>0;--i)t+=n.charAt(Math.round(61*Math.random()));return t},m=function(e){var t=e?e.options:undefined;t&&t.finder&&t.finder._initOptions({immutables:!0})},g=n.extend({init:function(n){this.editor=n,this.serializedImmutables={},this.options=e.extend({},n&&n.options&&n.options.immutables);var i=t.ui.Editor.defaultTools;m(i.justifyLeft),m(i.justifyCenter),m(i.justifyRight),m(i.justifyFull)},serialize:function(e){var t,n=this._toHtml(e);return-1===n.indexOf(l)?(t=this.randomId(),n=n.replace(/>/," "+l+'="'+t+'">')):t=n.match(/k-immutable\s*=\s*['"](.*)['"]/)[1],this.serializedImmutables[t]=e,n},_toHtml:function(e){var t,n=this.options.serialization;switch(typeof n){case"string":return o(n)(e);case"function":return n(e);default:return"<"+(t=r.name(e))+"></"+t+">"}},deserialize:function(n){var i=this,r=this.options.deserialization;e(c,n).each((function(){var n=this.getAttribute(l),o=i.serializedImmutables[n];t.isFunction(r)&&r(this,o),e(this).replaceWith(o)})),i.serializedImmutables={}},randomId:function(e){return f(e)},keydown:function(e,n){var i=function(e){var n=t.keys;return e===n.BACKSPACE||e==n.DELETE}(e.keyCode);if(i&&this._cancelDeleting(e,n)||!i&&this._cancelTyping(e,n))return e.preventDefault(),!0},_cancelTyping:function(e,t){var n=this.editor.keyboard;return t.collapsed&&!n.typingInProgress&&n.isTypingKey(e)&&p(t)},_cancelDeleting:function(e,n){var i=t.keys,o=e.keyCode===i.BACKSPACE,a=e.keyCode==i.DELETE;if(!o&&!a)return!1;var l=!1;if(n.collapsed){if(p(n))return!0;var c=this.nextImmutable(n,a);if(c&&o){var d=r.closest(n.commonAncestorContainer,"li");if(d){var u=r.closest(c,"li");if(u&&u!==d)return l}}if(c&&!r.tableCell(c)){if(r.parentOfType(c,s)===r.parentOfType(n.commonAncestorContainer,s)){for(;c&&1==c.parentNode.childNodes.length;)c=c.parentNode;if(r.tableCell(c))return l;this._removeImmutable(c,n)}l=!0}}return l},nextImmutable:function(e,t){var n=e.commonAncestorContainer;if(r.isBom(n)||t&&a.isEndOf(e,n)||!t&&a.isStartOf(e,n)){var i=this._nextNode(n,t);if(i&&r.isBlock(i)&&!h(i))for(;i&&i.children&&i.children[t?0:i.children.length-1];)i=i.children[t?0:i.children.length-1];return h(i)}},_removeImmutable:function(e,t){var n=this.editor,o=new i.RestorePoint(t,n.body);r.remove(e),i._finishUpdate(n,o)},_nextNode:function(e,t){for(var n,i=t?"nextSibling":"previousSibling",o=e;o&&!n&&!r.isChildOfBaseContainer(o);)(n=o[i])&&r.isDataNode(n)&&/^\s|[\ufeff]$/.test(n.nodeValue)&&(n=(o=n)[i]),n||(o=o.parentNode);return n}});g.immutable=u,g.immutableParent=h,g.expandImmutablesIn=function(e){var t=h(e.startContainer),n=h(e.endContainer);(t||n)&&(t&&e.setStartBefore(t),n&&e.setEndAfter(n))},g.immutablesContext=p,g.toolsToBeUpdated=["bold","italic","underline","strikethrough","superscript","subscript","forecolor","backcolor","fontname","fontsize","createlink","unlink","autolink","addcolumnleft","addcolumnright","addrowabove","addrowbelow","deleterow","deletecolumn","mergecells","formatting","cleanformatting"],g.removeImmutables=function(t){var n,i,o,a={empty:!0};return e(t).find("[contenteditable='false']").each((function(t,s){n=r.name(s),i=f(),o="<"+n+" "+l+"='"+i+"'></"+n+">",a[i]={node:s,style:e(s).attr("style")},a.empty=!1,e(s).replaceWith(o)})),a},g.restoreImmutables=function(t,n){var i,r;e(t).find(c).each((function(t,o){i=o.getAttribute(l),r=n[i],e(o).replaceWith(r.node),r.style!=e(r.node).attr("style")&&e(r.node).removeAttr("style").attr("style",r.style)}))},i.Immutables=g}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Class,i=t.ui.editor,r=i.Dom,o=i.RestorePoint,a=i.Marker,s=e.extend;var l=n.extend({init:function(e){this.options=e,this.restorePoint=new o(e.range,e.body,{immutables:e.immutables}),this.marker=new a,this.formatter=e.formatter},getRange:function(){return this.restorePoint.toRange()},lockRange:function(e){return this.marker.add(this.getRange(),e)},releaseRange:function(e){this.marker.remove(e),this.editor.selectRange(e)},undo:function(){var e=this.restorePoint;e.restoreHtml(),this.editor.selectRange(e.toRange())},redo:function(){this.exec()},createDialog:function(n,i){var r=this.editor;return e(n).appendTo(document.body).kendoWindow(s({},r.options.dialogOptions,i)).closest(".k-window").addClass("k-editor-window").toggleClass("k-rtl",t.support.isRtl(r.wrapper)).end()},exec:function(){var e=this.lockRange(!0);this.formatter.editor=this.editor,this.formatter.toggle(e),this.releaseRange(e)},postExec:function(){this.editor._handleSpaceAndNewLines()},immutables:function(){return this.editor&&this.editor.options.immutables},expandImmutablesIn:function(e){this.immutables()&&(t.ui.editor.Immutables.expandImmutablesIn(e),this.restorePoint=new o(e,this.editor.body))},_actionButtonsTemplate:function({messages:e,insertButtonIcon:n,cancelButtonIcon:i}){return'<div class="k-actions k-actions-start k-actions-horizontal k-window-buttons">'+t.html.renderButton(`<button class="k-dialog-insert">${e.dialogInsert}</button>`,{themeColor:"primary",icon:n})+t.html.renderButton(`<button class="k-dialog-close">${e.dialogCancel}</button>`,{icon:i})+"</div>"}}),c=n.extend({init:function(e,t){this.body=e.body,this.startRestorePoint=e,this.endRestorePoint=t},redo:function(){r.removeChildren(this.body),this.body.innerHTML=this.endRestorePoint.html,this.editor.selectRange(this.endRestorePoint.toRange())},undo:function(){r.removeChildren(this.body),this.body.innerHTML=this.startRestorePoint.html,this.editor.selectRange(this.startRestorePoint.toRange())}});s(i,{_finishUpdate:function(e,t){var n=e.selectionRestorePoint=new o(e.getRange(),e.body),i=new c(t,n);return i.editor=e,e.undoRedoStack.push(i),e._refreshTools(),n},Command:l,GenericCommand:c})}(window.kendo.jQuery),function(e,t){var n=window.kendo,i=e.extend,r=n.ui.editor,o=r.EditorUtils,a=r.Command,s=r.Tool,l=r.Dom,c=a.extend({init:function(e){var t=this;t.options=e,a.fn.init.call(t,e),t.attributes=null,t.async=!0},exec:function(){var i,r,a=this,s=a.editor,d=s.options,u=s.options.messages,h=e(n.template(c.template)(u)).appendTo(document.body),p=".k-editor-textarea > textarea";function f(e){e.preventDefault(),h.data("kendoWindow").destroy(),s.immutables&&(s.immutables.serializedImmutables={}),s.focus()}d.serialization.immutables=s.immutables,r=l.getAllComments(s.body),i=o.cacheComments(s.value(),r),i=c.indent(i),i=o.retrieveComments(i,r),d.serialization.immutables=t;let m=this.createDialog(h,{title:u.viewHtml,_footerTemplate:c._footerTemplate,_footerMessages:u,width:600,height:400,resizable:!0,close:f,visible:!1}).find(p).val(i).end().data("kendoWindow");m.center().open(),m.wrapper.find(".k-dialog-update").on("click",(function(e){d.deserialization.immutables=s.immutables,s.value(h.find(p).val()),d.deserialization.immutables=t,f(e),a.change&&a.change(),s.trigger("change")})).end(),m.wrapper.find(".k-dialog-close").on("click",f).end(),h.find(p).trigger("focus")}});i(c,{template:()=>'<div class="k-editor-dialog k-popup-edit-form k-viewhtml-dialog"><span class="k-input k-textarea k-input-solid k-input-md k-rounded-md k-editor-textarea"><textarea class="k-input-inner !k-overflow-auto !k-resize-none"></textarea></span></div>',_footerTemplate:({dialogUpdate:e,dialogCancel:t})=>'<div class="k-actions k-actions-start k-actions-horizontal k-window-actions">'+n.html.renderButton(`<button class="k-dialog-update">${n.htmlEncode(e)}</button>`,{themeColor:"primary",icon:"check"})+n.html.renderButton(`<button class="k-dialog-close">${n.htmlEncode(t)}</button>`,{icon:"cancel-outline"})+"</div>",indent:function(e){return e.replace(/<\/(p|li|ul|ol|h[1-6]|table|tr|td|th)>/gi,"</$1>\n").replace(/<(ul|ol)([^>]*)><li/gi,"<$1$2>\n<li").replace(/<br \/>/gi,"<br />\n").replace(/\n$/,"")}}),n.ui.editor.ViewHtmlCommand=c,r.EditorUtils.registerTool("viewHtml",new s({command:c}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.ui.editor,r=i.Tool,o=i.Command,a=i.EditorUtils,s=o.extend({init:function(e){e.formatter=e.formatter();var t=e.formatter.finder;t&&a.formatByName("immutable",t.format)&&(t._initOptions({immutables:e.immutables}),e.finder&&e.finder._initOptions({immutables:e.immutables})),o.fn.init.call(this,e)}}),l=r.extend({init:function(e){r.fn.init.call(this,e)},command:function(e){return new s(n(e,{formatter:this.options.formatter,finder:this.options.finder}))},update:function(e,t){var n=this.options.finder.isFormatted(t),i=e.closest(".k-toolbar").getKendoToolBar();i&&e.getKendoToggleButton()&&i.toggle(e,n)}});e.extend(i,{FormatCommand:s,FormatTool:l})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Class,i=t.ui.editor,r=t.ui.Editor.fn.options.formats,o=i.Tool,a=i.FormatTool,s=i.Dom,l=i.RangeUtils,c=e.extend,d=i.EditorUtils.registerTool,u=i.EditorUtils.registerFormat,h="mousedown.kendoEditor",p="k-marker",f=n.extend({init:function(e){this.format=e},numberOfSiblings:function(e){var t,n=0,i=0,r=0,o=e.parentNode;for(t=o.firstChild;t;t=t.nextSibling)t!=e&&(t.className==p?r++:3==t.nodeType?n++:i++);return r>1&&o.firstChild.className==p&&o.lastChild.className==p?0:i+n},findSuitable:function(e,t){if(!t&&this.numberOfSiblings(e)>0)return null;for(var n=e.parentNode,i=this.format[0].tags;!s.ofType(n,i);){if(this.numberOfSiblings(n)>0)return null;n=n.parentNode}return n},findFormat:function(e){var t,n,i,r,o,a=this.format,l=s.attrEquals;for(t=0,n=a.length;t<n;t++){if(i=e,r=a[t].tags,o=a[t].attr,i&&s.ofType(i,r)&&l(i,o))return i;for(;i;)if((i=s.parentOfType(i,r))&&l(i,o))return i}return null},isFormatted:function(e){var t,n;for(t=0,n=e.length;t<n;t++)if(this.findFormat(e[t]))return!0;return!1}}),m=n.extend({init:function(e,t){this.finder=new f(e),this.attributes=c({},e[0].attr,t),this.tag=e[0].tags[0]},wrap:function(e){return s.wrap(e,s.create(e.ownerDocument,this.tag,this.attributes))},activate:function(e,t){this.finder.isFormatted(t)?(this.split(e),this.remove(t)):this.apply(t)},toggle:function(e){var t=(this.immutables()?l.editableTextNodes:l.textNodes)(e);t.length>0&&this.activate(e,t)},immutables:function(){return this.editor&&this.editor.options.immutables},apply:function(e){var t,n,i,r,o=[];if(e.length>1)for(t=0,n=e.length;t<n;t++)i=e[t],r=this.format(i,!0),o.push(r);else i=e[0],this.format(i,!1);this.consolidate(o)},format:function(e,t){var n=this.finder.findSuitable(e),i=this.attributes,r=i&&i.style||{};if(n)s.is(n,"font")&&(r.color&&n.removeAttribute("color"),r.fontName&&n.removeAttribute("face"),r.fontSize&&n.removeAttribute("size")),s.attr(n,i);else{if(t)for(;!s.isBlock(e.parentNode)&&1==e.parentNode.childNodes.length&&"true"!==e.parentNode.contentEditable;)e=e.parentNode;n=this.wrap(e)}return n},remove:function(e){var t,n,i;for(t=0,n=e.length;t<n;t++)(i=this.finder.findFormat(e[t]))&&(this.attributes&&this.attributes.style?(s.unstyle(i,this.attributes.style),i.style.cssText||i.attributes.class||s.unwrap(i)):s.unwrap(i))},split:function(e){var t,n,i=l.textNodes(e),r=i.length;if(r>0)for(t=0;t<r;t++)(n=this.finder.findFormat(i[t]))&&l.split(e,n,!0)},consolidate:function(e){for(var t,n;e.length>1;)if(t=e.pop(),n=e[e.length-1],t.previousSibling&&t.previousSibling.className==p&&n.appendChild(t.previousSibling),t.tagName==n.tagName&&t.previousSibling==n&&t.style.cssText==n.style.cssText&&t.className===n.className){for(;t.firstChild;)n.appendChild(t.firstChild);s.remove(t)}}}),g=f.extend({init:function(e,t,n,i){this.format=e,this.greedyProperty=t,this.fontAttr=n,this.defaultValue=i,f.fn.init.call(this,e)},getInlineCssValue:function(e){var n,i,r,o,a,l,c,d,u,h,p,f,m=e.attributes,g=t.trim;if(m)for(n=0,i=m.length;n<i;n++){if(o=(r=m[n]).nodeName,a=r.nodeValue,r.specified&&"style"==o)for(d=0,u=(l=g(a||e.style.cssText).split(";")).length;d<u;d++)if((c=l[d]).length){if(p=g((h=c.split(":"))[0].toLowerCase()),f=g(h[1]),p!=this.greedyProperty)continue;return p.indexOf("color")>=0?s.toHex(f):f}if(this.fontAttr&&r.specified&&o==this.fontAttr)return p=r.nodeValue,f=r.nodeValue,p.indexOf("color")>=0?s.toHex(f):f}},getFormatInner:function(t){var n,i,r,o=e(s.isDataNode(t)?t.parentNode:t).parentsUntil("[contentEditable]").addBack().toArray().reverse();for(n=0,i=o.length;n<i;n++)if(r="className"==this.greedyProperty?o[n].className:this.getInlineCssValue(o[n]))return r;return this.defaultValue||"inherit"},getFormat:function(e){var t,n,i=this.getFormatInner(e[0]);for(t=1,n=e.length;t<n;t++)if(i!=this.getFormatInner(e[t]))return"";return i},isFormatted:function(e){return""!==this.getFormat(e)}}),v=m.extend({init:function(e,n,i){m.fn.init.call(this,e,n),this.values=n,this.finder=new g(e,i),i&&(this.greedyProperty=t.toCamelCase(i))},activate:function(e,t){var n=this.greedyProperty,i="apply";this.split(e),n&&"inherit"==this.values.style[n]&&(i="remove"),this[i](t)}}),_=a.extend({init:function(e){a.fn.init.call(this,c(e,{finder:new f(e.format),formatter:function(){return new m(e.format)}}))}}),b=o.extend({update:function(e,t){var n=e.data(this.type);n.close(),n.value(this.finder.getFormat(t))}}),y=b.extend({init:function(e){o.fn.init.call(this,e),this.type="kendoComboBox",this.format=[{tags:["span","font"]}],this.finder=new g(this.format,e.cssAttr,e.fontAttr)},command:function(e){var t=this.options,n=this.format,r={};return new i.FormatCommand(c(e,{formatter:function(){return r[t.domAttr]=e.value,new v(n,{style:r},t.cssAttr)}}))},initialize:function(e,n){var i,r,a=this.options,s=a.name,l=e.data("kendoComboBox"),c=[];l&&(a.defaultValue&&(c=[{text:n.options.messages[a.defaultValue[0].text],value:a.defaultValue[0].value}]),i=c.concat(a.items?a.items:n.options[s]||[]),l.setDataSource(i),l.bind("change",(e=>{n._range=r,""!==e.sender.value()&&o.exec(n,s,e.sender.value())})),l.bind("close",(()=>{setTimeout((function(){n._deleteSavedRange()}),0)})),l.value("inherit"),l.wrapper.on(h,".k-select,.k-input-button,.k-input",(function(){var e=n.getRange();r=n._containsRange(e)?e:r})).on("keydown.kendoEditor",(function(e){e.keyCode===t.keys.ENTER&&(n._deleteSavedRange(),e.preventDefault())})))}}),w=o.extend({init:function(e){o.fn.init.call(this,e),this.format=[{tags:["span","font"]}],this.finder=new g(this.format,e.cssAttr)},options:{palette:"websafe",columns:18},update:function(){this._widget.close()},command:function(e){var t=this.options,n=this.format,r={};return new i.FormatCommand(c(e,{formatter:function(){return r[t.domAttr]=e.value,new v(n,{style:r},t.cssAttr)}}))},initialize:function(t,n){var i=this,r=i.options.name,a=this._widget=t.getKendoColorPicker();a&&(a.bind("change",(()=>{var e=a.value();e&&o.exec(n,r,e),delete i.storedRange,delete i._inputFocused,n.focus()})),a.bind("open",(()=>{i.storedRange=n.getRange(),a._popup.element.on(h,(function(t){e(t.target).is("input.k-color-value")||t.preventDefault()})),a._popup.element.is("[unselectable='on']")||a._popup.element.attr({unselectable:"on"}).find("*:not(input)").attr("unselectable","on").end().find("input").on("focus",(function(){i._inputFocused=!0})),a._popup.one("activate",(()=>{a._popup.element.find(".k-colorpalette").trigger("focus")}))})),a.bind("close",(e=>{a._popup.element.off(h)})),a.unbind("activate").bind("activate",(e=>{a._value&&"rgba(255, 255, 255, 0)"!==a._value.toCssRgba()&&a.trigger("change")})),a.wrapper.attr({unselectable:"on"}).find("*:not(input)").attr("unselectable","on"),a.value("transparent"))}});c(i,{InlineFormatFinder:f,InlineFormatter:m,DelayedExecutionTool:b,GreedyInlineFormatFinder:g,GreedyInlineFormatter:v,InlineFormatTool:_,FontTool:y,ColorTool:w}),u("bold",[{tags:["strong","b"]},{tags:["span"],attr:{style:{fontWeight:"bold"}}}]),d("bold",new _({key:"B",ctrl:!0,format:r.bold,ui:{togglable:!0}})),u("italic",[{tags:["em","i"]},{tags:["span"],attr:{style:{fontStyle:"italic"}}}]),d("italic",new _({key:"I",ctrl:!0,format:r.italic,ui:{togglable:!0}})),u("underline",[{tags:["span"],attr:{style:{textDecoration:"underline"}}},{tags:["u"]}]),d("underline",new _({key:"U",ctrl:!0,format:r.underline,ui:{togglable:!0}})),u("strikethrough",[{tags:["del","strike"]},{tags:["span"],attr:{style:{textDecoration:"line-through"}}}]),d("strikethrough",new _({format:r.strikethrough,ui:{togglable:!0}})),u("superscript",[{tags:["sup"]}]),d("superscript",new _({format:r.superscript,ui:{togglable:!0}})),u("subscript",[{tags:["sub"]}]),d("subscript",new _({format:r.subscript,ui:{togglable:!0}})),d("foreColor",new w({cssAttr:"color",fontAttr:"color",domAttr:"color",name:"foreColor",ui:{type:"component",overflow:"never",component:"ColorPicker",componentOptions:{views:["palette"],toolIcon:"foreground-color",palette:"websafe",columns:18,preview:!1,input:!1,buttons:!1,commandOn:"change",closeOnSelect:!0}}})),d("backColor",new w({cssAttr:"background-color",domAttr:"backgroundColor",name:"backColor",ui:{type:"component",overflow:"never",component:"ColorPicker",componentOptions:{views:["palette"],toolIcon:"droplet",palette:"websafe",columns:18,preview:!1,input:!1,buttons:!1,commandOn:"change",closeOnSelect:!0}}})),d("fontName",new y({cssAttr:"font-family",fontAttr:"face",domAttr:"fontFamily",name:"fontName",defaultValue:[{text:"fontNameInherit",value:"inherit"}],ui:{type:"component",component:"ComboBox",componentOptions:{dataValueField:"value",dataTextField:"text",valuePrimitive:!0},overflow:"never"}})),d("fontSize",new y({cssAttr:"font-size",fontAttr:"size",domAttr:"fontSize",name:"fontSize",defaultValue:[{text:"fontSizeInherit",value:"inherit"}],ui:{type:"component",component:"ComboBox",componentOptions:{dataValueField:"value",dataTextField:"text",valuePrimitive:!0},overflow:"never"}}))}(window.kendo.jQuery),function(e,t){var n=window.kendo,i=n.htmlEncode,r=n.Class,o=e.extend,a=n.ui.editor,s=a.Dom,l=a.RangeUtils,c=a.Command,d=a.Tool,u=a.InlineFormatter,h=a.InlineFormatFinder,p=l.textNodes,f=l.editableTextNodes,m=a.EditorUtils.registerTool,g=n.keys,v="http://",_=/^\w*:\/\//,b=/[\w\/\$\-_\*\?]/i,y=r.extend({findSuitable:function(e){return s.parentOfType(e,["a"])}}),w=r.extend({init:function(){this.finder=new y},apply:function(e,t){var n,i,r,o,a,c=this.immutables?f(e):p(e);if(t.innerText){i=l.documentFromRange(e),n=l.getMarkers(e),e.deleteContents(),o=s.create(i,"a",t),e.insertNode(o),a=o.parentNode,"a"==s.name(a)&&s.insertAfter(o,a),s.emptyNode(a)&&s.remove(a);for(var d=o,h=0;h<n.length;h++)s.insertAfter(n[h],d),d=n[h];n.length&&(s.insertBefore(i.createTextNode("\ufeff"),n[1]||n[0]),s.insertAfter(i.createTextNode("\ufeff"),n[1]||n[0]),e.setStartBefore(n[0]),e.setEndAfter(n[n.length-1]))}else(r=new u([{tags:["a"]}],t)).finder=this.finder,r.apply(c)}}),k=c.extend({init:function(e){var t=this;e.formatter={toggle:function(e){var n=t.immutables()?f(e):p(e);new u([{tags:["a"]}]).remove(n)}},this.options=e,c.fn.init.call(this,e)}}),x=c.extend({init:function(e){var t;this.options=e,c.fn.init.call(this,e),this.formatter=new w,e.url?this.exec=function(){this.formatter.immutables=t,this.formatter.apply(e.range,{href:e.url,innerText:e.text||e.url,target:e.target})}:(this.attributes=null,this.async=!0)},exec:function(){var t=this.editor.options.messages;this._initialText="",this._range=this.lockRange(!0),this.formatter.immutables=this.immutables();var n=p(this._range),i=n.length?this.formatter.finder.findSuitable(n[0]):null,r=n.length&&"img"==s.name(n[0]),o=this.createDialog("<div/>",{title:t.createLink,minWidth:340,close:this._close.bind(this),visible:!1}).data("kendoWindow");this._form=this._createForm(o),i&&(this._range.selectNodeContents(i),n=p(this._range)),this._initialText=this.linkText(n),o.wrapper.find(".k-dialog-insert").on("click",this._apply.bind(this)).end().find(".k-dialog-close").on("click",this._close.bind(this)).end().find(".k-form-field input").on("keydown",this._keydown.bind(this)).end().find("#k-editor-link-url").val(this.linkUrl(i)).end().find("#k-editor-link-text").val(this._initialText).end().find("#k-editor-link-title").val(i?i.title:"").end().find("#k-editor-link-target").prop("checked",!!i&&"_blank"==i.target).end().find(".k-editor-link-text-row").toggle(!r),this._dialog=o.center().open(),e("#k-editor-link-url",o.element).trigger("focus").select()},_createForm:function(t){var n=e("<div/>").appendTo(t.element),r=this.editor.options.messages,o=n.kendoForm({renderButtons:!1,items:[{field:"k-editor-link-url",label:i(r.linkWebAddress),title:i(r.linkWebAddress),editor:"TextBox"},{field:"k-editor-link-text",label:i(r.linkText),title:i(r.linkText),editor:"TextBox"},{field:"k-editor-link-title",label:i(r.linkToolTip),title:i(r.linkToolTip),editor:"TextBox"},{field:"k-editor-link-target",editorOptions:{label:i(r.linkOpenInNewWindow)},label:"",title:i(r.linkOpenInNewWindow),editor:"CheckBox"}]}).data("kendoForm");return n.find("#k-editor-link-text").parents(".k-form-field").addClass("k-editor-link-text-row"),t.element.after(e(this._actionButtonsTemplate({messages:r,insertButtonIcon:"link",cancelButtonIcon:"cancel-outline"}))),o},_keydown:function(e){var t=n.keys;e.keyCode==t.ENTER?this._apply(e):e.keyCode==t.ESC&&this._close(e)},_apply:function(t){var i,r,o,a=this._dialog.element,l=e("#k-editor-link-url",a).val(),c=e("#k-editor-link-text",a);l&&l!=v&&(l.indexOf("@")>0&&!/^(\w+:)|(\/\/)/i.test(l)&&(l="mailto:"+l),this.attributes={href:l},(i=e("#k-editor-link-title",a).val())&&(this.attributes.title=i),c.is(":visible")&&((r=n.trim(c.val()))||this._initialText?r&&r!==this._initialText&&(this.attributes.innerText=s.stripBom(r)):this.attributes.innerText=l),o=e("#k-editor-link-target",a).is(":checked"),this.attributes.target=o?"_blank":null,this.formatter.apply(this._range,this.attributes)),this._close(t),this.change&&this.change()},_close:function(e){e.preventDefault(),this._form.destroy(),this._dialog.destroy(),s.windowFromDocument(l.documentFromRange(this._range)).focus(),this.releaseRange(this._range)},linkUrl:function(e){return e?e.getAttribute("href",2):v},linkText:function(e){var t,n="";for(t=0;t<e.length;t++)n+=e[t].nodeValue;return s.stripBom(n||"")},redo:function(){var e=this.lockRange(!0);this.formatter.apply(e,this.attributes),this.releaseRange(e)}}),C=c.extend({init:function(e){c.fn.init.call(this,e),this.formatter=new w},exec:function(){var e=this.detectLink();if(e){var t=this.getRange(),i=new n.ui.editor.Marker,r=t.cloneRange();r.setStart(e.start.node,e.start.offset),r.setEnd(e.end.node,e.end.offset),t=this.lockRange(),i.add(r),this.formatter.apply(r,{href:this._ensureWebProtocol(e.text)}),i.remove(r),this.releaseRange(t)}},detectLink:function(){var e=this.getRange(),t=e.startContainer,n=e.startOffset;!t.previousSibling&&(s.isBom(t)&&!t.nextSibling||!n&&s.isDataNode(t))&&(t=t.parentNode,n=0);var i=new E({node:t,offset:n,cancelAtNode:function(e){return e&&"a"===s.name(e)}});return new T(i).detectLink()},changesContent:function(){return!!this.detectLink()},_ensureWebProtocol:function(e){return this._hasProtocolPrefix(e)?e:this._prefixWithWebProtocol(e)},_hasProtocolPrefix:function(e){return _.test(e)},_prefixWithWebProtocol:function(e){return v+e}}),S=d.extend({init:function(t){this.options=t,this.finder=new h([{tags:["a"]}]),d.fn.init.call(this,e.extend(t,{command:k}))},update:function(e,t){var n=this.finder.isFormatted(t),i=e.closest(".k-toolbar").data("kendoToolBar");n?i.enable(e,!0):i.enable(e,!1)}}),T=r.extend({init:function(e){this.traverser=e,this.start=A(),this.end=A(),this.text=""},detectLink:function(){var e=this.traverser.node,t=this.traverser.offset;if(s.isDataNode(e)){var n=e.data.substring(0,t);if(/\s{2}$/.test(s.stripBom(n)))return}else if(0===t){var i=s.closestEditableOfType(e,s.blockElements);i&&i.previousSibling&&this.traverser.init({node:i.previousSibling})}if(this.traverser.traverse(this._detectEnd.bind(this)),!this.end.blank()&&(this.traverser=this.traverser.clone(this.end),this.traverser.traverse(this._detectStart.bind(this)),!this._isLinkDetected())){var r=this.traverser.extendOptions(this.start);new I(r).traverse(this._skipStartPuntuation.bind(this)),this._isLinkDetected()||(this.start=A())}return this.start.blank()?null:{start:this.start,end:this.end,text:this.text}},_isLinkDetected:function(){return _.test(this.text)||/^w{3}\./i.test(this.text)},_detectEnd:function(e,t){var n=D(e,b);if(n>-1)return this.end.node=t,this.end.offset=n+1,!1},_detectStart:function(e,t){var n=D(e,/\s/),i=n+1;if(this.text=e.substring(i)+this.text,this.start.node=t,this.start.offset=i,n>-1)return!1},_skipStartPuntuation:function(e,t,n){var i,r=(i=/\w/.exec(e))?i.index:-1,o=r;if(-1===r&&(o=e.length),this.text=this.text.substring(o),this.start.node=t,this.start.offset=o+(0|n),r>-1)return!1}});function D(e,t){for(var n=e.length;n--&&!t.test(e[n]););return n}var A=function(){return{node:null,offset:null,blank:function(){return null===this.node&&null===this.offset}}},M=r.extend({init:function(n){this.node=n.node,this.offset=n.offset===t?s.isDataNode(this.node)&&this.node.length||0:n.offset,this.cancelAtNode=n.cancelAtNode||this.cancelAtNode||e.noop},traverse:function(e){e&&(this.cancel=!1,this._traverse(e,this.node,this.offset))},_traverse:function(e,n,i){if(n&&!this.cancel){if(3!==n.nodeType){var r=this.edgeNode(n);return this.cancel=this.cancel||this.cancelAtNode(r),this._traverse(e,r)}var o=n.data;i!==t&&(o=this.subText(o,i)),this.cancel=!1===e(o,n,i);var a=this.next(n);if(!a)for(var l=n.parentNode;!a&&s.isInline(l);)a=this.next(l),l=l.parentNode;this.cancel=this.cancel||this.cancelAtNode(a),this._traverse(e,a)}},extendOptions:function(t){return e.extend({node:this.node,offset:this.offset,cancelAtNode:this.cancelAtNode},t||{})},edgeNode:function(e){},next:function(e){},subText:function(e,t){}}),E=M.extend({subText:function(e,t){return e.substring(0,t)},next:function(e){return e.previousSibling},edgeNode:function(e){return e.lastChild},clone:function(e){var t=this.extendOptions(e);return new E(t)}}),I=M.extend({subText:function(e,t){return e.substring(t)},next:function(e){return e.nextSibling},edgeNode:function(e){return e.firstChild},clone:function(e){var t=this.extendOptions(e);return new I(t)}});o(n.ui.editor,{LinkFormatFinder:y,LinkFormatter:w,UnlinkCommand:k,LinkCommand:x,AutoLinkCommand:C,UnlinkTool:S,DomTextLinkDetection:T,LeftDomTextTraverser:E,RightDomTextTraverser:I}),m("createLink",new d({key:"K",ctrl:!0,command:x})),m("unlink",new S({key:"K",ctrl:!0,shift:!0,ui:{enable:!1}})),m("autoLink",new d({key:[g.ENTER,g.SPACEBAR],keyPressCommand:!0,command:C}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Class,i=e.extend,r=t.ui.editor,o=t.ui.Editor.fn.options.formats,a=r.Dom,s=r.FormatTool,l=r.EditorUtils,c=l.registerTool,d=l.registerFormat,u=r.RangeUtils,h=n.extend({init:function(e){this.format=e},contains:function(e,t){var n,i,r;for(n=0,i=t.length;n<i;n++)if(!(r=t[n])||!a.isAncestorOrSelf(e,r))return!1;return!0},findSuitable:function(t){var n,i,r,o=this.format,s=[];for(n=0,i=t.length;n<i;n++){for(var l=o.length-1;l>=0&&!(r=a.ofType(t[n],o[l].tags)?t[n]:a.closestEditableOfType(t[n],o[l].tags));l--);if(!r||"true"===r.contentEditable)return[];e.inArray(r,s)<0&&s.push(r)}for(this._resolveListsItems(s),n=0,i=s.length;n<i;n++)if(this.contains(s[n],s))return[s[n]];return s},_resolveListsItems:function(e){var t,n,i;for(t=0;t<e.length;t++)n=e[t],i=(i=a.is(n,"li")?n:a.wrapper(n))&&a.list(i)?i.children[0]:i,a.is(i,"li")&&(e[t]=i)},findFormat:function(e,t){var n,i,o,s,l,c=this.format,d=a.editableParent(e),u=this.options&&this.options.immutables,h=r.Immutables;for(n=0,i=c.length;n<i;n++){if(o=e,s=c[n].tags,l=c[n].attr,u&&s&&"immutable"==s[0]){var p=h.immutableParent(o);if(p&&a.attrEquals(p,l))return o}for(;o&&a.isAncestorOf(d,o);){if(a.ofType(o,s)&&a.attrEquals(o,l))return o;if(t&&t(o))break;o=o.parentNode}}return null},getFormat:function(e){var t,n,i=this,r=function(e){return i.findFormat(a.isDataNode(e)?e.parentNode:e)},o=r(e[0]);if(!o)return"";for(t=1,n=e.length;t<n;t++)if(o!=r(e[t]))return"";return o.nodeName.toLowerCase()},isFormatted:function(e,t){for(var n=0,i=e.length;n<i;n++)if(!this.findFormat(e[n],t))return!1;return!0}}),p=n.extend({init:function(e,t){this.format=e,this.values=t,this.finder=new h(e)},wrap:function(e,t,n){var i=1==n.length?a.blockParentOrBody(n[0]):a.commonAncestor.apply(null,n);a.isInline(i)&&(i=a.blockParentOrBody(i));var r,o,s=a.significantChildNodes(i),l=a.findNodeIndex(s[0]),c=a.create(i.ownerDocument,e,t);for(r=0;r<s.length;r++)o=s[r],a.isBlock(o)?(a.attr(o,t),c.childNodes.length&&(a.insertBefore(c,o),c=c.cloneNode(!1)),l=a.findNodeIndex(o)+1):c.appendChild(o);c.firstChild&&a.insertAt(i,c,l)},apply:function(t){var n,r=this.values;function o(e){return i({},e&&e.attr,r)}this._handleImmutables(t,!0);var s=a.filter("img",t),c=o(l.formatByName("img",this.format));if(e.each(s,(function(){a.attr(this,c)})),s.length!=t.length){var d=a.filter("img",t,!0),u=this.finder.findSuitable(d);if(u.length)for(var h=0,p=u.length;h<p;h++)n=l.formatByName(a.name(u[h]),this.format),a.attr(u[h],o(n));else n=this.format[0],this.wrap(n.tags[0],o(n),d)}},_handleImmutables:function(e,t){if(this.immutables()){var n=l.formatByName("immutable",this.format);if(n)for(var i=r.Immutables,o=e.length-1;o>=0;o--){var s=i.immutableParent(e[o]);s&&(s!==e[o+1]&&(t?a.attr(s,n.attr):a.unstyle(s,n.attr.style)),e.splice(o,1))}}},immutables:function(){return this.editor&&this.editor.options.immutables},remove:function(e){var t,n,i,r,o;for(this._handleImmutables(e,!1),t=0,n=e.length;t<n;t++)(i=this.finder.findFormat(e[t]))&&(o=a.name(i),(r=l.formatByName(o,this.format)).attr.style&&a.unstyle(i,r.attr.style),r.attr.className&&a.removeClass(i,r.attr.className))},toggle:function(e){var t=this,n=a.filterBy(u.nodes(e),a.htmlIndentSpace,!0);t.finder.isFormatted(n)?t.remove(n):t.apply(n)}}),f=n.extend({init:function(e,t){var n=this;n.format=e,n.values=t,n.finder=new h(e)},apply:function(e){var t,n,i,o,s,l,c,d,u=this.format,h=a.blockParents(e),f=u[0].tags[0];if(h.length)for(t=0,n=h.length;t<n;t++)d=h[t],this.immutables()&&r.Immutables.immutableParent(d)||("li"==(c=a.name(d))?(i=d.parentNode,o=new r.ListFormatter(i.nodeName.toLowerCase(),f),(s=this.editor.createRange()).selectNode(h[t]),o.toggle(s)):f&&("td"==c||d.attributes.contentEditable)?new p(u,this.values).apply(d.childNodes):(l=a.changeTag(d,f),a.attr(l,u[0].attr)));else{var m=new p(u,this.values);m.editor=this.editor,m.apply(e)}},toggle:function(e){var t=u.textNodes(e);t.length||(e.selectNodeContents(e.commonAncestorContainer),(t=u.textNodes(e)).length||(t=a.significantChildNodes(e.commonAncestorContainer))),this.apply(t)},immutables:function(){return this.editor&&this.editor.options.immutables}}),m=s.extend({init:function(e){s.fn.init.call(this,i(e,{finder:new h(e.format),formatter:function(){return new p(e.format)}}))}});i(r,{BlockFormatFinder:h,BlockFormatter:p,GreedyBlockFormatter:f,BlockFormatTool:m});var g=["ul","ol","li"];d("justifyLeft",[{tags:a.nonListBlockElements,attr:{style:{textAlign:"left"}}},{tags:["img"],attr:{style:{float:"left",display:"",marginLeft:"",marginRight:""}}},{tags:["immutable"],attr:{style:{float:"left",display:"",marginLeft:"",marginRight:""}}},{tags:g,attr:{style:{textAlign:"left",listStylePosition:""}}}]),c("justifyLeft",new m({format:o.justifyLeft,ui:{togglable:!0,group:"align"}})),d("justifyCenter",[{tags:a.nonListBlockElements,attr:{style:{textAlign:"center"}}},{tags:["img"],attr:{style:{display:"block",marginLeft:"auto",marginRight:"auto",float:""}}},{tags:["immutable"],attr:{style:{display:"block",marginLeft:"auto",marginRight:"auto",float:""}}},{tags:g,attr:{style:{textAlign:"center",listStylePosition:"inside"}}}]),c("justifyCenter",new m({format:o.justifyCenter,ui:{togglable:!0,group:"align"}})),d("justifyRight",[{tags:a.nonListBlockElements,attr:{style:{textAlign:"right"}}},{tags:["img"],attr:{style:{float:"right",display:"",marginLeft:"",marginRight:""}}},{tags:["immutable"],attr:{style:{float:"right",display:"",marginLeft:"",marginRight:""}}},{tags:g,attr:{style:{textAlign:"right",listStylePosition:"inside"}}}]),c("justifyRight",new m({format:o.justifyRight,ui:{togglable:!0,group:"align"}})),d("justifyFull",[{tags:a.nonListBlockElements,attr:{style:{textAlign:"justify"}}},{tags:["img"],attr:{style:{display:"block",marginLeft:"auto",marginRight:"auto",float:""}}},{tags:["immutable"],attr:{style:{display:"block",marginLeft:"auto",marginRight:"auto",float:""}}},{tags:g,attr:{style:{textAlign:"justify",listStylePosition:""}}}]),c("justifyFull",new m({format:o.justifyFull,ui:{togglable:!0,group:"align"}}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Class,i=e.extend,r=t.ui.editor,o=r.Dom,a=r.RangeUtils,s=r.Command,l=r.FormatTool,c=r.BlockFormatFinder,d=a.textNodes,u=r.EditorUtils.registerTool,h=c.extend({init:function(e){this.tag=e.tag,this.attr=e.attr,this.altAttr=e.altAttr;var t=this.tags=["ul"==this.tag?"ol":"ul",this.tag],n=[{tags:t,attr:this.attr}];this.altAttr&&n.push({tags:t,attr:this.altAttr}),c.fn.init.call(this,n)},matchesType:function(e){return o.attrEquals(e,this.attr)||this.altAttr&&o.attrEquals(e,this.altAttr)},isList:function(e){return o.list(e)},isFormatted:function(e){var t,n,i=[];for(n=0;n<e.length;n++)(t=this.findFormat(e[n],this.isList))&&o.name(t)==this.tag&&this.matchesType(t)&&i.push(t);if(i.length<1)return!1;if(i.length!=e.length)return!1;for(n=0;n<i.length&&i[n].parentNode==t.parentNode;n++)if(i[n]!=t)return!1;return!0},findSuitable:function(e){var t=this.findFormat(e[0],this.isList);return t&&o.name(t)==this.tag?t:null}}),p=n.extend({init:function(t,n){var i=this;t=e.isPlainObject(t)?t:{tag:t,attr:null},i.tag=t.tag,i.attr=t.attr,i.finder=new h(t),i.unwrapTag=n},isList:function(e){return o.list(e)},immutables:function(){return this.editor&&!!this.editor.options.immutables},wrap:function(t,n){var i,a,s=o.create(t.ownerDocument,"li"),l=this.immutables()?r.Immutables.immutable:e.noop;for(i=0;i<n.length;i++)if(a=n[i],o.is(a,"li"))t.appendChild(a);else if(this.isList(a))for(;a.firstChild;)t.appendChild(a.firstChild);else if(o.is(a,"td")){for(;a.firstChild;)s.appendChild(a.firstChild);t.appendChild(s),a.appendChild(t),t=t.cloneNode(!1),s=s.cloneNode(!1)}else s.appendChild(a),o.isBlock(a)&&(t.appendChild(s),l(a)||o.unwrap(a),s=s.cloneNode(!1));s.firstChild&&t.appendChild(s)},containsAny:function(e,t){for(var n=0;n<t.length;n++)if(o.isAncestorOrSelf(e,t[n]))return!0;return!1},suitable:function(e,t){if("k-marker"==e.className){var n=e.nextSibling;if(n&&o.isBlock(n))return!1;if((n=e.previousSibling)&&o.isBlock(n))return!1}return this.containsAny(e,t)||o.isInline(e)||3==e.nodeType},_parentLists:function(t){var n=o.closestEditable(t);return e(t).parentsUntil(n,"ul,ol")},split:function(e){var t,n,i,r=d(e);if(r.length){t=o.parentOfType(r[0],["li"]),n=o.parentOfType(r[r.length-1],["li"]),e.setStartBefore(t),e.setEndAfter(n);for(var s=0,l=r.length;s<l;s++){var c=this.finder.findFormat(r[s]);c&&((i=this._parentLists(c)).length?a.split(e,i.last()[0],!0):a.split(e,c,!0))}}},merge:function(e,t){for(var n,i=t.previousSibling;i&&("k-marker"==i.className||3==i.nodeType&&o.isWhitespace(i));)i=i.previousSibling;if(i&&o.name(i)==e&&this.finder.matchesType(i)){for(;t.firstChild;)i.appendChild(t.firstChild);o.remove(t),t=i}for(n=t.nextSibling;n&&("k-marker"==n.className||3==n.nodeType&&o.isWhitespace(n));)n=n.nextSibling;if(n&&o.name(n)==e&&this.finder.matchesType(n)){for(;t.lastChild;)n.insertBefore(t.lastChild,n.firstChild);o.remove(t)}},breakable:function(e){return e!=e.ownerDocument.body&&!/table|tbody|thead|tr|td/.test(o.name(e))&&!e.attributes.contentEditable},findSuitableNode:function(e){var t,n=this,i=n.finder,r=n.tag;return(t=i.findSuitable(e))||(t=(i=new h({tag:"ul"==r?"ol":"ul"})).findSuitable(e)),t||(t=(t=(i=new h({tag:r})).findSuitable(e))&&n.finder.matchesType(t)?null:t),t},applyOnSection:function(t,n){var i,r=this.tag,a=this.attr,s=o.closestSplittableParent(n),l=[],c=this.findSuitableNode(n);function d(){l.push(this)}/table|tbody|thead/.test(o.name(s))?i=e.map(n,(function(e){return o.parentOfType(e,["td"])})):(i=o.significantChildNodes(s),e.grep(i,o.isBlock).length&&(i=e.grep(i,function(e){return this.containsAny(e,n)}.bind(this))),i.length||(i=n));for(var u=0;u<i.length;u++){var h=i[u];(!c||!o.isAncestorOrSelf(c,h))&&this.suitable(h,n)&&(c&&this.isList(h)?(e.each(h.children,d),o.remove(h)):l.push(h))}for(l.length==i.length&&this.breakable(s)&&(l=[s]),c||(c=o.create(s.ownerDocument,r,a),o.isBlock(l[0])&&o.mergeAttributes(l[0],c),o.insertBefore(c,l[0])),this.wrap(c,l);o.isBom(c.nextSibling);)o.remove(c.nextSibling);this.finder.matchesType(c)||(c.removeAttribute("type"),c.style.listStyleType="",o.mergeAttributes(o.create(s.ownerDocument,r,a),c,!0)),c&&""===c.getAttribute("type")&&c.removeAttribute("type"),o.is(c,r)||o.changeTag(c,r),this.merge(r,c)},apply:function(t){var n,i,a,s,l=0,c=[],d=t.length,u=this.immutables()?r.Immutables.immutableParent:e.noop;function h(){n&&c.push({section:n,nodes:i})}for(l=0;l<d;l++)s=u(t[l])||t[l],a=o.closestEditable(s,["td","th","body"]),n&&a==n?i.push(s):(h(),i=[s],n=a);for(h(),l=0;l<c.length;l++)this.applyOnSection(c[l].section,c[l].nodes)},unwrap:function(e){var t,n,i,r,a=e.ownerDocument.createDocumentFragment(),s=this.unwrapTag;for(n=e.firstChild;n;n=n.nextSibling){for(i=o.create(e.ownerDocument,s||"p");n.firstChild;)r=n.firstChild,o.isBlock(r)?(i.firstChild&&(a.appendChild(i),i=o.create(e.ownerDocument,s||"p")),a.appendChild(r)):i.appendChild(r);i.firstChild&&a.appendChild(i)}(t=this._parentLists(e))[0]?(o.insertAfter(a,t.last()[0]),t.last().remove()):o.insertAfter(a,e),o.remove(e)},remove:function(e){for(var t,n=0,i=e.length;n<i;n++)(t=this.finder.findFormat(e[n]))&&this.unwrap(t)},toggle:function(e){var t=this,n=d(e),i=e.commonAncestorContainer;if(!n.length&&(e.selectNodeContents(i),!(n=d(e)).length)){var r=i.ownerDocument.createTextNode("");e.startContainer.appendChild(r),n=[r],e.selectNode(r.parentNode)}n=o.filterBy(n,o.htmlIndentSpace,!0),t.finder.isFormatted(n)?(t.split(e),t.remove(n)):t.apply(n)}}),f=s.extend({init:function(e){e.formatter=new p({tag:e.tag,attr:e.attr}),s.fn.init.call(this,e)}}),m=l.extend({init:function(e){this.options=e,l.fn.init.call(this,i(e,{finder:new h(e)}))},command:function(e){return new f(i(e,{tag:this.options.tag,attr:this.options.attr}))}});i(r,{ListFormatFinder:h,ListFormatter:p,ListCommand:f,ListTool:m}),u("insertUnorderedList",new m({tag:"ul",attr:{style:{listStyleType:""},type:""},ui:{togglable:!0,group:"lists"}})),u("insertOrderedList",new m({tag:"ol",attr:{style:{listStyleType:""},type:""},ui:{togglable:!0,group:"lists"}})),u("insertUpperRomanList",new m({tag:"ol",attr:{style:{listStyleType:"upper-roman"}},altAttr:{type:"I"},ui:{togglable:!0,group:"lists"}})),u("insertLowerRomanList",new m({tag:"ol",attr:{style:{listStyleType:"lower-roman"}},altAttr:{type:"i"},ui:{togglable:!0,group:"lists"}}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.ui.editor,i=n.Tool,r=n.DelayedExecutionTool,o=n.Command,a=n.Dom,s=n.EditorUtils,l=n.RangeUtils,c=s.registerTool,d=r.extend({init:function(e){var n=this;i.fn.init.call(n,t.deepExtend({},n.options,e)),n.type="kendoDropDownList",n.finder={getFormat:function(){return""}}},options:{items:[{text:"Paragraph",value:"p"},{text:"Quotation",value:"blockquote"},{text:"Heading 1",value:"h1"},{text:"Heading 2",value:"h2"},{text:"Heading 3",value:"h3"},{text:"Heading 4",value:"h4"},{text:"Heading 5",value:"h5"},{text:"Heading 6",value:"h6"}],width:110},toFormattingItem:function(e){var t=e.value;if(!t)return e;if(e.tag||e.className)return e;var n=t.indexOf(".");return 0===n?e.className=t.substring(1):-1==n?e.tag=t:(e.tag=t.substring(0,n),e.className=t.substring(n+1)),e},command:function(t){var i=this,r=t.value;return r=this.toFormattingItem(r),new n.FormatCommand({range:t.range,formatter:function(){var t,o=(r.tag||r.context||"span").split(","),s=[{tags:o,attr:{className:r.className||""}}];return(t=e.inArray(o[0],a.inlineElements)>=0?new n.GreedyInlineFormatter(s):new n.GreedyBlockFormatter(s)).editor=i.editor,t}})},decorate:function(t){var n,i,r,o,s=this.component,l=s.dataSource,c=l.data();if(t&&s.list.css("background-color",a.getEffectiveBackground(e(t))),this.component&&this.component.options&&!1!==this.component.options.unsafeInline)for(n=0;n<c.length;n++)i=c[n].tag||"span",r=c[n].className,o=(o=a.inlineStyle(t,i,{className:r})).replace(/"/g,"'"),c[n].style=o+";display:inline-block";l.trigger("change")},initialize:function(e,t){var n=this.options,r=n.name,o=this,a=e.getKendoDropDownList();a&&(o.editor=t,o.component=a,e.closest(".k-dropdownlist").width(n.width),a.setOptions({optionLabel:t.options.messages.formatting,change:()=>{var e=a.dataItem();e&&i.exec(t,r,e.toJSON())},dataBound:function(){var e,t=a.dataSource.data(),n=a.list.parent().find(".k-list-optionlabel");for(e=0;e<t.length;e++)t[e]=o.toFormattingItem(t[e]);n.length&&n.remove()}}))},getFormattingValue:function(t,n){for(var i=0;i<t.length;i++){var r=t[i],o=(r.tag||r.context||"")+(r.className?"."+r.className:"");if(e(n[0]).closest(o)[0]){if(1==n.length)return r.value;for(var a=1;a<n.length&&e(n[a]).closest(o)[0];a++)if(a==n.length-1)return r.value}}return""},update:function(t,n){var i=e(t).data(this.type);if(i){var o,s,l=i.dataSource,c=l.data(),d=a.commonAncestor.apply(null,n);if(d==a.closestEditable(d)||this._ancestor!=d){for(this._ancestor=d,o=0;o<c.length;o++)s=c[o].context,c[o].visible=!s||!!e(d).closest(s).length;l.filter([{field:"visible",operator:"eq",value:!0}]),r.fn.update.call(this,t,n),i.value(this.getFormattingValue(l.view(),n)),i.wrapper.toggleClass("k-disabled",!l.view().length)}}},destroy:function(){this._ancestor=null}}),u=o.extend({exec:function(){var e=this.lockRange(!0);this.tagsToClean=this.options.remove||"strong,em,span,sup,sub,del,b,i,u,font".split(","),l.wrapSelectedElements(e);for(var t=l.mapAll(e,(function(e){return e})),n=t.length-1;n>=0;n--){var i=t[n];this.immutableParent(i)||this.clean(i)}this.releaseRange(e)},clean:function(i){if(i&&!a.isMarker(i)){var r=a.name(i);if("ul"==r||"ol"==r){var o=new n.ListFormatter(r),s=i.previousSibling,l=i.nextSibling;for(o.unwrap(i);s&&s!=l;s=s.nextSibling)this.clean(s)}else if("blockquote"==r)a.changeTag(i,"p");else if(1!=i.nodeType||a.insignificant(i))!function(e){var i=a.closestEditableOfType(e,["li"]);if(i){var r=new n.ListFormatter(a.name(i.parentNode)),o=t.ui.editor.W3CRange.fromNode(e);o.selectNode(i),r.toggle(o)}}(i);else{for(var c=i.childNodes.length-1;c>=0;c--)this.clean(i.childNodes[c]);i.removeAttribute("style"),i.removeAttribute("class")}e.inArray(r,this.tagsToClean)>-1&&a.unwrap(i)}},immutableParent:function(e){return this.immutables()&&n.Immutables.immutableParent(e)}});e.extend(n,{FormattingTool:d,CleanFormatCommand:u}),c("formatting",new d({ui:{type:"component",component:"DropDownList",componentOptions:{dataTextField:"text",dataValueField:"value",highlightFirst:!1,autoWidth:!0,template:t.template((e=>`<span unselectable="on" ${e.style?`class="k-d-block" style="display:block;${e.style||""}`:""}">${t.htmlEncode(e.text)}</span>`))},overflow:"never"}})),c("cleanFormatting",new i({command:u}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.htmlEncode,r=t.ui.editor,o=r.EditorUtils,a=r.Dom,s=o.registerTool,l=r.RangeUtils,c=r.Command,d=t.keys,u="#k-editor-image-url",h="#k-editor-image-title",p="#k-editor-image-width",f="#k-editor-image-height",m=c.extend({init:function(e){var t=this;c.fn.init.call(t,e),t.async=!0,t.attributes={}},insertImage:function(e,t){var n=this.attributes,i=l.documentFromRange(t);if(n.src&&"http://"!=n.src){var r=function(){setTimeout((function(){n.width||e.removeAttribute("width"),n.height||e.removeAttribute("height"),e.removeAttribute("complete")}))};if(!e)return(e=a.create(i,"img",n)).onload=e.onerror=r,t.deleteContents(),t.insertNode(e),e.nextSibling||a.insertAfter(i.createTextNode("\ufeff"),e),r(),t.setStartAfter(e),t.setEndAfter(e),l.selectRange(t),!0;e.onload=e.onerror=r,a.attr(e,n),r()}return!1},redo:function(){var e=this,t=e.lockRange();e.insertImage(l.image(t),t)||e.releaseRange(t)},exec:function(){var e,i,r=this,o=r.lockRange(),s=!1,c=l.image(o),m=c&&c.getAttribute("width")||"",g=c&&c.getAttribute("height")||"",v=t.support.browser.msie,_=r.editor.options,b=_.messages,y=_.imageBrowser,w=!!(t.ui.ImageBrowser&&y&&y.transport&&undefined!==y.transport.read),k={title:b.insertImage,visible:!1,resizable:w};function x(t){var n=e.element,i=parseInt(n.find(p).val(),10),a=parseInt(n.find(f).val(),10);r.attributes={src:n.find(u).val().replace(/ /g,"%20"),alt:n.find(h).val()},r.attributes.width=null,r.attributes.height=null,!isNaN(i)&&i>0&&(r.attributes.width=i),!isNaN(a)&&a>0&&(r.attributes.height=a),s=r.insertImage(c,o),C(t),r.change&&r.change(),r.editor._handleSpaceAndNewLines()}function C(t){t.preventDefault(),i.destroy(),e.destroy(),a.windowFromDocument(l.documentFromRange(o)).focus(),s||r.releaseRange(o)}this.expandImmutablesIn(o),k.close=C,w&&(k.width=750),k.minWidth=350,e=this.createDialog("<div/>",k).data("kendoWindow"),i=r._createForm(e,w),e.element.toggleClass("k-filebrowser-dialog",w),e.wrapper.find(".k-dialog-insert").on("click",x).end().find(".k-dialog-close").on("click",C).end().find(".k-form-field input").on("keydown",(function(e){e.keyCode==d.ENTER?x(e):e.keyCode==d.ESC&&C(e)})).end().find(u).val(c?c.getAttribute("src",2):"http://").end().find(h).val(c?c.alt:"").end().find(p).val(m).end().find(f).val(g).end();var S=e.element;if(w&&(this._imageBrowser=new t.ui.ImageBrowser(S.find(".k-imagebrowser"),n({},y)),this._imageBrowser.bind("change",(function(e){"f"===e.selected.get("type")&&S.find(u).val(this.value())})),this._imageBrowser.bind("apply",x)),v){var T=S.closest(".k-window").height();S.css("max-height",T)}e.center().open(),S.find(u).trigger("focus").select()},_createForm:function(t,n){var r=e("<div/>").appendTo(t.element),o=this.editor.options.messages,a=r.kendoForm({renderButtons:!1,items:[{field:"k-editor-image-url",label:i(o.imageWebAddress),editor:"TextBox"},{field:"k-editor-image-title",label:i(o.imageAltText),editor:"TextBox"},{field:"k-editor-image-width",label:i(o.imageWidth),editor:"TextBox"},{field:"k-editor-image-height",label:i(o.imageHeight),editor:"TextBox"}]}).data("kendoForm");return n&&r.prepend(e('<div class="k-filebrowser k-imagebrowser"></div>')),t.element.after(e(this._actionButtonsTemplate({messages:o,insertButtonIcon:"image-add",cancelButtonIcon:"cancel-outline"}))),a}});t.ui.editor.ImageCommand=m,s("insertImage",new r.Tool({command:m}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.ui.editor,r=i.EditorUtils,o=i.Command,a=i.Tool,s=r.registerTool,l='<div contenteditable="false" class="k-loading-mask" style="width: 100%; height: 100%; position: absolute; top: 0px; left: 0px;"><div class="k-loading-image"></div><div class="k-loading-color"></div></div>',c=o.extend({exec:function(){(this.editor._uploadWidget||this._initializeUploadWidget()).element.click()},_initializeUploadWidget:function(){var t=this,n=t.editor,i=n.options.import,r=e('<input id="editorImport" name="files" type="file" />').kendoUpload({success:t._onUploadSuccess.bind(t),progress:t._onUploadProgress.bind(t),select:t._onUploadSelect.bind(t),error:t._onUploadError.bind(t),complete:t._onUploadComplete.bind(t),showFileList:!1,multiple:!1,async:{saveUrl:i.proxyURL,autoUpload:!0,saveField:"file"},validation:{allowedExtensions:i.allowedExtensions,maxFileSize:i.maxFileSize}}).getKendoUpload();return n._uploadWidget=r,r},_onUploadComplete:function(e){this._trigger("complete",e),e.sender.clearAllFiles(),this._removeLoadingOverlay()},_onUploadSuccess:function(e){this.editor.value(e.response.html.replace(/<\/?body>/gi,"")),this._trigger("success",e)},_onUploadProgress:function(e){this._trigger("progress",e)},_onUploadSelect:function(e){this._trigger("select",e),e.files[0].validationErrors||this._initLoadingOverlay()},_onUploadError:function(e){this._trigger("error",e)},_trigger:function(e,t){var n=this.editor,i=n.options.import;"function"==typeof i[e]&&i[e].call(n,t)},_initLoadingOverlay:function(){var n=this.editor.body;i.Dom.is(n,"body")?this._iframeWrapper=this._container=this.editor.wrapper.find("iframe").parent().css({position:"relative"}).append(l):this._container=e(n).append(l),t.ui.progress(this._container,!0)},_removeLoadingOverlay:function(){t.ui.progress(this._container,!1),e(this._iframeWrapper).css({position:""}),delete this._container,delete this._iframeWrapper}});n(i,{ImportCommand:c}),s("import",new a({command:c,ui:{showText:"both"}}))}(window.kendo.jQuery),function(e){var t=window.kendo.ui.editor,n=t.Command,i=t.GenericCommand,r=t.EditorUtils.registerTool,o=t.Tool,a=t.RestorePoint,s=e.extend,l=n.extend({init:function(e){n.fn.init.call(this,e),this.managesUndoRedo=!0},exec:function(){var e=this.editor,t=this.options,n=t.range,r=e.body,o=new a(n,r),s=t.html||t.value||"";e.selectRange(n),e.clipboard.paste(s,t),t.postProcess&&t.postProcess(e,e.getRange());var l=new i(o,new a(e.getRange(),r));l.editor=e,e.undoRedoStack.push(l),e.focus()}}),c=o.extend({initialize:function(e,t){var n=this.options,i=n.items?n.items:t.options.insertHtml,r=e.getKendoDropDownList();r&&(r.one("open",(()=>{var e=r.list.parent().find(".k-list-optionlabel");e.length&&e.remove()})),r.setOptions({dataSource:i,optionLabel:t.options.messages.insertHtml}),r.bind("change",(()=>{o.exec(t,"insertHtml",r.value())})))},command:function(e){return new l(e)},update:function(e){var t=e.data("kendoDropDownList");t.close(),t.value(null)}});s(t,{InsertHtmlCommand:l,InsertHtmlTool:c}),r("insertHtml",new c({ui:{initialValue:"Insert HTML",type:"component",component:"DropDownList",componentOptions:{dataTextField:"text",dataValueField:"value",autoSize:!0,highlightFirst:!1},overflow:"never"}}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.ui.editor,r=i.EditorUtils,o=i.Command,a=i.Tool,s=r.registerTool,l=o.extend({init:function(e){var t=this;t.options=e,o.fn.init.call(t,e),t.attributes=null,t.exportType=e.exportType},exec:function(){var e=this.lockRange(!0);this.postToProxy(),this.releaseRange(e)},postToProxy:function(){this.generateForm().appendTo("body").submit().remove()},generateForm:function(){var t=this,n=t.editor.options.exportAs,i=e("<form>").attr({action:n&&n.proxyURL||"",method:"POST"});return i.append([t.valueInput(),t.exportTypeInput(),t.fileNameInput(),t.antiForgeryInput()]),i},valueInput:function(){var t=this.editor;return e("<input>").attr({value:t.encodedValue(),name:"value",type:"hidden"})},exportTypeInput:function(){return e("<input>").attr({value:this.exportType,name:"exportType",type:"hidden"})},fileNameInput:function(){var t=this.editor,n=t.options.exportAs,i=n&&n.fileName||t.element.attr("id")||"editor";return e("<input>").attr({value:i,name:"fileName",type:"hidden"})},antiForgeryInput:function(){var t=e("meta[name=csrf-param],meta[name=_csrf_header]").attr("content");return e("input[name^='__RequestVerificationToken']").clone().add(e("input[name^='"+t+"']").clone())}}),c=a.extend({init:function(e){var n=this;a.fn.init.call(n,t.deepExtend({},n.options,e)),n.type="kendoDropDownList"},options:{items:[{text:"Docx",value:"docx"},{text:"Rtf",value:"rtf"},{text:"Pdf",value:"pdf"},{text:"Html",value:"html"},{text:"Plain Text",value:"txt"}]},command:function(e){var t=e.value;return new i.ExportAsCommand({range:e.range,exportType:t.exportType})},initialize:function(e,t){var n=e.getKendoDropDownList();this.editor=t,n.bind("change",this.changeHandler.bind(this))},changeHandler:function(e){this._exec(e.sender.value()),e.sender.value(null),e.sender.wrapper.find(".k-export-tool-text").text(t.htmlEncode(this.editor.options.messages.exportAs))},update:function(e,n){var i=e.data("kendoDropDownList");i.close(),i.value(null),e.closest(".k-dropdownlist").find(".k-export-tool-text").text(t.htmlEncode(this.editor.options.messages.exportAs))},_exec:function(e){e&&a.exec(this.editor,this.options.name,{exportType:e})},destroy:function(){this._ancestor=null}});n(i,{ExportAsTool:c,ExportAsCommand:l}),s("exportAs",new c({ui:{type:"component",overflow:"never",component:"DropDownList",componentOptions:{dataTextField:"text",dataValueField:"value",valuePrimitive:!0,value:null,width:"140px",highlightFirst:!1,autoWidth:!0,itemTemplate:e=>`<span class="k-link k-menu-link" data-value="${e.value}">${e.text}</strong></span>`,icon:"export",valueTemplate:()=>`<span class="k-editor-export">${t.ui.icon({icon:"export",iconClass:"k-button-icon"})}<span class="k-export-tool-text"></span></span>`}}}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Class,i=e.extend,r=t.ui.editor,o=r.Dom,a=r.EditorUtils.registerTool,s=r.Command,l=r.Tool,c=r.RangeUtils,d=o.blockElements,u=r.BlockFormatFinder,h=r.BlockFormatter;function p(t,n){var i="rtl"==e(t).css("direction")?"Right":"Left",r="td"!=o.name(t)?"margin"+i:"padding"+i;if(undefined===n)return t.style[r]||0;n>0?t.style[r]=n+"px":(t.style[r]="",t.style.cssText||t.removeAttribute("style"))}var f=n.extend({init:function(){this.finder=new u([{tags:o.blockElements}])},apply:function(t){t=o.filterBy(t,o.htmlIndentSpace,!0);var n,i,r,a,s,l=this.finder.findSuitable(t),c=[];if((l=this.mapImmutables(l)).length){for(n=0,i=l.length;n<i;n++)o.is(l[n],"li")?e(l[n]).index()?e.inArray(l[n].parentNode,c)<0&&c.push(l[n]):c.push(l[n].parentNode):c.push(l[n]);for(;c.length;)if(r=c.shift(),o.is(r,"li")){a=r.parentNode;var d=(s=e(r).prev("li")).find("ul,ol").last(),u=e(r).children("ul,ol")[0];if(u&&s[0])d[0]?(d.append(r),d.append(e(u).children()),o.remove(u)):(s.append(u),u.insertBefore(r,u.firstChild));else for((u=s.children("ul,ol")[0])||(u=o.create(r.ownerDocument,o.name(a),this.getListTypeAttr(a)),s.append(u));r&&r.parentNode==a;)u.appendChild(r),r=c.shift()}else{var f=parseInt(p(r),10)+30;p(r,f);for(var m=0;m<c.length;m++)e.contains(r,c[m])&&c.splice(m,1)}}else{new h([{tags:["p"]}],{style:{marginLeft:30}}).apply(t)}},getListTypeAttr:function(e){var t=e.getAttribute("type"),n=e.style.listStyleType;return t?{type:t}:{style:{listStyleType:n}}},mapImmutables:function(t){if(this.immutables){var n=[];return e.map(t,(function(t){var i=r.Immutables.immutableParent(t);if(i){if(-1!==e.inArray(i,n))return null;n.push(i)}return i||t}))}return t},remove:function(t){t=o.filterBy(t,o.htmlIndentSpace,!0);var n,i,r,a,s,l,c,d,u=this.finder.findSuitable(t);for(i=0,r=(u=this.mapImmutables(u)).length;i<r;i++){if((c=e(u[i])).is("li")){if((s=(a=c.parent()).parent()).is("li,ul,ol")&&!p(a[0])){if(n&&e.contains(n,s[0]))continue;(l=c.nextAll("li")).length&&e(a[0].cloneNode(!1)).appendTo(c).append(l),s.is("li")?c.insertAfter(s):c.appendTo(s),a.children("li").length||a.remove();continue}if(n==a[0])continue;n=a[0]}else n=u[i];d=parseInt(p(n),10)-30,p(n,d)}}}),m=s.extend({init:function(e){e.formatter={toggle:function(e){var t=new f;t.immutables=this.editor&&this.editor.options.immutables,t.apply(c.nodes(e))}.bind(this)},s.fn.init.call(this,e)}}),g=s.extend({init:function(e){e.formatter={toggle:function(e){var t=new f;t.immutables=this.editor&&this.editor.options.immutables,t.remove(c.nodes(e))}.bind(this)},s.fn.init.call(this,e)}}),v=l.extend({init:function(e){l.fn.init.call(this,e),this.finder=new u([{tags:d}])},initialize:function(t,n){e.extend(this.options,{immutables:n&&n.options.immutables})},update:function(t,n){var i,a,s,l,c,d,u=this.finder.findSuitable(n),h=t.closest(".k-toolbar").data("kendoToolBar");for(s=0,l=u.length;s<l;s++)if(c=u[s],this.options.immutables&&(d=r.Immutables.immutableParent(c))&&(c=d),(i=p(c))||(a=e(c).parents("ul,ol").length,i=o.is(c,"li")&&(a>1||p(c.parentNode))||o.ofType(c,["ul","ol"])&&a>0),i)return void h.enable(t,!0);h.enable(t,!1)}});i(r,{IndentFormatter:f,IndentCommand:m,OutdentCommand:g,OutdentTool:v}),a("indent",new l({command:m})),a("outdent",new v({command:g,ui:{enable:!1}}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.ui.editor,r=i.Dom,o=i.Command,a=i.Tool,s=i.BlockFormatter,l=r.normalize,c=i.RangeUtils,d=i.EditorUtils.registerTool,u=o.extend({init:function(e){this.options=e,o.fn.init.call(this,e)},_insertMarker:function(e,t){var n,i=r.create(e,"a");return i.className="k-marker",t.insertNode(i),i.parentNode||((n=t.commonAncestorContainer).innerHTML="",n.appendChild(i)),l(i.parentNode),i},_moveFocus:function(e,t){if(r.isEmpty(t))e.setStartBefore(t);else{e.selectNodeContents(t);var n=c.textNodes(e)[0];if(!n){for(;t.childNodes.length&&!r.is(t.firstChild,"br");)t=t.firstChild;n=t}if(r.isEmpty(n))e.setStartBefore(n);else{r.emptyNode(n)&&(n.innerHTML="\ufeff");var i=n.firstChild||n;r.isDataNode(i)?e.setStart(i,0):e.setStartBefore(i)}}},shouldTrim:function(e){var t="p,h1,h2,h3,h4,h5,h6".split(","),n=r.parentOfType(e.startContainer,t),i=r.parentOfType(e.endContainer,t);return n&&!i||!n&&i},_blankAfter:function(e){for(;e&&(r.isMarker(e)||""===r.stripBom(e.nodeValue));)e=e.nextSibling;return!e},exec:function(){const t=this.getRange(),n=c.documentFromRange(t);let o,a,d,u,h,p,f,m,g,v;const _=i.emptyElementContent;if(this.expandImmutablesIn(t),v=this.shouldTrim(t),t.deleteContents(),h=this._insertMarker(n,t),r.stripBomNode(h.previousSibling),r.stripBomNode(h.nextSibling),p=r.closestEditableOfType(h,["li"]),f=r.closestEditableOfType(h,"h1,h2,h3,h4,h5,h6".split(",")),m=r.is(h.parentNode,"table")&&h.parentNode,p){if(r.emptyNode(p)){u=r.create(n,"p"),r.next(p)&&(g=t.cloneRange(),g.selectNode(p),c.split(g,p.parentNode));const i=e("br",p);1==i.length&&i.remove();const o=p.parentNode,a=p.parentNode.children.length,s=a>=1&&1==p.childNodes.length&&p.children[0];r.insertAfter(u,o),r.remove(1==a?p.parentNode:p),s&&s!==h?(u.appendChild(s),u.appendChild(h)):u.innerHTML=_,d=u}}else f&&this._blankAfter(h)?(u=this._insertParagraphAfter(f),r.remove(h),d=u):m&&(u=this._insertParagraphAfter(m),r.remove(h),d=u);if(!d){p||f||new s([{tags:["p"]}]).apply([h]),t.selectNode(h);const e=f?r.name(f):"p";o=r.parentOfType(h,[p?"li":e]),c.split(t,o,v),a=o.previousSibling,r.is(a,"li")&&a.firstChild&&!r.is(a.firstChild,"br")&&(a=a.firstChild),d=o.nextSibling,this.clean(a,{links:!0}),this.clean(d,{links:!0}),r.is(d,"li")&&d.firstChild&&!r.is(d.firstChild,"br")&&(d=d.firstChild),r.remove(o),l(a)}l(d),this._moveFocus(t,d),t.collapse(!0),r.scrollTo(d,!0),c.selectRange(t)},_insertParagraphAfter:function(e){var t=this.getRange(),n=c.documentFromRange(t),o=i.emptyElementContent,a=r.create(n,"p");return r.insertAfter(a,e),a.innerHTML=o,a},clean:function(t,n){var o=t;if(t.firstChild&&r.is(t.firstChild,"br")&&r.remove(t.firstChild),r.isDataNode(t)&&!t.nodeValue&&(t=t.parentNode),t){for(var a=!1;t.firstChild&&1==t.firstChild.nodeType;)a=a||r.significantNodes(t.childNodes).length>1,t=t.firstChild;if(r.isEmpty(t)||"k-br"==t.className||!/^\s*$/.test(t.innerHTML)||a||(e(o).find(".k-br").remove(),t.innerHTML=i.emptyElementContent),n&&n.links)for(;t!=o;){if(r.is(t,"a")&&r.emptyNode(t)){r.unwrap(t);break}t=t.parentNode}}}}),h=o.extend({init:function(e){this.options=e,o.fn.init.call(this,e)},exec:function(){var n=this.getRange();this.expandImmutablesIn(n);var i,o,a=r.create(c.documentFromRange(n),"br"),s=n.startContainer,d=t.support.browser,u=d.msie&&d.version<11,h=r.is(s,"table")&&s;n.deleteContents(),h?r.insertAfter(a,h):(o=e(s).closest(".k-br"),n.insertNode(a),o.length&&r.unwrap(o[0])),l(a.parentNode),u||a.nextSibling&&!r.isWhitespace(a.nextSibling)||(a.nextSibling&&r.isWhitespace(a.nextSibling)&&e(a.nextSibling).remove(),(i=a.cloneNode(!0)).className="k-br",r.insertAfter(i,a)),n.setStartAfter(a),n.collapse(!0),r.scrollTo(a.nextSibling||a,!0),c.selectRange(n)}});n(i,{ParagraphCommand:u,NewLineCommand:h}),d("insertLineBreak",new a({key:13,shift:!0,command:h})),d("insertParagraph",new a({key:13,command:u}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.htmlEncode,r=t.ui.editor,o=r.EditorUtils,a=r.Dom,s=o.registerTool,l=r.RangeUtils,c=r.Command,d=r.LinkFormatter,u=l.textNodes,h=t.keys,p="#k-editor-file-url",f="#k-editor-file-text",m="#k-editor-file-title",g=c.extend({init:function(e){var t=this;c.fn.init.call(t,e),t.formatter=new d,t.async=!0,t.attributes={}},insertFile:function(e,t){var n=this.attributes,i=l.documentFromRange(t);if(n.href&&"http://"!=n.href){if(!e)return(e=a.create(i,"a",{href:n.href})).innerHTML=n.innerHTML,e.title=n.title,t.deleteContents(),t.insertNode(e),e.nextSibling||a.insertAfter(i.createTextNode("\ufeff"),e),t.setStartAfter(e),t.setEndAfter(e),l.selectRange(t),!0;a.attr(e,n)}return!1},redo:function(){var e=this.lockRange();this.formatter.apply(e,this.attributes),this.releaseRange(e)},exec:function(){var e,i,r=this,o=r.lockRange(),s=u(o),c=!1,d=s.length?this.formatter.finder.findSuitable(s[0]):null,g=t.support.browser.msie,v=r.editor.options,_=v.messages,b=v.fileBrowser,y=!!(t.ui.FileBrowser&&b&&b.transport&&undefined!==b.transport.read),w={title:_.insertFile,visible:!1,resizable:y};function k(t){var n=e.element,i=n.find(p).val().replace(/ /g,"%20"),a=n.find(f).val(),s=n.find(m).val();r.attributes={href:i,innerHTML:""!==a?a:i,title:s},c=r.insertFile(d,o),x(t),r.change&&r.change()}function x(t){t.preventDefault(),i.destroy(),e.destroy(),a.windowFromDocument(l.documentFromRange(o)).focus(),c||r.releaseRange(o)}this.expandImmutablesIn(o),w.close=x,y&&(w.width=750),w.minWidth=350,e=this.createDialog("<div/>",w).data("kendoWindow"),i=r._createForm(e,y),e.element.toggleClass("k-filebrowser-dialog",y),e.wrapper.find(".k-dialog-insert").on("click",k).end().find(".k-dialog-close").on("click",x).end().find(".k-form-field input").on("keydown",(function(e){e.keyCode==h.ENTER?k(e):e.keyCode==h.ESC&&x(e)})).end().find(p).val(d?d.getAttribute("href",2):"http://").end().find(f).val(d?d.innerText:"").end().find(m).val(d?d.title:"").end();var C=e.element;if(y&&(r._fileBrowser=new t.ui.FileBrowser(C.find(".k-filebrowser"),n({},b)),r._fileBrowser.bind("change",(function(e){"f"===e.selected.get("type")&&C.find(p).val(this.value())})),r._fileBrowser.bind("apply",k)),g){var S=C.closest(".k-window").height();C.css("max-height",S)}e.center().open(),C.find(p).trigger("focus").select()},_createForm:function(t,n){var r=e("<div/>").appendTo(t.element),o=this.editor.options.messages,a=r.kendoForm({renderButtons:!1,items:[{field:"k-editor-file-url",label:i(o.fileWebAddress),editor:"TextBox"},{field:"k-editor-file-text",label:i(o.fileText),editor:"TextBox"},{field:"k-editor-file-title",label:i(o.fileTitle),editor:"TextBox"}]}).data("kendoForm");return n&&r.prepend(e('<div class="k-filebrowser"></div>')),t.element.after(e(this._actionButtonsTemplate({messages:o,insertButtonIcon:"file-add",cancelButtonIcon:"cancel-outline"}))),a}});t.ui.editor.FileCommand=g,s("insertFile",new r.Tool({command:g}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.ui.editor,r=i.Dom,o=i.RangeUtils,a=i.Command,s="kendoEditor",l="k-active",c="k-selected",d="scope",u="row",h="col",p="rowgroup",f="colgroup",m="colspan",g="rowspan",v="table",_="thead",b="tbody",y="tr",w="td",k="th",x=i.Tool,C=i.InsertHtmlCommand,S=i.BlockFormatFinder,T=i.BlockFormatTool,D=i.FormatCommand,A=i.EditorUtils.registerTool,M=i.EditorUtils.registerFormat,E=t.ui.Editor.fn.options.formats,I=t.getTouches,z=t.template,P=({width:e,content:t})=>`<td style="width:${e}%;">${t}</td>`,H=new S([{tags:[v]}]),F=C.extend({init:function(t){var n=e.extend({postProcess:this.postProcess,skipCleaners:!0},t||{});C.fn.init.call(this,n)},_tableHtml:function(e,t){e=e||1,t=t||1;var n=z(P)({width:100/t,content:i.emptyTableCellContent}),r=100/e;return"<table class='k-table' data-last>"+new Array(e+1).join("<tr style='height:"+r+"%;'>"+new Array(t+1).join(n)+"</tr>")+"</table>"},postProcess:function(t,n){var i=e("table[data-last]",t.document).removeAttr("data-last");n.setStart(i.find(w)[0],0),n.collapse(!0),t.selectRange(n)},exec:function(){var e=this.options;e.html=this._tableHtml(e.rows,e.columns),C.fn.exec.call(this)}}),R=x.extend({initialize:function(t,n){var r=this,o=e("<button>"+n.options.messages.tableWizard+"</button>"),a=e(this.options.popupTemplate).appendTo("body").kendoPopup({anchor:t,copyAnchorStyles:!1,open:this._open.bind(this),activate:this._activate.bind(this),close:this._close.bind(this)}).data("kendoPopup");t.on("click",this._toggle.bind(this)).on("keydown",this._keydown.bind(this)),this._editor=n,this._popup=a,n.tablePopup=this._popup;var s=new i.TableWizardTool({command:i.TableWizardCommand,insertNewTable:!0});A("tableWizardInsert",s),o.appendTo(a.element),o.kendoButton({icon:"table-wizard"}),o.on("click",(()=>{r._editor.exec("tableWizardInsert")}))},popup:function(){return this._popup},_activate:e.noop,_open:function(){this._popup.options.anchor.addClass(l)},_close:function(){this._popup.options.anchor.removeClass(l)},_keydown:function(e){var n=this,i=t.keys,r=e.keyCode;r==i.ESC?n._popup.close():r==i.DOWN&&e.altKey?(n._popup.open(),n._setTableSize({row:1,col:1})):r===i.ENTER&&setTimeout((()=>{n._setTableSize({row:1,col:1})}))},_toggle:function(t){e(t.target).closest(".k-tool").hasClass("k-disabled")||this.popup().toggle()},update:function(e){var t=this.popup();t.wrapper&&"block"==t.wrapper.css("display")&&t.close(),e.removeClass("k-hover")},destroy:function(){this._popup&&this._popup.destroy()}}),L=R.extend({init:function(t){this.cols=8,this.rows=6,R.fn.init.call(this,e.extend(t,{command:F,popupTemplate:"<div class='k-ct-popup'><div>"+new Array(this.cols*this.rows+1).join("<span class='k-ct-cell k-disabled'></span>")+"</div><div class='k-status'></div></div>"}))},_activate:function(){var n,i,r=this,o=r._popup.element,a=o.find(".k-ct-cell"),l=a.eq(0),c=a.eq(a.length-1),d=t.getOffset(l),u=t.getOffset(c),h=r.cols,p=r.rows;function f(t){var r=e(window);return{row:Math.floor((t.clientY+r.scrollTop()-d.top)/i)+1,col:Math.floor((t.clientX+r.scrollLeft()-d.left)/n)+1}}o.find("*").addBack().attr("unselectable","on"),u.left+=c[0].offsetWidth,u.top+=c[0].offsetHeight,n=(u.left-d.left)/h,i=(u.top-d.top)/p,o.autoApplyNS(s).on("mousemove",".k-ct-cell",(function(e){r._setTableSize(f(e))})).on("mouseleave",".k-ct-cell",(function(){r._setTableSize()})).on("down",".k-ct-cell",(function(e){e.preventDefault();var t=I(e)[0];r._exec(f(t.location))}))},_valid:function(e){return e&&e.row>0&&e.col>0&&e.row<=this.rows&&e.col<=this.cols},_exec:function(e){this._valid(e)&&(this._editor.exec("createTable",{rows:e.row,columns:e.col}),this._popup.close())},_setTableSize:function(n){var i=this._popup.element,r=i.find(".k-status"),o=i.find(".k-ct-cell"),a=this.cols,s=this._editor.options.messages;this._valid(n)?(r.text(t.format(s.createTableHint,n.row,n.col)),o.each((function(t){e(this).toggleClass(c,t%a<n.col&&t/a<n.row)}))):(r.text(s.createTable),o.removeClass(c))},_keydown:function(e){var n=this._popup.visible();if(R.fn._keydown.call(this,e),this._popup.visible()){var i,r=t.keys,o=e.keyCode,a=this._popup.element.find(".k-ct-cell"),s=Math.max(a.filter(".k-selected").last().index(),0),l=Math.floor(s/this.cols),c=s%this.cols,d=!1;o!=r.DOWN||e.altKey?o==r.UP?(d=!0,l--):o==r.RIGHT?(d=!0,c++):o==r.LEFT?(d=!0,c--):o==r.TAB&&(i=this._popup.element.find(".k-button")).length>0&&(d=!0,i.trigger("focus")):(d=!0,l++);var u={row:Math.max(1,Math.min(this.rows,l+1)),col:Math.max(1,Math.min(this.cols,c+1))};o==r.ENTER&&n?this._exec(u):this._setTableSize(u),d&&(e.preventDefault(),e.stopImmediatePropagation())}},_open:function(){var e=this._editor.options.messages;R.fn._open.call(this),this.popup().element.find(".k-status").text(e.createTable).end().find(".k-ct-cell").removeClass(c)},_close:function(){R.fn._close.call(this),this.popup().element.off("."+s)}}),B=a.extend({undo:function(){var t=this.restorePoint;t.restoreHtml(),e(this.editor.body).find(".k-element-resize-handle-wrapper").each((function(e,t){t.remove()})),this.editor.selectRange(t.toRange())},_clearColIndexAttr:function(e){r.clearTableMappings(e,"col-index")},_mapColIndices:function(e){r.reMapTableColumns(e,"col-index")},_findRowSpanCell:function(t,n,i){for(var r,o,a=n;a>=0;a--)if(r=t.rows[a],(o=e(r).find("[col-index="+i+"]")).length)return o},_resetElementResizing:function(e){e._destroyResizings(),e._initializeColumnResizing(),e._initializeRowResizing(),e._initializeElementResizing()},_findNextTdInRow:function(e,t){for(var n,i=e.find("td:last-child"),r=parseInt(i.attr("col-index"),10)+i.prop("colSpan")-1,o=t;o<=r;o++)if((n=e.find("[col-index="+o+"]")).length)return n},_adjustColgroups:function(e,t){for(var n,i,o,a=t.getElementsByTagName(h),s=t.getElementsByTagName(f),l=e.cells,c=l.length;a.length>0;)a[0].remove();for(;s.length>0;)s[0].remove();for(n=c-1;n>=0;n--)(o=l[n]).getAttribute(d)===f?((i=r.createEmptyNode(this.editor.document,f)).setAttribute("span",o.getAttribute(m)),t.prepend(i)):t.prepend(r.createEmptyNode(this.editor.document,h))},_associateHeaderIds:function(t){r.clearTableMappings(t,"col-index"),r.reMapTableColumns(t,"col-index"),e(t).find("th, td").removeAttr("id headers"),r.associateWithIds(t)},_getNumberOfColumns:function(e){return r._getNumberOfColumns(e,"td, th")}}),O=B.extend({exec:function(){var t,n,o,a,s,l,c=this.lockRange(!0),h=r.closest(c.endContainer,[w,k]),f=r.closest(h,v),m=this.options.position||"after";if(!f||this.immutables()&&i.Immutables.immutableParent(h))this.releaseRange(c);else{this._mapColIndices(f),n=h.parentNode,s=r.findNodeIndex(n,!0),h.rowSpan>1&&"after"===m&&(n=f.rows[s+h.rowSpan-1]),t=this._getNumberOfColumns(f),a=n.cloneNode(!0),e(a).empty();for(var _=0;_<t;_+=o.prop("colSpan"))(o=e(n).find("[col-index="+_+"]")).length?o.prop("rowSpan")>1&&"after"===m&&o?o.attr(g,o.prop("rowSpan")+1):this._appendCell(a,o):(s=r.findNodeIndex(n,!0),(o=this._findRowSpanCell(n.parentElement,s,_)).closest(y).index()+o.prop("rowSpan")-1===s&&"after"===m?this._appendCell(a,o):o.attr(g,o.prop("rowSpan")+1)),(l=e(a).find("[col-index="+_+"]")).attr(d)!==p||l.attr(g)||l.attr(d,u);"before"==m?r.insertBefore(a,n):r.insertAfter(a,n),e(f).find("[headers]").length>0&&this._associateHeaderIds(f),this._clearColIndexAttr(f),this.releaseRange(c),this._resetElementResizing(this.editor)}},_appendCell:function(e,t){var n;(n=t.clone()).html(i.emptyTableCellContent),n.removeAttr(g),n.appendTo(e)}}),V=B.extend({exec:function(){var t,n,o,a,s=this.lockRange(!0),l=r.closest(s.endContainer,[w,k]),c=r.closest(l,v),u=c.getElementsByTagName(h),p=c.getElementsByTagName(f),g=c&&c.rows,_=this.options.position||"after";if(!l||this.immutables()&&i.Immutables.immutableParent(l))this.releaseRange(s);else{for(this._mapColIndices(c),t=parseInt(l.getAttribute("col-index"),10),l.colSpan>1&&"after"===_&&(l.setAttribute("col-index",t+l.colSpan-1),t=t+l.colSpan-1),n=0;n<g.length;n++)(o=this._processForColSpan(g[n],t,_,l))&&((a=o.cloneNode()).innerHTML=i.emptyTableCellContent,a.removeAttribute(m),a.getAttribute(d)&&a.getAttribute(d)===f&&a.setAttribute(d,h),"before"==_?r.insertBefore(a,o):r.insertAfter(a,o),this._resizeCells(a,o));(u.length>0||p.length>0)&&this._adjustColgroups(g[0],c),e(c).find("[headers]").length>0&&this._associateHeaderIds(c),this._clearColIndexAttr(c),this.releaseRange(s),this._resetElementResizing(this.editor)}},_processForColSpan:function(t,n,i,r){var o,a,s=n-1;if((o=e(t).find("[col-index="+n+"]")[0])&&o.colSpan>1&&"after"===i&&o!==r)o.colSpan+=1;else{if(o)return o;for(;s>=0&&!((o=e(t).find("[col-index="+s+"]")[0])&&o.colSpan>1);s--);if(o){if((a=parseInt(o.getAttribute("col-index"),10)+o.colSpan-1)===n&&"after"===i)return o;n<=a&&o.setAttribute(m,o.colSpan+1)}}},_resizeCells:function(e,t){var n,i,r,o=e.style.width;o&&(n=parseFloat(o),i=o.slice(n.toString().length),r=n/2+i,e.style.width=r,t.style.width=r)}}),N=B.extend({exec:function(){var t,n=this.lockRange(),a=o.mapAll(n,(function(t){return e(t).closest(y)[0]})),s=r.closest(n.endContainer,[w,k]),l=a[0],c=s?s.rowSpan:1,d=e(a[0]).index(),u=r.closest(l,v),h=l.parentElement;if(!u||this.immutables()&&i.Immutables.immutableParent(l))this.releaseRange(n);else{for(var p=0;p<c;p++)a.indexOf(h.rows[d+p])<0&&a.push(h.rows[d+p]);if(u.rows.length<=a.length)(t=r.next(u))&&!r.insignificant(t)||(t=r.prev(u)),t&&t.rows&&(t=t.rows[0].cells[0]),r.remove(u),this._resetElementResizing(this.editor);else if(h.rows.length<=a.length)(t=h.nextSibling)||(t=h.previousSibling),r.remove(h);else{this._mapColIndices(u);for(var f=0;f<a.length;f++)l=a[f],r.removeTextSiblings(l),t=(t=r.next(l)||r.prev(l)).cells[0],this._focusElement(n,t),t=null,this._handleRowSpanCells(u,l),r.remove(l);this._clearColIndexAttr(u)}e(u).find("[headers]").length>0?this._associateHeaderIds(u):r.is(h,_)&&e(u).find("[scope]").length>0&&this._adjustColgroups(h.rows[0],u),t&&this._focusElement(n,t),this._resetElementResizing(this.editor)}},_focusElement:function(e,t){e.setStart(t,0),e.collapse(!0),this.editor.selectRange(e)},_handleRowSpanCells:function(t,n){var i,o,a,s,l=r.findNodeIndex(n,!0),c=t.rows[0],d=c.cells[c.cells.length-1],u=parseInt(d.getAttribute("col-index"),10)+d.colSpan-1;for(i=0;i<=u;i+=o.prop("colSpan"))(o=e(n).find("[col-index="+i+"]")).length&&o.prop("rowSpan")>1&&(s=t.rows[l+1],(a=e(s).find("[col-index="+(i+1)+"]")).length?a.before(o):e(s).append(o),this._reduceRowSpan(o)),o.length||(o=this._findRowSpanCell(n.parentElement,l,i),this._reduceRowSpan(o))},_reduceRowSpan:function(e){var t=e.prop("rowSpan")-1;t<=1?(e.removeAttr(g),e.attr(d)===p&&e.attr(d,u)):e.attr(g,t)}}),$=B.extend({exec:function(){var t,n,o,a,s,l=this.lockRange(),c=r.closest(l.endContainer,[w,k]),d=r.closest(c,v),u=d&&d.rows,p=u&&u[0].cells.length,m=d.getElementsByTagName(h),g=d.getElementsByTagName(f);if(!c||this.immutables()&&i.Immutables.immutableParent(c))this.releaseRange(l);else{if(1==p||c.colSpan==p)(t=r.next(d))&&!r.insignificant(t)||(t=r.prev(d)),t&&t.rows&&(t=t.rows[0].cells[0]),r.remove(d),this._resetElementResizing(this.editor);else{for(r.removeTextSiblings(c),t=r.next(c)||r.prev(c),this._mapColIndices(d),n=parseInt(c.getAttribute("col-index"),10),s=0;s<c.colSpan;s++)for(o=0;o<u.length;o+=a.prop("rowSpan")||1)(a=e(u[o]).find("[col-index="+(n+s)+"]")).length&&a.prop("colSpan")<=1?a.remove():this._handleColSpanCells(u[o],n+s);this._clearColIndexAttr(d)}(m.length>0||g.length>0)&&this._adjustColgroups(u[0],d),e(d).find("[headers]").length>0&&this._associateHeaderIds(d),t&&(l.setStart(t,0),l.collapse(!0),this.editor.selectRange(l)),this._resetElementResizing(this.editor)}},_handleColSpanCells:function(t,n){var i=e(t).find("[col-index="+n+"]");if(i.length&&i.prop("colSpan")>1){var r=i.clone(!0);return i.after(r),this._reduceColSpan(r),r.attr("col-index",parseInt(i.attr("col-index"),10)+1),void i.remove()}for(var o=n;o>=0;o--)if((i=e(t).find("[col-index="+o+"]")).length)return this._reduceColSpan(i),void i.attr("col-index",parseInt(i.attr("col-index"),10)+1)},_reduceColSpan:function(e){var t=e.prop("colSpan")-1;t<=1?(e.removeAttr(m),e.attr(d)===f&&e.attr(d,h)):e.attr(m,t)}}),U=B.extend({exec:function(){var t,n,o,a,s,l=this.lockRange(),c=r.closest(l.endContainer,[w,k]);if(c)if(t=r.closest(c,v),n=c.parentNode,o=r.findNodeIndex(c,!0),n.children[o+1],this.immutables()&&i.Immutables.immutableParent(c))this.releaseRange(l);else{if(this._mapColIndices(t),o=parseInt(e(c).attr("col-index"),10),!(a=e(n).find("[col-index="+(o+1+this._getColspan(c)-1)+"]").get(0))||a.rowSpan!==c.rowSpan||c.tagName!==a.tagName)return this._clearColIndexAttr(t),void this.releaseRange(l);s=this._getColspan(c)+this._getColspan(a),e(c).prop(m,s).append(r.emptyNode(a)?"":"<br/>"+a.innerHTML),e(c).width(c.offsetWidth),e(a).remove(),c.getAttribute(d)===h&&c.setAttribute(d,f),c.getAttribute(d)===f&&this._adjustColgroups(n,t),e(t).find("[headers]").length>0&&this._associateHeaderIds(t),this._clearColIndexAttr(t),this.releaseRange(l),this._resetElementResizing(this.editor)}else this.releaseRange(l)},_getColspan:function(e){return parseInt(e.getAttribute(m),10)||1}}),W=B.extend({exec:function(){var t,n,o,a,s,l,c,h=this.lockRange(),f=r.closest(h.endContainer,[w,k]);if(f)if(t=r.closest(f,y),n=r.closest(f,[_,b]),o=r.closest(f,v),a=r.findNodeIndex(f,!0),(s=r.findNodeIndex(t,!0))+1!==n.rows.length)if((l=n.rows[s+this._getRowspan(f)])&&l.children[a],this.immutables()&&i.Immutables.immutableParent(f))this.releaseRange(h);else{if(this._mapColIndices(o),a=e(f).attr("col-index"),!(c=e(l).find("[col-index="+a+"]").get(0))||c.colSpan!==f.colSpan||f.tagName!==c.tagName)return this._clearColIndexAttr(o),void this.releaseRange(h);e(f).prop(g,this._getRowspan(f)+this._getRowspan(c)).append(r.emptyNode(c)?"":"<br/>"+c.innerHTML),f.getAttribute(d)===u&&f.setAttribute(d,p),e(c).remove(),e(o).find("[headers]").length>0&&this._associateHeaderIds(o),this._clearColIndexAttr(o),this.releaseRange(h)}else this.releaseRange(h);else this.releaseRange(h)},_getRowspan:function(e){return parseInt(e.getAttribute(g),10)||1}}),j=B.extend({exec:function(){var t=this.lockRange(),n=this.options.type,o="row"===n?m:g,a=r.closest(t.endContainer,[w,k]),s=r.closest(a,[_,b]),l=r.closest(a,v),c=r.createEmptyNode(this.editor.document,a.nodeName.toLowerCase());!a||this.immutables()&&i.Immutables.immutableParent(a)||(this._mapColIndices(l),"row"===n&&e(a).is("["+o+"]")?this._splitCellHorizontally(a,s,o,c):"column"===n&&e(a).is("["+o+"]")&&this._splitCellVertically(a,s,o,c),e(a).prop(o.toLowerCase())<=1&&e(a).removeAttr(o),e(l).find("[headers]").length>0&&this._associateHeaderIds(l),this._clearColIndexAttr(l)),this.releaseRange(t)},_getRowspanValue:function(e){return parseInt(e.getAttribute(g),10)},_getColspanValue:function(e){return parseInt(e.getAttribute(m),10)},_splitCellHorizontally:function(t,n,i,r){var o=t.rowSpan,a=t.colSpan,s=e(r),l=Math.floor(a/2);l>1&&s.attr(m,l),o>1&&s.attr(g,o),e(t).prop(i,a-l).after(s),e(t).width(t.offsetWidth),s.width(s[0].offsetWidth),t.hasAttribute(d)&&(t.getAttribute(d)===f?(s.attr(d,h),t.getAttribute(m)&&"1"!==t.getAttribute(m)||t.setAttribute(d,h),this._adjustColgroups(t.parentNode,n.parentNode)):s.attr(d,t.getAttribute(d)))},_splitCellVertically:function(t,n,i,o){var a=r.closest(t,y),s=parseInt(e(t).attr("col-index"),10),l=r.findNodeIndex(a,!0),c=t.rowSpan,h=t.colSpan,f=Math.floor(c/2),v=e(n).find(y).eq(l+c-f),_=this._findNextTdInRow(v,s+h),b=e(o);f>1&&b.attr(g,f),h>1&&b.attr(m,h),_&&_.length?_.before(b):v.append(b),e(t).prop(i,c-f),t.hasAttribute(d)&&(t.getAttribute(d)===p?(b.attr(d,u),t.getAttribute(g)&&"1"!==t.getAttribute(g)||t.setAttribute(d,u)):b.attr(d,t.getAttribute(d)))}}),q=x.extend({command:function(e){var t={row:{insert:O,delete:N,merge:U,split:j},column:{insert:V,delete:$,merge:W,split:j}};return(e=n(e,this.options)).action=e.action||"insert",new t[e.type][e.action](e)},update:function(e,t){var n=!H.isFormatted(t),i=e.closest(".k-toolbar").getKendoToolBar();!0===n?i.hide(e):i.show(e)}}),G=D.extend({exec:function(){var e=this.editor;D.fn.exec.call(this),e.elementResizing&&e.elementResizing._showResizeHandles()}}),K=T.extend({update:function(e,t){var n=!H.isFormatted(t),i=this.options.finder.isFormatted(t,this.isTable),r=e.closest(".k-toolbar").getKendoToolBar();r&&r.toggle(e,i),!0===n?r.hide(e):r.show(e)},command:function(e){return new G(n(e,{formatter:this.options.formatter}))},isTable:function(e){return r.is(e,"table")}});n(t.ui.editor,{PopupTool:R,TableCommand:F,InsertTableTool:L,TableFormatTool:K,TableFormatCommand:G,TableModificationTool:q,InsertRowCommand:O,InsertColumnCommand:V,DeleteRowCommand:N,DeleteColumnCommand:$,MergeCellsHorizontallyCommand:U,MergeCellsVerticallyCommand:W,SplitCellCommand:j}),A("createTable",new L({ui:{popup:!0,overflow:"never"}})),A("addColumnLeft",new q({type:"column",position:"before"})),A("addColumnRight",new q({type:"column"})),A("addRowAbove",new q({type:"row",position:"before"})),A("addRowBelow",new q({type:"row"})),A("deleteRow",new q({type:"row",action:"delete"})),A("deleteColumn",new q({type:"column",action:"delete"})),A("mergeCellsHorizontally",new q({type:"row",action:"merge"})),A("mergeCellsVertically",new q({type:"column",action:"merge"})),A("splitCellHorizontally",new q({type:"row",action:"split"})),A("splitCellVertically",new q({type:"column",action:"split"})),M("tableAlignLeft",[{tags:["table"],attr:{style:{marginLeft:"",marginRight:"auto"}}},{tags:["table"],attr:{align:"left"}}]),A("tableAlignLeft",new K({format:E.tableAlignLeft,ui:{togglable:!0,group:"tableAlign"}})),M("tableAlignCenter",[{tags:["table"],attr:{style:{marginLeft:"auto",marginRight:"auto"}}},{tags:["table"],attr:{align:"center"}}]),A("tableAlignCenter",new K({format:E.tableAlignCenter,ui:{togglable:!0,group:"tableAlign"}})),M("tableAlignRight",[{tags:["table"],attr:{style:{marginLeft:"auto",marginRight:""}}},{tags:["table"],attr:{align:"right"}}]),A("tableAlignRight",new K({format:E.tableAlignRight,ui:{togglable:!0,group:"tableAlign"}}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Class,i=t.ui.editor,r=i.RangeUtils,o=i.Dom,a=i.RestorePoint,s=i.Marker,l=t.support.browser,c=e.extend,d=n.extend({init:function(e){this.editor=e;var t=e.options.pasteCleanup;this.nonSplittableTagsOnPaste=e.options.nonSplittableTagsOnPaste||[],this.cleaners=[new h(t),new p(t),new f(t),new m(t),new v(t),new _(t),new k(t),new x(t)]},htmlToFragment:function(e){var t=this.editor.document,n=o.create(t,"div"),i=t.createDocumentFragment();for(n.innerHTML=e;n.firstChild;)i.appendChild(n.firstChild);return i},isBlock:function(e){return/<(div|p|ul|ol|table|h[1-6])/i.test(e)},_startModification:function(){var e,t,n=this.editor;if(!this._inProgress)return this._inProgress=!0,e=n.getRange(),t=new a(e,n.body),o.persistScrollTop(n.document),{range:e,restorePoint:t}},_endModification:function(e){i._finishUpdate(this.editor,e.restorePoint),this.editor._selectionChange(),this._inProgress=!1},_contentModification:function(e,t){var n=this,i=n.editor,r=n._startModification();r&&(e.call(n,i,r.range),setTimeout((function(){t.call(n,i,r.range),n._endModification(r)})))},_removeBomNodes:function(e){for(var t=r.textNodes(e),n=0;n<t.length;n++)t[n].nodeValue=o.stripBom(t[n].nodeValue)||t[n].nodeValue},_onBeforeCopy:function(e){var t=new s;t.add(e),this._removeBomNodes(e),t.remove(e),this.editor.selectRange(e)},oncopy:function(){this._onBeforeCopy(this.editor.getRange())},oncut:function(){this._onBeforeCopy(this.editor.getRange()),this._contentModification(e.noop,e.noop)},_fileToDataURL:function(t){var n=e.Deferred(),i=new FileReader;return t instanceof window.File||!t.getAsFile||(t=t.getAsFile()),i.onload=n.resolve.bind(n),i.readAsDataURL(t),n.promise()},_triggerPaste:function(e,t){var n={html:e||""};n.html=n.html.replace(/\ufeff/g,""),this.editor.trigger("paste",n),this.paste(n.html,t||{})},_handleImagePaste:function(e){if("FileReader"in window&&!(l.msie&&l.version>10)){var t=e.clipboardData||e.originalEvent.clipboardData||window.clipboardData||{},n=t.items||t.files;return this._insertImages(n)}},_insertImages:function(t){if(t){var n=e.grep(t,(function(e){return/^image\//i.test(e.type)}));if(!e.grep(t,(function(e){return/^text\/html/i.test(e.type)})).length&&n.length){var i=this._startModification();if(i)return e.when.apply(e,e.map(n,this._fileToDataURL)).done(function(){var t=Array.prototype.slice.call(arguments),n=e.map(t,(function(e){return'<img src="'+e.target.result+'" />'})).join("");this._triggerPaste(n),this._endModification(i)}.bind(this)),!0}}},onpaste:function(n){"false"!==this.editor.body.contentEditable&&(this._handleImagePaste(n)?n.preventDefault():(this.expandImmutablesIn(),this._contentModification((function(i,r){var a=o.create(i.document,"div",{className:"k-paste-container",innerHTML:"\ufeff"}),s=t.support.browser,l=i.body;if(this._decoreateClipboardNode(a,l),l.appendChild(a),s.webkit&&this._moveToCaretPosition(a,r),s.msie&&s.version<11){n.preventDefault();var c=i.createRange();c.selectNodeContents(a),i.selectRange(c);var d=i.document.body.createTextRange();d.moveToElementText(a),e(l).off("paste"),d.execCommand("Paste"),e(l).on("paste",this.onpaste.bind(this))}else{var u=i.createRange();u.selectNodeContents(a),i.selectRange(u)}r.deleteContents()}),(function(t,n){var i,r="";t.selectRange(n),(i=e(t.body).children(".k-paste-container")).each((function(){var e=this.lastChild;e&&o.is(e,"br")&&o.remove(e),r+=this.innerHTML})),i.remove(),this._triggerPaste(r,{clean:!0})}))))},ondragover:function(e){(l.msie||l.edge)&&(e.stopPropagation(),e.preventDefault())},ondrop:function(e){if("FileReader"in window){var t=(e.originalEvent||e).dataTransfer||{},n=t.items||t.files;this._insertImages(n)&&e.preventDefault()}},_decoreateClipboardNode:function(t,n){if((l.msie||l.webkit)&&((t=e(t)).css({borderWidth:"0px",width:"0px",height:"0px",overflow:"hidden",margin:"0",padding:"0"}),l.msie)){var i=e(n.ownerDocument.documentElement);t.css({fontVariant:"normal",fontWeight:"normal",lineSpacing:"normal",lineHeight:"normal",textDecoration:"none"});var r=i.css("color");r&&t.css("color",r);var o=i.css("fontFamily");o&&t.css("fontFamily",o);var a=i.css("fontSize");a&&t.css("fontSize",a)}},_moveToCaretPosition:function(t,n){var i=this.editor.body,r=o.offset(t,i),a=this._caretOffset(n,i),s="translate("+(a.left-r.left)+"px,"+(a.top-r.top)+"px)";e(t).css({"-webkit-transform":s,transform:s})},_caretOffset:function(e,t){var n,i=this.editor,r=o.create(i.document,"span",{innerHTML:"\ufeff"}),a=e.startContainer;if(e.collapsed){var s=o.isDataNode(a);s&&(o.isBom(a)||0===e.startOffset)?o.insertBefore(r,a):s&&e.startOffset===a.length?o.insertAfter(r,a):(e.insertNode(r),n=!0)}else a=a===t?a.childNodes[e.startOffset]:a,o.insertBefore(r,a);var l=o.offset(r,t),c=r.previousSibling,d=r.nextSibling;if(o.remove(r),n&&o.isDataNode(c)&&o.isDataNode(d)&&!o.isBom(c)&&!o.isBom(d)){var u=c.length;d.data=c.data+d.data,e.setStart(d,u),o.remove(c),e.collapse(!0),i.selectRange(e)}return l},expandImmutablesIn:function(e){var n=this.editor;if(n&&n.options.immutables){var i=n.body;if(e=e||n.getRange(),t.ui.editor.Immutables.expandImmutablesIn(e),e.startContainer===i&&0===e.startOffset){var r=i.ownerDocument.createTextNode("\ufeff");i.insertBefore(r,i.childNodes[0]),e.setStartBefore(r)}n.selectRange(e)}},splittableParent:function(e,t){var n,i;if(e)return o.closestEditableOfType(t,["p","ul","ol"])||t.parentNode;if(n=t.parentNode,i=t.ownerDocument.body,o.isInline(n))for(;n.parentNode!=i&&!o.isBlock(n.parentNode);)n=n.parentNode;return n},paste:function(t,n){var i,a,l,d,u=this.editor,h=this.nonSplittableTagsOnPaste,p=!1,f=!1;if(this.expandImmutablesIn(),!(n=c({clean:!1,split:!0},n)).skipCleaners)for(i=0,a=this.cleaners.length;i<a;i++)this.cleaners[i].applicable(t)&&(t=this.cleaners[i].clean(t));n.clean&&(t=(t=t.replace(/(<br>(\s|&nbsp;)*)+(<\/?(div|p|li|col|t))/gi,"$3")).replace(/<(a|span)[^>]*><\/\1>/gi,"")),t=(t=t.replace(/<(a|span|font)([^>]*)> <\/\1>/gi,"<$1$2>&nbsp;</$1>")).replace(/^<li/i,"<ul><li").replace(/li>$/g,"li></ul>");var m=this.isBlock(t);u.focus();var g=u.getRange();g.deleteContents(),g.startContainer==u.document&&g.selectNodeContents(u.body);var v=new s,_=v.addCaret(g),b=this.splittableParent(m,_),y=!1;for(i=0;i<h.length;i++){const e=h[i],t=e.tag||e;if(o.is(b,t)){p=!0,f=!1!==e.unwrap;break}}var w=b!=u.body&&!o.is(b,"td")&&!p;n.split&&w&&(m||o.isInline(b))&&(g.selectNode(_),r.split(g,b,!0),y=!0);var k=this.htmlToFragment(t);if(k.firstChild&&"k-paste-container"===k.firstChild.className){var x=[];for(i=0,a=k.childNodes.length;i<a;i++)x.push(k.childNodes[i].innerHTML);k=this.htmlToFragment(x.join("<br />"))}if(l=k.childNodes,f&&(d=o.list(l[0]),o.unwrap(l[0]),d&&g.selectNode(_.parentNode)),e(l).filter("table").addClass("k-table").end().find("table").addClass("k-table"),e(l).each((function(e,t){o.isBlock(t)&&!o.isSelfClosing(t)&&""===t.innerHTML&&t.appendChild(u.document.createTextNode("\ufeff"))})),g.insertNode(k),b=this.splittableParent(m,_),y){for(;_.parentNode!=b;)o.unwrap(_.parentNode);o.unwrap(_.parentNode)}o.normalize(g.commonAncestorContainer),_.style.display="inline",o.restoreScrollTop(u.document),o.scrollTo(_),v.removeCaret(g);var C=g.commonAncestorContainer.parentNode;(g.collapsed&&"tbody"==o.name(C)||g.collapsed&&"thead"==o.name(C))&&(g.setStartAfter(e(C).closest("table")[0]),g.collapse(!0));var S=e(g.commonAncestorContainer.parentNode).closest("table");if(S.get(0)){for(var T=S.parent().contents(),D=T.length-1,A=T.get(D);null!==A.nodeValue&&(" "===A.nodeValue||""===A.nodeValue);)D-=1,A=T.get(D);A!==S.get(0)||S.parents("table").length||o.insertAfter(o.createEmptyNode(u.document,"p"),S[0])}u._handleSpaceAndNewLines(),u.selectRange(g)}}),u=n.extend({init:function(e){this.options=e||{},this.replacements=[]},clean:function(e,t){var n,i,r=t||this.replacements;for(n=0,i=r.length;n<i;n+=2)e=e.replace(r[n],r[n+1]);return e}}),h=u.extend({init:function(e){u.fn.init.call(this,e),this.replacements=[/<(\/?)script([^>]*)>/i,"<$1telerik:script$2>"]},applicable:function(e){return!this.options.none&&/<script[^>]*>/i.test(e)}}),p=u.extend({init:function(e){u.fn.init.call(this,e);this.replacements=[/<span\s+class="Apple-tab-span"[^>]*>\s*<\/span>/gi," ",/\t/gi," ",/&nbsp;&nbsp; &nbsp;/gi," "]},applicable:function(e){return/&nbsp;&nbsp; &nbsp;|class="?Apple-tab-span/i.test(e)}}),f=u.extend({init:function(e){u.fn.init.call(this,e),this.junkReplacements=[/<\?xml[^>]*>/gi,"",/<!--(.|\n)*?-->/g,"",/&quot;/g,"'",/<o:p>&nbsp;<\/o:p>/gi,"&nbsp;",/<\/?(meta|link|style|o:|v:|x:)[^>]*>((?:.|\n)*?<\/(meta|link|style|o:|v:|x:)[^>]*>)?/gi,"",/<\/o>/g,""],this.replacements=this.junkReplacements.concat([/(?:<br>&nbsp;[\s\r\n]+|<br>)*(<\/?(h[1-6]|hr|p|div|table|tbody|thead|tfoot|th|tr|td|li|ol|ul|caption|address|pre|form|blockquote|dl|dt|dd|dir|fieldset)[^>]*>)(?:<br>&nbsp;[\s\r\n]+|<br>)*/g,"$1",/<br><br>/g,"<BR><BR>",/<br>\n/g,"<br/>",/<br>(?!\n)/g," ",/<table([^>]*)>(\s|&nbsp;)+<t/gi,"<table$1><t",/<tr[^>]*>(\s|&nbsp;)*<\/tr>/gi,"",/<tbody[^>]*>(\s|&nbsp;)*<\/tbody>/gi,"",/<table[^>]*>(\s|&nbsp;)*<\/table>/gi,"",/<BR><BR>/g,"<br>",/^\s*(&nbsp;)+/gi,"",/(&nbsp;|<br[^>]*>)+\s*$/gi,"",/mso-[^;"]*;?/gi,"",/<(\/?)b(\s[^>]*)?>/gi,"<$1strong$2>",/<(\/?)font(\s[^>]*)?>/gi,this.convertFontMatch,/<(\/?)i(\s[^>]*)?>/gi,"<$1em$2>",/style=(["|'])\s*\1/g,"",/(<br[^>]*>)?\n/g,function(e,t){return t?e:" "}])},convertFontMatch:function(e,t,n){var i=/face=['"]([^'"]+)['"]/i.exec(n),r=n&&i&&i[1];return t?"</span>":r?'<span style="font-family:'+r+'">':"<span>"},applicable:function(e){return/class="?Mso/i.test(e)||/style="[^"]*mso-/i.test(e)||/urn:schemas-microsoft-com:office/.test(e)},stripEmptyAnchors:function(e){return e.replace(/<a([^>]*)>\s*<\/a>/gi,(function(e,t){return!t||t.indexOf("href")<0?"":e}))},listType:function(e,t){var n,i=e.innerHTML,r=o.innerText(e),a=i.match(/^(?:<span [^>]*texhtml[^>]*>)?<span [^>]*(?:Symbol|Wingdings)[^>]*>([^<]+)/i),s=a&&a[1],l=/^[a-z\d]/i.test(s),c=function(e){return e.replace(/^(?:&nbsp;|[\u00a0\n\r\s])+/,"")};return a&&(n=!0),i=i.replace(/<\/?\w+[^>]*>/g,"").replace(/&nbsp;/g," "),!n&&/^[\u2022\u00b7\u00a7\u00d8o]\u00a0+/.test(i)||n&&/^.\u00a0+/.test(i)||s&&!l&&t?{tag:"ul",style:this._guessUnorderedListStyle(c(r))}:/^\s*\w+[\.\)][\u00a0 ]{2,}/.test(i)?{tag:"ol",style:this._guessOrderedListStyle(c(r))}:void 0},_convertToLi:function(e){var t;return 1==e.childNodes.length?(t=e.firstChild.nodeType===o.nodeTypes.TEXT_NODE?o.innerText(e):e.firstChild.innerHTML.replace(/^\w+[\.\)](&nbsp;)+ /,""),t=this._checkForBullet(t)):t=this._getHtmlNoBullet(e),o.remove(e),o.create(document,"li",{innerHTML:t})},_checkForBullet:function(e){var t=o.create(document,"p",{innerHTML:e});return/^\s*\w+[\.\)]\s+/.test(t.innerText)?this._getHtmlNoBullet(t):e},_getHtmlNoBullet:function(e){var t=o.name(e);return o.remove(e.firstChild),3==e.firstChild.nodeType&&/^[ivxlcdm]+\.$/i.test(e.firstChild.nodeValue)&&o.remove(e.firstChild),/^(&nbsp;|\s)+$/i.test(e.firstChild.innerHTML)&&o.remove(e.firstChild),"p"!=t?"<"+t+">"+e.innerHTML+"</"+t+">":e.innerHTML},_guessUnorderedListStyle:function(e){return/^[\u2022\u00b7\u00FC\u00D8\u002dv-]/.test(e)?null:/^o/.test(e)?"circle":"square"},_guessOrderedListStyle:function(e){var t=null;return/^\d/.test(e)||(t=(/^[a-z]/.test(e)?"lower-":"upper-")+(/^[ivxlcdm]/i.test(e)?"roman":"alpha")),t},extractListLevels:function(e){return e=e.replace(/style=['"]?[^'"]*?mso-list:\s?[a-zA-Z]+(\d+)\s[a-zA-Z]+(\d+)\s(\w+)/gi,(function(e,n,i){return t.format('data-list="{0}" data-level="{1}" {2}',n,i,e)}))},_createList:function(e,t){return o.create(document,e,{style:{listStyleType:t}})},lists:function(t){var n,i,r,a,s,c,d,u,h,p,f,m,g,v=e(t).find(o.blockElements.join(",")),_=-1,b={},y=["p","h1","h2","h3","h4","h5","h6"];for(u=0;u<v.length;u++){h=v[u];var w=(g=e(h).data()).list;if(n=o.name(h),!!!e(h).parents("table").length){var k=this.listType(h,g);if(!(p=k&&k.tag)||y.indexOf(n)<0)h.innerHTML?i&&!c&&i.appendChild(h):o.remove(h);else if(!l.msie){var x=p+w;b[f=g.level||parseFloat(h.style.marginLeft||0)]||(b[f]={}),(!r||r<0)&&(r=f,a=w,s=e(t).find("[data-list='"+a+"']").last()[0],d=this._createList(p,k.style),o.insertBefore(d,h),_=f,b[f][x]=d),c=s===h,m=b[f][x],(f>_||!m)&&(m=this._createList(p,k.style),b[f][x]=m,i.appendChild(m)),i=this._convertToLi(h),m.appendChild(i),c?r=_=-1:_=f}}}},removeAttributes:function(e){for(var t,n=e.attributes,i=n.length,r=[],a=function(e){(function(e){return["border","background","padding"].filter((function(t){return 0===e.trim().indexOf(t)})).length>0})(e)&&r.push(e.trim())};i--;)"colspan"!=o.name(n[i])&&("style"!==(t=n[i]).name||"TD"!==e.nodeName&&"TH"!==e.nodeName||t.value.split(";").forEach(a),e.removeAttributeNode(n[i]));r.length>0&&e.setAttribute("style",r.join(";"))},createColGroup:function(n){var i=n.cells,r=e(n).closest("table"),o=r.children("colgroup");i.length<2||(o.length&&(i=o.children(),o[0].parentNode.removeChild(o[0])),(o=e(e.map(i,(function(e){var n=e.width;return n&&0!==parseInt(n,10)?t.format('<col style="width:{0}px;"/>',n):"<col />"})).join(""))).is("colgroup")||(o=e("<colgroup/>").append(o)),o.prependTo(r))},convertHeaders:function(t){var n,i=t.cells,r=e.map(i,(function(t){var n=e(t).children("p").children("strong")[0];if(n&&"strong"==o.name(n))return n}));if(r.length==i.length){for(n=0;n<r.length;n++)o.unwrap(r[n]);for(e(t).closest("table").find("colgroup").after("<thead></thead>").end().find("thead").append(t),n=0;n<i.length;n++)o.changeTag(i[n],"th")}},removeParagraphs:function(t){var n,i,r,a;for(n=0;n<t.length;n++)for(this.removeAttributes(t[n]),i=0,r=(a=e(t[n]).children("p")).length;i<r;i++)i<r-1&&o.insertAfter(o.create(document,"br"),a[i]),o.unwrap(a[i])},removeTextNodes:function(e){var t,n,i,r,a;for(t=0;t<e.length;t++)for(i=(a=e[t]).childNodes,n=0;n<i.length;n++)(r=i[n]).nodeType===o.nodeTypes.TEXT_NODE&&a.removeChild(r)},tables:function(t){var n,i,r,o,a,s=e(t).find("table"),l=this;for(o=0;o<s.length;o++){for(r=i=(n=s[o].rows)[0],a=1;a<n.length;a++)n[a].cells.length>r.cells.length&&(r=n[a]);l.createColGroup(r),l.convertHeaders(i),l.removeAttributes(s[o]),l.removeParagraphs(s.eq(o).find("td,th")),l.removeTextNodes(s.eq(o).find("tr"))}},headers:function(t){for(var n=e(t).find("p.MsoTitle"),i=0;i<n.length;i++)o.changeTag(n[i],"h1")},removeFormatting:function(t){e(t).find("*").each((function(){e(this).css({fontSize:"",fontFamily:""}),this.getAttribute("style")||this.style.cssText||this.removeAttribute("style")}))},clean:function(e){var t,n=this,i=this.options;return i.none?(e=u.fn.clean.call(n,e,this.junkReplacements),e=n.stripEmptyAnchors(e)):(e=i.msConvertLists?this.extractListLevels(e):e,e=u.fn.clean.call(n,e),e=n.stripEmptyAnchors(e),t=o.create(document,"div",{innerHTML:e}),n.headers(t),i.msConvertLists&&n.lists(t),n.tables(t),i.msAllFormatting&&n.removeFormatting(t),e=t.innerHTML.replace(/(<[^>]*)\s+class="?[^"\s>]*"?/gi,"$1")),e}}),m=u.extend({init:function(e){u.fn.init.call(this,e),this.replacements=[/\s+class="Apple-style-span[^"]*"/gi,"",/<(div|p|h[1-6])\s+style="[^"]*"/gi,"<$1",/^<div>(.*)<\/div>$/,"$1"]},applicable:function(e){return/class="?Apple-style-span|style="[^"]*-webkit-nbsp-mode/i.test(e)}}),g=u.extend({clean:function(e){var t=o.create(document,"div",{innerHTML:e});return(t=this.cleanDom(t)).innerHTML},cleanDom:function(e){return e}}),v=g.extend({cleanDom:function(t){var n=this.collectTags();return e(t).find(n).each((function(){o.unwrap(this)})),t},collectTags:function(){if(this.options.span)return"span"},applicable:function(){return this.options.span}}),_=g.extend({cleanDom:function(t){var n=this.collectAttr();return e(t).find("["+n.join("],[")+"]").removeAttr(n.join(" ")),t},collectAttr:function(){return this.options.css?["class","style"]:[]},applicable:function(){return this.options.css}}),b=function(){this.text="",this.add=function(e){this.text+=e}},y=n.extend({init:function(e){this.separators=e||{text:" ",line:"<br/>"},this.lines=[],this.inlineBlockText=[],this.resetLine()},appendText:function(e){3===e.nodeType&&(e=e.nodeValue),this.textContainer.add(e)},appendInlineBlockText:function(e){this.inlineBlockText.push(e)},flashInlineBlockText:function(){this.inlineBlockText.length&&(this.appendText(this.inlineBlockText.join(" ")),this.inlineBlockText=[])},endLine:function(){this.flashInlineBlockText(),this.resetLine()},html:function(){var e=this.separators,t="",n=this.lines;this.flashInlineBlockText();for(var i=0,r=n.length,o=r-1;i<r;i++){for(var a=n[i],s=0,l=a.length,c=l-1;s<l;s++){t+=a[s].text,s!==c&&(t+=e.text)}i!==o&&(t+=e.line)}return t},resetLine:function(){this.textContainer=new b,this.line=[],this.line.push(this.textContainer),this.lines.push(this.line)}}),w=n.extend({init:function(e){this.callback=e},enumerate:function(e){if(e){var t=this.callback(e),n=e.firstChild;!t&&n&&this.enumerate(n),this.enumerate(e.nextSibling)}}}),k=u.extend({init:function(e){u.fn.init.call(this,e),this.hasText=!1,this.enumerator=new w(this.buildText.bind(this))},clean:function(e){var t=o.create(document,"div",{innerHTML:e});return this.cleanDom(t)},cleanDom:function(e){return this.separators=this.getDefaultSeparators(),this.htmlLines=new y(this.separators),this.enumerator.enumerate(e.firstChild),this.hasText=!1,this.htmlLines.html()},buildText:function(e){if(o.isDataNode(e)){if(o.isEmptyspace(e))return;this.htmlLines.appendText(e.nodeValue.replace("\n",this.separators.line)),this.hasText=!0}else{if(o.isBlock(e)&&this.hasText)return(this.actions[o.name(e)]||this.actions.block)(this,e);o.isBr(e)&&this.htmlLines.appendText(this.separators.line)}},applicable:function(){var e=this.options;return e.all||e.keepNewLines},getDefaultSeparators:function(){return this.options.all?{text:" ",line:" "}:{text:" ",line:"<br/>"}},actions:{ul:e.noop,ol:e.noop,table:e.noop,thead:e.noop,tbody:e.noop,td:function(e,t){var n=new k({all:!0}).cleanDom(t);return e.htmlLines.appendInlineBlockText(n),!0},block:function(e){e.htmlLines.endLine()}}}),x=u.extend({clean:function(e){return this.options.custom(e)},applicable:function(){return"function"==typeof this.options.custom}});c(i,{Clipboard:d,Cleaner:u,ScriptCleaner:h,TabCleaner:p,MSWordFormatCleaner:f,WebkitFormatCleaner:m,HtmlTagsCleaner:v,HtmlAttrCleaner:_,HtmlContentCleaner:k,HtmlTextLines:y,CustomCleaner:x})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Class,i=t.ui.editor,r=i.RangeUtils,o=i.Dom,a=i.RestorePoint,s=i.Marker,l=t.support.browser,c="<span  class='k-br'>\ufeff</span>",d=e.extend,u=o.nodeTypes,h="previousSibling";function p(e,t,n){for(var i=e?e[t]:null;i&&!n(i);)i=i[t];return i}var f="td,th,caption",m="table,tbody,thead,tfoot,tr",g=m+","+f,v=function(t){return!t.collapsed&&e(t.commonAncestorContainer).is(m)},_=n.extend({remove:function(t){var n=new s;n.add(t,!1);var i=r.getAll(t,(function(t){return e(t).is(g)})),a=r.documentFromRange(t),l=n.start,c=n.end,d=f.split(","),u=o.parentOfType(l,d),h=o.parentOfType(c,d);this._removeContent(l,u,!0),this._removeContent(c,h,!1),e(i).each((function(t,n){((n=e(n)).is(f)?n:n.find(f)).each((function(e,t){t.innerHTML="&#65279;"}))})),u&&!l.previousSibling&&o.insertBefore(a.createTextNode("\ufeff"),l),h&&!c.nextSibling&&o.insertAfter(a.createTextNode("\ufeff"),c),u?t.setStartBefore(l):i[0]&&(u=(u=e(i[0])).is(f)?u:u.find(f).first()).length&&t.setStart(u.get(0),0),t.collapse(!0),o.remove(l),o.remove(c)},_removeContent:function(t,n,i){if(n){var r,a=i?"nextSibling":"previousSibling",s=function(t){for(;t&&!t[a];)t=t.parentNode;return t&&e.contains(n,t)?t[a]:null};for(t=s(t);t;)r=s(t),o.remove(t),t=r}}}),b=n.extend({init:function(e){this.editor=e},keydown:function(t){var n=this,r=n.editor,o=r.keyboard,s=o.isTypingKey(t),c=d(e.Event(),t);if(n.editor.trigger("keydown",c),c.isDefaultPrevented()||t&&t.isDefaultPrevented())return t.preventDefault(),!0;if(!c.isDefaultPrevented()&&s&&!o.isTypingInProgress()){var u=r.getRange(),h=r.body;if(n.startRestorePoint=new a(u,h),v(u))new _(r).remove(u),r.selectRange(u);if(l.webkit&&!u.collapsed&&function(e,t){return t.startContainer===e&&t.endContainer===e&&0===t.startOffset&&t.endOffset==e.childNodes.length}(h,u)&&(h.innerHTML=""),r.immutables&&i.Immutables.immutablesContext(u))new i.BackspaceHandler(r).deleteSelection(u);return o.startTyping((function(){n._removeBomSpan(),n.endRestorePoint=i._finishUpdate(r,n.startRestorePoint)})),!0}return!1},keyup:function(e){var t=this.editor.keyboard;return this.editor.trigger("keyup",e),!!t.isTypingInProgress()&&(t.endTyping(),!0)},_removeBomSpan:function(){var e=this.editor.getRange().commonAncestorContainer;o.emptyNode(e)||(3===e.nodeType&&(e=e.parentNode),o.insignificant(e)&&(e.textContent=o.stripBom(e.textContent),o.unwrap(e)))}}),y=n.extend({init:function(e){this.editor=e},_addCaret:function(e){var n=o.create(this.editor.document,"a");return!t.support.browser.chrome&&e.firstChild&&e.firstChild.nodeType===u.ELEMENT_NODE&&(e=e.firstChild),o.insertAt(e,n,0),o.stripBomNode(n.previousSibling),o.stripBomNode(n.nextSibling),n},_restoreCaret:function(e){var t=this.editor.createRange();!e.nextSibling&&o.isDataNode(e.previousSibling)?t.setStart(e.previousSibling,e.previousSibling.length):t.setStartAfter(e),t.collapse(!0),this.editor.selectRange(t),o.remove(e)},_handleDelete:function(e){var t=e.endContainer,n=o.closestEditableOfType(t,o.blockElements);if(n&&i.RangeUtils.isEndOf(e,n)){var r=o.next(n);if(!r||"p"!=o.name(r))return!1;var a=o.significantChildNodes(r)[0];a=a&&o.isInline(a)?a:r;var s=this._addCaret(a);return this._merge(n,r),this._restoreCaret(s),!0}return!1},_cleanBomBefore:function(e){for(var t=e.startOffset,n=e.startContainer,i=n.nodeValue,r=0;t-r>=0&&"\ufeff"==i[t-r-1];)r++;r>0&&(n.deleteData(t-r,r),e.setStart(n,Math.max(0,t-r)),e.collapse(!0),this.editor.selectRange(e))},_handleBackspace:function(t){var n,r=t.startContainer,a=o.closestEditableOfType(r,["li"]),s=o.closestEditableOfType(r,"p,h1,h2,h3,h4,h5,h6".split(",")),l=this.editor;if(o.isDataNode(r)){if(t.collapsed&&/^\s[\ufeff]+$/.test(r.nodeValue))return t.setStart(r,0),t.setEnd(r,r.length),l.selectRange(t),!1;this._cleanBomBefore(t)}n=p(s,h,(function(e){return!o.htmlIndentSpace(e)})),t.collapsed&&t.startOffset!==t.endOffset&&t.startOffset<0&&(t.startOffset=0,t.endOffset=0,l.selectRange(t));var c=a&&i.RangeUtils.isStartOf(t,a),d=a&&e(a).index(),u=c&&d>0;if(u&&(s=a,n=o.prev(a)),s&&n&&o.is(n,"table")&&i.RangeUtils.isStartOf(t,s))return""===s.innerText&&(s.innerHTML="\ufeff"),!0;if(i.RangeUtils.isStartOf(t,s)&&parseInt(s.style.marginLeft,10)>0)return l.exec("outdent"),!0;if(s&&n&&i.RangeUtils.isStartOf(t,s)||u){var f=o.significantChildNodes(s)[0];f=f&&o.isInline(f)&&!o.isImg(f)?f:s;var m=this._addCaret(f);return this._merge(n,s),this._restoreCaret(m),!0}if(c&&0===d){var g=a.firstChild;g||(a.innerHTML=i.emptyElementContent,g=a.firstChild);var v=new i.ListFormatter(o.name(a.parentNode),"p");return t.selectNodeContents(a),v.toggle(t),o.insignificant(g)?t.setStartBefore(g):t.setStart(g,0),l.selectRange(t),!0}var _=r.childNodes[t.startOffset-1],b=t,y=_&&o.closestEditableOfType(_,["a"]),w=p(_||r,h,(function(e){return!o.isDataNode(e)||!o.isBom(e)&&e.length>0}));if((y||(0===t.startOffset||_)&&o.is(w,"a"))&&(y=y||w,(b=l.createRange()).setStart(y,y.childNodes.length),b.collapse(!0)),(y=y||o.closestEditableOfType(_||b.startContainer,["a"]))&&i.RangeUtils.isEndOf(b,y)){var k=new i.UnlinkCommand({range:b,body:l.body,immutables:!!l.immutables});l.execCommand(k),l._selectionChange()}return!1},_handleSelection:function(t){var n,r=t.commonAncestorContainer,a=o.closest(r,"table"),l=i.emptyElementContent,c=this.editor;if(v(t))return new _(c).remove(t),c.selectRange(t),!0;var d=new s;d.add(t,!1),t.commonAncestorContainer===c.body&&this._surroundFullyContent(d,t),c.immutables&&this._handleImmutables(d),this._surroundFullySelectedAnchor(d,t),t.setStartAfter(d.start),t.setEndBefore(d.end);var u=t.startContainer,h=t.endContainer;return t.deleteContents(),"li"===h.tagName.toLocaleLowerCase()&&o.emptyNode(h)&&(t.selectNode(h),t.deleteContents()),a&&""===e(a).text()&&(t.selectNode(a),t.deleteContents()),r=t.commonAncestorContainer,"p"===o.name(r)&&""===r.innerHTML&&(r.innerHTML=l,t.setStart(r,0)),this._join(u,h),o.insertAfter(c.document.createTextNode("\ufeff"),d.start),d.remove(t),u=t.startContainer,"tr"==o.name(u)&&(u=u.childNodes[Math.max(0,t.startOffset-1)],t.setStart(u,o.getNodeLength(u))),t.collapse(!0),c.selectRange(t),n=u.parentElement||u.parentNode,o.isDataNode(u)&&!o.emptyNode(n)&&this._cleanBomBefore(t),!0},_handleImmutables:function(e){var t=i.Immutables.immutableParent,n=t(e.start),r=t(e.start);n&&o.insertBefore(e.start,n),r&&o.insertAfter(e.end,r),n&&o.remove(n),r&&r.parentNode&&o.remove(r)},_surroundFullyContent:function(e,t){var n=t.commonAncestorContainer.children,i=n[0],r=n[n.length-1];this._moveMarker(e,t,i,r)},_surroundFullySelectedAnchor:function(t,n){var i=t.start,r=e(i).closest("a").get(0),o=t.end,a=e(o).closest("a").get(0);this._moveMarker(t,n,r,a)},_moveMarker:function(e,t,n,i){var a=e.start,s=e.end;n&&r.isStartOf(t,n)&&o.insertBefore(a,n),i&&r.isEndOf(t,i)&&o.insertAfter(s,i)},_root:function(e){for(;e&&"body"!=o.name(e)&&e.parentNode&&"body"!=o.name(e.parentNode);)e=e.parentNode;return e},_join:function(e,t){(e=this._root(e))!=(t=this._root(t))&&o.is(t,"p")&&this._merge(e,t)},_merge:function(e,t){for(o.removeTrailingBreak(e);e&&t.firstChild;)1==e.nodeType?(e=o.list(e)?e.children[e.children.length-1]:e)&&e.appendChild(t.firstChild):e.nodeType===u.TEXT_NODE?this._mergeWithTextNode(e,t.firstChild):e.parentNode.appendChild(t.firstChild);o.remove(t)},_mergeWithTextNode:function(e,t){e&&e.nodeType===u.TEXT_NODE&&(e.nextSibling&&this._isCaret(e.nextSibling)?o.insertAfter(t,e.nextSibling):o.insertAfter(t,e))},_isCaret:function(t){return e(t).is("a")},keydown:function(e){var n,r,o=this.editor,s=o.getRange(),l=e.keyCode,c=t.keys,d=l===c.BACKSPACE,u=l==c.DELETE;o.immutables&&o.immutables.keydown(e,s)||(!d&&!u||s.collapsed?d?n="_handleBackspace":u&&(n="_handleDelete"):n="_handleSelection",n&&(r=new a(s,o.body),this[n](s)&&(e.preventDefault(),i._finishUpdate(o,r))))},deleteSelection:function(e){this._handleSelection(e)},keyup:e.noop}),w=n.extend({init:function(e){this.editor=e,this.systemCommandIsInProgress=!1},createUndoCommand:function(){this.startRestorePoint=this.endRestorePoint=i._finishUpdate(this.editor,this.startRestorePoint)},changed:function(){return!!this.startRestorePoint&&this.startRestorePoint.html!=this.editor.body.innerHTML},keydown:function(e){var t=this,n=t.editor,i=n.keyboard;return i.isModifierKey(e)?(i.isTypingInProgress()&&i.endTyping(!0),t.startRestorePoint=new a(n.getRange(),n.body),!0):!!i.isSystem(e)&&(t.systemCommandIsInProgress=!0,t.changed()&&(t.systemCommandIsInProgress=!1,t.createUndoCommand()),!0)},keyup:function(){var e=this;return!(!e.systemCommandIsInProgress||!e.changed())&&(e.systemCommandIsInProgress=!1,e.createUndoCommand(),!0)}}),k=n.extend({init:function(e){this.editor=e},keydown:function(e){!l.webkit||e.isDefaultPrevented()||!e.ctrlKey||65!=e.keyCode||e.altKey||e.shiftKey||(this.editor.options.immutables&&this._toSelectableImmutables(),this._selectEditorBody())},_selectEditorBody:function(){var e=this.editor,t=e.getRange();t.selectNodeContents(e.body),setTimeout((function(){e.selectRange(t)}))},_toSelectableImmutables:function(){for(var t=this.editor.body,n=i.Immutables.immutable,r=o.emptyTextNode,a=t.firstChild,s=t.lastChild;r(a);)a=a.nextSibling;for(;r(s);)s=s.previousSibling;a&&n(a)&&e(c).prependTo(t),s&&n(s)&&e(c).appendTo(t)},keyup:e.noop}),x=n.extend({init:function(e){this.handlers=e,this.typingInProgress=!1},isCharacter:function(e){return e>=48&&e<=90||e>=96&&e<=111||e>=186&&e<=192||e>=219&&e<=222||229==e},toolFromShortcut:function(t,n){var i,r,o=String.fromCharCode(n.keyCode),a=this._getShortcutModifier(n,navigator.platform);for(i in t)if(((r=e.extend({ctrl:!1,alt:!1,shift:!1},t[i].options)).key==o||r.key==n.keyCode)&&r.ctrl==a&&r.alt==n.altKey&&r.shift==n.shiftKey)return i},_getShortcutModifier:function(e,t){return t.toUpperCase().indexOf("MAC")>=0?e.metaKey:e.ctrlKey},toolsFromShortcut:function(t,n){var i,r,o=String.fromCharCode(n.keyCode),a=[],s=function(e){return e==o||e==n.keyCode||e==n.charCode};for(i in t)r=e.extend({ctrl:!1,alt:!1,shift:!1},t[i].options),(Array.isArray(r.key)?e.grep(r.key,s).length>0:s(r.key))&&r.ctrl==n.ctrlKey&&r.alt==n.altKey&&r.shift==n.shiftKey&&a.push(t[i]);return a},isTypingKey:function(e){var t=e.keyCode;return this.isCharacter(t)&&!e.ctrlKey&&!e.altKey||32==t||13==t||8==t||46==t&&!e.shiftKey&&!e.ctrlKey&&!e.altKey},isModifierKey:function(e){var t=e.keyCode;return 17==t&&!e.shiftKey&&!e.altKey||16==t&&!e.ctrlKey&&!e.altKey||18==t&&!e.ctrlKey&&!e.shiftKey},isSystem:function(e){return 46==e.keyCode&&e.ctrlKey&&!e.altKey&&!e.shiftKey},startTyping:function(e){this.onEndTyping=e,this.typingInProgress=!0},stopTyping:function(){this.typingInProgress&&this.onEndTyping&&this.onEndTyping(),this.typingInProgress=!1},endTyping:function(e){var t=this;t.clearTimeout(),e?t.stopTyping():t.timeout=window.setTimeout(t.stopTyping.bind(t),1e3)},isTypingInProgress:function(){return this.typingInProgress},clearTimeout:function(){window.clearTimeout(this.timeout)},notify:function(e,t){var n,i=this.handlers;for(n=0;n<i.length&&!i[n][t](e);n++);},keydown:function(e){this.notify(e,"keydown")},keyup:function(e){this.notify(e,"keyup")}});d(i,{TypingHandler:b,SystemHandler:w,BackspaceHandler:y,SelectAllHandler:k,Keyboard:x})}(window.kendo.jQuery),function(e){var t=window.kendo.ui.editor,n=t.Command,i=t.EditorUtils.registerTool,r=t.Tool,o=e.extend,a=n.extend({init:function(e){this.async=!0,n.fn.init.call(this,e)},exec:function(){var e=this,t=e.lockRange(!0),n=e.editor;n._destroyResizings(),n.saveAsPDF().then((function(){e.releaseRange(t),n._initializeColumnResizing(),n._initializeRowResizing(),n._initializeElementResizing()}))}});o(t,{ExportPdfCommand:a}),i("pdf",new r({command:a}))}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.ui.editor,i=n.Command,r=n.EditorUtils.registerTool,o=n.Tool,a=e.extend,s=i.extend({init:function(e){i.fn.init.call(this,e),this.managesUndoRedo=!0},exec:function(){var e=this.editor;t.support.browser.msie?e.document.execCommand("print",!1,null):e.window.print&&e.window.print()}});a(n,{PrintCommand:s}),r("print",new o({command:s}))}(window.kendo.jQuery),function(e){var t=window.kendo.ui.editor,n=t.Tool,i=t.Command,r=t.EditorUtils,o=t.Dom,a=t.RangeUtils,s=r.registerTool,l=i.extend({init:function(e){i.fn.init.call(this,e)},exec:function(){var e=this.lockRange(!0);this.inlineStyles=[],this.blockStyles=[],this.collectStyles(e),this.editor.inlineStyles=this.inlineStyles,this.editor.blockStyles=this.blockStyles,this.releaseRange(e)},collectStyles:function(e){var t,n=a.nodes(e);for(t=1===n.length?n[0].parentNode:e.startContainer;t&&!o.is(t,"body")&&"editor"!==t.getAttribute("data-role");)o.isBlock(t)?(this.populateStyles(t,"blockStyles"),t=o.is(t,"li")?t.parentNode:null):(this.populateStyles(t,"inlineStyles"),t=t.parentNode)},populateStyles:function(e,t){var n,i,r,o,a,s=e.style,l=e.attributes,c={tags:[e.tagName],attr:{style:{}}};if(s)for(a=0;a<s.length;a++)n=s[i=s[a]],c.attr.style[i]=n;if(l)for(a=0;a<l.length;a++)r=l[a].nodeName,o=l[a].nodeValue,"style"!==r&&("class"===r?c.attr.className=o:c.attr[r]=o);this[t].push(c)}}),c=i.extend({init:function(e){i.fn.init.call(this,e)},exec:function(){var e,t=this.lockRange(!0),n=a.getMarkers(t),i=this.editor,r=i.inlineStyles,s=i.blockStyles;(r&&0!==r.length||s&&0!==s.length)&&(3===n.length&&(this.marker.removeCaret(t),this.marker.caret=null),this.removeEmptyElementsFromRange(t),e=a.nodes(t),this.cleanInlineParents(e),o.normalize(t.commonAncestorContainer),2===n.length?(t.setStartAfter(n[0]),t.setEndBefore(n[1])):(t.setStartBefore(e[0]),t.setEndAfter(e[0])),(e=a.nodes(t))&&s&&s.length&&this.applyBlockStyles(e,s),e&&r&&r.length&&this.applyInlineStyles(e,r),this.releaseRange(t))},removeEmptyElementsFromRange:function(e){var t,n;if((t=a.getAll(e,(function(e){return o.isInline(e)&&!e.firstChild&&!o.isMarker(e)})))&&t.length>0)for(n=0;n<t.length;n++)t[n].parentNode.removeChild(t[n])},cleanInlineParents:function(e){var t,n,i,r,a,s,l;for(t=0;t<e.length;t++)if(i=(n=e[t]).parentNode,!this.immutableParent(n))for(;i&&o.isInline(i);){for(r=i.childNodes,a=0;a<r.length;a++)s=r[a],o.isMarker(s)||s===n||((l=i.cloneNode(!0)).innerHTML="",o.wrap(s,l));o.unwrap(i),i=n.parentNode}},applyBlockStyles:function(e,t){var n,i,r,a,s,l,c,d,u,h,p,f,m,g,v,_=t[0].tags[0],b=t[0].attr,y=this.editor.document;for(n=0,i=e.length;n<i;n++)if(r=e[n],!o.isWhitespace(r)&&!this.immutableParent(r))if("BODY"!==(s=o.blockParentOrBody(r)).tagName&&s.tagName!==_){if("LI"!==s.tagName&&"TD"!==s.tagName&&"TH"!==s.tagName){for(c=[],d=[],u=r.previousSibling,h=r.nextSibling;u;)o.isMarker(u)||c.push(u),u=u.previousSibling;if(c.length)for((p=s.cloneNode(!0)).innerHTML="",o.insertBefore(p,c[0]),g=0;g<c.length;g++)m=c[g],o.insertAt(p,m,0);for(;h;)o.isMarker(h)||d.push(h),h=h.nextSibling;if(d.length)for((f=s.cloneNode(!0)).innerHTML="",o.insertBefore(f,d[0]),g=0;g<d.length;g++)m=d[g],f.appendChild(m);o.unwrap(s)}a=o.create(y,_,b),o.wrap(r,a)}else s.tagName===_&&o.attr(s,b);if(s&&2===t.length&&"LI"!==s.tagName&&"LI"===_){for(v=[];o.is(a,"li");)v.push(a),a=o.prev(a);for(l=o.create(y,t[1].tags[0],t[1].attr),o.insertBefore(l,v[v.length-1]),l.appendChild(v[0]),n=1,i=v.length;n<i;n++)o.insertBefore(v[n],l.firstChild)}else s&&2===t.length&&"LI"!==s.tagName&&(l=o.create(y,t[1].tags[0],t[1].attr),o.wrap(a,l))},applyInlineStyles:function(e,t){var n,i,r,a,s,l,c=this.editor.document;for(a=0;a<t.length;a++)n=t[a],i=o.create(c,n.tags[0],n.attr),r&&i.appendChild(r),r=i;if(r)for(a=0;a<e.length;a++)if(l=e[a],!o.isWhitespace(l)&&!this.immutableParent(l)){for(s=r.cloneNode(!0),o.insertBefore(s,l);s.children&&s.children.length;)s=s.children[0];s.appendChild(l)}},immutables:function(){return this.editor&&this.editor.options.immutables},immutableParent:function(e){return this.immutables()&&t.Immutables.immutableParent(e)}}),d=n.extend({init:function(e){n.fn.init.call(this,e)},command:function(e){return new l(e)}}),u=n.extend({init:function(e){n.fn.init.call(this,e)},command:function(e){return new c(e)}});e.extend(t,{CopyFormatCommand:l,ApplyFormatCommand:c,CopyFormatTool:d,ApplyFormatTool:u}),s("copyFormat",new d({})),s("applyFormat",new u({}))}(window.kendo.jQuery),function(e){const t=window.kendo,n=e.extend,i=t.ui.editor,r=t.ui.Editor.fn.options.formats,o=i.Dom,a=i.Tool,s=i.DelayedExecutionTool,l=i.BlockFormatter,c=i.FormatCommand,d=i.GreedyInlineFormatFinder,u=i.EditorUtils,h=u.registerTool,p=u.registerFormat,f=i.RangeUtils,m=c.extend({exec:function(){const e=this,t=e.lockRange(!0),n=o.filterBy(f.nodes(t),o.htmlIndentSpace,!0);e.formatter.format[0].attr.style.lineHeight=e.options.value.lineHeight,e.formatter.apply(n),e.releaseRange(t)}}),g=s.extend({init:function(e){a.fn.init.call(this,e),this.type="kendoComboBox",this.format=[{tags:["p","lineHeight"]}],this.finder=new d(this.format,e.cssAttr,e.fontAttr,e.defaultValue)},command:function(e){var t=this;return new m(n(e,{formatter:function(){return new l(t.options.format)}}))},initialize:function(e,t){let n=e.getKendoComboBox();this.editor=t,n.bind("change",this.changeHandler.bind(this)),n.bind("close",this.closeHandler.bind(this)),n.wrapper.on("mousedown.kendoEditor",".k-input-button,.k-input-inner",this.mouseDownHandler.bind(this)).on("keydown.kendoEditor",this.keyDownHandler.bind(this))},changeHandler:function(e){this._exec(e.sender.value())},closeHandler:function(){let e=this,t=e.editor;setTimeout((function(){t._deleteSavedRange(),e.currentRange=null}),0)},mouseDownHandler:function(){let e=this.editor.getRange();this.currentRange=this.editor._containsRange(e)?e:this.currentRange},keyDownHandler:function(e){e.keyCode===t.keys.ENTER&&(this.editor._deleteSavedRange(),this.currentRange=null,e.preventDefault())},_exec:function(e){this.editor._range=this.currentRange,e&&a.exec(this.editor,this.options.name,{lineHeight:e})}});e.extend(i,{LineHeightCommand:m,LineHeightFormatTool:g}),p("lineHeight",[{tags:o.blockElements,attr:{style:{lineHeight:"normal"}}}]),h("lineHeight",new g({cssAttr:"line-height",format:r.lineHeight,defaultValue:1.15,ui:{type:"component",component:"ComboBox",componentOptions:{value:1.15,dataTextField:"text",dataValueField:"value",prefixOptions:{icon:"paragraphHeight"},autoSize:!0,dataSource:[{text:"1",value:"1"},{text:"1.15",value:"1.15"},{text:"1.5",value:"1.5"},{text:"2",value:"2"},{text:"2.5",value:"2.5"}]}}}))}(window.kendo.jQuery),function(e){const t=window.kendo.ui.editor,n=t.Tool,i=t.Command,r=t.EditorUtils.registerTool,o=t.Dom,a=function(e,t,n,i,r,o){const a=e.cloneRange(),s=a.startContainer;let l,c,d,u,h;return null!=r&&(a.setStart(s,r),a.setEnd(s,r+1)),l=a.getBoundingClientRect(),o?(h=o.getBoundingClientRect(),c=l.left-h.left-l.width/2,d=l.top-h.top+l.height+i):"·"===n?(c=l.x-l.width/4,d=l.y+l.height+i):"↵"===n&&(c=l.x,d=l.y+l.height+i),u=t.createElementNS("http://www.w3.org/2000/svg","text"),u.setAttributeNS(null,"x",c),u.setAttributeNS(null,"y",d),u.setAttributeNS(null,"fill","#6098f2"),u.setAttributeNS(null,"font-size",`${Math.ceil(l.height+l.width)}px`),u.textContent=n,u},s=function(){const t=this,n=t.getRange().cloneRange(),i=t._formattingMarksOverlay[0],r=t.document.createDocumentFragment(),s=t.document,l=t._isInlineEditor(),c=l?t.body.parentElement:null,d=l?c.scrollTop:s.documentElement.scrollTop;if(!t.body.firstChild&&!t.body.lastChild)return;n.setStart(t.body.firstChild,0),n.setEnd(t.body.lastChild,0);o.getTextNodes(t.body).concat(e(t.body).find("br").toArray()).forEach((e=>{if(e.nodeType===o.nodeTypes.TEXT_NODE){n.selectNodeContents(e);for(let e=n.startOffset;e<n.endOffset;e++)32!==n.startContainer.textContent.charCodeAt(e)&&160!==n.startContainer.textContent.charCodeAt(e)||r.appendChild(a(n,s,"·",d,e,c))}else n.selectNode(e),r.appendChild(a(n,s,"↵",d,null,c))})),i.appendChild(r)},l=function(e){e._formattingMarksOverlay.empty()},c=function(e){e._updateFormattingMarksOverlayHeight(),s.call(e)},d=i.extend({exec:function(){const e=this,t=e.lockRange(!0),n=e.editor;n._toggledFormattingMarks?(n._toggledFormattingMarks=!1,n._destroyFormattingMarksOverlay()):(n._toggledFormattingMarks=!0,n._appendFormattingMarksOverlay(),n._appendFormattingMarksStyles(),l(n),c(n)),e.releaseRange(t)}});e.extend(t,{FormattingMarksCommand:d,applyFormattingMarks:c,clearFormattingMarksOverlay:l}),r("formattingMarks",new n({command:d,icon:"paragraphMark",ui:{togglable:!0}}))}(window.kendo.jQuery),function(e){var t=window,n=t.Math,i=n.min,r=n.max,o=t.parseFloat,a=e.jQuery,s=a.extend,l=e.ui.editor,c=/(\d+)(\.?)(\d*)%/,d=/(\d+)(\.?)(\d*)px/,u="string";function h(e){return typeof e===u&&c.test(e)}var p={constrain:function(e){var t=e.value,n=e.min,a=e.max;return r(i(o(t),o(a)),o(n))},getScrollBarWidth:function(t){return t&&!a(t).is("body")&&t.scrollHeight>t.clientHeight?e.support.scrollbar():0},calculatePercentageRatio:function(e,t){return h(e)?o(e):o(e)/t*100},inPercentages:h,inPixels:function(e){return typeof e===u&&d.test(e)},toPercentages:function(e){return o(e)+"%"},toPixels:function(e){return o(e)+"px"}};s(l,{ResizingUtils:p})}(window.kendo),function(e){var t=e.jQuery,n=t.extend,i=t.noop,r=e.ui.editor,o=e.Class,a="keydown",s="mouseleave",l="mouseup",c="table",d=o.extend({init:function(e,i){var r=this;r.options=n({},r.options,i),r.options.tags=Array.isArray(r.options.tags)?r.options.tags:[r.options.tags],t(e).is(c)&&(r.element=e,r._attachEventHandlers())},destroy:function(){var e=this,n=e.options.eventNamespace;e.element&&(t(e.element).off(n),e.element=null),t(e.options.rootElement).off(a+n),e._destroyResizeHandle()},options:{tags:[],min:0,rootElement:null,eventNamespace:"",rtl:!1,handle:{dataAttribute:"",height:0,width:0,classNames:{},template:""}},_attachEventHandlers:function(){var e=this,n=e.options;t(e.element).on("mousemove"+n.eventNamespace,n.tags.join(","),e.detectElementBorderHovering.bind(e))},resizingInProgress:function(){var e=this._resizable;return!!e&&!!e.resizing},resize:i,detectElementBorderHovering:function(e){var n=this,i=n.options.handle,r=t(e.currentTarget),o=n.resizeHandle,a=i.dataAttribute;n.resizingInProgress()||(!r.is(":last-child")&&n.elementBorderHovered(r,e)?o?o.data(a)&&o.data(a)!==r[0]&&n.showResizeHandle(r,e):n.showResizeHandle(r,e):o&&n._destroyResizeHandle())},elementBorderHovered:i,showResizeHandle:function(e,t){var n=this;0===t.buttons&&(n._initResizeHandle(),n.setResizeHandlePosition(e),n.setResizeHandleDimensions(),n.setResizeHandleDataAttributes(e[0]),n._attachResizeHandleEventHandlers(),n._initResizable(e),n._hideResizeMarker(),n.resizeHandle.show())},_initResizeHandle:function(){var e=this,n=e.options;e._destroyResizeHandle(),e.resizeHandle=t(n.handle.template).appendTo(n.rootElement)},setResizeHandlePosition:i,setResizeHandleDimensions:i,setResizeHandleDataAttributes:function(e){this.resizeHandle.data(this.options.handle.dataAttribute,e)},_attachResizeHandleEventHandlers:function(){var e=this,t=e.options,n=t.eventNamespace,i=t.handle.classNames.marker,r=e.resizeHandle;e.resizeHandle.on("mousedown"+n,(function(){r.find("."+i).show()})).on(l+n,(function(){r.find("."+i).hide()}))},_hideResizeMarker:function(){this.resizeHandle.find("."+this.options.handle.classNames.marker).hide()},_destroyResizeHandle:function(){var e=this;e.resizeHandle&&(e._destroyResizable(),e.resizeHandle.off(e.options.eventNamespace).remove(),e.resizeHandle=null)},_initResizable:function(t){var n=this;n.resizeHandle&&(n._destroyResizable(),n._resizable=new e.ui.Resizable(t,{draggableElement:n.resizeHandle[0],start:n.onResizeStart.bind(n),resize:n.onResize.bind(n),resizeend:n.onResizeEnd.bind(n)}))},_destroyResizable:function(){var e=this;e._resizable&&(e._resizable.destroy(),e._resizable=null)},onResizeStart:function(){this._disableKeyboard()},onResize:function(e){this.setResizeHandleDragPosition(e)},setResizeHandleDragPosition:i,onResizeEnd:function(e){var t=this;t.resize(e),t._destroyResizeHandle(),t._enableKeyboard(),this.options.editor&&this.options.editor._handleSpaceAndNewLines()},_enableKeyboard:function(){var e=this.options;t(e.rootElement).off(a+e.eventNamespace)},_disableKeyboard:function(){var e=this.options;t(e.rootElement).on(a+e.eventNamespace,(function(e){e.preventDefault()}))},_forceResizing:function(e){var t=this._resizable;t&&t.userEvents&&t.userEvents._end(e)}}),u=o.extend({create:function(e,n){var i=this,r=n.name,o=n.eventNamespace;t(e.body).on("mouseenter"+o,c,(function(t){var o=t.currentTarget,a=e[r];t.stopPropagation(),a?a.element===o||a.resizingInProgress()||(i._destroyResizing(e,n),i._initResizing(e,o,n)):i._initResizing(e,o,n)})).on(s+o,c,(function(o){var a,s=e[r];o.stopPropagation(),!s||s.resizingInProgress()||s.resizeHandle||(a=t(s.element).parents(c)[0])&&(i._destroyResizing(e,n),i._initResizing(e,a,n))})).on(s+o,(function(){var t=e[r];t&&!t.resizingInProgress()&&i._destroyResizing(e,n)})).on(l+o,(function(o){var a,s=e[r];s&&s.resizingInProgress()&&(a=t(o.target).parents(c)[0])&&(s._forceResizing(o),i._destroyResizing(e,n),i._initResizing(e,a,n))}))},dispose:function(e,n){t(e.body).off(n.eventNamespace)},_initResizing:function(t,n,i){var r=i.name,o=i.type;t[r]=new o(n,{rtl:e.support.isRtl(t.element),rootElement:t.body,editor:t})},_destroyResizing:function(e,t){var n=t.name;e[n]&&(e[n].destroy(),e[n]=null)}});u.current=new u,d.create=function(e,t){u.current.create(e,t)},d.dispose=function(e,t){u.current.dispose(e,t)},n(r,{TableElementResizing:d})}(window.kendo),function(e){var t=window.Math.abs,n=e.jQuery,i=n.extend,r=e.ui.editor,o=r.Dom,a=r.TableElementResizing,s=r.ResizingUtils,l=s.constrain,c=s.calculatePercentageRatio,d=s.getScrollBarWidth,u=s.inPercentages,h=s.toPercentages,p=s.toPixels,f=e._outerWidth,m=".kendoEditorColumnResizing",g="k-column-resize-handle",v="k-column-resize-marker",_="body",b="tbody",y="thead",w="tr",k="col-index",x=",",C="width",S=a.extend({options:{tags:["td","th"],min:20,rootElement:null,eventNamespace:m,rtl:!1,handle:{dataAttribute:"column",width:10,height:0,classNames:{handle:g,marker:v},template:'<div class="k-column-resize-handle-wrapper" unselectable="on" contenteditable="false"><div class="'+g+'"><div class="'+v+'"></div></div></div>'}},elementBorderHovered:function(e,t){var i=this.options,r=i.handle.width,o=e.offset().left+(i.rtl?0:f(e)),a=t.clientX+n(e[0].ownerDocument).scrollLeft();return a>o-r&&a<o+r},setResizeHandlePosition:function(t){var i=this,r=n(i.element.tHead||i.element.tBodies[0]),o=i.options,a=o.rtl,s=o.handle.width,l=n(o.rootElement),c=l.is(_)?0:l.scrollTop(),u=l.is(_)?0:e.scrollLeft(l),h=a?0:f(t),p=a?d(l[0]):0,m=t.offset().left-(l.offset().left+parseFloat(l.css("borderLeftWidth")))-parseFloat(t.css("marginLeft")),g=r.offset().top-(l.offset().top+parseFloat(l.css("borderTopWidth")))-parseFloat(r.css("marginTop")),v=e.support.browser;a&&(v.mozilla||v.webkit&&v.version>=85)&&(u*=-1),i.resizeHandle.css({top:g+c,left:m+h+(u-p)-s/2,position:"absolute"})},setResizeHandleDimensions:function(){var e=this,t=n(e.element).children(y),i=n(e.element).children(b),r=t.length>0?t.height()+i.height():i.height();e.resizeHandle.css({width:e.options.handle.width,height:r})},setResizeHandleDragPosition:function(t){var i=this,r=n(n(t.currentTarget).data(i.options.handle.dataAttribute)),o=i.options,a=n(o.rootElement),s=o.handle?o.handle.width:0,c=o.min,u=o.rtl,h=f(r),p=r.offset().left-(a.offset().left+parseFloat(a.css("borderLeftWidth")))-parseFloat(r.css("marginLeft")),m=f(r.next()),g=n(i.resizeHandle),v=a.is(_)?0:e.scrollLeft(a),b=u?d(a[0]):0,y=g.offset().left-(a.offset().left+parseFloat(a.css("borderLeftWidth")))-parseFloat(g.css("marginLeft")),w=e.support.browser;u&&(w.mozilla||w.webkit&&w.version>=85)&&(v*=-1);var k=l({value:y+(v-b)+t.x.delta,min:p+(v-b)-(u?m:0)+c,max:p+h+(v-b)+(u?0:m)-s-c});g.css({left:k})},resize:function(e){var t,i,r,a,s,c=this,d=n(n(e.currentTarget).data(c.options.handle.dataAttribute)),u=c.options,h=u.rtl?-1:1,p=u.min,m=h*e.x.initialDelta;o.reMapTableColumns(c.element,k),a=parseInt(d.attr(k),10),d.prop("colSpan")>1&&(d=n(c.element).find("["+k+"="+(a+d.prop("colSpan")-1)+"]").eq(0),a=parseInt(d.attr(k),10)),s=n(c.element).find("["+k+"="+(a+1)+"]:not([colspan])"),c._setTableComputedWidth(),c._setColumnsComputedWidth(),r=f(d),i=f(s),t=l({value:r+m,min:p,max:r+i-p}),c._resizeColumn(d[0],t),c._resizeTopAndBottomColumns(d[0],t),c._resizeAdjacentColumns(parseInt(d.attr(k),10),i,r,r-t),o.clearTableMappings(c.element,k)},_setTableComputedWidth:function(){var e=this.element;""===e.style[C]&&(e.style[C]=p(f(n(e))))},_setColumnsComputedWidth:function(){var e,t=n(this.element.tHead||this.element.tBodies[0]),i=f(t),r=t.children(w).children("td"),o=r.length,a=r.map((function(){return f(n(this))}));for(e=0;e<o;e++)u(r[e].style[C])?r[e].style[C]=h(c(a[e],i)):r[e].style[C]=p(a[e])},_resizeTopAndBottomColumns:function(e,t){var i,r=this,o=n(e).attr(k),a=n(r.element).children(b+x+y).children(w).children(r.options.tags.join(x)).filter((function(){return n(this).attr(k)===o&&this!==e})),s=a.length;for(i=0;i<s;i++)r._resizeColumn(a[i],t)},_resizeColumn:function(e,t){var i=n(this.element.tHead||this.element.tBodies[0]);u(e.style[C])?e.style[C]=h(c(t,f(i))):e.style[C]=p(t)},_resizeAdjacentColumns:function(e,t,i,r){var o,a=this,s=n(a.element).children(b+x+y).children(w).children(a.options.tags.join(x)).filter((function(){return parseInt(n(this).attr(k),10)===e+1})),l=s.length;for(o=0;o<l;o++)a._resizeAdjacentColumn(s[o],t,i,r)},_resizeAdjacentColumn:function(e,n,i,r){var o,a=this.options.min;o=l({value:n+r,min:a,max:t(i+n-a)}),this._resizeColumn(e,o)}});S.create=function(e){a.create(e,{name:"columnResizing",type:S,eventNamespace:m})},S.dispose=function(e){a.dispose(e,{eventNamespace:m})},i(r,{ColumnResizing:S})}(window.kendo),function(e){var t=window.Math.abs,n=e.jQuery,i=n.extend,r=e.ui.editor,o=r.TableElementResizing,a=r.ResizingUtils,s=a.getScrollBarWidth,l=a.constrain,c=a.calculatePercentageRatio,d=a.inPercentages,u=a.toPercentages,h=a.toPixels,p=e._outerHeight,f=".kendoEditorRowResizing",m="k-row-resize-handle",g="k-row-resize-marker",v="body",_="tr",b="tbody",y="thead",w="height",k=o.extend({options:{tags:[_],min:20,rootElement:null,eventNamespace:f,rtl:!1,handle:{dataAttribute:"row",width:0,height:10,classNames:{handle:m,marker:g},template:'<div class="k-row-resize-handle-wrapper" unselectable="on" contenteditable="false"><div class="'+m+'"><div class="k-row-resize-marker-wrapper"><div class="'+g+'"></div></div></div></div>'}},elementBorderHovered:function(e,t){var i=this.options.handle[w],r=e.offset().top+p(e),o=t.clientY+n(e[0].ownerDocument).scrollTop();return o>r-i&&o<r+i},setResizeHandlePosition:function(t){var i=this.options,r=i.handle[w],o=n(i.rootElement),a=o.is(v)?0:o.scrollTop(),l=o.is(v)?0:e.scrollLeft(o),c=i.rtl?s(o[0]):0,d=t.offset().left-(o.offset().left+parseFloat(o.css("borderLeftWidth")))-parseFloat(t.css("marginLeft")),u=t.offset().top-(o.offset().top+parseFloat(o.css("borderTopWidth")))-parseFloat(t.css("marginTop")),h=e.support.browser;i.rtl&&(h.mozilla||h.webkit&&h.version>=85)&&(l*=-1),this.resizeHandle.css({top:u+p(t)+a-r/2,left:d+(l-c),position:"absolute"})},setResizeHandleDimensions:function(){var e=this,t=n(e.element.tHead||e.element.tBodies[0]);e.resizeHandle.css({width:t.width(),height:e.options.handle[w]})},setResizeHandleDragPosition:function(e){var t=this,i=t.options,r=i.min,o=n(t.element).children(y),a=n(t.element).children(b),s=o.length>0?o:a,c=n(t.resizeHandle),d=n(e.currentTarget).data(i.handle.dataAttribute),u=n(d),h=n(i.rootElement),f=h.is(v)?0:h.scrollTop(),m=s.offset().top-(h.offset().top+parseFloat(h.css("borderTopWidth")))-parseFloat(s.css("marginTop")),g=u.offset().top-(h.offset().top+parseFloat(h.css("borderTopWidth")))-parseFloat(u.css("marginTop")),_=c.offset().top-(Math.max(0,h.offset().top)+parseFloat(h.css("borderTopWidth")))-parseFloat(c.css("marginTop")),k=l({value:_+f+e.y.delta,min:g+f+r,max:m+p(o)+p(a)+f-i.handle[w]-r});c.css({top:k})},resize:function(e){var i=this,r=i.options,o=n(e.currentTarget).data(r.handle.dataAttribute),a=p(n(o)),s=n(i.element),c=p(s),u=s.children(y),f=u.length>0?u.height():0,m=s.children(b).height(),g=o.style[w],v=l({value:a+e.y.initialDelta,min:r.min,max:t(f+m-r.min)});i._setRowsHeightInPixels(),o.style[w]=h(v),i._setTableHeight(c+(v-a)),d(g)&&i._setRowsHeightInPercentages()},_setRowsHeightInPixels:function(){var e,t=n(this.element).children(b+","+y).children(_),i=t.length,r=t.map((function(){return p(n(this))}));for(e=0;e<i;e++)t[e].style[w]=h(r[e])},_setRowsHeightInPercentages:function(){var e,t=this,i=n(t.element).children(y),r=i.length>0?i.height():0,o=n(t.element).children(b).height(),a=n(t.element).children(y+","+b).children(_),s=a.length,l=a.map((function(){return p(n(this))}));for(e=0;e<s;e++)a[e].style[w]=u(c(l[e],r+o))},_setTableHeight:function(e){var t=this.element;d(t.style[w])?t.style[w]=u(c(e,n(t).parent().height())):t.style[w]=h(e)}});k.create=function(e){o.create(e,{name:"rowResizing",type:k,eventNamespace:f})},k.dispose=function(e){o.dispose(e,{eventNamespace:f})},i(r,{RowResizing:k})}(window.kendo),function(e){var t=e.jQuery,n=t.extend,i=t.noop,r=e.ui.editor,o=e.Class,a=e.ui.Draggable,s=e.Observable,l=r.ResizingUtils.getScrollBarWidth,c=e._outerWidth,d=e._outerHeight,u=".kendoEditorElementResizeHandle",h="k-element-resize-handle",p="dragStart",f="drag",m="dragEnd",g="halfInside",v="mouseover",_="mouseout",b="east",y="north",w="northeast",k="northwest",x="south",C="southeast",S="southwest",T="west",D=s.extend({init:function(e){var i=this;s.fn.init.call(i),i.options=n({},i.options,e),i.element=t(i.options.template).appendTo(i.options.appendTo)[0],i._attachEventHandlers(),i._addStyles(),i._initDraggable(),i._initPositioningStrategy(),i._initDraggingStrategy(),t(i.element).data("table",i.options.resizableElement)},destroy:function(){var e=this;t(e.element).off(u).remove(),e.element=null,e._destroyDraggable(),e.unbind()},options:{appendTo:null,direction:C,resizableElement:null,rtl:!1,template:"<div class='k-element-resize-handle-wrapper' unselectable='on' contenteditable='false'><div class='"+h+"'></div></div>"},events:[p,f,m,v,_],show:function(){this._setPosition()},_setPosition:function(){var e=this._positioningStrategy.getPosition();t(this.element).css({top:e.top,left:e.left,position:"absolute"})},_attachEventHandlers:function(){var e=this;t(e.element).on(v+u,e._onMouseOver.bind(e)).on(_+u,e._onMouseOut.bind(e))},_onMouseOver:function(){this.trigger(v)},_onMouseOut:function(){this.trigger(_)},_addStyles:function(){t(this.element).children("."+h).addClass("k-resize-"+this.options.direction)},_initPositioningStrategy:function(){var e=this,t=e.options;e._positioningStrategy=E.create({name:t.direction,handle:e.element,resizableElement:t.resizableElement,rootElement:t.rootElement,rtl:t.rtl})},_initDraggable:function(){var e=this,t=e.element;!e._draggable&&t&&(e._draggable=new a(t,{dragstart:e._onDragStart.bind(e),drag:e._onDrag.bind(e),dragend:e._onDragEnd.bind(e)}))},_onDragStart:function(){this.trigger(p)},_onDrag:function(e){var t=this;t.trigger(f,t._draggingStrategy.adjustDragDelta({deltaX:e.x.delta,deltaY:e.y.delta,initialDeltaX:e.x.initialDelta,initialDeltaY:e.y.initialDelta})),t.options.editor&&t.options.editor._handleSpaceAndNewLines()},_onDragEnd:function(){this.trigger(m)},_destroyDraggable:function(){var e=this;e._draggable&&(e._draggable.destroy(),e._draggable=null)},_initDraggingStrategy:function(){this._draggingStrategy=V.create({name:this.options.direction})}}),A=o.extend({init:function(){this._items=[]},register:function(e,t){this._items.push({name:e,type:t})},create:function(e){var t,n,i,r=this._items,o=r.length,a=e.name?e.name.toLowerCase():"";for(i=0;i<o;i++)if((n=r[i]).name.toLowerCase()===a){t=n;break}if(t)return new t.type(e)}}),M=A.extend({});M.current=new M;var E=o.extend({init:function(e){this.options=n({},this.options,e)},options:{handle:null,offset:g,resizableElement:null,rootElement:null,rtl:!1},getPosition:function(){var e=this,t=e.calculatePosition(),n=e.applyHandleOffset(t);return e.applyScrollOffset(n)},calculatePosition:i,applyHandleOffset:function(e){var n=this.options,i=t(n.handle);return n.offset===g?{top:e.top-d(i)/2,left:e.left-c(i)/2}:e},applyScrollOffset:function(n){var i,r=this.options,o=t(r.rootElement),a=r.rtl?l(o[0]):0,s=e.support.browser;return o.is("body")?n:(i=e.scrollLeft(o)||0,r.rtl&&(s.mozilla||s.webkit&&s.version>=85)&&(i*=-1),{top:n.top+(o.scrollTop()||0),left:n.left+i-a})}});E.create=function(e){return M.current.create(e)};var I=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement),n=e.position(),i=parseInt(e.css("marginLeft"),10);return{top:n.top+d(e)/2,left:n.left+c(e)+i}}});M.current.register(b,I);var z=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement),n=e.position(),i=parseInt(e.css("marginLeft"),10);return{top:n.top,left:n.left+c(e)/2+i}}});M.current.register(y,z);var P=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement),n=e.position(),i=parseInt(e.css("marginLeft"),10);return{top:n.top,left:n.left+c(e)+i}}});M.current.register(w,P);var H=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement),n=e.position(),i=parseInt(e.css("marginLeft"),10);return{top:n.top,left:n.left+i}}});M.current.register(k,H);var F=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement),n=e.position(),i=parseInt(e.css("marginLeft"),10);return{top:n.top+d(e),left:n.left+c(e)/2+i}}});M.current.register(x,F);var R=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement),n=e.position(),i=parseInt(e.css("marginLeft"),10);return{top:n.top+d(e),left:n.left+c(e)+i}}});M.current.register(C,R);var L=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement),n=e.position(),i=parseInt(e.css("marginLeft"),10);return{top:n.top+d(e),left:n.left+i}}});M.current.register(S,L);var B=E.extend({calculatePosition:function(){var e=t(this.options.resizableElement),n=e.position(),i=parseInt(e.css("marginLeft"),10);return{top:n.top+d(e)/2,left:n.left+i}}});M.current.register(T,B);var O=A.extend({});O.current=new O;var V=o.extend({init:function(e){this.options=n({},this.options,e)},options:{deltaX:{adjustment:null,modifier:null},deltaY:{adjustment:null,modifier:null}},adjustDragDelta:function(e){var t=this.options,n=t.deltaX.adjustment*t.deltaX.modifier,i=t.deltaY.adjustment*t.deltaY.modifier;return{deltaX:e.deltaX*n,deltaY:e.deltaY*i,initialDeltaX:e.initialDeltaX*n,initialDeltaY:e.initialDeltaY*i}}});V.create=function(e){return O.current.create(e)};var N=V.extend({options:{deltaX:{adjustment:1,modifier:1},deltaY:{adjustment:0,modifier:0}}}),$=N.extend({options:{deltaX:{modifier:1}}});O.current.register(b,$);var U=N.extend({options:{deltaX:{modifier:-1}}});O.current.register(T,U);var W=V.extend({options:{deltaX:{adjustment:0,modifier:0},deltaY:{adjustment:1,modifier:1}}}),j=W.extend({options:{deltaY:{modifier:-1}}});O.current.register(y,j);var q=W.extend({options:{deltaY:{modifier:1}}});O.current.register(x,q);var G=V.extend({options:{deltaX:{adjustment:1,modifier:1},deltaY:{adjustment:1,modifier:1}}}),K=G.extend({options:{deltaX:{modifier:1},deltaY:{modifier:-1}}});O.current.register(w,K);var Y=G.extend({options:{deltaX:{modifier:-1},deltaY:{modifier:-1}}});O.current.register(k,Y);var Q=G.extend({options:{deltaX:{modifier:1},deltaY:{modifier:1}}});O.current.register(C,Q);var X=G.extend({options:{deltaX:{modifier:-1},deltaY:{modifier:1}}});O.current.register(S,X),n(r,{ElementResizeHandle:D})}(window.kendo),function(e){var t=window.Math,n=t.min,i=t.max,r=e.jQuery,o=r.contains,a=r.extend,s=e.support.browser,l=e.ui.editor,c=e.Class,d=l.ElementResizeHandle,u=l.ResizingUtils,h=u.calculatePercentageRatio,p=u.constrain,f=u.inPercentages,m=u.inPixels,g=u.toPercentages,v=u.toPixels,_=e._outerWidth,b=e._outerHeight,y=l.RangeUtils,w=".kendoEditorElementResizing",k="k-element-resize-handle-wrapper",x="k-element-resizing",C="dragStart",S="drag",T="dragEnd",D="keydown",A="mousedown",M="select",E="tr",I="tbody",z="thead",P="table",H=["TABLE","IMG"],F=",",R="width",L="height";function B(e){return void 0===e}var O=c.extend({init:function(e,t){var n=this;n.options=a({},n.options,t),n.handles=[],H.indexOf(e.nodeName)>=0&&(n.element=e)},destroy:function(){var e=this;r(e.element).off(w),e.element=null,r(e.options.rootElement).off(D+w),e._destroyResizeHandles()},options:{appendHandlesTo:null,rtl:!1,rootElement:null,minWidth:10,minHeight:10,handles:[{direction:"northwest"},{direction:"north"},{direction:"northeast"},{direction:"east"},{direction:"southeast"},{direction:"south"},{direction:"southwest"},{direction:"west"}]},resize:function(e){var t=this,n=a({},{deltaX:0,deltaY:0,initialDeltaX:0,initialDeltaY:0},e);t._resizeWidth(n.deltaX,n.initialDeltaX),t._resizeHeight(n.deltaY,n.initialDeltaY),t.showResizeHandles()},_resizeWidth:function(){return!1},_resizeHeight:function(){return!1},_getMaxDimensionValue:function(t){var n=this,i=r(n.element),o=t.toLowerCase(),a=n.options.rtl?-1:1,s=r(n.element).parent(),l=s[0],c=s[o](),d=a*(t===R?e.scrollLeft(s):s.scrollTop());return l&&l===i.closest("td")[0]?""!==l.style[o]||f(n.element.style[o])?c+d:1/0:c+d},showResizeHandles:function(){this._initResizeHandles(),this._showResizeHandles()},_initResizeHandles:function(){var e,t=this,n=t.handles,i=t.options,r=t.options.handles,o=r.length;if(!(n&&n.length>0)){for(e=0;e<o;e++)t.handles.push(new d(a({appendTo:i.appendHandlesTo,resizableElement:t.element,rootElement:i.rootElement,rtl:i.rtl,editor:t.options.editor},r[e])));t._bindToResizeHandlesEvents()}},_destroyResizeHandles:function(){for(var e=this,t=e.handles?e.handles.length:0,n=0;n<t;n++)e.handles[n].destroy();e.handles=[]},_showResizeHandles:function(){var e,t=(this.handles||[]).length;for(e=0;e<t;e++)this.handles[e].show()},_bindToResizeHandlesEvents:function(){return!1},_onResizeHandleDragStart:function(){var e=this,t=r(e.element);t.addClass(x),e._initialElementHeight=b(t),e._initialElementWidth=_(t),e._disableKeyboard()},_onResizeHandleDrag:function(e){this.resize(e)},_onResizeHandleDragEnd:function(){r(this.element).removeClass(x),this._enableKeyboard()},_enableKeyboard:function(){r(this.options.rootElement).off(D+w)},_disableKeyboard:function(){r(this.options.rootElement).on(D+w,(function(e){e.preventDefault()}))}}),V=O.extend({_bindToResizeHandlesEvents:function(){var e,t,n=this,i=n.handles||[],r=i.length;for(e=0;e<r;e++)(t=i[e]).bind(C,n._onResizeHandleDragStart.bind(n)),t.bind(S,n._onResizeHandleDrag.bind(n)),t.bind(T,n._onResizeHandleDragEnd.bind(n))},_hasRowsInPixels:function(){for(var e=r(this.element).children(z+F+I).children(E),t=0;t<e.length;t++)if(""===e[t].style.height||m(e[t].style.height))return!0;return!1},_resizeWidth:function(e,t){var o,a,s,l,c=this,d=r(c.element),u=d[0].style[R],m=_(d),b=d.parent().width(),y=c._getMaxDimensionValue(R);0!==e&&(B(c._initialElementWidth)&&(c._initialElementWidth=m),l=p({value:c._initialElementWidth+t,min:c.options.minWidth,max:y}),f(u)?(m+e>b?(a=i(l,b),s=n(l,b)):(a=n(l,b),s=i(l,b)),o=g(h(a,s))):o=v(l),c._setColumnsWidth(),d[0].style[R]=o)},_resizeHeight:function(e,t){var o,a,s,l,c=this,d=r(c.element),u=d[0].style[L],m=b(d),_=d.parent().height(),y=c._getMaxDimensionValue(L),w=c.options.minHeight,k=c._hasRowsInPixels();0!==e&&(B(c._initialElementHeight)&&(c._initialElementHeight=m),l=p({value:c._initialElementHeight+t,min:w,max:y}),k&&e<0&&c._setRowsHeightInPercentages(),f(u)?(m+e>_?(a=i(l,_),s=n(l,_)):(a=n(l,_),s=i(l,_)),o=g(h(a,s))):o=v(l),d[0].style[L]=o,k&&e<0&&c._setRowsHeightInPixels())},_setColumnsWidth:function(){var e,t=r(this.element),n=t.parent()[0],i=t.closest("td"),o=i.closest(E).children(),a=o.length;if(function(e){var t=e.style.width;return""!==t?!!f(t):!!r(e).hasClass("k-table")}(t[0])&&n===i[0]&&""===n.style[R])for(e=0;e<a;e++)o[e].style[R]=v(r(o[e]).width())},_setRowsHeightInPercentages:function(){var e,t=this,n=r(t.element).children(z),i=n.length>0?n.height():0,o=r(t.element).children(I).height(),a=r(t.element).children(z+F+I).children(E),s=a.length,l=a.map((function(){return b(r(this))}));for(e=0;e<s;e++)a[e].style[L]=g(h(l[e],i+o))},_setRowsHeightInPixels:function(){var e,t=r(this.element).children(z+F+I).children(E),n=t.length,i=t.map((function(){return b(r(this))}));for(e=0;e<n;e++)t[e].style[L]=v(i[e])}}),N=O.extend({_bindToResizeHandlesEvents:function(){var e,t,n=this,i=n.handles||[],r=i.length;for(e=0;e<r;e++)(t=i[e]).bind(C,n._onResizeHandleDragStart.bind(n)),"north"===t.options.direction||"south"===t.options.direction?t.bind(S,n._onResizeHandleDragVertical.bind(n)):"east"===t.options.direction||"west"===t.options.direction?t.bind(S,n._onResizeHandleDragHorizontal.bind(n)):t.bind(S,n._onResizeHandleDragLocked.bind(n)),t.bind(T,n._onResizeHandleDragEnd.bind(n))},_getDeltas:function(e){return a({},{deltaX:0,deltaY:0,initialDeltaX:0,initialDeltaY:0},e)},_onResizeHandleDragVertical:function(e){var t=this._getDeltas(e);this._resizeHeight(t.deltaY,t.initialDeltaY),this.showResizeHandles()},_onResizeHandleDragHorizontal:function(e){var t=this._getDeltas(e);this._resizeWidth(t.deltaX,t.initialDeltaX),this.showResizeHandles()},_onResizeHandleDragLocked:function(e){var t,n=Math.min(Math.abs(e.initialDeltaX),Math.abs(e.initialDeltaY)),i=this._initialElementWidth,r=this._initialElementHeight;n===e.initialDeltaX||n===-1*e.initialDeltaX?(e.initialDeltaY=e.initialDeltaX*r/i,e.deltaY=e.deltaX):n!==e.initialDeltaY&&n!==-1*e.initialDeltaY||(e.initialDeltaX=e.initialDeltaY*i/r,e.deltaX=e.deltaY),t=this._getDeltas(e),this._resizeWidth(t.deltaX,t.initialDeltaX),this._resizeHeight(t.deltaY,t.initialDeltaY),this.showResizeHandles()},_resizeWidth:function(e,t){var n,i,o=this,a=r(o.element),s=_(a);0!==e&&(B(o._initialElementWidth)&&(o._initialElementWidth=s),i=p({value:o._initialElementWidth+t,min:o.options.minWidth,max:o._getMaxDimensionValue(R)}),n=v(i),a[0].style[R]=n,a.attr(R,Math.floor(i)))},_resizeHeight:function(e,t){var n,i,o=this,a=r(o.element),s=b(a);0!==e&&(B(o._initialElementHeight)&&(o._initialElementHeight=s),i=p({value:o._initialElementHeight+t,min:o.options.minHeight,max:Number.MAX_SAFE_INTEGER}),n=v(i),a[0].style[L]=n,a.attr(L,Math.floor(i)))}});const $=c.extend({create:function(e){let t=this;r(e.body).on("dragstart"+w,(function(){var t=y.nodes(e.getRange()),n=!1;t.forEach((function(e){"IMG"===e.nodeName&&(n=!0)})),n&&t.length>1&&e.elementResizing._destroyResizeHandles()})).on("drop"+w,(function(){setTimeout((function(){var t=y.image(e.getRange());t&&(e.elementResizing._destroyResizeHandles(),e.elementResizing.element=t,e.elementResizing.showResizeHandles())}))})).on(A+w,P+F+"img",(function(n){var i=n.target,r=n.currentTarget,a=e.elementResizing,s=a?a.element:null;if(a){if(s&&r!==s){if(o(r,s)&&s!==i&&o(s,i))return;s!==i&&(e._destroyElementResizing(),t._initResizing(e,r))}}else t._initResizing(e,r);e._showElementResizeHandles()})).on(A+w,(function(t){var n=e.elementResizing,i=n?n.element:null,a=t.target,s=r(a).hasClass(k)||r(a).parents("."+k).length>0;!n||i===a||o(i,a)||s||e._destroyElementResizing()}))},dispose:function(e){r(e.body).off(w)},_initResizing:function(t,n){s.msie||(r(n).is(P)?t.elementResizing=t.tableResizing=new V(n,{appendHandlesTo:t.body,rtl:e.support.isRtl(t.element),rootElement:t.body,editor:t}):r(n).is("img")&&(t.elementResizing=new N(n,{appendHandlesTo:t.body,rtl:e.support.isRtl(t.element),rootElement:t.body,editor:t})),t._showElementResizeHandlesProxy&&(t.unbind(M,t._showElementResizeHandlesProxy),t.bind(M,t._showElementResizeHandlesProxy)))}});$.current=new $,a(l,{TableResizing:V,ImageResizing:N,ElementResizing:O,ElementResizingFactory:$})}(window.kendo),function(e,t){var n=window.kendo,i=n.ui.editor,r=i.EditorUtils,o=i.RangeUtils,a=i.Dom,s=r.registerTool,l=i.Command,c=new i.BlockFormatFinder([{tags:["table"]}]),d=new i.BlockFormatFinder([{tags:["td","th"]}]),u=/([a-z]+|%)$/i,h="scope",p="col-index",f="th",m="td",g=l.extend({exec:function(){var e=this,r=e.editor,o=e.range=e.lockRange(),a=e.options.tableCellWizard,s=e._sourceTable=e.options.insertNewTable?t:e._selectedTable(o),l=e._selectedTableCells=s?e._selectedCells(o):t,c={visible:!1,messages:r.options.messages,closeCallback:e.onDialogClose.bind(e),table:e.parseTable(s,l),dialogOptions:r.options.dialogOptions,isRtl:n.support.isRtl(r.wrapper)};new i.TableWizardDialog(c).open(a)},onDialogClose:function(e){var t=this;t.releaseRange(t.range),e&&(t.options.insertNewTable?t.insertTable(t.createNewTable(e)):t.updateTable(e,t._sourceTable,t._selectedTableCells))},releaseRange:function(e){var t=this.editor.document;a.windowFromDocument(t).focus(),l.fn.releaseRange.call(this,e)},insertTable:function(e){var t=this.range;t.insertNode(e),t.collapse(!0),this.editor.selectRange(t),this._ensureFocusableAfterTable(e)},_ensureFocusableAfterTable:function(t){for(var n=e(t).parent().contents(),i=n.length-1,r=n.get(i);null!==r.nodeValue&&(" "===r.nodeValue||""===r.nodeValue);)i-=1,r=n.get(i);r===t&&a.insertAfter(a.createEmptyNode(this.editor.document,"p"),t)},updateTable:function(t,n,i){for(var r,o,s=this,l=e(n.rows).toArray(),c=t.tableProperties,d=c.rows,u=n.tHead,h=s._lastInCollection;i.length>1;)i.pop();r=i.length?h(i).parentNode:h(l),s._deleteTableRows(l,l.length-d),l.length<d&&s._addRows(r,d,l),a.reMapTableColumns(n,p),s._updateColumns(l,c.columns,i,r),s._updateTableProperties(n,c),o=t.cellProperties,i[0]&&a.attr(i[0],{id:(o||{}).id||null}),o&&(o.selectAllCells?e(l).children():e(i)).each((function(e,t){s._updateCellProperties(t,o,c)})),s._updateCaption(n,c),u?s._updateHeadersWithThead(n,t):s._updateHeadersNoThead(n,t),s._updateHeaderAssociates(n,c),a.clearTableMappings(n,p)},_isHeadingRow:function(e){return a.is(e.cells[0],f)&&a.is(e.parentNode,"thead")},_isHeadingCell:function(e){return a.is(e,f)},cellsWithHeadersAssociated:function(t){var n=e(t.rows).children(),i=[],r=function(e){return i.indexOf(e)>-1};return n.each((function(e,t){t.id&&a.is(t,f)&&i.push(t.id)})),!!n.filter((function(e,t){var n,i=t.getAttribute("headers");return!!(i&&!a.is(t,f)&&(n=i.split(" "))&&n.length>0)&&n.some(r)})).length},_insertCells:function(e,t,n){n=isNaN(n)?-1:n;for(var i=0;i<e;i++)t.insertCell(n).innerHTML="&nbsp;"},_deleteTableRows:function(e,t){for(var n,i,r=0;r<t;r++)(i=(n=e.pop()).parentNode).removeChild(n),i.rows.length||a.remove(i)},createNewTable:function(e){var t,n=this,i=n.editor.document,r=e.tableProperties,o=a.create(i,"table"),s=0;n._updateTableProperties(o,r),n._updateCaption(o,r),r.headerRows&&r.headerRows>0&&(t=o.createTHead(),n._createTableRows(e,t,s,!0),s+=r.headerRows);var l=o.createTBody();return n._createTableRows(e,l,s,!1),a.reMapTableColumns(o,p),"ids"===r.cellsWithHeaders?a.associateWithIds(o):"scope"===r.cellsWithHeaders&&n._addScopes(o,r.headerRows,r.headerColumns),a.clearTableMappings(o,p),o},_createTableRows:function(e,t,n,i){for(var r,o=e.tableProperties,a=e.cellProperties,s=o.columns,l=i?o.headerRows:o.rows,c=o.headerColumns,d=n;d<l;d++){r=t.insertRow();for(var u,h=0;h<s;h++)u=i||c>h?document.createElement(f):document.createElement(m),r.appendChild(u),u.innerHTML="&nbsp;",a&&0===d&&0===h&&a.id&&(u.id=a.id),this._updateCellProperties(u,a&&(a.selectAllCells||0===d&&0===h)?a:{},o)}},_addRows:function(t,n,i){for(var r,o=e(t).index(),a=t.cells.length,s=n-i.length,l=t.parentNode;s;)r=l.insertRow(o+1),this._insertCells(a-r.cells.length,r),s--},_updateColumns:function(t,n,i,r){var o=this,a=o._lastInCollection,s=a(t[0].cells),l=Number(s.getAttribute(p))+s.colSpan;if(l>n&&e(t).each((function(e,t){for(var i=a(t.cells),r=Number(i.getAttribute(p))+i.colSpan;r>n;)i.colSpan&&i.colSpan>1?i.colSpan-=1:t.deleteCell(-1),i=a(t.cells),r=Number(i.getAttribute(p))+i.colSpan})),l<n){var c=e(a(i)||a(r.cells)).index();e(t).each((function(e,t){var i=a(t.cells);o._insertCells(n-Number(i.getAttribute(p))-i.colSpan,t,c+1)}))}},_updateTableProperties:function(t,n){var i=this._getStylesData(n);a.attr(t,{cellSpacing:n.cellSpacing||null,topCellPadding:this._getNumericValue(n.topCellPadding)??"",leftCellPadding:this._getNumericValue(n.leftCellPadding)??"",bottomCellPadding:this._getNumericValue(n.bottomCellPadding)??"",rightCellPadding:this._getNumericValue(n.rightCellPadding)??"",className:n.className||null,id:n.id||null,summary:n.summary||null,style:i||null}),e(t).addClass("k-table")},_updateCellProperties:function(e,t,n){var i=this._getStylesData(t);i.paddingTop=this._getNumericValue(t.topCellPadding)??this._getNumericValue(n?.topCellPadding)??"",i.paddingLeft=this._getNumericValue(t.leftCellPadding)??this._getNumericValue(n?.leftCellPadding)??"",i.paddingBottom=this._getNumericValue(t.bottomCellPadding)??this._getNumericValue(n?.bottomCellPadding)??"",i.paddingRight=this._getNumericValue(t.rightCellPadding)??this._getNumericValue(n?.rightCellPadding)??"",i.margin=t.cellMargin||null,a.attr(e,{style:i||null,className:t.className||null})},_updateCaption:function(e,t){if(e.caption&&!t.captionContent)e.deleteCaption();else if(t.captionContent){var n=e.createCaption();n.innerHTML=t.captionContent;var i=this._getAlignmentData(t.captionAlignment);a.attr(n,{style:{textAlign:i.textAlign,verticalAlign:i.verticalAlign}})}},_updateHeadersNoThead:function(e,t){var n,i,r,o,s=t.tableProperties,l=e.rows;for(r=0;r<l.length;r++)for(n=l[r].cells,o=0;o<n.length;o++)i=n[o],!this._isHeadingCell(i)&&(r<s.headerRows||s.headerColumns>i.getAttribute(p))?a.changeTag(i,f,!1):this._isHeadingCell(i)&&r>=s.headerRows&&s.headerColumns<=i.getAttribute(p)&&a.changeTag(i,m,!1)},_updateHeadersWithThead:function(e,t){var n,i,r,o=this,s=t.tableProperties,l=e.tHead,c=0,d=e.tBodies[0];if(d||(d=e.createTBody()),s.headerRows&&s.headerRows>0){for(l||(l=e.createTHead());l.rows.length<s.headerRows;)l.appendChild(d.rows[0]);for(;l.rows.length>s.headerRows;)d.appendChild(l.rows[0]);o._swapToHeaderCells(l)}else if(l){for(;l.rows.length>0;)d.appendChild(l.rows[l.rows.length-1]);e.deleteTHead()}for(;d.rows.length>c;){for(n=d.rows[c],r=0;r<n.cells.length;r++)i=n.cells[r],o._isHeadingCell(i)&&s.headerColumns<=i.getAttribute(p)?a.changeTag(i,m,!1):!o._isHeadingCell(i)&&s.headerColumns>i.getAttribute(p)&&a.changeTag(i,f,!1);c+=1}},_updateHeaderAssociates:function(e,t){var n=this;"ids"===t.cellsWithHeaders?(n.cellsWithHeadersAssociated(e)||n._removeScopes(e),a.associateWithIds(e)):"scope"===t.cellsWithHeaders?(n.cellsWithHeadersAssociated(e)&&n._removeAssociates(e),n._addScopes(e,t.headerRows,t.headerColumns)):n.cellsWithHeadersAssociated(e)?n._removeAssociates(e):n._removeScopes(e)},_addScopes:function(e,t,n){var i,r,o,a,s=e.rows;for(i=0;i<s.length;i++)for(o=s[i],r=0;r<o.cells.length;r++)a=o.cells[r],i<t?a.setAttribute(h,"col"):a.getAttribute(p)<n&&a.setAttribute(h,"row")},_removeScopes:function(t){e(t).find(f).removeAttr(h),e(t).find("col").remove(),e(t).find("colgroup").remove()},_removeAssociates:function(t){e(t).find("th, td").removeAttr("id headers")},_swapToHeaderCells:function(t){e(t).find("td").each((function(e,t){a.changeTag(t,f,!1)}))},_getStylesData:function(t){var n=this._getAlignmentData(t.alignment),i="wrapText"in t?t.wrapText?"":"nowrap":null;return e.extend({width:t.width?t.width+t.widthUnit:null,height:t.height?t.height+t.heightUnit:null,textAlign:n.textAlign,verticalAlign:n.verticalAlign,backgroundColor:t.bgColor||"",borderWidth:t.borderWidth,borderStyle:t.borderStyle,borderColor:t.borderColor||"",borderCollapse:t.collapseBorders?"collapse":null,whiteSpace:i},this._getTablePositionData(t.position))},_getAlignmentData:function(e){var t="",n=t;if(e)if(-1!=e.indexOf(" ")){var i=e.split(" ");t=i[0],n=i[1]}else t=e;return{textAlign:t,verticalAlign:n}},_getTablePositionData:function(e){return e?{marginLeft:"left"!=e?"auto":"",marginRight:"right"!=e?"auto":""}:{}},parseTable:function(n,i){if(!n)return{tableProperties:{},selectedCells:[]};var r=this,o=n.style,s=n.rows,l=n.caption,c=e(l?l.cloneNode(!0):t);c.find(".k-marker").remove();var d=n.className;d=(d=(d=d.replace(/^k-table\s|\sk-table$/,"")).replace(/\sk-table\s/," ")).replace(/^k-table$/,"");var u,h=r._getAlignment(n,!0),f=r._getTablePosition(n),m=l?r._getAlignment(l):t,g=a._getNumberOfHeaderRows(n);u=r.cellsWithHeadersAssociated(n)?"ids":e(n).find("th[scope]").length>0?"scope":"none",a.reMapTableColumns(n,p);var v=a._getNumberOfColumns(n),_=a._getNumberOfHeaderColumns(n,g);a.clearTableMappings(n,p);var b={tableProperties:{width:o.width||n.width?parseFloat(o.width||n.width):null,height:o.height||n.height?parseFloat(o.height||n.height):null,columns:v,rows:s.length,widthUnit:r._getUnit(o.width),heightUnit:r._getUnit(o.height),cellSpacing:n.cellSpacing,topCellPadding:n.topCellPadding,leftCellPadding:n.leftCellPadding,bottomCellPadding:n.bottomCellPadding,rightCellPadding:n.rightCellPadding,alignment:h.textAlign,position:f,bgColor:o.backgroundColor||n.bgColor,className:d,id:n.id,borderWidth:o.borderWidth||n.border,borderColor:o.borderColor,borderStyle:o.borderStyle||"",collapseBorders:!!o.borderCollapse,summary:n.summary,captionContent:l?c.html():"",captionAlignment:l&&m.textAlign?m.textAlign+" "+m.verticalAlign:"",headerRows:g,headerColumns:_,cellsWithHeaders:u},selectedCells:[]};return b.rows=r.parseTableRows(s,i,b),b},parseTableRows:function(t,n,i){for(var r,o,a,s,l=[],c=0;c<t.length;c++){r={cells:[]},o=t[c].cells,l.push(r);for(var d=0;d<o.length;d++)a=o[d],s=this.parseCell(a),-1!=e.inArray(a,n)&&i.selectedCells.push(s),r.cells.push(s)}return l},parseCell:function(e){var t=this,n=e.style,i=t._getAlignment(e);return i=i.textAlign?i.textAlign+" "+i.verticalAlign:"",{width:n.width||e.width?parseFloat(n.width||e.width):null,height:n.height||e.height?parseFloat(n.height||e.height):null,widthUnit:t._getUnit(n.width),heightUnit:t._getUnit(n.height),cellMargin:n.margin,topCellPadding:n.paddingTop,leftCellPadding:n.paddingLeft,bottomCellPadding:n.paddingBottom,rightCellPadding:n.paddingRight,alignment:i,bgColor:n.backgroundColor||e.bgColor,className:e.className,id:e.id,borderWidth:n.borderWidth||e.border,borderColor:n.borderColor,borderStyle:n.borderStyle,wrapText:"nowrap"!=n.whiteSpace}},_getTablePosition:function(e){var t=e.style;return"auto"==t.marginLeft&&"auto"==t.marginRight?"center":"auto"==t.marginLeft?"right":"left"},_getAlignment:function(e,t){var n=e.style,i=n.textAlign||e.align||"";if(t)return{textAlign:i};var r=n.verticalAlign||e.vAlign||"";return i&&r?{textAlign:i,verticalAlign:r}:!i&&r?{textAlign:"left",verticalAlign:r}:i&&!r?{textAlign:i,verticalAlign:"top"}:{textAlign:"",verticalAlign:""}},_getUnit:function(e){var t=(e||"").match(u);return t?t[0]:"px"},_selectedTable:function(e){var t=a.filterBy(o.nodes(e),a.htmlIndentSpace,!0);return c.findSuitable(t)[0]},_selectedCells:function(e){var t=a.filterBy(o.nodes(e),a.htmlIndentSpace,!0);return d.findSuitable(t)},_lastInCollection:function(e){return e[e.length-1]},_getNumericValue:function(e){return isNaN(e)&&"string"!=typeof e?null:e}}),v=i.Tool.extend({command:function(e){return e.insertNewTable=this.options.insertNewTable,e.tableCellWizard=!!this.options.tableCellWizard,new g(e)}}),_=v.extend({update:function(e,t){var n=!c.isFormatted(t),i=e.closest(".k-toolbar").getKendoToolBar();!0===n?i.hide(e):i.show(e)}}),b=v.extend({update:function(e,t){var n=!c.isFormatted(t),i=e.closest(".k-toolbar").getKendoToolBar();!0===n?i.hide(e):i.show(e)}});n.ui.editor.TableWizardTool=v,n.ui.editor.TableWizardCommand=g,s("tableProperties",new _({command:g,insertNewTable:!1,property:"tableProperties"})),s("tableCellProperties",new b({command:g,tableCellWizard:!0,insertNewTable:!1,property:"tableCellProperties"}))}(window.kendo.jQuery),function(e){const t="k-form-field",n="k-visibility-invisible",i=".";var r=window.kendo,o=r.htmlEncode,a={format:"0",min:0},s=["px","em"],l=["solid","dotted","dashed","double","groove","ridge","inset","outset","initial","inherit","none","hidden"],c={dataSource:[{className:"text-wrap",value:"wrap"},{className:"parameter-string",value:"nowrap"}],dataTextField:"className",dataValueField:"value",template:({className:t,tooltip:n})=>r.ui.icon(e(`<span title="${o(n)}"></span>`),{icon:o(t)})+o(n),valueTemplate:({className:t,tooltip:n})=>r.ui.icon(e(`<span title="${o(n)}"></span>`),{icon:o(t),iconClass:"k-text-wrap"})+o(n)},d={dataSource:[{className:"table-position-start",value:"left"},{className:"table-position-center",value:"center"},{className:"table-position-end",value:"right"}],dataTextField:"className",dataValueField:"value",template:({className:t,tooltip:n})=>r.ui.icon(e(`<span title="${o(n)}"></span>`),{icon:o(t)})+o(n),valueTemplate:({className:t,tooltip:n})=>r.ui.icon(e(`<span title="${o(n)}"></span>`),{icon:o(t),iconClass:"k-align-group"})+o(n)},u={dataSource:[{className:"table-align-middle-left",value:"left"},{className:"table-align-middle-center",value:"center"},{className:"table-align-middle-right",value:"right"},{className:"align-remove",value:""}],dataTextField:"className",dataValueField:"value",template:({className:t,tooltip:n})=>r.ui.icon(e(`<span title="${o(n)}"></span>`),{icon:o(t)})+o(n),valueTemplate:({className:t,tooltip:n})=>r.ui.icon(e(`<span title="${o(n)}"></span>`),{icon:o(t),iconClass:"k-align-group"})+o(n)},h={dataSource:[{className:"table-align-top-left",value:"left top"},{className:"table-align-top-center",value:"center top"},{className:"table-align-top-right",value:"right top"},{className:"table-align-middle-left",value:"left middle"},{className:"table-align-middle-center",value:"center middle"},{className:"table-align-middle-right",value:"right middle"},{className:"table-align-bottom-left",value:"left bottom"},{className:"table-align-bottom-center",value:"center bottom"},{className:"table-align-bottom-right",value:"right bottom"},{className:"align-remove",value:""}],dataTextField:"className",dataValueField:"value",template:({className:t,tooltip:n})=>r.ui.icon(e(`<span title="${o(n)}"></span>`),{icon:o(t)})+o(n),valueTemplate:({className:t,tooltip:n})=>r.ui.icon(e(`<span title="${o(n)}"></span>`),{icon:o(t),iconClass:"k-align-group"})+o(n)},p={dataSource:[{className:"table-align-top-left",value:"left top"},{className:"table-align-top-center",value:"center top"},{className:"table-align-top-right",value:"right top"},{className:"table-align-bottom-left",value:"left bottom"},{className:"table-align-bottom-center",value:"center bottom"},{className:"table-align-bottom-right",value:"right bottom"},{className:"align-remove",value:""}],dataTextField:"className",dataValueField:"value",template:({className:t,tooltip:n})=>r.ui.icon(e(`<span title="${o(n)}"></span>`),{icon:o(t)}),valueTemplate:({className:t,tooltip:n})=>r.ui.icon(e(`<span title="${o(n)}"></span>`),{icon:o(t),iconClass:"k-align-group"})},f=({messages:e})=>`<div class="k-editor-dialog k-editor-table-wizard-window k-action-window k-popup-edit-form"><div id="k-table-wizard-tabs" class="k-root-tabs"><ul><li class="k-active">${e.tableTab}</li><li>${e.accessibilityTab}</li></ul><div id="k-table-properties"></div><div id="k-accessibility-properties"></div></div><div class="k-actions k-actions-start k-actions-horizontal k-window-buttons">`+r.html.renderButton(`<button class="k-dialog-ok"><span class="k-button-text">${e.dialogOk}</span></button>`,{icon:"check",themeColor:"primary"})+r.html.renderButton(`<button class="k-dialog-close"><span class="k-button-text">${e.dialogCancel}</span></button>`,{icon:"cancel-outline"})+"</div></div>",m=({messages:e})=>'<div class="k-editor-dialog k-editor-table-wizard-window k-action-window k-popup-edit-form"><div id="k-cell-properties"></div><div class="k-actions k-actions-start k-actions-horizontal k-window-buttons">'+r.html.renderButton(`<button class="k-dialog-ok"><span class="k-button-text">${e.dialogOk}</span></button>`,{icon:"check",themeColor:"primary"})+r.html.renderButton(`<button class="k-dialog-close"><span class="k-button-text">${e.dialogCancel}</span></button>`,{icon:"cancel-outline"})+"</div></div>",g=r.Class.extend({init:function(e){this.options=e},_openTablePropertiesDialog:function(){var t,n=this,i=n.options,o=i.dialogOptions,a=i.table,s=i.messages,l=r.support.browser.msie;function c(e){e.preventDefault(),n.destroy(),t.destroy()}function d(e){c(e),i.closeCallback()}o.close=d,o.minWidth=700,o.width=700,o.title=s.tableProperties,o.visible=i.visible;var u=(t=e(n._dialogTemplate(s)).appendTo(document.body).kendoWindow(o).addClass("k-editor-window").closest(".k-window").toggleClass("k-rtl",i.isRtl).end().find(".k-dialog-ok").on("click",(function(e){n.collectTableDialogValues(a),c(e),n.change&&n.change(),i.closeCallback(a)})).end().find(".k-dialog-close").on("click",d).end().data("kendoWindow")).element;if(this.components={},n._initTabStripComponent(u),n._tablePropertiesForm=n._createTablePropertiesForm(t,s),n._accessibilityPropertiesForm=n._createAccessibilityPropertiesForm(t,s),t.center(),t.open(),l){var h=u.closest(".k-window").height();u.css("max-height",h)}},_openCellPropertiesDialog:function(){var t,n=this,i=n.options,o=i.dialogOptions,a=i.table,s=i.messages,l=r.support.browser.msie;function c(e){e.preventDefault(),n.destroy(),t.destroy()}function d(e){c(e),i.closeCallback()}o.close=d,o.minWidth=400,o.title=s.tableCellProperties,o.visible=i.visible;var u=(t=e(n._dialogTemplate(s,m)).appendTo(document.body).kendoWindow(o).addClass("k-editor-window").closest(".k-window").toggleClass("k-rtl",i.isRtl).end().find(".k-dialog-ok").on("click",(function(e){n.collectCellDialogValues(a),c(e),n.change&&n.change(),i.closeCallback(a)})).end().find(".k-dialog-close").on("click",d).end().data("kendoWindow")).element;if(n._cellPropertiesForm=n._createCellPropertiesForm(t,s),t.center(),t.open(),l){var h=u.closest(".k-window").height();u.css("max-height",h)}},open:function(e){e?this._openCellPropertiesDialog():this._openTablePropertiesDialog()},_initTabStripComponent:function(e){(this.components={}).tabStrip=e.find("#k-table-wizard-tabs").kendoTabStrip({animation:!1}).data("kendoTabStrip")},collectTableDialogValues:function(){var e=this,t=e.options.table;e._collectTableViewValues(t),e._collectAccessibilityViewValues(t)},collectCellDialogValues:function(){var e=this.options.table;this._collectCellViewValues(e)},_collectTableViewValues:function(e){var t=this.components.tableView,n=e.tableProperties,i=e.cellProperties=e.cellProperties||{};n.width=t.width.value(),n.widthUnit=t.widthUnit.value(),n.height=t.height.value(),n.columns=t.columns.value(),n.rows=t.rows.value(),n.heightUnit=t.heightUnit.value(),n.cellSpacing=t.cellSpacing.value(),n.topCellPadding=t.topCellPadding.value(),n.leftCellPadding=t.leftCellPadding.value(),n.bottomCellPadding=t.bottomCellPadding.value(),n.rightCellPadding=t.rightCellPadding.value(),n.alignment=t.alignment.value(),n.position=t.position.value(),n.bgColor=t.bgColor.value(),n.borderWidth=t.borderWidth.value(),n.borderColor=t.borderColor.value(),n.borderStyle=t.borderStyle.value(),n.collapseBorders=t.collapseBorders.check(),i.width||(i.selectAllCells=!0,i.width=100/e.tableProperties.columns,i.widthUnit="%")},_collectCellViewValues:function(e){var t=e.cellProperties=e.cellProperties||{},n=this.components.cellView;t.selectAllCells=n.selectAllCells.check(),t.width=n.width.value(),t.widthUnit=n.widthUnit.value(),t.height=n.height.value(),t.heightUnit=n.heightUnit.value(),t.independentCellPaddings=n.independentCellPaddings.check(),t.topCellPadding=n.topCellPadding.value(),t.leftCellPadding=n.leftCellPadding.value(),t.bottomCellPadding=n.bottomCellPadding.value(),t.rightCellPadding=n.rightCellPadding.value(),t.cellMargin=n.cellMargin.value(),t.alignment=n.alignment.value(),t.bgColor=n.bgColor.value(),t.className=n.className.value(),t.id=n.id.value(),t.borderWidth=n.borderWidth.value(),t.borderColor=n.borderColor.value(),t.borderStyle=n.borderStyle.value(),t.wrapText="wrap"==n.wrapTextValue.value(),t.width||(t.selectAllCells=!0,t.width=100/e.tableProperties.columns,t.widthUnit="%")},_collectAccessibilityViewValues:function(e){var t=e.tableProperties,n=this.components.accessibilityView;t.captionContent=n.captionContent.value(),t.captionAlignment=n.captionAlignment.value(),t.summary=n.summary.value(),t.cellsWithHeaders=n.cellsWithHeaders.value(),t.className=n.className.value(),t.id=n.id.value(),t.headerRows=n.headerRows.value(),t.headerColumns=n.headerColumns.value()},_addUnit:function(t,n){n&&-1==e.inArray(n,t)&&t.push(n)},_initNumericTextbox:function(t,n,i,r,o){var s=r[n]=t.kendoNumericTextBox(o?e.extend({},a,o):a).data("kendoNumericTextBox");n in i&&s.value(parseInt(i[n],10))},_initDropDownList:function(e,t,n,i,r){var o=i[t]=e.kendoDropDownList({dataSource:r}).data("kendoDropDownList");this._setComponentValue(o,n,t)},_initBorderStyleDropDown:function(e,t,n,i,r){var o=i[t]=e.kendoDropDownList({dataSource:r,optionLabel:this.options.messages.borderNone}).data("kendoDropDownList");this._setComponentValue(o,n,t)},_initTablePositionDropDown:function(e,t){var n=this.options.messages,i=this.components.tableView,r=d.dataSource;r[0].tooltip=n.tableAlignLeft,r[1].tooltip=n.tableAlignCenter,r[2].tooltip=n.tableAlignRight,this._initPositionDropDown(e,d,"position",t,i)},_initTableAlignmentDropDown:function(e,t){var n=this.options.messages,i=this.components.tableView,r=u.dataSource;r[0].tooltip=n.alignLeft,r[1].tooltip=n.alignCenter,r[2].tooltip=n.alignRight,r[3].tooltip=n.alignRemove,this._initAlignmentDropDown(e,u,"alignment",t,i)},_initCellAlignmentDropDown:function(e,t){var n=this.options.messages,i=this.components.cellView,r=h.dataSource;r[0].tooltip=n.alignLeftTop,r[1].tooltip=n.alignCenterTop,r[2].tooltip=n.alignRightTop,r[3].tooltip=n.alignLeftMiddle,r[4].tooltip=n.alignCenterMiddle,r[5].tooltip=n.alignRightMiddle,r[6].tooltip=n.alignLeftBottom,r[7].tooltip=n.alignCenterBottom,r[8].tooltip=n.alignRightBottom,r[9].tooltip=n.alignRemove,this._initAlignmentDropDown(e,h,"alignment",t,i)},_initAccessibilityAlignmentDropDown:function(e,t){var n=this.options.messages,i=this.components.accessibilityView,r=p.dataSource;r[0].tooltip=n.alignLeftTop,r[1].tooltip=n.alignCenterTop,r[2].tooltip=n.alignRightTop,r[3].tooltip=n.alignLeftBottom,r[4].tooltip=n.alignCenterBottom,r[5].tooltip=n.alignRightBottom,r[6].tooltip=n.alignRemove,this._initAlignmentDropDown(e,p,"captionAlignment",t,i)},_initTextWrapDropDown:function(e,t){var n=this.options.messages,i="wrapTextValue";t.wrapTextValue=t.wrapText?"wrap":"nowrap";var r=this.components.cellView,o=c.dataSource;o[0].tooltip=n.wrapText,o[1].tooltip=n.fitToCell;var a=r[i]=e.kendoDropDownList(c).data("kendoDropDownList");a.list.addClass("k-text-wrap"),this._setComponentValue(a,t,i)},_initPositionDropDown:function(e,t,n,i,r){var o=r[n]=e.kendoDropDownList(t).data("kendoDropDownList");o.list.addClass("k-position"),this._setComponentValue(o,i,n)},_initAlignmentDropDown:function(e,t,n,i,r){var o=r[n]=e.kendoDropDownList(t).data("kendoDropDownList");o.list.addClass("k-align"),this._setComponentValue(o,i,n)},_initAssociationDropDown:function(e,t,n,i,r){var o=r[t]=e.kendoDropDownList(n).data("kendoDropDownList");this._setComponentValue(o,i,t)},_setComponentValue:function(e,t,n){n in t&&e.value(t[n])},_initColorPicker:function(e,t,n,i){var r=i[t]=e.kendoColorPicker({buttons:!1,clearButton:!0}).data("kendoColorPicker");n[t]&&r.value(n[t])},_initInput:function(e,t,n,i,r){var o=i[t]=e.kendoTextBox(r||{}).data("kendoTextBox");t in n&&o.value(n[t])},_initCheckbox:function(e,t,n,i,r){var o=i[t]=e.kendoCheckBox(r||{}).data("kendoCheckBox");t in n&&o.check(n[t])},_initTextArea:function(e,t,n,i,r){var o=i[t]=e.kendoTextArea(r||{}).data("kendoTextArea");t in n&&o.value(n[t])},destroy:function(){this._destroyComponents(this.components),delete this.components},_destroyComponents:function(e){for(var t in e)e[t].destroy&&e[t].destroy(),delete e[t]},_dialogTemplate:function(e,t){return r.template(t||f)({messages:e})},_onPaddingTopChange:function(e){let t=this.components.tableView?"tableView":"cellView",n=this.components[t],i=!n.independentCellPaddings.check(),r=n.topCellPadding,o=r.value(),a=n.leftCellPadding,s=n.bottomCellPadding,l=n.rightCellPadding;i&&(a.value(o),s.value(o),l.value(o)),r._cachedPadding=o},_onPaddingCheckChange:function(e){let r=this.components.tableView?"tableView":"cellView",o=this.options.messages,a=e.sender.check(),s=this.components[r],l=s.topCellPadding,c=s.leftCellPadding,d=s.bottomCellPadding,u=s.rightCellPadding,h=l.value(),p=d.value(),f=c.value(),m=u.value();a?(isNaN(l._cachedPadding)||l.value(l._cachedPadding),c.wrapper.closest(i+t).removeClass(n),d.wrapper.closest(i+t).removeClass(n),u.wrapper.closest(i+t).removeClass(n),l.wrapper.closest(i+t).find(".k-form-label").text(o.topPadding)):(h===p&&h===f&&h===m?(c.value(h),d.value(h),u.value(h)):l.value(null),c.wrapper.closest(i+t).addClass(n),d.wrapper.closest(i+t).addClass(n),u.wrapper.closest(i+t).addClass(n),l.wrapper.closest(i+t).find(".k-form-label").text(o.cellPadding))},_onColumnsNumberChange:function(e){var t=this.components.accessibilityView.headerColumns,n=t.value(),i=e.sender.value();i<n&&t.value(i),t.max(i)},_onRowsNumberChange:function(e){var t=this.components.accessibilityView.headerRows,n=t.value(),i=e.sender.value();i<n&&t.value(i),t.max(i)},_createTablePropertiesForm:function(t,n){var i,r=this,a=r.options.table,c=t.element.find("#k-table-properties"),d=r.components.tableView={},u=a.tableProperties=a.tableProperties||{};return r._addUnit(s,u.widthUnit),r._addUnit(s,u.heightUnit),u.borderStyle=u.borderStyle||"",(i=c.kendoForm({renderButtons:!1,layout:"grid",grid:{cols:4},items:[{colSpan:2,field:"k-editor-table-columns",label:o(n.columns),editor:function(t,n){r._initNumericTextbox(e('<input type="numeric" id="k-editor-table-columns" />').appendTo(t),"columns",u,d,{min:1,value:4,change:r._onColumnsNumberChange.bind(r)})}},{colSpan:2,field:"k-editor-table-rows",label:o(n.rows),editor:function(t,n){r._initNumericTextbox(e('<input type="numeric" id="k-editor-table-rows" />').appendTo(t),"rows",u,d,{min:1,value:4,change:r._onRowsNumberChange.bind(r)})}},{colSpan:1,field:"k-editor-table-width",label:o(n.width),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-width" />').appendTo(t),"width",u,d,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-width-type",label:{encoded:!1,text:"&nbsp;"},editor:function(t,i){r._initDropDownList(e(`<input id="k-editor-table-width-type" aria-label="${n.units}" />`).appendTo(t),"widthUnit",u,d,s)}},{colSpan:1,field:"k-editor-table-height",label:o(n.height),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-height" />').appendTo(t),"height",u,d,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-height-type",label:{encoded:!1,text:"&nbsp;"},editor:function(t,i){r._initDropDownList(e(`<input id="k-editor-table-height-type" aria-label="${n.units}" />`).appendTo(t),"heightUnit",u,d,s)}},{colSpan:2,field:"k-editor-table-position",label:o(n.position),editor:function(t,n){r._initTablePositionDropDown(e('<input id="k-editor-table-position" class="k-position" />').appendTo(t),u)}},{colSpan:2,field:"k-editor-table-alignment",label:o(n.alignment),editor:function(t,n){r._initTableAlignmentDropDown(e('<input id="k-editor-table-alignment" class="k-align" />').appendTo(t),u)}},{colSpan:2,field:"k-editor-table-cell-spacing",label:o(n.cellSpacing),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-cell-spacing" />').appendTo(t),"cellSpacing",u,d,{placeholder:o(n.auto)})}},{type:"group",label:"Cell Paddings",layout:"grid",colSpan:4,grid:{cols:4,gutter:20},items:[{colSpan:"full",field:"k-editor-padding-all-sides",label:"",editor:function(t,i){r._initCheckbox(e('<input id="k-editor-padding-all-sides" />').appendTo(t),"independentCellPaddings",u,d,{checked:!0,label:o(n.independentCellPaddings),change:r._onPaddingCheckChange.bind(r)})}},{colSpan:1,field:"k-editor-table-cell-padding-top",label:o(n.topPadding),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-cell-padding-top" />').appendTo(t),"topCellPadding",u,d,{placeholder:o(n.auto),change:r._onPaddingTopChange.bind(r)})}},{colSpan:1,field:"k-editor-table-cell-padding-right",label:o(n.rightPadding),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-cell-padding-right" />').appendTo(t),"rightCellPadding",u,d,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-cells-padding-bottom",label:o(n.bottomPadding),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-cell-padding-bottom" />').appendTo(t),"bottomCellPadding",u,d,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-cell-padding-left",label:o(n.leftPadding),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-cell-padding-left" />').appendTo(t),"leftCellPadding",u,d,{placeholder:o(n.auto)})}}]},{type:"group",label:"Borders",layout:"grid",colSpan:4,grid:{cols:4,gutter:10},items:[{colSpan:"full",field:"k-editor-table-bg",label:o(n.tableBackground),editor:function(t,n){r._initColorPicker(e('<input id="k-editor-table-bg" />').appendTo(t),"bgColor",u,d)}},{colSpan:1,field:"k-editor-border-width",label:o(n.borderWidth),editor:function(t,n){r._initNumericTextbox(e('<input id="k-editor-border-width" />').appendTo(t),"borderWidth",u,d)}},{colSpan:1,field:"k-editor-border-color",label:o(n.borderColor),editor:function(t,n){r._initColorPicker(e('<input id="k-editor-border-color" />').appendTo(t),"borderColor",u,d)}},{colSpan:2,field:"k-editor-border-style",label:o(n.borderStyle),editor:function(t,n){r._initBorderStyleDropDown(e('<input id="k-editor-border-style" />').appendTo(t),"borderStyle",u,d,l)}},{colSpan:"full",field:"k-editor-collapse-borders",label:"",editor:function(t,i){r._initCheckbox(e('<input id="k-editor-collapse-borders"/>').appendTo(t),"collapseBorders",u,d,{label:o(n.collapseBorders)})}}]}]}).data("kendoForm")).layoutWrapper.addClass("k-gap-x-4"),i},_createCellPropertiesForm:function(t,n){var i,r=this,a=r.options.table,c=t.element.find("#k-cell-properties"),d=(r.components=r.components||{}).cellView={},u=a.selectedCells&&a.selectedCells[0]||{borderStyle:"",wrapText:!0};return r._addUnit(s,u.widthUnit),r._addUnit(s,u.heightUnit),(i=c.kendoForm({renderButtons:!1,layout:"grid",grid:{cols:4},items:[{colSpan:"full",field:"k-editor-selectAllCells",label:"",editor:function(t,i){r._initCheckbox(e('<input id="k-editor-selectAllCells" />').appendTo(t),"selectAllCells",a.tableProperties,d,{label:o(n.selectAllCells)})}},{colSpan:1,field:"k-editor-cell-width",label:o(n.width),hint:o(n.applyToColumn),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-cell-width" />').appendTo(t),"width",u,d,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-cell-width-type",label:{encoded:!1,text:"&nbsp;"},editor:function(t,i){r._initDropDownList(e(`<input id="k-editor-cell-width-type" aria-label="${n.units}" />`).appendTo(t),"widthUnit",u,d,s)}},{colSpan:1,field:"k-editor-cell-height",label:o(n.height),hint:o(n.applyToRow),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-cell-height" />').appendTo(t),"height",u,d,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-cell-height-type",label:{encoded:!1,text:"&nbsp;"},editor:function(t,i){r._initDropDownList(e(`<input id="k-editor-cell-height-type" aria-label="${n.units}" />`).appendTo(t),"heightUnit",u,d,s)}},{colSpan:2,field:"k-editor-cell-alignment",label:o(n.alignment),editor:function(t,n){r._initCellAlignmentDropDown(e('<input id="k-editor-cell-alignment" class="k-align" />').appendTo(t),u)}},{colSpan:2,field:"k-editor-wrap-text",label:"Text control",editor:function(t,n){r._initTextWrapDropDown(e('<input id="k-editor-wrap-text" />').appendTo(t),u)}},{colSpan:"full",field:"k-editor-cell-bg",label:o(n.background),editor:function(t,n){r._initColorPicker(e('<input id="k-editor-cell-bg" />').appendTo(t),"bgColor",u,d)}},{colSpan:2,field:"k-editor-table-cell-margin",label:o(n.cellMargin),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-cell-margin" />').appendTo(t),"cellMargin",u,d,{placeholder:o(n.auto)})}},{type:"group",label:"Cell Paddings",layout:"grid",colSpan:4,grid:{cols:4,gutter:20},items:[{colSpan:"full",field:"k-editor-padding-all-sides",label:"",editor:function(t,i){r._initCheckbox(e('<input id="k-editor-padding-all-sides" />').appendTo(t),"independentCellPaddings",a.tableProperties,d,{checked:!0,label:o(n.independentCellPaddings),change:r._onPaddingCheckChange.bind(r)})}},{colSpan:1,field:"k-editor-table-cells-padding-top",label:o(n.topPadding),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-cells-padding-top" />').appendTo(t),"topCellPadding",u,d,{placeholder:o(n.auto),change:r._onPaddingTopChange.bind(r)})}},{colSpan:1,field:"k-editor-table-cells-padding-right",label:o(n.rightPadding),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-cells-padding-right" />').appendTo(t),"rightCellPadding",u,d,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-cells-padding-bottom",label:o(n.bottomPadding),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-cells-padding-bottom" />').appendTo(t),"bottomCellPadding",u,d,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-table-cells-padding-left",label:o(n.leftPadding),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-table-cells-padding-left" />').appendTo(t),"leftCellPadding",u,d,{placeholder:o(n.auto)})}}]},{type:"group",label:"Borders",layout:"grid",colSpan:4,grid:{cols:4,gutter:10},items:[{colSpan:1,field:"k-editor-cell-border-width",label:o(n.borderWidth),editor:function(t,i){r._initNumericTextbox(e('<input id="k-editor-cell-border-width" />').appendTo(t),"borderWidth",u,d,{placeholder:o(n.auto)})}},{colSpan:1,field:"k-editor-cell-border-color",label:o(n.borderColor),editor:function(t,i){r._initColorPicker(e('<input id="k-editor-cell-border-color" />').appendTo(t),"borderColor",u,d,{placeholder:o(n.auto)})}},{colSpan:2,field:"k-editor-cell-border-style",label:o(n.borderStyle),editor:function(t,n){r._initBorderStyleDropDown(e('<input id="k-editor-cell-border-style" />').appendTo(t),"borderStyle",u,d,l)}}]},{colSpan:"full",field:"k-editor-cell-id",label:{text:o(n.id),optional:!0},editor:function(t,n){r._initInput(e('<input id="k-editor-cell-id" />').appendTo(t),"id",u,d)}},{colSpan:"full",field:"k-editor-cell-css-class",label:{text:o(n.cssClass),optional:!0},editor:function(t,n){r._initInput(e('<input id="k-editor-cell-css-class" />').appendTo(t),"className",u,d)}}]}).data("kendoForm")).layoutWrapper.addClass("k-gap-x-4"),i},_createAccessibilityPropertiesForm:function(t,n){var i,r=this,a=r.options.table,s=t.element.find("#k-accessibility-properties"),l=r.components.accessibilityView={},c=a.tableProperties;return i=s.kendoForm({renderButtons:!1,layout:"grid",grid:{cols:4},items:[{colSpan:"full",field:"k-editor-id",label:{text:o(n.id),optional:!0},editor:function(t,n){r._initInput(e('<input id="k-editor-id" />').appendTo(t),"id",c,l)}},{colSpan:"full",field:"k-editor-css-class",label:{text:o(n.cssClass),optional:!0},editor:function(t,n){r._initInput(e('<input id="k-editor-css-class" />').appendTo(t),"className",c,l)}},{layout:"grid",grid:{cols:4,gutter:16},colSpan:"full",type:"group",label:"Accessibility",items:[{colSpan:2,field:"k-editor-table-caption",label:{text:o(n.caption),optional:!0},editor:function(t,n){r._initInput(e('<input id="k-editor-table-caption" />').appendTo(t),"captionContent",c,l)}},{colSpan:2,field:"k-editor-accessibility-alignment",label:o(n.captionAlignment),editor:function(t,n){r._initAccessibilityAlignmentDropDown(e('<input id="k-editor-accessibility-alignment" />').appendTo(t),c)}},{colSpan:1,field:"k-editor-table-header-rows",label:o(n.headerRows),editor:function(t,n){r._initNumericTextbox(e('<input id="k-editor-table-header-rows" />').appendTo(t),"headerRows",c,l,{max:c.rows||4})}},{colSpan:1,field:"k-editor-table-header-columns",label:o(n.headerColumns),editor:function(t,n){r._initNumericTextbox(e('<input id="k-editor-table-header-columns" />').appendTo(t),"headerColumns",c,l,{max:c.columns||4})}},{colSpan:2,field:"k-editor-cells-headers",label:o(n.associateCellsWithHeaders),editor:function(t,i){var o=e(`<select id="k-editor-cells-headers">\n                                    <option value="none">${n.associateNone}</option>\n                                    <option value="scope">${n.associateScope}</option>\n                                    <option value="ids">${n.associateIds}</option>\n                                </select>`).appendTo(t);r._initAssociationDropDown(o,"cellsWithHeaders",{valuePrimitive:!0},c,l)}},{colSpan:"full",field:"k-editor-accessibility-summary",label:{text:o(n.summary),optional:!0},editor:function(t,i){r._initTextArea(e('<textarea id="k-editor-accessibility-summary"></textarea>').appendTo(t),"summary",c,l,{rows:5,placeholder:n.tableSummaryPlaceholder})}}]}]}).data("kendoForm"),i.layoutWrapper.addClass("k-gap-x-4"),i}});r.ui.editor.TableWizardDialog=g}(window.kendo.jQuery);kendo;!function(e,t){var n=window,i=n.Math.min,r=n.kendo,o=r.caret,a=r.keys,s=r.ui,l=s.Widget,c=".kendoMaskedTextBox",d=e.isPlainObject,u=window.setTimeout,h="k-disabled",p="k-invalid",f="k-focus",m="disabled",g="readonly",v="change",_="mouseup",b="drop",y="keydown",w="paste";function k(e){return e+c}var x=k(r.support.propertyChangeEvent?"propertychange":"input");var C=l.extend({init:function(t,n){var i,a=this;l.fn.init.call(a,t,n),a._rules=e.extend({},a.rules,a.options.rules),t=a.element,i=t[0],a._wrapper(),a._tokenize(),a._form(),a.element.addClass("k-input-inner").attr("autocomplete","off").on("focus"+c,(function(){var e=i.value;e?a._togglePrompt(!0):i.value=a._old=a._emptyMask,a._oldValue=e,a.wrapper.addClass(f),a._timeoutId=u((function(){o(t,0,e?a._maskLength:0)}))})).on("focusout"+c,(function(){var e=t.val();clearTimeout(a._timeoutId),i.value=a._old="",e!==a._emptyMask&&(i.value=a._old=e),a.wrapper.removeClass(f),a._change(),a._togglePrompt()})),a.options.mask&&a.options.mask.length>0&&a.element.attr("aria-placeholder",a.options.mask),t.is("[disabled]")||e(a.element).parents("fieldset").is(":disabled")?a.enable(!1):a.readonly(t.is("[readonly]")),a._validationIcon=e(r.ui.icon({icon:"exclamation-circle",iconClass:"k-input-validation-icon k-hidden"})).insertAfter(t),a.value(a.options.value||t.val()),a._label(),a._applyCssClasses(),Tf({widget:a,wrapper:a.wrapper,options:a.options,suffixInsertAfter:a._validationIcon}),a.floatingLabel&&a.floatingLabel.refresh(),r.notify(a)},options:{name:"MaskedTextBox",clearPromptChar:!1,unmaskOnPost:!1,promptChar:"_",culture:"",rules:{},value:"",mask:"",label:null,size:"medium",fillMode:"solid",rounded:"medium",prefixOptions:{separator:!0},suffixOptions:{separator:!0}},events:[v],rules:{0:/\d/,9:/\d|\s/,"#":/\d|\s|\+|\-/,L:/[a-zA-Z]/,"?":/[a-zA-Z]|\s/,"&":/\S/,C:/./,A:/[a-zA-Z0-9]/,a:/[a-zA-Z0-9]|\s/},setOptions:function(t){var n=this;l.fn.setOptions.call(n,t),n._rules=e.extend({},n.rules,n.options.rules),n._tokenize(),this._unbindInput(),this._bindInput(),n.value(n.element.val())},destroy:function(){var e=this;e.floatingLabel&&e.floatingLabel.destroy(),e.element.off(c),e._formElement&&(e._formElement.off("reset",e._resetHandler),e._formElement.off("submit",e._submitHandler)),l.fn.destroy.call(e)},raw:function(){return this._unmask(this.element.val(),0).replace(new RegExp(S(this.options.promptChar),"g"),"")},value:function(e){var n=this.element,i=this._emptyMask;return e===t?this.element.val():(null===e&&(e=""),i?(e=this._unmask(e+""),n.val(e?i:""),this._mask(0,this._maskLength,e),this._unmaskedValue=null,e=n.val(),this._oldValue=e,r._activeElement()!==n&&(e===i?n.val(""):this._togglePrompt()),void(this.floatingLabel&&this.floatingLabel.refresh())):(this._oldValue=e,void n.val(e)))},_togglePrompt:function(e){var t=this.element[0],n=t.value;this.options.clearPromptChar&&(n=e?this._oldValue:n.replace(new RegExp(S(this.options.promptChar),"g")," "),t.value=this._old=n)},readonly:function(e){this._editable({readonly:e===t||e,disable:!1}),this.floatingLabel&&this.floatingLabel.readonly(e===t||e)},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)}),this.floatingLabel&&this.floatingLabel.enable(e=e===t||e)},_bindInput:function(){var e=this;if(e._maskLength&&(e.element.on(k(y),e._keydown.bind(e)).on(k(b),e._drop.bind(e)).on(k(v),e._trackChange.bind(e)).on(x,e._inputHandler.bind(e)),r.support.browser.msie)){var t=r.support.browser.version;if(t>8&&t<11){var n=[k(_),k(b),k(y),k(w)].join(" ");e.element.on(n,e._legacyIEInputHandler.bind(e))}}},_unbindInput:function(){var e=[x,k(y),k(_),k(b),k(w)].join(" ");this.element.off(e)},_editable:function(e){var t=this,n=t.element,i=t.wrapper,r=e.disable,o=e.readonly;t._unbindInput(),o||r?(n.attr(m,r).attr(g,o),i.toggleClass(h,r)):(n.prop(m,!1).prop(g,!1),i.removeClass(h),t._bindInput())},_change:function(){var e=this,t=e.value();t!==e._oldValue?(e._oldValue=t,e.trigger(v),e.element.trigger(v)):""===t&&e.__changing&&e.element.trigger(v)},inputChange:function(e){var t=this,n=t._old,a=t.element[0],s=a.value,l=o(a)[1],c=s.length-n.length,d=r.support.mobileOS;if(!(t.__dropping&&c<0)){-1===c&&d.android&&"chrome"===d.browser&&(e=!0);var u=i(l,function(e,t){for(var n=0;n<t.length&&e[n]===t[n];)n++;return n}(s,n)),h=s.substring(u,l);a.value=s.substring(0,u)+t._emptyMask.substring(u);var p=t._mask(u,l,h),f=t._trimStartPromptChars(s.substring(l),i(c,p-u)),m=t._unmask(f,n.length-f.length);t._mask(p,p,m),e&&(p=t._findCaretPosBackwards(u)),o(a,p),t.__dropping=!1}},_trimStartPromptChars:function(e,t){for(var n=this.options.promptChar;t-- >0&&0===e.indexOf(n);)e=e.substring(1);return e},_findCaretPosBackwards:function(e){var t=this._find(e,!0);return t<e&&(t+=1),t},_inputHandler:function(){r._activeElement()===this.element[0]&&this.inputChange(this.__backward)},_legacyIEInputHandler:function(e){var t=this,n=t.element[0],i=n.value,r=e.type;t.__pasting="paste"===r,u((function(){"mouseup"===r&&t.__pasting||n.value&&n.value!==i&&t.inputChange(t.__backward)}))},_trackChange:function(){var e=this;e.__changing=!0,u((function(){e.__changing=!1}))},_form:function(){var t=this,n=t.element,i=n.attr("form"),r=i?e("#"+i):n.closest("form");r[0]&&(t._resetHandler=function(){u((function(){t.value(n[0].value)}))},t._submitHandler=function(){t.element[0].value=t._old=t.raw()},t.options.unmaskOnPost&&r.on("submit",t._submitHandler),t._formElement=r.on("reset",t._resetHandler))},_keydown:function(e){var t=e.keyCode;this.__backward=t===a.BACKSPACE,t===a.ENTER&&this._change()},_drop:function(){this.__dropping=!0},_find:function(e,t){var n=this.element.val()||this._emptyMask,i=1;for(!0===t&&(i=-1);e>-1||e<=this._maskLength;){if(n.charAt(e)!==this.tokens[e])return e;e+=i}return-1},_mask:function(e,n,i,a){var s,l,c,d,u=this.element[0],h=u.value||this._emptyMask,p=this.options.promptChar,f=0;for((e=this._find(e,a))>n&&(n=e),l=this._unmask(h.substring(n),n),s=(i=this._unmask(i,e)).length,i&&(l=l.replace(new RegExp("^_{0,"+s+"}"),"")),i+=l,h=h.split(""),c=i.charAt(f);e<this._maskLength;)h[e]=c||p,c=i.charAt(++f),d===t&&f>s&&(d=e),e=this._find(e+1);return u.value=this._old=h.join(""),r._activeElement()===u&&(d===t&&(d=this._maskLength),o(u,d)),d},_unmask:function(e,t){if(!e)return"";if(this._unmaskedValue===e)return this._unmaskedValue;var n,i;e=(e+"").split("");for(var o=0,a=t||0,s=this.options.promptChar,l=e.length,c=this.tokens.length,d="";a<c&&((n=e[o])===(i=this.tokens[a])||n===s?(d+=n===s?s:"",o+=1,a+=1):"string"!=typeof i?(i&&i.test&&i.test(n)||r.isFunction(i)&&i(n)?(d+=n,a+=1):1===l&&this._blinkInvalidState(),o+=1):a+=1,!(o>=l)););return this._unmaskedValue=d,d},_label:function(){var t,n,i=this,o=i.element,a=i.options,s=o.attr("id");null!==a.label&&(t=!!d(a.label)&&a.label.floating,n=d(a.label)?a.label.content:a.label,t&&(i._floatingLabelContainer=i.wrapper.wrap("<span></span>").parent(),i.floatingLabel=new r.ui.FloatingLabel(i._floatingLabelContainer,{widget:i})),r.isFunction(n)&&(n=n.call(i)),n||(n=""),s||(s=a.name+"_"+r.guid(),o.attr("id",s)),i._inputLabel=e("<label class='"+(t?"k-floating-label":"k-label k-input-label")+"' for='"+s+"'>"+n+"</label>'")[t?"insertAfter":"insertBefore"](i.wrapper))},_wrapper:function(){var e=this.element,t=e[0],n=e.wrap("<span class='k-input k-maskedtextbox'></span>").parent();n[0].style.cssText=t.style.cssText,t.style.width="100%",this.wrapper=n.addClass(t.className).removeClass("input-validation-error")},_blinkInvalidState:function(){var e=this;e._addInvalidState(),clearTimeout(e._invalidStateTimeout),e._invalidStateTimeout=u(e._removeInvalidState.bind(e),100)},_addInvalidState:function(){this.wrapper.addClass(p),this._validationIcon.removeClass("k-hidden")},_removeInvalidState:function(){var e=this;e.wrapper.removeClass(p),e._validationIcon.addClass("k-hidden"),e._invalidStateTimeout=null},_tokenize:function(){for(var e,t,n=[],i=0,o=(this.options.mask||"").split(""),a=o.length,s=0,l="",c=this.options.promptChar,d=r.getCulture(this.options.culture).numberFormat,u=this._rules;s<a;){if(t=u[e=o[s]])n[i]=t,l+=c,i+=1;else{"."===e||","===e?e=d[e]:"$"===e?e=d.currency.symbol:"\\"===e&&(e=o[s+=1]);for(var h=0,p=(e=e.split("")).length;h<p;h++)n[i]=e[h],l+=e[h],i+=1}s++}this.tokens=n,this._emptyMask=l,this._maskLength=l.length}});function S(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}r.cssProperties.registerPrefix("MaskedTextBox","k-input-"),r.cssProperties.registerValues("MaskedTextBox",[{prop:"rounded",values:r.cssProperties.roundedValues.concat([["full","full"]])}]),s.plugin(C)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n="end",i="pause",r="play",o="ready",a="timeChange",s="volumeChange",l="fullscreen",c="fullscreen-exit",d="volume-mute",u="volume-down",h="volume-up",p="k-mediaplayer-quality",f="play",m="pause",g="k-mediaplayer-titlebar",v="k-mediaplayer-toolbar",_="k-mediaplayer-seekbar",b="k-mediaplayer-volume",y="k-mediaplayer-media",w="k-mediaplayer-overlay",k="k-mediaplayer-yt",x=".",C='span[class*="i-play"]',S='span[class*="i-'+l+'"]',T='span[class*="i-'+c+'"]',D='span[class*="i-'+d+'"]',A='span[class*="i-'+u+'"]',M='span[class*="i-'+h+'"]',E=".k-draghandle.k-selected",I=t.ui,z=".kendoMediaPlayer",P=new Date(1970,0,1),H=60*P.getTimezoneOffset(),F=t.ui.Widget,R=Array.isArray,L="mm:ss",B="HH:mm:ss",O=t.template,V=t.keys,N={htmlPlayer:()=>"<video class='"+y+"'> </video>",titleBar:O((()=>"<div class='"+g+"'><span class='k-title'>Video Title</span></div>")),toolBar:()=>"<div class='k-mediaplayer-toolbar-wrap'><div class='"+v+"'></div></div>",youtubePlayer:()=>"<div class='"+k+"'> </div>",toolBarTime:()=>"<span class='k-mediaplayer-currenttime'>00:00:00</span> / <span class='k-mediaplayer-duration'>00:00:00</span>",slider:()=>"<input class='"+_+"' value='0' title='seekbar' />",volumeSlider:()=>"<input class='"+b+"' title='volume'/>",qualityDropDown:()=>"<input class='"+p+"' title='video quality' />",toolTip:({value:e})=>`${t.toString(new Date(e),"HH:mm:ss")}`},$=F.extend({init:function(n,i){this.wrapper=e(n),F.fn.init.call(this,n,i),this.wrapper.addClass("k-mediaplayer k-widget"),i=this.options,this._currentIndex=0,this._createTitlebar(),this._createToolbar(),this._createDropDown(),this._createSlider(),this._createVolumeSlider(),this._timers={},this._aria(),this._navigatable(),i.fullScreen&&this.fullScreen(!0),i.media&&this.media(this.options.media),t.notify(this)},events:[n,i,r,o,a,s],options:{name:"MediaPlayer",autoPlay:!1,autoRepeat:!1,volume:100,fullScreen:!1,mute:!1,navigatable:!1,forwardSeek:!0,media:null,messages:{pause:"Pause",play:"Play",mute:"Mute",unmute:"Unmute",quality:"Quality",fullscreen:"Full Screen"}},_msToTime:function(e){var t=new Date(P.getTime());return t.setSeconds(e),t},_timeToSec:function(e){return new Date(e).getTime()/1e3},_createTitlebar:function(){this._titleBar=this.wrapper.find(x+g),0===this._titleBar.length&&(this.wrapper.append(N.titleBar),this._titleBar=this.wrapper.find(x+g))},_createSlider:function(){var e=this.wrapper.find(x+_);this._slider||(this._sliderDragChangeHandler=this._sliderDragChange.bind(this),this._sliderDraggingHandler=this._sliderDragging.bind(this),e=this.wrapper.find(x+_),this._slider=new I.Slider(e[0],{smallStep:1e3,tickPlacement:"none",showButtons:!1,change:this._sliderDragChangeHandler,slide:this._sliderDraggingHandler,tooltip:{template:N.toolTip},dragHandleTitle:this.options.messages.time}))},_createVolumeSlider:function(){var e=this.wrapper.find(x+b);this._volumeSlider||(this._volumeDraggingHandler=this._volumeDragging.bind(this),this._volumeChangeHandler=this._volumeChange.bind(this),e.width(87),this._volumeSlider=new I.Slider(e[0],{smallStep:1,min:0,max:100,value:this.options.volume,slide:this._volumeDraggingHandler,change:this._volumeChangeHandler,tickPlacement:"none",showButtons:!1,tooltip:{enabled:!1},dragHandleTitle:this.options.messages.volume}))},_resetTime:function(){this._youTubeVideo?this._ytmedia.seekTo(0,!0):this._media.currentTime=0,this._mediaTimeUpdate(),e.grep(this._toolBar.options.items,(function(e){return!!e.template})).template=N.toolBarTime},_currentUrl:function(){var e=this.media();return R(e.source)?e.source[this._currentIndex].url:e.source},_isYouTubeUrl:function(){return!!this._currentUrl().match("youtube.com/|youtu.be/")},_setPlayerUrl:function(){var e=this._youTubeVideo;this.stop(),this._youTubeVideo=this._isYouTubeUrl(),e!==this._youTubeVideo&&(this.wrapper.find(x+k).toggle(),this.wrapper.find(x+y).toggle());var t=this._media||this._ytmedia;this._initializePlayer(),t&&(this.mute(this.mute()),this.volume(this.volume())),this._youTubeVideo?this._ytmedia&&(this._videoOverlay&&this._videoOverlay.hide(),this.options.autoPlay?(this._ytmedia.loadVideoById(this._getMediaId()),this._playStateToggle(!0)):(this._ytmedia.cueVideoById(this._getMediaId()),this._playStateToggle(!0))):(this._videoOverlay.show(),this.wrapper.find(x+y+" > source").remove(),this.wrapper.find(x+y).attr("src",this._currentUrl()),this.options.autoPlay&&this.play())},_createToolbar:function(){var n=this.wrapper.find(x+v);0===n.length&&(this._toolbarClickHandler=this._toolbarClick.bind(this),this.wrapper.append(N.toolBar),(n=this.wrapper.find(x+v)).width(this.wrapper.find(x+y).width()),this._toolBar=new I.ToolBar(n,{click:this._toolbarClickHandler,resizable:!1,items:[{type:"button",attributes:{class:"k-play-button"},icon:"play",fillMode:"flat"},{template:N.toolBarTime,attributes:{class:"k-mediaplayer-currenttime-wrap"}},{type:"spacer"},{type:"button",attributes:{class:"k-volume-button"},icon:"volume-up",fillMode:"flat"},{template:N.volumeSlider,attributes:{class:"k-mediaplayer-volume-wrap"}},{template:N.qualityDropDown,attributes:{class:"k-mediaplayer-quality-wrap"}},{type:"button",attributes:{class:"k-fullscreen-button"},icon:"fullscreen",fillMode:"flat"}]}),this._toolBar.wrapper.off("keydown"),n.before(N.slider),this._volumeButton=n.find(".k-volume-button"),this._fullscreenButton=n.find(".k-fullscreen-button"),this._volumeButton.attr("title",this.options.mute?this.options.messages.unmute:this.options.messages.mute),this._volumeButton.attr("aria-label",this.options.mute?this.options.messages.unmute:this.options.messages.mute),this._fullscreenButton.attr("title",this.options.messages.fullscreen),this._fullscreenButton.attr("aria-label",this.options.messages.fullscreen),n.width("auto"),this._currentTimeElement=n.find(".k-mediaplayer-currenttime"),this._durationElement=n.find(".k-mediaplayer-duration"),this._playButton=n.find(".k-play-button"),this._playButtonSpan=this._playButton.find(C),this.options.autoPlay&&this._playStateToggle(!0),!1===t.support.cssFlexbox&&e([this._volumeButton[0],n.find(".k-mediaplayer-volume-wrap")[0],n.find(".k-mediaplayer-quality-wrap")[0],this._fullscreenButton[0]]).wrapAll("<div class='k-align-right' />"))},_createDropDown:function(){var e=t.ui.icon("hd"),n=this.wrapper.find(x+p),i=this.media();void 0===n.data("kendoDropDownList")&&(this._dropDownSelectHandler=this._dropDownSelect.bind(this),this._dropDown=new I.DropDownList(n,{dataTextField:"quality",dataValueField:"url",popup:{position:"bottom",origin:"top",appendTo:this.wrapper},animation:{open:{effects:"slideIn:up",duration:1}},select:this._dropDownSelectHandler}),i&&R(i.source)&&(this._dropDown.setDataSource(i.source),this._dropDown.select(0)),this._dropDown.wrapper.addClass("k-button k-button-md k-rounded-md k-button-flat k-button-flat-base"),this._dropDown.wrapper.attr("title",this.options.messages.quality).hide(),this._dropDown.wrapper.find('span[class*="i-caret-alt-down"]').replaceWith(e),this._dropDown.list.addClass("k-quality-list"))},_dropDownSelect:function(e){this._currentIndex!==e.item.index()&&(this._currentIndex=e.item.index(),this._setPlayerUrl())},_toolbarClick:function(n){var i=e(n.target).children().first(),r=i.is(C);if(this.media()&&((i.is(C)||i.is('span[class*="i-pause"]'))&&(r?this.play():this.pause()),(i.is(S)||i.is(T))&&(this._isInFullScreen?(t.ui.icon(i,{icon:l}),this.fullScreen(!1)):(t.ui.icon(i,{icon:c}),this.fullScreen(!0))),i.is(D)||i.is(A)||i.is(M))){var o=this.mute();this.mute(!o)}},_sliderDragging:function(){this.media()&&(this._isDragging=!0)},_sliderDragChange:function(e){var t=this,n=e.sender,i=1e3*H;this.media()&&(t._sliderChangeFired=!0,t._isDragging=!1,!this.options.forwardSeek&&n.value()>this._seekBarLastPosition?setTimeout((function(){n.value(t._seekBarLastPosition)}),1):this._youTubeVideo?t._ytmedia.seekTo(t._timeToSec(e.value-i)):t._media.currentTime=t._timeToSec(e.value-i),t.trigger(a),t._preventPlay=!0)},_changeVolumeButtonImage:function(e){var n=this._volumeButton,i=n.find("span");0===e?(t.ui.icon(i,{icon:d}),n.attr("title",this.options.messages.unmute),n.attr("aria-label",this.options.messages.unmute)):e>0&&e<51?(t.ui.icon(i,{icon:u}),n.attr("title",this.options.messages.mute),n.attr("aria-label",this.options.messages.mute)):(t.ui.icon(i,{icon:h}),n.attr("title",this.options.messages.mute),n.attr("aria-label",this.options.messages.mute))},_volumeDragging:function(e){this.media()&&(this.volume(e.value),this._changeVolumeButtonImage(e.value),this.trigger(s))},_volumeChange:function(e){this.media()&&(this.volume(e.value),this._changeVolumeButtonImage(e.value),this.trigger(s))},_mediaTimeUpdate:function(){var e=this._youTubeVideo?this._ytmedia.getCurrentTime():this._media.currentTime;e=e||0;var n=this._msToTime(e);return this._currentTimeElement.text(t.toString(n,this._timeFormat)),this._isDragging||(this._seekBarLastPosition=1e3*(e+H),this._slider.value(this._seekBarLastPosition)),this.isPlaying()},_playStateToggle:function(e){void 0===e&&(e=this._playButtonSpan.is(C)),e?(t.ui.icon(this._playButtonSpan,{icon:m}),this._playButton.attr("title",this.options.messages.pause),this._playButton.attr("aria-label",this.options.messages.pause)):(t.ui.icon(this._playButtonSpan,{icon:f}),this._playButton.attr("title",this.options.messages.play),this._playButton.attr("aria-label",this.options.messages.play))},_mediaEnded:function(){this._playStateToggle(!1),this._currentTimeElement.text(t.toString(this._msToTime(0),this._timeFormat)),this._slider.value(1e3*(0+H)),this.trigger(n)},_mediaPlay:function(){this.trigger(r)},_mediaReady:function(){this.trigger(o)},_mediaDurationChange:function(){var e=this._msToTime(this._youTubeVideo?this._ytmedia.getDuration():this._media.duration);this._timeFormat=0===e.getHours()?L:B,this._durationElement.text(t.toString(e,this._timeFormat)),this._slider.setOptions({min:P.getTime(),max:e.getTime()}),this._isFirstRun||(this._resetTime(),this._isFirstRun=!0)},_createYoutubePlayer:function(){this._mediaTimeUpdateHandler=this._mediaTimeUpdate.bind(this),this._mediaDurationChangeHandler=this._mediaDurationChange.bind(this),this.wrapper.prepend(N.youtubePlayer),this._ytPlayer=this.wrapper.find(x+k)[0],e(this._ytPlayer).css({width:this.wrapper.width(),height:this.wrapper.height()}),window.YT&&window.YT.Player?this._configurePlayer():(window.onYouTubeIframeAPIReadyRegister||(window.onYouTubeIframeAPIReadyRegister=[],e.getScript("https://www.youtube.com/iframe_api"),window.onYouTubeIframeAPIReady=function(){if(window.onYouTubeIframeAPIReadyRegister)for(var e=0;e<window.onYouTubeIframeAPIReadyRegister.length;e++)window.onYouTubeIframeAPIReadyRegister[e]._youtubeApiReady();window.onYouTubeIframeAPIReadyRegister.length=0,window.onYouTubeIframeAPIReadyRegister=undefined}),window.onYouTubeIframeAPIReadyRegister[window.onYouTubeIframeAPIReadyRegister.length]=this)},_poll:function(e,t,n,i){var r=this;return null!==r._timers[e]&&clearTimeout(r._timers[e]),r._timers[e]=setTimeout(function(i){return function o(){t.call(i)&&(r._timers[e]=setTimeout(o,n))}}(i),n),r._timers[e]},_youtubeApiReady:function(){this._configurePlayer()},_configurePlayer:function(){var e={autoplay:+this.options.autoPlay,wmode:"transparent",controls:0,rel:0,showinfo:0};this._onYouTubePlayerReady=this._onYouTubePlayerReady.bind(this),window.onYouTubePlayerReady=this._onYouTubePlayerReady,this._onPlayerStateChangeHandler=this._onPlayerStateChange.bind(this),window.onPlayerStateChange=this._onPlayerStateChange;new window.YT.Player(this.wrapper.find(x+k)[0],{height:this.wrapper.height(),width:this.wrapper.width(),videoId:this._getMediaId(),playerVars:e,events:{onReady:this._onYouTubePlayerReady,onStateChange:this._onPlayerStateChangeHandler}})},_onYouTubePlayerReady:function(e){this._ytmedia=e.target,this._ytmedia.getIframe().style.width="100%",this._ytmedia.getIframe().style.height="100%",this._youTubeVideo=!0,this._mediaDurationChangeHandler(),this.options.autoPlay?(this._playStateToggle(!0),this._ytmedia.loadVideoById(this._getMediaId())):this._ytmedia.cueVideoById(this._getMediaId()),this.options.mute&&this.mute(!0),this.trigger(o)},_updateTitle:function(){this.titlebar().text(this.media().title||this.media().source)},_onPlayerStateChange:function(e){0===e.data?(this._slider.value(0),this._paused=!1,this._playStateToggle(!0),this.trigger(n),this.options.autoRepeat&&this.play()):1===e.data?(this._mediaDurationChange(),this._ytmedia.setVolume(this.volume()),this._sliderChangeFired?this._sliderChangeFired=!1:this._uiDisplay(!1),this.trigger(r),this._playStateToggle(!0),this._poll("progress",this._mediaTimeUpdate,500,this),this._paused=!1):2===e.data&&(this._paused||(this._uiDisplay(!0),this._playStateToggle(!1),this.trigger(i),this._paused=!0))},_getMediaId:function(){var e=this._currentUrl(),t=e.match(/^.*((youtu.be\/)|(v\/)|(\/u\/\w\/)|(embed\/)|(watch\?))\??v?=?([^#\&\?]*).*/);return t&&11===t[7].length&&(e=t[7]),e},_mouseClick:function(){this.isPaused()?this.play():this.pause()},_initializePlayer:function(){this._mouseMoveHandler||(this._mouseMoveHandler=this._mouseMove.bind(this),this._mouseInHandler=this._mouseIn.bind(this),this._mouseOutHandler=this._mouseOut.bind(this),e(this.wrapper).on("mouseenter"+z,this._mouseInHandler).on("mouseleave"+z,this._mouseOutHandler).on("mousemove"+z,this._mouseMoveHandler)),!this._ytmedia&&this._youTubeVideo?this._createYoutubePlayer():this._media||this._youTubeVideo||this._createHtmlPlayer()},_createHtmlPlayer:function(){this._videoOverlay||(this._mouseClickHanlder=this._mouseClick.bind(this),this.wrapper.append("<div class='"+w+"'></div>"),this._videoOverlay=this.wrapper.find(".k-mediaplayer-overlay").on("click"+z,this._mouseClickHanlder)),this._mediaTimeUpdateHandler=this._mediaTimeUpdate.bind(this),this._mediaDurationChangeHandler=this._mediaDurationChange.bind(this),this._mediaEndedHandler=this._mediaEnded.bind(this),this._mediaCanPlayHandler=this._mediaReady.bind(this),this._mediaPlayHandler=this._mediaPlay.bind(this),this._videoOverlay.after(N.htmlPlayer),this._media=this.wrapper.find(x+y)[0],e(this._media).css({width:"100%",height:"100%"}),this.options.mute&&this.mute(!0),this._media.ontimeupdate=this._mediaTimeUpdateHandler,this._media.ondurationchange=this._mediaDurationChangeHandler,this._media.oncanplay=this._mediaCanPlayHandler,this._media.onplay=this._mediaPlayHandler,this._media.onended=this._mediaEndedHandler,this._media.loop=this.options.autoRepeat},_mouseIn:function(){this._shownOnKeydown||this._uiDisplay(!0)},_mouseOut:function(){this._shownOnKeydown||this._poll("mouseIdle",this._mouseIdle,3e3,this)},_mouseIdle:function(){return this._shownOnKeydown||this._uiDisplay(!1),!1},_mouseMove:function(){this._titleBar.is(":animated")||this._toolBar.element.is(":animated")||this._slider.wrapper.is(":animated")||this._uiDisplay(!0),this._poll("mouseIdle",this._mouseIdle,3e3,this)},_uiDisplay:function(e,t){var n=t||"slow",i=this._titleBar.add(this._toolBar.element.parent());e?i.fadeIn(n):(i.fadeOut(n),this.options.navigatable&&this.wrapper.trigger("focus"))},setOptions:function(e){F.fn.setOptions.call(this,e)},destroy:function(){F.fn.destroy.call(this),this.isPaused()||this.pause(),this.element.off(z),this.element.find(x+w).off(z),this._timers=null,this._mouseMoveHandler=null,this._mouseOutHandler=null,this._mouseInHandler=null,this._mouseClickHanlder=null,this._keyDownHandler=null,this._fullscreenHandler=null,this._toolbarClickHandler=null,this._sliderDragChangeHandler=null,this._sliderDraggingHandler=null,this._volumeDraggingHandler=null,this._volumeChangeHandler=null,this._youtubeApiReadyHandler=null,this._onYouTubePlayerReady=null,this._onPlayerStateChangeHandler=null,this._dropDownSelectHandler=null,this._youTubeVideo?this._ytmedia.destroy():(this._media.ontimeupdate=this._mediaTimeUpdateHandler=null,this._media.ondurationchange=this._mediaDurationChangeHandler=null,this._media.oncanplay=this._mediaCanPlayHandler=null,this._media.onplay=this._mediaPlayHandler=null,this._media.onended=this._mediaEndedHandler=null,this._media.src="",this._media.remove()),this._mouseMoveTimer=null,clearTimeout(this._mouseMoveTimer),t.destroy(this.element)},seek:function(e){if(void 0===e)return 1e3*this._youTubeVideo?this._ytmedia.getCurrentTime():this._media?this._media.currentTime:0;var t=e/1e3;return this._youTubeVideo?t+3>=this._ytmedia.getDuration()|0?this._ytmedia.seekTo(this._ytmedia.getDuration()-3|0,!0):this._ytmedia.seekTo(t,!0):this._media.currentTime=t,this},play:function(){return this._youTubeVideo?this._ytmedia.playVideo():(t.support.mobileOS&&this._uiDisplay(!1),this._media.play()),this._paused=!1,this._playStateToggle(!0),this},stop:function(){return this._youTubeVideo&&this._ytmedia?this._ytmedia.stopVideo():this._media&&!this._youTubeVideo&&(t.support.mobileOS&&this._uiDisplay(!0),this._media.pause(),this._media.currentTime=0),this._paused=!0,this._playStateToggle(!1),this},pause:function(){return this._youTubeVideo?this._ytmedia.pauseVideo():(t.support.mobileOS&&this._uiDisplay(!0),this._media.pause()),this._paused=!0,this._playStateToggle(!1),this.trigger(i),this},toolbar:function(){return this._toolBar},dropdown:function(){return this._dropDown},titlebar:function(){return this._titleBar},fullScreen:function(e){if(void 0===e)return this._isInFullScreen||!1;var t=this.element.get(0);e?(this.element.addClass("k-mediaplayer-fullscreen"),t.requestFullscreen?t.requestFullscreen():t.webkitRequestFullscreen?t.webkitRequestFullscreen():t.mozRequestFullScreen?t.mozRequestFullScreen():t.msRequestFullscreen&&t.msRequestFullscreen(),this._isInFullScreen=!0):(document.cancelFullscreen?document.cancelFullscreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.msCancelFullscreen?document.msCancelFullscreen():document.exitFullscreen?document.exitFullscreen():document.msExitFullscreen&&document.msExitFullscreen(),this.element.removeClass("k-mediaplayer-fullscreen"),this._isInFullScreen=!1),this._slider.resize()},volume:function(e){if(void 0===e)return void 0!==this._volume?this._volume:this._volume=this.options.volume;this._volume=e,this.mute(e<=0),this._youTubeVideo?this._ytmedia.setVolume(this._volume):this._media.volume=this._volume/100,this._volumeSlider.value(e)},mute:function(e){var t=this._youTubeVideo?this._ytmedia&&this._ytmedia.isMuted():this._media&&this._media.muted;if(void 0===e||e===t)return t;this._youTubeVideo?e?this._ytmedia.mute():this._ytmedia.unMute():this._media.muted=e,e?this._volumeSlider.value(0):this._volumeSlider.value(this._media&&100*this._media.volume||this._ytmedia&&this._ytmedia.getVolume()),this.trigger(s),this._changeVolumeButtonImage(this._volumeSlider.value())},isEnded:function(){return this._youTubeVideo?0===this._ytmedia.getPlayerState():this._media.ended},media:function(e){var t=this.dropdown();if(void 0===e)return void 0!==this._mediaData?this._mediaData:this._mediaData=this.options.media;R(e.source)?(t.setDataSource(e.source),t.wrapper.show()):t.wrapper.hide(),this._mediaData=e,this._updateTitle(),this._setPlayerUrl()},isPaused:function(){return this._paused},isPlaying:function(){return!this.isEnded()&&!this._paused},_aria:function(){this.wrapper.attr("role","region")},_navigatable:function(){this._fullscreenHandler=this._fullscreen.bind(this),e(document).on("webkitfullscreenchange mozfullscreenchange fullscreenchange"+z,this._fullscreenHandler),this.options.navigatable&&(this.wrapper.attr("tabIndex",0),this._keyDownHandler=this._keyDown.bind(this),this.wrapper.on("keydown"+z,this._keyDownHandler))},_fullscreen:function(){var e=document.fullScreen||document.mozFullScreen||document.webkitIsFullScreen,n=this.wrapper.find(S);this._uiDisplay(!0),this._slider.resize(),e||(t.ui.icon(n,{icon:l}),this.fullScreen(!1))},_keyIdle:function(){return this._uiDisplay(!1),this._shownOnKeydown=!1,!1},_keyDown:function(e){e.preventDefault();const n=this.wrapper.find(S);if(this._shownOnKeydown=!0,this._uiDisplay(!0,"fast"),this._poll("keyDown",this._keyIdle,3e3,this),e.keyCode===V.SPACEBAR)this.isPlaying()?this.pause():this.play();else if(e.keyCode!==V.ENTER||this._isInFullScreen)if(77===e.keyCode){var i=this.mute();this.mute(!i)}else e.keyCode===V.ESC&&this._isInFullScreen?(t.ui.icon(n,{icon:l}),this.fullScreen(!1)):e.keyCode===V.LEFT||e.keyCode===V.RIGHT?(e.preventDefault(),this._volumeSlider.wrapper.find(E).length||this._sliderKeyNav(this._slider,e.keyCode)):e.keyCode===V.UP||e.keyCode===V.DOWN?(e.preventDefault(),this._slider.wrapper.find(E).length||this._sliderKeyNav(this._volumeSlider,e.keyCode)):!e.ctrlKey||97!==e.keyCode&&49!==e.keyCode?!e.ctrlKey||98!==e.keyCode&&50!==e.keyCode||this._qualityDropDownKeyNav("increase"):this._qualityDropDownKeyNav("decrease");else t.ui.icon(n,{icon:c}),this.fullScreen(!0)},_error:function(){},_progress:function(){},_sliderKeyNav:function(e,t){e._setValueInRange(e._keyMap[t](e.options.value))},_qualityDropDownKeyNav:function(e){const t=this._dropDown,n=t.dataSource,i=t.options.dataValueField;let r=t.selectedIndex;switch(e){case"increase":r+=1;break;case"decrease":r-=1}const o=n.at(r);o&&o[i]&&(t.value(o[i]),this._currentIndex=r,this._setPlayerUrl())}});I.plugin($)}(window.kendo.jQuery);kendo;var Mf=function(e){return null!=e},Ef=function(e){return null==e},If=function(e){return Array.isArray(e)},zf=function(e){return"function"==typeof e},Pf=function(e){return"string"==typeof e},Hf=function(e){return!function(e){return Ef(e)||0===e.trim().length}(e)},Ff=function(e){return!isNaN(e-parseFloat(e))},Rf=function(e){return e&&e.getTime},Lf=function(e){return Mf(e.filters)};var Bf,Of=function(e,t,n){return function(i){return e(i)?t(i):n(i)}},Vf=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(t){return e.reduceRight((function(e,t){return t(e)}),t)}},Nf=function(e){return new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()))},$f=function(e){return Rf(e.value)},Uf=(Bf="",{}),Wf=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g;Uf[void 0]=function(e){return e};var jf,qf,Gf=function(e,t){var n=e+t;if(Uf[n])return Uf[n];var i=[];return e.replace(Wf,(function(e,t,n,r){i.push(Mf(t)?t:n||r)})),Uf[n]=function(e){for(var n=e,r=0;r<i.length;r++)if(n=n[i[r]],!Mf(n)&&t)return n;return n},Uf[n]},Kf=function(e){return function(t){return[e,t]}},Yf=function(){return null},Qf=function(e){return function(t){return Mf(e(t))}},Xf=function(e){return function(t){return function(e){return Mf(e)&&If(e)&&e.length>0}(e(t))}},Zf=function(e,t){return Of(e,t,Yf)},Jf=function(e,t){return function(n){return e(n).map(t).join("~")}},em=Vf.apply(void 0,[['"',""],[":","-"]].map((function(e){var t=e[0],n=e[1];return function(e){return e.replace(new RegExp(t,"g"),n)}}))),tm=(jf=".",function(e){return e.slice(0,e.indexOf(jf))}),nm=function(e){var t=e.field,n=e.dir;return t+"-"+(void 0===n?"asc":n)},im=Gf("take"),rm=Gf("aggregates"),om=Gf("skip"),am=Gf("group"),sm=Gf("sort",!0),lm=Jf(sm,nm),cm=Jf(am,nm),dm=Jf(rm,(function(e){return e.field+"-"+e.aggregate})),um=Vf((function(e){return"datetime'"+e+"'"}),tm,em,JSON.stringify,Nf),hm=Vf(Kf("page"),(function(e){var t=e.skip,n=e.take;return Math.floor((t||0)/n)+1})),pm=Vf(Kf("pageSize"),im),fm=Vf(Kf("group"),cm),mm=Vf(Kf("sort"),lm),gm=Vf(Kf("aggregate"),dm),vm=(Zf(Qf(om),hm),Zf(Qf(im),pm),Zf(Xf(am),fm),Zf(Qf(rm),gm),Vf(Zf(Xf(sm),mm),(function(e){return Object.assign({},e,{sort:(sm(e)||[]).filter((function(e){var t=e.dir;return Hf(t)}))})})),function(e){return e.field+"~"+e.operator+"~"+e.value}),_m=(Of($f,Vf(vm,(function(e){var t=e.field,n=e.value,i=e.ignoreCase,r=e.operator;return{value:um(n),field:t,ignoreCase:i,operator:r}})),vm),function(e,t,n){return t[e]=n,t}),bm=function(e){return function(t){var n,i=t[e];return Mf(i)?i:t[(n=e,n.replace(/(^[A-Z])/g,(function(e,t){return t.toLowerCase()})))]}},ym=(bm("Member"),bm("AggregateMethodName"),bm("Value"),function(e){return function(t){return Object.keys(t).reduce(e.bind(null,t),{})}}),wm=ym((function(e,t,n){return _m(n.toLowerCase(),t,e[n])})),km=ym((function(e,t,n){return _m(n,t,wm(e[n]))})),xm=function(e,t){return Mf(e)?e:t},Cm=Vf((function(e){var t=e.field,n=e.hasSubgroups,i=e.value,r=e.aggregates,o=e.items;return{aggregates:km(r),field:t,items:n?o.map(Cm):o,value:i}}),(function(e){return{aggregates:e.Aggregates||e.aggregates,field:e.Member||e.member||e.field,hasSubgroups:e.HasSubgroups||e.hasSubgroups||!1,items:e.Items||e.items,value:xm(e.Key,xm(e.key,e.value))}})),Sm=function(e){return function(t){return function(n,i,r){return t(n,e(i,r))}}},Tm=(Sm((function(e){return e})),{or:{concat:function(e,t){return function(n){return e(n)||t(n)}},identity:function(){return!1}},and:{concat:function(e,t){return function(n){return e(n)&&t(n)}},identity:function(){return!0}}}),Dm={contains:function(e,t){return(e||"").indexOf(t)>=0},doesnotcontain:function(e,t){return-1===(e||"").indexOf(t)},doesnotendwith:function(e,t){return(e||"").indexOf(t,(e||"").length-(t||"").length)<0},doesnotstartwith:function(e,t){return-1===(e||"").lastIndexOf(t,0)},endswith:function(e,t){return(e||"").indexOf(t,(e||"").length-(t||"").length)>=0},eq:function(e,t){return e===t},gt:function(e,t){return e>t},gte:function(e,t){return e>=t},isempty:function(e){return""===e},isnotempty:function(e){return""!==e},isnotnull:function(e){return Mf(e)},isnull:function(e){return Ef(e)},lt:function(e,t){return e<t},lte:function(e,t){return e<=t},neq:function(e,t){return e!=t},startswith:function(e,t){return 0===(e||"").lastIndexOf(t,0)}},Am=/^\/Date\((.*?)\)\/$/,Mm=function(e){var t=e.field,n=e.ignoreCase,i=e.value,r=e.operator;t=Mf(t)?t:function(e){return e},n=!Mf(n)||n;var o=function(e,t,n){if(!Mf(t))return e;var i=e;if(Pf(t)){var r=Am.exec(t);r?t=new Date(+r[1]):i=function(t){var i=e(t);return"string"==typeof i&&n?i.toLowerCase():Ff(i)?i+"":i}}return Rf(t)?function(e){var t=i(e);return Rf(t)?t.getTime():t}:i}(zf(t)?t:Gf(t,!0),i,n);i=function(e,t){if(null!=e&&Pf(e)){var n=Am.exec(e);if(n)return new Date(+n[1]).getTime();if(t)return e.toLowerCase()}else if(null!=e&&Rf(e))return e.getTime();return e}(i,n);var a=zf(r)?r:Dm[r];return function(e){return a(o(e),i,n)}},Em=function(e){var t=Tm[e.logic];return e.filters.filter(Mf).map((function(e){return Lf(e)?Em(e):Mm(e)})).reduce(t.concat,t.identity)},Im=function(e){return e&&0!==e.filters.length?Em(e):function(){return!0}};Sm((function(e){return e}));!function(e){e.Contains="contains",e.DoesNotContain="doesnotcontain",e.DoesNotEndWith="doesnotendwith",e.DoesNotStartWith="doesnotstartwith",e.EndsWith="endswith",e.EqualTo="eq",e.GreaterThan="gt",e.GreaterThanOrEqual="gte",e.IsEmpty="isempty",e.IsNotEmpty="isnotempty",e.IsNotNull="isnotnull",e.IsNull="isnull",e.LessThan="lt",e.LessThanOrEqual="lte",e.NotEqualTo="neq",e.StartsWith="startswith"}(qf||(qf={}));var zm={contains:', InStr({0}.CurrentMember.MEMBER_CAPTION,"{1}") > 0',doesnotcontain:', InStr({0}.CurrentMember.MEMBER_CAPTION,"{1}")',endswith:', Right({0}.CurrentMember.MEMBER_CAPTION,Len("{1}"))="{1}"',eq:', {0}.CurrentMember.MEMBER_CAPTION = "{1}"',neq:', {0}.CurrentMember.MEMBER_CAPTION = "{1}"',startswith:', Left({0}.CurrentMember.MEMBER_CAPTION,Len("{1}"))="{1}"'},Pm="doesnotcontain",Hm="in",Fm="neq";function Rm(e){var t="",n=String(e.value),i=e.field,r=e.operator;return r===Hm?(t+="{",t+=n,t+="}"):(t+=r===Fm||r===Pm?"-":"",t+="Filter(",t+=i+".MEMBERS",t+=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return t.forEach((function(t,n){e=e.replace(new RegExp("\\{"+n+"\\}","g"),t)})),e}(zm[r],i,n),t+=")"),t}function Lm(e,t,n){var i,r="",o=function(e){for(var t,n=[],i=[],r=[],o=0;o<e.length;o++){var a=e[o],s=a.name;if(t=!1,s.length>1)i.push(a);else{for(var l=$m(s[0]),c=0,d=r.length;c<d;c++)if(0===r[c].name[0].indexOf(l)){t=!0;break}t||r.push(a),a.expand&&n.push(a)}}return n=n.concat(i),{expanded:n,root:r}}(e=e||[]),a=o.expanded,s=function(e){var t=[];return e.forEach((function(e){var n=e.name[0],i=$m(n);t.some((function(e){return 0===e.indexOf(i)}))||t.push(n)})),t}(o.root),l=[],c=a.length,d=0,u=[];if(s.length>1||t.length>1){for(l.push(Vm(s,t));d<c;d++)u=Om(i=Nm(a[d].name,n),s),l.push(Vm(u,t));r+=l.join(",")}else{for(;d<c;d++)i=Nm(a[d].name,n),u.push(i[0]);r+=s.concat(u).join(",")}return r}function Bm(e){for(var t,n=e.length,i=[],r=0;r<n;r++)t=e[r],i.push(void 0!==t.name?t.name:t);return i}function Om(e,t){var n=t.length;t=t.slice(0);for(var i=0;i<e.length;i++)for(var r=e[i],o=0;o<n;o++){var a=$m(t[o]);if(-1!==r.indexOf(a)){t[o]=r;break}}return t}function Vm(e,t){var n=e.slice(0);return t.length>1&&n.push("{"+Bm(t).join(",")+"}"),Um(n)}function Nm(e,t){var n=e.length-1,i=e[n],r=function(e,t){for(var n=0,i=e.length;n<i;n++)if(0===t.indexOf(e[n].field))return e[n];return null}(t,i);return r&&r.dir?i="ORDER("+i+".Children,"+r.field+".CurrentMember.MEMBER_CAPTION,"+r.dir+")":i+=".Children",e[n]=i,e}function $m(e){var t=e.split(".");return t.length>2?t[0]+"."+t[1]:e}function Um(e){var t,n="CROSSJOIN({";return e.length>2?(t=e.pop(),n+=Um(e)):(n+=e.shift(),t=e.pop()),n+="},{",n+=t,n+="})"}function Wm(e){var t='<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/"><Header/><Body><Execute xmlns="urn:schemas-microsoft-com:xml-analysis"><Command><Statement>',n=e.columnAxes,i=void 0===n?[]:n,r=e.rowAxes,o=void 0===r?[]:r,a=e.measureAxes,s=void 0===a?[]:a,l=e.sort,c=void 0===l?[]:l,d=e.filter,u=void 0===d?[]:d,h="rows"===e.measuresAxis;return t+="SELECT NON EMPTY {",!i.length&&o.length&&(!s.length||s.length&&h)&&(i=o,o=[],h=!1),i.length||o.length||(h=!1),i.length?t+=Lm(i,h?[]:s,c):s.length&&!h&&(t+=Bm(s).join(",")),t+="} DIMENSION PROPERTIES CHILDREN_CARDINALITY, PARENT_UNIQUE_NAME ON COLUMNS",(o.length||h&&s.length>1)&&(t+=", NON EMPTY {",o.length?t+=Lm(o,h?s:[],c):t+=Bm(s).join(","),t+="} DIMENSION PROPERTIES CHILDREN_CARDINALITY, PARENT_UNIQUE_NAME ON ROWS"),u.length?(t+=" FROM ",t+="(",t+=function(e,t){for(var n="",i="",r=e.length-1;r>=0;r--)i="SELECT (",i+=Rm(e[r]),i+=") ON 0",n=r===e.length-1?i+=" FROM ["+t+"]":i+" FROM ( "+n+" )";return n}(u,e.connection.cube),t+=")"):t+=" FROM ["+e.connection.cube+"]",1===s.length&&i.length&&(t+=" WHERE ("+Bm(s).join(",")+")"),(t+="</Statement></Command><Properties><PropertyList><Catalog>"+e.connection.catalog+"</Catalog><Format>Multidimensional</Format></PropertyList></Properties></Execute></Body></Envelope>").replace(/&/g,"&amp;")}var jm=function(e,t){return jm=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},jm(e,t)};function qm(e,t){function n(){this.constructor=e}jm(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var Gm=function(){return Gm=Object.assign||function(e){for(var t,n=1,i=arguments.length;n<i;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e},Gm.apply(this,arguments)};function Km(e,t,n,i){return new(n||(n=Promise))((function(r,o){function a(e){try{l(i.next(e))}catch(e){o(e)}}function s(e){try{l(i.throw(e))}catch(e){o(e)}}function l(e){e.done?r(e.value):function(e){return e instanceof n?e:new n((function(t){t(e)}))}(e.value).then(a,s)}l((i=i.apply(e,t||[])).next())}))}function Ym(e,t){var n,i,r,o,a={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,i&&(r=2&o[0]?i.return:o[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[2&o[0],r.value]),o[0]){case 0:case 1:r=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,i=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(r=a.trys,(r=r.length>0&&r[r.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]<r[3])){a.label=o[1];break}if(6===o[0]&&a.label<r[1]){a.label=r[1],r=o;break}if(r&&a.label<r[2]){a.label=r[2],a.ops.push(o);break}r[2]&&a.ops.pop(),a.trys.pop();continue}o=t.call(e,a)}catch(e){o=[6,e],i=0}finally{n=r=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}}function Qm(e){var t=(new DOMParser).parseFromString(e,"text/xml"),n=Array.from(t.querySelectorAll("Axis")),i=Array.from(t.querySelectorAll("CellData > Cell")).map((function(e){return{fmtValue:Xm(e,"FmtValue"),ordinal:parseInt(e.getAttribute("CellOrdinal"),10),value:Xm(e,"Value")}})),r={tuples:[]},o={tuples:[]},a=[];n.forEach((function(e){if("SlicerAxis"!==e.getAttribute("name")){var t=0===r.tuples.length?r.tuples:o.tuples;Array.prototype.push.apply(t,function(e){var t=Array.from(e.querySelectorAll("Tuple"));return t.map((function(e){var t=Array.from(e.querySelectorAll("Member")).map((function(e){var t=parseInt(Xm(e,"LNum")||"0",10),n=parseInt(Xm(e,"CHILDREN_CARDINALITY")||"0",10)>0;return{caption:Xm(e,"Caption"),children:[],hasChildren:n,hierarchy:e.getAttribute("Hierarchy"),levelName:Xm(e,"LName"),levelNum:t,name:Xm(e,"UName"),parentName:Xm(e,"PARENT_UNIQUE_NAME")}}));return{members:t}}))}(e))}}));var s=new Array(o.tuples.length*r.tuples.length).fill(null);i.forEach((function(e){s[e.ordinal]=e}));var l=0;return o.tuples.forEach((function(e){r.tuples.forEach((function(t){a.push({columnTuple:t,data:s[l],rowTuple:e}),l++}))})),{columns:r,data:a,rows:o}}function Xm(e,t){var n=e.querySelector(t);return n?n.textContent:""}var Zm={schemaCatalogs:"DBSCHEMA_CATALOGS",schemaCubes:"MDSCHEMA_CUBES",schemaDimensions:"MDSCHEMA_DIMENSIONS",schemaHierarchies:"MDSCHEMA_HIERARCHIES",schemaKPIs:"MDSCHEMA_KPIS",schemaLevels:"MDSCHEMA_LEVELS",schemaMeasures:"MDSCHEMA_MEASURES",schemaMembers:"MDSCHEMA_MEMBERS"};function Jm(e){var t={},n='<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/"><Header/><Body><Discover xmlns="urn:schemas-microsoft-com:xml-analysis">';return n+="<RequestType>"+(Zm[e.command]||e.command)+"</RequestType>",n+="<Restrictions>"+eg("RestrictionList",e.restrictions,!0)+"</Restrictions>",e.connection&&e.connection.catalog&&(t.Catalog=e.connection.catalog),n+="<Properties>"+eg("PropertyList",t,!1)+"</Properties>",n+="</Discover></Body></Envelope>"}function eg(e,t,n){var i="";if(t){i+="<"+e+">";var r=void 0;for(var o in t)t[o]&&(r=t[o],n&&(o=o.replace(/([A-Z]+(?=$|[A-Z][a-z])|[A-Z]?[a-z]+)/g,"$1_").toUpperCase().replace(/_$/,"")),i+="<"+o+">"+r+"</"+o+">");i+="</"+e+">"}else i+="<"+e+"/>";return i}var tg=void 0,ng={schemaCatalogs:function(e){var t=(new DOMParser).parseFromString(e,"text/xml");return Array.from(t.querySelectorAll("DiscoverResponse > return > root > row")).map((function(e){return{name:Xm(e,"CATALOG_NAME"),description:Xm(e,"DESCRIPTION")}}))},schemaCubes:function(e){var t=(new DOMParser).parseFromString(e,"text/xml");return Array.from(t.querySelectorAll("DiscoverResponse > return > root > row")).map((function(e){return{name:Xm(e,"CUBE_NAME"),caption:Xm(e,"CUBE_CAPTION"),description:Xm(e,"DESCRIPTION"),type:Xm(e,"CUBE_TYPE")}}))},schemaDimensions:function(e){var t=(new DOMParser).parseFromString(e,"text/xml");return Array.from(t.querySelectorAll("DiscoverResponse > return > root > row")).map((function(e){return{caption:Xm(e,"DIMENSION_CAPTION"),defaultHierarchy:Xm(e,"DEFAULT_HIERARCHY"),description:Xm(e,"DESCRIPTION"),name:Xm(e,"DIMENSION_NAME"),type:parseInt(Xm(e,"DIMENSION_TYPE"),10),uniqueName:Xm(e,"DIMENSION_UNIQUE_NAME")}}))},schemaHierarchies:function(e){var t=(new DOMParser).parseFromString(e,"text/xml");return Array.from(t.querySelectorAll("DiscoverResponse > return > root > row")).map((function(e){return{name:Xm(e,"HIERARCHY_NAME"),caption:Xm(e,"HIERARCHY_CAPTION"),description:Xm(e,"DESCRIPTION"),uniqueName:Xm(e,"HIERARCHY_UNIQUE_NAME"),dimensionUniqueName:Xm(e,"DIMENSION_UNIQUE_NAME"),displayFolder:Xm(e,"HIERARCHY_DISPLAY_FOLDER"),origin:Xm(e,"HIERARCHY_ORIGIN"),defaultMember:Xm(e,"DEFAULT_MEMBER")}}))},schemaKPIs:function(e){var t=(new DOMParser).parseFromString(e,"text/xml");return Array.from(t.querySelectorAll("DiscoverResponse > return > root > row")).map((function(e){return{name:Xm(e,"KPI_NAME"),uniqueName:Xm(e,"KPI_NAME"),caption:Xm(e,"KPI_CAPTION"),value:Xm(e,"KPI_VALUE"),goal:Xm(e,"KPI_GOAL"),status:Xm(e,"KPI_STATUS"),trend:Xm(e,"KPI_TREND"),statusGraphic:Xm(e,"KPI_STATUS_GRAPHIC"),trendGraphic:Xm(e,"KPI_TREND_GRAPHIC"),description:Xm(e,"KPI_DESCRIPTION"),groupName:Xm(e,"MEASUREGROUP_NAME"),type:"kpi"}}))},schemaLevels:function(e){var t=(new DOMParser).parseFromString(e,"text/xml");return Array.from(t.querySelectorAll("DiscoverResponse > return > root > row")).map((function(e){return{name:Xm(e,"LEVEL_NAME"),caption:Xm(e,"LEVEL_CAPTION"),description:Xm(e,"DESCRIPTION"),uniqueName:Xm(e,"LEVEL_UNIQUE_NAME"),dimensionUniqueName:Xm(e,"DIMENSION_UNIQUE_NAME"),displayFolder:Xm(e,"LEVEL_DISPLAY_FOLDER"),orderingProperty:Xm(e,"LEVEL_ORDERING_PROPERTY"),origin:Xm(e,"LEVEL_ORIGIN"),hierarchyUniqueName:Xm(e,"HIERARCHY_UNIQUE_NAME")}}))},schemaMeasures:function(e){var t=(new DOMParser).parseFromString(e,"text/xml");return Array.from(t.querySelectorAll("DiscoverResponse > return > root > row")).map((function(e){return{name:Xm(e,"MEASURE_NAME"),caption:Xm(e,"MEASURE_CAPTION"),uniqueName:Xm(e,"MEASURE_UNIQUE_NAME"),description:Xm(e,"DESCRIPTION"),aggregator:Xm(e,"MEASURE_AGGREGATOR"),groupName:Xm(e,"MEASUREGROUP_NAME"),displayFolder:Xm(e,"MEASURE_DISPLAY_FOLDER"),defaultFormat:Xm(e,"DEFAULT_FORMAT_STRING")}}))},schemaMembers:function(e){var t=(new DOMParser).parseFromString(e,"text/xml");return Array.from(t.querySelectorAll("DiscoverResponse > return > root > row")).map((function(e){return{name:Xm(e,"MEMBER_NAME"),caption:Xm(e,"MEMBER_CAPTION"),uniqueName:Xm(e,"MEMBER_UNIQUE_NAME"),dimensionUniqueName:Xm(e,"DIMENSION_UNIQUE_NAME"),hierarchyUniqueName:Xm(e,"HIERARCHY_UNIQUE_NAME"),levelUniqueName:Xm(e,"LEVEL_UNIQUE_NAME"),childrenCardinality:Xm(e,"CHILDREN_CARDINALITY")}}))}},ig=function(e,t){return Km(tg,void 0,void 0,(function(){var n;return Ym(this,(function(i){switch(i.label){case 0:return n=Gm({body:Wm(t),headers:{"Content-Type":"text/xml"},method:"POST"},e.init),[4,fetch(e.url,n)];case 1:return[4,i.sent().text()];case 2:return[2,Qm(i.sent())]}}))}))},rg=function(e,t){return Km(tg,void 0,void 0,(function(){var n,i;return Ym(this,(function(r){switch(r.label){case 0:return n=Gm({body:Jm(t),headers:{"Content-Type":"text/xml"},method:"POST"},e.init),[4,fetch(e.url,n)];case 1:return[4,r.sent().text()];case 2:return i=r.sent(),[2,ng[t.command](i)]}}))}))},og=function(e){return"[Measures]"===e.hierarchy},ag=function(e,t){return void 0===t&&(t=new Set),(e.children||[]).forEach((function(e){t.add(e.levelName),ag(e,t)})),t.size},sg=function(e){var t=0;return(e.children||[]).forEach((function(e){t+=sg(e)||1})),t},lg=function(e,t){return(t&&t.hierarchy===e.hierarchy?(t.normalizedPath||[]).slice(0,-1).concat([e.name||null]):(t&&t.normalizedPath?t.normalizedPath:[]).concat([e.name])).filter(Boolean)},cg=function(e,t,n,i,r,o,a,s){void 0===t&&(t=-1),void 0===n&&(n=0),void 0===i&&(i=void 0),void 0===r&&(r=void 0),void 0===o&&(o=void 0),void 0===a&&(a=void 0),void 0===s&&(s=void 0);var l=ag(e),c=sg(e),d=i||l,u=r||c,h=o?o.slice():[],p=a?a.slice():new Array(u),f=h.findIndex((function(t){return t&&t.name===e.levelName&&t.level===e.levelNum})),m=h[f],g={name:e.levelName,level:e.levelNum,index:t,cells:new Array(u).fill(null)},v=-1!==t&&-1!==n,_={caption:e.caption,name:e.name,levelName:e.levelName,levelNum:e.levelNum,hasChildren:e.hasChildren,parentName:e.parentName,hierarchy:e.hierarchy,total:void 0!==e.total&&e.total||s&&s.children.length<=1&&s.total,parent:s,rowIndex:t,colIndex:n,depth:1,breadth:1,path:e.path||[],normalizedPath:e.normalizedPath||[],children:e.children.filter((function(t){return t.hierarchy===e.hierarchy}))};if(v)if(m)m.cells[n]=_,m.index>=t&&(t=m.index);else if(h[t]&&h[t].cells.length){for(var b=t;b<h.length;b++){h[b].index++}h.splice(t,0,g),h[t].cells[n]=_}else h[t]=g,h[t].cells[n]=_;var y=0;return e.children&&e.children.length?e.children.forEach((function(e){var i=cg(e,t+1,n+y,d,u,h,p,_),r=i[0],o=i[1],a=i[3];y+=a||1,h=r.slice(),p=o.slice()})):e.normalizedPath&&(p[n]={total:_.total,path:e.normalizedPath}),_.depth=l,_.breadth=c,[h,p,l,c]},dg=function(e,t,n){var i;void 0===t&&(t=null),void 0===n&&(n=0);for(var r=Gm({},e,{total:!0,hasChildren:!1,children:[]}),o=0;o<e.children.length;o++){var a=dg(e.children[o],e,o);i=i||a.hierarchy,a.hierarchy===i||!t||t.children.some((function(e){return e.total&&e.name===r.name}))||e.total||(r.children.push(a),e.children.splice(o,1),o--)}if(e.children.filter((function(e){return!e.total})).length>=1&&t&&!t.children.some((function(e){return e.total&&e.name===r.name}))&&!e.total){var s=e.children[0].hierarchy;e.hierarchy===s&&t.children.splice(n+1,0,r)}return e},ug=function(e){var t={children:[]},n={};if(e.every((function(e){return 1===e.members.length&&og(e.members[0])})))return{children:e.map((function(e){var t=e.members[0];return Gm({},t,{normalizedPath:[t.name],parentName:t.name,path:[t.hierarchy]})}))};for(var i=0;i<e.length;i++)for(var r=mg(e[i]),o="",a=function(e){var i,a,s,l=r.members[e];if(t.children&&0===t.children.length)i=t;else if(n[o]&&!n[o+l.name]&&0===l.levelNum)i=n[o];else if(n[o+l.parentName]&&l.levelNum>0&&!n[o+l.parentName+l.name])i=n[o+l.parentName];else if(!n[o+l.parentName]&&l.levelNum>0&&!n[o+l.parentName+l.name]){var c=Object.keys(n).find((function(e){return l.parentName===n[e].name}));c&&(i=n[c])}if(i){l.path=(a=l,((s=i)&&s.hierarchy===a.hierarchy?(s.path||[]).slice(0,-1).concat([(0===a.levelNum?a.hierarchy:a.name)||null]):(s&&s.path?s.path:[]).concat([0===a.levelNum?a.hierarchy:a.name])).filter(Boolean)),l.normalizedPath=lg(l,i);var d=i.children.findIndex((function(e){return e.hierarchy!==i.hierarchy}));-1!==d?i.children.splice(d,0,l):i.children.push(l)}l.parentName+=l.name,o+=l.parentName,n[o]||(n[o]=l)},s=0;s<r.members.length;s++)a(s);return mg(dg(t))},hg=function(e,t,n,i,r){var o=Array.from(new Array(r),(function(){return{cells:Array.from(new Array(i),(function(){return null}))}})),a=function(e){return e.join("|")},s=function(e){return e.members.map((function(e){return e.name}))},l=new Map,c=new Map;return t.forEach((function(e,t){l.set(a(e.path),t)})),n.forEach((function(e,t){c.set(a(e.path),t)})),e.forEach((function(e){var t=l.get(a(s(e.columnTuple))),i=c.get(a(s(e.rowTuple)));void 0!==t&&void 0!==i&&(o[i].cells[t]||(o[i].row=n[i].path,o[i].cells[t]=e))})),o},pg=function(e){for(var t=cg(e),n=t[0],i=t[1],r=t[2],o=t[3],a=0;a<o;a++)for(var s=null,l=0;l<r;l++)if(n[l]){var c=n[l].cells[a];!c&&s&&(s.rowSpan=(s.rowSpan||1)+1),s&&(s.colSpan=s.breadth||1),c&&(s=c)}return[n,i,r,o]},fg=function(e){for(var t=cg(e),n=t[0],i=t[1],r=t[2],o=t[3],a=0;a<o;a++)for(var s=null,l=0;l<r;l++)if(n[l]){var c=n[l].cells[a];!c&&s&&(s.rowSpan=(s.rowSpan||1)+1),s&&(s.colSpan=s.breadth),c&&(s=c)}return function(e,t,n,i){for(var r=new Array(i),o=0;o<i;o++)for(var a=0;a<n;a++)if(e[a]&&e[a].cells[o]){var s=e[a].cells[o];r[o]||(r[o]={cells:new Array(n).fill(null)}),r[o].cells[a]=Gm({},s,{rowSpan:s.colSpan,colSpan:s.rowSpan})}return[r,t,i,n]}(n,i,r,o)};function mg(e){return JSON.parse(JSON.stringify(e))}var gg=function(e,t,n){return{hierarchyUniqueName:e,uniqueName:t,caption:t,measure:t,name:t,type:n,kpi:!0}};function vg(e){var t=e.name;return[gg(t,e.value,"value"),gg(t,e.goal,"goal"),gg(t,e.status,"status"),gg(t,e.trend,"trend")]}var _g=function(e){for(var t,n=0;n<e.length;n++)if(2===e[n].type){t=!0;break}t&&e.splice(n+1,0,{caption:"KPIs",defaultHierarchy:"[KPIs]",name:"KPIs",uniqueName:"[KPIs]"})},bg=function(e,t){return String(e.name)===String([t.defaultHierarchy?t.defaultHierarchy:t.uniqueName])},yg=function(e,t){return String(e.name)===String(t.name)},wg=function(e,t){for(var n=function(n){var i=e[n],r=i.name.findIndex((function(e){return bg({name:[e]},t)||String(e).startsWith(t.uniqueName)}));if(-1!==r)if(r===i.name.length-1||1===i.name.length)e.splice(n,1);else{i.name.splice(r,1);var o=e.findIndex((function(e){return e!==i&&String(e.name)===String(i.name)}));-1!==o&&(e[o]=Gm({},e[o],i,e[o].expand||i.expand?{expand:!0}:{}),e.splice(n,1))}},i=e.length-1;i>=0;i--)n(i)},kg=function(e,t,n){var i=-1;if(n.dropTarget&&n.dropDirection){var r=n.dropDirection?"before"===n.dropDirection?0:1:0;i=e.findIndex((function(e){return yg(e,n.dropTarget)}))+r}-1!==i?(e.forEach((function(e){var n;e.expand&&e.name.length>1&&e.name.length>i&&(n=e.name).splice.apply(n,[i,0].concat(t.name))})),e.splice(i,0,t)):e.push(t)},xg=function(e){var t=e.length&&e[0],n=t&&t.members[t.members.length-1];if(n&&og(n)){for(var i=[],r=new Set(e.map((function(e){return e.members[e.members.length-1].caption}))).size,o=0;o<e.length;o+=r)i.push(e.slice(o,o+r));var a=[];return i.forEach((function(e){a.push.apply(a,e.reverse())})),a}return e},Cg=function(e){return{columns:xg(e.columns.tuples),data:e.data,rows:e.rows.tuples}};function Sg(e){for(var t=[],n=0,i=Object.keys(e);n<i.length;n++){var r=i[n];t.push({name:JSON.parse(r),expand:e[r]})}return t}var Tg,Dg=function(e,t){void 0===t&&(t=[]),e.sort=t},Ag=function(e,t){void 0===t&&(t=[]),e.filter=t};!function(e){e.toggle="HEADERS_ACTION_TOGGLE",e.expand="HEADERS_ACTION_EXPAND",e.collapse="HEADERS_ACTION_COLLAPSE"}(Tg||(Tg={}));var Mg,Eg=function(e,t,n){var i=new Set;return e.children.forEach((function(e){var r=t(e);n&&i.add(String(e.path)),Eg(e,t,n||r).map((function(e){i.add(e)}))})),Array.from(i.values())},Ig=function(e,t){switch(t.type){case Tg.toggle:var n=e.find((function(e){return String(e.name)===String(t.payload)}));return Ig(e,Gm({},t,{type:n&&n.expand?Tg.collapse:Tg.expand}));case Tg.expand:var i=e.find((function(e){return String(e.name)===String(t.payload)}));if(i&&!0===i.expand)return e;if(!i||!1!==i.expand&&void 0!==i.expand){var r=e.slice();return r.push({name:t.payload,expand:!0}),r}return e.map((function(e){return e===i?Gm({},i,{expand:!0}):e}));case Tg.collapse:var o=Eg(t.tree,(function(e){return!e.total&&String(e.path)===String(t.payload)}));return e.slice().filter((function(e){return!o.some((function(t){return t===String(e.name)}))})).map((function(e){return Gm({},e,{expand:Boolean(e.expand)})})).map((function(e){return String(e.name)===String(t.payload)?t.payload.length>1?void 0:{name:t.payload,expand:!1}:e})).filter(Boolean);default:return e}};!function(e){e.toggleSelection="PIVOT_CONFIGURATOR_ACTION_TOGGLE_SELECTION",e.addColumnAxis="PIVOT_CONFIGURATOR_ACTION_ADD_COLUMN_AXIS",e.addColumnAxes="PIVOT_CONFIGURATOR_ACTION_ADD_COLUMN_AXES",e.removeColumnAxis="PIVOT_CONFIGURATOR_ACTION_REMOVE_COLUMN_AXIS",e.removeColumnAxes="PIVOT_CONFIGURATOR_ACTION_REMOVE_COLUMN_AXES",e.addRowAxis="PIVOT_CONFIGURATOR_ACTION_ADD_ROW_AXIS",e.addRowAxes="PIVOT_CONFIGURATOR_ACTION_ADD_ROW_AXES",e.removeRowAxis="PIVOT_CONFIGURATOR_ACTION_REMOVE_ROW_AXIS",e.removeRowAxes="PIVOT_CONFIGURATOR_ACTION_REMOVE_ROW_AXES",e.addMeasureAxis="PIVOT_CONFIGURATOR_ACTION_ADD_MEASURE_AXIS",e.addMeasureAxes="PIVOT_CONFIGURATOR_ACTION_ADD_MEASURE_AXES",e.removeMeasureAxis="PIVOT_CONFIGURATOR_ACTION_REMOVE_MEASURE_AXIS",e.removeMeasureAxes="PIVOT_CONFIGURATOR_ACTION_REMOVE_MEASURE_AXES",e.remove="PIVOT_CONFIGURATOR_ACTION_REMOVE",e.setSort="PIVOT_CONFIGURATOR_ACTION_SET_SORT",e.setFilter="PIVOT_CONFIGURATOR_ACTION_SET_FILTER",e.addFilter="PIVOT_CONFIGURATOR_ACTION_ADD_FILTER",e.changeFilter="PIVOT_CONFIGURATOR_ACTION_CHANGE_FILTER",e.removeFilter="PIVOT_CONFIGURATOR_ACTION_REMOVE_FILTER",e.setDragItem="PIVOT_CONFIGURATOR_ACTION_SET_DRAGITEM",e.drop="PIVOT_CONFIGURATOR_ACTION_DROP",e.setDropZone="PIVOT_CONFIGURATOR_ACTION_SET_DROP_ZONE",e.setDropTarget="PIVOT_CONFIGURATOR_ACTION_SET_DROP_TARGET",e.setDropDirection="PIVOT_CONFIGURATOR_ACTION_SET_DROP_DIRECTION"}(Mg||(Mg={}));var zg=function(e,t){var n,i,r,o,a,s,l,c,d;switch(t.type){case Mg.toggleSelection:if(!Array.isArray(t.payload)){var u=t.payload;if(2===u.type||"aggregator"in u)return e.measureAxes.some((function(e){return bg(e,u)}))?zg(e,Gm({},t,{type:Mg.removeMeasureAxis})):zg(e,Gm({},t,{type:Mg.addMeasureAxis}));if("kpi"===u.type){var h=vg(u);return h.every((function(t){return e.measureAxes.some((function(e){return bg(e,t)}))}))?zg(e,Gm({},t,{type:Mg.removeMeasureAxes,payload:h})):zg(e,Gm({},t,{type:Mg.addMeasureAxes,payload:h.filter((function(t){return!e.measureAxes.some((function(e){return bg(e,t)}))}))}))}return t.payload.kpi?e.measureAxes.some((function(e){return bg(e,u)}))?zg(e,Gm({},t,{type:Mg.removeMeasureAxis})):zg(e,Gm({},t,{type:Mg.addMeasureAxis})):e.columnAxes.some((function(e){return bg(e,u)}))?zg(e,Gm({},t,{type:Mg.removeColumnAxis})):e.rowAxes.some((function(e){return bg(e,u)}))?zg(e,Gm({},t,{type:Mg.removeRowAxis})):!e.columnAxes||!e.columnAxes.length||e.rowAxes&&e.rowAxes.length?zg(e,Gm({},t,{type:Mg.addColumnAxis})):zg(e,Gm({},t,{type:Mg.addRowAxis}))}break;case Mg.addColumnAxis:i=(e.columnAxes||[]).concat([{name:[t.payload.defaultHierarchy||t.payload.uniqueName]}]);break;case Mg.addColumnAxes:break;case Mg.removeColumnAxis:i=(e.columnAxes||[]).filter((function(e){return!bg(e,t.payload)})).slice(),wg(i,t.payload);break;case Mg.removeColumnAxes:break;case Mg.addRowAxis:n=(e.rowAxes||[]).concat([{name:[t.payload.defaultHierarchy||t.payload.uniqueName]}]);break;case Mg.addRowAxes:break;case Mg.removeRowAxis:n=(e.rowAxes||[]).filter((function(e){return!bg(e,t.payload)})).slice(),wg(n,t.payload);break;case Mg.removeRowAxes:break;case Mg.addMeasureAxis:r=(e.measureAxes||[]).concat([{name:[t.payload.defaultHierarchy||t.payload.uniqueName]}]);break;case Mg.removeMeasureAxis:r=(e.measureAxes||[]).filter((function(e){return!bg(e,t.payload)})).slice();break;case Mg.addMeasureAxes:r=(e.measureAxes||[]).concat((t.payload||[]).map((function(e){return{name:[e.defaultHierarchy||e.uniqueName]}})));break;case Mg.removeMeasureAxes:r=(e.measureAxes||[]).filter((function(e){return!t.payload.some((function(t){return bg(e,t)}))})).slice();break;case Mg.remove:e.columnAxes.some((function(e){return yg(e,t.payload)}))&&(i=e.columnAxes.filter((function(e){return!yg(e,t.payload)})).slice(),wg(i,{uniqueName:t.payload.name})),e.rowAxes.some((function(e){return yg(e,t.payload)}))&&(n=e.rowAxes.filter((function(e){return!yg(e,t.payload)})).slice(),wg(n,{uniqueName:t.payload.name})),e.measureAxes.some((function(e){return yg(e,t.payload)}))&&(r=e.measureAxes.filter((function(e){return!yg(e,t.payload)})).slice());break;case Mg.setDragItem:s=t.payload;break;case Mg.setDropZone:l=t.payload;break;case Mg.setDropTarget:d=t.payload;break;case Mg.setDropDirection:c=t.payload;break;case Mg.drop:if(e.dragItem&&e.dropZone){var p=e.columnAxes.find((function(e){return yg(e,t.payload)})),f=e.rowAxes.find((function(e){return yg(e,t.payload)})),m=e.measureAxes.find((function(e){return yg(e,t.payload)})),g=void 0;switch(p&&(g=p,i=e.columnAxes.filter((function(e){return!yg(e,t.payload)})).slice(),wg(i,{uniqueName:t.payload.name})),f&&(g=f,n=e.rowAxes.filter((function(e){return!yg(e,t.payload)})).slice(),wg(n,{uniqueName:t.payload.name})),m&&(g=m,r=e.measureAxes.filter((function(e){return!yg(e,t.payload)})).slice()),e.dropZone){case"columnAxes":i=i||e.columnAxes.slice(),kg(i,g,e);break;case"rowAxes":n=n||e.rowAxes.slice(),kg(n,g,e);break;case"measureAxes":r=r||e.measureAxes.slice(),kg(r,g,e)}}s=null,l=null,d=null;break;case Mg.setSort:o=t.payload;break;case Mg.setFilter:a=Array.isArray(t.payload)?t.payload:[t.payload];break;case Mg.addFilter:a=(e.filter||[]).slice(),Array.isArray(t.payload)?a.push.apply(a,t.payload):a.push(t.payload);break;case Mg.changeFilter:a=Array.isArray(t.payload)?(e.filter||[]).map((function(e){return t.payload.some((function(t){return t.field===e.field}))?t.payload.find((function(t){return t.field===e.field})):e})):(e.filter||[]).map((function(e){return e.field===t.payload.field?t.payload:e}));break;case Mg.removeFilter:a=(e.filter||[]).slice(),a=Array.isArray(t.payload)?a.filter((function(e){return!t.payload.some((function(t){return t.field===e.field&&t.operator===e.operator}))})):a.filter((function(e){return!(e.field===t.payload.field&&e.operator===t.payload.operator)}))}return{dragItem:s,dropTarget:d,dropDirection:c,dropZone:l,columnAxes:i,rowAxes:n,measureAxes:r,filter:a,sort:o}},Pg={init:function(e){"sum"in e==!1&&(e.sum=0)},merge:function(e,t){t.sum+=e.sum},accumulate:function(e,t){e.sum+=t},result:function(e){return e.sum},format:function(e){return e.toFixed(2)}},Hg={init:function(e){"countA"in e==!1&&(e.countA=0)},merge:function(e,t){t.countA+=e.countA},accumulate:function(e,t){e.countA+=1},result:function(e){return e.countA},format:function(e){return e.toFixed()}},Fg={init:function(e){"min"in e==!1&&(e.min=Number.POSITIVE_INFINITY)},merge:function(e,t){t.min=Math.min(e.min,t.min)},accumulate:function(e,t){e.min=Math.min(t,e.min)},result:function(e){return Number.isFinite(e.min)?e.min:NaN},format:function(e){return e.toFixed(2)}},Rg={init:function(e){"max"in e==!1&&(e.max=Number.NEGATIVE_INFINITY)},merge:function(e,t){t.max=Math.max(e.max,t.max)},accumulate:function(e,t){e.max=Math.max(t,e.max)},result:function(e){return Number.isFinite(e.max)?e.max:NaN},format:function(e){return e.toFixed(2)}},Lg={init:function(e){"count"in e==!1&&(e.sumA=0,e.count=0)},merge:function(e,t){t.sumA+=e.sumA,t.count+=e.count},accumulate:function(e,t){e.sumA+=t,e.count+=1},result:function(e){return e.sumA/e.count},format:function(e){return e.toFixed(2)}};function Bg(e,t){"filters"in e?e.filters.map((function(e){return Bg(e,t)})):t(e)}var Og=function(e,t){(Array.isArray(e)?e:e.filters).forEach((function(e){return Bg(e,t)}))},Vg=function(e,t,n){var i=e.get(t);return i||(i=n||new Map,e.set(t,i)),i},Ng=function(e){var t=e.indexOf("&");return-1!==t?[e.substring(0,t),e.substring(t+1)]:[e,void 0]},$g=function(e,t,n){e.forEach((function(i,r){if(r!==n){i.size>0&&$g(i,t,n);var o=i.get(n),a=Vg(e,n,{});t.forEach((function(e){e.aggregate.init(a),e.aggregate.merge(o,a)}))}}))},Ug=function(e,t,n,i){e.forEach((function(e,r){var o;r!==i?(o=Vg(t,r),Ug(e,o,n,i)):(o=Vg(t,r,{}),n.forEach((function(t){t.aggregate.init(o),t.aggregate.merge(e,o)})))}))},Wg=function(e,t,n,i){e.forEach((function(r,o){if(o!==n){r.size>0&&Wg(r,t,n,i);var a=Vg(r,n),s=Vg(e,n);Ug(a,s,t,i)}}))},jg=function(e,t,n,i,r,o){var a=new Map,s=new Map,l=t.concat(n),c=new Set,d=r.dataField,u=r.columnsData,h=function(e,t,n){var i=n?Array.isArray(n)?{logic:"and",filters:n}:n:void 0,r=i?Im(i):function(){return!0},o=e.concat(t),a=[];Og(n||[],(function(e){"field"in e&&e.field&&a.push(e.field)}));var s={hasFilter:!1,predicate:r,filteringAxes:[]};if(a.some((function(e){return"function"==typeof e})))s.filteringAxes=o.slice();else if(a.length>0){var l=Array.from(new Set(a).values()),c=o.filter((function(e){return l.indexOf(e.key)>=0}));s.filteringAxes=c}return s.hasFilter=s.filteringAxes.length>0,s}(t,n,o),p=h.hasFilter,f=h.predicate,m=h.filteringAxes;return e.forEach((function(e){if(p){var r={};if(m.forEach((function(t){r[t.key]=t.displayValue(e)})),!f(r))return}var o=l.map((function(t){return t.displayValue(e)})),h="".concat.apply("",o),g=s.get(h);if(!g){var v=a,_=function(t){v=Vg(v,function(e,t){return e+"&"+t}(t.key,t.displayValue(e)))};t.forEach(_),v=Vg(v,u),c.add(v),n.forEach(_),g={},v.set(d,g),s.set(h,g),i.forEach((function(e){e.aggregate.init(g)}))}i.forEach((function(t){t.aggregate.accumulate(g,t.value(e))}))})),c.forEach((function(e){return $g(e,i,d)})),Wg(a,i,u,d),a},qg=function(e,t,n){var i=new Map;return Ug(e,i,n,t),i},Gg=function(e,t,n){var i=Ng(e),r=i[0],o=i[1],a=n.slice();if(r&&o){var s=t.find((function(e){return e.key===r})),l=s?s.caption:"";return a.map((function(t){return t===l?e:t}))}return a},Kg=function(e,t,n,i,r,o,a){for(var s=a||new Map,l=i.map((function(e){return e.caption}));t.length>1&&i.some((function(e){return e.caption===t[t.length-1].caption}));)t.pop(),l.pop();var c=e;return t.forEach((function(e,t){if(l=Gg(e.name,i,l),c&&!i.some((function(t){return t.caption===e.name}))){if(!c.has(e.name)&&!s.has(l.slice(0,l.indexOf(e.name)+1).join("-")))for(var a=Array.from(c).find((function(e){return e[0]!==n})),d=a&&a[0],u=d&&Ng(d)[0],h=u?t-i.findIndex((function(e){return e.key===u})):0,p=function(t){var a=[];c.forEach((function(e,t){t!==n&&a.push.apply(a,Array.from(e).filter((function(e){return e[0]!==n})))}));var d=new Map;a.forEach((function(e){if(d.has(e[0])){var t=d.get(e[0]),n=e[1],i=new Map;Ug(t,i,r,o),Ug(n,i,r,o),d.set(e[0],i)}else d.set(e[0],new Map(e[1]))}));var u=l.slice(0,l.indexOf(e.name));d.forEach((function(e,t){s.set(Gg(t,i,u.concat([t])).join("-"),e)})),d.set(n,c.get(n)),c=d},f=0;f<h;f++)p();c=c.get(e.name)||s.get(l.slice(0,l.indexOf(e.name)+1).join("-"))}})),c},Yg=function(e,t,n,i,r,o,a){var s=[],l=i.dataField,c=i.columnsData,d=new Map;return t.forEach((function(t){var i=Kg(e,t.members.slice(),c,o,a,l,d),u=i&&i.get(c);n.forEach((function(e){var n=e.members.slice(),i=a[0];if("[Measures].[MeasuresLevel]"===n[n.length-1].levelName){var o=n.pop();i=a.find((function(e){return String(e.name)===o.caption}))||i}var c=u&&Kg(u,n,l,r,a,l),d="",h="";if(c&&i){var p=i.aggregate.result(c.get(l));d=String(p),h=i.aggregate.format(p)}s.push({columnTuple:e,data:{fmtValue:h,ordinal:0,value:d},rowTuple:t})}))})),s},Qg=function(e,t,n){e.forEach((function(e,i){if(!n[i]){var r=Vg(t,i);Qg(e,r,n)}}))},Xg=function(e){var t=new Set;return e.forEach((function(e){1!==e.name.length||Ng(e.name[0])[1]||t.add(e.name[0])})),t},Zg=function(e,t,n,i,r){var o=Xg(t),a=[],s=function(e,t){var n={members:[]};return e.forEach((function(e){var i=t.find((function(t){return t.key===e})),r=i?i.caption:"",o={caption:r,children:[],hasChildren:!0,parentName:"",levelNum:0,levelName:r,hierarchy:e,name:r};n.members.push(o)})),n}(o,e);a.push(s);for(var l=function(s){var l=t[s];if(1===l.name.length&&!l.expand&&o.has(l.name[0]))return"continue";var c,d=new Set(o.keys()),u=[],h=[],p=[];l.name.forEach((function(t,o){var s,f=Ng(t),m=f[0],g=f[1];if(c=e.find((function(e){return e.key===m})),g){d.delete(m),h.push(t);var v={children:[],caption:g,hierarchy:m,levelNum:1,levelName:m+" "+m,name:t,parentName:c?c.caption:""};u.push(v)}else if(l.expand&&l.name.length-1===o){d.delete(t),h.push(t);var _=function(e,t,n){for(var i,r=[],o=function(e){return Array.from(e).filter((function(e){return!n[e[0]]}))},a=new Map(e),s=function(e){if(i=a.get(t[e]))a=new Map(i);else if(e<t.length-1&&Array.from(a).some((function(n){return Ng(n[0])[0]===t[e]}))){var s=[];a.forEach((function(e,t){n[t]||s.push.apply(s,o(new Map(e)))})),a=new Map,s.forEach((function(e){if(a.has(e[0])){var t=a.get(e[0]),i=e[1],r=new Map;Qg(t,r,n),Qg(i,r,n),a.set(e[0],r)}else a.set(e[0],new Map(e[1]))}))}else 0!==e&&e!==t.length-1||Array.from(a).some((function(n){return Ng(n[0])[0]===t[e]}))&&r.push.apply(r,o(a))},l=0;l<t.length;l++)s(l);return r}(n,h,r),b=i.find((function(e){return e.field===m}));b&&b.dir&&_.sort(function(e,t){return function(n,i){var r=e.dir,o=t.sortValue(Ng(n[0])[1]),a=t.sortValue(Ng(i[0])[1]);return o<a?"asc"===r?-1:1:o>a?"asc"===r?1:-1:0}}(b,c));for(var y=0;y<_.length;y++){var w=_[y][0],k={members:[]};p.push(k);var x=Ng(w)[1];c=e.find((function(e){return e.key===t}));v={caption:x,children:[],levelName:t+" "+t,levelNum:1,parentName:c?c.caption:"",hierarchy:t,name:w};(s=k.members).push.apply(s,u),k.members.push(v)}}else if(l.expand){var C=(c=e.find((function(e){return e.key===t})))?c.caption:"";d.delete(t),h.push(t);v={children:[],caption:C,hierarchy:t,levelName:C,levelNum:0,name:C,parentName:""};u.push(v)}d.forEach((function(t){p.forEach((function(n){var i=(c=e.find((function(e){return e.key===t})))?c.caption:"",r={children:[],hasChildren:!0,caption:i,hierarchy:t,levelName:i,levelNum:0,name:i,parentName:""};n.members.push(r)}))})),a.push.apply(a,p)}))},c=0;c<t.length;c++)l(c);return a},Jg=function(e){return{caption:String(e.name),children:[],hasChildren:!1,hierarchy:"[Measures]",levelName:"[Measures].[MeasuresLevel]",levelNum:0,name:"[Measures].["+e.name+"]",parentName:""}},ev=function(e,t){var n=Jg(t),i=mg(e);return i.members.push(n),i},tv=function(e,t){if(t.length<2)return e;for(var n=e.slice(),i=n.length-1;i>=0;i--){var r=n[i];n[i]=ev(n[i],t[0]);for(var o=1;o<t.length;o++){var a=ev(r,t[o]);n.splice(i+o,0,a)}}return xg(n)},nv=function(e){var t,n=e.dataTree,i=e.rowSettings,r=e.columnSettings,o=e.rowAxes,a=e.columnAxes,s=e.measures,l=e.sort,c=e.fields,d=((t={})[c.columnsData]=c.columnsData,t[c.dataField]=c.dataField,t),u=a.length?Zg(r,a,n.get(c.columnsData),l,d):s.map((function(e){return{members:[Jg(e)]}})),h=a.length>0?tv(u,s):u,p=o.length?Zg(i,o,n,l,d):[{members:[]}];return{columns:h,data:Yg(n,p,h,c,r,i,s),rows:p}},iv=function(e,t){var n=Object.keys(e).map((function(e){return{caption:e,defaultHierarchy:e,description:"",name:e,uniqueName:e,hierarchyUniqueName:e,measure:!0,type:1}}));return t.length&&n.push({caption:"Measures",children:t.map((function(e){return{aggregator:"1",caption:String(e.name),defaultFormat:"",description:"",displayFolder:"",groupName:String(e.name),name:String(e.name),uniqueName:String(e.name)}})),type:2,description:"",name:"Measures",uniqueName:"[Measures]"}),n},rv=function(){function e(e){this.tabIndex=0,this.root=null,this.eventHandlers={},this.update=function(){},this.tabIndex=e.tabIndex}return Object.defineProperty(e.prototype,"elements",{get:function(){return this.root?Array.from(this.root.querySelectorAll(this.selectors.join(","))):[]},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"first",{get:function(){return this.root&&this.root.querySelector(this.selectors.join(","))||null},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"last",{get:function(){var e=this.elements;return e[e.length-1]||null},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"current",{get:function(){return this.elements.find((function(e){return e.matches(":focus")}))},enumerable:!0,configurable:!0}),e.prototype.start=function(e){var t=this;this.root=e;var n=function(n){i.mouseEvents[n]&&(i.eventHandlers[n]=function(e){var i=e.target instanceof Element&&e.target.closest(t.selectors.join(","));i&&t.mouseEvents[n].call(void 0,i,t,e)},e.addEventListener(n,i.eventHandlers[n]))},i=this;for(var r in this.mouseEvents)n(r);var o=function(n){a.keyboardEvents[n]&&(a.eventHandlers[n]=function(e){var i=e.target instanceof Element&&e.target.closest(t.selectors.join(",")),r=" "===e.key?"Space":e.key;i&&t.keyboardEvents[n][r]&&t.keyboardEvents[n][r].call(void 0,i,t,e)},e.addEventListener(n,a.eventHandlers[n]))},a=this;for(var r in this.keyboardEvents)o(r)},e.prototype.stop=function(){if(this.root)for(var e in this.eventHandlers)this.eventHandlers[e]&&this.root.removeEventListener(e,this.eventHandlers[e]);this.root=null},e.prototype.focusElement=function(e,t){e&&(t&&(t.removeAttribute("tabindex"),t.classList.remove("k-focus")),e.setAttribute("tabindex",String(this.tabIndex)),e.focus({preventScroll:!0}))},e}(),ov=".k-pivotgrid .k-pivotgrid-values",av=".k-pivotgrid .k-pivotgrid-column-headers",sv=".k-pivotgrid .k-pivotgrid-row-headers",lv=".k-pivotgrid > .k-pivotgrid-empty-cell",cv="table.k-pivotgrid-table",dv=".k-pivotgrid-cell",uv=[ov,av,sv].join(","),hv=[lv,[av,cv,dv].join(" "),[sv,cv,dv].join(" "),[ov,cv,dv].join(" ")],pv=function(e,t,n){var i=e.querySelector(".k-icon, .k-svg-icon");if(i){var r=t.elements.indexOf(e);t.update=function(){t.focusElement(t.elements[r],null),t.update=function(){}},i.click(),n.preventDefault()}},fv=function(e,t,n){e.offsetLeft<t.scrollLeft&&(n.scrollLeft=e.offsetLeft)},mv=function(e,t,n){e.offsetLeft+e.offsetWidth>t.scrollLeft+t.offsetWidth&&e.offsetWidth<t.offsetWidth&&(n.scrollLeft=e.offsetLeft+e.offsetWidth-t.offsetWidth)},gv=function(e,t,n){t.scrollTop&&e.offsetTop<t.scrollTop&&(n.scrollTop=e.offsetTop)},vv=function(e,t,n){e.offsetTop+e.offsetHeight>t.scrollTop+t.offsetHeight&&e.offsetHeight<t.offsetHeight&&(n.scrollTop=e.offsetTop+e.offsetHeight-t.offsetHeight)},_v=function(e,t,n){var i=t.querySelector(ov),r=e&&e.closest(uv);i&&r&&e&&n.forEach((function(t){return t(e,r,i)}))},bv=function(e){var t=Array.from(e.rows),n=Array.from(t&&t[0]&&t[0].cells||[]).map((function(e){return e.colSpan})).reduce((function(e,t){return e+t}),0),i=t.map((function(){return new Array(n)}));return t.forEach((function(e,t){var n=0;Array.from(e.cells).forEach((function(e){for(var r=0;r<e.colSpan;r++){for(var o=0;o<e.rowSpan;o++){var a=i[t+o].findIndex((function(e,t){return t>=n&&!e}));i[t+o][a]=e}n++}}))})),i},yv=function(e){for(var t=bv(e.querySelector([av,cv].join(" "))),n=bv(e.querySelector([sv,cv].join(" "))),i=bv(e.querySelector([ov,cv].join(" "))),r=e.querySelector(lv),o=new Array(n[0].length).fill(r),a=[],s=0;s<t.length;s++)a.push(o.concat(t[s]));for(s=0;s<n.length;s++)a.push(n[s].concat(i[s]));return a},wv=function(e){return e.ctrlKey||e.metaKey},kv=function(e,t,n){for(var i=yv(e),r=function(e,t){for(var n=0;n<e.length;n++)for(var i=0;i<e[n].length;i++)if(e[n][i]===t)return[n,i];return[-1,-1]}(i,t),o=[r[0]+n[0],r[1]+n[1]],a=i[o[0]]&&i[o[0]][o[1]];a&&a===t;)a=i[(o=[o[0]+n[0],o[1]+n[1]])[0]]&&i[o[0]][o[1]];return a},xv={keydown:{ArrowLeft:function(e,t,n){n.preventDefault();var i=kv(t.root,e,[0,-1]);t.focusElement(i,e),_v(i,t.root,[mv,fv,vv,gv])},ArrowRight:function(e,t,n){n.preventDefault();var i=kv(t.root,e,[0,1]);t.focusElement(i,e),_v(i,t.root,[fv,mv,vv,gv])},ArrowUp:function(e,t,n){n.preventDefault();var i=kv(t.root,e,[-1,0]);t.focusElement(i,e),_v(i,t.root,[mv,fv,vv,gv])},ArrowDown:function(e,t,n){n.preventDefault();var i=kv(t.root,e,[1,0]);t.focusElement(i,e),_v(i,t.root,[mv,fv,gv,vv])},o:function(e,t,n){if(t.root){var i=t.root.nextElementSibling;i&&i instanceof HTMLElement&&i.matches("div.k-pivotgrid-configurator-button")&&(i.click(),setTimeout((function(){if(t.root.parentNode){var e=t.root.parentNode.querySelector(".k-pivotgrid-configurator-content .k-form-field .k-fields-list-wrapper .k-treeview");e instanceof HTMLElement&&(e.setAttribute("tabindex",String(t.tabIndex)),e.focus())}}),0))}},Enter:pv,Space:pv,Home:function(e,t,n){var i=yv(t.root),r=wv(n)?i[0]:i.find((function(t){return Boolean(t.find((function(t){return t===e})))}))||[],o=r[0];o&&(t.focusElement(o,e),_v(o,t.root,[mv,fv,vv,gv]),n.preventDefault())},End:function(e,t,n){var i=yv(t.root),r=wv(n)?i[i.length-1]:i.find((function(t){return Boolean(t.find((function(t){return t===e})))}))||[],o=r&&r[r.length-1]||null;o&&(t.focusElement(o,e),_v(o,t.root,[fv,mv,gv,vv]),n.preventDefault())}}},Cv={click:function(e,t){if(e&&e instanceof HTMLElement){var n=t.elements.find((function(e){return e.hasAttribute("tabindex")}))||null;t.focusElement(e,n)}}},Sv=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.selectors=hv,t.mouseEvents=Cv,t.keyboardEvents=xv,t}return qm(t,e),t}(rv),Tv=[".k-pivotgrid-configurator-content .k-form-field .k-fields-list-wrapper .k-treeview",".k-pivotgrid-configurator-content .k-chip",".k-pivotgrid-configurator-actions button"],Dv=function(e,t,n,i){n.preventDefault();var r=t.elements,o=r.indexOf(e)+i;o<0&&(o=r.length-1),t.focusElement(r[o%r.length],e)},Av=function(e,t,n){n.target instanceof HTMLElement&&(n.target.querySelector(".k-icon.k-i-x-circle, .k-svg-icon.k-svg-i-x-circle")instanceof HTMLElement&&(n.preventDefault(),Dv(e,t,n,-1)))},Mv={keydown:{Tab:function(e,t,n){Dv(e,t,n,n.shiftKey?-1:1)},Escape:function(e,t,n){if(n.target instanceof HTMLElement&&t.root){var i=t.root.previousElementSibling,r=t.root.nextElementSibling,o=Array.from(i instanceof HTMLElement?i.querySelectorAll("[tabindex]"):[]).find((function(e){return e.tabIndex>=0}));o instanceof HTMLElement&&(o.focus(),r instanceof HTMLElement&&r.click())}},Delete:Av,Backspace:Av}},Ev={click:function(e,t){if(e&&e instanceof HTMLElement){var n=t.elements.find((function(e){return e.hasAttribute("tabindex")}))||null;t.focusElement(e,n)}}},Iv=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.selectors=Tv,t.mouseEvents=Ev,t.keyboardEvents=Mv,t}return qm(t,e),t}(rv);!function(e,t){var n=window.kendo,i=n.ui,r=n.htmlEncode,o=n.Class,a=n.data.Comparer,s=i.Widget,l=n.data.DataSource,c=n._outerWidth,d=n._outerHeight,u=n.data.Query.normalizeFilter,h=n.data.Query.normalizeSort,p={}.toString,f=function(e){return e},m=e.map,g=e.extend,v=n.keys,_=n.isFunction,b="resize",y="read",w="change",k="error",x="progress",C="Measures",S="stateReset",T="auto",D="<div></div>",A=".kendoPivotGrid",M="__row_total__",E="dataBinding",I="dataBound",z="expandMember",P=({id:t,key:i,headerClass:o,colspan:a,rowspan:s,expandable:l,iconClass:c,role:d,expanded:u})=>`<th id="${t}" role="${d}" ${l?`aria-expanded="${u}"`:""}  data-key="${r(i)}" class="${r(o)}" ${a?'colspan="'+r(a)+'"':""} ${s?'rowspan="'+r(s)+'"':""}>${l?n.ui.icon(e('<span role="presentation" class="k-pivotgrid-toggle"></span>'),{icon:`chevron-${r(c)}`}):""}</th>`,H="collapseMember",F="caret-alt-down",R=`.k-i-${F},.k-svg-i-${F}`,L="caret-alt-right",B=({member:e})=>`<span>${r(e.caption||e.name)}</span>`,O={"kpi-trend-decrease":"caret-alt-down","kpi-trend-increase":"caret-alt-up","kpi-trend-equal":"minus"},V=({dataItem:t})=>n.ui.icon(e(`<span title="${r(t.value)}"></span>`),{icon:"kpi-status-"+(t.value>0?"open":t.value<0?"deny":"hold")}),N=({dataItem:t})=>n.ui.icon(e(`<span title="${r(t.value)}"></span>`),{icon:O["kpi-trend-"+(t.value>0?"increase":t.value<0?"decrease":"equal")]}),$=({dataItem:e})=>e&&(e.fmtValue||e.value)?`<span class="k-pivotgrid-content">${r(e.fmtValue||e.value)}</span>`:"&nbsp;",U="k-table-row",W="k-header k-table-th",j="k-grid-header-table k-table k-table-md",q="k-table k-table-md",G="k-grid-table k-table k-table-md",K="k-table-tbody",Y="k-table-td";function Q(n){var i="string"==typeof n?[{name:n}]:n,r="[object Array]"===p.call(i)?i:i!==t?[i]:[];return m(r,(function(t){return"string"==typeof t?{name:t}:e.extend(!0,t,{name:t.name,type:t.type})}))}function X(e){var n="string"==typeof e?[{name:[e],expand:!1}]:e,i="[object Array]"===p.call(n)?n:n!==t?[n]:[];return m(i,(function(e){return"string"==typeof e?{name:[e],expand:!1}:{name:"[object Array]"===p.call(e.name)?e.name.slice():[e.name],expand:e.expand}}))}function Z(e){return-1!==e.indexOf(" ")&&(e='["'+e+'"]'),e}function J(e,t,i,r){var o,a,s,l;if(i||(i=t),r||(r=0),(l=i.members[r])&&!l.measure){if(a=(s=l.children).length,i===t?e[n.stringify([l.name])]=!!a:a&&(e[n.stringify(st(i,r))]=!0),a)for(o=0;o<a;o++)J(e,t,s[o],r);J(e,t,i,r+1)}}function ee(e){var t={};e.length&&J(t,e[0]);var n=[];for(var i in t)n.push({name:JSON.parse(i),expand:t[i]});return n}function te(e,t,n){(function(e,t){var n=(t.tuples||[])[0];if(n&&e.length<n.members.length)for(var i=n.members,r=0;r<i.length;r++)if(!i[r].measure){for(var o=!1,a=0;a<e.length;a++)if(0===Re(e[a]).indexOf(i[r].hierarchy)){o=!0;break}o||e.push({name:[i[r].name],expand:!1})}})(t,e=e||{}),n.length>1&&t.push({name:C,measure:!0,children:X(n)});var i={members:t};if(e.tuples){var r=Ce(e.tuples,i);r.tuple&&(t=function(e){for(var t=[],n=e.members,i=0;i<n.length;i++)n[i].measure||t.push({name:[n[i].name],expand:n[i].children.length>0});return t}(r.tuple))}return t}function ne(e){var t=n.getter(e.field,!0);return function(n,i){return e.aggregate(t(n.dataItem),i,n)}}function ie(e){return"number"==typeof e&&!isNaN(e)}function re(e){return e&&e.getTime}function oe(e,t,n){const i=this,r=(i.reader.data(e)||[]).slice(0);r&&!i._pristineData&&(i._pristineData=r);const o=i._createSettings(t.columnAxes),a=i._createSettings(t.rowAxes),s=i.measures(),l={dataTree:jg(r,a,o,s,{dataField:"aggregate",columnsData:"columns"},i.filter()||[]),columnSettings:o,rowSettings:a,columnAxes:t.columnAxes,rowAxes:t.rowAxes,measures:s.map((function(e){return e})),fields:{dataField:"aggregate",columnsData:"columns"},sort:ae(t.sort||[])};i._saveState(nv(l)),i.trigger(w),n.resolve()}function ae(e){for(var t=[],n=0;n<e.length;n++)t.push({dir:e[n].dir,field:e[n].field.split(".").pop()});return t}function se(e,t,i,r){var o={sum:Pg,average:Lg,min:Fg,max:Rg,count:Hg},a={value:function(e){return e[this.field]}.bind({field:e}),aggregate:o[r],caption:t,uniqueName:t,type:2,name:[t]};return i&&(a.aggregate.format=function(e){return n.format(this.format,e)}.bind({format:i})),a}var le={sum:function(e,t){var n=t.accumulator;return ie(n)?ie(e)&&(n+=e):n=e,n},count:function(e,t){return(t.accumulator||0)+1},average:{aggregate:function(e,n){var i=n.accumulator;return n.count===t&&(n.count=0),ie(i)?ie(e)&&(i+=e):i=e,ie(e)&&n.count++,i},result:function(e){var t=e.accumulator;return ie(t)&&(t/=e.count),t}},max:function(e,t){var n=t.accumulator;return ie(n)||re(n)||(n=e),n<e&&(ie(e)||re(e))&&(n=e),n},min:function(e,t){var n=t.accumulator;return ie(n)||re(n)||(n=e),n>e&&(ie(e)||re(e))&&(n=e),n}},ce=o.extend({init:function(e){this.options=g({},this.options,e),this.dimensions=this._normalizeDescriptors("field",this.options.dimensions),this.measures=this._normalizeDescriptors("name",this.options.measures)},_normalizeDescriptors:function(e,t){t=t||{};var n,i={};if("[object Array]"===p.call(t)){for(var r=0,o=t.length;r<o;r++)"string"==typeof(n=t[r])?i[n]={}:n[e]&&(i[n[e]]=n);t=i}return t},_rootTuples:function(e,n){var i,r,o,a,s=n.length||1,l=this.dimensions||[],c=0,d=e.length,u=[],h=[];if(d||n.length){for(c=0;c<s;c++){for(i={members:[]},a=0;a<d;a++)o=(r=e[a]).split("&"),i.members[i.members.length]={children:[],caption:(l[r]||{}).caption||"All",name:r,levelName:r,levelNum:"0",hasChildren:!0,parentName:o.length>1?o[0]:t,hierarchy:r};s>1&&(i.members[i.members.length]={children:[],caption:n[c].caption,name:n[c].descriptor.name,levelName:"MEASURES",levelNum:"0",hasChildren:!1,parentName:t,hierarchy:"MEASURES"}),u[u.length]=i}h.push(M)}return{keys:h,tuples:u}},_sortMap:function(t,n){var i,r,o,s=[],l=[];for(o in t)t[o].directParentName||l.push(e.extend({},{name:o,parentName:t[o].parentName}));if(!l.length)for(o in t)l.push(e.extend({},{name:o,parentName:t[o].parentName}));me(l,t);for(var c=0;c<n.length;c++)fe(n[c].field.split(".").pop(),l,a.create({field:"name",dir:n[c].dir}));i=pe(l);for(var d=0;d<i.length;d++)(r=t[i[d].name]).index=d,s[d]=r;return s},_expandedTuples:function(n,i,r,o){var a,s,l,c,d,u,h,p,f,m,g,v=r.length||1,_=this.dimensions||[],b=[],y=[];for(l in o&&o.length&&!e.isEmptyObject(n)&&(n=this._sortMap(n,o)),n){for(c=n[l],d=b[(h=this._findExpandedMember(i,c.uniquePath)).index]||[],u=y[h.index]||[],p=h.member.names,a=0;a<v;a++){for(s={members:[]},g=0;g<p.length;g++)g===h.member.expandedIdx?(s.members[s.members.length]={children:[],caption:c.value,name:c.name,hasChildren:!1,levelNum:1,levelName:c.parentName+c.name,parentName:c.parentName,hierarchy:c.parentName+c.name},0===a&&u.push(st(s,g).join(""))):(f=(m=p[g]).split("&"),s.members[s.members.length]={children:[],caption:(_[m]||{}).caption||"All",name:m,levelName:m,levelNum:"0",hasChildren:!0,parentName:f.length>1?f[0]:t,hierarchy:m});v>1&&(s.members[s.members.length]={children:[],caption:r[a].caption,name:r[a].descriptor.name,levelName:"MEASURES",levelNum:"0",hasChildren:!0,parentName:t,hierarchy:"MEASURES"}),d[d.length]=s}b[h.index]=d,y[h.index]=u}return{keys:y,tuples:b}},_findExpandedMember:function(e,t){for(var n=0;n<e.length;n++)if(e[n].uniquePath===t)return{member:e[n],index:n}},_asTuples:function(e,t,n,i){n=n||[];var r=this._rootTuples(t.root,n),o=this._expandedTuples(e,t.expanded,n,i);return{keys:[].concat.apply(r.keys,o.keys),tuples:[].concat.apply(r.tuples,o.tuples)}},_measuresInfo:function(e,t){for(var n,i,r=0,o=e&&e.length,a=[],s={},l={},c=this.measures||{};r<o;r++)n=c[i=e[r].descriptor.name]||{},a.push(i),n.result&&(s[i]=n.result),n.format&&(l[i]=n.format);return{names:a,formats:l,resultFuncs:s,rowAxis:t}},_toDataArray:function(e,t,n,i){var r,o,a,s,l,c,d,u,h,p,f=[],m=1,g=[],v=n.length||1,_=i.length||1;for(t.rowAxis?m=(g=t.names).length:p=t.names,a=0;a<v;a++)for(d=e[n[a]||M],c=0;c<m;c++)for(t.rowAxis&&(p=[g[c]]),s=0;s<_;s++)for(h=i[s]||M,u=d.items[h],r=h===M?d.aggregates:u?u.aggregates:{},l=0;l<p.length;l++)o=p[l],this._addData(f,r[o],t.formats[o],t.resultFuncs[o]);return f},_addData:function(e,t,i,r){var o,a="";t&&(t=r?r(t):t.accumulator,a=i?n.format(i,t):t),e[o=e.length]={ordinal:o,value:t||"",fmtValue:a}},_matchDescriptors:function(e,n,i){for(var r,o,a,s,l=n.names,c=n.expandedIdx;c>0;)if((r=l[--c].split("&")).length>1&&(o=r[0],a=r[1],(s=(s=i[o](e))!==t&&null!==s?s.toString():s)!=a))return!1;return!0},_calculateAggregate:function(e,t,n){for(var i,r,o={},a=0;a<e.length;a++)r=e[a].descriptor.name,(i=n.aggregates[r]||{}).accumulator=e[a].aggregator(t,i),o[r]=i;return o},_processColumns:function(e,n,i,r,o,a,s,l){for(var c,d,u,h,p,f,m,g,v=o.dataItem,_=0;_<n.length;_++)d=n[_],this._matchDescriptors(v,d,i)&&(g=d.names.slice(0,d.expandedIdx).join(""),m=f=d.names[d.expandedIdx],u=r[p=g+(f=f+"&"+(c=(c=i[f](v))!==t&&null!==c?c.toString():c))]||{index:s.columnIndex,parentName:m,name:f,directParentName:-1!==g.indexOf("&")?g:"",uniquePath:g+m,childrenMap:{},value:c},g&&r[g]&&!r[g].childrenMap[g+m+"&"+c]&&(r[g].childrenMap[g+m+"&"+c]=!0),h=a.items[p]||{aggregates:{}},a.items[p]={index:u.index,aggregates:this._calculateAggregate(e,o,h)},l&&(r[p]||s.columnIndex++,r[p]=u))},_measureAggregators:function(e){var t,n,i,r,o,a,s=e.measures||[],l=this.measures||{},c=[];if(s.length){for(i=0,r=s.length;i<r;i++)if(o=null,n=l[(t=s[i]).name]){if("string"==typeof(a=n.aggregate)){if(!(o=le[a.toLowerCase()]))throw new Error("There is no such aggregate function");n.aggregate=o.aggregate||o,n.result=o.result}c.push({descriptor:t,caption:n.caption,result:n.result,aggregator:ne(n)})}}else c.push({descriptor:{name:"default"},caption:"default",aggregator:function(){return 1}});return c},_buildGetters:function(e){for(var t,i,r={},o=0;o<e.length;o++)(t=(i=e[o]).split("&")).length>1?r[t[0]]=n.getter(t[0],!0):r[i]=n.getter(Z(i),!0);return r},_parseDescriptors:function(e){for(var t=Oe(e),n=Le(t.root),i=t.expanded,r=[],o=0;o<i.length;o++)r.push(Be(i[o].name,n));return{root:n,expanded:r}},_filter:function(e,t){if(!t)return e;for(var i,r=0,o=t.filters;r<o.length;r++)"in"===(i=o[r]).operator&&(o[r]=this._normalizeFilter(i));return new n.data.Query(e).filter(t).data},_normalizeFilter:function(e){var t=e.value.split(","),n=[];if(!t.length)return t;for(var i=0;i<t.length;i++)n.push({field:e.field,operator:"eq",value:t[i]});return{logic:"or",filters:n}},process:function(e,n){e=e||[],n=n||{},e=this._filter(e,n.filter);var i=n.measures||[],r="rows"===n.measuresAxis,o=n.columns||[],a=n.rows||[];!o.length&&a.length&&(!i.length||i.length&&r)&&(o=a,a=[],r=!1),o.length||a.length||(r=!1),!o.length&&i.length&&(o=X(n.measures)),o=this._parseDescriptors(o),a=this._parseDescriptors(a);var s,l,c,d,u,h,p,f,m,g,v,_,b,y={},w={},k={},x={columnIndex:0},C=this._measureAggregators(n),S=this._buildGetters(o.root),T=this._buildGetters(a.root),D=!1,A=o.expanded,E=a.expanded,I=0!==E.length,z=e.length,P=0;if(o.root.length||a.root.length)for(D=!0,P=0;P<z;P++)for(c={dataItem:l=e[P],index:P},p=y[M]||{items:{},aggregates:{}},this._processColumns(C,A,S,w,c,p,x,!I),p.aggregates=this._calculateAggregate(C,c,p),y[M]=p,d=0;d<E.length;d++)u=E[d],this._matchDescriptors(l,u,T)?(m=u.names.slice(0,u.expandedIdx).join(""),g=h=u.names[u.expandedIdx],k[f=m+(h=h+"&"+(s=(s=T[h](l))!==t?s.toString():s))]={uniquePath:m+g,parentName:g,name:h,value:s},v=y[f]||{items:{},aggregates:{}},this._processColumns(C,A,S,w,c,v,x,!0),v.aggregates=this._calculateAggregate(C,c,v),y[f]=v):this._processColumns(C,A,S,w,c,{items:{},aggregates:{}},x,!0);return D&&z?(!(C.length>1)||n.columns&&n.columns.length||(o={root:[],expanded:[]}),_=this._asTuples(w,o,r?[]:C,n.sort?n.sort:[]),b=this._asTuples(k,a,r?C:[],n.sort?n.sort:[]),w=_.tuples,k=b.tuples,y=this._toDataArray(y,this._measuresInfo(C,r),b.keys,_.keys)):y=w=k=[],{axes:{columns:{tuples:w},rows:{tuples:k}},data:y}}}),de=o.extend({init:function(e,t){this.transport=t,this.options=t.options||{},this.transport.discover||_(e.discover)&&(this.discover=e.discover)},read:function(e){return this.transport.read(e)},update:function(e){return this.transport.update(e)},create:function(e){return this.transport.create(e)},destroy:function(e){return this.transport.destroy(e)},discover:function(e){if(this.transport.discover)return this.transport.discover(e);e.success({})},catalog:function(n){var i=this.options||{};if(n===t)return(i.connection||{}).catalog;var r=i.connection||{};r.catalog=n,this.options.connection=r,e.extend(this.transport.options,{connection:r})},cube:function(e){var n=this.options||{};if(e===t)return(n.connection||{}).cube;var i=n.connection||{};i.cube=e,this.options.connection=i,g(!0,this.transport.options,{connection:i})}}),ue=l.extend({init:function(t){var n=((t||{}).schema||{}).cube,i={axes:f,cubes:f,catalogs:f,measures:f,dimensions:f,hierarchies:f,levels:f,members:f};n&&(this.cubeSchema=e.extend(i,this._cubeSchema(n))),l.fn.init.call(this,g(!0,{},{schema:this.cubeSchema},t));var r=this.options.transport||{};"xmla"===(this.options.type||"xmla").toLowerCase()?(this._online=!0,this.transport=new Ge(r)):this.transport=new de(this.options.transport||{},this.transport),this._columns=X(this.options.columns),this._rows=X(this.options.rows);var o=this.cubeSchema?this.cubeSchema.measures():this.options.measures||[];"[object Object]"===p.call(o)&&(this._measuresAxis=o.axis||"columns",o=o.values||[]),this._measures=Q(o)},options:{serverSorting:!0,serverPaging:!0,serverFiltering:!0,serverGrouping:!0,serverAggregates:!0},axes:function(){return{columns:ye(this.columns()),rows:ye(this.rows())}},catalog:function(e){if(e===t)return this.transport.catalog();this.transport.catalog(e),this._mergeState({}),this.read()},cube:function(e){if(e===t)return this.transport.cube();this.transport.cube(e),this._mergeState({}),this.read()},measuresAxis:function(){return this._measuresAxis||"columns"},fetch:function(e){var n=this;if(this._data===t||0===this._data.length){return this._query().done((function(){_(e)&&e.call(n)}))}},_createSettings:function(e){for(var t,n=[],i=this.cubeSchema.dimensionsSettings(),r=function(e){return e[this.key]},o=function(e){return e},a=0;a<e.length;a++)t=e[a].name[0],n.push({key:t,displayValue:r.bind({key:t}),sortValue:o,caption:(i[t]||{}).caption||t});return n},_cubeSchema:function(e){return{dimensionsSettings:function(){return e.dimensions},dimensions:function(){var t=[],n=e.dimensions;for(var i in n)t.push({name:i,caption:n[i].caption||i,uniqueName:i,defaultHierarchy:i,type:1});return e.measures&&t.push({name:C,caption:C,uniqueName:C,type:2}),t},restoreMeasure:function(e,t){for(var n=0;n<e.length;n++)e[n].aggregate||(e[n].aggregate=t.aggregate,e[n].value=t.value,e[n].caption=t.caption,e[n].uniqueName=t.uniqueName,e[n].type=2)},measures:function(){var t=[],n=e.measures;for(var i in n)t.push(se(n[i].field,i,n[i].format,n[i].aggregate));return t},memberType:function(e){var t=n.getter(Z(e),!0),i=this.options.data||this._pristineData||[];return i.length?typeof t(i[0]):null}.bind(this),members:function(t){var i,r,o=this.options.data||this._pristineData||[],a=[],s={},l=0;if(-1!==t.indexOf("[(ALL)]"))return[{caption:e.dimensions[t.split(".")[0]].caption||t,levelUniqueName:t,name:t,childrenCardinality:1,uniqueName:t}];for(i=n.getter(Z(t),!0);l<o.length;l++)!(r=i(o[l]))&&0!==r&&!1!==r||s[r]||(s[r]=!0,a.push({caption:r+"",name:r+"",childrenCardinality:0,uniqueName:r}));return a}.bind(this)}},read:function(t){const n=this,i=n.trigger("requestStart",{type:y}),r=n._params(t),o=e.Deferred();return i||(n.trigger(x),n.options.data?oe.call(n,n.options.data,r,o):"xmla"===(this.options.type||"xmla").toLowerCase()?n.transport.read({data:r,success:function(e){n._saveState(e),n.trigger("requestEnd",{response:e,type:y}),n.trigger(w),n._preventRefresh&&(n._preventRefresh=!1),o.resolve()},error:function(e){n.trigger(k,{error:e})}}):n.transport.read({success:function(e){oe.call(n,e,r,o)},error:function(e){n.trigger(k,{error:e})}})),o.promise()},_params:function(e){var t=this,n=l.fn._params.call(t,e);return n=g({columnAxes:JSON.parse(JSON.stringify(t._columns)),rowAxes:JSON.parse(JSON.stringify(t._rows)),measuresAxis:t.measuresAxis(),measureAxes:t._measures},n),"xmla"===(this.options.type||"").toLowerCase()&&(n.connection=t.options.transport.connection),n.filter&&(n.filter=u(n.filter),n.filter=(n.filter||{}).filters),n.sort&&(n.sort=h(n.sort)),n},discover:function(t){const n=this,i=n.transport,r="odata"===n.options.type,o={schemaMeasures:n.reader.measures,schemaKPIs:n.reader.kpis,schemaDimensions:n.reader.dimensions,schemaHierarchies:n.reader.hierarchies,schemaLevels:n.reader.levels,schemaCubes:n.reader.cubes,schemaCatalogs:n.reader.catalogs,schemaMembers:n.reader.members};return i.discover&&!r?i.discover(t):e.Deferred((function(e){i.discover(g({success:function(i){i=n.reader.parse(i),n._handleCustomErrors(i)||(o[t.command]&&(i=o[t.command](i)),e.resolve(i))},error:function(t,i,r){e.reject(t),n.error(t,i,r)}},t))})).promise().done((function(){n.trigger("schemaChange")}))},schemaMeasures:function(){const e=this;return e.discover({command:"schemaMeasures",restrictions:{catalogName:e.transport.catalog(),cubeName:e.transport.cube()}})},schemaKPIs:function(){const e=this;return e.discover({command:"schemaKPIs",restrictions:{catalogName:e.transport.catalog(),cubeName:e.transport.cube()}})},schemaDimensions:function(){const e=this;return e.discover({command:"schemaDimensions",restrictions:{catalogName:e.transport.catalog(),cubeName:e.transport.cube()}})},schemaHierarchies:function(e){const t=this;return t.discover({command:"schemaHierarchies",restrictions:{catalogName:t.transport.catalog(),cubeName:t.transport.cube(),dimensionUniqueName:e}})},schemaLevels:function(e){const t=this;return t.discover({command:"schemaLevels",restrictions:{catalogName:t.transport.catalog(),cubeName:t.transport.cube(),hierarchyUniqueName:e}})},schemaCubes:function(){return this.discover({command:"schemaCubes",restrictions:{catalogName:this.transport.catalog()}})},schemaCatalogs:function(){return this.discover({command:"schemaCatalogs"})},schemaMembers:function(e){const t=this;return t.discover({command:"schemaMembers",restrictions:g({catalogName:t.transport.catalog(),cubeName:t.transport.cube()},e)})},_saveState:function(e){var t=this;t._columnTuples=e.columns,t._rowTuples=e.rows,t._view=t._data=e.data},columns:function(e){if(e===t)return this._columns;this._columns=X(e),this.read()},rows:function(e){if(e===t)return this._rows;this._rows=X(e),this.read()},measures:function(e){if(e===t)return this._measures;this._measures=Q(e),this.read()},_mergeState:function(e){return e=l.fn._mergeState.call(this,e)},_query:function(e){var t=this,n=g({},{sort:t.sort(),measuresAxis:t.measuresAxis(),filter:t.filter()},e);return this._mergeState(n),this.read()}}),he=l.extend({init:function(t){var n,i=((t||{}).schema||{}).cube,r="columns",o={axes:f,cubes:f,catalogs:f,measures:f,dimensions:f,hierarchies:f,levels:f,members:f};i&&(o=e.extend(o,this._cubeSchema(i)),this.cubeBuilder=new ce(i)),l.fn.init.call(this,g(!0,{},{schema:o},t)),this.transport=new de(this.options.transport||{},this.transport),this._columns=X(this.options.columns),this._rows=X(this.options.rows),n=this.options.measures||[],"[object Object]"===p.call(n)&&(r=n.axis||"columns",n=n.values||[]),this._measures=Q(n),this._measuresAxis=r,this._skipNormalize=0,this._axes={}},_cubeSchema:function(e){return{dimensions:function(){var t=[],n=e.dimensions;for(var i in n)t.push({name:i,caption:n[i].caption||i,uniqueName:i,defaultHierarchy:i,type:1});return e.measures&&t.push({name:C,caption:C,uniqueName:C,type:2}),t},hierarchies:function(){return[]},measures:function(){var t=[],n=e.measures;for(var i in n)t.push({name:i,caption:i,uniqueName:i,aggregator:i});return t},members:function(t,i){var r,o,a=i.levelUniqueName||i.memberUniqueName,s=this.options.schema.data,l=_(s)?s:n.getter(s,!0),c=this.options.data&&l(this.options.data)||this._rawData||[],d=[],u=0,h={};if(a&&(a=a.split(".")[0]),!i.treeOp)return d.push({caption:e.dimensions[a].caption||a,childrenCardinality:"1",dimensionUniqueName:a,hierarchyUniqueName:a,levelUniqueName:a,name:a,uniqueName:a}),d;for(r=n.getter(Z(a),!0);u<c.length;u++)!(o=r(c[u]))&&0!==o||h[o]||(h[o]=!0,d.push({caption:o,childrenCardinality:"0",dimensionUniqueName:a,hierarchyUniqueName:a,levelUniqueName:a,name:o,uniqueName:o}));return d}.bind(this)}},options:{serverSorting:!0,serverPaging:!0,serverFiltering:!0,serverGrouping:!0,serverAggregates:!0},catalog:function(e){if(e===t)return this.transport.catalog();this.transport.catalog(e),this._mergeState({}),this._axes={},this.data([])},cube:function(e){if(e===t)return this.transport.cube();this.transport.cube(e),this._axes={},this._mergeState({}),this.data([])},axes:function(){return this._axes},columns:function(e){if(e===t)return this._columns;this._skipNormalize+=1,this._clearAxesData=!0,this._columns=X(e),this.query({columns:e,rows:this.rowsAxisDescriptors(),measures:this.measures(),sort:this.sort(),filter:this.filter()})},rows:function(e){if(e===t)return this._rows;this._skipNormalize+=1,this._clearAxesData=!0,this._rows=X(e),this.query({columns:this.columnsAxisDescriptors(),rows:e,measures:this.measures(),sort:this.sort(),filter:this.filter()})},measures:function(e){if(e===t)return this._measures;this._skipNormalize+=1,this._clearAxesData=!0,this.query({columns:this.columnsAxisDescriptors(),rows:this.rowsAxisDescriptors(),measures:Q(e),sort:this.sort(),filter:this.filter()})},measuresAxis:function(){return this._measuresAxis||"columns"},_expandPath:function(e,t){var n="columns"===t?"columns":"rows",i="columns"===t?"rows":"columns",r=X(e),o=Re(r[r.length-1]);this._lastExpanded=n,r=te(this.axes()[n],r,this.measures());for(var a=0;a<r.length;a++){if(Re(r[a])===o){if(r[a].expand)return;r[a].expand=!0}else r[a].expand=!1}var s={};s[n]=r,s[i]=this._descriptorsForAxis(i),this._query(s)},_descriptorsForAxis:function(e){var t=this.axes(),n=this[e]()||[];return t&&t[e]&&t[e].tuples&&t[e].tuples[0]&&(n=ee(t[e].tuples||[])),n},columnsAxisDescriptors:function(){return this._descriptorsForAxis("columns")},rowsAxisDescriptors:function(){return this._descriptorsForAxis("rows")},_process:function(e,t){this._view=e,(t=t||{}).items=t.items||this._view,this.trigger(w,t)},_query:function(e){var t=this;return e||(this._skipNormalize+=1,this._clearAxesData=!0),t.query(g({},{page:t.page(),pageSize:t.pageSize(),sort:t.sort(),filter:t.filter(),group:t.group(),aggregate:t.aggregate(),columns:this.columnsAxisDescriptors(),rows:this.rowsAxisDescriptors(),measures:this.measures()},e))},query:function(t){var n=this._mergeState(t);return this._data.length&&this.cubeBuilder?(this._params(n),this._updateLocalData(this._pristineData),e.Deferred().resolve().promise()):this.read(n)},_mergeState:function(e){return(e=l.fn._mergeState.call(this,e))!==t&&(this._measures=Q(e.measures),e.columns?e.columns=X(e.columns):e.columns||(this._columns=[]),e.rows?e.rows=X(e.rows):e.rows||(this._rows=[])),e},filter:function(e){if(e===t)return this._filter;this._skipNormalize+=1,this._clearAxesData=!0,this._query({filter:e,page:1})},expandColumn:function(e){this._expandPath(e,"columns")},expandRow:function(e){this._expandPath(e,"rows")},success:function(e){var t;this.cubeBuilder&&(t=(this.reader.data(e)||[]).slice(0)),l.fn.success.call(this,e),t&&(this._pristineData=t)},_processResult:function(e,t){if(this.cubeBuilder){var n=this.cubeBuilder.process(e,this._requestData);e=n.data,t=n.axes}var i,r,o,a,s,l,c=this.columns(),d=this.rows(),u=t.columns&&t.columns.tuples;c.length||!d.length||!u||!this._rowMeasures().length&&this.measures().length||(t={columns:{},rows:t.columns}),c.length||d.length||"rows"!==this.measuresAxis()||!u||(t={columns:{},rows:t.columns}),this._axes={columns:ye(this._axes.columns),rows:ye(this._axes.rows)},t={columns:ye(t.columns),rows:ye(t.rows)},i=this._normalizeTuples(t.columns.tuples,this._axes.columns.tuples,c,this._columnMeasures()),r=this._normalizeTuples(t.rows.tuples,this._axes.rows.tuples,d,this._rowMeasures()),this._skipNormalize>0&&(this._skipNormalize-=1),this.cubeBuilder||(e=this._normalizeData({columnsLength:t.columns.tuples.length,rowsLength:t.rows.tuples.length,columnIndexes:i,rowIndexes:r,data:e})),"rows"==this._lastExpanded?(o=t.columns.tuples,s=this._columnMeasures(),(a=ve(t.columns,this._axes.columns,s))&&(l="columns",t.columns=a,function(e,t,n,i,r){var o,a,s,l=e.length,c=be(t,i),d=i.length||1;for(a=0;a<n;a++)for(o=0;o<l;o++)s=_e(e[o],t)*d,s+=o%d,r[a*l+o].ordinal=a*c+s}(o,a.tuples,t.rows.tuples.length,s,e),this.cubeBuilder||(e=this._normalizeData({columnsLength:be(t.columns.tuples,s),rowsLength:t.rows.tuples.length,data:e})))):"columns"==this._lastExpanded&&(o=t.rows.tuples,s=this._rowMeasures(),(a=ve(t.rows,this._axes.rows,s))&&(l="rows",t.rows=a,function(e,t,n,i,r){var o,a,s,l=e.length,c=i.length||1;for(a=0;a<l;a++)for(s=_e(e[a],t),s*=c,s+=a%c,o=0;o<n;o++)r[a*n+o].ordinal=s*n+o}(o,a.tuples,t.columns.tuples.length,s,e),this.cubeBuilder||(e=this._normalizeData({columnsLength:be(t.rows.tuples,s),rowsLength:t.columns.tuples.length,data:e})))),this._lastExpanded=null;var h=this._mergeAxes(t,e,l);return this._axes=h.axes,h.data},_readData:function(e){var t=this.reader.axes(e),n=this.reader.data(e);return this.cubeBuilder&&(this._rawData=n),this._processResult(n,t)},_createTuple:function(e,t,n){var i,r,o,a,s,l,c,d,u=e.members,h=u.length,p={members:[]},f=0;for(t&&(h-=1);f<h;f++)d=u[f],r=Number(d.levelNum),o=d.name,a=d.parentName,c=d.caption||o,s=d.hasChildren,l=d.hierarchy,i=d.levelName,n&&(c="All",0===r?a=d.name:r-=1,s=!0,o=l=i=a),p.members.push({name:o,children:[],caption:c,levelName:i,levelNum:r.toString(),hasChildren:s,hierarchy:l,parentName:n?"":a});return t&&p.members.push({name:t.name,children:[]}),p},_hasRoot:function(e,t,n){if(t.length)return Ce(t,e).tuple;for(var i,r,o,a=e.members,s=!0,l=0,c=a.length;l<c;l++)if(i=a[l],o=Number(i.levelNum)||0,r=n[l],!(0===o||r&&i.name===Re(r))){s=!1;break}return s},_mergeAxes:function(e,t,n){var i,r,o=this._columnMeasures(),a=this._rowMeasures(),s=this.axes(),l=be(s.rows.tuples,a),c=e.rows.tuples.length,d=be(s.columns.tuples,o),u=e.columns.tuples.length;"columns"==n?(u=d,r=e.columns.tuples):t=function(e,t){if(!e||!e.length)return t;var n,i,r,o,a=[],s=Me(e),l=s.length,c=Math.max(t.length/l,1);for(i=0;i<c;i++)for(r=l*i,n=0;n<l;n++)o=s[n]+r,a[r+n]=t[o]||{value:"",fmtValue:"",ordinal:o};return a}(r=Ae(e.columns.tuples,o),t);var h=ke(s.columns.tuples,r,o);"rows"==n?(c=be(e.rows.tuples,a),r=e.rows.tuples):t=function(e,t){if(!e||!e.length)return t;var n,i,r,o,a,s=[],l=Me(e),c=l.length,d=Math.max(t.length/c,1);for(n=0;n<c;n++)for(r=d*n,o=d*l[n],i=0;i<d;i++)a=parseInt(o+i,10),s[parseInt(r+i,10)]=t[a]||{value:"",fmtValue:"",ordinal:a};return s}(r=Ae(e.rows.tuples,a),t);var p=ke(s.rows.tuples,r,a);if(s.columns.tuples=h.tuples,s.rows.tuples=p.tuples,d!==be(s.columns.tuples,o)){i=h.index+we(h.parsedRoot,h.memberIndex,o);var f=d+u;t=this._mergeColumnData(t,i,c,u,f)}else l!==be(s.rows.tuples,a)&&(i=p.index+we(p.parsedRoot,p.memberIndex,a),t=this._mergeRowData(t,i,c,u));return 0===s.columns.tuples.length&&0===s.rows.tuples.length&&(t=[]),{axes:s,data:t}},_mergeColumnData:function(e,t,n,i,r){var o,a,s,l=this.data().toJSON(),c=0,d=Math.max(this._columnMeasures().length,1);for(n=Math.max(n,1),l.length>0&&(c=d,r-=d),o=0;o<n;o++)a=t+o*r,(s=e.splice(0,i)).splice(0,c),[].splice.apply(l,[a,0].concat(s));return l},_mergeRowData:function(e,t,n,i){var r,o,a,s=this.data().toJSON(),l=Math.max(this._rowMeasures().length,1);for(i=Math.max(i,1),s.length>0&&(n-=l,e.splice(0,i*l)),r=0;r<n;r++)a=e.splice(0,i),o=t*i+r*i,[].splice.apply(s,[o,0].concat(a));return s},_columnMeasures:function(){var e=this.measures(),t=[];return"columns"===this.measuresAxis()&&(0===this.columns().length||e.length>1)&&(t=e),t},_rowMeasures:function(){var e=this.measures(),t=[];return"rows"===this.measuresAxis()&&(0===this.rows().length||e.length>1)&&(t=e),t},_updateLocalData:function(e,t){this.cubeBuilder&&(t&&(this._requestData=t),e=this._processResult(e)),this._data=this._observe(e),this._ranges=[],this._addRange(this._data),this._total=this._data.length,this._pristineTotal=this._total,this._process(this._data)},data:function(e){if(e===t)return this._data;this._pristineData=e.slice(0),this._updateLocalData(e,{columns:this.columns(),rows:this.rows(),measures:this.measures()})},_normalizeTuples:function(e,t,n,i){var r,o,a,s=i.length||1,l=0,c=[],d={},u=0;if(e.length){if(this._skipNormalize<=0&&!this._hasRoot(e[0],t,n)){for(this._skipNormalize=0;l<s;l++)c.push(this._createTuple(e[0],i[l],!0)),d[l]=l;e.splice.apply(e,[0,e.length].concat(c).concat(e)),l=s}if(i.length)for(a=r=e[l],o=r.members.length-1;r;){if(u>=s&&(u=0),r.members[o].name!==i[u].name&&(e.splice(l,0,this._createTuple(r,i[u])),d[l]=l),u+=1,r=e[l+=1],s>u&&(!r||lt(a,o-1)!==lt(r,o-1))){for(;u<s;u++)e.splice(l,0,this._createTuple(a,i[u])),d[l]=l,l+=1;r=e[l]}a=r}return d}},_addMissingDataItems:function(e,n){for(;n.rowIndexes[parseInt(e.length/n.columnsLength,10)]!==t;)for(var i=0;i<n.columnsLength;i++)e=ge(e);for(;n.columnIndexes[e.length%n.columnsLength]!==t;)e=ge(e);return e},_normalizeOrdinals:function(e,t,n){var i=n.lastOrdinal;if(!t)return ge(e);if(t.ordinal-i>1)for(i+=1;i<t.ordinal&&e.length<n.length;)e=this._addMissingDataItems(ge(e),n),i+=1;return t.ordinal=e.length,e[e.length]=t,e},_normalizeData:function(e){var t,n,i,r=e.data,o=0,a=[];if(e.lastOrdinal=0,e.columnIndexes=e.columnIndexes||{},e.rowIndexes=e.rowIndexes||{},e.columnsLength=e.columnsLength||1,e.rowsLength=e.rowsLength||1,e.length=e.columnsLength*e.rowsLength,i=e.length,r.length===i)return r;for(;a.length<i;)(t=r[o++])&&(n=t.ordinal),a=this._normalizeOrdinals(this._addMissingDataItems(a,e),t,e),e.lastOrdinal=n;return a},discover:function(t,n){var i=this,r=i.transport;return e.Deferred((function(e){r.discover(g({success:function(t){t=i.reader.parse(t),i._handleCustomErrors(t)||(n&&(t=n(t)),e.resolve(t))},error:function(t,n,r){e.reject(t),i.error(t,n,r)}},t))})).promise().done((function(){i.trigger("schemaChange")}))},schemaMeasures:function(){var e=this;return e.discover({data:{command:"schemaMeasures",restrictions:{catalogName:e.transport.catalog(),cubeName:e.transport.cube()}}},(function(t){return e.reader.measures(t)}))},schemaKPIs:function(){var e=this;return e.discover({data:{command:"schemaKPIs",restrictions:{catalogName:e.transport.catalog(),cubeName:e.transport.cube()}}},(function(t){return e.reader.kpis(t)}))},schemaDimensions:function(){var e=this;return e.discover({data:{command:"schemaDimensions",restrictions:{catalogName:e.transport.catalog(),cubeName:e.transport.cube()}}},(function(t){return e.reader.dimensions(t)}))},schemaHierarchies:function(e){var t=this;return t.discover({data:{command:"schemaHierarchies",restrictions:{catalogName:t.transport.catalog(),cubeName:t.transport.cube(),dimensionUniqueName:e}}},(function(e){return t.reader.hierarchies(e)}))},schemaLevels:function(e){var t=this;return t.discover({data:{command:"schemaLevels",restrictions:{catalogName:t.transport.catalog(),cubeName:t.transport.cube(),hierarchyUniqueName:e}}},(function(e){return t.reader.levels(e)}))},schemaCubes:function(){var e=this;return e.discover({data:{command:"schemaCubes",restrictions:{catalogName:e.transport.catalog()}}},(function(t){return e.reader.cubes(t)}))},schemaCatalogs:function(){var e=this;return e.discover({data:{command:"schemaCatalogs"}},(function(t){return e.reader.catalogs(t)}))},schemaMembers:function(e){var t=this,n=function(e){return function(n){return t.reader.members(n,e)}}(e);return t.discover({data:{command:"schemaMembers",restrictions:g({catalogName:t.transport.catalog(),cubeName:t.transport.cube()},e)}},n)},_params:function(e){this._clearAxesData&&(this._axes={},this._data=this._observe([]),this._clearAxesData=!1,this.trigger(S));var t=l.fn._params.call(this,e);return t=g({measures:this.measures(),measuresAxis:this.measuresAxis(),columns:this.columns(),rows:this.rows()},t),this.cubeBuilder&&(this._requestData=t),t}});function pe(e){for(var t=[],n=0;n<e.length;n++)t.push(e[n]),e[n].children&&(t=t.concat(pe(e[n].children)));return t}function fe(e,t,n){for(var i=0;i<t.length;i++)t[i].children&&t[i].children.length&&fe(e,t[i].children,n);t[0].parentName==e&&(t=t.sort(n))}function me(t,n){for(var i=0;i<t.length;i++){var r=n[t[i].name];if(!e.isEmptyObject(r.childrenMap)){for(var o in t[i].children=[],r.childrenMap)t[i].children.push(e.extend({},{name:o,parentName:n[o].parentName}));me(t[i].children,n)}}}function ge(e){return e[e.length]={value:"",fmtValue:"",ordinal:e.length},e}function ve(e,t,n){if(e.tuples.length<be(t.tuples,n))return t}function _e(e,t){return Ce(t,e).index}function be(e,t){if(!e.length)return 0;for(var n=e.slice(),i=n.shift(),r=1;i;)i.members?[].push.apply(n,i.members):i.children&&(i.measure||(r+=i.children.length),[].push.apply(n,i.children)),i=n.shift();return t.length&&(r*=t.length),r}function ye(e){return e||(e={tuples:[]}),e.tuples||(e.tuples=[]),e}function we(e,t,n){if(!e)return 0;for(var i=Math.max(n.length,1),r=e.members.slice(0,t),o=r.shift(),a=i;o;)o.name===C?a+=i-1:o.children?[].push.apply(r,o.children):(a++,[].push.apply(r,o.members)),o=r.shift();return a}function ke(e,t,n){if(!t[0])return{parsedRoot:null,tuples:e,memberIndex:0,index:0};var i=Ce(e,t[0]);if(!i.tuple)return{parsedRoot:null,tuples:t,memberIndex:0,index:0};var r=i.tuple.members,o=t[0].members,a=-1;if(r.length!==o.length)return{parsedRoot:null,tuples:t,memberIndex:0,index:0};for(var s=0,l=r.length;s<l;s++)!r[s].measure&&o[s].children[0]&&(-1==a&&o[s].children.length&&(a=s),r[s].children=o[s].children);return n=Math.max(n.length,1),{parsedRoot:i.tuple,index:i.index*n,memberIndex:a,tuples:e}}function xe(e,t){var n,i,r=!0;for(e=e.members,t=t.members,n=0,i=e.length;n<i;n++)e[n].measure||t[n].measure||(r=r&&Re(e[n])===Re(t[n]));return r}function Ce(e,t){var n,i,r,o,a,s,l,c=0;for(n=0,i=e.length;n<i;n++){if(xe(r=e[n],t))return{tuple:r,index:c};for(c++,a=0,s=r.members.length;a<s;a++)if(!(l=r.members[a]).measure&&(c+=(o=Ce(l.children,t)).index,o.tuple))return{tuple:o.tuple,index:c}}return{index:c}}function Se(e,t){var n,i,r,o="";for(i=0,r=e.length;i<r;i++)t[o+=(n=e[i]).name]||(t[o]=n)}function Te(e,t){var n,i,r,o,a=e.members,s="",l="";for(n=0,i=a.length;n<i;n++){if(r=a[n],o){if(t[s+r.name]){o=t[s+=r.name];continue}return t[s+r.parentName]?t[s+r.parentName]:t[l+r.parentName]?t[l+r.parentName]:t[l]}if(s+=r.name,!(o=t[r.parentName])&&!(o=t[s]))return null;o&&(l+=o.name)}return o}function De(n,i){if(!(i<0)){var r={name:C,measure:!0,children:[e.extend({members:[],dataIndex:n.dataIndex},n.members[i])]};n.members.splice(i,1,r),n.dataIndex=t}}function Ae(e,t){if(e.length<1)return[];for(var n=[],i={},r=function(e,t){if(0===t.length)return-1;for(var n=t[0],i=e.members,r=0,o=i.length;r<o;r++)if(i[r].name==n.name)return r}(e[0],t),o=0;o<e.length;o++){var a=e[o];a.dataIndex=o,De(a,r);var s=Te(a,i);s?r<0||!s.measure?s.children.push(a):s.children.push(a.members[r].children[0]):n.push(a),Se(a.members,i)}return n}function Me(e){for(var n,i,r,o,a,s=[],l=(e=e.slice()).shift();l;){for(l.dataIndex!==t&&s.push(l.dataIndex),r=0,n=0,i=l.members.length;n<i;n++)o=(a=l.members[n]).children,a.measure?[].splice.apply(e,[0,0].concat(o)):[].splice.apply(e,[r,0].concat(o)),r+=o.length;l=e.shift()}return s}function Ee(e){var t=e.split(".");return t.length>2?t[0]+"."+t[1]:e}function Ie(e,t){var n,i=e.length-1,r=e[i];return n=function(e,t){for(var n=0,i=e.length;n<i;n++)if(0===t.indexOf(e[n].field))return e[n];return null}(t,r),n&&n.dir?r="ORDER("+r+".Children,"+n.field+".CurrentMember.MEMBER_CAPTION,"+n.dir+")":r+=".Children",e[i]=r,e}function ze(e){var t,n="CROSSJOIN({";return e.length>2?(t=e.pop(),n+=ze(e)):(n+=e.shift(),t=e.pop()),n+="},{",n+=t,n+="})"}function Pe(e,t){var n=e.slice(0);return t.length>1&&n.push("{"+He(t).join(",")+"}"),ze(n)}function He(e){for(var n,i=0,r=e.length,o=[];i<r;i++)n=e[i],o.push(n.name!==t?n.name:n);return o}function Fe(e,t){var n,i,r=-1;for(n=0,i=t.length;n<i;n++)if(Re(t[n])===e){r=n;break}return r}function Re(e){return e=e.name||e,"[object Array]"===p.call(e)&&(e=e[e.length-1]),e}function Le(e){for(var t=e.length,n=[],i=0;i<t;i++)n.push(e[i].name[0]);return n}function Be(e,t){var n,i,r,o=0,a=e.length,s=t.length;for(t=t.slice(0);o<a;o++)for(n=e[o],r=0;r<s;r++)if(i=Ee(t[r]),-1!==n.indexOf(i)){t[r]=n;break}return{names:t,expandedIdx:r,uniquePath:t.slice(0,r+1).join("")}}function Oe(e){for(var t,n,i,r,o,a,s=[],l=[],c=[],d=0,u=e.length;d<u;d++)if(r=(t=e[d]).name,a=!1,"[object Array]"!==p.call(r)&&(t.name=r=[r]),r.length>1)l.push(t);else{for(o=Ee(r[0]),n=0,i=c.length;n<i;n++)if(0===c[n].name[0].indexOf(o)){a=!0;break}a||c.push(t),t.expand&&s.push(t)}return{root:c,expanded:s=s.concat(l)}}function Ve(e,t,n){var i,r="",o=Oe(e=e||[]),a=Le(o.root),s=[],l=(o=o.expanded).length,c=0,d=[];if(a.length>1||t.length>1){for(s.push(Pe(a,t));c<l;c++)d=Be(i=Ie(o[c].name,n),a).names,s.push(Pe(d,t));r+=s.join(",")}else{for(;c<l;c++)i=Ie(o[c].name,n),d.push(i[0]);r+=a.concat(d).join(",")}return r}ue.create=function(e){var t=(e=e&&e.push?{data:e}:e)||{},i=t.data;if(t.data=i,!(t instanceof ue)&&t instanceof n.data.DataSource)throw new Error("Incorrect DataSource type. Only PivotDataSource instances are supported");return t instanceof ue?t:new ue(t)},he.create=function(e){var t=(e=e&&e.push?{data:e}:e)||{},i=t.data;if(t.data=i,!(t instanceof he)&&t instanceof n.data.DataSource)throw new Error("Incorrect DataSource type. Only PivotDataSource instances are supported");return t instanceof he?t:new he(t)};var Ne={contains:', InStr({0}.CurrentMember.MEMBER_CAPTION,"{1}") > 0',doesnotcontain:', InStr({0}.CurrentMember.MEMBER_CAPTION,"{1}")',startswith:', Left({0}.CurrentMember.MEMBER_CAPTION,Len("{1}"))="{1}"',endswith:', Right({0}.CurrentMember.MEMBER_CAPTION,Len("{1}"))="{1}"',eq:', {0}.CurrentMember.MEMBER_CAPTION = "{1}"',neq:', {0}.CurrentMember.MEMBER_CAPTION = "{1}"'};function $e(e){var t="",i=e.value,r=e.field,o=e.operator;return"in"==o?(t+="{",t+=i,t+="}"):(t+="neq"==o||"doesnotcontain"==o?"-":"",t+="Filter(",t+=r+".MEMBERS",t+=n.format(Ne[o],r,i),t+=")"),t}function Ue(e,t,n){var i="";if(t){var r;for(var o in i+="<"+e+">",t){r=t[o];let e=o;n&&(e=e.replace(/([A-Z]+(?=$|[A-Z][a-z])|[A-Z]?[a-z]+)/g,"$1_").toUpperCase().replace(/_$/,"")),i+="<"+e+">"+r+"</"+e+">"}i+="</"+e+">"}else i+="<"+e+"/>";return i}var We={schemaCubes:"MDSCHEMA_CUBES",schemaCatalogs:"DBSCHEMA_CATALOGS",schemaMeasures:"MDSCHEMA_MEASURES",schemaDimensions:"MDSCHEMA_DIMENSIONS",schemaHierarchies:"MDSCHEMA_HIERARCHIES",schemaLevels:"MDSCHEMA_LEVELS",schemaMembers:"MDSCHEMA_MEMBERS",schemaKPIs:"MDSCHEMA_KPIS"},je={read:function(e){var t='<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/"><Header/><Body><Execute xmlns="urn:schemas-microsoft-com:xml-analysis"><Command><Statement>';t+="SELECT NON EMPTY {";var n=e.columns||[],i=e.rows||[],r=e.measures||[],o="rows"===e.measuresAxis,a=e.sort||[];return!n.length&&i.length&&(!r.length||r.length&&o)&&(n=i,i=[],o=!1),n.length||i.length||(o=!1),n.length?t+=Ve(n,o?[]:r,a):r.length&&!o&&(t+=He(r).join(",")),t+="} DIMENSION PROPERTIES CHILDREN_CARDINALITY, PARENT_UNIQUE_NAME ON COLUMNS",(i.length||o&&r.length>1)&&(t+=", NON EMPTY {",i.length?t+=Ve(i,o?r:[],a):t+=He(r).join(","),t+="} DIMENSION PROPERTIES CHILDREN_CARDINALITY, PARENT_UNIQUE_NAME ON ROWS"),e.filter?(t+=" FROM ",t+="(",t+=function(e,t){var n,i,r="",o=e.filters,a=o.length;for(i=a-1;i>=0;i--)n="SELECT (",n+=$e(o[i]),n+=") ON 0",r=i==a-1?n+=" FROM ["+t+"]":n+" FROM ( "+r+" )";return r}(e.filter,e.connection.cube),t+=")"):t+=" FROM ["+e.connection.cube+"]",1==r.length&&n.length&&(t+=" WHERE ("+He(r).join(",")+")"),(t+="</Statement></Command><Properties><PropertyList><Catalog>"+e.connection.catalog+"</Catalog><Format>Multidimensional</Format></PropertyList></Properties></Execute></Body></Envelope>").replace(/\&/g,"&amp;")},discover:function(t){var n='<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/"><Header/><Body><Discover xmlns="urn:schemas-microsoft-com:xml-analysis">';return n+="<RequestType>"+(We[(t=t||{}).command]||t.command)+"</RequestType>",n+="<Restrictions>"+Ue("RestrictionList",t.restrictions,!0)+"</Restrictions>",t.connection&&t.connection.catalog&&(t.properties=e.extend({},{Catalog:t.connection.catalog},t.properties)),n+="<Properties>"+Ue("PropertyList",t.properties)+"</Properties>",n+="</Discover></Body></Envelope>"}},qe=n.data.RemoteTransport.extend({init:function(e){var t=e;e=this.options=g(!0,{},this.options,e),n.data.RemoteTransport.call(this,e),_(t.discover)?this.discover=t.discover:"string"==typeof t.discover?this.options.discover={url:t.discover}:t.discover||(this.options.discover=this.options.read)},setup:function(t,i){return t.data=t.data||{},e.extend(!0,t.data,{connection:this.options.connection}),n.data.RemoteTransport.fn.setup.call(this,t,i)},options:{read:{dataType:"text",contentType:"text/xml",type:"POST"},discover:{dataType:"text",contentType:"text/xml",type:"POST"},parameterMap:function(e,t){return je[t](e,t)}},discover:function(t){return e.ajax(this.setup(t,"discover"))}}),Ge=o.extend({init:function(e){e=this.options=g(!0,{},this.options,e)},setup:function(t){return e.extend(!0,t||{},{connection:this.options.connection})},read:function(t){var n,i,r=this,o=r.setup(t.data,y);n=t.success||e.noop,i=t.error||e.noop,t.parameterMap&&(o=r.parameterMap(o,y));const a="object"==typeof r.options.read&&r.options.read.url?r.options.read:{url:r.options.read};ig(a,o).then(Cg).then((function(e){n(e)})).catch((function(e){i(e)}))},catalog:function(n){var i=this.options||{};if(n===t)return(i.connection||{}).catalog;var r=i.connection||{};r.catalog=n,this.options.connection=r,e.extend(this.transport.options,{connection:r})},cube:function(e){var n=this.options||{};if(e===t)return(n.connection||{}).cube;var i=n.connection||{};i.cube=e,this.options.connection=i,g(!0,this.transport.options,{connection:i})},discover:function(e){return rg({url:this.options.read},e)}});function Ke(e){return null==e?[]:"[object Array]"!==p.call(e)?[e]:e}function Ye(e){for(var t={tuples:[]},i=Ke(n.getter("Tuples.Tuple",!0)(e)),r=n.getter("Caption['#text']"),o=n.getter("UName['#text']"),a=n.getter("LName['#text']"),s=n.getter("LNum['#text']"),l=n.getter("CHILDREN_CARDINALITY['#text']",!0),c=n.getter("['@Hierarchy']"),d=n.getter("PARENT_UNIQUE_NAME['#text']",!0),u=0;u<i.length;u++){for(var h=[],p=Ke(i[u].Member),f=0;f<p.length;f++)h.push({children:[],caption:r(p[f]),name:o(p[f]),levelName:a(p[f]),levelNum:s(p[f]),hasChildren:parseInt(l(p[f]),10)>0,parentName:d(p[f]),hierarchy:c(p[f])});t.tuples.push({members:h})}return t}var Qe={cubes:{name:n.getter("CUBE_NAME['#text']",!0),caption:n.getter("CUBE_CAPTION['#text']",!0),description:n.getter("DESCRIPTION['#text']",!0),type:n.getter("CUBE_TYPE['#text']",!0)},catalogs:{name:n.getter("CATALOG_NAME['#text']",!0),description:n.getter("DESCRIPTION['#text']",!0)},measures:{name:n.getter("MEASURE_NAME['#text']",!0),caption:n.getter("MEASURE_CAPTION['#text']",!0),uniqueName:n.getter("MEASURE_UNIQUE_NAME['#text']",!0),description:n.getter("DESCRIPTION['#text']",!0),aggregator:n.getter("MEASURE_AGGREGATOR['#text']",!0),groupName:n.getter("MEASUREGROUP_NAME['#text']",!0),displayFolder:n.getter("MEASURE_DISPLAY_FOLDER['#text']",!0),defaultFormat:n.getter("DEFAULT_FORMAT_STRING['#text']",!0)},kpis:{name:n.getter("KPI_NAME['#text']",!0),caption:n.getter("KPI_CAPTION['#text']",!0),value:n.getter("KPI_VALUE['#text']",!0),goal:n.getter("KPI_GOAL['#text']",!0),status:n.getter("KPI_STATUS['#text']",!0),trend:n.getter("KPI_TREND['#text']",!0),statusGraphic:n.getter("KPI_STATUS_GRAPHIC['#text']",!0),trendGraphic:n.getter("KPI_TREND_GRAPHIC['#text']",!0),description:n.getter("KPI_DESCRIPTION['#text']",!0),groupName:n.getter("MEASUREGROUP_NAME['#text']",!0)},dimensions:{name:n.getter("DIMENSION_NAME['#text']",!0),caption:n.getter("DIMENSION_CAPTION['#text']",!0),description:n.getter("DESCRIPTION['#text']",!0),uniqueName:n.getter("DIMENSION_UNIQUE_NAME['#text']",!0),defaultHierarchy:n.getter("DEFAULT_HIERARCHY['#text']",!0),type:n.getter("DIMENSION_TYPE['#text']",!0)},hierarchies:{name:n.getter("HIERARCHY_NAME['#text']",!0),caption:n.getter("HIERARCHY_CAPTION['#text']",!0),description:n.getter("DESCRIPTION['#text']",!0),uniqueName:n.getter("HIERARCHY_UNIQUE_NAME['#text']",!0),dimensionUniqueName:n.getter("DIMENSION_UNIQUE_NAME['#text']",!0),displayFolder:n.getter("HIERARCHY_DISPLAY_FOLDER['#text']",!0),origin:n.getter("HIERARCHY_ORIGIN['#text']",!0),defaultMember:n.getter("DEFAULT_MEMBER['#text']",!0)},levels:{name:n.getter("LEVEL_NAME['#text']",!0),caption:n.getter("LEVEL_CAPTION['#text']",!0),description:n.getter("DESCRIPTION['#text']",!0),uniqueName:n.getter("LEVEL_UNIQUE_NAME['#text']",!0),dimensionUniqueName:n.getter("DIMENSION_UNIQUE_NAME['#text']",!0),displayFolder:n.getter("LEVEL_DISPLAY_FOLDER['#text']",!0),orderingProperty:n.getter("LEVEL_ORDERING_PROPERTY['#text']",!0),origin:n.getter("LEVEL_ORIGIN['#text']",!0),hierarchyUniqueName:n.getter("HIERARCHY_UNIQUE_NAME['#text']",!0)},members:{name:n.getter("MEMBER_NAME['#text']",!0),caption:n.getter("MEMBER_CAPTION['#text']",!0),uniqueName:n.getter("MEMBER_UNIQUE_NAME['#text']",!0),dimensionUniqueName:n.getter("DIMENSION_UNIQUE_NAME['#text']",!0),hierarchyUniqueName:n.getter("HIERARCHY_UNIQUE_NAME['#text']",!0),levelUniqueName:n.getter("LEVEL_UNIQUE_NAME['#text']",!0),childrenCardinality:n.getter("CHILDREN_CARDINALITY['#text']",!0)}},Xe=["axes","catalogs","cubes","dimensions","hierarchies","levels","measures"],Ze=n.data.XmlDataReader.extend({init:function(e){n.data.XmlDataReader.call(this,e),this._extend(e)},_extend:function(e){for(var t,n,i=0,r=Xe.length;i<r;i++)(n=e[t=Xe[i]])&&n!==f&&(this[t]=n)},parse:function(e){var t=n.data.XmlDataReader.fn.parse(e.replace(/<(\/?)(\w|-)+:/g,"<$1"));return n.getter("['Envelope']['Body']",!0)(t)},errors:function(e){var t=n.getter("['Fault']",!0)(e);return t?[{faultstring:n.getter("faultstring['#text']",!0)(t),faultcode:n.getter("faultcode['#text']",!0)(t)}]:null},axes:function(e){e=n.getter('ExecuteResponse["return"].root',!0)(e);for(var t,i=Ke(n.getter("Axes.Axis",!0)(e)),r={columns:{},rows:{}},o=0;o<i.length;o++)"sliceraxis"!==(t=i[o])["@name"].toLowerCase()&&(r.columns.tuples?r.rows=Ye(t):r.columns=Ye(t));return r},data:function(e){e=n.getter('ExecuteResponse["return"].root',!0)(e);for(var t=Ke(n.getter("CellData.Cell",!0)(e)),i=[],r=n.getter("['@CellOrdinal']"),o=n.getter("Value['#text']"),a=n.getter("FmtValue['#text']"),s=0;s<t.length;s++)i.push({value:o(t[s]),fmtValue:a(t[s]),ordinal:parseInt(r(t[s]),10)});return i},_mapSchema:function(e,t){e=n.getter('DiscoverResponse["return"].root',!0)(e);for(var i=Ke(n.getter("row",!0)(e)),r=[],o=0;o<i.length;o++){var a={};for(var s in t)a[s]=t[s](i[o]);r.push(a)}return r},measures:function(e){return this._mapSchema(e,Qe.measures)},kpis:function(e){return this._mapSchema(e,Qe.kpis)},hierarchies:function(e){return this._mapSchema(e,Qe.hierarchies)},levels:function(e){return this._mapSchema(e,Qe.levels)},dimensions:function(e){return this._mapSchema(e,Qe.dimensions)},cubes:function(e){return this._mapSchema(e,Qe.cubes)},catalogs:function(e){return this._mapSchema(e,Qe.catalogs)},members:function(e){return this._mapSchema(e,Qe.members)}});g(!0,n.data,{PivotDataSource:he,PivotDataSourceV2:ue,XmlaTransport:qe,XmlaDataReader:Ze,PivotCubeBuilder:ce,transports:{xmla:qe},readers:{xmla:Ze}});var Je=function(e,t){for(var n=[],i=0,r=e.length;i<r;i++)e[i].field!==t&&n.push(e[i]);return n};n.ui.PivotSettingTarget=s.extend({init:function(t,r){var o=this;if(s.fn.init.call(o,t,r),o.element.addClass("k-pivot-setting"),o.dataSource=n.data.PivotDataSource.create(r.dataSource),o._refreshHandler=o.refresh.bind(o),o.dataSource.first(w,o._refreshHandler),!r.template){var a="";o.options.enabled&&(a=`<span class="k-setting-delete k-chip-action">${n.ui.icon("x")}</span>`),o.options.template=e=>`<span class="k-chip k-chip-md k-rounded-md k-chip-solid k-chip-solid-base" data-${n.ns}name="${e.name||e}"><span class="k-chip-content"><span class="k-chip-text">${e.name||e}</span></span><span class="k-chip-actions">`+a+"</span></span>"}o.template=n.template(o.options.template),o.emptyTemplate=n.template(o.options.emptyTemplate),o._sortable(),o.element.on("click"+A,".k-chip, .k-button",(function(t){var i=e(t.target).closest(":not(path,svg)"),r=i.closest(".k-chip-action"),a=i.closest("["+n.attr("name")+"]").attr(n.attr("name"));if(a)if(r.hasClass("k-setting-delete"))o.remove(a);else if(!(i.closest(".k-chip-actions").length>0)&&o.options.sortable){var s=e(t.currentTarget).closest(":not(path,svg)").find(".k-i-sort-asc-small,.k-svg-i-sort-asc-small").length?"desc":"asc";o.sort({field:a,dir:s})}})),(r.filterable||r.sortable)&&(o.fieldMenu=new i.PivotFieldMenu(o.element,{messages:o.options.messages.fieldMenu,filter:".k-setting-fieldmenu",filterable:r.filterable,sortable:r.sortable,dataSource:o.dataSource})),o.refresh()},options:{name:"PivotSettingTarget",template:null,filterable:!1,sortable:!1,emptyTemplate:e=>`<div class='k-empty'>${e}</div>`,setting:"columns",enabled:!0,messages:{empty:"Drop Fields Here"}},setDataSource:function(e){this.dataSource.unbind(w,this._refreshHandler),this.dataSource=this.options.dataSource=e,this.fieldMenu&&this.fieldMenu.setDataSource(e),e.first(w,this._refreshHandler),this.refresh()},_sortable:function(){var e=this;e.options.enabled&&(this.sortable=this.element.kendoSortable({connectWith:this.options.connectWith,hint:e.options.hint,filter:">*:not(.k-empty)",cursor:"move",start:function(e){e.item.trigger("focus").trigger("blur")},change:function(t){var i=t.item.attr(n.attr("name"));"receive"==t.action?e.add(i):"remove"==t.action?e.remove(i):"sort"==t.action&&e.move(i,t.newIndex)}}).data("kendoSortable"))},_isKPI:function(e){return"kpi"===e.type||e.measure},validate:function(e){var t=2==e.type||"aggregator"in e||this._isKPI(e);if(t)return"measures"===this.options.setting;if("measures"===this.options.setting)return t;var n=this.dataSource[this.options.setting](),i=e.defaultHierarchy||e.uniqueName;return!(Fe(i,n)>-1)&&!(Fe(i,n=this.dataSource["columns"===this.options.setting?"rows":"columns"]())>-1)},add:function(e){let t=this.dataSource[this.options.setting](),n=0,i=(e=Array.isArray(e)?e.slice(0):[e]).length;for(;n<i;)-1!==Fe(e[n],t)&&(e.splice(n,1),n-=1,i-=1),n++;e.length&&(t=t.concat(e),this.dataSource[this.options.setting](t))},move:function(e,t){var n=this.dataSource[this.options.setting](),i=Fe(e,n);i>-1&&(e=n.splice(i,1)[0],n.splice(t,0,e),this.dataSource[this.options.setting](n))},remove:function(e){var t=this.dataSource[this.options.setting](),n=Fe(e,t),i=this.dataSource.sort(),r=this.dataSource.filter();n>-1&&(r&&(r.filters=Je(r.filters,e),this.dataSource._filter.filters=r.filters,r.filters.length||(this.dataSource._filter=null)),i&&(i=Je(i,e),this.dataSource._sort=i),t.splice(n,1),this.dataSource[this.options.setting](t))},sort:function(e){var t=this.options.sortable,n=(!0===t||t.allowUnsort)&&"asc"===e.dir,i=this.dataSource.sort()||[],r=Je(i,e.field);n&&i.length!==r.length&&(e=null),e&&r.push(e),this.dataSource.sort(r)},refresh:function(){var e,n="",i=this.dataSource[this.options.setting](),r=i.length,o=0;if(r)for(;o<r;o++)e=(e=i[o]).name===t?{name:e}:e,n+=this.template(g({sortIcon:this._sortIcon(e.name)},e));else n=this.emptyTemplate(this.options.messages.empty);this.element.html(n)},destroy:function(){s.fn.destroy.call(this),this.dataSource.unbind(w,this._refreshHandler),this.element.off(A),this.sortable&&this.sortable.destroy(),this.fieldMenu&&this.fieldMenu.destroy(),this.element=null,this._refreshHandler=null},_sortIcon:function(e){var t=function(e,t){if(!e)return null;for(var n=0,i=e.length;n<i;n++)if(e[n].field===t)return e[n];return null}(this.dataSource.sort(),Re(e)),n="";return t&&(n="sort-"+t.dir),n}}),n.ui.PivotSettingTargetV2=s.extend({init:function(t,r){var o=this;s.fn.init.call(o,t,r),o.dataSource=n.data.PivotDataSourceV2.create(r.dataSource),o._refreshHandler=o.refresh.bind(o),o.dataSource.first(w,o._refreshHandler),o.template=n.template(o.options.template),o._sortable(),o.element.on("click"+A,".k-i-x-circle,.k-svg-i-x-circle",(function(t){var n=e(t.target).closest(":not(path,svg)").closest(".k-chip"),i=n.find(".k-chip-label").text();i&&(o.remove(i),n.remove(),o.trigger("remove",{name:i}))})),o.options.navigatable&&o.element.on("keydown"+A,".k-chip",(function(t){var n=e(t.target),i=t.keyCode,r=n.find(".k-chip-label").text();if(i===v.DELETE||i===v.BACKSPACE){const e=o.options.configuratorNavigation?o.options.configuratorNavigation.elements.indexOf(n[0]):-1;if(n.find(".k-i-x-circle,.k-svg-i-x-circle").trigger("click"),!o.options.configuratorNavigation)return;o.options.configuratorNavigation.focusElement(o.options.configuratorNavigation.elements[e-1])}else if(i===v.DOWN&&t.altKey)n.find(".k-i-more-vertical,.k-svg-i-more-vertical").trigger("click");else if(t.ctrlKey&&t.shiftKey)if(i==v.LEFT){if(o.move(r,Math.max(0,n.index()-1)),!o.options.configuratorNavigation)return;o.options.configuratorNavigation.focusElement(o.element.find(".k-chip .k-chip-label").filter(((t,n)=>e(n).text()==r)).closest(".k-chip")[0])}else if(i==v.RIGHT){if(o.move(r,Math.min(n.index()+1,n.parent().find("> .k-chip").length-1)),!o.options.configuratorNavigation)return;o.options.configuratorNavigation.focusElement(o.element.find(".k-chip .k-chip-label").filter(((t,n)=>e(n).text()==r)).closest(".k-chip")[0])}else if(i==v.UP&&"rows"==o.options.setting||i==v.DOWN&&"columns"==o.options.setting){let e=o.sortable.options.connectWith.data("kendoPivotSettingTargetV2");if(!e)return;if(o.remove(r),e.add(r),!o.options.configuratorNavigation)return;o.options.configuratorNavigation.focusElement(e.element.find(".k-chip").last()[0])}})),o.fieldMenu=new i.PivotFieldMenuV2(o.element,{messages:o.options.messages.fieldMenu,filterable:r.filterable,filter:".k-i-more-vertical,.k-svg-i-more-vertical",sortable:r.sortable,dataSource:o.dataSource,setting:r.setting}),o.refresh()},events:["remove"],options:{name:"PivotSettingTargetV2",template:null,filterable:!1,sortable:!1,setting:"columns",enabled:!0,messages:{empty:"Drop Fields Here"}},setDataSource:function(e){this.dataSource.unbind(w,this._refreshHandler),this.dataSource=this.options.dataSource=e,this.fieldMenu&&this.fieldMenu.setDataSource(e),e.first(w,this._refreshHandler),this.refresh()},_applyState:function(){this._sortState!==t&&(this.dataSource._sort=this._sortState,this._sortState=t),this._stateFilter!==t&&(this.dataSource._filter=this._stateFilter,this._stateFilter=t),this.dataSource["_"+this.options.setting]="measures"===this.options.setting?Q(this._savedState):X(this._savedState)},_cancelChanges:function(){this._sortState=t,this._stateFilter=t,this._savedState=n.deepExtend([],this._initialState),this._redraw()},_state:function(e,t){var i=this;if(!e)return i._savedState||[];i._savedState&&!t||(i._initialState=n.deepExtend([],e)),i._savedState=n.deepExtend([],e)},_sortable:function(){var e=this;this.sortable=this.element.kendoSortable({connectWith:this.options.connectWith,hint:e.options.hint,filter:">*:not(.k-empty)",cursor:"move",start:function(e){e.item.trigger("focus").blur()},change:function(t){var n=t.item.find(".k-chip-label").text();"receive"==t.action?e.add(n):"remove"==t.action?e.remove(n):"sort"==t.action&&e.move(n,t.newIndex)}}).data("kendoSortable")},add:function(e){let t=this._state(),n=0,i=(e=Array.isArray(e)?e.slice(0):[e]).length;for(;n<i;)-1!==Fe(e[n],t)&&(e.splice(n,1),n-=1,i-=1),n++;e.length&&(t=t.concat(e),this._state(t),this._redraw())},move:function(e,t){var n=this._state(),i=Fe(e,n);i>-1&&(e=n.splice(i,1)[0],n.splice(t,0,e),this._state(n),this._redraw())},remove:function(e){var t=this._state(),n=Fe(e,t),i=this.dataSource.sort(),r=this.dataSource.filter();n>-1&&(r&&(r.filters=Je(r.filters,e),this._savedFilter=this.dataSource._filter,this._savedFilter.filters=r.filters,r.filters.length||(this._savedFilter=null)),i&&(i=Je(i,e),this._sortState=i),t.splice(n,1),this._state(t),this._redraw())},_emptyState:function(e){e?this.element.html(this.options.messages.empty).addClass("k-settings-description").removeClass("k-chip-list"):this.element.removeClass("k-settings-description").addClass("k-chip-list")},_redraw:function(){var e=this._state()||[];this._emptyState(!e.length),e.length&&this.element.html(this._targetsHTML(e))},_targetsHTML:function(e){var n,i="",r=0;if(e.length)for(;r<e.length;r++)n=(n=e[r]).name===t?{name:n}:n,i+=this.template({name:n.name,menuenabled:true});return i},refresh:function(){if(!this.dataSource._preventRefresh){var e=this.dataSource[this.options.setting]();this._state(e,!0),this._emptyState(!this._state().length),e.length&&this.element.html(this._targetsHTML(e))}},destroy:function(){s.fn.destroy.call(this),this.dataSource.unbind(w,this._refreshHandler),this.element.off(A),this.sortable&&this.sortable.destroy(),this.fieldMenu&&this.fieldMenu.destroy(),this.element=null,this._refreshHandler=null}});var et=s.extend({init:function(t,n){var i=this;s.fn.init.call(i,t,n),i.element=e(t),i._element(),i._attachEvents()},options:{name:"PivotConfiguratorButton",text:"Change settings",configurator:""},destroy:function(){this.element.off(A)},setOptions:function(e){n.deepExtend(this.options,e),this.init(this.element,this.options)},toggle:function(){var t,i=n.attr("role"),r=this.element.closest("["+i+"=pivotcontainer]").find("["+i+"=pivotgridv2]");e("#"+this.options.configurator).toggleClass("k-hidden"),r.length&&((t=r.getKendoPivotGridV2())._setContentWidth(),t._updateDimensions())},_attachEvents:function(){this.element.on("click"+A,this.toggle.bind(this))},_element:function(){var e=this.options;this.element.addClass("k-pivotgrid-configurator-button"),this.element.html(n.format("<span>{0}{1}</span>",e.text,n.ui.icon("gear")))}}),tt=s.extend({init:function(t,n){var i=this;s.fn.init.call(i,t,n),i.element=e(t),i.options=n,i._addClasses()},options:{name:"PivotContainer",configuratorPosition:"left"},setOptions:function(e){n.deepExtend(this.options,e),this.init(this.element,this.options)},_addClasses:function(){var e,t=this.options;switch(this.element.removeClass("k-flex-row k-flex-row-reverse k-flex-column k-flex-column-reverse"),t.configuratorPosition){case"right":default:e="k-flex-row";break;case"left":e="k-flex-row-reverse";break;case"bottom":e="k-flex-column";break;case"top":e="k-flex-column-reverse"}this.element.addClass("k-d-flex k-pos-relative").addClass(e)}}),nt=s.extend({init:function(t,i){var r=this;s.fn.init.call(r,t,i),r._dataSource(),r._bindConfigurator(),r._ariaId=r.element.attr("id")||n.guid(),r._wrapper(),r._columnHeadersWrapper=e('<div class="k-pivotgrid-column-headers"></div>'),r._rowHeadersWrapper=e('<div class="k-pivotgrid-row-headers"></div>'),r._contentWrapper=e('<div class="k-pivotgrid-values"></div>'),r.wrapper.append(r._columnHeadersWrapper),r.wrapper.append(r._rowHeadersWrapper),r.wrapper.append(r._contentWrapper),r._columnBuilder=new dt({template:this.options.columnHeaderTemplate,axes:"columns",ariaId:r._ariaId}),r._rowBuilder=new dt({template:this.options.rowHeaderTemplate,axes:"rows",ariaId:r._ariaId}),r._contentBuilder=new ct({dataCellTemplate:this.options.dataCellTemplate||$,kpiStatusTemplate:this.options.kpiStatusTemplate||V,kpiTrendTemplate:this.options.kpiTrendTemplate||N,measures:this.dataSource._measures,ariaId:r._ariaId}),r._scrollable(),r._rowHeadersWrapper.add(r._columnHeadersWrapper).on("click","span.k-icon,span.k-svg-icon",(function(){var t=e(this),i=t.parent().attr(n.attr("key")),o=t.is(".k-i-chevron-up,.k-svg-i-chevron-up"),a=0!==t.closest(".k-pivotgrid-row-headers").length,s=i.split(","),l=o?H:z;if(!r.trigger(l,{path:s,axis:a?"rows":"columns"})){var c={type:"HEADERS_ACTION_TOGGLE",payload:s,tree:a?r._rowBuilder.getTree():r._columnBuilder.getTree()},d=a?r.dataSource._rows:r.dataSource._columns,u=Ig(d,c);r.dataSource._preventRefresh=!0,r._columnBuilder._exportData={},r._rowBuilder._exportData={},a?r.dataSource.rows(u):r.dataSource.columns(u)}})),r.options.autoBind&&r.dataSource.fetch(),r._aria(),r.options.navigatable&&r._initPivotGridNavigation(),r._initLoader(),n.notify(r)},events:[E,I,z,H],options:{name:"PivotGridV2",autoBind:!0,height:null,columnWidth:null,configurator:"",columnHeaderTemplate:null,rowHeaderTemplate:null,dataCellTemplate:null,kpiStatusTemplate:null,kpiTrendTemplate:null,messages:{emptyCellLabel:"PivotGrid Empty Cell"}},destroy:function(){var t=this;s.fn.destroy.call(t),t.loader&&t.loader.destroy(),t._windowResizeHandler&&(e(window).off(b+A,t._windowResizeHandler),t._windowResizeHandler=null)},_aria:function(){this.element.attr("role","grid")},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this._bindConfigurator(),this.options.autoBind&&e.fetch()},_initLoader:function(t){var n=this,i={size:"medium",messages:{exporting:"Exporting..."}};i=e.extend({},i,t);const r=e("<div></div>").kendoLoader(i).data("kendoLoader");n.loader=r,n._loaderContainer=Af.bind(n)},_initPivotGridNavigation:function(){var e=this;e.navigation=new Sv({tabIndex:0}),e.navigation.keyboardEvents.keydown.o=function(e,t,n){if(!t.root)return;let i=t.root.nextElementSibling;i&&i instanceof HTMLElement&&(i.matches("div.k-pivotgrid-configurator-button")||(i=i.nextElementSibling),i&&i instanceof HTMLElement&&i.matches("div.k-pivotgrid-configurator-button")&&(t.root.parentNode&&!t.root.parentNode.querySelector(".k-pivotgrid-configurator.k-hidden")||i.click(),setTimeout((()=>{if(t.root.parentNode){const e=t.root.parentNode.querySelector(".k-pivotgrid-configurator-content .k-form-field .k-fields-list-wrapper .k-treeview");e instanceof HTMLElement&&(e.setAttribute("tabindex",String(t.tabIndex)),e.focus())}}),0)))},e.navigation.start(e.element[0]);const t=e.navigation.first;t&&t.setAttribute("tabindex","0")},_matchAriaAttributes:function(e){var t=this;const n=e.querySelectorAll(".k-pivotgrid-row-headers .k-pivotgrid-row"),i=n[0]?Array.from(n[0].children).reduce(((e,t)=>e+(null!==t.getAttribute("colspan")?+t.getAttribute("colspan"):1)),0):[],r=e.querySelectorAll(".k-pivotgrid-column-headers tr"),o=e.querySelectorAll(".k-pivotgrid-column-headers th"),a=e.querySelectorAll(".k-pivotgrid-values td"),s=e.querySelector(".k-pivotgrid-empty-cell");s.setAttribute("aria-rowspan",r.length.toString()),s.setAttribute("aria-colspan",i.toString());const l=r[0],c=l?Array.from(l.children).map((e=>e.getAttribute("id"))).join(" "):[];l&&l.setAttribute("aria-owns",`${s.getAttribute("id")} ${c}`),n.forEach(((e,n)=>{const i=t.filterAndMap(Array.from(a),(e=>{const t=e.getAttribute("id").split("-");return t[t.length-2]===(n+1).toString()}),(e=>e.getAttribute("id")));e.setAttribute("aria-owns",i.join(" "))})),a.forEach((e=>{const n=e.getAttribute("id").split("-"),i=+n[n.length-1],r=t.filterAndMap(Array.from(o),(e=>{const t=e.getAttribute("id").split("-"),n=+t[t.length-1],r=+e.getAttribute("colspan");return i===n||r>1&&n<i&&n+r-1>=i}),(e=>e.getAttribute("id")));e.setAttribute("aria-describedby",r.join(" "))}))},filterAndMap:function(e,t,n){return e.reduce(((e,i)=>t(i)?[...e,n(i)]:e),[])},_dataSource:function(){var e=this,t=e.options.dataSource;t=Array.isArray(t)?{data:t}:t,e.dataSource&&this._refreshHandler?e.dataSource.unbind(w,e._refreshHandler).unbind(x,e._progressHandler).unbind(k,e._errorHandler):(e._refreshHandler=e.refresh.bind(e),e._progressHandler=e._requestStart.bind(e),e._errorHandler=e._error.bind(e)),e.dataSource=n.data.PivotDataSourceV2.create(t).bind(w,e._refreshHandler).bind(x,e._progressHandler).bind(k,e._errorHandler)},_resize:function(){this.wrapper[0].style.setProperty("--kendo-scrollbar-width",n.format("{0}px",function(){var e,t=0;return document&&document.createElement&&((e=document.createElement("div")).style.cssText="overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block",e.innerHTML="&nbsp;",document.body.appendChild(e),t=e.offsetWidth-e.scrollWidth,document.body.removeChild(e)),t}()))},_scrollable:function(){var t=this,i=t._columnHeadersWrapper,r=t._rowHeadersWrapper;t._resize(),t._windowResizeHandler=t._resize.bind(t),t._contentWrapper.scroll((function(){n.scrollLeft(i,this.scrollLeft),r.scrollTop(this.scrollTop)})),r.bind("DOMMouseScroll"+A+" mousewheel"+A,t._wheelScroll.bind(t)),e(window).on(b+A,t._windowResizeHandler)},_wheelScroll:function(t){if(!t.ctrlKey){var i=n.wheelDeltaY(t),r=this._contentWrapper.scrollTop();i&&(t.preventDefault(),e(t.currentTarget).one("wheel"+A,!1),this._rowHeadersWrapper.scrollTop(r+-i),this._contentWrapper.scrollTop(r+-i))}},_wrapper:function(){var t=this.options.height;this.wrapper=this.element.addClass("k-pivotgrid");var n=e(`<span class="k-pivotgrid-empty-cell" id="${this._ariaId}-empty-cell" role="columnheader"><span class="k-sr-only">${this.options.messages.emptyCellLabel}</span></span>`);this.wrapper.append(n),t&&this.wrapper.css("height",t)},_progress:function(e){this._isExport?this._loaderContainer(e,{message:"Exporting..."}):n.ui.progress(this.wrapper,e)},_error:function(){this._progress(!1)},_requestStart:function(){this._progress(!0)},_updateDimensions:function(){var e=this;e.wrapper.css({"grid-template-columns":n.format("{0}px 1fr",e._rowHeadersWrapper.find(".k-pivotgrid-table")[0].offsetWidth),"grid-template-rows":n.format("{0}px 1fr",e._columnHeadersWrapper.find(".k-pivotgrid-table")[0].offsetHeight)})},_setContentWidth:function(){if(this.options.columnWidth){var e=this._contentWrapper.find("table"),t=this._columnHeadersWrapper.children("table"),n=this._rowHeadersWrapper.children("table");e.add(t).add(n).find("col").width(this.options.columnWidth)}},_bindConfigurator:function(){var t=this.options.configurator;t&&e(t).kendoPivotConfiguratorV2("setDataSource",this.dataSource)},cellInfoByElement:function(t){return t=e(t),this.cellInfo(t.index(),t.parent("tr").index())},cellInfo:function(e,t){var n,i,r=this._contentBuilder;return e>=r.columnsCount||e<0||t>=r.rowsCount||t<0?null:(n=t*r.columnsCount+e,{columnTuple:(i=r.hash[n<0?0:n]).columnTuple,rowTuple:i.rowTuple,dataItem:i.data})},refresh:function(){var e=this,t=e.dataSource;if(!e.trigger(E,{action:"rebind"})){var i=n._activeElement()?n._activeElement().id:null,r=e.wrapper.find("[tabindex=0]").attr("id");if(e._columnBuilder.setTuples(t._columnTuples),e._columnHeadersWrapper.html(e._columnBuilder.build()),e._rowBuilder.setTuples(t._rowTuples),e._rowHeadersWrapper.html(e._rowBuilder.build()),e._contentBuilder.setRowColumnInfo({columnHeaderLeafs:e._columnBuilder.getHeaderLeafs(),rowHeaderLeafs:e._rowBuilder.getHeaderLeafs(),columnHeaderBreadth:e._columnBuilder.getBreadth(),rowHeaderDepth:e._rowBuilder.getBreadth(),data:t._view}),e._contentWrapper.html(e._contentBuilder.build()),e._setContentWidth(),e._updateDimensions(),e._progress(!1),e.trigger(I),e._matchAriaAttributes(e.wrapper[0]),e.navigation){if(r&&e.element.find(`#${r}`).length>0)e.element.find(`#${r}`).attr("tabindex","0");else{const t=e.navigation.first;t&&t.setAttribute("tabindex","0")}i&&0==i.indexOf(e._ariaId)&&e.navigation.focusElement(e.element.find(`#${i}`)[0])}}}});i.plugin(et),i.plugin(tt),i.plugin(nt);var it=s.extend({init:function(i,r){var o,a,l=this;s.fn.init.call(l,i,r),L=n.support.isRtl(l.element)?"caret-alt-left":"caret-alt-right",l._dataSource(),l._bindConfigurator(),l._wrapper(),l._createLayout(),l._columnBuilder=o=new ut,l._rowBuilder=a=new ht,l._contentBuilder=new pt,l._templates(),l.columnsHeader.add(l.rowsHeader).on("click","span.k-icon,span.k-svg-icon",(function(){var i,r=e(this),s=o,c="expandColumn",d=r.attr(n.attr("path")),u={axis:"columns",path:JSON.parse(d)};r.parent().is("td")&&(s=a,c="expandRow",u.axis="rows");var h=r.is(R),p=s.metadata[d],f=p.expanded===t;i=h?H:z,u.childrenLoaded=p.maxChildren>p.children,l.trigger(i,u)||(s.metadata[d].expanded=!h,n.ui.icon(r,{icon:h?L:F}),!h&&f?l.dataSource[c](u.path):l.refresh())})),l._scrollable(),l.options.autoBind&&l.dataSource.fetch(),n.notify(l)},events:[E,I,z,H],options:{name:"PivotGrid",autoBind:!0,reorderable:!0,filterable:!1,sortable:!1,navigatable:!1,height:null,columnWidth:100,configurator:"",columnHeaderTemplate:null,rowHeaderTemplate:null,dataCellTemplate:null,kpiStatusTemplate:null,kpiTrendTemplate:null,messages:{measureFields:"Drop Data Fields Here",columnFields:"Drop Column Fields Here",rowFields:"Drop Rows Fields Here"}},_templates:function(){var e=this.options.columnHeaderTemplate,t=this.options.rowHeaderTemplate,i=this.options.dataCellTemplate,r=this.options.kpiStatusTemplate,o=this.options.kpiTrendTemplate;this._columnBuilder.template=n.template(e||B,{useWithBlock:!!e}),this._contentBuilder.dataTemplate=n.template(i||$,{useWithBlock:!!i}),this._contentBuilder.kpiStatusTemplate=n.template(r||V,{useWithBlock:!!r}),this._contentBuilder.kpiTrendTemplate=n.template(o||N,{useWithBlock:!!o}),this._rowBuilder.template=n.template(t||B,{useWithBlock:!!t})},_bindConfigurator:function(){var t=this.options.configurator;t&&e(t).kendoPivotConfigurator("setDataSource",this.dataSource)},cellInfoByElement:function(t){return t=e(t),this.cellInfo(t.index(),t.parent("tr").index())},cellInfo:function(e,t){var n,i=this._contentBuilder,r=i.columnIndexes[e||0],o=i.rowIndexes[t||0];return r&&o?(n=o.index*i.rowLength+r.index,{columnTuple:r.tuple,rowTuple:o.tuple,measure:r.measure||o.measure,dataItem:this.dataSource.view()[n]}):null},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.measuresTarget&&this.measuresTarget.setDataSource(e),this.rowsTarget&&this.rowsTarget.setDataSource(e),this.columnsTarget&&this.columnsTarget.setDataSource(e),this._bindConfigurator(),this.options.autoBind&&e.fetch()},setOptions:function(e){s.fn.setOptions.call(this,e),this._templates()},destroy:function(){s.fn.destroy.call(this),clearTimeout(this._headerReflowTimeout)},_dataSource:function(){var e=this,t=e.options.dataSource;t=Array.isArray(t)?{data:t}:t,e.dataSource&&this._refreshHandler?e.dataSource.unbind(w,e._refreshHandler).unbind(S,e._stateResetHandler).unbind(x,e._progressHandler).unbind(k,e._errorHandler):(e._refreshHandler=e.refresh.bind(e),e._progressHandler=e._requestStart.bind(e),e._stateResetHandler=e._stateReset.bind(e),e._errorHandler=e._error.bind(e)),e.dataSource=n.data.PivotDataSource.create(t).bind(w,e._refreshHandler).bind(x,e._progressHandler).bind(S,e._stateResetHandler).bind(k,e._errorHandler)},_error:function(){this._progress(!1)},_requestStart:function(){this._progress(!0)},_stateReset:function(){this._columnBuilder.reset(),this._rowBuilder.reset()},_wrapper:function(){var e=this.options.height;this.wrapper=this.element.addClass("k-pivot"),e&&this.wrapper.css("height",e)},_measureFields:function(){this.measureFields=e(D).addClass("k-pivot-toolbar k-toolbar k-toolbar-md k-settings-measures"),this.measuresTarget=this._createSettingTarget(this.measureFields,{setting:"measures",messages:{empty:this.options.messages.measureFields}})},_createSettingTarget:function(t,i){var r,o=this.options;return r=({sortIcon:e,name:t})=>`<span class="k-chip k-chip-md k-rounded-md k-chip-solid k-chip-solid-base" tabindex="0" data-${n.ns}name="${t}"><span class="k-chip-content"><span class="k-chip-text">${t}</span></span><span class="k-chip-actions k-field-actions">`+function(e,t,i){var r=t.sortable,o=t.filterable,a=i.reorderable,s="";return r&&(s+=e?`<span class="k-chip-action">${n.ui.icon(e+"-sm")}</span>`:""),(o||r)&&(s+=`<span class="k-setting-fieldmenu k-chip-action">${n.ui.icon("more-vertical")}</span>`),a&&(s+=`<span class="k-setting-delete k-chip-action">${n.ui.icon("x")}</span>`),s}(e,i,o)+"</span></span>",new n.ui.PivotSettingTarget(t,e.extend({dataSource:this.dataSource,template:r,emptyTemplate:e=>`<span class="k-empty">${e}</span>`,enabled:this.options.reorderable},i))},_initSettingTargets:function(){this.columnsTarget=this._createSettingTarget(this.columnFields,{connectWith:this.rowFields,setting:"columns",filterable:this.options.filterable,sortable:this.options.sortable,messages:{empty:this.options.messages.columnFields,fieldMenu:this.options.messages.fieldMenu}}),this.rowsTarget=this._createSettingTarget(this.rowFields,{connectWith:this.columnFields,setting:"rows",filterable:this.options.filterable,sortable:this.options.sortable,messages:{empty:this.options.messages.rowFields,fieldMenu:this.options.messages.fieldMenu}})},_createLayout:function(){var t=this,i=e('<table class="k-pivot-layout"><tr><td><div class="k-pivot-rowheaders"></div></td><td><div class="k-pivot-table"></div></td></tr></table>'),r=i.find(".k-pivot-rowheaders"),o=i.find(".k-pivot-table"),a=e(D).addClass("k-grid");t._measureFields(),t.columnFields=e(D).addClass("k-pivot-toolbar k-toolbar k-toolbar-md k-settings-columns"),t.rowFields=e(D).addClass("k-pivot-toolbar k-toolbar k-toolbar-md k-settings-rows"),t.columnsHeader=e('<div class="k-grid-header-wrap" />').wrap('<div class="k-grid-header" />'),t.columnsHeader.parent().css("padding-right",n.support.scrollbar()),t.rowsHeader=e('<div class="k-grid k-alt"/>'),t.content=e('<div class="k-grid-content" />'),r.append(t.measureFields),r.append(t.rowFields),r.append(t.rowsHeader),a.append(t.columnsHeader.parent()),a.append(t.content),o.append(t.columnFields),o.append(a),t.wrapper.append(i),t.columnsHeaderTree=new n.dom.Tree(t.columnsHeader[0]),t.rowsHeaderTree=new n.dom.Tree(t.rowsHeader[0]),t.contentTree=new n.dom.Tree(t.content[0]),t._initSettingTargets()},_progress:function(e){n.ui.progress(this.wrapper,e)},_resize:function(){this.content[0].firstChild&&(this._setSectionsWidth(),this._setSectionsHeight(),this._setContentWidth(),this._setContentHeight(),this._columnHeaderReflow())},_columnHeaderReflow:function(){var e=this.columnsHeader.children("table");n.support.browser.mozilla&&(clearTimeout(this._headerReflowTimeout),e.css("table-layout","auto"),this._headerReflowTimeout=setTimeout((function(){e.css("table-layout","")})))},_setSectionsWidth:function(){var e,t=this.rowsHeader,n=t.parent(".k-pivot-rowheaders").width(T);e=Math.max(c(this.measureFields),c(this.rowFields)),e=Math.max(t.children("table").width(),e),n.width(e)},_setSectionsHeight:function(){var e=this.measureFields.height(T).height(),t=this.columnFields.height(T).height(),n=this.rowFields.height(T).innerHeight(),i=this.columnsHeader.height(T).innerHeight(),r=n-this.rowFields.height(),o=t>e?t:e,a=i>n?i:n;this.measureFields.height(o),this.columnFields.height(o),this.rowFields.height(a-r),this.columnsHeader.height(a)},_setContentWidth:function(){var e=this.content.find("table"),t=this.columnsHeader.children("table"),n=e.children("colgroup").children().length*this.options.columnWidth,i=Math.ceil(n/this.content.width()*100);i<100&&(i=100),e.add(t).css("width",i+"%"),this._resetColspan(t)},_setContentHeight:function(){var e=this,t=e.content,i=e.rowsHeader,r=e.wrapper.innerHeight(),o=n.support.scrollbar(),a=t[0].offsetHeight===t[0].clientHeight,s=e.options.height;if(e.wrapper.is(":visible")){if(!r||!s)return a&&(o=0),t.height("auto"),void i.height(t.height()-o);r-=d(e.columnFields),(r-=d(e.columnsHeader.parent()))<=2*o&&(r=2*o+1,a||(r+=o)),t.height(r),a&&(o=0),i.height(r-o)}},_resetColspan:function(e){var n=this,i=e.children("tbody").children().first().children().first();n._colspan===t&&(n._colspan=i.attr("colspan")),i.attr("colspan",1),clearTimeout(n._layoutTimeout),n._layoutTimeout=setTimeout((function(){i.attr("colspan",n._colspan),n._colspan=t}))},_axisMeasures:function(e){var t=[],n=this.dataSource,i=n.measures(),r=i.length>1||i[0]&&i[0].type;return n.measuresAxis()===e&&(0===n[e]().length||r)&&(t=i),t},items:function(){return[]},refresh:function(){var e,t,i=this,r=i.dataSource,o=r.axes(),a=(o.columns||{}).tuples||[],s=(o.rows||{}).tuples||[],l=i._columnBuilder,c=i._rowBuilder;if(!i.trigger(E,{action:"rebind"})){if(l.measures=i._axisMeasures("columns"),c.measures=i._axisMeasures("rows"),i.columnsHeaderTree.render(l.build(a)),i.rowsHeaderTree.render(c.build(s)),e={indexes:l._indexes,measures:l.measures,metadata:l.metadata},t={indexes:c._indexes,measures:c.measures,metadata:c.metadata},i.contentTree.render(i._contentBuilder.build(r.view(),e,t)),i._resize(),i.touchScroller)i.touchScroller.contentResized();else{var d=n.touchScroller(i.content);d&&d.movable&&(i.touchScroller=d,d.movable.bind("change",(function(e){n.scrollLeft(i.columnsHeader,-e.sender.x),i.rowsHeader.scrollTop(-e.sender.y)})))}i._progress(!1),i.trigger(I)}},_scrollable:function(){var e=this,t=e.columnsHeader,i=e.rowsHeader;e.content.on("scroll",(function(){n.scrollLeft(t,this.scrollLeft),i.scrollTop(this.scrollTop)})),i.on("DOMMouseScroll"+A+" mousewheel"+A,e._wheelScroll.bind(e))},_wheelScroll:function(t){if(!t.ctrlKey){var i=n.wheelDeltaY(t),r=this.content.scrollTop();i&&(t.preventDefault(),e(t.currentTarget).closest(":not(path,svg)").one("wheel"+A,!1),this.rowsHeader.scrollTop(r+-i),this.content.scrollTop(r+-i))}}}),rt=n.dom.element,ot=n.dom.html,at=function(e,t){return{maxChildren:0,children:0,maxMembers:0,members:0,measures:1,levelNum:e,parentMember:0!==t}},st=function(e,t){for(var n=[],i=0;i<=t;i++)n.push(e.members[i].name);return n},lt=function(e,t){for(var n="",i=0;i<=t;i++)n+=e.members[i].name;return n},ct=o.extend({init:function(e){this.dataCellTemplate=n.template(e.dataCellTemplate),this.kpiStatusTemplate=n.template(e.kpiStatusTemplate),this.kpiTrendTemplate=n.template(e.kpiTrendTemplate),this.measures=e.measures,this.ariaId=e.ariaId,this.hash=[]},setRowColumnInfo:function(e){this.data=e.data,this.columnHeaderLeafs=e.columnHeaderLeafs,this.rowHeaderLeafs=e.rowHeaderLeafs,this.columnHeaderBreadth=e.columnHeaderBreadth,this.rowHeaderDepth=e.rowHeaderDepth,this.hash.length=0},addColElements:function(e){for(var t="",n=0;n<e;n++)t+="<col>";this.table.find("colgroup").append(t)},addRowElements:function(t){for(var n,i=this.table.find("tbody"),r=0;r<t.length;r++)n=e("<tr class=\"k-pivotgrid-row\" role='presentation'></tr>"),i.append(n),this.addColumCell(n,t[r],r);this.rowsCount=t.length},_getTemplate:function(e,t){let n;const i=e.columnTuple.members,r=i[i.length-1],o=this.measures&&this.measures.find((e=>e.name===r.name)),a=null!==e.data?e.data.value:e.data;o&&o.type&&(n=o.type);let s=this.dataCellTemplate;if(this.measures&&n&&""!==a)switch(t.dataItem||(t.dataItem={value:isNaN(Number(a))?a:Number(a)}),n){case"status":s=this.kpiStatusTemplate;break;case"trend":s=this.kpiTrendTemplate}return s(t)},addColumCell:function(t,n,i){for(var r=0;r<n.cells.length;r++){var o=n.cells[r];if(o){var a=e(`<td id="${this.ariaId}-cell-${i+1}-${r+1}" class="k-pivotgrid-cell" role="gridcell"></td>`);(this.rowHeaderLeafs[i].total||this.columnHeaderLeafs[r].total)&&a.addClass("k-pivotgrid-total"),a.append(this._getTemplate(o,{dataItem:o.data,rowTuple:o.rowTuple,columnTuple:o.columnTuple})),this.hash.push(o),t.append(a)}}},build:function(){var t=hg((this.data||[]).slice(),this.columnHeaderLeafs,this.rowHeaderLeafs,this.columnHeaderBreadth,this.rowHeaderDepth),n=this,i=e("<table class='k-pivotgrid-table' role='presentation'><colgroup></colgroup><tbody class='k-pivotgrid-tbody' role='presentation'></tbody></table>");return n.table=i,n.addColElements(this.columnHeaderLeafs.length),n.addRowElements(t),this.rowsCount=t.length,this.columnsCount=this.columnHeaderLeafs.length,n.table}}),dt=o.extend({init:function(e){this.tuples=e.tuples,this.axes=e.axes,this.ariaId=e.ariaId,this.headerTemplate=n.template(P),this._exportData={},e.template&&(this.template=n.template(e.template))},setTuples:function(e){this.tuples=e},addColElements:function(e){for(var t="",n=0;n<e;n++)t+="<col>";this.table.find("colgroup").append(t)},addRowElements:function(t){for(var n,i=this.table.find("tbody"),r=0;r<t.length;r++)n=e('<tr class="k-pivotgrid-row" role="row"></tr>'),i.append(n),this.addColumCell(n,t[r],r)},_getExportData:function(e,t,n){t.levelName.match(/\[\(All\)\]/)&&(t.caption=t.caption.toUpperCase()),this._exportData[e]?this._exportData[e].children.push(t):this._exportData[e]={children:[t],element:n}},addColumCell:function(t,i,r){for(var o,a,s=this,l=0;l<i.cells.length;l++)if(a=i.cells[l]){this._getExportData(r,a,t);const i=a.children&&a.children.length>0;o=e(s.headerTemplate({id:`${s.ariaId}-${"columns"==s.axes?"ch":"rh"}-${r+1}-${l+1}`,rowspan:a.rowSpan,colspan:a.colSpan,key:a.path.join(",")+(a.total?"|[TOTAL]":""),iconClass:a.children&&a.children.length?"up":"down",expandable:a.hasChildren&&!a.total,expanded:i?"true":"false",headerClass:n.format("k-pivotgrid-cell{0}{1}",a.total?" k-pivotgrid-header-total":"",0===a.levelNum?" k-pivotgrid-header-root":""),role:"columns"==s.axes?"columnheader":"rowheader"})),i&&o.addClass("k-pivotgrid-expanded");const c=`<span class="k-pivotgrid-header-title">${a.caption}</span>`;o.append(s.template?s.template({member:a}):c),t.append(o)}},build:function(){var t=ug((this.tuples||[]).slice()),n="columns"==this.axes?pg(t):fg(t),i=n[0],r=n[1],o=n[2],a=n[3],s=this;s._tree=t,s._breadth=o,s._headerLeafs=r;var l=e("<table class='k-pivotgrid-table' role='presentation'><colgroup></colgroup><tbody class='k-pivotgrid-tbody' role='rowgroup'></tbody></table>");return s.table=l,s.addColElements("columns"==this.axes?r.length:a),s.addRowElements(i),s.table},getTree:function(){return this._tree},getBreadth:function(){return this._breadth},getHeaderLeafs:function(){return this._headerLeafs}}),ut=o.extend({init:function(){this.measures=1,this.metadata={}},build:function(e){var t=this._tbody(e),n=this._colGroup();return[rt("table",{className:j},[n,t])]},reset:function(){this.metadata={}},_colGroup:function(){for(var e=this._rowLength(),t=[],n=0;n<e;n++)t.push(rt("col",null));return rt("colgroup",null,t)},_tbody:function(e){var t=e[0];return this.map={},this.rows=[],this.rootTuple=t,this._indexes=[],t?(this._buildRows(t,0),this._normalize()):this.rows.push(rt("tr",{className:U},[rt("th",{className:W},[ot("&nbsp;")])])),rt("tbody",{className:K},this.rows)},_normalize:function(){for(var e,t,n,i,r,o=this.rows,a=o.length,s=0;s<a;s++)if(1!==(e=o[s]).rowSpan)for(n=0,t=(i=e.children).length;n<t;n++)(r=i[n]).tupleAll&&(r.attr.rowSpan=e.rowSpan)},_rowIndex:function(e){for(var t=this.rows,n=t.length,i=0;i<n&&t[i]!==e;i++);return i},_rowLength:function(){var e=this.rows[0]?this.rows[0].children:[],t=e.length,n=0,i=0;if(t)for(;i<t;i++)n+=e[i].attr.colSpan||1;return n||(n=this.measures),n},_row:function(e,t,n){var i,r,o=this.rootTuple.members[t].name,a=e.members[t].levelNum,s=o+a,l=this.map,c=l[s];return c?(c.notFirst=!1,c.parentMember&&c.parentMember===n||(c.parentMember=n,c.collapsed=0,c.colSpan=0)):((c=rt("tr",{className:U},[])).parentMember=n,c.collapsed=0,c.colSpan=0,c.rowSpan=1,l[s]=c,(i=l[o+(Number(a)-1)])&&((r=i.children)[1]&&-1===r[1].attr.className.indexOf("k-alt")?c.notFirst=!0:c.notFirst=i.notFirst),this.rows.splice(this._rowIndex(i)+1,0,c)),c},_measures:function(e,t,n){var i,r=this.map,o=r.measureRow;o||(o=rt("tr",{className:U},[]),r.measureRow=o,this.rows.push(o));for(var a=0,s=e.length;a<s;a++)i=e[a],o.children.push(this._cell(n||"",[this._content(i,t)],i));return s},_content:function(e,t){return ot(this.template({member:e,tuple:t}),!0)},_cell:function(e,t,n){var i=rt("th",{className:W+" "+e},t);return i.value=n.caption||n.name,i},_buildRows:function(t,i,r){var o,a,s,l,c,d,u,h,p,f=t.members,m=f[i],g=f[i+1],v=[],_=0,b=0,y=0;if(!m.measure){if(u=n.stringify(st(t,i)),o=this._row(t,i,r),l=(s=m.children).length,(h=this.metadata[u])||(this.metadata[u]=h=at(Number(m.levelNum),i),h.rootLevelNum=Number(this.rootTuple.members[i].levelNum)),this._indexes.push({path:u,tuple:t}),m.hasChildren){!1===h.expanded&&(b=h.maxChildren,o.collapsed+=b,h.children=0,l=0);let t=e("<span></span>");t.attr(n.attr("path"),u),v.push(n.dom.html(n.ui.icon(t,{icon:l?F:L}),!0))}if(v.push(this._content(m,t)),c=this._cell(o.notFirst?" k-first":"",v,m),o.children.push(c),o.colSpan+=1,l){for(d=this._cell(" k-alt",[this._content(m,t)],m),o.children.push(d);_<l;_++)a=this._buildRows(s[_],i,m);p=a.colSpan,b=a.collapsed,c.attr.colSpan=p,h.children=p,h.members=1,o.colSpan+=p,o.collapsed+=b,o.rowSpan=a.rowSpan+1,g&&(g.measure?p=this._measures(g.children,t," k-alt"):(p=(a=this._buildRows(t,i+1)).colSpan,o.collapsed+=a.collapsed,y=a.collapsed),d.attr.colSpan=p,p-=1,h.members+=p,o.colSpan+=p)}else g&&(g.measure?p=this._measures(g.children,t):(p=(a=this._buildRows(t,i+1)).colSpan,o.collapsed+=a.collapsed,y=a.collapsed),h.members=p,p>1&&(c.attr.colSpan=p,o.colSpan+=p-1));return h.maxMembers<h.members+y&&(h.maxMembers=h.members+y),s=h.children+b,h.maxChildren<s&&(h.maxChildren=s),(d||c).tupleAll=!0,o}this._measures(m.children,t)}}),ht=o.extend({init:function(){this.metadata={}},build:function(e){var t=this._tbody(e),n=this._colGroup();return[rt("table",{className:q},[n,t])]},reset:function(){this.metadata={}},_rowLength:function(){for(var e=this.rows[0].children,t=0,n=0,i=e[n];i;)t+=i.attr.colSpan||1,i=e[++n];return t},_colGroup:function(){for(var e=this._rowLength(),t=[],n=0;n<e;n++)t.push(rt("col",null));return rt("colgroup",null,t)},_tbody:function(e){var t=e[0];return this.rootTuple=t,this.rows=[],this.map={},this._indexes=[],t?(this._buildRows(t,0),this._normalize()):this.rows.push(rt("tr",{className:U},[rt("td",{className:Y},[ot("&nbsp;")])])),rt("tbody",{className:K},this.rows)},_normalize:function(){for(var e,t,n,i,r=this.rows,o=r.length,a=0,s=this.rootTuple.members,l=s[0].name,c=s.length,d=0,u=this.map;a<o;a++)for(e=r[a],d=0;d<c;d++)n=this[s[d].name],(t=e.colSpan["dim"+d])&&t.colSpan<n&&(t.attr.colSpan=n-t.colSpan+1);e=u[l],i=u[l+"all"],e&&(e.children[0].attr.className=Y+" k-first"),i&&(i.children[0].attr.className+=" k-first "+Y)},_row:function(e){var t=rt("tr",{className:U},e);return t.rowSpan=1,t.colSpan={},this.rows.push(t),t},_content:function(e,t){return ot(this.template({member:e,tuple:t}),!0)},_cell:function(e,t,n){var i=rt("td",{className:Y+" "+e},t);return i.value=n.caption||n.name,i},_buildRows:function(t,i){var r,o,a,s,l,c,d,u,h=this.map,p=t.members,f=p[i],m=p[i+1],g=f.children,v=g.length,_=Number(f.levelNum),b=this.rootTuple.members[i].name,y=st(t,i-1).join(""),w=Number(this.rootTuple.members[i].levelNum),k=y+(w===_?"":f.parentName||""),x=h[k+"all"]||h[k],C=_+1,S=[];if(!x||x.hasChild?x=this._row():x.hasChild=!0,f.measure){for(d=x.allCell?"k-grid-footer":"",x.children.push(this._cell(d,[this._content(g[0],t)],g[0])),x.rowSpan=v,u=1;u<v;u++)this._row([this._cell(d,[this._content(g[u],t)],g[u])]);return x}if(h[y+f.name]=x,r=n.stringify(st(t,i)),(c=this.metadata[r])||(this.metadata[r]=c=at(_,i),c.rootLevelNum=w),this._indexes.push({path:r,tuple:t}),f.hasChildren){!1===c.expanded&&(v=0,c.children=0);let t=e("<span></span>");t.attr(n.attr("path"),r),S.push(n.dom.html(n.ui.icon(t,{icon:v?F:L}),!0))}if(S.push(this._content(f,t)),d=x.allCell&&!v?"k-grid-footer":"",(o=this._cell(d,S,f)).colSpan=C,x.children.push(o),x.colSpan["dim"+i]=o,(!this[b]||this[b]<C)&&(this[b]=C),v){for(x.allCell=!1,x.hasChild=!1,u=0;u<v;u++)x!==(s=this._buildRows(g[u],i))&&(x.rowSpan+=s.rowSpan);x.rowSpan>1&&(o.attr.rowSpan=x.rowSpan),c.children=x.rowSpan,(a=this._cell("k-grid-footer",[this._content(f,t)],f)).colSpan=C,(l=this._row([a])).colSpan["dim"+i]=a,l.allCell=!0,h[y+f.name+"all"]=l,m&&(s=this._buildRows(t,i+1),a.attr.rowSpan=s.rowSpan),x.rowSpan+=l.rowSpan,c.members=l.rowSpan}else m&&(x.hasChild=!1,this._buildRows(t,i+1),(a||o).attr.rowSpan=x.rowSpan,c.members=x.rowSpan);return c.maxChildren<c.children&&(c.maxChildren=c.children),c.maxMembers<c.members&&(c.maxMembers=c.members),x}}),pt=o.extend({init:function(){this.columnAxis={},this.rowAxis={}},build:function(e,n,i){var r=n.indexes[0],o=n.metadata[r?r.path:t];this.columnAxis=n,this.rowAxis=i,this.data=e,this.rowLength=o?o.maxChildren+o.maxMembers:n.measures.length||1,this.rowLength||(this.rowLength=1);var a=this._tbody(),s=this._colGroup();return[rt("table",{className:G},[s,a])]},_colGroup:function(){var e=this.columnAxis.measures.length||1,t=[],n=0;for(this.rows[0]&&(e=this.rows[0].children.length);n<e;n++)t.push(rt("col",null));return rt("colgroup",null,t)},_tbody:function(){return this.rows=[],this.data[0]?(this.columnIndexes=this._indexes(this.columnAxis,this.rowLength),this.rowIndexes=this._indexes(this.rowAxis,Math.ceil(this.data.length/this.rowLength)),this._buildRows()):this.rows.push(rt("tr",{className:U},[rt("td",{className:Y},[ot("&nbsp;")])])),rt("tbody",{className:K},this.rows)},_indexes:function(e,n){var i,r,o,a,s,l=[],c=e.indexes,d=e.metadata,u=e.measures,h=u.length||1,p=0,f=0,m=0,g=c.length;if(!g){for(o=0;o<h;o++)l[o]={index:o,measure:u[o],tuple:null};return l}for(;m<g;m++){if(s=0,(a=(r=d[(i=c[m]).path]).children+r.members)&&(a-=h),!1===r.expanded&&r.children!==r.maxChildren&&(s=r.maxChildren),r.parentMember&&r.levelNum===r.rootLevelNum&&(a=-1),a>-1){for(o=0;o<h;o++)r.children||f,l[a+f+o]={children:a,index:p,measure:u[o],tuple:i.tuple},p+=1;for(;l[f]!==t;)f+=1}if(f===n)break;p+=s}return l},_buildRows:function(){for(var e=this.rowIndexes,t=e.length,n=0;n<t;n++){var i=e[n];i&&this.rows.push(this._buildRow(i))}},_buildRow:function(e){for(var n,i,r,o,a,s,l,c=e.index*this.rowLength,d=this.columnIndexes,u=d.length,h=[],p=0;p<u;p++)(n=d[p])!==t&&(a={className:Y},n.children&&(a.className+=" k-alt"),o="",s=this.data[c+n.index],l=n.measure||e.measure,i={columnTuple:n.tuple,rowTuple:e.tuple,measure:l,dataItem:s},""!==s.value&&l&&l.type&&("status"===l.type?o=this.kpiStatusTemplate(i):"trend"===l.type&&(o=this.kpiTrendTemplate(i))),o||(o=this.dataTemplate(i)),(r=rt("td",a,[ot(o)])).value=s.value,h.push(r));return a={className:U},e.children&&(a.className+=" k-grid-footer"),rt("tr",a,h)}});i.plugin(it),n.PivotExcelExporter=n.Class.extend({init:function(e){this.options=e,this.widget=e.widget,this.dataSource=this.widget.dataSource},_columns:function(){var e,t=this.widget.columnsHeaderTree.children[0],n=this.widget.rowsHeaderTree.children[0],i=t.children[0].children.length,r=n.children[0].children.length,o=this.widget.options.columnWidth,a=[];if(r&&this.dataSource.data()[0])for(e=0;e<r;e++)a.push({autoWidth:!0});for(e=0;e<i;e++)a.push({autoWidth:!1,width:o});return a},_cells:function(e,t,n){for(var i,r,o,a,s,l=[],c=0,d=e.length;c<d;c++){for(r=[],i=(o=e[c].children).length,a=0;a<i;a++)s=o[a],r.push({background:"#7a7a7a",color:"#fff",value:s.value,colSpan:s.attr.colSpan||1,rowSpan:s.attr.rowSpan||1});n&&n(r,c),l.push({cells:r,type:t})}return l},_rows:function(){var e=this.widget.columnsHeaderTree.children[0],t=this.widget.rowsHeaderTree.children[0],n=e.children[0].children.length,i=t.children[0].children.length,r=e.children[1].children,o=t.children[1].children,a=this.widget.contentTree.children[0].children[1].children,s=this._cells(r,"header");i&&s[0].cells.splice(0,0,{background:"#7a7a7a",color:"#fff",value:"",colSpan:i,rowSpan:r.length});var l=this._cells(o,"data",(function(e,t){for(var i,r,o=0,s=a[t].children;o<n;o++)i=s[o],r=Number(i.value),isNaN(r)&&(r=i.value),e.push({background:"#dfdfdf",color:"#333",value:r,colSpan:1,rowSpan:1})}));return s.concat(l)},_freezePane:function(){var e=this.widget.columnsHeaderTree.children[0];return{colSplit:this.widget.rowsHeaderTree.children[0].children[0].children.length,rowSplit:e.children[1].children.length}},_columnsV2:function(){const e=this.widget._columnBuilder.table[0],t=this.widget._rowBuilder.table[0],n=e.children[0].children.length,i=t.children[0].children.length,r=this.widget.options.columnWidth,o=[];if(i&&this.dataSource.data()[0])for(let e=0;e<i;e++)o.push({autoWidth:!0});for(let e=0;e<n;e++)o.push({autoWidth:!1,width:r});return o},_cellsV2:function(e,t,n){const i=[],r=Object.keys(e).length;for(let o=0;o<r;o++){const r=[],a=e[o].children,s=a.length;for(let e=0;e<s;e++){const t=a[e];r.push({background:"#7a7a7a",color:"#fff",value:t.caption,colSpan:t.colSpan||1,rowSpan:t.rowSpan||1})}n&&n(r,o),i.push({cells:r,type:t})}return i},_rowsV2:function(){const e=this.widget._columnBuilder.table[0],t=this.widget._rowBuilder.table[0],n=e.children[0].children.length,i=t.children[0].children.length,r=this.widget._columnBuilder._exportData,o=this.widget._rowBuilder._exportData,a=this.widget._contentBuilder.hash,s=this._cellsV2(r,"header");i&&s[0].cells.splice(0,0,{background:"#7a7a7a",color:"#fff",value:"",colSpan:i,rowSpan:Object.keys(r).length});const l=this._cellsV2(o,"data",(function(e,t){const i=(t+1)*n;for(let r=t*n;r<i;r++){const t=a[r],n=null!==t.data?t.data.value:t.data;let i=Number(n);isNaN(i)&&(i=n),e.push({background:"#dfdfdf",color:"#333",value:i,colSpan:1,rowSpan:1})}}));return s.concat(l)},_freezePaneV2:function(){const e=this.widget._columnBuilder.table[0];return{colSplit:this.widget._rowBuilder.table[0].children[0].children.length,rowSplit:e.children[1].children.length}},_filterV2:function(){if(!this.options.excel.filterable)return null;const e=this.widget._columnBuilder.table[0],t=this.widget._rowBuilder.table[0].children[0].children.length;return{from:t,to:e.children[0].children.length+(t-1)}},workbook:function(){var t;return this.dataSource.view()[0]?(t=e.Deferred()).resolve():t=this.dataSource.fetch(),t.then(function(){return"PivotGridV2"===this.widget.options.name?{sheets:[{columns:this._columnsV2(),rows:this._rowsV2(),freezePane:this._freezePaneV2(),filter:this._filterV2()}]}:{sheets:[{columns:this._columns(),rows:this._rows(),freezePane:this._freezePane(),filter:null}]}}.bind(this))}});var ft={extend:function(t){t.events.push("excelExport"),t.options.excel=e.extend(t.options.excel,this.options),t.saveAsExcel=this.saveAsExcel},options:{proxyURL:"",filterable:!1,fileName:"Export.xlsx"},saveAsExcel:function(){var e=this.options.excel||{},t=new n.PivotExcelExporter({widget:this,excel:e});this._progress&&(this._isExport=!0,this._progress(!0));t.workbook().then(function(t){this.trigger("excelExport",{workbook:t})||new n.ooxml.Workbook(t).toDataURLAsync().then((function(i){n.saveAs({dataURI:i,fileName:t.fileName||e.fileName,proxyURL:e.proxyURL,forceProxy:e.forceProxy})})).always((()=>{this._progress&&(this._progress(!1),this._isExport=!1)}))}.bind(this))}};n.PivotExcelMixin=ft,n.ooxml&&n.ooxml.Workbook&&ft.extend(it.prototype),n.ooxml&&n.ooxml.Workbook&&ft.extend(nt.prototype),n.PDFMixin&&(n.PDFMixin.extend(it.prototype),it.fn._drawPDF=function(){return this._drawPDFShadow({width:this.wrapper.width()},{avoidLinks:this.options.pdf.avoidLinks})}),n.PDFMixin&&(n.PDFMixin.extend(nt.prototype),nt.prototype._saveAsPDF=n.PDFMixin.saveAsPDF,nt.fn.saveAsPDF=function(){this._progress&&(this._isExport=!0,this._progress(!0)),this._saveAsPDF().always((()=>{this._progress&&(this._progress(!1),this._isExport=!1)}))},nt.fn._drawPDF=function(){return this._drawPDFShadow({width:this.wrapper.width()},{avoidLinks:this.options.pdf.avoidLinks})}),window.kendo.pivotgrid=window.kendo.pivotgrid||{},window.kendo.pivotgrid.common={addKPI:_g,addMultipleMeasures:tv,averageAggregate:Lg,buildKPIMeasures:vg,cloneDataTree:qg,compareAxes:yg,configuratorReducer:zg,createAxisDescriptors:Sg,createDataState:Cg,createDataTree:jg,createDiscoverBody:Jm,createFlatSchemaDimensions:iv,createLocalDataState:nv,createRequestBody:Wm,createTuples:Zg,discoverCommands:Zm,fetchData:ig,fetchDiscover:rg,headersReducer:Ig,maxAggregate:Rg,mergeTrees:Ug,minAggregate:Fg,parseResponse:Qm,readData:Yg,rootFields:Xg,setFilter:Ag,setSort:Dg,sumAggregate:Pg,toColumns:pg,toData:hg,toRows:fg,toTree:ug}}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=t.keys,r=t.htmlEncode,o="kendoContextMenu",a=".kendoPivotFieldMenu",s=".kendoPivotFieldMenuKeyboard",l="kendoPivotSettingTargetV2",c=n.Widget,d=".",u="k-column-fields",h="k-filter-item",p="aria-label",f="kendoExpansionPanel",m=c.extend({init:function(e,n){c.fn.init.call(this,e,n),this._dataSource(),this._layout(),t.notify(this)},events:[],options:{name:"PivotFieldMenuV2",animation:{expand:{effects:"expand:vertical",duration:200},collapse:{duration:200,effects:"expand:vertical",hide:!0,reverse:!0}},filter:null,filterable:!0,sortable:!0,messages:{apply:"Apply",sortAscending:"Sort Ascending",sortDescending:"Sort Descending",filterFields:"Fields Filter",filter:"Filter",include:"Include Fields...",clear:"Clear",reset:"Reset",moveToColumns:"Move to Columns",moveToRows:"Move to Rows",movePrevious:"Move previous",moveNext:"Move next",filterOperatorsDropDownLabel:"Region Filter Operators",filterValueTextBoxLabel:"Region Filter Value",operators:{contains:"Contains",doesnotcontain:"Does not contain",startswith:"Starts with",endswith:"Ends with",eq:"Is equal to",neq:"Is not equal to"}}},destroy:function(){c.fn.destroy.call(this),this.menu&&(this.menu.element.off(a),this.menu.element.off(s),this.menu.destroy(),this.menu=null,this._applyProxy=this._resetIncludes=null),this.wrapper&&this.wrapper.off(s),this.treeView&&(this.treeView.destroy(),this.treeView=null),this.wrapper=null,this.element=null},setDataSource:function(e){this.options.dataSource=e,this._dataSource()},_createExpanders:function(){var n=this,i=n.options,o={expanded:!1,headerClass:"k-columnmenu-item",wrapperClass:"k-item",useBareTemplate:!0};n.wrapper.find(".k-columns-item")[f](e.extend(!0,{},o,{title:t.ui.icon("grid-layout")+"<span>"+r(i.messages.include)+"</span>"})),n.wrapper.find(".k-column-menu-filter")[f](e.extend(!0,{},o,{title:t.ui.icon("filter")+"<span>"+r(i.messages.filterFields)+"</span>"}))},_getSettingTargets:function(){this.columnsSettingTarget=this.element.parent().find(d+u).eq(0).data(l),this.measuresSettingTarget=this.element.parent().find(d+u).eq(1).data(l),this.rowsSettingTarget=this.element.parent().find(".k-row-fields").data(l)},_createTreeView:function(e){var t=this;t._includesCache={},t.treeView=new n.TreeView(e,{autoBind:!1,dataSource:t._treeViewDataSource(),dataTextField:"caption",template:({item:e})=>`${r(e.caption||e.name)}`,check:function(e){var n=e.sender.dataItem(e.node);t._includesCache[n.uniqueName]?delete t._includesCache[n.uniqueName]:t._includesCache[n.uniqueName]=e.node},checkboxes:{checkChildren:!0}})},_dataSource:function(){this.dataSource=t.data.PivotDataSourceV2.create(this.options.dataSource)},_layout:function(){var n=this,r=n.options;n.wrapper=e(t.template(x)({ns:t.ns,filterable:r.filterable,sortable:r.sortable,messages:r.messages,renderAll:"measures"!==r.setting})),t.applyStylesFromKendoAttributes(n.wrapper,["overflow"]),n._createExpanders(),n.wrapper.on("keydown"+s,(function(r){var o,a=r.keyCode,s=n.menu,l=".k-columnmenu-item:visible,.k-treeview:visible,button.k-button:visible,.k-picker:visible,.k-input input.k-input-inner:visible",c=n.menu.element.find(l),d=t._activeElement()==n.menu.element[0],u=e(t._activeElement()).parents(".k-pivotgrid-column-menu")[0]==n.menu.element[0]?e(t._activeElement()).closest(l):n.menu.element.find(".k-focus:not(.k-expander):not(.k-treeview-item)").last();a==i.TAB?(o=r.shiftKey?c.eq(u[0]?(c.index(u)+c.length-1)%c.length:0):c.eq(u[0]?(c.index(u)+1)%c.length:0),s.element.find(".k-focus").removeClass("k-focus"),o.is(".k-item")?(d||s.element.trigger("focus"),s.element.find(".k-focus").removeClass("k-focus"),s._moveFocus(u,o)):o.trigger("focus"),r.preventDefault(),r.stopImmediatePropagation()):a==i.ENTER&&(u.trigger("click"),r.preventDefault(),r.stopImmediatePropagation())})),n.menu=n.wrapper[o]({filter:r.filter,target:n.element,orientation:"vertical",showOn:"click",closeOnClick:!1,open:this._menuOpen.bind(this),close:this._closeMenu.bind(this),activate:this._activateMenu.bind(this),deactivate:this._deactivateMenu.bind(this),copyAnchorStyles:!1}).data(o),n.menu.element.off("blur.kendoMenu","[tabindex]",n.menu._checkActiveProxy),n.menu.element.on("focus"+s,(function(t){var i=e(`#${n.menu._ariaId}`);if(i.is(".k-pivotgrid-column-menu-popup")&&n.menu.element.find(".k-columnmenu-item:visible").length){var r=n.menu.element.find(".k-columnmenu-item:visible").first();n.menu._moveFocus(i,r)}})),r.filterable&&(n._initFilterForm(),n._attachFilterHandlers(),n._createTreeView(n.wrapper.find(".k-treeview"))),n._clickHandler=n._click.bind(n),n.wrapper.on("click",".k-item:not([role='treeitem'])",n._clickHandler)},_activateMenu:function(e){var t=this;if(t.menu.element.find(".k-columnmenu-item:visible").length){var n=t.menu.element.find(".k-columnmenu-item:visible").first();t.menu._moveFocus([],n)}},_deactivateMenu:function(e){var t=this,n=t.menu.target.find("[tabindex=0]"),i=t.element.parent();n.length||(n=i.find(`.k-chip:contains("${t.currentMember}")`)).attr("tabindex",0),n.trigger("focus")},_closeMenu:function(n){var i=e(t._activeElement());this.options.filterable&&(i[0]===this._filterOperator.wrapper[0]||i.closest(".k-treeview")[0]===this.treeView.wrapper[0]||i.hasClass("k-button-includes-reset"))&&n.preventDefault()},_treeViewDataSource:function(){var n=this;return t.data.HierarchicalDataSource.create({schema:{model:{id:"uniqueName",hasChildren:function(e){return parseInt(e.childrenCardinality,10)>0}}},transport:{read:function(t){var i,r,o,a,s,l=n.treeView.dataSource.get(t.data.uniqueName),c=t.data.uniqueName,d=[];n.dataSource.cubeSchema?(d=c?n.dataSource.cubeSchema.members(n.currentMember):n.dataSource.cubeSchema.members(n.currentMember+".[(ALL)]"),i=n.dataSource.filter(),n._getFilterStorage(n.currentMember)&&1==y({filter:i,member:n.currentMember}).length&&!c?d[0].checked=!0:function(t,n,i){var r,o=0,a=i.length,s=y({filter:t,member:n,operator:"neq"});if(i[0].name.indexOf("[(ALL)]")>=0)return void(i[0].checked=!s.length);if(s.length)for(r=s.map((function(e){return e.value}));o<a;o++)i[o].checked=e.inArray(i[o].uniqueName,r)<0;else for(;o<a;o++)i[o].checked=!0}(n.dataSource.filter(),n.currentMember,d),t.success(d)):(a={catalogName:r=n.dataSource.transport.catalog(),cubeName:o=n.dataSource.transport.cube()},s={command:"schemaMembers"},c?(a.memberUniqueName=l.uniqueName.replace(/\&/g,"&amp;"),a.treeOp=1):a.levelUniqueName=n.currentMember+".[(ALL)]",s.connection={catalog:r,cube:o},s.restrictions=a,n.dataSource.discover(s).then((function(e){l&&!l.checked||w(n.dataSource.filter(),n.currentMember,e),t.success(e)})))}}})},_storeFilterForm:function(e){var t=this;t._filterStorage||(t._filterStorage={}),t._filterStorage[e]={value:t._filterValue.val(),operator:t._filterOperator.value()}},_getFilterStorage:function(e){return this._filterStorage&&this._filterStorage[e]?this._filterStorage[e]:null},_clearFilterStorage:function(e){this._filterStorage[e]=null},_click:function(t){var n=e(t.currentTarget).closest(":not(path,svg)");n.hasClass("k-columnmenu-item")&&n.find(".k-i-sort-asc-small,.k-svg-i-sort-asc-small").length&&this._sort("asc"),n.hasClass("k-columnmenu-item")&&n.find(".k-i-sort-desc-small,.k-svg-i-sort-desc-small").length&&this._sort("desc"),n.hasClass("k-columnmenu-item")&&n.find(".k-i-columns,.k-svg-i-columns").length&&this._move("columns"),n.hasClass("k-columnmenu-item")&&n.find(".k-i-rows,.k-svg-i-rows").length&&this._move("rows"),n.hasClass("k-columnmenu-item")&&n.find(".k-i-arrow-left,.k-svg-i-arrow-left").length&&this._move("previous"),n.hasClass("k-columnmenu-item")&&n.find(".k-i-arrow-right,.k-svg-i-arrow-right").length&&this._move("next")},_attachFilterHandlers:function(){this._applyIncludesProxy=this._applyIncludes.bind(this),this._resetIncludesProxy=this._resetIncludes.bind(this),this.menu.element.on("click"+a,".k-button-includes-reset",this._resetIncludesProxy).on("click"+a,".k-button-includes-apply",this._applyIncludesProxy)},_includesHandler:function(t){t.preventDefault(),e(t.target).closest(":not(path,svg)").hasClass("k-button-includes-reset")?this._resetIncludes():this._applyIncludes()},_applyIncludes:function(e){e.preventDefault();var t,n=this.treeView.dataSource.view(),i=this.dataSource.filter();t=this.dataSource.cubeSchema?function(e,t,n){var i=[];b(t,n,"neq"),t||(t={logic:"and",filters:[]});if(k(e,i,!1),i.length)for(var r=0;r<i.length;r++)t.filters.push({field:n,operator:"neq",value:i[r]});return t||null}(n,i,this.currentMember):function(e,t,n){var i,r=[],o=e[0].checked,a=y({filter:t,member:n,operator:"in"})[0];k(e,r,!0),a&&(o?(t.filters.splice(t.filters.indexOf(a),1),t.filters.length||(t={})):a.value=r.join(","),i=t);r.length&&(i||o||(i={field:n,operator:"in",value:r.join(",")},t&&(t.filters.push(i),i=t)));return i||null}(n,i,this.currentMember),this._includesCache={},t&&(this.dataSource._preventRefresh=!0,this.dataSource.filter(t),this.menu.close())},_resetIncludes:function(t){t.preventDefault();var n,i=this;for(var r in i._includesCache)(n=e(i._includesCache[r]).find(".k-checkbox")).prop("checked",!n.prop("checked")),i.treeView._checkboxChange({target:n}),delete i._includesCache[r]},_initFilterForm:function(){var e=this.menu.element.find(".kendo-grid-filter-menu-container"),n=this._filter.bind(this);this._filterOperator=new t.ui.DropDownList(e.find("select"),{popup:{appendTo:document.body}}),this._filterValue=e.find("input.k-input-inner"),this._filterForm=e,this._updateFilterAriaLabel(),e.on("click"+a,".k-button-filter",n).on("click"+a,".k-button-filter-clear",this._reset.bind(this))},_updateFilterAriaLabel:function(){var e=this._filterOperator.value(),t=this.options.messages.operators[e];this._filterForm.find("select").attr(p,t)},_filter:function(e){var t=this,n=v(t._filterValue.val(),t.dataSource,t.currentMember),i=t.dataSource.filter();if(e.preventDefault(),""!==n){var r={field:t.currentMember,operator:t._filterOperator.value(),value:n};i?function(e,t){if(!t)return;e=e.filters;var n=0,i=e.length;for(n=i-1;n>=0;n--)e[n].value===t.value&&e[n].operator===t.operator&&e.splice(n,1)}(i,t._getFilterStorage(t.currentMember)):i={logic:"and",filters:[]},t._storeFilterForm(t.currentMember),i.filters.push(r),t.dataSource._preventRefresh=!0,t.dataSource.filter(i),t.menu.close()}else t.menu.close()},_reset:function(e){var t=this,n=t.dataSource.filter();b(n,t.currentMember),e.preventDefault(),n.filters[0]||(n={}),t.dataSource._preventRefresh=!0,t.dataSource.filter(n),t._clearFilterStorage(t.currentMember),t._setFilterForm(null),t.menu.close()},_setFilterForm:function(e){var t=this._filterOperator,n="",i="";e&&(n=e.operator,i=e.value),t.value(n),t.value()||t.select(0),this._filterValue.val(i)},_collapseItems:function(n){n.find(".k-expander-indicator span").each(((n,i)=>t.ui.icon(e(i),{icon:"chevron-up"}))),n.nextAll().hide()},_sort:function(e){var t=this.currentMember,n=this.dataSource.sort()||[];(n=_(n,t)).push({field:t,dir:e}),this.dataSource._preventRefresh=!0,this.dataSource.sort(n),this.menu.close()},_move:function(e){var t=this,n=t.currentMemberIndex;switch(e){case"columns":t._moveToColumns();break;case"rows":t._moveToRows();break;case"previous":t._changeOrder(--n);break;case"next":t._changeOrder(++n)}t.menu.close()},_updateDisabledState:function(){var e=this,t=e.menu.element,n=e.currentSettingTarget.element,i=n.prev().text();t.find(".k-columnmenu-item.k-disabled").removeClass("k-disabled"),0===e.currentMemberIndex&&t.find('[data-move="previous"]').closest(".k-columnmenu-item").addClass("k-disabled"),e.currentMemberIndex===n.children().length-1&&t.find('[data-move="next"]').closest(".k-columnmenu-item").addClass("k-disabled"),"Columns"===i&&t.find('[data-move="columns"]').closest(".k-columnmenu-item").addClass("k-disabled"),"Rows"===i&&t.find('[data-move="rows"]').closest(".k-columnmenu-item").addClass("k-disabled")},_moveToColumns:function(){var e=this,t=e.currentMember;e.rowsSettingTarget.remove(t),e.columnsSettingTarget.add(t)},_moveToRows:function(){var e=this,t=e.currentMember;e.columnsSettingTarget.remove(t),e.rowsSettingTarget.add(t)},_changeOrder:function(e){var t=this.currentMember;this.currentSettingTarget.move(t,e)},_menuOpen:function(t){if(t.event){var n,i=this,r=i.dataSource.cubeSchema,o=e(t.event.target).closest(".k-chip");i.currentMember=o.text(),i.currentMemberIndex=o.index(),i.currentSettingTarget=o.closest(".k-chip-list").data(l),i.menu.popup._hovered=!0,i._getSettingTargets(),i._updateDisabledState(),i.options.filterable&&(i._setFilterForm(i._getFilterStorage(i.currentMember)),n=i.wrapper.find(".k-columnmenu-item-wrapper").last(),r&&"string"!==r.memberType(i.currentMember).toLowerCase()?n.hide():n.show(),i.currentMember!==i._oldCurrentmember&&(i._oldCurrentmember&&i._collapseItems(i.menu.element.find(".k-item.k-expander")),i._oldCurrentmember=i.currentMember,i._includesCache={},this.treeView.dataSource.read()))}}}),g=c.extend({init:function(e,n){c.fn.init.call(this,e,n),this._dataSource(),this._layout(),t.notify(this)},events:[],options:{name:"PivotFieldMenu",filter:null,filterable:!0,sortable:!0,messages:{info:"Show items with value that:",sortAscending:"Sort Ascending",sortDescending:"Sort Descending",filterFields:"Fields Filter",filter:"Filter",include:"Include Fields...",title:"Fields to include",clear:"Clear",ok:"OK",cancel:"Cancel",operators:{contains:"Contains",doesnotcontain:"Does not contain",startswith:"Starts with",endswith:"Ends with",eq:"Is equal to",neq:"Is not equal to"}}},_layout:function(){var n=this.options;this.wrapper=e(t.template(T)({ns:t.ns,filterable:n.filterable,sortable:n.sortable,messages:n.messages})),this.menu=this.wrapper[o]({filter:n.filter,target:this.element,orientation:"vertical",showOn:"click",closeOnClick:!1,open:this._menuOpen.bind(this),select:this._select.bind(this),copyAnchorStyles:!1}).data(o),this._createWindow(),n.filterable&&this._initFilterForm()},_initFilterForm:function(){var e=this.menu.element.find("."+h),n=this._filter.bind(this);this._filterOperator=new t.ui.DropDownList(e.find("select")),this._filterValue=e.find("input.k-input-inner"),this._updateFilterAriaLabel(),e.on("submit"+a,n).on("click"+a,".k-button-filter",n).on("click"+a,".k-button-clear",this._reset.bind(this))},_setFilterForm:function(e){var t=this._filterOperator,n="",i="";e&&(n=e.operator,i=e.value),t.value(n),t.value()||t.select(0),this._filterValue.val(i)},_clearFilters:function(e){var t,n,i=this.dataSource.filter()||{},r=0;for(i.filters=i.filters||[],n=(t=y({filter:i,member:e})).length;r<n;r++)i.filters.splice(i.filters.indexOf(t[r]),1);return i},_filter:function(e){var t=this,n=v(t._filterValue.val(),t.dataSource,t.currentMember);if(e.preventDefault(),""!==n){var i={field:t.currentMember,operator:t._filterOperator.value(),value:n},r=t._clearFilters(t.currentMember);r.filters.push(i),t.dataSource.filter(r),t.menu.close()}else t.menu.close()},_updateFilterAriaLabel:function(){var e=this.menu.element.find("."+h),t=this._filterOperator.value(),n=this.options.messages.operators[t];e.find("select").attr(p,n)},_reset:function(e){var t=this,n=t._clearFilters(t.currentMember);e.preventDefault(),n.filters[0]||(n={}),t.dataSource.filter(n),t._setFilterForm(null),t.menu.close()},_sort:function(e){var t=this.currentMember,n=this.dataSource.sort()||[];(n=_(n,t)).push({field:t,dir:e}),this.dataSource.sort(n),this.menu.close()},setDataSource:function(e){this.options.dataSource=e,this._dataSource()},_dataSource:function(){this.dataSource=t.data.PivotDataSource.create(this.options.dataSource)},_createWindow:function(){var i=this.options.messages;this.includeWindow=e(t.template(D)({messages:i})).on("click"+a,".k-button-ok",this._applyIncludes.bind(this)).on("click"+a,".k-button-cancel",this._closeWindow.bind(this)),this.includeWindow=new n.Window(this.includeWindow,{title:i.title,visible:!1,resizable:!1,open:this._windowOpen.bind(this)})},_applyIncludes:function(e){var t,n=[],i=this.treeView.dataSource.view(),r=i[0].checked,o=this.dataSource.filter(),a=y({filter:o,member:this.currentMember,operator:"in"})[0];k(i,n,!0),a&&(r?(o.filters.splice(o.filters.indexOf(a),1),o.filters.length||(o={})):a.value=n.join(","),t=o),n.length&&(t||r||(t={field:this.currentMember,operator:"in",value:n.join(",")},o&&(o.filters.push(t),t=o))),t&&this.dataSource.filter(t),this._closeWindow(e)},_closeWindow:function(e){e.preventDefault(),this.includeWindow.close()},_treeViewDataSource:function(){var e=this;return t.data.HierarchicalDataSource.create({schema:{model:{id:"uniqueName",hasChildren:function(e){return parseInt(e.childrenCardinality,10)>0}}},transport:{read:function(t){var n={},i=e.treeView.dataSource.get(t.data.uniqueName);t.data.uniqueName?(n.memberUniqueName=i.uniqueName.replace(/\&/g,"&amp;"),n.treeOp=1):n.levelUniqueName=e.currentMember+".[(ALL)]",e.dataSource.schemaMembers(n).done((function(n){w(e.dataSource.filter(),e.currentMember,n),t.success(n)})).fail(t.error)}}})},_createTreeView:function(e){var t=this;t.treeView=new n.TreeView(e,{autoBind:!1,dataSource:t._treeViewDataSource(),dataTextField:"caption",template:({item:e})=>`${r(e.caption||e.name)}`,checkboxes:{checkChildren:!0},dataBound:function(){n.progress(t.includeWindow.element,!1)}})},_menuOpen:function(n){if(n.event){var i=t.attr("name");this.currentMember=e(n.event.target).closest("["+i+"]").attr(i),this.options.filterable&&this._setFilterForm(y({filter:this.dataSource.filter(),member:this.currentMember})[0])}},_select:function(t){var n=e(t.item);e(".k-pivot-filter-window").not(this.includeWindow.element).kendoWindow("close"),n.hasClass("k-include-item")?this.includeWindow.center().open():n.hasClass("k-sort-asc")?this._sort("asc"):n.hasClass("k-sort-desc")?this._sort("desc"):n.hasClass(h)&&this._updateFilterAriaLabel()},_windowOpen:function(){this.treeView||this._createTreeView(this.includeWindow.element.find(".k-treeview")),n.progress(this.includeWindow.element,!0),this.treeView.dataSource.read()},destroy:function(){c.fn.destroy.call(this),this.menu&&(this.menu.destroy(),this.menu=null),this.treeView&&(this.treeView.destroy(),this.treeView=null),this.includeWindow&&(this.includeWindow.destroy(),this.includeWindow=null),this.wrapper=null,this.element=null}});function v(e,t,n){var i=((t.options.schema.model||{}).fields||{})[n];return i&&("number"===i.type?e=parseFloat(e):"boolean"===i.type&&(e=Boolean(JSON.parse(e)))),e}function _(e,t){for(var n=[],i=0,r=e.length;i<r;i++)e[i].field!==t&&n.push(e[i]);return n}function b(e,t,n){if(e){var i,r=0;for(r=(e=e.filters).length-1;r>=0;r--)i=e[r].operator,n&&i!==n||e[r].field!==t||e.splice(r,1)}}function y(e){if(!e.filter)return[];for(var t,n=e.filter.filters,i=0,r=[],o=n.length,a=e.isLocal?"neq":"in";i<o;i++)t=n[i].operator,(e.operator||t===a)&&t!==e.operator||n[i].field!==e.member||r.push(n[i]);return r}function w(t,n,i){var r,o=0,a=i.length;if(t=y({filter:t,member:n,operator:"in"})[0])for(r=t.value.split(",");o<a;o++)i[o].checked=e.inArray(i[o].uniqueName,r)>=0;else for(;o<a;o++)i[o].checked=!0}function k(e,t,n){var i,r=e.length;for(i=0;i<r;i++)e[i].checked===n&&0!==e[i].level()&&t.push(e[i].uniqueName),e[i].hasChildren&&k(e[i].children.view(),t,n)}var x=({messages:e,sortable:n,filterable:i,renderAll:o})=>'<div class="k-pivotgrid-column-menu k-column-menu k-popup k-child-animation-container"><div class="k-pivotgrid-column-menu-popup k-grid-columnmenu-popup"><div>'+(n&&o?`<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item k-item">${t.ui.icon("sort-asc-small")}${r(e.sortAscending)}</div><div class="k-columnmenu-item k-item">${t.ui.icon("sort-desc-small")}${r(e.sortDescending)}</div></div>`:"")+(i&&o?'<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item-content k-columns-item"><div class="k-column-list-wrapper"><div class="k-column-list"><div class="k-treeview"></div></div></div><div class="k-columnmenu-actions">'+t.html.renderButton(`<button class="k-button-includes-reset">${r(e.reset)}</button>`)+t.html.renderButton(`<button class="k-button-includes-apply">${r(e.apply)}</button>`,{themeColor:"primary"})+"</div></div></div>":"")+(i&&o?`<div class="k-columnmenu-item-wrapper"><div class="k-columnmenu-item-content k-column-menu-filter"><div class="kendo-grid-filter-menu-container"><form class="k-filter-menu k-group k-reset"><div class="k-filter-menu-container"><select class="k-dropdown k-picker k-dropdown-list" ${p}="${e.filterOperatorsDropDownLabel}" ${t.attr("style-overflow")}="visible">${Object.keys(e.operators||{}).map((t=>'<option value="'+t+'">'+r(e.operators[t])+"</option>")).join("")}</select><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input class="k-input-inner" ${p}="${e.filterValueTextBoxLabel}" value=""></span><div class="k-actions k-hstack k-justify-content-stretch">`+t.html.renderButton(`<button class="k-button-filter-clear">${r(e.clear)}</button>`)+t.html.renderButton(`<button class="k-button-filter">${r(e.filter)}</button>`,{themeColor:"primary"})+"</div></div></form></div></div></div>":"")+C(o,e)+"</div></div></div>",C=(e,n)=>'<div class="k-columnmenu-item-wrapper">'+(e?`<div class="k-columnmenu-item k-item" data-move="columns">${t.ui.icon("columns")}${r(n.moveToColumns)}</div>`:"")+(e?`<div class="k-columnmenu-item k-item" data-move="rows">${t.ui.icon("rows")}${r(n.moveToRows)}</div>`:"")+'<div class="k-columnmenu-item k-item" data-move="previous">'+`${t.ui.icon("arrow-left")}${r(n.movePrevious)}</div><div class="k-columnmenu-item k-item" data-move="next">`+`${t.ui.icon("arrow-right")}${r(n.moveNext)}</div></div>`,S=(e,n)=>{var i="";return n&&(i+='<li class="k-item k-menu-item k-include-item"><span class="k-link k-menu-link">'+t.ui.icon("filter")+`<span class="k-menu-link-text">${r(e.include)}</span></span></li><li class="k-separator"></li><li class="k-item k-menu-item `+h+'"><span class="k-link k-menu-link">'+t.ui.icon("filter")+`<span class="k-menu-link-text">${r(e.filterFields)}</span></span><ul><li>`+(e=>`<div class="k-filterable k-content" tabindex="-1" data-role="fieldmenu"><form class="k-filter-menu"><div class="k-filter-menu-container"><div class="k-filter-help-text">${r(e.info)}</div><select>${Object.keys(e.operators||{}).map((t=>'<option value="'+t+'">'+r(e.operators[t])+"</option>")).join("")}</select><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input class="k-input-inner" type="text" ${p}="${e.filter}" title="${e.filter}" /></span><div class="k-actions"><a class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary k-button-filter" href="#"><span class="k-button-text">${r(e.filter)}</span></a><a class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-button-clear" href="#"><span class="k-button-text">${r(e.clear)}</span></a></div></div></form></div>`)(e)+"</li></ul></li>"),i},T=({messages:e,filterable:n,sortable:i})=>'<ul class="k-pivot-fieldmenu">'+((e,n,i)=>{var o="";return n&&(o+='<li class="k-item k-menu-item k-sort-asc"><span class="k-link k-menu-link">'+t.ui.icon("sort-asc-small")+`<span class="k-menu-link-text">${r(e.sortAscending)}</span></span></li><li class="k-item k-menu-item k-sort-desc"><span class="k-link k-menu-link">`+t.ui.icon("sort-desc-small")+`<span class="k-menu-link-text">${r(e.sortDescending)}</span></span></li>`,i&&(o+='<li class="k-separator"></li>')),o})(e,i,n)+S(e,n)+"</ul>",D=({messages:e})=>`<div class="k-popup-edit-form k-pivot-filter-window"><div class="k-edit-form-container"><div class="k-treeview"></div><div class="k-edit-buttons"><a class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary k-button-ok" href="#"><span class="k-button-text">${r(e.ok)}</span></a><a class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-button-cancel" href="#"><span class="k-button-text">${r(e.cancel)}</span></a></div></div>`;n.plugin(g),n.plugin(m)}(window.kendo.jQuery);kendo;var zv={number:0,boolean:!1,string:"",date:""},Pv=({mainFilterLogicLabel:e,uid:t})=>`<div class='k-filter-toolbar'><div class='k-toolbar' aria-label='${e}' id='${t}'></div></div>`,Hv=({filterLogicLabel:e})=>`<li class='k-filter-item' role='treeitem'><div class='k-filter-toolbar'><div role='toolbar' aria-label='${e}' class='k-toolbar'></div></div></li>`,Fv=({filterExpressionLabel:e,uid:t})=>`<li class='k-filter-item' role='treeitem'><div class='k-filter-toolbar'><div role='group' aria-label='${e}' class='k-toolbar' id='${t}'></div></div></li>`;!function(e){var t=window.kendo,n=t.ui,i=t.guid,r=t.ns,o=t.keys,a=n.Widget,s=n.ButtonGroup,l=":kendoFocusable",c="change",d="tabindex",u=".kendoFilter",h="Is equal to",p="Is not equal to",f={number:function(t,{field:n}){e(`<input tabindex='-1' id='${i()}' type='text' aria-label='${n}' title='${n}' data-${r}role='numerictextbox' data-${r}bind='value: value'/>`).appendTo(t)},string:function(n,{field:r}){e(`<span class='k-textbox k-input k-input-md k-rounded-md k-input-solid'><input tabindex='-1' id='${i()}' type='text' aria-label='${r}' title='${r}' class='k-input-inner' data-${t.ns}bind='value: value'/></span>`).appendTo(n)},boolean:function(t,{field:n}){e(`<input tabindex='-1' id='${i()}' class='k-checkbox k-checkbox-md k-rounded-md' aria-label='${n}' data-${r}role='checkbox' data-${r}bind='checked: value' type='checkbox'>`).appendTo(t)},date:function(t,{field:n}){e(`<input tabindex='-1' id='${i()}' type='text' aria-label='${n}' title='${n}' data-${r}role='datepicker' data-${r}bind='value: value'/>`).appendTo(t)}},m=s.extend({init:function(e,t){s.fn.init.call(this,e,t)},options:{name:"FilterButtonGroup"},value:function(e){if(void 0===e)return this._value;this._value=e,s.fn._select.call(this,this.wrapper.find("[value='"+e+"']")),this.trigger(c)},_select:function(t){-1!==t&&this.value(e(t).attr("value"))}}),g=a.extend({init:function(t,n){var i,r=this;a.fn.init.call(r,t,n),r.element=e(t).addClass("k-filter"),r.dataSource=n.dataSource,r.operators=e.extend(r.options.operators,n.operators),r._getFieldsInfo(),r._modelChangeHandler=r._modelChange.bind(r),r._renderMain(),n.expression&&r._addExpressionTree(r.filterModel),r._renderApplyButton(),r.options.expressionPreview&&(r._previewContainer||(r._previewContainer=e('<div class="k-filter-preview"></div>').insertAfter(r.element.children().eq(0))),i=r._createPreview(r.filterModel.toJSON()),r._previewContainer.html(i)),r._attachEvents(),r.hasCustomOperators();var o=e(r.element).find(".k-filter-toolbar > .k-toolbar");o.attr(d,-1),o.find(l).attr(d,-1),o.eq(0).attr(d,0)},events:[c],options:{name:"Filter",dataSource:null,expression:null,applyButton:!1,fields:[],mainLogic:"and",messages:{and:"And",or:"Or",apply:"Apply",close:"Close",addExpression:"Add Expression",fields:"Fields",filterExpressionLabel:"filter expression",filterLogicLabel:"filter logic",filterAriaLabel:"filter component",mainFilterLogicLabel:"main filter logic",operators:"Operators",addGroup:"Add Group"},operators:{string:{eq:h,neq:p,startswith:"Starts with",contains:"Contains",doesnotcontain:"Does not contain",endswith:"Ends with",isnull:"Is null",isnotnull:"Is not null",isempty:"Is empty",isnotempty:"Is not empty",isnullorempty:"Has no value",isnotnullorempty:"Has value"},number:{eq:h,neq:p,gte:"Is greater than or equal to",gt:"Is greater than",lte:"Is less than or equal to",lt:"Is less than",isnull:"Is null",isnotnull:"Is not null"},date:{eq:h,neq:p,gte:"Is after or equal to",gt:"Is after",lte:"Is before or equal to",lt:"Is before",isnull:"Is null",isnotnull:"Is not null"},boolean:{eq:h,neq:p}}},applyFilter:function(){var e=this.filterModel.toJSON();this._hasCustomOperators&&this._mapOperators(e),this._hasFieldsFilter(e.filters||[])?(this._removeEmptyGroups(e.filters),this.dataSource.filter(e)):this.dataSource.filter({})},destroy:function(){this.element.off(u),t.destroy(this.element.find(".k-filter-group-main")),this._previewContainer=null,this._applyButton=null,this._modelChangeHandler=null,a.fn.destroy.call(this)},setOptions:function(e){t.deepExtend(this.options,e),this.destroy(),this.element.empty(),this.init(this.element,this.options)},getOptions:function(){var t=e.extend(!0,{},this.options);return delete t.dataSource,t.expression=this.filterModel.toJSON(),t},_addExpressionTree:function(e){if(e.filters)for(var t=this.element.find("[id="+e.uid+"]"),n=0;n<e.filters.length;n++)e.filters[n].logic?this._addGroup(t,e.filters[n]):this._addExpression(t,e.filters[n]),e.filters[n].filters&&this._addExpressionTree(e.filters[n])},_click:function(t){var n=this;t.preventDefault();var i=e(t.currentTarget),r=i.data("command");"x"==r?n._removeExpression(i.closest(".k-toolbar")):"expression"==r?n._addExpression(i.closest(".k-toolbar")):"group"==r?n._addGroup(i.closest(".k-toolbar")):"apply"==r&&n.applyFilter()},_keydown:function(t){var n=this,i=e(t.target),r=t.keyCode,a=i.closest(".k-toolbar"),s=i.is(".k-toolbar");if(r===o.UP&&s)t.preventDefault(),n._focusToolbar(a,"prev");else if(r==o.DOWN&&s)t.preventDefault(),n._focusToolbar(a,"next");else if(r==o.ESC)t.stopPropagation(),n._focusToolbar(a);else if(r==o.ENTER&&s){a.find(".k-toolbar-item").eq(0).attr(d,0).trigger("focus")}},_attachEvents:function(){var e=this,t=e._click.bind(e),n=e._keydown.bind(e);e.element.on("click"+u,"button.k-button",t).on("keydown"+u,".k-filter-toolbar > .k-toolbar, .k-filter-toolbar > .k-toolbar .k-toolbar-item",n)},_focusToolbar:function(t,n,i){var r=t,o=e(this.element).find(".k-filter-toolbar > .k-toolbar");if(o.attr(d,-1),o.find(l).attr(d,-1),"next"==n){let e=Math.min(o.length-1,i||o.index(t)+1);r=o.eq(e)}else if("prev"==n){let e=Math.max(0,i||o.index(t)-1);r=o.eq(e)}r.attr(d,0).trigger("focus")},_addExpression:function(n,i){var o,a=this,s=n.attr("id"),l=n.closest(".k-filter-toolbar").next("ul.k-filter-lines"),c=i?a._fields[i.field]:a._defaultField,d="";i?o=i:((o=_(a.filterModel,s)).filters||o.set("filters",[]),o=a._addNewModel(o.filters,c)),l.length||(l=e("<ul class='k-filter-lines' role='group'></ul>").appendTo(n.closest("li")));var u={fields:a._fields,operators:a.operators[c.type],close:a.options.messages.close,fieldsLabel:a.options.messages.fields,uid:o.uid,ns:t.ns,filterExpressionLabel:a.options.messages.filterExpressionLabel},h=(d=e(t.template(Fv)(u)).appendTo(l)).find(".k-toolbar").first(),p=c.operators&&c.operators[c.type]?c.operators[c.type]:this.operators[c.type];h.kendoToolBar({resizable:!1,items:[{type:"component",component:"DropDownList",element:`<select data-${r}bind="value: field" title='${a.options.messages.fields}' aria-label='${a.options.messages.fields}' data-auto-width='true'></select>`,attributes:{class:"k-filter-field"},componentOptions:{title:a.options.messages.fields,dataTextField:"text",dataValueField:"value",dataSource:Object.keys(a._fields||{}).map((e=>({value:a._fields[e].name,text:a._fields[e].label})))}},{type:"component",component:"DropDownList",element:`<select data-${r}bind="value: operator" aria-label='${a.options.messages.operators}' title='${a.options.messages.operators}'></select>`,attributes:{class:"k-filter-operator"},componentOptions:{title:a.options.messages.operators,dataTextField:"text",dataValueField:"value",dataSource:Object.keys(p||{}).map((e=>({value:e,text:p[e].text||p[e]})))}},{attributes:{class:"k-filter-value"},template:" "},{type:"button",icon:"x",fillMode:"flat",attributes:{"data-command":"x",title:u.close,"aria-label":u.close}}]}),a._addExpressionControls(d.find(".k-toolbar"),c,o),i||a._expressionChange()},_addExpressionControls:function(e,n,i){var r=e.find(".k-toolbar-item.k-filter-operator"),o=e.find(".k-toolbar-item.k-filter-value");o.attr("ref-toolbar-tool",""),t.destroy(o),o.empty(),this._bindOperators(r,n),this._appendEditor(o,n),this._bindModel(e,i),this._showHideEditor(e,i),e.find(l).attr(d,-1)},_bindOperators:function(e,t){var n=t.operators&&t.operators[t.type]?t.operators[t.type]:this.operators[t.type],i=e.find("select[data-role=dropdownlist]").getKendoDropDownList();i&&i.setDataSource(Object.keys(n||{}).map((e=>({value:e,text:n[e].text||n[e]}))))},_appendEditor:function(n,i){t.isFunction(i.editor)?i.editor(n,e.extend(!0,{},{field:i.name})):e(t.template(i.editor)({ns:t.ns,field:i.name,id:t.guid()})).appendTo(n)},_addNewModel:function(e,t){var n,i,r=t.type,o=t.operators;return o||(o=this.options.operators),i=Object.keys(o[r])[0],e.push({field:t.name}),(n=e[e.length-1]).set("value",t.defaultValue),n.set("operator",i),n},_addGroup:function(n,i){let r,o=this,a=o.filterModel,s=n.attr("id"),l=n.closest(".k-filter-toolbar").next("ul.k-filter-lines");i?a=i:(a=_(a,s),a.filters||a.set("filters",[]),a.filters.push({logic:o.options.mainLogic}),a=a.filters[a.filters.length-1]),l.length||(l=e("<ul class='k-filter-lines' role='group'></ul>").appendTo(n.closest("li")));let c={operators:{and:o.options.messages.and,or:o.options.messages.or},addExpression:o.options.messages.addExpression,addGroup:o.options.messages.addGroup,close:o.options.messages.close,ns:t.ns,filterLogicLabel:o.options.messages.filterLogicLabel,filterModel:a};r=e(t.template(Hv)(c)).appendTo(l);let d=r.find(".k-toolbar");o._initGroupToolBar(d,c),o._bindModel(d,a),i||o._expressionChange()},_bindModel:function(e,n){e.attr("id",n.uid),n.bind("change",this._modelChangeHandler),t.bind(e,n),e.parent().attr(t.attr("stop"),!0)},_createPreview:function(e){var n,i,r="",o=!1,a=this._hasFieldsFilter(e.filters||[]),s="";if(!e.filters||!e.filters.length||!a)return"";r+='<span class="k-filter-preview-bracket">(</span>';for(var l=0;l<e.filters.length;l++)(n=e.filters[l]).filters&&((s=this._createPreview(n))&&(o&&(r+='<span class="k-filter-preview-operator"> '+e.logic.toLocaleUpperCase()+" </span>"),o=!0),r+=s),n.field&&(i=this._fields[n.field],o&&(r+='<span class="k-filter-preview-operator"> '+e.logic.toLocaleUpperCase()+" </span>"),o=!0,r+='<span class="k-filter-preview-field">'+i.label+"</span>",r+='<span class="k-filter-preview-criteria"> '+this._getOperatorText(n.field,n.operator),n.operator.indexOf("is")<0?(r+=" </span>",r+="<span class='k-filter-preview-value'>'"+t.htmlEncode(i.previewFormat?t.toString(n.value,i.previewFormat):n.value)+"'</span>"):r+="</span>");return r+='<span class="k-filter-preview-bracket">)</span>'},_expressionChange:function(){var e=this,t=e.filterModel.toJSON(),n="";e.options.expressionPreview&&(n=e._createPreview(t),e._previewContainer.html(n)),e.trigger(c,{expression:t})},_getOperatorText:function(e,t){var n=this._fields[e].type,i=this._fields[e].operators;return i||(i=this.options.operators),i[n][t].text||i[n][t]},_addField:function(t,n){var i=this;t=e.extend(!0,{},{name:t.name||n,editor:t.editorTemplate||f[t.type||"string"],defaultValue:t.defaultValue||!1===t.defaultValue||0===t.defaultValue?t.defaultValue:zv[t.type||"string"],type:t.type||"string",label:t.label||t.name||n,operators:t.operators,previewFormat:t.previewFormat}),i._fields[t.name]=t,i._defaultField||(i._defaultField=t)},_getFieldsInfo:function(){var e,t=this,n=t.options.fields.length?t.options.fields:(t.options.dataSource.options.schema.model||{}).fields;if(t._fields={},Array.isArray(n))for(var i=0;i<n.length;i++)e=n[i],t._addField(e);else for(var r in n)e=n[r],t._addField(e,r)},_hasFieldsFilter:function(e,t){t=!!t;for(var n=0;n<e.length;n++)if(e[n].filters&&(t=this._hasFieldsFilter(e[n].filters,t)),e[n].field)return!0;return t},_removeEmptyGroups:function(e){if(e)for(var t=e.length-1;t>=0;t--)e[t].logic&&!e[t].filters||e[t].filters&&!this._hasFieldsFilter(e[t].filters)?e.splice(t,1):e[t].filters&&this._removeEmptyGroups(e[t].filters)},_modelChange:function(e){var t=this,n=t.element.find("[id="+e.sender.uid+"]");if(t._showHideEditor(n,e.sender),"field"===e.field){var i=e.sender.field,r=e.sender.parent(),o=t._fields[i],a=t._addNewModel(r,o);e.sender.unbind("change",t._modelChangeHandler),r.remove(e.sender),t._addExpressionControls(n,o,a),t._expressionChange()}else"filters"!==e.field&&t._expressionChange()},_renderMain:function(){let n=this;var i;e((i=n.options.messages.filterAriaLabel,`<ul class='k-filter-container' role='tree' aria-label='${i}'><li class='k-filter-group-main' role='treeitem'></li></ul>`)).appendTo(n.element),n.options.expression?n.filterModel=t.observable(n.options.expression):n.filterModel=t.observable({logic:n.options.mainLogic});let r={operators:{and:n.options.messages.and,or:n.options.messages.or},addExpression:n.options.messages.addExpression,addGroup:n.options.messages.addGroup,close:n.options.messages.close,uid:n.filterModel.uid,ns:t.ns,mainFilterLogicLabel:n.options.messages.mainFilterLogicLabel,filterModel:n.filterModel},o=e(t.template(Pv)(r));o.appendTo(n.element.find("li").first());let a=o.find(".k-toolbar").first();n._initGroupToolBar(a,r),n._bindModel(a,n.filterModel)},_initGroupToolBar:function(t,n){let i=this;t.kendoToolBar({resizable:!1,toggle:function(t){let n=e(t.target).closest(".k-toolbar").attr("id"),r=_(i.filterModel,n);r&&r.set("logic",e(t.target).data("logic"))},items:[{type:"buttonGroup",selection:"single",buttons:[{text:i.options.messages.and,group:"mainlogic",togglable:!0,selected:"and"===n.filterModel.get("logic"),attributes:{"data-logic":"and"}},{text:i.options.messages.or,group:"mainlogic",togglable:!0,selected:"or"===n.filterModel.get("logic"),attributes:{"data-logic":"or"}}]},{type:"button",icon:"filter-add-expression",attributes:{"data-command":"expression",title:n.addExpression,"aria-label":n.addExpression}},{type:"button",icon:"filter-add-group",attributes:{"data-command":"group",title:n.addGroup,"aria-label":n.addGroup}},{type:"button",icon:"x",fillMode:"flat",attributes:{"data-command":"x",title:n.close,"aria-label":n.close}}]})},_removeExpression:function(n){var i,r,o=this,a=n.attr("id"),s=n.closest("li"),l=-1;if(s.hasClass("k-filter-group-main"))s=s.find(".k-filter-lines"),o.filterModel.filters&&(o.filterModel.filters.empty(),delete o.filterModel.filters);else{l=e(o.element).find(".k-filter-toolbar > .k-toolbar").index(n),i=(r=_(o.filterModel,a)).parent(),r.unbind("change",o._modelChangeHandler),i.remove(r),i.length||delete i.parent().filters,s.siblings().length||(s=s.parent())}t.destroy(s),s.remove(),o._expressionChange(),l>-1&&o._focusToolbar(n,"next",l)},_renderApplyButton:function(){var n=this;n.options.applyButton&&(n._applyButton||(n._applyButton=e(t.format('<button type="button" data-command="apply" aria-label="{0}" title="{0}" class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-filter-apply"><span class="k-button-text">{0}</span></button>',n.options.messages.apply)).appendTo(n.element)))},_showHideEditor:function(e,t){if(!t.logic){var n=t.operator,i=e.find(".k-toolbar-item.k-filter-value");"isnull"==n||"isnotnull"==n||"isempty"==n||"isnotempty"==n||"isnullorempty"==n||"isnotnullorempty"==n?i.hide():i.show()}},_mapOperators:function(e){var t=this;e.filters&&e.filters.forEach((function(e){if(e.filters)t._mapOperators(e);else{var n,i=t._fields[e.field],r=i.type;(n=i.operators&&i.operators[r][e.operator]?i.operators[r][e.operator]:t.operators[r][e.operator])&&(e.operator=n.handler||e.operator)}}))},hasCustomOperators:function(){var t=e.extend(!0,{},this.operators);for(var n in this._fields)t=e.extend(!0,{},t,this._fields[n].operators);this._hasCustomOperators=v(t)}});function v(e){for(var t in e){var n=e[t];if(n.handler&&"function"==typeof n.handler||"object"==typeof n&&null!==n&&v(n))return!0}return!1}function _(e,t){if(e.uid===t)return e;if(e.filters)for(var n=0;n<e.filters.length;n++){var i=_(e.filters[n],t);if(i)return i}}n.plugin(g),n.plugin(m)}(window.kendo.jQuery);kendo;!function(e,t){var n,i=window.kendo,r=i.ui,o=i.keys,a=e.extend,s=i.htmlEncode,l=e.each,c=Array.isArray,d=i.template,u=r.Widget,h=i.data.HierarchicalDataSource,p=/^(ul|a|div)$/i,f=".kendoPanelBar",m="href",g="k-link",v="."+g,_="error",b=".k-panelbar-item",y=".k-panelbar-group:visible",w="k-image",k="change",x="expand",C="select",S="click",T="k-panelbar-content",D="activate",A="collapse",M="dataBound",E="mouseenter",I="contentLoad",z="k-expanded",P="> .k-panelbar-group",H="> .k-panelbar-content",F="k-focus",R="k-disabled",L="k-selected",B="."+L,O=b+":not(.k-disabled)",V="> "+O+" > "+v+", .k-panelbar-group > "+O+" > "+v,N=b+".k-disabled > .k-link",$="> li > "+B+", .k-panelbar-group > li > "+B,U="aria-disabled",W="aria-expanded",j="aria-hidden",q="aria-selected",G=":visible",K="single",Y={text:"dataTextField",url:"dataUrlField",spriteCssClass:"dataSpriteCssClassField",imageUrl:"dataImageUrlField",icon:"dataIconField",iconClass:"dataIconClassField"},Q={aria:function(e){var t="";return(e.items||e.content||e.contentUrl||e.expanded)&&(t+=W+"='"+(e.expanded?"true":"false")+"' "),!1===e.enabled&&(t+=U+"='true'"),t},wrapperCssClass:function(e,t){var n="k-panelbar-item";t.index;return e.firstLevel&&(n+=" k-panelbar-header"),!1===t.enabled?n+=" "+R:!0===t.expanded&&(n+=" "+z),t.cssClass&&(n+=" "+t.cssClass),t.level&&(n+=" k-level-"+t.level()),n},textClass:function(e){var t=g;return e.selected&&(t+=" "+L),t},textAttributes:function(e){return e?" href='"+e+"'":""},arrowIconOptions:function(e){return{icon:e.expanded?"chevron-up":"chevron-down",iconClass:"k-panelbar-toggle k-panelbar-"+(e.expanded?"collapse":"expand")}},text:function(e){return!1===e.encoded?e.text:i.htmlEncode(e.text)},groupAttributes:function(e){return!0!==e.expanded?` ${i.attr("style-display")}="none"`:""},ariaHidden:function(e){return!0!==e.expanded},groupCssClass:function(){return"k-panelbar-group"},contentAttributes:function(e){return!0!==e.item.expanded?` ${i.attr("style-display")}="none"`:""},content:function(e){return e.content?e.content:e.contentUrl?"":"&nbsp;"},contentUrl:function(e){return e.contentUrl?'href="'+e.contentUrl+'"':""}};function X(t){(t=e(t)).addClass("k-level-"+t.parentsUntil(".k-panelbar","ul").length)}n=function(e){return e.children("span").children(".k-panelbar-toggle")};var Z=i.ui.DataBoundWidget.extend({init:function(e,t){var n,r,o=this;c(t)&&(t={dataSource:t}),r=t&&!!t.dataSource,u.fn.init.call(o,e,t),e=o.wrapper=o.element.addClass("k-panelbar"),t=o.options,e[0].id&&(o._itemId=e[0].id+"_pb_active"),o._tabindex(),o._accessors(),o._dataSource(),o._templates(),o._initData(r),o._updateClasses(),o._animations(t),e.on(S+f,V,o._click.bind(o)).on(E+f+" mouseleave"+f,V,o._toggleHover).on(S+f,N,!1).on(S+f,".k-request-retry",o._retryRequest.bind(o)).on("keydown"+f,o._keydown.bind(o)).on("focus"+f,(function(){var e=o.select();o._current(e[0]?e:o._first())})).on("blur"+f,(function(){o._current(null)})).attr("role","tree"),(n=e.find("li."+z+" > ."+T))[0]&&o.expand(n.parent(),!1),i.notify(o),o._showWatermarkOverlay&&o._showWatermarkOverlay(o.wrapper[0])},events:[x,A,C,D,k,_,M,I],options:{name:"PanelBar",dataSource:{},animation:{expand:{effects:"expand:vertical",duration:200},collapse:{duration:200}},messages:{loading:"Loading...",requestFailed:"Request failed.",retry:"Retry"},autoBind:!0,loadOnDemand:!0,expandMode:"multiple",template:null,dataTextField:null,selectable:!0},destroy:function(){u.fn.destroy.call(this),this.element.off(f),i.destroy(this.element)},_initData:function(e){var t=this;e&&(t.element.empty(),t.options.autoBind&&(t._progress(!0),t.dataSource.fetch()))},_templates:function(){var t=this,n=t.options,r=t._fieldAccessor.bind(t);n.template&&"string"==typeof n.template?n.template=d(n.template):n.template||(n.template=d((e=>{var t=r("text")(e.item);return!1!==e.item.encoded&&(t=s(t)),`<span class='k-panelbar-item-text'>${t}</span>`}))),t.templates={content:d((({data:e,item:t,contentAttributes:n,content:i})=>`<div class='k-panelbar-content'${n({data:e,item:t,contentAttributes:n,content:i})}>${i(t)}</div>`)),group:d((({data:e,items:t,group:n,renderItems:i,panelBar:r,ariaHidden:o,groupCssClass:a,groupAttributes:s})=>`<ul role='group' aria-hidden='${o(n)}' class='${a(n)}' ${s(n)}>`+i({data:e,items:t,group:n,renderItems:i,panelBar:r,ariaHidden:o,groupCssClass:a,groupAttributes:s})+"</ul>")),itemWrapper:d((({panelBar:t,item:n,arrow:o,textClass:a,arrowIconOptions:s,textAttributes:l,contentUrl:c})=>{var d=r("url")(n),u=r("imageUrl")(n),h=r("spriteCssClass")(n),p=r("icon")(n),f=r("iconClass")(n);f=f?" "+f:"";c=c(n);var m=d||c?"a":"span";return`<${m} class='${a(n)}' ${c}${l(d)}>`+(u?`<img class='k-panelbar-item-icon k-image' alt='' src='${u}' />`:"")+(h?`<span class='k-sprite ${h}'></span>`:"")+(p?i.ui.icon(e("<span></span>"),{icon:p,iconClass:"k-panelbar-item-icon"+f}):"")+t.options.template({panelBar:t,item:n,arrow:o,textClass:a,textAttributes:l,contentUrl:c})+o({panelBar:t,item:n,arrow:o,textClass:a,arrowIconOptions:s,textAttributes:l,contentUrl:c})+`</${m}>`})),item:d((({data:e,group:t,item:n,panelBar:r,itemWrapper:o,renderContent:a,arrow:s,arrowIconOptions:l,subGroup:c,aria:d,wrapperCssClass:u,contentUrl:h,textClass:p,textAttributes:f})=>`<li aria-selected='false' role='treeitem' ${d(n)}class='${u(t,n)}' `+i.attr("uid")+`='${n.uid}'>`+o({data:e,group:t,item:n,panelBar:r,itemWrapper:o,renderContent:a,arrow:s,arrowIconOptions:l,subGroup:c,aria:d,wrapperCssClass:u,contentUrl:h,textClass:p,textAttributes:f})+(n.items&&n.items.length>0?c({items:n.items,panelBar:r,group:{expanded:n.expanded}}):n.content||n.contentUrl?a({data:e,group:t,item:n,panelBar:r,itemWrapper:o,renderContent:a,arrow:s,arrowIconOptions:l,subGroup:c,aria:d,wrapperCssClass:u,contentUrl:h,textClass:p,textAttributes:f}):"")+"</li>")),loading:d((({messages:e})=>`<li class='k-panelbar-item'><span class='k-icon k-i-loading'></span> ${s(e.loading)}</li>`)),retry:d((({messages:e})=>`<li class='k-panelbar-item'>${s(e.requestFailed)} <button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-request-retry'><span class='k-button-text'>${s(e.retry)}</span></button></li>`)),arrow:d((({item:e,arrowIconOptions:t})=>i.ui.icon(t(e)))),empty:d((()=>""))}},setOptions:function(e){var t=this.options.animation;this._animations(e),e.animation=a(!0,t,e.animation),"dataSource"in e&&this.setDataSource(e.dataSource),u.fn.setOptions.call(this,e)},expand:function(t,n){var i=this,r={};if(t=this.element.find(t),!i._animating||!t.find("ul").is(":visible"))return i._animating=!0,n=!1!==n,t.each((function(o,a){a=e(a);var s=t.children(".k-panelbar-group,.k-panelbar-content");s.length||(s=i._addGroupElement(t));var l=s.add(a.find(H));if(!a.hasClass(R)&&l.length>0){if(i.options.expandMode==K&&i._collapseAllExpanded(a))return i;n||(r=i.options.animation,i.options.animation={expand:{effects:{}},collapse:{hide:!0,effects:{}}}),i._triggerEvent(x,a)||i._toggleItem(a,!1,!1),n||(i.options.animation=r)}})),i;i.one("complete",(function(){setTimeout((function(){i.expand(t)}))}))},collapse:function(t,n){var i=this,r={};return i._animating=!0,n=!1!==n,(t=i.element.find(t)).each((function(t,o){var a=(o=e(o)).find(P).add(o.find(H));!o.hasClass(R)&&a.is(G)&&(n||(r=i.options.animation,i.options.animation={expand:{effects:{}},collapse:{hide:!0,effects:{}}}),i._triggerEvent(A,o)||i._toggleItem(o,!0),n||(i.options.animation=r))})),i},updateArrow:function(t){var n=this;(t=e(t)).children(v).children(".k-panelbar-collapse, .k-panelbar-expand").remove(),t.filter((function(){var t=n.dataItem(this);return t?t.hasChildren||t.content||t.contentUrl:e(this).find(".k-panelbar-group").length>0||e(this).find(".k-panelbar-content").length>0})).children(".k-link:not(:has([class*=-i-chevron]))").each((function(){var t=e(this),n=t.parent();let r=i.ui.icon({icon:n.hasClass(z)?"chevron-up":"chevron-down",iconClass:"k-panelbar-toggle k-panelbar-"+(n.hasClass(z)?"collapse":"expand")});t.append(r)}))},_accessors:function(){var e,t,n,r=this.options,o=this.element;for(e in Y)t=r[Y[e]],n=o.attr(i.attr(e+"-field")),!t&&n&&(t=n),t||(t=e),c(t)||(t=[t]),r[Y[e]]=t},_progress:function(e,t){var i=this.element,r=this.templates.loading({messages:this.options.messages});1==arguments.length?(t=e)?i.html(r):i.empty():n(e).empty().removeClass("k-i-arrow-rotate-cw k-svg-i-arrow-rotate-cw").toggleClass("k-i-loading",t)},_refreshRoot:function(t){var n=this,o={firstLevel:!0,expanded:!0,length:n.element.children().length};this.element.empty();var s=e.map(t,(function(t,r){if("string"==typeof t)return e(t);{t.items=[];let s=e(n.renderItem({group:o,item:a(t,{index:r})}));return i.applyStylesFromKendoAttributes(s,["display"]),s}}));this.element.append(s);for(var l=this.element.children(".k-panelbar-item"),c=0;c<t.length;c++)this.trigger("itemChange",{item:l.eq(c).find(".k-link").first(),data:t[c],ns:r})},_refreshChildren:function(t,n){var i,o,a;if(n.children(".k-panelbar-group").empty(),t.children.data().length)for(this.append(t.children,n),this.options.loadOnDemand&&this._toggleGroup(n.children(".k-panelbar-group"),!1),o=n.children(".k-panelbar-group").children("li"),i=0;i<o.length;i++)a=o.eq(i),this.trigger("itemChange",{item:a.find(".k-link").first(),data:this.dataItem(a),ns:r});else!function(t){var n=t,i=t.children("ul"),r=n.children(".k-link").children(".k-panelbar-toggle");t.hasClass("k-panelbar")||(!r.length&&i.length?r=e("<span class='k-panelbar-toggle' />").appendTo(n):i.length&&i.children().length||(r.remove(),i.remove()))}(n),o=n.children(".k-panelbar-group").children("li")},findByUid:function(t){for(var n,r=this.element.find(".k-panelbar-item"),o=i.attr("uid"),a=0;a<r.length;a++)if(r[a].getAttribute(o)==t){n=r[a];break}return e(n)},refresh:function(e){var n=this.options,i=e.node,r=e.action,o=e.items,a=this.wrapper,s=n.loadOnDemand;if(e.field){if(!o[0]||!o[0].level)return;return this._updateItems(o,e.field)}if(i&&(a=this.findByUid(i.uid),this._progress(a,!1)),"add"==r?this._appendItems(e.index,o,a):"remove"==r?this.remove(this.findByUid(o[0].uid)):"itemchange"==r?this._updateItems(o):"itemloaded"==r?this._refreshChildren(i,a):this._refreshRoot(o),"remove"!=r)for(var l=0;l<o.length;l++)if(!s||o[l].expanded){var c=o[l];this._hasChildItems(c)&&c.load()}this.trigger(M,{node:i?a:t})},_error:function(e){var t=e.node&&this.findByUid(e.node.uid),r=this.templates.retry({messages:this.options.messages});t?(this._progress(t,!1),i.ui.icon(n(t),{icon:"arrow-rotate-cw"}),e.node.loaded(!1)):(this._progress(!1),this.element.html(r))},_retryRequest:function(e){e.preventDefault(),this.dataSource.fetch()},items:function(){return this.element.find(".k-panelbar-item > span:first-child")},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.options.autoBind&&(this._progress(!0),this.dataSource.fetch())},_bindDataSource:function(){this._refreshHandler=this.refresh.bind(this),this._errorHandler=this._error.bind(this),this.dataSource.bind(k,this._refreshHandler),this.dataSource.bind(_,this._errorHandler)},_unbindDataSource:function(){var e=this.dataSource;e&&(e.unbind(k,this._refreshHandler),e.unbind(_,this._errorHandler))},_fieldAccessor:function(t){var n=this.options[Y[t]]||[],r=n.length;return 0===r?function(e){return e[t]}:function(t){var o=e.map(n,i.getter);return t.level?o[Math.min(t.level(),r-1)](t):o[r-1](t)}},_dataSource:function(){var e=this,t=e.options.dataSource;t&&(t=c(t)?{data:t}:t,e._unbindDataSource(),t.fields||(t.fields=[{field:"text"},{field:"url"},{field:"spriteCssClass"},{field:"imageUrl"},{field:"icon"},{field:"iconClass"}]),e.dataSource=h.create(t),e._bindDataSource())},_appendItems:function(t,n,r){var o,s,l=this;r.hasClass("k-panelbar")?(o=r.children("li"),s=r):((s=r.children(".k-panelbar-group")).length||(s=l._addGroupElement(r)),o=s.children("li"));var c={firstLevel:r.hasClass("k-panelbar"),expanded:!0,length:o.length},d=e.map(n,(function(t,n){if("string"==typeof t)return e(t);{let r=e(l.renderItem({group:c,item:a(t,{index:n})}));return i.applyStylesFromKendoAttributes(r,["display"]),r}}));void 0===t&&(t=o.length);for(var u=0;u<d.length;u++)0===o.length||0===t?s.append(d[u]):d[u].insertAfter(o[t-1]);l.dataItem(r)&&(l.dataItem(r).hasChildren=!0,l.updateArrow(r))},_updateItems:function(t,n){var i,o,s,l,c=this,d={panelBar:c.options,item:l,group:{}},u="expanded"!=n;if("selected"==n)if(t[0][n]){var h=c.findByUid(t[0].uid);h.hasClass(R)||c.select(h,!0)}else c.clearSelection();else{var p=e.map(t,(function(e){return c.findByUid(e.uid)}));for(i=0;i<t.length;i++)d.item=l=t[i],d.panelBar=c,o=(s=p[i]).parent(),u&&(d.group={firstLevel:o.hasClass("k-panelbar"),expanded:s.parent().hasClass(z),length:s.children().length},s.children(".k-link").remove(),s.prepend(c.templates.itemWrapper(a(d,{arrow:l.hasChildren||l.content||l.contentUrl?c.templates.arrow:c.templates.empty},Q)))),"expanded"==n?c._toggleItem(s,!l[n],!l[n]||"true"):"enabled"==n&&(c.enable(s,l[n]),l[n]||l.selected&&l.set("selected",!1)),s.length&&this.trigger("itemChange",{item:s.find(".k-link").first(),data:l,ns:r})}},_toggleDisabled:function(e,t){(e=this.element.find(e)).toggleClass(R,!t).attr(U,!t)},dataItem:function(t){var n=e(t).closest(b).attr(i.attr("uid")),r=this.dataSource;return r&&r.getByUid(n)},select:function(n,i){var r=this;return n===t?r.element.find($).parent():((n=r.element.find(n)).length?n.each((function(){var t=e(this),n=t.children(v);if(t.hasClass(R))return r;r._updateSelected(n,i)})):this._updateSelected(n),r)},clearSelection:function(){this.select(e())},enable:function(e,t){return this._toggleDisabled(e,!1!==t),this},disable:function(e){return this._toggleDisabled(e,!1),this},append:function(e,t){t=this.element.find(t);var n=this._insert(e,t,t.length?t.find(P):null);return l(n.items,(function(){n.group.append(this),X(this)})),this.updateArrow(t),n.group.height("auto"),this},insertBefore:function(e,t){t=this.element.find(t);var n=this._insert(e,t,t.parent());return l(n.items,(function(){t.before(this),X(this)})),n.group.height("auto"),this},insertAfter:function(e,t){t=this.element.find(t);var n=this._insert(e,t,t.parent());return l(n.items,(function(){t.after(this),X(this)})),n.group.height("auto"),this},remove:function(e){var t=this,n=(e=this.element.find(e)).parentsUntil(t.element,b),i=e.parent("ul");return e.remove(),!i||i.hasClass("k-panelbar")||i.children(b).length||i.remove(),n.length&&(n=n.eq(0),t.updateArrow(n)),t},reload:function(t){var n=this;(t=n.element.find(t)).each((function(){var t=e(this);n._ajaxRequest(t,t.children("."+T),!t.is(G))}))},_first:function(){return this.element.children(O).first()},_last:function(){var e=this.element.children(O).last(),t=e.children(y);return t[0]?t.children(O).last():e},_current:function(n){var i=this,r=i._focused,o=i._itemId;if(n===t)return r;i.element.removeAttr("aria-activedescendant"),r&&r.length&&(r[0].id===o&&r.removeAttr("id"),r.children(v).removeClass(F)),e(n).length&&(o=n[0].id||o,n.attr("id",o).children(v).addClass(F),i.element.attr("aria-activedescendant",o)),i._focused=n},_keydown:function(e){var t=this,n=e.keyCode,i=t._current();e.target==e.currentTarget&&(n==o.DOWN||n==o.RIGHT?(t._current(t._nextItem(i)),e.preventDefault()):n==o.UP||n==o.LEFT?(t._current(t._prevItem(i)),e.preventDefault()):n==o.ENTER||n==o.SPACEBAR?(t._click(e),e.preventDefault()):n==o.HOME?(t._current(t._first()),e.preventDefault()):n==o.END&&(t._current(t._last()),e.preventDefault()))},_nextItem:function(e){if(!e)return this._first();var t=e.children(y),n=e.nextAll(":visible").first();return t[0]&&(n=t.children().first()),n[0]||(n=e.parent(y).parent(b).next()),n[0]||(n=this._first()),n},_prevItem:function(e){if(!e)return this._last();var t,n=e.prevAll(":visible").first();if(n[0])for(t=n;t[0];)(t=t.children(y).children().last())[0]&&(n=t);else(n=e.parent(y).parent(b))[0]||(n=this._last());return n},_insert:function(t,n,r){var o,s,l=this,c=e.isPlainObject(t),d=n&&n[0];if(d||(r=l.element),s={firstLevel:r.hasClass("k-panelbar"),expanded:e(n).hasClass(z),length:r.children().length},d&&!r.length&&(r=e(l.renderGroup({group:s,options:l.options})),i.applyStylesFromKendoAttributes(r,["display"]),r.appendTo(n)),c||Array.isArray(t)||t instanceof h){if(t instanceof h&&(t=t.data()),o=e.map(c?[t]:t,(function(t,n){if("string"==typeof t)return e(t);{let r=e(l.renderItem({group:s,item:a(t,{index:n})}));return i.applyStylesFromKendoAttributes(r,["display"]),r}})),d){var u=l.dataItem(n);u?(u.hasChildren=!0,n.attr(W,u.expanded).not("."+z).children("ul").attr(j,!u.expanded)):n.attr(W,!1)}}else o="string"==typeof t&&"<"!=t.charAt(0)?l.element.find(t):e(t),l._updateItemsClasses(o);return t.length||(t=[t]),{items:o,group:r}},_toggleHover:function(t){var n=e(t.currentTarget);n.parents("li."+R).length||n.toggleClass("k-hover",t.type==E)},_updateClasses:function(){var t,n,i,r,o,a=this;r=(t=a.element.find("li > ul").not((function(){return e(this).parentsUntil(".k-panelbar","div").length})).addClass("k-panelbar-group").attr("role","group")).parent(),i=(o=a.dataItem(r))&&o.expanded||!1,t.parent().not("["+W+"]").attr(W,i).not("."+z).children("ul").attr(j,!i).hide(),n=a.element.add(t).children(),a._updateItemsClasses(n),a.updateArrow(n)},_updateItemsClasses:function(e){for(var t=e.length,n=0;n<t;n++)this._updateItemClasses(e[n],n)},_updateItemClasses:function(t,n){var r,o,a=this._selected,s=this.options.contentUrls,l=s&&s[n],c=this.element[0];t=e(t).addClass("k-panelbar-item").attr({role:"treeitem","aria-selected":!1}),i.support.browser.msie&&t.css("list-style-position","inside").css("list-style-position",""),t.children("img").addClass(w),(o=t.children("a").addClass(g))[0]&&(o.attr("href",l),o.children("img").addClass(w)),t.filter("li[disabled]").addClass("k-disabled").attr(U,!0).prop("disabled",!1),t.children("div").addClass(T+" k-panelbar-content").attr(j,!0).hide().parent().attr(W,!1),(o=t.children(B))[0]&&(a&&a.attr(q,!1).children(B).removeClass(L),o.addClass(L),this._selected=t.attr(q,!0)),t.children(v)[0]||(r="<span class='"+g+"'><span class='k-panelbar-item-text'></span></span>",s&&s[n]&&t[0].parentNode==c&&(r='<a class="k-link" href="'+s[n]+'"></a>'),t.contents().filter((function(){return!(this.nodeName.match(p)||3==this.nodeType&&!i.trim(this.nodeValue.trim))})).wrapAll(r)),t.parent(".k-panelbar")[0]?t.addClass("k-panelbar-header"):t.addClass("k-panelbar-item"),/k\-level\-\d+/i.test(t.attr("class"))||t.addClass("k-level-"+t.parentsUntil(this.element,"ul").length)},_click:function(t){var n,i,r,o=this,a=t.type==S?e(t.target):o._current().children(v),s=o.element;if(!a.parents("li."+R).length&&a.closest(".k-panelbar")[0]==s[0]&&(!a.is(":kendoFocusable")||a.hasClass(g))){var l=a.closest(v),c=l.closest(b);o._updateSelected(l);var d=c.children(".k-panelbar-group,.k-panelbar-content"),u=this.dataItem(c);if(!d.length&&(o.options.loadOnDemand&&u&&u.hasChildren||this._hasChildItems(c)||c.content||c.contentUrl)&&(d=o._addGroupElement(c)),i=c.find(P).add(c.find(H)),n=!(!((r=l.attr(m))&&("#"==r.charAt(r.length-1)||-1!=r.indexOf("#"+o.element[0].id+"-")))&&!i.length),i.data("animating")&&n)t.preventDefault();else if(o._triggerEvent(C,c)&&(n=!0),!1!==n)if(o.options.expandMode==K&&o._collapseAllExpanded(c)&&n)t.preventDefault();else{if(i.length){var h=i.is(G);o._triggerEvent(h?A:x,c)||(n=o._toggleItem(c,h))}n&&t.preventDefault()}}},_hasChildItems:function(e){return e.items&&e.items.length>0||e.hasChildren},_toggleItem:function(e,n,i){var r,o,a=this,s=e.find(P),l=e.find(v).attr(m),c=a.dataItem(e),d=!n,u=c&&c.loaded();return c&&!i&&c.expanded!==d?(c.set("expanded",d),r=c.hasChildren||!!c.content||!!c.contentUrl):(!c||i&&"true"!==i||u||c.content||c.contentUrl?s.length?(this._toggleGroup(s,n),r=!0):(o=e.children("."+T)).length&&(r=!0,o.is(":empty")&&l!==t?a._ajaxRequest(e,o,n):a._toggleGroup(o,n)):(a.options.loadOnDemand&&this._progress(e,!0),e.children(".k-panelbar-group,.k-panelbar-content").remove(),r=c.hasChildren,c.load()),r)},_toggleGroup:function(t,n){var r=this,o=r.options.animation,s=o.expand,l=o.collapse&&"effects"in o.collapse,c=a({},o.expand,o.collapse);t.hasClass("k-hidden")&&t.removeClass("k-hidden"),l||(c=a(c,{reverse:!0})),t.is(G)==n?(t.attr(j,!!n),t.parent().attr(W,!n).toggleClass(z,!n).find("> .k-link > .k-panelbar-collapse,> .k-link > .k-panelbar-expand").each((function(t,r){let o=e(r);o.removeClass("k-panelbar-expand k-panelbar-collapse"),i.ui.icon(o,{icon:n?"chevron-down":"chevron-up",iconClass:n?"k-panelbar-expand":"k-panelbar-collapse"})})),n?(s=a(c,{hide:!0})).complete=function(){r._animationCallback()}:s=a({complete:function(e){r._triggerEvent(D,e.closest(b)),r._animationCallback()}},s),t.toggle(0).kendoStop(!0,!0).kendoAnimate(s)):r._animating=!1},_animationCallback:function(){this.trigger("complete"),this._animating=!1},_addGroupElement:function(t){var n=e('<ul role="group" aria-hidden="true" class="k-panelbar-group"></ul>').hide();return t.append(n),n},_collapseAllExpanded:function(t){var n,i=this,r=!1,o=t.find(P).add(t.find(H));return o.is(G)&&(r=!0),o.is(G)||0===o.length||((n=t.siblings()).find(P).add(n.find(H)).filter((function(){return e(this).is(G)})).each((function(t,n){n=e(n),(r=i._triggerEvent(A,n.closest(b)))||i._toggleGroup(n,!0)})),i.one("complete",(function(){setTimeout((function(){for(let e=0;e<n.length;e++){let t=i.dataItem(n.eq(e));t&&t.set("expanded",!1)}}))}))),r},_ajaxRequest:function(t,n,r){var o=this,a=t.find(".k-panelbar-collapse, .k-panelbar-expand"),s=t.find(v),l=setTimeout((function(){a.empty().removeClass("k-i-chevron-up k-i-chevron-down k-svg-i-chevron-up k-svg-i-chevron-down").addClass("k-i-loading")}),100),c=s.attr(m);e.ajax({type:"GET",cache:!1,url:c,dataType:"html",data:{},error:function(e,t){a.removeClass("k-i-loading"),i.ui.icon(a,{icon:a.hasClass("k-panelbar-expand")?"chevron-down":"chevron-up"}),o.trigger(_,{xhr:e,status:t})&&this.complete()},complete:function(){clearTimeout(l),i.ui.icon(a,{icon:a.hasClass("k-panelbar-expand")?"chevron-down":"chevron-up"}),a.removeClass("k-i-loading")},success:function(e){try{n.html(e)}catch(e){var i=window.console;i&&i.error&&i.error(e.name+": "+e.message+" in "+c),this.error(this.xhr,"error")}o._toggleGroup(n,r),o.trigger(I,{item:t[0],contentElement:n[0]})}})},_triggerEvent:function(e,t){return this.trigger(e,{item:t[0]})},_updateSelected:function(e,t){var n=this,i=n.element,r=e.parent(b),o=n._selected,a=n.dataItem(r);0!=n.options.selectable?(o&&o.attr(q,!1),n._selected=r.attr(q,!0),i.find($).removeClass(L),e.addClass(L),n._current(r[0]?r:null),a&&a.set("selected",!0),t||n.trigger(k)):n._current(r[0]?r:null)},_animations:function(e){e&&"animation"in e&&!e.animation&&(e.animation={expand:{effects:{}},collapse:{hide:!0,effects:{}}})},renderItem:function(e){var t=this;e=a({panelBar:t,group:{}},e);var n=t.templates.empty,i=e.item;return t.templates.item(a(e,{itemWrapper:t.templates.itemWrapper,renderContent:t.renderContent,arrow:t._hasChildItems(i)||i.content||i.contentUrl?t.templates.arrow:n,subGroup:!e.loadOnDemand||i.expanded?t.renderGroup:n},Q))},renderGroup:function(e){return(this&&this.templates||e.panelBar.templates).group(a({renderItems:function(e){let t="",n=0,i=e.items,r=i?i.length:0,o=a({length:r},e.group);for(;n<r;n++)t+=e.panelBar.renderItem(a(e,{group:o,item:a({index:n},i[n])}));return t}},e,Q))},renderContent:function(e){return e.panelBar.templates.content(a(e,Q))}});i.ui.plugin(Z)}(window.kendo.jQuery);kendo;!function(e){var t=".kendoResponsivePanel",n="open",i="close",r="click"+t+" touchstart"+t+" touchend"+t,o=kendo.ui.Widget,a=o.extend({init:function(n,i){o.fn.init.call(this,n,i),this._guid="_"+kendo.guid(),this._toggleHandler=this._toggleButtonClick.bind(this),this._closeHandler=this._close.bind(this),e(document.documentElement).on(r,this.options.toggleButton,this._toggleHandler),this._registerBreakpoint(),this.options.content&&(kendo.destroy(this.element.children()),this.element.html(this.options.content)),this.element.addClass("k-rpanel k-rpanel-"+this.options.orientation+" "+this._guid),this._resizeHandler=this.resize.bind(this,!0),e(window).on("resize"+t,this._resizeHandler)},_mediaQuery:({breakpoint:e,guid:t,toggleButton:n})=>`@media (max-width: ${e-1}px) {.${t}.k-rpanel-animate.k-rpanel-left,.${t}.k-rpanel-animate.k-rpanel-right {-webkit-transition: -webkit-transform .2s ease-out;-ms-transition: -ms-transform .2s ease-out;transition: transform .2s ease-out;} .${t}.k-rpanel-top {overflow: hidden;}.${t}.k-rpanel-animate.k-rpanel-top {-webkit-transition: max-height .2s linear;-ms-transition: max-height .2s linear;transition: max-height .2s linear;}} @media (min-width: ${e}px) {${n} { display: none; } .${t}.k-rpanel-left { float: left; } .${t}.k-rpanel-right { float: right; } .${t}.k-rpanel-left, .${t}.k-rpanel-right {position: relative;-webkit-transform: translateX(0);-ms-transform: translateX(0);transform: translateX(0);-webkit-transform: translateX(0) translateZ(0);-ms-transform: translateX(0) translateZ(0);transform: translateX(0) translateZ(0);} .k-ie9 .${t}.k-rpanel-left { left: 0; } .${t}.k-rpanel-top { max-height: none; }}`,_registerBreakpoint:function(){var e=this.options;this._registerStyle(this._mediaQuery({breakpoint:e.breakpoint,toggleButton:e.toggleButton,guid:this._guid}))},_registerStyle:function(t){var n=e("head,body")[0],i=document.createElement("style"),r=this.options.nonce;r&&i.setAttribute("nonce",r),n.appendChild(i),i.styleSheet?i.styleSheet.cssText=t:i.appendChild(document.createTextNode(t))},options:{name:"ResponsivePanel",content:"",nonce:"",orientation:"left",toggleButton:".k-rpanel-toggle",breakpoint:640,autoClose:!0},events:[n,i],_resize:function(){this.element.removeClass("k-rpanel-animate k-rpanel-expanded"),e(document.documentElement).off(r,this._closeHandler)},_toggleButtonClick:function(e){e.preventDefault(),"touchend"!=e.type&&(this.element.hasClass("k-rpanel-expanded")?this.close():this.open())},open:function(){this.trigger(n)||(this.element.addClass("k-rpanel-animate k-rpanel-expanded"),this.options.autoClose&&e(document.documentElement).on(r,this._closeHandler))},close:function(){this.trigger(i)||(this.element.addClass("k-rpanel-animate").removeClass("k-rpanel-expanded"),e(document.documentElement).off(r,this._closeHandler))},_close:function(t){var n=t.isDefaultPrevented();e(t.target).closest(this.options.toggleButton+",.k-rpanel").length||n||this.close()},destroy:function(){o.fn.destroy.call(this),e(window).off("resize"+t,this._resizeHandler),e(document.documentElement).off(r,this._closeHandler)}});kendo.ui.plugin(a)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.keys,r=n.html,o=n.parseDate,a=n.htmlEncode,s=n._activeElement,l=n._extractFormat,c=n.support,d=c.browser,u=n.mediaQuery,h=n.ui,p=h.Widget,f="open",m="close",g="change",v=".kendoTimePicker",_="click"+v,b="disabled",y="readonly",w="li",k="k-focus",x="k-hover",C="mouseenter"+v+" mouseleave"+v,S="mousedown"+v,T=6e4,D=864e5,A="k-selected",M="k-disabled",E="aria-selected",I="aria-expanded",z="aria-hidden",P="aria-disabled",H="aria-readonly",F="aria-activedescendant",R="id",L=Array.isArray,B=e.extend,O=Date,V=new O,N=({mainSize:e,messages:t,buttonSize:i})=>`<div><div tabindex="0" class="k-timeselector ${e}"><div class="k-time-header"><span class="k-title"></span>`+n.html.renderButton(`<button class="k-time-now" title="Select now" aria-label="Select now">${a(t.now)}</button>`,{fillMode:"flat",size:i})+'</div><div class="k-time-list-container"><span class="k-time-highlight"></span></div></div>'+$(i,t)+"</div>",$=(e,t)=>'<div class="k-time-footer k-actions k-actions-stretched k-actions-horizontal">'+n.html.renderButton(`<button class="k-time-accept" title="Set time" aria-label="Set time">${a(t.set)}</button>`,{size:e,themeColor:"primary"})+n.html.renderButton(`<button class="k-time-cancel" title="Cancel changes" aria-label="Cancel changes">${a(t.cancel)}</button>`,{size:e})+"</div>";V=new Date(V.getFullYear(),V.getMonth(),V.getDate(),0,0,0);var U=function(e){var t=this,i=e.focusTime,r=e.id;t.options=e,t._dates=[],t.bigScreenMQL=u("large"),t.smallScreenMQL=u("small"),"auto"==t.options.adaptiveMode&&t.smallScreenMQL.onChange((function(){t.popup&&n.isFunction(t.popup.fullscreen)&&(t.popup.fullscreen(t.smallScreenMQL.mediaQueryList.matches),t.options.timeView&&"scroll"===t.options.timeView.list&&(t.addTranslate(),t._updateRanges()))})),t._createList(e.timeView&&"scroll"===e.timeView.list),i&&(t._focusTime=new O(V.getFullYear(),V.getMonth(),V.getDate(),i.getHours(),i.getMinutes(),i.getSeconds())),r&&(t._timeViewID=r+"_timeview",t._optionID=r+"_option_selected",t.ul.attr(R,t._timeViewID)),t._heightHandler=t._height.bind(t),t._popup()};function W(e){return 60*e.getHours()*T+e.getMinutes()*T+1e3*e.getSeconds()+e.getMilliseconds()}function j(e,t,n){var i,r=W(t),o=W(n);return!e||r==o||(r>(i=W(e))&&(i+=D),o<r&&(o+=D),i>=r&&i<=o)}U.prototype={_createList:function(e){e?this._createScrollList():this._createClassicRenderingList()},_createScrollList:function(){var t="auto"!=this.options.adaptiveMode||this.bigScreenMQL.mediaQueryList.matches?this.options.size||"medium":"large",i=e.extend({},this.options,{mainSize:n.getValidCssClass("k-timeselector-","size",t),buttonSize:t});this.popupContent=e(n.template(N)(i)).on(S,K),this.list=this.popupContent.find(".k-timeselector"),this.ul=this.list.find(".k-time-list-container"),this.list.on("click"+v,".k-time-header button.k-time-now",this._nowClickHandler.bind(this)),this.popupContent.on("click"+v,".k-time-footer button.k-time-cancel",this._cancelClickHandler.bind(this)),this.popupContent.on("click"+v,".k-time-footer button.k-time-accept",this._setClickHandler.bind(this)),this.list.on("mouseover"+v,".k-time-list-wrapper",this._mouseOverHandler.bind(this)),this.list.on("keydown"+v,this._scrollerKeyDownHandler.bind(this))},_scrollerKeyDownHandler:function(t){var r=this,o=t.keyCode,a=e(t.currentTarget).find(".k-time-list-wrapper.k-focus"),s=r.list.find(".k-time-list-wrapper"),l=s.length,c=s.index(a),d=n.support.isRtl(r.wrapper),u=Z(a.find(".k-item:visible").eq(0)),h=a.find(".k-time-container.k-content.k-scrollable");a.length&&(o==i.RIGHT&&!d||o==i.LEFT&&d?c+1<l&&r._focusList(s.eq(c+1)):o==i.LEFT&&!d||o==i.RIGHT&&d?c-1>=0&&r._focusList(s.eq(c-1)):o==i.UP?(h.scrollTop(h.scrollTop()-u),t.preventDefault()):o==i.DOWN?(h.scrollTop(h.scrollTop()+u),t.preventDefault()):o===i.ENTER?r._setClickHandler(t):o===i.ESC&&r._cancelClickHandler(t))},_mouseOverHandler:function(t){this._focusList(e(t.currentTarget))},_focusList:function(e){this.list.find(".k-time-list-wrapper").removeClass(k),e.addClass(k),this.list.trigger("focus"),this._scrollTop=e.find(".k-scrollable").scrollTop()},_createClassicRenderingList:function(){var t=this,i=e('<div class="k-list '+n.getValidCssClass("k-list-","size",t.options.size)+'"><div class="k-list-content"><ul tabindex="-1" role="listbox" aria-hidden="true" unselectable="on" class="k-list-ul"/></div></div>');t.ul=i.find("ul").css({overflow:c.kineticScrollNeeded?"":"auto"}).on(_,w,t._click.bind(t)).on("mouseenter"+v,w,(function(){e(this).addClass(x)})).on("mouseleave"+v,w,(function(){e(this).removeClass(x)})),t.list=e("<div class='k-list-container k-list-scroller' unselectable='on'/>").append(i).on(S,K),t.template=e=>`<li tabindex="-1" role="option" class="k-list-item" unselectable="on"><span class="k-list-item-text">${e}</span></li>`},current:function(n){var i=this,r=i.options.active;if(n===t)return i._current;i._current&&(i._current.removeClass(A),i._current&&i._current.length&&(i._current[0].removeAttribute(R),i._current[0].removeAttribute(E))),n&&(n=e(n).addClass(A).attr(R,i._optionID).attr(E,!0),i.scroll(n[0])),i._current=n,r&&r(n)},_updateTitle:function(){this.list.find(".k-time-header > .k-title").html(n.toString(this._value,this.options.format,this.options.culture))},applyValue:function(e){if(e){var t,i=Q(this.options.format.toLowerCase(),"t"),r=e.getHours(),o=e.getMinutes(),a=e.getSeconds(),s=n.attr("index"),l=this.ul.find("["+s+'="1"]'),c=this.ul.find("["+s+'="2"]'),d=this.ul.find("["+s+'="3"]'),u=this.ul.find("["+s+'="4"]');i&&(r>=12?(t="PM",r>12&&(r-=12)):(t="AM",0===r&&(r=12))),this._internalScroll=!0,l.length&&this._scrollListToPosition(l,r),c.length&&this._scrollListToPosition(c,o),d.length&&this._scrollListToPosition(d,a),u.length&&this._scrollListToPosition(u,t),this._internalScroll=!1}},_scrollListToPosition:function(e,t){var n=e.find('.k-item[data-value="'+X(t)+'"]'),i=Z(n);e.scrollTop(e.find(".k-item:visible").index(n)*i)},close:function(){this.popup&&this.popup.close()},destroy:function(){var e=this;e.ul.off(v),e.list.off(v),e.popupContent&&e.popupContent.off(v),e.popup&&e.popup.destroy(),e.bigScreenMQL&&e.bigScreenMQL.destroy(),e.smallScreenMQL&&e.smallScreenMQL.destroy()},open:function(){var e,t=this;(!t.ul[0].firstChild||t.ul.find("li").length<1)&&t.bind(),t._focusTime&&t.value(t._focusTime),e=t.popup._hovered,t.popup._hovered=!0,t.popup.open(),setTimeout((function(){t.popup._hovered=e}),1),t._current&&t.scroll(t._current[0])},dataBind:function(e){for(var t,i=this,r=i.options,o=r.format,a=n.toString,s=i.template,l=e.length,c=0,d="";c<l;c++)j(t=e[c],r.min,r.max)&&(d+=s(a(t,o,r.culture)));i._html(d)},refresh:function(){var e,t,i,r=this,o=r.options,a=o.format,s=(e=new O,t=new O(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0),i=new O(e.getFullYear(),e.getMonth(),e.getDate(),12,0,0),-1*(t.getTimezoneOffset()-i.getTimezoneOffset())),l=s<0,c=n.parseDate(r._value),d=Y(c||new Date,o.min),u=o.min,h=o.max,p=W(u),f=W(h),m=W(function(e){var t=new Date(2100,0,1);return t.setMinutes(-e),t}(o.interval)),g=o.interval*T,v=n.toString,_=r.template,b=o.useValueToRender?d:new Date(+o.min),y=new O(b),w="";p==f&&m!==f||p>f&&(f+=D),o.timeView&&"scroll"===o.timeView.list?w=r._createListContent(n.date.splitDateFormat(a),o.interval):r.getDatesInRange(undefined,f,y,h,g,b).forEach((function(e){w+=_(v(e,a,o.culture))})),r._html(w)},_showAllHiddenItems:function(){for(var t,n=this.list.find(".k-time-container"),i=n.length,r=0;r<i;r++)(t=e(n[r])).find(".k-item:hidden").show(),this._updateListBottomOffset(t)},_updateListBottomOffset:function(e){var t=Z(e.find(".k-item:visible").eq(0)),n=e.outerHeight()-t;e.find(".k-scrollable-placeholder").css({height:e.find("ul").height()+n})},_updateHoursRange:function(){var t,i,r=this,o=n.attr("index"),a=this.ul.find("["+o+'="1"]'),s=this._minHours,l=this._maxHours,c=Q(this.options.format.toLowerCase(),"t"),d=this._findSelectedValue(this.ul.find("["+o+'="4"]'));a.length&&(c&&d?("AM"===d?(s<12&&(i=!0),l<12&&(t=!0)):"PM"===d&&(s>12&&(i=!0,s-=12),l>12&&(t=!0,l-=12)),a.find(".k-item").each((function(n,o){var a=+(o=e(o)).attr("data-value");r._validateMin&&i&&a<s||r._validateMax&&t&&a>l?o.hide():o.show()}))):a.find(".k-item").each((function(t,n){var i=+(n=e(n)).attr("data-value");r._validateMin&&i<s||r._validateMax&&i>l?n.hide():n.show()})),this._updateListBottomOffset(a))},_updateMinutesRange:function(){var t=this,i=n.attr("index"),r=this.ul.find("["+i+'="2"]'),o=this._minHours,a=this._maxHours,s=this._minMinutes,l=this._maxMinutes,c=+this._findSelectedValue(this.ul.find("["+i+'="1"]')),d=Q(this.options.format.toLowerCase(),"t"),u=this._findSelectedValue(this.ul.find("["+i+'="4"]'));d&&"PM"===u&&(c+=12),r.length&&(r.find(".k-item").each((function(n,i){var r=+(i=e(i)).attr("data-value");t._validateMin&&r<s&&(o&&c)===o||t._validateMax&&r>l&&(a&&c)===a?i.hide():i.show()})),this._updateListBottomOffset(r))},_updateSecondsRange:function(){var t=this,i=n.attr("index"),r=this.ul.find("["+i+'="3"]'),o=this._minSeconds,a=this._minSeconds,s=this._minMinutes,l=this._maxMinutes,c=+this._findSelectedValue(this.ul.find("["+i+'="2"]'));r.length&&(r.find(".k-item").each((function(n,i){var r=+(i=e(i)).attr("data-value");t._validateMin&&r<o&&s&&c===s||t._validateMax&&r>a&&l&&c===l?i.hide():i.show()})),this._updateListBottomOffset(r))},_updateDesignatorRange:function(){var e=this._minHours,t=this._maxHours,i=n.attr("index"),r=this.ul.find("["+i+'="4"]');r.length&&(this._validateMin&&e>=12?r.find('.k-item[data-value="AM"]').hide():r.find('.k-item[data-value="AM"]').show(),this._validateMax&&t<12?r.find('.k-item[data-value="PM"]').hide():r.find('.k-item[data-value="PM"]').show())},_updateRanges:function(){if(this.options.specifiedRange){this._currentlySelected||(this._currentlySelected=new Date);var e=this.options.endTime?this.options.endTime:this.options.max,t=this.options.startTime?this.options.startTime:this.options.min;if(this.options.validateDate){if(e.getFullYear()===this._currentlySelected.getFullYear()&&e.getMonth()===this._currentlySelected.getMonth()&&e.getDate()===this._currentlySelected.getDate()?this._validateMax=!0:this._validateMax=!1,t.getFullYear()===this._currentlySelected.getFullYear()&&t.getMonth()===this._currentlySelected.getMonth()&&t.getDate()===this._currentlySelected.getDate()?this._validateMin=!0:this._validateMin=!1,!this._validateMax&&!this._validateMin)return void this._showAllHiddenItems()}else this._validateMax=!0,this._validateMin=!0;this._minMinutes=t.getMinutes(),this._maxMinutes=e.getMinutes(),this._minHours=t.getHours(),this._maxHours=e.getHours(),this._minSeconds=t.getSeconds(),this._maxSeconds=e.getSeconds(),this._updateDesignatorRange(),this._updateHoursRange(),this._updateMinutesRange(),this._updateSecondsRange()}},addTranslate:function(){for(var e,t,n,i,r,o=this.ul.find(".k-time-container.k-content.k-scrollable"),a=o.length,s=0;s<a;s++)t=Z((e=o.eq(s)).find(".k-item:visible").eq(0)),i="translateY("+((n=e.outerHeight())-t)/2+"px)",r=n-t,e.find("ul").css({transform:i,"-ms-transform":i}),e.find(".k-scrollable-placeholder").css({height:e.find("ul").height()+r}),e.off(v).on("click"+v,".k-item",this._itemClickHandler.bind(this)).on("scroll"+v,this._listScrollHandler.bind(this))},_nowClickHandler:function(e){e.preventDefault();var t=new Date;this.value(t),this.options.change(n.toString(t,this.options.format,this.options.culture),!0)},_cancelClickHandler:function(e){e.preventDefault(),this.value(this._value),this.popup&&this.popup.close()},_setClickHandler:function(e){e.preventDefault(),this._value=new Date(this._currentlySelected),this.options.change(n.toString(this._currentlySelected,this.options.format,this.options.culture),!0),this.popup&&this.popup.close()},_listScrollHandler:function(t){var n=this,i=Z(e(t.currentTarget).find(".k-item:visible").eq(0));n._internalScroll||(n._scrollingTimeout&&clearTimeout(n._scrollingTimeout),n._scrollingTimeout=setTimeout((function(){t.currentTarget.scrollTop%i>1&&(t.currentTarget.scrollTop+=i-t.currentTarget.scrollTop%i),n._scrollTop=t.currentTarget.scrollTop,n._updateRanges(),n._updateCurrentlySelected()}),100))},_updateCurrentlySelected:function(){var e,i,r,o,a=Q(this.options.format.toLowerCase(),"t"),s=n.attr("index"),l=this.ul.find("["+s+'="1"]'),c=this.ul.find("["+s+'="2"]'),d=this.ul.find("["+s+'="3"]'),u=this.ul.find("["+s+'="4"]');this.ul.is(":visible")&&(this._currentlySelected||(this._currentlySelected=this._value?new Date(this._value):new Date),l.length&&(e=+this._findSelectedValue(l)),c.length&&(i=+this._findSelectedValue(c)),d.length&&(r=+this._findSelectedValue(d)),u.length&&(o=this._findSelectedValue(u)),a&&("PM"==o&&24==(e+=12)&&(e=12),"AM"===o&&12===e&&(e=0)),e!==t&&this._currentlySelected.setHours(e),i!==t&&this._currentlySelected.setMinutes(i),r!==t&&this._currentlySelected.setSeconds(r))},_findSelectedValue:function(e){var t,n,i=(t=e.scrollTop(),n=Z(e.find(".k-item:visible").eq(0)),Math.max(Math.round(t/n),0));return e.find(".k-item:visible").eq(i).attr("data-value")},_itemClickHandler:function(t){var n=e(t.originalEvent.currentTarget),i=n.find(".k-item:visible").index(e(t.currentTarget)),r=Z(n.find(".k-item:visible").eq(0));n.scrollTop(i*r)},getDatesInRange:function(e,t,n,i,r,o){for(var a=[];;){if(t&&(W(o)>=t||n.getDate()!=o.getDate())){e=W(o),n<o&&(e+=D),e>t&&(o=new O(+i)),W(o)>0&&a.push(new Date(o));break}if(n.getDate()!=o.getDate())break;if(a.push(new Date(o)),o.setTime(o.getTime()+r),!t&&this.options.maxSet)break}return a},_createListContent:function(e,t){for(var n,i,r=e.length,o="",a=0;a<r;a++)"literal"===(n=e[a]).type||"dayperiod"==n.type?o+=this._literalTemplate(n):(i=this._getValues(n,!0,t),o+=this._itemTemplate(i.values,n,this.options.messages[n.type],i.index));return o},_itemTemplate:function(e,t,i,r){var o="",a=e.length,s=n.attr("index");o+='<div class="k-time-list-wrapper" role="presentation"><span class="k-title">'+(i||t.type)+'</span><div class="k-time-list"><div class="k-time-container k-content k-scrollable" role="presentation" '+s+'="'+r+'"><ul class="k-reset">';for(var l=0;l<a;l++)o+='<li class="k-item" data-value="'+e[l]+'"><span>'+e[l]+"</span></li>";return o+='</ul><div class="k-scrollable-placeholder"></div></div></div></div>'},_getValues:function(t,n,i){var r,o,a=[],s=0,l=0,c=0;for(e.isPlainObject(i)&&(l=i[t.type]||0),"hour"===t.type?(s=t.hour12?1:0,r=1,o=t.hour12?12:23):"minute"===t.type?(r=2,o=59):"second"===t.type&&(r=3,o=59);s<=o;s++)l>0?((0===s||1===s&&l>1&&"hour"===t.type)&&a.push(n?X(c):c),s%l==0&&c+l<=o&&(c+=l,a.push(n?X(c):c))):a.push(n?X(s):s);return{values:a,index:r}},_literalTemplate:function(e){var t=" tt"===e.pattern||"aa"===e.pattern,n='<div class="k-time-separator">'+(t?":":e.pattern)+"</div>";return t&&(n+=this._itemTemplate(["AM","PM"],e,"AM/PM",4)),n},bind:function(){var e=this,t=e.options,n=t.dates;!n||!n[0]||t.timeView&&"scroll"===t.timeView.list?(e.refresh(),e.addTranslate(),e._value&&e.applyValue(e._value)):e.dataBind(n)},_html:function(e){var t=this;t.options.timeView&&"scroll"===t.options.timeView.list?(e='<span class="k-time-highlight"></span>'+e,t.ul.html(e)):(t.ul[0].innerHTML=e,t.popup.unbind(f,t._heightHandler),t.popup.one(f,t._heightHandler),t.current(null),t.select(t._value))},scroll:function(e){e&&(e.scrollIntoViewIfNeeded?e.scrollIntoViewIfNeeded():function(e,t){function n(e,t){return{start:e,length:t,end:e+t}}function i(e,n){return!1===t||n.start<e.end&&e.start<n.end?Math.min(e.start,Math.max(n.start,e.end-n.length)):(e.start+e.end-n.length)/2}function r(e,t){return{x:e,y:t,translate:function(n,i){return r(e+n,t+i)}}}function o(e,t){for(;e;)t=t.translate(e.offsetLeft,e.offsetTop),e=e.offsetParent;return t}var a,s=o(e,r(0,0)),l=r(e.offsetWidth,e.offsetHeight),c=e.parentNode;for(;c instanceof HTMLElement;)a=o(c,r(c.clientLeft,c.clientTop)),c.scrollLeft=i(n(s.x-a.x,l.x),n(c.scrollLeft,c.clientWidth)),c.scrollTop=i(n(s.y-a.y,l.y),n(c.scrollTop,c.clientHeight)),s=s.translate(-c.scrollLeft,-c.scrollTop),c=c.parentNode}(e))},select:function(t){var i,r=this,o=r.options,a=r._current;t instanceof Date&&(t=n.toString(t,o.format,o.culture)),"string"==typeof t&&(t=a&&a.text()===t?a:(t=e.grep(r.ul[0].childNodes,(function(e){return(e.textContent||e.innerText)==t})))[0]?t:null),i=r._distinctSelection(t),r.current(i)},_distinctSelection:function(t){var n,i,r=this;return t&&t.length>1&&(n=W(r._value),i=e.inArray(n,r._dates),t=r.ul.children()[i]),t},setOptions:function(e){var t=this.options;e.min=o(e.min),e.max=o(e.max),this.options=B(t,e,{active:t.active,change:t.change,close:t.close,open:t.open}),this.bind()},toggle:function(){var e=this;e.popup.visible()?e.close():e.open()},value:function(e){var t=this;t._value=e,t.ul[0].firstChild&&(t.options.timeView&&"scroll"===t.options.timeView.list?t.applyValue(e):t.select(e))},_click:function(t){let n=this,i=e(t.currentTarget),r=i.text(),o=n.options.dates,a=n.options.min,s=n.options.max;o&&o.length>0&&(a.getTime()!==s.getTime()&&(o=o.filter((e=>n._inRange(e)))),r=o[i.index()]),t.isDefaultPrevented()||(n.select(i),n.options.change(r,!0),n.close())},_inRange(e){const t=this.options.min,n=this.options.max,i=3600*e.getHours()+60*e.getMinutes()+e.getSeconds(),r=3600*t.getHours()+60*t.getMinutes()+t.getSeconds(),o=3600*n.getHours()+60*n.getMinutes()+n.getSeconds();return i>=r&&i<=o},_height:function(){var e=this,t=e.list,n=t.parent(".k-child-animation-container"),i=n.closest(".k-animation-container"),r=e.options.height,o=t.add(i),a=e.ul[0];a.children.length&&(o.add(n).show(),t.add(n).height(a.scrollHeight>r&&("auto"!=e.options.adaptiveMode||e.bigScreenMQL.mediaQueryList.matches)?r:"auto"),o.hide())},_parse:function(e){var t=this.options,n=W(t.min)!=W(V)?t.min:null,i=W(t.max)!=W(V)?t.max:null,r=this._value||n||i||V;return e instanceof O||(e=o(e,t.parseFormats,t.culture))&&(e=new O(r.getFullYear(),r.getMonth(),r.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())),e},_adjustListWidth:function(){var e,t,i=this.list,r=i[0].style.width,o=this.options.anchor,a=n._outerWidth;!i.data("width")&&r||(t=(e=window.getComputedStyle?window.getComputedStyle(o[0],null):0)?parseFloat(e.width):a(o),e&&(d.mozilla||d.msie)&&(t+=parseFloat(e.paddingLeft)+parseFloat(e.paddingRight)+parseFloat(e.borderLeftWidth)+parseFloat(e.borderRightWidth)),r=t-(a(i)-i.width()),i.css({fontFamily:o.css("font-family"),width:"auto"!=this.options.adaptiveMode||this.bigScreenMQL.mediaQueryList.matches?r:"100%"}).data("width",r))},_popup:function(){var e=this,t=e.list,n=e.options,i=n.anchor;if(this.options.omitPopup)t.appendTo(n.timeDiv);else if("auto"!=n.adaptiveMode||e.bigScreenMQL.mediaQueryList.matches)e.popup=new h.Popup(e.popupContent||t,B(n.popup,{anchor:i,open:n.open,close:n.close,animation:n.animation,isRtl:c.isRtl(n.anchor),activate:function(){e.options.timeView&&"scroll"===e.options.timeView.list&&(e.addTranslate(),e._updateRanges(),e._value?e.applyValue(e._value):e._updateCurrentlySelected(),e._focusList(e.list.find(".k-time-list-wrapper").eq(0)))}}));else{var r=e.popupContent||t;r.appendTo(document.body),e.popup=new h.ActionSheet(r,{adaptive:!0,focusOnActivate:!1,title:"Set time",subtitle:"00/00/00",closeButton:!0,fullscreen:e.smallScreenMQL.mediaQueryList.matches,popup:B(n.popup,{anchor:i,open:n.open,close:n.close,animation:n.animation,isRtl:c.isRtl(n.anchor)}),activate:function(){e.options.timeView&&"scroll"===e.options.timeView.list&&(e.addTranslate(),e._updateRanges(),e._value?e.applyValue(e._value):e._updateCurrentlySelected(),e._focusList(e.list.find(".k-time-list-wrapper").eq(0)))}}),e._updateRanges(),e._updateCurrentlySelected(),r.find(".k-time-footer").appendTo(r)}},move:function(e){var t=this,n=e.keyCode,r=t.ul[0],o=t._current,a=n===i.DOWN;if(n===i.UP||a){if(e.altKey)return void t.toggle(a);(o=a?o?o[0].nextSibling:r.firstChild:o?o[0].previousSibling:r.lastChild)&&t.select(o),t.options.change(t._current.text()),e.preventDefault()}else n!==i.ENTER&&n!==i.TAB&&n!==i.ESC||(e.preventDefault(),o&&t.options.change(o.text(),!0),t.close())}},U.getMilliseconds=W,n.TimeView=U;var q=p.extend({init:function(t,i){var r=this;(i=i||{}).componentType=i.componentType||"classic",e.isPlainObject(i.interval)&&"modern"!==i.componentType&&(i.interval=30),p.fn.init.call(r,t,i),t=r.element,(i=r.options).min=o(t.attr("min"))||o(i.min),i.max=o(t.attr("max"))||o(i.max),+i.max==+V&&+i.min==+V||(this._specifiedRange=!0),G(i),r._initialOptions=B({},i),r._wrapper(),r.options.timeView&&"scroll"===r.options.timeView.list&&(r.options.height=null),r.bigScreenMQL=u("large"),"auto"==r.options.adaptiveMode&&r.bigScreenMQL.onChange((()=>{r._createTimeViewProxy(),r._update(r.element.val())})),r._createTimeView(),r._createTimeViewProxy=r._createTimeView.bind(r),r._icon(),r._reset();try{t[0].setAttribute("type","text")}catch(e){t[0].type="text"}t.addClass("k-input-inner").attr({role:"combobox","aria-expanded":!1,"aria-controls":r.timeView._timeViewID,autocomplete:"off"}),t.is("[disabled]")||e(r.element).parents("fieldset").is(":disabled")?r.enable(!1):r.readonly(t.is("[readonly]")),r._createDateInput(),r._old=r._update(i.value||r.element.val()),r._oldText=t.val(),r._applyCssClasses(),i.label&&r._label(),r.element.removeAttr("style"),n.notify(r)},options:{name:"TimePicker",autoAdjust:!0,min:V,max:V,format:"",dates:[],parseFormats:[],focusTime:null,value:null,interval:30,height:200,animation:{},dateInput:!1,messages:{set:"Set",cancel:"Cancel",hour:"hour",minute:"minute",second:"second",millisecond:"millisecond",now:"Now"},adaptiveMode:"none",componentType:"classic",size:"medium",fillMode:"solid",rounded:"medium",label:null,autoCorrectParts:!0},events:[f,m,g],componentTypes:{classic:{timeView:{list:"list"}},modern:{timeView:{list:"scroll"}}},setOptions:function(t){let i=this,r=i._value,o=!!t.componentType;p.fn.setOptions.call(i,t),t=i.options,e.isPlainObject(t.interval)&&"modern"!==t.componentType&&(t.interval=30),+t.max==+V&&+t.min==+V||(this._specifiedRange=!0),i._arrow.off(v),i._arrow.remove(),G(t),t.componentType&&o&&(t.timeView.list="classic"==t.componentType?"list":"scroll",i.options.height="classic"==t.componentType?200:null,i._createTimeView(),i.timeView._value=r),i.timeView.setOptions(t),i._icon(),i._editable(t),i._createDateInput(),r&&i.element.val(n.toString(r,t.format,t.culture)),t.label&&i._inputLabel?i.label.setOptions(t.label):!1===t.label?(i.label._unwrapFloating(),i._inputLabel.remove(),delete i._inputLabel):t.label&&i._label()},dataBind:function(e){L(e)&&this.timeView.dataBind(e)},_createDateInput:function(){const e=this,t=e.options,n=e.element;if(e._dateInput&&(e._dateInput.destroy(),e._dateInput=null),t.dateInput){var i=t.min,r=t.max,o=new O;W(i)==W(r)&&(i=new O(o.getFullYear(),o.getMonth(),o.getDate(),0,0,0),r=new O(o.getFullYear(),o.getMonth(),o.getDate(),24,0,0)),e._dateInput=new h.DateInput(n,{autoAdjust:t.autoAdjust,culture:t.culture,format:t.format,min:i,max:r,value:t.value,interval:t.interval,size:t.size,fillMode:t.fillMode,rounded:t.rounded,messages:t.messages.dateInput,autoCorrectParts:t.autoCorrectParts})}},_editable:function(e){var t=this,n=e.disable,i=e.readonly,r=t._arrow.off(v),o=t.element.off(v),a=t.wrapper.off(v);t._dateInput&&t._dateInput._unbindInput(),i||n?(a.addClass(n?M:"").removeClass(n?"":M),o.attr(b,n).attr(y,i).attr(P,n).attr(H,i)):(a.removeClass(M).on(C,t._toggleHover),o&&o.length&&(o[0].removeAttribute(b),o[0].removeAttribute(y)),o.attr(P,!1).attr(H,!1).on("keydown"+v,t._keydown.bind(t)).on("focusout"+v,t._blur.bind(t)).on("focus"+v,(function(){t.wrapper.addClass(k)})),t._dateInput&&t._dateInput._bindInput(),r.on(_,t._click.bind(t)).on(S,K))},_label:function(){var t=this,i=t.options,r=e.isPlainObject(i.label)?i.label:{content:i.label};t._dateInput&&(r.floatCheck=()=>!(t.value()||t._dateInput._hasDateInput()&&""!==t.element.val()||document.activeElement===t.element[0])&&(t.element.val(""),!0)),t.label=new n.ui.Label(null,e.extend({},r,{widget:t})),t._inputLabel=t.label.element},readonly:function(e){this._editable({readonly:e===t||e,disable:!1}),this.label&&this.label.floatingLabel&&this.label.floatingLabel.readonly(e===t||e)},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)}),this.label&&this.label.floatingLabel&&this.label.floatingLabel.enable(e=e===t||e)},destroy:function(){var e=this;p.fn.destroy.call(e),e.timeView.destroy(),e.element.off(v),e._arrow.off(v),e.wrapper.off(v),e._form&&e._form.off("reset",e._resetHandler),e.label&&e.label.destroy(),e.bigScreenMQL&&e.bigScreenMQL.destroy(),e._createTimeViewProxy=null},close:function(){this.timeView.close()},open:function(){this.timeView.open()},min:function(e){return e&&(this._specifiedRange=!0),this._option("min",e)},max:function(e){return e&&this.timeView?(this._specifiedRange=!0,this.timeView.options.maxSet=!0):this.timeView&&(this.timeView.options.maxSet=!1),this._option("max",e)},value:function(e){var n=this;if(e===t)return n._value;n._old=n._update(e),null===n._old&&n.element.val(""),n._oldText=n.element.val(),n.label&&n.label.floatingLabel&&n.label.floatingLabel.refresh()},_blur:function(){var e=this,t=e.element.val();e._typing=!1,e.options.timeView&&"scroll"===e.options.timeView.list||e.close(),t!==e._oldText&&e._change(t),e.wrapper.removeClass(k)},_click:function(){var e=this,t=e.element;e.timeView.toggle(),c.touch||t[0]===s()||e.options.timeView&&"scroll"===e.options.timeView.list||t.trigger("focus")},_change:function(e){var t,i=this,r=i.element.val();e=i._update(e);var o=(t=!n.calendar.isEqualDate(i._old,e))&&!i._typing,a=r!==i.element.val();(o||a)&&i.element.trigger(g),t&&(i._old=e,i._oldText=i.element.val(),i.trigger(g)),i._typing=!1},_createTimeView:function(){var e,t,n=this,i=n.options,r=n.element;n.timeView&&(n.timeView.destroy(),n.timeView=null),n.timeView=e=new U(B({},i,{id:r.attr(R),size:"auto"!=i.adaptiveMode||n.bigScreenMQL.mediaQueryList.matches?i.size:"large",anchor:n.wrapper,format:i.format,change:function(e,t){t?n._change(e):r.val(e),n.timeView._focusTime=null},open:function(i){n.options.timeView&&"scroll"!==n.options.timeView.list?n.timeView._adjustListWidth():n.timeView._updateTitle(),n.trigger(f)?i.preventDefault():(r.attr(I,!0),t.attr(z,!1),e.current()&&r.attr(F,e._optionID))},close:function(e){n.trigger(m)?e.preventDefault():(r.attr(I,!1),t.attr(z,!0),r[0].removeAttribute(F))},active:function(t){r&&r.length&&r[0].removeAttribute(F),t&&r.attr(F,e._optionID)},specifiedRange:n._specifiedRange,maxSet:+i.max!=+V})),t=e.ul,n._ariaLabel(t)},_icon:function(){var t,n=this,i=n.element,o=n.options;(t=i.next("button.k-input-button"))[0]||(t=e(r.renderButton('<button unselectable="on" tabindex="-1" class="k-input-button" aria-label="select"></button>',{icon:"clock",size:o.size,fillMode:o.fillMode,shape:"none",rounded:"none"})).insertAfter(i)),n._arrow=t.attr({role:"button"})},_keydown:function(e){var t=this,n=e.keyCode,r=t.timeView,o=t.element.val();r.popup.visible()||e.altKey?(r.move(e),t._dateInput&&e.stopImmediatePropagation&&e.stopImmediatePropagation()):n===i.ENTER&&o!==t._oldText?t._change(o):t._typing=!0},_option:function(e,n){var i=this,r=i.options;if(n===t)return r[e];(n=i.timeView._parse(n))&&(n=new O(+n),r[e]=n,i.timeView.options[e]=n,i._dateInput&&i._dateInput[e](n),i.timeView.bind())},_toggleHover:function(t){e(t.currentTarget).toggleClass(x,"mouseenter"===t.type)},_update:function(e){var t=this,i=t.options,r=t.timeView,o=r._parse(e);return j(o,i.min,i.max)||(o=null),t._value=o,t._currentlySelected=o,t._dateInput&&o?t._dateInput.value(o||e):t.element.val(n.toString(o||e,i.format,i.culture)),r.value(o),o},_wrapper:function(){var e,t=this.element;(e=t.parents(".k-timepicker"))[0]||(e=t.wrap("<span></span>").parent()),e[0].style.cssText=t[0].style.cssText,this.wrapper=e.addClass("k-timepicker k-input").addClass(t[0].className),t.css({height:t[0].style.height})},_reset:function(){var t=this,n=t.element,i=n.attr("form"),r=i?e("#"+i):n.closest("form");r[0]&&(t._resetHandler=function(){t.value(n[0].defaultValue),t.max(t._initialOptions.max),t.min(t._initialOptions.min)},t._form=r.on("reset",t._resetHandler))}});function G(e){var t=e.parseFormats;e.format=l(e.format||n.getCulture(e.culture).calendars.standard.patterns.t),(t=L(t)?t:[t]).splice(0,0,e.format),e.parseFormats=t}function K(e){e.preventDefault()}function Y(e,t){return new Date(e.getFullYear(),e.getMonth(),e.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds())}function Q(e,t){var n=!1;return-1!==e.indexOf(t)&&(n=!0),n}function X(e,t){for(var n=String(e);n.length<(t||2);)n="0"+n;return n}function Z(e){return e.length&&e[0].getBoundingClientRect().height}n.cssProperties.registerPrefix("TimePicker","k-input-"),n.cssProperties.registerValues("TimePicker",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),h.plugin(q)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.TimeView,r=n.html,o=n.parseDate,a=n.support,s=n.mediaQuery,l=n._activeElement,c=n._extractFormat,d=n.calendar,u=d.isInRange,h=d.restrictValue,p=d.isEqualDatePart,f=i.getMilliseconds,m=n.ui,g=m.Widget,v="open",_="close",b="change",y=".kendoDateTimePicker",w="click"+y,k=a.mouseAndTouchPresent?n.applyEventMap("up",y.slice(1)):w,x="disabled",C="readonly",S="k-focus",T="k-disabled",D="mouseenter"+y+" mouseleave"+y,A="mousedown"+y,M="month",E="aria-activedescendant",I="aria-expanded",z="aria-hidden",P="aria-disabled",H="aria-readonly",F=Date,R=new F(1800,0,1),L=new F(2099,11,31),B={view:"date"},O={view:"time"},V=e.extend,N=({buttonSize:e,messages:t})=>'<div class="k-date-tab k-datetime-wrap"><div class="k-datetime-buttongroup"><div class="k-button-group k-button-group-stretched">'+n.html.renderButton(`<button class="k-selected k-group-start">${n.htmlEncode(t.date)}</button>`,{size:e})+n.html.renderButton(`<button class="k-group-end">${n.htmlEncode(t.time)}</button>`,{size:e})+'</div></div><div class="k-datetime-selector"><div class="k-datetime-calendar-wrap"></div><div class="k-datetime-time-wrap"></div></div><div class="k-datetime-footer k-actions-stretched k-actions">'+n.html.renderButton(`<button class="k-time-accept" title="Set" aria-label="Set">${n.htmlEncode(t.set)}</button>`,{size:e,themeColor:"primary"})+n.html.renderButton(`<button class="k-time-cancel" title="Cancel" aria-label="Cancel">${n.htmlEncode(t.cancel)}</button>`,{size:e})+"</div></div>",$="k-selected",U=g.extend({init:function(t,i){var r,a=this;(i=i||{}).componentType=i.componentType||"classic",g.fn.init.call(a,t,i),t=a.element,(i=a.options).disableDates=n.calendar.disabled(i.disableDates),i.min=o(t.attr("min"))||o(i.min),i.max=o(t.attr("max"))||o(i.max),+i.max==+L&&+i.min==+R&&+i.startTime==+R&&i.endTime==+L||(this._specifiedRange=!0),q(i),a._initialOptions=V({},i),a._wrapper(),a.bigScreenMQL=s("large"),"auto"==a.options.adaptiveMode&&a.bigScreenMQL.onChange((function(){a.dateView&&a.dateView.destroy(),a.timeView&&a.timeView.destroy(),i.singlePopup&&a._popup(),a._views()})),a.smallScreenMQL=s("small"),"auto"==a.options.adaptiveMode&&a.smallScreenMQL.onChange((function(){a.popup&&n.isFunction(a.popup.fullscreen)&&(a.popup.fullscreen(a.smallScreenMQL.mediaQueryList.matches),a.options.timeView&&"scroll"===a.options.timeView.list&&(a.timeView.addTranslate(),a.timeView._updateRanges()))})),i.singlePopup&&a._popup(),a._views(),a._icons(),a._reset(),a._template();try{t[0].setAttribute("type","text")}catch(e){t[0].type="text"}t.addClass("k-input-inner").attr({role:"combobox","aria-expanded":!1,"aria-haspopup":"dialog","aria-controls":a.dateView._dateViewID+" "+a.timeView._timeViewID,autocomplete:"off"}),a._midnight=a._calculateMidnight(i.min,i.max),t.is("[disabled]")||e(a.element).parents("fieldset").is(":disabled")?a.enable(!1):a.readonly(t.is("[readonly]")),r=o(i.value||a.element.val(),i.parseFormats,i.culture),a._createDateInput(i),a._old=a._update(r||a.element.val()),a._oldText=t.val(),a._applyCssClasses(),i.label&&a._label(),a.element.removeAttr("style"),n.notify(a)},options:{name:"DateTimePicker",autoAdjust:!0,value:null,format:"",timeFormat:"",culture:"",parseFormats:[],dates:[],disableDates:null,startTime:null,endTime:null,min:new F(R),max:new F(L),interval:30,height:200,footer:"",start:M,depth:M,animation:{},month:{},ARIATemplate:({valueType:e,text:t})=>`Current focused ${e} is ${t}`,dateButtonText:"Open the date view",timeButtonText:"Open the time view",dateInput:!1,weekNumber:!1,messages:{set:"Set",cancel:"Cancel",hour:"hour",minute:"minute",second:"second",millisecond:"millisecond",now:"Now",date:"Date",time:"Time",today:"Today",weekColumnHeader:""},adaptiveMode:"none",componentType:"classic",size:"medium",fillMode:"solid",rounded:"medium",label:null,autoCorrectParts:!0},events:[v,_,b],componentTypes:{classic:{singlePopup:!1,timeView:{list:"list"}},modern:{singlePopup:!0,timeView:{list:"scroll"}}},setOptions:function(e){let t,i,r,a,s=this,l=s._value;if(a=!!e.componentType,g.fn.setOptions.call(s,e),(e=s.options).min=t=o(e.min),e.max=i=o(e.max),q(e),s._midnight=s._calculateMidnight(e.min,e.max),r=e.value||s._value||s.dateView._current,t&&!p(t,r)&&(t=new F(R)),i&&!p(i,r)&&(i=new F(L)),s._dateIcon.off(y),s._dateIcon.remove(),s._timeIcon.off(y),s._timeIcon.remove(),a){let t=U.prototype.componentTypes;e.timeView=t[e.componentType].timeView,e.singlePopup=t[e.componentType].singlePopup,e.omitPopup=t[e.componentType].singlePopup,e.singlePopup&&s._popup(),s._views()}s.dateView.setOptions(e),s.timeView.setOptions(V({},e,{format:e.timeFormat,min:t,max:i})),s._icons(),s._editable(e),s._createDateInput(e),s._dateInput||s.element.val(n.toString(l,e.format,e.culture)),l&&s._updateARIA(l),e.label&&s._inputLabel?s.label.setOptions(e.label):!1===e.label?(s.label._unwrapFloating(),s._inputLabel.remove(),delete s._inputLabel):e.label&&s._label()},_editable:function(e){var t=this,i=t.element.off(y),r=t._dateIcon.off(y),o=t._timeIcon.off(y),a=t.wrapper.off(y),s=e.readonly,l=e.disable;s||l?(a.addClass(l?T:"").removeClass(l?"":T),i.attr(x,l).attr(C,s).attr(P,l).attr(H,s)):(a.removeClass(T).on(D,t._toggleHover),i&&i.length&&(i[0].removeAttribute(x),i[0].removeAttribute(C,!1),i[0].removeAttribute(P,!1),i[0].removeAttribute(H,!1)),i.on("keydown"+y,t._keydown.bind(t)).on("focus"+y,(function(){t.wrapper.addClass(S)})).on("focusout"+y,(function(){t.wrapper.removeClass(S),i.val()!==t._oldText&&(t._change(i.val()),i.val()||t.dateView.current(n.calendar.getToday())),t.options.singlePopup||(t.close("date"),t.close("time"))})),r.on(A,j).on(k,(function(e){t.toggle("date"),t._focusElement(e.type)})),o.on(A,j).on(k,(function(e){t.toggle("time"),t._focusElement(e.type)})))},_label:function(){var t=this,i=t.options,r=e.isPlainObject(i.label)?i.label:{content:i.label};t._dateInput&&(r.floatCheck=()=>!(t.value()||t._dateInput._hasDateInput()&&""!==t.element.val()||document.activeElement===t.element[0])&&(t.element.val(""),!0)),t.label=new n.ui.Label(null,e.extend({},r,{widget:t})),t._inputLabel=t.label.element},_focusElement:function(e){var t=this.element;a.touch&&(!a.mouseAndTouchPresent||(e||"").match(/touch/i))||t[0]===l()||t.trigger("focus")},readonly:function(e){this._editable({readonly:e===t||e,disable:!1}),this.label&&this.label.floatingLabel&&this.label.floatingLabel.readonly(e===t||e)},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)}),this.label&&this.label.floatingLabel&&this.label.floatingLabel.enable(e=e===t||e)},destroy:function(){var e=this;g.fn.destroy.call(e),e.dateView.destroy(),e.timeView.destroy(),e.label&&e.label.destroy(),e.options.singlePopup&&(e.popup.element.off(y),e.popup.destroy()),e.element.off(y),e._dateIcon.off(y),e._timeIcon.off(y),e.wrapper.off(y),e._form&&e._form.off("reset",e._resetHandler),e.bigScreenMQL&&(e.bigScreenMQL.destroy(),e.bigScreenMQL=null),e.smallScreenMQL&&(e.smallScreenMQL.destroy(),e.smallScreenMQL=null)},close:function(e){var t=this;t.options.singlePopup?t.popup.close():("time"!==e&&(e="date"),t[e+"View"].close()),setTimeout((function(){t.element.removeAttr("aria-activedescendant")}))},open:function(e){var t,n=this;n.options.singlePopup?(n.dateView._calendar(),n.timeView.ul.find("li").length<1&&n.timeView.bind(),t=n.popup._hovered,n.popup._hovered=!0,n.popup.open(),"time"===e?n._switchToTimeView():n._switchToDateView(),this._dateIcon.toggle("time"!==e),this._timeIcon.toggle("time"===e),setTimeout((function(){n.popup._hovered=t}),1)):("time"!==e&&(e="date"),this[e+"View"].open())},min:function(e){return this._option("min",e)},max:function(e){return this._option("max",e)},toggle:function(e){if(this.options.singlePopup)this.popup.visible()?this.close():this.open(e);else{var t="timeView";"time"!==e?e="date":t="dateView",this[e+"View"].toggle(),this[t].close()}},value:function(e){var n=this;if(e===t)return n._value;n._old=n._update(e),null===n._old&&(n._dateInput?n._dateInput.value(n._old):n.element.val("")),n._oldText=n.element.val(),n.label&&n.label.floatingLabel&&n.label.floatingLabel.refresh()},_change:function(e){var t,n=this,i=n.element.val();e=n._update(e);var r=(t=+n._old!=+e)&&!n._typing,o=i!==n.element.val();(r||o)&&n.element.trigger(b),t&&(n._old=e,n._oldText=n.element.val(),n.trigger(b)),n._typing=!1},_option:function(e,n){var i,r,a=this,s=a.options,l=a.timeView,c=l.options,d=a._value||a._old;if(n===t)return s[e];if(n=o(n,s.parseFormats,s.culture),c.maxSet=!1,n){if(s.min.getTime()===s.max.getTime()&&(c.dates=[]),s[e]=new F(n.getTime()),a.dateView[e](n),a._dateInput&&a._dateInput[e](n),a._midnight=a._calculateMidnight(s.min,s.max),d&&(i=p(s.min,d),r=p(s.max,d)),i||r){if(c[e]=n,i&&!r&&(c.max=W(s.interval)),r){if(a._midnight)return void l.dataBind([L]);i||(c.min=R,c.maxSet=!0)}}else c.max=L,c.min=R;l.bind()}},_toggleHover:function(t){e(t.currentTarget).toggleClass("k-hover","mouseenter"===t.type)},_update:function(t){var i,r,a,s,l,c=this,d=c.options,f=d.min,m=d.max,g=d.startTime,v=d.endTime,_=d.dates,y=c.timeView,w=c._value,k=o(t,d.parseFormats,d.culture),x=null===k&&null===w||k instanceof Date&&w instanceof Date;return d.disableDates&&d.disableDates(k)&&(k=null,c._old||c.element.val()||(t=null)),+k==+w&&x?((l=n.toString(k,d.format,d.culture))!==t&&(c.element.val(null===k?t:l),t instanceof String&&c.element.trigger(b)),k):(null!==k&&p(k,f)?k=h(k,f,m):u(k,f,m)||(k=null),c._value=k,y.value(k),c.dateView.value(k),k&&(a=c._old,(r=y.options).maxSet=!1,_[0]&&(_=e.grep(_,(function(e){return p(k,e)})))[0]&&(y.dataBind(_),s=!0),s||(p(k,f)&&(r.min=g||f,r.max=v||W(d.interval),i=!0),p(k,m)&&(c._midnight?(y.dataBind([L]),s=!0):(r.max=v||m,r.maxSet=!0,i||(r.min=R),i=!0))),!s&&(!a&&i||a&&!p(a,k))&&(i||(r.max=v||L,r.min=g||R),y.bind())),c._dateInput?k&&c._dateInput.value(k):c.element.val(n.toString(k||t,d.format,d.culture)),c._updateARIA(k),k)},_keydown:function(e){var t=this,i=t.dateView,r=t.timeView,o=t.element.val(),a=t.options.singlePopup?t.popup.visible():i.popup.visible(),s=t._dateInput&&e.stopImmediatePropagation;e.altKey&&e.keyCode===n.keys.DOWN?t.toggle(a?"time":"date"):a?(i.move(e),t._updateARIA(i._current),e.keyCode===n.keys.ENTER&&t.toggle("time")):!t.options.singlePopup&&r.popup.visible()?r.move(e):e.keyCode===n.keys.ENTER&&o!==t._oldText?t._change(o):(t._typing=!0,s=!1),s&&e.stopImmediatePropagation()},_timeOption:function(e){var t,n=this,i=n.options,r=i[e],o="startTime"==e?i.min:i.max,a=new F("startTime"==e?R:L);return r&&(a=new F(r)),r&&o&&(t=new Date(o.getFullYear(),o.getMonth(),o.getDate(),r.getHours(),r.getMinutes(),r.getSeconds()),"startTime"==e?n.options.min=t:n.options.max=t),"modern"===i.componentType&&(a=o),a},_views:function(){var e,t,r,a,s,l,c,d,u,h=this,p=h.element,f=h.options,m=p.attr("id");f.singlePopup&&(f.dateDiv=h.popup.element.find(".k-datetime-calendar-wrap"),c=h.popup.element.find(".k-datetime-time-wrap"),f.omitPopup=d=!0,u=f.timeView),h.dateView&&(h.dateView.destroy(),h.dateView=null),h.dateView=e=new n.DateView(V({},f,{id:m,anchor:h.wrapper,change:function(){var e=h._applyDateValue();f.singlePopup?(h.timeView._currentlySelected||(h.timeView._currentlySelected=new Date),h.timeView._currentlySelected.setFullYear(e.getFullYear()),h.timeView._currentlySelected.setMonth(e.getMonth()),h.timeView._currentlySelected.setDate(e.getDate()),h._switchToTimeView(),h._toggleIcons("time")):(h._change(e),h.close("date"))},close:function(e){h.trigger(_,B)?e.preventDefault():(p.attr(I,!1),r.attr(z,!0))},open:function(e){h.trigger(v,B)?e.preventDefault():(p.val()!==h._oldText&&(l=o(p.val(),f.parseFormats,f.culture),h.dateView[l?"current":"value"](l)),r.attr(z,!1),p.attr(I,!0),h._updateARIA(l))}})),r=e.div,s=f.min.getTime(),h.timeView&&(h.timeView.destroy(),h.timeView=null),h.timeView=t=new i({id:m,adaptiveMode:f.adaptiveMode,value:f.value,size:"auto"!=f.adaptiveMode||h.bigScreenMQL.mediaQueryList.matches?f.size:"large",anchor:h.wrapper,animation:f.animation,format:f.timeFormat,culture:f.culture,height:"modern"===f.componentType?null:f.height,interval:f.interval,startTime:f.startTime,endTime:f.endTime,min:h._timeOption("startTime"),max:h._timeOption("endTime"),dates:s===f.max.getTime()?[new Date(s)]:[],parseFormats:f.parseFormats,validateDate:!f.startTime&&!f.endTime,change:function(t,i){t=h._applyTimeValue(t),i?(h._timeSelected=!0,h._change(t)):(p.val(n.toString(t,f.format,f.culture)),e.value(t),h._updateARIA(t))},close:function(e){h.trigger(_,O)?e.preventDefault():(a.attr(z,!0),p.attr(I,!1))},open:function(e){"modern"!==h.options.componentType?t._adjustListWidth():h.timeView._updateTitle(),h.trigger(v,O)?e.preventDefault():(p.val()!==h._oldText&&(l=o(p.val(),f.parseFormats,f.culture),h.timeView.value(l)),a.attr(z,!1),p.attr(I,!0),t.options.active(t.current()))},active:function(e){p&&p.length&&p[0].removeAttribute(E),e&&p.attr(E,t._optionID)},popup:f.popup,useValueToRender:!0,specifiedRange:h._specifiedRange,omitPopup:d,timeDiv:c,timeView:u,messages:h.options.messages}),a=t.ul},_applyDateValue:function(){var e,t,i=this,r=i.options,o=i.dateView.calendar.value(),a=+o,s=+r.min,l=+r.max;return a!==s&&a!==l||(e=a===s?s:l,(e=new F(i._value||e)).setFullYear(o.getFullYear(),o.getMonth(),o.getDate()),u(e,s,l)&&(o=e)),i._value&&(t=n.date.setHours(new Date(o),i._value),u(t,s,l)&&(o=t)),o},_applyTimeValue:function(e){var t=this.timeView,n=this.options;return(e=t._parse(e))<n.min?(e=new F(+n.min),t.options.min=e):e>n.max&&(e=new F(+n.max),t.options.max=e),e},_icons:function(){var t=this,n=t.element,i=t.options;t.wrapper.find("button.k-input-button")[0]||(t._dateIcon=e(r.renderButton('<button unselectable="on" tabindex="-1" class="k-input-button" aria-label="'+i.dateButtonText+'"></button>',{icon:"calendar",size:i.size,fillMode:i.fillMode,shape:"none",rounded:"none"})).insertAfter(n),t._timeIcon=e(r.renderButton('<button unselectable="on" tabindex="-1" class="k-input-button" aria-label="'+i.timeButtonText+'"></button>',{icon:"clock",size:i.size,fillMode:i.fillMode,shape:"none",rounded:"none"})).insertAfter(t._dateIcon)),i.singlePopup&&t._timeIcon.hide()},_wrapper:function(){var e,t=this.element;(e=t.parents(".k-datetimepicker"))[0]||(e=t.wrap("<span/>").parent()),e[0].style.cssText=t[0].style.cssText,t.css({height:t[0].style.height}),this.wrapper=e.addClass("k-datetimepicker k-input").addClass(t[0].className).removeClass("input-validation-error")},_reset:function(){var t=this,i=t.element,r=i.attr("form"),o=r?e("#"+r):i.closest("form"),a=t.options,s=a.disableDates,l=a.parseFormats.length?a.parseFormats:null,c=t._initialOptions.value,d=i[0].defaultValue;c&&s&&s(c)&&(c=null),d&&n.parseDate(d,l,a.culture)||!c||i.attr("value",n.toString(c,a.format,a.culture)),o[0]&&(t._resetHandler=function(){t.value(c||i[0].defaultValue),t.max(t._initialOptions.max),t.min(t._initialOptions.min)},t._form=o.on("reset",t._resetHandler))},_template:function(){this._ariaTemplate=n.template(this.options.ARIATemplate).bind(this)},_createDateInput:function(e){this._dateInput&&(this._dateInput.destroy(),this._dateInput=null),e.dateInput&&(this._dateInput=new m.DateInput(this.element,{culture:e.culture,format:e.format,size:e.size,fillMode:e.fillMode,rounded:e.rounded,min:e.min,max:e.max,interval:e.interval,messages:e.messages.dateInput,autoCorrectParts:e.autoCorrectParts,autoAdjust:e.autoAdjust}))},_calculateMidnight:function(e,t){return f(e)+f(t)===0},_updateARIA:function(e){var t=this,n=t.dateView.calendar;t.element&&t.element.length&&t.element[0].removeAttribute(E),n&&t.element.attr(E,n._updateAria(t._ariaTemplate,e))},_popup:function(){var t=this,i=t.options,r=e("<div></div>").attr(z,"true").addClass("k-datetime-container k-group k-reset").appendTo(document.body);r.append(n.template(N)(V({},t.options,{buttonSize:"auto"!=i.adaptiveMode||t.bigScreenMQL.mediaQueryList.matches?i.size:"large"}))),t.popup&&(t.popup.destroy(),t.popup.element.remove(),t.popup=null),"auto"!=t.options.adaptiveMode||t.bigScreenMQL.mediaQueryList.matches?t.popup=new m.Popup(r,V(i.popup,i,{name:"Popup",isRtl:n.support.isRtl(t.wrapper),anchor:t.wrapper,activate:function(){t.options.timeView&&"scroll"===t.options.timeView.list&&(t.timeView.addTranslate(),t.timeView.applyValue(t._value),t.timeView._updateRanges())},open:function(e){t.trigger(v,{view:this.element.find(".k-date-tab").length?"date":"time",sender:t})?e.preventDefault():(this.element.attr(z,!1),t.element.attr(I,!0)),t.timeView._updateTitle()},close:function(e){t.trigger(_,{view:this.element.find(".k-date-tab").length?"date":"time",sender:t})?e.preventDefault():(t.element.attr(I,!1),this.element.attr(z,!0))}})):t.popup=new m.ActionSheet(r,{adaptive:!0,title:"Select Date and Time",subtitle:"DD / MM / YY - 00:00:00",closeButton:!0,focusOnActivate:!1,fullscreen:t.smallScreenMQL.mediaQueryList.matches,popup:V(i.popup,i,{name:"Popup",isRtl:n.support.isRtl(t.wrapper),anchor:t.wrapper,activate:function(){t.options.timeView&&"scroll"===t.options.timeView.list&&(t.timeView.addTranslate(),t.timeView.applyValue(t._value),t.timeView._updateRanges())},open:function(e){t.trigger(v,{view:this.element.find(".k-date-tab").length?"date":"time",sender:t})?e.preventDefault():(this.element.attr(z,!1),t.element.attr(I,!0)),t.timeView._updateTitle()},close:function(e){t.trigger(_,{view:this.element.find(".k-date-tab").length?"date":"time",sender:t})?e.preventDefault():(t.element.attr(I,!1),this.element.attr(z,!0))}})}),r.on(w+y,".k-datetime-buttongroup .k-button",t._groupChangeClick.bind(t)),r.on(w+y,".k-datetime-footer button.k-time-cancel",t._cancelClickHandler.bind(t)),r.on(w+y,".k-datetime-footer button.k-time-accept",t._setClickHandler.bind(t))},_groupChangeClick:function(t){j(t),e(t.currentTarget).index()?(this._switchToTimeView(),this._toggleIcons("time")):(this._switchToDateView(),this._toggleIcons("date"))},_switchToDateView:function(){this.timeView.list.addClass("k-hidden"),this.popup.element.find(".k-group-start, .k-group-end").removeClass($).eq(0).addClass($),this.popup.element.find(".k-datetime-wrap").removeClass("k-time-tab").addClass("k-date-tab")},_switchToTimeView:function(){this.timeView.list.removeClass("k-hidden"),this.timeView.addTranslate(),this.timeView.applyValue(this._value),this.timeView._updateRanges(),this.popup.element.find(".k-group-start, .k-group-end").removeClass($).eq(1).addClass($),this.popup.element.find(".k-datetime-wrap").removeClass("k-date-tab").addClass("k-time-tab")},_toggleIcons:function(e){if(!e)return this._dateIcon.toggle(),void this._timeIcon.toggle();this._dateIcon.toggle("time"!==e),this._timeIcon.toggle("time"===e)},_cancelClickHandler:function(e){j(e),this._value&&(this.value(this._value),this.dateView.value(this._value)),this.popup.close()},_setClickHandler:function(e){j(e);var t,n=this._applyDateValue();n=n||new Date,t=this.timeView._currentlySelected||n,this.timeView._updateCurrentlySelected(),n.setHours(t.getHours()),n.setMinutes(t.getMinutes()),n.setSeconds(t.getSeconds()),n=this._applyTimeValue(n),this._change(n),this.popup.close()}});function W(e){var t=new Date(2100,0,1);return t.setMinutes(-e),t}function j(e){e.preventDefault()}function q(t){var i,r=n.getCulture(t.culture).calendars.standard.patterns,o=!t.parseFormats.length;t.format=c(t.format||r.g),t.timeFormat=i=c(t.timeFormat||r.t),n.DateView.normalize(t),o&&t.parseFormats.unshift("yyyy-MM-ddTHH:mm:ss"),-1===e.inArray(i,t.parseFormats)&&t.parseFormats.push(i)}n.cssProperties.registerPrefix("DateTimePicker","k-input-"),n.cssProperties.registerValues("DateTimePicker",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),m.plugin(U)}(window.kendo.jQuery);kendo;!function(e,t){let n=window.kendo,i=n.ui,r=n.html,o=n.keys,a=n.mediaQuery,s=i.Widget,l="month",c="open",d="close",u="change",h=n.template,p=e.extend,f=n.support,m=f.mobileOS,g="aria-expanded",v="aria-disabled",_="aria-activedescendant",b="k-disabled",y="k-hidden",w="disabled",k="readonly",x="aria-hidden",C="start",S="end",T=".kendoDateRangePicker",D="click"+T,A="mousedown"+T,M=f.mouseAndTouchPresent?n.applyEventMap("up",T.slice(1)):D,E=n.parseDate;var I=function(e){n.DateView.call(this,e)};function z(e){e.preventDefault()}(I.prototype=Object.create(n.DateView.prototype))._calendar=function(){var t,r=this,o=r.calendar,a=r.options;if(!o){var s=r.popup._content||r.popup.element;"auto"!=a.adaptiveMode||r.bigScreenMQL.mediaQueryList.matches||(s=s.append(e('<div class="k-scrollable-wrap"></div>')).find(".k-scrollable-wrap")),t=e("<div />").attr("id",n.guid()).appendTo(s),r.calendar=o=new i.MultiViewCalendar(t,{size:"auto"!=a.adaptiveMode||r.bigScreenMQL.mediaQueryList.matches?a.size||"medium":"large",orientation:"auto"!=a.adaptiveMode||r.bigScreenMQL.mediaQueryList.matches?"horizontal":"vertical",views:"auto"!=a.adaptiveMode||r.bigScreenMQL.mediaQueryList.matches?2:1}),r._setOptions(a),o.navigate(r._value||r._current,a.start),r._range=r._range||a.range||{},t.on(A,z).on(D,"td:has(.k-link)",r._click.bind(r)),r.calendar.selectRange(r._range)}},I.prototype._setOptions=function(e){this.calendar.setOptions({allowReverse:e.allowReverse,focusOnNav:!1,change:e.change,culture:e.culture,dates:e.dates,depth:e.depth,footer:e.footer,format:e.format,selectable:e.selectable,max:e.max,min:e.min,month:e.month,weekNumber:e.weekNumber,start:e.start,disableDates:e.disableDates,range:e.range,size:"auto"!=e.adaptiveMode||this.bigScreenMQL.mediaQueryList.matches?e.size||"medium":"large"})},I.prototype.range=function(e){this._range=e,this.calendar&&(e.start||e.end?this.calendar.selectRange(e):(this.calendar.selectRange(e),this.calendar.rangeSelectable.clear()))},I.prototype.move=function(e){var t=this,n=e.keyCode,i=t.calendar,r=e.ctrlKey&&n==o.DOWN||n==o.ENTER,a=!1;if(e.altKey)n==o.DOWN?(t.open(),e.preventDefault(),a=!0):n==o.UP&&(t.close(),e.preventDefault(),a=!0);else if(t.popup.visible()){if(n==o.ESC||r&&i._cell.hasClass("k-selected"))return t.close(),e.preventDefault(),!0;t._current=i._move(e),a=!0}return a},I.prototype._click=function(t){this.options.autoClose&&(m.ios||m.android&&("firefox"==m.browser||"chrome"==m.browser)?this._range&&this._range.end&&this.close():this._range&&this._range.start&&this._range.end&&e(t.currentTarget).closest(".k-calendar-view").is(".k-calendar-monthview")&&this.close())},n.DateRangeView=I;var P=s.extend({init:function(e,t){var i=this;s.fn.init.call(i,e,t),e=i.element,(t=i.options).disableDates=n.calendar.disabled(t.disableDates),t.min=E(e.attr("min"))||E(t.min),t.max=E(e.attr("max"))||E(t.max),i._initialOptions=p({},t),i._buildHTML(),i._range=i.options.range,i._changeTriggered=!1,i._initializeDateView(),i._initializeDateViewProxy=i._initializeDateView.bind(i),i.bigScreenMQL=a("large"),i.bigScreenMQL.onChange((()=>{i._initializeDateViewProxy()})),i._ariaTemplate=h(this.options.ARIATemplate).bind(i),i._reset(),i._aria(),i._inputs.on(M+T,i._click.bind(i)).on("keydown"+T,i._keydown.bind(i)),i._initializeDateInputs(),i._expandButton(),i._clearButton(),e.is("[disabled]")?i.enable(!1):i.readonly(e.is("[readonly]"))},options:{name:"DateRangePicker",labels:!0,autoAdjust:!0,allowReverse:!1,autoClose:!0,calendarButton:!1,clearButton:!1,footer:"",format:"",culture:"",min:new Date(1900,0,1),max:new Date(2099,11,31),start:l,depth:l,adaptiveMode:"none",animation:{},month:{},startField:"",endField:"",dates:[],disableDates:null,range:null,ARIATemplate:({valueType:e,text:t})=>`Current focused ${e} is ${t}`,weekNumber:!1,messages:{startLabel:"Start",endLabel:"End"},size:"medium",fillMode:"solid",rounded:"medium"},events:[c,d,u],setOptions:function(e){var t=this;s.fn.setOptions.call(t,e),(e=t.options).min=E(e.min),e.max=E(e.max),t._inputs.off(T),t._initializeDateInputs(),t.dateView.setOptions(e),t._expandButton(),t._clearButton(),t._range=e.range},_aria:function(){this._inputs.attr({role:"combobox","aria-haspopup":"grid","aria-expanded":!1,"aria-controls":this.dateView._dateViewID,autocomplete:"off"})},_clearButton:function(){let t=this,i=t.options,r=t._startInput,o=t._endInput,a=t.range();i.clearButton&&(t._startClearButton||(t._startClearButton=e(`<span unselectable="on" class="k-clear-value ${a&&a.start?"":"k-hidden"}" title="Clear the start date value">${n.ui.icon("x")}</span>`).attr({role:"button",tabIndex:-1}).insertAfter(r).on("click",t._clearValue.bind(t))),t._endClearButton||(t._endClearButton=e(`<span unselectable="on" class="k-clear-value ${a&&a.start?"":"k-hidden"}" title="Clear the end date value">${n.ui.icon("x")}</span>`).attr({role:"button",tabIndex:-1}).insertAfter(o).on("click",t._clearValue.bind(t))))},_expandButton:function(){let t,n,i=this,o=i._startInput,a=i._endInput,s=i.options;s.calendarButton&&(t=o.next("button.k-input-button"),n=a.next("button.k-input-button"),t[0]||(t=e(r.renderButton('<button aria-label="select" tabindex="-1" class="k-input-button k-button k-icon-button"></button>',{icon:"calendar",size:s.size,fillMode:s.fillMode,shape:"none",rounded:"none"})).insertAfter(o)),n[0]||(n=e(r.renderButton('<button aria-label="select" tabindex="-1" class="k-input-button k-button k-icon-button"></button>',{icon:"calendar",size:s.size,fillMode:s.fillMode,shape:"none",rounded:"none"})).insertAfter(a)),i._startDateButton=t.attr({role:"button"}).on(D,i._expandButtonClick.bind(i)),i._endDateButton=n.attr({role:"button"}).on(D,i._expandButtonClick.bind(i)))},_click:function(){let e=this;e.options.calendarButton||e._preventInputAction||e.dateView.popup.visible()||e.dateView.open()},_toggleClearButton:function(e,t){let n=this;e&&n.options.clearButton&&(e===C&&n._startClearButton.toggleClass(y,!t),e===S&&n._endClearButton.toggleClass(y,!t))},_clearValue:function(t){let n=this,i=e(t.target).closest(".k-input").find(".k-input-inner").data("input"),r=n._startDateInput,o=n._endDateInput,a=n.range();i===C&&(r.value(null),r.trigger(u),n.range({start:null,end:a.end})),i===S&&(o.value(null),o.trigger(u),n.range({start:a.start,end:null})),n._toggleClearButton(i,!1)},_expandButtonClick:function(t){let n=this;n._preventInputAction||n.dateView.popup.visible()||(n.dateView.open(),e(t.target).closest(".k-input").find(".k-input-inner").trigger("focus"))},_keydown:function(e){var t,n=this,i=n.dateView;n._preventInputAction?e.stopImmediatePropagation():(t=i.move(e),n._updateARIA(i._current),t&&e.stopImmediatePropagation&&e.stopImmediatePropagation())},_updateARIA:function(t){var n=this,i=n.dateView.calendar;n._inputs&&n._inputs.length&&n._inputs.removeAttr(_),i&&(t&&!i._dateInViews(t)&&i.navigate(t),e.contains(n.element[0],document.activeElement)&&n._inputs.attr(_,i._updateAria(n._ariaTemplate,t)))},_inputFocus:function(t){let n=this,i=n.range();n._currentTarget!==e(t.target).data("input")&&(n._currentTarget=e(t.target).data("input"),i?(i.start=n._startDateInput.value(),i.end=n._endDateInput.value(),n.range(i)):n.range({start:null,end:null}))},_startChange:function(e){var t=this,n=e.sender.value(),i=t._endDateInput.value();t.options.disableDates(n)&&(e.sender.value(null),n=null),t.range({start:n,end:i}),t._changeTriggered||t.trigger(u),t._toggleClearButton(C,null!==n)},_endChange:function(e){var t=this,n=e.sender.value(),i=t._startDateInput.value();t.options.disableDates(n)&&(e.sender.value(null),n=null),t.range({start:i,end:n}),t._changeTriggered||t.trigger(u),e.blur||(t._currentTarget===S?i&&t.options.autoClose?t._endDateInput.dateInputInstance.focus():t._startDateInput.dateInputInstance.focus():n&&t.options.autoClose?t._startDateInput.dateInputInstance.focus():t._endDateInput.dateInputInstance.focus()),t._toggleClearButton(S,null!==n)},_initializeDateView:function(){var e,t=this;t.dateView&&(t.dateView.destroy(),t.dateView=null),t.dateView=new I(p({},t.options,{id:t.element.attr("id"),anchor:t.wrapper,views:2,selectable:{mode:"range",reverse:t.options.allowReverse,resetOnStart:!1},value:t._range?.start||t._range?.end,range:t._range,change:function(){var e=this.selectRange();t.range(e),t.trigger(u),t._changeTriggered=!0,t._startDateInput.trigger(u),t._endDateInput.trigger(u),t._changeTriggered=!1},close:function(n){let i=t.range();t.trigger(d)?n.preventDefault():(t._inputs.attr(g,!1),e.attr(x,!0),setTimeout((function(){t._inputs&&t._inputs.removeAttr(_),i&&t.dateView&&t.dateView.calendar&&t.dateView.calendar.rangeSelectable&&t.range(i)})))},open:function(n){t.trigger(c)?n.preventDefault():(t._inputs.attr(g,!0),e.attr(x,!1),t._updateARIA())}})),e=t.dateView.div},_initializeDateInputs:function(){var e=this,t=e.options,n=t.range||{},i={autoAdjust:t.autoAdjust,footer:t.footer,format:t.format,culture:t.culture,min:t.min,max:t.max,start:t.start,startField:t.startField,endField:t.endField,depth:t.depth,animation:t.animation,month:t.month,dates:t.dates,disableDates:t.disableDates,ARIATemplate:t.ARIATemplate,weekNumber:t.weekNumber,size:t.size,fillMode:t.fillMode,rounded:t.rounded};e._startDateInput&&(e._startDateInput.destroy(),e._endDateInput.destroy(),e.wrapper.empty(),e._buildHTML(),e._inputs.on(M+T,e._click.bind(e)).on("keydown"+T,e._keydown.bind(e))),e._startDateInput=e._startInput.kendoDateInput(p(!0,i,{value:n.start})).getKendoDateInput(),e._endDateInput=e._endInput.kendoDateInput(p(!0,i,{value:n.end})).getKendoDateInput(),e._startChangeHandler=e._startChange.bind(e),e._startDateInput.bind(u,e._startChangeHandler),e._endChangeHandler=e._endChange.bind(e),e._endDateInput.bind(u,e._endChangeHandler),e._inputs.on("focus"+T,e._inputFocus.bind(e))},_buildHTML:function(){var t,i=this,r=i.element;i.wrapper||(i.wrapper=r.addClass("k-daterangepicker")),i.options.labels?(t=n.guid(),e('<span class="k-floating-label-container"><input data-input="start" id="'+t+'"/><label for="'+t+'" class="k-floating-label">'+n.htmlEncode(i.options.messages.startLabel)+"</label></span>").appendTo(i.wrapper),t=n.guid(),e('<span>&nbsp;</span><span class="k-floating-label-container"><input data-input="end" id="'+t+'"/><label for="'+t+'" class="k-floating-label">'+n.htmlEncode(i.options.messages.endLabel)+"</label></span>").appendTo(i.wrapper)):e('<input data-input="start" /><span>&nbsp;</span><input data-input="end" />').appendTo(i.wrapper),i._startInput=i.wrapper.find("input").eq(0),i._endInput=i.wrapper.find("input").eq(1),""!==i.options.startField&&(i._startInput.attr(n.attr("bind"),"value: "+i.options.startField),i._startInput.attr("name",i.options.startField)),""!==i.options.endField&&(i._endInput.attr(n.attr("bind"),"value: "+i.options.endField),i._endInput.attr("name",i.options.endField)),i._inputs=i._startInput.add(i._endInput)},_option:function(e,n){var i=this,r=i.options,o=i._startDateInput,a=i._endDateInput;if(n===t)return r[e];(n=E(n,r.parseFormats,r.culture))&&(r[e]=new Date(+n),i.dateView[e](n),o&&o[e](n),a&&a[e](n))},_reset:function(){var t=this,n=t.element,i=n.attr("form"),r=i?e("#"+i):n.closest("form");r[0]&&(t._resetHandler=function(){t.max(t._initialOptions.max),t.min(t._initialOptions.min)},t._form=r.on("reset",t._resetHandler))},_editable:function(t){var n=this,i=n._inputs,r=t.readonly,o=t.disable;r||o?(n.wrapper.addClass(o?b:"").removeClass(o?"":b),i.attr(w,o).attr(k,r).attr(v,o),n._preventInputAction=!0):(n.wrapper.removeClass(b),e.each(i,(function(e,t){t.removeAttribute(w),t.removeAttribute(k)})),i.attr(v,!1),n._preventInputAction=!1)},destroy:function(){var e=this;e._startDateInput&&(e._startDateInput.unbind(u,e._startChangeHandler),e._startDateInput.destroy(),e._startChangeHandler=null),e._endDateInput&&(e._endDateInput.unbind(u,e._endChangeHandler),e._endDateInput.destroy(),e._endChangeHandler=null),e._startDateButton&&e._startDateButton.off(D,e._expandButtonClick),e._endDateButton&&e._endDateButton.off(D,e._expandButtonClick),e._startDateClear&&e._startDateClear.off(D,e._clearValue),e._endDateClear&&e._endDateClear.off(D,e._clearValue),e._form&&e._form.off("reset",e._resetHandler),e._inputs.off(T),e._inputs=null,e.bigScreenMQL&&e.bigScreenMQL.destroy(),e._createDateViewProxy=null,e.dateView.destroy(),e.element.off(T),s.fn.destroy.call(e)},range:function(e){let n=this,i=n._currentTarget||C;if(e===t)return n._range;n._range=e,n._range.target=i,n.dateView.range({start:null,end:null,target:i}),e||(n._startDateInput.value(null),n._endDateInput.value(null)),n._startDateInput.value(e.start?e.start:null),n._endDateInput.value(e.end?e.end:null),i===C&&n.dateView.range({start:e.start,end:e.end||null,target:i}),i===S&&n.dateView.range({start:e.start||null,end:e.end,target:i})},open:function(){this.dateView.open()},close:function(){this.dateView.close()},min:function(e){return this._option("min",e)},max:function(e){return this._option("max",e)},readonly:function(e){this._startDateInput.readonly(e),this._endDateInput.readonly(e),this._editable({readonly:e===t||e,disable:!1})},enable:function(e){this._startDateInput.enable(e),this._endDateInput.enable(e),e||this.close(),this._editable({readonly:!1,disable:!(e=e===t||e)})}});n.ui.plugin(P)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=n.effects.Transition,o=n.ui.Pane,a=n.keys,s=n.ui.PaneDimensions,l=i.DataBoundWidget,c=n.data.DataSource,d=Math,u=d.abs,h=d.ceil,p=d.round,f=d.max,m=d.min,g=d.floor,v="change",_="click",b="refresh",y="primary",w="scrollview-page",k="function",x="itemChange",C=".ScrollView",S="keydown",T="focus",D="focusout",A="k-focus",M="tabindex";function E(e){return"k-"+e}var I=n.Observable.extend({init:function(e){var t=this;this.dataSource=e,this.pendingRequestArray=[],this.initialFetch=!1,this.useRanges=e.options.serverPaging,n.Observable.fn.init.call(this),e.bind("change",(function(){t._change()}))},_change:function(){this.trigger("reset",{offset:this.offset})},page:function(e,t){var n=this;this.useRanges||(this.dataSource.page(e+1),t?t(n.dataSource.view()):n.trigger("page",{page:e})),this.useRanges&&this.dataSource.range(e*this.dataSource.pageSize(),this.dataSource.pageSize(),(function(){t?t(n.dataSource.view()):n.trigger("page",{page:e})}))},scrollTo:function(e){var t=Math.ceil(this.dataSource.total()/this.dataSource.pageSize()||1),n=e-1,i=n-1,r=e,o=t>0&&e+1>=t?-1:e+1,a=t>0&&o+1>=t?-1:o+1;o>=0&&this.pendingRequestArray.push(o),n>=0&&this.pendingRequestArray.push(n),i>=0&&this.pendingRequestArray.push(i),a>=0&&this.pendingRequestArray.push(a),this.page(r)},getViewData:function(){var e,t=this.dataSource.view();if(this.dataSource.options.pageSize>1){e=[];for(var n=0;n<t.length;n++)e.push(t[n])}else e=t[0];return e},destroy:function(){this.dataSource.unbind(),this.dataSource=null}});n.ui.ScrollViewDataReader=I;var z=n.Class.extend({init:function(t){var n=this,i=e("<div class='"+E("scrollview-nav")+"'/>"),r=e("<div class='"+E("scrollview-nav-wrap")+"'></div>");r.append(i),t._navigationContainer.append(r),this._changeProxy=n._change.bind(n),this._refreshProxy=n._refresh.bind(n),t.bind(v,this._changeProxy),t.bind(b,this._refreshProxy),i.on(_+C,".k-link",this._click.bind(t)),e.extend(n,{element:i,scrollView:t}),n._navigatable()},items:function(){return this.element.children()},_focus:function(){var e=this;e._focused=!0,e._setCurrent(e.element.find("."+E(y)))},_blur:function(){var e=this;e._focused=!1,e._current&&(e._current.removeClass(A),e._current.removeAttr("id"),e.element.removeAttr("aria-activedescendant"))},_keyDown:function(e){var t,n,i=this,r=i._current,o=e.keyCode;o==a.LEFT&&(t=!0,(n=r.prev(".k-link")).length&&i._setCurrent(n)),o==a.RIGHT&&(t=!0,(n=r.next(".k-link")).length&&i._setCurrent(n)),e.keyCode!=a.SPACEBAR&&e.keyCode!=a.ENTER||(t=!0,i._current.trigger("click")),t&&(e.preventDefault(),e.stopPropagation())},_setCurrent:function(t){if(this._focused){var i=this,r=n.guid(),o=e(t);i._current&&(e(i._current).removeClass(A).removeAttr("id"),i.element.removeAttr("aria-activedescendant")),o.attr("id",r).addClass(A),i.element.attr("aria-activedescendant",r),i._current=o}},_navigatable:function(){var e=this,t=e.scrollView.options.pageable||{};e.element.attr({tabindex:0,"aria-label":e.scrollView.options.messages.pagerLabel,role:"group"}),e.scrollView.itemsWrapper&&e.element.attr("aria-controls",e.scrollView.itemsWrapper.attr("id")),e._ariaTemplate=n.template(t.ARIATemplate||(({index:e})=>`Item ${e+1}`)),e.scrollView.options.navigatable&&(e.element.on(S+C,e,e._keyDown.bind(e)),e.element.on(T+C,e._focus.bind(e)),e.element.on(D+C,e._blur.bind(e)))},_refresh:function(e){for(var t,n="",i=0;i<e.pageCount;i++)n+='<span class="k-link" role="button" aria-label="'+this._ariaTemplate({index:i})+'" aria-pressed="false"></span>';this.element.html(n),(t=this.items().eq(e.page)).addClass(E(y)),t.attr("aria-pressed",!0),this.scrollView._toggleNavigation({currentPage:e.page})},_change:function(e){if(!e.isDefaultPrevented()){var t,i=this.scrollView._navigationContainer.find(".k-scrollview-nav"),r=this.scrollView.element.width(),o=(r-i.width())/2,a=i.find(".k-link").eq(0).outerWidth(!0)/2,s=this.items();s.removeClass(E(y)),t=s.eq(e.nextPage).addClass(E(y)),s.attr("aria-pressed",!1),this._setCurrent(t),t.attr("aria-pressed",!0);var l=this.items().eq(e.nextPage).length>0?this.items().eq(e.nextPage).position().left:0;if(l>r/2||l<n.scrollLeft(i)+r/2){var c=0;c=l>r/2?n.scrollLeft(i)+l-r/2:n.scrollLeft(i)-(r/2-l),c+=o+a,i.animate({scrollLeft:c},300)}this.scrollView._toggleNavigation({currentPage:e.currentPage,nextPage:e.nextPage})}},_click:function(t){var n=e(t.currentTarget).index();this.scrollTo(n)},destroy:function(){this.scrollView.unbind(v,this._changeProxy),this.scrollView.unbind(b,this._refreshProxy),this.element.off(C),this.element.remove()}});n.ui.ScrollViewPager=z;var P="transitionEnd",H="dragStart",F="dragEnd",R=n.Observable.extend({init:function(t,i){var a,l,c,d,h,p,f=this;n.Observable.fn.init.call(this),this.element=t,this.container=t.parent(),a=new n.ui.Movable(f.element),l=new r({axis:"x",movable:a,onEnd:function(){f.trigger(P)}}),c=new n.UserEvents(t,{fastTap:!0,start:function(e){2*u(e.x.velocity)>=u(e.y.velocity)?c.capture():c.cancel(),f.trigger(H,e),l.cancel()},allowSelection:!0,end:function(e){f.trigger(F,e)}}),(h=(d=new s({element:f.element,container:f.container})).x).bind(v,(function(){f.trigger(v)})),p=new o({dimensions:d,userEvents:c,movable:a,elastic:!0}),e.extend(f,{duration:i&&i.duration||1,movable:a,transition:l,userEvents:c,dimensions:d,dimension:h,pane:p}),this.bind([P,H,F,v],i)},size:function(){return{width:this.dimensions.x.getSize(),height:this.dimensions.y.getSize()}},total:function(){return this.dimension.getTotal()},offset:function(){return-this.movable.x},updateDimension:function(){this.dimension.update(!0)},refresh:function(){this.dimensions.refresh(),this.dimensions.y.enabled=!1},moveTo:function(e){this.movable.moveAxis("x",-e)},transitionTo:function(e,t,n){n?this.moveTo(-e):this.transition.moveTo({location:e,duration:this.duration,ease:t})},destroy:function(){var e=this;e.userEvents.destroy(),e.unbind(),e.movable=e.tansition=e.dimensions=e.dimension=e.pane=null,e.element.remove()}});n.ui.ScrollViewElasticPane=R;var L=n.Observable.extend({init:function(e,t,i){var r=this;n.Observable.fn.init.call(this),r.element=e,r.pane=t,r._getPages(),this.page=0,this.pageSize=i.pageSize||1,this.contentHeight=i.contentHeight,this.enablePager=i.enablePager,this.pagerOverlay=i.pagerOverlay,r.pane.dimension.forceEnabled()},scrollTo:function(e,n){var i=this;(e!=i.page||n)&&(i.trigger("resize",{currentPage:this.page,nextPage:e,data:t})||(i.page=e,i.pane.transitionTo(-e*i.pane.size().width,r.easeOutExpo,n)))},paneMoved:function(e,t,n,i){var o,a,s=this,l=s.pane,c=l.size().width*s.pageSize,d=p,u=t?r.easeOutBack:r.easeOutExpo;if(-1===e?d=h:1===e&&(d=g),(a=d(l.offset()/c))<0||a>=s.pageCount){var v=a<0?0:-this.page*this.pane.size().width;return this.pane.transitionTo(v,u,i)}o=f(s.minSnap,m(-a*c,s.maxSnap)),a!=s.page&&n&&n({currentPage:s.page,nextPage:a})&&(o=-s.page*l.size().width),l.transitionTo(o,u,i)},updatePage:function(){var e=this.pane,t=p(e.offset()/e.size().width);return t!=this.page&&(this.page=t,!0)},forcePageUpdate:function(){return this.updatePage()},resizeTo:function(e){var t=this.pane,n=e.width;if(this.pageElements.width(n),"100%"===this.contentHeight){var i=this.element.parent().height();this.element.css("height",i),this.pageElements.css("height",i)}t.updateDimension(),this._paged||(this.page=g(t.offset()/n)),this.scrollTo(this.page,!0,!0),this.pageCount=this.pageElements.length,this.minSnap=-(this.pageCount-1)*n,this.maxSnap=0},_getPages:function(){this.pageElements=this.element.find(n.roleSelector("page")),this._paged=this.pageElements.length>0},destroy:function(){this.pane=null,this.element.remove()}});n.ui.ScrollViewContent=L;var B=n.Observable.extend({init:function(e,t,i){var r=this;n.Observable.fn.init.call(this),r.element=e,r.pane=t,r.options=i,r._templates(),r.page=i.page||0,r.pages=[],r._initPages(),r.resizeTo(r.pane.size()),r.pane.dimension.forceEnabled()},setDataSource:function(e){this.dataSource=c.create(e),this._dataReader(),this._pendingPageRefresh=!1,this._pendingWidgetRefresh=!1},_viewShow:function(){var e=this;e._pendingWidgetRefresh&&(setTimeout((function(){e._resetPages()}),0),e._pendingWidgetRefresh=!1)},_dataReader:function(){this.dataReader=new I(this.dataSource),this._pageProxy=this._onPage.bind(this),this._resetProxy=this._onReset.bind(this),this.dataReader.bind({page:this._pageProxy,reset:this._resetProxy})},_templates:function(){var e=this.options.template,t=this.options.emptyTemplate,i={},r={};typeof e===k&&(i.template=e,e=e=>i.template(e)),this.template=n.template(e).bind(i),typeof t===k&&(r.emptyTemplate=t,t=e=>r.emptyTemplate(e)),this.emptyTemplate=n.template(t).bind(r)},_initPages:function(){for(var e,t=this.pages,n=this.element,i=0;i<3;i++)e=new O(n),t.push(e);this.pane.updateDimension()},resizeTo:function(e){for(var t=this.pages,n=this.pane,i=0;i<t.length;i++)t[i].setWidth(e.width);if("auto"===this.options.contentHeight)this.element.css("height",this.pages[1].element.height());else if("100%"===this.options.contentHeight){var r=this.element.parent().height();this.element.css("height",r),t[0].element.css("height",r),t[1].element.css("height",r),t[2].element.css("height",r)}else this.options.contentHeight&&(t[0].element.css("height",this.options.contentHeight),t[1].element.css("height",this.options.contentHeight),t[2].element.css("height",this.options.contentHeight));n.updateDimension(),this._repositionPages(),this.width=e.width},scrollTo:function(e,t,n){var i=this,r=i.dataReader;(e!=i.page||t)&&r.page(e,(function(o){n?r.scrollTo(e):i.trigger("resize",{currentPage:i.page,nextPage:e,data:o})||(t?i.page=e:(r.pagerScroll=e>i.page?-1:1,i.page=e+r.pagerScroll),r.scrollTo(e))}))},paneMoved:function(e,i,r,o){var a,s,l,c=this,d=c.pane,u=d.size().width,h=d.offset(),p=Math.abs(h)>=u/3,f=i?n.effects.Transition.easeOutBack:n.effects.Transition.easeOutExpo,m=c.page+2>c.pageCount,g=0;1===e?0!==c.page&&(g=-1):-1!==e||m?h>0&&p&&!m?g=1:h<0&&p&&0!==c.page&&(g=-1):g=1,a=c.page,g&&(a=g>0?a+1:a-1,c instanceof n.ui.VirtualScrollViewContent?(c.dataReader.page(a),s=c.dataReader.getViewData()):s=t,s instanceof Array||(s=[s]),l=c.pages?c.pages[1].element:t),r&&c.page!=a&&r({currentPage:c.page,nextPage:a,element:l,data:s})&&(g=0),0===g?c._cancelMove(f,o):-1===g?c._moveBackward(o):1===g&&c._moveForward(o)},updatePage:function(){var e=this.pages;return 0!==this.pane.offset()&&(this.pane.offset()>0?(e.push(this.pages.shift()),this.page++,this.page+2<this.pageCount&&this.dataReader.pendingRequestArray.push(this.page+2),this.page+1<this.pageCount&&this.dataReader.page(this.page+1),this.page+1==this.pageCount&&this.setPageContent(this.pages[2],null)):(e.unshift(this.pages.pop()),this.page--,this.page-2>=0&&this.dataReader.pendingRequestArray.push(this.page-2),this.page-1>=0&&this.dataReader.page(this.page-1)),this._repositionPages(),this._resetMovable(),!0)},forcePageUpdate:function(){var e=this.pane.offset(),t=3*this.pane.size().width/4;return u(e)>t&&this.updatePage()},_resetMovable:function(){this.pane.moveTo(0)},_moveForward:function(e){this.pane.transitionTo(-this.width,n.effects.Transition.easeOutExpo,e)},_moveBackward:function(e){this.pane.transitionTo(this.width,n.effects.Transition.easeOutExpo,e)},_cancelMove:function(e,t){this.pane.transitionTo(0,e,t)},_resetPages:function(){this.page=this.options.page||0,this._repositionPages(),this.trigger("reset")},_onPage:function(e){if(e.page>=this.pageCount&&this.setPageContent(this.pages[2],null),this.page==e.page?(!this.dataReader.pagerScroll||0===this.dataReader.pagerScroll&&this.dataReader.initialFetch||(this.dataReader.pagerScroll<0?this._moveForward():this._moveBackward(),this.dataReader.pagerScroll=0),this.setPageContent(this.pages[1],this.dataReader.getViewData())):this.page+1==e.page?this.setPageContent(this.pages[2],this.dataReader.getViewData()):this.page-1==e.page&&this.setPageContent(this.pages[0],this.dataReader.getViewData()),this.dataReader.pendingRequestArray.length>0&&this.dataReader.initialFetch){var t=this.dataReader.pendingRequestArray.shift();this.dataReader.page(t)}},_onReset:function(){this.pageCount=h(this.dataSource.total()/this.dataSource.pageSize())},_repositionPages:function(){var e=this.pages;e[0].position(-1),e[1].position(0),e[2].position(1)},setPageContent:function(e,n){var i=this.template,r=this.emptyTemplate;null!==n&&n!==t?e.content(i(n)):e.content(r({}))},destroy:function(){var e=this,t=e.pages;e.dataReader.unbind(),e.dataSource.unbind(),e.dataReader=e.dataSource=e.pane=null;for(var n=0;n<t.length;n++)t[n].destroy();e.element.remove()}});n.ui.VirtualScrollViewContent=B;var O=n.Class.extend({init:function(t){this.element=e("<li class='"+E(w)+"'></li>"),this.element.css({position:"absolute",top:"0",left:"0"}),this.width=t.width(),this.element.width(this.width),t.append(this.element)},content:function(e){this.element.html(e)},position:function(e){this.element.css("transform","translate3d("+this.width*e+"px, 0, 0)")},setWidth:function(e){this.width=e,this.element.width(e)},destroy:function(){this.element.remove(),this.element=null}});n.ui.VirtualPage=O;var V=l.extend({init:function(t,i){var r=this;l.fn.init.call(r,t,i),i=r.options,t=r.element,n.stripWhitespace(t[0]);var o=e(`<${0===t.children().length?"ul":"div"} class="k-scrollview-wrap" />`);t.wrapInner(o),r.itemsWrapper=t.find(".k-scrollview-wrap"),t.addClass(E("scrollview")),r._initNavigation(),this.options.pageable||this.options.enablePager?(this.pager=new z(this),"dark"===this.options.pagerOverlay?t.addClass(E("scrollview-dark")):"light"===this.options.pagerOverlay&&t.addClass(E("scrollview-light"))):(this._changeProxy=r._toggleNavigation.bind(r),this.bind(v,this._changeProxy)),r.inner=t.children().first(),r.page=0,r.inner.css("height",i.contentHeight),r.pane=new R(r.inner,{duration:this.options.duration,transitionEnd:this._transitionEnd.bind(this),dragStart:this._dragStart.bind(this),dragEnd:this._dragEnd.bind(this),change:this[b].bind(this)}),r.bind("resize",(function(){r.pane.refresh()})),r.page=i.page;var a=0===this.inner.children().length?new B(r.inner,r.pane,i):new L(r.inner,r.pane,i);a.page=r.page,a.bind("reset",(function(){this._pendingPageRefresh=!1,r.trigger(b,{pageCount:a.pageCount,page:a.page}),r._toggleNavigation({currentPage:a.page,nextPage:a.page})})),a.bind("resize",(function(e){a.page!=e.nextPage&&(e._defaultPrevented=r.trigger(v,{currentPage:a.page,nextPage:e.nextPage,data:e.data})),r._toggleNavigation({currentPage:a.page,nextPage:e.nextPage})})),a.bind(x,(function(e){r.trigger(x,e)})),r._content=a,r.setDataSource(i.dataSource),r.viewInit(),r.viewShow(),r._navigatable()},options:{name:"ScrollView",ARIATemplate:({index:e,total:t})=>`Item ${e} of ${t}`,page:0,duration:400,velocityThreshold:.8,contentHeight:"auto",pageSize:1,bounceVelocityThreshold:1.6,enablePager:!0,enableNavigationButtons:!0,pagerOverlay:"none",navigatable:!1,autoBind:!0,pageable:!1,template:()=>"",emptyTemplate:()=>"",messages:{previousButtonLabel:"Previous",nextButtonLabel:"Next",pagerLabel:"ScrollView pager"}},events:["changing",v,b],destroy:function(){l.fn.destroy.call(this),this._content.destroy(),this.pane.destroy(),this.pager&&this.pager.destroy(),this._navigationContainer.off(C),this._navigationContainer=null,this.itemsWrapper.off(C),this.itemsWrapper=null,this.ariaLiveEl=this._current=null,this.inner=null,n.destroy(this.element)},viewInit:function(){this.options.autoBind&&this._content.scrollTo(this._content.page,!0,!0)},viewShow:function(){this.pane.refresh()},refresh:function(){var e=this._content,t=this.options;e.resizeTo(this.pane.size()),this.page=e.page,(e instanceof L||e.dataReader.initialFetch)&&(t.enablePager?this.trigger(b,{pageCount:e.pageCount,page:e.page}):this.trigger(v,{pageCount:e.pageCount,currentPage:e.page}))},content:function(e){this.element.children().first().html(e),this._content._getPages(),this.pane.refresh()},scrollTo:function(e,t,n){this._content.scrollTo(e,t,n)},prev:function(){var e=this,n=e._content.page-1;e._content instanceof B?e._content.paneMoved(1,t,(function(t){return e.trigger(v,t)})):n>-1&&e.scrollTo(n)},next:function(){var e=this,n=e._content.page+1;e._content instanceof B?e._content.paneMoved(-1,t,(function(t){return e.trigger(v,t)})):n<e._content.pageCount&&e.scrollTo(n)},setDataSource:function(e){var t=this;if(this._content instanceof B){var n=!e;e instanceof c?(e.options.pageSize=e.options.pageSize||1,this.dataSource=e=new c(e.options)):this.dataSource=c.create(e),this._content.setDataSource(this.dataSource),this.options.autoBind&&!n&&this.dataSource.fetch((function(){t._content.dataReader.initialFetch=!0,t.scrollTo(t._content.page,!0,!0),t._content.trigger("reset")}))}},items:function(){return this.element.find(".k-"+w)},_updateAria:function(){var e=this._content;this.ariaLiveEl.html(this._ariaTemplate({index:e.page+1,total:e.pageCount}))},_setCurrent:function(t){if(this._focused){var i=this,r=i._content.page,o=(n.guid(),i.itemsWrapper.children()),a=e(t||o.eq(r));if(i._content.pages)return o.attr("aria-hidden",!0),void i._content.pages[1].element.removeAttr("aria-hidden");i._current&&(e(i._current).removeClass(A).removeAttr("id"),o.attr("aria-hidden",!0)),a.addClass(A),i._updateAria(),i._current=a}},_dragStart:function(){this._content.forcePageUpdate()},_dragEnd:function(e){var t=this,n=e.x.velocity,i=this.options.velocityThreshold,r=0,o=u(n)>this.options.bounceVelocityThreshold;n>i?r=1:n<-i&&(r=-1),this._content.paneMoved(r,o,(function(e){return t.trigger(v,e)}))},_transitionEnd:function(){this._content.updatePage(),this._setCurrent()},_initNavigation:function(){var t,i,r=this,o=r.options.messages,a=r._navigationContainer=e("<div class='k-scrollview-elements'></div>"),s=r.itemsWrapper,l=s.attr("id")||n.guid();s.attr("id",l),t=e(`<span class="k-scrollview-prev" role="button" aria-label="${o.previousButtonLabel}" aria-controls="${l}">${n.ui.icon({icon:"chevron-left",size:"xxxlarge"})}</span>`),i=e(`<span class="k-scrollview-next" role="button" aria-label="${o.nextButtonLabel}" aria-controls="${l}">${n.ui.icon({icon:"chevron-right",size:"xxxlarge"})}</span>`),t.hide(),i.hide(),a.append(t),a.append(i),r.element.append(a),r.ariaLiveEl=e("<div aria-live='polite' aria-atomic='true' class='k-sr-only'></div>"),r.element.append(r.ariaLiveEl),a.on(_+C,"span.k-scrollview-prev",r.prev.bind(r)),a.on(_+C,"span.k-scrollview-next",r.next.bind(r))},_navigatable:function(){var t=this,i=t._navigationContainer;t._ariaTemplate=n.template(t.options.ARIATemplate),i.on(S+C,t,(function(t){var n=e(t.target);t.keyCode!=a.SPACEBAR&&t.keyCode!=a.ENTER||(t.preventDefault(),n.click())})),t.element.attr({tabindex:0,role:"application","aria-roledescription":"carousel"}),t.itemsWrapper.attr("role","list").children().addClass("k-scrollview-view").attr({role:"listitem","aria-roledescription":"slide"}),t.options.navigatable&&(i.find(">span.k-scrollview-prev").attr(M,0),i.find(">span.k-scrollview-next").attr(M,0),t.element.on(S+C,t,t._keyDown.bind(t)),t.element.on(T+C,t._focus.bind(t)),t.element.on(D+C,t._blur.bind(t)))},_focus:function(){this._focused=!0,this._setCurrent()},_blur:function(){this._current&&this._current.removeClass(A)},_keyDown:function(e){var t,n=e.keyCode;n==a.LEFT&&(t=!0,this.prev()),n==a.RIGHT&&(t=!0,this.next()),t&&(e.preventDefault(),e.stopPropagation())},_toggleNavigation:function(e){var t=e.nextPage||0===e.nextPage?e.nextPage:e.currentPage,n=this._navigationContainer,i=n.find(">span.k-scrollview-prev"),r=n.find(">span.k-scrollview-next");i.hide(),r.hide(),(t||0===t)&&(0!==t&&i.show(),t!=this._content.pageCount-1&&r.show())}});i.plugin(V)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=t.keys,r=e.extend,o=n.Widget,a=/^\d+(\.\d+)?px$/i,s=/^\d+(\.\d+)?%$/i,l=".kendoSplitter",c="expand",d="collapse",u="contentLoad",h="error",p="layoutChange",f="pane",m="k-focus",g="."+(S="k-"+f),v="k-scrollable",_="k-pane-static",b="k-splitter",y="k-splitbar",w="flex-basis",k="horizontal",x="vertical",C=Number.MAX_SAFE_INTEGER,S="k-pane",T="click",D="resize",A="px";function M(e){return s.test(e)}function E(e){return a.test(e)||/^\d+$/.test(e)}function I(e){return!M(e)&&!E(e)}function z(e,t){var n=parseInt(e,10);return M(e)&&(n=Math.floor(n*t/100)),n}function P(e,t){return function(n,i){var r=this.element.find(n).data(f);if(1==arguments.length)return r[e];(r[e]=i,t)&&this.element.data("kendo"+this.options.name).resize(!0)}}var H=o.extend({init:function(e,n){var r,a=this;o.fn.init.call(a,e,n),a.wrapper=a.element,a.options.orientation&&(r=a.options.orientation.toLowerCase()!=x),a.orientation=r?k:x,a._dimension=r?"width":"height",a._keys={decrease:r?i.LEFT:i.UP,increase:r?i.RIGHT:i.DOWN},a._resizeStep=10,a._marker=t.guid().substring(0,8),a.element.addClass(`${b} k-splitter-flex ${b}-${a.orientation}`),a.element.closest(S).removeClass(_).addClass("k-pane-flex"),a._initPanes(),a.resizing=new L(a),a.element.triggerHandler("init"+l)},events:[c,d,u,h,D,p],_addOverlays:function(){this._panes().append("<div class='k-splitter-overlay k-overlay' />")},_removeOverlays:function(){this._panes().children(".k-splitter-overlay").remove()},_attachEvents:function(){var t=this,n=t.options.orientation;t.element.children(".k-splitbar-draggable-"+n).on("keydown"+l,t._keydown.bind(t)).on("mousedown"+l,(function(e){e.currentTarget.focus()})).on("focus"+l,(function(t){e(t.currentTarget).addClass(m)})).on("blur"+l,(function(n){e(n.currentTarget).removeClass(m),t.resizing&&t.resizing.end()})).on("mouseenter"+l,(function(){e(this).addClass("k-splitbar-"+t.orientation+"-hover")})).on("mouseleave"+l,(function(){e(this).removeClass("k-splitbar-"+t.orientation+"-hover")})).on("mousedown"+l,t._addOverlays.bind(t)).end().children(".k-splitbar").on("dblclick"+l,t._togglePane.bind(t)).children(".k-collapse-next, .k-collapse-prev").on(T+l,t._arrowClick(d)).end().children(".k-expand-next, .k-expand-prev").on(T+l,t._arrowClick(c)).end().end(),e(window).on("resize"+l+t._marker,t.resize.bind(t,!1)),e(document).on("mouseup"+l+t._marker,t._removeOverlays.bind(t))},_detachEvents:function(){var t=this;t.element.children(".k-splitbar-draggable-"+t.orientation).off(l).end().children(".k-splitbar").off("dblclick"+l).children(".k-collapse-next, .k-collapse-prev, .k-expand-next, .k-expand-prev").off(l),e(window).off(l+t._marker),e(document).off(l+t._marker)},options:{name:"Splitter",clickMoveClick:!0,orientation:k,panes:[]},destroy:function(){o.fn.destroy.call(this),this._detachEvents(),this.resizing&&this.resizing.destroy(),t.destroy(this.element),this.wrapper=this.element=null},_keydown:function(t){var n,r=this,o=t.keyCode,a=r.resizing,s=e(t.currentTarget),l=r._keys,u=o===l.increase,h=o===l.decrease;u||h?(t.ctrlKey?(n=s[h?"next":"prev"](),a&&a.isResizing()&&a.end(),n[r._dimension]()?r._triggerAction(d,s[h?"prev":"next"]()):r._triggerAction(c,n)):a&&a.move((h?-1:1)*r._resizeStep,s),t.preventDefault()):o===i.HOME?(n=s.prev(),r.collapse(n),t.preventDefault()):o===i.END?(n=s.prev(),r.expand(n),t.preventDefault()):o===i.ENTER&&a&&(a.end(),t.preventDefault(),r._togglePane(t))},_initPanes:function(){var t=this.options.panes||[],n=this;this.element.children().each((function(i,r){"script"!=r.nodeName.toLowerCase()&&(t[i]=e.extend(n._getDefaultPaneConfig(),t[i],{order:2*i}),t[i].isFluid=I(t[i].size),r.style.order=2*i,n._initPane(r,t[i]))})),this.resize()},_getDefaultPaneConfig:function(){return{scrollable:!0,resizable:!0,size:"auto"}},_updatePaneOrderStyles:function(t){e(t||this.element).children().each((function(e,t){if("script"!=t.nodeName.toLowerCase()){t.data(f).order=2*e,t.style.order=2*e}}))},_initPane:function(t,n){(n=e.extend({},this._getDefaultPaneConfig(),n)).fixedSize=n.size&&"auto"!==n.size,t=e(t).attr("role","group").addClass(S);let i=!n.resizable&&!n.collapsible||n.fixedSize;t.css(w,n.size).data(f,n).toggleClass(_,Boolean(i)).toggleClass(v,Boolean(n.scrollable)),this.ajaxRequest(t)},ajaxRequest:function(e,n,i){var r,o=this;r=(e=o.element.find(e)).data(f),(n=n||r.contentUrl)&&(e.append("<span class='k-icon k-i-loading k-pane-loading' />"),t.isLocalUrl(n)?jQuery.ajax({url:n,data:i||{},type:"GET",dataType:"html",success:function(t){e.html(t),o.trigger(u,{pane:e[0]})},error:function(t,n){o.trigger(h,{pane:e[0],status:n,xhr:t})}}):e.removeClass(v).html("<iframe src='"+n+"' frameborder='0' class='k-content-frame'>This page requires frames in order to show content</iframe>"))},_triggerAction:function(e,t){var n=t.data(f),i=n.collapsed&&e==c||!n.collapsed&&e==d;n.collapsible&&(i&&!this.trigger(e,{pane:t[0]})&&this[e](t[0]),this.resizing.stop(),this.resizing.end())},_togglePane:function(t){var n,i=this,r=e(t.target);r.closest(".k-splitter")[0]==i.element[0]&&1===(n=r.children("span:not(.k-resize-handle)")).length&&(n.is(".k-collapse-prev")?i._triggerAction(d,r.prev()):n.is(".k-collapse-next")?i._triggerAction(d,r.next()):n.is(".k-expand-prev")?i._triggerAction(c,r.prev()):n.is(".k-expand-next")&&i._triggerAction(c,r.next()),i.resizing?.end())},_arrowClick:function(t){var n=this;return function(i){var r,o=e(i.currentTarget);o.closest(".k-splitter")[0]==n.element[0]&&(r=o.is(".k-"+t+"-prev")?o.parent().prev():o.parent().next(),n._triggerAction(t,r))}},_updateSplitBar:function(e,i,r,o){var a=function(e,t,i){var r=t?n.icon({icon:t,size:"xsmall"}):"";return i?"<span class='k-"+e+"'>"+r+"</span>":""},s=this.orientation,l=!1!==i.resizable&&!1!==r.resizable,c=i.collapsible,d=i.collapsed,u=r.collapsible,h=r.collapsed,p=o.attr("id");p||(p=t.guid(),o.attr("id",p));const f=t.support.isRtl(e),m=f?"caret-alt-right":"caret-alt-left",g=f?"caret-alt-left":"caret-alt-right";e.addClass("k-splitbar k-splitbar-"+s).attr("role","separator").attr("aria-valuemin","0").attr("aria-valuemax","100").attr("aria-controls",p).removeClass("k-splitbar-"+s+"-hover").toggleClass("k-splitbar-draggable-"+s,l&&!d&&!h).toggleClass("k-splitbar-static-"+s,!l&&!c&&!u).html(a("collapse-prev","caret-alt-up",c&&!d&&!h&&s==x)+a("collapse-prev",m,c&&!d&&!h&&s==k)+a("expand-prev","caret-alt-down",c&&d&&!h&&s==x)+a("expand-prev",g,c&&d&&!h&&s==k)+a("resize-handle",null,l&&s==x)+a("resize-handle",null,l&&s==k)+a("collapse-next","caret-alt-down",u&&!h&&!d&&s==x)+a("collapse-next",g,u&&!h&&!d&&s==k)+a("expand-next","caret-alt-up",u&&h&&!d&&s==x)+a("expand-next",m,u&&h&&!d&&s==k)),i.labelId?e.attr("aria-labelledby",i.labelId):i.label&&e.attr("aria-label",i.label),s==k&&e.attr("aria-orientation",x),l||c||u||e.removeAttr("tabindex")},_updateSplitBars:function(){var t=this;this.element.children(".k-splitbar").each((function(){var n=e(this),i=n.prevAll(g).first(),r=i.data(f),o=n.nextAll(g).first().data(f);n.css("order",r.order+1),o&&t._updateSplitBar(n,r,o,i)}))},_removeSplitBars:function(){this.element.children(".k-splitbar").remove()},_panes:function(){return this.element?this.element.children(g):e()},_resetAriaValueNow:function(e,t){var n,i,r;for(n=0;n<e.length;n++)r=t[n]+t[n+1]||1,i=Math.round(t[n]/r*100),e[n].setAttribute("aria-valuenow",i)},_resize:function(){var n=this,i=n.element,r=i.children(g),o=n.orientation==k,a=i.children(".k-splitbar"),s=a.length,l=o?"width":"height",c=i[l](),d=[];if(n.wrapper.addClass("k-splitter-resizing"),!n._suppressResize){0===s?(s=r.length-1,r.slice(0,s).after("<div tabindex='0' class='k-splitbar' data-marker='"+n._marker+"' />"),n._updateSplitBars(),a=i.children(".k-splitbar")):n._updateSplitBars(),a.each((function(){c-=this[o?"offsetWidth":"offsetHeight"]}));var u=0,h=e();r.each((function(){var t,n=e(this),i=n.data(f)||{};if(n.removeClass("k-collapsed"),i.collapsed)t=i.collapsedSize?z(i.collapsedSize,c):0,n.css("overflow","hidden").addClass("k-collapsed");else{if(i.isFluid||I(i.size))return h=h.add(this),void d.push(!1);t=z(i.size,c)}return u+=t,d.push(t),n.css(w,t+A),t})),c-=u;var m=h.length,v=Math.floor(c/m);h.slice(0,m-1).css(w,v+A).end().eq(m-1).css(w,c-(m-1)*v+A),d.forEach((function(e,t){!1===e&&(d[t]=v)})),n._resetAriaValueNow(a,d);var _=o?"offsetWidth":"offsetHeight";if(0===m){var b=r.filter((function(){return!(e(this).data(f)||{}).collapsed})).last();b.length&&b[l](c+b[0][_])}n._detachEvents(),n._attachEvents(),n.wrapper.removeClass("k-splitter-resizing"),t.resize(r),n.trigger(p)}},toggle:function(e,t){var n;n=(e=this.element.find(e)).data(f),(t||!0===n?.collapsible)&&(1==arguments.length&&(t=undefined!==n.collapsed&&n.collapsed),n.collapsed=!t,e.toggleClass("k-hidden",n.collapsed&&!n.collapsedSize),e.css("overflow",n.collapsed&&!n.collapsedSize?"hidden":"auto"),this.resize(!0))},collapse:function(e){this.toggle(e,!1)},expand:function(e){this.toggle(e,!0)},_addPane:function(e,t,n){var i=this;return n.length&&(i.options.panes.splice(t,0,e),i._initPane(n,e),i._removeSplitBars(),i.resize(!0)),n},append:function(t){t=t||{};var n=this,i=e("<div />").appendTo(n.element);return n._addPane(t,n.options.panes.length,i)},insertBefore:function(t,n){n=e(n),t=t||{};var i=this.wrapper.children(".k-pane").index(n),r=e("<div />").insertBefore(e(n));return this._addPane(t,i,r)},insertAfter:function(t,n){n=e(n),t=t||{};var i=this.wrapper.children(".k-pane").index(n),r=e("<div />").insertAfter(e(n));return this._addPane(t,i+1,r)},remove:function(n){var i=this;return(n=i.wrapper.find(n)).length&&(t.destroy(n),n.each((function(t,n){i.options.panes.splice(i.wrapper.children(".k-pane").index(n),1),e(n).remove()})),i._removeSplitBars(),i.options.panes.length&&i.resize(!0)),i},size:P("size",!0),min:P("min"),max:P("max"),_getPaneElement:function(e){return this._getPaneElements()[e]},_getPaneElements:function(){const t=Array.from(this.element.children()||[]).filter((t=>e(t).hasClass("k-pane")||e(t).hasClass("k-splitter")));return t},_dragSplitterBar:function(e,t){const n=this,{leftPane:i,rightPane:r}=n._getAdjacentPanes(e),o=i.computedSize+t,a=o>i.min&&o<i.max,s=n._getPaneElements().filter((e=>!e.style[w])),l=(i.size||r.size)&&s.length>1;return i.size&&r.size||l?a&&(n._resizePane(i,t),n._resizePane(r,-t)):r.size?n._resizePane(r,-t):n._resizePane(i,t),{leftPane:i,rightPane:r}},_getAdjacentPanes:function(e){const t=this,n=e,i=e+1,r=t._getPaneElement(n),o=t._getPaneElement(i),a=t._getPane(n),s=t._getPane(i),l=t._getPaneOffsetSize(n),c=t._getPaneOffsetSize(i),d=l+c,u=t._getElementClientSize(t.element,t.options.orientation),h=e=>t._calculatePixelSize(e,u),{leftPaneMaxSize:p,rightPaneMaxSize:f}=t._getAdjacentPanesMaxSize(n,i),m=h(s&&s.max),g=h(a&&a.max);return{leftPane:{index:n,computedSize:l,min:h(a&&a.min)||(m?d-m:0)||0,max:p,size:r.style[w],collapsible:a&&a.collapsible,uid:a.uid},rightPane:{index:i,computedSize:c,min:h(s&&s.min)||(g?d-g:0)||0,max:f,size:o.style[w],collapsible:s&&s.collapsible,uid:s.uid}}},_resizePane:function(e,n){const i=this,r=function(e,t,n){return Math.min(n,Math.max(t,e))}(e.computedSize+n,e.min,e.max);let o="";if(M(e.size)){o=function(e){return`${e}%`}(100*r/i._getElementClientSize(i.element,i.options.orientation))}else o=function(e){return t.parseFloat(e)+"px"}(r);e.size=o,i._setPaneSize(e.index,o)},_allExpandedPanesHaveSize:function(){const e=this.options.panes.filter((e=>!e.collapsed));return!!e.length&&e.filter((e=>e.size)).length},_setPaneSize:function(t,n){const i=this._getPaneElement(t);i&&(this._allExpandedPanesHaveSize()||e(i).addClass(_),i.style[w]=n,e(i).data("pane").size=n)},_getPaneSizes:function(e){const t=this,n=t._getElementClientSize(t.element,t.options.orientation),i=t._getPane(e);return{size:t._getPaneOffsetSize(e),min:i&&i.min?t._calculatePixelSize(i.min,n):0,max:i&&i.max?t._calculatePixelSize(i.max,n):C}},_calculatePixelSize:function(e,n){let i=t.parseFloat(e);return M(e)&&(i=n*i/100),i},_getPaneOffsetSize:function(e){const t=this,n=t._getPaneElement(e);return t._getElementOffsetSize(n,t.options.orientation)},_getElementOffsetSize:function(e,t){if(!e)return 0;const n=e.getBoundingClientRect();return t===k?n.width:n.height},_getElementClientSize:function(e,t){return this._getElementSize(e,t,"client")},_getElementSize:function(e,t,n){return e?(e=e[0],t===k?e[`${n}Width`]:e[`${n}Height`]):0},_getPane:function(e){return(this.options.panes||[])[e]},_getPaneIndex:function(e){return this.options.panes.indexOf(e)},_getAdjacentPanesMaxSize:function(e,t){const{size:n,min:i,max:r}=this._getPaneSizes(e),{size:o,min:a,max:s}=this._getPaneSizes(t),l=n+o;return{leftPaneMaxSize:Math.min(r,l-a),rightPaneMaxSize:Math.min(s,l-i)}},_getElementIndex:function(e,t){if(!e)return[].indexOf(e);let n=Array.from(e.parent().children());return t&&(n=n.filter((e=>e.matches(t)))),Array.from(n).indexOf(e[0])}});n.plugin(H);var F={sizingProperty:"height",sizingDomProperty:"offsetHeight",alternateSizingProperty:"width",positioningProperty:"top",mousePositioningProperty:"pageY"},R={sizingProperty:"width",sizingDomProperty:"offsetWidth",alternateSizingProperty:"height",positioningProperty:"left",mousePositioningProperty:"pageX"};function L(e){var n=this,i=e.orientation,o=".k-splitbar-draggable-"+i+"[data-marker="+e._marker+"]";e.options.clickMoveClick&&(o+=",.k-ghost-splitbar"),n.owner=e,n._element=e.element,n.orientation=i,r(n,i===k?R:F),n._resizable=new t.ui.Resizable(e.element,{orientation:i,handle:o,clickMoveClick:e.options.clickMoveClick,hint:n._createHint.bind(n),start:n._start.bind(n),max:n._max.bind(n),min:n._min.bind(n),invalidClass:"k-restricted-size-"+i,resize:n._resize.bind(n),resizeend:n._stop.bind(n)})}L.prototype={stop:function(){this._resizable._stop()},press:function(e){this._resizable.press(e),this.pressed=!0},move:function(e,t){if(!t.hasClass("k-splitbar-draggable-horizontal")&&!t.hasClass("k-splitbar-draggable-vertical"))return;const n=this.owner._getElementIndex(t,`.${y}`),{leftPane:i,rightPane:r}=this.owner._dragSplitterBar(n,e);this.owner.trigger(D,{leftPane:i,rightPane:r})},end:function(){this._resizable.end(),this.pressed=!1},destroy:function(){this._resizable.destroy(),this._resizable=this._element=this.owner=null},isResizing:function(){return this._resizable.resizing},_createHint:function(t){var n=this;return e("<div class='k-ghost-splitbar k-ghost-splitbar-"+n.orientation+"' />").css("z-index",99).css(n.alternateSizingProperty,t[n.alternateSizingProperty]())},_start:function(n){var i=this,r=e(n.currentTarget);const o=t.support.isRtl(i._element);let a=i.orientation===k?"offsetLeft":"offsetTop";const s=i.owner._getElementIndex(r,`.${y}`),l=i.owner._getPaneElement(s),c=i.owner._getPaneElement(s+1);let d=e(i.orientation===k&&o?c:l),u=e(i.orientation===k&&o?l:c);if(e(n.initialTarget).closest(".k-expand-next, .k-expand-prev, .k-collapse-next, .k-collapse-prev").length>0||!u.length||!d.length)n.preventDefault();else{var h=d.data(f),p=u.data(f),m=parseInt(d[0][a],10),g=parseInt(u[0][a],10)+u[0][i.sizingDomProperty]-r[0][i.sizingDomProperty],v=parseInt(i._element.css(i.sizingProperty),10),_=function(e){var t=parseInt(e,10);return(E(e)?t:v*t/100)||0};if(!h||!p)return n.preventDefault(),n.sender.draggable.clickMoveClick.cancel(),void i.owner.element.find(".k-ghost-splitbar").remove();var b=_(h.min),w=_(h.max)||g-m,x=_(p.min),C=_(p.max)||g-m;i.previousPane=d,i.nextPane=u,i._maxPosition=Math.min(g-x,m+w),i._minPosition=Math.max(m+b,g-C)}},_max:function(){return this._maxPosition},_min:function(){return this._minPosition},_resize:function(e){let n,i=this.owner,r=i.orientation;const o=e.currentTarget||e.target;if(!o)return;const a=i._getElementIndex(o,`.${y}`),s=t.support.isRtl(this._element)?-1:1;n=r===k?e.x.delta*s:e.y.delta,i._dragSplitterBar(a,n)},_stop:function(n){var i=e(n.currentTarget),r=this.owner;let o=t.support.isRtl(this._element);if(r._panes().children(".k-splitter-overlay").remove(),n.keyCode!==t.keys.ESC){let e=r.orientation===k?n.x.initialDelta:n.y.initialDelta,t=r.orientation===k?i.position().left:i.position().top,a=n.position,s=r.orientation===k&&o?-1:1;const l=this.owner._getElementIndex(n.currentTarget,`.${y}`);Math.abs(t-a)>2&&r._dragSplitterBar(l,e*s);const{leftPane:c,rightPane:d}=r._getAdjacentPanes(l);r.trigger(D,{leftPane:c,rightPane:d})}return!1}}}(window.kendo.jQuery);kendo;kendo.ui.scheduler={},function(e){var t=window.kendo,n=t.ui,i=t.date.getDate,r=n.Widget,o=t._outerHeight,a=t.keys,s="k-event-ongoing",l=Math,c=" ";function d(e,t){var n=[];return function e(i,r){if(r=r[t])for(var o=n[i]=n[i]||[],a=0;a<r.length;a++)o.push(r[a]),e(i+1,r[a])}(0,e),n}function u(e,n){return e.length?'<table role="presentation" class="'+t.trim("k-scheduler-table "+(n||""))+'"><tr>'+e.join("</tr><tr>")+"</tr></table>":""}var h,p=t.Class.extend({init:function(e,t,n){this._index=e,this._timeSlotCollections=[],this._daySlotCollections=[],this._isRtl=t,this._enforceAllDaySlot=n},addTimeSlotCollection:function(e,t){return this._addCollection(e,t,this._timeSlotCollections)},addDaySlotCollection:function(e,t){return this._addCollection(e,t,this._daySlotCollections)},_addCollection:function(e,t,n){var i=new v(e,t,this._index,n.length);return n.push(i),i},timeSlotCollectionCount:function(){return this._timeSlotCollections.length},daySlotCollectionCount:function(){return this._daySlotCollections.length},_refreshSlotCollections:function(){for(var e=[this._timeSlotCollections||[],this._daySlotCollections||[]],t=0;t<e.length;t++)for(var n=e[t],i=0;i<n.length;i++){n[i].refresh()}},daySlotByPosition:function(e,t,n){return this._slotByPosition(e,t,this._daySlotCollections,n)},timeSlotByPosition:function(e,t,n){return this._slotByPosition(e,t,this._timeSlotCollections,n)},_slotByPosition:function(e,t,n,i){for(var r=0;r<n.length;r++)for(var o=n[r],a=0;a<o.count();a++){var s,l=o.at(a),c=l.offsetWidth,d=l.offsetHeight,u=l.offsetLeft+c,h=l.offsetTop+d;if(i||(s=o.at(a+1)),s&&(s.offsetLeft!=l.offsetLeft?u=this._isRtl?l.offsetLeft+(l.offsetLeft-s.offsetLeft):s.offsetLeft:h=s.offsetTop),e>=l.offsetLeft&&e<u&&t>=l.offsetTop&&t<h)return l}},refresh:function(){var e;for(e=0;e<this._daySlotCollections.length;e++)this._daySlotCollections[e].refresh();for(e=0;e<this._timeSlotCollections.length;e++)this._timeSlotCollections[e].refresh()},timeSlotRanges:function(e,n){var i,r,o=this._timeSlotCollections,a=this._startSlot(e,o);!a.inRange&&e>=a.slot.end&&(i=a.slot.collectionIndex+1,a=null);var s=a;if(e<n&&(s=this._endSlot(n,o)),s&&!s.inRange&&n<=s.slot.start&&(r=s.slot.collectionIndex,n===s.slot.start&&(a&&r>a.slot.collectionIndex||r>i)&&(r-=1),s=null),null===a&&null===s){if(n-e<t.date.MS_PER_DAY)return[];a={inRange:!0,slot:o[i].first()},s={inRange:!0,slot:o[r].last()}}if(null===a){if(s.slot.end<=e)return[];a={inRange:!0,slot:(o[i]||o[s.slot.collectionIndex]).first()}}if(null===s){if(a.slot.start>=n)return[];s={inRange:!0,slot:(o[r]||o[a.slot.collectionIndex]).last()}}return this._continuousRange(m,o,a,s)},daySlotRanges:function(e,n,i){var r=this._daySlotCollections,o=this._startSlot(e,r,i);!o.inRange&&e>=o.slot.end&&(o=null);var a=o;if(e<n&&(a=this._endSlot(n,r,i)),a&&!a.inRange&&n<=a.slot.start&&(a=null),null===o&&null===a)return[];if(null===o){if(a.slot.end<=e)return[];do{e+=t.date.MS_PER_DAY,o=this._startSlot(e,r,i)}while(!o.inRange&&e>=o.slot.end)}if(null===a){if(o.slot.start>=n)return[];do{n-=t.date.MS_PER_DAY,a=this._endSlot(n,r,i)}while(!a.inRange&&n<=a.slot.start)}return this._continuousRange(g,r,o,a)},_continuousRange:function(e,t,n,i){for(var r=n.slot,o=i.slot,a=r.collectionIndex,s=o.collectionIndex,l=[],c=a;c<=s;c++){var d=t[c],u=d.first(),h=d.last(),p=!1,f=!1;c==a&&(f=!n.inRange),c==s&&(p=!i.inRange),u.start<r.start&&(u=r),h.start>o.start&&(h=o),a<s&&(c==a?p=!0:c==s?f=!0:p=f=!0),l.push(new e({start:u,end:h,collection:d,head:p,tail:f}))}return l},slotRanges:function(e,n){var i=e._startTime||t.date.toUtcTime(e.start),r=e._endTime||t.date.toUtcTime(e.end);return void 0===n&&(n=this._enforceAllDaySlot?e.isMultiDay():e.isAllDay),n?this.daySlotRanges(i,r,e.isAllDay):this.timeSlotRanges(i,r)},ranges:function(e,n,i,r){return"number"!=typeof e&&(e=t.date.toUtcTime(e)),"number"!=typeof n&&(n=t.date.toUtcTime(n)),i?this.daySlotRanges(e,n,r):this.timeSlotRanges(e,n)},_startCollection:function(e,t){for(var n=0;n<t.length;n++){var i=t[n];if(i.startInRange(e))return i}return null},_endCollection:function(e,t,n){for(var i=0;i<t.length;i++){var r=t[i];if(r.endInRange(e,n))return r}return null},_getCollections:function(e){return e?this._daySlotCollections:this._timeSlotCollections},continuousSlot:function(e,t){var n=t?-1:1,i=this._getCollections(e.isDaySlot)[e.collectionIndex+n];return i?i[t?"last":"first"]():void 0},firstSlot:function(){return this._getCollections(this.daySlotCollectionCount())[0].first()},lastSlot:function(){var e=this._getCollections(this.daySlotCollectionCount());return e[e.length-1].last()},upSlot:function(e,t,n){var i=this;return this.timeSlotCollectionCount()||(t=!0),this._verticalSlot(e,-1,(function(e,n,r){if(!t&&!e&&0===r&&i.daySlotCollectionCount())return i._daySlotCollections[0].at(n)}),n)},downSlot:function(e,t,n){var i=this;return this.timeSlotCollectionCount()||(t=!0),this._verticalSlot(e,1,(function(e,n,r){if(!t&&e&&i.timeSlotCollectionCount())return i._timeSlotCollections[r].at(0)}),n)},leftSlot:function(e,t){return this._horizontalSlot(e,-1,t)},rightSlot:function(e,t){return this._horizontalSlot(e,1,t)},_horizontalSlot:function(e,t,n){var i=e.index,r=e.isDaySlot,o=e.collectionIndex,a=this._getCollections(r);(r=!n&&r)?i+=t:o+=t;var s=a[o];return s?s.at(i):void 0},_verticalSlot:function(e,t,n,i){var r=e.index,o=e.isDaySlot,a=e.collectionIndex,s=this._getCollections(o);if(e=n(o,a,r))return e;(o=!i&&o)?a+=t:r+=t;var l=s[a];return l?l.at(r):void 0},_collection:function(e,t){return(t?this._daySlotCollections:this._timeSlotCollections)[e]},_startSlot:function(e,t,n){var i=this._startCollection(e,t),r=!0,o=0;if(!i){for(i=t[o];o<t.length-1&&i._start<e;)i=t[++o];r=!1}var a=i.slotByStartDate(e,n);return a||(a=i.first(),r=!1),{slot:a,inRange:r}},_endSlot:function(e,t,n){var i=this._endCollection(e,t,n),r=!0,o=t.length-1;if(!i){for(i=t[o];o>0&&i._start>e;)i=t[--o];r=!1}var a=i.slotByEndDate(e,n);return a||(a=e<=i.first().start?i.first():i.last(),r=!1),{slot:a,inRange:r}},getSlotCollection:function(e,t){return this[t?"getDaySlotCollection":"getTimeSlotCollection"](e)},getTimeSlotCollection:function(e){return this._timeSlotCollections[e]},getDaySlotCollection:function(e){return this._daySlotCollections[e]}}),f=t.Class.extend({init:function(t){e.extend(this,t)},innerHeight:function(){for(var e=this.collection,t=this.start.index,n=this.end.index,i=0,r=t;r<=n;r++)i+=e.at(r).offsetHeight;return i},events:function(){return this.collection.events()},addEvent:function(e){this.events().push(e)},startSlot:function(){return this.start.offsetLeft>this.end.offsetLeft?this.end:this.start},endSlot:function(){return this.start.offsetLeft>this.end.offsetLeft?this.start:this.end}}),m=f.extend({innerHeight:function(){for(var e=this.collection,t=this.start.index,n=this.end.index,i=0,r=t;r<=n;r++)i+=e.at(r).offsetHeight;return i},outerRect:function(e,t,n){return this._rect("offset",e,t,n)},_rect:function(e,n,i,r){var o,a,s,l,c=this.start,d=this.end,u=t.support.isRtl(c.element);if("number"!=typeof n&&(n=t.date.toUtcTime(n)),"number"!=typeof i&&(i=t.date.toUtcTime(i)),r)o=c.offsetTop,a=d.offsetTop+d[e+"Height"],u?(s=d.offsetLeft,l=c.offsetLeft+c[e+"Width"]):(s=c.offsetLeft,l=d.offsetLeft+d[e+"Width"]);else{var h=n-c.start;h<0&&(h=0);var p=c.end-c.start;o=c.offsetTop+c[e+"Height"]*h/p;var f=d.end-i;f<0&&(f=0);var m=d.end-d.start;a=d.offsetTop+d[e+"Height"]-d[e+"Height"]*f/m,u?(s=Math.round(d.offsetLeft+d[e+"Width"]*f/m),l=Math.round(c.offsetLeft+c[e+"Width"]-c[e+"Width"]*h/p)):(s=Math.round(c.offsetLeft+c[e+"Width"]*h/p),l=Math.round(d.offsetLeft+d[e+"Width"]-d[e+"Width"]*f/m))}return{top:o,bottom:a,left:0===s?s:s+1,right:l}},innerRect:function(e,t,n){return this._rect("client",e,t,n)}}),g=f.extend({innerWidth:function(){for(var e=this.collection,t=this.start.index,n=this.end.index,i=0,r=t!==n?"offsetWidth":"clientWidth",o=t;o<=n;o++)i+=e.at(o)[r];return i}}),v=t.Class.extend({init:function(e,n,i,r){this._slots=[],this._events=[],this._start=t.date.toUtcTime(e),this._end=t.date.toUtcTime(n),this._groupIndex=i,this._collectionIndex=r},refresh:function(){for(var e=0;e<this._slots.length;e++)this._slots[e].refresh()},startInRange:function(e){return this._start<=e&&e<this._end},endInRange:function(e,t){var n=t?e<this._end:e<=this._end;return this._start<=e&&n},slotByStartDate:function(e){var n=e;"number"!=typeof n&&(n=t.date.toUtcTime(e));for(var i=0;i<this._slots.length;i++){var r=this._slots[i];if(r.startInRange(n))return r}return null},slotByEndDate:function(e,n){var i=e;if("number"!=typeof i&&(i=t.date.toUtcTime(e)),n)return this.slotByStartDate(e,!1);for(var r=0;r<this._slots.length;r++){var o=this._slots[r];if(o.endInRange(i))return o}return null},count:function(){return this._slots.length},events:function(){return this._events},addTimeSlot:function(e,t,n,i){var r=new b(e,t,n,this._groupIndex,this._collectionIndex,this._slots.length,i);this._slots.push(r)},addDaySlot:function(e,t,n,i){var r=new y(e,t,n,this._groupIndex,this._collectionIndex,this._slots.length,i);this._slots.push(r)},first:function(){return this._slots[0]},last:function(){return this._slots[this._slots.length-1]},at:function(e){return this._slots[e]}}),_=t.Class.extend({init:function(e,t,n,i,r,o){this.element=e,this.clientWidth=e.clientWidth,this.clientHeight=e.clientHeight,this.offsetWidth=e.offsetWidth,this.offsetHeight=e.offsetHeight,this.offsetTop=e.offsetTop,this.offsetLeft=e.offsetLeft,this.start=t,this.end=n,this.element=e,this.groupIndex=i,this.collectionIndex=r,this.index=o,this.isDaySlot=!1},refresh:function(){var e=this.element;this.clientWidth=e.clientWidth,this.clientHeight=e.clientHeight,this.offsetWidth=e.offsetWidth,this.offsetHeight=e.offsetHeight,this.offsetTop=e.offsetTop,this.offsetLeft=e.offsetLeft},startDate:function(){return t.timezone.toLocalDate(this.start)},endDate:function(){return t.timezone.toLocalDate(this.end)},startInRange:function(e){return this.start<=e&&e<this.end},endInRange:function(e){return this.start<e&&e<=this.end},startOffset:function(){return this.start},endOffset:function(){return this.end}}),b=_.extend({init:function(e,t,n,i,r,o,a){_.fn.init.apply(this,arguments),this.isHorizontal=!!a},offsetX:function(e,t){return this.offsetLeft+t},startInRange:function(e){return this.start<=e&&e<this.end},endInRange:function(e){return this.start<e&&e<=this.end},startOffset:function(n,i,r){if(r)return this.start;var o,a,s=e(this.element).offset(),l=this.end-this.start;if(this.isHorizontal){var c=t.support.isRtl(this.element);if(o=n-s.left,a=Math.floor(l*(o/this.offsetWidth)),c)return this.start+l-a}else o=i-s.top,a=Math.floor(l*(o/this.offsetHeight));return this.start+a},endOffset:function(n,i,r){if(r)return this.end;var o,a,s=e(this.element).offset(),l=this.end-this.start;if(this.isHorizontal){var c=t.support.isRtl(this.element);if(o=n-s.left,a=Math.floor(l*(o/this.offsetWidth)),c)return this.start+l-a}else o=i-s.top,a=Math.floor(l*(o/this.offsetHeight));return this.start+a}}),y=_.extend({init:function(e,t,n,i,r,o,a){if(_.fn.init.apply(this,arguments),this.eventCount=a,this.isDaySlot=!0,this.element.children.length){var s=this.element.children[0];this.firstChildHeight=s.offsetHeight,this.firstChildTop=s.offsetTop}else this.firstChildHeight=3,this.firstChildTop=0},startDate:function(){var e=new Date(this.start);return t.timezone.apply(e,"Etc/UTC")},endDate:function(){var e=new Date(this.end);return t.timezone.apply(e,"Etc/UTC")},startInRange:function(e){return this.start<=e&&e<this.end},endInRange:function(e){return this.start<e&&e<=this.end}});function w(e){return{start:e.start,end:e.end,slotIndex:e.slotIndex,slotIndexEnd:e.slotIndexEnd}}t.ui.SchedulerView=r.extend({init:function(n,i){r.fn.init.call(this,n,e.extend({},this.options,i)),this._normalizeOptions(),this._initDefaultTools(),this._scrollbar=h=h||t.support.scrollbar(),this._isRtl=t.support.isRtl(n),this._resizeHint=e(),this._moveHint=e(),this._cellId=t.guid(),this._resourcesForGroups(),this._selectedSlots=[],this.element.attr("role","application")},options:{messages:{ariaEventLabel:{on:"on",at:"at",to:"to",allDay:"(all day)",prefix:""}}},visibleEndDate:function(){return this.endDate()},_initDefaultTools:function(){this._defaultTools={todayMobile:{type:"button",fillMode:"flat",text:this.options.messages.today,click:this._footerTodayClickHandler.bind(this),attributes:{class:"k-scheduler-today"}},fulldayDesktop:{type:"button",icon:"clock",text:this.options.showWorkHours?this.options.messages.showFullDay:this.options.messages.showWorkDay,click:this.toggleFullDay?this.toggleFullDay.bind(this):e.noop,attributes:{class:"k-scheduler-fullday"}},fulldayMobile:{type:"button",fillMode:"flat",text:this.options.showWorkHours?this.options.messages.showFullDay:this.options.messages.showWorkDay,click:this.toggleFullDay?this.toggleFullDay.bind(this):e.noop,attributes:{class:"k-scheduler-fullday"}}}},_normalizeOptions:function(){var e=this.options;e.startTime&&e.startTime.setMilliseconds(0),e.endTime&&e.endTime.setMilliseconds(0),e.workDayStart&&e.workDayStart.setMilliseconds(0),e.workDayEnd&&e.workDayEnd.setMilliseconds(0)},_isMobile:function(){var e=this.options;return!0===e.mobile&&t.support.mobileOS||"phone"===e.mobile||"tablet"===e.mobile},_addResourceView:function(){var e=new p(this.groups.length,this._isRtl,this.options.enforceAllDaySlot);return this.groups.push(e),e},_refreshResourceViews:function(){var e=this.groups;if(e)for(var t=0;t<e.length;t++)e[t]._refreshSlotCollections()},dateForTitle:function(){return t.format(this.options.selectedDateFormat,this.startDate(),this.endDate())},shortDateForTitle:function(){return t.format(this.options.selectedShortDateFormat,this.startDate(),this.endDate())},mobileDateForTitle:function(){return t.format(this.options.selectedMobileDateFormat||this.options.selectedShortDateFormat,this.startDate(),this.endDate())},_changeGroup:function(e,t){var n=this[t?"prevGroupSlot":"nextGroupSlot"](e.start,e.groupIndex,e.isAllDay);return n&&(e.groupIndex+=t?-1:1),this._isGroupedByDate()&&!n&&(e.groupIndex=t?this.groups.length-1:0),n},_changeDate:function(e,t,n){var i,r,o=this.groups[e.groupIndex];if(n){if(i=o._getCollections(!1),(r=o.daySlotCollectionCount()?t.index-1:t.collectionIndex-1)>=0)return i[r]._slots[i[r]._slots.length-1]}else{i=o._getCollections(o.daySlotCollectionCount()),r=o.daySlotCollectionCount()?0:t.collectionIndex+1;var a=o.daySlotCollectionCount()?t.collectionIndex+1:0;if(i[r]&&i[r]._slots[a])return i[r]._slots[a]}},_changeGroupContinuously:function(){return null},_changeViewPeriod:function(){return!1},_isInRange:function(e,t){return!!(e&&t&&this.options.min&&this.options.max)&&(i(e)<=i(this.options.min)||i(t)>=i(this.options.max))},_horizontalSlots:function(e,t,n,i){var r,o=i?"leftSlot":"rightSlot",a={startSlot:t[0].start,endSlot:t[t.length-1].end},s=this.groups[e.groupIndex],l=this._isVerticallyGrouped();if(!n){var c=this._normalizeHorizontalSelection(e,t,i);c&&(a.startSlot=a.endSlot=c)}if(this._isGroupedByDate()&&!n){var d=this._changeGroup(e,i);d?a.startSlot=a.endSlot=d:a=this._getNextHorizontalRange(s,o,a)}else a.startSlot=s[o](a.startSlot),a.endSlot=s[o](a.endSlot),n||l||a.startSlot&&a.endSlot||(a.startSlot=a.endSlot=this._changeGroup(e,i));return a.startSlot&&a.endSlot||this._isGroupedByDate()||(r=this._continuousSlot(e,t,i),(r=this._changeGroupContinuously(e,r,n,i))&&(a.startSlot=a.endSlot=r)),a},_getNextHorizontalRange:function(e,t,n){return this._isVerticallyGrouped()||(n.startSlot=e[t](n.startSlot),n.endSlot=e[t](n.endSlot)),n},_verticalSlots:function(e,t,n,i){var r,o=this.groups[e.groupIndex],a={startSlot:t[0].start,endSlot:t[t.length-1].end};n||(r=this._normalizeVerticalSelection(e,t,i))&&(a.startSlot=a.endSlot=r);var s=i?"upSlot":"downSlot";return a=this._getNextVerticalRange(o,s,a,n),n||!this._isVerticallyGrouped()||a.startSlot&&a.endSlot||(this._isGroupedByDate()?a.startSlot=a.endSlot=this._changeDate(e,r,i):a.startSlot=a.endSlot=this._changeGroup(e,i)),a},_getNextVerticalRange:function(e,t,n,i){return n.startSlot=e[t](n.startSlot,i),n.endSlot=e[t](n.endSlot,i),n},_normalizeHorizontalSelection:function(){return null},_normalizeVerticalSelection:function(e,t,n){return n?t[0].start:t[t.length-1].end},_continuousSlot:function(){return null},_footerTodayClickHandler:function(e){e.preventDefault();var n,i=this,r=i.options,o=i.options.timezone,a=new Date;if(o){var s=t.timezone.offset(a,o);n=t.timezone.convert(a,a.getTimezoneOffset(),s)}else n=a;i.trigger("navigate",{view:i.name||r.name,action:"today",date:n})},_footerItems:function(){var e=this,t=[],n=this.options;return e._isMobile()&&t.push({type:"button",fillMode:"flat",text:n.messages.today,click:e._footerTodayClickHandler.bind(e),attributes:{class:"k-scheduler-today"}}),t},_footer:function(){if(!1!==this.options.footer){var t=this,n=t._footerItems();if(n.length>0){var i=e('<div class="k-scheduler-footer">');t.footer=i.appendTo(t.element),t.footer.kendoToolBar({resizable:!1,items:n})}}},constrainSelection:function(e){var t,n=this.groups[0];this.inRange(e)?n.daySlotCollectionCount()?n.timeSlotCollectionCount()||(e.isAllDay=!0):e.isAllDay=!1:(t=n.firstSlot(),e.isAllDay=t.isDaySlot,e.start=t.startDate(),e.end=t.endDate()),this.groups[e.groupIndex]||(e.groupIndex=0)},move:function(e,t,n){var i=!1,r=this.groups[e.groupIndex],o=this._isGroupedByDate()&&this._isVerticallyGrouped();r.timeSlotCollectionCount()||(e.isAllDay=!0);var s,l,c,d,u=r.ranges(e.start,e.end,e.isAllDay,!1);if(t===a.DOWN||t===a.UP){if(i=!0,c=t===a.UP,this._updateDirection(e,u,n,c,!0),!(d=this._verticalSlots(e,u,n,c)).startSlot&&!n&&this._changeViewPeriod(e,c,!o))return i}else if((t===a.LEFT||t===a.RIGHT)&&(i=!0,c=t===a.LEFT,this._updateDirection(e,u,n,c,!1),!(d=this._horizontalSlots(e,u,n,c)).startSlot&&!n&&this._changeViewPeriod(e,c,o)))return i;if(i){if(s=d.startSlot,l=d.endSlot,n){var h=e.backward;h&&s?e.start=s.startDate():!h&&l&&(e.end=l.endDate())}else s&&l&&(e.isAllDay=s.isDaySlot,e.start=s.startDate(),e.end=l.endDate());e.events=[]}return i},moveToEventInGroup:function(t,n,i,r){var o,a,s,l=t._continuousEvents||[],c=r?-1:1,d=l.length,u=r?d-1:0;if(i.length)if(s=i[i.length-1],r)for(a=0;a<l.length;a++)l[a].uid===s&&(u=a+c);else for(a=l.length-1;a>-1;a--)l[a].uid===s&&(u=a+c);for(;u<d&&u>-1;){if(o=l[u],(!r&&o.start.startDate()>=n.startDate()||r&&o.start.startDate()<=n.startDate())&&o&&-1===e.inArray(o.uid,i)){0;break}u+=c}return o},moveToEvent:function(e,t){var n,i=e.groupIndex,r=this.groups[i],o=r.ranges(e.start,e.end,"month"===this.name||e.isAllDay,!1)[0].start,a=this.groups.length,s=t?-1:1,l=e.events;if(this._isGroupedByDate()){var c=this._getAllEvents(),d=this._getUniqueEvents(c),u=this._getSortedEvents(d);if(0===l.length){var h=this._getNextEventIndexBySlot(o,u,i);t&&h--,n=u[h]}else for(var p=this._getStartIdx(l,u);p<u.length&&p>-1&&(l.length>0&&(o=this._getSelectedSlot(o,u,n,p,s,t)),o);){if((!t&&u[p].start.startDate()>=o.startDate()||t&&u[p].start.startDate()<=o.startDate())&&l[0]!=u[p].uid){n=u[p];break}p+=s}}else for(;i<a&&i>-1&&(n=this.moveToEventInGroup(r,o,l,t),i+=s,(r=this.groups[i])&&!n);)l=[],o=t?r.lastSlot():r.firstSlot(!0);return n&&(e.events=[n.uid],e.start=n.start.startDate(),e.end=n.end.endDate(),e.isAllDay=n.start.isDaySlot,e.groupIndex=n.start.groupIndex,e.eventElement=n.element[0]),!!n},current:function(e){if(void 0===e)return this._current;this._current=e,this.content.has(e)&&this._scrollTo(e,this.content[0])},select:function(e){this.clearSelection(),this._selectEvents(e)||this._selectSlots(e)},_getNextEventIndexBySlot:function(e,n,i){for(var r=0,o=t.date.getDate(e.startDate()),a=0;a<n.length;a++){var s=t.date.getDate(n[a].start.startDate());if(o>s)r++;else if(o.getTime()===s.getTime()&&i>n[a].start.groupIndex)r++;else{if(!(o.getTime()===s.getTime()&&i>=n[a].start.groupIndex&&e.startDate()>n[a].start.startDate()))break;r++}}return r},_getSelectedSlot:function(e,t,n,i,r,o){if(t[i+r]&&t[i].start.groupIndex!==t[i+r].start.groupIndex){var a=t[i+r].start.groupIndex,s=this.groups[a];s&&!n||(e=null),e=o?s.lastSlot():s.firstSlot(!0)}return e},_getStartIdx:function(t,n){var i=0;return e.each(n,(function(){if(this.uid===t[0])return!1;i++})),i},_getAllEvents:function(){for(var e=[],t=this.groups,n=0;n<t.length;n++)t[n]._continuousEvents&&(e=e.concat(t[n]._continuousEvents));return e},_getUniqueEvents:function(e){for(var t=[],n=0;n<e.length;n++){for(var i=!1,r=0;r<t.length;r++)if(e[n].uid===t[r].uid){i=!0;break}i||t.push(e[n])}return t},_getSortedEvents:function(n){return n.sort((function(n,i){var r=n.start.startDate(),o=i.start.startDate(),a=t.date.getDate(r)-t.date.getDate(o);return 0===a&&(a=n.start.groupIndex-i.start.groupIndex),0===a&&(a=r.getTime()-o.getTime()),0===a&&(n.start.isDaySlot&&!i.start.isDaySlot&&(a=-1),!n.start.isDaySlot&&i.start.isDaySlot&&(a=1)),0===a&&(a=e(n.element).index()-e(i.element).index()),a}))},_selectSlots:function(e){var t=e.isAllDay,n=this.groups[e.groupIndex];n.timeSlotCollectionCount()||(t=!0),this._selectedSlots=[];for(var i,r,o,a=n.ranges(e.start,e.end,t,!1),s=0;s<a.length;s++)for(var l=a[s],c=l.collection,d=l.start.index;d<=l.end.index;d++)i=(r=c.at(d)).element,(o=i).className=o.className.replace(T,"")+" k-selected",this._selectedSlots.push({start:r.startDate(),end:r.endDate(),element:i});e.backward&&(i=a[0].start.element),this.current(i)},_selectEvents:function(t){var n,i,r=!1,o=t.events,a=this._getAllEvents(),s=a.length;if(!o[0]||!a[0])return r;var l=e();for(t.events=[],n=0;n<s;n++)e.inArray(a[n].uid,o)>-1&&(i=a[n],l=l.add(i.element),-1===t.events.indexOf(i.uid)&&t.events.push(i.uid));return l[0]&&(l.addClass("k-selected"),t.eventElement?this.current(t.eventElement):this.current(l.last()[0]),this._selectedSlots=[],r=!0),r},inRange:function(e){var n=this.startDate(),i=t.date.addDays(this.endDate(),1),r=e.start,o=e.end;return n<=r&&r<i&&n<o&&o<=i},_resourceValue:function(e,n){return e.valuePrimitive&&(n=t.getter(e.dataValueField)(n)),n},_setResourceValue:function(e,n,i){var r=e.value;n.multiple&&(r=[r]),t.setter(n.field)(i,r)},_resourceBySlot:function(e){var t=this.groupedResources,n={};if(t.length){var i,r,o,a,s=e.groupIndex,l=this.options.group,c=l.date||"horizontal"===l.orientation?"columns":"rows",d="rows"===c?this.rowLevels:this.columnLevels,u=l.date&&"horizontal"===l.orientation?1:0,h=d[t.length-1+u],p=t[t.length-1],f=h[s];for(this._setResourceValue(f,p,n),o=t.length-2;o>=0;o--)for(h=d[o+u],p=t[o],i=0,a=0;a<h.length;a++){if((r=(f=h[a])[c].length)>s-i){this._setResourceValue(f,p,n);break}i+=r}}return n},_createResizeHint:function(t,n,i,r){return e('<div class="k-marquee k-scheduler-marquee"><div class="k-marquee-color"></div><div class="k-marquee-text"><div class="k-label-top"></div><div class="k-label-bottom"></div></div></div>').css({left:t,top:n,width:i,height:r})},_removeResizeHint:function(){this._resizeHint.remove(),this._resizeHint=e()},_removeMoveHint:function(t){t?(this._moveHint.filter("[data-uid='"+t+"']").remove(),this._moveHint=this._moveHint.filter("[data-uid!='"+t+"']")):(this._moveHint.remove(),this._moveHint=e())},_scrollTo:function(e,t){var n=e.offsetTop,i=e.offsetHeight,r=t.scrollTop,o=t.clientHeight,a=n+i,s=0;s=r>n?n:a>r+o?i<=o?a-o:n:r,t.scrollTop=s},_inverseEventColor:function(e){var t=e.css("color"),n=new k(t).isDark(),i=e.css("background-color");n==new k(i).isDark()&&e.addClass("k-event-inverse")},_eventTmpl:function(n,i){var r=this.options,o=e.extend({},t.Template,r.templateSettings),a=o.paramName,s="",l=typeof n,c={storage:{},count:0};"function"===l?(c.storage["tmpl"+c.count]=n,s+="#=this.tmpl"+c.count+"("+a+")#",c.count++):"string"===l&&(s+=n);var d=t.template(t.format(i,s),o);return c.count>0&&(d=d.bind(c.storage)),d},eventResources:function(e){var n=[],i=this.options;if(!i.resources)return n;for(var r=0;r<i.resources.length;r++){var o=i.resources[r],a=o.field,s=t.getter(a)(e);if(null!=s){o.multiple||(s=[s]);for(var l=o.dataSource.view(),c=0;c<s.length;c++){var d=null,u=s[c];o.valuePrimitive||(u=t.getter(o.dataValueField)(u));for(var h=0;h<l.length;h++)if(l[h].get(o.dataValueField)==u){d=l[h];break}if(null!==d){var p=t.getter(o.dataColorField)(d);n.push({field:o.field,title:o.title,name:o.name,text:t.getter(o.dataTextField)(d),value:u,color:p})}}}}return n},createLayout:function(n){var i=-1;n.rows||(n.rows=[]);for(var r=0;r<n.rows.length;r++)if(n.rows[r].allDay){i=r;break}var o=n.rows[i];i>=0&&n.rows.splice(i,1);var a=this.columnLevels=d(n,"columns"),s=this.rowLevels=d(n,"rows");this._isVirtualized()&&this._trimRowLevels(s),this.table=e('<table role="presentation" class="k-scheduler-layout k-scheduler-'+this.name+'view"><tbody></tbody></table>');var l=s[s.length-1].length;this.table.find("tbody").first().append(this._topSection(a,o,l)),this.table.find("tbody").first().append(this._bottomSection(s,l)),this.element.append(this.table),this._isVirtualized()&&this._updateDomRowLevels(),this._isMobile()&&a.length>1&&"horizontal"===this._groupOrientation()&&t._outerWidth(e(window))<1024&&(this.table.find(".k-scheduler-content .k-scheduler-table").width(100*a[a.length-2].length+"%"),this.table.find(".k-scheduler-header .k-scheduler-table").width(100*a[a.length-2].length+"%")),this._scroller()},_isVirtualized:function(){return this.options.virtual&&this.rowLevels.length>1&&this._isVerticallyGrouped()},_trimRowLevels:function(e){var t,n=e[e.length-2],i=this.cachedRowLevels||[];this._hasContentToRender=!0;for(var r=function(e,t){var n,i;return!(e[t-1].length>0)||(n=e[t-1][0],i=e[t][0].parentValue,n.value!==i)},o=e.length-2;o>=0;o--){var a=!1;if(o>0&&r(e,o)&&(a=!0,t=o),i[o]=e[o].splice(1),o<e.length-2&&1!=e[o][0].rows.length&&(e[o][0].rows=e[o+1]),a)break}return i[e.length-1]=e[e.length-1].splice(n[0].rows.length),this.cachedRowLevels=i,i[i.length-1].length||(this._hasContentToRender=!1),{levelMarker:t||0,rowLevels:e}},createNextLayout:function(){for(var e,t,n,i,r=[],o=0;o<this.cachedRowLevels.length;o++)r[o]=this.cachedRowLevels[o];t=(e=this._trimRowLevels(r)).rowLevels.splice(e.levelMarker),n=e.levelMarker,i=t[t.length-1].length,delete this._height;for(var a=n;a<this.rowLevels.length;a++)this.rowLevels[a]=this.rowLevels[a].concat(t[a-n]);if(this.table.find(".k-scheduler-times").last().find("tbody").append(this._times(t,i,this._isMobile()).find("tr")),this._updateDomRowLevels(),n>0)for(a=0;a<n;a++){var s=this.table.find("[data-row-level="+a+"]").last(),l=parseInt(s.attr("rowspan"),10)+i;s.attr("rowspan",l)}this._virtualContent(t,this.columnLevels),this.render(this._cachedEvents)},_tryRenderContent:function(){for(var e=this,t=e.table.innerHeight(),n=e.content.find("table").innerHeight(),i=e.content.scrollTop();e._hasContentToRender&&n-t<i;)e.createNextLayout(),n=e.content.find("table").innerHeight()},_isSchedulerHeightSet:function(){var e,t=this.element;return!!t[0].style.height||(e=t.height(),t.height("auto"),e!=t.height()?(t.height(""),!0):(t.height(""),!1))},_updateDomRowLevels:function(){var t=this.times.find(".k-group-cell:not([data-row-level])");if(this._rowLevelIndices){t=t.toArray().reverse();for(var n=0;n<=t.length;n++)e(t[n]).attr("data-row-level",this._rowLevelIndices[n])}else this._rowLevelIndices=t.map((function(t,n){return e(n).attr("data-row-level",t),t})).toArray().reverse()},refreshLayout:function(){for(var n=this,i=n.element.find("> .k-scheduler-toolbar"),r=n.element.innerHeight(),a=this._scrollbar,s=0,l=this._isRtl?"left":"right",c=0;c<i.length;c++)r-=o(i.eq(c));if(n.datesHeader&&(s=o(n.datesHeader)),n.timesHeader&&o(n.timesHeader)>s&&(s=o(n.timesHeader)),n.content&&n.content.find(".k-scheduler-table td").addClass("k-scheduler-cell"),n.datesHeader&&n.timesHeader){var d=n.datesHeader.find("table").first().find("tr");n.timesHeader.find("tr").height((function(t){e(this).height(d.eq(t).height())}))}s&&(r-=s),n.footer&&(r-=o(n.footer));var u=n.content[0],h=t.support.kineticScrollNeeded?0:a;if(this._isSchedulerHeightSet()&&(r>2*a?n.content.height(r):n.content.height(2*a+1),n.times)){n.times.height(u.clientHeight);var p=n.times.find("table");p.length&&p.height(n.content.find("table")[0].clientHeight)}n.table&&(u.offsetWidth-u.clientWidth>0?(n.table.addClass("k-scrollbar-v"),n.datesHeader.css("padding-"+l,h-parseInt(n.datesHeader.children().css("border-"+l+"-width"),10))):n.datesHeader.css("padding-"+l,"0"),u.offsetHeight-u.clientHeight>0||u.clientHeight>n.content.children(".k-scheduler-table").height()?n.table.addClass("k-scrollbar-h"):n.table.removeClass("k-scrollbar-h")),n._refreshResourceViews()},_topSection:function(t,n,i){var r=e("<tr class='k-scheduler-head'>");this.timesHeader=function(t,n,i){var r=[];if(i>0)for(var o=0;o<t;o++)r.push("<th class='k-scheduler-cell'>&#8203;</th>");return n&&r.push('<th class="k-scheduler-times-all-day k-scheduler-cell">'+n.text+"</th>"),i<1?e():e('<div class="k-scheduler-times">'+u(r)+"</div>")}(t.length,n,i),this.datesHeader=this._datesHeader(t,n);var o=this.datesHeader.find(".k-nav-day");return o.length&&o.closest("tr").addClass("k-scheduler-date-group"),this._isMobile()&&(r.addClass("k-mobile-header"),r.addClass("k-mobile-"+this._groupOrientation()+"-header")),e(r).append(this.timesHeader.add(this.datesHeader).wrap("<td>").parent())},_bottomSection:function(t,n){return this.times=this._times(t,n,this._isMobile()),this.content=e('<div class="k-scheduler-content"><table role="presentation" class="k-scheduler-table"></table></div>'),e("<tr class='k-scheduler-body'>").append(this.times.add(this.content).wrap("<td>").parent())},_scroller:function(){var n=this;this.content.on("scroll.kendoSchedulerView",(function(){t.scrollLeft(n.datesHeader.find(">.k-scheduler-header-wrap"),this.scrollLeft),n.times.scrollTop(this.scrollTop),n._isVirtualized()&&n._tryRenderContent()}));var i=t.touchScroller(this.content,{avoidScrolling:function(t){return e(t.event.target).closest(".k-event.k-event-active").length>0}});i&&i.movable&&(this._touchScroller=i,this.content=i.scrollElement,i.movable.bind("change",(function(e){t.scrollLeft(n.datesHeader.find(">.k-scheduler-header-wrap"),-e.sender.x),n.times.scrollTop(-e.sender.y),n._isVirtualized()&&n._tryRenderContent()})))},_resourcesForGroups:function(){var e=[],t=this.options.group,n=this.options.resources;if(t=t&&t.resources?t.resources:[],n&&t.length)for(var i=0,r=n.length;i<r;i++)for(var o=0,a=t.length;o<a;o++)n[i].name===t[o]&&e.push(n[i]);this.groupedResources=e},_createDateLayout:function(e,t,n){return C("rows",e,t,n)},_createColumnsLayout:function(e,t,n,i,r,o){return S("columns",e,t,n,i,r,o)},_groupOrientation:function(){var e=this.options.group;return e&&e.resources?e.orientation:"horizontal"},_isGroupedByDate:function(){return this.options.group&&this.options.group.date},_isVerticallyGrouped:function(){return this.groupedResources.length&&"vertical"===this._groupOrientation()},_createRowsLayout:function(e,t,n,i){return S("rows",e,t,n,i)},selectionByElement:function(){return null},clearSelection:function(){this.content.find(".k-selected").removeAttr("id").removeClass("k-selected")},destroy:function(){var e=this;r.fn.destroy.call(this),e._ongoingTimer&&(clearInterval(e._ongoingTimer),e._ongoingTimer=null),e.table&&(t.destroy(e.table),e.table.remove()),e.footer&&(e.footer.getKendoToolBar().destroy(),e.footer.remove()),e.groups=null,e.table=null,e.content=null,e.times=null,e.datesHeader=null,e.timesHeader=null,e.footer=null,e._resizeHint=null,e._moveHint=null},calendarInfo:function(){return t.getCulture().calendars.standard},prevGroupSlot:function(e,t,n){var i,r=this.groups[t],o=r.ranges(e,e,n,!1)[0].start;if(!(t<=0))return this._isGroupedByDate()?o:this._isVerticallyGrouped()?r.timeSlotCollectionCount()?(i=r._collection(n?o.index:o.collectionIndex,!1)).last():(i=r._collection(r.daySlotCollectionCount()-1,!0)).at(o.index):r.timeSlotCollectionCount()?(i=r._collection(n?0:r.timeSlotCollectionCount()-1,n),n?i.last():i.at(o.index)):(i=r._collection(o.collectionIndex,!0)).last()},nextGroupSlot:function(e,t,n){var i,r,o=this.groups[t],a=o.ranges(e,e,n,!1)[0].start;if(!(t>=this.groups.length-1))return this._isGroupedByDate()?a:this._isVerticallyGrouped()?o.timeSlotCollectionCount()?(r=o.daySlotCollectionCount(),i=o._collection(r?0:a.collectionIndex,r),n?i.first():i.at(a.collectionIndex)):(i=o._collection(0,!0)).at(a.index):o.timeSlotCollectionCount()?(i=o._collection(0,n),n?i.first():i.at(a.index)):(i=o._collection(a.collectionIndex,!0)).first()},_eventOptionsForMove:function(){return{}},_updateEventForResize:function(){},_updateEventForSelection:function(e){return e},_innerElements:function(e,t,n){var i=0,r=function(e){var o,a,s,l=e[n],c=e[t];if(l)i+=l;else if(c&&0!==c.length)for(s=0;s<c.length;s++)(a=(o=c[s])[t])&&a[0]?a[0][t]&&0!==a[0][t].length?r(o):i+=a.length:i+=1;else i+=1};return r(e),i},_times:function(t,n,i){for(var r,o=new Array(n).join().split(","),a=[],s=0;s<t.length;s++){var l=t[s],c=0;for(r=0;r<l.length;r++){var d=l[r],h=d.className||"",p=d.text,f=this._innerElements(d,"rows");c+=f,d.allDay&&(h="k-scheduler-times-all-day"),i&&-1!==h.indexOf("k-group-cell")&&(p='<span class="k-scheduler-group-text">'+p+"</span>"),o[c-f]+='<th class="k-scheduler-cell '+h+'" rowspan="'+f+'">'+p+"</th>"}}for(r=0;r<n;r++)a.push(o[r]);return n<1?e():e('<div class="k-scheduler-times">'+u(a)+"</div>")},_datesHeader:function(n,i){for(var r,o,a=[],s=0;s<n.length;s++){var l=n[s],c=[];for(r=0;r<l.length;r++){var d=l[r],h=this._innerElements(d,"columns","colspan");c.push('<th colspan="'+(d.colspan||h)+'" class="k-scheduler-cell '+(d.className||"")+'">'+d.text+"</th>")}a.push(c.join(""))}var p,f,m=[];if(i){var g=n[n.length-1],v=[],_=i.cellContent;for(r=0;r<g.length;r++)v.push('<td class="k-scheduler-cell '+(g[r].className||"")+'">'+(_?_(r):"&nbsp;")+"</td>");m.push(v.join(""))}return o=e('<div class="k-scheduler-header"><div class="k-scheduler-header-wrap">'+u(a)+(f="k-scheduler-header-all-day",((p=m).length?`<div ${t.attr("style-position")}="relative">${u(p,f)}</div>`:"")+"</div></div>")),t.applyStylesFromKendoAttributes(o,["position"]),o},_formatEventAriaLabel:function(e,n,i,r){var o,a=this.options.messages.ariaEventLabel,s=t.date.getDate(n).getTime()===t.date.getDate(i).getTime();return"string"==typeof a?t.format(a,e,n,n):(o=(a.prefix+c+e+c+a.on+c+t.toString(n,"D")).trim(),r&&s?o+c+a.allDay:r?o+c+a.to+c+t.toString(i,"D")+c+a.allDay:(o=o+c+a.at+c+t.toString(n,"t")+c+a.to+c,s?o+t.toString(i,"t"):o+t.toString(i,"D")+c+a.at+c+t.toString(i,"t")))},_ongoingEvents:function(e){var t,n=this,i=n.options.ongoingEvents;!!i&&(!0===i||i.enabled)&&(n._ongoingUpdater(e),t=i.updateInterval||6e4,n._ongoingTimer&&(clearInterval(n._ongoingTimer),n._ongoingTimer=null),isNaN(t)||(n._ongoingTimer=setInterval(this._ongoingUpdater.bind(n,e),t)))},_ongoingUpdater:function(e){var t=new Date,n=this.options.ongoingEvents.cssClass||s;this.content.find("."+n).removeClass(n),this.groups&&this.groups.length>0&&this._updateOngoing(t,e)},_updateOngoing:function(e,n){var i,r=this,o=r.element,a=r.options.ongoingEvents,l=a.cssClass||s,c=a.useLocalTimezone,d=r.options.timezone;n&&(!1===c&&d&&(i=t.timezone.offset(e,d),e=t.timezone.convert(e,e.getTimezoneOffset(),i)),n.forEach((t=>{var n,i=t.start,r=t.end;t.isAllDay&&(r=new Date(r.getTime()+864e5-1)),i<=e&&r>=e&&(n=t.uid,o.find("[data-uid="+n+"]").addClass(l))})))}});var k=function(e){var t,n,i,r,o,a=this,s=k.formats;if(1===arguments.length)for(e=a.resolveColor(e),r=0;r<s.length;r++)t=s[r].re,n=s[r].process,(i=t.exec(e))&&(o=n(i),a.r=o[0],a.g=o[1],a.b=o[2]);else a.r=arguments[0],a.g=arguments[1],a.b=arguments[2];a.r=a.normalizeByte(a.r),a.g=a.normalizeByte(a.g),a.b=a.normalizeByte(a.b)};function x(e){for(var t=[],n=0;n<e.length;n++){var i=e[n],r=w(i),o=null;i.zeroWidthEventOffset&&r.end-r.start<i.zeroWidthEventOffset&&(r.end=r.start+i.zeroWidthEventOffset);for(var a=0,s=t.length;a<s;a++){var l=r.start>t[a].end||r.slotIndex>t[a].slotIndexEnd;if(r.start<t[a].start||r.slotIndex<t[a].slotIndex||l){(o=t[a]).end<r.end&&(o.end=r.end),o.slotIndexEnd<r.slotIndexEnd&&(o.slotIndexEnd=r.slotIndexEnd);break}}o||(o={slotIndex:r.slotIndex,slotIndexEnd:r.slotIndexEnd,start:r.start,end:r.end,events:[]},t.push(o)),o.events.push(i)}return t}function C(t,n,i,r){var o=[];return e.each(n,(function(e,n){var a=n.className?"k-slot-cell "+n.className:"k-slot-cell",s={text:n.text,className:a};r&&!n.minorTicks?s[t]=C(t,n.columns,i,r):s[t]=i,o.push(s)})),o}function S(n,i,r,o,a,s,l){var c=i[0],d=[];if(c){if(a&&r)e.each(a,(function(e,t){s&&!t.minorTicks?t[n]=S(n,i,t.columns,o,t.columns,s,l):t[n]=S(n,i,null,o,null,null,l)})),d=a;else{var u=c.dataSource.view();u=u.filter((function(e){var n=t.getter(c.dataParentValueField)(e);return null==n||n===l}));for(var h=0;h<u.length;h++){var p=t.getter(c.dataValueField)(u[h]),f={text:o({text:t.htmlEncode(t.getter(c.dataTextField)(u[h])),color:t.getter(c.dataColorField)(u[h]),field:c.field,title:c.title,name:c.name,value:p}),className:"k-slot-cell k-group-cell",parentValue:l,value:p};f[n]=S(n,i.slice(1),r,o,a,s,p),d.push(f)}}return d}return r}k.prototype={resolveColor:function(e){return"#"==(e=e||"#000").charAt(0)&&(e=e.substr(1,6)),e=(e=e.replace(/ /g,"")).toLowerCase(),e=k.namedColors[e]||e},normalizeByte:function(e){return e<0||isNaN(e)?0:e>255?255:e},percBrightness:function(){var e=this;return l.sqrt(.241*e.r*e.r+.691*e.g*e.g+.068*e.b*e.b)},isDark:function(){return this.percBrightness()<180}},k.formats=[{re:/^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,process:function(e){return[parseInt(e[1],10),parseInt(e[2],10),parseInt(e[3],10)]}},{re:/^(\w{2})(\w{2})(\w{2})$/,process:function(e){return[parseInt(e[1],16),parseInt(e[2],16),parseInt(e[3],16)]}},{re:/^(\w{1})(\w{1})(\w{1})$/,process:function(e){return[parseInt(e[1]+e[1],16),parseInt(e[2]+e[2],16),parseInt(e[3]+e[3],16)]}}],k.namedColors={aqua:"00ffff",azure:"f0ffff",beige:"f5f5dc",black:"000000",blue:"0000ff",brown:"a52a2a",coral:"ff7f50",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgray:"a9a9a9",darkgreen:"006400",darkorange:"ff8c00",darkred:"8b0000",dimgray:"696969",fuchsia:"ff00ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lightblue:"add8e6",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumblue:"0000cd",navy:"000080",olive:"808000",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",pink:"ffc0cb",plum:"dda0dd",purple:"800080",red:"ff0000",royalblue:"4169e1",salmon:"fa8072",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",snow:"fffafa",steelblue:"4682b4",tan:"d2b48c",teal:"008080",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"};var T=/\s*k-selected/;e.extend(n.SchedulerView,{createColumns:function(e){return x(e)},createRows:function(e){return x(e)},rangeIndex:w,collidingEvents:function(e,t,n){var i,r,o,a;for(i=e.length-1;i>=0;i--)o=(r=w(e[i])).start,a=r.end,(o<=t&&a>=t||o>=t&&a<=n||t<=o&&n>=o)&&(o<t&&(t=o),a>n&&(n=a));return function(e,t,n){for(var i=[],r=0;r<e.length;r++){var o=w(e[r]);(o.start<t&&o.end>t||o.start>=t&&o.end<=n)&&i.push(e[r])}return i}(e,t,n)},groupEqFilter:function(e){return function(n){if(Array.isArray(n)||n instanceof t.data.ObservableArray){for(var i=0;i<n.length;i++)if(n[i]==e)return!0;return!1}return n==e}}})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=n.htmlEncode,o=n.date.setTime,a=i.SchedulerView,s=n._outerWidth,l=n._outerHeight,c=e.extend,d=n.date.getDate,u=n.date.MS_PER_MINUTE,h=n.date.MS_PER_DAY,p="k-current-time",f="k-current-time-arrow",m="k-event-inverse",g=n.date.getMilliseconds,v=".kendoMultiDayView",_=n.template((({start:e,end:t,title:i})=>`<div title="(${n.format("{0:t} - {1:t}",e,t)}): ${i.replace(/"/g,"&#34;")}"><div class="k-event-template k-event-time">${r(n.format("{0:t} - {1:t}",e,t))}</div><div class="k-event-template">${i}</div></div>`)),b=n.template((({start:e,title:t})=>`<div title="(${n.format("{0:t}",e)}): ${t.replace(/"/g,"&#34;")}"><div class="k-event-template">${t}</div></div>`)),y=n.template((({isMobile:e,date:t})=>`<span class='k-link k-nav-day'>${e?n.toString(t,"ddd")[0]:n.toString(t,"ddd M/dd")}</span>`)),w=e=>`<div role="button" aria-label="${r(e.ariaLabel)}" ${n.attr("uid")}="${e.uid}"`+(e.resources[0]?`${n.attr("style-background-color")}="${e.resources[0].color}" ${n.attr("style-border-color")}="${e.resources[0].color}"`:"")+' class="k-event"><span class="k-event-actions">'+(e.tail||e.middle?n.ui.icon("caret-alt-left"):"")+(e.isException()?n.ui.icon("arrows-no-repeat"):e.isRecurring()?n.ui.icon("arrow-rotate-cw"):"")+"</span>"+n.template(e.template)(e)+'<span class="k-event-actions">'+(e.showDelete?`<a href="#" class="k-link k-event-delete" title="${e.messages.destroy}" aria-label="${e.messages.destroy}">${n.ui.icon("x")}</a>`:"")+(e.head||e.middle?n.ui.icon("caret-alt-right"):"")+"</span>"+(!e.resizable||e.singleDay||e.tail||e.middle?"":'<span class="k-resize-handle k-resize-w"></span>')+(!e.resizable||e.singleDay||e.head||e.middle?"":'<span class="k-resize-handle k-resize-e"></span>')+"</div>",k=e=>`<div role="button" aria-label="${r(e.ariaLabel)}" ${n.attr("uid")}="${e.uid}"`+(e.resources[0]?`${n.attr("style-background-color")}="${e.resources[0].color}" ${n.attr("style-border-color")}="${e.resources[0].color}"`:"")+' class="k-event"><span class="k-event-actions">'+(e.isException()?n.ui.icon("arrows-no-repeat"):e.isRecurring()?n.ui.icon("arrow-rotate-cw"):"")+"</span>"+n.template(e.template)(e)+'<span class="k-event-actions">'+(e.showDelete?`<a href="#" class="k-link k-event-delete" title="${e.messages.destroy}" aria-label="${e.messages.destroy}">${n.ui.icon("x")}</a>`:"")+"</span>"+(e.tail||e.middle?'<span class="k-event-top-actions">'+n.ui.icon("caret-alt-up")+"</span>":"")+(e.head||e.middle?'<span class="k-event-bottom-actions">'+n.ui.icon("caret-alt-down")+"</span>":"")+(!e.resizable||e.tail||e.middle?"":'<span class="k-resize-handle k-resize-n"></span>')+(!e.resizable||e.head||e.middle?"":'<span class="k-resize-handle k-resize-s"></span>')+"</div>";function x(e){var t=new Date(1980,1,1,0,0,0);return o(t,g(e)),t}function C(e,t,n){return e>=t&&e<=n}function S(e,t,n,i){return i=i?e<=n:e<n,e>t&&i}function T(e,t,i,r){var o=e._continuousEvents,a=o[o.length-1],s=d(t.start.startDate()).getTime();if(r&&a&&d(a.start.startDate()).getTime()==s){for(var l=o.length-1;l>-1&&!(o[l].isAllDay||d(o[l].start.startDate()).getTime()<s);l--);o.splice(l+1,0,{element:i,isAllDay:!0,uid:i.attr(n.attr("uid")),start:t.start,end:t.end})}else o.push({element:i,isAllDay:r,uid:i.attr(n.attr("uid")),start:t.start,end:t.end})}var D=a.extend({init:function(e,t){var n=this;a.fn.init.call(n,e,t),n.title=n.options.title||n.options.name,n._workDays=function(e){if(e.workDays&&e.workDays.length)return e.workDays;var t=[],n=e.workWeekStart%7,i=Math.abs(e.workWeekEnd%7);for(t.push(n);i!=n;)n>6?n-=7:n++,t.push(n);return t}(n.options),n._templates(),n._editable(),n.calculateDateRange(),n._groups(),n._currentTime(!0)},_currentTimeMarkerUpdater:function(){this._updateCurrentTimeMarker(new Date)},_updateCurrentTimeMarker:function(t){var i,r,o,a,c=this.options,d="<div class='"+p+"'></div>";if(!1===c.currentTimeMarker.useLocalTimezone){var u=c.dataSource.options.schema.timezone;if(c.dataSource&&u){var h=n.timezone.offset(t,u);t=n.timezone.convert(t,t.getTimezoneOffset(),h)}}i=this.times.find("."+p),r=this.content.find("."+p);var m=c.group&&"horizontal"!=c.group.orientation?this.groups.length:1,g=this.times.find("tr").first().find("th").first(),v=this.times.find("tr").first().find("th").last();g.length>0&&v.length>0&&(a=this._isRtl?g.position().left+l(g)-l(v):v.position().left);for(var _=0;_<m;_++){var b=this.groups[_];if(!b)return;var y=n.date.toUtcTime(t),w=b.timeSlotRanges(y,y+1);if(0===w.length)return;if(w[0].collection.slotByStartDate(t)){var k=i[_]?i.eq(_):e(d).prependTo(this.times),x=Math.round(w[0].innerRect(t,new Date(t.getTime()+1),!1).top),C={};this._isRtl?(C.right=a,k.addClass(f+"-left")):(C.left=a,k.addClass(f+"-right")),o||(o=.8666*s(k)/2),C.top=x-o,k.css(C),(r[_]?r.eq(_):e(d).prependTo(this.content)).css({top:x,height:"1px",right:0,left:0})}}},_currentTime:function(e){var n=this,i=n.options.currentTimeMarker;!1!==i&&i.updateInterval!==t&&(n._currentTimeMarkerUpdater(),e&&(n._currentTimeUpdateTimer=setInterval(this._currentTimeMarkerUpdater.bind(n),i.updateInterval)))},_updateResizeHint:function(e,t,i,r){var o;o=this.options.enforceAllDaySlot?e.isMultiDay():e.isAllDay;var s,l,c,d,u=this.groups[t].ranges(i,r,o,e.isAllDay);this._removeResizeHint();for(var h=0;h<u.length;h++){var p=u[h],f=p.startSlot();if(this._isGroupedByDate()&&o)for(var m=f.index;m<=p.end.index;m++){var g=p.collection._slots[m];s=g.offsetWidth,l=g.clientHeight,c=g.offsetTop,d=a.fn._createResizeHint.call(this,g.offsetLeft,c,s,l),this._resizeHint=this._resizeHint.add(d)}else{if(s=f.offsetWidth,l=f.clientHeight,c=f.offsetTop,o)s=p.innerWidth();else{var v=p.outerRect(i,r,this.options.snap);c=v.top,l=v.bottom-v.top}d=a.fn._createResizeHint.call(this,f.offsetLeft,c,s,l),this._resizeHint=this._resizeHint.add(d)}}var _="t",b=this.content;o&&(_="M/dd",(b=this.element.find(".k-scheduler-header-wrap:has(.k-scheduler-header-all-day) > div")).length||(b=this.content)),this._resizeHint.appendTo(b),this._resizeHint.find(".k-label-top,.k-label-bottom").text(""),this._resizeHint.first().addClass("k-first").find(".k-label-top").text(n.toString(n.timezone.toLocalDate(i),_)),this._resizeHint.last().addClass("k-last").find(".k-label-bottom").text(n.toString(n.timezone.toLocalDate(r),_))},_updateMoveHint:function(t,i,r){var o;o=this.options.enforceAllDaySlot?t.isMultiDay():t.isAllDay;var a=this.groups[i],s=n.date.toUtcTime(t.start)+r,l=s+t.duration(),c=a.ranges(s,l,o,t.isAllDay);s=n.timezone.toLocalDate(s),l=n.timezone.toLocalDate(l),this._removeMoveHint(t.uid),!o&&g(l)<g(this.startTime())&&l<this._end().getTime()&&0!==g(l)&&c.length>1&&c.pop();for(var d=e(),u=0;u<c.length;u++){var h,p=c[u],f=p.start,v={left:f.offsetLeft+2,top:f.offsetTop};if(this._isGroupedByDate()&&o)for(var _=f.index;_<=p.end.index;_++){var b=p.collection._slots[_];v.left=this._isRtl?.1*b.clientWidth+b.offsetLeft+2:b.offsetLeft+2,v.height=b.offsetHeight,v.width=.9*b.clientWidth-2,h=this._createEventElement(t.clone({start:s,end:l}),!o),t.inverseColor&&h.addClass(m),this._appendMoveHint(h,v),d=d.add(h)}else{if(this._isRtl&&(v.left=.1*f.clientWidth+f.offsetLeft+2),o)v.width=p.innerWidth()-2;else{var y=p.outerRect(s,l,this.options.snap);v.top=y.top,v.height=y.bottom-y.top,v.width=.9*f.clientWidth-2}h=this._createEventElement(t.clone({start:s,end:l}),!o),t.inverseColor&&h.addClass(m),this._appendMoveHint(h,v),d=d.add(h)}}var w=this.content;o&&((w=this.element.find(".k-scheduler-header-wrap:has(.k-scheduler-header-all-day) > div")).length||(w=this.content)),d.appendTo(w)},_appendMoveHint:function(e,t){e.addClass("k-event-drag-hint"),e.css(t),this._moveHint=this._moveHint.add(e)},_slotByPosition:function(e,t){var n,i,r;for(this._isVerticallyGrouped()?(i=this.content.offset(),t+=this.content[0].scrollTop,e+=this.content[0].scrollLeft):i=this.element.find(".k-scheduler-header-wrap:has(.k-scheduler-header-all-day)").find(">div").offset(),i&&(e-=i.left,t-=i.top),e=Math.ceil(e),t=Math.ceil(t),r=0;r<this.groups.length;r++)if(n=this.groups[r].daySlotByPosition(e,t,this._isGroupedByDate()))return n;for(i&&(e+=i.left,t+=i.top),e-=(i=this.content.offset()).left,t-=i.top,this._isVerticallyGrouped()||(t+=this.content[0].scrollTop,e+=this.content[0].scrollLeft),e=Math.ceil(e),t=Math.ceil(t),r=0;r<this.groups.length;r++)if(n=this.groups[r].timeSlotByPosition(e,t))return n;return null},_groupCount:function(){var e=this.groupedResources,t=this._isGroupedByDate();return e.length?"vertical"===this._groupOrientation()?t?this._columnCountForLevel(e.length-1):this._rowCountForLevel(e.length-1):t?this._columnCountForLevel(e.length)/this._columnCountForLevel(0):this._columnCountForLevel(e.length)/this._columnOffsetForResource(e.length):1},_columnCountInResourceView:function(){var e=this.groupedResources,t=this._isGroupedByDate();return!e.length||this._isVerticallyGrouped()?t?this._rowCountForLevel(0):this._columnCountForLevel(0):t?this._columnCountForLevel(0):this._columnOffsetForResource(e.length)},_timeSlotGroups:function(e,t){var n,i,r,o,a=this._timeSlotInterval(),s=e,l=this._isGroupedByDate(),c=this.content.find("tr:not(.k-scheduler-header-all-day)"),d=c.length;this._isVerticallyGrouped()&&(l&&(s=t),d=Math.floor(d/s));for(var u=0;u<s;u++){var h=0,p=0;for(this._isVerticallyGrouped()?h=u:p=u,r=h*d;r<(h+1)*d;){var f=c[r].children;r%d==0&&(i=g(new Date(+this.startTime())));var m=0;if(l)if(this._isVerticallyGrouped())for(o=0;o<e;o++)n=this.groups[o],this._addTimeSlotGroup(n,f,o,i,a,u);else for(n=this.groups[u],o=p;o<e*t;o+=e)this._addTimeSlotGroup(n,f,o,i,a,m),m++;else for(n=this.groups[u],o=p*t;o<(p+1)*t;o++)this._addTimeSlotGroup(n,f,o,i,a,m),m++;i+=a,r++}}},_addTimeSlotGroup:function(e,t,n,i,r,o){var a=t[n],s=e.getTimeSlotCollection(o),l=this._dates[o];if(l&&a){var c=Date.UTC(l.getFullYear(),l.getMonth(),l.getDate())+i,d=c+r;s.addTimeSlot(a,c,d)}},_addDaySlotGroup:function(e,t,i,r,o){var a=t[i],s=this._dates[o];if(s){var l=Date.UTC(s.getFullYear(),s.getMonth(),s.getDate());e.addDaySlot(a,l,l+n.date.MS_PER_DAY)}},_daySlotGroups:function(e,t){var n,i,r=e,o=this._isGroupedByDate();this._isVerticallyGrouped()?(o&&(r=t),n=this.element.find(".k-scheduler-header-all-day")):n=this.element.find(".k-scheduler-header-all-day tr");for(var a=0;a<r;a++){var s,l=0;this._isVerticallyGrouped()&&(l=a);var c=n[l].children,d=0;this._isVerticallyGrouped()||(d=a);var u=0;if(o)if(this._isVerticallyGrouped())for(i=0;i<e;i++)s=this.groups[i].getDaySlotCollection(0),this._addDaySlotGroup(s,c,i,t,a);else for(s=this.groups[a].getDaySlotCollection(0),i=d;i<e*t;i+=e)this._addDaySlotGroup(s,c,i,t,u),u++;else for(s=this.groups[a].getDaySlotCollection(0),i=d*t;i<(d+1)*t;i++)this._addDaySlotGroup(s,c,i,t,u),u++}},_groups:function(){var e=this._groupCount(),t=this._columnCountInResourceView();this.groups=[];for(var i=0;i<e;i++){for(var r=this._addResourceView(i),o=0;o<t;o++)this._dates[o]&&r.addTimeSlotCollection(this._dates[o],n.date.addDays(this._dates[o],1));this.options.allDaySlot&&r.addDaySlotCollection(this._dates[0],n.date.addDays(this._dates[this._dates.length-1],1))}this._timeSlotGroups(e,t),this.options.allDaySlot&&this._daySlotGroups(e,t)},options:{name:"MultiDayView",selectedDateFormat:"{0:D}",selectedShortDateFormat:"{0:d}",selectedMobileDateFormat:"{0:MMM} {0:dd} - {1:dd}",allDaySlot:!0,showWorkHours:!1,title:"",startTime:n.date.today(),endTime:n.date.today(),minorTickCount:2,majorTick:60,majorTimeHeaderTemplate:({date:e})=>`<span>${n.toString(e,"t")}</span>`,minorTimeHeaderTemplate:()=>"&#8203;",groupHeaderTemplate:({text:e})=>e,slotTemplate:()=>"&nbsp;",allDaySlotTemplate:()=>"&nbsp;",eventTemplate:_,allDayEventTemplate:b,dateHeaderTemplate:y,editable:!0,workDayStart:new Date(1980,1,1,8,0,0),workDayEnd:new Date(1980,1,1,17,0,0),workWeekStart:1,workWeekEnd:5,footer:{command:"workDay"},messages:{allDay:"all day",showFullDay:"Show full day",showWorkDay:"Show business hours"},currentTimeMarker:{updateInterval:1e4,useLocalTimezone:!0},ongoingEvents:{cssClass:null,enabled:!0,updateInterval:6e4},enforceAllDaySlot:!1},events:["remove","add","edit"],_templates:function(){var e=this.options,t=c({},n.Template,e.templateSettings);this.allDayEventTemplate=n.template(w),this.eventTemplate=n.template(k),this.majorTimeHeaderTemplate=n.template(e.majorTimeHeaderTemplate,t),this.minorTimeHeaderTemplate=n.template(e.minorTimeHeaderTemplate,t),this.dateHeaderTemplate=n.template(e.dateHeaderTemplate,t),this.slotTemplate=n.template(e.slotTemplate,t),this.allDaySlotTemplate=n.template(e.allDaySlotTemplate,t),this.groupHeaderTemplate=n.template(e.groupHeaderTemplate,t)},_editable:function(){this.options.editable&&(this._isMobile()?this._touchEditable():this._mouseEditable())},_mouseEditable:function(){var t=this;t.element.on("click"+v,".k-event a:has(.k-i-x),.k-event a:has(.k-svg-i-x)",(function(i){t.trigger("remove",{uid:e(this).closest(".k-event").attr(n.attr("uid"))}),i.preventDefault()})),!1!==t.options.editable.create&&t.element.on("dblclick"+v,".k-scheduler-content > table td",(function(n){if(!e(this).parent().hasClass("k-scheduler-header-all-day")){var i=t._slotByPosition(n.pageX,n.pageY);if(i){var r=t._resourceBySlot(i);t.trigger("add",{eventInfo:c({start:i.startDate(),end:i.endDate()},r)})}n.preventDefault()}})).on("dblclick"+v,".k-scheduler-header-all-day td",(function(e){var i=t._slotByPosition(e.pageX,e.pageY);if(i){var r=t._resourceBySlot(i);t.trigger("add",{eventInfo:c({},{isAllDay:!0,start:n.date.getDate(i.startDate()),end:n.date.getDate(i.startDate())},r)})}e.preventDefault()})),!1!==t.options.editable.update&&t.element.on("dblclick"+v,".k-event",(function(i){t.trigger("edit",{uid:e(this).closest(".k-event").attr(n.attr("uid"))}),i.preventDefault()}))},_touchEditable:function(){var i=this,r=0;n.support.mobileOS.android&&(r=5),!1!==i.options.editable.create&&(i._addUserEvents=new n.UserEvents(i.element,{threshold:r,filter:".k-scheduler-content td",useClickAsTap:!n.support.browser.edge,tap:function(n){if(!i._scrolling&&!e(n.target).parent().hasClass("k-scheduler-header-all-day")){var r=n.x.location!==t?n.x.location:n.x,o=n.y.location!==t?n.y.location:n.y,a=i._slotByPosition(r,o);if(a){var s=i._resourceBySlot(a);i.trigger("add",{eventInfo:c({start:a.startDate(),end:a.endDate()},s)})}n.preventDefault()}}}),i._allDayUserEvents=new n.UserEvents(i.element,{threshold:r,useClickAsTap:!n.support.browser.edge,filter:".k-scheduler-header-all-day td",tap:function(e){if(!i._scrolling){var r=e.x.location!==t?e.x.location:e.x,o=e.y.location!==t?e.y.location:e.y,a=i._slotByPosition(r,o);if(a){var s=i._resourceBySlot(a);i.trigger("add",{eventInfo:c({},{isAllDay:!0,start:n.date.getDate(a.startDate()),end:n.date.getDate(a.startDate())},s)})}e.preventDefault()}}})),!1!==i.options.editable.update&&(i._editUserEvents=new n.UserEvents(i.element,{threshold:r,useClickAsTap:!n.support.browser.edge,filter:".k-event",tap:function(t){if(!i._scrolling){var r=e(t.target).closest(".k-event");e(t.touch.initialTouch).is(".k-i-x,.k-svg-i-x")?i.trigger("remove",{uid:r.attr(n.attr("uid"))}):r.hasClass("k-event-active")||i.trigger("edit",{uid:r.attr(n.attr("uid"))}),t.preventDefault()}}}))},_layout:function(e){for(var t=[],i=[],r=this.options,o=this,a=o._isGroupedByDate(),s=0;s<e.length;s++){var l={};l.text=o.dateHeaderTemplate({date:e[s],isMobile:o._isMobile()}),n.date.isToday(e[s])&&(l.className="k-today"),t.push(l)}var c=this.groupedResources;return r.allDaySlot&&i.push({text:r.messages.allDay,allDay:!0,cellContent:function(t){var n=t;return t=c.length&&"vertical"!==o._groupOrientation()?t%e.length:t,o.allDaySlotTemplate({date:e[t],resources:function(){return o._resourceBySlot({groupIndex:n})}})}}),this._forTimeRange(this.startTime(),this.endTime(),(function(e,t,n,r){var a={text:(t?o.majorTimeHeaderTemplate:o.minorTimeHeaderTemplate)({date:e}),className:r?"k-slot-cell":""};i.push(a)})),c.length&&("vertical"===this._groupOrientation()?a?(i=this._createDateLayout(t,i),t=this._createColumnsLayout(c,null,this.groupHeaderTemplate)):i=this._createRowsLayout(c,i,this.groupHeaderTemplate):t=a?this._createColumnsLayout(c,t,this.groupHeaderTemplate,t):this._createColumnsLayout(c,t,this.groupHeaderTemplate)),{columns:t,rows:i}},toggleFullDay:function(){var e=this.options;this.trigger("navigate",{view:this.name||e.name,date:e.date,isWorkDay:!e.showWorkHours})},_footerItems:function(){var e=this,t=[],n=this.options.footer.command;return e._isMobile()&&t.push(e._defaultTools.todayMobile),n&&"workDay"===n&&(e._isMobile()?t.push(e._defaultTools.fulldayMobile):t.push(e._defaultTools.fulldayDesktop)),t},_forTimeRange:function(e,t,n,i){e=x(e),t=x(t);var r,a,s=g(e),l=g(t),c=this.options.minorTickCount,d=this.options.majorTick*u,p=d/c||1,f=new Date(+e),m=f.getDate(),v=0,_="";for(a=h/p,s!=l&&(s>l&&(l+=h),a=(l-s)/p),a=Math.round(a);v<a;v++){var b=v%(d/p);_+=n(f,0===b,b<c-1,b===c-1),o(f,p,!1)}return l&&(r=g(f),m<f.getDate()&&(r+=h),r>l&&(f=new Date(+t))),i&&(_+=i(f)),_},_content:function(e){var t=this,n="";n+="<tbody>",n+=t._renderRows(e,t.rowLevels,t.columnLevels),n+="</tbody>",this.content.find("table").append(n)},_virtualContent:function(e,t){var n=this,i="",r=n._dates;i+=n._renderRows(r,e,t),n.content.find("table tbody").append(i)},_renderRows:function(e,t,n){var i=this,r="vertical"===i._groupOrientation(),o=i._isGroupedByDate(),a=0,s=e.length,l=i.options,c=i.startTime(),d=this.endTime(),u=1,h=1,p="";if(this.groupedResources.length){var f=i._recalculateLevels(t,n);h=f.rowCount,u=f.groupsCount}for(var m=function(t,n,l){var c,d,h="",p=0;if(h="<tr"+(l?' class="k-middle-row"':"")+">",o)for(c=0,d=s;c<d;c++){for(p=0;p<u;p++){var f=c;r&&(f=a),h=i._addCellsToContent(h,e,t,f,p,g)}if(r)break}else for(;p<u;p++)for(c=0,d=s;c<d;c++)h=i._addCellsToContent(h,e,t,c,p,g);return h+="</tr>"},g=0;g<h;g++)p+=l.allDaySlot&&r?this._allDayVerticalGroupRow(e,g,u,a):"",p+=this._forTimeRange(c,d,m),r&&a++;return p},_recalculateLevels:function(e,t){var n=this,i=n._isGroupedByDate(),r=1,o=1;return"vertical"===n._groupOrientation()?(o=n._rowCountForLevel(e.length-2,e),i&&(r=n._columnCountForLevel(t.length-1))):r=i?n._columnCountForLevel(t.length-1)/this._columnCountForLevel(0):n._columnCountForLevel(t.length-2),{rowCount:o,groupsCount:r}},_allDayVerticalGroupRow:function(e,t,n,i){var r=this,o='<tr class="k-scheduler-header-all-day">',a=r._isGroupedByDate(),s=a?0:t,l=r.allDaySlotTemplate,c=function(){return r._resourceBySlot({groupIndex:s})};if(a)for(;s<n;s++)o+="<td>"+l({date:e[i],resources:c})+"</td>";else for(var d=0;d<e.length;d++)o+="<td>"+l({date:e[d],resources:c})+"</td>";return o+"</tr>"},_addCellsToContent:function(e,t,i,r,o,a){var s,l,c=this,d="",u=this.slotTemplate,h="vertical"===this._groupOrientation();return n.date.isToday(t[r])&&(d+="k-today"),(n.date.getMilliseconds(i)<n.date.getMilliseconds(this.options.workDayStart)||n.date.getMilliseconds(i)>=n.date.getMilliseconds(this.options.workDayEnd)||!this._isWorkDay(t[r]))&&(d+=" k-nonwork-hour"),e+="<td"+(""!==d?' class="'+d+'"':"")+">",s=n.date.getDate(t[r]),n.date.setTime(s,n.date.getMilliseconds(i)),e+=u({date:s,resources:(l=h&&!c._isGroupedByDate()?a:o,function(){return c._resourceBySlot({groupIndex:l})})}),e+="</td>"},_isWorkDay:function(e){for(var t=e.getDay(),n=this._workDays,i=0;i<n.length;i++)if(n[i]===t)return!0;return!1},_render:function(t){var n=this;t=t||[],this._dates=t,this._startDate=t[0],this._endDate=t[t.length-1||0],this.createLayout(this._layout(t)),this._content(t),this._footer(),this.refreshLayout(),this._isVirtualized()&&this._tryRenderContent();var i=this.element.find(".k-scheduler-header-all-day td");i.length&&(this._allDayHeaderHeight=i.first()[0].clientHeight),n.element.on("click"+v,".k-nav-day",(function(t){var i=e(t.currentTarget).closest("th"),r=i.offset(),o=0,a=l(i);n._isGroupedByDate()&&(n._isVerticallyGrouped()?(o=s(n.times),a=0):a=l(n.datesHeader));var c=n._slotByPosition(r.left+o,r.top+a);n.trigger("navigate",{view:"day",date:c.startDate()})}))},startTime:function(){var e=this.options;return e.showWorkHours?e.workDayStart:e.startTime},endTime:function(){var e=this.options;return e.showWorkHours?e.workDayEnd:e.endTime},startDate:function(){return this._startDate},endDate:function(){return this._endDate},_end:function(e){var t=g(this.endTime())||h;return e&&(t=0),new Date(this._endDate.getTime()+t)},nextDate:function(){return n.date.nextDay(this.endDate())},previousDate:function(){return n.date.previousDay(this.startDate())},calculateDateRange:function(){this._render([this.options.date])},destroy:function(){var e=this;e._currentTimeUpdateTimer&&clearInterval(e._currentTimeUpdateTimer),e.datesHeader&&e.datesHeader.off(v),e.element&&e.element.off(v),a.fn.destroy.call(this),this._isMobile()&&e.options.editable&&(!1!==e.options.editable.create&&(e._addUserEvents.destroy(),e._allDayUserEvents.destroy()),!1!==e.options.editable.update&&e._editUserEvents.destroy())},inRange:function(e){var t=a.fn.inRange.call(this,e);if(e.isAllDay)return t;var i=g(this.startTime()),r=g(this.endTime())||n.date.MS_PER_DAY,o=g(e.start),s=g(e.end)||n.date.MS_PER_DAY;return t&&i<=o&&s<=r},selectionByElement:function(e){var t=e.offset(),n=Math.round(e.innerHeight())-5;return this._slotByPosition(t.left,t.top+n)},_timeSlotInterval:function(){var e=this.options;return e.majorTick/e.minorTickCount*u},_timeSlotIndex:function(e){var t=this.options;return(g(e)-g(this.startTime()))/(t.majorTick/t.minorTickCount*u)},_slotIndex:function(e,t){return t?this._dateSlotIndex(e):this._timeSlotIndex(e)},_dateSlotIndex:function(e,t){var i,r,o=this._dates||[];for(i=0,r=o.length;i<r;i++)if(C(e,n.date.getDate(o[i]),new Date(n.date.getDate(o[i]).getTime()+h-(t?0:1))))return 1*i;return-1},_positionAllDayEvent:function(t,n){var i=n.innerWidth(),r=n.start.index,o=n.end.index,s=a.collidingEvents(n.events(),r,o),l=this._headerColumnCount||0,c=r!==o?3:2,d=this._allDayHeaderHeight,u=n.startSlot();t.css({left:u.offsetLeft+2,width:i-c}),n.addEvent({slotIndex:r,start:r,end:o,element:t}),s.push({slotIndex:r,start:r,end:o,element:t});var h=a.createRows(s);h.length&&h.length>l&&(this._headerColumnCount=h.length);for(var p=n.start.offsetTop,f=0,m=h.length;f<m;f++)for(var g=h[f].events,v=0,_=g.length;v<_;v++)e(g[v].element).css({top:p+f*d,height:d-2})},_arrangeColumns:function(e,t,n,i){var r=i.start;e={element:e,slotIndex:r.index,start:t,end:t+n};var o,s,l=r.clientWidth,c=.1*l,d=i.events(),u=a.collidingEvents(d,e.start,e.end),h=this.table.find(".k-scheduler-content .k-scheduler-table")[0],p=this.table.find(".k-scheduler-content")[0];i.addEvent(e),u.push(e);for(var f=(l-c)/(o=a.createColumns(u)).length,m=0,g=o.length;m<g;m++)for(var v=0,_=(s=o[m].events).length;v<_;v++){var b=f-2;s[v].element[0].style.width=(b>0?b:f)+"px",this._isRtl&&p.clientWidth<p.scrollWidth?s[v].element[0].style.left=c+r.offsetLeft+m*f-(h.clientWidth-p.clientWidth)+"px":s[v].element[0].style.left=(this._isRtl?c:0)+r.offsetLeft+m*f+2+"px"}},_positionEvent:function(e,t,i){var r=e._startTime||e.start,o=e._endTime||e.end,a=n.getComputedStyles(i.start.element,["border-top-width","border-bottom-width"]),s=i.innerRect(r,o,!1),l=s.bottom-s.top-parseFloat(a["border-top-width"])-parseFloat(a["border-bottom-width"]);l<0&&(l=0),t.css({top:s.top,height:l}),this._arrangeColumns(t,s.top,t[0].clientHeight,i)},_createEventElement:function(t,i,r,o){var a,s=i?this.eventTemplate:this.allDayEventTemplate,l=this.options,u=l.editable,p=this._isMobile(),f=u&&!1!==u.destroy&&!p,m=u&&!1!==u.resize,v=d(this.startDate()),_=d(this.endDate()),b=g(this.startTime()),y=g(this.endTime()),w=t._time("start"),k=t._time("end"),x=i?l.eventTemplate:l.allDayEventTemplate;b>=y&&(y=g(new Date(this.endTime().getTime()+h-1))),i||t.isAllDay||(_=new Date(_.getTime()+h));var S=t.start,T=t.end;t.isAllDay&&(T=d(t.end)),!C(d(S),v,_)&&!C(T,v,_)||i&&t.start.getTime()!==t.end.getTime()&&(w<b||w>=y)&&(k>y||k<=b)?a=!0:d(S)<v||i&&0!==w&&t.start.getTime()!==t.end.getTime()&&(w<b||w>=y)?o=!0:(T>_&&!i||i&&0!==k&&t.start.getTime()!==t.end.getTime()&&(k>y||k<=b))&&(r=!0);var D=this.eventResources(t);t._startTime&&w!==n.date.getMilliseconds(t.start)&&(S=new Date(w),S=n.timezone.apply(S,"Etc/UTC")),t._endTime&&k!==n.date.getMilliseconds(t.end)&&(T=new Date(k),T=n.timezone.apply(T,"Etc/UTC"));var A=c({},{ns:n.ns,resizable:m,showDelete:f,middle:a,head:r,tail:o,singleDay:1==this._dates.length,resources:D,inverseColor:!1,messages:l.messages,ariaLabel:this._formatEventAriaLabel(t.title,S,T,t.isAllDay),template:x},t,{start:S,end:T}),M=e(s(A));return n.applyStylesFromKendoAttributes(M,["background-color","border-color"]),M},_isInTimeSlot:function(e){var t=this.startTime(),i=this.endTime(),r=e._startTime||e.start,a=e._endTime||e.end;if(g(i)===g(n.date.getDate(i))&&(i=n.date.getDate(i),o(i,h-1)),e._date("end")>e._date("start")&&(a=+e._date("end")+(h-1)),a=e._endTime?a-e._date("end"):g(new Date(a)),r=e._startTime?r-e._date("start"):g(new Date(r)),i=g(i),(t=g(t))===r&&r===a)return!0;var s=r!==i;return S(r,t,i,s)||S(a,t,i,s)||S(t,r,a)||S(i,r,a)||e.end.getDate()>e.start.getDate()&&a>t},_isInDateSlot:function(e){var t=this.groups[0],i=t.firstSlot().start,r=t.lastSlot().end-1,o=n.date.toUtcTime(e.start),a=n.date.toUtcTime(e.end);return(C(o,i,r)||C(a,i,r)||C(i,o,a)||C(r,o,a))&&(!C(a,i,i)||C(a,o,o)||e.isAllDay)},_updateAllDayHeaderHeight:function(e){if(this._height!==e){this._height=e;var t=this.element.find(".k-scheduler-header-all-day td");if(t.length){t.parent().add(this.element.find(".k-scheduler-times-all-day").parent()).height(e);for(var n=0;n<this.groups.length;n++)this.groups[n].refresh()}}},_renderEvents:function(e,t){var i,r,o,a=this.datesHeader.find(".k-scheduler-header-wrap > div"),s=this._isGroupedByDate();for(r=0,o=e.length;r<o;r++){var l,c,d,u,p,f,m,g;if(i=e[r],this._isInDateSlot(i))if(c=(l=this.options.enforceAllDaySlot?i.isAllDay||i.duration()>=h:i.isAllDay)&&!this._isVerticallyGrouped()?a:this.content,l){if(this.options.allDaySlot){if(!(g=this.groups[t]))continue;if(g._continuousEvents||(g._continuousEvents=[]),(u=g.slotRanges(i)).length){var v=(p=u[0]).start.index,_=p.end.index;if(s&&v!==_){f=p.start.start,m=p.end.end;for(var b=f,y=f,w=p.start.index;w<=p.end.index;w++){d=this._createEventElement(i,!l,w!==_,w!==v);var k=g.daySlotRanges(b,y,!0)[0];b=y+=n.date.MS_PER_DAY,this._positionAllDayEvent(d,k),T(g,k,d,!0),d.appendTo(c),this._inverseEventColor(d)}}else d=this._createEventElement(i,!l),this._positionAllDayEvent(d,u[0]),T(g,u[0],d,!0),d.appendTo(c),this._inverseEventColor(d)}}}else if(this._isInTimeSlot(i)){if(!(g=this.groups[t]))continue;g._continuousEvents||(g._continuousEvents=[]);for(var x=(u=g.slotRanges(i)).length,C=0;C<x;C++){p=u[C],f=i.start,m=i.end,x>1&&(0===C?m=p.end.endDate():C==x-1?f=p.start.startDate():(f=p.start.startDate(),m=p.end.endDate()));var S=i.clone({start:f,end:m,_startTime:i._startTime,_endTime:i.endTime});if(this._isInTimeSlot(S)){var D=p.head;(d=this._createEventElement(i,!l,D,p.tail)).appendTo(c),this._inverseEventColor(d),this._positionEvent(S,d,p),T(g,p,d,!1)}}}}},_eventsPerDate:function(t,n){let i=this;return e.map(t,(function(t){return e.grep(t,(function(e){return i.options.enforceAllDaySlot?e.isMultiDay()&&C(n,d(e.start),d(e.end)):e.isAllDay&&C(n,d(e.start),d(e.end))})).length}))},render:function(t){var i=this;this._headerColumnCount=0,this._cachedEvents=t,this._groups(),this.element.find(".k-event").remove(),t=new n.data.Query(t).sort([{field:"start",dir:"asc"},{field:"end",dir:"desc"}]).toArray();var r=[];this._eventsByResource(t,this.groupedResources,r);var o=e.map(this._dates,(function(e){return Math.max.apply(null,i._eventsPerDate(r,e))})),a=Math.max.apply(null,o);this._updateAllDayHeaderHeight((a+1)*this._allDayHeaderHeight);for(var s=0;s<r.length;s++)this._renderEvents(r[s],s);this.refreshLayout(),this._currentTime(!1),this._ongoingEvents(t),this.trigger("activate")},_eventsByResource:function(e,i,r,o){var s=i[0];if(s){var l=s.dataSource.view();l=l.filter((function(e){var i=n.getter(s.dataParentValueField)(e);return null===i||i===t||i===o}));for(var c=0;c<l.length;c++){var d=this._resourceValue(s,l[c]),u=new n.data.Query(e).filter({field:s.field,operator:a.groupEqFilter(d)}).toArray();i.length>1?this._eventsByResource(u,i.slice(1),r,d):r.push(u)}}else r.push(e)},_columnOffsetForResource:function(e){return this._columnCountForLevel(e)/this._columnCountForLevel(e-1)},_columnCountForLevel:function(e){var t=this.columnLevels[e];return t?t.length:0},_rowCountForLevel:function(e,t){var n=(t=t||this.rowLevels)[e];return n?n.length:0},clearSelection:function(){this.content.add(this.datesHeader).find(".k-selected").removeAttr("id").removeClass("k-selected")},_updateDirection:function(e,t,n,i,r){var o=e.isAllDay,a=t[0].start,s=t[t.length-1].end;n&&(r?o||a.index!==s.index||a.collectionIndex!==s.collectionIndex||(e.backward=i):(o&&a.index===s.index||!o&&a.collectionIndex===s.collectionIndex)&&(e.backward=i))},_changeViewPeriod:function(e,t,n){if(!n){var i,r,a,s=t?this.previousDate():this.nextDate(),l=e.start,c=e.end,d=this._isGroupedByDate()&&this._isVerticallyGrouped(),u=this.groups[e.groupIndex],p=t?u._timeSlotCollections:u._getCollections(u.daySlotCollectionCount()),f=p[p.length-1]._slots,m=t||u.daySlotCollectionCount()?f.length-1:0;if(r=new Date(s),a=new Date(s),this._isInRange(r,a))return!1;if(e.start=r,e.end=a,d){var v=new Date(f[m].startDate()),_=new Date(f[m].endDate());i=g(_)?g(_):h,o(e.start,g(v)),o(e.end,i),u.daySlotCollectionCount()&&(e.isAllDay=!e.isAllDay)}else i=e.isAllDay||!g(c)?h:g(c),o(e.start,g(l)),o(e.end,i);return this._isVerticallyGrouped()||(e.groupIndex=t?this.groups.length-1:0),e.events=[],!0}}});c(!0,i,{MultiDayView:D,DayView:D.extend({options:{name:"DayView",title:"Day",selectedMobileDateFormat:"{0:MMM d}"},name:"day"}),WeekView:D.extend({options:{name:"WeekView",title:"Week",selectedDateFormat:"{0:D} - {1:D}",selectedShortDateFormat:"{0:d} - {1:d}"},name:"week",calculateDateRange:function(){var e,t=this.options.date,i=n.date.dayOfWeek(t,this.calendarInfo().firstDay,-1),r=[];for(e=0,7;e<7;e++)r.push(i),i=n.date.nextDay(i);this._render(r)}}),WorkWeekView:D.extend({options:{name:"WorkWeekView",title:"Work Week",selectedDateFormat:"{0:D} - {1:D}",selectedShortDateFormat:"{0:d} - {1:d}"},name:"workWeek",nextDate:function(){var e=n.date.dayOfWeek(n.date.nextDay(this.startDate()),this.calendarInfo().firstDay,1);return n.date.addDays(e,this._workDays[0])},previousDate:function(){var e=n.date.dayOfWeek(this.startDate(),this.calendarInfo().firstDay,-1),t=this._workDays;return n.date.addDays(e,t[t.length-1]-7)},calculateDateRange:function(){var e=this.options,t=e.date,i=n.date.dayOfWeek,r=i(t,this.calendarInfo().firstDay,-1),o=i(r,e.workWeekStart,1),a=i(o,e.workWeekEnd,1),s=[],l=e.workDays&&e.workDays.length?e.workDays.map((function(e){return i(r,e,1).getTime()})):null;for(l&&(a=i(o=r,this.calendarInfo().firstDay+6,1));o<=a;)l&&l.indexOf(o.getTime())>-1?s.push(o):l||s.push(o),o=n.date.nextDay(o);this._render(s)}})})}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=t.htmlEncode,r=".kendoAgendaView",o="role",a=e=>`<div class="k-task" title="${i((e.title||"").replace(/"/g,"'"))}" ${t.attr("uid")}="${e.uid}">`+(e.resources[0]?`<span class="k-scheduler-mark" ${t.attr("style-background-color")}="${e.resources[0].color}"></span>`:"")+`${e.isException()?t.ui.icon("arrows-no-repeat"):e.isRecurring()?t.ui.icon("arrow-rotate-cw"):""}`+`<span class="k-scheduler-task-text">${t.template(e.template)(e)}</span>`+(e.showDelete?`<a href="#" class="k-link k-event-delete" title="${e.messages.destroy}" aria-label="${e.messages.destroy}">${t.ui.icon("x")}</a>`:"")+"</div>",s=t.Class.extend({init:function(e){this._view=e},_getColumns:function(e,t){return e.concat(t)},_getGroupsInDay:function(){return[]},_getSumOfItemsForDate:function(){return 0},_renderTaskGroupsCells:function(e,t,n,i){var r=this._view;0===n&&0===i&&t.length&&r._renderTaskGroupsCells(e,t)},_renderDateCell:function(e,n,i,r,o,a){var s=this._view,l=s._isMobile();e.push(t.format('<td class="k-scheduler-datecolumn{3}{2}" rowspan="{0}">{1}</td>',i.length,s._dateTemplate({date:r,isMobile:l}),n.length?"":" k-first"))},_renderDates:function(){},_getParents:function(e){return e.splice(0)},_getGroupsByDate:function(){},_renderTaskGroups:function(e,t,n){var i=this._view;e.append(i._renderTaskGroups(t,n))}}),l=t.Class.extend({init:function(e){this._view=e},_getColumns:function(e,t){if(this._view._isMobile())return e.concat(t);var n=t.slice(0,1),i=t.slice(1);return n.concat(e).concat(i)},_compareDateGroups:function(e,t,n){return e[n].text==t[n].text&&(0===n||this._compareDateGroups(e,t,n-1))},_getGroupsInDay:function(e,t){for(var n=[],i=null,r=0;r<e.length;r++)for(var o=0;o<e[r].items.length;o++){var a=0;if(0===n.length)for(;a<t[r].length;a++)n.push([1]);else for(;a<t[r].length;a++)if(this._compareDateGroups(t[r],i,a))n[a][n[a].length-1]++;else{for(var s=n[a][n[a].length-1]-1,l=0;l<s;l++)n[a].push(0);n[a].push(1)}i=t[r]}return n},_getSumOfItemsForDate:function(e){for(var t=0,n=0;n<e.length;n++)t+=e[n].items.length;return t},_renderTaskGroupsCells:function(e,n,i,r,o,a,s,l){var c=this._view,d=c._isMobile();if(d)0===i&&0===r&&n.length&&c._renderTaskGroupsCells(e,n);else{0===i&&0===r&&e.push(t.format('<td class="k-scheduler-datecolumn k-first" rowspan="{0}">{1}</td>',a,c._dateTemplate({date:s,isMobile:d})));for(var u=0;u<n[i].length;u++)o[u][l]&&e.push(t.format('<td class="k-scheduler-groupcolumn" rowspan="{0}">{1}</td>',o[u][l],c._groupTemplate({value:n[i][u].text,isMobile:d}),n[i][u].className))}},_renderDateCell:function(){},_renderDates:function(e){for(var t=this._view,n=t._groupsByDate.sort((function(e,t){return e.array[0].value.getTime()-t.array[0].value.getTime()})),i=0;i<n.length;i++)e.append(t._renderTaskGroups(n[i].array,n[i].groups))},_getParents:function(e){return e.slice(0)},_getGroupsByDate:function(e,t,n){var i=this._view;if(e[t].items)for(var r=0;r<e[t].items.length;r++){for(var o=e[t].items[r].value,a=!1,s=0;s<i._groupsByDate.length;s++)i._groupsByDate[s].array[0].value.getTime()===o.getTime()&&(a=!0,i._groupsByDate[s].array.push(e[t].items[r]),i._groupsByDate[s].groups.push(n));a||i._groupsByDate.push({array:[e[t].items[r]],groups:[n]})}},_renderTaskGroups:function(){}});function c(e){for(var t=0,n=0,i=e.length;n<i;n++)t+=e[n].items.length;return t}function d(e,n){return e.valuePrimitive&&(n=t.getter(e.dataValueField)(n)),n}function u(e){for(var t=[].concat(e),n=t.shift(),i=[],r=[].push;n;)n.groups?r.apply(t,n.groups):n.items?r.apply(t,n.items):r.call(i,n),n=t.shift();return i}t.ui.scheduler.AgendaGroupedView=s,t.ui.scheduler.AgendaGroupedByDateView=l,n.AgendaView=n.SchedulerView.extend({init:function(i,o){n.SchedulerView.fn.init.call(this,i,o),this._groupedView=this._getGroupedView(),(o=this.options).editable&&(o.editable=e.extend({delete:!0},o.editable,{create:!1,update:!1},{messages:o.messages})),this.title=o.title,this._eventTemplate=t.template(a),this._dateTemplate=t.template(o.eventDateTemplate),this._groupTemplate=t.template(o.eventGroupTemplate),this._timeTemplate=t.template(o.eventTimeTemplate),this.element.on("mouseenter"+r,".k-scheduler-content tr","_mouseenter").on("mouseleave"+r,".k-scheduler-content tr","_mouseleave").on("click"+r,".k-scheduler-content .k-link:has(.k-i-x),.k-scheduler-content .k-link:has(.k-svg-i-x)","_remove"),this._renderLayout(o.date),this.refreshLayout()},name:"agenda",_aria:function(){var e=this.table;e.attr(o,"grid"),e.children("tbody").attr(o,"none"),e.find("table").attr(o,"none"),e.find("table > tbody").attr(o,"rowgroup"),e.find("table tr").attr(o,"row"),e.find("table td").attr(o,"gridcell"),e.find(".k-scheduler-header-wrap th").attr(o,"columnheader"),e.find(".k-scheduler-content .k-scheduler-datecolumn, .k-scheduler-content .k-scheduler-groupcolumn").attr(o,"rowheader")},clearSelection:function(){this.element.find(".k-selected").attr("aria-selected",!1),t.ui.SchedulerView.fn.clearSelection.call(this)},_isVirtualized:function(){return!1},_getGroupedView:function(){return this._isGroupedByDate()?new t.ui.scheduler.AgendaGroupedByDateView(this):new t.ui.scheduler.AgendaGroupedView(this)},_mouseenter:function(t){e(t.currentTarget).addClass("k-hover")},_mouseleave:function(t){e(t.currentTarget).removeClass("k-hover")},_remove:function(n){n.preventDefault(),this.trigger("remove",{uid:e(n.currentTarget).closest(".k-task").attr(t.attr("uid"))})},nextDate:function(){return t.date.nextDay(this.startDate())},startDate:function(){return this._startDate},endDate:function(){return this._endDate},previousDate:function(){return t.date.previousDay(this.startDate())},_renderLayout:function(e){this._startDate=e,this._endDate=t.date.addDays(e,7),this.createLayout(this._layout()),this._footer()},_layout:function(){var e=[{text:this.options.messages.time,className:"k-scheduler-timecolumn"},{text:this.options.messages.event}];this._isMobile()||e.splice(0,0,{text:this.options.messages.date,className:"k-scheduler-datecolumn"});var t=this.groupedResources;if(t.length){for(var n=[],i=0;i<t.length;i++)n.push({text:"",className:"k-scheduler-groupcolumn"});e=this._groupedView._getColumns(n,e)}return{columns:e}},_tasks:function(e){for(var n=[],i=0;i<e.length;i++){var r=e[i],o=r.start,a=r.isAllDay?t.date.getDate(r.end):r.end,s=t.date.getDate(o),l=6e4*(s.getTimezoneOffset()-a.getTimezoneOffset()),c=Math.ceil((a-s+l)/t.date.MS_PER_DAY);r.isAllDay&&(c+=1);var d=r.clone();if(d.startDate=t.date.getDate(o),d.startDate>=this.startDate()&&n.push(d),c>1){d.end=t.date.nextDay(o),d.head=!0;for(var u=1;u<c;u++)o=d.end,(d=r.clone()).start=d.startDate=t.date.getDate(o),d.end=t.date.nextDay(o),u==c-1?(d.end=new Date(d.start.getFullYear(),d.start.getMonth(),d.start.getDate(),a.getHours(),a.getMinutes(),a.getSeconds(),a.getMilliseconds()),d.tail=!0):(d.isAllDay=!0,d.middle=!0),(t.date.getDate(d.end)<=this.endDate()&&d.start>=this.startDate()||t.date.getDate(d.start).getTime()==this.endDate().getTime())&&n.push(d)}}return new t.data.Query(n).sort([{field:"start",dir:"asc"},{field:"end",dir:"asc"}]).groupBy({field:"startDate"}).toArray()},_renderTaskGroups:function(e,n){for(var i=[],r=this.options.editable,o=r&&!1!==r.destroy&&!this._isMobile(),a=this._isMobile(),s=this._groupedView._getSumOfItemsForDate(e),l=this._groupedView._getGroupsInDay(e,n),c=0,d=0;d<e.length;d++)for(var u=e[d].value,h=e[d].items,p=t.date.isToday(u),f=0;f<h.length;f++){var m=h[f],g=[],v=a?[]:g;this._groupedView._renderTaskGroupsCells(v,n,d,f,l,s,u,c),c++,0===f&&(a?(v.push(t.format('<td class="k-scheduler-datecolumn {1}" colspan="2">{0}</td>',this._dateTemplate({date:u,isMobile:a}),this.groupedResources.length?"":"k-first")),i.push('<tr role="row" aria-selected="false"'+(p?' class="k-today">':">")+v.join("")+"</tr>")):this._groupedView._renderDateCell(g,n,h,u,d,e)),m.head?m.format="{0:t}":m.tail?m.format="{1:t}":m.format="{0:t}-{1:t}",m.resources=this.eventResources(m),g.push(t.format('<td class="k-scheduler-timecolumn {4}"><div>{0}{1}{2}</div></td><td>{3}</td>',m.tail||m.middle?t.ui.icon("caret-alt-left"):"",this._timeTemplate(m.clone({start:m._startTime||m.start,end:m.endTime||m.end,messages:this.options.messages})),m.head||m.middle?t.ui.icon("caret-alt-right"):"",this._eventTemplate(m.clone({showDelete:o,messages:this.options.messages,template:this.options.eventTemplate})),!this.groupedResources.length&&a?"k-first":"")),i.push('<tr role="row" aria-selected="false"'+(p?' class="k-today">':">")+g.join("")+"</tr>")}return i.join("")},_renderTaskGroupsCells:function(e,n){for(var i=this._isMobile(),r=0;r<n.length;r++)e.push(t.format('<td class="k-scheduler-groupcolumn{2}" rowspan="{0}">{1}</td>',n[r].rowSpan,this._groupTemplate({value:n[r].text,isMobile:i}),n[r].className))},render:function(n){var i=this.content.find("table").empty(),r=[];if(n.length>0){var o=this.groupedResources;if(i.append(e("<tbody>")),o.length)r=this._createGroupConfiguration(n,o,null),this._groupsByDate=[],this._renderGroups(r,i.find("tbody"),[]),this._groupedView._renderDates(i.find("tbody"));else{r=this._tasks(n);var a=e(this._renderTaskGroups(r,[]));t.applyStylesFromKendoAttributes(a,["background-color"]),i.find("tbody").append(a)}}this._eventsList=function(e){for(var t,n=0,i=e.length,r=[];n<i;n++)(t=e[n]).groups?(t=u(t.groups),r=r.concat(t)):r=r.concat(u(t.items));return r}(r);this._aria(),this.refreshLayout(),this.trigger("activate")},_renderGroups:function(e,t,n){for(var i=0,r=e.length;i<r;i++){var o=this._groupedView._getParents(n);o.push(e[i]),this._groupedView._getGroupsByDate(e,i,o),e[i].groups?this._renderGroups(e[i].groups,t,o):this._groupedView._renderTaskGroups(t,e[i].items,o)}},_createGroupConfiguration:function(e,i,r){var o=i[0],a=[],s=o.dataSource.view(),l=this._isMobile();s=s.filter((function(e){var n=t.getter(o.dataParentValueField)(e);return null==n||r&&n===r.value}));for(var u=0;u<s.length;u++){var h=d(o,s[u]),p=new t.data.Query(e).filter({field:o.field,operator:n.SchedulerView.groupEqFilter(h)}).toArray();if(p.length){var f=this._tasks(p),m=r?"":" k-first",g={text:t.getter(o.dataTextField)(s[u]),value:h,rowSpan:0,className:m};if(i.length>1)g.groups=this._createGroupConfiguration(p,i.slice(1),g),r&&(r.rowSpan+=g.rowSpan);else{g.items=f;var v=c(g.items);l&&(v+=g.items.length),g.rowSpan=v,r&&(r.rowSpan+=v)}a.push(g)}}return a},_resourceBySlot:function(){return{}},selectionByElement:function(t){var n,i;if(!(t=e(t)).hasClass("k-scheduler-datecolumn")&&this._eventsList.length){if(t.is(".k-task")&&(t=t.closest("td")),this._isMobile()){var r=t.parent();n=r.parent().children().filter((function(){return e(this).children(":not(.k-scheduler-datecolumn, .k-scheduler-groupcolumn)").length})).index(r)}else n=t.parent().index();return{index:n,start:(i=this._eventsList[n]).start,end:i.end,isAllDay:i.isAllDay,uid:i.uid}}},select:function(e){this.clearSelection();var t=this.table.find(".k-task").eq(e.index).closest("tr").addClass("k-selected").attr("aria-selected",!0)[0];this.current(t)},move:function(e,n){var i=!1,r=e.index;if(n==t.keys.UP?(r--,i=!0):n==t.keys.DOWN&&(r++,i=!0),i){var o=this._eventsList[r];o&&(e.start=o.start,e.end=o.end,e.isAllDay=o.isAllDay,e.events=[o.uid],e.index=r)}return i},moveToEvent:function(){return!1},constrainSelection:function(e){var t=this._eventsList[0];t&&(e.start=t.start,e.end=t.end,e.isAllDay=t.isAllDay,e.events=[t.uid],e.index=0)},isInRange:function(){return!0},destroy:function(){this.element&&this.element.off(r),n.SchedulerView.fn.destroy.call(this)},options:{title:"Agenda",name:"agenda",editable:!0,selectedDateFormat:"{0:D}-{1:D}",selectedShortDateFormat:"{0:d} - {1:d}",selectedMobileDateFormat:"{0: MMM} {0:dd} - {1:dd}",eventTemplate:({title:e})=>i(e),eventTimeTemplate:({isAllDay:e,messages:n,format:i,start:r,end:o})=>e?n.allDay:t.format(i,r,o),eventDateTemplate:e=>e.isMobile?(({date:e})=>`<div class="k-scheduler-datecolumn-wrap"><span class="k-mobile-scheduler-agendadate"><span class="k-mobile-scheduler-agendaday">${t.toString(e,"dd")}</span>&nbsp<span class="k-mobile-scheduler-agendamonth">${t.toString(e,"MMMM")}</span></span><span class="k-mobile-scheduler-agendaweekday">`+t.toString(e,"dddd")+"</span></div>")(e):(({date:e})=>'<strong class="k-scheduler-agendaday">'+t.toString(e,"dd")+'</strong><em class="k-scheduler-agendaweek">'+t.toString(e,"dddd")+'</em><span class="k-scheduler-agendadate">'+t.toString(e,"y")+"</span>")(e),eventGroupTemplate:({isMobile:e,value:t})=>e?'<span class="k-scheduler-group-text">'+t+"</span>":'<strong class="k-scheduler-adgendagroup">'+t+"</strong>",messages:{event:"Event",date:"Date",time:"Time",allDay:"all day"}}})}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=n.SchedulerView,r=".kendoMonthView",o=e.extend,a=t.htmlEncode,s=t.date.getDate,l=t.date.MS_PER_DAY,c="k-event-inverse",d=t.template((({date:e})=>`<span class="k-link k-nav-day">${a(t.toString(e,"dd"))}</span>`)),u=e=>`<div role="button" data-${e.ns}uid="${e.uid}" aria-label="${a(e.ariaLabel)}" `+(e.resources[0]?`${t.attr("style-background-color")}="${e.resources[0].color}" ${t.attr("style-border-color")}="${e.resources[0].color}" class="k-event">`:'class="k-event">')+'<span class="k-event-actions">'+`${e.tail||e.middle?t.ui.icon("caret-alt-left"):""}`+`${e.isException()?t.ui.icon("arrows-no-repeat"):e.isRecurring()?t.ui.icon("arrow-rotate-cw"):""}</span>`+`${t.template(e.template)(e)}<span class="k-event-actions">`+(e.showDelete?`<a href="#" class="k-link k-event-delete" title="${e.messages.destroy}" aria-label="${e.messages.destroy}">${t.ui.icon("x")}</a>`:"")+`${e.head||e.middle?t.ui.icon("caret-alt-right"):""}</span>`+(!e.resizable||e.tail||e.middle?"":'<span class="k-resize-handle k-resize-w"></span>')+(!e.resizable||e.head||e.middle?"":'<span class="k-resize-handle k-resize-e"></span>')+"</div>",h=t.template((({title:e})=>`<div title="${e.replace(/"/g,"&#34;")}"><div class="k-event-template">${a(e)}</div></div>`)),p=t.template((()=>`<div role="button" aria-label="Show all events in Day view." class="k-more-events k-button k-button-md k-rounded-md k-button-solid k-button-solid-base">${t.ui.icon({icon:"more-horizontal",iconClass:"k-button-icon"})}</div>`)),f=t.Class.extend({init:function(e){this._view=e},_verticalRowCountForLevel:function(e){return this._view._rowCountForLevel(e)},_horizontalGroupCountForLevel:function(e){return this._view._columnCountForLevel(e)},_getCalendarRowsLength:function(e,t){return t/e},_createRows:function(e,t,n,i){for(var r=this._view,o=r._isVerticallyGrouped(),a="",s=0;s<n;s++)a+=r._createRow(e,t,7,o?i:s);return a},_adjustStartDate:function(e){return t.date.addDays(e,7)},_getContent:function(e,t,n){return e({date:t,resources:n})},_getTimeSlotByPosition:function(e,t,n){return this._view.groups[n].daySlotByPosition(e,t)},_nextSlotStartDate:function(e){return t.date.nextDay(e)},_createRowsLayout:function(e,t,n){return this._view._createRowsLayout(e,t,n)},_createVerticalColumnsLayout:function(e,t,n,i){return i},_createColumnsLayout:function(e,t,n){return this._view._createColumnsLayout(e,t,n)},_verticalGroupCount:function(e){return this._view._rowCountForLevel(e)},_horizontalGroupCount:function(e){var t=this._view;return t._columnCountForLevel(e)/t._columnOffsetForResource(e)},_positionMobileEvent:function(e,t,n,i,r,o,a){var s=this._view;i>1&&(0===a?o=n.end.endDate():a==i-1?r=n.start.startDate():(r=n.start.startDate(),o=n.end.endDate()));var l=e.clone({start:new Date(r),end:new Date(o),head:n.head,tail:n.tail});s._positionMobileEvent(n,s._createEventElement(l),t)},_positionEvent:function(e,t,n,i,r,o,a){var s=this._view;i>1&&(0===a?o=n.end.endDate():a==i-1?r=n.start.startDate():(r=n.start.startDate(),o=n.end.endDate()));var l=e.clone({start:r,end:o,head:n.head,tail:n.tail});s._positionEvent(n,s._createEventElement(l),t)},_addDaySlotCollections:function(e,n,i){for(var r=this._view,o=0;o<e;o++){var a=0,s=0;r._isVerticallyGrouped()&&(s=o);for(var l=6*s;l<6*(s+1);l++){var c=r.groups[o].addDaySlotCollection(t.date.addDays(i,a),t.date.addDays(i,a+7)),d=n[l].children,u=0;r._isVerticallyGrouped()||(u=o);for(var h=7*u;h<7*(u+1);h++){var p=d[h];r.addDaySlot(c,p,i,a),a++}}}},_changePeriodGroupIndex:function(e){var t=this._view;return e?t.groups.length-1:0},_createResizeHint:function(e){var t=this._view,n=e.startSlot().offsetLeft,r=e.start.offsetTop,o=e.innerWidth(),a=e.start.clientHeight-2,s=i.fn._createResizeHint.call(t,n,r,o,a);t._appendResizeHint(s)},_createMoveHint:function(e,t){var n=this._view,i=e.startSlot(),r=e.endSlot(),o=n._createEventElement(t.clone({head:e.head,tail:e.tail}));o.css({left:i.offsetLeft+2,top:i.offsetTop+i.firstChildHeight,height:"auto"===n.options.eventHeight?25:n.options.eventHeight,width:e.innerWidth()-(i.index!==r.index?3:2)}),o.addClass("k-event-drag-hint"),t.inverseColor&&o.addClass(c),n._appendMoveHint(o)}}),m=t.Class.extend({init:function(e){this._view=e},_verticalRowCountForLevel:function(){return 1},_horizontalGroupCountForLevel:function(e){return this._view._columnCountForLevel(e+1)/7},_createRows:function(e,n,i){var r=this._view,o="",a=0;if(r._isVerticallyGrouped()){for(var s=new Date(e),l=r._groupCount();a<6;a++)o+=r._createRow(s,n,l,a),s=t.date.addDays(s,7);e=t.date.nextDay(e)}else{for(;a<7;a++)o+=r._createRow(e,n,i,a),e=t.date.nextDay(e);e=t.date.addDays(e,7)}return o},_adjustStartDate:function(e,n){return this._view._isVerticallyGrouped()?n?t.date.addDays(e,36):t.date.nextDay(e):t.date.addDays(e,7)},_getContent:function(e,t,n,i){return 0===i?e({date:t,resources:n}):""},_getTimeSlotByPosition:function(e,t,n){return this._view.groups[n].daySlotByPosition(e,t,!0)},_nextSlotStartDate:function(e){return e},_getCalendarRowsLength:function(){return this._view._isVerticallyGrouped()?7:6},_createRowsLayout:function(e,t,n,i){return this._view._createDateLayout(i,null,!1)},_createVerticalColumnsLayout:function(e,n,i){for(var r=this._view,o=e[0],a=[],s=o.dataSource.view(),l=0;l<6*s.length;l++){var c=t.getter(o.dataValueField)(s[l%s.length]),d={text:i({text:t.htmlEncode(t.getter(o.dataTextField)(s[l%s.length])),color:t.getter(o.dataColorField)(s[l%s.length]),field:o.field,title:o.title,name:o.name,value:c}),className:"k-slot-cell",value:c};d.columns=r._createColumnsLayout(e.slice(1),null,i,null,null,c),a.push(d)}return a},_createColumnsLayout:function(e,t,n,i){return this._view._createColumnsLayout(e,t,n,i,!0)},_verticalGroupCount:function(e){return this._view._columnCountForLevel(e)/6},_horizontalGroupCount:function(e){return this._view._columnCountForLevel(e)/7},_positionMobileEvent:function(e,t,n,i,r,o){for(var a=this._view,s=n.start.index,l=n.end.index,c=n.start.index;c<=n.end.index;c++){var d=n.collection._slots[c],u=t.daySlotRanges(d.start,d.start,!0)[0],h=e.clone({start:c===s?r:d.startDate(),end:c===l?o:d.endDate(),head:c!==l||n.head,tail:c!==s||n.tail});a._positionMobileEvent(u,a._createEventElement(h),t)}},_positionEvent:function(e,t,n,i,r,o){for(var a=this._view,s=n.start.index,l=n.end.index,c=n.start.index;c<=n.end.index;c++){var d=n.collection._slots[c],u=t.daySlotRanges(d.start,d.start,!0)[0],h=e.clone({start:c===s?r:d.startDate(),end:c===l?o:d.endDate(),head:c!==l||n.head,tail:c!==s||n.tail});a._positionEvent(u,a._createEventElement(h),t)}},_addDaySlotCollections:function(e,n,i){for(var r=this._view,o=r._isVerticallyGrouped(),a=0;a<7;a++)for(var s=0;s<6;s++){var l=0,c=n[o?a:s].children,d=0;r._isVerticallyGrouped()||(d=a);for(var u=d*e;u<(d+1)*e;u++){var h,p=7*s+a,f=c[o?u+s*e:u],m=o?u:l,g=r.groups[m];h=0===a?g.addDaySlotCollection(t.date.addDays(i,p),t.date.addDays(i,p+7)):g._daySlotCollections[s],r.addDaySlot(h,f,i,p),l++}}},_changePeriodGroupIndex:function(e,t,n){var i=this._view;return t&&i._isVerticallyGrouped()?e?i.groups.length-1:0:n},_createResizeHint:function(e){var t,n,r,o,a,s=this._view;if(s._isVerticallyGrouped())t=e.startSlot().offsetLeft,n=e.start.offsetTop,r=e.startSlot().offsetWidth,o=e.endSlot().offsetTop+e.startSlot().offsetHeight-e.startSlot().offsetTop-2,a=i.fn._createResizeHint.call(s,t,n,r,o),s._appendResizeHint(a);else for(var l=e.startSlot().index;l<=e.endSlot().index;l++){var c=e.collection._slots[l];t=c.offsetLeft,n=c.offsetTop,r=c.offsetWidth,o=c.offsetHeight-2,a=i.fn._createResizeHint.call(s,t,n,r,o),s._appendResizeHint(a)}},_createMoveHint:function(e,t){for(var n=this._view,i=e.startSlot(),r=e.endSlot(),o=i.index;o<=r.index;o++){var a=e.collection._slots[o],s=n._createEventElement(t.clone({head:e.head,tail:e.tail}));s.css({left:a.offsetLeft,top:a.offsetTop+a.firstChildHeight,height:"auto"===n.options.eventHeight?25:n.options.eventHeight,width:a.offsetWidth-2}),s.addClass("k-event-drag-hint"),t.inverseColor&&s.addClass(c),n._appendMoveHint(s)}}});function g(e,t,n){var i;return(i=e)>=t&&i<=n}t.ui.scheduler.MonthGroupedView=f,t.ui.scheduler.MonthGroupedByDateView=m,n.MonthView=i.extend({init:function(e,t){var n=this;0===t.eventsPerDay&&(t.eventsPerDay=1),0===t.eventHeight&&(t.eventHeight=1),0===t.moreButtonHeight&&(t.moreButtonHeight=1),"string"==typeof t.eventHeight&&"auto"!==t.eventHeight&&(t.eventHeight=25),"auto"===t.eventHeight&&(t.adaptiveSlotHeight=!0),i.fn.init.call(n,e,t),n._groupedView=n._getGroupedView();var r=this._isGroupedByDate(),o=this.options.adaptiveSlotHeight,a=this.options.eventHeight;if(!0===r&&!0===o)throw new Error("Incompatible options: adaptive slot height and date grouping!");if(!0===r&&"auto"===a)throw new Error("Incompatible options: auto event height and date grouping!");n.title=n.options.title,n._templates(),n._editable(),n._renderLayout(n.options.date),n._groups()},name:"month",_getGroupedView:function(){return this._isGroupedByDate()?new t.ui.scheduler.MonthGroupedByDateView(this):new t.ui.scheduler.MonthGroupedView(this)},_updateDirection:function(e,t,n,i,r){if(n){var o=t[0].start,a=t[t.length-1].end,s=o.index===a.index,l=o.collectionIndex===a.collectionIndex;(r?s&&l||l:s&&l)&&(e.backward=i)}},_changeDate:function(e,t,n){var i,r,o=this.groups[e.groupIndex];if(n){if(i=o._getCollections(o.daySlotCollectionCount()),(r=t.collectionIndex-1)>=0)return i[r]._slots[i[r]._slots.length-1]}else{if((i=o._getCollections(o.daySlotCollectionCount()))[r=t.collectionIndex+1]&&i[r]._slots[0])return i[r]._slots[0]}},_getNextHorizontalRange:function(e,t,n){var i=this._isVerticallyGrouped();return n.startSlot=e[t](n.startSlot,i),n.endSlot=e[t](n.endSlot,i),n},_getNextVerticalRange:function(e,t,n,i){var r=this._isVerticallyGrouped()&&this._isGroupedByDate();return n.startSlot=e[t](n.startSlot,i,r),n.endSlot=e[t](n.endSlot,i,r),n},_changeViewPeriod:function(e,n,i){var r,o,a=i?7:1;return n&&(a*=-1),r=t.date.addDays(e.start,a),o=t.date.addDays(e.end,a),!this._isInRange(r,o)&&(e.start=r,e.end=o,(!i||i&&this._isVerticallyGrouped())&&(e.groupIndex=this._groupedView._changePeriodGroupIndex(n,i,e.groupIndex)),e.events=[],!0)},_continuousSlot:function(e,t,n){var i=e.backward?0:t.length-1;return this.groups[e.groupIndex].continuousSlot(t[i].start,n)},_changeGroupContinuously:function(e,t,n,i){if(!n){var r=e.groupIndex,o=this.groups.length-1,a=this._isVerticallyGrouped(),s=this.groups[r];!t&&a?(t=s[i?"lastSlot":"firstSlot"](),r+=i?-1:1):t&&!a&&(r=i?o:0),(r<0||r>o)&&(r=i?o:0,t=null),e.groupIndex=r}return t},_normalizeHorizontalSelection:function(e,t,n){return n?t[0].start:t[t.length-1].end},_normalizeVerticalSelection:function(e,t){return e.backward?t[0].start:t[t.length-1].end},_templates:function(){var e=this.options,n=o({},t.Template,e.templateSettings);this.eventTemplate=t.template(u),this.dayTemplate=t.template(e.dayTemplate,n),this.groupHeaderTemplate=t.template(e.groupHeaderTemplate,n)},dateForTitle:function(){return t.format(this.options.selectedDateFormat,this._firstDayOfMonth,this._lastDayOfMonth)},shortDateForTitle:function(){return t.format(this.options.selectedShortDateFormat,this._firstDayOfMonth,this._lastDayOfMonth)},mobileDateForTitle:function(){return t.format(this.options.selectedMobileDateFormat,this._firstDayOfMonth,this._lastDayOfMonth)},mobileYearForTitle:function(){return this.dateForTitle().split(", ")[1]},nextDate:function(){return t.date.nextDay(this._lastDayOfMonth)},previousDate:function(){return t.date.previousDay(this._firstDayOfMonth)},startDate:function(){return this._startDate},endDate:function(){return this._endDate},_renderLayout:function(n){var i=this;this._firstDayOfMonth=t.date.firstDayOfMonth(n),this._lastDayOfMonth=t.date.lastDayOfMonth(n),this._startDate=function(e,n){var i=n.firstDay,r=new Date(e.getFullYear(),e.getMonth(),0,e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds());for(;r.getDay()!=i;)t.date.setTime(r,-1*l);return r}(n,this.calendarInfo()),this.createLayout(this._layout()),this._content(),this._initSlotHeight(),this._initTimesHeight(),this.refreshLayout(),this._isVirtualized()&&this._tryRenderContent(),this.content.on("click"+r,".k-nav-day,.k-more-events",(function(t){var n=e(t.currentTarget).offset(),r=i._slotByPosition(n.left,n.top);t.preventDefault(),i.trigger("navigate",{view:"day",date:r.startDate()})})),this._footer()},_editable:function(){this.options.editable&&(this._isMobile()?this._touchEditable():this._mouseEditable())},_mouseEditable:function(){var n=this;n.element.on("click"+r,".k-scheduler-monthview .k-event a:has(.k-i-x),.k-scheduler-monthview .k-event a:has(.k-svg-i-x)",(function(i){n.trigger("remove",{uid:e(this).closest(".k-event").attr(t.attr("uid"))}),i.preventDefault()})),!1!==n.options.editable.create&&n.element.on("dblclick"+r,".k-scheduler-monthview .k-scheduler-content td",(function(t){var i=e(t.currentTarget).offset(),r=n._slotByPosition(i.left,i.top);if(r){var a=n._resourceBySlot(r);n.trigger("add",{eventInfo:o({isAllDay:!0,start:r.startDate(),end:r.startDate()},a)})}t.preventDefault()})),!1!==n.options.editable.update&&n.element.on("dblclick"+r,".k-scheduler-monthview .k-event",(function(i){n.trigger("edit",{uid:e(this).closest(".k-event").attr(t.attr("uid"))}),i.preventDefault()}))},_touchEditable:function(){var n=this,i=0;t.support.mobileOS.android&&(i=5),!1!==n.options.editable.create&&(n._addUserEvents=new t.UserEvents(n.element,{threshold:i,useClickAsTap:!t.support.browser.edge,filter:".k-scheduler-monthview .k-scheduler-content td",tap:function(t){if(!n._scrolling){var i=e(t.target).offset(),r=n._slotByPosition(i.left,i.top);if(r){var a=n._resourceBySlot(r);n.trigger("add",{eventInfo:o({isAllDay:!0,start:r.startDate(),end:r.startDate()},a)})}t.preventDefault()}}}))},selectionByElement:function(t){var n=e(t).offset();return this._slotByPosition(n.left,n.top)},_columnCountForLevel:function(e){var t=this.columnLevels[e];return t?t.length:0},_rowCountForLevel:function(e){var t=this.rowLevels[e];return t?t.length:0},_content:function(){var e="<tbody>",t=1,n=this._groupedView,i=this.groupedResources;i.length&&this._isVerticallyGrouped()&&(t=n._verticalRowCountForLevel(i.length-1));for(var r=0;r<t;r++)e+=this._createCalendar(r),this._cachedGroupIndex=r;e+="</tbody>",this.content.find("table").html(e)},_virtualContent:function(){var e="";e+=this._createCalendar(++this._cachedGroupIndex),this.content.find("table tbody").append(e),this._initSlotHeight()},_calcSlotHeight:function(e){var t,n=this.options,i=n.eventHeight,r=n.eventSpacing,o=n.moreButtonHeight,a=this.content.find("table tr td")[0];if("auto"!==i&&a)return t=a.firstChild,Math.round(a.offsetHeight-a.clientHeight+t.offsetTop+t.offsetHeight+2+e*i+(e-1)*r+(2+o)+2)},_initSlotHeight:function(){var e,t=this.options,n=t.eventsPerDay,i=t.eventHeight,r=this._isMobile(),o=this.content.find("table");r||"number"==typeof i&&(e=this._calcSlotHeight(n),o.find("tr").height(e))},_sortEventMeta:function(e){e.eventMeta.sort((function(e,t){return e.order-t.order}))},_adjustSlotHeight:function(e){var t=this,n=this.options,i=n.eventHeight,r=n.eventSpacing,o=n.moreButtonHeight;!0===this._canAdjustSlotHeight&&e._daySlotCollections.forEach((function(e){var n=e._events,a=0,s=e._slots,l=s[0],c=l.element.offsetTop,d=0;s.forEach((function(e){e.eventMeta?e.actualEventCount=e.eventMeta.length:(e.eventMeta=[],e.actualEventCount=0)})),s.forEach((function(e,n){for(let t=0;t<e.eventMeta.length;t++){let i=e.eventMeta[t];if(i.startIndex!==n)return;if(i.startIndex===i.endIndex)return;s.slice(n,i.endIndex+1).forEach((function(n){var r=n.eventMeta;r.indexOf(i)>-1||(r[r.length]=e.eventMeta[t],n.actualEventCount=r.length,n.dirty=!0)}))}!0===e.dirty&&(t._sortEventMeta(e),delete e.dirty)})),"auto"===i&&s.forEach((function(e,t){let n=e.firstChildTop+e.firstChildHeight+2;for(let t=0;t<e.eventMeta.length;t++){let i=e.eventMeta[t];i.top=Math.max(i.top,c+n),n=i.top-c+r+i.height}})),s.forEach((function(e,t){var s=e.firstChildTop+e.firstChildHeight+2;for(let i=0;i<e.eventMeta.length;i++){let o=e.eventMeta[i];o.top=Math.max(o.top,c+s),s=o.top-c+r+o.height,o.startIndex===t&&(n[a].element[0].style.top=o.top+"px",a++)}e.eventMeta.length>0?(s-=r,s+=2):s+="auto"===i?25:i,e.more&&(e.more[0].style.top=c+s+"px",s+=2+o),d=Math.max(d,s+1)})),l.element.parentNode.style.height=d+"px",s.forEach((function(e){e.offsetTop=c,e.offsetHeight=d,e.clientHeight=d-1}))}))},_initTimesHeight:function(){var e=this,t=e.times,n=e._isSchedulerHeightSet(),i=e.content[0];t&&!n&&t.height(i.clientHeight)},_createCalendar:function(e){var n=this.startDate(),i=[n],r="",o=1,a=this._isVerticallyGrouped(),s=this._groupedView,l=this.groupedResources;l.length&&(a||(o=s._horizontalGroupCountForLevel(l.length-1))),this._slotIndices={};for(var c=s._getCalendarRowsLength(7,42),d=0;d<c;d++){r+="<tr>",i.push(n);var u=7*d;r+=s._createRows(n,u,o,e),n=s._adjustStartDate(n,d===c-1),r+="</tr>"}return this._weekStartDates=i,this._endDate=t.date.previousDay(n),r},_createRow:function(e,n,i,r){for(var o=this,a=o._firstDayOfMonth,l=o._lastDayOfMonth,c=o.dayTemplate,d="",u="",h=this._groupedView,p=function(){return o._resourceBySlot({groupIndex:r})},f=0;f<i;f++)d="",t.date.isToday(e)&&(d+="k-today"),t.date.isInDateRange(e,a,l)||(d+=" k-other-month"),u+="<td ",""!==d&&(u+='class="'+d+'"'),u+=">",u+=h._getContent(c,e,p,f),u+="</td>",o._slotIndices[s(e).getTime()]=n+f,e=h._nextSlotStartDate(e);return u},_layout:function(){var t,n=this.calendarInfo(),i=function(e,t){return e.slice(t).concat(e.slice(0,t))}(this._isMobile()?n.days.namesShort.map((function(e){return e[0]})):n.days.names,n.firstDay),r=e.map(i,(function(e){return{text:e}})),o=this.groupedResources,a=this._groupedView;if(o.length)if(this._isVerticallyGrouped()){for(var s=[],l=0;l<6;l++)s.push({text:"<div>&nbsp;</div>",className:"k-hidden k-slot-cell"});t=a._createRowsLayout(o,s,this.groupHeaderTemplate,r),r=a._createVerticalColumnsLayout(o,s,this.groupHeaderTemplate,r)}else r=a._createColumnsLayout(o,r,this.groupHeaderTemplate,r);return{columns:r,rows:t}},_createEventElement:function(n){var i=this.options,r=i.editable,o=this._isMobile();n.showDelete=r&&!1!==r.destroy&&!o,n.resizable=r&&!1!==r.resize&&!o,n.ns=t.ns,n.resources=this.eventResources(n),n.inverseColor=!1,n.messages=i.messages||{destroy:"Delete"};var a=e(this.eventTemplate(e.extend({},n,{ariaLabel:this._formatEventAriaLabel(n.title,n.start,n.end,n.isAllDay),template:this.options.eventTemplate})));return t.applyStylesFromKendoAttributes(a,["background-color","border-color"]),a},_isInDateSlot:function(e){if(!this.groups||0===this.groups.length)return!1;var n=this.groups[0],i=n.firstSlot().start,r=n.lastSlot().end-1,o=t.date.toUtcTime(e.start),a=t.date.toUtcTime(e.end);return(g(o,i,r)||g(a,i,r)||g(i,o,a)||g(r,o,a))&&(!g(a,i,i)||g(a,o,o)||e.isAllDay)},_slotIndex:function(e){return this._slotIndices[s(e).getTime()]},_positionMobileEvent:function(n,r,o){var a,s=n.start,l=this.table.find(".k-scheduler-content .k-scheduler-table")[0],c=this.table.find(".k-scheduler-content")[0];n.start.offsetLeft>n.end.offsetLeft&&(s=n.end);var d=n.start.index,u=d,h=i.collidingEvents(n.events(),d,u);h.push({element:r,start:d,end:u});var p=i.createRows(h),f=n.collection.at(d),m=f.container;m||(a=this._isRtl&&c.clientWidth<c.scrollWidth?s.offsetLeft-(l.clientWidth-c.clientWidth)+"px":s.offsetLeft+"px",m=e('<div class="k-events-container"></div>').css({top:s.offsetTop+s.firstChildTop+s.firstChildHeight+"px",left:a,width:s.offsetWidth+"px"}),f.container=m,this.content[0].appendChild(m[0])),p.length<=3&&(n.addEvent({element:r,start:d,end:u,groupIndex:s.groupIndex}),o._continuousEvents.push({element:r,uid:r.attr(t.attr("uid")),start:n.start,end:n.end}),m[0].appendChild(r[0]))},_positionEvent:function(n,r,o){var a=this.options.eventHeight,s=this.options.eventSpacing,l=n.start;n.start.offsetLeft>n.end.offsetLeft&&(l=n.end);var c=n.start.index,d=n.end.index,u=l.eventCount,h=i.collidingEvents(n.events(),c,d),f=c!==d?3:2;h.push({element:r,start:c,end:d});for(var m=i.createRows(h),g=0,v=Math.min(m.length,u);g<v;g++)for(var _=m[g].events,b="auto"===a?"":l.offsetTop+l.firstChildTop+l.firstChildHeight+2+g*(a+s)+"px",y=0,w=_.length;y<w;y++)_[y].element[0].style.top=b,_[y].element.attr(t.attr("order"),g);if(m.length>u)for(var k=c;k<=d;k++){var x=n.collection.at(k);x.more||(x.more=e(p()).css({width:x.clientWidth-2,left:x.offsetLeft+2,top:"auto"===a?"":x.offsetTop+x.firstChildTop+x.firstChildHeight+2+u*a+(u-1)*s+2}),this.content[0].appendChild(x.more[0]))}else{n.addEvent({element:r,start:c,end:d,groupIndex:l.groupIndex}),r[0].style.width=n.innerWidth()-f+"px",r[0].style.left=l.offsetLeft+2+"px",r[0].style.height="auto"===a?"":a+"px",o._continuousEvents.push({element:r,uid:r.attr(t.attr("uid")),start:n.start,end:n.end,order:parseInt(r.attr(t.attr("order")),10)}),r.appendTo(this.content),this._inverseEventColor(r);var C=n.start.collectionIndex,S=n.start.index,T=o._daySlotCollections[C]._slots[S];T.eventMeta||(T.eventMeta=[]),T.eventMeta.push({height:"auto"===a?r.outerHeight():a,top:0,startIndex:S,endIndex:n.end.index,uid:r.attr(t.attr("uid")),order:parseInt(r.attr(t.attr("order")),10)})}},_slotByPosition:function(e,t){var n=this.content.offset();e-=n.left,t-=n.top,t+=this.content[0].scrollTop,e+=this.content[0].scrollLeft,e=Math.ceil(e),t=Math.ceil(t);for(var i=0;i<this.groups.length;i++){var r=this._groupedView._getTimeSlotByPosition(e,t,i);if(r)return r}return null},_appendResizeHint:function(e){e.appendTo(this.content),this._resizeHint=this._resizeHint.add(e)},_updateResizeHint:function(e,n,i,r){this._removeResizeHint();for(var o=this.groups[n].ranges(i,r,!0,e.isAllDay),a=0;a<o.length;a++)this._groupedView._createResizeHint(o[a]);this._resizeHint.find(".k-label-top,.k-label-bottom").text(""),this._resizeHint.first().addClass("k-first").find(".k-label-top").text(t.toString(t.timezone.toLocalDate(i),"M/dd")),this._resizeHint.last().addClass("k-last").find(".k-label-bottom").text(t.toString(t.timezone.toLocalDate(r),"M/dd"))},_updateMoveHint:function(e,n,i){var r=t.date.toUtcTime(e.start)+i,o=r+e.duration(),a=this.groups[n].ranges(r,o,!0,e.isAllDay);this._removeMoveHint(e.uid);for(var s=0;s<a.length;s++)this._groupedView._createMoveHint(a[s],e)},_appendMoveHint:function(e){e.appendTo(this.content),this._moveHint=this._moveHint.add(e)},_groups:function(){var e=this._groupCount(),t=this.content[0].getElementsByTagName("tr"),n=this.startDate();this.groups=[];for(var i=0;i<e;i++)this._addResourceView(i);this._groupedView._addDaySlotCollections(e,t,n)},addDaySlot:function(e,n,i,r){var o=t.date.addDays(i,r),a=t.date.MS_PER_DAY,s=this.options.eventsPerDay;i.getHours()!==o.getHours()&&(a+=(i.getHours()-o.getHours())*t.date.MS_PER_HOUR),a+=o=t.date.toUtcTime(o),e.addDaySlot(n,o,a,s)},render:function(e){this.content.children(".k-event,.k-more-events,.k-events-container").remove(),this._cachedEvents=e,this._groups(),e=new t.data.Query(e).sort([{field:"start",dir:"asc"},{field:"end",dir:"desc"}]).toArray().filter(function(e){return this._isInDateSlot(e)}.bind(this));var n=this.groupedResources,i=this._isMobile(),r=this._isGroupedByDate(),o=this.options.adaptiveSlotHeight;this._canAdjustSlotHeight=!0!==i&&!0!==r&&0===n.length&&!0===o,n.length?this._renderGroups(e,n,0,1):this._renderEvents(e,0),this.refreshLayout(),this._ongoingEvents(e),this.trigger("activate")},_renderEvents:function(e,n){var i=this.groups[n],r=this._groupedView._view._isMobile();i&&(i._continuousEvents||(i._continuousEvents=[]),r?e.forEach(function(e){for(var n=i.slotRanges(e,!0),r=n[0],o=r.start.start,a=r.end.end,s=new Date(r.start.start),l=n[n.length-1].end.end,c=new Date(s),d=new Date(a);s.getTime()<=l&&e.end>=t.timezone.toLocalDate(s)&&e.start<=t.timezone.toLocalDate(l);){var u=i.daySlotRanges(c.getTime(),d.getTime(),!0)[0];d.setDate(d.getDate()+1),c.setDate(c.getDate()+1),u&&(u.head=null,u.middle=null,u.tail=null,this._groupedView._positionMobileEvent(e,i,u,1,o,a,0)),s=t.date.addDays(s,1)}}.bind(this)):(e.forEach(function(e){for(var t,n=e.start,r=e.end,o=i.slotRanges(e,!0),a=o.length,s=0;s<a;s++)t=o[s],this._groupedView._positionEvent(e,i,t,a,n,r,s)}.bind(this)),!0===this._canAdjustSlotHeight&&this._adjustSlotHeight(i)))},_renderGroups:function(e,n,r,o,a){var s=n[0];if(s){var l=s.dataSource.view();l=l.filter((function(e){var n=t.getter(s.dataParentValueField)(e);return null==n||n===a}));for(var c=0;c<l.length;c++){var d=this._resourceValue(s,l[c]),u=new t.data.Query(e).filter({field:s.field,operator:i.groupEqFilter(d)}).toArray();n.length>1?r=this._renderGroups(u,n.slice(1),r++,o+1,d):this._renderEvents(u,r++)}}return r},_groupCount:function(){var e=this.groupedResources,t=this._groupedView;return e.length?this._isVerticallyGrouped()?t._verticalGroupCount(e.length-1):t._horizontalGroupCount(e.length):1},_columnOffsetForResource:function(e){return this._columnCountForLevel(e)/this._columnCountForLevel(e-1)},destroy:function(){this.table&&this.table.removeClass("k-scheduler-monthview"),this.content&&this.content.off(r),this.element&&this.element.off(r),i.fn.destroy.call(this),this._isMobile()&&this.options.editable&&!1!==this.options.editable.create&&this._addUserEvents.destroy()},events:["remove","add","edit","navigate"],options:{title:"Month",name:"month",eventHeight:25,moreButtonHeight:13,editable:!0,selectedDateFormat:"{0:y}",selectedShortDateFormat:"{0:y}",selectedMobileDateFormat:"{0:MMMM}",groupHeaderTemplate:({text:e})=>e,dayTemplate:d,eventTemplate:h,eventsPerDay:2,adaptiveSlotHeight:!1,eventSpacing:3,ongoingEvents:{cssClass:null,enabled:!0,updateInterval:6e4}}})}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=t.htmlEncode,r=n.SchedulerView,o=e.extend,a=t.template,s=t.date.firstDayOfYear,l=t.date.firstDayOfMonth,c=t.date.lastDayOfMonth,d="navigate",u="keydown",h="click",p="focus",f=".kendoYearView",m={layout:"k-scheduler-layout k-scheduler-layout-flex k-scheduler-yearview",body:"k-scheduler-body",tooltip:"k-scheduler-tooltip",indicator:"k-day-indicator",event:"k-tooltip-event",hidden:"k-hidden",calendarView:"k-calendar-view",scheduler:"k-scheduler"},g=a((({date:e,events:n,messages:r})=>`<div class='k-tooltip-title k-text-center'><div class='k-month'>${i(t.format("{0:MMM}",e))}</div><div tabindex='0' class='k-link k-day k-text-primary'>${i(t.format("{0:dd}",e))}</div></div>`+(n.length?"<div class='k-tooltip-events-container'><div class='k-tooltip-events'>"+n.map((e=>`<div class="k-tooltip-event k-event" title="${i(e.title)}" ${e.resources[0]?`${t.attr("style-background-color")}="${i(e.resources[0].color)}" ${t.attr("style-border-color")}="${i(e.resources[0].color)}"`:""}><div class='k-event-title k-text-ellipsis'>${i(e.title)}</div><span class='k-spacer'></span><span class='k-event-time'>${i(t.format("{0:t}",e.start))}</span></div>`)).join("")+"</div></div>":`<div class='k-no-data k-text-center'>${i(r.noData)}</div>`))),v=r.extend({init:function(e,t){var n=this;r.fn.init.call(n,e,t),n._yearRange(),n._templates(),n._layout(),n._initCalendar(),n._initTooltip()},options:{title:"Year",name:"year",months:12,startDate:null,messages:{noData:"No events on this date."},selectedDateFormat:"{0:yyyy}",selectedShortDateFormat:"{0:yyyy}",selectedMobileDateFormat:"{0:yyyy}",tooltipTemplate:g},name:"year",events:[d],_yearRange:function(){var e,t=this,n=t.options;t._startDate=n.startDate?l(n.startDate):s(n.date),t._startDate.setFullYear(n.date.getFullYear()),(e=new Date(t._startDate)).setMonth(e.getMonth()+n.months),t._endDate=e},_templates:function(){var e=this.options,n=o({},t.Template,e.templateSettings);this.tooltipTemplate=t.template(e.tooltipTemplate,n)},_layout:function(){var t=this,n=m;t.content=e("<div/>").addClass(n.layout),t.element.append(t.content),t.body=e("<div/>").addClass(n.body),t.content.append(t.body)},_initCalendar:function(){var t,i,r=this,o=r.options,a=e("<div/>");r.body.append(a),r.calendar=t=new n.MultiViewCalendar(a,{views:o.months,value:r.startDate(),showViewHeader:!0,footer:!1}),i=t.element,o.selectable||r._disableCalendarSelection(),t.value(null),t.header.toggleClass(m.hidden),i.on(h+f,"td[role='gridcell']",r._calendarCellClick.bind(r)),i.on(u+f,"."+m.calendarView,r._calendarKeydown.bind(r)),t.bind(d,r._calendarNavigate.bind(r))},_calendarCellClick:function(e){var t=this.calendar.selectable.value().first();e.preventDefault(),e.stopPropagation(),this._displayTooltip(t)},_calendarKeydown:function(e){var n=t.keys,i=e.keyCode;i!=n.ENTER&&i!=n.SPACEBAR||(e.preventDefault(),this._displayTooltip(this.calendar.selectable.value().first()))},_calendarNavigate:function(e){var t=this,n=e.sender._firstViewValue<t.startDate()?t.previousDate():t.nextDate();t.trigger(d,{view:"year",date:n}),t._focusCellOnNavigate()},_focusCellOnNavigate:function(){var e,t=this,n=t.calendar||t.element.find(".k-calendar").getKendoMultiViewCalendar();n&&(e=n._firstViewValue<t.startDate()?t.lastDateInRange():t.nextDate(),n._focusCell(n._cellByDate(e),!0))},_disableCalendarSelection:function(){var e=this;e.calendar&&(e.calendar.value(null),e.calendar.element.off(u,e.calendar._move))},_initTooltip:function(){var e=this,i=e.content,r=e._buildTooltipTemplate.bind(e);e.tooltip=new n.Tooltip(i,{filter:".k-calendar td[role='gridcell']",showOn:h,position:"right",content:r,width:220,show:()=>setTimeout((()=>t.applyStylesFromKendoAttributes(e.tooltip.popup.element,["background-color","border-color"])))}),e._initTooltipPopup(),e.tooltip.bind("show",e._tooltipShow.bind(e)),e.tooltip.bind("hide",e._tooltipHide.bind(e))},_initTooltipPopup:function(){var e=this,t=e.tooltip;e.tooltip&&(t._initPopup(),t.popup.element.addClass(m.tooltip),t.popup.element.on(h+f,".k-tooltip-title > .k-day",e._tooltipTitleClick.bind(e)),t.popup.element.on(u+f,e,e._tooltipKeydown.bind(e)))},_buildTooltipTemplate:function(){var e=this,n=t.parseDate(e.calendar.current()),i=e.eventsByDate||[];return(i=i.filter((function(e){return t.toString(new Date(e.value),"d")==t.toString(n,"d")})))&&i[0]&&i[0].items.map((function(t){t.resources=e.eventResources(t)||[]})),e.tooltipTemplate({date:n,events:i[0]?i[0].items:[],messages:e.options.messages})},_inverseTooltipEventsColor:function(){var t=this;e.each(t.tooltip.popup.element.find("."+m.event),(function(){t._inverseEventColor(e(this))}))},_tooltipShow:function(e){var t=e.sender;t.refresh(),this._inverseTooltipEventsColor(),t.popup.element.find(":kendoFocusable").first().trigger(p)},_tooltipHide:function(){var e=this.calendar;e&&e.focus()},_tooltipTitleClick:function(){this._navigateToDayView()},_tooltipKeydown:function(n){var i=this.tooltip.popup.element,r=e(n.target),o=t.keys,a=n.keyCode,s=n.shiftKey;if((r.is(".k-day")&&a==o.ENTER||a==o.SPACEBAR)&&(n.preventDefault(),this._navigateToDayView()),a==o.TAB){var l=i.find(":kendoFocusable").first(),c=i.find(":kendoFocusable").last();s&&r.is(l)?(c.trigger(p),n.preventDefault()):r.is(c)&&(l.trigger(p),n.preventDefault())}},_navigateToDayView:function(){e.grep(this.options.views,(function(t){return e.isPlainObject(t)&&"kendo.ui.DayView"==t.type||"day"===t})).length&&this.trigger(d,{view:"day",date:this.calendar.current()})},_displayTooltip:function(e){var t=this;e.length&&(t.options.selectable||e.removeClass("k-selected"),setTimeout((function(){t.tooltip.show(e)}),50))},_renderEventIndicators:function(){var t,n,i=this.calendar;i.element.find("."+m.indicator).remove(),this.eventsByDate.forEach((function(r){t=i._currentView.toDateString(new Date(r.value)),n=i.element[0].querySelector("[data-value='"+t+"']"),r.items.length&&e("<span/>").addClass(m.indicator).appendTo(n)}))},_groupEventsByDate:function(e){var n;return e.length?(n=e.map((function(e){return e.formattedDate=e.start.toDateString(),e})),new t.data.Query(n).sort([{field:"start",dir:"asc"},{field:"end",dir:"desc"}]).group({field:"formattedDate"}).toArray()):[]},_resourceBySlot:function(){return{}},lastDateInRange:function(){var e=new Date(this.previousDate());return e.setMonth(e.getMonth()-1+this.options.months),c(e)},nextDate:function(){return t.date.nextYear(this._startDate)},previousDate:function(){return t.date.previousYear(this._startDate)},startDate:function(){return this._startDate},endDate:function(){return this._endDate},moveToEvent:function(){return!1},constrainSelection:function(){return!1},inRange:function(){return!0},select:function(e){this.clearSelection(),e.start>=this.startDate()&&e.start<this.endDate()?this.calendar.value(e.start):(this.calendar.value(this.calendar._firstViewValue),e.start=e.end=this.calendar.value()),this.current(this.calendar.selectable.value()[0])},selectionByElement:function(n){if(n.length)return n=e(n),{index:this.calendar._index,start:t.calendar.toDateObject(n),end:t.calendar.toDateObject(n),isAllDay:!1,uid:0}},current:function(e){if(undefined===e)return this._current;this._current=e},render:function(e){var t=this;t._cachedEvents=e,t.eventsByDate=t._groupEventsByDate(e)||[],t._renderEventIndicators(),t.trigger("activate")},destroy:function(){var e=this;e.tooltip&&(e.tooltip.destroy(),e.tooltip=null),e.calendar&&(e.calendar.destroy(),e.calendar=null),e.element&&(e.content.remove(),e.element.off(f)),r.fn.destroy.call(this)}});o(!0,n,{YearView:v})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.htmlEncode,r=n.timezone,o=n.Class,a=n.ui,s=a.Widget,l=a.DropDownList,c=a.ButtonGroup,d=n.date,u=d.setTime,h=d.setDayOfWeek,p=d.adjustDST,f=d.firstDayOfMonth,m=d.getMilliseconds,g=[0,31,60,91,121,152,182,213,244,274,305,335,366],v=[0,31,59,90,120,151,181,212,243,273,304,334,365],_=[31,28,31,30,31,30,31,31,30,31,30,31],b={0:"SU",1:"MO",2:"TU",3:"WE",4:"TH",5:"FR",6:"SA"},y={SU:0,MO:1,TU:2,WE:3,TH:4,FR:5,SA:6},w=["yyyy-MM-ddTHH:mm:ss.fffzzz","yyyy-MM-ddTHH:mm:sszzz","yyyy-MM-ddTHH:mm:ss","yyyy-MM-ddTHH:mm","yyyy-MM-ddTHH","yyyy-MM-dd","yyyyMMddTHHmmssfffzzz","yyyyMMddTHHmmsszzz","yyyyMMddTHHmmss","yyyyMMddTHHmm","yyyyMMddTHH","yyyyMMdd"],k=["months","weeks","yearDays","monthDays","weekDays","hours","minutes","seconds"],x=k.length,C={months:function(e,t,n){var i=n.months,r=$(i,e.getMonth()+1),o=!1;return null!==r&&(r.length?e.setMonth(r[0]-1,1):e.setFullYear(e.getFullYear()+1,i[0]-1,1),o=!0),o},monthDays:function(e,t,n){for(var i,r,o,a=!1,s=e.getHours(),l=function(e){return e<0&&(e=i+e+1),e};e<=t;){if(r=e.getMonth(),i=j(e),null===(o=$(n.monthDays,e.getDate(),l)))return a;if(a=!0,o.length){if(e.setMonth(r,o.sort(G)[0]),p(e,s),r===e.getMonth())break}else e.setMonth(r+1,1)}return a},yearDays:function(e,t,n){for(var i,r,o=!1,a=e.getHours(),s=function(e){return e<0&&(e=i+e),e};e<t;){if(i=q(e)?366:365,null===(r=$(n.yearDays,F(e),s)))return o;if(o=!0,i=e.getFullYear(),r.length){e.setFullYear(i,0,r.sort(G)[0]),p(e,a);break}e.setFullYear(i+1,0,1)}return o},weeks:function(e,t,n){for(var i,r,o,a=n.weekStart,s=!1,l=e.getHours(),c=function(e){return e<0&&(e=53+e),e};e<t;){if(null===(r=$(n.weeks,R(e,a),c)))return s;if(s=!0,i=e.getFullYear(),r.length){o=7*r.sort(G)[0]-1,e.setFullYear(i,0,o),h(e,a,-1),p(e,l);break}e.setFullYear(i+1,0,1)}return s},weekDays:function(e,t,n){var i,r,o=new Date(e.getTime()+n.offsets.start),a=o.getDay()-e.getDay(),s=n.weekDays,l=n.weekStart,c=function(e,t,n){for(var i,r,o,a,s=B(t.getDay(),n),l=e.length,c=[],d=0;d<l;d++)if(r=e[d],a=L(t,n),null!==(i=O(t,r,n)))if(a<i)c.push(r);else if(a===i)if(s<(o=B(r.day,n)))c.push(r);else if(s===o)return null;return c}(s,o,l),d=e.getHours();if(null===c)return!1;if((i=c[0])||(("monthly"===n.freq&&!n.positions||n.position>0)&&s.forEach((function(t){var n=new Date(e.getFullYear(),e.getMonth()+1,1),r=B(t.day,l);n.getDay()<=r&&(!i||B(i.day,l)>r)&&(i=t)})),i||(i=s[0]),h(e,l)),r=i.day,r-=a,i.offset)for(;e<=t&&!N(e,i,l);)L(e,l)===V(e,l)?(e.setMonth(e.getMonth()+1,1),p(e,d)):(e.setDate(e.getDate()+7),p(e,d),h(e,l,-1));return e.getDay()!==r&&h(e,r),!0},hours:function(e,t,n){var i=n.hours,r=n._startTime,o=r.getHours(),a=$(i,o),s=!1;return null!==a&&(s=!0,e.setHours(o),p(e,o),a.length?(a=a[0],e.setHours(a)):(a=e.getHours(),e.setDate(e.getDate()+1),p(e,a),a=i[0],e.setHours(a),p(e,a)),n.minutes&&e.setMinutes(0),r.setHours(a,e.getMinutes())),s},minutes:function(e,t,n){var i=n.minutes,r=$(i,e.getMinutes()),o=n._startTime.getHours(),a=!1;return null!==r&&(a=!0,r.length?r=r[0]:(o+=1,r=i[0]),n.seconds&&e.setSeconds(0),e.setHours(o,r),p(e,o%=24),n._startTime.setHours(o,r,e.getSeconds())),a},seconds:function(e,t,n){var i=n.seconds,r=n._startTime.getHours(),o=$(i,e.getSeconds()),a=e.getMinutes(),s=!1;return null!==o&&(s=!0,o.length?e.setSeconds(o[0]):(a+=1,e.setMinutes(a,i[0]),a>59&&(a%=60,r=(r+1)%24)),n._startTime.setHours(r,a,e.getSeconds())),s}},S=o.extend({next:function(e,t){var n,i,r=t._startTime,o=r.getDate();if(t.seconds)i=e.getSeconds()+1,e.setSeconds(i),r.setSeconds(i),r.setDate(o);else{if(!t.minutes)return!1;n=e.getMinutes()+1,e.setMinutes(n),r.setMinutes(n),r.setDate(o)}return!0},normalize:function(e){var t=e.rule;4===e.idx&&t.hours&&(t._startTime.setHours(0),this._hour(e.date,t))},limit:function(e,n,i){for(var r,o,a,s,l,c=i.interval;e<=n;){for(a=o=t,l=e.getDate(),s=0;s<x;s++){if(i[r=k[s]]){if(a=C[r](e,n,i),o!==t&&a)break;o=a}a&&this.normalize({date:e,rule:i,day:l,idx:s})}if((1===c||!this.interval(i,e))&&s===x)break}},interval:function(e,t){var n,i,r=new Date(e._startPeriod),o=new Date(t),a=t.getHours(),s=e.weekStart,l=e.interval,c=e.freq,u=!1,h=0,f=0,m=1;if("hourly"===c)n=o.getTimezoneOffset()-r.getTimezoneOffset(),i=e._startTime.getHours(),o=o.getTime(),a!==i&&(o+=(i-a)*d.MS_PER_HOUR),o-=r,n&&(o-=n*d.MS_PER_MINUTE),0!==(h=H(n=Math.floor(o/d.MS_PER_HOUR),l))&&(this._hour(t,e,h),u=!0);else if("daily"===c)d.setTime(o,-r,!0),0!==(h=H(n=Math.round(o/d.MS_PER_DAY),l))&&(this._date(t,e,h),u=!0);else if("weekly"===c){h=this._getNumberOfWeeksBetweenDates(r,t),B(t.getDay(),s)<B(r.getDay(),s)&&(h+=1),0!==(h=H(h,l))&&(d.setDayOfWeek(t,e.weekStart,-1),t.setDate(t.getDate()+7*h),p(t,a),u=!0)}else"monthly"===c?(n=t.getFullYear()-r.getFullYear(),0!==(h=H(n=t.getMonth()-r.getMonth()+12*n,l))&&(m=e._hasRuleValue?1:t.getDate(),t.setFullYear(t.getFullYear(),t.getMonth()+h,m),p(t,a),u=!0)):"yearly"===c&&(h=H(n=t.getFullYear()-r.getFullYear(),l),e.months||(f=t.getMonth()),e.yearDays||e.monthDays||e.weekDays||(m=t.getDate()),0!==h&&(t.setFullYear(t.getFullYear()+h,f,m),p(t,a),u=!0));return u},_getNumberOfWeeksBetweenDates:function(e,t){var n=(t-e)/6048e5,i=Math.floor(n);return n-i>.99&&(i=Math.round(n)),i},_hour:function(e,t,n){var i=t._startTime,r=i.getHours();n&&(r+=n),e.setHours(r),r%=24,i.setHours(r),p(e,r)},_date:function(e,t,n){var i=e.getHours();e.setDate(e.getDate()+n),p(e,i)||this._hour(e,t)}}),T=S.extend({next:function(e,t){S.fn.next(e,t)||this._hour(e,t,1)},normalize:function(e){var t=e.rule;4===e.idx&&(t._startTime.setHours(0),this._hour(e.date,t))}}),D=S.extend({next:function(e,t){S.fn.next(e,t)||this[t.hours?"_hour":"_date"](e,t,1)}}),A=D.extend({setup:function(e,t){e.weekDays||(e.weekDays=[{day:t.getDay(),offset:0}])}}),M=S.extend({next:function(e,t){var n,i;if(!S.fn.next(e,t))if(t.hours)this._hour(e,t,1);else if(t.monthDays||t.weekDays||t.yearDays||t.weeks)this._date(e,t,1);else{for(n=e.getDate(),i=e.getHours(),e.setMonth(e.getMonth()+1),p(e,i);e.getDate()!==n;)e.setDate(n),p(e,i);this._hour(e,t)}},normalize:function(e){var t=e.rule,n=e.date,i=n.getHours();0!==e.idx||t.monthDays||t.weekDays?S.fn.normalize(e):(n.setDate(e.day),p(n,i))},setup:function(e,t,n){e.monthDays||e.weekDays||n.setDate(t.getDate())}}),E=M.extend({next:function(e,t){var n,i=e.getHours();if(!S.fn.next(e,t))if(t.hours)this._hour(e,t,1);else if(t.monthDays||t.weekDays||t.yearDays||t.weeks)this._date(e,t,1);else if(t.months){for(n=e.getDate(),e.setMonth(e.getMonth()+1),p(e,i);e.getDate()!==n;)e.setDate(n),p(e,i);this._hour(e,t)}else e.setFullYear(e.getFullYear()+1),p(e,i),this._hour(e,t)},setup:function(){}}),I={hourly:new T,daily:new D,weekly:new A,monthly:new M,yearly:new E},z="click",P="change";function H(e,t){var n;return 0!==e&&e<t?n=t-e:(n=e%t)&&(n=t-n),n}function F(e){var t=e.getMonth();return(q(e)?g[t]:v[t])+e.getDate()}function R(e,n){var i,r;return e=new Date(e.getFullYear(),e.getMonth(),e.getDate()),p(e,0),i=e.getFullYear(),n!==t?(h(e,n,-1),e.setDate(e.getDate()+4)):e.setDate(e.getDate()+(4-(e.getDay()||7))),p(e,0),r=Math.floor((e.getTime()-new Date(i,0,1,-6))/864e5),1+Math.floor(r/7)}function L(e,t){var n=7-(f(e).getDay()+7-(t||7))||7;return n<0&&(n+=7),Math.ceil((e.getDate()-n)/7)+1}function B(e,t){return e+(e<t?7:0)}function O(e,t,n){var i=t.offset;if(!i)return L(e,n);var r=new Date(e.getFullYear(),e.getMonth()+1,0),o=L(r,n),a=B(t.day,n),s=a<B(new Date(e.getFullYear(),e.getMonth(),1).getDay(),n),l=a>B(r.getDay(),n);return i<0?i=o+(i+1-(l?1:0)):s&&(i+=1),o-=l?1:0,i<(s?1:0)||i>o?null:i}function V(e,t){return L(new Date(e.getFullYear(),e.getMonth()+1,0),t)}function N(e,t,n){return L(e,n)===O(e,t,n)}function $(e,t,n){for(var i,r=0,o=e.length,a=[];r<o;r++){if(i=e[r],n&&(i=n(i)),t===i)return null;t<i&&a.push(i)}return a}function U(e,t){for(var n,i=0,r=e.length;i<r;i++){if(n=parseInt(e[i],10),isNaN(n)||n<t.start||n>t.end||0===n&&t.start<0)return null;e[i]=n}return e.sort(G)}function W(e){for(var n,i,r,o=0,a=e.length;o<a;o++){if(i=(n=e[o]).length,r=n.substring(i-2).toUpperCase(),(r=y[r])===t)return null;e[o]={offset:parseInt(n.substring(0,i-2),10)||0,day:r}}return e}function j(e){var t=e.getMonth();return 1===t?1===new Date(e.getFullYear(),1,29).getMonth()?29:28:_[t]}function q(e){return(e=e.getFullYear())%4==0&&e%100!=0||e%400==0}function G(e,t){return e-t}function K(e,t){var n,i,r=0,o=[];if(e)for(n=(e=e.split(-1!==e.indexOf(";")?";":",")).length;r<n;r++)(i=ne(e[r],t))&&o.push(i);return o}function Y(e,t,n){for(var i=Array.isArray(e)?e:K(e,n),r=t.getTime()-t.getMilliseconds(),o=0,a=i.length;o<a;o++)if(i[o].getTime()===r)return!0;return!1}function Q(e,t){var i,r,o=0,a=[].concat(e);for(i=a.length;o<i;o++)r=a[o],r=n.timezone.convert(r,t||r.getTimezoneOffset(),"Etc/UTC"),a[o]=n.toString(r,"yyyyMMddTHHmmssZ");return a.join(",")}function X(e,t){var n=new Date(e);switch(t.freq){case"yearly":n.setFullYear(n.getFullYear(),11,31);break;case"monthly":n.setFullYear(n.getFullYear(),n.getMonth()+1,0);break;case"weekly":h(n,t.weekStart,-1),n.setDate(n.getDate()+6)}return t.hours&&n.setHours(23),t.minutes&&n.setMinutes(59),t.seconds&&n.setSeconds(59),n}function Z(e,t,n,i){for(var r,o,a,s=e.length,l=[],c=0,d=n.length;c<d;c++)(r=n[c])<0?r=s+r:r-=1,o=e[r],a=!i||o.start<i,o&&o.start>=t&&a&&l.push(o);return l}function J(e,t,n){for(var i,r=[],o=0;o<e.length;o++)Y(t,(i=e[o]).start,n)||r.push(i);return r}function ee(e){return e.getTimezoneOffset()<new Date(e.getTime()-36e5).getTimezoneOffset()}function te(e,t){return t?n.timezone.offset(e,t):e.getTimezoneOffset()}function ne(e,t){return(e=n.parseDate(e,w))&&t&&(e=r.apply(e,t)),e}function ie(e,t){for(var n,i,r,o,a,s,l=e.split(";"),c=0,d=l.length;c<d;c++)if(i=(n=l[c].split(":"))[0],r=n[1],-1!==i.indexOf("TZID")&&(o=i.substring(i.indexOf("TZID")).split("=")[1]),r)for(a=0,s=(r=r.split(",")).length;a<s;a++)r[a]=ne(r[a],o||t);if(r)return{value:r,tzid:o}}function re(e,i,r){var o,a,s,l,c,d,u,h,p={},f=0,m=!1;if(!e)return null;for((d=e.split("\n"))[1]||-1===e.indexOf("DTSTART")&&-1===e.indexOf("DTEND")&&-1===e.indexOf("EXDATE")||(d=e.split(" ")),f=0,s=d.length;f<s;f++)-1!==(c=n.trim(d[f])).indexOf("DTSTART")?p.start=ie(c,i):-1!==c.indexOf("DTEND")?p.end=ie(c,i):-1!==c.indexOf("EXDATE")?p.exdates=ie(c,i):-1!==c.indexOf("RRULE")?l=c.substring(6):n.trim(c)&&(l=c);for(f=0,s=(l=l.split(";")).length;f<s;f++)switch(o=l[f].split("="),a=n.trim(o[1]).split(","),n.trim(o[0]).toUpperCase()){case"FREQ":p.freq=a[0].toLowerCase();break;case"UNTIL":p.until=ne(a[0],i);break;case"COUNT":p.count=parseInt(a[0],10);break;case"INTERVAL":p.interval=parseInt(a[0],10);break;case"BYSECOND":p.seconds=U(a,{start:0,end:60}),m=!0;break;case"BYMINUTE":p.minutes=U(a,{start:0,end:59}),m=!0;break;case"BYHOUR":p.hours=U(a,{start:0,end:23}),m=!0;break;case"BYMONTHDAY":p.monthDays=U(a,{start:-31,end:31}),m=!0;break;case"BYYEARDAY":p.yearDays=U(a,{start:-366,end:366}),m=!0;break;case"BYMONTH":p.months=U(a,{start:1,end:12}),m=!0;break;case"BYDAY":p.weekDays=h=W(a),m=!0;break;case"BYWEEKNO":p.weeks=U(a,{start:-53,end:53}),m=!0;break;case"BYSETPOS":p.positions=U(a,{start:-366,end:366});break;case"WKST":p.weekStart=u=y[a[0]]}return p.freq===t||p.count!==t&&p.until?null:(p.interval||(p.interval=1),u===t&&(p.weekStart=u=n.culture().calendar.firstDay),h&&(p.weekDays=h.sort((function(e,t){var n=e.day,i=t.day;return n<u&&(n+=7),i<u&&(i+=7),n-i}))),p.positions&&!m&&(p.positions=null),p._hasRuleValue=m,p.offsets=r,p)}function oe(e,t){for(var i,o=e.value,a=e.tzid||"",s=o.length,l=0;l<s;l++)i=o[l],i=r.convert(i,a||t||i.getTimezoneOffset(),"Etc/UTC"),o[l]=n.toString(i,"yyyyMMddTHHmmssZ");return a&&(a=";TZID="+a),a+":"+o.join(",")+" "}function ae(e,i){var o=e.weekStart,a="FREQ="+e.freq.toUpperCase(),s=e.exdates||"",l=e.start||"",c=e.end||"",d=e.until;return o===t&&(o=n.culture().calendar.firstDay),e.interval>1&&(a+=";INTERVAL="+e.interval),e.count&&(a+=";COUNT="+e.count),d&&(d=r.convert(d,i||d.getTimezoneOffset(),"Etc/UTC"),a+=";UNTIL="+n.toString(d,"yyyyMMddTHHmmssZ")),e.months&&(a+=";BYMONTH="+e.months),e.weeks&&(a+=";BYWEEKNO="+e.weeks),e.yearDays&&(a+=";BYYEARDAY="+e.yearDays),e.monthDays&&(a+=";BYMONTHDAY="+e.monthDays),e.weekDays&&(a+=";BYDAY="+function(e){for(var t,n,i=0,r=e.length,o=[];i<r;i++)"string"==typeof(t=e[i])?n=t:(n=""+b[t.day],t.offset&&(n=t.offset+n)),o.push(n);return o.toString()}(e.weekDays)),e.hours&&(a+=";BYHOUR="+e.hours),e.minutes&&(a+=";BYMINUTE="+e.minutes),e.seconds&&(a+=";BYSECOND="+e.seconds),e.positions&&(a+=";BYSETPOS="+e.positions),o!==t&&(a+=";WKST="+b[o]),l&&(l="DTSTART"+oe(l,i)),c&&(c="DTEND"+oe(c,i)),s&&(s="EXDATE"+oe(s,i)),(l||c||s)&&(a=l+c+s+"RRULE:"+a),a}n.recurrence={rule:{parse:re,serialize:ae},expand:function(e,i,r,o){var a,s,l,c,p,f,g,v,_,b,y,w,k,x,C,S,T,D,A,M,E,z,P,H,F,R,L=[];if(!(a=re(e.recurrenceRule,o,{start:(te(e.start,o)-te(e.start,e.startTimezone||o))*n.date.MS_PER_MINUTE,end:(te(e.end,o)-te(e.end,e.endTimezone||o))*n.date.MS_PER_MINUTE})))return[e];E=(M=a.positions)?0:1,b=a.start,y=a.end,(b||y)&&(e=e.clone({start:b?new Date(b.value[0]):t,end:y?new Date(y.value[0]):t})),S=(T=e.start).getTime(),C=m(T),!(x=K(e.recurrenceException,o))[0]&&a.exdates&&(x=a.exdates.value,e.set("recurrenceException",Q(x,o))),_=i=new Date(i),r=new Date(r),k=a.freq,A=I[k],D=a.count,a.until&&a.until<r&&(r=new Date(a.until)),w="yearly"===k||"monthly"===k||"weekly"===k,i<S||D||a.interval>1||w||("daily"===k||"hourly"===k)&&!a.seconds?i=new Date(S):(p=i.getHours(),f=i.getMinutes(),g=i.getSeconds(),a.hours||(p=T.getHours()),a.minutes||(f=T.getMinutes()),a.seconds||(g=T.getSeconds()),i.setHours(p,f,g,T.getMilliseconds())),a._startPeriod=new Date(i),M&&(i=function(e,t){var n=new Date(e);switch(t.freq){case"yearly":n.setFullYear(n.getFullYear(),0,1);break;case"monthly":n.setFullYear(n.getFullYear(),n.getMonth(),1);break;case"weekly":h(n,t.weekStart,-1)}return t.hours&&n.setHours(0),t.minutes&&n.setMinutes(0),t.seconds&&n.setSeconds(0),n}(i,a),r=X(r,a),m(r)-m(i)<0&&(p=i.getHours(),r.setHours(p,i.getMinutes(),i.getSeconds(),i.getMilliseconds()),d.adjustDST(r,p)),a._startPeriod=new Date(i),a._endPeriod=X(i,a)),v=e.duration();var B=e.isAllDay?864e5:0;for(a._startTime=s=d.toInvariantTime(i),A.setup&&A.setup(a,T,i),A.limit(i,r,a);i<=r;){c=new Date(i),u(c,v);var O=new Date(i);if(u(O,v+B),(i>=_||O>_)&&!Y(x,i,o)||M)if(l=(s=d.toUtcTime(d.getDate(i))+m(a._startTime))+v,S!==i.getTime()||C!==m(a._startTime)){var V=e.startTimezone||e.endTimezone,N=e.endTimezone||e.startTimezone;if(!e.isAllDay&&(o&&V||!o&&!V)){var $=te(i,o)-te(e.start,o),U=te(c,o)-te(e.end,o),W=te(i,V)-te(e.start,V),j=te(c,N)-te(e.end,N);if($!==W){var q=6e4*($-W);P=new Date(i.getTime()-q),F=s-q}if(U!==j){var G=6e4*(U-j);H=new Date(c.getTime()-G),R=l-G}}L.push(e.toOccurrence({start:P||new Date(i),end:H||c,_startTime:F||s,_endTime:R||l})),P=H=F=R=null}else e._startTime=s,e._endTime=l,L.push(e);if(M){if(A.next(i,a),A.limit(i,r,a),i>a._endPeriod&&(z=J(z=Z(L.slice(E),T,M,a.until),x,o),L=L.slice(0,E).concat(z),a._endPeriod=X(i,a),E=L.length),D&&D===E)break}else{if(D&&D===E)break;E+=1;var ne=ee(i);A.next(i,a),ne&&"hourly"!==a.freq&&d.toInvariantTime(e.start).getTime()!==d.toInvariantTime(i).getTime()&&(a._startTime=s=new Date(i.getTime()-36e5)),A.limit(i,r,a)}}return L},dayInYear:F,weekInYear:R,weekInMonth:L,numberOfWeeks:V,isException:Y,toExceptionString:Q};var se=n.template((({frequency:e,messages:t,end:r})=>("never"!==e?`<div class="k-form-field"><label id="recur_interval_label" class="k-label k-form-label" for="recur_interval">${i(t.repeatEvery)}</label><div class="k-form-field-wrap"><input id="recur_interval" ref-recur-interval title="${i(t.repeatEvery)} ${i(t.interval)}" aria-labelledby="recur_interval_label">${i(t.interval)}</div></div>`:"")+("weekly"===e?`<div class="k-form-field"><label class="k-label k-form-label">${i(t.repeatOn)}</label><div class="k-form-field-wrap"><div class="k-button-group-stretched k-recur-weekday-buttons" title="${i(t.repeatOn)}"></div></div></div></div>`:"")+("monthly"===e?`<div class="k-form-field"><label class="k-label k-form-label">${i(t.repeatOn)}</label></div><div class="k-form-field-wrap"><ul class="k-radio-list"><li class="k-radio-item"><label class="k-radio-label"><input class="k-recur-month-radio k-radio k-radio-md" type="radio" name="month" value="monthday" title="${i(t.repeatOn)}" />${i(t.date)}:</label><input ref-recur-monthday aria-label="${i(t.date)}" title="${i(t.date)}" /></li><li class="k-radio-item"><input class="k-recur-month-radio k-radio k-radio-md" type="radio" name="month" value="weekday" aria-label="${i(t.repeatOn)} ${i(t.day)}" title="${i(t.repeatOn)} ${i(t.day)}" /><input class="k-recur-weekday-offset" title="${i(t.repeatOn)}" ${n.attr("style-width")}="8em" /><input class="k-recur-weekday" title="${i(t.day)}" ${n.attr("style-width")}="8em" /></li></ul></div></div>`:"")+("yearly"===e?`<div class="k-form-field"><label class="k-label k-form-label">${i(t.repeatOn)}</label><div class="k-form-field-wrap"><ul class="k-radio-list"><li class="k-radio-item"><input class="k-recur-year-radio k-radio k-radio-md" type="radio" name="year" value="monthday" title="${i(t.repeatOn)} ${i(t.month)}" /><input class="k-recur-month" aria-label="${i(t.month)}" title="${i(t.month)}" ${n.attr("style-width")}="8em" /><input ref-recur-monthday aria-label="${i(t.date)}" title="${i(t.date)}" /></li><li class="k-radio-item"><input class="k-recur-year-radio k-radio k-radio-md" type="radio" name="year" value="weekday" title="${i(t.repeatOn)} ${i(t.day)}" /><input class="k-recur-weekday-offset" title="${i(t.repeatOn)}" ${n.attr("style-width")}="8em"/><input class="k-recur-weekday" title="${i(t.day)}" ${n.attr("style-width")}="8em"/>${i(t.of)}<input class="k-recur-month" title="${i(t.of+t.month)}" ${n.attr("style-width")}="8em"/></li></ul></div></div>`:"")+("never"!==e?`<div class="k-form-field"><label class="k-label k-form-label">${i(r.label)}</label><div class="k-form-field-wrap"><ul class="k-radio-list"><li class="k-radio-item"><label class="k-radio-label"><input class="k-recur-end-never k-radio k-radio-md" type="radio" name="end" value="never" title="${i(r.label)}" />${i(r.never)}</label></li><li class="k-radio-item"><label class="k-radio-label"><input class="k-recur-end-count k-radio k-radio-md" type="radio" name="end" value="count" title="${i(r.label)}" />${i(r.after)}</label><input ref-recur-count aria-label="${i(r.occurrence)}" title="${i(r.occurrence)}" />${i(r.occurrence)}</li><li class="k-radio-item"><label class="k-radio-label"><input class="k-recur-end-until k-radio k-radio-md" type="radio" name="end" value="until" title="${i(r.label)}" />${i(r.on)}</label><input title="${i(r.on)}" aria-label="${i(r.on)}" ref-recur-until /></li></ul></div></div>`:""))),le=[{day:0,offset:0},{day:1,offset:0},{day:2,offset:0},{day:3,offset:0},{day:4,offset:0},{day:5,offset:0},{day:6,offset:0}],ce=[{day:1,offset:0},{day:2,offset:0},{day:3,offset:0},{day:4,offset:0},{day:5,offset:0}],de=[{day:0,offset:0},{day:6,offset:0}],ue=s.extend({init:function(e,t){var i,r=this,o=t&&t.frequencies;s.fn.init.call(r,e,t),r.wrapper=r.element,(t=r.options).start=i=t.start||d.today(),o&&(t.frequencies=o),"string"==typeof i&&(t.start=n.parseDate(i,"yyyyMMddTHHmmss")),null===t.firstWeekDay&&(t.firstWeekDay=n.culture().calendar.firstDay),r._namespace="."+t.name},options:{value:"",start:"",timezone:"",spinners:!0,firstWeekDay:null,frequencies:["never","daily","weekly","monthly","yearly"],mobile:!1,messages:{repeat:"Repeat",recurrenceEditorTitle:"Recurrence editor",frequencies:{never:"Never",hourly:"Hourly",daily:"Daily",weekly:"Weekly",monthly:"Monthly",yearly:"Yearly"},hourly:{repeatEvery:"Repeat every: ",interval:" hour(s)"},daily:{repeatEvery:"Repeat every: ",interval:" day(s)"},weekly:{interval:" week(s)",repeatEvery:"Repeat every: ",repeatOn:"Repeat on: "},monthly:{repeatEvery:"Repeat every: ",repeatOn:"Repeat on: ",interval:" month(s)",day:"Day ",date:"Date"},yearly:{repeatEvery:"Repeat every: ",repeatOn:"Repeat on: ",interval:" year(s)",of:" of ",month:"month",day:"day",date:"Date"},end:{label:"End:",mobileLabel:"Ends",never:"Never",after:"After ",occurrence:" occurrence(s)",on:"On "},offsetPositions:{first:"first",second:"second",third:"third",fourth:"fourth",last:"last"},weekdays:{day:"day",weekday:"weekday",weekend:"weekend day"}}},events:["change"],_initInterval:function(){var e=this,t=e._container.find("[ref-recur-interval]"),n=e._value;e._interval=t.kendoNumericTextBox({spinners:e.options.spinners,value:n.interval||1,decimals:0,format:"#",min:1,change:function(){n.interval=this.value(),e._trigger()}}).data("kendoNumericTextBox"),e._interval.wrapper.addClass("k-recur-interval")},_weekDayButtons:function(e){for(var t=this,i=n.culture().calendar.days.names,r=n.culture().calendar.days.namesAbbr,o=t.options.messages.weekly.repeatOn,a=i.length,s=0,l=[],d=[];s<a;s++)l.push(s);for(i=i.slice(e).concat(i.slice(0,e)),r=r.slice(e).concat(r.slice(0,e)),l=l.slice(e).concat(l.slice(0,e)),s=0;s<a;s++)d.push({text:r[s],attributes:{"data-value":l[s],"aria-label":o+" "+i[s]}});t._container.find(".k-recur-weekday-buttons").length>0&&(t._weekDayButtonGroup=new c(t._container.find(".k-recur-weekday-buttons"),{items:d,selection:"multiple",select:function(){var e=t._value,n=t._weekDayButtonGroup.current();e.weekDays=n.map((function(e,t){return{day:Number(t.getAttribute("data-value")),offset:0}})),t.options.mobile||t._trigger()}}))},_weekDayRule:function(e){var t=this,n=(t._weekDay.element||t._weekDay).val(),i=Number((t._weekDayOffset.element||t._weekDayOffset).val()),r=null,o=null;e||("day"===n?(r=le,o=i):"weekday"===n?(r=ce,o=i):"weekend"===n?(r=de,o=i):r=[{offset:i,day:Number(n)}]),t._value.weekDays=r,t._value.positions=o},_weekDayView:function(){var e,t,n,i,r=this,o=r._value.weekDays,a=r._value.positions,s=r._weekDayOffset;o&&(n=o.length,a&&(7===n?(t="day",e=a):5===n?(t="weekday",e=a):2===n&&(t="weekend",e=a)),t||(t=(o=o[0]).day,e=o.offset||""),s[i=s.value?"value":"val"](e),r._weekDay[i](t))},_initWeekDay:function(){var t,i=this,r=i.options.messages.weekdays,o=i.options.messages.offsetPositions,a=i._container.find(".k-recur-weekday"),s=function(){i._weekDayRule(),i._trigger()};a[0]&&(i._weekDayOffset=new l(i._container.find(".k-recur-weekday-offset"),{autoWidth:!0,change:s,dataTextField:"text",dataValueField:"value",dataSource:[{text:o.first,value:"1"},{text:o.second,value:"2"},{text:o.third,value:"3"},{text:o.fourth,value:"4"},{text:o.last,value:"-1"}]}),t=[{text:r.day,value:"day"},{text:r.weekday,value:"weekday"},{text:r.weekend,value:"weekend"}],i._weekDay=new l(a,{autoWidth:!0,value:i.options.start.getDay(),change:s,dataTextField:"text",dataValueField:"value",dataSource:t.concat(e.map(n.culture().calendar.days.names,(function(e,t){return{text:e,value:t}})))}),i._weekDayView())},_initWeekDays:function(){var e=this._value,t=this._weekDayButtonGroup;if(t&&e.weekDays&&e.weekDays.length){for(var n,i=e.weekDays,r=i.length,o=[],a=0;a<r;a++)o.push("[data-value='"+i[a].day+"']");n=t.element.find(o.join(",")),t.select(n)}},_initMonthDay:function(){var e=this,t=e._value,i=e._container.find("[ref-recur-monthday]");i[0]&&(e._monthDay=new n.ui.NumericTextBox(i,{spinners:e.options.spinners,min:1,max:31,decimals:0,format:"#",value:t.monthDays?t.monthDays[0]:e.options.start.getDate(),change:function(){var n=this.value();t.monthDays=n?[n]:n,e._trigger()}}),e._monthDay.wrapper.addClass("k-recur-monthday"))},_initCount:function(){var e=this,t=e._container.find("[ref-recur-count]"),n=e._value;e._count=t.kendoNumericTextBox({spinners:e.options.spinners,value:n.count||1,decimals:0,format:"#",min:1,change:function(){n.count=this.value(),e._trigger()}}).data("kendoNumericTextBox"),e._count.wrapper.addClass("k-recur-count")},_initUntil:function(){var e=this,t=e._container.find("[ref-recur-until]"),i=e.options.start,r=e._value,o=r.until,a=o&&o<i?o:i,s=e.wrapper.closest(".k-scheduler-edit-form").find("[name=start]:visible"),l=n.format(n.ui.Validator.prototype.options.messages.date,e.options.messages.end.on),c=n.ui.Validator.prototype.options.messages.dateCompare,d=new Date(i.getFullYear(),i.getMonth(),i.getDate(),23,59,59);t.attr("data-validDate-msg",l),t.attr("data-untilDateCompare-msg",c),0===s.length&&(s=e.wrapper.closest(".k-scheduler-edit-form").find("[name=start]")),s.length>0&&s.val()&&d<(a=n.parseDate(s.val()))&&(d=a),e._until=t.kendoDatePicker({min:a,value:o||d,change:function(){var t=this.value();t&&(r.until=new Date(t.getFullYear(),t.getMonth(),t.getDate(),23,59,59)),e._trigger()}}).data("kendoDatePicker"),e._until.wrapper.addClass("k-recur-until"),s&&s.on("change",(function(){var t=e._until.element,n=Boolean(t.attr("readonly")),i=!Boolean(t.is("[disabled]")||t.parents("fieldset").is(":disabled"));e._until.setOptions({min:s.val(),readonly:n,enable:i})}))},_trigger:function(){this.options.mobile||this.trigger("change")}}),he=ue.extend({init:function(e,t){var n=this;ue.fn.init.call(n,e,t),n._initFrequency(),n._initContainer(),n.value(n.options.value)},options:{name:"RecurrenceEditor"},events:["change"],destroy:function(){var e=this;e._frequency.destroy(),this._weekDayButtonGroup&&this._weekDayButtonGroup.destroy(),e._container.find("input[type=radio],input[type=checkbox]").off(z+e._namespace),n.destroy(e._container),ue.fn.destroy.call(e)},value:function(e){var n,i,r=this,o=r.options.timezone;if(e===t)return r._value.freq?ae(r._value,o):"";r._value=re(e,o)||{},(n=r._value.freq)?(i=r._frequency.element.find("[data-value='"+n+"']"),r._frequency.select(i)):r._frequency.select(0),r._initView(r._frequency.current().data("value"))},_initContainer:function(){var t=this.element,n=e('<div class="k-recur-view" />'),i=t.parent(".k-edit-field");i[0]?n.insertAfter(i):t.append(n),this._container=n},_initFrequency:function(){var t,n=this,i=n.options,r=i.frequencies,o=i.messages.frequencies,a=e('<div class="k-button-group-stretched k-flex-1"/>').attr({title:i.messages.recurrenceEditorTitle});r=e.map(r,(function(e){return{text:o[e],attributes:{"data-value":e,"aria-label":i.messages.repeat+o[e]}}})),(t=r[0])&&t.attributes&&"never"===t.attributes["data-value"]&&(t.attributes["data-value"]=""),n.element.append(a),n._frequency=new c(a,{items:r,select:function(){n._value={},n._initView(n._frequency.current().data("value")),n.trigger("change")}})},_initView:function(t){var i,r=this,o=r._value,a=r.options,s={frequency:t||"never",firstWeekDay:a.firstWeekDay,messages:a.messages[t],end:a.messages.end};r._weekDayButtonGroup&&(r._weekDayButtonGroup.destroy(),r._container.find(".k-recur-weekday-buttons").empty(),r._weekDayButtonGroup=null),n.destroy(r._container),i=e(se(s)),n.applyStylesFromKendoAttributes(i,["width"]),r._container.html(i),t?(o.freq=t,"weekly"!==t||o.weekDays||(o.weekDays=[{day:a.start.getDay(),offset:0}]),r._weekDayButtons(a.firstWeekDay),r._initInterval(),r._initWeekDays(),r._initMonthDay(),r._initWeekDay(),r._initMonth(),r._initCount(),r._initUntil(),r._period(),r._end()):r._value={}},_initMonth:function(){var t,i=this,r=i._value,o=r.months||[i.options.start.getMonth()+1],a=i._container.find(".k-recur-month");a[0]&&(t={autoWidth:!0,change:function(){r.months=[Number(this.value())],i.trigger("change")},dataTextField:"text",dataValueField:"value",dataSource:e.map(n.culture().calendar.months.names,(function(e,t){return{text:e,value:t+1}}))},i._month1=new l(a[0],t),i._month2=new l(a[1],t),o&&(o=o[0],i._month1.value(o),i._month2.value(o)))},_end:function(){var e,t=this,n=t._value,i=t._container,r=t._namespace,o=function(e){t._toggleEnd(e.currentTarget.value),t.trigger("change")};t._buttonNever=i.find(".k-recur-end-never").on(z+r,o),t._buttonCount=i.find(".k-recur-end-count").on(z+r,o),t._buttonUntil=i.find(".k-recur-end-until").on(z+r,o),n.count?e="count":n.until&&(e="until"),t._toggleEnd(e)},_period:function(){var e=this,t=e._value,n="monthly"===t.freq,i=n?e._toggleMonthDay:e._toggleYear,r=".k-recur-"+(n?"month":"year")+"-radio",o=e._container.find(r);(n||"yearly"===t.freq)&&(o.on(z+e._namespace,(function(t){i.call(e,t.currentTarget.value),e.trigger("change")})),e._buttonMonthDay=o.eq(0),e._buttonWeekDay=o.eq(1),i.call(e,t.weekDays?"weekday":"monthday"))},_toggleEnd:function(e){var t,n,i,r,o=this;"count"===e?(o._buttonCount.prop("checked",!0),i=!0,r=!1,t=o._count.value(),n=null):"until"===e?(o._buttonUntil.prop("checked",!0),i=!1,r=!0,t=null,n=o._until.value()):(o._buttonNever.prop("checked",!0),i=r=!1,t=n=null),o._count&&o._count.enable(i),o._until&&o._until.enable(r),o._value.count=t,o._value.until=n},_toggleMonthDay:function(e){var t,n=this,i=!1,r=!0,o=!1;"monthday"===e?(n._buttonMonthDay.prop("checked",!0),t=[n._monthDay.value()],i=!0,r=!1,o=!0):(n._buttonWeekDay.prop("checked",!0),t=null),n._weekDay.enable(r),n._weekDayOffset.enable(r),n._monthDay.enable(i),n._value.monthDays=t,n._weekDayRule(o)},_toggleYear:function(e){var t,n=this,i=!1,r=!0;"monthday"===e?(i=!0,r=!1,t=n._month1.value()):t=n._month2.value(),n._month1.enable(i),n._month2.enable(r),n._value.months=[t],n._toggleMonthDay(e)}});a.plugin(he);var pe=n.template((({headerTitle:e})=>`<div data-role="content"><ul class="k-listgroup k-listgroup-flush"><li class="k-item k-listgroup-item"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${e}</span><div class="k-recur-pattern k-listgroup-form-field-wrapper"></div></label></li><li class="k-item k-listgroup-item k-recur-view"></li></ul></div>`)),fe=n.template((({frequency:e,messages:t})=>("never"!==e?`<label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.repeatEvery)}</span><div class="k-recur-editor-wrap k-listgroup-form-field-wrapper"><input ref-recur-interval type="number" pattern="\\d*"/>`+(t.interval.length?`<span class="k-recur-editor-text">${i(t.interval)}</span>`:"")+"</div></label>":"")+("weekly"===e?`<ul class="k-recur-items-wrap k-listgroup k-listgroup-flush"><li class="k-item k-listgroup-item k-no-click"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.repeatOn)}</span></label></li><div class="k-button-group-stretched k-recur-weekday-buttons" title="${i(t.repeatOn)}"></ul>`:"")+("monthly"===e?`<ul class="k-recur-items-wrap k-listgroup k-listgroup-flush"><li class="k-item k-listgroup-item"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.repeatBy)}</span><div class="k-repeat-rule k-listgroup-form-field-wrapper"></div></label></li><li class="k-monthday-view k-item k-listgroup-item" ${n.attr("style-display")}="none"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.day)}</span><div class="k-listgroup-form-field-wrapper"><input ref-recur-monthday type="number" aria-label="${i(t.date)}" title="${i(t.day)}" pattern="\\d*"/></div></label></li><li class="k-weekday-view k-item k-listgroup-item" ${n.attr("style-display")}="none"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.every)}</span><div class="k-listgroup-form-field-wrapper"><select class="k-recur-weekday-offset" title="${i(t.every)}"></select></div></label></li><li class="k-weekday-view k-item k-listgroup-item" ${n.attr("style-display")}="none"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.day)}</span><div class="k-listgroup-form-field-wrapper"><select class="k-recur-weekday" title="${i(t.day)}"></select></div></label></li></ul>`:"")+("yearly"===e?`<ul class="k-recur-items-wrap k-listgroup k-listgroup-flush"><li class="k-item k-listgroup-item"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.repeatBy)}</span><div class="k-repeat-rule k-listgroup-form-field-wrapper"></div></label></li><li class="k-monthday-view k-item k-listgroup-item" ${n.attr("style-display")}="none"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.day)}</span><div class="k-listgroup-form-field-wrapper"><input ref-recur-monthday type="number" aria-label="${i(t.date)}" title="${i(t.day)}" pattern="\\d*"/></div></label></li><li class="k-weekday-view k-item k-listgroup-item" ${n.attr("style-display")}="none"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.every)}</span><div class="k-listgroup-form-field-wrapper"><select class="k-recur-weekday-offset" title="${i(t.every)}"></select></div></label></li><li class="k-weekday-view k-item k-listgroup-item" ${n.attr("style-display")}="none"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.day)}</span><div class="k-listgroup-form-field-wrapper"><select class="k-recur-weekday" title="${i(t.day)}"></select></div></label></li><li class="k-item k-item k-listgroup-item"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.month)}</span><div class="k-listgroup-form-field-wrapper"><select class="k-recur-month" title="${i(t.month)}"></select></div></label></li></ul>`:""))),me=n.template((({endPattern:e,messages:t})=>"count"===e?`<label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.after)}</span><div class="k-listgroup-form-field-wrapper"><input ref-recur-count aria-label="${i(t.occurrence)}" type="number" pattern="\\d*" /></div></label>`:"until"===e?`<label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${i(t.on)}</span><div class="k-listgroup-form-field-wrapper"><input type="date" aria-label="${i(t.on)}" ref-recur-until /></div></label>`:void 0)),ge=n.template((({dataSource:e,value:t})=>'<select class="k-scheduler-select">'+e.map((e=>`<option value="${e.value}" ${t===e.value?"selected":""}>${i(e.text)}</option>`)).join("")+"</select>")),ve=ue.extend({init:function(e,t){var r=this;ue.fn.init.call(r,e,t),t=r.options,r._optionTemplate=n.template((({value:e,text:t})=>`<option value="${i(e)}">${i(t)}</option>`)),r.value(t.value),r._pane=t.pane||r.wrapper.closest("[data-role=pane]").data("kendoPane"),r._initRepeatButton(),r._initParentRepeatEnd(),r._defaultValue=r._value},options:{name:"MobileRecurrenceEditor",animations:{left:"slide",right:"slide:right"},mobile:!0,messages:{cancel:"Cancel",update:"Save",endTitle:"Repeat ends",repeatTitle:"Repeat pattern",headerTitle:"Repeat event",end:{patterns:{never:"Never",after:"After...",on:"On..."},never:"Never",after:"End repeat after",on:"End repeat on"},daily:{interval:""},hourly:{interval:""},weekly:{interval:""},monthly:{interval:"",repeatBy:"Repeat by: ",dayOfMonth:"Day of the month",dayOfWeek:"Day of the week",repeatEvery:"Repeat every",every:"Every",day:"Day "},yearly:{interval:"",repeatBy:"Repeat by: ",dayOfMonth:"Day of the month",dayOfWeek:"Day of the week",repeatEvery:"Repeat every: ",every:"Every",month:"Month",day:"Day"}}},events:["change"],value:function(e){var n=this,i=n.options.timezone;if(e===t)return n._value.freq?ae(n._value,i):"";n._value=re(e,i)||{}},destroy:function(){this._destroyView(),n.destroy(this._endFields),this.element.off(z+this._namespace),ue.fn.destroy.call(this)},_initInterval:function(){var e=this,t=e._value;e._container.find("[ref-recur-interval]").val(e._value.interval||1).on(P+e._namespace,(function(n){t.interval=n.target.value,e._trigger()}))},_initRepeatButton:function(){var t=this,i=t.options.messages.frequencies[this._value.freq||"never"];t._chevronButton=e(n.ui.icon("chevron-right")),t._repeatValue=e('<span class="">'+i+"</span>"),t.element.append(t._repeatValue).append(t._chevronButton),t.element.parents("li.k-item").on(z+t._namespace,(function(e){e.preventDefault(),t._createView("repeat"),t._pane.navigate(t._view,t.options.animations.left)}))},_endLiItem:function(){return'<li class="k-item k-listgroup-item"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">'+this.options.messages.end.mobileLabel+"</span></label></li>"},_initParentRepeatEnd:function(){var t=this,n=e(t._endLiItem()).insertAfter(t.element.parents("li.k-item")),i=e('<div class="k-scheduler-recur-end-wrap k-listgroup-form-field-wrapper"><span class="k-scheduler-recur-end"></span></div>').appendTo(n.find(".k-label"));n.on(z+t._namespace,(function(e){e.preventDefault(),t._navigateToView("repeat")})),t._endParentLabelField=n.toggle(!!t._value.freq),t._endParentEndButton=i.find(".k-scheduler-recur-end").text(t._endText())},_initRepeatEnd:function(){var t=this,i=e(t._endLiItem()).insertAfter(t._container),r=e(`<div class="k-scheduler-recur-end-wrap k-listgroup-form-field-wrapper"><span class="k-scheduler-recur-end"></span>${n.ui.icon("chevron-right")}</div>`).appendTo(i.find(".k-label"));i.on(z+t._namespace,(function(e){e.preventDefault(),t._navigateToView("end")})),t._endLabelField=i.toggleClass("k-disabled",!t._value.freq),t._endButton=r.find(".k-scheduler-recur-end").text(t._endText())},_navigateToView:function(e){var t=this;t._createView(e),t._pane.navigate(t._view,t.options.animations.left)},_endText:function(){var e=this._value,t=this.options.messages.end,i=t.never;return e.count?i=n.format("{0} {1}",t.after,e.count):e.until&&(i=n.format("{0} {1:d}",t.on,e.until)),i},_initFrequency:function(){var t=this,i=t.options.messages.frequencies,r=ge({dataSource:e.map(this.options.frequencies,(function(e){return{text:i[e],value:"never"!==e?e:""}})),value:t._value.freq||"",ns:n.ns});t._view.element.find(".k-recur-pattern").append(r),t._view.element.find(".k-scheduler-select").on(P+t._namespace,(function(n){var i=n.target.value;t._value={freq:i},t._defaultValue=e.extend({},t._value),t._initRepeatView(),t._endButton.text(t._endText()),t._endParentEndButton.text(t._endText())}))},_initEndNavigation:function(){var e=this,t=e.options.messages.end.patterns,i=e._value,r="";i.count?r="count":i.until&&(r="until");var o=ge({dataSource:[{text:t.never,value:""},{text:t.after,value:"count"},{text:t.on,value:"until"}],value:r,ns:n.ns});e._view.element.find(".k-recur-pattern").append(o),e._view.element.find(".k-scheduler-select").on(P+e._namespace,(function(t){var r=t.target.value,o=null,a=null;e._initEndView(r),e._count.length?(o=e._count.val(),a=null):e._until.length&&(o=null,a=e._until.val?n.parseDate(e._until.val(),"yyyy-MM-dd"):e._until.value()),i.count=o,i.until=a}))},_createView:function(t){var r=this,o=r.options.messages,a=o["repeat"===t?"repeatTitle":"endTitle"],s='<div data-role="view" class="k-popup-edit-form k-scheduler-edit-form" id="recurrence"><div data-role="header" class="k-appbar k-appbar-primary">'+n.html.renderButton(`<button class="k-header-cancel k-scheduler-cancel" title="${o.cancel}" aria-label="${o.cancel}"></button>`,{fillMode:"flat",icon:"chevron-left"})+'<span class="k-spacer"></span>'+`<span>${i(o.headerTitle)}</span><span class="k-spacer"></span>`+n.html.renderButton(`<button class="k-header-done k-scheduler-update" title="${o.update}" aria-label="${o.update}"></button>`,{fillMode:"flat",icon:"check"})+"</div>",l=r._pane.view().id;r._view=r._pane.append(s+pe({headerTitle:a})),r._view.element.on(z+r._namespace,".k-scheduler-cancel, .k-scheduler-update",(function(t){t.preventDefault(),t.stopPropagation(),e(this).hasClass("k-scheduler-update")?(r.trigger("change"),r._defaultValue=e.extend({},r._value)):r._value=r._defaultValue;var n=r._value.freq;r._endParentEndButton.text(r._endText()),r._endParentLabelField.toggle(!!n&&"never"!==n),r._endButton.text(r._endText()),r._repeatValue.text(o.frequencies[n||"never"]),r._pane.one("viewShow",(function(){r._destroyView()})),r._pane.navigate(l,r.options.animations.right)})),r._container=r._view.element.find(".k-recur-view"),"repeat"===t?(r._initFrequency(),r._initRepeatView(),r._initRepeatEnd()):(r._initEndNavigation(),r._initEndView())},_destroyView:function(){this._view&&(this._view.destroy(),this._view.element.remove(),this._container=null),this._view=null},_initRepeatView:function(){var t=this,i=t._value.freq||"never",r={frequency:i,firstWeekDay:t.options.firstWeekDay,messages:t.options.messages[i]},o=fe(r),a=e(o);n.applyStylesFromKendoAttributes(a,["display"]);var s=t._container=t._container||this._pane.view().content.find("li.k-recur-view"),l=t._value;if(t._endLabelField&&t._endLabelField.toggleClass("k-disabled","never"===i),n.destroy(s),s.html(a),!o)return t._value={},void s.hide();s.show(),"weekly"!==i||l.weekDays||(l.weekDays=[{day:t.options.start.getDay(),offset:0}]),t._weekDayButtons(t.options.firstWeekDay),t._initInterval(),t._initMonthDay(),t._initWeekDays(),t._initWeekDay(),t._initMonth(),t._period()},_initMonthDay:function(){var e=this,t=e._value;(e._monthDay=e._container.find("[ref-recur-monthday]")).attr({min:1,max:31}).val(t.monthDays?t.monthDays[0]:e.options.start.getDate()).on(P+e._namespace,(function(n){t.count=n.target.value,e._trigger()}))},_initCount:function(){var e=this,t=e._count=e._container.find("[ref-recur-count]"),n=e._value;t.val(n.count||1).on(P+e._namespace,(function(t){n.count=t.target.value,e._trigger()})),t.parent().addClass("k-recur-count")},_initEndView:function(e){var i=this,r=i._value;e===t&&(r.count?e="count":r.until&&(e="until"));var o={endPattern:e,messages:i.options.messages.end};n.destroy(i._container),i._container.html(me(o)),i._initCount(),i._initUntil()},_initWeekDay:function(){var t,i=this,r=i.options.messages.weekdays,o=i.options.messages.offsetPositions,a=i._container.find(".k-recur-weekday"),s=function(){i._weekDayRule(),i.trigger("change")};a[0]&&(i._weekDayOffset=i._container.find(".k-recur-weekday-offset").html(i._options([{text:o.first,value:"1"},{text:o.second,value:"2"},{text:o.third,value:"3"},{text:o.fourth,value:"4"},{text:o.last,value:"-1"}])).on("change",s),t=(t=[{text:r.day,value:"day"},{text:r.weekday,value:"weekday"},{text:r.weekend,value:"weekend"}]).concat(e.map(n.culture().calendar.days.names,(function(e,t){return{text:e,value:t}}))),i._weekDay=a.html(i._options(t)).on("change",s).val(i.options.start.getDay()),i._weekDayView())},_initMonth:function(){var t=this,i=t._value,r=t.options.start,o=i.months||[r.getMonth()+1],a=t._container.find(".k-recur-month"),s=n.culture().calendar.months.names;if(a[0]){var l=e.map(s,(function(e,t){return{text:e,value:t+1}}));a.html(t._options(l)).on("change",(function(){i.months=[Number(this.value)]})),t._monthSelect=a,o&&a.val(o[0])}},_period:function(){var e=this,t=e._value,i=e._container,r=e.options.messages[t.freq],o=i.find(".k-repeat-rule"),a=i.find(".k-weekday-view"),s=i.find(".k-monthday-view");if(o[0]){var l=t.weekDays?"weekday":"monthday",c=ge({value:l,dataSource:[{text:r.dayOfMonth,value:"monthday"},{text:r.dayOfWeek,value:"weekday"}],ns:n.ns}),d=function(n){var i=e._weekDay.val(),r=e._weekDayOffset.val(),o=e._monthDay.val(),l=e._monthSelect?e._monthSelect.val():null;"monthday"===n?(t.weekDays=null,t.monthDays=o?[o]:o,t.months=l?[Number(l)]:l,a.hide(),s.show()):(t.monthDays=null,t.months=l?[Number(l)]:l,t.weekDays=[{offset:Number(r),day:Number(i)}],a.show(),s.hide())};o.append(c),o.find(".k-scheduler-select").on(P+e._namespace,(function(e){d(e.target.value)})),d(l)}},_initUntil:function(){var e=this,t=e._container.find("[ref-recur-until]"),i=e.options.start,r=e._value,o=r.until,a=o&&o<i?o:i,s=n.format(n.ui.Validator.prototype.options.messages.date,e.options.messages.end.on),l=n.ui.Validator.prototype.options.messages.dateCompare;t.attr("data-validDate-msg",s),t.attr("data-untilDateCompare-msg",l),n.support.input.date?(e._until=t.attr("min",n.toString(a,"yyyy-MM-dd")).val(n.toString(o||i,"yyyy-MM-dd")).on("change",(function(){var t=n.parseDate(this.value,"yyyy-MM-dd");t&&(r.until=t),e._trigger()})),e._until.parent().addClass("k-recur-until")):(e._until=t.kendoDatePicker({min:a,value:o||i,change:function(){var t=this.value();t&&(r.until=t),e._trigger()}}).data("kendoDatePicker"),e._until.wrapper.addClass("k-recur-until"))},_options:function(e,t){var n=0,i="",r=e.length,o=this._optionTemplate;for(t&&(i+=o({value:"",text:t}));n<r;n++)i+=o(e[n]);return i}});a.plugin(ve)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=n.date.setTime,o=i.SchedulerView,a=n._outerWidth,s=n._outerHeight,l=e.extend,c=n.htmlEncode,d=n.date.getDate,u=n.date.getMilliseconds,h=n.date.MS_PER_DAY,p=n.date.MS_PER_MINUTE,f="k-current-time",m="k-current-time-arrow",g="k-scheduler-header-wrap",v="k-event-inverse",_=.8666,b=".",y=".kendoTimelineView",w=n.template((({title:e,start:t,end:i})=>`<div><div class="k-event-template k-event-time">${c(n.format("{0:t} - {1:t}",t,i))}</div><div class="k-event-template">${e}</div></div>`)),k=n.template((({date:e})=>`<span class='k-link k-nav-day'>${n.format("{0:m}",e)}</span>`)),x=e=>`<div role="button" aria-label="${c(e.ariaLabel)}" data-${e.ns}uid="${e.uid}" `+(e.resources[0]?`${n.attr("style-background-color")}="${e.resources[0].color}" ${n.attr("style-border-color")}="${e.resources[0].color}" class="k-event">`:'class="k-event">')+'<span class="k-event-actions">'+`${e.tail?n.ui.icon("caret-alt-left"):""}`+`${e.isException()?n.ui.icon("arrows-no-repeat"):e.isRecurring()?n.ui.icon("arrow-rotate-cw"):""}</span>`+`${n.template(e.template)(e)}<span class="k-event-actions">`+(e.showDelete?`<a href="#" class="k-link k-event-delete" title="${e.messages.destroy}" aria-label="${e.messages.destroy}">${n.ui.icon("x")}</a>`:"")+`${e.head?n.ui.icon("caret-alt-right"):""}</span>`+(e.resizable&&!e.tail?'<span class="k-resize-handle k-resize-w"></span>':"")+(e.resizable&&!e.head?'<span class="k-resize-handle k-resize-e"></span>':"")+"</div>";function C(e){var t=new Date(1980,1,1,0,0,0);return r(t,u(e)),t}function S(e){var t=0;if(e.columns){for(var n=0;n<e.columns.length;n++)t+=S(e.columns[n]);return e.colspan=t,t}return e.colspan=1,1}var T=n.Class.extend({init:function(e){this._view=e},_getTimeSlotByPosition:function(e,t,n){return this._view.groups[n].timeSlotByPosition(e,t)},_hideHeaders:function(){var e=this._view;e.timesHeader.find("table tr").last().hide(),e.datesHeader.find("table tr").last().hide()},_setColspan:function(e){S(e)},_createRowsLayout:function(e,t,n){return this._view._createRowsLayout(e,t,n)},_createVerticalColumnsLayout:function(e,t,n,i){return i},_createColumnsLayout:function(e,t,n){return this._view._createColumnsLayout(e,t,n)},_getRowCount:function(){return this._view._groupCount()},_getGroupsCount:function(){return 1},_addContent:function(e,t,i,r,o,a,s,l){for(var c=this._view,d="",u=c.options,h=function(t){var i,r,o="",a="";return n.date.isToday(e[m])&&(a+="k-today"),(n.date.getMilliseconds(t)<n.date.getMilliseconds(u.workDayStart)||n.date.getMilliseconds(t)>=n.date.getMilliseconds(u.workDayEnd)||!c._isWorkDay(e[m]))&&(a+=" k-nonwork-hour"),o+="<td"+(""!==a?' class="'+a+'"':"")+">",i=n.date.getDate(e[m]),n.date.setTime(i,n.date.getMilliseconds(t)),o+=s({date:i,resources:(r=l?p:f,function(){return c._resourceBySlot({groupIndex:r})})}),o+="</td>"},p=0;p<r;p++){d+="<tr>";for(var f=0;f<i;f++)for(var m=0,g=t;m<g;m++)d+=c._forTimeRange(o,a,h);d+="</tr>"}return d},_addTimeSlotsCollections:function(e,t,n,i,r){var o=this._view,a=n.length;r&&(a=Math.floor(a/e));for(var s=0;s<e;s++){var l,c=0,d=o.groups[s];r&&(c=s);var h=0;r||(h=s);for(var p=n[c*a].children,f=p.length/(r?1:e),m=f/t,g=0;g<t;g++){var v=g*m+f*h;l=u(new Date(+o.startTime()));for(var _=0;_<m;_++)o._addTimeSlotToCollection(d,p,_,v,g,l,i),l+=i}}},_getVerticalGroupCount:function(e){return e},_getVerticalRowCount:function(e,t,n){return this._view._isVerticallyGrouped()?e[t].maxRowCount:n},_renderEvent:function(e,t,n,i,r,o){var a,s=this._view;(a=s._createEventElement(n.occurrence,t,r.head||n.head,r.tail||n.tail)).appendTo(o).css({top:0,height:s.options.eventHeight});var l={start:n.occurrence._startTime||n.occurrence.start,end:n.occurrence._endTime||n.occurrence.end,element:a,uid:t.uid,slotRange:r,rowIndex:0,offsetTop:0};e.events[t.uid]=l,s._inverseEventColor(a),s.addContinuousEvent(i,r,a,t.isAllDay),s._arrangeRows(l,r,e)},_verticalCountForLevel:function(e){return this._view._rowCountForLevel(e)},_horizontalCountForLevel:function(e){return this._view._columnCountForLevel(e)},_updateCurrentVerticalTimeMarker:function(t,n){var i=this._view,r="<div class='"+f+"'></div>",o=i.datesHeader.find(b+g),s=Math.round(t[0].innerRect(n,new Date(n.getTime()+1),!1).left),l=e(r).prependTo(o).addClass(m+"-down");l.css({left:i._adjustLeftPosition(s-a(l)*_/2),top:o.find("tr").last().prev().position().top}),e(r).prependTo(i.content).css({left:i._adjustLeftPosition(s),width:"1px",height:i.content[0].scrollHeight-1,top:0})},_changeGroup:function(){return t},_prevGroupSlot:function(e,t,n){return this._view._isVerticallyGrouped()?e:t._collection(0,n).last()},_nextGroupSlot:function(e,t,n){return this._view._isVerticallyGrouped()?e:t._collection(0,n).first()},_verticalSlots:function(e,t){return this._view._changeGroup(e,t)},_verticalMethod:function(e){return e?"leftSlot":"rightSlot"},_normalizeVerticalSelection:function(){return t},_horizontalSlots:function(e,t,n,i,r,o,a){var s=this._view,l={};return l.startSlot=t[n](i),l.endSlot=t[n](r),o||!s._isHorizontallyGrouped()||l.startSlot&&l.endSlot||(l.startSlot=l.endSlot=s._changeGroup(e,a)),l},_changeVerticalViewPeriod:function(){return!1},_changeHorizontalViewPeriod:function(e,t,n,i){var r=this._view;return!(e.startSlot&&e.endSlot||t||!r._changeViewPeriod(n,i,!1))},_updateDirection:function(e,t,n,i){this._view._updateDirection(e,t,n,i,!0)},_createMoveHint:function(e,t){var n=this._view,i=e.start,r=n._createEventElement(t.occurrence,t.occurrence,!1,!1);r.addClass("k-event-drag-hint");var o=e.innerRect(t.occurrence.start,t.occurrence.end,n.options.snap),a=o.right-o.left;a<0&&(a=0);var s={left:n._adjustLeftPosition(o.left),top:i.offsetTop,height:i.offsetHeight,width:a};r.css(s),t.occurrence.inverseColor&&r.addClass(v),n._appendMoveHint(r)},_adjustLeftPosition:function(e){var t=this._view;return t._isRtl&&(e-=t.content[0].scrollWidth-t.content[0].clientWidth),e}}),D=n.Class.extend({init:function(e){this._view=e},_getTimeSlotByPosition:function(e,t,n){return this._view.groups[n].timeSlotByPosition(e,t,!0)},_hideHeaders:function(){var e=this._view;e._isVerticallyGrouped()?e.times.find(".k-last").hide():(e.timesHeader.find("table tr").eq(2).hide(),e.datesHeader.find("table tr").eq(2).hide())},_setColspan:function(){},_createRowsLayout:function(e,t,n,i){return this._view._createDateLayout(i,null,!0)},_createVerticalColumnsLayout:function(e,t,n){return this._view._createColumnsLayout(e,null,n)},_createColumnsLayout:function(e,t,n,i){return this._view._createColumnsLayout(e,t,n,i,!0)},_getRowCount:function(e){return this._view._rowCountForLevel(e)},_getGroupsCount:function(){return this._view._groupCount()},_addContent:function(e,t,i,o,a,s,l,c){for(var d,u=this._view,h="",f=u.options,m=function(t,i,r,o,a,s){var c,h,p="",m="",g=u._isVerticallyGrouped()?d:y;return n.date.isToday(e[y])&&(m+="k-today"),(n.date.getMilliseconds(t)<n.date.getMilliseconds(f.workDayStart)||n.date.getMilliseconds(t)>=n.date.getMilliseconds(f.workDayEnd)||!u._isWorkDay(e[g]))&&(m+=" k-nonwork-hour"),p+="<td"+(""!==m?' class="'+m+'"':"")+">",c=n.date.getDate(e[y]),n.date.setTime(c,n.date.getMilliseconds(t)),p+=l({date:c,resources:(h=s,function(){return u._resourceBySlot({groupIndex:h})})}),p+="</td>"},g=new Date(a),v=u.options.minorTickCount,_=u.options.majorTick*p/v||1,b=0;b<o;b++){h+="<tr>",b%(o/u._dates.length)==0&&(d=b/(o/u._dates.length),g=new Date(u._dates[d]),n.date.setTime(g,n.date.getMilliseconds(a)));for(var y=0,w=t;y<w;y++)if(h+=u._forTimeRange(g,s,m,c,i),c){r(g,_,!1);break}h+="</tr>"}return h},_addTimeSlotsCollections:function(e,t,n,i,r){var o=this._view,a=n.length;r&&(a/=t);for(var s=0;s<t;s++){var l,c=0;r&&(c=s);var d,h=n[c*a].children,p=r?a:h.length/(t*e),f=h.length/t;l=u(new Date(+o.startTime()));for(var m=0;m<p;m++){r?(d=0,h=n[m+p*s].children):d=s*f+e*m;for(var g=0;g<e;g++){var v=o.groups[g];o._addTimeSlotToCollection(v,h,g,d,s,l,i)}l+=i}}},_getVerticalGroupCount:function(){return this._view.content.find("tr").length},_getVerticalRowCount:function(e,t,n){return n},_renderEvent:function(e,t,n,i,r,o,a,s){for(var l,c=this._view,d=[],u=r.start.index;u<=r.end.index;u++){(l=c._createEventElement(n.occurrence,t,u!==s,u!==a)).appendTo(o).css({top:0,height:c.options.eventHeight});var h=i._timeSlotCollections[0]._slots[u],p=i.timeSlotRanges(h.start,h.end,!1)[0],f={start:u===a?n.occurrence._startTime||n.occurrence.start:h.start,end:u===s?n.occurrence._endTime||n.occurrence.end:h.end,element:l,uid:t.uid,slotRange:p,rowIndex:0,offsetTop:0};e.events[t.uid]=f,d.push(f),c.addContinuousEvent(i,p,l,t.isAllDay),c._arrangeRows(f,p,e)}e.events[t.uid]=d},_verticalCountForLevel:function(e){return this._view._columnCountForLevel(e)},_horizontalCountForLevel:function(e,t){var n=this._view;return n._columnCountForLevel(t)/n._columnCountForLevel(2)},_updateCurrentVerticalTimeMarker:function(t,n){var i=this._view,r=i.times.find("tr").first().find("th").first(),o=i.times.find("tr").first().find("th").last(),l="<div class='"+f+"'></div>",c=e(l).prependTo(i.times),d=Math.round(t[0].innerRect(n,new Date(n.getTime()+1),!1).top),u={};this._isRtl?(u.right=r.position().left+s(r)-s(o),c.addClass(m+"-left")):(u.left=o.position().left,c.addClass(m+"-right")),u.top=d-a(c)*_/2,c.css(u),e(l).prependTo(i.content).css({top:d,height:"1px",right:"1px",width:i.content[0].scrollWidth,left:0})},_changeGroup:function(e,t,n){var i=this._view;n||(e.groupIndex=t?i.groups.length-1:0)},_prevGroupSlot:function(e){return e},_nextGroupSlot:function(e){return e},_changeDate:function(e,t,n){var i,r,o=this._view.groups[e.groupIndex];if(t){if(i=o._getCollections(!1),(r=n.index-1)>=0)return i[0]._slots[r]}else if(i=o._getCollections(!1),r=n.index+1,i[0]&&i[0]._slots[r])return i[0]._slots[r]},_verticalSlots:function(e,t,n){return this._changeDate(e,t,n)},_verticalMethod:function(e,t){return t?e?"upSlot":"downSlot":e?"leftSlot":"rightSlot"},_normalizeVerticalSelection:function(e,n,i,r){var o=this._view;return r?t:o._normalizeVerticalSelection(e,n,i)},_horizontalSlots:function(e,t,n,i,r,o,a){var s=this._view,l=s._changeGroup(e,a),c={};return l?c.startSlot=c.endSlot=l:s._isVerticallyGrouped()||(c.startSlot=t[n](i),c.endSlot=t[n](r)),c},_changeVerticalViewPeriod:function(e,t,n,i){var r=this._view;return!(e.startSlot&&e.endSlot||t||!r._changeViewPeriod(n,i,r._isVerticallyGrouped()))},_changeHorizontalViewPeriod:function(e,t,n,i){var r=this._view;return!r._isVerticallyGrouped()&&!(e.startSlot&&e.endSlot||t||!r._changeViewPeriod(n,i,!1))},_updateDirection:function(e,t,n,i){var r=this._view;r._updateDirection(e,t,n,i,!r._isVerticallyGrouped())},_createMoveHint:function(e,t){for(var n=this._view,i=e.start,r=e.end,o=i.index;o<=r.index;o++){var a=e.collection._slots[o],s=n._createEventElement(t.occurrence,t.occurrence,!1,!1);s.addClass("k-event-drag-hint");var l={left:a.offsetLeft+2,top:a.offsetTop,height:n.options.eventHeight,width:a.offsetWidth};s.css(l),t.occurrence.inverseColor&&s.addClass(v),n._appendMoveHint(s)}},_adjustLeftPosition:function(e){var t=this._view;return t._isRtl&&!t._isVerticallyGrouped()&&(e-=t.content[0].scrollWidth-t.content[0].offsetWidth),e}});n.ui.scheduler.TimelineGroupedView=T,n.ui.scheduler.TimelineGroupedByDateView=D;var A=o.extend({init:function(t,n){var i=this,r=e("<div class='k-event'></div>").appendTo(document.body);o.fn.init.call(i,t,n),i._zeroWidthEventOffset=r.outerWidth(),r.remove(),i._groupedView=i._getGroupedView(),i.title=i.options.title||i.options.name,i._workDays=function(e){if(e.workDays&&e.workDays.length)return e.workDays;var t=[],n=e.workWeekStart%7,i=Math.abs(e.workWeekEnd%7);for(t.push(n);i!=n;)n>6?n-=7:n++,t.push(n);return t}(i.options),i._templates(),i._editable(),i.calculateDateRange(),i._groups(),i._currentTime(!0)},name:"timeline",_isVirtualized:function(){return!1},_getGroupedView:function(){return this._isGroupedByDate()?new n.ui.scheduler.TimelineGroupedByDateView(this):new n.ui.scheduler.TimelineGroupedView(this)},_getNextEventIndexBySlot:function(e,t,i){if(this._isVerticallyGrouped())return n.ui.SchedulerView.fn._getNextEventIndexBySlot.call(this,e,t,i);for(var r=0,o=0;o<t.length;o++)if(e.startDate()>t[o].start.startDate())r++;else{if(!(e.startDate().getTime()===t[o].start.startDate().getTime()&&i>t[o].start.groupIndex))break;r++}return r},_getSelectedSlot:function(e,t,i,r,o,a){return this._isVerticallyGrouped()?n.ui.SchedulerView.fn._getSelectedSlot.call(this,e,t,i,r,o,a):e},_getSortedEvents:function(t){return this._isVerticallyGrouped()?n.ui.SchedulerView.fn._getSortedEvents.call(this,t):t.sort((function(t,n){var i=t.start.startDate().getTime()-n.start.startDate().getTime();return 0===i&&(t.start.isDaySlot&&!n.start.isDaySlot&&(i=-1),!t.start.isDaySlot&&n.start.isDaySlot&&(i=1)),0===i&&(i=t.start.groupIndex-n.start.groupIndex),0===i&&(i=e(t.element).index()-e(n.element).index()),i}))},_currentTimeMarkerUpdater:function(){this._updateCurrentTimeMarker(new Date)},_scrollTo:function(e,t){o.fn._scrollTo.call(this,e,t);var n=e.offsetLeft,i=e.offsetWidth,r=t.scrollLeft,a=t.clientWidth,s=n+i,l=0;l=r>n?n:s>r+a?i<=a?s-a:n:r,t.scrollLeft=l},_updateCurrentTimeMarker:function(t){var i=this.options;if(this.datesHeader.find(b+f).remove(),this.times.find(b+f).remove(),this.content.find(b+f).remove(),this._isInDateSlot({start:t,end:t})){if(!1===i.currentTimeMarker.useLocalTimezone){var r=i.dataSource.options.schema.timezone;if(i.dataSource&&r){var o=n.timezone.offset(t,r);t=n.timezone.convert(t,t.getTimezoneOffset(),o)}}for(var s=i.group&&"vertical"!=i.group.orientation?this.groups.length:1,l=0;l<s;l++){var c=this.groups[l];if(!c)return;var d=n.date.toUtcTime(t),u=c.timeSlotRanges(d,d+1);if(0===u.length)return;if(u[0].collection.slotByStartDate(t))if(this._isVerticallyGrouped())this._groupedView._updateCurrentVerticalTimeMarker(u,t);else{var h="<div class='"+f+"'></div>",p=this.datesHeader.find(b+g),v=Math.round(u[0].innerRect(t,new Date(t.getTime()+1),!1).left),y=e(h).prependTo(p).addClass(m+"-down");y.css({left:this._adjustLeftPosition(v-a(y)*_/2),top:p.find("tr").last().prev().position().top}),e(h).prependTo(this.content).css({left:this._adjustLeftPosition(v),width:"1px",height:this.content[0].scrollHeight-1,top:0})}}}},_adjustLeftPosition:function(e){return this._groupedView._adjustLeftPosition(e)},_currentTime:function(e){var n=this,i=n.options.currentTimeMarker;!1!==i&&i.updateInterval!==t&&(n._currentTimeMarkerUpdater(),e&&(n._currentTimeUpdateTimer=setInterval(this._currentTimeMarkerUpdater.bind(n),i.updateInterval)))},_editable:function(){this.options.editable&&(this._isMobile()?this._touchEditable():this._mouseEditable())},_mouseEditable:function(){var t=this;t.element.on("click"+y,".k-event a:has(.k-i-x),.k-event a:has(.k-svg-i-x)",(function(i){t.trigger("remove",{uid:e(this).closest(".k-event").attr(n.attr("uid"))}),i.preventDefault()})),!1!==t.options.editable.create&&t.element.on("dblclick"+y,".k-scheduler-content td",(function(e){var n=t._slotByPosition(e.pageX,e.pageY);if(n){var i=t._resourceBySlot(n);t.trigger("add",{eventInfo:l({start:n.startDate(),end:n.endDate()},i)})}e.preventDefault()})),!1!==t.options.editable.update&&t.element.on("dblclick"+y,".k-event",(function(i){t.trigger("edit",{uid:e(this).closest(".k-event").attr(n.attr("uid"))}),i.preventDefault()}))},_touchEditable:function(){var i=this,r=0;n.support.mobileOS.android&&(r=5),!1!==i.options.editable.create&&(i._addUserEvents=new n.UserEvents(i.element,{threshold:r,useClickAsTap:!n.support.browser.edge,filter:".k-scheduler-content td",tap:function(e){if(!i._scrolling){var n=e.x.location!==t?e.x.location:e.x,r=e.y.location!==t?e.y.location:e.y,o=i._slotByPosition(n,r);if(o){var a=i._resourceBySlot(o);i.trigger("add",{eventInfo:l({start:o.startDate(),end:o.endDate()},a)})}e.preventDefault()}}})),!1!==i.options.editable.update&&(i._editUserEvents=new n.UserEvents(i.element,{threshold:r,useClickAsTap:!n.support.browser.edge,filter:".k-event",tap:function(t){if(!i._scrolling){var r=e(t.target).closest(".k-event");e(t.touch.initialTouch).is(".k-i-x,.k-svg-i-x")?i.trigger("remove",{uid:r.attr(n.attr("uid"))}):r.hasClass("k-event-active")||i.trigger("edit",{uid:r.attr(n.attr("uid"))}),t.preventDefault()}}}))},_slotByPosition:function(e,t){var i,r,o=this.content,a=o.offset();if(e-=a.left,t-=a.top,this._isRtl){var s=n.support.browser;s.mozilla||s.webkit&&s.version>=85?(e+=o[0].scrollWidth-o[0].offsetWidth,e+=o[0].scrollLeft):s.msie?(e-=n.scrollLeft(o),e+=o[0].scrollWidth-o[0].offsetWidth):s.webkit&&(e+=o[0].scrollLeft)}else e+=o[0].scrollLeft;for(t+=o[0].scrollTop,e=Math.ceil(e),t=Math.ceil(t),r=0;r<this.groups.length;r++)if(i=this._groupedView._getTimeSlotByPosition(e,t,r))return i;return null},options:{name:"TimelineView",title:"Timeline",selectedDateFormat:"{0:D}",selectedShortDateFormat:"{0:d}",selectedMobileDateFormat:"{0:MMM dd}",date:n.date.today(),startTime:n.date.today(),endTime:n.date.today(),showWorkHours:!1,minorTickCount:2,editable:!0,workDayStart:new Date(1980,1,1,8,0,0),workDayEnd:new Date(1980,1,1,17,0,0),workWeekStart:1,workWeekEnd:5,majorTick:60,eventHeight:25,eventMinWidth:0,columnWidth:100,groupHeaderTemplate:({text:e})=>e,majorTimeHeaderTemplate:({date:e})=>n.toString(e,"t"),slotTemplate:()=>"&nbsp;",eventTemplate:w,dateHeaderTemplate:k,footer:{command:"workDay"},currentTimeMarker:{updateInterval:1e4,useLocalTimezone:!0},ongoingEvents:{cssClass:null,enabled:!0,updateInterval:6e4},messages:{defaultRowText:"All events",showFullDay:"Show full day",showWorkDay:"Show business hours"}},events:["remove","add","edit"],_templates:function(){var e=this.options,t=l({},n.Template,e.templateSettings);this.eventTemplate=n.template(x),this.majorTimeHeaderTemplate=n.template(e.majorTimeHeaderTemplate,t),this.dateHeaderTemplate=n.template(e.dateHeaderTemplate,t),this.slotTemplate=n.template(e.slotTemplate,t),this.groupHeaderTemplate=n.template(e.groupHeaderTemplate,t)},_render:function(t){var n=this;t=t||[],n._dates=t,n._startDate=t[0],n._endDate=t[t.length-1||0],n._calculateSlotRanges(),n.createLayout(n._layout(t)),n._content(t),n._footer(),n._setContentWidth(),n.refreshLayout(),n.datesHeader.on("click"+y,".k-nav-day",(function(t){var i=e(t.currentTarget).closest("th"),r=n._slotByPosition(i.offset().left,n.content.offset().top);n.trigger("navigate",{view:"timeline",date:r.startDate()})})),n._groupedView._hideHeaders()},_setContentWidth:function(){var e=this.content.width(),t=this.content.find("table"),n=100,i=t.find("tr").first().children().length*this.options.columnWidth;e<i&&(n=Math.ceil(i/e*100)),t.add(this.datesHeader.find("table")).css("width",n+"%")},_calculateSlotRanges:function(){var e=this._dates,t=this.startTime(),i=this.endTime();(i=u(i))===(t=u(t))?i+=h-1:i<t&&(i+=h);for(var o=[],a=0;a<e.length;a++){var s=d(e[a]);r(s,t);var l=d(e[a]);r(l,i),o.push({start:n.date.toUtcTime(s),end:n.date.toUtcTime(l)})}this._slotRanges=o},_forTimeRange:function(e,t,n,i,o){e=C(e),t=C(t);var a,s=u(e),l=u(t),c=this.options.minorTickCount,d=this.options.majorTick*p,f=d/c||1,m=new Date(+e),g=0,v="";for(a=h/f,s!=l&&(s>l&&(l+=h),a=(l-s)/f),a=i?1:Math.round(a),o&&(a*=o);g<a;g++){var _=g%(d/f),b=0===_,y=c;if(a%c!=0)b&&a-(g+1)<c&&(y=a%c);v+=n(m,b,_<c-1,_===c-1,y,g%o),i||(o?g%o==o-1&&r(m,f,!1):r(m,f,!1))}return v},_layout:function(e){for(var t=[],n=[],i=this,r=[{text:i.options.messages.defaultRowText}],o=i._groupedView,a=[],s=0;s<i.options.minorTickCount;s++)a.push({text:"&#8203;",minorTicks:!0});this._forTimeRange(i.startTime(),i.endTime(),(function(e,n,r,s,l){var c=i.majorTimeHeaderTemplate;if(n){var d={text:c({date:e}),className:s?"k-slot-cell":"",columns:a.slice(0,l)};o._setColspan(d),t.push(d)}}));for(var l=0;l<e.length;l++)n.push({text:i.dateHeaderTemplate({date:e[l]}),className:"k-slot-cell",columns:t.slice(0)});var c=this.groupedResources;return c.length&&("vertical"===this._groupOrientation()?(r=o._createRowsLayout(c,null,this.groupHeaderTemplate,n),n=o._createVerticalColumnsLayout(c,null,this.groupHeaderTemplate,n)):n=o._createColumnsLayout(c,n,this.groupHeaderTemplate,n)),{columns:n,rows:r}},_footerItems:function(){var e=this,t=[],n=this.options.footer.command;return e._isMobile()&&t.push(e._defaultTools.todayMobile),n&&"workDay"===n&&(e._isMobile()?t.push(e._defaultTools.fulldayMobile):t.push(e._defaultTools.fulldayDesktop)),t},toggleFullDay:function(){var e=this.options;this.trigger("navigate",{view:this.name||e.name,date:e.date,isWorkDay:!e.showWorkHours})},_columnCountForLevel:function(e){var t=this.columnLevels[e];return t?t.length:0},_rowCountForLevel:function(e){var t=this.rowLevels[e];return t?t.length:0},_isWorkDay:function(e){for(var t=e.getDay(),n=this._workDays,i=0;i<n.length;i++)if(n[i]===t)return!0;return!1},_content:function(e){var t=this,n=t.startTime(),i=this.endTime(),r=1,o=1,a=e.length,s="",l=this.groupedResources,c=this.slotTemplate,d=!1;l.length&&((d="vertical"===t._groupOrientation())?(o=t._groupedView._getRowCount(this.rowLevels.length-1),r=t._groupedView._getGroupsCount()):r=t._groupCount()),s+="<tbody>",s+=t._groupedView._addContent(e,a,r,o,n,i,c,d),s+="</tbody>",this.content.find("table").append(s)},_groups:function(){var e=this._groupCount(),t=this._dates,i=t.length;this.groups=[];for(var o=0;o<e;o++){var a=this._addResourceView(o),s=t[0],l=t[t.length-1||0],c=u(this.startTime()),h=u(this.endTime());0!==c&&h<=c&&(s=d(s),r(s,c),l=d(l),r(l,h)),a.addTimeSlotCollection(s,n.date.addDays(l,1))}this._timeSlotGroups(e,i)},_isHorizontallyGrouped:function(){return this.groupedResources.length&&"horizontal"===this._groupOrientation()},_timeSlotGroups:function(e,t){var n=this._timeSlotInterval(),i=this._isVerticallyGrouped(),r=this.content.find("tr");this._groupedView._addTimeSlotsCollections(e,t,r,n,i)},_addTimeSlotToCollection:function(e,t,n,i,r,o,a){var s=t[n+i],l=e.getTimeSlotCollection(0),c=this._dates[r],d=Date.UTC(c.getFullYear(),c.getMonth(),c.getDate())+o,u=d+a;l.addTimeSlot(s,d,u,!0)},startDate:function(){return this._startDate},endDate:function(){return this._endDate},visibleEndDate:function(){var e=u(this.startTime()),t=u(this.endTime()),i=this.endDate();return 0!==e&&t<=e&&(i=n.date.addDays(i,1)),i},startTime:function(){var e=this.options;return e.showWorkHours?e.workDayStart:e.startTime},endTime:function(){var e=this.options;return e.showWorkHours?e.workDayEnd:e.endTime},_timeSlotInterval:function(){var e=this.options;return e.majorTick/e.minorTickCount*p},nextDate:function(){return n.date.nextDay(this.endDate())},previousDate:function(){return n.date.previousDay(this.startDate())},calculateDateRange:function(){this._render([this.options.date])},render:function(e){this._headerColumnCount=0,this._groups(),this.element.find(".k-event").remove(),e=new n.data.Query(e).sort([{field:"start",dir:"asc"},{field:"end",dir:"desc"}]).toArray();var t=[];this._eventsByResource(e,this.groupedResources,t);for(var i=[],r=0,o=0;o<t.length;o++){var a={groupIndex:o,maxRowCount:0,events:{}};i.push(a),this._renderEvents(t[o],o,a),r<a.maxRowCount&&(r=a.maxRowCount)}this._setRowsHeight(i,t.length,r),this._positionEvents(i,t.length),this._currentTime(!1),this._ongoingEvents(e),this.trigger("activate")},_positionEvents:function(e,t){for(var n=0;n<t;n++){var i=e[n].events;for(var r in i){var o=i[r];if(Array.isArray(o))for(var a=0;a<o.length;a++)this._positionEvent(o[a]);else this._positionEvent(o)}}},_setRowsHeight:function(t,n,i){var r=this.options.eventHeight,o=this._getBottomRowOffset(),a=this._groupedView,s=a._getVerticalGroupCount(n);n=this._isVerticallyGrouped()?s:1;for(var l=0;l<n;l++){var c=a._getVerticalRowCount(t,l,i),d=(r+2)*(c=c||1)+o,u=e(this.times.find("tr")[l]),h=e(this.content.find("tr")[l]);u.height(d),h.height(d)}this._setContentWidth(),this.refreshLayout(),this._refreshSlots()},_getBottomRowOffset:function(){var e,t,n=.5*this.options.eventHeight;return this._isMobile()?(e=30,t=60):(e=15,t=30),n>t?n=t:n<e&&(n=e),n},_positionEvent:function(e){var t=this.options.eventHeight,n=e.slotRange.innerRect(e.start,e.end,!1),i=this._adjustLeftPosition(n.left),r=n.right-n.left;if(r<0&&(r=0),r<this.options.eventMinWidth){var o=e.slotRange.collection,a=o._slots[o._slots.length-1],s=a.offsetLeft+a.offsetWidth;s<i+(r=this.options.eventMinWidth)&&(r=s-n.left)}e.element.css({top:e.slotRange.start.offsetTop+e.rowIndex*(t+2)+"px",left:i,width:r})},_refreshSlots:function(){for(var e=0;e<this.groups.length;e++)this.groups[e].refresh()},_eventsByResource:function(e,i,r,a){var s=i[0];if(s){var l=s.dataSource.view();l=l.filter((function(e){var i=n.getter(s.dataParentValueField)(e);return null===i||i===t||i===a}));for(var c=0;c<l.length;c++){var d=this._resourceValue(s,l[c]),u=new n.data.Query(e).filter({field:s.field,operator:o.groupEqFilter(d)}).toArray();i.length>1?this._eventsByResource(u,i.slice(1),r,d):r.push(u)}}else r.push(e)},_isInDateSlot:function(e){var t=e.start,i=e.end,r=d(this._startDate);return t<n.date.addDays(d(this.visibleEndDate()),1)&&r<=i},_isInTimeSlot:function(e){var t=e._startTime||n.date.toUtcTime(e.start),i=e._endTime||n.date.toUtcTime(e.end),r=this._slotRanges;t===i&&(i+=1);for(var o=0;o<r.length;o++)if(t<r[o].end&&r[o].start<i)return!0;return!1},_adjustEvent:function(e){var t=e.start,i=e.end,o=e._time("start"),a=e._time("end"),s=u(this.startTime()),l=u(this.endTime()),c=null,p=null,f=!1,m=!1;return e.isAllDay&&(t=d(t),o=0,i=d(i),a=h,p=n.date.addDays(i,1)),0===l&&(l=h),l<=s?(o<s&&o>=l&&(c=d(t),r(c,s),m=!0),a>l&&a<=s&&(p=d(i),r(p,l),f=!0)):(s>o?(c=d(t),r(c,s),m=!0):l<=o&&(c=d(t),c=n.date.addDays(c,1),r(c,s),m=!0),l<a?(p=d(i),r(p,l),f=!0):s>a&&(p=d(i),p=n.date.addDays(p,-1),r(p,l),f=!0)),{occurrence:e.clone({start:c||t,end:p||i,_startTime:c?n.date.toUtcTime(c):e._startTime,_endTime:p?n.date.toUtcTime(p):e._endTime,isAllDay:!1}),head:f,tail:m}},_renderEvents:function(e,t,n){var i,r,o;for(r=0,o=e.length;r<o;r++)if(i=e[r],this._isInDateSlot(i)){var a=i.isAllDay||i.duration()>=h,s=this.content;if(a||this._isInTimeSlot(i)){var l=this._adjustEvent(i),c=this.groups[t];if(c._continuousEvents||(c._continuousEvents=[]),this._isInTimeSlot(l.occurrence)){var d=c.slotRanges(l.occurrence,!1)[0],u=d.start.index,p=d.end.index;this._groupedView._renderEvent(n,i,l,c,d,s,u,p)}}}},addContinuousEvent:function(e,t,i,r){e._continuousEvents.push({element:i,isAllDay:r,uid:i.attr(n.attr("uid")),start:t.start,end:t.end})},_createEventElement:function(t,i,r,o){var a=this.eventTemplate,s=this.options.editable,c=this._isMobile(),d=s&&!1!==s.destroy&&!c,u=s&&!1!==s.resize,h=i._time("start"),p=i._time("end"),f=i.start,m=i.end,g=this.eventResources(i);i._startTime&&h!==n.date.getMilliseconds(i.start)&&(f=new Date(h),f=n.timezone.apply(f,"Etc/UTC")),i._endTime&&p!==n.date.getMilliseconds(i.end)&&(m=new Date(p),m=n.timezone.apply(m,"Etc/UTC"));var v=l({},{ns:n.ns,resizable:u,showDelete:d,head:r,tail:o,singleDay:1==this._dates.length,resources:g,inverseColor:!1,messages:this.options.messages,ariaLabel:this._formatEventAriaLabel(i.title,f,m,i.isAllDay),template:this.options.eventTemplate},i,{start:f,end:m}),_=e(a(v));return n.applyStylesFromKendoAttributes(_,["background-color","border-color"]),_},_arrangeRows:function(e,t,n){var i=t.start.index,r=t.end.index,a=e.slotRange.innerRect(e.start,e.end,!1),s=a.right+this.options.eventMinWidth,l=o.collidingEvents(t.events(),a.left,s);t.addEvent({slotIndex:i,slotIndexEnd:r,start:a.left,end:s,zeroWidthEventOffset:this._zeroWidthEventOffset,rectLeft:a.left,rectRight:s,element:e.element,uid:e.uid}),l.push({slotIndex:i,slotIndexEnd:r,start:a.left,end:s,zeroWidthEventOffset:this._zeroWidthEventOffset,uid:e.uid});var c=o.createRows(l);n.maxRowCount<c.length&&(n.maxRowCount=c.length);for(var d=0,u=c.length;d<u;d++)for(var h=c[d].events,p=0,f=h.length;p<f;p++)n.events[h[p].uid].rowIndex=d},_groupCount:function(){var e=this.groupedResources,t=this._groupedView;return e.length?"vertical"===this._groupOrientation()?t._verticalCountForLevel(e.length-1):t._horizontalCountForLevel(e.length-1,this.columnLevels.length-1):1},_updateEventForSelection:function(e){return this._adjustEvent(e.clone()).occurrence},_eventOptionsForMove:function(e){return e.isAllDay?{isAllDay:!1}:{}},_updateEventForResize:function(e){e.isAllDay&&e.set("isAllDay",!1)},_updateMoveHint:function(e,t,n){var i=this.groups[t],r=e.clone({start:e.start,end:e.end}),o=r.duration();if(r.start=new Date(r.start.getTime()+n),r.end=new Date(+r.start+o),this._removeMoveHint(e.uid),this._isInDateSlot(r)&&(r.isAllDay||r.duration()>=h||this._isInTimeSlot(r)))for(var a=this._adjustEvent(r),s=i.slotRanges(a.occurrence,!1),l=0;l<s.length;l++)this._groupedView._createMoveHint(s[l],a)},_appendMoveHint:function(e){e.appendTo(this.content),this._moveHint=this._moveHint.add(e)},_updateResizeHint:function(e,t,i,r){var a=this.groups[t].ranges(i,r,!1,!1);this._removeResizeHint();for(var s=0;s<a.length;s++){var l=a[s],c=l.startSlot(),d=l.innerRect(i,r,!1);d.top=c.offsetTop;var u=d.right-d.left;if(u<0)for(var h=0;h<l.events().length;h++)if(l.events()[h].uid===e.uid){u=l.events()[h].rectRight-d.left;break}var p=l.endSlot().offsetTop+c.offsetHeight-d.top,f=this._adjustLeftPosition(d.left),m=o.fn._createResizeHint.call(this,f,d.top,u,p);this._resizeHint=this._resizeHint.add(m)}var g=this.content;this._resizeHint.appendTo(g),this._resizeHint.find(".k-label-top,.k-label-bottom").text(""),this._resizeHint.first().addClass("k-first").find(".k-label-top").text(n.toString(n.timezone.toLocalDate(i),"t")),this._resizeHint.last().addClass("k-last").find(".k-label-bottom").text(n.toString(n.timezone.toLocalDate(r),"t"))},selectionByElement:function(e){var t=e.offset();return this._slotByPosition(t.left,t.top)},_updateDirection:function(e,t,n,i,r){var o=t[0].start,a=t[t.length-1].end;n&&!r&&o.index===a.index&&o.collectionIndex===a.collectionIndex&&(e.backward=i)},_changeGroup:function(e,t){var n=this[t?"prevGroupSlot":"nextGroupSlot"](e.start,e.groupIndex,!1);return n&&(e.groupIndex+=t?-1:1),this._groupedView._changeGroup(e,t,n),n},prevGroupSlot:function(e,t,n){var i=this.groups[t],r=i.ranges(e,e,n,!1)[0].start;if(!(t<=0))return this._groupedView._prevGroupSlot(r,i,n)},nextGroupSlot:function(e,t,n){var i=this.groups[t],r=i.ranges(e,e,n,!1)[0].start;if(!(t>=this.groups.length-1))return this._groupedView._nextGroupSlot(r,i,n)},_verticalSlots:function(e,t,n,i){var r=this._groupedView,o=r._verticalMethod(i,n),a=t[0].start,s=t[t.length-1].end,l=this.groups[e.groupIndex],c=r._normalizeVerticalSelection(e,t,i,n);return c&&(a=s=c),a=l[o](a),s=l[o](s),n||!this._isVerticallyGrouped()||a&&s||(a=s=r._verticalSlots(e,i,c)),{startSlot:a,endSlot:s}},_horizontalSlots:function(e,t,n,i){var r=i?"upSlot":"downSlot",o=t[0].start,a=t[t.length-1].end,s=this.groups[e.groupIndex],l={};return n?(l.startSlot=s[r](o),l.endSlot=s[r](a),n||!this._isHorizontallyGrouped()||o&&a||(l.startSlot=l.endSlot=this._changeGroup(e,i))):l=this._groupedView._horizontalSlots(e,s,r,o,a,n,i),l},_changeViewPeriod:function(e,t){var n,i,o=t?this.previousDate():this.nextDate(),a=e.start,s=e.end;if(n=new Date(o),i=new Date(o),this._isInRange(n,i))return!1;e.start=n,e.end=i,this._isHorizontallyGrouped()&&(e.groupIndex=t?this.groups.length-1:0);var l=s-a;return t?(s=0===(s=u(this.endTime()))?h:s,r(e.start,s-l),r(e.end,s)):(a=u(this.startTime()),r(e.start,a),r(e.end,a+l)),e.events=[],!0},move:function(e,t,i){var r,o,a,s,l=!1,c=this.groups[e.groupIndex],d=n.keys,u=this._groupedView,h=c.ranges(e.start,e.end,!1,!1);if(t===d.DOWN||t===d.UP){if(l=!0,a=t===d.UP,u._updateDirection(e,h,i,a),s=this._verticalSlots(e,h,i,a),u._changeVerticalViewPeriod(s,i,e,a))return l}else if((t===d.LEFT||t===d.RIGHT)&&(l=!0,a=t===d.LEFT,this._updateDirection(e,h,i,a,!1),s=this._horizontalSlots(e,h,i,a),u._changeHorizontalViewPeriod(s,i,e,a)))return l;if(l){if(r=s.startSlot,o=s.endSlot,i){var p=e.backward;p&&r?e.start=r.startDate():!p&&o&&(e.end=o.endDate())}else r&&o&&(e.start=r.startDate(),e.end=o.endDate());e.events=[]}return l},destroy:function(){var e=this;e.element&&e.element.off(y),e._currentTimeUpdateTimer&&clearInterval(e._currentTimeUpdateTimer),o.fn.destroy.call(this),this._isMobile()&&e.options.editable&&(!1!==e.options.editable.create&&e._addUserEvents.destroy(),!1!==e.options.editable.update&&e._editUserEvents.destroy())},_resourceBySlot:function(e){var t=this.groupedResources,n={},i=this.options.group;if(t.length&&"horizontal"===i.orientation&&i.date){var r,a,s,l,c=e.groupIndex,d=this.columnLevels,u=d[d.length-1],h=t[t.length-1],p=u[c];for(this._setResourceValue(p,h,n),s=d.length-2;s>=3;s--)for(u=d[s],h=t[s-3],r=0,l=0;l<u.length;l++){if((a=(p=u[l]).columns.length)>c-r){this._setResourceValue(p,h,n);break}r+=a}return n}return o.fn._resourceBySlot.call(this,e)}});l(!0,i,{TimelineView:A,TimelineWeekView:A.extend({options:{name:"TimelineWeekView",title:"Timeline Week",selectedDateFormat:"{0:D} - {1:D}",selectedShortDateFormat:"{0:d} - {1:d}",selectedMobileDateFormat:"{0:MMM dd} - {1:dd}",majorTick:120},name:"timelineWeek",calculateDateRange:function(){var e,t=this.options.date,i=n.date.dayOfWeek(t,this.calendarInfo().firstDay,-1),r=[];for(e=0,7;e<7;e++)r.push(i),i=n.date.nextDay(i);this._render(r)}}),TimelineWorkWeekView:A.extend({options:{name:"TimelineWorkWeekView",title:"Timeline Work Week",selectedDateFormat:"{0:D} - {1:D}",selectedShortDateFormat:"{0:d} - {1:d}",selectedMobileDateFormat:"{0:MMM dd} - {1:dd}",majorTick:120},name:"timelineWorkWeek",nextDate:function(){var e=n.date.dayOfWeek(n.date.nextDay(this.endDate()),this.calendarInfo().firstDay,1);return n.date.addDays(e,this._workDays[0])},previousDate:function(){var e=n.date.dayOfWeek(this.startDate(),this.calendarInfo().firstDay,-1),t=this._workDays;return n.date.addDays(e,t[t.length-1]-7)},calculateDateRange:function(){var e=this.options,t=e.date,i=n.date.dayOfWeek,r=i(t,this.calendarInfo().firstDay,-1),o=i(r,e.workWeekStart,1),a=i(o,e.workWeekEnd,1),s=[],l=e.workDays&&e.workDays.length?e.workDays.map((function(e){return i(r,e,1).getTime()})):null;for(l&&(a=i(o=r,this.calendarInfo().firstDay+6,1));o<=a;)l&&l.indexOf(o.getTime())>-1?s.push(o):l||s.push(o),o=n.date.nextDay(o);this._render(s)}}),TimelineMonthView:A.extend({options:{name:"TimelineMonthView",title:"Timeline Month",selectedDateFormat:"{0:D} - {1:D}",selectedShortDateFormat:"{0:d} - {1:d}",workDayStart:new Date(1980,1,1,0,0,0),workDayEnd:new Date(1980,1,1,23,59,59),footer:!1,majorTick:1440,minorTickCount:1},name:"timelineMonth",calculateDateRange:function(){var e,t,i=this.options.date,r=n.date.firstDayOfMonth(i),o=[];for(e=0,t=n.date.lastDayOfMonth(i).getDate();e<t;e++)o.push(r),r=n.date.nextDay(r);this._render(o)}})})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.date,r=i.MS_PER_DAY,o=i.getDate,a=n.date.getMilliseconds,s=n.recurrence,l=n.htmlEncode,c=n.keys,d=n.ui,u=d.Widget,h=d.DataBoundWidget,p="string",f=d.Popup,m=d.Calendar,g=n.data.DataSource,v=e.isPlainObject,_=e.extend,b=Object.prototype.toString,y=Array.isArray,w=".kendoScheduler",k="click",x="mousedown",C=n.support.pointers?"pointerdown":"touchstart",S=n.support.pointers?"pointermove":"touchmove",T=n.support.pointers?"pointerup":"touchend",D=n.support.mousemove,A="change",M="progress",E="error",I="cancel",z="remove",P="resetSeries",H="save",F="edit",R="disabled",L="k-focus",B=/(?:value:start|value:end)(?:,|$)/,O="(min-width: 1024px)",V=o(new Date),N=",",$=/\;/g,U="recurrenceException",W="Do you want to edit only this event occurrence or the whole series?",j=({className:e,attr:t,text:i,icon:r,fillMode:o,themeColor:a})=>n.html.renderButton(`<button type="button" class="${e}" ${t}>${i}</button>`,{icon:r,fillMode:o,themeColor:a}),q=n.template((({label:e,views:t,type:n})=>`<select aria-label="${e}" class="k-picker k-dropdown-list k-dropdown ${n}">`+Object.keys(t).map((e=>`<option value="${e}">${t[e].title}</option>`)).join("")+"</select>")),G={pdf:{name:"pdf",type:"button",icon:"file-pdf",attributes:{class:"k-pdf"}},pdfMobile:{name:"pdf",type:"button",icon:"file-pdf",showText:"overflow",attributes:{class:"k-pdf"}},today:{name:"today",type:"button",attributes:{"ref-nav-today":""}},previous:{name:"previous",type:"button",icon:"caret-alt-left",showText:"overflow",attributes:{"ref-nav-prev":""},groupClass:"k-scheduler-navigation"},next:{name:"next",type:"button",icon:"caret-alt-right",showText:"overflow",attributes:{"ref-nav-next":""},groupClass:"k-scheduler-navigation"},current:{name:"current",type:"button",icon:"calendar",fillMode:"flat",text:"placeholder",attributes:{"aria-live":"polite",class:"k-nav-current"}},search:{template:`<span class="k-scheduler-search k-textbox k-input k-input-md k-rounded-md k-input-solid"><input tabindex="-1" autocomplete="off" class="k-input-inner k-scheduler-search-input k-input-inner" /><span class="k-input-suffix">${n.ui.icon("search")}</span></span>`},refresh:{name:"refresh",type:"button",icon:"arrow-rotate-cw",showText:"overflow",attributes:{class:"k-scheduler-refresh"}},create:{name:"create",type:"button",icon:"plus",attributes:{class:"k-create-event"}},calendar:{name:"calendar",type:"button",icon:"calendar",attributes:{class:"k-nav-calendar"}},previousMobile:{name:"previous",type:"button",icon:"chevron-left",showText:"overflow",attributes:{"ref-nav-prev":""},groupClass:"k-scheduler-navigation"},nextMobile:{name:"next",type:"button",icon:"chevron-right",showText:"overflow",attributes:{"ref-nav-next":""},groupClass:"k-scheduler-navigation"},currentMobile:{template:'<span class="k-scheduler-navigation"><span class="k-nav-current"><span class="k-m-date-format"></span><span class="k-y-date-format"></span></span></span>'},view:{name:"view",type:"button",togglable:!0,group:"views"}},K=[["today","previous","next"],"current",{type:"spacer"}],Y=[["calendar"],{type:"spacer"}],Q=["previousMobile",{type:"spacer"},"currentMobile",{type:"spacer"},"nextMobile"];function X(e,t){return t=t||"",e.startTimezone&&(t=e.startTimezone,e.endTimezone&&(t+=" | "+e.endTimezone)),t}function Z(e,t){var i=t.timezone;i&&(e[n.attr("timezone")]=i)}function J(e,t){var i=t.model.fields[t.field].validation;if(i){var r=i.validDateValidator;r&&v(r)&&r.message&&(e[n.attr("validDate-msg")]=r.message)}}function ee(e,t){var i=t.model.fields[t.field].validation;if(i){var r=i.dateCompare;r&&v(r)&&r.message&&(e[n.attr("dateCompare-msg")]=r.message)}}function te(e,t,i,r){var o,a,s,l,c;for(a=0,s=(e=e||[]).length;a<s;a++)l=(o=e[a]).start?o.start.getTimezoneOffset():null,c=o.start?o.end.getTimezoneOffset():null,r?o.startTimezone||o.endTimezone?i?(o.start=n.timezone.convert(o.start,o.startTimezone||o.endTimezone,i),o.end=n.timezone.convert(o.end,o.endTimezone||o.startTimezone,i),o.start=n.timezone[t](o.start,i),o.end=n.timezone[t](o.end,i)):(o.start=n.timezone[t](o.start,o.startTimezone||o.endTimezone),o.end=n.timezone[t](o.end,o.endTimezone||o.startTimezone)):i&&(o.start=n.timezone[t](o.start,i),o.end=n.timezone[t](o.end,i)):o.startTimezone||o.endTimezone?(o.start=n.timezone[t](o.start,o.startTimezone||o.endTimezone),o.end=n.timezone[t](o.end,o.endTimezone||o.startTimezone),i&&(o.start=n.timezone.convert(o.start,o.startTimezone||o.endTimezone,i),o.end=n.timezone.convert(o.end,o.endTimezone||o.startTimezone,i))):i&&(o.start=n.timezone[t](o.start,i),o.end=n.timezone[t](o.end,i)),r&&delete o.uid,"remove"===t&&o.start&&l&&l!==o.start.getTimezoneOffset()&&(o.start=new Date(o.start.getTime()+6e4*(l-o.start.getTimezoneOffset()))),"remove"===t&&o.end&&c&&c!==o.end.getTimezoneOffset()&&(o.end=new Date(o.end.getTime()+6e4*(c-o.end.getTimezoneOffset())));return e}function ne(e,t){for(var n,i=e.length,r=0;r<i;r++)if((n=e[r]).uid===t)return n}var ie=n.Class.extend({init:function(e,t){var i=e.timezone;this.reader=t,t.model&&(this.model=t.model),this.timezone=i,this.data=function(e,t){return function(n){return te(n=e(n),"apply",t),n||[]}}(this.data.bind(this),i),this.serialize=function(e,t){return function(i){return i&&("[object Array]"===b.call(i)||i instanceof n.data.ObservableArray||(i=[i])),te(i,"remove",t,!0),(i=e(i))||[]}}(this.serialize.bind(this),i)},errors:function(e){return this.reader.errors(e)},parse:function(e){return this.reader.parse(e)},data:function(e){return this.reader.data(e)},total:function(e){return this.reader.total(e)},groups:function(e){return this.reader.groups(e)},aggregates:function(e){return this.reader.aggregates(e)},serialize:function(e){return this.reader.serialize(e)}});function re(e,t,i){return e=i?n.timezone.convert(e,t,i):n.timezone.remove(e,t)}function oe(e){if(e.filter("[name=start]").length&&e.filter("[title=Start]").length||e.filter("[name=end]").length&&e.filter("[title=End]").length||e.filter(".k-recur-until").length){var t=n.widgetInstance(e,n.ui);return t?!!n.parseDate(e.val(),t.options.format)&&t.value():!!n.parseDate(e.val())}return!0}var ae=n.data.Model.define({init:function(e){var t=this;n.data.Model.fn.init.call(t,e),t._defaultId=t.defaults[t.idField]},_time:function(e){var t=this[e],i="_"+e+"Time";return this[i]?this[i]-n.date.toUtcTime(n.date.getDate(t)):a(t)},_date:function(e){var t="_"+e+"Time";return this[t]?this[t]-this._time(e):n.date.getDate(this[e])},clone:function(t,n){var i=this.uid,r=new this.constructor(e.extend({},this.toJSON(),t));return n||(r.uid=i),r},duration:function(){var e=this.end,t=this.start,i=(e.getTimezoneOffset()-t.getTimezoneOffset())*n.date.MS_PER_MINUTE;return e-t-i},expand:function(e,t,n){return s?s.expand(this,e,t,n):[this]},update:function(e){for(var t in e)this.set(t,e[t]);this._startTime&&this.set("_startTime",n.date.toUtcTime(this.start)),this._endTime&&this.set("_endTime",n.date.toUtcTime(this.end))},isMultiDay:function(){return this.isAllDay||this.duration()>=n.date.MS_PER_DAY},isException:function(){return!this.isNew()&&this.recurrenceId},isOccurrence:function(){return this.isNew()&&this.recurrenceId},isRecurring:function(){return!(!this.recurrenceRule&&!this.recurrenceId)},isRecurrenceHead:function(){return!(!this.id||!this.recurrenceRule)},toOccurrence:function(t){return(t=e.extend(t,{recurrenceException:null,recurrenceRule:null,recurrenceId:this.id||this.recurrenceId}))[this.idField]=this.defaults[this.idField],this.clone(t,!0)},toJSON:function(){var e=n.data.Model.fn.toJSON.call(this);return e.uid=this.uid,delete e._startTime,delete e._endTime,e},shouldSerialize:function(e){return n.data.Model.fn.shouldSerialize.call(this,e)&&"_defaultId"!==e},set:function(e,t){var i=this.isAllDay||!1;if(n.data.Model.fn.set.call(this,e,t),"isAllDay"==e&&t!=i){var o=n.date.getDate(this.start),a=new Date(this.end),s=n.date.getMilliseconds(a);0===s&&t&&(s=r),this.set("start",o),!0===t?(n.date.setTime(a,-s),a<o&&(a=o)):n.date.setTime(a,r-s),this.set("end",a)}},id:"id",fields:{id:{type:"number"},title:{defaultValue:"",type:"string"},start:{type:"date",validation:{required:!0,validDate:{value:oe}}},startTimezone:{type:"string"},end:{type:"date",validation:{required:!0,validDate:{value:oe},dateCompare:{value:function(e){if(e.filter("[name=end]").length){var t=e.closest(".k-scheduler-edit-form"),i=t.find("[name=start]:visible"),r=t.find("[name=end]:visible");if(r[0]&&i[0]){var o,a,s=n.widgetInstance(i,n.ui),l=n.widgetInstance(r,n.ui),c=t.data("kendoEditable"),d=c?c.options.model:null;if(s&&l?(o=s.value(),a=l.value()):(o=n.parseDate(i.val()),a=n.parseDate(r.val())),o&&a){if(d){var u=i.attr(n.attr("timezone")),h=d.startTimezone,p=d.endTimezone;h=h||p,p=p||h,h&&(o=re(o,h,u),a=re(a,p,u))}return o<=a}}}return!0}}}},endTimezone:{type:"string"},recurrenceRule:{defaultValue:"",type:"string",validation:{validDate:{value:oe},untilDateCompare:{value:function(e){var t,i,r,o;return!(e.filter(".k-recur-until").length&&(t=n.widgetInstance(e,n.ui).value(),(i=e.closest(".k-scheduler-edit-form").find("[name=start]:visible"))[0]&&(r=(o=n.widgetInstance(i,n.ui))?o.value():n.parseDate(i.val()))&&t))||r<=t}}}},recurrenceException:{defaultValue:"",type:"string"},isAllDay:{type:"boolean",defaultValue:!1},description:{type:"string"}}}),se=g.extend({init:function(e){g.fn.init.call(this,_(!0,{},{schema:{modelBase:ae,model:ae}},e)),this.reader=new ie(this.options.schema,this.reader)},expand:function(e,t){var i,o=this.view(),a={};return e&&t&&(i=t.getTimezoneOffset(),(t=new Date(t.getTime()+r-1)).getTimezoneOffset()!==i&&(t=n.timezone.apply(t,i)),a={logic:"or",filters:[{logic:"and",filters:[{field:"start",operator:"gte",value:e},{field:"end",operator:"gte",value:e},{field:"start",operator:"lte",value:t}]},{logic:"and",filters:[{field:"start",operator:"lte",value:new Date(e.getTime()+r-1)},{field:"end",operator:"gte",value:e}]}]},o=new n.data.Query(function(e,t,n,i){for(var r=e.length,o=[],a=0;a<r;a++)o=o.concat(e[a].expand(t,n,i));return o}(o,e,t,this.reader.timezone)).filter(a).toArray()),o},cancelChanges:function(e){e&&e.isOccurrence()&&this._removeExceptionDate(e),g.fn.cancelChanges.call(this,e)},insert:function(e,t){if(t){if(!(t instanceof ae)){var n=t;(t=this._createNewModel()).accept(n)}return(!this._pushCreated&&t.isRecurrenceHead()||t.recurrenceId)&&(t=t.recurrenceId?t:t.toOccurrence(),this._addExceptionDate(t)),g.fn.insert.call(this,e,t)}},pushCreate:function(e){this._pushCreated=!0,g.fn.pushCreate.call(this,e),this._pushCreated=!1},remove:function(e){return e.isRecurrenceHead()?this._removeExceptions(e):e.isRecurring()&&this._addExceptionDate(e),g.fn.remove.call(this,e)},_removeExceptions:function(e){for(var t=this.data().slice(0),n=t.shift(),i=e.id;n;)n.recurrenceId===i&&g.fn.remove.call(this,n),n=t.shift();e.set(U,"")},_removeExceptionDate:function(e){if(e.recurrenceId){var t=this.get(e.recurrenceId);if(t){var n=e.defaults.start,i=new RegExp("(\\,?)"+s.toExceptionString(n,this.reader.timezone)),r=(t.recurrenceException||"").replace($,N).replace(/\,$/,"");i.test(r)||(n=e.start,i=new RegExp("(\\,?)"+s.toExceptionString(n,this.reader.timezone))),t.set(U,r.replace(i,""))}}},_addExceptionDate:function(e){var t=e.start,n=this.reader.timezone,i=this.get(e.recurrenceId),r=(i.recurrenceException||"").replace($,N).replace(/\,$/,"");if(!s.isException(r,t,n)){var o=s.toExceptionString(t,n);e.defaults.start=t,i.set(U,r+(r&&o?N:"")+o)}}});se.create=function(e){(y(e)||e instanceof n.data.ObservableArray)&&(e={data:e});var t=e||{},i=t.data;if(t.data=i,!(t instanceof se)&&t instanceof n.data.DataSource)throw new Error("Incorrect DataSource type. Only SchedulerDataSource instances are supported");return t instanceof se?t:new se(t)},_(!0,n.data,{SchedulerDataSource:se,SchedulerDataReader:ie,SchedulerEvent:ae});var le={update:{text:"Save",className:"k-button-solid-primary k-scheduler-update"},canceledit:{text:"Cancel",className:"k-scheduler-cancel"},destroy:{text:"Delete",icon:"trash",imageClass:"k-i-trash",className:"k-button-solid-primary k-scheduler-delete",iconClass:"k-icon"}};function ce(t){var n=de(t.model,t.field);return function(t,i){e('<textarea name="description" class="k-input-inner" title="'+i.title+'"/>').attr(n).appendTo(t).wrap('<span class="k-input k-textarea k-input-solid k-input-md k-rounded-md"></span>')}}function de(t,i){var r,o,a=(t.fields||t)[i],s=["url","email","number","date","boolean"],l=a?a.validation:{},c=n.attr("type"),d=e.inArray,u={};for(r in l)o=l[r],d(r,s)>=0?u[c]=r:n.isFunction(o)||(u[r]=v(o)?o.value||r:o),u[n.attr(r+"-msg")]=o.message;return u}function ue(e,n,i,r){var o,a=e.value(),s=Array.isArray(a);o=s?JSON.parse(JSON.stringify(a)):[a.toString()],e.dataSource.data().forEach((function(a){if(null===a[i]||a[i]===t||a[i]==n)a.set(R,!1);else{var l=a.get(r);a.set(R,!0),(o.indexOf(l)>=0||o.indexOf(l.toString())>=0)&&(s?o.splice(o.indexOf(l),1):(e.value(null),e.trigger(A)))}})),s&&o.length<a.length&&(e.value(o),e.trigger(A))}function he(e,t,i,r){var o=e.closest(".k-edit-form-container").find("[data-"+n.ns+"bind='value:"+r+"']"),a=o.getKendoDropDownList();a?a.bind(A,(function(e){var n=e.sender.value();ue(t,n,i.dataParentValueField,i.dataValueField)})):o.on(A,(function(e){var n=e.target.value;ue(t,n,i.dataParentValueField,i.dataValueField)}))}function pe(e,i,r){var o,a=i.find("option"),s=i.val(),l=Array.isArray(s);o=l?JSON.parse(JSON.stringify(s)):[s],e.dataSource.view().forEach((function(s,c){var d=n.getter(e.dataParentValueField)(s);if(null===d||d===t||d==r)a[c].removeAttribute(R);else{a[c].setAttribute(R,R);var u=""+s.get(e.dataValueField);o.indexOf(u)>=0&&(l?o.splice(o.indexOf(u),1):(i.val(null),i.trigger(A)))}})),l&&o.length<s.length&&(i.val(o),i.trigger(A))}function fe(e,t){var i=e.end.getTime()-e.start.getTime(),r=new Date(e.start.getTime());n.date.setTime(r,t);var o=new Date(r.getTime());return n.date.setTime(o,i,!0),{start:r,end:o}}var me={mobile:{dateRange:function(t,i){var r={name:i.field,title:i.title},o=i.model.isAllDay,a=n.attr("validate")+"='"+!o+"'",s=n.attr("validate")+"='"+!!o+"'";Z(r,i),J(r,i),ee(r,i),e('<input type="datetime-local" required '+n.attr("type")+'="datetime-local" '+n.attr("bind")+'="value:'+i.field+', invisible:isAllDay" '+a+"/>").attr(r).appendTo(t),e('<input type="date" required '+n.attr("type")+'="date" '+n.attr("bind")+'="value:'+i.field+',visible:isAllDay" '+s+"/>").attr(r).appendTo(t),e("<span "+n.attr("for")+'="'+i.field+'" class="k-invalid-msg"/>').hide().appendTo(t)},timezonePopUp:function(t,i){var r=X(i.model,i.messages.noTimezone);e('<span class="k-timezone-label"></span>').text(r).appendTo(t),e(n.ui.icon("arrow-chevron-right")).appendTo(t),t.closest("li.k-item label").on(k,i.click)},timezone:function(t,i){e('<div class="k-mobiletimezoneeditor" '+n.attr("bind")+'="value:'+i.field+'" />').attr({name:i.field}).appendTo(t).kendoMobileTimezoneEditor({optionLabel:i.noTimezone})},recurrence:function(t,i){e("<div "+n.attr("bind")+'="value:'+i.field+'" />').attr({name:i.field}).appendTo(t).kendoMobileRecurrenceEditor({start:i.model.start,timezone:i.timezone,messages:i.messages,pane:i.pane,value:i.model[i.field]})},description:ce,multipleResources:function(t,i,r){var o=de(i,t.field);return function(a){for(var s="",l=t.dataSource.view(),c=0,d=l.length;c<d;c++)s+=n.format('<option value="{0}">{1}</option>',n.getter(t.dataValueField)(l[c]),n.getter(t.dataTextField)(l[c]));var u=e(n.format('<select aria-labelledby="'+t.field+'_label" data-{0}bind="value:{1}" multiple="multiple">{2}</select>',n.ns,t.field,s)).appendTo(a).attr(o);r&&setTimeout((function(){var e=a.closest(".k-stretched-view").find("[data-"+n.ns+"bind='value:"+r+"']"),o=i[r];pe(t,u,o),e.on(A,(function(e){var n=e.target.value;pe(t,u,n)}))}))}},resources:function(t,i,r){var o=de(i,t.field);return function(a){for(var s="",l=t.dataSource.view(),c=0,d=l.length;c<d;c++)s+=n.format('<option value="{0}">{1}</option>',n.getter(t.dataValueField)(l[c]),n.getter(t.dataTextField)(l[c]));var u=e(n.format('<select aria-labelledby="'+t.field+'_label" data-{0}bind="value:{1}">{2}</select>',n.ns,t.field,s)).appendTo(a).attr(o);r&&setTimeout((function(){var e=a.closest(".k-stretched-view").find("[data-"+n.ns+"bind='value:"+r+"']"),o=i[r];pe(t,u,o),e.on(A,(function(e){var n=e.target.value;pe(t,u,n)}))}))}},isAllDay:function(t,i){e('<input type="checkbox" data-role="switch"'+n.attr("bind")+'="value:'+i.field+'" />').appendTo(t)}},desktop:{dateRange:function(t,i){var r={name:i.field,title:i.title},o=i.model.isAllDay,a=n.attr("validate")+"='"+!o+"' ",s=n.attr("validate")+"='"+!!o+"' ";Z(r,i),J(r,i),ee(r,i),e('<input type="text" required '+n.attr("type")+'="date" '+n.attr("role")+'="datetimepicker" '+n.attr("bind")+'="value:'+i.field+',invisible:isAllDay" '+a+"/>").attr(r).appendTo(t),e('<input type="text" required '+n.attr("type")+'="date" '+n.attr("role")+'="datepicker" '+n.attr("bind")+'="value:'+i.field+',visible:isAllDay" '+s+"/>").attr(r).appendTo(t),e("<span "+n.attr("bind")+'="text: '+i.field+'Timezone"></span>').appendTo(t),"end"===i.field&&e("<span "+n.attr("bind")+'="text: startTimezone, invisible: endTimezone"></span>').appendTo(t),e("<span "+n.attr("for")+'="'+i.field+'" class="k-invalid-msg"/>').hide().appendTo(t)},timezonePopUp:function(t,n){e('<a href="#" class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base" data-bind="invisible:isAllDay"><span class="k-button-text">'+n.messages.timezoneEditorButton+"</span></a>").on(k,n.click).appendTo(t)},timezone:function(i,r){var o=r.visible||r.visible===t;e("<div "+n.attr("bind")+'="value:'+r.field+'" />').attr({name:r.field}).toggle(o).appendTo(i).kendoTimezoneEditor({optionLabel:r.noTimezone,title:r.title})},recurrence:function(t,i){e("<div "+n.attr("bind")+'="value:'+i.field+'" />').attr({name:i.field}).appendTo(t).kendoRecurrenceEditor({start:i.model.start,timezone:i.timezone,messages:i.messages})},description:ce,multipleResources:function(t,i,r){var o=de(i,t.field);return function(a){var s;r&&setTimeout((function(){ue(s,i[r],t.dataParentValueField,t.dataValueField),he(a,s,t,r)})),s=e(n.format('<select aria-labelledby="'+t.field+'_label" data-{0}bind="value:{1}">',n.ns,t.field)).appendTo(a).attr(o).kendoMultiSelect({dataTextField:t.dataTextField,dataValueField:t.dataValueField,dataSource:t.dataSource.data(),valuePrimitive:t.valuePrimitive,itemTemplate:e=>`<span ${e.disabled?"data-disabled":""}><span class="k-scheduler-mark" ${n.attr("style-background-color")}="${e[t.dataColorField]||"none"}"></span>${e[t.dataTextField]}</span>`,tagTemplate:e=>`<span class="k-scheduler-mark" ${n.attr("style-background-color")}="${e[t.dataColorField]||"none"}"></span>${e[t.dataTextField]}`,select:function(e){e.dataItem&&e.dataItem.disabled&&e.preventDefault()},dataBound:function(e){let t=e.sender.list.find("li");for(let e=0;e<t.length;e++){let n=t.eq(e);n.find("[data-disabled]").length>0&&n.addClass("k-disabled")}}}).data("kendoMultiSelect")}},resources:function(t,i,r){var o=de(i,t.field);return function(a){var s;r&&setTimeout((function(){ue(s,i[r],t.dataParentValueField,t.dataValueField),he(a,s,t,r)})),s=e(n.format('<select aria-labelledby="'+t.field+'_label" data-{0}bind="value:{1}" title="'+i.title+'">',n.ns,t.field)).appendTo(a).attr(o).kendoDropDownList({dataTextField:t.dataTextField,dataValueField:t.dataValueField,dataSource:t.dataSource.data(),valuePrimitive:t.valuePrimitive,optionLabel:"None",template:e=>`<span ${e.disabled?"data-disabled":""}><span class="k-scheduler-mark" ${n.attr("style-background-color")}="${e[t.dataColorField]||"none"}"></span>${e[t.dataTextField]}</span>`,select:function(e){e.dataItem&&e.dataItem.disabled&&e.preventDefault()},dataBound:function(e){let t=e.sender.list.find("li");for(let e=0;e<t.length;e++){var n=t.eq(e);n.find("[data-disabled]").length>0&&n.addClass("k-disabled")}}}).data("kendoDropDownList")}},isAllDay:function(t,i){e('<input type="checkbox" data-role="checkbox"'+n.attr("bind")+'="value:'+i.field+'" data-label="'+i.title+'" />').attr({id:i.field,name:i.field,title:i.title?i.title:i.field}).appendTo(t)}}},ge=n.Observable.extend({init:function(e,t){n.Observable.fn.init.call(this),this.element=e,this.options=_(!0,{},this.options,t),this.createButton=this.options.createButton,this.toggleDateValidationHandler=this._toggleDateValidation.bind(this)},_toggleDateValidation:function(t){if("isAllDay"==t.field){var i,r,o,a=this.container,s=this.editable.options.model.isAllDay,l=n.attr("bind");a.find("["+l+"*=end],["+l+"*=start]").each((function(){i=e(this),B.test(i.attr(l))&&(r=i.is("["+n.attr("role")+"=datetimepicker],[type*=datetime]"),o=s!==r,i.attr(n.attr("validate"),o.toString()))}))}},fields:function(e,t){var i=this,r=i.options.messages,o=i.options.timezone,a=[{field:"title",title:r.editor.title},{field:"start",title:r.editor.start,editor:e.dateRange,timezone:o},{field:"end",title:r.editor.end,editor:e.dateRange,timezone:o},{field:"isAllDay",title:r.editor.allDayEvent,editor:e.isAllDay}],s=function(e){return!!e[u.dataParentValueField]};n.timezone.windows_zones&&(a.push({field:"timezone",title:r.editor.timezone,editor:e.timezonePopUp,click:function(e){e.preventDefault(),i._initTimezoneEditor(t,this)},messages:r.editor,model:t}),a.push({field:"startTimezone",title:r.editor.startTimezone,editor:e.timezone,noTimezone:r.editor.noTimezone}),a.push({field:"endTimezone",title:r.editor.endTimezone,editor:e.timezone,noTimezone:r.editor.noTimezone})),t.recurrenceId||a.push({field:"recurrenceRule",title:r.editor.repeat,editor:e.recurrence,timezone:o,messages:r.recurrenceEditor,pane:this.pane}),"description"in t&&a.push({field:"description",title:r.editor.description,editor:e.description({model:t,field:"description"})});for(var l=0;l<this.options.resources.length;l++){var c,d,u=this.options.resources[l];u.dataSource.view().some(s)&&(c=this.options.resources[l-1])&&(d=c.field),a.push({field:u.field,title:u.title,editor:u.multiple?e.multipleResources(u,t,d):e.resources(u,t,d)})}return a},end:function(){return this.editable.end()},_buildDesktopEditTemplate:function(t,i,r){var o=this.options.messages;const a=`<div class="k-popup-edit-form k-scheduler-edit-form k-scheduler-timezones" ${n.attr("style-display")}="none"><div class="k-form"><div class="k-form-field"><div class="k-form-field-wrap">`+n.html.renderCheckBox(e('<input class="k-timezone-toggle"/>'),{label:o.editor.separateTimezones})+"</div></div>",s=e=>!t.editable||t.editable(e)?`<div ${n.attr("container-for")}="${e}" class="k-form-field-wrap"></div>`:`<div class="k-form-field-wrap">${e&&n.getter(e)(t)||""}</div>`;return'<div class="k-form">'+i.map((e=>{const n=e.field,i=e.title,o=t.fields[n];return(!t.editable||t.editable(n))&&r.push(e),("startTimezone"===n?a:"")+(o&&"boolean"===o.type?`<div class="k-form-field">${s(n)}</div>`:`<div class="k-form-field"><label class="k-label k-form-label" for="${n}" id="${n}_label">${i||n||""}</label>${s(n)}</div>`)+("endTimezone"===n?this._createEndTimezoneButton():"")})).join("")+"</div>"},_buildMobileEditTemplate:function(e,t,i){var r=this.options.messages;const o=`<div class="k-popup-edit-form k-scheduler-edit-form k-scheduler-timezones" ${n.attr("style-display")}="none"><ul class="k-listgroup k-listgroup-flush"><li class="k-item k-listgroup-item"><label class="k-label k-listgroup-form-row"><span class="k-item-title k-listgroup-form-row">`+l(r.editor.separateTimezones)+'</span><span class="k-listgroup-form-field-wrapper"><input class="k-timezone-toggle" data-role="switch" type="checkbox" /></span></label></li>';return'<ul class="k-listgroup k-listgroup-flush">'+t.map((t=>{const r=t.field;return(!e.editable||e.editable(r))&&i.push(t),("timezone"===r||"recurrenceRule"===r?'</ul><ul class="k-listgroup k-listgroup-flush">':"")+("startTimezone"===r?o:"")+(t=>{const i=t.field,r=t.title;let o;return o=!e.editable||e.editable(i)?("timezone"===i?'<label class="k-label k-listgroup-form-row" data-bind="css: { k-disabled: isAllDay }">':'<label class="k-label k-listgroup-form-row">')+`<span class="k-item-title k-listgroup-form-field-label">${r||i||""}</span>`+`<div class="k-listgroup-form-field-wrapper" ${n.attr("container-for")}="${i}"></div>`:`<li class="k-item k-listgroup-item"><label class="k-label k-no-click k-listgroup-form-row"><span class="k-item-title k-listgroup-form-field-label">${r||i||""}</span><span class="k-no-editor k-listgroup-form-field-wrapper">${i&&n.getter(i)(e)||""}</span>`,'<li class="k-item k-listgroup-item">'+o+"</label></li>"})(t)+("recurrenceRule"===r?'</ul><ul class="k-listgroup k-listgroup-flush">':"")+("endTimezone"===r?"</ul></div>":"")})).join("")+"</ul>"},_buildEditTemplate:function(e,t,i,r){var o=_({},n.Template,this.options.templateSettings),a=this.options.editable.template,s="";return a?(typeof a===p&&(a=n.unescape(a)),s+=n.template(a,o)(e)):s+=r?'<div data-role="content">'+this._buildMobileEditTemplate(e,t,i)+"</div>":this._buildDesktopEditTemplate(e,t,i),s},_createEndTimezoneButton:function(){return"</ul></div>"},_revertTimezones:function(e){e.set("startTimezone",this._startTimezone),e.set("endTimezone",this._endTimezone),delete this._startTimezone,delete this._endTimezone}}),ve=ge.extend({init:function(){ge.fn.init.apply(this,arguments),this.pane=n.Pane.wrap(this.element,{viewEngine:{viewOptions:{renderOnInit:!0,wrap:!1,wrapInSections:!0,detachOnHide:!1,detachOnDestroy:!1}}}),this.pane.element.parent().css("height",this.options.height),this.view=this.pane.view()},options:{animations:{left:"slide",right:"slide:right"}},destroy:function(){this.close(),this.unbind(),this.pane.destroy()},_initTimezoneEditor:function(t){var i=this,r=i.pane,o=i.options.messages,a=i.timezoneView,s=a?a.content.find(".k-scheduler-timezones"):i.container.find(".k-scheduler-timezones"),c=s.find("input.k-timezone-toggle").data("kendoSwitch"),d=s.find("li.k-item:not(.k-zonepicker)").last();if(i._startTimezone=t.startTimezone||"",i._endTimezone=t.endTimezone||"",!a){var u='<div data-role="view" class="k-popup-edit-form k-scheduler-edit-form"><div data-role="header" class="k-appbar k-appbar-primary">'+n.html.renderButton(`<button class="k-header-cancel k-scheduler-cancel" title="${o.cancel}" aria-label="${o.cancel}"></button>`,{fillMode:"flat",icon:"chevron-left"})+'<span class="k-spacer"></span>'+`<span>${l(o.editor.timezoneTitle)}</span><span class="k-spacer"></span>`+l(o.editor.timezoneTitle)+n.html.renderButton(`<button class="k-header-done k-scheduler-update" title="${o.save}" aria-label="${o.save}"></button>`,{fillMode:"flat",icon:"check"})+'</div><div data-role="content"></div>';this.timezoneView=a=r.append(u),a.contentElement.append(s.show()),a.element.on(k+w,".k-scheduler-cancel, .k-scheduler-update",(function(n){n.preventDefault(),n.stopPropagation(),e(this).hasClass("k-scheduler-cancel")&&i._revertTimezones(t);var a=i._editPane,s=X(t,o.editor.noTimezone);a.content.find(".k-timezone-label").text(s),r.navigate(a,i.options.animations.right)})),c.bind(A,(function(e){d.toggle(e.checked),t.set("endTimezone","")})),t.bind(A,(function(e){if("startTimezone"===e.field){var n=t.startTimezone;c.enable(n),n||(d.hide(),t.set("endTimezone",""),c.value(!1))}}))}c.value(!!t.endTimezone),c.enable(!!t.startTimezone),t.endTimezone?d.show():d.hide(),r.navigate(a,i.options.animations.left)},showDialog:function(t){var n=t.buttons.map((function(e){return{text:e.text,action:e.click}}));n.push({text:this.options.messages.cancel,primary:!0}),e("<div />").appendTo(document.body).kendoDialog({close:function(){this.destroy()},modal:{preventScroll:!0},closable:!1,title:!1,content:t.text,actions:n})},editEvent:function(t){var i=this.pane,r="",o=this.options.messages,a=o.save,s=o.destroy,c=o.cancel,d=o.editor.editorTitle,u=o.resetSeries;r+='<div data-role="view" class="k-popup-edit-form k-scheduler-edit-form"'+n.attr("uid")+'="'+t.uid+'"><div data-role="header" class="k-appbar k-appbar-primary">'+n.html.renderButton(`<button class="k-header-cancel k-scheduler-cancel" title="${c}" aria-label="${c}"></button>`,{fillMode:"flat",icon:"chevron-left"})+'<span class="k-spacer"></span>'+`<span>${l(d)}</span><span class="k-spacer"></span>`+n.html.renderButton(`<button class="k-header-done k-scheduler-update" title="${a}" aria-label="${a}"></button>`,{fillMode:"flat",icon:"check"})+"</div>";var h=this.fields(me.mobile,t),p=this,f=[];r+=this._buildEditTemplate(t,h,f,!0),r+="</div>";var m=i.append(r);if(!t.isNew()&&this.options.editable&&!1!==this.options.editable.destroy&&t.isRecurrenceHead()&&t.recurrenceException){var g='<ul class="k-edit-buttons k-listgroup k-listgroup-flush"><li class="k-item k-listgroup-item"><span class="k-scheduler-resetSeries k-link k-label" aria-label="'+u+'">'+u+"</span></li></ul>";m.contentElement.append(g)}if(!t.isNew()&&this.options.editable&&!1!==this.options.editable.destroy){var v='<ul class="k-edit-buttons k-listgroup k-listgroup-flush"><li class="k-item k-listgroup-item"><span class="k-scheduler-delete k-link k-label" aria-label="'+s+'">'+s+"</span></li></ul>";m.contentElement.append(v)}this._editPane=m;var _=this.container=m.element;return this.editable=_.kendoEditable({fields:f,model:t,clearContainer:!1,target:p.options.target,validateOnBlur:!0}).data("kendoEditable"),this.trigger("edit",{container:_,model:t})?this.trigger("cancel",{container:_,model:t}):(_.on(k+w,"a.k-scheduler-edit, .k-scheduler-cancel, .k-scheduler-update, span.k-scheduler-delete, span.k-scheduler-resetSeries",(function(n){n.preventDefault(),n.stopPropagation();var r=e(this);if(r.hasClass("k-scheduler-edit"))i.navigate(this._editPane,p.options.animations.right);else{var o="cancel";r.hasClass("k-scheduler-update")?o="save":r.hasClass("k-scheduler-delete")?o="remove":r.hasClass("k-scheduler-resetSeries")&&(o=P),p.trigger(o,{container:_,model:t})}})),i.navigate(m,p.options.animations.left),t.bind(A,p.toggleDateValidationHandler)),this.editable},_views:function(){return this.pane.element.find(n.roleSelector("view")).not(this.view.element)},close:function(){if(this.container){this.pane.navigate("",this.options.animations.right);for(var e,t=this._views(),n=0,i=t.length;n<i;n++)(e=t.eq(n).data("kendoView"))&&e.purge();t.remove(),this.container=null,this.editable&&(this.editable.options.model.unbind(A,this.toggleDateValidationHandler),this.editable.destroy(),this.editable=null),this.timezoneView=null}}}),_e=ge.extend({destroy:function(){this.close(),this.unbind()},editEvent:function(t){var i,r,o,a=this,s=a.options.editable,l="<div "+n.attr("uid")+'="'+t.uid+'" class="k-popup-edit-form k-scheduler-edit-form"><div class="k-edit-form-container">',c=a.options.messages,d=c.save,u=c.cancel,h=c.destroy,p=c.resetSeries,f=this.fields(me.desktop,t),m=[];l+=this._buildEditTemplate(t,f,m,!1);var g=v(s)?s.window:{};l+='<div class="k-edit-buttons">',l+=this.createButton({name:"update",text:d,attr:o,icon:"save"})+this.createButton({name:"canceledit",text:u,attr:o,icon:"cancel-outline"}),!t.isNew()&&!1!==s.destroy&&t.isRecurrenceHead()&&t.recurrenceException&&(l+=this.createButton({name:"resetSeries",text:p,attr:o})),t.isNew()&&!t.isRecurring()||!1===s.destroy||(l+='<span class="k-spacer"></span>'+this.createButton({name:"delete",text:h,attr:o,icon:"trash",fillMode:"flat",themeColor:"primary"})),i=e(l+="</div></div></div>"),n.applyStylesFromKendoAttributes(i,["display"]);var b=this.container=i.appendTo(a.element).eq(0).kendoWindow(_({modal:!0,resizable:!1,draggable:!0,title:c.editor.editorTitle,visible:!1,close:function(e){e.userTriggered&&a.trigger(I,{container:b,model:t})&&e.preventDefault()}},g));for(var y in a.editable=b.kendoEditable({fields:m,model:t,clearContainer:!1,validateOnBlur:!0,target:a.options.target}).data("kendoEditable"),m)"recurrenceRule"!==m[y].field&&(r=m[y].field,b.find("[name='"+r+"']").attr("aria-labelledby",r+"_label")),"isAllDay"===m[y].field&&b.find("label[for='"+r+"']").attr("id",r+"_label");return a.trigger(F,{container:b,model:t})?a.trigger(I,{container:b,model:t}):(s.window&&s.window.position?b.data("kendoWindow").open():b.data("kendoWindow").center().open(),b.on(k+w,"button.k-scheduler-cancel",(function(e){e.preventDefault(),e.stopPropagation(),a.trigger(I,{container:b,model:t})})),b.on(k+w,"button.k-scheduler-update",(function(e){e.preventDefault(),e.stopPropagation(),a.trigger("save",{container:b,model:t})})),b.on(k+w,"button.k-scheduler-delete",(function(e){e.preventDefault(),e.stopPropagation(),a.trigger(z,{container:b,model:t})})),b.on(k+w,"button.k-scheduler-resetSeries",(function(e){e.preventDefault(),e.stopPropagation(),a.trigger(P,{container:b,model:t})})),n.cycleForm(b),t.bind(A,a.toggleDateValidationHandler)),a.editable},close:function(){var e=this,t=function(){e.editable&&(e.editable.options.model.unbind(A,e.toggleDateValidationHandler),e.editable.destroy(),e.editable=null,e.container=null),e.popup&&(e.popup.destroy(),e.popup=null)};e.editable?(e._timezonePopup&&e._timezonePopup.data("kendoWindow")&&(e._timezonePopup.data("kendoWindow").destroy(),e._timezonePopup=null),e.container.is(":visible")?e.container.data("kendoWindow").bind("deactivate",t).close():t()):t()},_createEndTimezoneButton:function(){var e=this.options.messages,t="";return t+='<div class="k-edit-buttons">',t+=this.createButton({name:"savetimezone",icon:"save",themeColor:"primary",text:e.save})+this.createButton({name:"canceltimezone",icon:"cancel-outline",text:e.cancel}),t+="</div></div></div>"},showDialog:function(t){var i=n.format("<div class='k-popup-edit-form'><div class='k-edit-form-container'><p class='k-popup-message'>{0}</p>",t.text);i+='<div class="k-edit-buttons">';for(var r=0;r<t.buttons.length;r++)i+=this.createButton(t.buttons[r]);i+="</div></div></div>";var o=this.element;this.popup&&this.popup.destroy();var a=this.popup=e(i).appendTo(o).eq(0).on(k,".k-button",(function(n){n.preventDefault(),a.close();var i=e(n.currentTarget).index();t.buttons[i].click()})).kendoWindow({modal:!0,resizable:!1,draggable:!1,title:t.title,visible:!1,close:function(){this.destroy(),o.trigger("focus")}}).getKendoWindow();a.center().open()},_initTimezoneEditor:function(e,t){var n,i=this,r=i.container.find(".k-scheduler-timezones"),o=r.find("input.k-timezone-toggle"),a=r.find(".k-form-field").last(),s=r.find(".k-scheduler-savetimezone"),l=r.find(".k-scheduler-canceltimezone"),c=i._timezonePopup,d=function(t){if("startTimezone"===t.field){var n=e.startTimezone;o.prop(R,!n),n||(a.hide(),e.set("endTimezone",""),o.prop("checked",!1))}};i._startTimezone=e.startTimezone,i._endTimezone=e.endTimezone,c||(i._timezonePopup=c=r.kendoWindow({modal:!0,resizable:!1,draggable:!0,title:i.options.messages.editor.timezoneEditorTitle,visible:!1,close:function(n){e.unbind(A,d),n.userTriggered&&i._revertTimezones(e),t&&t.focus()}}),o.on(k,(function(){a.toggle(o.prop("checked")),e.set("endTimezone","")})),s.on(k,(function(e){e.preventDefault(),n.close()})),l.on(k,(function(t){t.preventDefault(),i._revertTimezones(e),n.close()})),e.bind(A,d)),o.prop("checked",e.endTimezone).prop(R,!e.startTimezone),e.endTimezone?a.show():a.hide(),(n=c.data("kendoWindow")).center().open()}}),be=h.extend({init:function(t,i){var r=this;u.fn.init.call(r,t,i),r.options.views&&r.options.views.length||(r.options.views=["day","week"]),r.resources=[],r._initModel(),r._wrapper(),r.options.selectable&&r._tabindex(),r._views(),r._toolbar(),r._dataSource(),r._resources(),r._resizeHandler=function(){r.resize()},r.wrapper.on(x+w+" selectstart"+w,(function(t){var n=e(t.target);n.is(":kendoFocusable")||0!==n.closest(".k-button").length||t.preventDefault()})),r.options.editable&&!1!==r.options.editable.resize&&r._resizable(),r._movable(),r._bindResize(),r.options.messages&&r.options.messages.recurrence&&(s.options=r.options.messages.recurrence),r._navigation(),r._selectable(),r._touchHandlers(),r._ariaId=n.guid(),r._createEditor(),r.mediaQueryList=n.mediaQuery(O),r.mediaQueryList.onChange(r._onMediaChange.bind(r)),r.toolbar.find(".k-scheduler-views").children().removeClass("k-button-rectangle"),r._showWatermarkOverlay&&r._showWatermarkOverlay(r.element[0])},_onMediaChange:function(e){var t=this,n=t._selectedView,i=t.toolbar,r=i.getKendoToolBar();e.matches?(r.hide(i.find(".k-views-dropdown")),r.show(i.find(".k-views-dropdown").parent().next(".k-button-group"))):(r.show(i.find(".k-views-dropdown")),r.hide(i.find(".k-views-dropdown").parent().next(".k-button-group"))),t._model.set("formattedDate",e.matches?n.dateForTitle():n.shortDateForTitle())},_bindResize:function(){e(window).on("resize"+w,this._resizeHandler)},_unbindResize:function(){e(window).off("resize"+w,this._resizeHandler)},dataItems:function(){var n,i,r=this.items(),o=this._data,a=e.map(r,(function(t){return e(t).attr("data-uid")})),s={},l=a.length;for(n=0;n<l;n++)s[a[n]]=null;var c=o.length;for(n=0;n<c;n++){var d=o[n];s[d.uid]!==t&&(s[d.uid]=d)}var u=[];for(i in s)u.push(s[i]);return u},_isMobile:function(){var e=this.options;return!0===e.mobile&&n.support.mobileOS||"phone"===e.mobile||"tablet"===e.mobile},_isTouch:function(e){return/touch/.test(e.type)||e.originalEvent&&/touch/.test(e.originalEvent.pointerType)},_isInverseColor:function(e){return e.hasClass("k-event-inverse")},_groupsByResource:function(e,t,i,r,o){i||(i=[]);var a=e[0];if(a){for(var s,l=a.dataSource.view(),c=0,d=0;d<l.length;d++){var u=n.getter(a.dataValueField)(l[d]),h=t+c+d;(s=this._groupsByResource(e.slice(1),h,i,u,a.field))[a.field]=u,c=s.groupIndex,o&&r&&(s[o]=r),1===e.length&&(s.groupIndex=t+d,i.push(s))}return s}return{}},data:function(){return this._data},select:function(e){var i,r=this,a=r.view(),s=r._selection,l=a.groups;if(e===t){var c,d=a._selectedSlots;return s?(s&&s.events&&(c=r._selectedEvents()),{start:s.start,end:s.end,events:c,slots:d,resources:a._resourceBySlot(s)}):[]}if(!e)return r._selection=null,r._old=null,void a.clearSelection();if(Array.isArray(e)&&(e={events:e.splice(0)}),e.resources){var u,h=[],p=[];for(u in a.groupedResources&&r._groupsByResource(a.groupedResources,0,p),e.resources)h.push({field:u,operator:"eq",value:e.resources[u]});i=new n.data.Query(p).filter(h).toArray()}if(e.events&&e.events.length)return r._selectEvents(e.events,i),void r._select();if(l&&e.start&&e.end){var f,m,g=o(a._startDate),v=n.date.addDays(o(a._endDate),1);e.start<v&&g<=e.end&&((f=i&&i.length?l[i[0].groupIndex]:l[0]).timeSlotCollectionCount()||(e.isAllDay=!0),(m=f.ranges(e.start,e.end,e.isAllDay,!1)).length&&(r._selection={start:n.timezone.toLocalDate(m[0].start.start),end:n.timezone.toLocalDate(m[m.length-1].end.end),groupIndex:m[0].start.groupIndex,index:m[0].start.index,isAllDay:m[0].start.isDaySlot,events:[]},r._select()))}},_selectEvents:function(e,t){var i,r=this,o=r.view(),a=o.groups,s=e.length,l=t&&t.length,c=r._ctrlKey;for(r._ctrlKey=!0,i=0;i<s;i++)if(a&&l){for(var d=a[t[0].groupIndex],u=[],h=d.timeSlotCollectionCount(),p=d.daySlotCollectionCount(),f=0;f<h;f++)u=u.concat(d.getTimeSlotCollection(f).events());for(var m=0;m<p;m++)u=u.concat(d.getDaySlotCollection(m).events());(u=new n.data.Query(u).filter({field:e=>e.element[0].getAttribute("data-uid"),operator:"eq",value:e[i]}).toArray())[0]&&r._createSelection(u[0].element)}else{var g=o.element.find(n.format(".k-event[data-uid={0}], .k-task[data-uid={0}]",e[i]));g.length&&r._createSelection(g[0])}r._ctrlKey=c},_touchHandlers:function(){var e,t,i,r,o,a=this,s=a.wrapper,l=a._touchMove.bind(a);s.on(C+w,".k-scheduler-header-all-day td, .k-scheduler-content td, .k-event",(function(n){var i=a.wrapper.find(".k-scheduler-content");a._isTouch(n)&&(i.stop(!0,!1),a._touchPosX=e=a._tapPosition(n,"X"),a._touchPosY=t=a._tapPosition(n,"Y"),a._userTouched=!0,a.view()._scrolling=!1,o=Date.now(),s.on(S+w,".k-scheduler-header-all-day td, .k-scheduler-content td, .k-event",l))})),s.on("contextmenu"+w,".k-scheduler-header-all-day td, .k-scheduler-content td, .k-event",(function(e){a._preventFocus=!0})),s.on(T+w,".k-scheduler-header-all-day td, .k-scheduler-content td, .k-event",(function(c){if(a._isTouch(c)){var d=Date.now()-o,u=a.wrapper.find(".k-scheduler-content"),h=-a._amplitude*(3e3/d);i=a._tapPosition(c,"X"),r=a._tapPosition(c,"Y"),a._dragging||(a.options.selectable&&(Math.abs(i-e)<=10||Math.abs(r-t)<=10)&&a._mouseDownSelection(c),!n.support.kineticScrollNeeded&&d<200&&Math.abs(i-e)>10&&u.animate({scrollTop:u[0].scrollTop+h}),s.off(S+w,".k-scheduler-header-all-day td, .k-scheduler-content td",l))}}))},_navigation:function(){var e=this,t=e.wrapper;t.on("focus"+w,(function(){var n=e._selection;setTimeout((function(){e._preventFocus?e._preventFocus=!1:(n&&!(n.events.length>0&&0===t.find("[data-uid='"+n.events[0]+"']").length)||e._userTouched||e._mouseDown?e._mouseDown=!1:e._initialFocus(),e._select())}),300)})),t.on("focusout"+w,(function(){e._ctrlKey=e._shiftKey=!1})),t.on("keydown"+w,e._keydown.bind(e)),t.on("keyup"+w,(function(t){e._ctrlKey=t.ctrlKey,e._shiftKey=t.shiftKey}))},_selectable:function(){var e=this,t=e.wrapper;if(e.options.selectable){t.on(x+w,".k-scheduler-header-all-day td, .k-scheduler-content td, .k-event, .k-scheduler-body td .k-link",(function(t){e._isTouch(t)||e._mouseDownSelection(t)}));var n=e._mouseMove.bind(e);t.on(x+w,".k-scheduler-header-all-day td, .k-scheduler-content td",(function(i){var r=i.which,o=i.button,a=r&&3===r||o&&2==o;e._isTouch(i)||a||t.on(D+w,".k-scheduler-header-all-day td, .k-scheduler-content td",n)})),t.on("mouseup"+w+" mousecancel"+w,(function(){t.off(D+w,".k-scheduler-header-all-day td, .k-scheduler-content td",n)}))}},_mouseDownSelection:function(t){var i=t.which,r=t.button;i&&3===i||r&&2==r||(t.ctrlKey&&(this._ctrlKey=t.ctrlKey),t.shiftKey&&(this._shiftKey=t.shiftKey),this._mouseDown=!0,this._createSelection(t.currentTarget),e(t.currentTarget).hasClass("k-event")&&(this._selection.eventElement=t.currentTarget)),"year"!==this.view().name&&n._activeElement()!==this.wrapper.get(0)?n.focusElement(this.wrapper):this._select(),this.toolbar&&this.toolbar.find("."+L).removeClass(L)},_selectFirstSlot:function(){var e,t=this.wrapper.find(".k-scheduler-header-all-day").find("td").first(),n=this.wrapper.find(".k-scheduler-content").find("td").first();e=t.length>0?t:n.length>0?n:this.wrapper.find(".k-scheduler-body").find(".k-link").first(),this._createSelection(e)},_firstEvent:function(){var e,t,n,i=this.wrapper.find(".k-scheduler-header-wrap .k-event, .k-task").first(),r=this.wrapper.find(".k-scheduler-content .k-event").first();return i.length>0?r.length>0?(t=this.occurrenceByUid(i.data("uid")),n=this.occurrenceByUid(r.data("uid")),e=t.start<=n.start?i:r):e=i:r&&(e=r),e},_initialFocus:function(){var e=this._firstEvent();this.options.selectable?e&&e.length>0?(this._createSelection(e),this._selection.eventElement=e[0]):this._selectFirstSlot():this.toolbar&&0===this.toolbar.find("."+L).length?this._focusToolbar():this.toolbar&&this.toolbar.find("."+L).removeClass(L)},_select:function(){var t=this,n=t.view(),i=t.wrapper,r=n.current(),o=t._selection,a=t._old?t._old.selection:null,s=t._old?t._old.eventsLength:null;if(o&&(r&&(r.removeAttribute("id"),i.removeAttr("aria-activedescendant")),n.select(o),t._selection.eventElement=null,(r=n.current())&&(r.setAttribute("id",t._ariaId),i.attr("aria-activedescendant",t._ariaId),a!==r||o.events&&s!==o.events.length))){var l=e(r).data("uid");if(t._old&&l&&l===e(t._old.selection).data("uid")&&o.events&&t._old.eventsLength===o.events.length)return;var c=t._selectedEvents(),d=n._selectedSlots;t._old={selection:r,eventsLength:c.length},t.trigger(A,{start:o.start,end:o.end,events:c,slots:d,resources:n._resourceBySlot(o)})}},_selectedEvents:function(){for(var e,t=this._selection.events,n=t.length,i=0,r=[];i<n;i++)(e=this.occurrenceByUid(t[i]))&&r.push(e);return r},_tapPosition:function(e,t){return/touch/.test(e.type)?(e.originalEvent||e).changedTouches[0]["page"+t]:e["page"+t]},_touchMove:function(e){var t=this,i=t.wrapper.find(".k-scheduler-content"),r=i[0].scrollHeight>i[0].clientHeight,o=i[0].scrollWidth>i[0].clientWidth,a=t._tapPosition(e,"Y"),s=t._tapPosition(e,"X"),l=i[0].scrollTop-Math.round(a-t._touchPosY),c=i[0].scrollLeft-Math.round(s-t._touchPosX),d=r&&Math.abs(a-t._touchPosY)>10,u=o&&Math.abs(a-t._touchPosY)>10;t._dragging||n.support.kineticScrollNeeded||!t._isTouch(e)||(d||u)&&(t._amplitude=Math.round(a-t._touchPosY),t._touchPosY=a,t._touchPosX=s,i.animate({scrollTop:l,scrollLeft:c},0),t.view()._scrolling=!0)},_mouseMove:function(t){var n=this;clearTimeout(n._moveTimer),n._isTouch(t)||(n._moveTimer=setTimeout((function(){var i=n.view(),r=n._selection;if(r){var o=i.selectionByElement(e(t.currentTarget));if(o&&r.groupIndex===o.groupIndex){var a=o.startDate(),s=o.endDate();a>=r.end?r.backward=!1:s<=r.start&&(r.backward=!0),r.backward?r.start=a:r.end=s,n._select()}}}),5))},_viewByIndex:function(e){var t,n=this.views;for(t in n){if(!e)return t;e--}},_keydownToolbar:function(e){var t=e.keyCode;return e.altKey&&t===c.DOWN&&this.toolbar.find(".k-nav-current").hasClass(L)?(this._showCalendar(),void e.preventDefault()):t===c.DOWN?("year"===this._selectedViewName?this.view().calendar.focus():document.activeElement!==this.element[0]&&this.element.focus(),void e.preventDefault()):void 0},_keydownView:function(e){var t,i,r,o=e.keyCode,a=16===o||18===o||17===o||91===o||92===o,s=this._selection,l=this.view(),d=l.options.editable,u=[c.LEFT,c.RIGHT,c.UP,c.DOWN],h=n.support.isRtl(this.element);a||s&&(o===c.ENTER?s.events.length&&d&&!1!==d.update&&this.editEvent(s.events[0]):o!==c.DELETE&&o!==c.BACKSPACE||!1===d||!1===d.destroy?u.indexOf(o)>-1?(t=o===c.UP||o===c.LEFT&&!h||o===c.RIGHT&&h,l.moveToEvent(s,t)&&(this._select(),document.activeElement!==this.element[0]&&this.element.trigger("focus"),e.preventDefault())):o!==c.HOME&&o!==c.END||(e.preventDefault(),i=this.view().content.eq(0),r=o===c.HOME?i.find(".k-scheduler-table td").first():i.find(".k-scheduler-table td").last(),this.view()._scrollTo(r[0],i[0])):this.removeEvent(s.events[0]))},_keydownShortcut:function(e){var t=new Date,r=this.options.timezone,o=this.view().options.editable;if(66===e&&this.view().toggleFullDay)this.view().toggleFullDay();else if(67===e&&o&&!1!==o.create)this.addEvent(_({},{start:this.date(),end:this.date()}));else if(84===e){if(r){var a=n.timezone.offset(t,r);i=n.timezone.convert(t,t.getTimezoneOffset(),a)}else i=t;this.trigger("navigate",{view:this._selectedViewName,action:"today",date:i})||this.date(i)}},_keydownYearView:function(e){var t=this.view(),n=this._selection,i=e.keyCode;i!==c.TAB&&(i===c.F10?(this._focusToolbar(),e.preventDefault()):(this.toolbar.find("."+L).removeClass(L),t.calendar.focus()),n&&this._adjustSelectedDate(),e.preventDefault())},_keydownAgendaView:function(e){var t,n,i=e.keyCode,r=this.view(),o=this._selection;r.move(o,i)?(e.preventDefault(),this.toolbar.find("."+L).removeClass(L),this._select()):i!==c.HOME&&i!==c.END||(e.preventDefault(),t=this.view().content.eq(0),n=i===c.HOME?t.find(".k-scheduler-table td").first():t.find(".k-scheduler-table td").last(),this.view()._scrollTo(n[0],t[0]))},_keydownChangeView:function(e){var t,n=e-49;-1===n&&(n=9),(t=this._viewByIndex(n))&&!this.trigger("navigate",{view:t,action:"changeView",date:this.date()})&&this.view(t)},_keydownChangeDate:function(e){var t=n.support.isRtl(this.element),r=t&&e===c.LEFT||!t&&e===c.RIGHT?"next":"previous";i="next"===r?this.view().nextDate():this.view().previousDate(),this.trigger("navigate",{view:this._selectedViewName,action:r,date:i})||(this.date(i),this._initialFocus(),this._select())},_keydown:function(t){var n=t.keyCode,i=e(t.target).closest(".k-toolbar").length>0,r=t.altKey;if(this._ctrlKey=t.ctrlKey,this._shiftKey=t.shiftKey,n===c.ESC&&this.popup&&this.popup.visible())return this.popup.close(),void t.preventDefault();if(n!==c.LEFT&&n!==c.RIGHT||!this._shiftKey)if(r&&n>=48&&n<=57)this._keydownChangeView(n);else if([66,67,84].indexOf(n)>-1)e(t.target).hasClass("k-scheduler-search-input")||this._keydownShortcut(n);else if(i)this._keydownToolbar(t);else{if("year"===this._selectedViewName)return void this._keydownYearView(t);if(n===c.F10)return this._focusToolbar(),void t.preventDefault();if("agenda"===this._selectedViewName)return void this._keydownAgendaView(t);this._keydownView(t)}else this._keydownChangeDate(n)},_focusToolbar:function(){this.toolbar.find("[tabindex=0]").first().trigger("focus").addClass(L)},_createSelection:function(t){var i,r,o=this._selection;(t=e(t)).is(".k-event")&&(i=t.attr(n.attr("uid")),o&&-1!==o.events.indexOf(i)&&!this._ctrlKey)||(o&&(this._ctrlKey||this._shiftKey)||(o=this._selection={events:[],groupIndex:0}),(r=this.view().selectionByElement(t))&&(o.groupIndex=r.groupIndex||0),i&&(r=ne(this._data,i)),r&&r.uid&&(i=[r.uid]),this._updateSelection(r,i),this._adjustSelectedDate())},_updateSelection:function(e,i,r){var o=this._selection;if(e&&o){var a=this.view();if(e.uid&&(e=a._updateEventForSelection(e)),this._shiftKey&&o.start&&o.end){var s=e.end<o.end;o.end=e.endDate?e.endDate():e.end,s&&a._timeSlotInterval&&n.date.setTime(o.end,-a._timeSlotInterval())}else o.start=e.startDate?e.startDate():e.start,o.end=e.endDate?e.endDate():e.end;if(o.isAllDay="isDaySlot"in e?e.isDaySlot:e.isAllDay,null!==r&&r!==t&&(o.groupIndex=r),o.index=e.index,this._ctrlKey){var l=i&&i.length?o.events.indexOf(i[0]):-1;l>-1?o.events.splice(l,1):o.events=o.events.concat(i||[])}else o.events=i||[]}},options:{name:"Scheduler",date:V,editable:!0,autoBind:!0,snap:!0,mobile:!1,timezone:"",allDaySlot:!0,min:new Date(1900,0,1),max:new Date(2099,11,31),toolbar:null,workWeekStart:1,workWeekEnd:5,workDays:null,showWorkHours:!1,startTime:V,endTime:V,currentTimeMarker:{updateInterval:1e4,useLocalTimezone:!0},ongoingEvents:{cssClass:"k-event-ongoing",enabled:!1,updateInterval:6e4,useLocalTimezone:!0},footer:{},messages:{today:"Today",pdf:"Export to PDF",save:"Save",cancel:"Cancel",destroy:"Delete",resetSeries:"Reset Series",deleteWindowTitle:"Delete event",next:"Next",previous:"Previous",refresh:"Refresh",selectView:"Select view",ariaSlotLabel:"Selected from {0:t} to {1:t}",ariaEventLabel:{on:"on",at:"at",to:"to",allDay:"(all day)",prefix:""},search:"Search...",views:{day:"Day",week:"Week",workWeek:"Work Week",agenda:"Agenda",month:"Month",timeline:"Timeline",timelineWeek:"Timeline Week",timelineWorkWeek:"Timeline Work Week",timelineMonth:"Timeline Month",year:"Year"},recurrenceMessages:{deleteWindowTitle:"Delete Recurring Item",resetSeriesWindowTitle:"Reset Series",deleteWindowOccurrence:"Delete current occurrence",deleteWindowSeries:"Delete the series",editWindowTitle:"Edit Recurring Item",editWindowOccurrence:"Edit current occurrence",editWindowSeries:"Edit the series"},editable:{confirmation:"Are you sure you want to delete this event?"},editor:{title:"Title",start:"Start",end:"End",allDayEvent:"All day event",description:"Description",repeat:"Repeat",timezone:"Timezone",startTimezone:"Start timezone",endTimezone:"End timezone",separateTimezones:"Use separate start and end time zones",timezoneEditorTitle:"Timezones",timezoneEditorButton:"Time zone",timezoneTitle:"Time zones",noTimezone:"No timezone",editorTitle:"Event"}},height:null,width:null,resources:[],group:{resources:[],orientation:"horizontal"},views:[],selectable:!1},events:[z,F,I,H,"add","dataBinding","dataBound","moveStart","move","moveEnd","resizeStart","resize","resizeEnd","navigate",A],destroy:function(){var t=this;if(u.fn.destroy.call(t),t.dataSource&&(t.dataSource.unbind(A,t._refreshHandler),t.dataSource.unbind(M,t._progressHandler),t.dataSource.unbind(E,t._errorHandler)),t._resourceRefreshHandler)for(var i=0;i<t.resources.length;i++){var r=t.resources[i].dataSource;r.unbind(A,t._resourceRefreshHandler),r.unbind(M,t._resourceProgressHandler),r.unbind(E,t._resourceErrorHandler)}t.calendar&&(t.calendar.destroy(),t.popup.destroy()),t.view()&&t.view().destroy(),t._editor&&t._editor.destroy(),this._moveDraggable&&this._moveDraggable.destroy(),this._resizeDraggable&&this._resizeDraggable.destroy(),t.mediaQueryList&&t.mediaQueryList.destroy(),t.element.add(t.wrapper).add(t.toolbar).add(t.popup).off(w),clearTimeout(t._moveTimer),t._model=null,t.toolbar=null,t.element=null,e(window).off("resize"+w,t._resizeHandler),n.destroy(t.wrapper)},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.options.autoBind&&e.fetch?e.fetch():y(e)&&this.view(this._selectedView)},items:function(){var e=this.wrapper.find(".k-scheduler-content"),t=this.view();return t&&"agenda"===t.options.name?e.find(".k-task"):e.find(".k-event").add(this.wrapper.find(".k-scheduler-header-wrap").find(".k-scheduler-header-all-day").siblings())},_movable:function(){var t,i,r,o,a,s,l,c,d,u=this,h=0,p=[],f=[],m=u._isMobile(),g=u.options.editable&&!1!==u.options.editable.move,v=u.options.editable&&!1!==u.options.editable.resize;(g||v&&m)&&(u._dragging=!1,m&&n.support.mobileOS.android&&(h=5),u._moveDraggable=new n.ui.Draggable(u.element,{distance:h,filter:".k-event",ignore:".k-resize-handle",holdToDrag:m,autoScroll:!0}),g&&u._moveDraggable.bind("dragstart",(function(e){var a=u.view(),h=e.currentTarget,f=u._isTouch(e);if(u._dragging=!0,!a.options.editable||!1===a.options.editable.move)return u._dragging=!1,void e.preventDefault();if(f&&!h.hasClass("k-event-active"))return u._dragging=!1,u.element.find(".k-event-active").removeClass("k-event-active"),void e.preventDefault();if(s=u.occurrenceByUid(h.attr(n.attr("uid"))),l=s.clone(),s.clone(),l.update(a._eventOptionsForMove(l)),l.inverseColor=u._isInverseColor(h),p=[],u._selection)for(var m=u._selection.events,g=0;g<m.length;g++){var v=u.occurrenceByUid(m[g]).clone(),_=this.element.find('div.k-event[data-uid="'+v.uid+'"]').eq(0);v.update(a._eventOptionsForMove(v)),_.length&&(v.inverseColor=u._isInverseColor(_)),p.push(v)}else p.push(l);t=a._slotByPosition(e.x.startLocation,e.y.startLocation),r=a._resourceBySlot(t),d=o=t.startOffset(e.x.startLocation,e.y.startLocation,u.options.snap),i=t,c=t,t&&!u.trigger("moveStart",{event:s})||e.preventDefault()})).bind("drag",(function(r){var h,m,g,v=u.view(),_=v._slotByPosition(r.x.location,r.y.location);if(_){if(a=_.startOffset(r.x.location,r.y.location,u.options.snap),_.isDaySlot!==t.isDaySlot)if(_.isDaySlot!==c.isDaySlot){var b=e(t.element).index(),y=e(_.element).parent().children().eq(b);for(t=v._slotByPosition(y.offset().left,y.offset().top),o=t.startOffset(r.x.location,r.y.location,!0),f=p.map((function(e){return e.clone()})),g=0;g<p.length;g++)p[g].isAllDay!=_.isDaySlot&&(p[g].isAllDay=_.isDaySlot,p[g].end=n.date.getDate(p[g].start),p[g].start=n.date.getDate(p[g].start),_.isDaySlot||(n.date.setTime(p[g].start,n.date.getMilliseconds(v.startTime())),n.date.setTime(p[g].end,n.date.getMilliseconds(v.startTime())+v._timeSlotInterval())))}else t=e.extend(!0,{},c),o=d,p=f;for(h=a-o,g=0;g<p.length;g++)v._updateMoveHint(p[g],_.groupIndex,h);if(m=fe(l,h),u.trigger("move",{event:s,slot:{element:_.element,start:_.startDate(),end:_.endDate(),isDaySlot:_.isDaySlot},resources:v._resourceBySlot(_),start:m.start,end:m.end}))for(g=0;g<p.length;g++)v._updateMoveHint(p[g],_.groupIndex,h);else i=_}})).bind("dragend",(function(t){u.view()._removeMoveHint();var d=a-o,h=fe(l,d),m=h.start,g=h.end;u._dragging=!1;var v=u.view()._resourceBySlot(i);if(!u.trigger("moveEnd",{event:s,slot:{element:i.element,start:i.startDate(),end:i.endDate()},start:m,end:g,resources:v})&&(s.start.getTime()!==m.getTime()||s.end.getTime()!==g.getTime()||c.isDaySlot!==i.isDaySlot||n.stringify(v)!==n.stringify(r))){u._isMultiDrag=p.length>1;for(var _=0;_<p.length;_++){var b=p[_];h=fe(b,d);var y=u.view()._eventOptionsForMove(b),w=e.extend({isAllDay:b.isAllDay,start:h.start,end:h.end},y,v);u._updateEvent(null,b,w)}u._isMultiDrag&&(u.dataSource.sync(),u._isMultiDrag=!1)}t.currentTarget.removeClass("k-event-active"),this.cancelHold(),p=[],f=[]})).bind("dragcancel",(function(){u.view()._removeMoveHint(),this.cancelHold(),p=[],f=[]})),u._moveDraggable.bind("hold",(function(e){u._isTouch(e)&&(u.element.find(".k-event-active").removeClass("k-event-active"),u.options.selectable&&u._createSelection(e.currentTarget),e.currentTarget.addClass("k-event-active"))})))},_resizable:function(){var t,i,r,o,a,s=this,l=0;function c(e){var t={"k-resize-e":"east","k-resize-w":"west","k-resize-n":"north","k-resize-s":"south"};for(var n in t)if(e.hasClass(n))return t[n]}s._isMobile()&&n.support.mobileOS.android&&(l=5),s._resizeDraggable=new n.ui.Draggable(s.element,{distance:l,filter:".k-resize-handle",autoScroll:!0,dragstart:function(l){var c=e(l.currentTarget).closest(".k-event").attr(n.attr("uid")),d=s.view();s._dragging=!0,r=s.occurrenceByUid(c),o=r.clone(),d._updateEventForResize(o),a=d._slotByPosition(l.x.startLocation,l.y.startLocation),s.trigger("resizeStart",{event:r})&&l.preventDefault(),t=n.date.toUtcTime(o.start),i=n.date.toUtcTime(o.end)},drag:function(l){if(a){var d=c(e(l.currentTarget)),u=s.view(),h=u._slotByPosition(l.x.location,l.y.location);if(h&&a.groupIndex==h.groupIndex){a=h;var p=t,f=i;"south"==d?!a.isDaySlot&&a.end-n.date.toUtcTime(o.start)>=u._timeSlotInterval()&&(i=o.isAllDay?a.startOffset(l.x.location,l.y.location,s.options.snap):a.endOffset(l.x.location,l.y.location,s.options.snap)):"north"==d?!a.isDaySlot&&n.date.toUtcTime(o.end)-a.start>=u._timeSlotInterval()&&(t=a.startOffset(l.x.location,l.y.location,s.options.snap)):"east"==d?a.isDaySlot&&n.date.toUtcTime(n.date.getDate(a.endDate()))>=n.date.toUtcTime(n.date.getDate(o.start))?i=o.isAllDay?a.startOffset(l.x.location,l.y.location,s.options.snap):a.endOffset(l.x.location,l.y.location,s.options.snap):!a.isDaySlot&&a.end-n.date.toUtcTime(o.start)>=u._timeSlotInterval()&&(i=a.endOffset(l.x.location,l.y.location,s.options.snap)):"west"==d&&(a.isDaySlot&&n.date.toUtcTime(n.date.getDate(o.end))>=n.date.toUtcTime(n.date.getDate(a.startDate()))||!a.isDaySlot&&n.date.toUtcTime(o.end)-a.start>=u._timeSlotInterval())&&(t=a.startOffset(l.x.location,l.y.location,s.options.snap)),s.trigger("resize",{event:r,slot:{element:a.element,start:a.startDate(),end:a.endDate()},start:n.timezone.toLocalDate(t),end:n.timezone.toLocalDate(i),resources:u._resourceBySlot(a)})?(t=p,i=f):u._updateResizeHint(o,a.groupIndex,t,i)}}},dragend:function(l){var d=e(l.currentTarget),u=new Date(o.start.getTime()),h=new Date(o.end.getTime()),p=c(d);s._dragging=!1,s.view()._removeResizeHint(),"south"==p?h=n.timezone.toLocalDate(i):"north"==p?u=n.timezone.toLocalDate(t):"east"==p?h=a.isDaySlot?n.date.getDate(n.timezone.toLocalDate(i)):n.timezone.toLocalDate(i):"west"==p&&(a.isDaySlot?((u=new Date(n.timezone.toLocalDate(t))).setHours(0),u.setMinutes(0)):u=n.timezone.toLocalDate(t)),!s.trigger("resizeEnd",{event:r,slot:{element:a.element,start:a.startDate(),end:a.endDate()},start:u,end:h,resources:s.view()._resourceBySlot(a)})&&h.getTime()>=u.getTime()&&(o.start.getTime()==u.getTime()&&o.end.getTime()==h.getTime()||(s.view()._updateEventForResize(r),s._updateEvent(p,r,{start:u,end:h}))),a=null,r=null},dragcancel:function(){s._dragging=!1,s.view()._removeResizeHint(),a=null,r=null}})},_updateEvent:function(e,t,i){var o=this,s=function(t,n){var a;try{o._preventRefresh=!0,t.update(i),o._convertDates(t),a=t.start,e&&t.duration()%r==0&&0===a.getHours()&&0===a.getMinutes()&&0===a.getSeconds()&&0===a.getMilliseconds()&&t.set("isAllDay",!0)}finally{o._preventRefresh=!1}o.trigger(H,{event:t})||(n&&n(),o._isMultiDrag||o.dataSource.sync())},l=function(e){return e.recurrenceRule?o.dataSource.getByUid(e.uid):o.dataSource.get(e.recurrenceId)};if(t.recurrenceRule||t.isOccurrence()){var c=o.options.messages.recurrenceMessages;o._showRecurringDialog(t,(function(){var e,n=l(t),i=n.toOccurrence({start:t.start,end:t.end});e=i.uid,s(o.dataSource.add(i),(function(){o._convertDates(n),o._selection&&o._selection.events.push(e)}))}),(function(){var r=l(t);if("south"==e||"north"==e){if(i.start){var c=n.date.getDate(r.start);n.date.setTime(c,a(i.start)),i.start=c}if(i.end){var d=n.date.getDate(r.end);n.date.setTime(d,a(i.end)),i.end=d}}o.dataSource._removeExceptions(r),s(r)}),{title:c.editWindowTitle,text:c.editRecurring?c.editRecurring:W,occurrenceText:c.editWindowOccurrence,seriesText:c.editWindowSeries})}else s(o.dataSource.getByUid(t.uid))},_modelForContainer:function(t){return t=e(t).closest("["+n.attr("uid")+"]"),this.dataSource.getByUid(t.attr(n.attr("uid")))},showDialog:function(e){this.toolbar.find("."+L).removeClass(L),this._editor.showDialog(e)},focus:function(){this.wrapper.trigger("focus")},_confirmation:function(e,t,i){var r=this.options.editable;if(!0===r||!1!==r.confirmation){var o=this.options.messages,a=o.deleteWindowTitle,s=typeof r.confirmation===p?r.confirmation:o.editable.confirmation;if(this._isEditorOpened()&&t.isRecurring()){var l=this.options.messages.recurrenceMessages;a=l.deleteWindowTitle,s=t.isException()||t.isNew()?l.deleteRecurringConfirmation?l.deleteRecurringConfirmation:"Are you sure you want to delete this event occurrence?":l.deleteSeriesConfirmation?l.deleteSeriesConfirmation:"Are you sure you want to delete the whole series?",i&&(a=l.resetSeriesWindowTitle,s=l.resetSeriesConfirmation?l.resetSeriesConfirmation:"Are you sure you want to reset the whole series?")}var c=[{name:"destroy",text:i?o.resetSeries:o.destroy,click:function(){e()}}];this._isMobile()&&n.Pane||c.push({name:"canceledit",text:o.cancel,click:function(){e(!0)}}),this._unbindResize(),this.showDialog({model:t,text:s,title:a,buttons:c}),this._bindResize()}else e()},addEvent:function(e){var t,n=this._editor.editable,i=this.dataSource;e=e||{},!this.trigger("add",{event:e})&&(n&&n.end()||!n)&&(this.cancelEvent(),e&&e.toJSON&&(e=e.toJSON()),(t=i.add(e))&&(this.cancelEvent(),this._editEvent(t)))},saveEvent:function(){var e=this,t=e._editor,n=e.dataSource;if(t){var i,r,o,a=t.editable,s=t.container,l=e._modelForContainer(s);if(s&&a&&a.end()&&!e.trigger(H,{container:s,event:l})){if(!l.isOccurrence()&&l.recurrenceException&&!l.recurrenceRule){for(r=(i=n.data()).length-1;r>=0;r-=1)(o=i[r])&&o.recurrenceId===l.id&&n.remove(o);l.set("recurrenceException","")}l.dirty||l.isOccurrence()||e._convertDates(l,"remove"),n.sync()}}},cancelEvent:function(){var e,t=this._editor,n=t.container;n&&((e=this._modelForContainer(n))&&e.isOccurrence()&&(this._convertDates(e,"remove"),this._convertDates(this.dataSource.get(e.recurrenceId),"remove")),this.dataSource.cancelChanges(e),t.close())},editEvent:function(e){var t="string"==typeof e?this.occurrenceByUid(e):e;t&&(this.cancelEvent(),t.isRecurring()?this._editRecurringDialog(t):this._editEvent(t))},_editEvent:function(e){this._preventRefresh=!0,this._unbindResize(),this._createPopupEditor(e),this.toolbar.find("."+L).removeClass(L),this._bindResize()},_editRecurringDialog:function(e){var t=this,n=t.options.messages.recurrenceMessages;t._showRecurringDialog(e,(function(){e.isException()?t._editEvent(e):t.addEvent(e)}),(function(){e.recurrenceId&&(e=t.dataSource.get(e.recurrenceId)),t._editEvent(e)}),{title:n.editWindowTitle,text:n.editRecurring?n.editRecurring:W,occurrenceText:n.editWindowOccurrence,seriesText:n.editWindowSeries})},_showRecurringDialog:function(e,t,n,i){var r=this.options.editable,o=v(r)?r.editRecurringMode:"dialog";"occurrence"===o||this._isMultiDrag?t():"series"===o?n():(this._unbindResize(),this.showDialog({model:e,title:i.title,text:i.text,buttons:[{text:i.occurrenceText,click:t},{text:i.seriesText,click:n}]}),this._bindResize())},_createButton:function(e){var t=e.template||j,i=typeof e===p?e:e.name||e.text,r={className:"k-scheduler-"+(i||"").replace(/\s/g,""),text:i,attr:""};if(!(i||v(e)&&e.template))throw new Error("Custom commands should have name specified");return v(e)?(e.className&&(e.className+=" "+r.className),"edit"===i&&v(e.text)&&((e=_(!0,{},e)).text=e.text.edit),r=_(!0,r,le[i],e)):r=_(!0,r,le[i]),r.className?-1===r.className.indexOf("k-button-solid-primary")&&(r.className+=" k-button-solid-base"):r.className="k-button-solid-base",n.template(t)(r)},_convertDates:function(e,t){var i=this.dataSource.reader.timezone,r=e.startTimezone,o=e.endTimezone,a=e.start,s=e.start;t=t||"apply",r=r||o,o=o||r,r&&(i?"apply"===t?(a=n.timezone.convert(e.start,i,r),s=n.timezone.convert(e.end,i,o)):(a=n.timezone.convert(e.start,r,i),s=n.timezone.convert(e.end,o,i)):(a=n.timezone[t](e.start,r),s=n.timezone[t](e.end,o)),e._set("start",a),e._set("end",s))},_createEditor:function(){var e,t=this;(e=this._isMobile()&&n.Pane?t._editor=new ve(this.wrapper,_({},this.options,{target:this,timezone:t.dataSource.reader.timezone,resources:t.resources,createButton:this._createButton.bind(this)})):t._editor=new _e(this.wrapper,_({},this.options,{target:this,createButton:this._createButton.bind(this),timezone:t.dataSource.reader.timezone,resources:t.resources}))).bind("cancel",(function(e){t.trigger("cancel",{container:e.container,event:e.model})?e.preventDefault():(t._preventRefresh=!1,t.cancelEvent(),t._attemptRefresh&&t.refresh(),t.focus())})),e.bind("edit",(function(e){t.trigger(F,{container:e.container,event:e.model})&&e.preventDefault()})),e.bind("save",(function(){t._preventRefresh=!1,t.saveEvent()})),e.bind("remove",(function(e){t._preventRefresh=!1,t.removeEvent(e.model)})),e.bind("resetSeries",(function(e){t._confirmation((function(n){t._preventRefresh=!1,n||(t.dataSource._removeExceptions(e.model),t.saveEvent())}),e.model,!0)}))},_createPopupEditor:function(e){var t=this._editor;e.isNew()&&!e.isOccurrence()||(e.isOccurrence()&&this._convertDates(e.recurrenceId?this.dataSource.get(e.recurrenceId):e),this._convertDates(e)),this.editable=t.editEvent(e)},removeEvent:function(e){var t=this,n="string"==typeof e?t.occurrenceByUid(e):e;n&&(n.isRecurring()?t._deleteRecurringDialog(n):t._confirmation((function(e){e||t._removeEvent(n)}),n))},occurrenceByUid:function(e){var t=this.dataSource.getByUid(e);return t||(t=ne(this._data,e)),t},occurrencesInRange:function(e,t){return new n.data.Query(this._data).filter({logic:"or",filters:[{logic:"and",filters:[{field:"start",operator:"gte",value:e},{field:"end",operator:"gte",value:e},{field:"start",operator:"lt",value:t}]},{logic:"and",filters:[{field:"start",operator:"lte",value:e},{field:"end",operator:"gt",value:e}]}]}).toArray()},_removeEvent:function(e){this.trigger(z,{event:e})||this.dataSource.remove(e)&&this.dataSource.sync()},_deleteRecurringDialog:function(e){var t,n,i,r,o,a,s=this,l=e,c=s.options.editable,d=v(c)?c.editRecurringMode:"dialog";t=function(){var e=l.recurrenceId?l:l.toOccurrence(),t=s.dataSource.get(e.recurrenceId);s._convertDates(t),s._removeEvent(e)},n=function(){l.recurrenceId&&(l=s.dataSource.get(l.recurrenceId)),s._removeEvent(l)},i=function(){s.dataSource.remove(l),s.dataSource.sync()},("dialog"!=d||s._isEditorOpened())&&(r=function(){s._confirmation((function(e){e||t()}),l)},o=function(){s._confirmation((function(e){e||n()}),l)},a=function(){s._confirmation((function(e){e||i()}),l)});var u=o||n,h=r||t,p=a||i;if(s._isEditorOpened())e.isException()?h():e.isNew()?p():u();else{var f=s.options.messages.recurrenceMessages;s._showRecurringDialog(e,h,u,{title:f.deleteWindowTitle,text:f.deleteRecurring?f.deleteRecurring:"Do you want to delete only this event occurrence or the whole series?",occurrenceText:f.deleteWindowOccurrence,seriesText:f.deleteWindowSeries})}},_isEditorOpened:function(){return!!this._editor.container},_unbindView:function(e){e.destroy()},_bindView:function(t){var n=this;n.options.editable&&(n._viewRemoveHandler&&t.unbind(z,n._viewRemoveHandler),n._viewRemoveHandler=function(e){n.removeEvent(e.uid)},t.bind(z,n._viewRemoveHandler),n._viewAddHandler&&t.unbind("add",n._viewAddHandler),n._viewAddHandler=function(e){n.addEvent(e.eventInfo)},t.bind("add",this._viewAddHandler),n._viewEditHandler&&t.unbind(F,n._viewEditHandler),n._viewEditHandler=function(e){n.editEvent(e.uid)},t.bind(F,this._viewEditHandler)),n._viewNavigateHandler&&t.unbind("navigate",n._viewNavigateHandler),n._viewNavigateHandler=function(e){if(e.action)n.trigger("navigate",{view:e.view,isWorkDay:e.isWorkDay,action:e.action,date:e.date})||n.date(e.date);else if(e.view){var t="isWorkDay"in e,i=t?"changeWorkDay":"changeView";n.trigger("navigate",{view:e.view,isWorkDay:e.isWorkDay,action:i,date:e.date})||(t&&(n._workDayMode=e.isWorkDay),n._selectView(e.view),n.date(e.date))}},t.bind("navigate",n._viewNavigateHandler),n._viewActivateHandler&&t.unbind("activate",n._viewActivateHandler),n._viewActivateHandler=function(){n._selection&&(this.constrainSelection(n._selection),0===e(document.activeElement).closest(".k-scheduler-toolbar").length&&(document.activeElement!==n.wrapper[0]?n.element.trigger("focus"):n._select()),n._adjustSelectedDate())},t.bind("activate",n._viewActivateHandler)},_selectView:function(e){var t=this;if(e&&t.views[e])if(t._selectedView&&t._unbindView(t._selectedView),t._selectedView=t._renderView(e),t._selectedViewName=e,this._initialSize&&(this._initialSize=!1,this._onMediaChange(window.matchMedia(O))),t._viewsCount>1&&!t._isMobile()){var i=t.toolbar.find("["+n.attr("name")+"="+e+"]"),r=t.toolbar.find(".k-views-dropdown"),o=i.closest(".k-button-group").data("kendoButtonGroup");r.val(e),o&&o.select(i)}else if(t._viewsCount>1){t.toolbar.find(".k-scheduler-mobile-views").find("[value="+e.replace(/\./g,"\\.")+"]").prop("selected","selected")}},view:function(e){var t=this;return e?("year"===e?t.wrapper.removeAttr("tabindex"):t.wrapper.attr("tabindex",0),t._selectView(e),void t.rebind()):t._selectedView},viewName:function(){return this.view().name},_renderView:function(e){var t=this._initializeView(e);return this._bindView(t),(n.support.mouseAndTouchPresent||n.support.pointers)&&(t.content.css("-ms-touch-action","pinch-zoom"),t.content.css("touch-action","pinch-zoom")),this._model.set("formattedDate",t.dateForTitle()),this._model.set("formattedShortDate",t.shortDateForTitle()),this._model.set("formattedMobileDate",t.mobileDateForTitle?t.mobileDateForTitle():t.shortDateForTitle()),this._model.set("formattedYear",t.mobileYearForTitle?t.mobileYearForTitle():n.format("{0:yyyy}",t.startDate())),t},resize:function(e){var t=this.getSize(),n=this._size,i=this.view();i&&i.groups&&(!e&&n&&t.width===n.width&&t.height===n.height||(this.refresh({action:"resize"}),this._size=t))},_adjustSelectedDate:function(){var e=this._model.selectedDate,t=this._selection,i=t.start;i&&!n.date.isInDateRange(e,o(i),o(t.end))&&e.setFullYear(i.getFullYear(),i.getMonth(),i.getDate())},_initializeView:function(e){var t=this.views[e];if(t){var i=v(t),r={},o=t.type;if(typeof o===p&&(o=n.getter(t.type)(window)),i&&t.workDays&&t.workDays.length&&(r.workDays=t.workDays),!o)throw new Error("There is no such view");t=new o(this.wrapper,function(e,t){for(var n in delete e.name,delete e.prefix,delete e.remove,delete e.edit,delete e.add,delete e.navigate,t)e[n]=t[n];return e}(_(!0,{},this.options,i?t:{},{resources:this.resources,date:this.date(),startTime:n.parseDate(t.startTime)||n.parseDate(this.options.startTime),endTime:n.parseDate(t.endTime)||n.parseDate(this.options.endTime),showWorkHours:this._workDayMode}),r))}return t},_views:function(){var e,t,n,i,r,o,a,s=this.options.views;for(this.views={},this._viewsCount=0,o=0,a=s.length;o<a;o++){var l=!1;e=s[o],(i=v(e))?typeof(r=e.type?e.type:e)!==p&&(r=e.name||e.title,l=!0):(r=e,e={}),(t=ye[r])&&!l&&(e.type=t.type,t.title=this.options.messages.views[r],"day"===t.type?t.messages={allDay:this.options.messages.allDay}:"agenda"===t.type&&(t.messages={event:this.options.messages.event,date:this.options.messages.date,time:this.options.messages.time})),e=_({title:r},t,i?e:{}),r&&(this.views[r]=e,this._viewsCount++,n&&!e.selected||(n=r))}n&&(this._selectedViewName=n)},rebind:function(){var t=this,n=t.resources,i=[];t._preventRebind?t._preventRebind=!1:!1===t.options.autoBind&&n&&n.length>0?(n.forEach((function(e){0===e.dataSource.data().length&&(t._preventRebind=!0,i.push(e.dataSource.fetch()))})),e.when.apply(null,i).then((function(){t.dataSource.fetch(),t._preventRebind=!1}))):t.dataSource.fetch()},_dataSource:function(){var e=this,t=e.options,i=t.dataSource;i=y(i)?{data:i}:i,!t.timezone||i instanceof se?i instanceof se&&(t.timezone=i.options.schema?i.options.schema.timezone:""):i=_(!0,i,{schema:{timezone:t.timezone}}),e.dataSource&&e._refreshHandler?e.dataSource.unbind(A,e._refreshHandler).unbind(M,e._progressHandler).unbind(E,e._errorHandler):(e._refreshHandler=e.refresh.bind(e),e._progressHandler=e._requestStart.bind(e),e._errorHandler=e._error.bind(e)),e.dataSource=n.data.SchedulerDataSource.create(i).bind(A,e._refreshHandler).bind(M,e._progressHandler).bind(E,e._errorHandler),e.options.dataSource=e.dataSource},_error:function(){this._progress(!1)},_requestStart:function(){this._progress(!0)},_progress:function(e){var t=this.element.find(".k-scheduler-content");n.ui.progress(t,e)},_resources:function(){for(var t=this,n=t.options.resources,i=[],r=0;r<n.length;r++){var o=n[r],a=o.field,s=o.name||a,l=o.dataSource;if(!a||!l)throw new Error('The "field" and "dataSource" options of the scheduler resource are mandatory.');t.resources.push({field:a,name:s,title:o.title||a,dataTextField:o.dataTextField||"text",dataValueField:o.dataValueField||"value",dataColorField:o.dataColorField||"color",dataParentValueField:o.dataParentValueField||"parentValue",valuePrimitive:null==o.valuePrimitive||o.valuePrimitive,multiple:o.multiple||!1,dataSource:t._resourceDataSource(l,s,i)})}t.options.autoBind?e.when.apply(null,i).then((function(){t.view(t._selectedViewName)})):t._selectView(t._selectedViewName)},_resourceDataSource:function(e,t,i){var r=this,o=y(e)?{data:e}:e,a=n.data.DataSource.create(o);return r.options.autoBind?i.push(a.fetch((function(){r._bindResourceEvents(this,t)}))):r._bindResourceEvents(a,t),a},_bindResourceEvents:function(e,t){var n=this,i=n.options.group&&n.options.group.resources.length&&n.options.group.resources.indexOf(t)>-1;!n._resourceRefreshHandler&&i&&(n._resourceRefreshHandler=n._refreshResource.bind(n),n._resourceErrorHandler=n._error.bind(n)),i&&e.bind(A,n._resourceRefreshHandler).bind(E,n._resourceErrorHandler)},_refreshResource:function(){var e=this;e._editor&&e._editor.editable||e._preventRefresh||e.view(e._selectedViewName)},_initModel:function(){var e=this;e._model=n.observable({selectedDate:new Date(this.options.date),formattedDate:"",formattedShortDate:""}),e._model.bind(A,(function(t){"selectedDate"===t.field&&e.view(e._selectedViewName)}))},_wrapper:function(){var e=this,t=e.options,n=t.height,i=t.width;e.wrapper=e.element.addClass("k-scheduler"),e._isMobile()&&e.wrapper.addClass("k-scheduler-mobile"),n&&e.wrapper.height(n),i&&e.wrapper.width(i)},date:function(e){return null!=e&&o(e)>=o(this.options.min)&&o(e)<=o(this.options.max)&&this._model.set("selectedDate",e),o(this._model.get("selectedDate"))},_processHandlers:function(e){var t=this;t._pdfClickHandler=e=>{e.preventDefault(),t.saveAsPDF()},t._createClickHandler=e=>{e.preventDefault(),t.addEvent()},t._calendarClickHandler=t._currentClickHandler=e=>{e.preventDefault(),t._showCalendar(e.target)},t._todayClickHandler=e=>{e.preventDefault();var i,r=t.options.timezone,o=new Date;if(r){var a=n.timezone.offset(o,r);i=n.timezone.convert(o,o.getTimezoneOffset(),a)}else i=o;t.trigger("navigate",{view:t._selectedViewName,action:"today",date:i})||t.date(i)},t._previousClickHandler=e=>{e.preventDefault();var n=t.view().previousDate();t.trigger("navigate",{view:t._selectedViewName,action:"previous",date:n})||t.date(n)},t._nextClickHandler=e=>{e.preventDefault();var n=t.view().nextDate();t.trigger("navigate",{view:t._selectedViewName,action:"next",date:n})||t.date(n)},t._refreshClickHandler=e=>{e.preventDefault();var n=t.view().name;t.trigger("navigate",{view:n,action:"changeView",date:t.date()})||t.view(n)},t._viewClickHandler=e=>{var i=e.target.attr(n.attr("name"));t.trigger("navigate",{view:i,action:"changeView",date:t.date()})||t.view(i)},Object.values(e).map((e=>{e.name&&(e.click=t["_"+e.name+"ClickHandler"])}))},_processDefaults:function(){var t,i,r=this.views,o=e.extend(!0,{},G),a=[],s=n.support.isRtl(this.wrapper);return Object.keys(r).map((t=>{var n=e.extend(!0,{},o.view);n.text=r[t].title;const i=`ref-view-${t.toLowerCase()}`;n.attributes={[i]:"","data-name":t},n.groupClass="k-scheduler-views",o[t]=n,a.push(t)})),a.length>1&&(t=q({views:this.views,label:this.options.messages.selectView,type:"k-views-dropdown"}),i=q({views:this.views,label:this.options.messages.selectView,type:"k-scheduler-mobile-views"})),o.viewsDdl={template:t},o.viewsMobile={template:i},this._viewsButtons=a,s&&(o.previous.icon="caret-alt-right",o.next.icon="caret-alt-left"),o},_processToolbarArray:function(){var t,n,i,r=this.options,o=r.toolbar,a=[],s=this._isMobile();return o&&(a=Array.isArray(o)?o:[o]),n=e.grep(a,(function(e){return"pdf"==e||"pdf"==e.name})).length>0,i=e.grep(a,(function(e){return"search"==e||"search"==e.name})).length>0,s?(t=[...Y],r.editable&&t[0].push("create")):t=[...K],i&&t.push("search"),n&&(s?t[0].unshift("pdfMobile"):t.unshift("pdf")),1===this._viewsCount?t.push("refresh"):this._viewsCount>1&&(s?t.push("viewsMobile"):(t.push("viewsDdl"),t.push(this._viewsButtons))),t},_processViewTools:function(e){var t=e,n=-1;return e.some(((e,t)=>("views"===e||"views"===e.name)&&(n=t,!0))),n>-1&&t.splice(n,1,"viewsDdl",this._viewsButtons),t},_processToolbarItems:function(){var e=this.options.toolbar.items.desktop||this.options.toolbar.items,t=this.options.toolbar.items.mobile||this.options.toolbar.items;return this._isMobile()?Array.isArray(t)?{tools:this._processViewTools(t),navigation:[]}:{tools:this._processViewTools(t.main),navigation:this._processViewTools(t.navigation)}:(e.main&&(e=e.navigation?e.main.concat(e.navigation):e.main),{tools:this._processViewTools(e)})},_processTools:function(){var e=this.options.toolbar;return e&&e.items?this._processToolbarItems():{tools:this._processToolbarArray()}},_toolbar:function(){var t,i=this,r=i.options,o=i._processDefaults(),{tools:a,navigation:s}=i._processTools(),l=e("<div class='k-scheduler-toolbar'>");i._processHandlers(o),i.wrapper.append(l),i.toolbar=l,l.kendoToolBar({resizable:!1,tools:a,defaultTools:o,parentMessages:r.messages}),!i._isMobile()||s&&0===s.length||(t=e("<div class='k-scheduler-toolbar'>"),i.wrapper.append(t),i.toolbar=i.toolbar.add(t),t.kendoToolBar({resizable:!1,tools:s||[...Q],defaultTools:o,parentMessages:r.messages})),i.toolbar.find(".k-nav-current .k-button-text").attr("data-"+n.ns+"bind","text: formattedDate"),i.toolbar.find(".k-m-date-format").attr("data-"+n.ns+"bind","text: formattedMobileDate"),i.toolbar.find(".k-y-date-format").attr("data-"+n.ns+"bind","text: formattedYear"),n.bind(i.toolbar,i._model),i.toolbar.find(".k-scheduler-search-input").attr({placeholder:r.messages.search,title:r.messages.search}),l.on("input"+w,".k-scheduler-search-input",n.throttle((function(e){i.dataSource.filter({logic:"or",filters:[{field:"title",operator:"contains",value:e.target.value},{field:"description",operator:"contains",value:e.target.value}]})}),250)),l.on(A+w,".k-views-dropdown, .k-scheduler-mobile-views",(function(){var e=this.value;i.trigger("navigate",{view:e,action:"changeView",date:i.date()})||i.view(e)})),i._initialSize=!0},_showCalendar:function(t){var n=this,i=t||n.toolbar.find(".k-nav-current"),r=e('<div class="k-calendar-container"><div class="k-scheduler-calendar"></div></div>');n.popup||(n.popup=new f(r,{anchor:i,activate:function(){n.popup&&n.calendar&&(n.popup._toggleResize(!1),n.calendar.element.find("table").trigger("focus"),n.popup._toggleResize(!0))},open:function(){n.calendar||(n.calendar=new m(this.element.find(".k-scheduler-calendar"),{change:function(){var e=this.value();n.trigger("navigate",{view:n._selectedViewName,action:"changeDate",date:e})||(n.date(e),n.popup.close()),n._isMobile()||(n._selectedView.element.trigger("focus"),n.toolbar.find(".k-nav-current").trigger("focus").addClass(L))},min:n.options.min,max:n.options.max})),n.calendar.element.on("keydown"+w,(function(e){e.keyCode!==c.ESC&&e.keyCode!==c.TAB||(n.popup.close(),n._selectedView.element.trigger("focus"),n.toolbar.find(".k-nav-current").trigger("focus").addClass(L))})),n.calendar.setOptions({start:"year"===n._selectedViewName?"decade":"month",depth:"year"===n._selectedViewName?"decade":"month"}),n.calendar.value(n.date())},copyAnchorStyles:!1})),n.popup.open()},refresh:function(e){var t=this.view(),n=e&&"itemchange"===e.action&&(this._editor.editable||this._preventRefresh)||"signalr"===this.dataSource.options.type&&this._preventRefresh;this._progress(!1),e=e||{},t&&(n?this._attemptRefresh="signalr"===this.dataSource.options.type:this.trigger("dataBinding",{action:e.action||"rebind",index:e.index,items:e.items})||(e&&"resize"===e.action||!this._editor||this._editor.close(),this._data=this.dataSource.expand(t.startDate(),t.visibleEndDate()),t.refreshLayout(),t.render(this._data),this.trigger("dataBound"),this._attemptRefresh=!1))},slotByPosition:function(e,t){var n=this.view();if(!n._slotByPosition)return null;var i=n._slotByPosition(e,t);return i?{startDate:i.startDate(),endDate:i.endDate(),groupIndex:i.groupIndex,element:i.element,isDaySlot:i.isDaySlot}:null},slotByElement:function(t){var n=e(t),i=n.offset(),r=n.width(),o=n.height(),a=i.left+r/2,s=i.top+o/2;i=e(t).offset();return this.slotByPosition(a,s)},resourcesBySlot:function(e){return this.view()._resourceBySlot(e)}}),ye={day:{type:"kendo.ui.DayView"},week:{type:"kendo.ui.WeekView"},workWeek:{type:"kendo.ui.WorkWeekView"},agenda:{type:"kendo.ui.AgendaView"},month:{type:"kendo.ui.MonthView"},timeline:{type:"kendo.ui.TimelineView"},timelineWeek:{type:"kendo.ui.TimelineWeekView"},timelineWorkWeek:{type:"kendo.ui.TimelineWorkWeekView"},timelineMonth:{type:"kendo.ui.TimelineMonthView"},year:{type:"kendo.ui.YearView"}};if(d.plugin(be),n.PDFMixin){n.PDFMixin.extend(be.prototype);var we="k-scheduler-pdf-export";be.fn._drawPDF=function(t){var n=this.wrapper,i=n[0].style.cssText;n.css({width:n.width(),height:n.height()}),n.addClass(we);var r=this,o=new e.Deferred,a=n.find(".k-scheduler-content").find("table").css("table-layout","auto");return setTimeout((function(){a.css("table-layout","fixed"),r.resize(!0),r._drawPDFShadow({},{avoidLinks:r.options.pdf.avoidLinks}).done((function(e){var n={page:e,pageNumber:1,progress:1,totalPages:1};t.notify(n),o.resolve(n.page)})).fail((function(e){o.reject(e)})).always((function(){n[0].style.cssText=i,n.removeClass(we),r.resize(!0),r.resize(!0)}))})),o}}var ke=u.extend({init:function(e,t){var i=this,r=n.timezone.windows_zones;if(!r||!n.timezone.zones_titles)throw new Error("kendo.timezones.min.js is not included.");u.fn.init.call(i,e,t),i.wrapper=i.element,i._zonesQuery=new n.data.Query(r),i._zoneTitleId=n.guid(),i._zoneTitlePicker(),i._zonePicker(),i._zoneTitle.bind("cascade",(function(){this.value()||i._zone.wrapper.hide()})),i._zone.bind("cascade",(function(){i._value=this.value(),i.trigger(A)})),i.value(i.options.value)},options:{name:"TimezoneEditor",value:"",optionLabel:"No timezone"},events:[A],_zoneTitlePicker:function(){var t=this,i=e('<input id="'+t._zoneTitleId+'" aria-label="'+t.options.title+'"/>').appendTo(t.wrapper);t._zoneTitle=new n.ui.DropDownList(i,{dataSource:n.timezone.zones_titles,dataValueField:"other_zone",dataTextField:"name",optionLabel:t.options.optionLabel})},_zonePicker:function(){var t=this,i=e('<input aria-label="'+t.options.title+'"/>').appendTo(this.wrapper);t._zone=new n.ui.DropDownList(i,{dataValueField:"zone",dataTextField:"territory",dataSource:t._zonesQuery.data,cascadeFrom:t._zoneTitleId,dataBound:function(){t._value=this.value(),this.wrapper.toggle(this.dataSource.view().length>1)}}),t._zone.wrapper.hide()},destroy:function(){u.fn.destroy.call(this),n.destroy(this.wrapper)},value:function(e){var n,i=this;if(e===t)return i._value;(n=i._zonesQuery.filter({field:"zone",operator:"eq",value:e}).data[0])?(i._zoneTitle.value(n.other_zone),i._zone.value(n.zone)):i._zoneTitle.select(0)}});d.plugin(ke);var xe=n.template((({name:e,other_zone:t})=>`<option value="${t}">${e}</option>`)),Ce=n.template((({zone:e,territory:t})=>`<option value="${e}">${t}</option>`)),Se=u.extend({init:function(e,t){var i=this,r=n.timezone.windows_zones;if(!r||!n.timezone.zones_titles)throw new Error("kendo.timezones.min.js is not included.");u.fn.init.call(i,e,t),i.wrapper=i.element,i._zonesQuery=new n.data.Query(r),i._zoneTitlePicker(),i._zonePicker(),i.value(i.options.value)},options:{name:"MobileTimezoneEditor",optionLabel:"No timezone",value:""},events:[A],_bindZones:function(e){var t=e?this._filter(e):[];this._zone.html(this._options(t,Ce))},_filter:function(e){return this._zonesQuery.filter({field:"other_zone",operator:"eq",value:e}).data},_options:function(e,t,n){var i=0,r="",o=e.length;for(n&&(r+=t({other_zone:"",name:n}));i<o;i++)r+=t(e[i]);return r},_zoneTitlePicker:function(){var t=this,i=t._options(n.timezone.zones_titles,xe,t.options.optionLabel);t._zoneTitle=e("<select>"+i+"</select>").appendTo(t.wrapper).on("change",(function(){var e=this.value,n=t._zonePickerLabel,i=n.find("select");t._bindZones(e),e&&i.children().length>1?n.show():n.hide(),t._value=t._zone[0].value,t.trigger(A)}))},_zonePicker:function(){var t=this;t._zonePickerLabel=e("<li class='k-item k-listgroup-item k-zonepicker'><label class='k-label k-listgroup-form-row'><span class='k-item-title k-listgroup-form-field-label'></span><div class='k-listgroup-form-field-wrapper'></div></label></li>").hide(),t._zone=e("<select></select>").appendTo(t._zonePickerLabel.find("div")).on("change",(function(){t._value=this.value,t.trigger(A)})),this.wrapper.closest(".k-item").after(t._zonePickerLabel),t._bindZones(t._zoneTitle.val()),t._value=t._zone[0].value},destroy:function(){u.fn.destroy.call(this),n.destroy(this.wrapper)},value:function(e){var n,i=this,r=i._zone,o="",a="";if(e===t)return i._value;(n=i._zonesQuery.filter({field:"zone",operator:"eq",value:e}).data[0])&&(a=n.zone,o=n.other_zone),i._zoneTitle.val(o),i._bindZones(o),r.val(a),(a=r[0].value)&&r.children.length>1?i._zonePickerLabel.show():i._zonePickerLabel.hide(),i._value=a}});d.plugin(Se)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.ContextMenu,i=e.extend,r=t.htmlEncode,o="action",a=n.extend({init:function(e,t){var i=this;n.fn.init.call(i,e,t),i._overrideTemplates(),i._extendItems(),i.bind("select",i._onSelect.bind(i)),i.bind("open",i._onOpen.bind(i))},_overrideTemplates:function(){this.templates.sprite=({icon:e,spriteCssClass:n})=>`${e||n?t.ui.icon({icon:r(e||""),iconClass:r(n||"")}):""}`},defaultItems:{separator:{name:"separator",separator:!0},create:{name:"create",text:"Add",icon:"plus",command:"AddCommand",rules:"isEditable"},createChild:{name:"createChild",text:"Add Child",icon:"plus",command:"CreateChildCommand",rules:"isEditable"},edit:{name:"edit",text:"Edit",icon:"pencil",command:"EditCommand",rules:"isEditable"},destroy:{name:"destroy",text:"Delete",icon:"trash",command:"DeleteCommand",rules:"isEditable"},select:{name:"select",text:"Select",icon:"table-body",rules:"isSelectable",items:[{name:"selectRow",text:"Row",icon:"table-row-groups",command:"SelectRowCommand"},{name:"selectAllRows",text:"All rows",icon:"grid",command:"SelectAllRowsCommand",softRules:"isMultiRowSelectionEnabled"},{name:"clearSelection",text:"Clear selection",icon:"table-unmerge",softRules:"hasSelection",command:"ClearSelectionCommand"}]},exportPDF:{name:"exportPDF",text:"Export to PDF",icon:"file-pdf",command:"ExportPDFCommand"},exportExcel:{name:"exportExcel",text:"Export to Excel",icon:"file-excel",command:"ExportExcelCommand"},sortAsc:{name:"sortAsc",text:"Sort Ascending",icon:"sort-asc-small",rules:"isSortable",command:"SortCommand",options:"dir:asc"},sortDesc:{name:"sortDesc",text:"Sort Descending",icon:"sort-desc-small",rules:"isSortable",command:"SortCommand",options:"dir:desc"},expandItem:{name:"expandItem",text:"Expand Item",icon:"folder-open",softRules:"isExpandable",command:"ToggleItemCommand",options:"expand:true"},collapseItem:{name:"collapseItem",text:"Collapse Item",icon:"folder",softRules:"isCollapsible",command:"ToggleItemCommand",options:"expand:false"}},events:n.fn.events.concat([o]),_onSelect:function(t){var n=e(t.item).data("command"),i=e(t.item).data("options");i=i?i.split(",").map((e=>{if(e.indexOf(":")>-1){var[t,e]=e.split(":");return{[t||"_"]:e}}return{[e]:!0}})).reduce(((e,t)=>Object.assign(e,t)),{}):{};var r=e(t.target);n&&this.action({command:n,options:Object.assign(i,{target:r})})},_onOpen:function(n){var i=n.sender,r=i.options.items,o=e(n.event?n.event.target:null);!r&&e.isEmptyObject(this.defaultItems)||o.closest(".k-grid-column-menu").length?n.preventDefault():(this._toggleSeparatorVisibility(),i.element.find(`[${t.attr("soft-rules")}]`).each(((n,r)=>{var a=e(r).attr(t.attr("soft-rules")).split(";");i.enable(r,this._validateSoftRules(a,o))})))},_toggleSeparatorVisibility:function(){this.element.find(".k-item.k-separator").filter(((t,n)=>{var i=e(n).prev(".k-item:not(.k-separator)"),r=e(n).next(".k-item:not(.k-separator)");return!(i.length&&r.length)})).hide()},_extendItems:function(){var t,n=this,i=n.options.items;if(i&&i.length)for(var r=0;r<i.length;r++)t=i[r],e.isPlainObject(t)&&1===Object.keys(t).length&&t.name&&(t=t.name),e.isPlainObject(t)?n._append(t):n.defaultItems[t]?(t=n.defaultItems[t],n._append(t)):"string"==typeof t&&(t={name:t,text:t,spriteCssClass:t,command:t+"Command"},n._append(t));else for(var o in n.defaultItems)t=n.defaultItems[o],n._append(t)},_extendItem:function(e){var n=this,r=n.options.messages,o=e.attr||{};if(e.command&&(o[t.attr("command")]=e.command),e.options&&(o[t.attr("options")]=e.options),e.softRules&&(o[t.attr("soft-rules")]=e.softRules),e.items)for(var a=0;a<e.items.length;a++)e.items.forEach((e=>{n._extendItem(e)}));i(e,{text:r.commands[e.name],icon:e.icon||"",spriteCssClass:e.spriteCssClass||"",attr:o,uid:t.guid()})},_validateSoftRules:function(e,t){if(!e||!e||!e.length)return!0;for(var n=0;n<e.length;n++)if(!this._readState(e[n],t))return!1;return!0},_validateRules:function(e){var t=e.rules?e.rules.split(";"):[];if(!t.length)return!0;for(var n=0;n<t.length;n++)if(!this._readState(t[n]))return!1;return!0},_readState:function(e,n){var i=this.options.states;return t.isFunction(i[e])?i[e](n):i[e]},_append:function(e){var t=this;t._extendItem(e),t._validateRules(e)&&t.append(e)},action:function(e){this.trigger(o,e)}});t.ui.treelist=t.ui.treelist||{},i(t.ui.treelist,{ContextMenu:a})}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.Class.extend({init:function(e){this.options=e,this.treelist=e.treelist}}),r=i.extend({exec:function(){var e,n,i=this.treelist,r=i.dataSource,o=r.sort()||[],a=this.options,s=a.dir,l=a.target.attr(t.attr("field")),c=i.options.sortable.mode&&"multiple"===i.options.sortable.mode,d=i.options.compare;if(c){for(n=0,e=o.length;n<e;n++)if(o[n].field===l){o.splice(n,1);break}o.push({field:l,dir:s,compare:d})}else o=[{field:l,dir:s,compare:d}];r.sort(o)}}),o=i.extend({exec:function(){this.treelist.addRow()}}),a=i.extend({exec:function(){var e=this.treelist,t=this.options.target.closest("tr");e.addRow(t)}}),s=i.extend({exec:function(){var e=this,t=e.treelist,n="incell"===t._editMode(),i=n?e.options.target:e.options.target.closest("tr");n?t.editCell(i):t.editRow(i)}}),l=i.extend({exec:function(){var e=this.treelist,t=this.options.target.closest("tr");e.removeRow(t)}}),c=i.extend({exec:function(){var e=this.treelist,n=t.ui.Selectable.parseOptions(e.options.selectable),i=this.options.target.closest("tr");e.select(n.cell?i.find("td"):i)}}),d=i.extend({exec:function(){var e=this.treelist,n=t.ui.Selectable.parseOptions(e.options.selectable),i=e.items();e.select(n.cell?i.find("td"):i)}}),u=i.extend({exec:function(){this.treelist.clearSelection()}}),h=i.extend({exec:function(){this.treelist.saveAsPDF()}}),p=i.extend({exec:function(){this.treelist.saveAsExcel()}}),f=i.extend({exec:function(){var e=this,t=e.treelist,n=e.options.target;"true"===e.options.expand?t.expand(n):t.collapse(n)}});t.ui.treelist=t.ui.treelist||{},n(t.ui.treelist,{TreeListCommand:i,commands:{SortCommand:r,AddCommand:o,CreateChildCommand:a,EditCommand:s,DeleteCommand:l,SelectRowCommand:c,SelectAllRowsCommand:d,ClearSelectionCommand:u,ExportPDFCommand:h,ExportExcelCommand:p,ToggleItemCommand:f}})}(window.kendo.jQuery);!function(e,t){var n=kendo.data,i=kendo.htmlEncode,r=kendo.dom,o=r.element,a=r.text,s=r.html,l=kendo._outerWidth,c=e.extend({F10:121},kendo.keys),d=kendo._outerHeight,u=kendo.ui,h=u.DataBoundWidget,p=n.DataSource,f=n.ObservableArray,m=n.Query,g=n.Model,v=kendo.support.browser,_=kendo.template,b=kendo.toCamelCase,y=kendo._activeElement,w=kendo.support.touch,k=Array.isArray,x=e.extend,C=e.map,S=e.grep,T=e.inArray,D=e.isPlainObject,A=Array.prototype.push,M="string",E="change",I="itemChange",z="error",P="progress",H=".",F=".kendoTreeList",R="click",L="beforeEdit",B="edit",O="page",V="save",N="saveChanges",$="expand",U="collapse",W="cellClose",j="remove",q="td:not(.k-group-cell):not(.k-hierarchy-cell):visible,th:not(.k-group-cell):not(.k-hierarchy-cell):visible",G=".k-filter-row td:not(.k-group-cell):not(.k-hierarchy-cell):visible,.k-filter-row th:not(.k-group-cell):not(.k-hierarchy-cell):visible",K="dataBinding",Y="dataBound",Q="cancel",X="tabIndex",Z="filterMenuInit",J="filterMenuOpen",ee="columnHide",te="columnShow",ne="columnReorder",ie="columnResize",re="columnMenuInit",oe="columnMenuOpen",ae="columnLock",se="columnUnlock",le="filter",ce="navigate",de="sort",ue="parentId",he="dragstart",pe="drag",fe="drop",me="dragend",ge="tr:visible",ve="td:visible",_e="th:visible",be="k-grid-norecords",ye="tr:not(.k-footer-template):visible",we=!1,ke="k-checkbox",xe="input[data-role='checkbox']."+ke,Ce='<input class="'+ke+' k-checkbox-md k-rounded-md" data-role="checkbox" aria-label="Select row" aria-checked="false" type="checkbox">',Se='<input class="'+ke+' k-checkbox-md k-rounded-md" data-role="checkbox" aria-label="Select all rows" aria-checked="false" type="checkbox">',Te="k-selected",De="[\\x20\\t\\r\\n\\f]",Ae=new RegExp("(^|"+De+")(k-filter-row)("+De+"|$)"),Me="[ref-treelist-expand-collapse-icon]",Ee="aria-label",Ie="aria-activedescendant",ze="[ref-blank-icon]",Pe={wrapper:"k-treelist k-grid k-grid-md",header:"k-header k-table-th",button:"k-button",alt:"k-alt k-table-alt-row",editCell:"k-edit-cell",editRow:"k-grid-edit-row",dirtyCell:"k-dirty-cell",group:"k-treelist-group",toolbar:"k-toolbar",gridToolbar:"k-grid-toolbar",gridHeader:"k-grid-header",gridHeaderWrap:"k-grid-header-wrap",gridContent:"k-grid-content",gridContentWrap:"k-grid-content",gridFilter:"k-grid-filter-menu",footerTemplate:"k-footer-template",focused:"k-focus",loading:"k-i-loading",refresh:"arrow-rotate-cw",retry:"k-request-retry",selected:"k-selected",status:"k-status",link:"k-link",filterable:"k-filterable",icon:"k-icon",iconFilter:"filter",iconCollapse:"caret-alt-down",iconExpand:"caret-alt-right",iconPlaceHolder:"k-treelist-toggle k-icon k-svg-icon",input:"k-input",dropPositions:"k-i-insert-top k-i-insert-bottom k-i-plus k-i-insert-middle",dropTop:"insert-top",dropBottom:"insert-bottom",dropAdd:"plus",dropMiddle:"insert-middle",dropDenied:"cancel",dragStatus:"k-drag-status",dragClue:"k-drag-clue",dragClueText:"k-clue-text",headerCellInner:"k-cell-inner",columnTitle:"k-column-title"},He={create:{icon:"plus",className:"k-grid-add",methodName:"addRow"},createchild:{icon:"plus",className:"k-grid-add",methodName:"addRow"},destroy:{icon:"x",className:"k-grid-remove-command",methodName:"removeRow"},edit:{icon:"pencil",className:"k-button-solid-primary k-grid-edit-command",methodName:"editRow"},update:{icon:"save",className:"k-button-solid-primary k-grid-save-command",methodName:"saveRow"},canceledit:{icon:"cancel",className:"k-grid-cancel-command",methodName:"_cancelEdit"},cancel:{icon:"cancel-outline",text:"Cancel changes",className:"k-grid-cancel-changes",methodName:"cancelChanges"},save:{icon:"check",text:"Save changes",className:"k-grid-save-changes",methodName:"saveChanges"},excel:{icon:"file-excel",className:"k-grid-excel",methodName:"saveAsExcel"},pdf:{icon:"file-pdf",className:"k-grid-pdf",methodName:"saveAsPDF"},search:{template:({message:e})=>"<span class='k-spacer'></span><span class='k-searchbox k-input k-input-md k-rounded-md k-input-solid k-grid-search'>"+kendo.ui.icon({icon:"search",iconClass:"k-input-icon"})+`<input autocomplete='off' placeholder='${e}' title='${e}' aria-label='${e}' class='k-input-inner' /></span>`}},Fe=["create","createChild","edit","destroy","separator","select","separator","exportPDF","exportExcel","separator","expandItem","collapseItem","separator"],Re=["sortAsc","sortDesc","separator"],Le=kendo.Class.extend({init:function(e,t){var n=this;n.data=e||[],n.options=x(n.options,t)},options:{defaultParentId:null,idField:"id",parentIdField:ue},childrenMap:function(){var e,t,n,i=this,r={},o=i.data.length,a=i.options.idField,s=i.options.parentIdField;if(i._childrenMap)return i._childrenMap;for(var l=0;l<o;l++)t=(e=this.data[l])[a],n=e[s],r[t]=r[t]||[],r[n]=r[n]||[],r[n].push(e);return i._childrenMap=r,r},idsMap:function(){var e,t=this,n={},i=t.data,r=i.length,o=t.options.idField;if(t._idMap)return t._idMap;for(var a=0;a<r;a++)n[(e=i[a])[o]]=e;return t.idsMap=n,n},dataMaps:function(){var e,t,n,i=this,r={},o=i.data,a=o.length,s={},l=i.options.idField,c=i.options.parentIdField;if(i._dataMaps)return i._dataMaps;for(var d=0;d<a;d++)t=(e=o[d])[l],n=e[c],s[t]=e,r[t]=r[t]||[],r[n]=r[n]||[],r[n].push(e);return i._dataMaps={children:r,ids:s},i._dataMaps},rootNodes:function(){for(var e,t=this,n=t.data,i=t.options.defaultParentId,r=n.length,o=[],a=t.options.parentIdField,s=0;s<r;s++)(e=n[s])[a]===i&&o.push(e);return o},removeCollapsedSubtreesFromRootNodes:function(e){e=e||{};var t,n=this,i=n.rootNodes(),r=[];n._childrenMap=e.childrenMap=e.childrenMap||n.childrenMap(),e.maxDepth=e.maxDepth||1/0;for(var o=0;o<i.length;o++)t=n.removeCollapsedSubtrees(i[o],e),r=r.concat(t);return r},removeCollapsedSubtrees:function(e,t){var n,i,r=[],o=(t=t||{}).childrenMap||{},a=t.maxDepth||1/0,s=o[e[this.options.idField]]||[],l=xt(e.expanded)?t.expanded:e.expanded;if(r.push(e),s&&l)for(n=0;n<s.length&&!(r.length>=a);n++)i=this.removeCollapsedSubtrees(s[n],t),r=r.concat(i);return r}}),Be=function(e){this.data=e||[]};(Be.prototype=new m).constructor=Be,Be.process=function(e,n,i){n=n||{};var r,o,a,s,l,c=new Be(e),d=n.group,u=m.normalizeGroup(d||[]).concat(m.normalizeSort(n.sort||[])),h=n.filterCallback,p=n.filter,f=n.skip,g=n.take;return u&&i&&(c=c.sort(u,t,t,i)),p&&(c=c.filter(p),h&&(c=h(c)),r=c.toArray().length),u&&!i&&(c=c.sort(u),d&&(e=c.toArray())),n.processFromRootNodes&&(s=new Le(c.toArray(),n),p&&(a=s.childrenMap()),l=s.removeCollapsedSubtreesFromRootNodes({childrenMap:p||u&&u.length?t:n.childrenMap,expanded:n.expanded,maxDepth:f+g||1/0}),o=s.childrenMap(),c=new Be(l)),f!==t&&g!==t&&(c=c.range(f,g)),d&&(c=c.group(d,e)),{total:r,data:c.toArray(),childrenMap:o,filteredChildrenMap:a}};var Oe=g.define({id:"id",parentId:ue,fields:{id:{type:"number"},parentId:{type:"number",nullable:!0}},init:function(e){g.fn.init.call(this,e),this._loaded=!1,this.parentIdField||(this.parentIdField=ue),this.parentId=this.get(this.parentIdField)},accept:function(e){g.fn.accept.call(this,e),this.parentId=this.get(this.parentIdField)},set:function(e,t,n){e==ue&&this.parentIdField!=ue&&(this[this.parentIdField]=t),g.fn.set.call(this,e,t,n),e==this.parentIdField&&(this.parentId=this.get(this.parentIdField))},loaded:function(e){if(e===t)return this._loaded;this._loaded=e},shouldSerialize:function(e){return g.fn.shouldSerialize.call(this,e)&&"_loaded"!==e&&"_error"!=e&&"_edit"!=e&&!("parentId"!==this.parentIdField&&"parentId"===e)}});function Ve(e){return function(t){return t[e]}}function Ne(e){return function(t){return!e(t)}}Oe.parentIdField=ue,Oe.define=function(e,n){n===t&&(n=e,e=Oe);var i=n.parentId||ue;n.parentIdField=i;var r=g.define(e,n);return i&&(r.parentIdField=i),r};var $e=p.extend({init:function(e){e=e||{};this._dataMaps=this._getDataMaps(),e.schema=x(!0,{},{modelBase:Oe,model:Oe},e.schema),p.fn.init.call(this,e)},_addRange:function(){},_createNewModel:function(e){var t={},n=e instanceof g,i=this._modelParentIdField();return n&&(t=e),t=p.fn._createNewModel.call(this,t),n||(e.parentId?e[t.parentIdField]=e.parentId:this._isPageable()&&e[i]&&(e[t.parentIdField]=e[i]),t.accept(e)),t},_shouldWrap:function(){return!0},_push:function(e,t){var n=p.fn._readData.call(this,e);n||(n=e),this[t](n)},_getData:function(){return this._data||[]},_readData:function(e){var t=this,n=t._isPageable()?t._getData().toJSON():t.data();return e=p.fn._readData.call(this,e),this._replaceData((n.toJSON?n.toJSON():n).concat(e),n),e instanceof f?e:n},_replaceData:function(e,t){for(var n=e.length,i=0;i<n;i++)t[i]=e[i];t.length=n},_readAggregates:function(e){var t=x(this._aggregateResult,this.reader.aggregates(e));return""in t&&(t[this._defaultParentId()]=t[""],delete t[""]),t},read:function(e){var n=this;return n._isPageable()&&(n._dataMaps={},n._modelOptions().expanded||(n._skip=0,n._page=1,n._collapsedTotal=t)),p.fn.read.call(n,e)},remove:function(e){return this._removeChildData(e),this._removeFromDataMaps(e),p.fn.remove.call(this,e)},_removeChildData:function(e,t){var n=this,i=n._isPageable(),r=i?this._getData():this.data(),o=i?n._getChildrenMap()||n.childrenMap(r):n._childrenMap(r),a=this._subtree(o,e.id),s=!xt(t)&&t,l=this._removeItems(a,s);n._removeFromDataMaps(l)},pushDestroy:function(e){var t=this;k(e)||(e=[e]);for(var n=0;n<e.length;n++)t._removeChildData(e[n],!0),t._removeFromDataMaps(e[n]);p.fn.pushDestroy.call(t,e)},insert:function(e,t){var n=this,i=n._createNewModel(t);return n._insertInDataMaps(i),p.fn.insert.call(n,e,i)},_filterCallback:function(e){var t,n,i,r=this,o={},a=[],s=e.toArray(),l=r._modelIdField(),c=r._modelParentIdField(),d=r._isPageable(),u=[];for(t=0;t<s.length;t++)if(n=s[t],d){for(u=[],o[n[l]]||(o[n[l]]=!0,u.push(n)),i=r._parentNode(n);i&&!o[i[l]];)o[i[l]]=!0,u.unshift(i),i=r._parentNode(i);u.length&&(a=a.concat(u))}else for(;n&&(o[n[l]]||(o[n[l]]=!0,a.push(n)),!o[n[c]]);)o[n[c]]=!0,(n=this.parentNode(n))&&a.push(n);return new m(a)},_subtree:function(e,t){for(var n=this,i=e[t]||[],r=n._defaultParentId(),o=n._modelIdField(),a=0,s=i.length;a<s;a++)i[a][o]!==r&&(i=i.concat(n._subtree(e,i[a][o])));return i},_childrenMap:function(e){var t,n,i,r,o={};for(e=this._observeView(e),t=0;t<e.length;t++)i=(n=e[t]).id,r=n.parentId,o[i]=o[i]||[],o[r]=o[r]||[],o[r].push(n);return o},childrenMap:function(e){return this._createTreeView(e).childrenMap()},_getChildrenMap:function(){return this._getDataMaps().children},_initIdsMap:function(e){var t=this._getDataMaps();return xt(t.ids)&&(t.ids=this._idsMap(e)),t.ids},_idsMap:function(e){return this._createTreeView(e).idsMap()},_getIdsMap:function(){return this._getDataMaps().ids||{}},_getFilteredChildrenMap:function(){return this._getDataMaps().filteredChildren},_setFilteredChildrenMap:function(e){this._getDataMaps().filteredChildren=e},_initDataMaps:function(e){var t=this,n=t._createTreeView(e);return t._dataMaps=n.dataMaps(),t._dataMaps},_initChildrenMapForParent:function(e){var t=this,n=t._getData(),i=t._getChildrenMap(),r=t._modelIdField(),o=t._modelParentIdField(),a=(e||{})[r];if(i&&e){i[a]=[];for(var s=0;s<n.length;s++)n[s][o]===a&&i[a].push(n[s])}},_getDataMaps:function(){var e=this;return e._dataMaps=e._dataMaps||{},e._dataMaps},_createTreeView:function(e,t){return new Le(e,x(t,this._defaultTreeModelOptions()))},_defaultTreeModelOptions:function(){var e=this,t=e._modelOptions();return{defaultParentId:e._defaultParentId(),idField:e._modelIdField(),parentIdField:e._modelParentIdField(),expanded:t.expanded}},_defaultDataItemType:function(){return this.reader.model||kendo.data.ObservableObject},_calculateAggregates:function(e,t){var n,i,r,o,a=this,s={},l=(t=t||{}).filter,c=t.skip,d=t.take,u=xt(c)||xt(d)?1/0:c+d,h=a._isPageable(),p=t.filteredChildrenMap,f=t.childrenMap;if(h){if(xt(t.aggregate))return s;o=p||(f||a.childrenMap(a._getData()))}!h&&l&&(e=m.process(e,{filter:l,filterCallback:this._filterCallback.bind(this)}).data);var g=h?o:a._childrenMap(e);for(s[this._defaultParentId()]=new m(this._subtree(g,this._defaultParentId())).aggregate(t.aggregate),r=0;r<e.length&&!(r>=u);r++)n=e[r],i=this._subtree(g,n.id),s[n.id]=new m(i).aggregate(t.aggregate);return s},_queryProcess:function(e,t){var n={};if((t=t||{}).filterCallback=this._filterCallback.bind(this),this._isPageable())return this._processPageableQuery(e,t);var i=this._defaultParentId();n=m.process(e,t);var r,o,a,s,l=this._childrenMap(n.data);for(e=l[i]||[],o=0;o<e.length;o++)(a=e[o]).id!==i&&(r=!(!(s=l[a.id])||!s.length),a.loaded()||a.loaded(r||!a.hasChildren),(a.loaded()||!0!==a.hasChildren)&&(a.hasChildren=r),r&&(e=e.slice(0,o+1).concat(s,e.slice(o+1))));return n.data=e,n},_processPageableQuery:function(e,n){var i,r,o=this,a=o._getDataMaps();return o._getData()===e&&a.children&&a.ids||(a=o._initDataMaps(o._getData())),n.childrenMap=a.children||{},n.idsMap=a.ids||{},i=o._processTreeQuery(e,n),o._replaceWithObservedData(i.data,e),o._processDataItemsState(i.data,i.childrenMap),o._replaceItemsInDataMaps(i.data),i.dataToAggregate=o._dataToAggregate(i.data,n),n.filter||o.filter()?(r=i.filteredChildrenMap,o._replaceInMapWithObservedData(r,e),o._setFilteredChildrenMap(r),n.filteredChildrenMap=r,o._calculateCollapsedTotal(i.data)):o._collapsedTotal=t,i},_dataToAggregate:function(e){var t=e[0]||{};return this._parentNodes(t).concat(e)},_replaceItemsInDataMaps:function(e){for(var n,i,r,o=this,a=k(e)?e:[e],s=o._defaultDataItemType(),l=o._defaultParentId(),c=o._modelIdField(),d=o._modelParentIdField(),u=o._getDataMaps(),h=0;h<a.length;h++)(n=a[h])instanceof s&&(o._insertInIdsMap(n),r=(i=o._parentNodes(n))&&i.length?i[i.length-1]:t,n[d]===l?o._replaceInMap(u.children,l,n,s):r&&o._replaceInMap(u.children,r[c],n,s))},_replaceInMap:function(e,t,n,i){var r=this._modelIdField();e[t]=e[t]||[],i=i||this._defaultDataItemType();var o=e[t].filter((function(e){return n[r]===e[r]}))[0],a=o?e[t].indexOf(o):-1;-1===a||o instanceof i||(e[t][a]=n)},_replaceWithObservedData:function(e,t){for(var n,i,r,o,a,s=this,l=s._getDataMaps().ids||{},c=s._modelIdField(),d=s._defaultDataItemType(),u=0;u<e.length;u++)i=(n=e[u])[c],n instanceof d||(l[i]instanceof d?e[u]=l[i]:(r=s._getById(i),o=t.indexOf(r),r&&-1!==o&&(a=t.at(o),e[u]=a)))},_replaceInMapWithObservedData:function(e,t){for(var n in e)this._replaceWithObservedData(e[n],t)},_insertInDataMaps:function(e){var t=this;t._isPageable()&&(t._insertInIdsMap(e),t._insertInChildrenMap(e))},_insertInIdsMap:function(e){var t=this._getIdsMap(),n=this._modelIdField();xt(e[n])||(t[e[n]]=e)},_insertInChildrenMap:function(e,t){var n=this,i=n._getChildrenMap()||{},r=n._modelIdField(),o=n._modelParentIdField(),a=e[r],s=e[o];t=t||0,i[a]=i[a]||[],i[s]=i[s]||[],i[s].splice(t,0,e)},_removeFromDataMaps:function(e){var t=this;if(e=k(e)?e:[e],t._isPageable())for(var n=0;n<e.length;n++)t._removeFromIdsMap(e[n]),t._removeFromChildrenMap(e[n])},_removeFromIdsMap:function(e){var n=this._getIdsMap(),i=this._modelIdField();xt(e[i])||(n[e[i]]=t)},_removeFromChildrenMap:function(e){var t=this,n=t._getChildrenMap()||{},i=e[t._modelParentIdField()];n[i]=n[i]||[];var r=t._indexInChildrenMap(e);-1!==r&&n[i].splice(r,1)},_indexInChildrenMap:function(e){return this._itemIndexInMap(e,this._getChildrenMap())},_itemIndexInMap:function(e,t){var n=t||{},i=this._modelParentIdField(),r=e[i];n[r]=n[r]||[];var o=n[r].filter((function(t){return e.uid===t.uid}))[0];return o?n[r].indexOf(o):-1},_getById:function(e){for(var t=this._modelIdField(),n=this._getData(),i=0;i<n.length;i++)if(n[i][t]===e)return n[i]},_isLastItemInView:function(e){var t=this.view();return t.length&&t[t.length-1]===e},_defaultPageableQueryOptions:function(){var e=this,t=e._getDataMaps();return{skip:e.skip(),take:e.take(),page:e.page(),pageSize:e.pageSize(),sort:e.sort(),filter:e.filter(),group:e.group(),aggregate:e.aggregate(),filterCallback:e._filterCallback.bind(e),childrenMap:t.children,idsMap:t.ids}},_isPageable:function(){var e=this.pageSize();return!xt(e)&&e>0&&!this.options.serverPaging},_updateTotalForAction:function(e,t){var n=this;p.fn._updateTotalForAction.call(n,e,t),n._isPageable()&&n._updateCollapsedTotalForAction(e,t)},_updateCollapsedTotalForAction:function(e,t){var n=this,i=parseInt(n._collapsedTotal,10);!function(e){return"number"==typeof e&&!isNaN(e)}(n._collapsedTotal)?n._calculateCollapsedTotal():("add"===e?i+=t.length:"remove"===e?i-=t.length:"itemchange"===e||"sync"===e||n.options.serverPaging?"sync"===e&&(i=n._calculateCollapsedTotal()):i=n._calculateCollapsedTotal(),n._collapsedTotal=i)},_setFilterTotal:function(e,t){p.fn._setFilterTotal.call(this,e,t)},collapsedTotal:function(){var e=this;return xt(e._collapsedTotal)?e._calculateCollapsedTotal():e._collapsedTotal},_calculateCollapsedTotal:function(e){var t=this,n=t._dataWithoutCollapsedSubtrees(e);return n.length&&(t._collapsedTotal=n.length),t._collapsedTotal},_dataWithoutCollapsedSubtrees:function(e){return this._removeCollapsedSubtrees(e||this._getData())},_removeCollapsedSubtrees:function(e){var t=this;return t._createTreeView(e).removeCollapsedSubtreesFromRootNodes({expanded:t._modelOptions().expanded,childrenMap:t.filter()?t._getFilteredChildrenMap():t._getChildrenMap()})},_processTreeQuery:function(e,t){return Be.process(e,x(t,this._defaultTreeModelOptions(),{processFromRootNodes:!0}))},_processDataItemsState:function(e,t){var n,i=e.length;for(n=0;n<i;n++)this._processDataItemState(e[n],t)},_processDataItemState:function(e,t){var n=this._defaultParentId();if(e.id!==n){var i=t[e.id]||[],r=!(!i||!i.length);e.loaded&&(e.loaded()||e.loaded(r||!e.hasChildren),(e.loaded()||!0!==e.hasChildren)&&(e.hasChildren=r))}},_queueRequest:function(e,t){t.call(this)},_modelLoaded:function(e){var t=this.get(e);t.loaded(!0),t.hasChildren=this.childNodes(t).length>0},_modelError:function(e,t){this.get(e)._error=t},success:function(e,t){t&&void 0!==t.id||(this._data=this._observe([])),p.fn.success.call(this,e,t),this._total=this._data.length},load:function(t){var n="_query",i=this.options.serverSorting||this.options.serverPaging||this.options.serverFiltering||this.options.serverGrouping||this.options.serverAggregates,r=e.Deferred().resolve().promise();if(t.loaded()){if(i)return r}else t.hasChildren&&(n="read",this._removeChildData(t));return this[n]({id:t.id}).done(this._modelLoaded.bind(this,t.id)).fail(this._modelError.bind(this,t.id))},contains:function(e,t){for(var n=this,i=n._modelIdField(),r=n._modelParentIdField(),o=e[i],a=n._isPageable();t;){if(t[r]===o)return!0;t=a?n._parentNode(t):n.parentNode(t)}return!1},_byParentId:function(e,t){var n,i=[],r=this.view();if(e===t)return[];for(var o=0;o<r.length;o++)(n=r.at(o)).parentId==e&&i.push(n);return i},_defaultParentId:function(){return this.reader.model.fn.defaults[this.reader.model.parentIdField]},_modelOptions:function(){return(this.options.schema||{}).model||{}},_modelIdField:function(){return this._modelOptions().id||"id"},_modelParentIdField:function(){return this._modelOptions().parentId||ue},childNodes:function(e){return this._byParentId(e.id,this._defaultParentId())},allChildNodes:function(e,t){for(var n=this.data().filter((function(t){return t.parentId===e.id})),i=0;i<n.length;i++)t.push(n[i]),this.allChildNodes(n[i],t)},rootNodes:function(){return this._byParentId(this._defaultParentId())},_rootNode:function(e){return this._parentNodes(e)[0]},_pageableRootNodes:function(e){e=e||{};for(var t,n,i=this,r=i._defaultParentId(),o=i._modelParentIdField(),a=[],s=i._nodesWithoutParentInView(e),l=0;l<s.length;l++)(t=s[l])[o]===r?a.push(t):(n=i._rootNode(t))&&-1===a.indexOf(n)&&a.push(n);return a},parentNode:function(e){return this.get(e.parentId)},_parentNode:function(e){var t=this,n=t._modelParentIdField(),i=t._initIdsMap(t._getData()),r=e[n];return i[r]||t._getById(r)},_parentNodes:function(e){for(var t=this._parentNode(e),n=[];t;)n.unshift(t),t=this._parentNode(t);return n},_parentNodesNotInView:function(){for(var e,t,n,i=this,r=i.view(),o=[],a=i._defaultParentId(),s=i._modelIdField(),l=i._modelParentIdField(),c=[],d=0;d<r.length;d++)(t=r[d])[s],n=t[l],i._parentInView(n)||n===a||(e=(c=i._parentNodes(t))&&c.length?c[c.length-1]:i._getById(n))&&-1===o.indexOf(e)&&o.push(e);return o},_nodesWithoutParentInView:function(e){e=e||{};for(var t,n=this,i=n.view(),r=e.childrenMap||n.childrenMap(n._getData()),o=n._modelIdField(),a=n._modelParentIdField(),s=[],l=0;l<i.length;l++)r[(t=i[l])[o]],n._parentInView(t[a])||s.push(t);return s},_parentInView:function(e){for(var t=this.view(),n=0;n<t.length;n++)if(t[n].id===e)return t[n]},level:function(e){var t=-1;e instanceof Oe||(e=this.get(e));do{e=this.parentNode(e),t++}while(e);return t},_pageableModelLevel:function(e){return e&&this._isPageable()?this._parentNodes(e).length:0},filter:function(e){var n=p.fn.filter;if(e===t)return n.call(this,e);n.call(this,e)},_pageableQueryOptions:function(e){var t=this._getDataMaps();return e.childrenMap=t.children,e.idsMap=t.ids,e},_flatData:function(e,t){return t=!!this._isPageable()||t,p.fn._flatData.call(this,e,t)},data:function(e){var t=this,n=p.fn.data.call(t,e);return t._isPageable()&&(t._initDataMaps(t._getData()),t._calculateCollapsedTotal()),n},cancelChanges:function(e){p.fn.cancelChanges.call(this,e),this._restorePageSizeAfterAddChild()},_modelCanceled:function(e){this._isPageable()&&this._removeFromDataMaps(e)},_changesCanceled:function(){var e=this;e._isPageable()&&e._initDataMaps(e._getData())},_setAddChildPageSize:function(){var e=this,t={};e._isPageable()&&(e._addChildPageSize=e.pageSize()+1,(t=e._defaultPageableQueryOptions()).take=e._addChildPageSize,t.pageSize=e._addChildPageSize,e._query(t))},_restorePageSizeAfterAddChild:function(){var e=this,n={};e._isPageable()&&(xt(e._addChildPageSize)||((n=e._defaultPageableQueryOptions()).take=e._addChildPageSize-1,n.pageSize=e._addChildPageSize-1,e._query(n))),e._addChildPageSize=t},sync:function(){var e=this;return p.fn.sync.call(e).then((function(){e._restorePageSizeAfterAddChild()}))},_syncEnd:function(){var e=this;e._isPageable()&&e._initDataMaps(e._getData())}});function Ue(){return"none"!==this.style.display}function We(n){var i=kendo.attr("index");return[].sort.call(n,(function(n,r){n=e(n),r=e(r);var o=n.attr(i),a=r.attr(i);return o===t&&(o=e(n).index()),a===t&&(a=e(r).index()),(o=parseInt(o,10))>(a=parseInt(a,10))?1:o<a?-1:0}))}function je(t){var n=t.find(">tr:not(.k-filter-row)"),i=function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")},r=e();return n.length>1&&(r=n.find("th[data-index]").filter(i)),We(r=r.add(n.last().find("th").filter(i)))}function qe(e){var t=[],n=e.className;const i=n===Pe.iconPlaceHolder?{"ref-blank-icon":""}:{};for(var r=0,a=e.level;r<a;r++)t.push(o("span",{className:n,"aria-hidden":!0,...i}));return t}function Ge(e){for(var t,n=0,i=0,r=e.length;i<r;i++)(t=e[i].style.width)&&-1==t.indexOf("%")&&(n+=parseInt(t,10));return n}$e.create=function(e){return Array.isArray(e)?e={data:e}:e instanceof f&&(e={data:e.toJSON()}),e instanceof $e?e:new $e(e)};var Ke=u.Pager.extend({options:{name:"TreeListPager"},totalPages:function(){var e=this,t=e.dataSource;return t&&t._filter?u.Pager.fn.totalPages.call(e):Math.ceil((e._collapsedTotal()||0)/(e.pageSize()||1))},_createDataSource:function(e){this.dataSource=kendo.data.TreeListDataSource.create(e.dataSource)},_collapsedTotal:function(){var e=this.dataSource;return e&&e.collapsedTotal()||0}}),Ye=kendo.Observable.extend({init:function(e,t){kendo.Observable.fn.init.call(this),t=this.options=x(!0,{},this.options,t),this.element=e,this.bind(this.events,t),this.model=this.options.model,this.fields=this._fields(this.options.columns),this._initContainer(),this.createEditable()},options:{renderForm:!1},events:[],_initContainer:function(){this.wrapper=this.element},createEditable:function(){var e=this.options;e.renderForm?(this.form=new u.Form(this.wrapper.find(".k-treelist-form"),{items:this.fields,buttonsTemplate:()=>"",formData:this.model,change:e.change}),this.editable=this.form.editable):this.editable=new u.Editable(this.wrapper,{fields:this.fields,target:e.target,clearContainer:e.clearContainer,model:this.model,change:e.change})},_isEditable:function(e){return kt(e,this.model)},_fields:function(e){var t,n,i,r=[];for(t=0,n=e.length;t<n;t++)i=e[t],this._isEditable(i)&&r.push({field:i.field,format:i.format,editor:i.editor,editorOptions:x(!0,{format:i.format},i.editorOptions),label:i.title||i.field||""});return r},end:function(){return this.editable.end()},close:function(){this.destroy()},destroy:function(){this.editable.destroy(),this.editable.element.find("["+kendo.attr("container-for")+"]").empty().end().removeAttr(kendo.attr("role")),this.model=this.wrapper=this.element=this.columns=this.editable=null}}),Qe=Ye.extend({init:function(e,t){Ye.fn.init.call(this,e,t),this._attachHandlers(),kendo.cycleForm(this.wrapper),this.open()},events:[Q,V],options:{window:{modal:!0,resizable:!1,draggable:!0,title:"Edit",visible:!1}},_initContainer:function(){var t=this.options,n=[];this.wrapper=e('<div class="k-popup-edit-form"/>').attr(kendo.attr("uid"),this.model.uid).append('<div class="k-edit-form-container"/>'),t.template?(this._appendTemplate(n),this.fields=[]):(this.options.renderForm=!0,n.push(s('<div class="k-treelist-form"></div>'))),new r.Tree(this.wrapper.children()[0]).render(n),this.wrapper.appendTo(t.appendTo),this.window=new u.Window(this.wrapper,t.window)},_appendTemplate:function(e){var t=this.options.template;typeof t===M&&(t=kendo.unescape(t)),t=kendo.template(t)(this.model),e.push(s(t))},_attachHandlers:function(){var e=this._cancelProxy=this._cancel.bind(this);this.window.wrapper.on(R+F,"button[data-command='canceledit']",this._cancelProxy),this._saveProxy=this._save.bind(this),this.window.wrapper.on(R+F,"button[data-command='update']",this._saveProxy),this.window.bind("close",(function(t){t.userTriggered&&e(t)}))},_detachHandlers:function(){this._cancelProxy=null,this._saveProxy=null,this.window.wrapper.off(F)},_cancel:function(e){this.trigger(Q,e)},_save:function(){this.trigger(V)},open:function(){this.window.center().open()},close:function(){this.window.bind("deactivate",this.destroy.bind(this)).close()},destroy:function(){this.form&&this.form.destroy(),this._detachHandlers(),this.window.destroy(),this.window=null,Ye.fn.destroy.call(this)}}),Xe=Ye.extend({destroy:function(){var e=this;e.editable.destroy(),e.editable.element.off().empty().removeAttr(kendo.attr("role")),e.model=e.wrapper=e.element=e.columns=e.editable=null}}),Ze=h.extend({init:function(t,n,i){if(h.fn.init.call(this,t,n),i&&(this._events=i),we=kendo.support.isRtl(t),Pe.iconExpand=we?"caret-alt-left":"caret-alt-right",this._dataSource(this.options.dataSource),this._columns(),this._layout(),this._aria(),this._ariaId(),this._navigatable(),this._selectable(),this._sortable(),this._resizable(),this._filterable(),this._filterRow(),this._attachEvents(),this._toolbar(),this._scrollable(),this._reorderable(),this._columnMenu(),this._minScreenSupport(),this._draggable(),this._pageable(),this.options.autoBind&&this.dataSource.fetch(),this._hasLockedColumns){var r=this;this.wrapper.addClass("k-grid-lockedcolumns"),this._resizeHandler=function(){r.resize()},e(window).on("resize"+F,this._resizeHandler)}this.options.contextMenu&&this._initContextMenu(),kendo.notify(this)},_draggable:function(){var t,n,i=this,r=this.options.editable,o=i.dataSource,a=o._modelIdField(),s=o._modelParentIdField(),l=i._isPageable();r&&r.move&&(t=r.move.reorderable,!1!==r.move.clickMoveClick&&this._hasDragHandleColumn&&(n=!0),this._dragging=new kendo.ui.HierarchicalDragAndDrop(this.wrapper,{autoScroll:!0,holdToDrag:w,filter:i._hasDragHandleColumn?".k-drag-cell":"tbody>tr",itemSelector:"tr",allowedContainers:this.table,clickMoveClick:n,hintText:function(t){return(t=t.closest("tr")).children("td").map((function(){return e(this).text()})).toArray().join("<span class='k-drag-separator'></span>")},contains:function(e,t){var n=this.dataItem(t),i=this.dataItem(e);return i==n||this.dataSource.contains(i,n)}.bind(this),itemFromTarget:function(e){var t,n,r=e.closest("tr"),o=r.prev(),a=r.next();return o&&(t=!i.sameLevel(o,r)),a&&(n=!i.sameLevel(a,r)),{item:r,content:r,first:t,last:n}},dragstart:function(e){this.wrapper.addClass("k-treelist-dragging"),this.wrapper.find(".k-grid-content").length&&this.wrapper.find(".k-grid-content table, .k-grid-content-locked table").css("position","relative");var t=this.dataItem(e);return this.trigger(he,{source:t})}.bind(this),drag:function(e){e.source=this.dataItem(e.source),this.trigger(pe,e)}.bind(this),drop:function(e){return e.source=this.dataItem(e.source),e.destination=this.dataItem(e.destination),this.wrapper.removeClass("k-treelist-dragging"),this.wrapper.find(".k-grid-content").length&&this.wrapper.find(".k-grid-content table, .k-grid-content-locked table").css("position","static"),this.trigger(fe,e)}.bind(this),dragend:function(e){var t=this.dataItem(e.destination),n=this.dataItem(e.source),r=n[s],c=o._indexInChildrenMap(n),d=e.position;if("over"==d){l&&(o._removeFromChildrenMap(n),n[s]=t?t[a]:null,o._initChildrenMapForParent(t),n[s]=r);var u=n.set("parentId",t?t.id:null);l&&u&&(o._removeFromChildrenMap(n),n[s]=r,o._removeFromChildrenMap(n),o._insertInChildrenMap(n,c))}else"before"==d?i.insertBefore(n,t):"after"==d&&i.insertAfter(n,t);e.source=n,e.destination=t,this.trigger(me,e)}.bind(this),reorderable:t,dropHintContainer:function(e){return e.children("td:visible").eq(0)},dropPositionFrom:function(e){var t,n,i,r,o=!1;if(e.parent().find(".k-i-none").length)return e.prevAll(".k-i-none").length>0?"after":"before";for(n=(t=e.parent().contents()).length,r=e[0],i=0;i<n&&t[i]!==r;i++)3===t[i].nodeType&&(o=!0);return o?"after":"before"}}))},sameLevel:function(){return arguments[0].find(ze).length===arguments[1].find(ze).length},insertAfter:function(e,t){this.insertAction(e,t,1)},insertBefore:function(e,t){this.insertAction(e,t,0)},insertAction:function(e,t,n){var i,r=this,o=r.dataSource,a=o._modelParentIdField(),s=o.indexOf(e),l=r._isPageable(),c=o._indexInChildrenMap(t),d=o._getChildrenMap()||{},u=e[a];r._unbindDataSource(),r._unbindDataChange(),l&&o._removeFromChildrenMap(e),e[a]!=t[a]&&e.set("parentId",t&&t.parentId?t.parentId:null),o._data.splice(s,1),i=o.indexOf(t)+n,l&&(c+=n,d[u].length<=c&&(c=d[u].length),o._insertInChildrenMap(e,c)),o._data.splice(i,0,e),o._destroyed.pop(),r._bindDataChange(),r._bindDataSource(),r.refresh()},_bindDataChange:function(){var e=this.dataSource;e._data&&e._changeHandler&&(e._data.bind(E,e._changeHandler),e._data.trigger(E))},_unbindDataChange:function(){var e=this.dataSource;e._data&&e._changeHandler&&e._data.unbind(E,e._changeHandler)},_bindDataSource:function(){var e=this.dataSource;e&&e.bind(E,this._refreshHandler)},_unbindDataSource:function(){var e=this.dataSource;e&&e.unbind(E,this._refreshHandler)},itemFor:function(e){return"number"==typeof e&&(e=this.dataSource.get(e)),this.tbody.find("["+kendo.attr("uid")+"="+e.uid+"]")},_itemFor:function(e){var t=this,n=t.lockedContent?t.lockedTable:t.table;return"number"==typeof e&&(e=this.dataSource.get(e)),n.find("["+kendo.attr("uid")+"="+e.uid+"]")},_scrollable:function(){if(this.options.scrollable){var t=this.thead.closest(".k-grid-header-wrap"),n=e(this.lockedContent).on("DOMMouseScroll"+F+" mousewheel"+F,this._wheelScroll.bind(this));this.content.on("scroll"+F,(function(){kendo.scrollLeft(t,this.scrollLeft),n.scrollTop(this.scrollTop)})),this.element.find(".k-grid-content, .k-grid-content-locked").wrapAll("<div class='k-grid-container' />");var i=kendo.touchScroller(this.content);i&&i.movable&&(this._touchScroller=i,i.movable.bind("change",(function(e){kendo.scrollLeft(t,-e.sender.x),n&&n.scrollTop(-e.sender.y)})))}},_wheelScroll:function(t){if(!t.ctrlKey){var n=kendo.wheelDeltaY(t),i=e(t.currentTarget);n&&(i[0].scrollHeight>i[0].clientHeight&&(i[0].scrollTop<i[0].scrollHeight-i[0].clientHeight&&n<0||i[0].scrollTop>0&&n>0)&&t.preventDefault(),i.one("wheel"+F,!1),this.content.scrollTop(this.content.scrollTop()+-n))}},_progress:function(){var e=this.options.messages;this.tbody.find("tr").length||this._showStatus(kendo.template((({className:e,messages:t})=>`<span class='${e}'></span> ${i(t.loading)}`))({className:Pe.icon+" "+Pe.loading,messages:e}))},_error:function(e){this.dataSource.rootNodes().length||this._render({error:e})},refresh:function(t){var n=this;if(!("itemchange"==(t=t||{}).action&&this.editor||this.trigger(K))){var i,r,o=e(this.current()),a=!1;this._cancelEditor(),this._render(),this._adjustHeight(),this.options.navigatable&&((this._isActiveInTable()||this.editor)&&(i=(a=o.is("th"))?o.parent().children(":not(.k-group-cell)").index(o[0]):Math.max(this.cellIndex(o),0),r=!a&&o.parent().index()),this._restoreCurrent(i,a,r)),n._checkBoxSelection&&n._deselectCheckRows(n.items(),!0),n._aria(),this.trigger(Y)}},items:function(){return this._hasLockedColumns?this._items(this.tbody).add(this._items(this.lockedTable)):this._items(this.tbody)},_items:function(t){return t.find("tr[data-uid]").filter((function(){return!e(this).hasClass(Pe.footerTemplate)}))},_footerItems:function(){var t=this.tbody;return this._hasLockedColumns&&(t=t.add(this.lockedTable)),t.find("tr").filter((function(){return e(this).hasClass(Pe.footerTemplate)}))},dataItems:function(){var e=kendo.ui.DataBoundWidget.fn.dataItems.call(this);if(this._hasLockedColumns){for(var t=e.length,n=new Array(2*t),i=t;--i>=0;)n[i]=n[i+t]=e[i];e=n}return e},_showNoRecordsTemplate:function(){var t,n,i=this.options.scrollable&&!this.wrapper[0].style.height?` ${kendo.attr("style-margin")}="0 auto" ${kendo.attr("style-position")}="static"`:"";this._contentTree.render([]),this._hasLockedColumns&&this._lockedContentTree.render([]),t=kendo.format('<div class="k-grid-norecords-template"{1}>{0}</div>',this.options.messages.noRows,i),n=e(kendo.template((()=>kendo.format('<div class="{0}">{1}</div>',be,t)))({})),kendo.applyStylesFromKendoAttributes(n,["margin","position"]),n.insertAfter(this.table)},_showStatus:function(t){var n=this.element.find(".k-status"),i=e(this.content).add(this.lockedContent);n.length||(n=e("<div class='k-status' role='alert' aria-live='polite' />").appendTo(this.element)),this._contentTree.render([]),this._hasLockedColumns&&this._lockedContentTree.render([]),i.hide(),n.html(t)},_hideStatus:function(){this.element.find(".k-status").remove(),this._hideNoRecordsTempalte(),e(this.content).add(this.lockedContent).show()},_hideNoRecordsTempalte:function(){this.element.find("."+be).remove()},_adjustHeight:function(){var e,t=this,n=this.element,i=n.find(H+Pe.gridContentWrap),r=n.find(H+Pe.gridHeader),o=n.find(H+Pe.gridToolbar),a=n.find(H+Pe.status),s=t._isPageable()&&t.pager&&t.pager.element.is(":visible")?d(t.pager.element):0,l=kendo.support.scrollbar();n.css("height",this.options.height);var c,u,h;((c=n)[0].style.height||(u=c.height(),c.height("auto"),h=c.height(),c.height(""),u!=h))&&(e=t.options.hasHeader?n.height()-d(r)-d(o)-d(a)-s:n.height()-d(o)-d(a)-s,i.height(e),this._hasLockedColumns&&(l=this.table[0].offsetWidth>this.table.parent()[0].clientWidth?l:0,this.lockedContent.height(e-l)))},_resize:function(e,t){this._applyLockedContainersWidth(),this._adjustHeight(),this.pager&&this.pager.element&&this.pager.resize(t)},_minScreenSupport:function(){this.hideMinScreenCols()&&(this.minScreenResizeHandler=this.hideMinScreenCols.bind(this),e(window).on("resize",this.minScreenResizeHandler))},_iterateMinScreenCols:function(e,n){for(var i=!1,r=0;r<e.length;r++){var o=e[r],a=o.minScreenWidth;a!==t&&null!==a&&(i=!0,a>n?this.hideColumn(o):this.showColumn(o)),!o.hidden&&o.columns&&(i=this._iterateMinScreenCols(o.columns,n)||i)}return i},hideMinScreenCols:function(){var e=this.columns,t=window.innerWidth>0?window.innerWidth:screen.width;return this._iterateMinScreenCols(e,t)},destroy:function(){this._destroyColumnAttachments(),h.fn.destroy.call(this);var t=this.dataSource;t.unbind(E,this._refreshHandler),t.unbind(z,this._errorHandler),t.unbind(P,this._progressHandler),this._navigatableTables&&(this._navigatableTables.off(F),this._navigatableTables=null,this._headertables=null),this._current=null,this._resizeHandler&&e(window).off("resize"+F,this._resizeHandler),this._dragging&&(this._dragging.destroy(),this._dragging=null),this.resizable&&(this.resizable.destroy(),this.resizable=null),this.reorderable&&(this.reorderable.destroy(),this.reorderable=null),this._draggableInstance&&this._draggableInstance.element&&(this._draggableInstance.destroy(),this._draggableInstance=null),this.selectable&&this.selectable.destroy(),this._userEvents&&(this._userEvents.destroy(),this._userEvents=null),this.minScreenResizeHandler&&e(window).off("resize",this.minScreenResizeHandler),this._destroyEditor(),this.element.off(F),this.wrapper&&this.wrapper.off(F),this._touchScroller&&this._touchScroller.destroy(),this._destroyPager(),t&&(t._dataMaps=null),this._autoExpandable=null,this._refreshHandler=this._errorHandler=this._progressHandler=this._dataSourceFetchProxy=null,this.thead=this.content=this.tbody=this.table=this.element=this.lockedHeader=this.lockedContent=null,this._statusTree=this._headerTree=this._contentTree=this._lockedHeaderColsTree=this._lockedContentColsTree=this._lockedHeaderTree=this._lockedContentTree=null,kendo.destroy(this.wrapper)},options:{name:"TreeList",columns:[],autoBind:!0,scrollable:!0,selectable:!1,sortable:!1,toolbar:null,height:null,columnMenu:!1,messages:{noRows:"No records to display",loading:"Loading...",requestFailed:"Request failed.",retry:"Retry",dragHandleLabel:"Drag row",commands:{edit:"Edit",update:"Save",canceledit:"Cancel",create:"Add new record",createchild:"Add child record",destroy:"Delete",excel:"Export to Excel",pdf:"Export to PDF",search:"Search...",select:"Select",selectRow:"Select Row",selectAllRows:"All rows",clearSelection:"Clear selection",exportPdf:"Export to PDF",exportExcel:"Export to Excel",sortAsc:"Sort Ascending",sortDesc:"Sort Descending",expandItem:"Expand Item",collapseItem:"Collapse Item"},sortHeader:"Press Enter to sort",filterCellTitle:"filter cell"},excel:{hierarchy:!0},resizable:!1,search:!1,filterable:!1,editable:!1,reorderable:!1,pageable:!1,renderAllRows:!0,rowTemplate:null,altRowTemplate:null,hasHeader:!0,contextMenu:!1},events:[E,L,B,O,V,N,j,$,U,K,Y,Q,he,pe,fe,me,Z,I,W,J,ee,te,ne,ie,re,oe,ae,se,le,ce,de],getOptions:function(){this.options.dataSource=null;var t=x(!0,{},this.options);t.columns=kendo.deepExtend([],this.columns);var n=this.dataSource,i=n.options.data&&n._data;return n.options.data=null,t.dataSource=e.extend(!0,{},n.options),n.options.data=i,t.dataSource.data=i,t.dataSource.page=n.page(),t.dataSource.filter=e.extend(!0,{},n.filter()),t.dataSource.pageSize=n.pageSize(),t.dataSource.sort=n.sort(),t.dataSource.group=n.group(),t.dataSource.aggregate=n.aggregate(),t.dataSource.transport&&(t.dataSource.transport.dataSource=null),t.pageable&&t.pageable.pageSize&&(t.pageable.pageSize=n.pageSize()),t},setOptions:function(e){var t=this.getOptions();kendo.deepExtend(t,e),e.dataSource||(t.dataSource=this.dataSource);var n=this.wrapper,i=this._events,r=this.element;this.destroy(),this.options=null,n[0]!==r[0]&&(n.before(r),n.remove()),r.empty(),this.init(r,t,i),this._setEvents(t)},_destroyColumnAttachments:function(){var t=this;t.thead&&t.thead.add(t.lockedHeader).find("th").each((function(){var t=e(this),n=t.data("kendoFilterMenu"),i=t.data("kendoColumnSorter"),r=t.data("kendoColumnMenu");n&&n.destroy(),i&&i.destroy(),r&&r.destroy()}))},_toggle:function(n,i){var r=this,o=e.Deferred().resolve().promise(),a=n.loaded();if(r._isIncellEditable()&&r.editor&&(e(y()).change(),r.closeCell()),n._error&&(n.expanded=!1,n._error=t),!a&&n.expanded)return o;function s(){r._toggleData(),r._isPageable()?r.refresh():r._render(),r._syncLockedContentHeight()}return void 0===i&&(i=!n.expanded),n.expanded=i,a||(o=this.dataSource.load(n).always((function(){s()}))),s(),o},_toggleData:function(){this._isPageable()&&this._togglePageableData()},_togglePageableData:function(){var e,t=this,n=t.dataSource,i=n._getData(),r=n._defaultPageableQueryOptions();t._renderProgress(!0);var o=n._getChildrenMap()||n.childrenMap(n._getData());n._processDataItemsState(i,o),e=n._processPageableQuery(i,r),r.childrenMap=e.childrenMap,r.filteredChildrenMap=e.filteredChildrenMap,n._aggregateResult=n._calculateAggregates(e.dataToAggregate,r),n.view(e.data),n.filter()||n._calculateCollapsedTotal(),t._refreshPager(),t._renderProgress(!1)},_refreshPager:function(){var e=this.pager;e&&e.refresh()},expand:function(e){return this._toggle(this.dataItem(e),!0)},collapse:function(e){return this._toggle(this.dataItem(e),!1)},_toggleChildren:function(t){var n=e(t.target),i=this.dataItem(n);if(i){var r=i.expanded?U:$;this.trigger(r,{model:i})||this._toggle(i),t.preventDefault()}},_navigatable:function(){var t=this;if(t.options.navigatable){var n=t.table.add(t.lockedTable),i=t.thead.parent().add(e(">table",t.lockedHeader));t.options.scrollable&&(n=n.add(i)),i.find("a.k-link").attr("tabIndex",-1),this._navigatableTables=n,this._headertables=i,n.on(kendo.support.touch?"touchstart"+F:"mousedown"+F,ge+">:visible",t._tableClick.bind(t)).on("focus"+F,t._tableFocus.bind(t)).on("focusout"+F,t._tableBlur.bind(t)).on("keydown"+F,t._tableKeyDown.bind(t))}else t.table.attr("tabindex",0)},cellIndex:function(t){var n=0;return this.lockedTable&&!e.contains(this.lockedTable[0],t[0])&&(n=it(vt(this.columns)).length),e(t).parent().children().index(t)+n},_isActiveInTable:function(){var t=kendo._activeElement();return!!t&&(this.table[0]===t||e.contains(this.table[0],t)||this.lockedTable&&(this.lockedTable[0]===t||e.contains(this.lockedTable[0],t)))},_restoreCurrent:function(n,i,r){var o,a,s;n===t||n<0||(this._current&&this._current.removeClass("k-focus"),i?this._setCurrent(this.thead.find("th").eq(n)):(o=r||0,n=n||0,a=e(),this.lockedTable&&(a=this.lockedTable.find(">tbody>tr:visible").eq(o)),s=(a=a.add(this.tbody.children().eq(o))).find(">td:visible").eq(n),this._setCurrent(s)),this._current&&(wt(this.table,!0),this._current.addClass("k-focus")))},current:function(e){return this._setCurrent(e,!0)},_setCurrent:function(t,n,i){var r=this,o=r._current;return t=e(t),i?t[0]&&(r._current=t,r._updateCurrentAttr(r._current,t),r._scrollCurrent(),n||this.trigger(ce,{element:t})):(!t.length||o&&o[0]===t[0]||(this._updateCurrentAttr(o,t),this._scrollCurrent(),n||this.trigger(ce,{element:t})),t&&t.length&&(this._lastCellIndex=t.parent().children(q).index(t))),r._current},_scrollCurrent:function(){var t=this._current,n=this.options.scrollable;if(t&&n){var i=t.parent(),r=i.closest("table").parent(),o=r.is(".k-grid-content-locked,.k-grid-header-locked"),a=r.is(".k-grid-content-locked,.k-grid-content"),s=e(this.content)[0];a&&this._scrollTo(this._relatedRow(i)[0],s),this.lockedContent&&(this.lockedContent[0].scrollTop=s.scrollTop),o||this._scrollTo(t[0],s)}},_findCurrentCell:function(){var t=this,n=t.current(),i=e(t.table).add(t.header).add(t.lockedTable).add(t.lockedHeader);return n&&i.find(n).length>0?n:i.find(H+Pe.focused)},_scrollTo:function(t,n){var i=t.tagName.toLowerCase(),r="td"===i||"th"===i,o=e(t).closest("table")[0],a=t[r?"offsetWidth":"offsetHeight"],s=n[r?"scrollLeft":"scrollTop"],l=n[r?"clientWidth":"clientHeight"],c="relative"===e(t).css("position")&&we&&r?Math.abs(o.offsetLeft-t.offsetLeft):t[r?"offsetLeft":"offsetTop"],d=c+a,u=0,h=0,p=0;we&&r&&(v.msie||v.edge?h=o.offsetLeft:(v.mozilla||v.webkit&&v.version>85)&&(p=o.offsetLeft-kendo.support.scrollbar())),u=(s=Math.abs(s+h-p))>c?c:d>s+l?a<=l?d-l:c:s,u=Math.abs(u+h)+p,n[r?"scrollLeft":"scrollTop"]=u},_aria:function(){var e,t,n,i,r,o=this.wrapper,a=this.table,s=o.find(".k-grid-toolbar"),l=o.find(".k-grouping-header"),c=a.attr("id"),d=a.attr("tabindex"),u=this.thead.find("tr").length+this.wrapper.find(".k-grid-footer-wrap table tr").length,h=this._trailingColumns(),p=this.virtualScroll,f=this.options.pageable;a.attr({role:"treegrid",tabindex:d>=0?d:0}),a.find("tbody, thead, tfoot").attr("role","rowgroup"),a.find("tr").attr("role","row"),a.find("th").attr("role","columnheader"),a.find("td").attr("role","gridcell"),(f&&this.dataSource.totalPages()>1||p&&p.rows)&&(r=this._groups()>0?-1:u+this.dataSource.total(),a.attr("aria-rowcount",r)),r&&r>0&&this._ariaRowIndex(),(p&&p.columns||!a.attr("aria-colcount")&&(a.find("td:hidden").length>0||o.find(".k-grid-content-locked td:hidden").length>0))&&(a.attr("aria-colcount",h+it(this.columns).length),this._ariaColumnIndex()),c||(c=kendo.guid(),a.attr("id",c)),this.pager&&this.pager.element.attr("aria-controls",c),s.attr({role:"toolbar","aria-label":this.options.messages.toolbarLabel,"aria-controls":c}),l.attr({role:"toolbar","aria-label":this.options.messages.groupingHeaderLabel,"aria-controls":c}),t=this._ariaHeaderFooter("header","thead","th, td","columnheader"),n=this._ariaHeaderFooter("footer","tfoot","td","gridcell"),o.find(".k-grid-content-locked").length>0&&this._ariaLockedContent(),(t||n)&&(i=[t,e=this.tbody.attr("id")||kendo.guid(),n].join(" "),this.tbody.attr("id",e),a.attr("aria-owns",i))},_ariaColumnIndex:function(){var t,n,i,r,o=this._trailingColumns(),a=this.tbody.find(">tr").last().find("> td[data-virtual]"),s=this.thead.find(">tr").not(".k-filter-row"),l=this.wrapper.find(".k-grid-header-locked thead > tr").not(".k-filter-row"),c=Number.MAX_VALUE,d=0,u=0,h=0,p=0,f=function(n,i){var r=i.getAttribute("data-index"),o=Number(r),a=e(i).closest(".k-grid-header-locked");0===a.length&&o<c&&(c=o),a.length>0&&u<o&&(u=o),0===a.length&&d<o&&(d=o),null!==r?(i.setAttribute("aria-colindex",Number(o)+1),t=Number(o)+1+i.getAttribute("colspan")):(i.setAttribute("aria-colindex",t+1),t+=i.getAttribute("colspan"))};for(2===a.length?(h=Number(a[0].getAttribute("colspan")),p=Number(a[1].getAttribute("colspan"))):1===a.length&&0===a.prev().length?h=Number(a[0].getAttribute("colspan")):1===a.length&&1===a.prev().length&&(p=Number(a[0].getAttribute("colspan"))),n=0;n<l.length;n++)t=0,l.eq(n).find("th").each(f);for(n=0;n<s.length;n++)t=0,s.eq(n).find("th").each(f);for(n=0;n<=u;n++)i=n+o,this.wrapper.find(".k-grid-content-locked tbody > tr > td:nth-child("+(n+1)+")").attr("aria-colindex",i+1);for(n=h;n<=d-c-p;n++)r=0===h?n+1:n-h+2,i=c+n+o,this.tbody.find("> tr > td:nth-child("+r+")").attr("aria-colindex",i+1)},_ariaHeaderFooter:function(e,t,n,i){var r,o=this.wrapper,a=o.find(".k-grid-"+e+" .k-grid-"+e+"-wrap table"),s=o.find(".k-grid-"+e+" .k-grid-"+e+"-locked table"),l="";return a.length>0&&(l=(r=a.find(t+", tbody")).attr("id")||kendo.guid(),a.attr("role","none"),a.find("tr").attr("role","row"),a.find(n).attr("role",i),r.attr({role:"rowgroup",id:l})),s.length>0&&this._ariaLocked(e,t,n,i),s.find("td").attr("role","gridcell"),a.find("td").attr("role","gridcell"),l},_ariaId:function(){var e=this.element.attr("id")||"aria";e&&(this._cellId=e+"_active_cell")},_ariaLocked:function(t,n,i,r){var o=this,a=o.wrapper,s=a.find(".k-grid-"+t+" .k-grid-"+t+"-wrap table"),l=a.find(".k-grid-"+t+" .k-grid-"+t+"-locked table"),c=s.find("tr"),d=l.find("tr");l.attr("role","none"),l.find(n+", tbody").attr("role","none"),d.attr("role","none"),l.find(i).attr("role",r),c.each((function(n,r){var a=[];a=(a=o._cellsIds(d.eq(n).find(i),"locked_"+t,n)).concat(o._cellsIds(e(r).find(i),t,n)),r.setAttribute("aria-owns",a.join(" "))}))},_ariaLockedContent:function(){var t=this,n=t.table.find("tr"),i=t.wrapper.find(".k-grid-content-locked table"),r=i.find("tr");i.attr("role","none"),i.find("tbody").attr("role","none"),r.attr("role","none"),i.find("td").attr("role","gridcell"),n.each((function(n,i){var o=[];o=(o=t._cellsIds(r.eq(n).find("td"),"locked_datacell",n)).concat(t._cellsIds(e(i).find("td"),"datacell",n)),i.setAttribute("aria-owns",o.join(" "))}))},_ariaAddHiddenColIndex:function(){var e=this.virtualScroll||{},t=this.columns,n=this.table,i=it(t).length;e.columns||n.attr("aria-colcount")||(this._ariaColumnIndex(),n.attr("aria-colcount",i))},_ariaRemoveHiddenColIndex:function(){var e=this.virtualScroll||{};it(this.columns).length;e.columns||(this.wrapper.find("td, th").removeAttr("aria-colindex"),this.table.removeAttr("aria-colcount"))},_ariaRowIndex:function(){var e,t=this.thead.find(">tr"),n=t.length,i=this.tbody.find(">tr"),r=this.wrapper.find(".k-grid-footer-wrap tfoot > tr"),o=this.dataSource.total(),a=this.dataSource.skip()||0,s=1;for(e=0;e<n;e++)t.eq(e).attr("aria-rowindex",s+e);for(s=n+a,e=0;e<i.length;e++)s+=1,i.eq(e).attr("aria-rowindex",s);for(s=n+o+1,e=0;e<r.length;e++)r.eq(e).attr("aria-rowindex",s+e)},_cellsIds:function(e,t,n){var i=[];return e.each((function(e,r){var o=r.getAttribute("id")||t+"_"+n+"_"+e;r.setAttribute("id",o),i.push(o)})),i},_trailingColumns:function(){return this._groups()},_groups:function(){var e=this.dataSource.group();return e?e.length:0},_currentDataIndex:function(e,n){var i=n.attr("data-index");if(!i)return t;var r=vt(this.columns).length;return r&&!e.closest("div").hasClass("k-grid-content-locked")[0]?i-r:i},_prevVerticalCell:function(t,n){var i,r=n.parent(),o=t.children(ge),a=o.index(r),s=this._currentDataIndex(t,n),l=q+","+G;if((s||n.hasClass("k-header"))&&!r.hasClass("k-filter-row"))return(i=ct(n)).eq(i.length-2);if(s=Math.max(r.children(l).index(n),this._lastCellIndex||0),r.hasClass("k-filter-row"))return je(t).filter(Ue).eq(s);if(-1==a){if(!(r=t.find("tr.k-filter-row:visible"))[0])return je(t).filter(Ue).eq(s)}else r=0===a?e():o.eq(a-1);return(i=r.children(l)).length>s?i.eq(s):i.eq(0)},_nextVerticalCell:function(e,n){var i,r=n.parent(),o=e.children(ge),a=o.index(r),s=this._currentDataIndex(e,n),l=q+","+G;if(-1!=a&&s===t&&n.hasClass("k-header"))return dt(n).eq(1);s=s?parseInt(s,10):r.children(l).index(n),s=Math.max(s,this._lastCellIndex||0),r=-1==a?o.eq(0):o.eq(a+n[0].rowSpan);var c=s;if(this._currentDataIndex(e,n)!==t)for(var d=r.children(":not(.k-group-cell):not(.k-hierarchy-cell)"),u=d.filter(":hidden"),h=0,p=u.length;h<p;h++)d.index(u[h])<s&&c--;return s=c,(i=r.children(l)).length>s?i.eq(s):i.eq(0)},_verticalContainer:function(e,t){var n=e.parent(),i=this._navigatableTables.length,r=Math.floor(i/2),o=T(n[0],this._navigatableTables);return t&&(r*=-1),((o+=r)>=0||o<i)&&(n=this._navigatableTables.eq(o)),n.find(t?"thead":"tbody")},_filterFocusable:function(){return this.wrapper.find(".k-filter-row").find(".k-dropdownlist, .k-input .k-input-inner:visible, input[type='radio']:visible, input[type='checkbox']:visible")},_updateCurrentAttr:function(t,n){var i=e(t).data("headerId");e(t).removeClass(Pe.focused),this.table.removeAttr(Ie),i?(i=i.replace(this._cellId,""),e(t).attr("id",i)):e(t).removeAttr("id"),n.data("headerId",n.attr("id")).attr("id",this._cellId).addClass(Pe.focused),this.table.attr(Ie,this._cellId),this._current=n},_tableKeyDown:function(t){var n=!1,i=this.current(),r=e(t.target),o=!t.isDefaultPrevented()&&!r.is(":button,a,:input,a>.k-icon,a>.k-svg-icon");if(i=i||e(this.lockedTable).add(this.table).find(ge+" > td:visible").first(),t.altKey&&t.keyCode==c.DOWN)return i.find(".k-grid-filter-menu, .k-grid-column-menu").click(),void t.stopImmediatePropagation();t.keyCode===c.F10&&this.toolbar&&this.toolbar.length&&(this.toolbar.find("[tabindex=0]:visible").first().trigger("focus"),n=!0),o&&t.keyCode==c.UP&&(n=this._moveUp(i,t.shiftKey)),o&&t.keyCode==c.DOWN&&(n=this._moveDown(i,t.shiftKey)),o&&t.ctrlKey&&i.is(".k-header")&&this.options.reorderable&&t.keyCode==(we?c.RIGHT:c.LEFT)?this._moveColumn(i,!0):o&&t.ctrlKey&&i.is(".k-header")&&this.options.reorderable&&t.keyCode==(we?c.LEFT:c.RIGHT)?this._moveColumn(i,!1):o&&t.keyCode==(we?c.LEFT:c.RIGHT)?t.altKey?(this._handleExpand(i),n=!0):n=this._moveRight(i):o&&t.keyCode==(we?c.RIGHT:c.LEFT)&&(t.altKey?(this._handleCollapse(i),n=!0):n=this._moveLeft(i)),o&&t.keyCode==c.PAGEDOWN&&(n=this._handlePageDown()),o&&t.keyCode==c.PAGEUP&&(n=this._handlePageUp()),t.keyCode!=c.ENTER&&t.keyCode!=c.F2||(n=this._handleEnterKey(i,t.currentTarget,r)),t.keyCode==c.ESC&&(n=this._handleEscKey(i,t.currentTarget)),o&&t.keyCode==c.HOME&&(n=this._handleHome(i,t.ctrlKey)),o&&t.keyCode==c.END&&(n=this._handleEnd(i,t.ctrlKey)),t.keyCode==c.TAB&&(n=this._handleTabKey(i,t.currentTarget,t.shiftKey,r)),n&&(t.preventDefault(),t.stopPropagation())},_moveColumn:function(t,n){var i=this.wrapper.data().kendoReorderable.element.find(this._draggableInstance.options.filter+":visible"),r=ot(st(this.columns)),o=i.index(e(t)),a=n?-1:1,s=r[o],l=lt(r,this.columns,o,o+a);l>=0&&(this.reorderColumn(l,s,n),this.trigger(ne,{newIndex:l,oldIndex:o,column:s}))},_handleExpand:function(e){var t=e.parent(),n=this.dataItem(t);return!e.hasClass("k-header")&&(!(!n||!n.hasChildren||n.expanded||this.trigger($,{model:n}))&&(this.expand(t),!0))},_handleCollapse:function(e){var t=this,n=e.parent(),i=t.dataItem(n);return!e.hasClass("k-header")&&(!(!(i&&i.hasChildren&&i.expanded)||t.trigger(U,{model:i}))&&(t.collapse(n),!0))},_handleHome:function(e,t){var n,i=e.parent(),r=i.parent(),o=this.lockedTable&&this.lockedTable.children("tbody")[0]===r[0],a=r[0]===this.tbody[0];if(t?n=this.lockedTable?this.lockedTable.find(ge+" > td:visible").first():this.table.find(ge+" > td:visible").first():(a||o)&&(a&&this.lockedTable&&(i=this._relatedRow(i)),n=i.children(ve).first()),n&&n.length)return this._setCurrent(n),!0},_handleEnd:function(e,t){var n,i=e.parent(),r=i.parent(),o=this.lockedTable&&this.lockedTable.children("tbody")[0]===r[0],a=r[0]===this.tbody[0];if(t?n=this.table.find(ye).last().children(ve).last():(a||o)&&(!a&&this.lockedTable&&(i=this._relatedRow(i)),n=i.children(ve).last()),n&&n.length)return this._setCurrent(n),!0},_handlePageDown:function(){var e=this;return!!e._isPageable()&&(e.dataSource._restorePageSizeAfterAddChild(),e.dataSource.page(e.dataSource.page()+1),!0)},_handlePageUp:function(){var e=this;return!!e._isPageable()&&(e.dataSource._restorePageSizeAfterAddChild(),e.dataSource.page(e.dataSource.page()-1),!0)},_handleEscKey:function(t,n){var i,r,o,a,s,l=kendo._activeElement(),c=this;return t&&t.parent().hasClass("k-grid-edit-row")?(c._isIncellEditable()?(r=t.parent(),a=t.index(),o=r.index(),s=r.closest("tbody"),c.closeCell(!0),c._setCurrent(s.children().eq(o).children().eq(a),!1,!0)):(i=e(t).parent().index(),l&&l.blur(),this.cancelRow(),i>=0&&this._setCurrent(this.items().eq(i).children(ve).first())),wt(c.table,!0),!0):t.has(l).length?(wt(c.table,!0),!0):!!t.parent().hasClass("k-filter-row")&&(this._filterFocusable().attr(X,-1),wt(this.table,!0),!0)},_handleEnterKey:function(t,n,i){var r,o,a=this.options.editable,s=i.closest("[role=gridcell]");return i.is("table")||e.contains(t[0],i[0])||(t=s),t.is("th")?(o=t.find(".k-link"),!(t.has(e(y())).length>0)&&(o.length?o.click():t.parent().hasClass("k-filter-row")?(this._filterFocusable().attr(X,0),t.find(":kendoFocusable").first().trigger("focus")):t.find(xe).trigger("focus"),!0)):(r=t.find(":kendoFocusable").first())[0]&&t.hasClass("k-focus")?(r.trigger("focus"),!0):a&&!i.is(":button,.k-button,textarea")?(s[0]||(s=t),this._handleEditing(s,!1,n),!0):(!a&&t.is("td[aria-expanded]")&&(t.is("[aria-expanded=false]")?this._handleExpand(t):this._handleCollapse(t)),!1)},_handleTabKey:function(t,n,i,r){var o,a,s=this;if(!(s.options.editable&&s._isIncellEditable())||t.is("th")||(this.options.scrollable?this._headertables.filter(n).length:this.thead.filter(r).length)){if(t.parent().hasClass("k-filter-row")){if(a=this._filterFocusable(),!i&&a[a.length-1]===document.activeElement)return a.first().trigger("focus"),!0;if(i&&a[0]===document.activeElement)return a.last().trigger("focus"),!0}return!1}return o=e(y()).closest(H+Pe.editCell),!s.options._tabCycleStop&&(o[0]&&o[0]!==t[0]&&(t=o),(o=s._tabNext(t,n,i)).length?(s._handleEditing(t,o,o.closest("table")),!0):(s._preventPageSizeRestore=!1,!1))},_tabNext:function(e,t,n){var i=this,r=!0,o=n?e.prevAll(q).first():e.nextAll(":visible").first();return o.length||(o=e.parent(),i.lockedTable&&(r=n&&t==i.lockedTable[0]||!n&&t==i.table[0],o=i._relatedRow(o)),r&&(o=o[n?"prevAll":"nextAll"]("tr:not(.k-grouping-row):not(.k-detail-row):visible").first()),o=n?o.children(q).last():o.children(q).first(),i.dataSource._restorePageSizeAfterAddChild()),o},_handleEditing:function(t,n,i){var r,o,a,s,l=this,c=e(kendo._activeElement()),d=v.msie,u=l.options.editable&&!1!==l.options.editable.update,h=l._isIncellEditable(),p=e(n).parents("tr").index(),f=e(n).index(),m=e(t).parents("tr").index(),g=t.index();if(i=e(i),a=h?t.hasClass(Pe.editCell):t.parent().hasClass("k-grid-edit-row"),l.editor){if((r=l.editor.wrapper)&&e.contains(r[0],c[0])&&(v.opera?c.trigger("blur").change().triggerHandler("blur"):(c.trigger("blur"),d&&c.trigger("blur"))),!l.editor)return void wt(l.table);if(!l.editor.end())return h?l._setCurrent(r):l._setCurrent(r.children().filter(ve).first()),void((o=r.find(":kendoFocusable").first()[0])&&o.focus());h?(l._preventPageSizeRestore=!0,l.closeCell(),l._preventPageSizeRestore=!1,0===e(l.table).add(l.lockedTable).find(H+Pe.editCell).length&&l._setCurrent(i.find("tbody").children().eq(m).children().eq(g))):(l.saveRow(),a=!0)}if((n=e(n).length&&0===i.find(n).length?i.find("tbody").children().eq(p).children().eq(f):n)&&l._setCurrent(n),wt(l.table,!0),u)if(!a&&!n||n){if(!l.current())return;var _=l.current().index();h?(l.editCell(l.current()),(s=e(l.table).add(l.lockedTable).find(H+Pe.editCell)[0])?l._current=e(s):l._setCurrent(l._findCurrentCell())):(l.editRow(l.current().parent()),l._setCurrent(l.editor.wrapper.children().eq(_)),l.current().removeClass("k-focus"))}else l.dataSource._restorePageSizeAfterAddChild()},_moveRight:function(e){var t=e.nextAll(ve).first(),n=e.parent(),i=n.index();return(e.hasClass("k-header")||n.is(".k-filter-row"))&&!(t=e.nextAll(_e).first())[0]&&this.lockedTable&&e.closest("table")[0]===this.lockedHeader.find("table")[0]&&(t=this.thead.find("tr").eq(i).find(_e).first()),!t[0]&&this.lockedTable&&e.closest("table")[0]===this.lockedTable[0]&&(t=this._relatedRow(n).children(ve).first()),t[0]&&t[0]!==e[0]&&wt(this.table,!0),this._setCurrent(t),!0},_moveLeft:function(e){var t=e.prevAll(ve).first(),n=e.parent(),i=n.index();return(e.hasClass("k-header")||n.is(".k-filter-row"))&&!(t=e.prevAll(_e).first())[0]&&this.lockedTable&&e.closest("table")[0]===this.thead.parent()[0]&&(t=this.lockedHeader.find(">table>thead>tr").eq(i).children(_e).last()),!t[0]&&this.lockedTable&&e.closest("table")[0]===this.table[0]&&(t=this._relatedRow(n).children(ve).last()),t[0]&&t[0]!==e[0]&&wt(this.table,!0),this._setCurrent(t),!0},_moveUp:function(e,t){var n,i=e.parent().parent();t?(n=(n=e.parent()).prevAll(ye).first(),n=e.parent().is(ye)?n.children().eq(e.index()):n.children(q).last()):(n=this._prevVerticalCell(i,e))[0]||(this._lastCellIndex=0,i=this._verticalContainer(i,!0),(n=this._prevVerticalCell(i,e))[0]&&wt(this.table,!0));var r=this._lastCellIndex||0;return this._setCurrent(n),this._lastCellIndex=r,!0},_moveDown:function(e,t){var n,i=e.parent().parent();t?(n=(n=e.parent()).nextAll(ye).first(),n=e.parent().is(ye)?n.children().eq(e.index()):n.children(q).first()):(n=this._nextVerticalCell(i,e))[0]||(this._lastCellIndex=0,i=this._verticalContainer(i),(n=this._nextVerticalCell(i,e))[0]&&wt(this.table,!0));var r=this._lastCellIndex||0;return this._setCurrent(n),this._lastCellIndex=r,!0},_tableClick:function(t){var n=this,i=e(t.currentTarget),r=i.is("tr:not('.k-filter-row')>th"),o=e(t.target),a=this.table.add(this.lockedTable),s=this.thead.parent().add(e(">table",this.lockedHeader)),l=et(o.add(o.closest(".k-button-icon"))),c=i.closest("table")[0];kendo.support.touch||c!==a[0]&&c!==a[1]&&c!==s[0]&&c!==s[1]||(this.options.navigatable&&!l&&this._setCurrent(i),!r&&l||setTimeout((function(){et(kendo._activeElement())&&e.contains(c,kendo._activeElement())||wt(n.table,!0)})),r&&t.preventDefault())},_tableFocus:function(e){var t=this.current(),n=this.lockedTable?this.lockedTable:this.table;t&&t.is(":visible")?t.addClass(Pe.focused):this._setCurrent(n.find(ge+" > td:visible").first()),this.table.attr(X,0)},_tableBlur:function(){var e=this.current();e&&e.removeClass(Pe.focused)},_attachEvents:function(){var e=this,t=H+Pe.retry;e._userEvents=new kendo.UserEvents(e.element,{tap:e._onPress.bind(e),allowSelection:!0}),this.element.on(R+F,t,this._dataSourceFetchProxy).on(R+F,".k-button[data-command]",this._commandClick.bind(this)).on("input"+F,".k-grid-search input",this._search.bind(this)),this._attachCellEditingEventHandlers()},_onPress:function(e){var t=this;t._isToggleIcon(e.event.target)&&t._toggleChildren.call(t,e.event)},_isToggleIcon:function(t){const n=Me+",[class*='-i-arrow-rotate-cw']";return e(t).closest(":not(path,svg)").is(n)},_attachCellEditingEventHandlers:function(){var t=this,n=t.options.editable,i=t.selectable&&t.selectable.options.multiple;t._isIncellEditable()&&!1!==n.update&&t.wrapper.on(t.options._editCellEvent||R+F,"tr:not(.k-grouping-row) > td",(function(n){var r=e(this),o=t.lockedTable&&r.closest("table")[0]===t.lockedTable[0];if(!t._isToggleIcon(n.target))return r.hasClass(Pe.editCell)||r.has("a.k-grid-delete").length||r.has("button.k-grid-delete").length||r.closest("tbody")[0]!==t.tbody[0]&&!o||e(n.target).is(":input")||e(n.target).is(Me)?(t.editor||t.dataSource._restorePageSizeAfterAddChild(),void(t._preventPageSizeRestore=!1)):void(t.editor?r.is(":not(.k-command-cell)")&&t.editor.end()&&(i&&e(y()).trigger("blur"),t.closeCell(),t.editCell(r)):t.editCell(r))})).on("mousedown"+F,"tr:not(.k-grouping-row) > td",(function(n){t.editor&&t._isPageable()&&!xt(t.dataSource._addChildPageSize)?t._preventPageSizeRestore=e(n.target).parents(H+Pe.editRow).length>0:t._preventPageSizeRestore=!1})).on("focusin"+F,(function(){e.contains(this,y())||(clearTimeout(t._closeCellTimeout),t._closeCellTimeout=null)})).on("focusout"+F,(function(n){t._closeCellTimeout=setTimeout((function(){!function(n){var i=y(),r=t.editor||{},o=r.element;!o||e.contains(o[0],i)||o[0]===i||e(i).closest(".k-animation-container").length||r.end()&&(n.relatedTarget||!t._isPageable()||xt(t.dataSource._addChildPageSize)||(t._preventPageSizeRestore=!1),t.closeCell()),t._preventPageSizeRestore=!1}(n)}),1)}))},_commandByName:function(e){var t,n,i,r,o=this.columns,a=Array.isArray(this.options.toolbar)?this.options.toolbar:[];if(e){if(e=e.toLowerCase(),He[e])return He[e];for(t=0;t<o.length;t++)if(i=o[t].command)for(n=0;n<i.length;n++)if((r=i[n].name)&&r.toLowerCase()==e)return i[n];for(t=0;t<a.length;t++)if((r=a[t].name)&&r.toLowerCase()==e)return a[t]}},_commandClick:function(n){var i=e(n.currentTarget),r=i.attr("data-command")||i.parent().attr("data-command"),o=this._commandByName(r),a=i.parentsUntil(this.wrapper,"tr");a=a.length?a:t,o&&(o.methodName?this[o.methodName](a):o.click&&o.click.call(this,n),n.preventDefault&&n.preventDefault())},_search:function(e){var t=this,n=e.currentTarget;clearTimeout(t._searchTimeOut),t._searchTimeOut=setTimeout((function(){t._searchTimeOut=null;var e=t.options,i=e.search?e.search.fields:null,r={filters:[],logic:"or"},o=n.value;if(i||(i=function(e){var t=[];e=it(e);for(var n=0;n<e.length;n++)"string"==typeof e[n]?t.push(e[n]):e[n].field&&t.push(e[n].field);return t}(e.columns)),o)for(var a=0;a<i.length;a++)r.filters.push({field:i[a],operator:"contains",value:o});else r={};t.dataSource.filter(r)}),300)},_ensureExpandableColumn:function(){this._autoExpandable&&delete this._autoExpandable.expandable;var e=S(this.columns,Ne(Ve("hidden")));e=S(e,Ne(Ve("command"))),e=S(e,Ne(Ve("selectable"))),e=S(e,Ne(Ve("draggable")));var t=S(e,Ve("expandable"));this.columns.length&&!t.length&&(this._autoExpandable=e[0],e[0].expandable=!0)},_columns:function(){var t,n=this,i=this.options.columns||[];this.columns=C(i,(function(e){return x({encoded:!0},e="string"==typeof e?{field:e}:e)}));var r=vt(i);if(r.length>0){if(this.options.rowTemplate||this.options.altRowTemplate)throw new Error("Having both row template and locked columns is not supported");this._hasLockedColumns=!0,this.columns=r.concat(_t(this.columns))}if(this.columns=at(this.columns),this._ensureExpandableColumn(),this._columnTemplates(),this._columnAttributes(),e.grep(it(n.columns),(function(e){return e.selectable&&(n._includeChildren=e.includeChildren),e.selectable})).length&&(n._checkBoxSelection=!0,n.element.on(R+F,"tbody > tr "+xe,n._checkboxClick.bind(n)),n.element.on(R+F,"thead > tr "+xe,n._headerCheckboxClick.bind(n))),(t=e.grep(it(n.columns),(function(e){return e.draggable}))).length){n._hasDragHandleColumn=!0;for(var o=0;o<t.length;o++)t[o].headerAttributes=e.extend({"aria-label":n.options.messages.dragHandleLabel},t[o].headerAttributes)}},_columnTemplates:function(){var e,t,n,i=it(this.columns);for(e=0,t=i.length;e<t;e++)(n=i[e]).template&&(n.template=kendo.template(n.template)),this._isIncellEditable()&&(n.dirtyCellTemplate=this._createDirtyColumnTemplate(n),n.dirtyIndicatorTemplate=this._createIndicatorTemplate(n)),n.headerTemplate&&(n.headerTemplate=kendo.template(n.headerTemplate)),n.footerTemplate&&(n.footerTemplate=kendo.template(n.footerTemplate))},_columnAttributes:function(){var e,t,n=pt(this.columns);function i(e){var t,n,i;if(e&&e.style&&e.style.split)for(t=e.style.split(";"),e.style={},n=0;n<t.length;n++){i=t[n].split(":");var r=kendo.trim(i[0]);r&&(e.style[b(r)]=kendo.trim(i[1]))}}for(e=0,t=n.length;e<t;e++)i(n[e].attributes),i(n[e].headerAttributes)},_clearSortClasses:function(){var e=this;e.content&&e.content.find("col:not(.k-group-col):not(.k-hierarchy-col)").removeClass("k-sorted"),e.lockedContent&&e.lockedContent.find("col:not(.k-group-col):not(.k-hierarchy-col)").removeClass("k-sorted")},_layout:function(){this.columns;var e=this.element;this.wrapper=e.addClass(Pe.wrapper);var t=({gridHeader:e,gridHeaderWrap:t,gridContentWrap:n,toolbar:i,gridToolbar:r})=>{var o=this.options.hasHeader?`<div class='${e}'>`:"";return this.options.hasHeader&&this._hasLockedColumns&&(o+="<div class='k-grid-header-locked'><table class='k-grid-header-table k-table k-table-md'><colgroup></colgroup><thead class='k-table-thead' role='rowgroup'></thead></table></div>"),this.options.hasHeader&&(o+=`<div class='${t}'><table class='k-grid-header-table k-table k-table-md'><colgroup></colgroup><thead class='k-table-thead' role='rowgroup'></thead></table></div></div>`),this._hasLockedColumns&&(o+="<div class='k-grid-content-locked'><table class='k-grid-table k-table k-table-md' role='treegrid'><colgroup></colgroup><tbody class='k-table-tbody' role='rowgroup'></tbody></table></div>"),o+=`<div class='${n} k-auto-scrollable'><table class='k-grid-table k-table k-table-md' role='treegrid'><colgroup></colgroup><tbody class='k-table-tbody' role='rowgroup'></tbody></table></div>`,this.options.scrollable||(o="<table class='k-grid-table k-table k-table-md' role='treegrid' ><colgroup></colgroup>"+(this.options.hasHeader?`<thead class='k-table-thead ${e}' role='rowgroup'></thead>`:"")+"<tbody class='k-table-tbody' role='rowgroup'></tbody></table>"),this.options.toolbar&&(o=`<div class='${i} ${r}'></div>`+o),o};t=t.bind(this),e.append(kendo.template(t)(Pe)+"<div class='k-status' role='alert' aria-live='polite'></div>"),this.toolbar=e.find(H+Pe.gridToolbar);var n=e.find(H+Pe.gridHeader).find("thead").addBack().filter("thead");if(this.thead=n.last(),this.options.scrollable){var i=kendo.support.isRtl(e);e.find("div."+Pe.gridHeader).css(i?"padding-left":"padding-right",kendo.support.scrollbar())}var r=e.find(H+Pe.gridContentWrap);r.length?this.content=r:r=e,this.table=r.find(">table").addClass("k-grid-table"),this.tbody=this.table.find(">tbody"),this._hasLockedColumns&&(this.lockedHeader=n.first().closest(".k-grid-header-locked"),this.lockedContent=e.find(".k-grid-content-locked"),this.lockedTable=this.lockedContent.children().addClass("k-grid-table")),this._initVirtualTrees(),this._renderCols(),this.options.hasHeader&&this._renderHeader()},_initVirtualTrees:function(){this._headerColsTree=new r.Tree(this.thead.prev()[0]),this._contentColsTree=new r.Tree(this.tbody.prev()[0]),this._headerTree=new r.Tree(this.thead[0]),this._contentTree=new r.Tree(this.tbody[0]),this._statusTree=new r.Tree(this.element.children(".k-status")[0]),this.lockedHeader&&(this._lockedHeaderColsTree=new r.Tree(this.lockedHeader.find("colgroup")[0]),this._lockedContentColsTree=new r.Tree(this.lockedTable.find(">colgroup")[0]),this._lockedHeaderTree=new r.Tree(this.lockedHeader.find("thead")[0]),this._lockedContentTree=new r.Tree(this.lockedTable.find(">tbody")[0]))},_processToolbarItems:function(e){var t=this,n=t.options.messages.commands,i=[];return e.map((e=>{var r,o=(D(e)?e.name||"":e).toLowerCase(),a=n[o];if(!(o||D(e)&&e.template))throw new Error("Commands should have name specified");e=x({},He[o],{name:o,text:(He[o]||{}).text||a||(r=o,r.charAt(0).toUpperCase()+r.slice(1)),type:e.template?null:"button"},e),"search"===o&&(i.push({type:"spacer"}),e.template=e.template({message:e.text||n.search})),e.imageClass&&(e.spriteCssClass=e.imageClass,e.iconClass=e.imageClass),t._commandByName(o)&&(e.attributes||(e.attributes={}),e.attributes["data-command"]=o,e.click=e=>{e.event.preventDefault(),e.event.stopPropagation(),t._commandClick({currentTarget:e.target})}),e.className&&(e.attributes||(e.attributes={}),e.attributes.class=e.className),i.push(e)})),i},_toolbar:function(){var e=this.options.toolbar,t=this.toolbar;e&&(Array.isArray(e)?t.kendoToolBar({size:"medium",navigateOnTab:!this.options.navigatable,items:this._processToolbarItems(e)}):t.append(kendo.template(e)({})))},_initContextMenu:function(){var e=this,t=e.options,n=D(t.contextMenu)&&k(t.contextMenu.body)?{items:t.contextMenu.body}:{items:Fe},i=D(t.contextMenu)&&k(t.contextMenu.head)?{items:t.contextMenu.head}:{items:Re},r=D(t.contextMenu)?t.contextMenu:{};n=x({},{messages:t.messages,target:e.tbody,filter:".k-table-td",action:e._action.bind(e),states:e._buildStates()},r,n),i=x({},{messages:t.messages,target:e.thead,filter:".k-table-th",action:e._action.bind(e),states:e._buildStates()},r,i),e.tbodyContextMenu=new u.treelist.ContextMenu("<ul></ul>",n),e.theadContextMenu=new u.treelist.ContextMenu("<ul></ul>",i)},_buildStates:function(){var e=this;return{isEditable:e.options.editable,isSelectable:e.options.selectable,isMultiRowSelectionEnabled:"multiple, row"===e.options.selectable,isSortable:e.options.sortable&&e.options.hasHeader,alwaysDisabled:!1,hasSelection:()=>!!this.select()&&this.select().length>0,isSorted:()=>!(this.dataSource.sort()&&this.dataSource.sort().length>0),isExpandable:e=>{let t=this.dataItem(e);return t&&t.hasChildren&&!t.expanded},isCollapsible:e=>{let t=this.dataItem(e);return t&&t.hasChildren&&t.expanded}}},_action:function(e){var t=e.command,n=x({treelist:this},e.options);return new u.treelist.commands[t](n).exec()},_lockedColumns:function(){return S(this.columns,Ve("locked"))},_nonLockedColumns:function(){return S(this.columns,Ne(Ve("locked")))},_templateColumns:function(){return S(this.columns,Ve("template"))},_render:function(t){var n=this;t=t||{},t=n._renderOptions(t);var r=this.options.messages,o=n._isPageable(),a=n.dataSource,s={children:t.filteredChildrenMap||t.childrenMap,ids:t.idsMap},l=o?s&&s.children&&s.ids?s:a._initDataMaps(a._getData()):{},c=l.children,d=l.ids;t.childrenMap=c,t.idsMap=d;var u,h,p=n._dataToRender(t),f=n._renderedModelLevel(p[0],t),m=kendo.attr("uid"),g=this.select().removeClass("k-selected").map((function(t,n){return e(n).attr(m)}));this._absoluteIndex=0,n._clearRenderMap(),t.error?this._showStatus(kendo.template((({messages:e,buttonClass:t})=>`${i(e.requestFailed)} <button class='${t} k-button-md k-rounded-md k-button-solid k-button-solid-base'><span class='k-button-text'>${i(e.retry)}</span></button>`))({buttonClass:[Pe.button,Pe.retry].join(" "),messages:r})):p.length?(o&&(h=n._viewChildrenMap(t)),this._hideStatus(),u=this._hasFooterTemplate(),n._renderRows(t,p,it(_t(this.columns)),g,c,h,u),this._hasLockedColumns&&(this._absoluteIndex=0,this._lockedContentTree.render(this._trs({columns:it(vt(this.columns)),editedColumn:t.editedColumn,editedColumnIndex:t.editedColumnIndex,aggregates:t.aggregates,selected:g,data:p,childrenMap:c,viewChildrenMap:h,hasFooterTemplate:u,visible:!0,level:f,isLockedTable:!0})))):(this._hideStatus(),this._showNoRecordsTemplate()),this._touchScroller&&this._touchScroller.contentResized(),this.items().filter((function(){return e.inArray(e(this).attr(m),g)>=0})).addClass("k-selected"),this._syncLockedContentHeight(),n._togglePagerVisibility(),n._setExpanderElement()},_renderRows:function(e,t,n,i,r,o,a){this._contentTree.render(this._trs({columns:n,editedColumn:e.editedColumn,editedColumnIndex:e.editedColumnIndex,aggregates:e.aggregates,selected:i,data:t,childrenMap:r,viewChildrenMap:o,hasFooterTemplate:a,visible:!0,level:0}))},_setExpanderElement:function(){var t,n=this,i="k-grid-content-expander",r='<div class="'+i+'"></div>';n.options.scrollable&&n.wrapper.is(":visible")&&(t=n.table.parent().children("."+i),n.dataSource&&n.dataSource.view().length?t[0]&&t.remove():(t[0]||(t=e(r).appendTo(n.table.parent())),n.thead&&t.width(n.thead.width())))},_renderProgress:function(e){kendo.ui.progress(this.wrapper,e)},_renderOptions:function(e){e=e||{};var t=this,n=t.dataSource._getDataMaps(),i=t.dataSource.filter();return t._isPageable()&&(e.childrenMap=n.children,e.idsMap=n.ids,i&&(e.filteredChildrenMap=n.filteredChildren)),e},_renderedModelLevel:function(e,t){return this._isPageable()?this.dataSource._pageableModelLevel(e,t):0},_viewChildrenMap:function(e){e=e||{};var t,n,i,r,o,a,s=this,l=s.dataSource,c=l.childrenMap(l.view()),d=l._modelIdField(),u=l._parentNodesNotInView();s._clearRenderMap();for(var h=0;h<u.length;h++){n=(t=u[h])[d],s._markNodeAsNonRenderable(n),c[n]=c[n]||[],(a=l._parentNodes(t).slice()).push(t);for(var p=0;p<a.length-1;p++)i=a[p][d],s._markNodeAsNonRenderable(i),c[i]=c[i]||[],o=(r=a[p+1])[d],s._markNodeAsNonRenderable(o),c[o]=c[o]||[],-1===c[i].indexOf(r)&&c[i].unshift(r)}return c},_clearRenderMap:function(){this._skipRenderingMap={}},_dataToRender:function(e){var t=this;return t._isPageable()?t.dataSource._pageableRootNodes(e):t.dataSource.rootNodes()},_markNodeAsNonRenderable:function(e){this._skipRenderingMap[e]=!0},_adjustRowsHeight:function(e,t){if(this._hasLockedColumns){var n,i=e[0].rows,r=i.length,o=t[0].rows,a=e.add(t),s=a.length,l=[];for(n=0;n<r&&o[n];n++)i[n].style.height&&(i[n].style.height=o[n].style.height="");for(n=0;n<r&&o[n];n++){var c=i[n].offsetHeight,d=o[n].offsetHeight,u=0;c>d?u=c:c<d&&(u=d),l.push(u)}for(n=0;n<s;n++)a[n].style.display="none";for(n=0;n<r;n++)l[n]&&(i[n].style.height=o[n].style.height=l[n]+1+"px");for(n=0;n<s;n++)a[n].style.display=""}},_ths:function(t,n){for(var i,r,l,c,d,u,h,p,f=[],m=0,g=t.length;m<g;m++){if(i=t[m],l=[],c=[Pe.header],i.selectable){p=it(t),h=T(i,p),d={scope:"col",role:"columnheader",className:c.join(" ")},i.headerTemplate&&(r=i.headerTemplate({})),r=i.headerTemplate?r:kendo.template((()=>Se))({}),n&&!i.colSpan&&(d.rowSpan=n),h>-1&&(d[kendo.attr("index")]=h),l.push(s(r)),f.push(o("th",e.extend(!0,{},d,i.headerAttributes),l));continue}if(r=i.headerTemplate?i.headerTemplate({}):i.title||i.field||"",u=i.headerTemplate?s(r):a(r),this.options.sortable?i.draggable||l.push(o("span",{className:Pe.headerCellInner},[o("span",{className:Pe.link},[o("span",{className:Pe.columnTitle},[u])])])):l.push(u),d={"data-field":i.field,"data-title":i.title,style:!0===i.hidden?{display:"none"}:{},className:c.join(" "),role:"columnheader"},this.options.sortable&&!1!==i.sortable){let e=`${i.title||i.field}. ${this.options.messages.sortHeader}`;d["aria-label"]=e,d.title=e}i.columns||(d.rowSpan=n||1),i.headerAttributes&&(1===i.headerAttributes.colSpan&&delete i.headerAttributes.colSpan,i.headerAttributes.class&&(d.className+=" "+i.headerAttributes.class)),i["data-index"]>-1&&(d["data-index"]=i["data-index"]);let g={...i.headerAttributes};delete g.class,d=x(!0,{},d,g),f.push(o("th",d,l))}return f},_cols:function(e){for(var t,n,i=[],r=0;r<e.length;r++)!0!==e[r].hidden&&(n={},(t=e[r].width)&&0!==parseInt(t,10)&&(n.style={width:"string"==typeof t?t:t+"px"}),e[r].draggable&&(n.class="k-drag-col"),i.push(o("col",n)));return i},_clearColsCache:function(){this._headerColsTree.render([]),this.options.scrollable&&this._contentColsTree.render([]),this._hasLockedColumns&&(this._lockedHeaderColsTree.render([]),this._lockedContentColsTree.render([]))},_renderCols:function(){var e=_t(this.columns);this.options.hasHeader&&this._headerColsTree.render(this._cols(it(e))),this.options.scrollable&&this._contentColsTree.render(this._cols(it(e))),this._hasLockedColumns&&(e=vt(this.columns),this.options.hasHeader&&this._lockedHeaderColsTree.render(this._cols(it(e))),this._lockedContentColsTree.render(this._cols(it(e))),this.options.hasHeader||this._applyLockedContainersWidth())},_retrieveFirstColumn:function(t,n){var i=e();if(n.length&&t[0]){for(var r=t[0];r.columns&&r.columns.length;)r=r.columns[0],n=n.filter(":not(:first)");i=i.add(n)}return i},_updateFirstColumnClass:function(){var t,n=this,i=n.columns||[],r=n.thead.find(">tr:not(:first, .k-filter-row)");i=_t(i),t=n._retrieveFirstColumn(i,r),n.lockedHeader&&(r=n.lockedHeader.find("thead>tr:not(.k-filter-row):not(:first)"),i=vt(n.columns),t=t.add(n._retrieveFirstColumn(i,r))),t.each((function(){var t=e(this).find("th");t.removeClass("k-first"),t.eq(0).addClass("k-first")}))},_updateRowSpans:function(e){for(var t=e.length-1;t>=0;t--){rt(e[t].cells).length>0&&(e[t].rowSpan=e.length-t)}},_setColumnDataIndexes:function(e){for(var t=0;t<e.length;t++)e[t]["data-index"]=t},_updateColumnCellIndex:function(){var e=0;this.lockedHeader&&(e=mt(this.lockedHeader.find("thead"),vt(this.columns))),mt(this.thead,_t(this.columns),e)},_setParentsVisibility:function(e,t){var n,i,r=[],o=t?function(e){return ot(e.columns).length&&e.hidden}:function(e){return!ot(e.columns).length&&!e.hidden};if(ht(e,this.columns,r)&&r.length)for(n=r.length-1;n>=0;n--)o(i=r[n])&&(i.hidden=!t)},_prepareColumns:function(t,n,i,r,o){for(var a=r||t[t.length-1],s=t[a.index+1],l=0,c=0;c<n.length;c++){var d=e.extend({},n[c],{headerAttributes:n[c].headerAttributes||{}});a.cells.push(d),n[c].columns&&n[c].columns.length&&(s||(s={rowSpan:0,cells:[],index:t.length},t.push(s)),n[c].columns.length&&(d.headerAttributes.colSpan=rt(n[c].columns).length||1,d.headerAttributes["data-colspan"]=it(n[c].columns).length),this._prepareColumns(t,n[c].columns,d,s,n[c]),d.hidden||(l+=d.headerAttributes.colSpan-1),a.rowSpan=t.length-a.index),n[c].rowIndex=a.index,o&&(n[c].parentColumn=o),n[c].cellIndex=a.cells.length-1}i&&(i.headerAttributes.colSpan+=l)},_renderHeaderTree:function(e,t,n){var i,r=[],a=[],s=[];if(n)for(r=[{rowSpan:1,cells:[],index:0}],this._prepareColumns(r,t),this._updateRowSpans(r),i=0;i<r.length;i++)a.push(o("tr",{role:"row",class:"k-table-row"},this._ths(r[i].cells,r[i].rowSpan)));else a.push(o("tr",{role:"row",class:"k-table-row"},this._ths(t)));this._hasFilterRow()&&(this._filterThs(t,s),a.push(o("tr",{class:"k-filter-row k-table-row"},s))),e.render(a)},_renderHeader:function(){var e=_t(this.columns),n=S(this.columns,(function(e){return e.columns!==t})).length>0;this._setColumnDataIndexes(it(this.columns)),this._renderHeaderTree(this._headerTree,e,n),this._hasLockedColumns&&(e=vt(this.columns),this._renderHeaderTree(this._lockedHeaderTree,e,n),this._applyLockedContainersWidth(),this._syncLockedHeaderHeight()),this._updateFirstColumnClass()},_filterThs:function(e,t){for(var n,i,r=kendo.attr("uid"),a=0,s=e.length;a<s;a++)(n=e[a]).columns&&this._filterThs(n.columns,t),n.columns&&n.columns.length||((i={style:!0===n.hidden?{display:"none"}:{},className:"k-table-th k-header",title:this.options.messages.filterCellTitle,"aria-label":this.options.messages.filterCellTitle})[r]=n.headerAttributes.id,t.push(o("th",i)))},_updateFilterThs:function(t,n,i){var r,o,a=it([n]),s=e(this.lockedHeader).add(this.thead).find("tr.k-filter-row th"),l=kendo.attr("uid");function c(e,t){for(var n=0;n<e.length;n++)if(e.eq(n).attr(l)===t)return n}for(var d=a.length-1;d>=0;d--)o=c(s,(n=a[d]).headerAttributes.id),r=c(s,i.headerAttributes.id),s.eq(o)[t?"insertBefore":"insertAfter"](s.eq(r))},_applyLockedContainersWidth:function(){if(this._hasLockedColumns){var e=this.options.hasHeader?Ge(this.lockedHeader.find(">table>colgroup>col")):Ge(this.lockedTable.find(">colgroup>col")),t=this.options.hasHeader?this.thead.parent():this.tbody.parent(),n=Ge(t.find(">colgroup>col")),i=this.wrapper[0].clientWidth,r=kendo.support.scrollbar();e>=i&&(e=i-3*r),this.lockedHeader.add(this.lockedContent).width(e),t.add(this.table).width(n);var o=i-e;this.content.width(o-1),t.parent().width(o-r-2)}},_generateRowOptions:function(e,t,n,i,r,o){return{model:e,attr:t,level:n?this._renderedModelLevel(e,i):r,editedColumn:i.editedColumn,editedColumnIndex:i.editedColumnIndex,hasChildren:o,visible:i.visible,isAlt:this._absoluteIndex%2==0}},_renderRow:function(e,t,n){return this._tds(e,t,n)},_trs:function(t){var n,i,r,o,a,s,l,c,d=this,u=[],h=t.level,p=t.data,f=this.dataSource,m=f.aggregates()||{},g=f._modelIdField(),v=f._modelParentIdField(),_=t.columns,b=d._isPageable(),y=t.isLockedTable,w=t.childrenMap||f.childrenMap(f._getData());for(s=0,l=p.length;s<l;s++){if(r=["k-table-row"],c=(n=p[s])[g],o=(a=b?w[c]:n.loaded()?f.childNodes(n):[])&&a.length,(i={role:"row"})[kendo.attr("uid")]=n.uid,!y&&o&&(i["aria-expanded"]=!!n.expanded),t.visible?(!b||b&&!d._skipRenderingMap[c])&&(this._absoluteIndex%2!=0&&r.push(Pe.alt),this._absoluteIndex++):i.style={display:"none"},e.inArray(n.uid,t.selected)>=0&&r.push(Pe.selected),o&&r.push(Pe.group),n._edit&&r.push("k-grid-edit-row"),i.className=r.join(" "),!d._skipRenderingMap[c]){var k,x=d._generateRowOptions(n,i,b,t,h,o);k=d.options.rowTemplate?this._trFromTemplate(x):this._renderRow(x,_,this._td.bind(this)),u.push(k)}if(o&&(d.options.renderAllRows||n.expanded)){if(b&&(a=(t.viewChildrenMap||{})[c]||[]),0===a.length)continue;u=u.concat(this._trs({columns:_,editedColumn:t.editedColumn,editedColumnIndex:t.editedColumnIndex,aggregates:m,selected:t.selected,visible:b?t.visible:t.visible&&!!n.expanded,data:a,childrenMap:t.childrenMap||w,hasFooterTemplate:t.hasFooterTemplate,viewChildrenMap:t.viewChildrenMap,level:h+1,isLockedTable:t.isLockedTable}))}}return t.hasFooterTemplate&&n&&(i={className:Pe.footerTemplate+" k-table-row","data-parentId":n[v]},t.visible||(i.style={display:"none"}),u.push(this._tds({model:m[n[v]],attr:i,level:h,editedColumn:t.editedColumn,editedColumnIndex:t.editedColumnIndex},_,this._footerId))),u},_trFromTemplate:function(t){var n,i=this.options.rowTemplate,r=this.options.altRowTemplate;return r=r||i,kendo.isFunction(i)||(i=kendo.template(i)),kendo.isFunction(r)||(r=kendo.template(r)),n=this._absoluteIndex%2!=0?i(t):r(t),e(n).length?this.parseRowTemplate(e(n)[0],t):a(n)},parseRowTemplate:function(t,n){var i,r=t.nodeName.toLocaleLowerCase(),s=t.childNodes,l=[];i=this.parseAttributes(t);for(var c=0;c<s.length;c++)/\S/.test(s[c].nodeValue)&&"td"===s[c].nodeName.toLocaleLowerCase()&&l.push(this._createCellElement(s[c]));return n&&!n.visible&&(i.style=i.style||{},i.style=e.extend(!0,i.style,{display:"none"})),this._isTextNode(r)?a(t.nodeValue):o(r,i,l)},_createCellElement:function(t){for(var n=this.parseAttributes(t),i=e(t).find("."+Pe.iconHidden).remove(),r=e(t).find(Me).remove()[0],a=[],l=0;l<i.length;l++)a.push(o("span",this.parseAttributes(i[l])));return r&&a.push(s(r.outerHTML,!0)),a.push(s(e(t).html())),o("td",n,a)},parseAttributes:function(t){if(this._isTextNode(t.nodeName))return null;for(var n=(t=e(t)[0]).attributes,i=n.length,r={},o=0;o<i;o++)r[n[o].name]=n[o].value;return r},_isTextNode:function(e){return e.indexOf("text")>=0},_footerId:function(t){var n=[],i=t.column,r=t.column.footerTemplate||e.noop,a=t.model[i.field]||{},l={role:"gridcell",class:"k-table-td",style:!0===i.hidden?{display:"none"}:{}};return i.expandable&&(n=n.concat(qe({level:t.level+1,className:Pe.iconPlaceHolder}))),i.attributes&&x(!0,l,i.attributes,{style:!0===i.hidden?{display:"none"}:{}}),n.push(s(r(a)||"")),o("td",l,n)},_hasFooterTemplate:function(){return!!S(it(this.columns),(function(e){return e.footerTemplate})).length},_tds:function(e,t,n){for(var i,r=[],a=(e.editedColumn||{}).field,s=this._isIncellEditable(),l=t.length,c=0;c<l;c++){i=t[c];var d=n({model:e.model,column:i,editColumn:!s||s&&i.field===a&&e.editedColumnIndex===c,level:e.level});r.push(d)}return o("tr",e.attr,r)},_td:function(t){var n,i=[],r=t.model,a=t.column,l=kendo.defaults.iconType,c={role:"gridcell",class:"k-table-td",style:!0===a.hidden?{display:"none"}:{}},d=this._isIncellEditable(),u=!1;return a.attributes&&x(!0,c,a.attributes),a.headerAttributes&&a.headerAttributes.id&&(c["aria-describedby"]=a.headerAttributes.id),r._edit&&a.field&&t.editColumn&&(d||!d&&kt(a,r))?(c[kendo.attr("container-for")]=a.field,d&&(c.className&&-1!==c.className.indexOf(Pe.editCell)?c.className+=" k-table-td"+Pe.editCell:c.className||(c.className="k-table-td "+Pe.editCell))):(a.expandable&&(i=qe({level:t.level,className:Pe.iconPlaceHolder}),r.hasChildren?(c.ariaExpanded=r.expanded,n=r.expanded?Pe.iconCollapse:Pe.iconExpand):n=Pe.iconPlaceHolder,r._error?n=Pe.refresh:!r.loaded()&&r.expanded&&(n="loading",c["aria-busy"]=!0),i.push(s(kendo.ui.icon(e(`<span ref-treelist-expand-collapse-icon ${n===Pe.iconPlaceHolder?"ref-blank-icon":""} class="k-treelist-toggle ${n===Pe.iconPlaceHolder?"":"loading"===n?"k-i-loading":""}"></span>`),{icon:n,type:l}),!0)),c.style["white-space"]="nowrap"),function(e,t){var n=(e||{}).field||"";return t.dirty&&t.dirtyFields&&t.dirtyFields[n]&&kt(e,t)}(a,r)&&(c.className?c.className+=Pe.dirtyCell:c.className||(c.className=Pe.dirtyCell)),a.draggable&&(c.class+=" k-drag-cell k-touch-action-none",void 0===c[Ee]&&(c[Ee]=this.options.messages.dragHandleLabel),c.style.cursor="move"),a.command?(c.className&&-1!==c.className.indexOf("k-command-cell")?c.className+=" k-command-cell":c.className||(c.className="k-command-cell"),u=S(a.command,(function(e){return e===B||e.name===B})).length>0,i=r._edit&&!this._isIncellEditable()&&u?this._buildCommands(["update","canceledit"]):this._buildCommands(a.command)):i.push(this._cellContent(a,r)),c.className=[c.class,c.className].join(" ").trim()),o("td",c,i)},_cellContent:function(e,t){var n,i,r=this._isIncellEditable();return e.selectable?s(Ce):e.draggable?s(kendo.ui.icon("reorder")):(e.template?n=this._evalColumnTemplate(e,t):e.field?(n=t.get(e.field),i=r?e.dirtyIndicatorTemplate(t):"",null===n||xt(n)?n=i:(e.format&&(n=kendo.format(e.format,n)),n=i+n)):(null===n||xt(n))&&(n=""),e.template||!e.encoded||r?s(n):a(n))},_evalColumnTemplate:function(e,t){return this._isIncellEditable()?e.dirtyCellTemplate(t):e.template(t)},_createDirtyColumnTemplate:function(e){var t=this,n=t._customTemplateSettings();return _((function(n){return t._dirtyIndicatorTemplate(e.field)(n)+this.columnTemplate(n)}),n).bind({columnTemplate:e.template})},_createIndicatorTemplate:function(e){var t=this._dirtyIndicatorTemplate(e.field);return _(t)},_dirtyIndicatorTemplate:function(e){var t=this._customTemplateSettings().paramName;return e&&t?({dirty:t,dirtyFields:n})=>t&&n&&n[e]?'<span class="k-dirty"></span>':"":()=>""},_customTemplateSettings:function(){return x({},kendo.Template,this.options.templateSettings)},_buildCommands:function(e,t){var n,i=[];for(n=0;n<e.length;n++)i.push(this._handleCommand(e[n],t));return i},_handleCommand:function(e,t){var n=(e.name||e).toLowerCase(),i=this.options.messages.commands[n];return(e=x({},He[n],{text:i},e)).template?s(kendo.template(e.template)({message:e.text||this.options.messages.commands.search})):this._button(e,n,e.icon,t)},_button:function(e,t,n,i){if(e.className&&e.className.indexOf("k-primary")>-1&&(e.className=e.className.replace("k-primary","k-button-solid-primary")),e.className&&-1!==e.className.indexOf("k-button-solid-primary")||(e.className=(e.className||"")+" k-button-solid-base"),i&&e.className){let t=e.className.split(" ");e.className=t.filter((e=>-1===e.indexOf("command"))).join(" ")}let r='<button data-command="'+t+'" class="'+e.className+'">'+(e.text||(""===e.text?"":e.name))+"</button>";return s(kendo.html.renderButton(r,{icon:n,iconClass:e.imageClass}))},_positionResizeHandle:function(t){var n,i,r,o,a,s,c,u=e(t.currentTarget),h=this.resizeHandle,p=u.position(),f=0,m=l(u),g=u.closest("div"),_=void 0!==t.buttons?t.buttons:t.which||t.button,b=this.options.columnResizeHandleWidth||3,y=3*b/2;if(n=m,void 0===_||0===_){h||(h=this.resizeHandle=e('<div class="k-resize-handle"><div class="k-resize-handle-inner"></div></div>'));var w=je(u.closest("thead")).filter(":visible");if(we)c=kendo.scrollLeft(g),(v.mozilla||v.webkit&&v.version>=85)&&(c*=-1),s=parseFloat(g.css("borderLeftWidth")),f=(n=u.offset().left+c-parseFloat(u.css("marginLeft"))-(g.offset().left+s))<=c?y:0,a=(i=u.closest(".k-grid-header-wrap, .k-grid-header-locked"))[0].scrollWidth-i[0].offsetWidth,o=parseFloat(i.css("marginLeft")),r=v.msie?2*kendo.scrollLeft(i)+s-o-f:0,n-=(v.webkit&&v.version<85?a-f-o+s:-f)+(v.mozilla?s-o-f:0)+r;else for(var k=0;k<w.length&&w[k]!=u[0];k++)n+=w[k].offsetWidth;g.append(h),h.show().css({top:p.top,left:n-y,height:d(u),width:3*b}).data("th",u);var x=this;h.off("dblclick"+F).on("dblclick"+F,(function(){var t=u.index();e.contains(x.thead[0],u[0])&&(t+=S(x.columns,(function(e){return e.locked&&!e.hidden})).length),x.autoFitColumn(t)}))}},autoFitColumn:function(t){var n,i,r,o,a,s=this,c=s.options,d=s.columns,u=s.lockedHeader?je(s.lockedHeader.find(">table>thead")).filter(Ue).length:0;if((t="number"==typeof t?d[t]:D(t)?S(d,(function(e){return e===t}))[0]:S(d,(function(e){return e.field===t}))[0])&&!t.hidden){n=T(t,d),i=(r=(o=t.locked)?s.lockedHeader.children("table"):s.thead.parent()).find("[data-index='"+n+"']");var h=o?s.lockedTable:s.table,p=s.footer||e();s.footer&&s.lockedContent&&(p=o?s.footer.children(".k-grid-footer-locked"):s.footer.children(".k-grid-footer-wrap"));var f=p.find("table").first();s.lockedHeader&&u>=n&&!o&&(n-=u);for(var m=0;m<d.length&&d[m]!==t;m++)d[m].hidden&&n--;a=c.scrollable?r.find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(n).add(h.children("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(n)).add(f.find("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(n)):h.children("colgroup").find("col:not(.k-group-col):not(.k-hierarchy-col)").eq(n);var g=r.add(h).add(f),v=l(i);a.width(""),g.css("table-layout","fixed"),a.width("auto"),g.addClass("k-autofitting"),g.css("table-layout","");var _=Math.ceil(Math.max(l(i),l(h.find("tr").eq(0).children("td:visible").eq(n)),l(f.find("tr").eq(0).children("td:visible").eq(n))));if(a.width(_),t.width=_,c.scrollable){for(var b,y=r.find("col"),w=0,k=0,x=y.length;k<x;k+=1){if(!(b=y[k].style.width)||-1!=b.indexOf("%")){w=0;break}w+=parseInt(b,10)}w&&g.each((function(){this.style.width=w+"px"}))}g.removeClass("k-autofitting"),s.trigger(ie,{column:t,oldWidth:v,newWidth:_}),s._applyLockedContainersWidth(),s._syncLockedContentHeight(),s._syncLockedHeaderHeight()}},_adjustLockedHorizontalScrollBar:function(){var e=this.table,t=e.parent(),n=e[0].offsetWidth>t[0].clientWidth?kendo.support.scrollbar():0;this.lockedContent.height(d(t)-n)},_syncLockedContentHeight:function(){this.lockedTable&&(this._touchScroller||this._adjustLockedHorizontalScrollBar(),this._adjustRowsHeight(this.table,this.lockedTable),this._syncLockedScroll())},_syncLockedHeaderHeight:function(){if(this.lockedHeader){var e=this.lockedHeader.children("table"),t=this.thead.parent();this._adjustRowsHeight(e,t),function(e,t){if(e=e[0],t=t[0],e.rows.length&&t.rows.length&&e.rows.length!==t.rows.length){var n,i,r=e.offsetHeight,o=t.offsetHeight;r>o?(n=t.rows[t.rows.length-1],Ae.test(n.className)&&(n=t.rows[t.rows.length-2]),i=r-o):(n=e.rows[e.rows.length-1],Ae.test(n.className)&&(n=e.rows[e.rows.length-2]),i=o-r),n.style.height=n.offsetHeight+i+"px"}}(e,t)}},_syncLockedScroll:function(){this.options.scrollable&&(this.lockedContent[0].scrollTop=this.content[0].scrollTop)},_resizable:function(){if(this.options.resizable){this.resizable&&this.resizable.destroy();var t=this;e(this.lockedHeader).find("thead").add(this.thead).on("mousemove"+F,"tr:not(.k-filter-row) > th",this._positionResizeHandle.bind(this)),this.resizable=new kendo.ui.Resizable(this.wrapper,{handle:".k-resize-handle",start:function(n){var i,r,o=e(n.currentTarget).data("th"),a=e.inArray(o[0],je(o.closest("thead")).filter(":visible"));t.wrapper.addClass("k-grid-column-resizing"),t.lockedHeader&&e.contains(t.lockedHeader[0],o[0])?(i=t.lockedHeader,r=t.lockedTable):(i=t.thead.parent(),r=t.table),this.col=r.children("colgroup").find("col").eq(a).add(i.find("col").eq(a)),this.th=o,this.startLocation=n.x.location,this.columnWidth=l(o),this.table=this.col.closest("table"),this.totalWidth=this.table.width()},resize:function(e){var t=we?-1:1,n=e.x.location*t-this.startLocation*t;this.columnWidth+n<11&&(n=11-this.columnWidth),this.table.width(this.totalWidth+n),this.col.width(this.columnWidth+n)},resizeend:function(){t.wrapper.removeClass("k-grid-column-resizing");var e=this.th.attr("data-field"),n=S(it(t.columns),(function(t){return t.field==e})),i=Math.floor(l(this.th));n[0].width=i,t._resize(),t._syncLockedContentHeight(),t._syncLockedHeaderHeight(),t.trigger(ie,{column:n,oldWidth:this.columnWidth,newWidth:i}),this.table=this.col=this.th=null}})}},_sortable:function(){var n,i,r,o,a,s,l,c=this.options.sortable,d=S(this.columns,(function(e){return e.columns!==t})).length>0,u=this._sort.bind(this);if(c)for(o=d?this.lockedHeader?We(je(this.lockedHeader.find(">table>thead")).add(je(this.thead))):je(this.thead):e(this.lockedHeader).add(this.thead).find("tr:not(.k-filter-row) th"),n=it(this.columns),s=0,l=o.length;s<l;s++)!1===(i=n[s]).sortable||i.command||i.draggable||!i.field||i.selectable||((r=(a=o.eq(s)).data("kendoColumnSorter"))&&r.destroy(),a.kendoColumnSorter(x({},c,i.sortable,{dataSource:this.dataSource,change:u})))},_filterable:function(){var n,i,r,o,a,s,l,c=this.options.filterable,d=S(this.columns,(function(e){return e.columns!==t})).length>0;if(c&&!this.options.columnMenu){var u=function(e){this.trigger(Z,{field:e.field,container:e.container})}.bind(this),h=function(e){this.trigger(J,{field:e.field,container:e.container})}.bind(this),p=this._filter.bind(this);if(n=d?this.lockedHeader?je(this.lockedHeader.find(">table>thead").add(this.thead)):je(this.thead):e(this.lockedHeader).add(this.thead).find("tr:not(.k-filter-row) th"),o=it(this.columns),c&&typeof c.mode==M&&-1==c.mode.indexOf("menu")&&(c=!1),c)for(i=0,r=n.length;i<r;i++)a=o[i],(l=(s=n.eq(i)).data("kendoFilterMenu"))&&l.destroy(),a.draggable||a.command||!1===a.filterable||a.selectable||s.kendoFilterMenu(x(!0,{},c,a.filterable,{dataSource:this.dataSource,init:u,open:h,change:p,appendTo:H+Pe.headerCellInner}))}},_filterRow:function(){var t=this;if(t._hasFilterRow()){for(var n,i,r=kendo.attr("uid"),o=it(t.columns),a=t.options.filterable,s=this._filter.bind(this),l=0;l<o.length;l++){var c,d=o[l],u=t.options.filterable.operators,h=!1,f=this.wrapper.find(".k-grid-header .k-filter-row th["+r+'="'+d.headerAttributes.id+'"]'),m=d.field,g=d.parentColumn;if(delete d.parentColumn,m&&!1!==d.filterable){var v=d.filterable&&d.filterable.cell||{};(i=f.find(".k-filtercell").data("kendoFilterCell"))&&(i.destroy(),f.empty()),(c=t.options.dataSource)instanceof p&&(c=t.options.dataSource.options);var _=x(!0,{},a.messages);if(d.filterable&&x(!0,_,d.filterable.messages),!1===v.enabled){f.html("&nbsp;");continue}v.dataSource&&(c=v.dataSource,h=!0),d.filterable&&d.filterable.operators&&(u=d.filterable.operators),n={column:d,dataSource:t.dataSource,suggestDataSource:c,customDataSource:h,field:m,messages:_,values:d.values,template:v.template,delay:v.delay,inputWidth:v.inputWidth,suggestionOperator:v.suggestionOperator,minLength:v.minLength,dataTextField:v.dataTextField,operator:v.operator,operators:u,showOperators:v.showOperators,change:s},e("<span/>").attr(kendo.attr("field"),m).appendTo(f).kendoFilterCell(n),d.parentColumn=g}else f.html("&nbsp;")}this._filterFocusable().attr(X,-1)}},_hasFilterRow:function(){var t=this.options.filterable,n=t&&typeof t.mode==M&&-1!=t.mode.indexOf("row"),i=this.columns,r=e.grep(i,(function(e){return!1===e.filterable}));return i.length&&r.length==i.length&&(n=!1),n},_change:function(){var e,t=this;t._checkBoxSelection&&(e=t.selectable.value(),t._uncheckCheckBoxes(),t._checkRows(e),e.length&&e.length===t.items().length?t._toggleHeaderCheckState(!0):t._toggleHeaderCheckState(!1)),this.trigger(E)},_isLocked:function(){return null!==this.lockedHeader},_selectable:function(){var n,i,r,o,a=this,s=this.options.selectable,l=this.table,d=a._isLocked();s&&(s=kendo.ui.Selectable.parseOptions(s),this._hasLockedColumns&&(l=l.add(this.lockedTable),i=s.multiple&&s.cell),n=">tbody>tr:not(.k-footer-template)",s.cell&&(n+=">td"),this.selectable=new kendo.ui.Selectable(l,{filter:n,aria:!0,multiple:s.multiple,change:this._change.bind(this),useAllItems:i,continuousItems:this._continuousItems.bind(this,n,s.cell),relatedTarget:!s.cell&&this._hasLockedColumns?this._selectableTarget.bind(this):t}),a.options.navigatable&&(r=s.multiple,o=s.cell,l.on("keydown"+F,(function(t){var n=a.current();if(n){var i=t.target;if(t.keyCode===c.SPACEBAR&&!t.shiftKey&&e.inArray(i,l)>-1&&!n.is(".k-header")){if(t.preventDefault(),t.stopPropagation(),n=o?n:n.parent(),d&&!o&&(n=n.add(a._relatedRow(n))),r)if(t.ctrlKey){if(n.hasClass(Pe.selected))return n.removeClass(Pe.selected),void a.trigger(E)}else a.selectable.clear();else a.selectable.clear();o||(a.selectable._lastActive=n),a.selectable.value(n),a.trigger(E)}else!o&&(t.shiftKey&&t.keyCode==c.LEFT||t.shiftKey&&t.keyCode==c.RIGHT||t.shiftKey&&t.keyCode==c.UP||t.shiftKey&&t.keyCode==c.DOWN||t.keyCode===c.SPACEBAR&&t.shiftKey)&&(t.preventDefault(),t.stopPropagation(),n=n.parent(),d&&(n=n.add(a._relatedRow(n))),r?(a.selectable._lastActive||(a.selectable._lastActive=n),a.selectable.selectRange(a.selectable._firstSelectee(),n)):(a.selectable.clear(),a.selectable.value(n)),a.trigger(E))}}))))},_continuousItems:function(t,n){if(this.lockedContent){for(var i=e(t,this.lockedTable),r=e(t,this.table),o=n?vt(this.columns).length:1,a=n?this.columns.length-o:1,s=[],l=0;l<i.length;l+=o)A.apply(s,i.slice(l,l+o)),A.apply(s,r.splice(0,a));return s}},_selectableTarget:function(t){for(var n,i=e(),r=0,o=t.length;r<o;r++)n=this._relatedRow(t[r]),T(n[0],t)<0&&(i=i.add(n));return i},_relatedRow:function(t){var n=this.lockedTable;if(t=e(t),!n)return t;var i=t.closest(this.table.add(this.lockedTable)),r=i.find(">tbody>tr").index(t);return(i=i[0]===this.table[0]?n:this.table).find(">tbody>tr").eq(r)},select:function(t){var n=this,i=this.selectable;return n._checkBoxSelection?(t&&(n._checkRows(t),n.select().length===n.items().length&&n._toggleHeaderCheckState(!0)),n.items().filter("."+Te)):i?(void 0!==t&&(i.options.multiple||(i.clear(),t=t.first()),this._hasLockedColumns&&(t=t.add(e.map(t,this._relatedRow.bind(this))))),i.value(t)):e()},clearSelection:function(){var e=this;e.selectable&&!e._checkBoxSelection&&e.selectable.clear(),e._checkBoxSelection&&e._deselectCheckRows(e.select(),!0)},_uncheckCheckBoxes:function(){this.table.add(this.lockedTable).find("tbody "+xe).attr("aria-checked",!1).prop("checked",!1).attr("aria-label","Select row")},_deselectCheckRows:function(t,n){var i=this;t=i.table.add(i.lockedTable).find(t),i._isLocked()&&(t=t.add(t.map((function(){return i._relatedRow(this)})))),t.each((function(){e(this).removeClass(Te).find(xe).attr("aria-checked",!1).prop("checked",!1).attr("aria-label","Select row")})),i._toggleHeaderCheckState(!1),n||i.trigger(E)},_headerCheckboxClick:function(t){var n=this,i=e(t.target),r=i.prop("checked"),o=i.closest(".k-grid").getKendoTreeList();n===o&&(r?n.select(o.items()):n.clearSelection(),n.trigger(E))},_checkboxClick:function(t){var n=this,i=e(t.target).closest("tr"),r=!i.hasClass(Te),o=n.dataItem(i),a=[],s="";if(n===i.closest(".k-grid").getKendoTreeList()){if(n._includeChildren){n.dataSource.allChildNodes(o,a);for(var l=0;l<a.length;l++)s+="tr[data-uid='"+a[l].uid+"'],"}s+="tr[data-uid='"+o.uid+"']",i=e(s),r?(n.select(i),n.trigger(E)):n._deselectCheckRows(i)}},_checkRows:function(t){t.each((function(){e(this).addClass(Te).find(xe).prop("checked",!0).attr("aria-label","Deselect row").attr("aria-checked",!0)}))},_toggleHeaderCheckState:function(e){var t=this;e?t.thead.add(t.lockedHeader).find("tr "+xe).prop("checked",!0).attr("aria-checked",!0).attr("aria-label","Deselect all rows"):t.thead.add(t.lockedHeader).find("tr "+xe).prop("checked",!1).attr("aria-checked",!1).attr("aria-label","Select all rows")},_dataSource:function(e){var n=this,i=this.dataSource,r=n.options.pageable;i&&(i.unbind(E,this._refreshHandler),i.unbind(z,this._errorHandler),i.unbind(de,this._sortHandler),i.unbind(P,this._progressHandler)),this._refreshHandler=this.refresh.bind(this),this._errorHandler=this._error.bind(this),this._sortHandler=this._clearSortClasses.bind(this),this._progressHandler=this._progress.bind(this),D(e)&&(x(e,{table:n.table,fields:n.columns}),D(r)&&r.pageSize!==t&&(e.pageSize=r.pageSize)),i=this.dataSource=$e.create(e),r&&(i._collapsedTotal=t),i.bind(E,this._refreshHandler),i.bind(z,this._errorHandler),i.bind(de,this._sortHandler),i.bind(P,this._progressHandler),this._dataSourceFetchProxy=function(){this.dataSource.fetch()}.bind(this)},setDataSource:function(e){this._dataSource(e),this._sortable(),this._filterable(),this._filterRow(),this._columnMenu(),this._pageable(),this._contentTree.render([]),this.options.autoBind&&this.dataSource.fetch()},dataItem:function(t){if(t instanceof Oe)return t;var n=e(t).closest("tr").attr(kendo.attr("uid"));return xt(n)?null:this.dataSource.getByUid(n)},editRow:function(e){var t,n=this;!this._isIncellEditable()&&this.options.editable&&(typeof e===M&&(e=this.tbody.find(e)),(t=n._isPageable()&&n._isPopupEditable()&&e instanceof Oe?e:this.dataItem(e))&&(n.editor?(t._edit=!0,this._render(),this._cancelEditor()):n._preventPageSizeRestore=!1,"popup"!=this._editMode()&&(t._edit=!0),this.trigger(L,{model:t})?n.dataSource._restorePageSizeAfterAddChild():(this._render(),this._createEditor(t),this.trigger(B,{container:this.editor.wrapper,model:t}))))},_cancelEdit:function(t){var n;this.editor&&(t=x(t,{container:this.editor.wrapper,model:this.editor.model}),this.trigger(Q,t)||(this.options.navigatable&&(n=this.items().index(e(this.current()).parent())),this.cancelRow(),this.options.navigatable&&(this._setCurrent(this.items().eq(n).children().filter(ve).first()),wt(this.table,!0))))},cancelRow:function(){this._isIncellEditable()||(this._cancelEditor(),this._render())},saveRow:function(){var e,t=this.editor;this._isIncellEditable()||t&&(e={model:t.model,container:t.wrapper},t.end()&&!this.trigger(V,e)&&this.dataSource.sync())},addRow:function(e){var t=this,n=t.dataSource,i=t._isPageable(),r=t._isIncellEditable(),o=t._isInlineEditable(),a=this.editor,s=0,l={};if((!a||a.end())&&this.options.editable)return e?(e instanceof Oe||(e=this.dataItem(e)),l[e.parentIdField]=e.id,s=this.dataSource.indexOf(e)+1,void this.expand(e).then((function(){var a=i&&n._isLastItemInView(e)&&(r||o);t._insertAt(l,s,a)}))):void this._insertAt(l,s)},_insertAt:function(e,t,n){var i=this,r=i.dataSource;e=i.dataSource.insert(t,e),n&&r._setAddChildPageSize();var o,a=this._itemFor(e);i._isIncellEditable()?(o=a.children("td").eq(i._firstEditableColumnIndex(a)),i.editCell(o)):a&&a[0]?i.editRow(a):(i._isPageable()||i.dataSource.filter())&&(i._isPopupEditable()||i._isInlineEditable())&&i.editRow(e)},_firstEditableColumnIndex:function(e){var t,n,i=this.dataItem(e),r=it(this.columns),o=r.length;for(n=0;n<o;n++)if(t=r[n],i&&(!i.editable||i.editable(t.field))&&!t.command&&!t.draggable&&t.field&&!0!==t.hidden)return n;return-1},removeRow:function(t){var n=this.dataItem(t),i={model:n,row:t};this.options.editable&&n&&!this.trigger(j,i)&&(document.activeElement===e(t).find(".k-grid-delete")[0]&&e(t).find(".k-grid-delete").trigger("blur"),this.dataSource.remove(n),this._isIncellEditable()||this.dataSource.sync())},_cancelEditor:function(){var e,t=this,n=t.editor;n&&(e=n.model,t._destroyEditor(),t._isIncellEditable()?t._shouldRestorePageSize()&&t.dataSource._restorePageSizeAfterAddChild():t.dataSource.cancelChanges(e),e._edit=!1),t._preventPageSizeRestore=!1},_shouldRestorePageSize:function(){var e=this;return e._isPageable()&&e._isIncellEditable()&&!e._preventPageSizeRestore},_destroyEditor:function(){this.editor&&(this.editor.close(),this.editor=null)},_createEditor:function(e){let t=this.itemFor(e),n=it(this.columns),i=[],r=this;for(var o=0;o<n.length;o++)i.push(x({},n[o])),delete i[o].parentColumn;t=t.add(this._relatedRow(t));let a=this._editMode(),s={columns:i,model:e,target:this,clearContainer:!1,template:this.options.editable.template};if("inline"==a)this.editor=new Ye(t,s);else{let e=x({},r.options.editable.window,{_footerTemplate:()=>'<div class="k-actions k-actions-start k-actions-horizontal k-window-actions">'+r._buildCommands(["update"],!0)[0].html+r._buildCommands(["canceledit"],!0)[0].html+"</div>"});x(s,{window:e,fieldRenderer:this._cellContent.bind(this),save:this.saveRow.bind(this),cancel:this._cancelEdit.bind(this),appendTo:this.wrapper}),this.editor=new Qe(t,s)}},_createIncellEditor:function(e,t){var n=this,i=x({},t.columns[0]);return delete i.parentColumn,new Xe(e,x({},{fieldRenderer:n._cellContent.bind(n),appendTo:n.wrapper,clearContainer:!1,target:n,columns:[i],model:t.model,change:t.change}))},editCell:function(t){var n=this;t=e(t);var i=it(n.columns)[n.cellIndex(t)],r=n.dataItem(t);n._isIncellEditable()&&r&&kt(i,r)&&n._editCell(t,i,r,t.index())},_editCell:function(e,t,n,i){var r,o=this;o.trigger(L,{model:n})?o.dataSource._restorePageSizeAfterAddChild():(o.closeCell(),n._edit=!0,o._cancelEditor(),o._render({editedColumn:t,editedColumnIndex:i}),r=o.table.add(o.lockedTable).find(H+Pe.editCell).first(),o.editor=o._createIncellEditor(r,{columns:[t],model:n,change:function(t){o.trigger(V,{values:t.values,container:e,model:n})&&t.preventDefault()}}),o.lockedTable&&o._syncLockedContentHeight(),o.current()&&o.current().removeClass("k-focus"),o._current=r,o.trigger(B,{container:e,model:n}))},closeCell:function(e){var t,n,i=this,r=(i.editor||{}).element;r&&r[0]&&i._isIncellEditable()&&(n=i.dataItem(r),e&&i.trigger(Q,{container:r,model:n})||(i.trigger(W,{type:e?Q:V,model:n,container:r}),i._cancelEditor(),r.removeClass(Pe.editCell),t=r.parent().removeClass(Pe.editRow),i.lockedContent&&i._relatedRow(t).removeClass(Pe.editRow),i._render(),i.trigger(I,{item:t,data:n,ns:u}),i.lockedContent&&function(e,t){var n,i=e.offsetHeight,r=t.offsetHeight;i>r?n=i+"px":i<r&&(n=r+"px");n&&(e.style.height=t.style.height=n)}(t.css("height","")[0],i._relatedRow(t).css("height","")[0])))},cancelChanges:function(){this.dataSource.cancelChanges()},saveChanges:function(){var e=this,t=(e.editor||{}).editable;!(t&&t.end())&&t||e.trigger(N)||e.dataSource.sync()},_editMode:function(){var e="inline",t=this.options.editable;return!0!==t&&(e="string"==typeof t?t:t.mode||e),e.toLowerCase()},_isIncellEditable:function(){return"incell"===this._editMode()},_isInlineEditable:function(){return"inline"===this._editMode()},_isPopupEditable:function(){return"popup"===this._editMode()},hideColumn:function(e){this._toggleColumnVisibility(e,!0)},showColumn:function(e){this._toggleColumnVisibility(e,!1)},_toggleColumnVisibility:function(e,t){(e=this._findColumn(e))&&e.hidden!==t&&(e.hidden=t,this._setParentsVisibility(e,!t),this._ensureExpandableColumn(),this._clearColsCache(),this._renderCols(),this._renderHeader(),this._render(),this._adjustTablesWidth(),t?this._ariaAddHiddenColIndex():this._ariaRemoveHiddenColIndex(),this.trigger(t?ee:te,{column:e}),t||e.width||this.table.add(this.thead.closest("table")).width(""),this._updateFirstColumnClass())},_findColumn:function(e){return e="number"==typeof e?this.columns[e]:D(e)?S(it(this.columns),(function(t){return t===e}))[0]:S(it(this.columns),(function(t){return t.field===e}))[0]},_adjustTablesWidth:function(){var e,t,n,i=this.thead.prev().children(),r=0;for(e=0,t=i.length;e<t;e++){if(!(n=i[e].style.width)||-1!=n.indexOf("%")){r=0;break}r+=parseInt(n,10)}r&&this.table.add(this.thead.closest("table")).width(r)},_reorderable:function(){if(this.options.reorderable){var t=(!0===this.options.scrollable?".k-grid-header ":"table>.k-grid-header ")+"th.k-header",n=this;this._draggableInstance=new u.Draggable(this.wrapper,{group:kendo.guid(),filter:t,ignore:".k-filter-row *",hint:function(t){return e('<div class="k-reorder-clue k-drag-clue" />').html(t.attr(kendo.attr("title"))||t.attr(kendo.attr("field"))||t.text()).prepend(kendo.ui.icon({icon:"cancel",iconClass:"k-drag-status"}))}}),this.reorderable=new u.Reorderable(this.wrapper,{draggable:this._draggableInstance,dragOverContainers:this._allowDragOverContainers.bind(this),inSameContainer:function(t){return e(t.source).parent()[0]===e(t.target).parent()[0]&&lt(st(n.columns),n.columns,t.sourceIndex,t.targetIndex)>-1},change:function(e){var t=st(n.columns),i=t[e.oldIndex],r=lt(t,n.columns,e.oldIndex,e.newIndex);n.trigger(ne,{newIndex:r,oldIndex:T(i,t),column:i}),n.reorderColumn(r,i,"before"===e.position)}})}},_allowDragOverContainers:function(e,t){var n=st(this.columns);return!1!==n[e].lockable&&lt(n,this.columns,e,t)>-1},_reorderTrees:function(t,n,i,r,o,a,s,l){for(var c,d,u,h,p,f=e(),m=o.find("tr").eq(r[0].rowIndex),g=a.children[r[0].rowIndex],v=m.children(),_=s?t[0]:t[t.length-1],b=0;b<r.length;b++)c=r[b].cellIndex,f=f.add(v.eq(c)),i===a&&s&&(c+=b),i.children[_.rowIndex].children.splice(s?_.cellIndex+b:_.cellIndex+1+b,0,g.children[c]);if(i===a&&s?g.children.splice(r[0].cellIndex+r.length,r.length):g.children.splice(r[0].cellIndex,r.length),(p=n.find("tr").eq(_.rowIndex).find(">th.k-header").eq(_.cellIndex)).length&&f[0]!==p[0]&&f[s?"insertBefore":"insertAfter"](p),l>=r[0].rowIndex+1&&1!=l){for(d=[],b=0;b<r.length;b++)r[b].columns&&(d=d.concat(r[b].columns));if(!d.length)return;for(u=[],b=0;b<t.length;b++)t[b].columns&&(u=u.concat(t[b].columns));if(!u.length&&(n!==o||_.cellIndex-r[0].cellIndex>1||r[0].cellIndex-_.cellIndex>1)&&(u=[h=nt(this.columns,_,r[0],s,this.columns)],!h&&d.length&&n.find("tr").length>r[0].rowIndex+1))return void this._insertTree(d,o,a,n,i);if(!u.length)return;this._reorderTrees(u,n,i,d,o,a,s,l)}},_insertTree:function(t,n,i,r,o){var a,s,l=[],c=e();a=n.find("tr").eq(t[0].rowIndex),s=i.children[t[0].rowIndex];for(var d=0;d<t.length;d++)t[d].columns&&(l=l.concat(t[d].columns)),o.children[t[0].rowIndex].children.splice(d,0,s.children[t[d].rowIndex]),c=c.add(a.find(">th.k-header").eq(t[d].cellIndex));i.children[t[0].rowIndex].children.splice(t[0].cellIndex,t.length),r.find("tr").eq(t[0].rowIndex).append(c),l.length&&this._insertTree(l,n,i,r,o)},_reorderHeader:function(t,n,i){var r,a,s=n.columns?gt([n]):1,l=t.columns?gt([t]):1,c=tt(n),d=tt(t),u=d?this.lockedHeader:this.thead,h=c?this.lockedHeader:this.thead,p=d?this._lockedHeaderTree:this._headerTree,f=c?this._lockedHeaderTree:this._headerTree,m=u.find("tr:not(.k-filter-row)");if(s===l||s<m.length)this._reorderTrees([t],u,p,[n],h,f,i,s),bt(u,p),yt(h,f);else{if(u!==h){r=s-m.length,m.each((function(e){for(var t=this.cells,n=0;n<t.length;n++)t[n].colSpan<=1&&t[n].attributes.rowspan&&(p.children[e].children[n].attr.rowSpan+=r,t[n].rowSpan+=r)}));for(var g=0;g<r;g++)p.children.push(o("tr",{role:"row"})),a=u.is("thead")?u:u.find("thead"),this._hasFilterRow()?e("<tr class='k-table-row' role='row'></tr>").insertBefore(a.find("tr.k-filter-row")):a.append("<tr class='k-table-row' role='row'></tr>")}this._reorderTrees([t],u,p,[n],h,f,i,s),yt(h,f)}},reorderColumn:function(n,i,r){var o,a=i.parentColumn,s=a?a.columns:this.columns,l=T(i,s),c=s[n],d=!!c.locked,u=S(this.columns,(function(e){return e.columns!==t})).length>0,h=_t(s).length;if(l!==n&&(!d||i.locked||1!=h)&&(d||!i.locked||s.length-h!=1)){if(r===t&&(r=n<l),u&&this._reorderHeader(c,i,r),o=(o=!!i.locked)!=d,i.locked=d,s.splice(r?n:n+1,0,i),s.splice(l<n?l:l+1,1),this._setColumnDataIndexes(it(this.columns)),this._clearColsCache(),this._renderCols(),u)this.lockedHeader?(s=_t(this.columns),this._prepareColumns([{rowSpan:1,cells:[],index:0}],s),s=vt(this.columns),this._prepareColumns([{rowSpan:1,cells:[],index:0}],s)):this._prepareColumns([{rowSpan:1,cells:[],index:0}],this.columns);else{var p=e(this.lockedHeader).add(this.thead).find("tr:not(.k-filter-row) th");p.eq(l)[r?"insertBefore":"insertAfter"](p.eq(n));var f=this._headerTree.children[0].children;this._hasLockedColumns&&(f=this._lockedHeaderTree.children[0].children.concat(f)),f.splice(r?n:n+1,0,f[l]),f.splice(l<n?l:l+1,1),this._hasLockedColumns&&(this._lockedHeaderTree.children[0].children=f.splice(0,vt(s).length),this._headerTree.children[0].children=f)}this._updateColumnCellIndex(),this._applyLockedContainersWidth(),this._syncLockedHeaderHeight(),this._updateFirstColumnClass(),this._hasFilterRow()&&this._updateFilterThs(r,i,c),this.refresh(),o&&(d?this.trigger(ae,{column:i}):this.trigger(se,{column:i}))}},lockColumn:function(e){var t=this.columns;if((e="number"==typeof e?t[e]:S(t,(function(t){return t.field===e}))[0])&&!e.hidden){var n=vt(t).length-1;this.reorderColumn(n,e,!1)}},unlockColumn:function(e){var t=this.columns;if((e="number"==typeof e?t[e]:S(t,(function(t){return t.field===e}))[0])&&!e.hidden){var n=vt(t).length;this.reorderColumn(n,e,!0)}},_columnMenu:function(){var n,i,r,o,a,s=e(this.lockedHeader).add(this.thead).find("th"),l=this.columns,c=this.options,d=c.columnMenu,u=this._columnMenuInit.bind(this),h=this._columnMenuOpen.bind(this),p=this._sort.bind(this),f=this._filter.bind(this),m=S(this.columns,(function(e){return!1!==e.lockable})).length>0,g=S(this.columns,(function(e){return e.columns!==t})).length>0;if(g?(l=it(l),s=this.lockedHeader?We(je(this.lockedHeader.find(">table>thead")).add(je(this.thead))):je(this.thead)):s=e(this.lockedHeader).add(this.thead).find("tr:not(.k-filter-row) th"),d){"boolean"==typeof d&&(d={});for(var v=0;v<s.length;v++)(n=l[v]).field&&((i=s.eq(v).data("kendoColumnMenu"))&&i.destroy(),o=!1,!1!==n.sortable&&!1!==d.sortable&&!1!==c.sortable&&(o=x({},c.sortable,{compare:(n.sortable||{}).compare})),a=!1,c.filterable&&!1!==n.filterable&&!1!==d.filterable&&(a=x({pane:this.pane},n.filterable,c.filterable)),r={dataSource:this.dataSource,values:n.values,columns:d.columns,sortable:o,filterable:a,messages:d.messages,owner:this,closeCallback:Je,init:u,open:h,sort:p,filtering:f,pane:this.pane,hasLockableColumns:vt(l).length>0&&m&&!g,appendTo:H+Pe.headerCellInner,reorderable:!!c.reorderable},s.eq(v).kendoColumnMenu(r))}},_columnMenuInit:function(e){this.trigger(re,{field:e.field,container:e.container})},_columnMenuOpen:function(e){this.trigger(oe,{field:e.field,container:e.container})},_filter:function(e){this.trigger(le,{filter:e.filter,field:e.field})&&e.preventDefault()},_sort:function(e){this.trigger(de,{sort:e.sort})&&e.preventDefault()},_pageable:function(){var t,n=this,i=n.options.pageable;i&&((t=n.wrapper.children("div.k-grid-pager")).length||(t=e('<div class="k-pager k-grid-pager"/>').appendTo(n.wrapper)),n._destroyPager(),"object"==typeof i&&i instanceof kendo.ui.TreeListPager?n.pager=i:n.dataSource&&!n.dataSource.options.serverPaging&&n._createPager(t),n.pager&&n.pager.bind("pageChange",(function(e){n.trigger(O,{page:e.index})&&e.preventDefault()})))},_createPager:function(e,t){var n=this;n.pager=new Ke(e,x({},n.options.pageable,{dataSource:n.dataSource,size:"medium",navigatable:n.options.navigatable},t))},_destroyPager:function(){this.pager&&(this.pager.destroy(),this.pager=null)},_isPageable:function(){var e=this;return e.options.pageable&&(!e.dataSource||e.dataSource&&e.dataSource._isPageable())},_togglePagerVisibility:function(){var e=this,t=e.options.pageable;t&&(D(t)||t instanceof Ke)&&!1===t.alwaysVisible&&e.wrapper.find(".k-grid-pager").toggle((e.dataSource.collapsedTotal()||0)>=e.dataSource.pageSize())}});function Je(e){wt(e.closest(".k-treelist").find("[role=treegrid]"),!0)}function et(t){return e(t).is(":button,a,:input,a>.k-icon,a>.k-svg-icon,textarea,span.k-select,span.k-icon:not(.k-treelist-toggle),span.k-svg-icon:not(.k-treelist-toggle),span.k-link,.k-input,.k-multiselect-wrap,.k-tool-icon,.k-input-value-text,.k-input-inner,.k-button-icon,.k-switch-thumb,.k-switch-track,.k-switch-label-off,.k-switch-label-on")}function tt(e){return e.parentColumn?!!tt(e.parentColumn):!!e.locked}function nt(e,t,n,i,r){if(t.columns)return(t=t.columns)[i?0:t.length-1];var o,a=ut(t,e);o=a?a.columns:e;var s=T(t,o);0===s&&i&&1!==o.length?s++:s!=o.length-1||i||0===s?(s>0||0===s&&!i&&0!==s)&&(s+=i?-1:1):s--,t=function(e,t,n,i){var r,o,a=!!n.locked;do{r=e[t],t+=i?1:-1,o=!!r.locked}while(r&&t>-1&&t<e.length&&r!=n&&!r.columns&&o===a);return r}(o,s,n,T(n,o)>s);var l=T(t,r);return(!t.columns||l&&l!==o.length-1)&&t&&t!=n&&t.columns?nt(e,t,n,i,r):null}function it(e){for(var t=[],n=0;n<e.length;n++)e[n].columns?t=t.concat(it(e[n].columns)):t.push(e[n]);return t}function rt(e){return S(e,(function(e){return!e.hidden}))}function ot(e){return S(e,(function(e){var t=!e.hidden;return t&&e.columns&&(t=ot(e.columns).length>0),t}))}function at(e,t,n){return C(e,(function(e){var i;e.parentIds=n,function(e){return ot([e]).length>0}(e)&&!t||(i=!0);var r=kendo.guid();return e.headerAttributes=x({headers:n},e.headerAttributes),e.headerAttributes&&e.headerAttributes.id?r=e.headerAttributes.id:e.headerAttributes=x({id:r},e.headerAttributes),e.columns&&(e.columns=at(e.columns,i,n?n+" "+r:r)),x({hidden:i},e)}))}function st(e){return pt(vt(e)).concat(pt(_t(e)))}function lt(e,t,n,i){var r=e[n],o=e[i],a=ut(r,t);return t=a?a.columns:t,T(o,t)}function ct(t){var n=t.closest("table"),i=e().add(t),r=t.closest("tr"),o=n.find("tr"),a=o.index(r);if(a>0){for(var s=o.eq(a-1).find("th").filter((function(){return!e(this).attr("rowspan")})),l=0,c=r.find("th").index(t),d=t.prevAll().filter((function(){return this.colSpan>1})),u=0;u<d.length;u++)l+=d[u].colSpan||1;for(c+=Math.max(l-1,0),l=0,u=0;u<s.length;u++){var h=s.eq(u);if(h.attr("data-colspan")?l+=h[0].getAttribute("data-colspan"):l+=1,c>=u&&c<l){i=ct(h).add(i);break}}}return i}function dt(t){var n=t.closest("thead"),i=e().add(t),r=t.closest("tr"),o=n.find("tr"),a=o.index(r)+t[0].rowSpan,s=kendo.attr("colspan");if(a<=o.length-1){var l,c=r.next(),d=t.prevAll();d=d.filter((function(){return!this.rowSpan||1===this.rowSpan}));var u=0;for(l=0;l<d.length;l++)u+=parseInt(d.eq(l).attr(s),10)||1;var h=c.find("th"),p=parseInt(t.attr(s),10)||1;for(l=0;l<p;){c=h.eq(l+u),i=i.add(dt(c));var f=parseInt(c.attr(s),10);f>1&&(p-=f-1),l++}}return i}function ut(e,t){var n=[];return ht(e,t,n),n[n.length-1]}function ht(e,t,n){n=n||[];for(var i=0;i<t.length;i++){if(e===t[i])return!0;if(t[i].columns){var r=n.length;if(n.push(t[i]),ht(e,t[i].columns,n))return!0;n.splice(r,n.length-r)}}return!1}function pt(e){for(var t=[],n=[],i=0;i<e.length;i++)t.push(e[i]),e[i].columns&&(n=n.concat(e[i].columns));return n.length&&(t=t.concat(pt(n))),t}function ft(e,t,n,i){var r,o;for((i=i||{})[n=n||0]=i[n]||0,o=0;o<t.length;o++){if(t[o]==e){r={cell:i[n],row:n};break}if(t[o].columns&&(r=ft(e,t[o].columns,n+1,i)))break;i[n]++}return r}function mt(t,n,i){var r;i=i||0;var o=n;n=it(n);for(var a={},s=t.find(">tr:not(.k-filter-row)"),l=function(){var t=e(this);return!t.hasClass("k-group-cell")&&!t.hasClass("k-hierarchy-cell")},c=0,d=n.length;c<d;c++)a[(r=ft(n[c],o)).row]||(a[r.row]=s.eq(r.row).find(".k-header").filter(l)),a[r.row].eq(r.cell).attr(kendo.attr("index"),i+c);return n.length}function gt(e){for(var t=0,n=0;n<e.length;n++)if(e[n].columns){var i=gt(e[n].columns);i>t&&(t=i)}return 1+t}function vt(e){return S(e,Ve("locked"))}function _t(e){return S(e,Ne(Ve("locked")))}function bt(e,t){var n=e.find("tr:not(.k-filter-row)"),i=n.length;n.each((function(e){for(var n=this.cells,r=0;r<n.length;r++)n[r].colSpan<=1&&n[r].attributes.rowspan&&(t.children[e].children[r].attr.rowSpan=i-e,n[r].rowSpan=i-e)}))}function yt(t,n){var i=t.find("tr"),r=[];i.filter((function(t){var n=!e(this).children().length;return n&&r.push(t),n})).remove();for(var o=r.length-1;o>=0;o--)n.children.splice(r[o],1);bt(t,n)}function wt(t,n){var i,r;!0===n?(i=(t=e(t)).parent().scrollTop(),r=kendo.scrollLeft(t.parent()),kendo.focusElement(t),kendo.scrollLeft(t.parent().scrollTop(i),r)):e(t).one("focusin",(function(e){e.preventDefault()})).trigger("focus")}function kt(e,t){return!(!(e&&t&&e.field)||e.selectable||e.command||e.draggable||e.editable&&!e.editable(t))&&(e.field&&t.editable&&t.editable(e.field))}function xt(e){return void 0===e}kendo.ExcelMixin&&kendo.ExcelMixin.extend(Ze.prototype),kendo.PDFMixin&&(kendo.PDFMixin.extend(Ze.prototype),Ze.prototype._drawPDF=function(n){var i=this;if(i.options.pdf.paperSize&&"auto"!=i.options.pdf.paperSize)return i._drawPDF_autoPageBreak(n);var r=new e.Deferred,o=i.dataSource,a=i.options.pdf.allPages;this._initPDFProgress(n);var s=new kendo.drawing.Group,l=o.page();function c(){i._drawPDFShadow({width:i.wrapper.width()},{avoidLinks:i.options.pdf.avoidLinks}).done((function(e){var i=o.page(),d=a?o.totalPages():1,u={page:e,pageNumber:i,progress:i/d,totalPages:d};n.notify(u),s.append(u.page),i<d?o.page(i+1):a&&l!==t?(o.unbind("change",c),o.one("change",(function(){r.resolve(s)})),o.page(l)):r.resolve(s)})).fail((function(e){r.reject(e)}))}return a?(o.bind("change",c),o.page(1)):c(),r.promise()},Ze.prototype._initPDFProgress=function(t){var n=e("<div class='k-loading-pdf-mask'><div class='k-loading-color'></div></div>");n.prepend(this.wrapper.clone().css({position:"absolute",top:0,left:0})),this.wrapper.append(n);var i=e("<div class='k-loading-pdf-progress'>").appendTo(n).kendoProgressBar({type:"chunk",chunkCount:10,min:0,max:1,value:0}).data("kendoProgressBar");t.progress((function(e){i.value(e.progress)})).always((function(){kendo.destroy(n),n.remove()}))},Ze.prototype._drawPDF_autoPageBreak=function(n){var i=this,r=new e.Deferred,o=i.dataSource,a=i.options.pdf.allPages,s=i.wrapper.find('table[role="treeList"] > tbody'),l=e("<div>").css({position:"absolute",left:-1e4,top:-1e4}),c=i.wrapper.clone().css({height:"auto",width:"auto"}).appendTo(l);c.find(".k-grid-content").css({height:"auto",width:"auto",overflow:"visible"}),c.find('table[role="treeList"], .k-grid-footer table').css({height:"auto",width:"100%",overflow:"visible"}),c.find(".k-grid-pager, .k-grid-toolbar, .k-grouping-header").remove(),c.find(".k-grid-header, .k-grid-footer").css({paddingRight:0}),this._initPDFProgress(n);var d=c.find('table[role="treeList"] > tbody').empty(),u=o.page();function h(){l.appendTo(document.body);var t=e.extend({},i.options.pdf,{_destructive:!0,progress:function(e){n.notify({page:e.page,pageNumber:e.pageNum,progress:.5+e.pageNum/e.totalPages/2,totalPages:e.totalPages})}});kendo.drawing.drawDOM(c,t).always((function(){l.remove()})).then((function(e){r.resolve(e)})).fail((function(e){r.reject(e)}))}function p(){var e=o.page(),n=a?o.totalPages():1;d.append(s.find("tr")),e<n?o.page(e+1):(o.unbind("change",p),a&&u!==t?(o.one("change",h),o.page(u)):(i.refresh(),h()))}return a?(o.bind("change",p),o.page(1)):p(),r.promise()}),x(!0,kendo.data,{TreeListDataSource:$e,TreeListModel:Oe}),x(kendo.ui.treelist,{editor:Ye,defaultBodyContextMenu:Fe,defaultHeadContextMenu:Re}),u.plugin(Ze),u.plugin(Ke)}(window.kendo.jQuery);kendo;!function(e,t){var n=Array.isArray,i=e.extend,r=e.map,o=kendo.data,a=o.Query,s=o.DataSource,l=o.TreeListDataSource,c=o.TreeListModel,d=function(e,t){return function(i){var r=(i=n(i)?{data:i}:i)||{},o=r.data;if(r.data=o,!(r instanceof e)&&r instanceof s)throw new Error("Incorrect DataSource type. Only "+t+" instances are supported");return r instanceof e?r:new e(r)}},u=function(e){if(e.filter("[name=end], [name=start], [name=plannedEnd], [name=plannedStart]").length){for(var t,n,i=e.attr("name"),r=kendo.widgetInstance(e,kendo.ui),o={},a=e;a!==window&&!t;)t=(a=a.parent()).data("kendoEditable");return!(n=t?t.options.model:null)||(i.indexOf("planned")>=0?(o.plannedStart=n.plannedStart,o.plannedEnd=n.plannedEnd):(o.start=n.start,o.end=n.end),o[i]=r?r.value():kendo.parseDate(e.val()),i.indexOf("planned")>=0?o.plannedStart<=o.plannedEnd:o.start<=o.end)}return!0},h=kendo.data.Model.define({id:"id",fields:{id:{type:"number",editable:!1},predecessorId:{type:"number",validation:{required:!0}},successorId:{type:"number",validation:{required:!0}},type:{type:"number",validation:{required:!0}}}}),p=s.extend({init:function(e){s.fn.init.call(this,i(!0,{},{schema:{modelBase:h,model:h}},e))},dependencies:function(e){var t=this.predecessors(e),n=this.successors(e);return t.push.apply(t,n),t},predecessors:function(e){return this._dependencies("successorId",e)},successors:function(e){return this._dependencies("predecessorId",e)},_dependencies:function(e,t){var n=this.view(),i={field:e,operator:"eq",value:t};return n=new a(n).filter(i).toArray()}});p.create=d(p,"GanttDependencyDataSource");var f=c.define({fields:{id:{type:"number",editable:!1},parentId:{type:"number",defaultValue:null,nullable:!0},orderId:{type:"number",validation:{required:!0}},title:{type:"string",defaultValue:"New task"},start:{type:"date",validation:{required:!0}},end:{type:"date",validation:{required:!0,dateCompare:u,message:"End date should be after or equal to the start date"}},percentComplete:{type:"number",validation:{required:!0,min:0,max:1,step:.01}},summary:{type:"boolean"},expanded:{type:"boolean",defaultValue:!0},plannedStart:{type:"date",defaultValue:null,nullable:!0},plannedEnd:{type:"date",defaultValue:null,nullable:!0,validation:{dateCompare:u,message:"Planned end date should be after or equal to the planned start date"}}},duration:function(){return this.end-this.start},plannedDuration:function(){var e=this.plannedEnd,t=this.plannedStart;return e&&t?e-t:0},isMilestone:function(){return 0===this.duration()},_offset:function(e){for(var t,n=["start","end"],i=0;i<n.length;i++)t=new Date(this.get(n[i]).getTime()+e),this.set(n[i],t)},_offsetPlanned:function(e){for(var t,n=["plannedStart","plannedEnd"],i=0;i<n.length;i++)t=new Date(this.get(n[i]).getTime()+e),this.set(n[i],t)}});f.define=function(e,n){n===t&&(n=e,e=f);var i=n.parentId||"parentId";n.parentIdField=i;var r=c.define(e,n);return i&&(r.parentIdField=i),r};var m=l.extend({init:function(e){l.fn.init.call(this,i(!0,{},{schema:{modelBase:f,model:f},sort:{field:"orderId",dir:"asc"}},e))},add:function(e){if(e)return e=this._toGanttTask(e),this.insert(this.taskSiblings(e).length,e)},insert:function(e,t){if(t)return(t=this._toGanttTask(t)).set("orderId",e),t=s.fn.insert.call(this,e,t),this._reorderSiblings(t,this.taskSiblings(t).length-1),this._resolveSummaryFields(this.taskParent(t)),t},remove:function(e){var t=e.get("parentId"),n=this.taskAllChildren(e);return this._removeItems(n),e=l.fn.remove.call(this,e),this._childRemoved(t,e.get("orderId")),e},taskAllChildren:function(e){var t=[],n=this,i=function(e){var o=n.taskChildren(e);t.push.apply(t,o),r(o,i)};return e?i(e):t=this.view(),t},taskChildren:function(e,n){var i,r,o={field:"parentId",operator:"eq",value:null},s=this._sort&&this._sort.length?this._sort:{field:"orderId",dir:"asc"};if(r=n?this.view():this.data(),e){if((i=e.get("id"))===t||null===i||""===i)return[];o.value=i}return r=new a(r).filter(o).sort(s).toArray()},taskLevel:function(e){for(var t=0,n=this.taskParent(e);null!==n;)t+=1,n=this.taskParent(n);return t},taskParent:function(e){return e&&null!==e.get("parentId")?this.get(e.parentId):null},taskSiblings:function(e){if(!e)return null;var t=this.taskParent(e);return this.taskChildren(t)},taskTree:function(e){for(var t,n=[],i=this.taskChildren(e,!0),r=0,o=i.length;r<o;r++)if(t=i[r],n.push(t),t.get("expanded")){var a=this.taskTree(t);n.push.apply(n,a)}return n},update:function(e,n){var i,r=this,o=function(e){var t=e.field,n=e.sender;switch(t){case"start":r._resolveSummaryStart(r.taskParent(n)),function(e,t){for(var n=r.taskAllChildren(e),i=0,o=n.length;i<o;i++)n[i]._offset(t)}(n,n.get(t).getTime()-i.getTime());break;case"end":r._resolveSummaryEnd(r.taskParent(n));break;case"plannedStart":r._resolveSummaryPlannedStart(r.taskParent(n)),n.get(t)&&i&&function(e,t){for(var n=r.taskAllChildren(e),i=0,o=n.length;i<o;i++)n[i]._offsetPlanned(t)}(n,n.get(t).getTime()-i.getTime());break;case"plannedEnd":r._resolveSummaryPlannedEnd(r.taskParent(n));break;case"percentComplete":r._resolveSummaryPercentComplete(r.taskParent(n));break;case"orderId":r._reorderSiblings(n,i)}};for(var a in n.parentId!==t&&((i=e.get("parentId"))!==n.parentId&&(e.set("parentId",n.parentId),r._childRemoved(i,e.get("orderId")),e.set("orderId",r.taskSiblings(e).length-1),r._resolveSummaryFields(r.taskParent(e))),delete n.parentId),e.bind("change",o),e.bind("equalSet",o),n)i=e.get(a),"plannedStart"===a||"plannedEnd"===a?i===t&&null===n[a]||e.set(a,n[a]):("start"===a||"end"===a||e.get(a)!==n[a])&&e.set(a,n[a]);e.unbind("change",o),e.unbind("equalSet",o)},_childRemoved:function(e,t){for(var n=null===e?null:this.get(e),i=this.taskChildren(n),r=t,o=i.length;r<o;r++)i[r].set("orderId",r);this._resolveSummaryFields(n)},_resolveSummaryFields:function(e){e&&(this._updateSummary(e),this.taskChildren(e).length&&(this._resolveSummaryStart(e),this._resolveSummaryEnd(e),this._resolveSummaryPlannedStart(e),this._resolveSummaryPlannedEnd(e),this._resolveSummaryPercentComplete(e)))},_resolveSummaryStart:function(e){var t=this;this._updateSummaryRecursive(e,"start",(function(e){for(var n,i=t.taskChildren(e),r=i[0].start.getTime(),o=1,a=i.length;o<a;o++)(n=i[o].start.getTime())<r&&(r=n);return new Date(r)}))},_resolveSummaryEnd:function(e){var t=this;this._updateSummaryRecursive(e,"end",(function(e){for(var n,i=t.taskChildren(e),r=i[0].end.getTime(),o=1,a=i.length;o<a;o++)(n=i[o].end.getTime())>r&&(r=n);return new Date(r)}))},_resolveSummaryPlannedStart:function(e){var t=this;this._updateSummaryRecursive(e,"plannedStart",(function(e){for(var n,i=t.taskChildren(e),r=null,o=0,a=i.length;o<a;o++)i[o].plannedStart&&(n=i[o].plannedStart.getTime(),(!r||n<r)&&(r=n));return r?new Date(r):null}))},_resolveSummaryPlannedEnd:function(e){var t=this;this._updateSummaryRecursive(e,"plannedEnd",(function(e){for(var n,i=t.taskChildren(e),r=null,o=0,a=i.length;o<a;o++)i[o].plannedEnd&&(n=i[o].plannedEnd.getTime(),(!r||n>r)&&(r=n));return r?new Date(r):null}))},_resolveSummaryPercentComplete:function(e){var t=this;this._updateSummaryRecursive(e,"percentComplete",(function(e){var n=t.taskChildren(e);return new a(n).aggregate([{field:"percentComplete",aggregate:"average"}]).percentComplete.average}))},_reorderSiblings:function(e,t){var n=e.get("orderId"),i=n>t,r=i?t:n,o=i?n:t,a=i?r:r+1,s=this.taskSiblings(e);if(s.length){o=Math.min(o,s.length-1);for(var l=r;l<=o;l++)s[l]!==e&&(s[l].set("orderId",a),a+=1)}},_toGanttTask:function(e){if(!(e instanceof f)){var t=e;(e=s.fn._createNewModel.call(this)).accept(t)}return e},_updateSummary:function(e){if(null!==e){var t=this.taskChildren(e).length;e.set("summary",t>0)}},_updateSummaryRecursive:function(e,t,n){if(e){var i=n(e);e.set(t,i);var r=this.taskParent(e);r&&this._updateSummaryRecursive(r,t,n)}}});m.create=d(m,"GanttDataSource"),i(!0,kendo.data,{GanttDataSource:m,GanttTask:f,GanttDependencyDataSource:p,GanttDependency:h})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=n.Observable,o=i.Widget,a=n.htmlEncode,s=e.extend,l="23em",c="k-gantt-delete",d="k-gantt-cancel",u="k-gantt-update",h={form:"k-popup-edit-form",editForm:"k-gantt-edit-form",formContainer:"k-edit-form-container",resourcesFormContainer:"k-resources-form-container",message:"k-popup-message",buttonsContainer:"k-edit-buttons k-actions",button:"k-button",buttonDefaults:"k-button-md k-rounded-md k-button-solid k-button-solid-base",editField:"k-edit-field",editLabel:"k-edit-label",resourcesField:"k-gantt-resources"},p=r.extend({init:function(e,t){r.fn.init.call(this),this.element=e,this.options=s(!0,{},this.options,t)},destroy:function(){this.close(),this.unbind()},close:function(){var e=this,t=function(){e.editable&&(e.container.data("kendoWindow").destroy(),e.editable=null,e.container=null),e.popup&&(e.popup.destroy(),e.popup=null)};e.editable&&e.container.is(":visible")?(e.trigger("close",{window:e.container}),e.container.data("kendoWindow").bind("deactivate",t).close()):t()},editTask:function(e,t){this.task=e,this.plannedEditors=t,this.editable=this._createPopupEditor()},fields:function(){var t,i=this.options,r=this.task,o={};return i.editable.template?e.map(r.fields,(function(e,t){return{field:t}})):(o.general=this._fieldsGeneral(),i.resources&&(o.resources=[{field:"resources"}]),i.dependencies&&(o.dependencies=this._fieldsDependencies(r)),t=s(!0,{},r.fields),Object.keys(n.data.GanttTask.fields).map((e=>{delete t[e]})),Object.keys(t).length>0&&(o.other=this._fieldsOther(t)),o)},showDialog:function(t){var i,r=h,o=this.element,s=t.model,l=this,u=e(n.format('<div class="'+r.formContainer+'" data-uid="'+s.uid+'">')).appendTo(o),p=this.options.messages;u.append(e("<p>"+t.text+"</p>")),i=e('<div class="'+r.buttonsContainer+'">'),u.append(i),i.append(e("<button class='"+c+"'>"+a(p.destroy)+"</button>").kendoButton({name:"delete",themeColor:"primary",icon:"trash",click:e=>{e.preventDefault(),f.close(),t.callback()}})),i.append(e("<button class='"+d+"'>"+a(p.cancel)+"</button>").kendoButton({name:"cancel",icon:"cancel",click:e=>{e.preventDefault(),f.close(),t.callback(!0)}})),this.popup&&this.popup.destroy();var f=this.popup=u.kendoWindow({modal:!0,autoFocus:!1,resizable:!1,draggable:!1,title:t.title,visible:!1,deactivate:function(){this.destroy(),l.trigger("close",{window:u})}}).getKendoWindow();f.center().open(),f.element.find(".k-button-solid-primary").trigger("focus")},_buildButtons:function(t){var n=this.options.messages,i=e('<div class="'+h.buttonsContainer+'">');i.appendTo(t),i.append(e("<button class='"+u+"'>"+a(n.save)+"</button>").kendoButton({name:"update",themeColor:"primary",icon:"save",click:this._onSave.bind(this)})),i.append(e("<button class='"+d+"'>"+a(n.cancel)+"</button>").kendoButton({name:"cancel",icon:"cancel",click:this._onCancel.bind(this)})),i.append(e("<span class='k-spacer'>")),!1!==this.options.editable.destroy&&i.append(e("<button class='"+c+"'>"+a(n.destroy)+"</button>").kendoButton({name:"delete",themeColor:"primary",icon:"trash",fillMode:"flat",click:this._onDelete.bind(this)}))},_buildEditTemplate:function(t,i){var r=this.options.editable.template,o=s({},n.Template,this.options.templateSettings),a="";r?("string"==typeof r&&(r=n.unescape(r)),a+=n.template(r,o)(t)):(this.renderForm=!0,a+=`<div role="form" class="k-gantt-edit-tabstrip" ${n.attr("style-min-height")}="28em"></div>`);var l=e(a);n.applyStylesFromKendoAttributes(l,["min-height"]),l.appendTo(i)},_createPopupEditor:function(){var t,i=this,r=this.options.messages,o=h,a=this.task,l=e(n.format('<div {0}="{1}" class="{2} {3}">',n.attr("uid"),a.uid,o.form,o.editForm));return l.appendTo(this.element),this._buildEditTemplate(a,l),this._buildButtons(l),this.container=l.kendoWindow(s({width:554,modal:!0,resizable:!1,draggable:!0,title:r.editor.editorTitle,visible:!1,actions:["Minimize","Maximize","Close"],close:function(e){e.userTriggered&&i.trigger("cancel",{container:l,model:a})&&e.preventDefault()}},{})),t=this.renderForm?this._initForm():l.kendoEditable({model:a,clearContainer:!1,validateOnBlur:!0,target:i.options.target}).data("kendoEditable"),n.cycleForm(l),this.trigger("edit",{container:l,model:a})?i.trigger("cancel",{container:l,model:a}):l.data("kendoWindow").center().open(),t},_fieldsDependencies:function(e){return{nameDdlDs:this.options.target.dataSource.data().filter((t=>t.id!==e.id)).map((e=>({text:e.title,value:e.id}))),typeDs:[{value:0,text:"Finish-Finish"},{value:1,text:"Finish-Start"},{value:2,text:"Start-Finish"},{value:3,text:"Start-Start"}]}},_fieldsGeneral:function(){var e,t,i,r=this,o=this.options,l=o.target.dataSource,c=o.messages.editor,d=this.task,u=d.fields,h=this.plannedEditors?c.actualStart:c.start,p=this.plannedEditors?c.actualEnd:c.end,f=[{field:"title",title:c.title,colSpan:4}];return this.plannedEditors&&(f.push({field:"plannedStart",title:c.plannedStart,colSpan:2,editor:"DateTimePicker",validation:u.plannedStart.validation,editorOptions:{componentType:"modern"}}),f.push({field:"plannedEnd",title:c.plannedEnd,colSpan:2,editor:"DateTimePicker",validation:u.plannedEnd.validation,editorOptions:{componentType:"modern"}})),e=l.data(),(t=l.taskAllChildren(d)).push(d),i=e.filter((e=>!t.some((t=>t.id===e.id)))),f.push({field:"start",title:h,colSpan:2,editor:"DateTimePicker",validation:u.start.validation,editorOptions:{componentType:"modern"}}),f.push({field:"end",title:p,colSpan:2,editor:"DateTimePicker",validation:u.start.validation,editorOptions:{componentType:"modern"}}),f.push({field:"percentComplete",title:c.percentComplete,format:"p0",colSpan:1,hint:a(c.percentCompleteHint)}),f.push({field:"parentId",title:c.parent,colSpan:4,editor:"DropDownList",editorOptions:{optionLabel:c.parentOptionLabel,filter:"contains",dataSource:i,enable:i.length>0,dataValueField:"id",dataTextField:"title",valuePrimitive:!0,template:({title:e,start:t,end:i})=>`<span>${e} ${n.toString(t,"d")}-${n.toString(i,"d")}</span>`}}),f=f.map((function(e){return e=s(!0,{label:e.title},e),!d.editable||d.editable(e.field)?e:s(!0,e,{editor:r._readonlyEditor.bind(r)})}))},_fieldsOther:function(e){var t=this,n=this.task;return e=Object.keys(e).map((function(i){var r=e[i];return r=s(!0,{field:i,label:r.title},r),!n.editable||n.editable(r.field)?r:s(!0,r,{editor:t._readonlyEditor.bind(t)})}))},_gridOptions:function(t,n,i,r){var o=this.options.messages;return this.dependencyData||(this.dependencyData={}),{dataSource:{data:this.dependencyData[n]=this.options.target.dependencies.view().filter((e=>e[i]===r)),schema:{model:{fields:{id:{from:"id"},[n]:{from:n,validation:{required:{message:o.editor.name+" is required"}}},type:{from:"type",validation:{required:!0},defaultValue:1}}}}},encodeTitles:!0,columns:[{selectable:!0,width:50},{field:n,title:o.editor.name,values:t.nameDdlDs},{field:"type",title:o.editor.dependencyType,values:t.typeDs,width:"9em"}],toolbar:[{name:"create",text:o.editor.addNew},{name:"remove",icon:"minus",text:o.editor.remove,click:t=>{var n=t.target.closest(".k-grid").getKendoGrid(),i=n.dataSource,r=n.select(),o=[];r&&r.length>0&&(r.each(((t,i)=>{o.push(n.dataItem(e(i)))})),o.map((e=>{i.remove(e)})))}}],editable:!0,sortable:!0,navigatable:!0,height:l,edit:function(){var t=e("[name=predecessorId], [name=successorId]");t.length&&t.data("kendoDropDownList").setOptions({filter:"contains"})}}},_initForm:function(){var t=this,n=t.task,i=t.container,r=t.options.resources,o=n.get(r.field),a=t.fields(),s=t._tabStripSource(a,o);return i.find(".k-gantt-edit-tabstrip").kendoTabStrip({dataTextField:"name",dataContentField:"content",dataSource:s,value:t.options.messages.editor.general,select:t=>{var n=t.sender,i=e(n.contentElement(n.select().index())),r=i.find(".k-grid").data("kendoGrid"),o=i.find(".k-form").data("kendoForm");(r&&r.editable&&r.editable.validatable&&!r.editable.validatable.validate()||o&&!o.validator.validate())&&t.preventDefault()}}),t._initGeneral(a.general,n),o&&(t.resourceEditor=r.editor(i.find(".k-gantt-resources"),n)),a.dependencies&&(i.find(".k-gantt-predecessors").kendoGrid(t._gridOptions(a.dependencies,"predecessorId","successorId",n.id)),i.find(".k-gantt-successors").kendoGrid(t._gridOptions(a.dependencies,"successorId","predecessorId",n.id))),a.other&&t._initOther(a.other,n),t.form.editable},_initGeneral:function(e,t){this.form=this.container.find(".k-gantt-form-default").kendoForm({layout:"grid",grid:{cols:4,gutter:{rows:0,cols:8}},items:e,formData:t,buttonsTemplate:()=>"",validatable:{validateOnBlur:!0}}).data("kendoForm")},_initOther:function(e,t){this.container.find(".k-gantt-form-other").kendoForm({items:e,formData:t,buttonsTemplate:()=>"",validatable:{validateOnBlur:!0}})},_readonlyEditor:function(e,t){var i=t.field,r="",o=this.options.target.dataSource;null!==t.model.get(i)&&((r=t.model.get(i))instanceof Date?r=n.toString(r,"g"):"percentComplete"===i?r=n.toString(r,t.format):"parentId"===i&&(r=o.get(r).title)),e.append("<span>"+r+"</span>")},_onCancel:function(){this.trigger("cancel",{container:this.container,model:this.task})},_onDelete:function(){this.trigger("remove",{container:this.container,model:this.task})},_onSave:function(){var t,n,i,r,o=this.task,a=[],s={},l=this.container,c=l.find(".k-gantt-predecessors").getKendoGrid(),d=l.find(".k-gantt-successors").getKendoGrid(),u={},h=[],p=[];if(c){if(i=this.dependencyData.successorId.concat(this.dependencyData.predecessorId),r=c.dataSource.view().toJSON().concat(d.dataSource.view().toJSON()),c&&c.editable&&c.editable.validatable&&!c.editable.validatable.validate()||d&&d.editable&&d.editable.validatable&&!d.editable.validatable.validate())return;r.map((e=>{n=i.find((t=>t.id===e.id)),n&&(n.dirty&&p.push(e),r=r.filter((t=>t.id!==e.id)),i=i.filter((t=>t.id!==e.id)))})),r.map((e=>{e.successorId?(e.predecessorId||(e.predecessorId=o.get("id")),h.push(e)):e.predecessorId&&(e.successorId||(e.successorId=o.get("id")),h.push(e))})),(h.length>0||i.length>0||p.length>0)&&(u.updateDependencies={destroyed:i,created:h,updated:p})}if(Array.isArray(this.fields())?a=this.fields():Object.values(this.fields()).map((e=>{Array.isArray(e)&&a.push(...e)})),!this.resourceEditor||this.resourceEditor.updateModel()){for(var f=0,m=a.length;f<m;f++)s[t=a[f].field]=o.get(t);this.trigger("save",e.extend({},u,{container:l,model:o,updateInfo:s}))}},_tabStripSource:function(e,t){var n=this.options.messages.editor,i=e.dependencies,r=[{name:n.general,content:"<div class='k-gantt-form-default'></div>"}];return t&&r.push({name:n.resources,content:"<div class='k-gantt-resources'></div>"}),i&&(r.push({name:n.predecessors,content:"<div class='k-gantt-predecessors'></div>"}),r.push({name:n.successors,content:"<div class='k-gantt-successors'></div>"})),e.other&&r.push({name:n.other,content:"<div class='k-gantt-form-other'></div>"}),r}}),f=o.extend({init:function(e,t){o.fn.init.call(this,e,t),this.wrapper=this.element,this.model=this.options.model,this.resourcesField=this.options.resourcesField,this._resourceGrid()},destroy:function(){this.grid=null,o.fn.destroy.call(this),this.element=this.wrapper=null},updateModel:function(){var e,n,i=[],r=this.grid,o=r.dataSource.data(),a=r.editable;if(a&&a.validatable&&!a.validatable.validate())return!1;for(var s=0,l=o.length;s<l;s++)n=(e=o[s]).get("value"),e.id!==t&&null!==n&&n>0&&i.push(o[s]);return this.model[this.resourcesField]=i,!0},_resourceGrid:function(){var e=this,i=this.options.messages,r=e.options,o=this.wrapper,a=r.resources;e.grid=new n.ui.Grid(o,{encodeTitles:!0,columns:[{selectable:!0,width:50},{field:"id",title:i.resourcesHeader,values:a},{field:"value",title:i.unitsHeader,template:function(e){var t=e.format||"p0",i=null!==e.value?e.value:"";return t?n.toString(i,t):i},width:120}],height:l,sortable:!0,editable:!0,filterable:!0,navigatable:!0,toolbar:[{name:"create",text:i.addNew},{name:"remove",icon:"minus",text:i.remove,click:()=>{var t=e.grid,n=t.dataSource,i=t.selectedKeyNames();i&&i.length>0&&i.map((e=>{n.remove(n.get(e))}))}}],dataSource:{data:this.model.resources,schema:{model:{id:"id",fields:{id:{from:"id",defaultValue:t,validation:{required:{message:i.resourcesHeader+" is required"}}},value:{from:"value",type:"number",defaultValue:1,validation:this.options.unitsValidation},format:{from:"format",type:"string"}}}}},edit:function(e){var t=e.container.find("select").data("kendoDropDownList"),n=e.model.id,i=r.model.resources.map((e=>e.id)).filter((e=>e!==n)).map((e=>({field:"value",operator:"neq",value:e})));t&&(t.dataSource.filter({logic:"and",filters:i}),t.setOptions({filter:"contains"}))}})}});n.gantt={PopupEditor:p,ResourceEditor:f}}(window.kendo.jQuery);kendo;!function(e){var t=e.extend,n=e.map,i=kendo.isFunction,r=kendo.ui,o=r.TreeList,a=kendo._outerHeight,s=kendo._activeElement,l=kendo.support.mobileOS,c=kendo.attr("type"),d=kendo.attr("bind"),u=kendo.attr("format"),h="string",p="{0:"+kendo.getCulture().calendar.patterns.d+"}",f={title:"Title",start:"Start Time",end:"End Time",percentComplete:"% Done",parentId:"Predecessor ID",id:"ID",orderId:"Order ID"},m=`<table ${kendo.attr("style-visibility")}="hidden"><tbody><tr ${kendo.attr("style-height")}="{0}"><td>&nbsp;</td></tr></tbody></table>`,g={gridHeader:"k-grid-header",gridContentWrap:"k-grid-content",editCell:"k-edit-cell",iconCollapse:"caret-alt-down",iconExpand:"caret-alt-right"},v=r.GanttList=o.extend({init:function(e,t){0===this.options.columns.length&&this.options.columns.push("title"),o.fn.init.call(this,e,t),this._unbindDataSource(),this._setWidth()},options:{name:"GanttList",autoBind:!1,sortable:!0,selectable:!0,_editCellEvent:"dblclick",_tabCycleStop:!0,navigatable:!1,editable:{move:!0,mode:"incell"},resizable:!1,renderAllRows:!1},destroy:function(){o.fn.destroy.call(this),kendo.destroy(this.element)},closeCell:function(e){var t,n,i=this,o=(i.editor||{}).element;o&&o[0]&&i._isIncellEditable()&&(n=i.dataItem(o),i._cancelEditor(),o.removeClass(g.editCell),t=o.parent().removeClass(g.editRow),i.lockedContent&&i._relatedRow(t).removeClass(g.editRow),e&&i._render(),i.trigger("itemChange",{item:t,data:n,ns:r}),i.lockedContent&&i._adjustRowHeight(t.css("height","")[0],i._relatedRow(t).css("height","")[0]))},insertAfter:function(e,t){if(e&&t){var n=t.orderId,i={parentId:t.parentId};t.parentId===e.parentId&&t.orderId>e.orderId?i.orderId=n:i.orderId=n+1,this.trigger("reorder",{task:e,updateInfo:i})}},insertBefore:function(e,t){if(e&&t){var n=t.orderId,i={parentId:t.parentId};t.parentId===e.parentId&&t.orderId>e.orderId?i.orderId=n-1:i.orderId=n,this.trigger("reorder",{task:e,updateInfo:i})}},_adjustHeight:function(){var e,t=this.element,n=t.find("."+g.gridContentWrap),i=t.find("."+g.gridHeader),r=kendo.support.scrollbar();this._isHeightSet(t)&&(e=t.height()-a(i),n.height(e),this._hasLockedColumns&&(r=this.table[0].offsetWidth>this.table.parent()[0].clientWidth?r:0,this.lockedContent.height(e-r)))},_adjustRowHeight:function(e,t){var n,i=e.offsetHeight,r=t.offsetHeight;i>r?n=i+"px":i<r&&(n=r+"px"),n&&(e.style.height=t.style.height=n)},_isHeightSet:function(e){var t,n;return!!e[0].style.height||(t=e.height(),e.height("auto"),n=e.height(),e.height(""),t!=n)},_attachCellEditingEventHandlers:function(){var e=this,t=e.options.editable;o.fn._attachCellEditingEventHandlers.call(e),e._isIncellEditable()&&!1!==t.update&&l&&(e.touch=e.content.kendoTouch({filter:"td",touchstart:function(t){e._mouseDownHandler(t.touch)},doubletap:function(t){t.event.target.classList.contains("k-icon")||t.event.target.classList.contains("k-svg-icon")||e._openEditorHandler(t.touch)}}).data("kendoTouch"))},_blurActiveElement:function(){var t=kendo._activeElement();t&&"body"!==t.nodeName.toLowerCase()&&e(t).trigger("blur")},_columns:function(){var e=this,t=this.options.columns;e._hasExpandable=!1,t.forEach((function(t){t.expandable&&(e._hasExpandable=!0)})),e.columns=e.options.columns=n(t,e._eachColumn.bind(e)),o.fn._columns.call(e)},_columnEditor:function(t){var n={name:t.field,required:!0};return n[d]="value:"+t.field,n[c]="date",n[u]=kendo._extractFormat(t.format),function(r,o){var a=o.model,s=(a.fields[t.field]||a[t.field]).validation;s&&s.dateCompare&&i(s.dateCompare)&&s.message&&(e("<span "+kendo.attr("for")+'="'+t.field+'" class="k-invalid-msg"/>').hide().appendTo(r),n[kendo.attr("dateCompare-msg")]=s.message),e('<input type="text"/>').attr(n).prependTo(r).kendoDateTimePicker({format:o.format})}},_columnFromElement:function(e){var t=e.closest("td"),n=t.parent().children().index(t);return this.columns[n]},_eachColumn:function(e){var i=this,r=i.options.resourcesField,o=this.options.sortable;return e.columns&&(i.hasNestedColumns=!0,e.columns=n(e.columns,this._eachColumn.bind(this))),typeof e===h&&(e={field:e,title:f[e]}),!0===e.editable?e.editable=function(){return!0}:e.editable=function(){return!1},"start"!==e.field&&"end"!==e.field||(e.format=kendo.getCulture().calendar.patterns[e.format]||e.format||p,e.editor||(e.format===p||e.format.toLowerCase().indexOf("h")>-1)&&(e.editor=i._columnEditor(e))),e.field===r&&(e.sortable=!1,e.template=e.template||function(e){for(var t=e.get(r)||[],n=[],i=0;i<t.length;i++)n.push(kendo.format("{0} [{1}]",t[i].get("name"),t[i].get("formatedValue")));return n.join(", ")}),i._hasExpandable||"title"!==e.field||(e.expandable=!0),o&&!e.sortable&&(e.sortable=!1),t(new function(){this.field="",this.title="",this.editable=function(){return!1},this.sortable=!1},e)},_editCell:function(e,t,n){var i,r=this,o=r.options.resourcesField,a=r.dataSource._createNewModel(n.toJSON());clearTimeout(r._closeCellTimeout),t.field!==o?r.trigger("beforeEdit",{model:n,container:e})?r.dataSource._restorePageSizeAfterAddChild():(r.closeCell(),n._edit=!0,r._cancelEditor(),r._render({editedColumn:t,editedColumnIndex:e.index()}),i=r.table.add(r.lockedTable).find("."+g.editCell).first(),r.editor=r._createIncellEditor(i,{columns:[t],model:n,change:function(t){r.trigger("save",{values:t.values,container:e,model:n})&&t.preventDefault()}}),r._current=i,r.trigger("edit",{container:e,model:n})):t.editor(e,a)},_modelFromElement:function(e){var t=e.closest("tr");return this.dataSource.getByUid(t.attr(kendo.attr("uid")))},_mouseDownHandler:function(t){e(t.currentTarget).hasClass(g.editCell)||this._blurActiveElement()},_openEditorHandler:function(t){var n=this,i=e(t.currentTarget),r=n.lockedTable&&i.closest("table")[0]===n.lockedTable[0],o=n.selectable&&n.selectable.options.multiple;i.hasClass(g.editCell)||i.has("a.k-grid-delete").length||i.has("button.k-grid-delete").length||i.closest("tbody")[0]!==n.tbody[0]&&!r||e(t.target).is(":input")||e(t.target).is(`[class*=${g.iconExpand}]`)||e(t.target).is(`[class*=${g.iconCollapse}]`)||(n.editor?n.editor.end()&&(o&&e(s()).trigger("blur"),n.closeCell(),n.editCell(i)):n.editCell(i))},_renderTree:function(e){o.fn._render.call(this),this.hasNestedColumns&&this.element.addClass("k-gantt-treelist-nested-columns"),e&&e.length&&!e.editedColumn&&(this.options.rowHeight&&this._rowHeight(e),this.trigger("render")),this._adjustHeight()},_rowHeight:function(t){var n,i=this.content,r=this.options,o=typeof r.rowHeight===h?r.rowHeight:r.rowHeight+"px",s=e(kendo.format(m,o));kendo.applyStylesFromKendoAttributes(s,["height","visibility"]),i.append(s),n=a(s.find("tr")),s.remove(),this.element.find('[role="treegrid"]').css("height",t.length*n+"px")},_setData:function(e){this.dataSource.data(e)},_setWidth:function(){this.element.find(".k-grid-header table").css("minWidth",this.options.listWidth),this.content.find("table").css("minWidth",this.options.listWidth)}});r.plugin(v)}(window.kendo.jQuery);kendo;!function(){var e=window.kendo,t=e.ui.Widget,n=Math.abs,i=t.extend({init:function(n,i){var r=this;function o(e){return function(t){r._triggerTouch(e,t)}}function a(e){return function(t){r.trigger(e,{touches:t.touches,distance:t.distance,center:t.center,event:t.event})}}t.fn.init.call(r,n,i),i=r.options,n=r.element,r.wrapper=n,r.events=new e.UserEvents(n,{filter:i.filter,surface:i.surface,minHold:i.minHold,multiTouch:i.multiTouch,allowSelection:!0,fastTap:i.fastTap,press:o("touchstart"),hold:o("hold"),tap:r._tap.bind(r),gesturestart:a("gesturestart"),gesturechange:a("gesturechange"),gestureend:a("gestureend")}),i.enableSwipe?(r.events.bind("start",r._swipestart.bind(r)),r.events.bind("move",r._swipemove.bind(r))):(r.events.bind("start",r._dragstart.bind(r)),r.events.bind("move",o("drag")),r.events.bind("end",o("dragend"))),e.notify(r)},events:["touchstart","dragstart","drag","dragend","tap","doubletap","hold","swipe","gesturestart","gesturechange","gestureend"],options:{name:"Touch",surface:null,global:!1,fastTap:!1,filter:null,multiTouch:!1,enableSwipe:!1,minXDelta:30,maxYDelta:20,maxDuration:1e3,minHold:800,doubleTapTimeout:800},cancel:function(){this.events.cancel()},destroy:function(){t.fn.destroy.call(this),this.events.destroy()},_triggerTouch:function(e,t){this.trigger(e,{touch:t.touch,event:t.event})&&t.preventDefault()},_tap:function(t){var n=this,i=n.lastTap,r=t.touch;i&&r.endTime-i.endTime<n.options.doubleTapTimeout&&e.touchDelta(r,i).distance<20?(n._triggerTouch("doubletap",t),n.lastTap=null):(n._triggerTouch("tap",t),n.lastTap=r)},_dragstart:function(e){this._triggerTouch("dragstart",e)},_swipestart:function(e){2*n(e.x.velocity)>=n(e.y.velocity)&&e.sender.capture()},_swipemove:function(e){var t=this.options,i=e.touch,r=e.event.timeStamp-i.startTime,o=i.x.initialDelta>0?"right":"left";n(i.x.initialDelta)>=t.minXDelta&&n(i.y.initialDelta)<t.maxYDelta&&r<t.maxDuration&&(this.trigger("swipe",{direction:o,touch:e.touch}),i.cancel())}});e.ui.plugin(i)}(window.kendo.jQuery);kendo;!function(e){var t=kendo.ui.Widget,n=kendo.dom.element,i=kendo.dom.text,r=kendo.dom.html,o=e.isPlainObject,a=kendo._outerWidth,s=kendo._outerHeight,l=e.extend,c=!1,d=kendo.keys,u=kendo.data.Query,h=".kendoGanttTimeline",p="click",f="mousemove",m="mouseenter",g="mouseleave",v=".",_=({start:e})=>kendo.toString(e,"ddd M/dd"),b=({start:e,end:t})=>`${kendo.toString(e,"ddd M/dd")} - ${kendo.toString(kendo.date.addDays(t,-1),"ddd M/dd")}`,y=({start:e})=>kendo.toString(e,"MMM"),w=({styles:e,messages:t,start:n,end:i,format:r})=>`<div class="${e.tooltipWrapper} k-gantt-resize-hint"><div class="${e.tooltipContent}"><div>${kendo.htmlEncode(t.start)}: ${kendo.toString(n,r)}</div><div>${kendo.htmlEncode(t.end)}: ${kendo.toString(i,r)}</div></div></div>`,k=({styles:e,task:t,messages:n})=>`<div class="${kendo.htmlEncode(e.taskDetails)}"><strong>${kendo.htmlEncode(t.title)}</strong><div class="${e.taskDetailsPercent}">${kendo.toString(t.percentComplete,"p0")}</div><ul class="${e.reset}"><li>${kendo.htmlEncode(n.start)}: ${kendo.toString(t.start,"h:mm tt ddd, MMM d")}</li><li>${kendo.htmlEncode(n.end)}: ${kendo.toString(t.end,"h:mm tt ddd, MMM d")}</li></ul></div>`,x=`<table ${kendo.attr("style-visibility")}="hidden"><tbody><tr ${kendo.attr("style-height")}="{0}"><td>&nbsp;</td></tr></tbody></table>`,C={day:{type:"kendo.ui.GanttDayView"},week:{type:"kendo.ui.GanttWeekView"},month:{type:"kendo.ui.GanttMonthView"},year:{type:"kendo.ui.GanttYearView"}};function S(){var t=kendo._activeElement();t&&"body"!==t.nodeName.toLowerCase()&&e(t).trigger("blur")}var T=kendo.ui.GanttView=t.extend({init:function(e,n){t.fn.init.call(this,e,n),this.title=this.options.title||this.options.name,this.header=this.element.find(v+T.styles.gridHeader),this.content=this.element.find(v+T.styles.gridContent),this.contentWidth=this.content.width(),this._workDays=function(e){var t=[],n=e.workWeekStart;for(t.push(n);e.workWeekEnd!=n;)n>6?n-=7:n++,t.push(n);return t}(this.options),this._headerTree=n.headerTree,this._taskTree=n.taskTree,this._taskTemplate=n.taskTemplate?kendo.template(n.taskTemplate,l({},kendo.Template,n.templateSettings)):null,this._dependencyTree=n.dependencyTree,this._taskCoordinates={},this._currentTime()},destroy:function(){t.fn.destroy.call(this),clearTimeout(this._tooltipTimeout),this.headerRow=null,this.header=null,this.content=null,this._dragHint=null,this._resizeHint=null,this._resizeTooltip=null,this._taskTooltip=null,this._percentCompleteResizeTooltip=null,this._headerTree=null,this._taskTree=null,this._dependencyTree=null},options:{showWorkHours:!1,showWorkDays:!1,workDayStart:new Date(1980,1,1,8,0,0),workDayEnd:new Date(1980,1,1,17,0,0),workWeekStart:1,workWeekEnd:5,hourSpan:1,slotSize:100,currentTimeMarker:{updateInterval:1e4}},renderLayout:function(){this._slots=this._createSlots(),this._tableWidth=this._calculateTableWidth(),this.createLayout(this._layout()),this._slotDimensions(),this._adjustHeight(),this.content.find(v+T.styles.dependenciesWrapper).width(this._tableWidth)},_adjustHeight:function(){this.content&&this.content.height(this.element.height()-s(this.header))},createLayout:function(e){var t=this._headers(e),i=this._colgroup(),r=this._headerTree,o=n("tbody",{className:T.styles.tbody},t),a=n("table",{className:T.styles.headerTable,style:{width:this._tableWidth+"px"},role:"presentation"},[i,o]);r.render([a]),this.headerRow=this.header.find("table").first().find("tr").last()},_slotDimensions:function(){for(var e,t,n=this.headerRow[0].children,i=this._timeSlots(),r=0,o=n.length;r<o;r++)t=n[r],(e=i[r]).offsetLeft=t.offsetLeft,e.offsetWidth=t.offsetWidth},render:function(e){var t,n,i=e.length,r=T.styles,o=this._rowsTable(i),a=this._columnsTable(i),s=this._tasksTable(e),l=this.options.currentTimeMarker,c=this.options.calculatedSize;this._taskTree.render([o,a,s]),t=this.content.find(v+r.rowsTable),c&&(n=c.row*e.length,this.content.find(v+r.tasksTable).height(n),t.height(n)),this._contentHeight=t.height(),this._rowHeight=c?c.row:this._contentHeight/t.find("tr").length,this.content.find(v+r.columnsTable).height(this._contentHeight),!1!==l&&void 0!==l.updateInterval&&this._renderCurrentTime()},_rowsTable:function(e){for(var t,r=[],o=T.styles,a=[{className:o.tableRow},{className:o.alt}],s=0;s<e;s++)t=n("tr",a[s%2],[n("td",{className:o.tableCell},[i(" ")])]),r.push(t);return this._createTable(1,r,{className:o.rowsTable+" k-grid-table "+o.table})},_columnsTable:function(){for(var e,t,r,o,a=[],s=T.styles,l=this._timeSlots(),c=l.length,d=0,u=0;u<c;u++)t=l[u],o={className:s.tableCell},d+=r=t.span,1!==r&&(o.colspan=r),t.isNonWorking&&(o.className+=" "+s.nonWorking),a.push(n("td",o,[i(" ")]));return e=n("tr",{className:s.tableRow},a),this._createTable(d,[e],{className:s.columnsTable+" "+s.table})},_tasksTable:function(e){for(var t,i,r,o,a,s,l,d,u,h,p,f=[],m=T.styles,g=this._taskCoordinates={},v=this._calculateMilestoneWidth(),_=Math.round(v.width),b=this.options.resourcesField,y=[m.resource,m.resourceAlt],w=this.options.calculatedSize,k=this._calculateResourcesMargin(),x=this._calculateTaskBorderWidth(),C=this.options.showPlannedTasks,S=[{className:m.tableRow},{className:m.alt}],D=0,A=e.length;D<A;D++)a=e[D],r=this._taskPosition(a),C&&((o=this._taskPositionPlanned(a)).borderWidth=x),r.borderWidth=x,t=n("tr",S[D%2]),i=n("td",{className:m.tableCell}),a.start<=this.end&&a.end>=this.start&&(d=this._renderTask(e[D],r,o),this.options.navigatable&&(d.children[0].attr.tabIndex=D?-1:0),i.children.push(d),a[b]&&a[b].length&&(s=c?this._tableWidth-r.left:Math.max(r.width||v.clientWidth,0)+r.left,(l={width:this._tableWidth-(s+k)+"px"})[c?"right":"left"]=s+"px",w&&(l.height=w.cell+"px"),i.children.push(n("div",{className:m.resourcesWrap,style:l},this._renderResources(a[b],y[D%2])))),u=D,h=void 0,p=void 0,p=(h=r.left)+r.width,a.isMilestone()&&(p=(h-=_/2)+_),g[a.id]={start:h,end:p,rowIndex:u}),t.children.push(i),f.push(t);return this._createTable(1,f,{className:T.styles.tasksTable+" "+m.table})},_createTable:function(e,t,i){for(var r,o,a=[],s=0;s<e;s++)a.push(n("col"));return r=n("colgroup",null,a),o=n("tbody",{className:T.styles.tbody},t),i.style||(i.style={}),i.style.width=this._tableWidth+"px",i.role="presentation",n("table",i,[r,o])},_calculateTableWidth:function(){for(var e,t=this._timeSlots(),n=0,i=0,r=0,o=t.length;r<o;r++)i+=e=t[r].span,e>n&&(n=e);return Math.round(i*this.options.slotSize/n)},_calculateMilestoneWidth:function(){var t,n,i=T.styles.task+" "+T.styles.taskMilestone,r=e(`<div class="${i}">`).css({visibility:"hidden",position:"absolute"});return this.content.append(r),t={width:(n=r[0].getBoundingClientRect()).right-n.left,clientWidth:r[0].clientWidth},r.remove(),t},_calculateResourcesMargin:function(){var t,n=e(`<div class="${T.styles.resourcesWrap}">`).css({visibility:"hidden",position:"absolute"});return this.content.append(n),t=parseInt(n.css(c?"margin-right":"margin-left"),10),n.remove(),t},_calculateTaskBorderWidth:function(){var t,n,i=T.styles.task+" "+T.styles.taskSingle,r=e(`<div class="${i}">`).css({visibility:"hidden",position:"absolute"});return this.content.append(r),n=kendo.getComputedStyles(r[0],["border-left-width"]),t=parseFloat(n["border-left-width"],10),r.remove(),t},_renderTask:function(t,i,r){var o,a,s,l,d,u,h,p,f=this.options.editable,m=i.left,g=T.styles,v=g.taskWrap,_=this.options.calculatedSize,b={},y={className:v,style:{left:m+"px"}},w=[],k=0,x=i.width;return _&&(y.style.height=_.cell+"px"),r&&(l=t.isMilestone()?this._renderPlannedMilestone(i,r):this._renderPlannedSingleTask(i,r,t),w.push(l),c&&r.left<=i.left&&(y.style.left=r.left+"px")),t.summary?(a=this._renderSummary(t,i,r),y.className+=" "+g.taskSummaryWrap):t.isMilestone()?(a=this._renderMilestone(t,i),y.className+=" "+g.taskMilestoneWrap):a=this._renderSingleTask(t,i,r),r&&!t.isMilestone()&&t.plannedStart<t.end&&t.plannedEnd>t.start&&t.plannedEnd<t.end?(x=c?i.left+i.width-r.left:r.left+r.width-i.left,p=c?r.left-i.left:i.left+i.width-(r.left+r.width),h=n("div",{className:g.taskOffset,style:{width:p-2*r.borderWidth+"px"}}),f&&!1!==f.resize&&!1!==f.update&&!t.summary&&(!1!==f.destroy&&h.children.push(n("span",{className:g.taskActions,"aria-hidden":"true"},[n("a",{className:g.link+" "+g.taskDelete,href:"#","aria-label":"Delete"},[n(e(kendo.ui.icon(g.iconDelete))[0])])])),c?h.children.push(n("span",{className:g.taskResizeHandle+" "+g.taskResizeHandleWest,style:{right:i.width-5+"px"}})):h.children.push(n("span",{className:g.taskResizeHandle+" "+g.taskResizeHandleEast}))),u=n("div",{className:g.taskOffsetWrap+" "+g.taskInnerWrap},[a,h]),w.push(u)):r?w.push(n("div",{className:g.taskInnerWrap},[a])):w.push(a),o=n("div",y,w),f&&!1!==f.dependencyCreate&&(r&&t.plannedEnd>t.end&&(k=r.left+r.width-i.left-i.width-3+"px"),o.children.push(n("div",{className:g.taskDot+" "+g.taskDotStart})),c&&(k="auto",r&&t.plannedEnd>t.end&&(d=i.left-r.left+"px")),o.children.push(n("div",{className:g.taskDot+" "+g.taskDotEnd,style:{right:k,left:d}}))),t.summary||t.isMilestone()||!f||!1===f.dragPercentComplete||!1===f.update||null!==this._taskTemplate||(s=Math.round(x*t.percentComplete),b[c?"right":"left"]=s+"px",o.children.push(n("div",{className:g.taskDragHandle,style:b}))),o},_renderSingleTask:function(t,o,a){var s,l,d=T.styles,u=[],h=this.options.editable,p=d.task+" "+d.taskSingle,f=o.width;a&&(t.plannedEnd&&t.plannedEnd<=t.start?p+=" "+d.taskDelayed:t.plannedEnd&&t.plannedEnd>t.end?p+=" "+d.taskAdvanced:t.plannedEnd&&t.plannedEnd<t.end&&(c?f=f+o.left-a.left:f-=o.left+o.width-a.left-a.width)),s=Math.round(f*t.percentComplete),null!==this._taskTemplate?l=r(this._taskTemplate(t)):(l=i(t.title),u.push(n("div",{className:d.taskComplete,style:{width:s+"px"},"aria-hidden":"true"})));var m=n("div",{className:d.taskContent},[n("div",{className:d.taskTemplate},[l])]);return u.push(m),h&&(!1!==h.destroy&&(!a||!t.plannedEnd||t.end<=t.plannedEnd||t.start>=t.plannedEnd)&&m.children.push(n("span",{className:d.taskActions,"aria-hidden":"true"},[n("a",{className:d.link+" "+d.taskDelete,href:"#","aria-label":"Delete"},[n(e(kendo.ui.icon(d.iconDelete))[0])])])),!1!==h.resize&&!1!==h.update&&(m.children.push(n("span",{className:d.taskResizeHandle+" "+d.taskResizeHandleWest})),m.children.push(n("span",{className:d.taskResizeHandle+" "+d.taskResizeHandleEast})))),n("div",{className:p,"data-uid":t.uid,role:"treeitem",style:{width:Math.max(f-2*o.borderWidth,0)+"px"}},u)},_renderMilestone:function(e){var t=T.styles,i=t.task+" "+t.taskMilestone;return this.options.showPlannedTasks&&e.plannedEnd&&e.plannedEnd<e.start?i+=" "+t.taskDelayed:e.plannedStart&&e.plannedStart>e.end&&(i+=" "+t.taskAdvanced),n("div",{className:i,"data-uid":e.uid,role:"treeitem","aria-label":e.title})},_renderSummary:function(e,t,i){var r,o=T.styles,a=t.width,s=o.task+" "+o.taskSummary;return i&&(e.plannedEnd&&e.plannedEnd<=e.start?s+=" "+o.taskDelayed:e.plannedEnd&&e.plannedEnd>e.end?s+=" "+o.taskAdvanced:e.plannedEnd&&e.plannedEnd<e.end&&(c?a=a+t.left-i.left:a-=t.left+t.width-i.left-i.width)),r=Math.round(a*e.percentComplete),n("div",{className:s,"data-uid":e.uid,role:"treeitem","aria-label":e.title,style:{width:a+"px"}},[n("div",{className:o.taskSummaryProgress,style:{width:r+"px"}},[n("div",{className:o.taskSummaryComplete,style:{width:t.width+"px"}})])])},_renderPlannedSingleTask:function(e,t,i){var r=T.styles,o=[],a={};return i.plannedStart&&i.plannedEnd?(o.push(n("div",{className:r.taskPlannedMoment+" "+r.taskPlannedMomentLeft})),o.push(n("div",{className:r.taskPlannedDuration,style:{width:Math.max(t.width-2*t.borderWidth-16,0)+"px"}})),o.push(n("div",{className:r.taskPlannedMoment}))):i.plannedStart?o.push(n("div",{className:r.taskPlannedMoment+" "+r.taskPlannedMomentLeft})):i.plannedEnd&&o.push(n("div",{className:r.taskPlannedMoment,style:{"margin-left":Math.max(t.width-5,0)+"px"}})),a=c?{"margin-right":e.left-t.left+e.width-t.width+"px"}:{"margin-left":t.left-e.left+"px"},n("div",{className:r.taskPlanned,style:a},o)},_renderPlannedMilestone:function(e,t){var i=T.styles,r={};return r=c?{"margin-right":e.left-t.left+"px"}:{"margin-left":t.left-e.left+"px"},n("div",{className:i.taskPlanned,style:r},[n("div",{className:i.taskPlannedMoment})])},_renderResources:function(e,t){for(var r,o=[],a=0,s=e.length;a<s;a++)r=e[a],o.push(n("span",{className:t,style:{color:r.get("color")}},[i(r.get("name"))]));return c&&o.reverse(),o},_taskPosition:function(e){var t=Math.round,n=t(this._offset(c?e.end:e.start));return{left:n,width:t(this._offset(c?e.start:e.end))-n}},_taskPositionPlanned:function(e){var t=Math.round,n=t(this._offset(c?e.plannedEnd:e.plannedStart));return{left:n,width:t(this._offset(c?e.plannedStart:e.plannedEnd))-n}},_offset:function(e){var t,n=this._timeSlots(),i=0;return n.length?((t=n[this._slotIndex("start",e)]).end<e?i=t.offsetWidth:t.start<=e&&(i=(e-t.start)/(t.end-t.start)*t.offsetWidth),c&&(i=t.offsetWidth+1-i),t.offsetLeft+i):0},_slotIndex:function(e,t,n){var i,r=this._timeSlots(),o=0,a=r.length-1;n&&(r=[].slice.call(r).reverse());do{r[i=Math.ceil((a+o)/2)][e]<t?o=i:(i===a&&i--,a=i)}while(o!==a);return n&&(o=r.length-1-o),o},_timeByPosition:function(e,t,n){var i=this._slotByPosition(e);if(t)return n?i.end:i.start;var r=e-this.element.find(v+T.styles.tasksTable).offset().left,o=i.end-i.start,a=r-i.offsetLeft;return c&&(a=i.offsetWidth-a),new Date(i.start.getTime()+o*(a/i.offsetWidth))},_slotByPosition:function(e){var t=e-this.element.find(v+T.styles.tasksTable).offset().left,n=this._slotIndex("offsetLeft",t,c);return this._timeSlots()[n]},_renderDependencies:function(e){for(var t=[],n=this._dependencyTree,i=0,r=e.length;i<r;i++)t.push.apply(t,this._renderDependency(e[i]));n.render(t)},_renderDependency:function(e){var t,n=this._taskCoordinates[e.predecessorId],i=this._taskCoordinates[e.successorId];if(!n||!i)return[];for(var r=0,o=(t=this["_render"+["FF","FS","SF","SS"][c?3-e.type:e.type]](n,i)).length;r<o;r++)t[r].attr["data-uid"]=e.uid;return t},_renderFF:function(e,t){var n=this._dependencyFF(e,t,!1);return n[n.length-1].children[0]=this._arrow(!0),n},_renderSS:function(e,t){var n=this._dependencyFF(t,e,!0);return n[0].children[0]=this._arrow(!1),n.reverse()},_renderFS:function(e,t){var n=this._dependencyFS(e,t,!1);return n[n.length-1].children[0]=this._arrow(!1),n},_renderSF:function(e,t){var n=this._dependencyFS(t,e,!0);return n[0].children[0]=this._arrow(!0),n.reverse()},_dependencyFF:function(e,t,n){var i,r=this,o=[],a=0,s=0,l=0,c=0,d=n?"start":"end",u=this._rowHeight,h=e.rowIndex*u+Math.floor(u/2)-1,p=t.rowIndex*u+Math.floor(u/2)-1,f=T.styles,m=function(){o.push(r._line(f.line+" "+f.lineHorizontal,{left:a+"px",top:s+"px",width:l+"px"}))},g=function(){o.push(r._line(f.line+" "+f.lineVertical,{left:a+"px",top:s+"px",height:c+"px"}))};return a=e[d],s=h,l=10,(i=t[d]-e[d])>0!==n&&(l=Math.abs(i)+10),n?(a-=l,l-=1,m()):(m(),a+=l-2),p<s?(c=s-p,c+=2,s=p,g()):(c=p-s,c+=2,g(),s+=c-2),l=Math.abs(a-t[d]),n||(a-=l-=1),m(),o},_dependencyFS:function(e,t,n){var i=this,r=[],o=0,a=0,s=0,l=0,c=this._rowHeight,d=Math.floor(c/2),u=t.start-e.end,h=e.rowIndex*c+Math.floor(c/2)-1,p=t.rowIndex*c+Math.floor(c/2)-1,f=T.styles,m=function(){r.push(i._line(f.line+" "+f.lineHorizontal,{left:o+"px",top:a+"px",width:s+"px"}))},g=function(){r.push(i._line(f.line+" "+f.lineVertical,{left:o+"px",top:a+"px",height:l+"px"}))};return o=e.end,a=h,s=10,n&&(o+=1,u>20&&(s=u-8),s-=1),m(),o+=s-2,u<=20&&(l=n?Math.abs(p-h)-d:d,p<h?(a-=l,l+=2,g()):(g(),a+=l),(s=e.end-t.start+20)<10&&(s=10),o-=s-2,m()),p<h?(l=a-p,a=p,l+=2,g()):(l=p-a,g(),a+=l),s=t.start-o,n||(s-=1),m(),r},_line:function(e,t){return n("div",{className:e,style:t})},_arrow:function(e){return n("span",{className:e?T.styles.arrowWest:T.styles.arrowEast})},_colgroup:function(){for(var e=this._timeSlots(),t=e.length,i=[],r=0;r<t;r++)for(var o=0,a=e[r].span;o<a;o++)i.push(n("col"));return n("colgroup",null,i)},_createDragHint:function(e){var t,n=T.styles;this._dragHint=e.clone().addClass(n.dragHint).css({cursor:"move"}),(t=this._dragHint.find(v+n.taskPlanned)).css({visibility:"hidden"}),c&&e.find(v+n.taskAdvanced).length>0&&(t.css({"margin-right":"auto",width:0}),this._dragHint.find(v+n.taskDotEnd).css({left:0})),e.closest("td").append(this._dragHint)},_updateDragHint:function(e){var t=this._offset(e);this._dragHint.css({left:t})},_removeDragHint:function(){this._dragHint.remove(),this._dragHint=null},_createResizeHint:function(t){var n,i=T.styles,r=this._taskCoordinates[t.id].rowIndex*this._rowHeight,o=this.options,l=o.messages;this._resizeHint=e((({styles:e})=>`<div class="${e.marquee}"><div class="${e.marqueeColor}"></div></div>`)({styles:i})).css({top:0,height:this._contentHeight}),this.content.append(this._resizeHint),this._resizeTooltip=e(w({styles:i,start:t.start,end:t.end,messages:l.views,format:o.resizeTooltipFormat})).css({"z-index":"100002",top:0,left:0}),this.content.append(this._resizeTooltip),this._resizeTooltipWidth=a(this._resizeTooltip),(n=r-s(this._resizeTooltip))<0&&(n=r+this._rowHeight),this._resizeTooltipTop=n},_updateResizeHint:function(t,n,i){var r=this._offset(c?n:t),o=this._offset(c?t:n),a=o-r,s=i!==c?r:o,l=this._tableWidth-kendo.support.scrollbar(),d=this._resizeTooltipWidth,u=this.options,h=u.messages,p=this.element.find(v+T.styles.tasksTable).offset().left-this.element.find(v+T.styles.tasksWrapper).offset().left;c&&(r+=p),this._resizeHint.css({left:r,width:a}),this._resizeTooltip&&this._resizeTooltip.remove(),(s-=Math.round(d/2))<0?s=0:s+d>l&&(s=l-d),c&&(s+=p),this._resizeTooltip=e(w({styles:T.styles,start:t,end:n,messages:h.views,format:u.resizeTooltipFormat})).css({"z-index":"100002",top:this._resizeTooltipTop,left:s,"min-width":d}).appendTo(this.content)},_removeResizeHint:function(){this._resizeHint.remove(),this._resizeHint=null,this._resizeTooltip.remove(),this._resizeTooltip=null},_updatePercentCompleteTooltip:function(t,n,i){this._removePercentCompleteTooltip();var r=this._percentCompleteResizeTooltip=e((({styles:e,text:t})=>`<div ${kendo.attr("style-z-index")}="100002" class="${e.tooltipWrapper}" ><div class="${e.tooltipContent}">${t}%</div><div class="${e.tooltipCallout}" ${kendo.attr("style-left")}="13px"></div></div>`)({styles:T.styles,text:i}));kendo.applyStylesFromKendoAttributes(r,["z-index","left"]),r.appendTo(this.element);var o=Math.round(a(r)/2),l=r.find(v+T.styles.callout),c=Math.round(a(l)/2);r.css({top:t-(s(r)+c),left:n-o}),l.css("left",o-c)},_removePercentCompleteTooltip:function(){this._percentCompleteResizeTooltip&&this._percentCompleteResizeTooltip.remove(),this._percentCompleteResizeTooltip=null},_updateDependencyDragHint:function(e,t){this._removeDependencyDragHint(),this._creteDependencyDragHint(e,t)},_creteDependencyDragHint:function(t,n){var i=T.styles,r=n.x-t.x,o=n.y-t.y,a=Math.sqrt(r*r+o*o),s=Math.atan(o/r);r<0&&(s+=Math.PI),e("<div class='"+i.line+" "+i.lineHorizontal+" "+i.dependencyHint+"'></div>").css({top:t.y,left:t.x,width:a,"transform-origin":"0% 0","-ms-transform-origin":"0% 0","-webkit-transform-origin":"0% 0",transform:"rotate("+s+"rad)","-ms-transform":"rotate("+s+"rad)","-webkit-transform":"rotate("+s+"rad)"}).appendTo(this.content)},_removeDependencyDragHint:function(){this.content.find(v+T.styles.dependencyHint).remove()},_createTaskTooltip:function(t,n,i){var r=T.styles,o=this.options,a=this.content,l=a.offset(),d=kendo.scrollLeft(a),u=e(n).parents("tr").first(),h=u.offset(),p=o.tooltip&&o.tooltip.template?kendo.template(o.tooltip.template):k,f=c?i-(l.left+d+kendo.support.scrollbar()):i-(l.left-d),m=h.top+s(u)-l.top+a.scrollTop(),g=this._taskTooltip=e('<div class="'+r.tooltipWrapper+'" ><div class="'+r.taskContent+'"></div></div>');g.css({"z-index":"100002",left:f,top:m}).appendTo(a).find(v+r.taskContent).append(p({styles:r,task:t,messages:o.messages.views})),this._adjustTooltipDimensions(g,h,l,f,d)},_removeTaskTooltip:function(){this._taskTooltip&&this._taskTooltip.remove(),this._taskTooltip=null},_createOffsetTooltip:function(t,n,i){var r,o=T.styles,a=this.content,l=a.offset(),d=kendo.scrollLeft(a),u=n.parents("tr").first(),h=u.offset(),p=c?i-(l.left+d+kendo.support.scrollbar()):i-(l.left-d),f=h.top+s(u)-l.top+a.scrollTop(),m=this._offsetTooltip=e('<div class="'+o.tooltipWrapper+'" ></div>'),g=Math.round((t.end.getTime()-t.plannedEnd.getTime())/6e4),v=this.options.messages.plannedTasks,_=g%60,b=_+" "+v.minutes;g>=60&&(b=(r=g=Math.floor(g/60))+" "+v.hours,0!==_&&(b+=" "+_+" "+v.minutes),g>=24&&(r=g%24,b=(g=Math.floor(g/24))+" "+v.days,0!==r&&(b+=" "+r+" "+v.hours))),m.css({"z-index":"100002",left:p,top:f}).addClass(o.offsetTooltipDelay).appendTo(a).append((({offsetPrefix:e,offsetText:t})=>`<span>${e}: ${t}</span>`)({offsetPrefix:v.offsetTooltipDelay,offsetText:b})),this._adjustTooltipDimensions(m,h,l,p,d)},_removeOffsetTooltip:function(){this._offsetTooltip&&this._offsetTooltip.remove(),this._offsetTooltip=null},_createPlannedTooltip:function(t,n,i){var r=T.styles,o=this.content,a=o.offset(),l=kendo.scrollLeft(o),d=n.parents("tr").first(),u=d.offset(),h=c?i-(a.left+l+kendo.support.scrollbar()):i-(a.left-l),p=u.top+s(d)-a.top+o.scrollTop(),f=this._plannedTooltip=e('<div class="'+r.tooltipWrapper+" "+r.plannedTooltip+'" ></div>'),m=this.options.messages.editor;f.css({"z-index":"100002",left:h,top:p}).appendTo(o).append((({plannedStart:e,plannedEnd:t,startDate:n,endDate:i})=>`<div class="k-task-content"><div>${e}: ${n}</div><div>${t}: ${i}</div></div>`)({plannedStart:m.plannedStart,startDate:kendo.toString(t.plannedStart,"H:mm tt ddd, MMM dd"),plannedEnd:m.plannedEnd,endDate:kendo.toString(t.plannedEnd,"H:mm tt ddd, MMM dd")})),this._adjustTooltipDimensions(f,u,a,h,l)},_removePlannedTooltip:function(){this._plannedTooltip&&this._plannedTooltip.remove(),this._plannedTooltip=null},_adjustTooltipDimensions:function(e,t,n,i,r){var o,l=this.content,c=l.width();s(e)<t.top-n.top&&e.css("top",t.top-n.top-s(e)+l.scrollTop()),(o=a(e))+i-r>c&&((i-=o)<r&&(i=r+c-(o+17)),e.css("left",i))},_scrollTo:function(e){var t=e.offset().left,n=e.width(),i=t+n,r=e.closest("tr"),o=r.offset().top,a=o+r.height(),s=this.content,l=s.offset(),c=l.top,d=c+s.height(),u=l.left,h=s.width(),p=u+h,f=kendo.support.scrollbar();o<c?s.scrollTop(s.scrollTop()+(o-c)):a>d&&s.scrollTop(s.scrollTop()+(a+f-d)),t<u&&n>h&&i<p||i>p&&n<h?kendo.scrollLeft(s,kendo.scrollLeft(s)+(i+f-p)):(i>p&&n>h&&t>u||t<u&&n<h)&&kendo.scrollLeft(s,kendo.scrollLeft(s)+(t-u))},_scrollToDate:function(e){var t,n=this.start,i=this.end;e>=n&&e<i&&(t=this._offset(e),kendo.support.isRtl(this.element)&&(t=this._tableWidth-t),kendo.scrollLeft(this.content,t))},_timeSlots:function(){return this._slots&&this._slots.length?this._slots[this._slots.length-1]:[]},_headers:function(e){for(var t,i,o,a,s=[],l=T.styles,c=0,d=e.length;c<d;c++){i=[];for(var u=0,h=(t=e[c]).length;u<h;u++)o=t[u],a=r(o.text),i.push(n("td",{colspan:o.span,className:l.header+(o.isNonWorking?" "+l.nonWorking:"")},[a]));s.push(n("tr",{className:l.tableRow},i))}return s},_hours:function(e,t){var n,i,r,o=[],a=this.options,s=a.workDayStart.getHours(),l=a.workDayEnd.getHours(),c=a.hourSpan;for(e=new Date(e),t=new Date(t),a.showWorkHours&&e.setHours(s);e<t;)i=(r=(n=new Date(e)).getHours())>=s&&r<l,n.setHours(n.getHours()+c),r==n.getHours()&&n.setHours(n.getHours()+2*c),a.showWorkHours&&!i||o.push({start:e,end:n,isNonWorking:!i,span:1}),e=n;return o},_days:function(e,t){var n,i,r=[];for(e=new Date(e),t=new Date(t);e<t;)n=t<kendo.date.nextDay(e)?t:kendo.date.nextDay(e),i=this._isWorkDay(e),this.options.showWorkDays&&!i||r.push({start:e,end:n,isNonWorking:!i,span:1}),e=n;return r},_weeks:function(e,t){var n,i,r,o=[],a=this.calendarInfo().firstDay;for(e=new Date(e),t=new Date(t);e<t;)(n=kendo.date.dayOfWeek(kendo.date.addDays(e,1),a,1))>t&&(n=t),(r=(i=this._days(e,n)).length)>0&&o.push({start:i[0].start,end:i[r-1].end,span:r}),e=n;return o},_months:function(e,t){var n,i,r,o,a=[];for(e=new Date(e),t=new Date(t);e<t;)n=new Date(e),i=kendo.date.firstDayOfMonth(new Date(n.setMonth(n.getMonth()+1))),n=t<i?t:i,(o=(r=this._days(e,n)).length)>0&&a.push({start:r[0].start,end:r[o-1].end,span:o}),e=n;return a},_years:function(e,t){var n,i,r=[];for(e=new Date(e),t=new Date(t);e<t;)n=new Date(e),(n=kendo.date.firstDayOfMonth(new Date(n.setMonth(12))))>=t&&(n=t),i=(n.getMonth()||12)-e.getMonth(),r.push({start:e,end:n,span:i}),e=n;return r},_slotHeaders:function(e,t){for(var n,i=[],r=0,o=e.length;r<o;r++)n=e[r],i.push({text:t(n),isNonWorking:!!n.isNonWorking,span:n.span});return i},_isWorkDay:function(e){for(var t=e.getDay(),n=this._workDays,i=0,r=n.length;i<r;i++)if(n[i]===t)return!0;return!1},calendarInfo:function(){return kendo.getCulture().calendars.standard},_renderCurrentTime:function(){var t,n=this._getCurrentTime(),i=this._offset(n),r=e("<div class='k-current-time'></div>"),o=T.styles,a=this.element.find(v+o.tasksWrapper),s=this.element.find(v+o.tasksTable);this.content&&this._timeSlots().length&&(this.content.find(".k-current-time").remove(),n<(t=this._timeSlots()[this._slotIndex("start",n)]).start||n>t.end||(a.length&&s.length&&(i+=s.offset().left-a.offset().left),r.css({left:i+"px",top:"0px",width:"1px",height:this._contentHeight+"px"}).appendTo(this.content)))},_getCurrentTime:function(){return new Date},_currentTime:function(){var e=this.options.currentTimeMarker;!1!==e&&void 0!==e.updateInterval&&(this._renderCurrentTime(),this._currentTimeUpdateTimer=setInterval(this._renderCurrentTime.bind(this),e.updateInterval))}});l(!0,T,{styles:{alt:"k-alt k-table-row k-table-alt-row",reset:"k-reset",nonWorking:"k-nonwork-hour",header:"k-header k-table-td",gridHeader:"k-grid-header",gridHeaderWrap:"k-grid-header-wrap",gridContent:"k-grid-content",tasksWrapper:"k-gantt-tables",rowsTable:"k-gantt-rows",columnsTable:"k-gantt-columns",tasksTable:"k-gantt-tasks",dependenciesWrapper:"k-gantt-dependencies",resource:"k-resource",resourceAlt:"k-resource k-alt",headerTable:"k-grid-header-table k-table k-table-md",table:"k-table k-table-md",tbody:"k-table-tbody",tableRow:"k-table-row",tableCell:"k-table-td",task:"k-task",taskSingle:"k-task-single",taskMilestone:"k-task-milestone",taskSummary:"k-task-summary",taskWrap:"k-task-wrap",taskMilestoneWrap:"k-milestone-wrap",taskSummaryWrap:"k-summary-wrap",taskPlanned:"k-task-planned",taskPlannedMoment:"k-task-moment",taskPlannedDuration:"k-task-duration",taskPlannedMomentLeft:"k-moment-left",taskAdvanced:"k-task-advanced",taskDelayed:"k-task-delayed",taskOffset:"k-task-offset",taskOffsetWrap:"k-task-offset-wrap",taskInnerWrap:"k-task-inner-wrap",resourcesWrap:"k-resources-wrap",taskDot:"k-task-dot",taskDotStart:"k-task-start",taskDotEnd:"k-task-end",taskDragHandle:"k-task-draghandle",taskContent:"k-task-content",taskTemplate:"k-task-template",taskActions:"k-task-actions",taskDelete:"k-task-delete",taskComplete:"k-task-complete",taskDetails:"k-task-details",taskDetailsPercent:"k-task-pct",link:"k-link",iconDelete:"x",taskResizeHandle:"k-resize-handle",taskResizeHandleWest:"k-resize-w",taskResizeHandleEast:"k-resize-e",taskSummaryProgress:"k-task-summary-progress",taskSummaryComplete:"k-task-summary-complete",line:"k-gantt-line",lineHorizontal:"k-gantt-line-h",lineVertical:"k-gantt-line-v",arrowWest:"k-arrow-w",arrowEast:"k-arrow-e",dragHint:"k-drag-hint",dependencyHint:"k-gantt-dependency-hint",tooltipWrapper:"k-tooltip",tooltipContent:"k-tooltip-content",tooltipCallout:"k-callout k-callout-s",callout:"k-callout",marquee:"k-marquee k-gantt-marquee",marqueeColor:"k-marquee-color",offsetTooltipAdvanced:"k-offset-tooltip-advanced",offsetTooltipDelay:"k-offset-tooltip-delayed",plannedTooltip:"k-planned-tooltip"}}),kendo.ui.GanttDayView=T.extend({name:"day",options:{timeHeaderTemplate:({start:e})=>kendo.toString(e,"t"),dayHeaderTemplate:_,resizeTooltipFormat:"h:mm tt ddd, MMM d"},range:function(e){var t=this.options.range;this.start=kendo.date.getDate(e.start),this.end=kendo.date.getDate(e.end),(kendo.date.getMilliseconds(e.end)>0||this.end.getTime()===this.start.getTime())&&(this.end=kendo.date.addDays(this.end,1)),t&&t.start&&(this.start=kendo.date.getDate(t.start),this.start.setHours(t.start.getHours())),t&&t.end&&(this.end=kendo.date.getDate(t.end),this.end.setHours(t.end.getHours()))},_createSlots:function(){var e,t,n,i,r=[];n=[];for(var o=0,a=(e=this._days(this.start,this.end)).length;o<a;o++)t=e[o],i=this._hours(t.start,t.end),t.span=i.length,n.push.apply(n,i);return r.push(e),r.push(n),r},_layout:function(){var e=[],t=this.options;return e.push(this._slotHeaders(this._slots[0],kendo.template(t.dayHeaderTemplate))),e.push(this._slotHeaders(this._slots[1],kendo.template(t.timeHeaderTemplate))),e}}),kendo.ui.GanttWeekView=T.extend({name:"week",options:{dayHeaderTemplate:_,weekHeaderTemplate:b,resizeTooltipFormat:"h:mm tt ddd, MMM d"},range:function(e){var t,n=this.options.range,i=this.calendarInfo().firstDay,r=e.end;i===r.getDay()&&r.setDate(r.getDate()+7),this.start=kendo.date.getDate(kendo.date.dayOfWeek(e.start,i,-1)),this.end=kendo.date.getDate(kendo.date.dayOfWeek(r,i,1)),n&&n.start&&(this.start=kendo.date.getDate(n.start)),n&&n.end&&(t=new Date(n.end),kendo.date.getDate(t)<n.end?this.end=kendo.date.getDate(new Date(t.setDate(t.getDate()+1))):this.end=kendo.date.getDate(t))},_createSlots:function(){var e=[];return e.push(this._weeks(this.start,this.end)),e.push(this._days(this.start,this.end)),e},_layout:function(){var e=[],t=this.options;return e.push(this._slotHeaders(this._slots[0],kendo.template(t.weekHeaderTemplate))),e.push(this._slotHeaders(this._slots[1],kendo.template(t.dayHeaderTemplate))),e}}),kendo.ui.GanttMonthView=T.extend({name:"month",options:{weekHeaderTemplate:b,monthHeaderTemplate:y,resizeTooltipFormat:"dddd, MMM d, yyyy"},range:function(e){var t,n=this.options.range;this.start=kendo.date.firstDayOfMonth(e.start),this.end=kendo.date.addDays(kendo.date.getDate(kendo.date.lastDayOfMonth(e.end)),1),n&&n.start&&(this.start=kendo.date.getDate(n.start)),n&&n.end&&(t=new Date(n.end),kendo.date.getDate(t)<n.end?this.end=kendo.date.getDate(new Date(t.setDate(t.getDate()+1))):this.end=kendo.date.getDate(t))},_createSlots:function(){var e=[];return e.push(this._months(this.start,this.end)),e.push(this._weeks(this.start,this.end)),e},_layout:function(){var e=[],t=this.options;return e.push(this._slotHeaders(this._slots[0],kendo.template(t.monthHeaderTemplate))),e.push(this._slotHeaders(this._slots[1],kendo.template(t.weekHeaderTemplate))),e}}),kendo.ui.GanttYearView=T.extend({name:"year",options:{yearHeaderTemplate:({start:e})=>kendo.toString(e,"yyyy"),monthHeaderTemplate:y,resizeTooltipFormat:"dddd, MMM d, yyyy"},range:function(e){var t,n=this.options.range;this.start=kendo.date.firstDayOfMonth(new Date(e.start.setMonth(0))),this.end=kendo.date.firstDayOfMonth(new Date(e.end.setMonth(12))),n&&n.start&&(this.start=kendo.date.firstDayOfMonth(n.start)),n&&n.end&&(t=kendo.date.firstDayOfMonth(n.end),this.end=kendo.date.getDate(new Date(t.setMonth(t.getMonth()+1))))},_createSlots:function(){var t=[],n=this._months(this.start,this.end);return e(n).each((function(e,t){t.span=1})),t.push(this._years(this.start,this.end)),t.push(n),t},_layout:function(){var e=[],t=this.options;return e.push(this._slotHeaders(this._slots[0],kendo.template(t.yearHeaderTemplate))),e.push(this._slotHeaders(this._slots[1],kendo.template(t.monthHeaderTemplate))),e}});var D=kendo.ui.GanttTimeline=t.extend({init:function(e,n){t.fn.init.call(this,e,n),this.options.views&&this.options.views.length||(this.options.views=["day","week","month"]),c=kendo.support.isRtl(e),this._wrapper(),this._domTrees(),this._views(),this._selectable(),this._draggable(),this._resizable(),this._percentResizeDraggable(),this._createDependencyDraggable(),this._attachEvents(),this._navigatable(),this._tooltip()},options:{name:"GanttTimeline",messages:{views:{day:"Day",week:"Week",month:"Month",year:"Year",start:"Start",end:"End"}},snap:!0,selectable:!0,editable:!0},destroy:function(){t.fn.destroy.call(this),clearTimeout(this._tooltipTimeout),this._currentTimeUpdateTimer&&clearInterval(this._currentTimeUpdateTimer),this._unbindView(this._selectedView),this._moveDraggable&&this._moveDraggable.destroy(),this._resizeDraggable&&this._resizeDraggable.destroy(),this._percentDraggable&&this._percentDraggable.destroy(),this._dependencyDraggable&&this._dependencyDraggable.destroy(),this.touch&&this.touch.destroy(),this._headerTree=null,this._taskTree=null,this._dependencyTree=null,this.wrapper.off(h),kendo.destroy(this.wrapper)},_findNext:function(e){return e.next().find(".k-task")},_findFirst:function(e){return e.closest(".k-table-tbody").find(".k-task").first()},_findLast:function(e){return e.closest(".k-table-tbody").find(".k-task").last()},_findPrev:function(e){return e.prev().find(".k-task")},_scrollTasks:function(e){var t=this.wrapper,n=kendo.scrollLeft(t.find(".k-grid-content"));kendo.scrollLeft(t.find(".k-grid-content"),n+20*e)},_navigatable:function(){var t=this;t.options.navigatable&&t.wrapper.on("keydown"+h,".k-gantt-tables .k-gantt-tasks .k-task",(function(n){var i,r=e(n.target),o=r.closest(".k-table-row"),a=!1;n.keyCode==d.HOME&&(i=t._findFirst(o)),n.keyCode==d.END&&(i=t._findLast(o)),n.keyCode==d.DOWN&&(i=t._findNext(o)),n.keyCode==d.UP&&(i=t._findPrev(o)),i&&(a=!0,i[0]!==r[0]&&(r.closest(".k-gantt-tasks").find(".k-task").attr("tabindex",-1),i.attr("tabindex",0),i.trigger("focus"))),n.keyCode==d.LEFT&&(n.altKey?r.hasClass("k-task-summary")&&(t.trigger("collapse",{uid:r.attr("data-uid")}),setTimeout((function(){t.select().trigger("focus")}),1)):t._scrollTasks(-1),a=!0),n.keyCode==d.RIGHT&&(n.altKey?r.hasClass("k-task-summary")&&(t.trigger("expand",{uid:r.attr("data-uid")}),setTimeout((function(){t.select().trigger("focus")}),1)):t._scrollTasks(1),a=!0),n.keyCode==d.ENTER&&(a=!0,!1!==t.options.editable.update&&(t.trigger("editTask",{uid:r.attr("data-uid")}),n.stopPropagation())),n.keyCode==d.DELETE&&(a=!0,!1!==t.options.editable.update&&(t.trigger("removeTask",{uid:r.attr("data-uid")}),n.stopPropagation())),a&&n.preventDefault()})).on(p+h,v+D.styles.task,(function(n){n.preventDefault();var i=e(this);t.wrapper.find(v+D.styles.task).attr("tabindex","-1"),i.attr("tabindex","0").trigger("focus")}))},_wrapper:function(){var t,n,i,r,o,a=D.styles,l=this,c=this.options;this.wrapper=this.element.addClass(a.wrapper).append("<div class='"+a.gridHeader+"'><div class='"+a.gridHeaderWrap+"'></div></div>").append("<div role='tree' class='"+a.gridContentWrap+"'><div class='"+a.tasksWrapper+"'></div><div class='"+a.dependenciesWrapper+"'></div></div>"),c.rowHeight&&(this._calculatedSize=(i="string"==typeof c.rowHeight?c.rowHeight:c.rowHeight+"px",r=e(kendo.format(x,i)),o=l.wrapper.find(v+a.tasksWrapper),kendo.applyStylesFromKendoAttributes(r,["height","visibility"]),o.append(r),t=s(r.find("tr")),n=r.find("td").height(),r.remove(),{row:t,cell:n}))},_domTrees:function(){var e=D.styles,t=kendo.dom.Tree,n=this.wrapper;this._headerTree=new t(n.find(v+e.gridHeaderWrap)[0]),this._taskTree=new t(n.find(v+e.tasksWrapper)[0]),this._dependencyTree=new t(n.find(v+e.dependenciesWrapper)[0])},_views:function(){var e,t,n,i,r,a=this.options.views;this.views={};for(var s=0,c=a.length;s<c;s++)e=a[s],(t=o(e))&&!1===e.selectable||(n=t?"string"!=typeof e.type?e.title:e.type:e,(i=C[n])&&(t&&(e.type=i.type),i.title=this.options.messages.views[n]),e=l({title:n},i,t?e:{}),n&&(this.views[n]=e,r&&!e.selected||(r=n)));r&&(this._selectedViewName=r)},view:function(e){return e&&(this._selectView(e),this.trigger("navigate",{view:e,action:"changeView"})),this._selectedView},_selectView:function(e){e&&this.views[e]&&(this._selectedView&&this._unbindView(this._selectedView),this._selectedView=this._initializeView(e),this._selectedViewName=e)},_viewByIndex:function(e){var t,n=this.views;for(t in n){if(!e)return t;e--}},_initializeView:function(e){var t=this.views[e];if(t){var n=t.type;if("string"==typeof n&&(n=kendo.getter(t.type)(window)),!n)throw new Error("There is no such view");var i={};l(i,this.options.range,t.range);var r=t.date||this.options.date;t=new n(this.wrapper,function(e){return delete e.name,delete e.prefix,delete e.views,e}(l(!0,{headerTree:this._headerTree,taskTree:this._taskTree,dependencyTree:this._dependencyTree,calculatedSize:this._calculatedSize},t,this.options,{date:r,range:i})))}return t},_unbindView:function(e){e&&e.destroy()},_range:function(e){if(!e||!e.length)return{start:new Date,end:new Date};var t=new u(e).sort({field:"start",dir:"asc"}).toArray()[0].start||new Date,n=new u(e).sort({field:"end",dir:"desc"}).toArray()[0].end||new Date;return{start:new Date(t),end:new Date(n)}},_render:function(e){var t=this.view(),n=this._range(e),i=t.options.date;this._tasks=e,t.range(n),t.renderLayout(),t.render(e),i&&t._scrollToDate(i)},_renderDependencies:function(e){this.view()._renderDependencies(e)},_taskByUid:function(e){for(var t,n=this._tasks,i=n.length,r=0;r<i;r++)if((t=n[r]).uid===e)return t},_draggable:function(){var e,t,n,i,r=this,o=this.options.snap,a=D.styles,s=this.options.editable,l=function(){r.view()._removeDragHint(),e&&e.css("opacity",1),e=null,t=null,r.dragInProgress=!1};s&&!1!==s.move&&!1!==s.update&&(this._moveDraggable=new kendo.ui.Draggable(this.wrapper,{distance:0,filter:v+a.task+","+v+a.taskOffset,holdToDrag:kendo.support.mobileOS,ignore:v+a.taskResizeHandle}),this._moveDraggable.bind("dragstart",(function(s){var l=r.view();e=s.currentTarget.closest(v+a.taskWrap),t=r._taskByUid(s.currentTarget.parent().find(v+a.task).attr("data-uid")),r.trigger("moveStart",{task:t})?s.preventDefault():(n=t.start,i=l._timeByPosition(s.x.location,o)-n,l._createDragHint(e),e.css("opacity",.5),clearTimeout(r._tooltipTimeout),r.dragInProgress=!0)})).bind("drag",kendo.throttle((function(e){if(r.dragInProgress){var a=r.view(),s=new Date(a._timeByPosition(e.x.location,o)-i),l=s;r.trigger("move",{task:t,start:s})||(n=s,c&&(l=new Date(n.getTime()+t.duration())),a._updateDragHint(l))}}),15)).bind("dragend",(function(){r.trigger("moveEnd",{task:t,start:n}),l()})).bind("dragcancel",(function(){l()})).userEvents.bind("select",(function(){S()})))},_resizable:function(){var e,t,n,i,r,o=this,a=this.options.snap,s=D.styles,l=this.options.editable,d=function(){o.view()._removeResizeHint(),e=null,t=null,o.dragInProgress=!1};l&&!1!==l.resize&&!1!==l.update&&(this._resizeDraggable=new kendo.ui.Draggable(this.wrapper,{distance:0,filter:v+s.taskResizeHandle,holdToDrag:!1}),this._resizeDraggable.bind("dragstart",(function(a){r=a.currentTarget.hasClass(s.taskResizeHandleWest),c&&(r=!r),e=a.currentTarget.closest(v+s.taskWrap).find(v+s.task),t=o._taskByUid(e.attr("data-uid")),o.trigger("resizeStart",{task:t})?a.preventDefault():(n=t.start,i=t.end,o.view()._createResizeHint(t),clearTimeout(o._tooltipTimeout),o.dragInProgress=!0)})).bind("drag",kendo.throttle((function(e){if(o.dragInProgress){var s=o.view(),l=s._timeByPosition(e.x.location,a,!r);r?n=l<i?l:i:i=l>n?l:n,o.trigger("resize",{task:t,start:n,end:i})||s._updateResizeHint(n,i,r)}}),15)).bind("dragend",(function(){o.trigger("resizeEnd",{task:t,resizeStart:r,start:n,end:i}),d()})).bind("dragcancel",(function(){d()})).userEvents.bind("select",(function(){S()})))},_percentResizeDraggable:function(){var e,t,n,i,r,o,s,l,d,u,h=this,p=D.styles,f=this.options.editable,m=function(){h.view()._removePercentCompleteTooltip(),t=null,e=null,h.dragInProgress=!1},g=function(e){var n=t.siblings(v+p.taskDragHandle);n.length||(n=t.closest(v+p.taskWrap).find(v+p.taskDragHandle)),n.css(c?"right":"left",e),t.find(v+p.taskComplete).width(e)};f&&!1!==f.dragPercentComplete&&!1!==f.update&&(this._percentDraggable=new kendo.ui.Draggable(this.wrapper,{distance:0,filter:v+p.taskDragHandle,holdToDrag:!1}),this._percentDraggable.bind("dragstart",(function(l){h.trigger("percentResizeStart")?l.preventDefault():((t=l.currentTarget.siblings(v+p.task)).length||(t=l.currentTarget.closest(v+p.taskWrap).find(v+p.task)),e=h._taskByUid(t.attr("data-uid")),s=e.percentComplete,n=t.offset(),i=this.element.offset(),r=t.find(v+p.taskComplete).width(),o=a(t),clearTimeout(h._tooltipTimeout),h.dragInProgress=!0)})).bind("drag",kendo.throttle((function(e){if(h.dragInProgress){u=c?-e.x.initialDelta:e.x.initialDelta;var t=Math.max(0,Math.min(o,r+u));s=Math.round(t/o*100),g(t),l=n.top-i.top,d=n.left+t-i.left,c&&(d+=o-2*t),h.view()._updatePercentCompleteTooltip(l,d,s)}}),15)).bind("dragend",(function(){h.trigger("percentResizeEnd",{task:e,percentComplete:s/100}),m()})).bind("dragcancel",(function(){g(r),m()})).userEvents.bind("select",(function(){S()})))},_createDependencyDraggable:function(){var t,n,i,r=this,o=e(),l=e(),c=D.styles,d=this.options.editable,u=function(){t.css("display","").removeClass(c.hovered),t.parent().removeClass(c.origin),t=null,h(!1),l=e(),o=e(),r.view()._removeDependencyDragHint(),r.dragInProgress=!1},h=function(e){l.hasClass(c.origin)||(l.find(v+c.taskDot).css("display",e?"block":""),o.toggleClass(c.hovered,e))};d&&!1!==d.dependencyCreate&&(this._dependencyDraggable=new kendo.ui.Draggable(this.wrapper,{distance:0,filter:v+c.taskDot,holdToDrag:!1}),this._dependencyDraggable.bind("dragstart",(function(e){if(r.trigger("dependencyDragStart"))e.preventDefault();else{(t=e.currentTarget.css("display","block").addClass(c.hovered)).parent().addClass(c.origin);var o=t.offset(),l=r.wrapper.find(v+c.tasksWrapper).offset();n=Math.round(o.left-l.left+s(t)/2),i=Math.round(o.top-l.top+a(t)/2),clearTimeout(r._tooltipTimeout),r.dragInProgress=!0}})).bind("drag",kendo.throttle((function(t){if(r.dragInProgress){r.view()._removeDependencyDragHint();var a=e(kendo.elementUnderCursor(t)),s=r.wrapper.find(v+c.tasksWrapper).offset(),d=t.x.location-s.left,u=t.y.location-s.top;r.view()._updateDependencyDragHint({x:n,y:i},{x:d,y:u}),h(!1),o=a.hasClass(c.taskDot)?a:e(),l=a.closest(v+c.taskWrap),h(!0)}}),15)).bind("dragend",(function(){if(o.length){var e=t.hasClass(c.taskDotStart),n=o.hasClass(c.taskDotStart),i=e?n?3:2:n?1:0,a=t.siblings(v+c.task);a.length||(a=t.closest(v+c.taskWrap).find(v+c.task));var s=r._taskByUid(a.attr("data-uid")),l=o.siblings(v+c.task);l.length||(l=o.closest(v+c.taskWrap).find(v+c.task));var d=r._taskByUid(l.attr("data-uid"));s!==d&&r.trigger("dependencyDragEnd",{type:i,predecessor:s,successor:d})}u()})).bind("dragcancel",(function(){u()})).userEvents.bind("select",(function(){S()})))},_selectable:function(){var t=this,n=D.styles;this.options.selectable&&this.wrapper.on(p+h,v+n.task+","+v+n.taskOffset,(function(i){i.stopPropagation();var r=e(this).attr("data-uid");r||(r=e(this).closest(v+n.taskWrap).find(v+n.task).data("uid")),i.ctrlKey?t.trigger("clear"):t.trigger("select",{uid:r})})).on(p+h,v+n.taskWrap,(function(t){t.stopPropagation(),e(this).css("z-index","0");var i=e(document.elementFromPoint(t.clientX,t.clientY));i.hasClass(n.line)&&i.click(),e(this).css("z-index","")})).on(p+h,v+n.tasksWrapper,(function(){t.selectDependency().length>0?t.clearSelection():t.trigger("clear")})).on(p+h,v+n.line,(function(e){e.stopPropagation(),t.selectDependency(this)}))},select:function(e){var t=this.wrapper.find(e),n=D.styles;return t.length?(this.clearSelection(),t.addClass(n.selected),void(kendo.support.mobileOS&&t.parent().addClass(n.taskWrapActive))):this.wrapper.find(v+n.task+v+n.selected)},selectDependency:function(t){var n,i=this.wrapper.find(t),r=D.styles;return i.length?(this.clearSelection(),this.trigger("clear"),n=e(i).attr("data-uid"),void this.wrapper.find(v+r.line+"[data-uid='"+n+"']").addClass(r.selected)):this.wrapper.find(v+r.line+v+r.selected)},clearSelection:function(){var e=D.styles;this.wrapper.find(v+e.selected).removeClass(e.selected),kendo.support.mobileOS&&this.wrapper.find(v+e.taskWrapActive).removeClass(e.taskWrapActive)},_attachEvents:function(){var t=this,n=D.styles;this.options.editable&&(this.wrapper.on(p+h,v+n.taskDelete,(function(i){t.trigger("removeTask",{uid:e(this).closest(v+n.taskWrap).find(v+n.task).attr("data-uid")}),i.stopPropagation(),i.preventDefault()})).on("keydown"+h,(function(e){var n,i=t.options.editable;e.keyCode===d.DELETE&&i&&!1!==i.dependencyDestroy&&(n=t.selectDependency()).length&&(t.trigger("removeDependency",{uid:n.attr("data-uid")}),t.clearSelection())})),kendo.support.mobileOS?this.touch=this.wrapper.kendoTouch({filter:v+n.task+","+v+n.taskOffset,doubletap:function(i){!1!==t.options.editable.update&&t.trigger("editTask",{uid:e(i.touch.currentTarget).closest(v+n.taskWrap).find(v+n.task).attr("data-uid")})}}).data("kendoTouch"):this.wrapper.on("dblclick"+h,v+n.task+","+v+n.taskOffset,(function(i){!1!==t.options.editable.update&&(t.trigger("editTask",{uid:e(this).closest(v+n.taskWrap).find(v+n.task).attr("data-uid")}),i.stopPropagation(),i.preventDefault())})))},_tooltip:function(){var t,n=this,i=this.options.tooltip,r=D.styles,o=function(e){t=e.clientX};i&&!1===i.visible||(kendo.support.mobileOS?(this.wrapper.on(p+h,v+r.taskDelete,(function(e){e.stopPropagation(),n.view()._removeTaskTooltip()})).on(g+h,v+r.task,(function(t){0===e(t.relatedTarget).parents(v+r.taskWrap,v+r.task).length&&n.view()._removeTaskTooltip()})).on(g+h,v+r.taskOffset,(function(t){0===e(t.relatedTarget).parents(v+r.taskWrap,v+r.task).length&&n.view()._removeOffsetTooltip()})).on(g+h,v+r.taskPlanned,(function(t){0===e(t.relatedTarget).parents(v+r.taskWrap,v+r.task).length&&n.view()._removePlannedTooltip()})),this.touch&&this.touch.bind("tap",(function(t){var i,o=e(t.touch.target),a=t.touch.x.client;o.hasClass(r.task)?(i=n._taskByUid(o.attr("data-uid")),n.view()._taskTooltip&&n.view()._removeTaskTooltip(),n.view()._createTaskTooltip(i,o,a)):(i=n._taskByUid(o.closest(v+r.taskWrap).find(v+r.task).attr("data-uid")),n.view()._offsetTooltip&&n.view()._removeOffsetTooltip(),n.view()._createOffsetTooltip(i,o,a))})).bind("doubletap",(function(){n.view()._removeTaskTooltip(),n.view()._removeOffsetTooltip()}))):this.wrapper.on(m+h,v+r.task,(function(){var i=this,r=n._taskByUid(e(this).attr("data-uid"));n.dragInProgress||(n._tooltipTimeout=setTimeout((function(){n.view()._createTaskTooltip(r,i,t)}),800),e(this).on(f,o))})).on(g+h,v+r.task,(function(){clearTimeout(n._tooltipTimeout),n.view()._removeTaskTooltip(),e(this).off(f,o)})).on(m+h,v+r.taskOffset,(function(){var i=e(this).closest(v+r.taskWrap).find(v+r.task),a=n._taskByUid(i.attr("data-uid"));n.dragInProgress||(n._offsetTooltipTimeout=setTimeout((function(){n.view()._createOffsetTooltip(a,i,t)}),800),e(this).on(f,o))})).on(g+h,v+r.taskOffset,(function(){clearTimeout(n._offsetTooltipTimeout),n.view()._removeOffsetTooltip(),e(this).off(f,o)})).on(m+h,v+r.taskPlanned,(function(){var i=e(this).closest(v+r.taskWrap).find(v+r.task),a=n._taskByUid(i.attr("data-uid"));n._plannedTooltipTimeout=setTimeout((function(){n.view()._createPlannedTooltip(a,i,t)}),800),e(this).on(f,o)})).on(g+h,v+r.taskPlanned,(function(){clearTimeout(n._plannedTooltipTimeout),n.view()._removePlannedTooltip(),e(this).off(f,o)})))},_setPlanned:function(e){this.options.showPlannedTasks=e,this.view().options.showPlannedTasks=e}});l(!0,D,{styles:{wrapper:"k-gantt-timeline k-grid",gridHeader:"k-grid-header",gridHeaderWrap:"k-grid-header-wrap",gridContent:"k-grid-content",gridContentWrap:"k-grid-content",tasksWrapper:"k-gantt-tables",dependenciesWrapper:"k-gantt-dependencies",task:"k-task",taskOffset:"k-task-offset",taskOffsetWrap:"k-task-offset-wrap",taskPlanned:"k-task-planned",line:"k-gantt-line",taskResizeHandle:"k-resize-handle",taskResizeHandleWest:"k-resize-w",taskDragHandle:"k-task-draghandle",taskComplete:"k-task-complete",taskDelete:"k-task-delete",taskWrapActive:"k-task-wrap-active",taskWrap:"k-task-wrap",taskDot:"k-task-dot",taskDotStart:"k-task-start",taskDotEnd:"k-task-end",hovered:"k-hover",selected:"k-selected",origin:"k-origin"}})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.keys,r="matchMedia"in window,o=n.support.mobileOS,a=n.ui.Widget,s=n.htmlEncode,l=n.data.ObservableObject,c=n.data.ObservableArray,d=n.data.Query,u=Array.isArray,h=n.isFunction,p=e.extend,f=e.isPlainObject,m=n._outerWidth,g=n._outerHeight,v=".kendoGantt",_="tabIndex",b="string",y=".",w=({label:e,styles:t,views:i})=>`<select aria-label="${e}" class="k-dropdown k-picker k-dropdown-list ${t.viewsDropdown} ${t.viewsDropdownDefaults}">${Object.keys(i).map((e=>'<option value="'+e+'">'+n.htmlEncode(i[e].title)+"</option>")).join("")}</select>`,k=[{data:"add",text:"addChild"},{data:"insert-before",text:"insertBefore"},{data:"insert-after",text:"insertAfter"}],x={wrapper:"k-gantt",plannedTasks:"k-gantt-planned",rowHeight:"k-gantt-rowheight",content:"k-gantt-content",listWrapper:"k-gantt-treelist",list:"k-gantt-treelist",timelineWrapper:"k-gantt-timeline-pane",timeline:"k-gantt-timeline-pane",splitBar:"k-splitbar",splitter:"k-splitter",popupWrapper:"k-list-container",popupList:"k-list k-reset",resizeHandle:"k-resize-handle",icon:"k-icon",item:"k-item",line:"k-gantt-line",buttonDelete:"k-gantt-delete",buttonCancel:"k-gantt-cancel",buttonSave:"k-gantt-update",buttonToggle:"k-gantt-toggle",buttonDefaults:"k-button-md k-rounded-md k-button-solid",primary:"k-button-solid-primary",hovered:"k-hover",selected:"k-selected",focused:"k-focus",focusedCell:"k-focus",gridHeader:"k-grid-header",gridHeaderWrap:"k-grid-header-wrap",gridContent:"k-grid-content",tasks:"k-gantt-tasks",popup:{form:"k-popup-edit-form",editForm:"k-gantt-edit-form",formContainer:"k-edit-form-container",resourcesFormContainer:"k-resources-form-container",message:"k-popup-message",buttonsContainer:"k-edit-buttons",button:"k-button",editField:"k-edit-field",editLabel:"k-edit-label",resourcesField:"k-gantt-resources"},toolbar:{headerWrapper:"k-gantt-header k-gantt-toolbar",footerWrapper:"k-gantt-footer k-gantt-toolbar",toolbar:"k-gantt-toolbar",views:"k-gantt-views",viewsWrapper:"k-gantt-views-wrapper",viewsDropdown:"k-views-dropdown",viewsDropdownDefaults:"k-picker-solid k-rounded-md",button:"k-button",buttonToggle:"k-gantt-toggle",buttonDefaults:"k-button-md k-rounded-md k-button-solid",iconPlus:"plus",iconPdf:"file-pdf",iconToggle:"layout-1-by-4",viewButton:"k-view",link:"k-link",pdfButton:"k-gantt-pdf",appendButton:"k-gantt-create"}};function C(e){return"["+n.attr("uid")+(e?"='"+e+"']":"]")}function S(t,i){var r=t.parents("["+n.attr("role")+'="gantt"]'),o=[],a=function(t){return e(t).parentsUntil("body").filter((function(e,t){return"visible"!=n.getComputedStyles(t,["overflow"]).overflow})).add(window)}(r);t.attr(_,0),i&&a.each((function(t,n){o[t]=e(n).scrollTop()}));try{t[0].setActive()}catch(e){t[0].focus()}i&&a.each((function(t,n){e(n).scrollTop(o[t])}))}var T=a.extend({init:function(e,t,i){u(t)&&(t={dataSource:t}),a.fn.init.call(this,e,t),i&&(this._events=i),this._wrapper(),this._resources(),this.options.views&&this.options.views.length||(this.options.views=["day","week","month"]),this._timeline(),this._processDefaults(),this._toolbar(),this._footer(),this._splitter(),this._adjustDimensions(),this._preventRefresh=!0,this.view(this.timeline._selectedViewName),this._preventRefresh=!1,this._dataSource(),this._assignments(),this._list(),this._dependencies(),this._scrollable(),this._dataBind(),this._attachEvents(),this._createEditor(),n.notify(this),this._showWatermarkOverlay&&this._showWatermarkOverlay(this.wrapper[0])},events:["dataBinding","dataBound","add","edit","remove","cancel","save","change","navigate","moveStart","move","moveEnd","resizeStart","resize","resizeEnd","columnHide","columnReorder","columnResize","columnShow","togglePlannedTasks"],options:{name:"Gantt",autoBind:!0,navigatable:!0,selectable:!0,editable:!0,resizable:!1,columnResizeHandleWidth:3,columns:[],views:[],dataSource:{},dependencies:{},resources:{},assignments:{},taskTemplate:null,tooltip:{visible:!0},messages:{save:"Save",cancel:"Cancel",destroy:"Delete",deleteTaskConfirmation:"Are you sure you want to delete this task?",deleteDependencyConfirmation:"Are you sure you want to delete this dependency?",deleteTaskWindowTitle:"Delete task",deleteDependencyWindowTitle:"Delete dependency",selectView:"Select view",views:{day:"Day",week:"Week",month:"Month",year:"Year",start:"Start",end:"End"},actions:{append:"Add Task",addChild:"Add Child",insertBefore:"Add Above",insertAfter:"Add Below",pdf:"Export to PDF",toggle:"Toggle pane"},editor:{editorTitle:"Task",resourcesEditorTitle:"Resources",title:"Title",start:"Start",end:"End",plannedStart:"Planned Start",plannedEnd:"Planned End",percentComplete:"Complete",resources:"Resources",assignButton:"Assign",resourcesHeader:"Resources",unitsHeader:"Units",parent:"Parent",addNew:"Add",name:"Name",percentCompleteHint:"value from 0 to 1",remove:"Remove",actualStart:"Actual Start",actualEnd:"Actual End",parentOptionLabel:"-None-",general:"General",predecessors:"Predecessors",successors:"Successors",other:"Other",dependencyType:"Type"},plannedTasks:{switchText:"Planned Tasks",offsetTooltipAdvanced:"Met deadline earlier",offsetTooltipDelay:"Delay",seconds:"seconds",minutes:"minutes",hours:"hours",days:"days"}},showWorkHours:!0,showWorkDays:!0,toolbar:null,workDayStart:new Date(1980,1,1,8,0,0),workDayEnd:new Date(1980,1,1,17,0,0),workWeekStart:1,workWeekEnd:5,hourSpan:1,snap:!0,height:600,listWidth:"30%",rowHeight:null,showPlannedTasks:!1},select:function(e){var t=this.list;if(!e)return t.select();typeof e===b&&(e=t.content.find(e)),t.select(e),this._selectionUpdate()},clearSelection:function(){this.list.clearSelection(),this._selectionUpdate()},destroy:function(){a.fn.destroy.call(this),this.dataSource&&(this.dataSource.unbind("change",this._refreshHandler),this.dataSource.unbind("progress",this._progressHandler),this.dataSource.unbind("error",this._errorHandler)),this.dependencies&&(this.dependencies.unbind("change",this._dependencyRefreshHandler),this.dependencies.unbind("error",this._dependencyErrorHandler)),this.timeline&&(this.timeline.unbind(),this.timeline.destroy()),this.list&&(this.list.unbind(),this.list.destroy()),this.toolbar&&this.toolbar.getKendoToolBar()&&this.toolbar.getKendoToolBar().destroy(),this.footer&&this.footer.getKendoToolBar()&&this.footer.getKendoToolBar().destroy(),this._editor&&this._editor.destroy(),this._resourceEditorWindow&&this._resourceEditorWindow.destroy(),this._resizeDraggable&&this._resizeDraggable.destroy(),this.layout&&this._getGanttSplitter()&&this._getGanttSplitter().destroy(),this.toolbar.off(v),r&&(this._mediaQuery.removeListener(this._mediaQueryHandler),this._mediaQuery=null),e(window).off("resize"+v,this._resizeHandler),e(this.wrapper).off(v),this.toolbar=null,this.footer=null,n.destroy(this.element)},setOptions:function(t){var i=n.deepExtend({},this.options,t),r=this._events;if(!t.views){var o=this.view().name;i.views=e.map(this.options.views,(function(e){var t=f(e),n=t?"string"!=typeof e.type?e.title:e.type:e;return o===n?t?e.selected=!0:e={type:n,selected:!0}:t&&(e.selected=!1),e}))}t.dataSource||(i.dataSource=this.dataSource),t.dependencies||(i.dependencies=this.dependencies),t.resources||(i.resources=this.resources),t.assignments||(i.assignments=this.assignments),this.destroy(),this.element.empty(),this.options=null,this.init(this.element,i,r),a.fn._setEvents.call(this,i)},_attachEvents:function(){this._resizeHandler=this.resize.bind(this,!1),e(window).on("resize"+v,this._resizeHandler),r&&this._mediaQueryHandler({matches:this._mediaQuery.matches})},_splitter:function(){this.splitter=this.layout.find(".k-gantt-splitter").kendoSplitter({navigatable:this.options.navigatable,orientation:"horizontal",panes:[{collapsible:!1,scrollable:!1,label:"Gantt List",size:this.options.listWidth},{collapsible:!1,scrollable:!1,label:"Gantt Timeline"}]}).getKendoSplitter(),this.options.listWidth&&this.splitter.size(".k-pane:first",this.options.listWidth)},_getGanttSplitter:function(){return this.layout.find(".k-gantt-splitter").getKendoSplitter()},_wrapper:function(){var t=T.styles,n=this.options,i=n.height,r=n.width;this.wrapper=this.element.addClass(t.wrapper).attr("role","application");let o=e("<div class='k-gantt-splitter'></div>").append("<div class='"+t.listWrapper+"'><div></div></div>").append("<div class='"+t.timelineWrapper+"'><div></div></div>");this.layout=e("<div class='"+t.content+"'></div>").appendTo(this.wrapper).append(o),n.showPlannedTasks&&this.wrapper.addClass(t.plannedTasks),i&&this.wrapper.css("height",i),r&&this.wrapper.css("width",r),n.rowHeight&&this.wrapper.addClass(t.rowHeight),this.treelistWrapper=this.wrapper.find(y+t.list),this.timelineWrapper=this.wrapper.find(y+t.timeline),this.treelistWrapper.css("width",n.listWidth),this.timelineWrapper.css("width",this.wrapper.width()-this.treelistWrapper.outerWidth())},_viewClickHandler:function(e){var t=this.list,i=e.target.attr(n.attr("name"));t.editor&&!t.editor.end()||(this.trigger("navigate",{view:i})?e.preventDefault():this.view(i))},_togglePane:function(e){var t=this,n=t.treelistWrapper,i=t.timelineWrapper,r=y+x.gridContent;e.preventDefault(),n.is(":visible")?(n.addClass("k-hidden"),i.removeClass("k-hidden"),t.refresh(),i.find(r).scrollTop(t.scrollTop)):(n.removeClass("k-hidden"),i.addClass("k-hidden"),n.find(r).scrollTop(t.scrollTop)),t._resize()},_processDefaults:function(){var t=this,i=t.timeline.views,r=n.ns,o=[],a=T.styles.toolbar,s=this.options.messages.actions,l={append:{name:"append",type:"dropDownButton",menuButtons:k.map((e=>({text:s[e.text],attributes:{"data-type":e.data}}))),icon:a.iconPlus,attributes:{class:a.appendButton},click:t._addClickHandler.bind(t),open:t._openAddClickHandler.bind(t)},pdf:{name:"pdf",type:"button",attributes:{class:a.pdfButton},icon:a.iconPdf,click:t.saveAsPDF.bind(t)},toggle:{name:"toggle",type:"button",showText:"overflow",attributes:{class:"k-gantt-toggle"},icon:a.iconToggle,click:t._togglePane.bind(t)},switchLabel:{template:"<label for=planned-switch>"+t.options.messages.plannedTasks.switchText+"</label>"},plannedTasks:{type:"component",component:"Switch",element:"<input id='planned-switch' class='k-gantt-planned-switch'>",componentOptions:{checked:t.options.showPlannedTasks,change:t._togglePlannedTasks.bind(t),messages:{checked:"",unchecked:""}}},viewsDdl:{template:w({views:t.timeline.views,styles:a,label:t.options.messages.selectView})},view:{name:"view",type:"button",togglable:!0,group:"views"},viewsGroup:{type:"buttonGroup",attributes:{class:a.views}}};Object.keys(i).map((t=>{var n=e.extend(!0,{},l.view);n.text=i[t].title,n.attributes={class:"k-view-"+t.toLowerCase()},n.attributes["data"+r+"-name"]=t,l[t]=n,o.push(t)})),Object.values(l).map((e=>{"view"===e.name&&(e.click=t._viewClickHandler.bind(t))})),l.viewsGroup.buttons=o,t._viewsButtons=o,t.defaultCommands=l},_processTools:function(t){var n=this.options.editable,i=[],r=["toggle"],o=!1,a=this.defaultCommands;return Array.isArray(t)?i=t:n&&!1!==n.create&&r.push("append"),i.map((t=>{"plannedTasks"!==t&&"plannedTasks"!==t.name||(o=!0,r.push({type:"spacer"}),r.push("switchLabel")),a[t]||a[t.name]||t.template||(t=typeof t===b?{name:t,type:"button",text:t,attributes:{class:"k-gantt-"+t}}:e.extend({},{type:"button",text:t.name,attributes:{class:"k-gantt-"+t.name}},t)),r.push(t)})),o||r.push({type:"spacer"}),this._viewsButtons&&this._viewsButtons.length>0&&(this._viewsButtons.length>1&&r.push("viewsDdl"),r.push("viewsGroup")),r},_mediaQueryHandler:function(e){var t=this,n=t.layout.find(".k-splitbar"),i=t._getGanttSplitter(),r=t.treelistWrapper,o=t.timelineWrapper,a=y+x.gridContent,s=t.toolbar,l=s.getKendoToolBar();e.matches?(r.addClass("k-hidden"),n.addClass("k-hidden"),i._suppressResize=!0,l.hide(s.find(".k-gantt-views")),l.show(s.find(".k-views-dropdown")),r.width("100%")):(i._suppressResize=!1,r.removeClass("k-hidden"),n.removeClass("k-hidden"),o.removeClass("k-hidden"),l.show(s.find(".k-gantt-views")),l.hide(s.find(".k-views-dropdown")),r.width(r.outerWidth()),o.find(a).scrollTop(t.scrollTop)),t._resize()},_toolbar:function(){var t,i,o=this,a=T.styles,s=y+a.toolbar.viewsDropdown,l=this.options.toolbar;typeof l===b&&(l=n.template(l).bind(this)),t=h(l)?this._processTools([{template:l({})}]):this._processTools(l),i=e("<div class='"+a.toolbar.headerWrapper+"'>"),this.wrapper.prepend(i),this.toolbar=i,i.kendoToolBar({resizable:!1,tools:t,size:"medium",defaultTools:this.defaultCommands,parentMessages:this.options.messages.actions}),r&&(this._mediaQuery=window.matchMedia("(max-width: 480px)"),this._mediaQuery.addListener(this._mediaQueryHandler.bind(this))),i.on("change"+v,s,(function(){var t=o.list,n=e(this).val();t.editable&&t.editable.trigger("validate")||o.trigger("navigate",{view:n})||o.view(n)})),this.toggleSwitch=i.find("input.k-gantt-planned-switch").data("kendoSwitch")},_footer:function(){var t=this.options.editable;if(t&&!1!==t.create){var n=T.styles.toolbar,i=this.options.messages.actions,r=e("<div class='"+n.footerWrapper+"'>");this.wrapper.append(r),this.footer=r,r.kendoToolBar({resizable:!1,size:"medium",tools:["append"],defaultTools:{append:p(!0,{},this.defaultCommands.append,{direction:"up",animation:{open:{effects:"slideIn:up"}}})},parentMessages:i})}},_adjustDimensions:function(){var e=this.element,t=g(this.toolbar),n=this.footer?g(this.footer):0,i=e.height(),r=e.width(),o=this.treelistWrapper.is(":visible"),a=this.layout.find(".k-splitbar"),s=a.is(":visible")?m(a):0,l=o?m(this.treelistWrapper):0,c=r-(l+s);this.layout.children().height(i-(t+n)),this.timelineWrapper.width(c),o||this.timelineWrapper.css("left",0),r<l+s&&this.treelistWrapper.width(r-s)},_scrollTo:function(e){var t,i,r=this.timeline.view(),o=this.list,a=n.attr("uid"),s="string"==typeof e?e:e.closest("tr"+C()).attr(a);r.content.is(":visible")?(i=r.content.find(C(s)),t=function(){r._scrollTo(i)}):(i=o.element.find(C(s)),t=function(){i.get(0).scrollIntoView()}),0!==i.length&&t()},_addTask:function(e,t,n){var i,r=this.dataSource._createNewModel({}),o=this.timeline.view()._timeSlots()[0],a=this.list.editor;a&&a.trigger("validate")||(r.set("title","New task"),t?(r.set("parentId",t.get("id")),r.set("start",t.get("start")),r.set("end",t.get("end")),r.set("plannedStart",t.get("plannedStart")),r.set("plannedEnd",t.get("plannedEnd"))):(r.set("start",o.start),r.set("end",o.end)),n&&"add"!==n&&(i=e.get("orderId"),i="insert-before"===n?i:i+1),this._createTask(r,i))},_addClickHandler:function(e){var t=e.target.data("type"),n=this.dataSource,i=this.dataItem(this.select()),r=n.taskParent(i),o="add"===t?i:r;this._addTask(i,o,t)},_openAddClickHandler:function(e){var t=this.select();t&&0!==t.length||(e.preventDefault(),this._addTask())},_getListEditable:function(){var e=!1,t=this.options;return!1!==t.editable&&(e="incell",t.editable&&!1===t.editable.update?e=!1:t.editable&&!1===t.editable.reorder||(e={mode:"incell",move:{reorderable:!0,clickMoveClick:!1!==t.editable.clickMoveClick}})),e},_getListOptions:function(){var e=this.options,t=this._getListEditable(),n=this.wrapper.find(y+x.list);return{columns:e.columns||[],dataSource:this.dataSource,navigatable:e.navigatable,selectable:e.selectable,reorderable:e.reorderable,editable:t,resizable:e.resizable,filterable:e.filterable,columnMenu:e.columnMenu,columnResizeHandleWidth:this.options.columnResizeHandleWidth,listWidth:m(n),resourcesField:this.resources.field,rowHeight:this.options.rowHeight}},_attachResourceEditor:function(e){for(var t,n=0;n<e.length;n++)(t=e[n]).field===this.resources.field&&"function"!=typeof t.editor&&(t.editor=this._resourcePopupEditor.bind(this))},_attachListEvents:function(){var n=this;n.list.bind("columnShow",(function(e){n.trigger("columnShow",{column:e.column})})).bind("columnHide",(function(e){n.trigger("columnHide",{column:e.column})})).bind("columnReorder",(function(e){n.trigger("columnReorder",{column:e.column,oldIndex:e.oldIndex,newIndex:e.newIndex})})).bind("columnResize",(function(e){n.trigger("columnResize",{column:e.column,oldWidth:e.oldWidth,newWidth:e.newWidth})})).bind("render",(function(){n._navigatable()}),!0).bind("beforeEdit",(function(e){n.trigger("edit",{task:e.model,container:e.container})&&e.preventDefault()})).bind("cancel",(function(e){n.trigger("cancel",{task:e.model,container:e.cell})?e.preventDefault():(n._preventItemChange=!0,n.list.closeCell(!0))})).bind("save",(function(e){var i,r=e.values;for(i in n.previousTask={},n._preventRefresh=!0,null!==n.updateDuration&&n.updateDuration!==t||(n.updateDuration=e.model.duration()),null!==n.updatePlannedDuration&&n.updatePlannedDuration!==t||(n.updatePlannedDuration=e.model.plannedDuration()),r.hasOwnProperty("start")&&(r.end=new Date(r.start.getTime()+n.updateDuration)),r.hasOwnProperty("plannedStart")&&r.plannedStart&&(r.plannedEnd=new Date(r.plannedStart.getTime()+n.updatePlannedDuration)),r)r.hasOwnProperty(i)&&(n.previousTask[i]=e.model.get(i));n.updatedValues=r})).bind("itemChange",(function(t){var i,r,o,a,s,l=n.updatedValues,c=t.data,d=n.resources.field,u=n.previousTask,h=n.options.navigatable;if(n._preventItemChange)n._preventItemChange=!1;else{for(s in u)u.hasOwnProperty(s)&&c.set(s,u[s]);n.previousTask={},n.trigger("save",{task:c,values:l})?n.dataSource.hasChanges()&&(n.dataSource.cancelChanges(c),n._preventRefresh=!1,n.refresh()):(l&&(n._preventRefresh=!0,n.dataSource.update(c,l),l[d]&&n._updateAssignments(c.get("id"),l[d])),h&&(i=e(n.list.current()),r=i.is("th"),a=i.closest("tr").index(),o=r?i.parent().children(":not(.k-group-cell)").index(i[0]):Math.max(n.list.cellIndex(i),0)),n._preventRefresh=!1,n._requestStart(),n.dataSource.sync().then((function(){if(n.options.navigatable&&!n._tabPressed&&!r){var e=n.list.tbody.children().eq(a).find(">td:visible").eq(o);n.list._setCurrent(e,!1,!0)}n._tabPressed=!1}))),n.updatedValues=null,n.updateDuration=null}})).bind("change",(function(){n.trigger("change"),n._selectionUpdate()})).bind("navigate",(function(e){var t,i=e.sender.current();n._scrollTo(i),n.timeline.element.find("div.k-task").attr("tabindex","-1"),t=i.closest("tr").attr("data-uid"),n.timeline.element.find("div.k-task[data-uid='"+t+"']").attr("tabindex","0")})).bind("expand",(function(e){e.preventDefault(),e.model.set("expanded",!0),n.dataSource._updatePristineForModel(e.model,{expanded:!0})})).bind("collapse",(function(e){e.preventDefault(),e.model.set("expanded",!1),n.dataSource._updatePristineForModel(e.model,{expanded:!1})})).bind("dragend",(function(e){var t,i,r=n.dataSource;"over"===e.position&&(r.cancelChanges(),i={parentId:e.source.parentId},t=r.get(e.source.id),n.trigger("save",{task:t,values:i})||r.update(t,i),r.sync())})).bind("dataBound",(function(){0===n.dataSource.sort().length&&n.dataSource.sort([{field:"orderId",dir:"asc"}])})).bind("reorder",(function(e){n._updateTask(e.task,e.updateInfo)}))},_selectionUpdate:function(){var e=this,t=e.list.select();t.length?e.timeline.select("[data-uid='"+t.attr("data-uid")+"']"):e.timeline.clearSelection()},_list:function(){var e=T.styles,t=this.wrapper.find(y+e.list).find("> div"),i=this._getListOptions();this._attachResourceEditor(i.columns),this.list=new n.ui.GanttList(t,i),this._attachListEvents()},_timeline:function(){var e=this,t=T.styles,i=function(e){return delete e.name,delete e.prefix,delete e.remove,delete e.edit,delete e.add,delete e.navigate,e}(p(!0,{resourcesField:this.resources.field},this.options)),r=this.wrapper.find(y+t.timeline+" > div");this.timeline=new n.ui.GanttTimeline(r,i),this.timeline.bind("navigate",(function(n){var i=n.view.replace(/\./g,"\\.").toLowerCase(),r=e.toolbar.find(y+t.toolbar.views),o=r.getKendoButtonGroup();o&&o.select(r.find(y+t.toolbar.viewButton+"-"+i)),e.toolbar.find(y+t.toolbar.viewsDropdown).val(n.view),e.refresh()})).bind("moveStart",(function(t){var n=e.list.editor;!n||n.end()?e.trigger("moveStart",{task:t.task})&&t.preventDefault():t.preventDefault()})).bind("move",(function(t){var n=t.task,i=t.start,r=new Date(i.getTime()+n.duration());e.trigger("move",{task:n,start:i,end:r})&&t.preventDefault()})).bind("moveEnd",(function(t){var n=t.task,i=t.start,r=new Date(i.getTime()+n.duration());e.trigger("moveEnd",{task:n,start:i,end:r})||e._updateTask(e.dataSource.getByUid(n.uid),{start:i,end:r})})).bind("resizeStart",(function(t){var n=e.list.editor;!n||n.end()?e.trigger("resizeStart",{task:t.task})&&t.preventDefault():t.preventDefault()})).bind("resize",(function(t){e.trigger("resize",{task:t.task,start:t.start,end:t.end})&&t.preventDefault()})).bind("resizeEnd",(function(t){var n=t.task,i={};t.resizeStart?i.start=t.start:i.end=t.end,e.trigger("resizeEnd",{task:n,start:t.start,end:t.end})||e._updateTask(e.dataSource.getByUid(n.uid),i)})).bind("percentResizeStart",(function(t){var n=e.list.editor;n&&!n.end()&&t.preventDefault()})).bind("percentResizeEnd",(function(t){e._updateTask(e.dataSource.getByUid(t.task.uid),{percentComplete:t.percentComplete})})).bind("dependencyDragStart",(function(t){var n=e.list.editor;n&&!n.end()&&t.preventDefault()})).bind("dependencyDragEnd",(function(t){var n=e.dependencies._createNewModel({type:t.type,predecessorId:t.predecessor.id,successorId:t.successor.id});e._createDependency(n)})).bind("select",(function(t){var n,i=e.list.editor,r=e.select();i&&i.end(),r&&r.length&&(n=r.data("uid")),n!==t.uid&&(e.select("[data-uid='"+t.uid+"']"),e.trigger("change"))})).bind("editTask",(function(t){var n=e.list.editor;n&&!n.end()||e.editTask(t.uid)})).bind("clear",(function(){e.clearSelection(),e.trigger("change")})).bind("removeTask",(function(t){var n=e.list.editor;n&&!n.end()||e.removeTask(e.dataSource.getByUid(t.uid))})).bind("expand",(function(t){var n=e.dataSource.getByUid(t.uid);n.summary&&!n.get("expanded")?n.set("expanded",!0):t.preventDefault()})).bind("collapse",(function(t){var n=e.dataSource.getByUid(t.uid);n.summary&&n.get("expanded")?n.set("expanded",!1):t.preventDefault()})).bind("removeDependency",(function(t){var n=e.list.editor;n&&!n.end()||e.removeDependency(e.dependencies.getByUid(t.uid))}))},_dataSource:function(){var e=this.options.dataSource;e=u(e)?{data:e}:e,this.dataSource&&this._refreshHandler?this.dataSource.unbind("change",this._refreshHandler).unbind("progress",this._progressHandler).unbind("error",this._errorHandler):(this._refreshHandler=this.refresh.bind(this),this._progressHandler=this._requestStart.bind(this),this._errorHandler=this._error.bind(this)),this.dataSource=n.data.GanttDataSource.create(e).bind("change",this._refreshHandler).bind("progress",this._progressHandler).bind("error",this._errorHandler)},_dependencies:function(){var e=this.options.dependencies||{},t=u(e)?{data:e}:e;this.dependencies&&this._dependencyRefreshHandler?this.dependencies.unbind("change",this._dependencyRefreshHandler).unbind("error",this._dependencyErrorHandler):(this._dependencyRefreshHandler=this.refreshDependencies.bind(this),this._dependencyErrorHandler=this._error.bind(this)),this.dependencies=n.data.GanttDependencyDataSource.create(t).bind("change",this._dependencyRefreshHandler).bind("error",this._dependencyErrorHandler)},_resources:function(){var e=this.options.resources,t=e.dataSource||{};this.resources={field:"resources",dataTextField:"name",dataColorField:"color",dataFormatField:"format"},p(this.resources,e),this.resources.dataSource=n.data.DataSource.create(t)},_assignments:function(){var e=this.options.assignments,t=e.dataSource||{};this.assignments?this.assignments.dataSource.unbind("change",this._assignmentsRefreshHandler):this._assignmentsRefreshHandler=this.refresh.bind(this),this.assignments={dataTaskIdField:"taskId",dataResourceIdField:"resourceId",dataValueField:"value"},p(this.assignments,e),this.assignments.dataSource=n.data.DataSource.create(t),this.assignments.dataSource.bind("change",this._assignmentsRefreshHandler)},_createEditor:function(){var e=this;(this._editor=new n.gantt.PopupEditor(this.wrapper,p({},this.options,{target:this,resources:{field:this.resources.field,editor:this._createResourceEditor.bind(this)}}))).bind("cancel",(function(t){var n=e.dataSource.getByUid(t.model.uid);e.trigger("cancel",{container:t.container,task:n})?t.preventDefault():(e.dependencies&&e.dependencies.filter({}),e.cancelTask(),e.options.navigatable&&e.timeline.element.find('div[data-uid="'+t.model.uid+'"]').trigger("focus"))})).bind("edit",(function(t){var n=e.dataSource.getByUid(t.model.uid);e.trigger("edit",{container:t.container,task:n})&&t.preventDefault()})).bind("save",(function(t){var n=e.dataSource.getByUid(t.model.uid);e.saveTask(n,t.updateInfo,t.updateDependencies)})).bind("remove",(function(t){e.removeTask(t.model.uid)})).bind("close",(function(t){e.options.navigatable&&e.element.find('div[data-uid="'+t.window.attr("data-uid")+'"]').trigger("focus")}))},_resourcePopupEditor:function(t,i){var r,o,a=this,l=a._createResourceEditor(e("<div>"),i),c=x.popup,d=a.element,u=e(n.format('<div class="'+c.formContainer+'">')).appendTo(d),h=a.options.messages;return u.append(l.wrapper),r=e('<div class="'+c.buttonsContainer+'">'),u.append(r),r.append(e("<button class='"+x.buttonSave+"'>"+s(h.save)+"</button>").kendoButton({name:"save",themeColor:"primary",icon:"save",click:()=>{l.updateModel()&&(l.trigger("save",{model:l.model}),a._updateAssignments(l.model.get("id"),l.model.get(a.resources.field)),o.trigger("close"),o.close())}})),r.append(e("<button class='"+x.buttonCancel+"'>"+s(h.cancel)+"</button>").kendoButton({name:"cancel",icon:"cancel",click:()=>{o.trigger("close"),o.close()}})),this._resourceEditorWindow=o=u.kendoWindow({modal:!0,resizable:!1,draggable:!0,visible:!1,title:h.editor.resourcesEditorTitle,deactivate:()=>{l.destroy(),o.destroy(),o.element.closest(".k-window").remove()}}).data("kendoWindow"),o.center().open(),l},_createResourceEditor:function(e,t){var i=t instanceof l?t:t.model,r=this.options.messages,o=this.resources.field,a={step:.01,min:.01,max:1},s=this.assignments.dataSource.options.schema.model,c=this.resources.dataTextField,d=this.resources.dataSource.view();return s&&s.fields.Units&&s.fields.Units.validation&&p(!0,a,s.fields.Units.validation),this._resourceEditor=new n.gantt.ResourceEditor(e,{resourcesField:o,unitsValidation:a,resources:d.map((e=>({value:e.id,text:e[c]}))),model:i,messages:p({},r.editor)})},view:function(e){return this.timeline.view(e)},range:function(e){var t=this.dataSource,n=this.view(),i=this.timeline;return e&&(n.options.range={start:e.start,end:e.end},i._render(t.taskTree()),i._renderDependencies(this.dependencies.view())),{start:n.start,end:n.end}},date:function(e){var t=this.view();return e&&(t.options.date=e,t._scrollToDate(e)),t.options.date},dataItem:function(e){if(!e)return null;var t=this.list,n=t.element.find(e);return t._modelFromElement(n)},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.list.setDataSource(this.dataSource),this.options.autoBind&&e.fetch()},setDependenciesDataSource:function(e){this.options.dependencies=e,this._dependencies(),this.options.autoBind&&e.fetch()},items:function(){return this.wrapper.children(".k-task")},_updateAssignments:function(e,n){for(var i,r,o,a=this.assignments.dataSource,s=this.assignments.dataTaskIdField,l=this.assignments.dataResourceIdField,c=!1,u=new d(a.view()).filter({field:s,operator:"eq",value:e}).toArray();u.length;){i=u[0];for(var h=0,p=n.length;h<p;h++)if(r=n[h],i.get(l)===r.get("id")){o=n[h].get("value"),this._updateAssignment(i,o),n.splice(h,1),c=!0;break}c||this._removeAssignment(i),c=!1,u.shift()}for(var f=0,m=n.length;f<m;f++)(r=n[f]).id!==t&&r.value&&this._createAssignment(r,e);a.sync()},cancelTask:function(){var e=this._editor;e.container&&e.close(),this.dependencies&&this.dependencies.cancelChanges()},editTask:function(e){var t="string"==typeof e?this.dataSource.getByUid(e):e;if(t){var n=this.dataSource._createNewModel(t.toJSON());n.uid=t.uid,this.cancelTask(),this._editTask(n)}},_editTask:function(e){this._editor.editTask(e,this.options.editable.plannedTasks)},saveTask:function(e,n,i){var r,o=this,a=this._editor,s=a.container,l=a.editable,c=!1,d=!1,u=(n=n||{},o.options.resources.field);Object.keys(n).map((i=>{var o=n[i],a=e.get(i);o instanceof Date&&(o=o.getTime(),a=a?a.getTime():t),o!==a&&(i===u?(r=function(e,t){return e.filter((e=>!t.some((t=>t.id===e.id&&t.value===e.value)))).concat(t.filter((t=>!e.some((e=>e.id===t.id&&t.value===e.value)))))}(o,a),r&&r.length>0&&(d=!0)):c=!0)})),s&&l&&l.end()&&(c||d||i)?o.trigger("save",{task:e,values:n,updateDependencies:i})?(e&&e.dirty&&(o.dataSource.cancelChanges(e),o._preventRefresh=!1,o.refresh()),o.dependencies&&o.dependencies.cancelChanges()):(c&&(o._preventRefresh=!0,o.dataSource.update(e,n)),d&&this._updateAssignments(e.get("id"),n[u]),o._syncDataSource(),this.dependencies&&this._updateDependency(i),this._editor.close()):l&&l.end()&&this._editor.close()},_updateDependency:function(e){this.dependencies.filter({}),e&&(e.created.map((e=>{this._preventDependencyRefresh=!0,this.dependencies.add(e),this._preventDependencyRefresh=!1})),e.destroyed.map((e=>{this.dependencies.remove(e)}))),this.dependencies.sync()},_updateTask:function(e,t){var n=this,i=n.resources.field;n.trigger("save",{task:e,values:t})?(e&&e.dirty&&(n.dataSource.cancelChanges(e),n._preventRefresh=!1,n.refresh()),n.dependencies&&n.dependencies.cancelChanges()):(t&&(n._preventRefresh=!0,n.dataSource.update(e,t),t[i]&&n._updateAssignments(e.get("id"),t[i])),n._syncDataSource())},_updateAssignment:function(e,t){var n=this.assignments.dataValueField;e.set(n,t)},removeTask:function(e){var t=this,n="string"==typeof e?this.dataSource.getByUid(e):e;n&&this._taskConfirm((function(e){e||t._removeTask(n)}),n)},_createTask:function(e,n){if(!this.trigger("add",{task:e,dependency:null})){var i=this.dataSource;this._preventRefresh=!0,n===t?i.add(e):i.insert(n,e),this._scrollToUid=e.uid,this._syncDataSource()}},_createDependency:function(e){this.trigger("add",{task:null,dependency:e})||(this._preventDependencyRefresh=!0,this.dependencies.add(e),this._preventDependencyRefresh=!1,this.dependencies.sync())},_createAssignment:function(e,t){var n=this.assignments,i=n.dataSource,r=n.dataTaskIdField,o=n.dataResourceIdField,a=n.dataValueField,s=i._createNewModel();s[r]=t,s[o]=e.get("id"),s[a]=e.get("value"),i.add(s)},removeDependency:function(e){var t=this,n="string"==typeof e?this.dependencies.getByUid(e):e;n&&this._dependencyConfirm((function(e){e||t._removeDependency(n)}),n)},_removeTaskDependencies:function(e,t){this._preventDependencyRefresh=!0;for(var n=0,i=t.length;n<i;n++)this.dependencies.remove(t[n]);this._preventDependencyRefresh=!1,this.dependencies.sync()},_removeTaskAssignments:function(e){var t=this.assignments.dataSource,n=t.view(),i={field:this.assignments.dataTaskIdField,operator:"eq",value:e.get("id")};n=new d(n).filter(i).toArray(),this._preventRefresh=!0;for(var r=0,o=n.length;r<o;r++)t.remove(n[r]);this._preventRefresh=!1,t.sync()},_removeTask:function(e){var t=this.dependencies.dependencies(e.id);this.trigger("remove",{task:e,dependencies:t})||(this._removeTaskDependencies(e,t),this._removeTaskAssignments(e),this._preventRefresh=!0,this.dataSource.remove(e)&&this._syncDataSource(),this.dependencies&&this.dependencies.filter({}),this._preventRefresh=!1)},_removeDependency:function(e){this.trigger("remove",{task:null,dependencies:[e]})||this.dependencies.remove(e)&&this.dependencies.sync()},_removeAssignment:function(e){this.assignments.dataSource.remove(e)},_taskConfirm:function(e,t){let n=this.options.messages;this._confirm(e,{model:t,text:s(n.deleteTaskConfirmation),title:s(n.deleteTaskWindowTitle)})},_dependencyConfirm:function(e,t){let n=this.options.messages;this._confirm(e,{model:t,text:s(n.deleteDependencyConfirmation),title:s(n.deleteDependencyWindowTitle)})},_confirm:function(e,t){var n=this.options.editable;!0===n||!1!==n.confirmation?this.showDialog(p(!0,{},t,{callback:e})):e()},showDialog:function(e){this._editor.showDialog(e)},refresh:function(){if(!this._preventRefresh&&this.list&&!this.list.editor){this._progress(!1);var e,t,i=this.dataSource.taskTree(),r=this._scrollToUid,o=-1,a=this.select()[0]?this.select().data("uid"):this._selected;this.current&&(t=this.current.closest("tr").attr(n.attr("uid")),o=this.current.index()),this.trigger("dataBinding")||(0!==this.resources.dataSource.data().length&&this._assignResources(i),this._editor&&this._editor.close(),this.clearSelection(),this.list._renderTree(i),this.timeline._render(i),this.timeline._renderDependencies(this.dependencies.view()),r&&(this._scrollTo(r),this.select(C(r))),(r||t)&&o>=0&&(e=this.list.element.find("tr"+C(r||t)+" > td").eq(o),this._current(e)),this._scrollToUid=null,a&&(this._selected=a,this.select("[data-uid="+a+"]")),this.trigger("dataBound"))}},refreshDependencies:function(){this._preventDependencyRefresh||this.trigger("dataBinding")||(this.timeline._renderDependencies(this.dependencies.view()),this.trigger("dataBound"))},_assignResources:function(e){for(var t=this.resources,i=this.assignments,r=function(){var e=i.dataSource.view(),t={field:i.dataTaskIdField};return e=new d(e).group(t).toArray()}(),o=function(e,i){var o=e.get("id");n.setter(t.field)(e,new c([]));for(var a=0,s=r.length;a<s;a++)r[a].value===o&&i(e,r[a].items)},a=function(e,r){for(var o=0,a=r.length;o<a;o++){var s=r[o],c=t.dataSource.get(s.get(i.dataResourceIdField)),d=s.get(i.dataValueField),u=s.get(i.dataResourceIdField),h=c.get(t.dataFormatField)||"p0",p=n.toString(d,h);e[t.field].push(new l({id:u,name:c.get(t.dataTextField),color:c.get(t.dataColorField),value:d,formatedValue:p,format:h}))}},s=0,u=e.length;s<u;s++)o(e[s],a)},_wrapResourceData:function(e){for(var t,n=this,i=[],r=this.resources.dataSource.view(),o=this.assignments.dataSource.view(),a=new d(o).filter({field:n.assignments.dataTaskIdField,operator:"eq",value:e}).toArray(),s=function(e){var t=null;return new d(a).filter({field:n.assignments.dataResourceIdField,operator:"eq",value:e}).select((function(e){t+=e.get(n.assignments.dataValueField)})),t},l=0,c=r.length;l<c;l++)t=r[l],i.push({id:t.get("id"),name:t.get(n.resources.dataTextField),format:t.get(n.resources.dataFormatField)||"p0",value:s(t.id)});return i},_syncDataSource:function(){this._preventRefresh=!1,this._requestStart(),this.dataSource.sync()},_requestStart:function(){this._progress(!0)},_error:function(){this._progress(!1)},_progress:function(e){n.ui.progress(this.element,e)},_scrollable:function(){var t=this,i=T.styles,r=y+i.gridContent,a=y+i.gridHeaderWrap,s=this.timeline.element.find(a),l=this.timeline.element.find(r),c=this.list.element.find(a),d=this.list.element.find(r);o&&d.css("overflow-y","auto"),l.on("scroll",(function(){t.scrollTop=this.scrollTop,n.scrollLeft(s,this.scrollLeft),d.scrollTop(this.scrollTop)})),d.on("scroll",(function(){n.scrollLeft(c,this.scrollLeft)})).on("DOMMouseScroll"+v+" mousewheel"+v,(function(t){var i=l.scrollTop(),r=n.wheelDeltaY(t);r&&(t.preventDefault(),e(t.currentTarget).one("wheel"+v,!1),l.scrollTop(i+-r))}))},_navigatable:function(){var t=this,r=this.options.navigatable,o=this.options.editable,a=T.styles,s=y+a.gridContent,l=y+a.listWrapper,c=y+a.gridHeaderWrap,d=this.list.element.find(c).find("table"),u=this.list.element.find(s).find("table"),h=d.add(u),p=C();e(this.wrapper).on("mousedown"+v,l+" tr"+p,(function(n){var i=e(n.target).is(":button,a,:input,a>.k-icon,.k-svg-icon,k-svg-icon,svg,path,textarea,span.k-icon:not(.k-i-none),span.k-svg-icon:not(.k-svg-i-none),span.k-link,.k-input,.k-multiselect-wrap,.k-input-value-text,.k-input-inner");n.ctrlKey||!r&&!o||i||(t._focusTimeout=setTimeout((function(){S(t.list.content.find("table"),!0)}),2))})).on("keydown"+v,function(t){var n,r,o,s=t.keyCode,l=this,c=e(t.target),d=[l.toolbar,l.layout.find(".k-splitbar"),l.layout.find(".k-gantt-treelist"),l.layout.find(".k-gantt-timeline-pane")];l._tabPressed=!1,l.footer&&d.push(l.footer);for(var u=0;u<d.length;u++)if(e.contains(d[u][0],t.target)||d[u][0]===t.target){o=u;break}if(s===i.F10)l.toolbar.find("[tabindex=0]:visible").first().addClass(a.focused).trigger("focus"),t.preventDefault();else if(s==i.TAB)if(2==o&&(l._tabPressed=!0),t.shiftKey){for(u=o-1;u>=0;u--)if(!d[u].hasClass("k-hidden")){n=c.attr("data-uid"),2===u&&n?(r=l.list.content.find("tr[data-uid='"+n+"']").find("td").last(),l.list.current(r),S(l.list.content.find("table"),!0)):d[u].is(":kendoFocusable")?d[u].trigger("focus"):d[u].find("[tabindex=0]:visible").trigger("focus"),t.preventDefault();break}}else for(u=o+1;u<d.length;u++)if(!d[u].hasClass("k-hidden")){d[u].is(":kendoFocusable")?d[u].trigger("focus"):d[u].find("[tabindex=0]:visible").trigger("focus"),t.preventDefault();break}}.bind(this)),r?u.on("keydown"+v,(function(e){var r=e.keyCode;e.keyCode==i.DELETE?function(){var e=t.options.editable;if(e&&!1!==e.destroy&&!t.list.editor){var i=t.select(),r=n.attr("uid");i.length&&t.removeTask(i.attr(r))}}():r>=49&&r<=57&&"input"!==e.target.tagName.toLowerCase()&&t.view(t.timeline._viewByIndex(r-49))})):h.on("focus"+v,(function(){e(t.toolbar.find(y+a.focused)).removeClass(a.focused)})).on("blur"+v,(function(){this==d&&e(this).attr(_,-1)}))},_dataBind:function(){var t=this;if(t.options.autoBind){this._preventRefresh=!0,this._preventDependencyRefresh=!0;var n=e.map([this.dataSource,this.dependencies,this.resources.dataSource,this.assignments.dataSource],(function(e){return e.fetch()}));e.when.apply(null,n).done((function(){t._preventRefresh=!1,t._preventDependencyRefresh=!1,t.refresh()}))}},_resize:function(){this._adjustDimensions(),this.timeline.view()._adjustHeight(),this.timeline.view()._renderCurrentTime(),this.list._adjustHeight()},_togglePlannedTasks:function(e){var t=this.timeline;this.trigger("togglePlannedTasks",{showPlannedTasks:!t.options.showPlannedTasks})?e.preventDefault():(this.wrapper.toggleClass(x.plannedTasks),t._setPlanned(!t.options.showPlannedTasks),t._render(this.dataSource.taskTree()),t._renderDependencies(this.dependencies.view()))}});n.PDFMixin&&(n.PDFMixin.extend(T.fn),T.fn._drawPDF=function(){var e=T.styles,t=this.wrapper.find(y+e.list+" "+y+e.gridContent+">table").width(),n=this.wrapper.find(y+e.list+" "+y+e.gridContent+">table").height(),i=this.wrapper.find(y+e.toolbar.toolbar).outerHeight()*this.wrapper.find(y+e.toolbar.toolbar).length,r=this.wrapper.find(y+e.timeline+" "+y+e.gridContent+" table").width(),o=this.wrapper.clone();return o.find(y+e.list).css("height",n+i),o.find(y+e.splitter).css("width",r+t),o.find(y+e.splitter).css("height",n+i),this._drawPDFShadow({content:o},{avoidLinks:this.options.pdf.avoidLinks})}),n.ui.plugin(T),p(!0,T,{styles:x})}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=t.data.DataSource,r=t.effects.Transition,o=t.keys,a=Array.isArray,s=t.htmlEncode,l="vertical",c="transitionEnd",d="k-timeline-flag-wrap",u="k-timeline-track-item",h="k-timeline-scrollable-wrap",p=".k-timeline-track-item:not(.k-timeline-flag-wrap)",f=".kendoTimeline",m="change",g=e=>{let t=e.titleField,n=e.subtitleField,i=e.descriptionField,r=e.imagesField,o=e.actionsField,a=e.altField,l=e.data;return'<div class="k-card-inner"><div class="k-card-header">'+(l[t]?`<div class="k-card-title"><span class="k-event-title">${s(l[t])}</span></div>`:"")+(l[n]?`<div class="k-card-subtitle">${s(l[n])}</div>`:"")+'</div><div class="k-card-body"><div class="k-card-description">'+(l[i]?`<p>${s(l[i])}</p>`:"")+(l[r]&&l[r].length>0?`<img src="${s(l[r][0].src)}" ${l[a]?`alt="${s(l[a])}"`:""} class="k-card-media" />`:"")+"</div></div>"+(l[o]&&l[o].length>0?'<div class="k-actions k-card-actions">'+l[o].map((e=>`<a class="k-button k-button-md k-rounded-md k-button-flat k-button-flat-primary" href="${e.url?s(e.url):"#"}"><span class="k-button-text">${s(e.text)}</span></a>`)).join("")+"</div>":"")+"</div>"},v=e=>{let n=e.titleField,i=e.subtitleField,r=e.descriptionField,o=e.imagesField,a=(e.navigatable,e.collapsibleEvents),l=e.actionsField,c=e.altField,d=e.data;return'<div class="k-card-inner"><div class="k-card-header"><div class="k-card-title">'+(d[n]?`<span class="k-event-title">${s(d[n])}</span>`:"")+(a?'<span class="k-event-collapse k-button k-button-md k-rounded-md k-button-flat k-button-flat-base k-icon-button">'+t.ui.icon({icon:"chevron-right",iconClass:"k-button-icon"})+"</span>":"")+"</div>"+(d[i]?`<div class="k-card-subtitle">${s(d[i])}</div>`:"")+'</div><div class="k-card-body"><div class="k-card-description">'+(d[r]?`<p>${s(d[r])}</p>`:"")+(d[o]&&d[o].length>0?`<img src="${s(d[o][0].src)}" ${d[c]?`alt="${s(d[c])}"`:""} class="k-card-media" />`:"")+"</div></div>"+(d[l]&&d[l].length>0?'<div class="k-actions k-card-actions">'+d[l].map((e=>`<a class="k-button k-button-md k-rounded-md k-button-flat k-button-flat-primary" href="${e.url?s(e.url):"#"}"><span class="k-button-text">${s(e.text)}</span></a>`)).join("")+"</div>":"")+"</div>"},_=e=>{e.itemTemplate;let n=e.dateField,i=e.dateFormat,r=e.showDateLabels,o=e.data,a=0,s="";for(var l=0;l<o.length;l++){if(!(o[l][n]instanceof Date))continue;let e=o[l][n].getFullYear();a!=e&&(a=e,s+=`<li class="k-timeline-track-item k-timeline-flag-wrap"><span class="k-timeline-flag">${a}</span></li>`),s+='<li class="k-timeline-track-item" role="tab"><div class="k-timeline-date-wrap">'+(r?`<span class="k-timeline-date">${t.toString(o[l][n],i)}</span>`:"")+'</div><span class="k-timeline-circle"></span></li>'}return s},b=e=>{let n=e.itemTemplate,i=e.dateField,r=e.titleField,o=e.descriptionField,a=e.subtitleField,l=e.imagesField,c=e.actionsField,d=e.alterMode,u=e.collapsibleEvents,h=e.dateFormat,p=e.showDateLabels,f=e.navigatable,m=e.altField,g=e.data,v=0,_=0,b=!1,y="";for(var w=0;w<g.length;w++)if(g[w][i]instanceof Date){var k=g[w][i].getFullYear();k!=_&&(_=k,y+=`<li class="k-timeline-flag-wrap"><span class="k-timeline-flag">${_}</span></li>`),b=v%2==0&&d,y+=`<li class="${b?"k-timeline-event k-reverse":"k-timeline-event"}" data-uid="${s(g[w].uid)}"><div class="k-timeline-date-wrap">`+(p?`<span id="${s(g[w].uid)}-date" class="k-timeline-date">${t.toString(g[w][i],h)}</span>`:"")+'</div><span class="k-timeline-circle"></span>'+`<div class="${u?"k-timeline-card k-collapsed":"k-timeline-card"}">`+`<div aria-expanded="false" class="k-card k-card-vertical k-card-with-callout" ${f?`aria-describedby="${s(g[w].uid)}-date" tabindex="0" role="button" aria-live="polite" aria-atomic="true"`:""} >`+`<span class="${b?"k-timeline-card-callout k-card-callout k-callout-e":"k-timeline-card-callout k-card-callout k-callout-w"}"></span>`+`${n({titleField:r,subtitleField:a,descriptionField:o,imagesField:l,actionsField:c,data:g[w],altField:m,navigatable:f,collapsibleEvents:u})}</div></div></li>`,v++}return y},y='<button disabled tabindex="-1" aria-hidden="true" class="k-button k-button-md k-rounded-full k-button-solid k-button-solid-base k-icon-button k-timeline-arrow k-timeline-arrow-left k-disabled" title="previous">'+t.ui.icon({icon:"caret-alt-left",iconClass:"k-button-icon"})+'</button><button disabled tabindex="-1" aria-hidden="true" class="k-button k-button-md k-rounded-full k-button-solid k-button-solid-base k-icon-button k-timeline-arrow k-timeline-arrow-right k-disabled" title="next">'+t.ui.icon({icon:"caret-alt-right",iconClass:"k-button-icon"})+"</button>";function w(e){var t=e.css("transform");return"none"!=t&&""!=t?t.match(/-?[\d\.]+/g)[4]/e.width()*100:0}function k(e,t){return e.offset().left-t.offset().left+e.width()/2}function x(e,t,n){e.css(t,n)}var C=t.Class.extend({init:function(t){this.cardContainer=e("<div class='k-card k-card-vertical k-card-with-callout' role='tabpanel'/>");var n=e("<div class='k-timeline-card'></div>").append(this.cardContainer);this.element=e("<li class='"+function(e){return"k-"+e}("timeline-event")+"'></li>").append(n),t.append(this.element)},content:function(t,n,i){var r=e("<span class='k-timeline-card-callout k-card-callout k-callout-n'></span>");this.cardContainer.html(t),this.cardContainer.prepend(r),this.element.attr("data-uid",n),this.element.find(".k-card").attr({role:"tabpanel","aria-label":i})},position:function(e){this.element.css("transform","translate3d("+this.element.width()*e+"px, 0, 0)"),0===e?this.element.find(".k-card").attr("tabindex",0):this.element.find(".k-card").removeAttr("tabindex")},setPageCallout:function(e,t){this.element.find(".k-timeline-card-callout").css(e,t)},destroy:function(){var e=this;e.cardContainer=null,e.element.remove(),e.element=null}}),S=t.Observable.extend({init:function(n,i){var o,a,s,l=this;t.Observable.fn.init.call(this),this.element=n,o=new t.ui.Movable(l.element),a=new r({axis:"x",movable:o,onEnd:function(){l.trigger(c)}}),s=[],e.extend(l,{duration:i&&i.duration||1,movable:o,transition:a,pages:s,eventTemplate:i.eventTemplate,eventHeight:i.eventHeight,dataFieldMappings:i.dataFieldMappings,dateFormat:i.dateFormat}),this.bind([c],i)},initPages:function(){for(var e,t=this.pages,n=this.element,i=0;i<3;i++)e=new C(n),t.push(e)},repositionPages:function(){var e=this.pages;e[0].position(-1),e[1].position(0),e[2].position(1)},setPageContent:function(e,n){var i,r=typeof this.eventTemplate===Function?this.eventTemplate:t.template(this.eventTemplate),o=this.dataFieldMappings,a=t.toString(n.date,this.dateFormat);i=r({data:n,titleField:o.title,subtitleField:o.subtitle,descriptionField:o.description,imagesField:o.images,actionsField:o.actions,altField:o.altField}),e.content(i,n.uid,a)},updatePage:function(e,t,n){var i=this.pages,r=null===e?i[1]:e?i[i.length-1]:i[0];this.setPageContent(r,t),r.setPageCallout("left",n/r.element.width()*100+"%")},moveTo:function(e){this.movable.moveAxis("x",-e)},transitionTo:function(e,t){this.transition.moveTo({location:e,duration:this.duration,ease:t})},destroy:function(){for(var e=this,t=0;t<e.pages.length;t++)e.pages[t].destroy();e.unbind(),e.movable=e.transition=e.dataFieldMappings=e.eventTemplate=e.duration=e.pages=null}}),T=t.ui.Widget.extend({init:function(t,i){var r=this,o=i.orientation||r.options.orientation;n.fn.init.call(this,t,i),this.element.addClass(o===l?"k-timeline k-timeline-vertical":"k-timeline k-timeline-horizontal"),o!=l?r._horizontal():r._vertical(),this.element.on("click",".k-card-actions",(function(t){var n=e(t.target),i=e(t.target).closest(".k-timeline-event").data("uid"),o=r.dataSource.getByUid(i);r.trigger("actionClick",{sender:r,element:n,dataItem:o})})),r.currentEventIndex=0,r._forward=null,r._eventPage=1,r._currentIndex=0,r._firstIndexInView=0,r._initDataFieldMappings(),r.setDataSource(i.dataSource)},_horizontal:function(){var t=this,n=this.element,i=this.options,r=e("<div />"),o=e("<div />"),a=e("<ul role='tablist' tabindex='0' />"),s=e("<div />"),l=e("<ul />");t._trackWrap=r,t._trackEl=o,t._scrollableWrap=a,t._eventsWrap=s,t._eventsList=l,r.addClass("k-timeline-track-wrap"),o.addClass("k-timeline-track"),a.addClass(h),s.addClass("k-timeline-events-list"),l.addClass(h),i.eventHeight&&l.height(i.eventHeight),o.append(a),r.append(y),r.append(o),s.append(l),r.appendTo(n),s.appendTo(n)},_vertical:function(){var t=this,n=this.options,i=this.element,r=t._eventsList=e("<ul />"),a=n.navigatable,s=n.collapsibleEvents;t.element.append(r),n.alternatingMode&&i.addClass("k-timeline-alternating"),s&&(i.addClass("k-timeline-collapsible"),this.element.on("click",".k-card-header",(function(){var n=e(this).closest(".k-timeline-card"),i=n.parent(),r=t.dataSource.getByUid(i.data("uid"));n.hasClass("k-collapsed")?t.trigger("expand",{sender:t,dataItem:r})||t.expand(i):t.trigger("collapse",{sender:t,dataItem:r})||t.collapse(i)}))),a&&s&&this.element.on("keydown"+f,t,(function(t){if(t.keyCode==o.SPACEBAR||t.keyCode==o.ENTER){var n=e(t.target).find(".k-card-header");n.length&&(t.preventDefault(),n.trigger("click"))}}))},_renderContentVertical:function(e){var n,i,r=this.options;i=typeof r.eventTemplate===Function?r.eventTemplate:r.eventTemplate?t.template(r.eventTemplate):t.template(v,{useWithBlock:!1}),n=t.template(b,{useWithBlock:!1})({data:e,dateField:r.dataDateField,titleField:r.dataTitleField,subtitleField:r.dataSubtitleField,descriptionField:r.dataDescriptionField,imagesField:r.dataImagesField,actionsField:r.dataActionsField,itemTemplate:i,alterMode:r.alternatingMode,collapsibleEvents:r.collapsibleEvents,dateFormat:r.dateFormat,showDateLabels:r.showDateLabels,altField:r.dataImagesAltField,navigatable:r.navigatable}),this._eventsList.html(n),r.eventWidth&&this.element.find(".k-card").width(r.eventWidth)},_renderContentHorizontal:function(n){var i,r,o=this,a=o.options,s=o._dataFieldMappings;r=typeof a.eventTemplate===Function?a.eventTemplate:a.eventTemplate?t.template(a.eventTemplate):t.template(g,{useWithBlock:!1}),i=t.template(_,{useWithBlock:!1})({data:n,itemTemplate:r,dateFormat:a.dateFormat,dateField:a.dataDateField,showDateLabels:a.showDateLabels}),a.initialEventIndex?o._trackWrap.append(e(i).find("."+h).css("transform","translateX(-100%)").parent()):o._scrollableWrap.html(i),o.pane&&o.pane.destroy(),o.pane=new S(o._eventsList,{transitionEnd:this._transitionEnd.bind(this),eventTemplate:r,dataFieldMappings:s,eventHeight:a.eventHeight,dateFormat:a.dateFormat})},_initDataFieldMappings:function(){var e=this.options;this._dataFieldMappings={title:e.dataTitleField,subtitle:e.dataSubtitleField,date:e.dataDateField,description:e.dataDescriptionField,images:e.dataImagesField,actions:e.dataActionsField,altField:e.dataImagesAltField}},_transitionEnd:function(){this._forward?this.pane.pages.push(this.pane.pages.shift()):this.pane.pages.unshift(this.pane.pages.pop()),this._forward=null,this.pane.repositionPages(),this.pane.movable.moveAxis("x",0),this.options.navigatable&&(this._transition=null,this._eventsList.find(".k-card").removeAttr("id"),this.pane.pages[1].cardContainer.attr("id",this._cardId),this._setCurrent(this._currentBullet)),this._animationInProgress=!1},_setCurrentEvent:function(t){var n,i=this,r=e(t.currentTarget),o=i.dataSource.view()[r.parent().children(":not(.k-timeline-flag-wrap)").index(r)];n=i._forward?i.pane.pages[2].element:i.pane.pages[0].element,i.trigger("change",{eventContainer:n,dataItem:o})||i.open(r)},open:function(t){var n,i=this,o=e(t),a=o.find(".k-timeline-circle"),s=o.parent().children(":not(.k-timeline-flag-wrap)"),l=s.index(o);this.options.navigatable&&(i._removeCurrent(),s.attr("aria-selected",!1),o.attr("aria-selected",!0),i._currentBullet=o);var c=i.dataSource.view()[l];i.currentEventIndex!==l&&(i._currentIndex=o.index(),n=i._forward=i.currentEventIndex<l,i.currentEventIndex=l,i.pane.updatePage(n,c,k(a,i._trackWrap)),i._forward?(clearTimeout(i.navigateTimeOut),i.navigateTimeOut=setTimeout((function(){i.pane.transition.moveTo({location:-i.pane.pages[2].element.width(),duration:800,ease:r.easeOutExpo})}),200)):(clearTimeout(i.navigateTimeOut),i.navigateTimeOut=setTimeout((function(){i.pane.transition.moveTo({location:i.pane.pages[0].element.width(),duration:800,ease:r.easeOutExpo})}),200)),i._repositionEvents())},_navigateToView:function(t){var n=this,i=e(t.currentTarget).hasClass("k-timeline-arrow-right")?1:-1;n.trigger("navigate",{sender:n,action:i>0?"next":"previous"})||n._animationInProgress||(n._animationInProgress=!0,i>0?n.next():n.previous(),n._updateArrows())},_enableDisableArrow:function(e,t){t?(e.removeClass("k-disabled"),e.removeAttr("disabled"),e.attr("aria-hidden",!1)):(e.addClass("k-disabled"),e.attr("disabled","disabled"),e.attr("aria-hidden",!0))},_updateArrows:function(){var e=this,t=e.element.find(".k-timeline-arrow"),n=t.filter(".k-timeline-arrow-left"),i=t.filter(".k-timeline-arrow-right");this._enableDisableArrow(n,!e._validateNavigation(!1)),this._enableDisableArrow(i,!e._validateNavigation(!0))},_validateNavigation:function(e){var t=this,n=t._end||0;return e?t._firstIndexInView+t.numOfEvents>=t.maxEvents:Math.abs(n)<=1},next:function(){var e=this,t=e.options;e._validateNavigation(!0)||t.orientation==l||(e._forward=!0,e._navigate()),e._updateArrows()},_navigate:function(){var t,n,i,o,a=this,s=a._forward,l=w(this._trackWrap.find("."+h)),c=s?-e("."+h).width():e("."+h).width(),m=a._currentIndex,g=a._firstIndexInView;if((l=s?l-100:l+100)>=0&&(l=0),a._end=l,a._tackItemWidth,o=Math.floor(m/a.numOfEvents),s?1===a.numOfEvents?(t=0===g?1:g,n=this._trackWrap.find("."+u).eq(t).nextAll(":not(."+d+")").first(),a._firstIndexInView=n.index()):(t=g+a.numOfEvents-1,n=this._trackWrap.find("."+u).eq(t).nextAll(":not(."+d+")").first(),a._firstIndexInView=g+a.numOfEvents):1===a.numOfEvents?(t=g,n=this._trackWrap.find("."+u).eq(t).prevAll(":not(."+d+")").first(),a._firstIndexInView=n.index()):(t=g,n=(n=this._trackWrap.find("."+u).eq(t).prevAll(":not(."+d+")").first()).length>0?n:this._trackWrap.find("."+u+":not(."+d+")").first(),a._firstIndexInView=g-a.numOfEvents<0?0:g-a.numOfEvents),i=a.dataSource.view()[this._trackWrap.find(p).index(n)],this._trackWrap.find("."+h).css("transform","translateX("+l+"%)"),a._currentIndex!=n.index())a.currentEventIndex=this._trackWrap.find(p).index(n),a._currentIndex=n.index(),a.pane.updatePage(a._forward,i,0!==o||s?k(n.find(".k-timeline-circle"),a._trackWrap)+c:n.find(".k-timeline-circle").offset().left+15),clearTimeout(a.navigateTimeOut),a.navigateTimeOut=setTimeout((function(){s&&a.pane&&a.pane.pages.length>0?a.pane.transition.moveTo({location:-a.pane.pages[2].element.width(),duration:800,ease:r.easeOutExpo}):a.pane.transition.moveTo({location:a.pane.pages[0].element.width(),duration:800,ease:r.easeOutExpo})}),200);else{var v=this._trackWrap.find("."+h),_=function(){if(1!=a.numOfEvents){var e=a.pane.pages[1],t=k(n.find(".k-timeline-circle"),a._trackWrap);e.setPageCallout("left",t/e.element.width()*100+"%")}this._transition=null,v.off("transitionend"+f,_)};v.on("transitionend"+f,_)}},previous:function(){var e=this,t=e.options;e._validateNavigation(!1)||t.orientation==l||(e._forward=!1,e._navigate()),e._updateArrows()},expand:function(n){var i=this.options,r=e(n).find(".k-timeline-card"),o=e(n).find(".k-card"),a=e(n).find(".k-card-body");r.hasClass("k-collapsed")&&(i.navigatable&&i.collapsibleEvents&&o.attr("aria-expanded",!0),r.removeClass("k-collapsed"),t.fx(a).expand("vertical").stop().play())},collapse:function(n){var i=this.options,r=e(n).find(".k-timeline-card"),o=e(n).find(".k-card"),a=e(n).find(".k-card-body");r.hasClass("k-collapsed")||(i.navigatable&&i.collapsibleEvents&&o.attr("aria-expanded",!1),r.addClass("k-collapsed"),t.fx(a).expand("vertical").stop().reverse())},items:function(){return this.element.find("li[data-uid]")},_resizeHandler:function(){var e=this;clearTimeout(e.resizeTimeOut),e.resizeTimeOut=setTimeout((function(){e._redrawEvents(),e.pane.repositionPages()}))},redraw:function(){this.options.orientation!=l&&(this._redrawEvents(),this.pane.repositionPages())},_redrawEvents:function(){var e,t=this,n=Math.floor(t.element.find("."+h).width()/150);t.element.width()<=480?(t.element.addClass("k-timeline-mobile"),e=100,t.numOfEvents=1,t._tackItemWidth=e,t.element.find("li."+u).css("flex","1 0 "+e+"%"),t._repositionEvents()):(t.element.removeClass("k-timeline-mobile"),n!=t.numOfEvents&&(t.numOfEvents=n,e=100/n,x(t.element.find("li."+u),"flex","1 0 "+e+"%"),t._tackItemWidth=e,t._repositionEvents())),t._updateArrows()},_repositionEvents:function(){var e,t,n,i=this,r=i._tackItemWidth,o=null===i._forward?i.pane.pages[1]:i._forward?i.pane.pages[2]:i.pane.pages[0],a=this._trackWrap.find("."+h),s=w(a);if(t=1===i.numOfEvents?i.currentEventIndex*r:i._currentIndex*r,o){if(1===i.numOfEvents)return o.setPageCallout("left","50%"),x(a,"transform","translateX(-"+(n=t)+"%)"),i._firstIndexInView=i._currentIndex,void i._updateArrows();t>=Math.abs(s)+100?(n=Math.abs(s)+(t-(Math.abs(s)+100)+r),i._end=-n,x(a,"transform","translateX(-"+n+"%)"),i._firstIndexInView=i._currentIndex-i.numOfEvents+1):t<=Math.abs(s)?(n=t,i._end=-n,x(a,"transform","translateX(-"+n+"%)"),i._firstIndexInView=i._currentIndex):(e=k(a.find("li."+u).eq(i._currentIndex).find(".k-timeline-circle"),i._trackWrap),o.setPageCallout("left",e/o.element.width()*100+"%"),i._firstIndexInView=Math.round(Math.abs(s)/r));var l=this._trackWrap.find("."+h),c=function(){if(1!=i.numOfEvents){var e=i.pane.pages[1],t=k(i._trackWrap.find("."+u).eq(i._currentIndex).find(".k-timeline-circle"),i._trackWrap);e.setPageCallout("left",t/e.element.width()*100+"%")}l.off("transitionend"+f,c)};l.on("transitionend"+f,c)}i._updateArrows()},_initHorizontal:function(){var e,n=this,i=n._trackWrap.find(".k-timeline-circle").first(),r=n.dataSource.view()[0],a=n.options.navigatable;n.maxEvents=n._trackWrap.find("."+u).length,n._currentIndex=1,n.pane.initPages(),n.pane.repositionPages(),n.pane.updatePage(n._forward,r,k(i,n._trackWrap)),n._updateArrows(),n._resizeHandlerBound=n._resizeHandler.bind(n),t.jQuery(window).on("resize"+f,n._resizeHandlerBound),n._trackWrap.on("click",p,n._setCurrentEvent.bind(n)),n._trackWrap.on("click",".k-timeline-arrow:not(.k-disabled)",n._navigateToView.bind(n)),a&&(n._trackWrap.find(".k-timeline-track-item.k-timeline-flag-wrap").attr("role","none").attr("aria-hidden",!0),n._trackWrap.find(p).attr("aria-selected",!1).first().attr("aria-selected",!0),n._cardId=t.guid(),n._scrollableWrap.on("focus"+f,(function(){n.pane.pages[1].cardContainer.attr("id",n._cardId),n._currentBullet&&n._currentBullet.addClass("k-focus")})).on("focusout"+f,(function(){n._currentBullet&&n._currentBullet.removeClass("k-focus")})).on("keydown"+f,(function(e){var t,i,r,a=n._currentBullet;n._transition||(e.keyCode==o.LEFT&&(t=!0,(r=a.prevAll(p).first()).length&&((i=k(r,n._trackWrap))<0||i>r.parent().width()?(n._transition=!0,n._removeCurrent(),n.previous(),n.open(r)):n._setCurrentEvent({currentTarget:r}))),e.keyCode==o.RIGHT&&(t=!0,(r=a.nextAll(p).first()).length&&((i=k(r,n._trackWrap))<0||i>r.parent().width()?(n._transition=!0,n._removeCurrent(),n.next(),n.open(r)):n._setCurrentEvent({currentTarget:r}))),t&&e.preventDefault())})),e=n._scrollableWrap.find("."+u).eq(n._currentIndex),n._setCurrent(e),e.removeClass("k-focus"))},_setCurrent:function(e){if(e){var n=t.guid(),i=this;i._removeCurrent(),i._scrollableWrap.attr("aria-activedescendant",n),e.attr("id",n).addClass("k-focus"),e.siblings().removeAttr("aria-describedby"),"true"===e.attr("aria-selected")&&(e.attr("aria-describedby",i._cardId),i.pane.pages[1].cardContainer.attr("id",i._cardId)),i._currentBullet=e}},_removeCurrent:function(){this._currentBullet&&this._currentBullet.removeClass("k-focus").removeAttr("id").removeAttr("aria-describedby"),this._scrollableWrap.removeAttr("aria-activedescendant")},setDataSource:function(e){var t=this,n=t.options;e=a(e)?{data:e}:e,t.dataSource&&t._refresh?t.dataSource.unbind(m,t._refresh):this._refresh=t.refresh.bind(t),this.dataSource=i.create(e),undefined===this.dataSource._sort&&(this.dataSource._sort=[{field:n.dataDateField,dir:"asc"}]),t.dataSource.bind(m,t._refresh),n.autoBind&&this.dataSource.fetch()},refresh:function(){var e=this,t=e.options,n=this.dataSource.view();t.orientation!=l&&(e._trackWrap.empty().remove(),e.element.find(".k-timeline-events-list").remove(),e._horizontal()),e.currentEventIndex=0,e._forward=null,e._eventPage=1,e._currentIndex=0,e._firstIndexInView=0,e.numOfEvents=null,e._end=0,e._initDataFieldMappings(),n.length&&("horizontal"===t.orientation?(e._renderContentHorizontal(n),e._redrawEvents(),e._initHorizontal()):e._renderContentVertical(n)),e.trigger("dataBound",{sender:e})},destroy:function(){var i=this.options;n.fn.destroy.call(this),this.resizeTimeOut&&clearTimeout(this.resizeTimeOut),this.navigateTimeOut&&clearTimeout(this.navigateTimeOut),e(window).off("resize"+f,this._resizeHandlerBound),this._resizeHandlerBound=null,this.element.off(),i.orientation!=l&&(this.pane&&this.pane.destroy(),this._trackWrap.find("."+h).off(),this.element.find(".k-timeline-arrow").off(),this._trackWrap.off(),this.currentEventIndex=this.maxEvents=this.numOfEvents=this._currentIndex=this._eventPage=this._eventsList=this._eventsWrap=this.element=this._trackWrap=this.pane=null),t.destroy(this.element),this._dataFieldMappings=this.element=null},options:{autoBind:!0,name:"Timeline",orientation:"vertical",dateFormat:"MMM d, yyyy",showDateLabels:!0,collapsibleEvents:!1,alternatingMode:!1,dataTitleField:"title",dataDateField:"date",dataSubtitleField:"subtitle",dataDescriptionField:"description",dataImagesField:"images",dataActionsField:"actions",dataImagesAltField:"altField",navigatable:!1},events:["collapse","dataBound","expand","actionClick","change","navigate"]});t.ui.plugin(T)}(window.kendo.jQuery);kendo;function Rv(e){const t=Math.floor(e/26)-1;return(t>=0?Rv(t):"")+String.fromCharCode(65+e%26)}function Lv(e){return/^[a-z_][a-z0-9_]*$/i.test(e)?e:"'"+e.replace(/\x27/g,"\\'")+"'"}function Bv(e,t,n,i){let r="";return++t,isFinite(t)?null==i||2&i||(t="$"+t):t="",isFinite(n)?(r=Rv(n),null==i||1&i||(r="$"+r)):n="",e?Lv(e)+"!"+r+t:r+t}class Ov{constructor(){this.type="ref",this.sheet=""}clone(){return this}hasSheet(){return this._hasSheet}simplify(){return this}setSheet(e,t){return this.sheet=e,null!=t&&(this._hasSheet=t),this}absolute(e,t){return this}relative(...e){return this}adjust(e,t,n,i,r,o,a){return this}toString(){return this.relative(0,0,3,3).print(0,0)}forEach(e,t){e.call(t,this)}map(e,t){return e.call(t,this)}intersect(e){return this}intersects(e){return this.intersect(e)!==Vv}isCell(){return!1}toRow(e){return this}toColumn(e){return this}first(){return this}lastRange(){return this}size(){return 1}rangeAt(e){return this}nextRangeIndex(e){return 0}previousRangeIndex(e){return 0}eq(e){let t=this,n=e;if(t===Vv||n===Vv)return t===n;if((n instanceof $v||n instanceof Uv&&!(t instanceof $v))&&(t=e,n=this),t instanceof $v)return n=n.simplify(),n instanceof $v&&t.row==n.row&&t.col==n.col&&t.sheet==n.sheet;if(t instanceof Uv){if(n instanceof Uv)return n.topLeft.eq(t.topLeft)&&n.bottomRight.eq(t.bottomRight);if(n instanceof Wv)return n.single()&&t.eq(n.refs[0])}else if(t instanceof Wv&&n instanceof Wv){const e=t.refs,i=n.refs;if(e.length!=i.length)return!1;for(let t=0,n=e.length;t<n;t++)if(!e[t].eq(i[t]))return!1;return!0}return t===n}concat(e){return new Wv([this,e])}replaceAt(e,t){return t}forEachColumnIndex(e){this.forEachAxisIndex("col",e)}forEachRowIndex(e){this.forEachAxisIndex("row",e)}forEachRow(e){}forEachColumn(e){}forEachAxisIndex(e,t){let n=[];this["row"===e?"forEachRow":"forEachColumn"]((function(t){let i=t.first()[e];-1===n.indexOf(i)&&n.push(i)})),n.sort((function(e,t){return e>t?1:e<t?-1:0})).forEach(t)}valid(){return!1}renameSheet(e,t){if(this.sheet&&this.sheet.toLowerCase()==e.toLowerCase())return this.sheet=t,!0}}Ov.display=Bv;const Vv=new class extends Ov{print(){return"#NULL!"}eq(e){return e===this}forEach(){}};class Nv extends Ov{constructor(e){super(),this.name=e,this.ref="name"}clone(){return new Nv(this.name).setSheet(this.sheet,this.hasSheet())}print(){let e=Lv(this.name);return this.hasSheet()&&(e=Lv(this.sheet)+"!"+e),e}}class $v extends Ov{constructor(e,t,n){super(),this.row=e,this.col=t,this.rel=n||0,this.ref="cell"}clone(){return new $v(this.row,this.col,this.rel).setSheet(this.sheet,this.hasSheet())}intersect(e){return e instanceof $v?this.eq(e)?this:Vv:e.intersect(this)}print(e,t,n){let i,r=this.col,o=this.row,a=this.rel;if(null==e&&a){let e=this.hasSheet()?Lv(this.sheet)+"!":"";return r=isFinite(r)?1&a?"C["+r+"]":"C"+(r+1):"",o=isFinite(o)?2&a?"R["+o+"]":"R"+(o+1):"",e+o+r}return i=this.absolute(e,t),n?(o=i.row%1048576,r=i.col%16384,o<0&&(o+=1048576),r<0&&(r+=16384),Bv(this._hasSheet&&this.sheet,o,r,a)):i.valid()?Bv(this._hasSheet&&this.sheet,i.row,i.col,a):"#REF!"}absolute(e,t){let n=this.clone();return 3&n.rel?(1&n.rel&&(n.col=(n.col+t)%16384),2&n.rel&&(n.row=(n.row+e)%1048576),n.rel=0,n):n}toRangeRef(){return new Uv(this,this)}relative(e,t,n){null==n&&(n=this.rel);let i=2&n?this.row-e:this.row,r=1&n?this.col-t:this.col;return new $v(i,r,n).setSheet(this.sheet,this.hasSheet())}height(){return 1}width(){return 1}toString(){return Bv(null,this.row,this.col,3)}isCell(){return!0}leftColumn(){return this}rightColumn(){return this}topRow(){return this}bottomRow(){return this}forEachRow(e){e(this.toRangeRef())}forEachColumn(e){e(this.toRangeRef())}adjust(e,t,n,i,r,o,a){let s=this.absolute(e,t);if(r){if(s.row>=o){if(a<0&&s.row<o-a)return Vv;s.row+=a}}else if(s.col>=o){if(a<0&&s.col<o-a)return Vv;s.col+=a}return null!=n&&null!=i&&(s=s.relative(n,i,this.rel)),s}valid(){if(this.rel)throw new Error("valid() called on relative reference");let e=this.col,t=this.row;return!(isFinite(e)&&e<0||isFinite(t)&&t<0)}}class Uv extends Ov{constructor(e,t){super(),this.ref="range",e._hasSheet&&t._hasSheet&&e.sheet.toLowerCase()!=t.sheet.toLowerCase()&&(this.endSheet=t.sheet),this.topLeft=new $v(e.row,e.col,e.rel),this.bottomRight=new $v(t.row,t.col,t.rel),this.normalize()}clone(){return new Uv(this.topLeft.clone(),this.bottomRight.clone()).setSheet(this.sheet,this.hasSheet())}_containsRange(e){return this._containsCell(e.topLeft)&&this._containsCell(e.bottomRight)}_containsCell(e){return e.sheet==this.sheet&&e.row>=this.topLeft.row&&e.col>=this.topLeft.col&&e.row<=this.bottomRight.row&&e.col<=this.bottomRight.col}contains(e){if(e instanceof Array){let t=this;return e.some((function(e){return Boolean(t.contains(e))}))}return e instanceof $v?this._containsCell(e):e instanceof Uv&&this._containsRange(e)}_intersectRange(e){if(this.sheet!=e.sheet)return Vv;let t=this.topLeft.col,n=this.topLeft.row,i=this.bottomRight.col,r=this.bottomRight.row,o=e.topLeft.col,a=e.topLeft.row,s=e.bottomRight.col,l=e.bottomRight.row;return t<=s&&o<=i&&n<=l&&a<=r?new Uv(new $v(Math.max(n,a),Math.max(t,o)),new $v(Math.min(r,l),Math.min(i,s))).setSheet(this.sheet,this.hasSheet()):Vv}intersect(e){return e instanceof $v?this._containsCell(e)?e:Vv:e instanceof Uv?this._intersectRange(e).simplify():e instanceof Wv?e.intersect(this):Vv}simplify(){return this.isCell()?new $v(this.topLeft.row,this.topLeft.col,this.topLeft.rel).setSheet(this.sheet,this.hasSheet()):this}normalize(){let e,t=this.topLeft,n=this.bottomRight,i=t.row,r=t.col,o=n.row,a=n.col,s=2&t.rel,l=1&t.rel,c=2&n.rel,d=1&n.rel,u=!1;return s===c&&l===d&&(i>o&&(u=!0,e=i,i=o,o=e,e=s,s=c,c=e),r>a&&(u=!0,e=r,r=a,a=e,e=l,l=d,d=e),u&&(this.topLeft=new $v(i,r,l|s),this.bottomRight=new $v(o,a,d|c))),this}print(e,t,n){if(n||this.absolute(e,t).valid()){let i=this.topLeft.print(e,t,n)+":"+this.bottomRight.print(e,t,n);return this.hasSheet()&&(i=Lv(this.sheet)+(this.endSheet?":"+Lv(this.endSheet):"")+"!"+i),i}return"#REF!"}absolute(e,t){return new Uv(this.topLeft.absolute(e,t),this.bottomRight.absolute(e,t)).setSheet(this.sheet,this.hasSheet())}relative(e,t,n,i){return null==i&&(i=n),new Uv(this.topLeft.relative(e,t,n),this.bottomRight.relative(e,t,i)).setSheet(this.sheet,this.hasSheet())}height(){if(this.topLeft.rel!=this.bottomRight.rel)throw new Error("Mixed relative/absolute references");return this.bottomRight.row-this.topLeft.row+1}width(){if(this.topLeft.rel!=this.bottomRight.rel)throw new Error("Mixed relative/absolute references");return this.bottomRight.col-this.topLeft.col+1}collapse(){return this.topLeft.toRangeRef()}leftColumn(){return new Uv(this.topLeft,new $v(this.bottomRight.row,this.topLeft.col))}rightColumn(){return new Uv(new $v(this.topLeft.row,this.bottomRight.col),this.bottomRight)}topRow(){return new Uv(this.topLeft,new $v(this.topLeft.row,this.bottomRight.col))}bottomRow(){return new Uv(new $v(this.bottomRight.row,this.topLeft.col),this.bottomRight)}toRangeRef(){return this}toRow(e){return e+=Math.max(0,this.topLeft.row),new Uv(new $v(e,this.topLeft.col),new $v(e,this.bottomRight.col)).setSheet(this.sheet,this.hasSheet())}toColumn(e){return e+=Math.max(0,this.topLeft.col),new Uv(new $v(this.topLeft.row,e),new $v(this.bottomRight.row,e)).setSheet(this.sheet,this.hasSheet())}toCell(e,t){return e+=Math.max(0,this.topLeft.row),t+=Math.max(0,this.topLeft.col),new $v(e,t,0).setSheet(this.sheet,this.hasSheet())}forEachRow(e){let t=this.topLeft.row,n=this.bottomRight.row,i=this.topLeft.col,r=this.bottomRight.col;for(let o=t;o<=n;o++)e(new Uv(new $v(o,i),new $v(o,r)))}forEachColumn(e){let t=this.topLeft.row,n=this.bottomRight.row,i=this.topLeft.col,r=this.bottomRight.col;for(let o=i;o<=r;o++)e(new Uv(new $v(t,o),new $v(n,o)))}intersecting(e){return e.filter((e=>e.toRangeRef().intersects(this)))}union(e,t){let n=this.intersecting(e),i=this.topLeft.row,r=this.topLeft.col,o=this.bottomRight.row,a=this.bottomRight.col,s=!1;n.forEach((function(e){(e=e.toRangeRef()).topLeft.row<i&&(s=!0,i=e.topLeft.row),e.topLeft.col<r&&(s=!0,r=e.topLeft.col),e.bottomRight.row>o&&(s=!0,o=e.bottomRight.row),e.bottomRight.col>a&&(s=!0,a=e.bottomRight.col),t&&t(e)}));let l=new Uv(new $v(i,r),new $v(o,a));return s?l.union(e,t):l}resize(e){let t=Math.max.bind(Math,0);function n(e){return e||0}let i=this.topLeft.row+n(e.top),r=this.topLeft.col+n(e.left),o=this.bottomRight.row+n(e.bottom),a=this.bottomRight.col+n(e.right);return r<0&&a<0||i<0&&o<0?Vv:i<=o&&r<=a?new Uv(new $v(t(i),t(r)),new $v(t(o),t(a))):Vv}move(e,t){return new Uv(new $v(this.topLeft.row+e,this.topLeft.col+t),new $v(this.bottomRight.row+e,this.bottomRight.col+t))}first(){return this.topLeft.clone().setSheet(this.sheet,this.hasSheet())}isCell(){return!this.endSheet&&this.topLeft.eq(this.bottomRight)}toString(){return this.topLeft+":"+this.bottomRight}adjust(e,t,n,i,r,o,a){let s=this.topLeft.adjust(e,t,n,i,r,o,a),l=this.bottomRight.adjust(e,t,n,i,r,o,a);return s===Vv&&l===Vv?Vv:(s===Vv?(s=this.topLeft.absolute(e,t),r?s.row=o:s.col=o,null!=n&&null!=i&&(s=s.relative(n,i,this.topLeft.rel))):l===Vv&&(l=this.bottomRight.absolute(e,t),r?l.row=o-1:l.col=o-1,null!=n&&null!=i&&(l=l.relative(n,i,this.bottomRight.rel))),new Uv(s,l).setSheet(this.sheet,this.hasSheet()).simplify())}valid(){return this.topLeft.valid()&&this.bottomRight.valid()}}class Wv extends Ov{constructor(e){super(),this.refs=e,this.length=e.length}clone(){return new Wv(this.refs.slice())}intersect(e){let t=[];for(let n=0;n<this.length;++n){let i=e.intersect(this.refs[n]);i!==Vv&&t.push(i)}return t.length>0?new Wv(t).simplify():Vv}simplify(){let e=new Wv(this.refs.reduce((function(e,t){return(t=t.simplify())!==Vv&&e.push(t),e}),[]));return e.empty()?Vv:e.single()?e.refs[0]:e}absolute(e,t){return new Wv(this.refs.map((function(n){return n.absolute(e,t)})))}forEach(e,t){this.refs.forEach((function(n){n instanceof Wv?n.forEach(e,t):e.call(t,n)}),t)}toRangeRef(){return this.refs[0].toRangeRef()}contains(e){return this.refs.some((function(t){return t.contains(e)}))}map(e,t){let n=[];return this.forEach((function(i){n.push(e.call(t,i))})),new Wv(n)}first(){return this.refs[0].first()}lastRange(){return this.refs[this.length-1]}size(){return this.length}single(){return 1==this.length}empty(){return 0===this.length}isCell(){return this.single()&&this.refs[0].isCell()}rangeAt(e){return this.refs[e]}nextRangeIndex(e){return e===this.length-1?0:e+1}previousRangeIndex(e){return 0===e?this.length-1:e-1}concat(e){return new Wv(this.refs.concat([e]))}print(e,t,n){return this.refs.map((function(i){return i.print(e,t,n)})).join(",")}replaceAt(e,t){let n=this.refs.slice();return n.splice(e,1,t),new Wv(n)}leftColumn(){return this.map((function(e){return e.leftColumn()}))}rightColumn(){return this.map((function(e){return e.rightColumn()}))}topRow(){return this.map((function(e){return e.topRow()}))}bottomRow(){return this.map((function(e){return e.bottomRow()}))}forEachRow(e){this.forEach((function(t){t.forEachRow(e)}))}forEachColumn(e){this.forEach((function(t){t.forEachColumn(e)}))}adjust(e,t,n,i,r,o,a){return this.map((function(s){return s.adjust(e,t,n,i,r,o,a)})).simplify()}toString(){return this.refs.map((function(e){return e.toString()})).join(", ")}valid(){for(let e=this.refs.length;--e>=0;)if(this.refs[e].valid())return!1;return!0}renameSheet(e,t){this.refs.forEach((function(n){n.renameSheet(e,t)}))}}const jv=new $v(0,0),qv=new Uv(new $v(0,0),new $v(1/0,1/0));qv.print=function(){return"#SHEET"};const Gv={view:{nameBox:"Name Box",errors:{modifyMerged:"Cannot change part of a merged cell.",openUnsupported:"Unsupported format. Please select an .xlsx file.",shiftingNonblankCells:"Cannot insert cells due to data loss possibility. Select another insert location or delete the data from the end of your worksheet.",insertColumnWhenRowIsSelected:"Cannot insert column when all columns are selected.",insertRowWhenColumnIsSelected:"Cannot insert row when all rows are selected.",filterRangeContainingMerges:"Cannot create a filter within a range containing merges",sortRangeContainingMerges:"Cannot sort a range containing merges",cantSortMultipleSelection:"Cannot sort multiple selection",cantSortNullRef:"Cannot sort empty selection",cantSortMixedCells:"Cannot sort range containing cells of mixed shapes",validationError:"The value that you entered violates the validation rules set on the cell.",cannotModifyDisabled:"Cannot modify disabled cells.",insertRowBelowLastRow:"Cannot insert row below the last row.",insertColAfterLastCol:"Cannot insert column to the right of the last column."},tabs:{home:"Home",insert:"Insert",data:"Data"}},menus:{cut:"Cut",copy:"Copy",paste:"Paste",merge:"Merge",unmerge:"Unmerge",delete:"Delete",hide:"Hide",unhide:"Unhide",bringToFront:"Bring to front",sendToBack:"Send to back"},workbook:{defaultSheetName:"Sheet"}},Kv={name:"Spreadsheet",toolbar:!0,sheetsbar:!0,rows:200,columns:50,rowHeight:20,columnWidth:64,headerHeight:20,headerWidth:32,excel:{fileName:"Workbook.xlsx",forceProxy:!1,proxyURL:""},messages:Gv,pdf:{area:"workbook",fileName:"Workbook.pdf",proxyURL:"",paperSize:"a4",landscape:!0,margin:null,title:null,author:null,subject:null,keywords:null,creator:"Kendo UI PDF Generator",date:null},defaultCellStyle:{fontFamily:"Arial",fontSize:12},useCultureDecimals:!1,locale:"en"},Yv={recalc:!0,selection:!0,activeCell:!0,layout:!0,sheetSelection:!0,resize:!0,editorChange:!1,editorClose:!1},Qv=46,Xv=9,Zv=13,Jv=38,e_=40,t_=33,n_=34,i_=121,r_=122,o_=66,a_=73,s_=85,l_=78,c_=72,d_=65,u_=82,h_=new RegExp("[\\u0041-\\u005A\\u0061-\\u007A\\u00AA\\u00B5\\u00BA\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377\\u037A-\\u037D\\u037F\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u048A-\\u052F\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05D0-\\u05EA\\u05F0-\\u05F2\\u0620-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA\\u07F4\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u08A0-\\u08B2\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0980\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u0A05-\\u0A0A\\u0A0F\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32\\u0A33\\u0A35\\u0A36\\u0A38\\u0A39\\u0A59-\\u0A5C\\u0A5E\\u0A72-\\u0A74\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8\\u0AAA-\\u0AB0\\u0AB2\\u0AB3\\u0AB5-\\u0AB9\\u0ABD\\u0AD0\\u0AE0\\u0AE1\\u0B05-\\u0B0C\\u0B0F\\u0B10\\u0B13-\\u0B28\\u0B2A-\\u0B30\\u0B32\\u0B33\\u0B35-\\u0B39\\u0B3D\\u0B5C\\u0B5D\\u0B5F-\\u0B61\\u0B71\\u0B83\\u0B85-\\u0B8A\\u0B8E-\\u0B90\\u0B92-\\u0B95\\u0B99\\u0B9A\\u0B9C\\u0B9E\\u0B9F\\u0BA3\\u0BA4\\u0BA8-\\u0BAA\\u0BAE-\\u0BB9\\u0BD0\\u0C05-\\u0C0C\\u0C0E-\\u0C10\\u0C12-\\u0C28\\u0C2A-\\u0C39\\u0C3D\\u0C58\\u0C59\\u0C60\\u0C61\\u0C85-\\u0C8C\\u0C8E-\\u0C90\\u0C92-\\u0CA8\\u0CAA-\\u0CB3\\u0CB5-\\u0CB9\\u0CBD\\u0CDE\\u0CE0\\u0CE1\\u0CF1\\u0CF2\\u0D05-\\u0D0C\\u0D0E-\\u0D10\\u0D12-\\u0D3A\\u0D3D\\u0D4E\\u0D60\\u0D61\\u0D7A-\\u0D7F\\u0D85-\\u0D96\\u0D9A-\\u0DB1\\u0DB3-\\u0DBB\\u0DBD\\u0DC0-\\u0DC6\\u0E01-\\u0E30\\u0E32\\u0E33\\u0E40-\\u0E46\\u0E81\\u0E82\\u0E84\\u0E87\\u0E88\\u0E8A\\u0E8D\\u0E94-\\u0E97\\u0E99-\\u0E9F\\u0EA1-\\u0EA3\\u0EA5\\u0EA7\\u0EAA\\u0EAB\\u0EAD-\\u0EB0\\u0EB2\\u0EB3\\u0EBD\\u0EC0-\\u0EC4\\u0EC6\\u0EDC-\\u0EDF\\u0F00\\u0F40-\\u0F47\\u0F49-\\u0F6C\\u0F88-\\u0F8C\\u1000-\\u102A\\u103F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065\\u1066\\u106E-\\u1070\\u1075-\\u1081\\u108E\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F4\\u1401-\\u166C\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u16EE-\\u16F8\\u1700-\\u170C\\u170E-\\u1711\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7\\u17DC\\u1820-\\u1877\\u1880-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191E\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19C1-\\u19C7\\u1A00-\\u1A16\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4B\\u1B83-\\u1BA0\\u1BAE\\u1BAF\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1CE9-\\u1CEC\\u1CEE-\\u1CF1\\u1CF5\\u1CF6\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2160-\\u2188\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2\\u2CF3\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303C\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312D\\u3131-\\u318E\\u31A0-\\u31BA\\u31F0-\\u31FF\\u3400-\\u4DB5\\u4E00-\\u9FCC\\uA000-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B\\uA640-\\uA66E\\uA67F-\\uA69D\\uA6A0-\\uA6EF\\uA717-\\uA71F\\uA722-\\uA788\\uA78B-\\uA78E\\uA790-\\uA7AD\\uA7B0\\uA7B1\\uA7F7-\\uA801\\uA803-\\uA805\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB\\uA90A-\\uA925\\uA930-\\uA946\\uA960-\\uA97C\\uA984-\\uA9B2\\uA9CF\\uA9E0-\\uA9E4\\uA9E6-\\uA9EF\\uA9FA-\\uA9FE\\uAA00-\\uAA28\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAA60-\\uAA76\\uAA7A\\uAA7E-\\uAAAF\\uAAB1\\uAAB5\\uAAB6\\uAAB9-\\uAABD\\uAAC0\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEA\\uAAF2-\\uAAF4\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\\uAB16\\uAB20-\\uAB26\\uAB28-\\uAB2E\\uAB30-\\uAB5A\\uAB5C-\\uAB5F\\uAB64\\uAB65\\uABC0-\\uABE2\\uAC00-\\uD7A3\\uD7B0-\\uD7C6\\uD7CB-\\uD7FB\\uF900-\\uFA6D\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D\\uFB1F-\\uFB28\\uFB2A-\\uFB36\\uFB38-\\uFB3C\\uFB3E\\uFB40\\uFB41\\uFB43\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE70-\\uFE74\\uFE76-\\uFEFC\\uFF21-\\uFF3A\\uFF41-\\uFF5A\\uFF66-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC]");function p_(e){let t=Object.create(null);return function(){let n="";for(let e=arguments.length;--e>=0;)n+=":"+arguments[e];return n in t?t[n]:t[n]=e.apply(this,arguments)}}function f_(e,t){try{return e.call(t,(function(e){throw new n(e)}))}catch(e){if(e instanceof n)return e.value;throw e}function n(e){this.value=e}}const m_={undefined:e=>e},g_=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g;function v_(e,t){const n=e+t;if(m_[n])return m_[n];const i=[];return e.replace(g_,((e,t,n,r)=>{i.push(x_(t)?t:n||r)})),m_[n]=e=>{let n=e;for(let e=0;e<i.length;e++)if(n=n[i[e]],!x_(n)&&t)return n;return n},m_[n]}function __(e){let t=1,n=arguments.length;for(t=1;t<n;t++)b_(e,arguments[t]);return e}function b_(e,t){let n,i,r,o;for(n in t)"__proto__"!==n&&"constructor"!==n&&(i=t[n],r=typeof i,i instanceof Date?e[n]=new Date(i.getTime()):T_(i?.clone)?e[n]=i.clone():"object"===r&&null!==i&&D_(i)?(o=e[n],"object"==typeof o&&null!==o||(e[n]={}),b_(e[n],i)):"undefined"!==r&&(e[n]=i));return e}const y_={},w_=function(e){if(!isNaN(y_._scrollbar)&&!e)return y_._scrollbar;let t,n=document.createElement("div");return n.style.overflow="scroll",n.style.overflowX="hidden",n.style.zoom="1",n.style.clear="both",n.style.display="block",n.innerHTML="&nbsp;",document.body.appendChild(n),y_._scrollbar=t=n.offsetWidth-n.scrollWidth,document.body.removeChild(n),t};const k_=function(e,t){t.parentNode.insertBefore(e,t.nextSibling)},x_=e=>null!=e,C_=e=>e&&e.getTime,S_=e=>"string"==typeof e,T_=e=>"function"==typeof e,D_=function(e){if(!e||"[object Object]"!==toString.call(e))return!1;const t=Object.getPrototypeOf(e);return null===t||t.constructor===Object};class A_{constructor(e){if(e instanceof A_)return e;this.code=e}toString(){return"#"+this.code+("NAME"===this.code?"?":"!")}}let M_={};const E_=e=>{if(!e)return M_;M_=e},I_=()=>E_().localeInfo();let z_={runtime:{FUNCS:Object.create(null)}},P_=z_.runtime.FUNCS;class H_{constructor(e,t,n,i){this.callback=e,this.formula=t,this.ss=n,this.parent=i}resolve(e){var t=this;e instanceof Ov?t.resolveCells([e],(function(){t._resolve(e)})):t._resolve(e)}error(e){return new A_(e)}_resolve(e){e=void 0===e?null:Array.isArray(e)?this.asMatrix(e):N_(e);var t=this.formula;t.arrayFormulaRange?e=this.asMatrix(e)||this.asMatrix([[e]]):e instanceof Uv&&(e=this._arrayArg(e)),t.value=e,this.ss.onFormula(t)&&this.callback&&this.callback.call(t,e)}resolveCells(e,t){var n=this,i=[];if(function e(t){for(var i=0;i<t.length;++i){var r=t[i];r instanceof Ov&&a(n.getRefCells(r)),Array.isArray(r)&&e(r)}}(e),!i.length)return t.call(n);for(var r=i.length,o=0;o<i.length;++o)i[o].exec(n.ss,(function(){--r||t.call(n)}),n);function a(e){for(var t=0;t<e.length;++t){var n=e[t];n.formula&&i.push(n.formula)}return!0}}cellValues(e,t){for(var n=[],i=0;i<e.length;++i){var r=e[i];r instanceof Ov?(r=this.getRefData(r,t),n=n.concat(r)):Array.isArray(r)?n=n.concat(this.cellValues(r,t)):r instanceof R_?n=n.concat(this.cellValues(r.data,t)):n.push(r)}return n}fetchName(e,t){var n=this.formula,i=this.ss.nameValue(e,n.sheet,n.row,n.col);if(i instanceof B_){i=i.clone(n.sheet,n.row,n.col,!0);var r=new z_.ValidationFormulaContext(this.ss.workbook);i.exec(r,t,this)}else i instanceof Ov&&((i=i.absolute(n.row,n.col))instanceof Uv&&this.ss.isMerged(i)&&(i=i.topLeft),i.sheet||(i.sheet=n.sheet)),t(null==i?new A_("NAME"):i)}force(e){return e instanceof Ov?this.getRefData(e):e}func(e,t,n){e=e.toLowerCase();var i=P_[e];if(i)return i.call(this,t,n);t(new A_("NAME"))}bool(e){return e instanceof Ov&&(e=this.getRefData(e)),"string"==typeof e?"true"==e.toLowerCase():"number"==typeof e?0!==e:"boolean"==typeof e?e:null!=e}_arrayArg(e){var t=this.formula;return!t.arrayFormulaRange&&e instanceof Uv?1==e.height()&&t.col>=e.topLeft.col&&t.col<=e.bottomRight.col?this.getRefData(new $v(e.topLeft.row,t.col).setSheet(e.sheet)):1==e.width()&&t.row>=e.topLeft.row&&t.row<=e.bottomRight.row?this.getRefData(new $v(t.row,e.topLeft.col).setSheet(e.sheet)):new A_("VALUE"):this.asMatrix(e)}asMatrix(e){if(e instanceof R_)return e;let t=this;if(e instanceof Uv){let n=e.topLeft,i=n.row,r=n.col,o=t.getRefCells(e),a=new R_(t);return isFinite(e.width())&&(a.width=e.width()),isFinite(e.height())&&(a.height=e.height()),isFinite(i)||(i=0),isFinite(r)||(r=0),o.forEach((function(e){a.set(e.row-i,e.col-r,e.value)})),a}if(Array.isArray(e)&&e.length>0){let n=new R_(t),i=0;return e.forEach((function(e){let r=0,o=1;e.forEach((function(e){let a=e instanceof Uv;e instanceof Ov&&!a&&(e=t.getRefData(e)),(a||Array.isArray(e))&&(e=t.asMatrix(e)),e instanceof R_?(e.each((function(e,t,o){n.set(i+t,r+o,e)})),o=Math.max(o,e.height),r+=e.width):("string"==typeof e&&e.length&&!isNaN(e)&&(e=Number(e)),n.set(i,r++,e))})),i+=o})),n}}getRefCells(e,t,n){var i=this.formula;return this.ss.getRefCells(e,t,i.sheet,i.row,i.col,n)}getRefData(e,t){var n=this.formula;return this.ss.getData(e,n.sheet,n.row,n.col,t)}workbook(){return this.ss.workbook}}function F_(e,t,n){for(var i=n(e),r=e;++e<t;){var o=n(e);o>i&&(i=o,r=e)}return r}let R_=class e{constructor(e){this.context=e,this.height=0,this.width=0,this.data=[]}clone(){var t=new e(this.context);return t.height=this.height,t.width=this.width,t.data=this.data.map((function(e){return e.slice()})),t}get(e,t){var n=this.data[e],i=n?n[t]:null;return i instanceof Ov?this.context.getRefData(i):i}getNA(e,t){return 1==this.height&&(e=0),1==this.width&&(t=0),e<this.height&&t<this.width?this.get(e,t):new A_("N/A")}set(e,t,n){var i=this.data[e];null==i&&(i=this.data[e]=[]),i[t]=n,e>=this.height&&(this.height=e+1),t>=this.width&&(this.width=t+1)}each(e,t){for(var n=0;n<this.height;++n)for(var i=0;i<this.width;++i){var r=this.get(n,i);if((t||null!=r)&&void 0!==(r=e.call(this.context,r,n,i)))return r}}map(t,n){var i=new e(this.context);return this.each((function(e,n,r){i.set(n,r,t.call(this,e,n,r))}),n),i}eachRow(e){for(var t=0;t<this.height;++t){var n=e.call(this.context,t);if(void 0!==n)return n}}eachCol(e){for(var t=0;t<this.width;++t){var n=e.call(this.context,t);if(void 0!==n)return n}}mapRow(t){var n=new e(this.context);return this.eachRow((function(e){n.set(e,0,t.call(this.context,e))})),n}mapCol(t){var n=new e(this.context);return this.eachCol((function(e){n.set(0,e,t.call(this.context,e))})),n}toString(){return JSON.stringify(this.data)}transpose(){var t=new e(this.context);return this.each((function(e,n,i){t.set(i,n,e)})),t}unit(e){this.width=this.height=e;for(var t=this.data=new Array(e),n=e;--n>=0;)for(var i=t[n]=new Array(e),r=e;--r>=0;)i[r]=n==r?1:0;return this}multiply(t){for(var n=this,i=new e(n.context),r=0;r<n.height;++r)for(var o=0;o<t.width;++o){for(var a=0,s=0;s<n.width;++s){var l=n.get(r,s),c=t.get(s,o);if("number"!=typeof l||"number"!=typeof c)throw new A_("VALUE");a+=l*c}i.set(r,o,a)}return i}adds(t,n){for(var i=this,r=new e(i.context),o=n?-1:1,a=0;a<i.height;++a)for(var s=0;s<i.width;++s){var l=i.get(a,s),c=t.get(a,s);r.set(a,s,l+o*c)}return r}determinant(){var e,t,n,i,r=this.clone().data,o=r.length,a=1;for(e=0;e<o;e++){for(t=e;t<o&&!r[t][e];t++);if(t==o)return 0;if(t!=e)for(a=-a,i=e;i<o;i++){var s=r[e][i];r[e][i]=r[t][i],r[t][i]=s}for(n=e+1;n<o;n++)for(i=e+1;i<o;i++)r[n][i]-=r[e][i]*r[n][e]/r[e][e];a*=r[e][e]}return a}inverse(){let t,n=this.width,i=this.augment(new e(this.context).unit(n)),r=i.data;for(let e=0;e<n;++e){let i=F_(e,n,(function(t){return r[t][e]}));if(!r[i][e])return null;e!=i&&(t=r[e],r[e]=r[i],r[i]=t);for(let t=e+1;t<n;++t){for(let i=e+1;i<2*n;++i)r[t][i]-=r[e][i]*r[t][e]/r[e][e];r[t][e]=0}}for(let e=0;e<n;++e)for(let t=r[e][e],i=0;i<2*n;++i)r[e][i]/=t;for(let e=n;--e>=0;)for(let t=e;--t>=0;)if(r[t][e])for(let i=2*n;--i>=n;)r[t][i]-=r[e][i]*r[t][e];return i.slice(0,n,n,n)}augment(e){var t=this.clone(),n=t.width;return e.each((function(e,i,r){t.set(i,r+n,e)})),t}slice(t,n,i,r){for(var o=new e(this.context),a=0;a<i;++a)for(var s=0;s<r;++s)o.set(a,s,this.get(t+a,n+s));return o}};function L_(e,t){if(e.constructor!==t.constructor)return!1;if(e instanceof $v)return e.sheet==t.sheet&&e.row==t.row&&e.col==t.col&&e.rel==t.rel;if(e instanceof Uv)return L_(e.topLeft,t.topLeft)&&L_(e.bottomRight,t.bottomRight)&&e.endSheet==t.endSheet;if(e instanceof Wv){var n=e.refs.length;if(n!=t.refs.length)return!1;for(;--n>=0;)if(!L_(e.refs[n],t.refs[n]))return!1}return!0}let B_=class e{constructor(e,t,n,i,r,o,a){this.refs=e,this.handler=t,this.print=n,this.absrefs=null,this.sheet=i,this.row=r,this.col=o,this.onReady=[],this.pending=!1,this.arrayFormulaRange=a}setArrayFormulaRange(e){this.arrayFormulaRange=e.clone().setSheet(this.sheet)}clone(t,n,i,r){var o=t.toLowerCase(),a=this.refs,s=this.arrayFormulaRange;return(r||o!=this.sheet.toLowerCase())&&(a=a.map((function(e){return e.hasSheet()||e.sheet&&e.sheet.toLowerCase()==o||(e=e.clone().setSheet(t)),e})),s&&(s=s.clone().setSheet(t))),new e(a,this.handler,this.print,t,n,i,s)}deepClone(){var t=this.refs.map((function(e){return e.clone()}));return new e(t,this.handler,this.print,this.sheet,this.row,this.col,this.arrayFormulaRange)}resolve(e){this.pending=!1,this.onReady.forEach((function(t){t(e)}))}exec(e,t,n){if("value"in this)t&&t(this.value);else{t&&this.onReady.push(t);for(var i=new H_(this.resolve,this,e,n),r=0;n;){if(n.formula===this)return this.pending=!1,void i.resolve(new A_("CIRCULAR"));n=n.parent,++r}if(this.pending)return;this.pending=!0;var o=function(){this.absrefs||(this.absrefs=this.refs.map((function(e){return e.absolute(this.row,this.col)}),this)),this.handler.call(i)}.bind(this);r<20?o():setTimeout(o,0)}}reset(){this.onReady=[],this.pending=!1,delete this.value}renameSheet(e,t){e=e.toLowerCase(),this.absrefs=null,this.sheet.toLowerCase()==e&&(this.sheet=t),this.refs.forEach((function(n){n.renameSheet(e,t)}))}adjust(t,n,i,r){t=t.toLowerCase();var o=this.row,a=this.col,s=this.sheet.toLowerCase(),l=!1;s==t&&("row"==n&&o>=i&&(this.row+=r,l=!0),"col"==n&&a>=i&&(this.col+=r,l=!0));var c=this.row,d=this.col;this.absrefs=null;var u=this.refs,h=l;this.refs=u.map((function(e){var t=f(e);return h||L_(t,e)||(h=!0),t}));var p=this.arrayFormulaRange;if(p&&(this.arrayFormulaRange=f(p),h||L_(p,this.arrayFormulaRange)||(h=!0)),h)return new e(u,this.handler,this.print,this.sheet,o,a,p);function f(e){return e===Vv?e:e.sheet.toLowerCase()!=t?(l&&("row"==n&&o>=i&&(e=e.relative(r,0)),"col"==n&&a>=i&&(e=e.relative(0,r))),e):e.adjust(o,a,c,d,"row"==n,i,r)}}toString(){return this.print(this.row,this.col)}};function O_(e,t){var n,i,r,o="function arrayArgs(args) { var xargs = [], width = 0, height = 0, arrays = [], i = 0; ",a="function resolve(args, callback) { var toResolve = [], i = 0; ",s="'use strict'; function check(args) { var stack = [], tmp, xargs = [], i = 0, m, err = 'VALUE'; ",l=!1,c=!1,d=!1;return s+=t.map((function e(t){n=t[0];var r="{ ";if(Array.isArray(n))o+="while (i < args.length) { ",a+="while (i < args.length) { ",r+="xargs.push(tmp = []); stack.push(xargs); xargs = tmp; ",r+="while (i < args.length) { ",r+=t.map(e).join(""),r+="} ",r+="xargs = stack.pop(); ",a+="} ",o+="} ";else if("+"==n)o+="while (i < args.length) { ",a+="while (i < args.length) { ",r+="if (i >= args.length) return new CalcError('N/A'); ",r+="xargs.push(tmp = []); stack.push(xargs); xargs = tmp; ",r+="do { ",r+=t.slice(1).map(e).join(""),r+="} while (i < args.length); ",r+="xargs = stack.pop(); ",a+="} ",o+="} ";else if("?"==n)r+="if (!("+p(t[1])+")) return new CalcError(err); ";else{var s=t[1];if(Array.isArray(s)&&/^#?collect/.test(s[0])){var l=/!$/.test(s[0]),h=s[2];u(),r+="try {var $"+n+" = this.cellValues(args.slice(i",h&&(r+=", i + "+h),r+=")"+(l?",true":"")+").reduce(function(ret, $"+n+"){ ","#"!=s[0].charAt(0)&&(r+="if ($"+n+" instanceof CalcError) throw $"+n+"; "),r+="if ("+p(s[1])+") ret.push($"+n+"); ",r+="return ret; ",r+="}.bind(this), []); ",r+=h?"i += "+h+"; ":"i = args.length; ",r+="xargs.push($"+n+")} catch(ex) { if (ex instanceof CalcError) return ex; throw ex; } ",a+="toResolve.push(args.slice(i)); "}else if("rest"==s)r+="xargs.push(args.slice(i)); i = args.length; ";else{(c=/^\*/.test(n))&&(d=!0,n=n.substr(1)),r+="var $"+n+" = args[i++]; ";var f=!1;/!$/.test(s)?(s=s.substr(0,s.length-1),f=!0):r+="if ($"+n+" instanceof CalcError) return $"+n+"; ",r+=function(e,t){i=!1;var r="if (!("+p(e)+")) { ";i&&!t&&(r+=" if ($"+n+" instanceof CalcError) return $"+n+"; ");i||(a+="i++; ");o+=c?"var $"+n+" = this._arrayArg(args[i]); if ($"+n+") { xargs.push($"+n+"); width = Math.max(width, $"+n+".width); height = Math.max(height, $"+n+".height); arrays.push(true) } else { xargs.push(args[i]); arrays.push(false); } i++; ":"xargs.push(args[i++]); arrays.push(false); ";return r+="return new CalcError(err); } "}(s,f)+"xargs.push($"+n+"); "}}return r+="} "})).join(""),s+="if (i < args.length) return new CalcError('N/A'); ",s+="return xargs; } ",o+="return { args: xargs, width: width, height: height, arrays: arrays }; } ",l?(a+="this.resolveCells(toResolve, callback); } ",r=new Function("kendo","CalcError","round",s+a+o+" return { resolve: resolve, check: check, arrayArgs: arrayArgs };")):r=new Function("kendo","CalcError","round",s+" return { check: check };"),r=r(z_.kendo,A_,V_),d||delete r.arrayArgs,r;function u(){return i?"$"+n:(l=!0,i=!0,a+="toResolve.push(args[i++]); ","($"+n+" = this.force($"+n+"))")}function h(e){return"("+(e?"(typeof "+u()+" == 'number' ? ($"+n+" = round($"+n+"), true) : false) || ":"(typeof "+u()+" == 'number') || ")+"(typeof $"+n+" == 'boolean' ? ($"+n+" = +$"+n+", true) : false) || (typeof $"+n+" == 'string' && !/^(?:=|true|false)/i.test($"+n+") ? (tmp = kendo.spreadsheet.calc.parse(0, 0, 0, $"+n+"), /^date|number|percent$/.test(tmp.type) ? ($"+n+" = +tmp.value, true) : false) : false))"}function p(e){if(Array.isArray(e)){if("or"==e[0])return"("+e.slice(1).map(p).join(") || (")+")";if("and"==e[0])return"("+e.slice(1).map(p).join(") && (")+")";if("values"==e[0])return"("+e.slice(1).map((function(e){return u()+" === "+e})).join(") || (")+")";if("null"==e[0])return"("+p("null")+" ? (($"+n+" = "+e[1]+"), true) : false)";if("between"==e[0]||"[between]"==e[0])return"("+u()+" >= "+e[1]+" && $"+n+" <= "+e[2]+" ? true : ((err = 'NUM'), false))";if("(between)"==e[0])return"("+u()+" > "+e[1]+" && $"+n+" < "+e[2]+" ? true : ((err = 'NUM'), false))";if("(between]"==e[0])return"("+u()+" > "+e[1]+" && $"+n+" <= "+e[2]+" ? true : ((err = 'NUM'), false))";if("[between)"==e[0])return"("+u()+" >= "+e[1]+" && $"+n+" < "+e[2]+" ? true : ((err = 'NUM'), false))";if("assert"==e[0]){var t=e[2]||"N/A";return"(("+e[1]+") ? true : (err = "+JSON.stringify(t)+", false))"}if("not"==e[0])return"!("+p(e[1])+")";throw new Error("Unknown array type condition: "+e[0])}if("number"==e||"datetime"==e)return h(!0);if("number!"==e)return"(typeof "+u()+" == 'number' ? ($"+n+" = round($"+n+"), true) : false)";if("integer"==e||"date"==e)return"("+h()+" && (($"+n+" |= 0), true))";if("divisor"==e)return"("+h(!0)+" && ($"+n+" == 0 ? ((err = 'DIV/0'), false) : true))";if("number+"==e)return"("+h(!0)+" && ($"+n+" >= 0 ? true : ((err = 'NUM'), false)))";if("integer+"==e)return"("+h()+" && (($"+n+" |= 0) >= 0 ? true : ((err = 'NUM'), false)))";if("number++"==e)return"("+h(!0)+" && ($"+n+" > 0 ? true : ((err = 'NUM'), false)))";if("integer++"==e)return"("+h()+" && (($"+n+" |= 0) > 0 ? true : ((err = 'NUM'), false)))";if("string"==e)return"((typeof "+u()+" == 'string' || typeof $"+n+" == 'boolean' || typeof $"+n+" == 'number') ? ($"+n+" += '', true) : ($"+n+" === undefined ? (($"+n+" = ''), true) : false))";if("boolean"==e)return"(typeof "+u()+" == 'boolean')";if("logical"==e)return"(typeof "+u()+" == 'boolean' || (typeof $"+n+" == 'number' ? ($"+n+" = !!$"+n+", true) : false))";if("matrix"==e)return u(),"((m = this.asMatrix($"+n+")) ? ($"+n+" = m) : false)";if("#matrix"==e)return"((m = this.asMatrix($"+n+")) ? ($"+n+" = m) : false)";if("ref"==e)return"($"+n+" instanceof kendo.spreadsheet.Ref)";if("area"==e)return"($"+n+" instanceof kendo.spreadsheet.CellRef || $"+n+" instanceof kendo.spreadsheet.RangeRef)";if("cell"==e)return"($"+n+" instanceof kendo.spreadsheet.CellRef)";if("null"==e)return"("+u()+" == null)";if("anyvalue"==e)return"("+u()+" != null && i <= args.length)";if("forced"==e)return"("+u()+", i <= args.length)";if("anything"==e)return"(i <= args.length)";if("blank"==e)return"("+u()+" == null || $"+n+" === '')";throw new Error("Can't check for type: "+e)}}function V_(e,t){return e===parseInt(e,10)?e:+e.toPrecision(t||16)}function N_(e,t){return"number"==typeof e?V_(e,t):e}function $_(e,t,n){if(n instanceof A_)return n;try{return t.apply(e,n)}catch(e){if(e instanceof A_)return e;throw e}}function U_(e,t,n,i){return function(r,o){function a(){if(i){let t=i.call(this,o);if(o=t.args,t.width>0&&t.height>0){let i=new R_(this);for(let r=0;r<t.height;++r)for(let a=0;a<t.width;++a){let s=[];for(let e=0;e<o.length;++e)t.arrays[e]?s[e]=o[e].getNA(r,a):s[e]=o[e];s=n.call(this,s),i.set(r,a,$_(this,e,s))}return r(i)}}let t=n.call(this,o);r($_(this,e,t))}t?t.call(this,o,a):a.call(this)}}function W_(e,t,n,i){return function(r,o){function a(){if(i){let t=i.call(this,o);if(o=t.args,t.width>0&&t.height>0){let i=new R_(this),a=t.width*t.height,s=function(e,t){return function(n){if(i.set(e,t,n),--a,0===a)return r(i)}};for(let l=0;l<t.height&&a>0;++l)for(let c=0;c<t.width&&a>0;++c){let d=[];for(let e=0;e<o.length;++e)t.arrays[e]?d[e]=o[e].getNA(l,c):d[e]=o[e];if(d=n.call(this,d),d instanceof A_){if(i.set(l,c,d),--a,0===a)return r(i)}else d.unshift(s(l,c)),e.apply(this,d)}return}}let t=n.call(this,o);t instanceof A_?r(t):(t.unshift(r),e.apply(this,t))}t?t.call(this,o,a):a.call(this)}}function j_(e,t,n){return(1461*(e+4800+((++t-14)/12|0))/4|0)+(367*(t-2-12*((t-14)/12|0))/12|0)-(3*((e+4900+((t-14)/12|0))/100|0)/4|0)+n-32075}P_.if=function(e,t){var n=this,i=t[0],r=t[1],o=t[2];this.resolveCells([i],(function(){var t=n.asMatrix(i);t?r((function(i){o((function(r){var o=n.asMatrix(i),a=n.asMatrix(r);e(t.map((function(e,t,s){return e instanceof A_?e:n.bool(e)?o?o.get(t,s):i:a?a.get(t,s):r})))}))})):(i=this.force(i))instanceof A_?e(i):n.bool(i)?r(e):o(e)}))},P_["φ"]=function(e){e((1+Math.sqrt(5))/2)};var q_=j_(1900,0,-1),G_=[31,28,31,30,31,30,31,31,30,31,30,31],K_=[[0,31,59,90,120,151,181,212,243,273,304,334],[0,31,60,91,121,152,182,213,244,274,305,335]];function Y_(e){return e%4?0:e%100?1:e%400?0:1}function Q_(e,t){return Y_(e)&&1==t?29:G_[t]}function X_(e){return n=(t=(0|e)+q_)+68569,s=(n=(n-=(146097*(i=4*n/146097|0)+3)/4|0)-(1461*(o=4e3*(n+1)/1461001|0)/4|0)+31)-(2447*(r=80*n/2447|0)/80|0),a=r+2-12*(n=r/11|0),{year:l=100*(i-49)+o+n,month:--a,date:s,day:(t+1)%7,ord:K_[Y_(l)][a]+s};var t,n,i,r,o,a,s,l}function Z_(e,t,n){return j_(e,t,n)-q_}var J_=6e4,eb=36e5;function tb(e){var t=e-(0|e);t<0&&t++;var n=Math.round(864e5*t),i=Math.floor(n/eb);n-=i*eb;var r=Math.floor(n/J_);n-=r*J_;var o=Math.floor(n/1e3);return{hours:i,minutes:r,seconds:o,milliseconds:n-=1e3*o}}function nb(e,t,n,i){return(e+(t+(n+i/1e3)/60)/60)/24}class ib{constructor(e,t){this.message=e,this.pos=t}toString(){return this.message}}function rb(){this.node=null}function ob(){}z_.runtime.CalcError=A_,z_.runtime.Formula=B_,z_.runtime.Matrix=R_,z_.runtime.packDate=Z_,z_.runtime.unpackDate=X_,z_.runtime.packTime=nb,z_.runtime.unpackTime=tb,z_.runtime.serialToDate=function(e){var t=X_(e),n=tb(e);return new Date(t.year,t.month,t.date,n.hours,n.minutes,n.seconds,n.milliseconds)},z_.runtime.dateToSerial=function(e){var t=nb(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds());return(e=Z_(e.getFullYear(),e.getMonth(),e.getDate()))<0?e-1+t:e+t},z_.runtime.daysInMonth=Q_,z_.runtime.validDate=function(e,t,n){return t>=1&&t<=12&&n>=1&&n<=Q_(e,t-1)},z_.runtime.isLeapYear=Y_,z_.runtime.daysInYear=function(e){return Y_(e)?366:365},z_.runtime.parseDate=function(e,t){t&&(t=z_.formatting.makeDateFormat(t));const n=E_().parseDate;return n(e,t)||n(e)||n(e,["MMMM dd yyyy","MMMM dd yy","MMM dd yyyy","MMM dd yy","dd MMMM yyyy","dd MMMM yy","dd MMM yyyy","dd MMM yy","MMMM dd, yyyy","MMMM dd, yy","MMM dd, yyyy","MMM dd, yy","MMMM dd","MMM dd","MMMM yyyy","MMM yyyy","dd MMMM","dd MMM"])},z_.runtime.limitPrecision=V_,z_.runtime.defineBuiltinFunction=function(e,t,n,i){P_[e]=t?W_(i,n.resolve,n.check,n.arrayArgs):U_(i,n.resolve,n.check,n.arrayArgs)},z_.runtime.defineAlias=function(e,t){var n=P_[t];if(!n)throw new Error("Function "+t+" is not yet defined");n.kendoSpreadsheetAliases||(n.kendoSpreadsheetAliases=[t]),n.kendoSpreadsheetAliases.push(e),P_[e]=n},z_.runtime.InputStream=function(e){let t=0;return{next:n,peek:i,eof:r,croak:o,readWhile:function(e){let t="";for(;!r()&&e(i(),t);)t+=n();return t},readEscaped:function(e){let t=!1,i="";for(;!r();){let r=n();if(t)i+=r,t=!1;else if("\\"===r)t=!0;else{if(r===e)break;i+=r}}return i},lookingAt:function(n){return n.exec(e.substr(t))},skip:function(n){if("string"==typeof n)e.substr(t,n.length)!==n&&o("Expected "+n),a(n.length);else if(n instanceof RegExp){let i=n.exec(e.substr(t));if(i)return a(i[0].length),i}else a(n[0].length)},forward:a,pos:function(){return t}};function n(){return e.charAt(t++)}function i(){return e.charAt(t)}function r(){return""===i()}function o(n){throw new ib(n+" (input: "+e+")",t)}function a(e){for(;e-- >0;)n()}},z_.runtime.ParseError=ib,rb.prototype={remove:function(){this.node.parentNode&&this.node.parentNode.removeChild(this.node),this.attr={}},attr:{},text:function(){return""}},ob.prototype={nodeName:"#null",attr:{style:{}},children:[],remove:function(){}};let ab=new ob;function sb(e,t,n){this.nodeName=e,this.attr=t||{},this.children=n||[]}function lb(e){this.nodeValue=String(e)}function cb(e){this.html=e}function db(e){return new cb(e)}function ub(e,t,n){return new sb(e,t,n)}function hb(e){return new lb(e)}function pb(e){this.root=e,this.children=[]}sb.prototype=new rb,sb.prototype.appendTo=function(e){let t="string"==typeof this.nodeName?document.createElement(this.nodeName):this.nodeName,n=this.children;for(let e=0;e<n.length;e++)n[e].render(t,ab);return e.appendChild(t),t},sb.prototype.render=function(e,t){let n;if(t.nodeName!==this.nodeName)t.remove(),n=this.appendTo(e);else{let i;n=t.node;let r=this.children,o=r.length,a=t.children,s=a.length;if(Math.abs(s-o)>2)return void this.render({appendChild:function(n){e.replaceChild(n,t.node)}},ab);for(i=0;i<o;i++)r[i].render(n,a[i]||ab);for(i=o;i<s;i++)a[i].remove()}this.node=n,this.syncAttributes(t.attr),this.removeAttributes(t.attr)},sb.prototype.syncAttributes=function(e){let t=this.attr;for(let n in t){let i=t[n],r=e[n];"style"===n?this.setStyle(i,r):i!==r&&this.setAttribute(n,i,r)}},sb.prototype.setStyle=function(e,t){let n,i=this.node;if(t)for(n in e)e[n]!==t[n]&&(i.style[n]=e[n]);else for(n in e)i.style[n]=e[n]},sb.prototype.removeStyle=function(e){let t=this.attr.style||{},n=this.node;for(let i in e)void 0===t[i]&&(n.style[i]="")},sb.prototype.removeAttributes=function(e){let t=this.attr;for(let n in e)"style"===n?this.removeStyle(e.style):void 0===t[n]&&this.removeAttribute(n)},sb.prototype.removeAttribute=function(e){let t=this.node;"style"===e?t.style.cssText="":"className"===e?t.className="":t.removeAttribute(e)},sb.prototype.setAttribute=function(e,t){let n=this.node;void 0!==n[e]?n[e]=t:n.setAttribute(e,t)},sb.prototype.text=function(){let e="";for(let t=0;t<this.children.length;++t)e+=this.children[t].text();return e},lb.prototype=new rb,lb.prototype.nodeName="#text",lb.prototype.render=function(e,t){let n;t.nodeName!==this.nodeName?(t.remove(),n=document.createTextNode(this.nodeValue),e.appendChild(n)):(n=t.node,this.nodeValue!==t.nodeValue&&n.parentNode&&(n.nodeValue=this.nodeValue)),this.node=n},lb.prototype.text=function(){return this.nodeValue},cb.prototype={nodeName:"#html",attr:{},remove:function(){for(let e=0;e<this.nodes.length;e++){let t=this.nodes[e];t.parentNode&&t.parentNode.removeChild(t)}},render:function(e,t){if(t.nodeName!==this.nodeName||t.html!==this.html){t.remove();let n=e.lastChild;!function(e,t){const n=document.createElement("div");n.innerHTML=t;for(;n.firstChild;)e.appendChild(n.firstChild)}(e,this.html),this.nodes=[];for(let t=n?n.nextSibling:e.firstChild;t;t=t.nextSibling)this.nodes.push(t)}else this.nodes=t.nodes.slice(0)}},pb.prototype={html:db,element:ub,text:hb,render:function(e){let t,n,i=this.children;for(t=0,n=e.length;t<n;t++){let n=i[t];n?n.node&&n.node.parentNode||(n.remove(),n=ab):n=ab,e[t].render(this.root,n)}for(t=n;t<i.length;t++)i[t].remove();this.children=e}};const fb={html:db,text:hb,element:ub,Tree:pb,Node:rb};let mb=/^\[(black|green|white|blue|magenta|yellow|cyan|red)\]/i,gb=/^\[(<=|>=|<>|<|>|=)(-?[0-9.]+)\]/;function vb(e){e=z_.runtime.InputStream(e);let t,n=[],i=!1;for(;!e.eof();){let e=l();n.push(e),e.cond&&(i=!0)}return i||(1===n.length?n[0].cond="num":2===n.length?(n[0].cond={op:">=",value:0},n[1].cond={op:"<",value:0}):n.length>=3&&(n[0].cond={op:">",value:0},n[1].cond={op:"<",value:0},n[2].cond={op:"=",value:0},n.length>3&&(n[3].cond="text",n=n.slice(0,4)))),n;function r(){let t=e.skip(mb);if(t)return t[1].toLowerCase()}function o(){let t,n=[],i=null;for(;!e.eof()&&(t=s());)"date"===t.type?i&&/^(el)?time$/.test(i.type)&&"h"===i.part&&"m"===t.part&&t.format<3&&(t.type="time"):/^(el)?time$/.test(t.type)&&"s"===t.part&&i&&"date"===i.type&&"m"===i.part&&i.format<3&&(i.type="time"),/^(?:str|space|fill)$/.test(t.type)||(i=t),n.push(t);return n}function a(t){if("date"!==t.type||"m"===t.part&&t.format<3){let n=e.skip(/^\.(0+)/);n&&(t.fraction=n[1].length,"date"===t.type&&(t.type="time"))}return t}function s(){let n,i;if(i=e.skip(/^([#0?]+)(?:,([#0?]+))+/))return{type:"digit",sep:!0,format:i[1]+i[2],decimal:t};if(i=e.skip(/^[#0?]+/))return{type:"digit",sep:!1,format:i[0],decimal:t};if(i=e.skip(/^(e)([+-])/i))return{type:"exp",ch:i[1],sign:i[2]};if(i=e.skip(/^(d{1,4}|m{1,5}|yyyy|yy|y)/i))return i=i[1].toLowerCase(),a({type:"date",part:i.charAt(0),format:i.length});if(i=e.skip(/^(hh?|ss?)/i))return i=i[1].toLowerCase(),a({type:"time",part:i.charAt(0),format:i.length});if(i=e.skip(/^\[(hh?|mm?|ss?)\]/i))return i=i[1].toLowerCase(),a({type:"eltime",part:i.charAt(0),format:i.length});if(i=e.skip(/^(a[.]?m[.]?\/p[.]?m[.]?|a\/p)/i))return i=i[1].split("/"),{type:"ampm",am:i[0],pm:i[1]};switch(n=e.next()){case";":return null;case"\\":return{type:"str",value:e.next()};case'"':return{type:"str",value:e.readEscaped(n)};case"@":return{type:"text"};case"_":return{type:"space",value:e.next()};case"*":return{type:"fill",value:e.next()};case".":return e.lookingAt(/^\s*[#0?]/)?(t=!0,{type:"dec"}):{type:"str",value:"."};case"%":return{type:"percent"};case",":return{type:"comma"}}return{type:"str",value:n}}function l(){t=!1;let n=r(),i=function(){let t=e.skip(gb);if(t){let e=parseFloat(t[2]);if(!isNaN(e))return{op:t[1],value:e,custom:!0}}}();return!n&&i&&(n=r()),{color:n,cond:i,body:o()}}}let _b={unpackDate:z_.runtime.unpackDate,unpackTime:z_.runtime.unpackTime,date:function(e,t,n,i){switch(n){case"d":switch(i){case 1:return t.date;case 2:return xb(t.date,2,"0");case 3:return e.calendar.days.format.abbreviated[t.day];case 4:return e.calendar.days.format.wide[t.day]}break;case"m":switch(i){case 1:return t.month+1;case 2:return xb(t.month+1,2,"0");case 3:return e.calendar.months.format.abbreviated[t.month];case 4:return e.calendar.months.format.wide[t.month];case 5:return e.calendar.months.format.narrow[t.month]}break;case"y":switch(i){case 1:case 4:return t.year;case 2:return t.year%100}}return"##"},time:function(e,t,n,i,r){let o,a;switch(t){case"h":o=xb(i?e.hours%12||12:e.hours,n,"0"),r&&(a=(e.minutes+(e.seconds+e.milliseconds/1e3)/60)/60);break;case"m":o=xb(e.minutes,n,"0"),r&&(a=(e.seconds+e.milliseconds/1e3)/60);break;case"s":o=xb(e.seconds,n,"0"),r&&(a=e.milliseconds/1e3)}return a&&(o+=_b.toFixed(a,r).replace(/^0+/,"")),o},eltime:function(e,t,n,i){let r,o;switch(t){case"h":r=24*e;break;case"m":r=24*e*60;break;case"s":r=24*e*60*60}return i&&(o=r-(0|r)),r=xb(0|r,n,"0"),o&&(r+=_b.toFixed(o,i).replace(/^0+/,"")),r},fill:function(e){return e},formatInt:function(e,t,n,i,r){t=_b.toFixed(t,i).replace(/\..*$/,"");let o=n[n.length-1];i>0&&"0"!=o[n.length-1]&&("0"===t?t="":"-0"===t&&(t="-"));let a,s=!1,l=t.length-1,c=[],d=0;function u(t,n){r&&d&&d%3==0&&/^[0-9]$/.test(t)&&(a=e.numbers.symbols.group+a),n&&"-"===t&&(s=!0,t="0"),a=t+a,d++}for(let e=n.length;--e>=0;){let i=n[e];a="";for(let e=i.length;--e>=0;){let n=i.charAt(e);l<0?"0"==n?u("0"):"?"==n&&u(" "):("0"==t&&"?"==n?u(" "):"0"==n?u(t.charAt(l),!0):u(t.charAt(l)),l--)}if(0===e)for(;l>=0;)u(t.charAt(l--));c.unshift(a)}return s&&(c[0]="-"+c[0]),c},formatDec:function(e,t,n){let i=(e=_b.toFixed(e,n)).indexOf(".");e=i>=0?e.substr(i+1).replace(/0+$/,""):"";let r=0,o=[];for(let n=0;n<t.length;++n){let i=t[n],a="";for(let t=0;t<i.length;++t){let n=i.charAt(t);r<e.length?a+=e.charAt(r++):"0"==n?a+="0":"?"==n&&(a+=" ")}o.push(a)}return o},toFixed:function(e,t){return function e(n,i){if(!isFinite(n))return"#NUM!";if(n<0)return"-"+e(-n);if(0===t)return String(Math.round(n));if(n===Math.round(n)&&!/e/i.test(String(n)))return n.toFixed(t);let r=function(e){let t,n,i,r=String(e).toLowerCase(),o=r.indexOf(".");o<0?(o=r.indexOf("e"),o<0?(t=r,n=""):(t=r.substr(0,o),n=r.substr(o))):(t=r.substr(0,o),n=r.substr(o+1));if(i=/(\d*)e([-+]?\d+)/.exec(n)){let e=parseInt(i[2],10);e>=0?(n=function(e,t,n){e+="";for(;e.length<t;)e+=n;return e}(i[1],e,"0"),t+=n.substr(0,e),n=n.substr(e)):(t=xb(t,-e,"0"),n=t.substr(e)+i[1],t=t.substr(0,t.length+e))}return{intpart:t||"0",decpart:n}}(n),o=r.intpart,a=r.decpart;if(a.length<=t){for(;a.length<t;)a+="0";return o+"."+a}if(i)return o+"."+a.substr(0,t);let s=Math.pow(10,t);return e(Math.round(n*s)/s,!0)}(Number(e.toFixed(14)))}};function bb(e){let t=function(e){let t=0;return{next:function(){return e[t++]},eof:function(){return t>=e.length},ahead:function(n,i){if(t+n<=e.length){let r=i.apply(null,e.slice(t,t+n));return r&&(t+=n),r}},restart:function(){t=0}}}(e.body),n=!1,i=!1,r=!1,o=0,a=/[\$\xA2-\xA5\u058F\u060B\u09F2\u09F3\u09FB\u0AF1\u0BF9\u0E3F\u17DB\u20A0-\u20BD\uA838\uFDFC\uFE69\uFF04\uFFE0\uFFE1\uFFE5\uFFE6]/,s=0,l=!1,c=0,d=[],u=[],h=e.cond;function p(e,t){("digit"===e.type&&"comma"===t.type||"comma"===e.type&&e.hidden&&"comma"===t.type)&&(t.hidden=!0,s++)}for(;!t.eof();){t.ahead(2,p);let e=t.next();"percent"===e.type?o++:"digit"===e.type?e.decimal?(c+=e.format.length,u.push(e.format)):(d.push(e.format),e.sep&&(l=!0)):"time"===e.type?i=!0:"date"===e.type?n=!0:"ampm"===e.type&&(r=i=!0)}return function(p,f,m){let g,v,_,b,y;if("text"===h){if(!("string"==typeof f||f instanceof A_))return!1}else if("num"===h){if("number"!=typeof f)return!1}else if(h){if("number"!=typeof f)return!1;if(!function(e,t,n){switch(e.op){case"=":return t==n;case"<":return t<n;case">":return t>n;case"<=":return t<=n;case">=":return t>=n}throw new Error(`Unknown condition operator: ${JSON.stringify(e)}`)}(h,f,h.value))return!1;h.custom||(f=Math.abs(f))}if((o>0||s>0||d.length||u.length||n||i)&&"number"!=typeof f)return!1;e.color&&(p.color=e.color),o>0&&(f*=Math.pow(100,o)),s>0&&(f/=Math.pow(1e3,s)),d.length&&(g=_b.formatInt(m,f,d,c,l),_=parseInt(g[0])<0),u.length&&(v=_b.formatDec(f,u,c)),(d.length||u.length)&&(p.type="number"),n&&(b=_b.unpackDate(f)),i&&(y=_b.unpackTime(f)),(n||i)&&(p.type="date");let w=!1,k="";for(t.restart();!t.eof();){let e=t.next();"dec"===e.type?k+=m.numbers.symbols.decimal:"comma"!==e.type||e.hidden?"percent"===e.type?(p.type="percent",k+=m.numbers.symbols.percentSign):"str"===e.type?(a.test(e.value)&&(p.type="currency",_&&(k+="-",w=!0)),k+=e.value):"text"===e.type?(p.type="text",k+=f):"space"===e.type?(k&&p.body.push(k),k="",p.body.push(e)):"fill"===e.type?k+=_b.fill(e.value):"digit"===e.type?(_&&g[0]&&w&&(g[0]=g[0].replace("-","")),k+=e.decimal?v.shift():g.shift()):"date"===e.type?k+=_b.date(m,b,e.part,e.format):"time"===e.type?k+=_b.time(y,e.part,e.format,r,e.fraction):"eltime"===e.type?k+=_b.eltime(f,e.part,e.format,e.fraction):"ampm"===e.type&&(k+=y.hours<12?e.am:e.pm):k+=","}return k&&p.body.push(k),!0}}let yb=bb({cond:"text",body:[{type:"text"}]}),wb=p_((function(e){let t=vb(e).map(bb);return t.push(yb),function(e,n=I_()){let i={body:[]};for(let r=0;r<t.length&&!t[r](i,e,n);++r);return i}})),kb=p_((function(e){let t,n=vb(e),i=!1,r=!1;for(let e=0;e<n.length;++e){t=n[e];for(let e=0;e<t.body.length;++e)/^(?:date|time|ampm)$/.test(t.body[e].type)&&(i=!0,"ampm"===t.body[e].type&&(r=!0));if(i)break}return i?t.body.map((function(e){if("digit"===e.type)return e.sep?e.format.charAt(0)+","+e.format.substr(1):e.format;if("exp"===e.type)return e.ch+e.sign;if("date"===e.type||"time"===e.type){let t=e.part;return"date"===e.type&&/^m/.test(t)?t="M":"time"===e.type&&/^h/.test(t)&&(r||(t=t.toUpperCase())),function(e,t){t.fraction&&(e+=xb("",Math.max(t.fraction,3),"f"));return e}(xb("",e.format,t),e)}return"ampm"===e.type?"tt":"str"===e.type?e.value:"space"===e.type?" ":"dec"===e.type?".":"percent"===e.type?"%":"comma"===e.type?",":""})).join(""):null}));function xb(e,t,n){for(e+="";e.length<t;)e=n+e;return e}function Cb(e){let t=e.body,n="";for(let e=0;e<t.length;++e){let i=t[e];"string"==typeof i?n+=i:"space"===i.type&&(n+=" ")}return n}const Sb={compile:wb,parse:vb,format:function(e,t,n){let i=wb(t)(e,n),r=fb.element("span");r.__dataType=i.type;let o=i.body;i.color&&(r.attr.style={color:i.color});for(let e=0;e<o.length;++e){let t=o[e];"string"==typeof t?r.children.push(fb.text(t)):"space"===t.type&&r.children.push(fb.element("span",{style:{visibility:"hidden"}},[fb.text(t.value)]))}return r},text:function(e,t,n){return Cb(wb(t)(e,n))},textAndColor:function(e,t,n){let i=wb(t)(e,n);return{text:Cb(i),color:i.color,type:i.type}},type:function(e,t,n){return wb(t)(e,n).type},adjustDecimals:function(e,t){let n=vb(e);return function(e,t){e.forEach((function(e){let n=t;if("text"===e.cond)return;let i=e.body,r=!1,o=i.length;for(;0!==n&&--o>=0;){let e=i[o];if("digit"===e.type){if(e.decimal){if(r=!0,n>0)e.format+=xb("",n,"0");else if(n<0){let t=e.format.length;e.format=e.format.substr(0,t+n),n+=t-e.format.length}if(0===e.format.length)for(i.splice(o,1);--o>=0;){if(e=i[o],"digit"===e.type&&e.decimal){++o;break}if("dec"===e.type){i.splice(o,1);break}}}if(n>0)break}}!r&&n>0&&i.splice(o+1,0,{type:"dec"},{type:"digit",sep:!1,decimal:!0,format:xb("",n,"0")})}))}(n,t),function(e){return e.map((function(e){let t="";return e.color&&(t+="["+e.color+"]"),e.cond&&"text"!==e.cond&&"num"!==e.cond&&(t+="["+e.cond.op+e.cond.value+"]"),t+=e.body.map(n).join(""),t})).join(";");function t(e,t){return t.fraction&&(e+="."+xb("",t.fraction,"0")),e}function n(e){return"digit"===e.type?e.sep?e.format.charAt(0)+","+e.format.substr(1):e.format:"exp"===e.type?e.ch+e.sign:"date"===e.type||"time"===e.type?t(xb("",e.format,e.part),e):"eltime"===e.type?t("["+xb("",e.format,e.part)+"]",e):"ampm"===e.type?e.am+"/"+e.pm:"str"===e.type?JSON.stringify(e.value):"text"===e.type?"@":"space"===e.type?"_"+e.value:"fill"===e.type?"*"+e.value:"dec"===e.type?".":"percent"===e.type?"%":"comma"===e.type?",":void 0}}(n)},makeDateFormat:kb},Tb=function(e,t,n,i,r){const o={};return o.spreadsheet={calc:e,CalcError:t,Ref:n,CellRef:i,RangeRef:r},o.culture=()=>I_(),o}(z_,A_,Ov,$v,Uv);z_.kendo=Tb,z_.formatting=Sb;let Db=Object.create(null),Ab=Object.create(null);var Mb;(Mb=[[":"],[" "],[","],["%"],["^"],["*","/"],["+","-"],["&"],["=","<",">","<=",">=","<>"]]).forEach((function(e,t){e.forEach((function(e){Db[e]=Mb.length-t,Ab[","===e?";":e]=Mb.length-t}))}));let Eb=Db,Ib={DEC:".",ARG:",",COL:","};function zb(e){Ib.DEC=e,Ib.ARG=","===e?";":",",Ib.COL=","===e?"\\":",",Eb=","===e?Ab:Db}z_.withDecimalSeparator=function(e,t){if(Ib.DEC===e)return t();let n=Ib.DEC;zb(e);try{return t()}finally{zb(n)}},z_._separators=Ib;let Pb={type:"bool",value:!0},Hb={type:"bool",value:!1};function Fb(e){e=e.toUpperCase();let t=0;for(let n=0;n<e.length;++n)t=26*t+e.charCodeAt(n)-64;return t-1}function Rb(e){return parseInt(e,10)-1}function Lb(e,t,n,i){let r=[],o=(i=Gb(i,{row:t,col:n})).is;return{type:"exp",ast:l(!0),refs:r,sheet:e,row:t,col:n};function a(e){return e.index=r.length,r.push(e),e}function s(e,t,n){if(o(e,t))return i.next();{let r=i.peek();r?i.croak("Expected "+e+" «"+t+"» but found "+r.type+" «"+r.value+"»"):n||i.croak("Expected "+e+" «"+t+"»")}}function l(e){return u(function(e){return o("punc","(")||o("ref")||o("num")||o("func")?{type:"binary",op:" ",left:e,right:l(!1)}:e}(c()),0,e)}function c(){let t;var n;return o("ref")?t=function(t){return t.hasSheet()||t.setSheet(e),a(t)}(i.next()):o("func")?t=function(){let e=i.next();e=e.value,s("punc","(");let t=[];for(;!o("punc",")");)if(o("op",Ib.ARG))t.push({type:"null"}),i.next();else{if(t.push(l(!1)),i.eof()||o("punc",")"))break;s("op",Ib.ARG)}return s("punc",")",!0),{type:"func",func:e,args:t}}():o("punc","(")?(i.next(),t=l(!0),s("punc",")",!0)):o("punc","{")?(i.next(),t=function(){let e=[],t=[e],n=!0;for(;!i.eof()&&!o("punc","}");)n?n=!1:o(null,";")?(t.push(e=[]),i.next()):s(null,Ib.COL),e.push(l(!1));return{type:"matrix",value:t}}(),s("punc","}",!0)):o("num")||o("str")||o("error")?t=i.next():o("sym")?t="TRUE"===(n=i.next()).upper||"FALSE"===n.upper?"TRUE"===n.upper?Pb:Hb:a(new Nv(n.value)):o("op","+")||o("op","-")?t={type:"prefix",op:i.next().value,exp:c()}:i.peek()?o("punc","[")?i.croak("External reference not supported"):i.croak("Parse error"):i.croak("Incomplete expression"),d(t)}function d(e){return o("op","%")?(i.next(),d({type:"postfix",op:"%",exp:e})):e}function u(e,t,n){let r=o("op");if(r&&(n||r.value!==Ib.ARG)){let o=Eb[r.value];if(o>t){i.next();let a=u(c(),o,n);return u({type:"binary",op:";"===r.value?",":r.value,left:e,right:a},t,n)}}return e}}function Bb(e){return function(t,n,i){return function(e,t,n,i,r){return function e(a,s,l){switch(a.type){case"num":return"."==z_._separators.DEC?JSON.stringify(a.value):JSON.stringify(a.value).replace(".",z_._separators.DEC);case"bool":return a.value;case"error":return"#"+a.value;case"str":return JSON.stringify(a.value);case"ref":return c((()=>t[a.index].print(n,i,r)));case"prefix":return c((()=>a.op+e(a.exp,a,Eb[a.op])));case"postfix":return c((()=>e(a.exp,a,Eb[a.op])+a.op));case"binary":return c((()=>{let t=o(e(a.left,a,Eb[a.op]),a.left instanceof Nv&&":"===a.op),n=o(e(a.right,a,Eb[a.op]),a.right instanceof Nv&&":"===a.op);return/^[,;]/.test(a.op)?t+z_._separators.ARG+n:t+a.op+n}));case"func":return a.func+"("+a.args.map((t=>e(t,a,0))).join(z_._separators.ARG+" ")+")";case"matrix":return"{ "+a.value.map((t=>t.map((t=>e(t,a,0))).join(z_._separators.COL))).join("; ")+" }";case"null":return""}throw new Error("Cannot print node "+a.type);function c(e){let t=a.op,n=Eb[t]<l||!l&&","===t||"prefix"===s.type&&l===Eb[t]&&"-"===s.op||"binary"===s.type&&l===Eb[t]&&a===s.right;return o(e(),n)}}(e.ast,e,0);function o(e,t){return t?"("+e+")":e}}(e,this.refs,t,n,i)}}function Ob(e,t,n){return 0===t.length?n(!0):1===t.length?Ub(e,t[0],(t=>n(e.bool(t)))):Ub(e,t[0],(i=>e.bool(i)?Ob(e,t.slice(1),n):n(!1)))}function Vb(e,t,n){return 0===t.length?n(!1):1===t.length?Ub(e,t[0],(t=>n(e.bool(t)))):Ub(e,t[0],(i=>e.bool(i)?n(!0):Vb(e,t.slice(1),n)))}function Nb(e,t,n){switch(t.func.toLowerCase()){case"if":return function(e,t,n,i,r){return Ub(e,t,(t=>e.func("if",r,[t,t=>Ub(e,n,t),t=>Ub(e,i,t)])))}(e,t.args[0],t.args[1]||Pb,t.args[2]||Hb,n);case"and":return Ob(e,t.args,n);case"or":return Vb(e,t.args,n);case"true":return n(!0);case"false":return n(!1)}return $b(e,t.args,0,(i=>e.func(t.func,n,i)))}function $b(e,t,n,i,r=[]){return n===t.length?i(r):Ub(e,t[n],(o=>(r[n]=o,$b(e,t,n+1,i,r))))}function Ub(e,t,n){switch(t.type){case"ref":return function(e,t,n){return"name"===t.ref?e.fetchName(t,n):n(e.formula.absrefs[t.index])}(e,t,n);case"num":case"str":case"null":case"bool":return n(t.value);case"error":return n(e.error(t.value));case"prefix":case"postfix":return function(e,t,n){return Ub(e,t.exp,(i=>e.func("unary"+t.op,n,[i])))}(e,t,n);case"binary":return function(e,t,n){return Ub(e,t.left,(i=>Ub(e,t.right,(r=>e.func("binary"+t.op,n,[i,r])))))}(e,t,n);case"func":return Nb(e,t,n);case"matrix":return function(e,{value:t},n){let i=[];return function r(o){return o===t.length?n(i):$b(e,t[o],0,(e=>(i[o]=e,r(o+1))))}(0)}(e,t,n)}throw new Error("Cannot evaluate "+t.type)}let Wb=Object.create(null);function jb(e){let t=Bb(e),n=t.call(e),i=Wb[n];return i?i.clone(e.sheet,e.row,e.col):(i=new z_.runtime.Formula(e.refs,function({ast:e}){return function(){return Ub(this,e,(e=>this.resolve(e)))}}(e),t,e.sheet,e.row,e.col),Wb[n]=i.clone(e.sheet,e.row,e.col),i)}function qb(e){return e}function Gb(e,t){e=function(e,t){let n=[],i=0,r=e.readWhile;return{next:y,peek:b,eof:x,croak:e.croak,ahead:w,skip:k};function o(e){return/[0-9]/i.test(e)}function a(e){return/[a-z$_]/i.test(e)||function(e){return h_.test(e)}(e)}function s(e){return a(e)||o(e)||"."===e}function l(e){return e in Eb}function c(e){return"\\!;(){}[]".indexOf(e)>=0}function d(){let e=!1,t=r((function(t){return t===Ib.DEC?!e&&(e=!0,!0):o(t)}));return t===Ib.DEC?{type:"punc",value:Ib.DEC}:{type:"num",value:parseFloat(t.replace(Ib.DEC,"."))}}function u(t,n){return{type:"sym",value:t,upper:t.toUpperCase(),space:Kb(e.peek()),quote:n}}function h(e,t,n){if(!e&&!t&&!n)return null;if(!e&&!n||e&&n){let n=t?parseInt(t,10):0;return e?n:n-1}}function p(){let t=e.lookingAt(/^R(\[)?(-?[0-9]+)?(\])?C(\[)?(-?[0-9]+)?(\])?/i);if(t){let n=h(t[1],t[2],t[3]),i=h(t[4],t[5],t[6]);if(null!=n&&null!=i)return e.skip(t),{type:"rc",row:n,col:i,rel:(t[4]||!(t[4]||t[5]||t[6])?1:0)|(t[1]||!(t[1]||t[2]||t[3])?2:0)}}return u(r(s))}function f(){return e.next(),{type:"str",value:e.readEscaped('"')}}function m(){return e.next(),u(e.readEscaped("'"),!0)}function g(){return{type:"op",value:r((function(e,t){return t+e in Eb}))}}function v(){return{type:"punc",value:e.next()}}function _(){if(e.eof())return null;let n,i=e.peek();return'"'===i?f():"'"===i?m():o(i)||i===Ib.DEC?d():a(i)?p():l(i)?g():c(i)?v():(n=e.lookingAt(/^#([a-z\/]+)[?!]?/i))?(e.skip(n),{type:"error",value:n[1]}):(t.forEditor||e.croak("Can't handle character with code: "+i.charCodeAt(0)),{type:"error",value:e.next()})}function b(){for(;n.length<=i;){r(Kb);let i=e.pos(),o=_();t.forEditor&&o&&(o.begin=i,o.end=e.pos()),n.push(o)}return n[i]}function y(){let e=b();return e&&i++,e}function w(e,t){let n=i,r=[];for(;e-- >0;)r.push(y()||Yb);return i=n,t.apply(r,r)}function k(e){i+=e}function x(){return null==b()}}(z_.runtime.InputStream(e),t);let n=e.ahead,i=e.skip,r=null,o=null!=t.row&&null!=t.col?function(e){return 1&e.rel&&(e.col-=t.col),2&e.rel&&(e.row-=t.row),e}:qb,a=t.forEditor?function(e,t,n){return e.begin=t.begin,e.end=n.end,e}:qb;return{peek:s,next:function(){if(null!=r){let e=r;return r=null,e}return l()},croak:e.croak,eof:e.eof,is:function(e,t){let n=s();return null==n||null!=e&&n.type!==e||null!=t&&n.value!==t?null:n}};function s(){return null==r&&(r=l()),r}function l(){let t,i=e.peek();return i&&("sym"!==i.type&&"rc"!==i.type&&"num"!==i.type||(t=n(8,d)||n(6,u)||n(6,h)||n(4,p)||n(4,f)||n(2,m)||n(2,g)),t||(t=e.next())),t}function c(n,i){if("rc"===n.type)return!n.rel||t.forEditor||null!=t.row&&null!=t.col||e.croak("Cannot read relative cell in RC notation"),new $v(n.row,n.col,n.rel);if("num"===n.type)return n.value<=1048577?o(new $v(Rb(n.value),i?-1/0:1/0,2)):null;let r=n.value,a=/^(\$)?([a-z]+)(\$)?(\d+)$/i.exec(r);if(a){let e=Rb(a[4]),t=Fb(a[2]);return e<=1048576&&t<=16383?o(new $v(Rb(a[4]),Fb(a[2]),(a[1]?0:1)|(a[3]?0:2))):null}let s="$"===r.charAt(0);if(s&&(r=r.substr(1)),/^\d+$/.test(r)){if(Rb(r)<=1048576)return o(new $v(Rb(r),i?-1/0:1/0,s?0:2))}else{if(Fb(r)<=16383)return o(new $v(i?-1/0:1/0,Fb(r),s?0:1))}}function d(e,t,n,r,o,s,l,d){if("sym"===e.type&&"op"===t.type&&":"===t.value&&"sym"===n.type&&"punc"===r.type&&"!"===r.value&&("sym"===o.type||"rc"===o.type||"num"===o.type&&o.value==o.value|0)&&"op"===s.type&&":"===s.value&&("sym"===l.type||"rc"===l.type||"num"===l.type&&l.value==l.value|0)&&l.type===o.type&&("punc"!==d.type||"("!==d.value||l.space)){let t=c(o,!0),r=c(l,!1);if(t&&r)return i(7),a(new Uv(t.setSheet(e.value,!0),r.setSheet(n.value,!0)).setSheet(e.value,!0),e,l)}}function u(e,t,n,r,o,s){if("sym"===e.type&&"op"===t.type&&":"===t.value&&"sym"===n.type&&"punc"===r.type&&"!"===r.value&&("sym"===o.type||"rc"===o.type||"num"===o.type&&o.value==o.value|0)&&("punc"!==s.type||"("!==s.value||o.space)){let t=c(o);if(t){i(5);let r=t.clone();return a(new Uv(t.setSheet(e.value,!0),r.setSheet(n.value,!0)).setSheet(e.value,!0),e,o)}}}function h(e,t,n,r,o,s){if("sym"===e.type&&"punc"===t.type&&"!"===t.value&&("sym"===n.type||"rc"===n.type||"num"===n.type&&n.value==n.value|0)&&"op"===r.type&&":"===r.value&&("sym"===o.type||"rc"===o.type||"num"===o.type&&o.value==o.value|0)&&("punc"!==s.type||"("!==s.value||o.space)){let t=c(n,!0),r=c(o,!1);if(t&&r)return i(5),a(new Uv(t,r).setSheet(e.value,!0),e,o)}}function p(e,t,n,r){if("sym"===e.type&&"punc"===t.type&&"!"===t.value&&("sym"===n.type||"rc"===n.type||"num"===n.type&&n.value==n.value|0)&&("punc"!==r.type||"("!==r.value||n.space)){i(3);let t=c(n);return t&&isFinite(t.row)||(t=new Nv(n.value)),a(t.setSheet(e.value,!0),e,n)}}function f(e,t,n,r){if(("sym"===e.type||"rc"===e.type||"num"===e.type&&e.value==e.value|0)&&"op"===t.type&&":"===t.value&&("sym"===n.type||"rc"===n.type||"num"===n.type&&n.value==n.value|0)&&("punc"!==r.type||"("!==r.value||n.space)){let t=c(e,!0),r=c(n,!1);if(t&&r)return i(3),a(new Uv(t,r),e,n)}}function m(e,t){if(("sym"===e.type||"rc"===e.type)&&("punc"!==t.type||"("!==t.value||e.space)){let t=c(e);if(t&&isFinite(t.row)&&isFinite(t.col))return i(1),a(t,e,e)}}function g(e,t){if("sym"===e.type&&"punc"===t.type&&"("===t.value&&!e.space)return e.type="func",i(1),e}}function Kb(e){return" \t\r\n ​".indexOf(e)>=0}let Yb={type:"eof"};let Qb=[],Xb=z_.registerFormatParser=function(e){Qb.push(e)};z_.parse=function(e,t,n,i,r){if(i instanceof Date)return{type:"date",value:z_.runtime.dateToSerial(i)};if("number"==typeof i)return{type:"number",value:i};if("boolean"==typeof i)return{type:"boolean",value:i};if(/^'/.test(i+=""))return{type:"string",value:i.substr(1)};if(/^-?[0-9]+%$/.test(i)){let e=i.substr(0,i.length-1),t=parseFloat(e);if(!isNaN(t)&&t===e)return{type:"percent",value:t/100}}if(/^=/.test(i))return i=i.substr(1),/\S/.test(i)?Lb(e,t,n,i):{type:"string",value:"="+i};for(let e=0;e<Qb.length;++e){let t=Qb[e](i,r);if(t)return t}if("true"===i.toLowerCase())return{type:"boolean",value:!0};if("false"===i.toLowerCase())return{type:"boolean",value:!1};let o=z_.runtime.parseDate(i,r);if(o)return{type:"date",value:z_.runtime.dateToSerial(o)};let a=parseFloat(i);return!isNaN(a)&&i.length>0&&a===i?(r=null,a!==Math.floor(a)&&(r="0."+String(a).split(".")[1].replace(/\d/g,"0")),{type:"number",value:a,format:r}):{type:"string",value:i}},z_.parseNameDefinition=function(e,t){let n=Lb(null,0,0,e);if(!(n.ast instanceof Nv))throw new z_.runtime.ParseError("Invalid name: "+e);if(n=n.ast,!(t instanceof Ov)){let e=Lb(n.sheet,0,0,t);t=e.ast instanceof Ov?e.ast:/^(?:str|num|bool|error)$/.test(e.ast.type)?e.ast.value:jb(e)}return{name:n,value:t}},z_.parseFormula=Lb,z_.parseReference=function(e,t){if("#sheet"===e.toLowerCase())return qv;e:{let t;if(t=/^(\$)?([a-z]+)(\$)?(\d+)$/i.exec(e)){let e=Rb(t[4]),n=Fb(t[2]);if(e<1048576&&n<16384)return new $v(Rb(t[4]),Fb(t[2]));break e}let n=Gb(e,{}),i=[];for(;;){let e=n.next();if(e instanceof $v)e.rel=0;else{if(!(e instanceof Uv))break e;e.topLeft.rel=0,e.bottomRight.rel=0}if(i.push(e),n.eof())break;if(!n.is("op",Ib.ARG))break e;n.next()}return 1===i.length?i[0]:new Wv(i)}if(!t)throw new Error("Cannot parse reference: "+e)},z_.compile=jb,z_.parseSqref=function(e,t,n){e=Gb(e,{row:t=t||0,col:n=n||0});let i=[];for(;!e.eof();){let r=e.next();if("ref"!==r.type)throw new z_.runtime.ParseError("Expecting a reference but got: "+JSON.stringify(r));i.push(r.absolute(t,n))}return i},z_.tokenize=function(e,t,n){let i=[];for(e=Gb(e,{forEditor:!0,row:t,col:n});!e.eof();)i.push(o());let r=i[0];return"op"===r.type&&"="===r.value&&(r.type="startexp"),i;function o(){let i=e.next();return"sym"===i.type?"TRUE"===i.upper?(i.type="bool",i.value=!0):"FALSE"===i.upper&&(i.type="bool",i.value=!1):"ref"===i.type&&(i={type:"ref",ref:null!=t&&null!=n?i.absolute(t,n):i,begin:i.begin,end:i.end}),i}},Xb((function(e,t){let n,i=0,r="";if(t||(t=I_().calendar.patterns.d),n=/^(\d+)([-/.])(\d+)\2(\d{2}(?:\d{2})?)(\s*)/.exec(e)){let o=parseInt(n[1],10),a=n[2],s=parseInt(n[3],10),l=parseInt(n[4],10);l<30?l+=2e3:l<100&&(l+=1900);let c=!t||t.indexOf("M")<t.indexOf("d");if(o>12||!c){let e=o;o=s,s=e,c=!1}if(!z_.runtime.validDate(l,o,s))return null;i=z_.runtime.packDate(l,o-1,s),i<0&&i--,r=c?["mm","dd","yyyy"].join(a):["dd","mm","yyyy"].join(a),r+=n[5],e=e.substr(n[0].length)}if(n=/^(\d+):(\d+)$/.exec(e)){let e=parseInt(n[1],10),t=parseInt(n[2],10);return{type:"date",format:r+"hh:mm",value:i+z_.runtime.packTime(e,t,0,0)}}if(n=/^(\d+):(\d+)(\.\d+)$/.exec(e)){let e=parseInt(n[1],10),t=parseInt(n[2],10),o=1e3*parseFloat(n[3]);return{type:"date",format:r+"mm:ss.00",value:i+z_.runtime.packTime(0,e,t,o)}}if(n=/^(\d+):(\d+):(\d+)$/.exec(e)){let e=parseInt(n[1],10),t=parseInt(n[2],10),o=parseInt(n[3],10);return{type:"date",format:r+"hh:mm:ss",value:i+z_.runtime.packTime(e,t,o,0)}}if(n=/^(\d+):(\d+):(\d+)(\.\d+)$/.exec(e)){let e=parseInt(n[1],10),t=parseInt(n[2],10),o=parseInt(n[3],10),a=1e3*parseFloat(n[4]);return{type:"date",format:r+"hh:mm:ss.00",value:i+z_.runtime.packTime(e,t,o,a)}}})),Xb((function(e){let t,n;const i=E_();var r=i.localeInfo().numbers;let o=r.symbols.group,a=r.symbols.decimal,s=r.localeCurrency;!s&&i.localeCurrency&&(s=i.localeCurrency());let l=r.currencies[s].symbol,c=function(e,t){let n=e+t,i=Zb[n];i||(i="^(\\d+(COM\\d{3})*(DOT\\d+)?)",i=i.replace(/DOT/g,"\\"+t).replace(/COM/g,"\\"+e),i=new RegExp(i),Zb[n]=i);return i}(o,a),d=new RegExp("^\\s*\\"+l+"\\s*"),u=1,h="",p="",f=!1,m=!1;if((e=z_.runtime.InputStream(e.replace(/^\s+|\s+$/g,""))).skip(/^-\s*/)&&(u=-1),(t=e.skip(d))&&(f=!0,h+='"'+t[0]+'"'),e.skip(/^-\s*/)){if(u<0)return null;u=-1}if(!(n=e.skip(c)))return null;if(h+="0",t=e.skip(d)){if(f)return null;f=!0,p='"'+t[0]+'"'}if(!f&&(t=e.skip(/^\s*%\s*/))&&(m=!0,p=t[0]),!e.eof())return null;(n[2]||f)&&(h=h.replace("0","#"),h+=",0"),n[3]&&(h+="."+Jb("0",n[3].length-1));let g=n[0].replace(new RegExp("\\"+o,"g"),"").replace(new RegExp("\\"+a,"g"),".");return g=parseFloat(g),m&&(g/=100),h+=p,f&&(h+=";-"+h),{type:"number",currency:f,format:h,value:u*g}})),Xb((function(e){let t;if(t=/^([0-9]*)\.([0-9]+)(\s*%)$/.exec(e))return{type:"number",value:parseFloat(e)/100,format:"0."+Jb("0",t[2].length)+t[3]}}));let Zb={};function Jb(e,t){let n="";for(;t-- >0;)n+=e;return n}class ey{constructor(e){this.workbook=e}getRefCells(e,t,n,i,r,o){let a,s,l,c;if(e instanceof $v)return a=this.workbook.sheetByName(e.sheet),a&&e.valid()?(s=a.formula(e),l=a.range(e.row,e.col).value(),o||null!=s||null!=l?[{formula:s,value:l,row:e.row,col:e.col,sheet:e.sheet,hidden:!!t&&(0===a.columnWidth(e.col)||0===a.rowHeight(e.row))}]:[]):[{value:new A_("REF")}];if(e instanceof Uv){c=this.workbook.sheetIndex(e.sheet);let n=[],i=c;if(e.endSheet&&(i=this.workbook.sheetIndex(e.endSheet),c>i)){let e=c;c=i,i=e}if(c<0||i<0||!e.valid())return[{value:new A_("REF")}];for(;c<=i;){a=this.workbook.sheetByIndex(c++);let i=a._grid.normalize(e.topLeft),r=a._grid.normalize(e.bottomRight),d=a._grid.cellRefIndex(i),u=a._grid.cellRefIndex(r),h=a._properties.iterator("value",d,u);for(let e=i.col;e<=r.col;++e)for(let c=i.row;c<=r.row;++c){let i=a._grid.index(c,e);s=a._properties.get("formula",i),l=h.at(i),(o||null!=s||null!=l)&&n.push({formula:s,value:l,row:c,col:e,sheet:a.name(),hidden:!!t&&(0===a.columnWidth(e)||0===a.rowHeight(c))})}}return n}if(e instanceof Wv){let o=[];for(c=0;c<e.refs.length;++c)o=o.concat(this.getRefCells(e.refs[c],t,n,i,r));return o}if(e instanceof Nv){let o=this.nameValue(e,n,i,r);return o instanceof Ov?this.getRefCells(o,t,n,i,r):[{value:null==o?new A_("NAME"):o}]}return[]}isMerged(e){return this.workbook.sheetByName(e.sheet).isMerged(e)}nameValue(e,t,n,i){let r;return e.hasSheet()?r=this.workbook.nameValue(this._displayString(e.print())):(e=e.clone().setSheet(t,!0),r=this.workbook.nameValue(this._displayString(e.print())),null==r&&(r=this.workbook.nameValue(this._displayString(e.name))),null==r&&(r=this.workbook.nameValue(e.print())||this.workbook.nameValue(e.name))),r instanceof Ov&&(r=r.absolute(n,i)),r}getData(e,t,n,i,r){let o=e instanceof $v;e instanceof Nv&&(o=this.workbook.nameValue(e.name)instanceof $v);let a=this.getRefCells(e,!1,t,n,i,r).map((function(e){let t=e.value;return t instanceof z_.runtime.Formula&&(t=t.value),t}));return o?a[0]:a}onFormula(e){let t=this.workbook.sheetByName(e.sheet),n=e.row,i=e.col,r=e.value;if(t.formula({row:n,col:i})!==e)return!1;let o=e.arrayFormulaRange;if(o){let e,n,i=r.width,a=r.height;t.forEach(o,(function(o,s){void 0===e&&(e=o,n=s);let l,c=o-e,d=s-n;l=c<a&&d<i?r.get(c,d):new A_("N/A"),t._value(o,s,l)}))}else r instanceof Ov&&(r=this.getData(r,e.sheet,n,i),Array.isArray(r)&&(r=r[0]),void 0===r&&(r=null)),r instanceof z_.runtime.Matrix&&(r=r.get(0,0)),t._value(n,i,r);return clearTimeout(t._formulaContextRefresh),t._formulaContextRefresh=setTimeout((function(){t.batch((function(){}),{layout:!0})}),50),!0}_displayString(e){return/^[a-z_][a-z0-9_]*$/i.test(e)?e:"'"+e.replace(/\x27/g,"\\'")+"'"}}class ty extends ey{onFormula(){return!0}}z_.ValidationFormulaContext=ty;let ny={8:"backspace",9:"tab",13:"enter",27:"esc",37:"left",38:"up",39:"right",40:"down",35:"end",36:"home",32:"spacebar",33:"pageup",34:"pagedown",46:"delete",113:":edit"};class iy{constructor(e,t,n){if(this._handlers={},this.target=e,this._observer=t||window,this.keyDownProxy=this.keyDown.bind(this),this.mouseProxy=this.mouse.bind(this),this.touchProxy=this.touch.bind(this),this.threshold=5,this._pressLocation=null,this._attachEvent(e,"keydown",this.keyDownProxy),this._attachEvent(e,"contextmenu mousedown cut copy paste scroll wheel click dblclick focus",this.mouseProxy),this._attachEvent(e,"touchmove touchend",this.touchProxy),this._attachEvent(document.documentElement,"mousemove mouseup",this.mouseProxy),this._attachEvent(document.documentElement,"touchmove touchend",this.touchProxy),n)for(let e in n)this.on(e,n[e])}_attachEvent(e,t,n){t.split(" ").forEach((t=>{e.addEventListener(t,n)}))}_removeEvent(e,t,n){t.split(" ").forEach((t=>{e.removeEventListener(t,n)}))}keyDown(e){(!e.altKey||"n"!==e.key&&"h"!==e.key&&"a"!==e.key)&&this.handleEvent(e,function(e){let t=e.keyCode,n=ny[t];return!n&&function(e){return e>47&&e<58||e>64&&e<91||e>95&&e<112||e>185&&e<193||e>218&&e<223||229===e}(t)&&(n=":alphanum"),!n&&e.key&&1===e.key.length&&(n=":alphanum"),n}(e))}touch(e){this.handleEvent(e,e.type)}mouse(e){let t;e.which?t=3===e.which:e.button&&(t=2===e.button);let n=e.type;if("mousedown"===n&&(t?n="rightmousedown":this._pressLocation={x:e.pageX,y:e.pageY}),"mouseup"===n&&(t||(this._pressLocation=null)),"mousemove"===n&&this._pressLocation){let t=this._pressLocation.x-e.pageX,i=this._pressLocation.y-e.pageY;Math.sqrt(t*t+i*i)>this.threshold&&(n="mousedrag")}this.handleEvent(e,n)}handleEvent(e,t){let n="";e.mod=navigator.platform.toUpperCase().indexOf("MAC")>=0?e.metaKey:e.ctrlKey&&!e.altKey,e.altKey&&(n+="alt+"),e.shiftKey&&(n+="shift+"),e.ctrlKey&&(n+="ctrl+"),n+=t;let i=this._handlers["*+"+t];i&&i.call(this._observer,e,n);let r=this._handlers[n];r&&r.call(this._observer,e,n)}on(e,t){let n=this._handlers;"string"==typeof t&&(t=this._observer[t]),"string"==typeof e&&(e=e.split(",")),e.forEach((function(e){n[e]=t}))}destroy(){this._removeEvent(this.target,"keydown",this.keyDownProxy),this._removeEvent(this.target,"contextmenu mousedown cut copy paste scroll wheel click dblclick focus",this.mouseProxy),this._removeEvent(this.target,"touchmove touchend",this.touchProxy),this._removeEvent(document.documentElement,"mousemove mouseup",this.mouseProxy),this._removeEvent(document.documentElement,"touchmove touchend",this.touchProxy)}}let ry=/:alphanum$/,oy={up:"up",down:"down",left:"left",right:"right",home:"first-col",end:"last-col","ctrl+left":"word-left","ctrl+right":"word-right","ctrl+up":"word-up","ctrl+down":"word-down","ctrl+home":"first","ctrl+end":"last",pageup:"prev-page",pagedown:"next-page"},ay={tab:"next","shift+tab":"previous",enter:"lower","shift+enter":"upper",delete:"clearContents",backspace:"clearContents","shift+:alphanum":"edit","alt+:alphanum":"edit",":alphanum":"edit","ctrl+:alphanum":"ctrl","alt+ctrl+:alphanum":"edit",":edit":"edit"},sy={wheel:"onWheel","*+mousedown":"onMouseDown",contextmenu:"onContextMenu","*+mousedrag":"onMouseDrag","*+mouseup":"onMouseUp","*+dblclick":"onDblClick",mousemove:"onMouseMove"},ly={pageup:"onPageUp",pagedown:"onPageDown",mouseup:"onMouseUp","*+cut":"onCut","*+paste":"onPaste","*+copy":"onCopy"},cy={esc:"onEditorEsc",enter:"onEditorBlur","alt+enter":"insertNewline","shift+enter":"onEditorBlur",tab:"onEditorBlur","shift+tab":"onEditorBlur","shift+ctrl+enter":"onEditorArrayFormula"},dy=Object.assign({focus:"onEditorBarFocus"},cy),uy=Object.assign({focus:"onEditorCellFocus"},cy),hy={cell:"range",rowheader:"row",columnheader:"column",topcorner:"sheet",autofill:"autofill"},py=[],fy=[],my=[];for(let e in oy)py.push(e),fy.push("shift+"+e);for(let e in ay)my.push(e);ly[py]="onAction",ly[fy]="onShiftAction",ly[my]="onEntryAction",uy[py]="onEditorAction",uy[fy]="onEditorShiftAction";class gy{constructor(e,t){this.view=e,this.workbook(t),this.container=e.container,this.clipboardElement=e.clipboard,this.scroller=e.scroller,this.tabstrip=e.tabstrip,this.sheetsbar=e.sheetsbar,e.nameEditor.bind("enter",this.onNameEditorEnter.bind(this)),e.nameEditor.bind("cancel",this.onNameEditorCancel.bind(this)),e.nameEditor.bind("select",this.onNameEditorSelect.bind(this)),e.nameEditor.bind("delete",this.onNameEditorDelete.bind(this)),this.editor=e.editor,this.editor.bind("change",this.onEditorChange.bind(this)),this.editor.bind("activate",this.onEditorActivate.bind(this)),this.editor.bind("deactivate",this.onEditorDeactivate.bind(this)),this.editor.bind("update",this.onEditorUpdate.bind(this)),this.listener=new iy(this.container,this,sy),this.scrollHandler=this.onScroll.bind(this),this.mouseDownHandler=this.onMouseDown.bind(this),e.scroller.addEventListener("scroll",this.scrollHandler),e.scroller.addEventListener("mousedown",this.mouseDownHandler),this._enableEditorEvents(),this.sheetsbar&&(this.sheetsbar.bind("select",this.onSheetBarSelect.bind(this)),this.sheetsbar.bind("reorder",this.onSheetBarReorder.bind(this)),this.sheetsbar.bind("rename",this.onSheetBarRename.bind(this)),this.sheetsbar.bind("remove",this.onSheetBarRemove.bind(this)))}executeCommand(e){return this._execute(e)}_enableEditorEvents(e){void 0===e||e?(this.keyListener=new iy(this.clipboardElement,this,ly),this.barKeyListener=new iy(this.editor.barElement(),this,dy),this.inputKeyListener=new iy(this.editor.cellElement(),this,uy)):(this.keyListener.destroy(),this.barKeyListener.destroy(),this.inputKeyListener.destroy())}_execute(e){let t=this._workbook.execute(e);return"EditCommand"!==e.command||t||this._workbook.trigger("change",{editorClose:!0}),t&&(this._preventNavigation=!0,"error"===t.reason?(this.editor.deactivate(!0),this.view.showError(t,function(){}.bind(this))):this.view.openDialog(t.reason)),t}_activeTooltip(){return this._workbook.activeSheet().activeCell().simplify().toString()}onContextMenuSelect(e){let t;switch(e.item.getAttribute("data-action")){case"cut":t={command:"ToolbarCutCommand",options:{workbook:this._workbook}};break;case"copy":t={command:"ToolbarCopyCommand",options:{workbook:this._workbook}};break;case"paste":t={command:"ToolbarPasteCommand",options:{workbook:this._workbook}};break;case"delete-drawing":t={command:"DeleteDrawingCommand",options:{drawing:this.navigator._sheet._activeDrawing}};break;case"bring-to-front":t={command:"BringToFrontCommand",options:{drawing:this.navigator._sheet._activeDrawing}};break;case"send-to-back":t={command:"SendToBackCommand",options:{drawing:this.navigator._sheet._activeDrawing}};break;case"unmerge":t={command:"MergeCellCommand",options:{value:"unmerge"}};break;case"merge":this.view.openDialog("merge");break;case"hide-row":t={command:"HideLineCommand",options:{axis:"row"}};break;case"hide-column":t={command:"HideLineCommand",options:{axis:"column"}};break;case"unhide-row":t={command:"UnHideLineCommand",options:{axis:"row"}};break;case"unhide-column":t={command:"UnHideLineCommand",options:{axis:"column"}};break;case"delete-row":t={command:"DeleteRowCommand"};break;case"delete-column":t={command:"DeleteColumnCommand"}}t&&this._execute(t)}onSheetBarRemove(e){let t=this._workbook.sheetByName(e.name);t&&this._workbook.removeSheet(t)}destroy(){this.view.scroller.removeEventListener("scroll",this.scrollHandler),this.view.scroller.removeEventListener("mousedown",this.mouseDownHandler),this.listener.destroy(),this._enableEditorEvents(!1),this.keyListener.destroy(),this.inputKeyListener.destroy()}onSheetBarSelect(e){let t,n=this._workbook;if(e.isAddButton){if(this._workbook.trigger("insertSheet"))return;t=n.insertSheet()}else t=n.sheetByName(e.name);if(n.activeSheet().name()!==t.name()){if(this._workbook.trigger("selectSheet",{sheet:t}))return;this.editor.canInsertRef(!1)||this.editor.deactivate(),n.activeSheet(t)}}onSheetBarReorder(e){let t=this._workbook,n=t.sheetByIndex(e.oldIndex),i=t.activeSheet(),r=i.name();if(t.moveSheetToIndex(n,e.newIndex),r!==n.name()){if(t.trigger("selectSheet",{sheet:n}))return void t.activeSheet(i);this.editor.canInsertRef(!1)||this.editor.deactivate(),t.activeSheet(n)}}onSheetBarRename(e){let t=this._workbook.sheetByIndex(e.sheetIndex);this._workbook.sheetByName(e.name)?this.view.showError({reason:"error",type:"duplicateSheetName"}):(this._workbook.renameSheet(t,e.name),this.clipboardElement.focus())}sheet(e){this.navigator=e.navigator(),this.axisManager=e.axisManager()}workbook(e){this._workbook=e,this.clipboard=e.clipboard(),e.bind("commandRequest",this.onCommandRequest.bind(this))}refresh(){let e=this.editor,t=this._workbook.activeSheet();this._viewPortHeight=this.view.scroller.clientHeight,this.navigator.height(this._viewPortHeight),e.isActive()||this.isEditorDisabled||(e.enable(!1!==t.selection().enable()),this.resetEditorValue());let n=t.selection()._ref.simplify(),i=this._workbook.nameForRef(n,t.name());this.view.nameEditor.value(i.name)}onScroll(){this.view.render({scroll:!0})}onWheel(e){let t=e.deltaX,n=e.deltaY;1===e.deltaMode&&(t*=10,n*=10),this.scrollWith(t,n),e.preventDefault()}onAction(e,t){this._workbook.activeSheet()._activeDrawing=null,this.navigator.moveActiveCell(oy[t]),e.preventDefault()}onPageUp(){this.scrollDown(-this._viewPortHeight)}onPageDown(){this.scrollDown(this._viewPortHeight)}onEntryAction(e,t){let n=this._workbook.activeSheet();if(e.mod){let t=!0;switch(String.fromCharCode(e.keyCode)){case"A":n._activeDrawing=null,this.navigator.selectAll();break;case"Y":this._workbook.undoRedoStack.redo();break;case"Z":this._workbook.undoRedoStack.undo();break;default:t=!1}t&&e.preventDefault()}else{let i=!1===n.selection().enable(),r=":edit"!==t;if("delete"==t||"backspace"==t)n._activeDrawing?this._execute({command:"DeleteDrawingCommand",options:{drawing:n._activeDrawing}}):i||this._execute({command:"ClearContentCommand"}),e.preventDefault();else if(ry.test(t)||!r){if(n._activeDrawing=null,i)return void e.preventDefault();r&&this.editor.value(""),this.activateEditor(r)}else this.navigator.navigateInSelection(ay[t]),e.preventDefault()}}onShiftAction(e,t){this.navigator.modifySelection(oy[t.replace("shift+","")],this.appendSelection),e.preventDefault()}onMouseMove(e){let t=this._workbook.activeSheet();if(t.resizingInProgress()||t.selectionInProgress())return;let n=this.objectAt(e);"columnresizehandle"===n.type||"rowresizehandle"===n.type?t.positionResizeHandle(n.ref):t.removeResizeHandle(),t._renderComment("cell"==n.type?n.ref:null)}onMouseDown(e){let t=this.objectAt(e);if(t.pane&&(this.originFrame=t.pane),this._startResizingDrawing(e,t))return void e.stopPropagation();let n=this._workbook.activeSheet();if(n._activeDrawing=null,"drawing"===t.type)return n._activeDrawing=t.drawing,t.copy=t.drawing.clone(),t.startBox=n.drawingBoundingBox(t.copy),n.startDragging(t),n.triggerChange({dragging:!0}),void e.preventDefault();if("outside"===t.type)return e.preventDefault(),void e.stopPropagation();if("editor"===t.type)return this.onEditorEsc(),this.openCustomEditor(),void e.preventDefault();if(this.editor.canInsertRef(!1)&&t.ref)return this._workbook.activeSheet()._setFormulaSelections(this.editor.highlightedRefs()),this.navigator.startSelection(t.ref,this._selectionMode,this.appendSelection,e.shiftKey,this.view),void e.preventDefault();if(this._preventNavigation=!1,this.editor.deactivate(),!this._preventNavigation){if("columnresizehandle"===t.type||"rowresizehandle"===t.type)return n.startResizing({x:t.x,y:t.y}),void e.preventDefault();if("filtericon"===t.type)return this.openFilterMenu(e),void e.preventDefault();this._selectionMode=hy[t.type],this.appendSelection=e.mod,this.navigator.startSelection(t.ref,this._selectionMode,this.appendSelection,e.shiftKey,this.view)}}_startResizingDrawing(e){let t=e.target.closest(".k-spreadsheet-drawing-handle");if(t){let n=this.translateCoords(e),i=t.getAttribute("data-direction"),r=this._workbook.activeSheet(),o=r._activeDrawing;return r.startDragging({pane:this.originFrame,drawing:o,copy:o.clone(),startBox:r.drawingBoundingBox(o),resize:i,startX:n.x,startY:n.y}),!0}}onContextMenu(e){let t=this._workbook.activeSheet();if(e.preventDefault(),t.resizingInProgress()||t.draggingInProgress())return;let n=this.objectAt(e);if("columnresizehandle"===n.type||"rowresizehandle"===n.type)return;n.ref?this.navigator.selectForContextMenu(n.ref,hy[n.type]):"drawing"==n.type&&this.navigator.selectDrawingForContextMenu(n.drawing);let i=this.navigator._sheet.select()instanceof Wv,r=!1,o=!1;"columnheader"==n.type?r=!i&&this.axisManager.selectionIncludesHiddenColumns():"rowheader"==n.type?r=!i&&this.axisManager.selectionIncludesHiddenRows():"drawing"==n.type||(o=this.navigator.selectionIncludesMergedCells()),this._workbook.trigger("contextmenu",{objectRef:n.ref,targetType:n.type,isComposite:i,showUnhide:r,showUnmerge:o,originalEvent:e})}prevent(e){e.preventDefault()}constrainResize(e,t){let n=this._workbook.activeSheet().resizeHandlePosition();return!n||"outside"===e||"topcorner"===e||t.col<n.col||t.row<n.row}_dragDrawing(e){let t=this._workbook.activeSheet(),n=t.draggingInProgress();if(!n)return!1;let i=this.translateCoords(e),r=n.drawing,o=i.x-n.startX,a=i.y-n.startY;return"SE"==n.resize?n.aspect?Math.abs(o)>Math.abs(a)?(r.width=Math.max(n.copy.width+o,20),r.height=r.width/n.aspect):(r.height=Math.max(n.copy.height+a,20),r.width=r.height*n.aspect):(r.width=Math.max(n.copy.width+o,20),r.height=Math.max(n.copy.height+a,20)):"E"==n.resize?r.width=Math.max(n.copy.width+o,20):"S"==n.resize?r.height=Math.max(n.copy.height+a,20):"N"==n.resize?n.copy.height-a>20&&(r.height=n.copy.height-a,r.offsetY=n.copy.offsetY+a):"W"==n.resize?n.copy.width-o>20&&(r.width=n.copy.width-o,r.offsetX=n.copy.offsetX+o):"NE"==n.resize?(r.width=Math.max(n.copy.width+o,20),n.copy.height-a>20&&(r.height=n.copy.height-a,r.offsetY=n.copy.offsetY+a)):"SW"==n.resize?(r.height=Math.max(n.copy.height+a,20),n.copy.width-o>20&&(r.width=n.copy.width-o,r.offsetX=n.copy.offsetX+o)):"NW"==n.resize?(n.copy.height-a>20&&(r.height=n.copy.height-a,r.offsetY=n.copy.offsetY+a),n.copy.width-o>20&&(r.width=n.copy.width-o,r.offsetX=n.copy.offsetX+o)):(r.offsetX=n.copy.offsetX+o,r.offsetY=n.copy.offsetY+a),t.triggerChange({dragging:!0}),!0}onMouseDrag(e){if("sheet"===this._selectionMode)return;let t={clientX:e.clientX,clientY:e.clientY},n=this._workbook.activeSheet();if(this._dragDrawing(e))return;let i=this.objectAt(t);if(n.resizingInProgress())this.constrainResize(i.type,i.ref)||n.resizeHintPosition({x:i.x,y:i.y});else if("outside"!==i.type){if(this.originFrame===i.pane)this.selectToLocation(t);else{let e=this.originFrame._grid;i.x,e.right,i.y>e.bottom&&this.scrollTop(),i.y<e.top||i.x<e.left?this.startAutoScroll(i,t):this.selectToLocation(t)}e.preventDefault()}else this.startAutoScroll(i)}onMouseUp(e){let t=this._workbook.activeSheet();t.completeResizing(),t.completeDragging(),this.navigator.completeSelection(),this.stopAutoScroll();let n=this.editor.activeEditor();if(!n)return;let i=e.target;for(;i;){if(i===n.element)return;i=i.parentNode}let r=this.objectAt(e);r&&r.ref&&n.canInsertRef(!1)&&(n.refAtPoint(t),t._setFormulaSelections(n.highlightedRefs()))}onDblClick(e){let t=this.objectAt(e),n=!1===this._workbook.activeSheet().selection().enable();if("cell"!==t.type||n)return;let i=this._workbook.activeSheet().selection();this.activateEditor(!i.value()&&!i.formula()),this.onEditorUpdate()}onCut(e){let t=this;setTimeout((function(){t.clipboard.menuInvoked=void 0===e,t._execute({command:"CutCommand",options:{workbook:t.view._workbook,event:e}})}))}clipBoardValue(){return this.clipboardElement.html()}_pasteImage(e){let t=this,n=new window.Image;n.src=window.URL.createObjectURL(e),n.onload=function(){t._execute({command:"InsertImageCommand",options:{blob:e,width:n.width,height:n.height}})},setTimeout((function(){window.URL.revokeObjectURL(n.src)}),10)}onPaste(e){let t=this,n="",i="";if(t.clipboard.menuInvoked=void 0===e,e){let r=e.clipboardData;if(!r||!r.getData){if(window.clipboardData.files&&window.clipboardData.files.length){let e=window.clipboardData.files[0];if(/^image\/(?:png|jpe?g|gif)$/i.test(e.type))return t._pasteImage(e)}return i=window.clipboardData.getData("Text"),i&&(i=i.trim()),t.clipboardElement.empty(),void setTimeout((function(){n=t.clipboardElement.html(),(n||i)&&(t.clipboard.external({html:n,plain:i}),t._execute({command:"PasteCommand",options:{workbook:t.view._workbook,event:e}}))}))}{e.preventDefault();let o=!1,a=!1;if(window.DOMStringList&&r.types instanceof window.DOMStringList?(o=r.types.contains("text/html"),a=r.types.contains("text/plain")):Array.isArray(r.types)?(o=r.types.indexOf("text/html")>=0,a=r.types.indexOf("text/plain")>=0):(o=/text\/html/.test(r.types),a=/text\/plain/.test(r.types)),o&&(n=r.getData("text/html").trim()),a&&(i=r.getData("text/plain").trim()),!n&&!i&&r.items&&r.items.length)for(let e=0;e<r.items.length;++e){let n=r.items[e];if("file"===n.kind&&/^image\/(?:png|jpe?g|gif)$/i.test(n.type))return t._pasteImage(n.getAsFile())}}}else t.clipboard.menuInvoked=!0;(n||i)&&(t.clipboard.external({html:n,plain:i}),t._execute({command:"PasteCommand",options:{workbook:t.view._workbook,event:e}}))}onCopy(e){this.clipboard.menuInvoked=void 0===e,this._execute({command:"CopyCommand",options:{workbook:this.view._workbook,event:e}})}scrollTop(){this.scroller.scrollTop=0}scrollLeft(){this.scroller.scrollLeft=0}scrollDown(e){this.scroller.scrollTop+=e}scrollRight(e){this.scroller.scrollLeft+=e}scrollWith(e,t){this.scroller.scrollTop+=t,this.scroller.scrollLeft+=e}translateCoords(e){let t=this.container.getBoundingClientRect();return{x:e.clientX-t.left,y:e.clientY-t.top}}objectAt(e,t){if(!e)return;const n=this.translateCoords(e);return this.view.objectAt(n.x,n.y,t)}selectToLocation(e){let t=this.objectAt(e,!0);t.pane&&t.ref&&(this.extendSelection(t),this.lastKnownCellLocation=e,this.originFrame=t.pane),this.stopAutoScroll()}extendSelection(e){this.navigator.extendSelection(e.ref,this._selectionMode)}autoScroll(){let e=this._autoScrollTarget.x,t=this._autoScrollTarget.y,n=this.originFrame._grid,i=this.view.scroller,r=i.scrollLeft,o=i.scrollTop;e<n.left&&this.scrollRight(-8),e>n.right&&this.scrollRight(8),t<n.top&&this.scrollDown(-8),t>n.bottom&&this.scrollDown(8),o===i.scrollTop&&r===i.scrollLeft?this.selectToLocation(this.finalLocation):this.extendSelection(this.objectAt(this.lastKnownCellLocation))}startAutoScroll(e,t){this._scrollInterval||(this._scrollInterval=setInterval(this.autoScroll.bind(this),50)),this.finalLocation=t||this.lastKnownCellLocation,this._autoScrollTarget=e}stopAutoScroll(){clearInterval(this._scrollInterval),this._scrollInterval=null}openCustomEditor(){this.view.openCustomEditor()}openFilterMenu(e){let t=this.objectAt(e),n=this._workbook.activeSheet().filterColumn(t.ref),i=this.view.createFilterMenu(n);i.bind("action",this.onCommandRequest.bind(this)),i.bind("action",i.close.bind(i)),i.openFor(e.target,e)}_saveEditorValue(e){let t=this.editor._range.sheet(),n=this.editor.value();this._workbook.activeSheet()!==t&&(this._workbook.activeSheet()._setFormulaSelections(),this._workbook.activeSheet(t)),t.isInEditMode(!1),this._lastEditorValue=n,this._execute({command:"EditCommand",options:{value:n,arrayFormula:e}})}onEditorChange(){this._saveEditorValue(!1)}onEditorArrayFormula(){this._saveEditorValue(!0),this.editor.deactivate(!0)}onEditorActivate(){let e=this._workbook.activeSheet();e._setFormulaSelections(this.editor.highlightedRefs()),e.isInEditMode(!0)}onEditorDeactivate(){let e=this._workbook.activeSheet();e.isInEditMode(!1),e._setFormulaSelections([])}onEditorUpdate(){this._workbook.activeSheet()._setFormulaSelections(this.editor.highlightedRefs())}onEditorBarFocus(){!1===this._workbook.activeSheet().selection().enable()||this.editor.activate({range:this._workbook.activeSheet().selection(),rect:this.view.activeCellRectangle(),tooltip:this._activeTooltip()})}onEditorCellFocus(){this.editor.scale()}onEditorEsc(){this.resetEditorValue(),this.editor.deactivate(),this.clipboardElement.focus()}insertNewline(e){e.preventDefault(),this.editor.insertNewline()}onEditorBlur(e,t){e.defaultPrevented||this.editor.isFiltered()||(this._preventNavigation=!1,this.editor.deactivate(),this._preventNavigation||(this.clipboardElement.focus(),this.navigator.navigateInSelection(ay[t])),"tab"===t&&e.preventDefault())}onEditorAction(e,t){if(e.defaultPrevented)return;let n=this.editor,i=this._workbook.activeSheet();this._casualEditing&&/^(?:up|right|down|left)$/.test(t)?(this.deactivateEditor(),this.navigator.moveActiveCell(oy[t]),e.preventDefault()):n.canInsertRef(!0)&&(this.navigator.moveActiveCell(oy[t]),n.activeEditor().refAtPoint(i),i._setFormulaSelections(n.highlightedRefs()),e.preventDefault())}onEditorShiftAction(e,t){let n=this.editor,i=this._workbook.activeSheet();n.canInsertRef(!0)&&(this.navigator.modifySelection(oy[t.replace("shift+","")],this.appendSelection),n.activeEditor().refAtPoint(i),i._setFormulaSelections(n.highlightedRefs()),e.preventDefault())}resetEditorValue(){let e=this._workbook.activeSheet(),t=e.activeCell(),n=this._workbook._inputForRef(t),i=e.range(t).intersectingArrayFormula();i&&(n="="+i.formula),this.editor.value(n,Boolean(i))}activateEditor(e){this._casualEditing=e,this.editor.activate({range:this._workbook.activeSheet().selection(),rect:this.view.activeCellRectangle(),tooltip:this._activeTooltip()}).focus()}deactivateEditor(){this.view.editor.deactivate()}onCommandRequest(e){e.command?this._execute(e):this._workbook.undoRedoStack[e.action]()}onDialogRequest(e){let t={pdfExport:this._workbook.options.pdf,excelExport:this._workbook.options.excel};e.options?__(e.options,t):e.options=t,this.view.openDialog(e.name,e.options)}onNameEditorEnter({value:e}){let t,n=this._workbook,i=n.activeSheet(),r=void 0!==e?e:this.view.nameEditor.value();if(t=z_.parseReference(r,!0)||n.nameValue(r),t instanceof Ov){if(t.sheet&&t.sheet.toLowerCase()!==i.name().toLowerCase()){let e=n.sheetByName(t.sheet);e&&(n.activeSheet(e),i=e)}i.range(t).select()}else t=i.selection()._ref.clone().simplify().setSheet(i.name(),!0),this._execute({command:"DefineNameCommand",options:{name:r,value:t}}),this.clipboardElement.focus()}onNameEditorCancel(){this.clipboardElement.focus()}onNameEditorSelect(e){let t=e.name,n=this._workbook,i=n.activeSheet(),r=n.nameValue(t);if(r instanceof Ov){if(r.sheet&&r.sheet.toLowerCase()!==i.name().toLowerCase()){let e=n.sheetByName(r.sheet);e&&(n.activeSheet(e),i=e)}i.range(r).select()}else this.clipboardElement.focus()}onNameEditorDelete(e){this._execute({command:"DeleteNameCommand",options:{name:e.name}}),this.clipboardElement.focus()}}class vy{constructor(e,t,n,i){this.level=e,this.value=t,this.left=n,this.right=i}}const _y={left:void 0,right:void 0,level:0};function by(e){let t=e;if(t.left.level===t.level){let e=t;t=t.left,e.left=t.right,t.right=e}return t}function yy(e){let t=e;if(t.right.right.level===t.level){let e=t;t=t.right,e.right=t.left,t.left=e,t.level+=1}return t}function wy(e,t){return e===_y?new vy(1,t,_y,_y):(e.value.start>t.start?e.left=wy(e.left,t):e.right=wy(e.right,t),yy(by(e)))}function ky(e,t){let n=e;if(n===_y)return n;let i=n.value.start-t.start;if(0===i)if(n.left!==_y&&n.right!==_y){let e=n.left;for(;e.right!==_y;)e=e.right;n.value=e.value,n.left=ky(n.left,n.value)}else n=n.left===_y?n.right:n.left;else i>0?n.left=ky(n.left,t):n.right=ky(n.right,t);return(n.left.level<n.level-1||n.right.level<n.level-1)&&(n.level-=1,n.right.level>n.level&&(n.right.level=n.level),n=by(n),n.right=by(n.right),n.right.right=by(n.right.right),n=yy(n),n.right=yy(n.right)),n}_y.left=_y,_y.right=_y;class xy{constructor(e,t,n){this.start=e,this.end=t,this.value=n}intersects(e){return e.start<=this.end&&e.end>=this.start}clone(){return new xy(this.start,this.end,this.value)}}class Cy{constructor(){this.root=_y}insert(e){this.root=wy(this.root,e)}remove(e){this.root=ky(this.root,e)}findrange(e){let t=this.root;for(;t!==_y;)if(e<t.value.start)t=t.left;else{if(!(e>t.value.end))return t.value;t=t.right}return null}values(){let e=[];return Sy(this.root,e),e}intersecting(e,t){let n=[];return Ty(this.root,new xy(e,t),n),n}map(e){let t=new Cy;return Dy(t,this.root,e),t}forEach(e){Ay(this.root,e)}clone(){return this.map((function(e){return e.clone()}))}first(){let e=this.root;for(;e.left!==_y;)e=e.left;return e}last(){let e=this.root;for(;e.right!==_y;)e=e.right;return e}}function Sy(e,t){e!==_y&&(Sy(e.left,t),t.push(e.value),Sy(e.right,t))}function Ty(e,t,n){if(e===_y)return;let i=e.value;t.start<i.start&&Ty(e.left,t,n),i.intersects(t)&&n.push(i),t.end>i.end&&Ty(e.right,t,n)}function Dy(e,t,n){t!==_y&&(Dy(e,t.left,n),e.insert(n(t.value)),Dy(e,t.right,n))}function Ay(e,t){e!==_y&&(Ay(e.left,t),t(e.value),Ay(e.right,t))}class My{constructor(e,t,n){void 0===t?this.tree=e:(this.tree=new Cy,this.tree.insert(new xy(e,t,n)))}values(){return this.tree.values()}map(e){return new My(this.tree.map(e))}forEach(e){this.tree.forEach(e)}intersecting(e,t){return this.tree.intersecting(e,t)}first(){return this.tree.first().value}last(){return this.tree.last().value}insert(e,t,n){return this.tree.insert(new xy(e,t,n))}value(e,t,n){let i=e,r=t;if(void 0===n)return void 0===r&&(r=i),this.intersecting(i,r)[0].value;let o=this.tree.intersecting(i-1,r+1);if(o.length){let e=o[0],t=o[o.length-1];e.end<i&&(e.value===n?i=e.start:o.shift()),t.start>r&&(t.value===n?r=t.end:o.pop());for(let e=0,t=o.length;e<t;e++){let t=o[e],a=t.value,s=t.start,l=t.end;this.tree.remove(t),s<i&&(a!==n?this.insert(s,i-1,a):i=s),l>r&&(a!==n?this.insert(r+1,l,a):r=l)}}this.insert(i,r,n)}expandedValues(e,t){let n=this.intersecting(e,t),i=[],r=0;for(let o=e;o<=t;o++)n[r].end<o&&r++,i.push({index:o-e,value:n[r].value});return i}sortedIndices(e,t,n,i){let r=this.expandedValues(e,t),o=function(e,t){return e.value===t.value?e.index-t.index:n(e.value,t.value)};return i&&(o=function(e,t){let r=i[e.index],o=i[t.index];return r.value===o.value?n(e.value,t.value):e.index-t.index}),r.sort(o),r}sort(e,t,n){if(1===this.intersecting(e,t).length)return;let i=this.expandedValues(e,t);for(let t=0,r=n.length;t<r;t++)this.value(t+e,t+e,i[n[t].index].value)}copy(e,t,n){let i,r=this.intersecting(e,t),o=n;for(let n=0,a=r.length;n<a;n++){let a=r[n].start;a<e&&(a=e);let s=r[n].end;s>t&&(s=t),i=o+(s-a),this.value(o,i,r[n].value),o=++i}}iterator(e,t){return new Ey(e,t,this.intersecting(e,t))}getState(){return this.tree.clone()}setState(e){this.tree=e.clone()}toJSON(){return this.values()}fromJSON(e){e.forEach((e=>{this.value(e.start,e.end,e.value)}))}}let Ey=class{constructor(e,t,n){this.start=e,this.end=t,this.index=0,this.ranges=n}unique(){return this.ranges.map((function(e){return e.value}))}at(e){for(;this.ranges[this.index]&&this.ranges[this.index].end<e;)this.index++;return this.ranges[this.index]&&this.ranges[this.index].value}forEach(e){for(let t=this.start;t<=this.end;t++)e(this.at(t),t);this.index=0}};class Iy extends My{constructor(e,t,n){super(e,t,n),this._defaultValue=n,this.tree=new Cy,this.range=new xy(e,t,n)}intersecting(e,t){let n,i=e,r=this.tree.intersecting(i,t),o=[];if(!r.length)return[this.range];for(let e=0,t=r.length;e<t;e++)n=r[e],n.start>i&&o.push(new xy(i,n.start-1,this.range.value)),o.push(n),i=n.end+1;return n.end<t&&o.push(new xy(n.end+1,t,this.range.value)),o}insert(e,t,n){let i=n;null==i&&(i=this._defaultValue),i!==this.range.value&&this.tree.insert(new xy(e,t,i))}lastRangeStart(){let e=this.tree.root;if(e===_y)return this.range.start;for(;e.right!==_y;)e=e.right;return e.value.end+1}}class zy{constructor(e){this.list=e}get(e){return this.parse(this.list.value(e,e))}set(e,t,n){void 0===n&&(n=t,t=e),this.list.value(e,t,n)}parse(e){return e}copy(e,t,n){this.list.copy(e,t,n)}iterator(e,t){return this.list.iterator(e,t)}}class Py extends zy{set(e,t,n){this.list.value(e,t,JSON.stringify(n))}parse(e){return JSON.parse(e)}}const Hy=[{property:zy,name:"format",value:null,sortable:!0,serializable:!0},{property:class extends zy{constructor(e,t){super(e),this.formats=t}set(e,t,n){n instanceof Date?(n=z_.runtime.dateToSerial(n),this.formats.value(e,t)||this.formats.value(e,t,I_().calendar.patterns.d.replace(/M/g,"m").replace(/'/g,'"').replace(/tt/,"am/pm"))):"number"==typeof n&&(n=z_.runtime.limitPrecision(n)),this.list.value(e,t,n)}},name:"value",value:null,sortable:!0,serializable:!0,depends:"format"},{property:zy,name:"formula",value:null,sortable:!0,serializable:!0},{property:zy,name:"background",value:null,sortable:!0,serializable:!0},{property:Py,name:"vBorders",value:null,sortable:!1,serializable:!1},{property:Py,name:"hBorders",value:null,sortable:!1,serializable:!1},{property:Py,name:"dBorders",value:null,sortable:!1,serializable:!0},{property:zy,name:"color",value:null,sortable:!0,serializable:!0},{property:zy,name:"fontFamily",value:null,sortable:!0,serializable:!0},{property:zy,name:"underline",value:null,sortable:!0,serializable:!0},{property:zy,name:"fontSize",value:null,sortable:!0,serializable:!0},{property:zy,name:"italic",value:null,sortable:!0,serializable:!0},{property:zy,name:"bold",value:null,sortable:!0,serializable:!0},{property:zy,name:"textAlign",value:null,sortable:!0,serializable:!0},{property:zy,name:"indent",value:null,sortable:!0,serializable:!0},{property:zy,name:"verticalAlign",value:null,sortable:!0,serializable:!0},{property:zy,name:"wrap",value:null,sortable:!0,serializable:!0},{property:zy,name:"validation",value:null,sortable:!1,serializable:!0},{property:zy,name:"enable",value:null,sortable:!1,serializable:!0},{property:zy,name:"link",value:null,sortable:!0,serializable:!0},{property:zy,name:"editor",value:null,sortable:!0,serializable:!0},{property:zy,name:"comment",value:null,sortable:!0,serializable:!0},{property:zy,name:"html",value:null,sortable:!0,serializable:!0}];class Fy{constructor(e,t,n){n=n||{};let i=e*t-1;this.specs=Hy,this.rowCount=e,this.columnCount=t,this.cellCount=i,this.properties={},this.lists={},this.specs.forEach((function(e){let t=e.name,r=n[t];void 0===r&&(r=e.value),this.lists[t]=new Iy(0,i,r),(this.properties[t]=new e.property(this.lists[t],this.lists[e.depends])).spec=e}),this),this.lists.formula.tree.clone=Ly,this.lists.validation.tree.clone=Ly}_resize(e,t){let n=this,i=n.rowCount,r=e*t-1;function o(t){return(t/i|0)*e+t%i}function a(e){e.start=o(e.start),e.end=o(e.end)}Object.keys(n.lists).forEach((function(t){let o=n.lists[t];e!==i&&o.forEach(a),o.range.end=r})),n.rowCount=e,n.columnCount=t,n.cellCount=r}getState(){let e={};return this.specs.forEach((function(t){e[t.name]=this.lists[t.name].getState()}),this),e}setState(e){this.specs.forEach((function(t){this.lists[t.name].setState(e[t.name])}),this)}get(e,t){if(void 0===t)return this.lists[e];switch(e){case"borderRight":t+=this.rowCount;case"borderLeft":e="vBorders";break;case"borderBottom":t++;case"borderTop":e="hBorders"}return t>this.cellCount?null:this.properties[e].get(t)}set(e,t,n,i){switch(e){case"borderRight":t+=this.rowCount,n+=this.rowCount;case"borderLeft":e="vBorders";break;case"borderBottom":t++,n++;case"borderTop":e="hBorders"}t<=n&&n<=this.cellCount&&this.properties[e].set(t,n,i)}fromJSON(e,t){for(let n=0;n<this.specs.length;n++){let i=this.specs[n];i.serializable&&void 0!==t[i.name]&&this.set(i.name,e,e,t[i.name],!1)}["borderLeft","borderRight","borderTop","borderBottom"].forEach((function(n){void 0!==t[n]&&this.set(n,e,e,t[n])}),this)}copy(e,t,n){this.specs.forEach((function(i){this.properties[i.name].copy(e,t,n)}),this)}iterator(e,t,n){let i=this.properties[e],r=i.iterator(t,n),o=r.at,a=this.cellCount;return r.at=function(e){return e>a?null:i.parse(o.call(r,e))},r.name=e,r.value=i.spec.value,r}sortable(){return this.specs.filter((function(e){return e.sortable})).map((function(e){return this.lists[e.name]}),this)}iterators(e,t){return this.specs.reduce(function(n,i){return i.serializable&&n.push(this.iterator(i.name,e,t)),n}.bind(this),[])}forEach(e,t,n){let i,r,o=this.iterators(e,t),a=this.iterator("hBorders",e,t+1),s=this.iterator("vBorders",e,t),l=this.iterator("vBorders",e+this.rowCount,t+this.rowCount);function c(e,t,n){let r=t.at(n);r!==t.value&&(i[e]=r)}for(r=e;r<=t;r++){i={};for(let e=0;e<o.length;e++){let t=o[e],n=t.at(r);n!==t.value&&(i[t.name]=n)}c("borderLeft",s,r),c("borderRight",l,r+this.rowCount),c("borderTop",a,r),(r+1)%this.rowCount&&c("borderBottom",a,r+1),n(i)}}forEachProperty(e){for(let t in this.properties)e(this.properties[t])}}function Ry(e){return(e=e.clone()).value=e.value.deepClone(),e}function Ly(){let e=this.map(Ry);return e.clone=Ly,e}const By=Hy.reduce((function(e,t){return t.serializable&&e.push(t.name),e}),["borderTop","borderRight","borderBottom","borderLeft"]);let Oy='DATEVALUE("{0}")';class Vy{constructor(e){this.handler=e.handler,this.from=e.from,this.to=e.to,this.dataType=e.dataType,this.comparerType=e.comparerType,this.type=e.type?e.type:"warning",this.allowNulls=!!e.allowNulls,this.fromIsDateValue=!!e.fromIsDateValue,this.toIsDateValue=!!e.toIsDateValue,this.showButton=e.showButton,this.fromIsListValue=!!e.fromIsListValue,this.sheet=e.sheet,this.row=e.row,this.col=e.col,e.tooltipMessageTemplate&&(this.tooltipMessageTemplate=e.tooltipMessageTemplate),e.tooltipTitleTemplate&&(this.tooltipTitleTemplate=e.tooltipTitleTemplate),e.messageTemplate&&(this.messageTemplate=e.messageTemplate),e.titleTemplate&&(this.titleTemplate=e.titleTemplate)}_formatMessages(e){let t=this.from?this.from_value:"",n=this.to?this.to_value:"",i=this.from?this.from.toString():"",r=this.to?this.to.toString():"",o=this.dataType,a=this.type,s=this.comparerType;return E_().format(e,t,n,i,r,o,a,s)}_setMessages(){this.title="",this.message="",this.tooltipTitleTemplate&&(this.tooltipTitle=this._formatMessages(this.tooltipTitleTemplate)),this.tooltipMessageTemplate&&(this.tooltipMessage=this._formatMessages(this.tooltipMessageTemplate)),this.titleTemplate&&(this.title=this._formatMessages(this.titleTemplate)),this.messageTemplate&&(this.message=this._formatMessages(this.messageTemplate))}_getListData(){if(!this.from_value||!this.from_value.data)return[];let e,t,n=this.from_value.data,i=[];for(e=0;e<n.length;e++){let r=n[e];if(r)for(t=0;t<r.length;t++)i.push(r[t])}return i}clone(e,t,n){let i=this._getOptions();i.from&&(i.from=i.from.clone(e,t,n)),i.to&&(i.to=i.to.clone(e,t,n));const r=Object.assign({},i);return r.handler=this.handler,r.sheet=e,r.row=t,r.col=n,new Vy(r)}deepClone(){let e=new Vy(this);return e.from=e.from.deepClone(),e.to&&(e.to=e.to.deepClone()),e}exec(e,t,n,i){let r=this;function o(t){return t instanceof Ov&&(t=e.getData(t),Array.isArray(t)&&(t=t[0])),t}let a=function(e){r.from_value=o(e),r.value=r.handler.call(r,t,n),r._setMessages(),i&&i(r.value)};r.to?r.to.exec(e,(function(t){r.to_value=o(t),r.from.exec(e,a)})):r.from.exec(e,a)}reset(){this.from&&this.from.reset(),this.to&&this.to.reset(),delete this.value}adjust(e,t,n,i){let r,o,a,s=this.row,l=this.col;if(this.from&&(r=this.from.adjust(e,t,n,i)),this.to&&(o=this.to.adjust(e,t,n,i)),this.sheet.toLowerCase()===e.toLowerCase())switch(t){case"row":s>=n&&(a=!0,this.row+=i);break;case"col":l>=n&&(a=!0,this.col+=i)}if(a||r||o){let e=new Vy(this);return e.from=r,e.to=o,e.row=s,e.col=l,e}}toJSON(){let e=this._getOptions();return e.from&&(e.from=e.from.toString(),"list"===e.dataType&&(e.from=e.from.replace(/^_matrix\((.*)\)$/i,"$1"),delete e.fromIsListValue),"date"===e.dataType&&this.fromIsDateValue&&(e.from=e.from.replace(/^DATEVALUE\("(.*)"\)$/i,"$1"),delete e.fromIsDateValue)),e.to&&(e.to=e.to.toString(),"date"===e.dataType&&this.toIsDateValue&&(e.to=e.to.replace(/^DATEVALUE\("(.*)"\)$/i,"$1"),delete e.toIsDateValue)),e}_getOptions(){return{from:this.from,to:this.to,dataType:this.dataType,type:this.type,comparerType:this.comparerType,row:this.row,col:this.col,sheet:this.sheet,allowNulls:this.allowNulls,fromIsListValue:this.fromIsListValue,fromIsDateValue:this.fromIsDateValue,toIsDateValue:this.toIsDateValue,tooltipMessageTemplate:this.tooltipMessageTemplate,tooltipTitleTemplate:this.tooltipTitleTemplate,messageTemplate:this.messageTemplate,titleTemplate:this.titleTemplate,showButton:this.showButton}}}const Ny={compile:function(e,t,n,i){let r,o,a,s;if("string"==typeof i&&(i=JSON.parse(i)),i.from&&("list"!==i.dataType||i.fromIsListValue||(i.from.indexOf("{")>-1&&(i.from=i.from.replace(/\"/g,"").replace("{",'"').replace("}",'"')),i.from=E_().format("_matrix({0})",i.from),i.fromIsListValue=!0),"date"===i.dataType&&(a=z_.runtime.parseDate(i.from),a&&(i.from=E_().format(Oy,i.from),i.fromIsDateValue=!0)),i.from=z_.compile(z_.parseFormula(e,t,n,i.from))),i.to&&("date"===i.dataType&&(s=z_.runtime.parseDate(i.to),s&&(i.to=E_().format(Oy,i.to),i.toIsDateValue=!0)),i.to=z_.compile(z_.parseFormula(e,t,n,i.to))),o="custom"===i.dataType?Ny.validationComparers.custom:"list"===i.dataType?Ny.validationComparers.list:Ny.validationComparers[i.comparerType],!o)throw E_().format("'{0}' comparer is not implemented.",i.comparerType);r=function(e){let t=this.to&&(this.to_value||0===this.to_value)?this.to_value:void 0;if(null===e||""===e)this.allowNulls?this.value=!0:this.value=!1;else if("custom"===this.dataType)this.value=o(e,this.from_value,t);else if("list"===this.dataType){let n=this._getListData();this.value=o(e,n,t)}else this.value=o(e,this.from_value,t);return this.value};const l=Object.assign({},i);return l.handler=r,l.sheet=e,l.row=t,l.col=n,new Vy(l)},validationComparers:{greaterThan:function(e,t){return e>t},lessThan:function(e,t){return e<t},between:function(e,t,n){return e>=t&&e<=n},equalTo:function(e,t){return e===t},notEqualTo:function(e,t){return e!==t},greaterThanOrEqualTo:function(e,t){return e>=t},lessThanOrEqualTo:function(e,t){return e<=t},notBetween:function(e,t,n){return e<t||e>n},custom:function(e,t){return t},list:function(e,t){return t.indexOf(e)>-1}}};Ny.Validation=Vy;const{measureText:$y}=Vo;let Uy=["color","fontFamily","underline","italic","bold","textAlign","indent","verticalAlign","background","format","link","editor","borderTop","borderRight","borderBottom","borderLeft","comment","html"],Wy=class e{constructor(e,t){this._sheet=t,this._ref=e}clone(){return new e(this._ref.clone(),this._sheet)}skipHiddenCells(){let e=[],t=this,n=t._sheet,i=n.isHiddenRow.bind(n),r=n.isHiddenColumn.bind(n);return t._ref.forEach((function(n){let o=(n=t._normalize(n.toRangeRef())).topLeft,a=n.bottomRight,s=jy(o.row,a.row,i),l=jy(o.col,a.col,r);for(let t=0;t<s.length;++t)for(let n=0;n<l.length;++n)e.push(new Uv(new $v(s[t].begin,l[n].begin),new $v(s[t].end,l[n].end)))})),n.range(e.length>1?new Wv(e):e[0])}_normalize(e){return this._sheet._grid.normalize(e)}_set(e,t,n){let i=this,r=i._sheet;return i._ref.forEach((function(n){let i=n;if(("value"===e||"formula"===e||"link"===e)&&n.topLeft){let e=new $v(n.topLeft.row,n.topLeft.col);r.forEachMergedCell((function(t){t.intersects(e)&&(i=e)}))}r._set(i.toRangeRef(),e,t)})),n||r.triggerChange({recalc:"formula"===e||"value"===e||"validation"===e,value:t,range:i,ref:i._ref,isValue:"value"===e}),i}_get(e){return this._sheet._get(this._ref.toRangeRef(),e)}_property(e,t){return void 0===t?this._get(e):this._set(e,t)}value(e){return void 0!==e&&this._set("formula",null,!0),this._property("value",e)}html(e){return this._property("html",e)}resize(t){let n=this._resizedRef(t);return new e(n,this._sheet)}_resizedRef(e){return this._ref.map((function(t){return t.toRangeRef().resize(e)}))}input(e,t){t=Object.assign({arrayFormula:!1},t);let n,i=this._get("format");if(void 0!==e){let r=this._ref.toRangeRef().topLeft;return n=z_.parse(this._sheet.name(),r.row,r.col,e,i),this._sheet.batch(function(){let r=null;if("exp"===n.type)r=z_.compile(n);else if("@"!==i){let e=i&&Sb.type(n.value,i);"date"===n.type&&"date"!==e?this.format(n.format||I_().calendar.patterns.d.replace(/M/g,"m").replace(/'/g,'"').replace(/tt/,"am/pm")):"percent"===n.type&&"percent"!==e?this.format(100*n.value==(100*n.value|0)?"0%":"0.00%"):n.format&&(!i||n.currency||"number"===e&&"number"===n.type&&n.format.length>i.length)&&this.format(n.format)}else"string"!==n.type&&(n.value=e);this.formula(r,t.arrayFormula),r||this.value(n.value)}.bind(this),{recalc:!0,value:e,ref:this._ref,editorChange:this._sheet.isInEditMode(),isValue:!0}),this}{e=this._get("value");let t=this._get("formula"),o=i&&!t&&Sb.type(e,i);if(t)e="="+t;else e:{if(i&&"date"===o){let t=Sb.text(e,i);if(n=z_.parse(null,null,null,t,i),t===Sb.text(n.value,i)){e=t;break e}}if("date"===o){const t=E_();e=t.toString(z_.runtime.serialToDate(e),I_().calendar.patterns.d,t.locale)}else"percent"===o?e=z_.runtime.limitPrecision(100*e)+"%":"string"==typeof e&&(/^[=']/.test(e)||/^(?:true|false)$/i.test(e)||!/^=/.test(r=e)&&/number|percent/.test(z_.parse(null,0,0,r).type))?e="'"+e:this._sheet._useCultureDecimals()&&"number"==typeof e&&e!==Math.floor(e)&&(e=String(e).replace(".",I_().numbers.symbols.decimal))}return e}var r}enable(e){return void 0===e?!f_((function(e){this._sheet.forEach(this._ref,(function(t,n,i){!1===i.enable&&e(!0)}))}),this):this._property("enable",e)}formula(e,t){let n=this;if(void 0===e){let e=n._get("formula");return e?""+e:null}if(t){let t=this._ref.toRangeRef();(e=n._sheet.range(t.topLeft)._set("formula",e)._get("formula"))&&e.setArrayFormulaRange(t)}else n._set("formula",e);return n}intersectingArrayFormula(){let e=this._ref.clone().simplify().setSheet(this._sheet.name());return f_((function(t){this._sheet._forFormulas((function(n){let i=n.arrayFormulaRange;i&&(i=e.intersect(i))!==Vv&&t({formula:n,intersection:i})}))}),this)}canEditArrayFormula(){let e=this.intersectingArrayFormula();return!e||e.formula.arrayFormulaRange.eq(e.intersection)}validation(e){if(void 0===e){let e=this._get("validation");return e?e.toJSON():null}return this._property("validation",e)}_getValidationState(){let e,t,n=this._ref.toRangeRef(),i=n.topLeft.row,r=n.topLeft.col,o=n.bottomRight.row,a=n.bottomRight.col;for(e=r;e<=a;e++)for(t=i;t<=o;t++){let n=this._sheet._validation(t,e);if(n&&"reject"===n.type&&!1===n.value)return n}return!1}merge(){return this._ref=this._sheet._merge(this._ref),this}unmerge(){let e=this._sheet._mergedCells;return this._ref.forEach((function(t){t.toRangeRef().intersecting(e).forEach((function(t){e.splice(e.indexOf(t),1)}))})),this._sheet.triggerChange({}),this}select(){return this._sheet.select(this._ref),this}values(e){if(this._ref instanceof Wv)throw new Error("Unsupported for multiple ranges.");if(this._ref===Vv){if(void 0!==e)throw new Error("Unsupported for NULLREF.");return[]}let t,n,i=this._ref.toRangeRef(),r=i.topLeft.row,o=i.topLeft.col,a=i.bottomRight.row,s=i.bottomRight.col;if(void 0===e){e=new Array(i.height());for(let t=0;t<e.length;t++)e[t]=new Array(i.width());for(t=o;t<=s;t++)for(n=r;n<=a;n++)e[n-r][t-o]=this._sheet._value(n,t);return e}for(this._sheet._set(i,"formula",null),t=o;t<=s;t++)for(n=r;n<=a;n++){let i=e[n-r];if(i){let e=i[t-o];void 0!==e&&this._sheet._value(n,t,e)}}return this._sheet.triggerChange({recalc:!0,ref:i}),this}_properties(e,t){if(this._ref instanceof Wv)throw new Error("Unsupported for multiple ranges.");if(this._ref===Vv){if(void 0!==e)throw new Error("Unsupported for NULLREF.");return[]}let n,i,r=this._ref.toRangeRef(),o=r.topLeft.row,a=r.topLeft.col,s=r.bottomRight.row,l=r.bottomRight.col,c=this._sheet;if(void 0===e)return e=new Array(r.height()),c.forEach(r,(function(t,n,i){n-=a,(e[t-=o]||(e[t]=[]))[n]=i})),e;{let d;r=r.clone();let u=function(e){let t=d[e];r.topLeft.row=r.bottomRight.row=i,r.topLeft.col=r.bottomRight.col=n,"value"===e&&c._set(r,"formula",null),c._set(r,e,t)},h=!1;for(n=a;n<=l;n++)if(t||!c.isHiddenColumn(n))for(i=o;i<=s;i++){if(!t&&c.isHiddenRow(i))continue;if(t&&c.isFilteredRow(i))continue;let r=e[i-o];if(r&&(d=r[n-a],d)){const e=Object.keys(d);e.forEach(u),h=h||e.includes("value")}}return c.triggerChange({recalc:!0,ref:this._ref,isValue:h}),this}}clear(e){let t=(e=e||{}).clearAll||!Object.keys(e).length,n=this._sheet,i={recalc:t||e.contentsOnly,ref:this._ref,isValue:!0};return n.batch(function(){i.recalc&&this.formula(null),t&&this.validation(null),(t||e.formatOnly)&&(Uy.forEach(function(t){e.keepBorders&&/^border/i.test(t)||this[t](null)}.bind(this)),this.fontSize(null),this.wrap(null),this.unmerge())}.bind(this),i),this}clearContent(){return this.clear({contentsOnly:!0})}clearFormat(){return this.clear({formatOnly:!0})}isSortable(){return!this.cantSort()}cantSort(){if(this._ref instanceof Wv)return{code:"cantSortMultipleSelection",message:"Unsupported for multiple ranges."};if(this._ref===Vv)return{code:"cantSortNullRef",message:"Unsupported for NULLREF."};let e=this._sheet._getMergedCells(this._ref.toRangeRef()),t=e.primary,n=e.secondary,i=null,r=null,o={};try{this._sheet.forEach(this,(function(a,s){let l=new $v(a,s).print(),c=t[l];if(c){if(null===i)i=c.width(),r=c.height();else if(i!==c.width()||r!==c.height())throw o}else if(!n[l]&&e.hasMerged)throw o}))}catch(e){if(e!==o)throw e;return{code:"cantSortMixedCells",message:"Unsupported for range containing cells of different shapes."}}return!1}sort(e){let t=this.cantSort();if(t)throw new Error(t.message);return void 0===e&&(e={column:0}),e=e instanceof Array?e:[e],this._sheet._sortBy(this._ref.toRangeRef(),e.map((function(e,t){return"number"==typeof e&&(e={column:e}),{index:void 0===e.column?t:e.column,ascending:void 0===e.ascending||e.ascending}}))),this}isFilterable(){return!(this._ref instanceof Wv)}filter(e){if(this._ref instanceof Wv)throw new Error("Unsupported for multiple ranges.");return!1===e?this.clearFilters():(e=!0===e?[]:e instanceof Array?e:[e],this._sheet._filterBy(this._ref.toRangeRef(),e.map((function(e,t){return{index:void 0===e.column?void 0===e.index?t:e.index:e.column,filter:e.filter}})))),this}clearFilter(e){this._sheet.clearFilter(e)}clearFilters(){let e=this._sheet.filter(),t=[];if(e){for(let n=0;n<e.columns.length;n++)t.push(e.columns[n].index);this._sheet.batch((function(){this.clearFilter(t),this._filter=null}),{layout:!0,filter:!0})}}hasFilter(){let e=this._sheet.filter();return Boolean(e)}leftColumn(){return new e(this._ref.leftColumn(),this._sheet)}rightColumn(){return new e(this._ref.rightColumn(),this._sheet)}topRow(){return new e(this._ref.topRow(),this._sheet)}bottomRow(){return new e(this._ref.bottomRow(),this._sheet)}column(t){return new e(this._ref.toColumn(t),this._sheet)}row(t){return new e(this._ref.toRow(t),this._sheet)}forEachRow(t){this._ref.forEachRow(function(n){t(new e(n,this._sheet))}.bind(this))}forEachColumn(t){this._ref.forEachColumn(function(n){t(new e(n,this._sheet))}.bind(this))}sheet(){return this._sheet}topLeft(){return this._ref.toRangeRef().topLeft}intersectingMerged(){let e=this._sheet,t=[];return e._mergedCells.forEach(function(e){e.intersects(this._ref)&&t.push(e.toString())}.bind(this)),t}getState(e){let t,n=this._ref.first(),i={ref:n,data:[],origRef:this._ref,rows:this._sheet._rows.getState()};e?t="input"===e?["value","formula"]:"border"===e?["borderLeft","borderTop","borderRight","borderBottom"]:[e]:(t=By,i.mergedCells=this.intersectingMerged());let r=i.data;return this.forEachCell((function(e,i,o){let a={},s=e-n.row,l=i-n.col;r[s]||(r[s]=[]),r[s][l]=a,t.forEach((function(e){let t=void 0===o[e]?null:o[e];(t instanceof z_.runtime.Formula||t instanceof Ny.Validation)&&(t=t.deepClone()),a[e]=t}))})),i}setState(e,t){let n=this._sheet,i=this._ref.first(),r=e.ref.row-i.row,o=e.ref.col-i.col,a=t&&!t.isExternal(),s=t&&!a;n.batch(function(){e.mergedCells&&this.unmerge(),t||this._sheet._rows.setState(e.rows);let l=i.row,c=this.hasFilter();e.data.forEach((function(r,o){if(c&&a&&n.isHiddenRow(e.ref.row+o))return;let d=i.col;r.forEach((function(r,u){if(c&&a&&n.isHiddenColumn(e.ref.col+u))return;let h=t?n.range(l,d):n.range(i.row+o,i.col+u);if(h.enable()){for(let e in r)"value"!==e&&(t&&"enable"===e||h._set(e,r[e]));if(!r.formula)if(s)try{null==r.value?h._set("value",null):h.input(r.value)}catch(e){h._set("value",r.value)}else h._set("value",r.value)}d++})),l++})),e.mergedCells&&e.mergedCells.forEach((function(e){e=n._ref(e).relative(r,o,3),n.range(e).merge()}),this)}.bind(this),{recalc:!0,ref:this._ref})}_adjustRowHeight(){let e=this,t=e._sheet,n=t._getMergedCells(e._ref.toRangeRef()),i=n.primary,r=n.secondary;t.batch((function(){e.forEachRow((function(e){let n=e._ref.topLeft.row,o=t.rowHeight(n);o&&(e.forEachCell((function(e,n,a){let s=new $v(e,n).print();if(r[s])return;let l,c=i[s];l=c?t._columns.sum(c.topLeft.col,c.bottomRight.col):t.columnWidth(n);let d=a.value;a.format&&null!=d&&(d=Sb.format(d,a.format));let u=function(e,t,n,i,r){const o=document.createElement("div");o.style.setProperty("position","absolute","important"),o.style.setProperty("top","-4000px","important"),o.style.setProperty("height","auto","important"),o.style.setProperty("padding","1px 3px","important"),o.style.setProperty("box-sizing","border-box","important"),o.style.setProperty("margin","0","important"),o.style.setProperty("border","1px solid black","important"),o.style.setProperty("line-height","normal","important"),o.style.setProperty("visibility","hidden","important"),o.style.setProperty("white-space","pre-wrap");let a={baselineMarkerSize:0,width:!0===r?t+"px":"auto","font-size":(i||12)+"px","font-family":n||"Arial","white-space":!0===r?"pre-wrap":"pre","overflow-wrap":!0===r?"break-word":"normal","word-wrap":!0===r?"break-word":"normal"};return $y(e,a,{box:o,normalizeText:!1}).height}(d,l,a.fontFamily,a.fontSize,a.wrap);o=Math.max(o,u)})),t.rowHeight(n,o))}))}),{layout:!0})}forEachCell(e){this._ref.forEach(function(t){this._sheet.forEach(t.toRangeRef(),e.bind(this))}.bind(this))}hasValue(){let e=this._sheet._defaultCellStyle;return f_((function(t){this.forEachCell((function(n,i,r){for(let n in r){let i=r[n];null!=i&&i!==e[n]&&t(!0)}}))}),this)}wrap(e){return void 0===e?Boolean(this._property("wrap")):(this._property("wrap",e),null!==e&&this._adjustRowHeight(),this)}fontSize(e){return void 0===e?this._property("fontSize"):(this._property("fontSize",e),null!==e&&this._adjustRowHeight(),this)}draw(e,t){this._sheet.draw(this,e,t)}insideBorders(e){return this.insideVerticalBorders(e).insideHorizontalBorders(e)}insideVerticalBorders(e){return this._ref.forEach((function(t){t instanceof Uv&&t.width()>1&&((t=t.clone()).topLeft.col++,this._sheet.range(t)._set("vBorders",e))}),this),this}insideHorizontalBorders(e){return this._ref.forEach((function(t){t instanceof Uv&&t.height()>1&&((t=t.clone()).topLeft.row++,this._sheet.range(t)._set("hBorders",e))}),this),this}};function jy(e,t,n){for(;e<=t&&n(e);)e++;if(e>t)return[];for(let i=e+1;i<=t;++i)if(n(i))return[{begin:e,end:i-1}].concat(jy(i+1,t,n));return[{begin:e,end:t}]}Uy.forEach((function(e){Wy.prototype[e]=function(t){return this._property(e,t)}}));var qy=z_.runtime.Formula,Gy="incompatibleRanges",Ky=Wy.FillError=function(e){this.code=e};function Yy(e){for(var t=e.length,n=(t+1)/2,i=e.reduce((function(e,t){return e+t}),0)/t,r=0,o=0,a=0;a<t;a++){var s=a+1-n;r+=s*(e[a]-i),o+=s*s}if(!o)return function(t){return e[t%e.length]};var l=r/o,c=i-l*n;return function(e){return c+l*(e+1)}}function Qy(e){function t(e){return e.map((function(e){return e.number}))}var n=[],i=e.map((function(e){return e.formula||e.value}));return function(e,t){for(var n,i=null,r=0,o=[],a=0;a<e.length;++a)n=Xy(e[a]),o.push(n),null!=i&&n.type!==i.type&&(t(r,a,i.type,o.slice(r,a)),r=a),i=n;t(r,a,i.type,o.slice(r,a))}(i,(function(e,r,o,a){var s,l;if("number"==o)s=Yy(l=t(a));else if("string"==o||"formula"==o||"boolean"==o)s=function(e,t){return i[t]};else if(Array.isArray(o))if(1==a.length)s=function(e){return o[(a[0].number+e)%o.length]};else{var c=function(e){for(var t=e[1]-e[0],n=2;n<e.length;++n)if(e[n]-e[n-1]!=t)return null;return t}(t(a));s=null==c?function(e){return a[e%a.length].value}:function(e){var t=a[0].number+c*e;return o[t%o.length]}}else"null"!=o?(1==(l=t(a)).length&&l.push(l[0]+1),l=Yy(l),s=function(e,t){return i[t].replace(/^(.*[\D0]+)\d+/,"$1"+l(e,t))}):s=function(){return null};for(var d={f:s,begin:e,end:r,len:r-e},u=e;u<r;++u)n[u]=d})),function(t,r){var o=n[r],a=t/i.length|0,s=t%i.length,l=a*o.len+s-o.begin,c=o.f(l,r),d=function(e){var t={};return Object.keys(e||{}).forEach((function(n){t[n]=e[n]})),t}(e[r]);return delete d.enable,c instanceof qy?d.formula=c:d.value=c,d}}function Xy(e){if("number"==typeof e)return{type:"number",number:e};if("string"==typeof e){var t=function(e){for(var t=e.toLowerCase(),n=function(){const e=I_().calendar;return[e.days.format.abbreviated,e.days.format.wide,e.months.format.abbreviated,e.months.format.wide]}(),i=0;i<n.length;++i)for(var r=n[i],o=r.length;--o>=0;){if(r[o].toLowerCase()==t)return{type:r,number:o,value:e}}}(e);if(t)return t;var n=/^(.*\D)(\d+)/.exec(e);return n?{type:e=e.replace(/^(.*\D)\d+/,"$1-######"),match:n,number:parseFloat(n[2])}:{type:"string"}}if("boolean"==typeof e)return{type:"boolean"};if(null==e)return{type:"null"};if(e instanceof qy)return{type:"formula"};throw window.console.error(e),new Error("Cannot fill data")}function Zy(e){for(var t=e.length,n=e[0].length,i=[],r=0;r<n;++r){i[r]=[];for(var o=0;o<t;++o)i[r][o]=e[o][r]}return i}Wy.prototype._previewFillFrom=function(e,t){var n=this,i=n._sheet;"string"==typeof e&&(e=i.range(e));var r=e._ref.toRangeRef().clone().setSheet(i.name()),o=n._ref.toRangeRef().clone().setSheet(i.name());if(r.intersects(o)){if(r.eq(o))return null;if(o=o.clone(),r.topLeft.eq(o.topLeft))if(r.width()==o.width())o.topLeft.row+=r.height(),t=0;else{if(r.height()!=o.height())throw new Ky(Gy);o.topLeft.col+=r.width(),t=1}else{if(!r.bottomRight.eq(o.bottomRight))throw new Ky(Gy);if(r.width()==o.width())o.bottomRight.row-=r.height(),t=2;else{if(r.height()!=o.height())throw new Ky(Gy);o.bottomRight.col-=r.width(),t=3}}return i.range(o)._previewFillFrom(e,t)}if(null==t)if(r.topLeft.col==o.topLeft.col)t=r.topLeft.row<o.topLeft.row?0:2;else{if(r.topLeft.row!=o.topLeft.row)throw new Ky("noFillDirection");t=r.topLeft.col<o.topLeft.col?1:3}var a=1&t,s=2&t;if(a&&r.height()!=o.height()||!a&&r.width()!=o.width())throw new Ky(Gy);var l,c=e._properties();a?l=o.width():(c=Zy(c),l=o.height());for(var d=new Array(c.length),u=null,h=0;h<c.length;++h)for(var p=c[h],f=Qy(p),m=d[h]=new Array(l),g=0;g<l;++g){var v=s?-g-1:p.length+g,_=s?p.length-g%p.length-1:g%p.length,b=m[s?l-g-1:g]=f(v,_);null!=b.value&&(u=b.value)}return a||(d=Zy(d)),{props:d,direction:t,dest:n,hint:u}},Wy.prototype.fillFrom=function(e,t){var n=this._previewFillFrom(e,t);return n.dest._properties(n.props,!0),n.dest};const Jy="string",ew="function";let tw=function(){this._defaultPrevented=!0},nw=function(){return!0===this._defaultPrevented},iw=class{constructor(){this._events={}}bind(e,t,n){let i,r,o,a,s,l=this,c=typeof e===Jy?[e]:e,d=typeof t===ew;if(void 0===t){for(i in e)l.bind(i,e[i]);return l}for(i=0,r=c.length;i<r;i++)e=c[i],a=d?t:t[e],a&&(n&&(o=a,a=function(){l.unbind(e,a),o.apply(l,arguments)},a.original=o),s=l._events[e]=l._events[e]||[],s.push(a));return l}one(e,t){return this.bind(e,t,!0)}first(e,t){let n,i,r,o,a=this,s=typeof e===Jy?[e]:e,l=typeof t===ew;for(n=0,i=s.length;n<i;n++)e=s[n],r=l?t:t[e],r&&(o=a._events[e]=a._events[e]||[],o.unshift(r));return a}trigger(e,t){let n,i,r=this,o=r._events[e];if(o){for((t=t||{}).sender=r,t._defaultPrevented=!1,t.preventDefault=tw,t.isDefaultPrevented=nw,o=o.slice(),n=0,i=o.length;n<i;n++)o[n].call(r,t);return!0===t._defaultPrevented}return!1}unbind(e,t){let n,i=this,r=i._events[e];if(void 0===e)i._events={};else if(r)if(t)for(n=r.length-1;n>=0;n--)r[n]!==t&&r[n].original!==t||r.splice(n,1);else i._events[e]=[];return i}};class rw extends iw{constructor(e,t){super(),this.element=e,this.events=[],this.options=t}setOptions(e){this._setEvents(e),__({},this.options,e)}_setEvents(e){let t,n=this,i=0,r=n.events.length;for(;i<r;i++)t=n.events[i],n.options[t]&&e[t]&&(n.unbind(t,n.options[t]),n._events&&n._events[t]&&delete n._events[t]);n.bind(n.events,e)}resize(e){const t=this.getSize(),n=this._size;(e||(t.width>0||t.height>0)&&(!n||t.width!==n.width||t.height!==n.height))&&(this._size=t,this._resize(t,e),this.trigger("resize",t))}getSize(){return{width:this.element.offsetWidth,height:this.element.offsetHeight}}destroy(){this.unbind()}}class ow extends iw{constructor(e){super(),this.events=["activate","deactivate","change","update"],this.view=e,this.formulaBar=e.formulaBar,this._active=!1,this.barInput=e.formulaBar.formulaInput,this.cellInput=e.formulaInput,this.barInput.syncWith(this.cellInput),this.cellInput.syncWith(this.barInput),this.barInput.bind("keyup",this._triggerUpdate.bind(this)),this.cellInput.bind("keyup",this._triggerUpdate.bind(this)),this.barInput.bind("blur",this._blur.bind(this)),this.cellInput.bind("blur",this._blur.bind(this))}_blur(){this.deactivate()}_triggerUpdate(){this.trigger("update",{value:this.value()})}activeEditor(){let e=null,t=function(){try{return document.activeElement}catch(e){return document.documentElement.activeElement}}();return this.barElement()===t?e=this.barInput:this.cellElement()===t&&(e=this.cellInput),e}activate(e){let t,n,i,r=this.view.element;return this._active=!0,this._rect=e.rect,this._range=e.range,this.cellInput.position(e.rect),this.cellInput.resize(e.rect),this.cellInput.tooltip(e.tooltip),this.cellInput.activeCell=this.barInput.activeCell=this._range.topLeft(),this.cellInput.activeSheet=this.barInput.activeSheet=this._range._sheet,r&&(t=r.offsetWidth,n=r.querySelector(".k-spreadsheet-scroller"),i=n.offsetWidth-n.clientWidth,this.cellInput.element.style.maxWidth=t-i-parseFloat(this.cellInput.element.style.left)+"px"),this.trigger("activate"),this}deactivate(e){let t=this.cellInput;this._active&&(this._active=!1,e||t.value()===this._value||this.trigger("change",{value:t.value(),range:this._range}),this._rect=null,t.hide(),this.trigger("deactivate"))}enable(e){this.barInput.enable(e),this.cellInput.enable(e)}barElement(){return this.barInput.element}cellElement(){return this.cellInput.element}focus(e){"cell"===(e=e||"cell")?(this.cellInput.element.focus(),this.cellInput.end()):this.barInput.focus()}isActive(){return this._active}isFiltered(){return this.barInput.popup.visible()||this.cellInput.popup.visible()}canInsertRef(e){let t=this.activeEditor();return t&&t.canInsertRef(e)}highlightedRefs(){let e=this.activeEditor(),t=[];return e&&(t=e.highlightedRefs()),t}scale(){this.cellInput.scale()}toggleTooltip(e){var t,n;this.cellInput.toggleTooltip((t=this._rect,n=e,t&&(t.top!==n.top||t.left!==n.left)))}value(e,t){if(void 0===e)return this.barInput.value();null===e&&(e=""),this._value=e,this.barInput.value(e),this.cellInput.value(e),this.barInput.element.classList.toggle("k-spreadsheet-array-formula",Boolean(t))}insertNewline(){this.activeEditor().insertNewline(),this.scale()}select(){this.activeEditor().select()}}const aw=/&/g,sw=/</g,lw=/"/g,cw=/'/g,dw=/>/g;let uw=class{constructor(e,t){this._value=t,this._count=e,this.values=new My(0,e-1,t),this._hidden=new My(0,e-1,0),this.scrollBarSize=w_(),this._refresh()}_resize(e){e>this._count?(this.values.value(this._count,e-1,this._value),this._hidden.value(this._count,e-1,0)):e<this._count&&(this.values.value(e,this._count-1,0),this._hidden.value(e,this._count-1,0)),this._count=e,this._refresh()}adjust(e,t){t<0?(this.values.copy(e-t,this._count-1,e),this._hidden.copy(e-t,this._count-1,e)):(this.values.copy(e,this._count,e+t),this._hidden.copy(e,this._count,e+t),this.values.value(e,e+t-1,this._value),this._hidden.value(e,e+t-1,0)),this._refresh()}toJSON(e,t){let n=[],i=this.values.iterator(0,this._count-1);for(let r=0;r<this._count;r++){let o=i.at(r),a=this._hidden.value(r,r);if(o===this._value&&!a)continue;let s=t[r];if(void 0===s){s=n.length;let i={index:r};i[e]=o,a&&(i.hidden=a),n.push(i),t[r]=s}}return n}fromJSON(e,t){for(let n=0;n<t.length;n++){let i=t[n],r=i.index;void 0===r&&(r=n);let o=i[e];0===o?(this._hidden.value(r,r,i.hidden||this._value),this.value(r,r,0)):this.value(r,r,o)}}hide(e){if(!this.hidden(e)){let t=this.value(e,e);this._hidden.value(e,e,t),this.value(e,e,0)}}hidden(e){return 0!==this._hidden.value(e,e)}includesHidden(e,t){return this._hidden.intersecting(e,t).length>1}nextVisible(e){let t=this._count-1,n=e;for(;++n<=t;)if(!this.hidden(n))return n;return e}nextUntil(e,t){let n=this._count-1,i=e,r=!1;for(;++i<=n;){let e=t(i,r,this.hidden(i));if("number"==typeof e)return e;if(e)break;r=!0}return i-1}nextPage(e,t){return this.index(this.sum(0,e-1)+t)}prevPage(e,t){return this.index(this.sum(0,e)-t)}firstVisible(){let e=this._hidden.first();return 0===e.value?0:e.end+1}lastVisible(){let e=this._hidden.last();return 0===e.value?this._count-1:e.start-1}prevVisible(e){let t=e;for(;--t>=0;)if(!this.hidden(t))return t;return e}prevUntil(e,t){let n=e,i=!1;for(;--n>=0;){let e=t(n,i,this.hidden(n));if("number"==typeof e)return e;if(e)break;i=!0}return n+1}unhide(e){if(this.hidden(e)){let t=this._hidden.value(e,e);this._hidden.value(e,e,0),this.value(e,e,t)}}value(e,t,n){if(void 0===n)return this.values.iterator(e,t).at(0);this.values.value(e,t,n),this._refresh()}sum(e,t){let n=this.values.iterator(e,t),i=0;for(let r=e;r<=t;r++)i+=n.at(r);return i}locate(e,t,n){let i=this.values.iterator(e,t),r=0;for(let o=e;o<=t;o++){if(r+=i.at(o),n(r))return o}return null}visible(e,t){let n=null,i=null,r=!1;t>=this.total+this.scrollBarSize&&(r=!0);let o=this._pixelValues.intersecting(e,t);if(n=o[0],i=o[o.length-1],!n)return{values:this.values.iterator(0,0),offset:0};let a=e-n.start,s=(a/n.value.value|0)+n.value.start,l=a-(s-n.value.start)*n.value.value,c=t-i.start,d=(c/i.value.value|0)+i.value.start;return d>i.value.end&&(d=i.value.end),r&&(l+=i.value.value-(c-(d-i.value.start)*i.value.value)),l=Math.min(-l,0),{values:this.values.iterator(s,d),offset:l}}index(e){let t=0,n=this.values.iterator(0,this._count-1),i=n.at(0);for(;i<e&&t<this._count-1;)i+=n.at(++t);return t}indexVisible(e){let t=this.index(e);return this.hidden(t)&&(t=this.prevVisible(t)),t}_refresh(){let e=0;this._pixelValues=this.values.map((function(t){let n=e;return e+=(t.end-t.start+1)*t.value,new xy(n,e-1,t)})),this.total=e}getState(){return{values:this.values.getState(),hidden:this._hidden.getState(),count:this._count}}setState(e){this.values.setState(e.values),this._hidden.setState(e.hidden);let t=this._count;t>e.count?(this._count=e.count,this._resize(t)):this._refresh()}},hw=class{constructor(e,t,n,i){this._axis=e,this._start=t,this._count=n,this.hasHeader=0===t,this.headerSize=i,this.defaultValue=e._value,this.frozen=n>0}viewSize(e){this._viewSize=e}sum(e,t){return this._axis.sum(e,t-1)}start(){return this.sum(0,this._start)}size(){return this.sum(this._start,this._start+this._count)}index(e,t){return this._axis.index(e+(this.frozen?0:t)-this.headerSize)}indexVisible(e,t){return this._axis.indexVisible(e+(this.frozen?0:t)-this.headerSize)}paneSegment(){let e,t=this.start();return this.hasHeader||(t+=this.headerSize),this.frozen?(e=this.size(),this.hasHeader?e+=this.headerSize:e-=this.headerSize):e=this._viewSize-t,{offset:t,length:e}}visible(e){let t,n=this.start();this.frozen?(t=this.size(),this.hasHeader||(t-=this.headerSize)):(t=this._viewSize-n-this.headerSize,n+=e);let i=this._axis.visible(n,n+t-1);return this.frozen&&(i.offset=0),i.start=n,this.hasHeader&&(i.offset+=this.headerSize,i.start-=this.headerSize),i}contains(e,t){return this.frozen?!(e>this._start+this._count)&&!(t<this._start):t>=this._start}};class pw{constructor(e,t,n,i){this.left=e,this.top=t,this.width=n,this.height=i,this.right=this.left+this.width,this.bottom=this.top+this.height}offset(e,t){return new pw(this.left+e,this.top+t,this.width,this.height)}resize(e,t){return new pw(this.left,this.top,this.width+e,this.height+t)}intersects(e,t){return e instanceof pw?this.intersectsRect(e):this.left<e&&e<this.left+this.width&&this.top<t&&t<this.top+this.height}intersectsRect(e){let t=this;return t.left<=e.right&&e.left<=t.right&&t.top<=e.bottom&&e.top<=t.bottom}toDiv(e){return fb.element("div",{className:e,style:{width:this.width+"px",height:this.height+"px",top:this.top+"px",left:this.left+"px"}})}}class fw{constructor(e,t,n,i,r,o){this.rowCount=n,this.columnCount=i,this._columns=t,this._rows=e,this._headerHeight=r,this._headerWidth=o}_resize(e,t){this.rowCount=e,this.columnCount=t}isAxis(e){let t=(e=e.toRangeRef()).topLeft,n=e.bottomRight;return 0===t.row&&n.row===this.rowCount-1||0===t.col&&n.col===this.columnCount-1}width(e,t){return this._columns.sum(e,t)}height(e,t){return this._rows.sum(e,t)}totalHeight(){return this._rows.total+this._headerHeight}totalWidth(){return this._columns.total+this._headerWidth}index(e,t){return t*this.rowCount+e}cellRef(e){return new $v(e%this.rowCount,e/this.rowCount|0)}rowRef(e){return new Uv(new $v(e,0),new $v(e,this.columnCount-1))}colRef(e){return new Uv(new $v(0,e),new $v(this.rowCount-1,e))}cellRefIndex(e){return this.index(e.row,e.col)}normalize(e){return e instanceof Uv?new Uv(this.normalize(e.topLeft),this.normalize(e.bottomRight)).setSheet(e.sheet,e.hasSheet()):e instanceof Wv?e.map((function(e){return this.normalize(e)}),this):(e instanceof $v&&((e=e.clone()).col=Math.max(0,Math.min(this.columnCount-1,e.col)),e.row=Math.max(0,Math.min(this.rowCount-1,e.row))),e)}rectangle(e){let t=this.normalize(e.topLeft),n=this.normalize(e.bottomRight);return new pw(this.width(0,t.col-1),this.height(0,t.row-1),this.width(t.col,n.col),this.height(t.row,n.row))}pane(e){return new mw(new hw(this._rows,e.row,e.rowCount,this._headerHeight),new hw(this._columns,e.column,e.columnCount,this._headerWidth),this)}rangeDimensions(e){return{rows:this._rows.values.iterator(e.topLeft.row,e.bottomRight.row),columns:this._columns.values.iterator(e.topLeft.col,e.bottomRight.col)}}forEach(e,t){let n=this.normalize(e.topLeft),i=this.normalize(e.bottomRight);for(let e=n.col;e<=i.col;e++)for(let r=n.row;r<=i.row;r++)t(new $v(r,e))}trim(e,t){let n=this.normalize(e.topLeft),i=this.normalize(e.bottomRight),r=n.row,o=n.col;for(let e=n.col;e<=i.col;e++){let a=this.index(n.row,e),s=this.index(i.row,e),l=t.tree.intersecting(a,s);if(l.length){let t=this.cellRef(l[l.length-1].end);r=Math.max(r,t.row),o=e}}return new Uv(e.topLeft,new $v(Math.min(r,e.bottomRight.row),o))}}class mw{constructor(e,t,n){this.rows=e,this.columns=t,this._grid=n,this.headerHeight=e.headerSize,this.headerWidth=t.headerSize,this.hasRowHeader=t.hasHeader,this.hasColumnHeader=e.hasHeader}refresh(e,t){this.columns.viewSize(e),this.rows.viewSize(t);let n=this.columns.paneSegment(),i=this.rows.paneSegment();this.left=n.offset,this.top=i.offset,this.right=n.offset+n.length,this.bottom=i.offset+i.length,this.style={top:i.offset+"px",left:n.offset+"px",height:i.length+"px",width:n.length+"px"}}view(e,t){let n=this.rows.visible(t),i=this.columns.visible(e);return{rows:n,columns:i,rowOffset:n.offset,columnOffset:i.offset,mergedCellLeft:i.start,mergedCellTop:n.start,ref:new Uv(new $v(n.values.start,i.values.start),new $v(n.values.end,i.values.end))}}contains(e){return this.rows.contains(e.topLeft.row,e.bottomRight.row)&&this.columns.contains(e.topLeft.col,e.bottomRight.col)}index(e,t){return this._grid.index(e,t)}boundingRectangle(e){return this._grid.rectangle(e)}cellRefIndex(e){return this._grid.cellRefIndex(e)}scrollBoundaries(e){let t=this.boundingRectangle(e),n={top:Math.max(0,t.top-this.top+(this.hasColumnHeader?0:this.headerHeight)),left:Math.max(0,t.left-this.left+(this.hasRowHeader?0:this.headerWidth)),right:t.right-this.columns._viewSize+this.headerWidth,bottom:t.bottom-this.rows._viewSize+this.headerHeight},i=this.columns.defaultValue/2,r=this.rows.defaultValue/2;return n.scrollTop=n.top-r,n.scrollBottom=n.bottom+r,n.scrollLeft=n.left-i,n.scrollRight=n.right+i,n}}class gw{constructor(e,t){this._grid=e,this._lists=t}indices(e,t,n,i){let r=gw.ascendingComparer;return!1===n&&(r=gw.descendingComparer),t.sortedIndices(this._grid.cellRefIndex(e.topLeft),this._grid.cellRefIndex(e.bottomRight),r,i)}sortBy(e,t,n,i,r){let o=this.indices(e.toColumn(t),n,i,r);for(let t=e.topLeft.col;t<=e.bottomRight.col;t++){let n=this._grid.index(e.topLeft.row,t),i=this._grid.index(e.bottomRight.row,t);for(let e=0;e<this._lists.length;e++)n<this._lists[e].lastRangeStart()&&this._lists[e].sort(n,i,o)}return o}}gw.ascendingComparer=function(e,t){if(null===e&&null===t)return 0;if(null===e)return 1;if(null===t)return-1;let n=typeof e,i=typeof t;if("number"===n)return"number"===i?e-t:-1;if("string"===n)switch(i){case"number":return 1;case"string":return e.localeCompare(t);default:return-1}if("boolean"===n)switch(i){case"number":case"string":return 1;case"boolean":return e-t;default:return-1}if(e instanceof A_)return t instanceof A_?0:1;throw new Error("Cannot compare "+e+" and "+t)},gw.descendingComparer=function(e,t){return null===e&&null===t?0:null===e?1:null===t?-1:gw.ascendingComparer(t,e)};class vw{constructor(e){this._sheet=e}forEachSelectedColumn(e){let t=this._sheet;t.batch((function(){t.select().forEachColumnIndex((function(n,i){e(t,n,i)}))}),{layout:!0,recalc:!0})}forEachSelectedRow(e){let t=this._sheet;t.batch((function(){t.select().forEachRowIndex((function(n,i){e(t,n,i)}))}),{layout:!0,recalc:!0})}includesHiddenColumns(e){return this._sheet._grid._columns.includesHidden(e.topLeft.col,e.bottomRight.col)}includesHiddenRows(e){return this._sheet._grid._rows.includesHidden(e.topLeft.row,e.bottomRight.row)}selectionIncludesHiddenColumns(){return this.includesHiddenColumns(this._sheet.select())}selectionIncludesHiddenRows(){return this.includesHiddenRows(this._sheet.select())}deleteSelectedColumns(){let e=[],t=0;return this.forEachSelectedColumn((function(n,i){if(i-=t,n.isHiddenColumn(i))return;t++;let r=[];e.unshift({index:i,formulas:r,width:n.columnWidth(i)}),n._saveModifiedFormulas(r,(function(){n.deleteColumn(i)}))})),e}deleteSelectedRows(){let e=[],t=0;return this.forEachSelectedRow((function(n,i){if(i-=t,n.isHiddenRow(i))return;t++;let r=[];e.unshift({index:i,formulas:r,height:n.rowHeight(i)}),n._saveModifiedFormulas(r,(function(){n.deleteRow(i)}))})),e}hideSelectedColumns(){this.forEachSelectedColumn((function(e,t){e.hideColumn(t)}));let e=this._sheet,t=e.select().toRangeRef(),n=t.topLeft.col,i=t.bottomRight.col,r=null;for(;;){let t=i<e._columns._count,o=n>=0;if(!o&&!t)break;if(t&&!e.isHiddenColumn(i)){r=i;break}if(o&&!e.isHiddenColumn(n)){r=n;break}n--,i++}null!==r&&(t=new Uv(new $v(0,r),new $v(e._rows._count-1,r)),e.range(t).select())}hideSelectedRows(){this.forEachSelectedRow((function(e,t){e.hideRow(t)}));let e=this._sheet,t=e.select().toRangeRef(),n=t.topLeft.row,i=t.bottomRight.row,r=null;for(;;){let t=i<e._rows._count,o=n>=0;if(!o&&!t)break;if(t&&!e.isHiddenRow(i)){r=i;break}if(o&&!e.isHiddenRow(n)){r=n;break}n--,i++}null!==r&&(t=new Uv(new $v(r,0),new $v(r,e._columns._count-1)),e.range(t).select())}unhideSelectedColumns(){this.forEachSelectedColumn((function(e,t){e.unhideColumn(t)}))}unhideSelectedRows(){this.forEachSelectedRow((function(e,t){e.unhideRow(t)}))}addColumnLeft(){let e,t=this._sheet,n=0;return t.batch((function(){t.select().forEachColumnIndex((function(i){e||(e=i),t.insertColumn(e),++n}))}),{recalc:!0,layout:!0}),{base:e,count:n}}addColumnRight(){let e,t=this._sheet,n=0;return t.batch((function(){t.select().forEachColumnIndex((function(t){e=t+1,++n}));for(let i=0;i<n;++i)t.insertColumn(e)}),{recalc:!0,layout:!0}),{base:e,count:n}}addRowAbove(){let e,t=this._sheet,n=0,i=t.select();return t.batch((function(){i.forEachRowIndex((function(i){e||(e=i),t.insertRow(e),++n}))}),{recalc:!0,layout:!0}),{base:e,count:n}}addRowBelow(){let e,t=this._sheet,n=0;return t.batch((function(){t.select().forEachRowIndex((function(t){e=t+1,++n}));for(let i=0;i<n;++i)t.insertRow(e)}),{recalc:!0,layout:!0}),{base:e,count:n}}}class _w{constructor(e){this._grid=e}rectIsVertical(e,t,n,i){let r=this._grid.rectangle(e.toRangeRef()),o=this._grid.rectangle(t.toRangeRef());return Math.abs(o[i]-r[i])>Math.abs(r[n]-o[n])}autoFillDest(e,t){let n,i,r,o,a,s=e.topLeft,l=e.bottomRight,c=t.row>=s.row,d=t.col>=s.col;if(n=c?d?4:3:d?2:1,4===n)i=s,r=l,a=t.row>r.row||t.col>r.col,a&&(t=new $v(Math.max(t.row,r.row),Math.max(t.col,r.col))),o=this.rectIsVertical(r,t,"right","bottom")?new $v(t.row,r.col):new $v(r.row,t.col);else if(3===n){let e=new $v(s.col,l.row);t.row>l.row&&this.rectIsVertical(e,t,"left","bottom")?(i=s,o=new $v(t.row,l.col)):(i=l,o=new $v(s.row,t.col))}else if(2===n){let e=new $v(s.row,l.col);t.col>l.col&&!this.rectIsVertical(e,t,"right","top")?(i=s,o=new $v(l.row,t.col)):(i=l,o=new $v(t.row,s.col))}else i=l,o=this.rectIsVertical(s,t,"left","top")?new $v(t.row,s.col):new $v(s.row,t.col);return this._grid.normalize(new Uv(i,o))}}class bw{constructor(e,t,n,i){this.rangeGetter=n,this.prevLeft=function(n){var r=i(this.range(n)),o=this.range(t.prevVisible(r.topLeft[e]));return i(o).topLeft[e]},this.nextRight=function(n){var r=i(this.range(n)),o=this.range(t.nextVisible(r.bottomRight[e]));return i(o).bottomRight[e]},this.nextLeft=function(n){var r=i(this.range(n));return t.nextVisible(r.bottomRight[e])},this.prevRight=function(n){var r=i(this.range(n));return t.prevVisible(r.topLeft[e])}}boundary(e,t){this.top=e,this.bottom=t}range(e){return this.rangeGetter(e,this.top,this.bottom)}}class yw{constructor(e){this._sheet=e,this.autoFillCalculator=new _w(e._grid),this.colEdge=new bw("col",this._sheet._grid._columns,this.columnRange.bind(this),this.union.bind(this)),this.rowEdge=new bw("row",this._sheet._grid._rows,this.rowRange.bind(this),this.union.bind(this))}height(e){this._viewPortHeight=e}union(e){return this._sheet.unionWithMerged(e)}columnRange(e,t,n){return this._sheet._ref(t,e,n-t,1)}rowRange(e,t,n){return this._sheet._ref(e,t,1,n-t)}selectionIncludesMergedCells(){return this._sheet.select().contains(this._sheet._mergedCells)}setSelectionValue(e){var t=this._sheet.selection();setTimeout((function(){t.value(e())}))}selectAll(){this._sheet.select(this._sheet._sheetRef)}select(e,t,n){e=this.refForMode(e,t),n&&(e=this._sheet.select().concat(e)),this._sheet.select(e)}refForMode(e,t){var n=this._sheet._grid;switch(t){case"range":e=n.normalize(e);break;case"row":e=n.rowRef(e.row);break;case"column":e=n.colRef(e.col);break;case"sheet":e=this._sheet._sheetRef}return e}startSelection(e,t,n,i,r){if("autofill"===t)this._sheet.startAutoFill();else if(i&&"range"===t){var o=new Uv(this._sheet.activeCell().first(),e);this._sheet.select(o,!1,!1),this._sheet.startSelection(r)}else this._sheet.startSelection(r),this.select(e,t,n)}completeSelection(){this._sheet.completeSelection()}selectForContextMenu(e,t){var n=this._sheet;n._activeDrawing=null,n.select().contains(this.refForMode(e,t))||this.select(e,t)}selectDrawingForContextMenu(e){var t=this._sheet;t._activeDrawing=e,t.triggerChange({selection:!0})}modifySelection(e){var t,n=this.determineDirection(e),i=this._sheet,r=this._viewPortHeight,o=i._grid._rows,a=i._grid._columns,s=i.currentOriginalSelectionRange(),l=i.select().toRangeRef(),c=i.activeCell(),d=s.topLeft.clone(),u=s.bottomRight.clone(),h=new $v(u.row,d.col);switch(this.colEdge.boundary(l.topLeft.row,l.bottomRight.row),this.rowEdge.boundary(l.topLeft.col,l.bottomRight.col),n){case"expand-left":d.col=this.colEdge.prevLeft(d.col),t=d;break;case"shrink-right":d.col=this.colEdge.nextLeft(d.col),t=d;break;case"expand-right":u.col=this.colEdge.nextRight(u.col),t=u;break;case"shrink-left":u.col=this.colEdge.prevRight(u.col),t=u;break;case"expand-up":d.row=this.rowEdge.prevLeft(d.row),t=d;break;case"shrink-down":d.row=this.rowEdge.nextLeft(d.row),t=d;break;case"expand-down":u.row=this.rowEdge.nextRight(u.row),t=u;break;case"shrink-up":u.row=this.rowEdge.prevRight(u.row),t=u;break;case"expand-page-up":d.row=o.prevPage(d.row,r);break;case"shrink-page-up":u.row=o.prevPage(u.row,r);break;case"expand-page-down":u.row=o.nextPage(u.row,r);break;case"shrink-page-down":d.row=o.nextPage(d.row,r);break;case"first-col":d.col=a.firstVisible(),u.col=c.bottomRight.col,t=d;break;case"last-col":u.col=a.lastVisible(),d.col=c.topLeft.col,t=u;break;case"first-row":d.row=o.firstVisible(),u.row=c.bottomRight.row,t=d;break;case"last-row":u.row=o.lastVisible(),d.row=c.topLeft.row,t=u;break;case"last":u.row=o.lastVisible(),u.col=a.lastVisible(),d=c.topLeft,t=u;break;case"first":d.row=o.firstVisible(),d.col=a.firstVisible(),u=c.bottomRight,t=d;break;case"expand-word-right":u.col=a.nextUntil(u.col,ww(i,u,!0)),t=u;break;case"shrink-word-right":d.col=a.nextUntil(h.col,ww(i,h,!0)),t=d;break;case"expand-word-left":d.col=a.prevUntil(h.col,ww(i,h,!0)),t=d;break;case"shrink-word-left":u.col=a.prevUntil(u.col,ww(i,u,!0)),t=u;break;case"expand-word-up":d.row=o.prevUntil(d.row,ww(i,d,!1)),t=d;break;case"shrink-word-up":u.row=o.prevUntil(u.row,ww(i,u,!1)),t=u;break;case"expand-word-down":u.row=o.nextUntil(u.row,ww(i,u,!1)),t=u;break;case"shrink-word-down":d.row=o.nextUntil(d.row,ww(i,d,!1)),t=d}var p=new Uv(d,u);this.union(p).intersects(c)?(t&&i.focus(t),this.updateCurrentSelectionRange(p)):this.modifySelection(n.replace("shrink","expand"))}moveActiveCell(e){var t=this._sheet,n=t.activeCell(),i=n.topLeft,r=n.bottomRight,o=t.originalActiveCell(),a=t._grid._rows,s=t._grid._columns,l=o.row,c=o.col;switch(e){case"left":c=s.prevVisible(i.col);break;case"up":l=a.prevVisible(i.row);break;case"right":c=s.nextVisible(r.col);break;case"down":l=a.nextVisible(r.row);break;case"first-col":c=s.firstVisible();break;case"last-col":c=s.lastVisible();break;case"first-row":l=a.firstVisible();break;case"last-row":l=a.lastVisible();break;case"last":l=a.lastVisible(),c=s.lastVisible();break;case"first":l=a.firstVisible(),c=s.firstVisible();break;case"next-page":l=a.nextPage(r.row,this._viewPortHeight);break;case"prev-page":l=a.prevPage(r.row,this._viewPortHeight);break;case"word-right":c=s.nextUntil(c,ww(t,r,!0));break;case"word-left":c=s.prevUntil(c,ww(t,r,!0));break;case"word-up":l=a.prevUntil(l,ww(t,r,!1));break;case"word-down":l=a.nextUntil(l,ww(t,r,!1))}t.select(new $v(l,c))}navigateInSelection(e){var t,n,i,r=this._sheet,o=r.activeCell().topLeft,a=r.originalActiveCell(),s=r._grid._rows,l=r._grid._columns,c=a.row,d=a.col,u=!1,h=!1,p=o.col,f=o.row;function m(e){t=e.topLeft,n=e.bottomRight}m(r.currentNavigationRange());for(var g=!1,v=!1;!g&&!v;){var _=new $v(c,d);switch(r.singleCellSelection()&&(u=t.eq(_)&&r._sheetRef.topLeft.eq(_),h=n.eq(_)&&r._sheetRef.bottomRight.eq(_),u||(u=l.firstVisible()===d&&s.firstVisible()===c),h||(h=l.lastVisible()===d&&s.lastVisible()===c)),e){case"next":h?v=!0:n.eq(_)?(m(r.nextNavigationRange()),c=t.row,d=t.col):((d=l.nextVisible(p))===p||d>n.col)&&(d=t.col,c=(i=s.nextVisible(c))===c||i>n.row?t.row:i);break;case"previous":u?(v=!0,this._sheet._workbook._view.element.querySelector(".k-spreadsheet-name-editor .k-input-inner").focus()):t.eq(_)?(m(r.previousNavigationRange()),c=n.row,d=n.col):((d=l.prevVisible(p))===p||d<t.col)&&(d=n.col,c=(i=s.prevVisible(c))===c||i<t.row?n.row:i);break;case"lower":n.eq(_)?(m(r.nextNavigationRange()),c=t.row,d=t.col):((c=s.nextVisible(f))===f||c>n.row)&&(c=t.row,d=(i=l.nextVisible(d))===d||i>n.col?t.col:i);break;case"upper":t.eq(_)?(m(r.previousNavigationRange()),c=n.row,d=n.col):((c=s.prevVisible(f))===f||c<t.row)&&(c=n.row,d=(i=l.prevVisible(d))===d||i<t.col?n.col:i);break;default:throw new Error("Unknown entry navigation: "+e)}g=!this.shouldSkip(c,d),p=d,f=c}g&&(r.singleCellSelection()?r.select(new $v(c,d)):r.activeCell(new $v(c,d)))}extendSelection(e,t){var n=this._sheet,i=n._grid;if("autofill"!==t){"range"===t?e=i.normalize(e):"row"===t?e=i.rowRef(e.row).bottomRight:"column"===t&&(e=i.colRef(e.col).bottomRight);var r=n.originalActiveCell().toRangeRef();this.updateCurrentSelectionRange(new Uv(r.topLeft,e))}else this.resizeAutoFill(e)}shouldSkip(e,t){if(this._sheet.isHiddenRow(e)||this._sheet.isHiddenColumn(t))return!0;var n=new $v(e,t),i=!1;return this._sheet.forEachMergedCell((function(e){e.intersects(n)&&!e.collapse().eq(n)&&(i=!0)})),i}resizeAutoFill(e){var t,n,i=this._sheet,r=i.select(),o=i._autoFillOrigin,a=this.autoFillCalculator.autoFillDest(r,e),s=this.punch(r,a);if(!s){var l=i.range(a)._previewFillFrom(i.range(o));l&&(n=l.direction,t=l.hint)}i.updateAutoFill(a,s,t,n)}determineDirection(e){var t=this._sheet.currentSelectionRange(),n=this._sheet.activeCell(),i=n.topLeft.col===t.topLeft.col,r=n.bottomRight.col===t.bottomRight.col,o=n.topLeft.row===t.topLeft.row,a=n.bottomRight.row===t.bottomRight.row;switch(e){case"left":e=r?"expand-left":"shrink-left";break;case"right":e=i?"expand-right":"shrink-right";break;case"up":e=a?"expand-up":"shrink-up";break;case"down":e=o?"expand-down":"shrink-down";break;case"prev-page":e=a?"expand-page-up":"shrink-page-up";break;case"next-page":e=o?"expand-page-down":"shrink-page-down";break;case"word-left":e=r?"expand-word-left":"shrink-word-left";break;case"word-right":e=i?"expand-word-right":"shrink-word-right";break;case"word-up":e=a?"expand-word-up":"shrink-word-up";break;case"word-down":e=o?"expand-word-down":"shrink-word-down"}return e}updateCurrentSelectionRange(e){var t=this._sheet;t.select(t.originalSelect().replaceAt(t.selectionRangeIndex(),e),!1)}punch(e,t){var n;if(t.topLeft.eq(e.topLeft))if(t.bottomRight.row<e.bottomRight.row){var i=this.rowEdge.nextRight(t.bottomRight.row);n=new Uv(new $v(i,e.topLeft.col),e.bottomRight)}else if(t.bottomRight.col<e.bottomRight.col){var r=this.colEdge.nextRight(t.bottomRight.col);n=new Uv(new $v(e.topLeft.row,r),e.bottomRight)}return n}}function ww(e,t,n){var i=e.range(t).value();return function(r,o,a){if(a)return!0;var s=(n?e.range(t.row,r):e.range(r,t.col)).value();return null===i?null!==s&&r:o||null!==s?null===s:(i=null,!1)}}function kw(e){return null==e?null:z_.runtime.serialToDate(e)}var xw=function(e){return e};class Cw{constructor(e){this.options=Object.assign({columns:[]},this.options,Object.keys(e).reduce(((t,n)=>(void 0!==e[n]&&(t[n]=e[n]),t)),{})),this.columns=this._normalizeColumns(this.options.columns),this._sheet(),this._dataSource(),this._header(),this._boundRowsCount=0,this.dataSource.fetch()}_sheet(){this.sheet=this.options.sheet,this._sheetChangeHandler=this._sheetChange.bind(this),this._sheetDeleteRowHandler=this._sheetDeleteRow.bind(this),this._sheetInsertRowHandler=this._sheetInsertRow.bind(this),this.sheet.bind("change",this._sheetChangeHandler).bind("afterDeleteRow",this._sheetDeleteRowHandler).bind("afterInsertRow",this._sheetInsertRowHandler)}_sheetInsertRow(e){void 0!==e.index&&this.dataSource.insert(Math.max(e.index-1,0),{})}_sheetDeleteRow(e){if(void 0!==e.index){var t=this.dataSource,n=t.view()[e.index-1];n&&t.remove(n)}}_header(){this.sheet.batch(function(){this.columns.forEach(function(e,t){this.sheet.range(0,t).value(e.title)}.bind(this))}.bind(this))}_sheetChange(e){if(!e.insertRow&&!e.deleteRow&&e.recalc&&e.ref&&e.isValue){var t,n,i,r,o,a=this.dataSource,s=a.view(),l=this.columns,c=[],d=this.sheet,u=function(e){for(var t,i=0,o=(e=e.toRangeRef()).topLeft.row;o<=e.bottomRight.row;o++){(t=s[o-1])||(t=a.insert(o-1,{}),s=a.view());for(var d=0,u=e.topLeft.col;u<=e.bottomRight.col&&u<l.length;u++){var h=c[r][i][d++];t.set(l[u].field,n[u](h))}i++}};for(a.reader.model&&(t=a.reader.model.fields),!l.length&&s.length&&(l=Object.keys(s[0].toJSON())),n=l.map((function(e){var n=e.field;return n&&t&&t[n]&&"date"===t[n].type?kw:xw})),this._skipRebind=!0,(i=d._grid.normalize(e.ref))instanceof Wv||(i=new Wv([i])),(o=i.refs).forEach((function(e){c.push(d.range(e).values())})),r=0;r<o.length;r++)o[r].forEach(u);this._boundRowsCount=a.view().length,this._skipRebind=!1}}_normalizeColumns(e){return e.map((function(e){var t=e.field||e;return{field:t,title:e.title||t}}))}_dataSource(){var e=this.options.dataSource;e=Array.isArray(e)?{data:e}:e,this.dataSource&&this._changeHandler?this.dataSource.unbind("change",this._changeHandler).unbind("progress",this._progressHandler).unbind("error",this._errorHandler):(this._changeHandler=this._change.bind(this),this._progressHandler=this._requestStart.bind(this),this._errorHandler=this._error.bind(this)),this.dataSource=this.options.sheet.createSheetDataSource?.(e).bind("change",this._changeHandler).bind("progress",this._progressHandler).bind("error",this._errorHandler)}_error(){this._progress(!1)}_requestStart(){this._progress(!0)}_progress(e){this.sheet.trigger("progress",{toggle:e})}_change(){if(!this._skipRebind&&!this.sheet.trigger("dataBinding")){var e=this.dataSource.view(),t=this.columns;!t.length&&e.length&&(this.columns=t=this._normalizeColumns(Object.keys(e[0].toJSON())),this._header());var n=t.map((function(e){return v_(e.field)}));this.sheet.batch(function(){for(var t=Math.max(e.length,this._boundRowsCount,this.sheet._grid.rowCount-1),i=0;i<t;i++)for(var r=0;r<n.length;r++){var o=e[i]?n[r](e[i]):null;this.sheet.range(i+1,r).value(o)}}.bind(this)),this._boundRowsCount=e.length,this._progress(!1),this.sheet.trigger("dataBound")}}destroy(){this.dataSource.unbind("change",this._changeHandler).unbind("progress",this._progressHandler).unbind("error",this._errorHandler),this.sheet.unbind("change",this._sheetChangeHandler).unbind("deleteRow",this._sheetDeleteRowHandler).unbind("insertRow",this._sheetInsertRowHandler)}}const Sw=function(){function e(){return Gh(new Date)}return{dayOfWeek:jh,getDate:Gh,isToday:function(t){return Gh(t).getTime()===e().getTime()},addDays:Vh,today:e,firstDayOfMonth:qh}}(),Tw={or:{concat:(e,t)=>n=>e(n)||t(n),identity:()=>!1},and:{concat:(e,t)=>n=>e(n)&&t(n),identity:()=>!0}},Dw={contains:(e,t)=>(e||"").indexOf(t)>=0,doesnotcontain:(e,t)=>-1===(e||"").indexOf(t),doesnotendwith:(e,t)=>(e||"").indexOf(t,(e||"").length-(t||"").length)<0,doesnotstartwith:(e,t)=>-1===(e||"").lastIndexOf(t,0),endswith:(e,t)=>(e||"").indexOf(t,(e||"").length-(t||"").length)>=0,eq:(e,t)=>e===t,gt:(e,t)=>e>t,gte:(e,t)=>e>=t,isempty:e=>""===e,isnotempty:e=>""!==e,isnotnull:e=>x_(e),isnull:e=>(e=>!x_(e))(e),lt:(e,t)=>e<t,lte:(e,t)=>e<=t,neq:(e,t)=>e!=t,startswith:(e,t)=>0===(e||"").lastIndexOf(t,0)},Aw=/^\/Date\((.*?)\)\/$/,Mw=({field:e,ignoreCase:t,value:n,operator:i,accentFoldingFiltering:r})=>{e=x_(e)?e:e=>e,t=!x_(t)||t;const o=Ew(T_(e)?e:v_(e,!0),n,t,r);n=((e,t,n)=>{if(null!=e&&S_(e)){const i=Aw.exec(e);if(i)return new Date(+i[1]).getTime();if(t)return n?e.toLocaleLowerCase(n):e.toLowerCase()}else if(null!=e&&C_(e))return e.getTime();return e})(n,t,r);const a=T_(i)?i:Dw[i];return e=>a(o(e),n,t)},Ew=(e,t,n,i)=>{if(!x_(t))return e;let r=e;if(S_(t)){const o=Aw.exec(t);o?t=new Date(+o[1]):r=t=>{const r=e(t);return"string"==typeof r&&n?i?r.toLocaleLowerCase(i):r.toLowerCase():(e=>!isNaN(e-parseFloat(e)))(r)?r+"":r}}return C_(t)?e=>{const t=r(e);return C_(t)?t.getTime():t}:r},Iw=function(e){const t=e.accentFoldingFiltering,n=Tw[e.logic||"and"];return e.filters.filter(x_).map((e=>{const n=x_(t)?__({},e,{accentFoldingFiltering:t}):e;return x_(e.filters)?Iw(n):Mw(n)})).reduce(n.concat,n.identity)};let zw={};const Pw=z_.runtime.dateToSerial,Hw=z_.runtime.serialToDate;class Fw{prepare(){}value(e){return e.value}matches(){throw new Error("The 'matches' method is not implemented.")}toJSON(){throw new Error("The 'toJSON' method is not implemented.")}}Fw.create=function(e){var t=e.filter;if(!t)throw new Error("Filter type not specified.");var n=zw[t.charAt(0).toUpperCase()+t.substring(1)+"Filter"];if(!n)throw new Error("Filter type not recognized.");return new n(e)};class Rw extends Fw{constructor(e){super(e),this._values=[],this._dates=[],this._blanks=!1,void 0!==e.values&&(this._values=e.values),void 0!==e.blanks&&(this._blanks=e.blanks),void 0!==e.dates&&(this._dates=e.dates)}value(e){var t=e.value;this._dates.length>0&&e.format&&"number"==typeof t&&("date"===Sb.type(t,e.format)&&(t=Hw(t)));return t}matches(e){return null==e?this._blanks:e instanceof Date?this._dates.some((function(t){return!(t.year!==e.getFullYear()||void 0!==t.month&&t.month!==e.getMonth()||void 0!==t.day&&t.day!==e.getDate()||void 0!==t.hours&&t.hours!==e.getHours()||void 0!==t.minutes&&t.minutes!==e.getMinutes()||void 0!==t.seconds&&t.seconds!==e.getSeconds())})):this._values.indexOf(e)>=0}toJSON(){return{filter:"value",blanks:this._blanks,values:this._values.slice(0)}}}class Lw extends Fw{constructor(e){if(super(e),this._logic="and",void 0!==e.logic&&(this._logic=e.logic),void 0===e.criteria)throw new Error("Must specify criteria.");this._criteria=e.criteria,this._matches=Iw({logic:this._logic,filters:this._criteria,accentFoldingFiltering:I_().name})}matches(e){return null!==e&&this._matches(e)}value(e){var t=e.value,n=this._criteria[0].value,i=n instanceof Date?"date":typeof n,r=typeof t;return e.format&&(r=Sb.type(t,e.format)),r!=i?"string"==i&&(e.format&&(t=Sb.text(t,e.format)),t+=""):"date"==r&&(t=Hw(t)),t}toJSON(){return{filter:"custom",logic:this._logic,criteria:this._criteria}}}class Bw extends Fw{constructor(e){super(e),this._type=e.type,this._value=e.value,this._values=[]}prepare(e){var t=e.map(this.value).sort().filter((function(e,t,n){return 0===t||e!==n[t-1]}));"topNumber"===this._type||"topPercent"==this._type?t.sort((function(e,t){return t-e})):t.sort((function(e,t){return e-t}));var n=this._value;"topPercent"!==this._type&&"bottomPercent"!==this._type||(n=t.length*n/100|0),this._values=t.slice(0,n)}matches(e){return this._values.indexOf(e)>=0}toJSON(){return{filter:"top",type:this._type,value:this._value}}}class Ow extends Fw{constructor(e){if(super(e),this._type=e.type,this._predicate=this[e.type],"function"!=typeof this._predicate)throw new Error("DynamicFilter type '"+e.type+"' not recognized.")}value(e){var t=e.value;e.format&&("date"===Sb.type(t,e.format)&&(t=Hw(t)));return t}prepare(e){for(var t=0,n=0,i=0;i<e.length;i++){var r=this.value(e[i]);"number"==typeof r&&(t+=r,n++)}this._average=n>0?t/n:0}matches(e){return this._predicate(e)}aboveAverage(e){return e instanceof Date&&(e=Pw(e)),"number"==typeof e&&e>this._average}belowAverage(e){return e instanceof Date&&(e=Pw(e)),"number"==typeof e&&e<this._average}tomorrow(e){if(e instanceof Date){var t=Sw.addDays(Sw.today(),1);return Sw.getDate(e).getTime()===t.getTime()}return!1}today(e){return e instanceof Date&&Sw.isToday(e)}yesterday(e){if(e instanceof Date){var t=Sw.addDays(Sw.today(),-1);return Sw.getDate(e).getTime()===t.getTime()}return!1}nextWeek(e){return Ww(Sw.addDays(Sw.today(),7),e)}thisWeek(e){return Ww(Sw.today(),e)}lastWeek(e){return Ww(Sw.addDays(Sw.today(),-7),e)}nextMonth(e){return Uw(e,1)}thisMonth(e){return Uw(e,0)}lastMonth(e){return Uw(e,-1)}nextQuarter(e){if(e instanceof Date){var t=Sw.today(),n=Nw(e)-Nw(t);return 1===n&&t.getFullYear()===e.getFullYear()||-3==n&&t.getFullYear()+1===e.getFullYear()}return!1}thisQuarter(e){if(e instanceof Date){var t=Sw.today();return 0===Nw(e)-Nw(t)&&t.getFullYear()===e.getFullYear()}return!1}lastQuarter(e){if(e instanceof Date){var t=Sw.today(),n=Nw(t)-Nw(e);return 1===n&&t.getFullYear()===e.getFullYear()||-3==n&&t.getFullYear()-1===e.getFullYear()}return!1}nextYear(e){return $w(e,1)}thisYear(e){return $w(e,0)}lastYear(e){return $w(e,-1)}yearToDate(e){if(e instanceof Date){var t=Sw.today();return e.getFullYear()===t.getFullYear()&&e<=t}return!1}toJSON(){return{filter:"dynamic",type:this._type}}}zw={Filter:Fw,ValueFilter:Rw,CustomFilter:Lw,TopFilter:Bw},[1,2,3,4].forEach((function(e){Ow.prototype["quarter"+e]=function(t){return t instanceof Date&&Nw(t)===e}}));const Vw=()=>{I_().calendar.months.format.wide.forEach((function(e,t){Ow.prototype[e.toLowerCase()]=function(e){return e instanceof Date&&e.getMonth()===t}}))};function Nw(e){var t=e.getMonth()+1;return t>=1&&t<=3?1:t>=4&&t<=6?2:t>=7&&t<=9?3:4}function $w(e,t){if(e instanceof Date){var n=Sw.today();return n.setFullYear(n.getFullYear()+t),n.getFullYear()===e.getFullYear()}return!1}function Uw(e,t){if(e instanceof Date){var n=Sw.firstDayOfMonth(Sw.today());return n.setMonth(n.getMonth()+t,1),n.getTime()===Sw.firstDayOfMonth(e).getTime()}return!1}function Ww(e,t){if(t instanceof Date){var n=Sw.dayOfWeek(Sw.getDate(e),1),i=Sw.dayOfWeek(Sw.getDate(t),1);return n.getTime()===i.getTime()}return!1}var jw;let qw=class{constructor(e){this._sheet=e,this.selection=jv.toRangeRef(),this.originalSelection=jv.toRangeRef(),this._activeCell=jv.toRangeRef(),this.originalActiveCell=jv}currentSelectionRange(){return this.selection.rangeAt(this.selectionRangeIndex).toRangeRef()}currentOriginalNavigationRange(){return this.originalSelection.rangeAt(this.selectionRangeIndex).toRangeRef()}currentNavigationRange(){return this.singleCellSelection()?this._sheet._sheetRef:this.selection.rangeAt(this.selectionRangeIndex).toRangeRef()}nextNavigationRange(){return this.singleCellSelection()||(this.selectionRangeIndex=this.selection.nextRangeIndex(this.selectionRangeIndex)),this.currentNavigationRange()}previousNavigationRange(){return this.singleCellSelection()||(this.selectionRangeIndex=this.selection.previousRangeIndex(this.selectionRangeIndex)),this.currentNavigationRange()}activeCell(e){return e&&(this.originalActiveCell=e.first(),this._activeCell=this._sheet.unionWithMerged(e.toRangeRef()),this._sheet.focus(e),this._sheet.triggerChange({activeCell:!0,selection:!0})),this._activeCell}select(e,t,n,i){if(e){if(e.eq(this.originalSelection))return;if(this._sheet.triggerSelect(new Wy(e,this._sheet)),this.originalSelection=e,this.selection=t,!1!==n){if(e.isCell())this._sheet.forEachMergedCell(e,(function(t){e=t.topLeft})),this.activeCell(e);else{if(e=this.selection.lastRange(),i&&i._sheet===this._sheet&&i.panes[0]){var r,o,a,s,l,c,d=i.panes;for(r=0;r<d.length&&(!(o=d[r])._currentView||(a=o._currentView.rows.values,s=o._currentView.columns.values,l=new Uv(new $v(a.start,s.start),new $v(a.end,s.end)),(c=e.intersect(l))===Vv));r++);c&&c!==Vv&&(e=c)}this.activeCell(e.first())}this.selectionRangeIndex=this.selection.size()-1}else this._sheet.triggerChange({selection:!0})}return this.selection}singleCellSelection(){return this._activeCell.eq(this.selection)}},Gw={};class Kw extends iw{constructor(){super(),this.events=["changing","commandRequest","afterInsertRow","afterDeleteRow","insertRow","insertColumn","deleteRow","deleteColumn","hideRow","hideColumn","unhideRow","unhideColumn","select","dataBinding","dataBound","progress"],this.createSheetDataSource=Array.from(arguments).pop(),this._reinit.apply(this,arguments)}activeCellCustomEditor(){let e=this.activeCell().first();if(this.range(e).enable()){let t,n=this.validation(e),i=this._properties.get("editor",this._grid.cellRefIndex(e));return null!=i?t=Gw[i]:n&&n.showButton&&(i="_validation_"+n.dataType,t=Gw[i]),"function"==typeof t&&(t=Gw[i]=t()),t}}_reinit(e,t,n,i,r,o,a){a=a||{},this._defaultCellStyle={background:a.background,color:a.color,fontFamily:a.fontFamily,fontSize:a.fontSize,italic:a.italic,bold:a.bold,underline:a.underline,wrap:a.wrap,verticalAlign:a.verticalAlign,textAlign:a.textAlign},this._rows=new uw(e,n),this._columns=new uw(t,i),this._filteredRows=new My(0,e-1,!1),this._mergedCells=[],this._frozenRows=0,this._frozenColumns=0,this._suspendChanges=!1,this._filter=null,this._showGridLines=!0,this._gridLinesColor=null,this._grid=new fw(this._rows,this._columns,e,t,r,o),this._sheetRef=this._grid.normalize(qv),this._properties=new Fy(e,t,this._defaultCellStyle),this._sorter=new gw(this._grid,this._properties.sortable()),this._viewSelection=new qw(this),this._editSelection=new qw(this),this._formulaSelections=[],this._drawings=[]}resize(e,t){e=Math.max(e,1),t=Math.max(t,1);var n=this._rows._count,i=this._columns._count;e<n&&this.range(e,0,n-e,i).clear(),t<i&&this.range(0,t,n,i-t).clear(),this._rows._resize(e),this._columns._resize(t),this._grid._resize(e,t),this._properties._resize(e,t),this._sheetRef=this._grid.normalize(qv),e>n&&(this.range(n,0,e-n,t).clear(),this._filteredRows.value(n,e-1,!1)),t>i&&this.range(0,i,e,t-i).clear(),this.triggerChange({layout:!0})}_resizeAddRow(e){this.resize(this._rows._count+(e||1),this._columns._count)}_resizeAddColumn(e){this.resize(this._rows._count,this._columns._count+(e||1))}_resizeDeleteRow(e){this._resizeAddRow(-(e||1))}_resizeDeleteColumn(e){this._resizeAddColumn(-(e||1))}_resizeForJSON(e){for(var t=e.length,n=0,i=0;i<e.length;++i){var r=e[i];if(null!=r.index&&(t=Math.max(t,r.index+1)),r.cells){n=Math.max(n,r.cells.length);for(var o=0;o<r.cells.length;++o){var a=r.cells[o];null!=a.index&&(n=Math.max(n,a.index+1))}}}this.resize(Math.max(t,this._rows._count),Math.max(n,this._columns._count))}_selectionState(){return this._inEdit?this._editSelection:this._viewSelection}navigator(){return this._navigator||(this._navigator=new yw(this)),this._navigator}axisManager(){return this._axisManager||(this._axisManager=new vw(this)),this._axisManager}_name(e){return e?(this._sheetName=e,this):this._sheetName}name(){return this._name()}_state(e){return e?(this._sheetState=e,this):this._sheetState||"visible"}state(){return this._state()}_property(e,t,n){return void 0===t?e():(e(t),this.triggerChange(n))}_field(e,t,n){return void 0===t?this[e]:(this[e]=t,this.triggerChange(n))}suspendChanges(e){return void 0===e?this._suspendChanges:(this._suspendChanges=e,this)}triggerChange(e){return this._suspendChanges?e&&e.isValue&&(this._valueChanged=!0):this.trigger("change",e),this}triggerSelect(e){this.trigger("select",{range:e})}setDataSource(e,t){this.dataSourceBinder&&this.dataSourceBinder.destroy(),this.dataSourceBinder=new Cw({dataSource:e,sheet:this,columns:t,createSheetDataSource:this.createSheetDataSource}),this.dataSource=this.dataSourceBinder.dataSource}hideColumn(e){if(!this.trigger("hideColumn",{index:e}))return this._property(this._columns.hide.bind(this._columns),e,{layout:!0})}unhideColumn(e){if(!this.trigger("unhideColumn",{index:e}))return this._property(this._columns.unhide.bind(this._columns),e,{layout:!0})}isHiddenColumn(e){return this._grid._columns.hidden(e)}_copyRange(e,t){var n=this._grid,i=n.rowCount,r=n.normalize(e.topLeft),o=n.normalize(e.bottomRight),a=r.col*i+r.row,s=o.col*i+o.row,l=t.col*i+t.row;this._properties.copy(a,s,l)}_saveModifiedFormulas(e,t){var n=jw;jw=e;var i=t();return jw=n,i}_restoreModifiedFormulas(e){var t=this._workbook;e.forEach((function(e){var n,i=t.sheetByName(e.sheet);e instanceof z_.runtime.Formula&&(n=i._grid.cellRefIndex(e),i._properties.set("formula",n,n,e)),e instanceof Ny.Validation&&(n=i._grid.cellRefIndex(e),i._properties.set("validation",n,n,e))}))}_adjustReferences(e,t,n,i){if(this._mergedCells=i.reduce((function(i,r){return(r=r.adjust(null,null,null,null,"row"===e,t,n))instanceof Uv&&i.push(r),i}),[]),this._workbook){var r=this._name();this._workbook._sheets.forEach((function(i){i._forFormulas((function(i){var o=i.adjust(r,e,t,n);o&&jw&&jw.push(o)})),i._forValidations((function(i){var o=i.adjust(r,e,t,n);o&&jw&&jw.push(o)}))})),this._workbook.adjustNames(r,"row"===e,t,n)}var o=this.select();(o=o.adjust(null,null,null,null,"row"===e,t,n))!==Vv&&this.select(o),("col"===e?this._columns:this._rows).adjust(t,n),"row"===e&&(n<0?this._filteredRows.copy(t-n,this._rows._count-1,t):(this._filteredRows.copy(t,this._rows._count,t+n),this._filteredRows.value(t,t+n-1,!1))),this._drawings.forEach((function(i){i.topLeftCell&&(i.topLeftCell=i.topLeftCell.adjust(null,null,null,null,"row"===e,t,n))}))}_forFormulas(e){var t=this._properties.get("formula").values(),n=t.length;t.forEach((function(t,i){e.call(this,t.value,i,n)}),this)}_forValidations(e){this._properties.get("validation").values().forEach((function(t){e.call(this,t.value)}),this)}insertRow(e,t){if(!this.trigger("insertRow",{index:e}))return this.batch((function(){this._resizeAddRow();var t=this._grid,n=t.columnCount,i=t.rowCount;if(e+1!==i){var r=this.frozenRows();e<r&&this.frozenRows(r+1);for(var o=this._mergedCells.slice(),a=0;a<n;a++){var s=new Uv(new $v(e,a),new $v(e,a)),l=t.normalize(s.topLeft),c=t.normalize(s.bottomRight),d=new Uv(new $v(l.row,l.col),new $v(i-2,c.col));this._copyRange(d,new $v(l.row+1,l.col)),new Wy(s,this).clear({clearAll:!0,keepBorders:!0})}this._adjustReferences("row",e,1,o)}}),{recalc:!0,layout:!0,insertRow:{index:e},ref:new Uv(new $v(e,0),new $v(1/0,1/0))}),t||this.trigger("afterInsertRow",{index:e}),this}isEnabledRow(e){var t=new Uv(new $v(e,0),new $v(e,this._grid.columnCount));return new Wy(t,this).enable()}deleteRow(e,t){return this.isEnabledRow(e)?this.trigger("deleteRow",{index:e})?void 0:(this.batch((function(){var t=this._grid,n=t.columnCount,i=this.frozenRows();e<i&&this.frozenRows(i-1);for(var r=this._mergedCells.slice(),o=0;o<n;o++){var a=new Uv(new $v(e,o),new $v(e,o));new Wy(a,this).clear({clearAll:!0,keepBorders:!0});var s=t.normalize(a.topLeft),l=t.normalize(a.bottomRight),c=new Uv(new $v(s.row+1,s.col),new $v(1/0,l.col));this._copyRange(c,s);var d=t.normalize(c.bottomRight);new Wy(new Uv(d,d),this).clear()}this._adjustReferences("row",e,-1,r),this._resizeDeleteRow()}),{recalc:!0,layout:!0,deleteRow:{index:e},ref:new Uv(new $v(e,0),new $v(1/0,1/0))}),t||this.trigger("afterDeleteRow",{index:e}),this):this}insertColumn(e){if(!this.trigger("insertColumn",{index:e}))return this.batch((function(){this._resizeAddColumn();var t=this._grid,n=t.columnCount;if(e+1!==n){var i=this.frozenColumns();e<i&&this.frozenColumns(i+1);for(var r=this._mergedCells.slice(),o=n;o>=e;o--){var a=new Uv(new $v(0,o),new $v(1/0,o));if(new Wy(a,this).clear({clearAll:!0,keepBorders:!0}),o===e)break;var s=t.normalize(a.topLeft),l=t.normalize(a.bottomRight),c=new Uv(new $v(s.row,s.col-1),new $v(l.row,l.col-1));this._copyRange(c,s)}this._adjustReferences("col",e,1,r)}}),{recalc:!0,layout:!0,insertColumn:{index:e},ref:new Uv(new $v(0,e),new $v(1/0,1/0))}),this}isEnabledColumn(e){var t=new Uv(new $v(0,e),new $v(1/0,e));return new Wy(t,this).enable()}deleteColumn(e){return this.isEnabledColumn(e)?this.trigger("deleteColumn",{index:e})?void 0:(this.batch((function(){var t=this._grid,n=t.columnCount,i=this.frozenColumns();e<i&&this.frozenColumns(i-1);for(var r=this._mergedCells.slice(),o=e;o<n;o++){var a=new Uv(new $v(0,o),new $v(1/0,o));if(new Wy(a,this).clear({clearAll:!0,keepBorders:!0}),o===n-1)break;var s=t.normalize(a.topLeft),l=t.normalize(a.bottomRight),c=new Uv(new $v(s.row,s.col+1),new $v(l.row,l.col+1));this._copyRange(c,s)}this._adjustReferences("col",e,-1,r),this._resizeDeleteColumn()}),{recalc:!0,layout:!0,deleteColumn:{index:e},ref:new Uv(new $v(0,e),new $v(1/0,1/0))}),this):this}_filterRow(e){this._rows.hide(e),this._filteredRows.value(e,e,!0),this.triggerChange({layout:!0})}hideRow(e){if(!this.trigger("hideRow",{index:e}))return this._property(this._rows.hide.bind(this._rows),e,{layout:!0})}unhideRow(e){if(!this.trigger("unhideRow",{index:e}))return this._property(this._rows.unhide.bind(this._rows),e,{layout:!0})}isHiddenRow(e){return this._grid._rows.hidden(e)}isFilteredRow(e){return this._filteredRows.value(e)}columnWidth(e,t){return this._property(this._columns.value.bind(this._columns,e,e),t,{layout:!0})}rowHeight(e,t){return this._property(this._rows.value.bind(this._rows,e,e),t,{layout:!0})}frozenRows(e){return this._field("_frozenRows",e,{layout:!0})}frozenColumns(e){return this._field("_frozenColumns",e,{layout:!0})}showGridLines(e){return this._field("_showGridLines",e,{layout:!0})}gridLinesColor(e){return this._field("_gridLinesColor",e,{layout:!0})}_ref(e,t,n,i){var r=null;return e instanceof Ov?e:e instanceof Wy?e._ref.toRangeRef():("string"==typeof e?r=z_.parseReference(e):(n||(n=1),i||(i=1),r=new Uv(new $v(e,t),new $v(e+n-1,t+i-1))),r)}range(e,t,n,i){return new Wy(this._ref(e,t,n,i),this)}_getMergedCells(e){var t=this._grid,n={},i={},r=!1;return this.forEachMergedCell(e,(function(o){var a=o.topLeft;t.forEach(o,(function(t){a.eq(t)?(n[t.print()]=o,r=!0):e.contains(t)&&(i[t.print()]=a,r=!0)}))})),{primary:n,secondary:i,hasMerged:r}}forEachMergedCell(e,t){var n=!1;void 0===t&&(t=e,n=!0),this._mergedCells.forEach((function(i){(n||i.intersects(e))&&t(i)}))}forEachFilterHeader(e,t){var n=!1;if(void 0===t&&(t=e,n=!0),this._filter){var i=[];this._filter.ref.forEachColumn((function(t){(n||t.intersects(e))&&i.push(t.topLeft)})),this._mergedCells.forEach((function(e){i=i.map((function(t){return e.intersects(t)?e:t}))})),i.reduce((function(e,t){return e.indexOf(t)<0&&e.push(t),e}),[]).forEach(t)}}forEach(e,t){var n=this;function i(e){e instanceof Uv||(e=e.toRangeRef());var i,r,o=n._grid.normalize(e.topLeft),a=n._grid.normalize(e.bottomRight);function s(e){t(r++,i,e)}for(i=o.col;i<=a.col;i++){r=o.row;var l=n._grid.index(r,i),c=n._grid.index(a.row,i);n._properties.forEach(l,c,s)}}e instanceof Uv||(e=n._ref(e)),e instanceof Wv?e.forEach(i):i(e)}startResizing(e){this._initialPosition=e,this._resizeInProgress=!0}startAutoFill(){this._autoFillInProgress=!0;var e=this.select();this._autoFillOrigin=e,this._autoFillDest=e,this.triggerChange({selection:!0})}updateAutoFill(e,t,n,i){this._autoFillDest=e,this._autoFillPunch=t,this._autoFillHint=n,this._autoFillDirection=i,this.triggerChange({selection:!0})}autoFillRef(){return this._autoFillDest}autoFillPunch(){return this._autoFillPunch}autoFillInProgress(){return this._autoFillInProgress}resizingInProgress(){return this._resizeInProgress}draggingInProgress(){return this._draggingInProgress}completeResizing(){if(this._resizeInProgress){this._resizeInProgress=!1;var e=this.resizeHintPosition();if(this._initialPosition&&e){var t=this.resizeHandlePosition();t.col!==-1/0?this.trigger("commandRequest",{command:"ColumnWidthCommand",options:{target:t.col,value:this.columnWidth(t.col)-(this._initialPosition.x-e.x)}}):this.trigger("commandRequest",{command:"RowHeightCommand",options:{target:t.row,value:this.rowHeight(t.row)-(this._initialPosition.y-e.y)}})}else this.trigger("change",{resize:!0})}}_visualRange(e){for(var t=this._mergedCells,n=t.length;--n>=0;)if(t[n].intersects(e))return this.range(t[n]);return this.range(e)}_renderComment(e){var t=null;if(e){var n=this._visualRange(e);t=n.comment(),e=n._ref.toRangeRef().topLeft}t?this._commentRef&&e.eq(this._commentRef)||(this._commentRef=e,this.trigger("change",{comment:!0})):this._commentRef&&(this._commentRef=null,this.trigger("change",{comment:!0}))}resizeHandlePosition(){return this._resizeHandlePosition}resizeHintPosition(e){return void 0!==e&&(this._resizeHintPosition=e,this.trigger("change",{resize:!0})),this._resizeHintPosition}removeResizeHandle(){this._resizeHandlePosition&&(this._resizeHintPosition=void 0,this._resizeHandlePosition=void 0,this._initialPosition=void 0,this.trigger("change",{resize:!0}))}positionResizeHandle(e){this._resizeHandlePosition=e,this.trigger("change",{resize:!0})}startDragging(e){this._draggingInProgress=e}completeDragging(){var e=this._draggingInProgress;if(e){this._draggingInProgress=null;var t=e.drawing;if(t.eq(e.copy))return;if(t.topLeftCell){var n=this.drawingBoundingBox(t),i=this._rows.indexVisible(n.top),r=this._columns.indexVisible(n.left),o=new $v(i,r),a=this.refBoundingBox(o);t.offsetX=n.left-a.left,t.offsetY=n.top-a.top,t.topLeftCell=o,this.triggerChange({dragging:!0})}this.trigger("commandRequest",{command:"DrawingUpdateCommand",options:{sheet:this,drawing:t,previous:e.copy}})}}startSelection(e){this.frozenRows()||this.frozenColumns()?this._currentView=null:e&&e._sheet===this&&(this._currentView=e),this._selectionInProgress=!0}completeSelection(){if(this._selectionInProgress&&(this._selectionInProgress=!1,this._resizeHintPosition=void 0,this.trigger("change",{selection:!0})),this._autoFillInProgress){this._autoFillInProgress=!1;var e=this._autoFillDest,t=this._autoFillOrigin;this._autoFillPunch?this.trigger("commandRequest",{command:"ClearContentCommand",options:{operatingRange:this.range(this._autoFillPunch)}}):e.eq(t)?this.triggerChange({selection:!0}):this.trigger("commandRequest",{command:"AutoFillCommand",options:{operatingRange:this.range(e),origin:this.range(t)}}),this._autoFillDest=null,this._autoFillPunch=null,this._autoFillOrigin=null,this.select(e)}}selectionInProgress(){return this._selectionInProgress}select(e,t){var n,i=this._selectionState();return e&&(e=this._ref(e),e=this._grid.normalize(e),n=this._grid.isAxis(e)?e:this.unionWithMerged(e)),i.select(e,n,t,this._currentView)}originalSelect(){return this._selectionState().originalSelection}currentSelectionRange(){return this._selectionState().currentSelectionRange()}currentOriginalSelectionRange(){return this._selectionState().currentOriginalNavigationRange()}currentNavigationRange(){return this._selectionState().currentNavigationRange()}nextNavigationRange(){return this._selectionState().nextNavigationRange()}previousNavigationRange(){return this._selectionState().previousNavigationRange()}selectionRangeIndex(){return this._selectionState().selectionRangeIndex}activeCell(e){return this._selectionState().activeCell(e)}originalActiveCell(){return this._selectionState().originalActiveCell}singleCellSelection(){return this._selectionState().singleCellSelection()}unionWithMerged(e){var t=this._mergedCells;return e.map((function(e){return e.toRangeRef().union(t)}))}trim(e){var t=[],n=this._grid;return this._properties.forEachProperty((function(i){t.push(n.trim(e,i.list))})),this.unionWithMerged(e.topLeft.toRangeRef().union(t))}focus(e){if(!e){var t=this._focus;return this._focus=null,t}this._focus=e.toRangeRef()}activeCellSelection(){return new Wy(this._grid.normalize(this.activeCell()),this)}selection(){return new Wy(this._grid.normalize(this._selectionState().selection),this)}selectedHeaders(){var e=this.select(),t={},n={},i=!1,r=!1,o=this._grid.rowCount-1,a=this._grid.columnCount-1;return e.forEach((function(e){var s,l="partial",c="partial",d=(e=e.toRangeRef()).bottomRight,u=e.topLeft,h=u.col<=0&&d.col>=a,p=u.row<=0&&d.row>=o;if(p&&(r=!0,c="full"),h&&(i=!0,l="full"),!p)for(s=u.row;s<=d.row;s++)"full"!==t[s]&&(t[s]=l);if(!h)for(s=u.col;s<=d.col;s++)"full"!==n[s]&&(n[s]=c)})),{rows:t,cols:n,allRows:r,allCols:i,all:r&&i}}isInEditMode(e){if(void 0===e)return this._inEdit;this._inEdit=e,e&&(this._editSelection.selection=this._viewSelection.selection.clone(),this._editSelection.originalSelection=this._viewSelection.originalSelection.clone(),this._editSelection._activeCell=this._viewSelection._activeCell.clone(),this._editSelection.originalActiveCell=this._viewSelection.originalActiveCell.clone())}_setFormulaSelections(e){this._formulaSelections=(e||[]).slice(),this.triggerChange({selection:!0})}_viewActiveCell(){return this._viewSelection._activeCell.toRangeRef()}toJSON(){var e={},t=this._rows.toJSON("height",e),n=this._columns.toJSON("width",{}),i=this._viewSelection,r=[],o=this._defaultCellStyle||{};this.forEach(qv,(function(n,i,a){if(function(e){Object.keys(o).forEach((function(t){e[t]===o[t]&&delete e[t]}))}(a),0!==Object.keys(a).length){a.link&&r.push({ref:Ov.display(null,n,i),target:a.link});var s=e[n];void 0===s&&(s=t.length,t.push({index:n}),e[n]=s),n=t[s],a.index=i,void 0===n.cells&&(n.cells=[]),a.formula&&(a.formula.arrayFormulaRange?a.formula={src:a.formula.toString(),ref:a.formula.arrayFormulaRange.toString()}:a.formula=a.formula.toString()),a.validation&&(a.validation=a.validation.toJSON()),a.color&&(a.color=jr(a.color).toCss()),a.background&&(a.background=jr(a.background).toCss()),a.borderTop&&a.borderTop.color&&(a.borderTop.color=jr(a.borderTop.color).toCss()),a.borderBottom&&a.borderBottom.color&&(a.borderBottom.color=jr(a.borderBottom.color).toCss()),a.borderRight&&a.borderRight.color&&(a.borderRight.color=jr(a.borderRight.color).toCss()),a.borderLeft&&a.borderLeft.color&&(a.borderLeft.color=jr(a.borderLeft.color).toCss()),n.cells.push(a)}}));var a={name:this._name(),state:this._state(),rows:t,columns:n,selection:i.selection.toString(),activeCell:i.activeCell().toString(),frozenRows:this.frozenRows(),frozenColumns:this.frozenColumns(),showGridLines:this.showGridLines(),gridLinesColor:this.gridLinesColor(),mergedCells:this._mergedCells.map((function(e){return e.toString()})),hyperlinks:r,defaultCellStyle:o,drawings:this._drawings.map((function(e){return e.toJSON()}))};return this._sort&&(a.sort={ref:this._sort.ref.toString(),columns:this._sort.columns.map((function(e){return{index:e.index,ascending:e.ascending}}))}),this._filter&&(a.filter={ref:this._filter.ref.toString(),columns:this._filter.columns.map((function(e){var t=e.filter.toJSON();return t.index=e.index,t}))}),a}fromJSON(e){this.batch((function(){if(void 0!==e.name&&this._name(e.name),void 0!==e.frozenColumns&&this.frozenColumns(e.frozenColumns),void 0!==e.frozenRows&&this.frozenRows(e.frozenRows),void 0!==e.columns&&this._columns.fromJSON("width",e.columns),void 0!==e.rows){this._resizeForJSON(e.rows),this._rows.fromJSON("height",e.rows);for(var t=0;t<e.rows.length;t++){var n=e.rows[t],i=n.index;if(void 0===i&&(i=t),n.cells)for(var r=0;r<n.cells.length;r++){var o=n.cells[r],a=o.index;if(void 0===a&&(a=r),o.formula){var s="string"!=typeof o.formula,l=s?o.formula.src:o.formula,c=this._compileFormula(i,a,l);s&&c.setArrayFormulaRange(z_.parseReference(o.formula.ref)),o.formula=c}o.validation&&(o.validation=this._compileValidation(i,a,o.validation)),this._properties.fromJSON(this._grid.index(i,a),o)}}}if(e.drawings&&(this._drawings=e.drawings.map(Yw.fromJSON)),e.selection&&(this._viewSelection.selection=this._viewSelection.originalSelection=this._ref(e.selection)),e.activeCell){var d=this._ref(e.activeCell);this._viewSelection._activeCell=d.toRangeRef(),this._viewSelection.originalActiveCell=d.first()}if(e.mergedCells&&e.mergedCells.forEach((function(e){this.range(e).merge()}),this),e.filter){var u=e.filter.ref,h=void 0===e.filter.columns?[]:e.filter.columns;u&&(this._filter={ref:this._ref(u),columns:h.map((function(e){return{index:e.index,filter:Fw.create(e)}}))},this._refreshFilter())}void 0!==e.showGridLines&&(this._showGridLines=e.showGridLines),this._gridLinesColor=e.gridLinesColor,e.sort&&this._sortBy(this._ref(e.sort.ref),e.sort.columns.slice(0))})),this._rows._refresh(),this._columns._refresh()}formula(e){return this._properties.get("formula",this._grid.cellRefIndex(e))}validation(e){return this._properties.get("validation",this._grid.cellRefIndex(e))}resetFormulas(){this._forFormulas((function(e){e.reset()}))}resetValidations(){this._forValidations((function(e){e.reset()}))}recalc(e,t){var n=this._properties.get("formula").values(),i=n.length,r=0,o=0;if(!i&&t)return t();function a(){r--,o!==i||r||t()}for(;o<i;)r++,n[o++].value.exec(e,t?a:null)}revalidate(e){var t=this;this._forValidations((function(n){var i=new $v(n.row,n.col),r=new Uv(i,i);n.exec(e,t._get(r,"value"),t._get(r,"format"))}))}_value(e,t,n){var i=this._grid.index(e,t);if(void 0===n)return this._properties.get("value",i);this._properties.set("value",i,i,n)}_validation(e,t){var n=this._grid.index(e,t);return this._properties.get("validation",n)}_compileValidation(e,t,n){return n instanceof Ny.Validation?n.clone(this._name(),e,t):(null!=n.from&&(n.from=(n.from+"").replace(/^=/,"")),null!=n.to&&(n.to=(n.to+"").replace(/^=/,"")),Ny.compile(this._name(),e,t,n))}_compileFormula(e,t,n){return n=n.replace(/^=/,""),n=z_.parseFormula(this._name(),e,t,n),z_.compile(n)}_copyValuesInRange(e,t,n,i){var r,o,a;for(r=e.col;r<=t.col;r++){o=this._grid.index(e.row,r),a=this._grid.index(t.row,r);for(var s=o,l=e.row;s<=a;++s,++l)n=n.clone(this._name(),l,r),this._properties.set(i,s,s,n)}return n}_set(e,t,n){var i,r,o,a=this._grid.normalize(e.topLeft),s=this._grid.normalize(e.bottomRight);if("number"==typeof n&&(n=z_.runtime.limitPrecision(n)),n&&"formula"===t)"string"==typeof n&&(n=this._compileFormula(a.row,a.col,n)),n=this._copyValuesInRange(a,s,n,"formula");else if(n&&"validation"===t)n=this._compileValidation(a.row,a.col,n),n=this._copyValuesInRange(a,s,n,"validation");else for(i=a.col;i<=s.col;i++)r=this._grid.index(a.row,i),o=this._grid.index(s.row,i),this._properties.set(t,r,o,n),"formula"===t&&this._properties.set("value",r,o,null)}_get(e,t){var n=this._grid.normalize(e.topLeft),i=this._grid.index(n.row,n.col);return this._properties.get(t,i)}batch(e,t){var n=this.suspendChanges();return this.suspendChanges(!0),this._valueChanged=!1,e.call(this),t||(t={recalc:!0}),this._valueChanged&&(t.isValue=!0),this.suspendChanges(n).triggerChange(t)}_sortBy(e,t){var n=null;t.forEach((function(t){n=this._sorter.sortBy(e,t.index,this._properties.get("value"),t.ascending,n)}),this),this._sort={ref:e,columns:t},this._refreshFilter(),this.forEach(e,function(e,t,n){var i=n.formula;if(i){var r=e-i.row;if(0!==r){var o=r>0?i.row:i.row+r;i.adjust(this.name(),"row",o,r)}}}.bind(this)),this.triggerChange({recalc:!0})}_refreshFilter(){this._filter&&this._filterBy(this._filter.ref,this._filter.columns)}_filterBy(e,t){this.batch((function(){for(var n=e.topLeft.row;n<=e.bottomRight.row;n++)this.isFilteredRow(n)&&(this._filteredRows.value(n,n,!1),this._rows.unhide(n));t.forEach((function(t){var n=e.resize({top:1}).toColumn(t.index),i=[];if(n!==Vv){this.forEach(n,(function(e,t,n){n.row=e,i.push(n)})),t.filter.prepare(i);for(var r=0;r<i.length;r++){var o=i[r],a=t.filter.value(o);!1===t.filter.matches(a)&&this._filterRow(o.row)}}}),this),this._filter={ref:e,columns:t}}),{recalc:!0,layout:!0,filter:!0})}filterColumn(e){var t=this.filter().ref;return e.toRangeRef().topLeft.col-t.topLeft.col}filter(){return this._filter}clearFilter(e){this._clearFilter(e instanceof Array?e:[e])}_clearFilter(e){this._filter&&this.batch((function(){this._filter.columns=this._filter.columns.filter((function(t){return e.indexOf(t.index)<0})),this._refreshFilter()}),{recalc:!0,layout:!0,filter:!0})}getAxisState(){return{rows:this._rows.getState(),columns:this._columns.getState()}}setAxisState(e){this._rows.setState(e.rows),this._columns.setState(e.columns),this.triggerChange({layout:!0})}getState(){return{rows:this._rows.getState(),columns:this._columns.getState(),mergedCells:this._mergedCells.map((function(e){return e.clone()})),properties:this._properties.getState()}}setState(e){this._rows.setState(e.rows),this._columns.setState(e.columns),this._mergedCells=e.mergedCells,this._properties.setState(e.properties),this.triggerChange(Yv)}_merge(e){var t,n=this._mergedCells,i=this;return this.batch((function(){t=e.map((function(e){if(e instanceof $v)return e;var t=e.toRangeRef().union(n,(function(e){n.splice(n.indexOf(e),1)})),r=new Wy(t,i),o=r._get("formula"),a=r.value(),s=r.format(),l=r.background();r.value(null),r.format(null),r.background(null);var c=new Wy(t.collapse(),i);return o?c._set("formula",o):c.value(a),c.format(s),c.background(l),n.push(t),t}));var r=i._viewSelection;r.selection=i.unionWithMerged(r.originalSelection),r._activeCell=i.unionWithMerged(r.originalActiveCell)}),{activeCell:!0,selection:!0}),t}_useCultureDecimals(){return this._workbook&&this._workbook.options.useCultureDecimals}withCultureDecimals(e){var t=".";return this._useCultureDecimals()&&(t=I_().numbers.symbols.decimal),z_.withDecimalSeparator(t,e)}drawingBoundingBox(e){var t=e.offsetX,n=e.offsetY;return e.topLeftCell&&(t+=this._columns.sum(0,e.topLeftCell.col-1),n+=this._rows.sum(0,e.topLeftCell.row-1)),new pw(t,n,e.width,e.height)}refBoundingBox(e){return this._grid.rectangle(e.toRangeRef())}addDrawing(e,t){return e instanceof Yw||(e=new Yw(e)),this._drawings.push(e),t&&(this._activeDrawing=e),this.triggerChange({layout:!0}),e}removeDrawing(e){var t=this._drawings.indexOf(e);t>=0&&(this._drawings.splice(t,1),this.triggerChange({layout:!0}))}usesImage(e){for(var t=this._drawings.length;--t>=0;)if(this._drawings[t].image===e)return!0;return!1}isMerged(e){for(var t=this._mergedCells,n=t.length;--n>=0;)if(t[n].eq(e))return!0;return!1}}class Yw{constructor(e){this.reset(e)}toJSON(){return{topLeftCell:this.topLeftCell.toString(),offsetX:this.offsetX,offsetY:this.offsetY,width:this.width,height:this.height,image:this.image,opacity:this.opacity}}clone(){return new Yw(this)}reset(e){var t=e.topLeftCell;"string"==typeof t&&(t=z_.parseReference(t)),this.topLeftCell=t,this.offsetX=e.offsetX||0,this.offsetY=e.offsetY||0,this.width=e.width,this.height=e.height,this.image=e.image,this.opacity=null!=e.opacity?e.opacity:1}eq(e){return(!this.topLeftCell&&!e.topLeftCell||this.topLeftCell&&e.topLeftCell&&this.topLeftCell.eq(e.topLeftCell))&&this.offsetX===e.offsetX&&this.offsetY===e.offsetY&&this.width===e.width&&this.height===e.height&&this.image===e.image&&this.opacity===e.opacity}}Yw.fromJSON=function(e){return new Yw(e)};let Qw={a0:[2383.94,3370.39],a1:[1683.78,2383.94],a2:[1190.55,1683.78],a3:[841.89,1190.55],a4:[595.28,841.89],a5:[419.53,595.28],a6:[297.64,419.53],a7:[209.76,297.64],a8:[147.4,209.76],a9:[104.88,147.4],a10:[73.7,104.88],b0:[2834.65,4008.19],b1:[2004.09,2834.65],b2:[1417.32,2004.09],b3:[1000.63,1417.32],b4:[708.66,1000.63],b5:[498.9,708.66],b6:[354.33,498.9],b7:[249.45,354.33],b8:[175.75,249.45],b9:[124.72,175.75],b10:[87.87,124.72],c0:[2599.37,3676.54],c1:[1836.85,2599.37],c2:[1298.27,1836.85],c3:[918.43,1298.27],c4:[649.13,918.43],c5:[459.21,649.13],c6:[323.15,459.21],c7:[229.61,323.15],c8:[161.57,229.61],c9:[113.39,161.57],c10:[79.37,113.39],executive:[521.86,756],folio:[612,936],legal:[612,1008],letter:[612,792],tabloid:[792,1224]};function Xw(e){return e*(72/25.4)}function Zw(e){return Xw(10*e)}function Jw(e){return 72*e}function ek(e,t){if("number"==typeof e)return e;if("string"==typeof e){let t;if(t=/^\s*([0-9.]+)\s*(mm|cm|in|pt)\s*$/.exec(e),t){let e=parseFloat(t[1]);if(!isNaN(e))return"pt"===t[2]?e:{mm:Xw,cm:Zw,in:Jw}[t[2]](e)}}if(null!=t)return t;throw new Error("Can't parse unit: "+e)}let tk,nk=.8;function ik(e,t,n,i,r){let o=0,a=[],s=t,l=0;return t&&n&&(n*=t),e.forEach((function(e,c){null!=i&&c<i&&(l+=e),t&&o+e>s&&(s-o<n&&(o=t*Math.ceil(o/t)+l,l>0&&r.push(o-l)),s+=t*Math.ceil(e/t)),a.push(o),o+=e})),a.push(o),a}function rk(e,t,n){let i=e._grid;t=i.normalize(t);let r=i.rectangle(t),o=[];e._drawings.forEach((function(t){let n=e.drawingBoundingBox(t);n.intersects(r)&&o.push({drawing:t,box:n.offset(-r.left,-r.top)})}));let a=[],s=[],l=[],c=e._getMergedCells(t),d=-1,u=-1;e.forEach(t,(function(i,r,h){let p=i-t.topLeft.row,f=r-t.topLeft.col,m=e.rowHeight(i),g=e.columnWidth(r);n.forScreen||(h.drawings=o.filter((function(t){let n=t.drawing.topLeftCell;if(n&&n.row==i&&n.col==r)return d=Math.max(d,e._rows.index(t.box.bottom)),u=Math.max(u,e._columns.index(t.box.right)),!0}))),f||s.push(m),p||l.push(g);let v=new $v(i,r).print();if(c.secondary[v])return;h.row=p,h.col=f;let _=c.primary[v];if(_?(delete c.primary[v],h.merged=!0,h.rowspan=_.height(),h.colspan=_.width(),n.forScreen&&(h.width=e._columns.sum(_.topLeft.col,_.bottomRight.col),h.height=e._rows.sum(_.topLeft.row,_.bottomRight.row))):(h.rowspan=1,h.colspan=1),!e._grid._columns.sum(r,r+h.colspan-1)||!e._grid._rows.sum(i,i+h.rowspan-1))return;let b=n.forScreen||function(e){return null!=e.value||e.merged||null!=e.background||null!=e.borderRight||null!=e.borderBottom||null!=e.dBorders||null!=e.validation&&!e.validation.value||e.drawings&&e.drawings.length}(h);(n.emptyCells||b)&&(b?(d=Math.max(d,p+h.rowspan-1),u=Math.max(u,f+h.colspan-1)):h.empty=!0,a.push(h))})),n.forScreen||(s=s.slice(0,d+1),l=l.slice(0,u+1));let h=n.pageWidth,p=n.pageHeight,f=n.scale||1;if(n.fitWidth){let e=l.reduce(ak,0);e>h&&(f=h/e)}h=Math.ceil(h/f),p=Math.ceil(p/f);let m=[],g=ik(s,p||0,n.maxEmpty,n.headerRows,m),v=ik(l,h||0,n.maxEmpty),_=0,b=0,y=[];return a=a.filter((function(e){return(!e.empty||!(e.row>d||e.col>u))&&(n.headerRows&&e.row<n.headerRows&&y.push(e),e.left=v[e.col],e.top=g[e.row],e.merged?n.forScreen?(e.right=e.left+e.width,e.bottom=e.top+e.height):(e.right=sk(v,e.col+e.colspan),e.bottom=sk(g,e.row+e.rowspan),e.width=e.right-e.left,e.height=e.bottom-e.top):(e.width=l[e.col],e.height=s[e.row],e.bottom=e.top+e.height,e.right=e.left+e.width),n.forScreen||e.drawings.forEach((function(t){let n=t.box;n.left=e.left+t.drawing.offsetX,n.top=e.top+t.drawing.offsetY,n.right=n.left+n.width,n.bottom=n.top+n.height})),_=Math.max(_,e.right),b=Math.max(b,e.bottom),!0)})),Object.keys(c.primary).forEach((function(n){let i=c.primary[n];e.forEach(i.topLeft.toRangeRef(),(function(n,r,o){let s=n-t.topLeft.row,l=r-t.topLeft.col;o.merged=!0,o.colspan=i.width(),o.rowspan=i.height(),o.top=s<0?-e._rows.sum(n,n-s-1):g[s],o.left=l<0?-e._columns.sum(r,r-l-1):v[l],o.height=e._rows.sum(i.topLeft.row,i.bottomRight.row),o.width=e._columns.sum(i.topLeft.col,i.bottomRight.col),o.height>0&&o.width>0&&(o.right=o.left+o.width,o.bottom=o.top+o.height,o.row=s,o.col=l,a.push(o))}))})),n.headerRows&&(m.forEach((function(e){y.forEach((function(t){t=function(e,t){t||(t={});if(Object.assign)return Object.assign(t,e);return Object.keys(e).reduce((function(t,n){return t[n]=e[n],t}),t)}(t),t.top+=e,t.bottom=t.top+t.height,a.push(t)})),g.push(e)})),g.sort(ck)),{width:_,height:b,cells:a.sort(lk),scale:f,xCoords:v,yCoords:g,drawings:o}}function ok(e,t){return e.size===t.size&&e.color===t.color}function ak(e,t){return e+t}function sk(e,t){return t<e.length?e[t]:e[e.length-1]}function lk(e,t){return e.top<t.top?-1:e.top==t.top?e.left<t.left?-1:e.left==t.left?0:1:1}function ck(e,t){return e<t?-1:e>t?1:0}function dk(e,t,n,i){let r=Math.ceil(t.width/i.pageWidth),o=Math.ceil(t.height/i.pageHeight),a=Math.ceil(i.pageWidth/t.scale),s=Math.ceil(i.pageHeight/t.scale);for(let e=0;e<o;++e)for(let t=0;t<r;++t)l(e,t);function l(r,o){let l=o*a,c=l+a,d=r*s,u=d+s,h=0,p=0;function f(e){return!(e.right<=l||e.left>=c||e.bottom<=d||e.top>=u)&&(h=Math.max(e.bottom,h),p=Math.max(e.right,p),!0)}let m=t.cells.filter(f),g=t.drawings.filter((function(e){return f(e.box)}));if(h=Math.min(h,u),p=Math.min(p,c),m.length||g.length){let r=new vs;n.append(r);let o=new vs;r.append(o),o.clip(us.fromRect(new Yo([l-1,d-1],[p+1,h+1])));let a=Do.scale(t.scale,t.scale).multiplyCopy(Do.translate(-l,-d));if((i.hCenter||i.vCenter)&&(a=a.multiplyCopy(Do.translate(i.hCenter?(c-p)/2:0,i.vCenter?(u-h)/2:0))),o.transform(a),i.guidelines){let e=null;t.xCoords.forEach((function(t){(t=Math.min(t,p))!==e&&t>=l&&t<=c&&(e=t,o.append((new us).moveTo(t,d).lineTo(t,h).close().stroke(i.guideColor,nk)))})),e=null,t.yCoords.forEach((function(t){(t=Math.min(t,h))!==e&&t>=d&&t<=u&&(e=t,o.append((new us).moveTo(l,t).lineTo(p,t).close().stroke(i.guideColor,nk)))}))}let s=fk();m.forEach((function(t){!function(e,t,n){let i=new vs;t.append(i);let r=new Yo([e.left,e.top],[e.width,e.height]);if(e.background||e.merged){let t=r;n.guidelines&&(t=r.clone(),t.origin.x+=.5,t.origin.y+=.5,t.size.width-=1,t.size.height-=1),i.append(new Ss(t).fill(e.background||"#fff").stroke(null))}e.dBorders&&(2&e.dBorders.type&&i.append((new us).moveTo(e.left,e.bottom).lineTo(e.right,e.top).stroke(e.dBorders.color,e.dBorders.size)),1&e.dBorders.type&&i.append((new us).moveTo(e.left,e.top).lineTo(e.right,e.bottom).stroke(e.dBorders.color,e.dBorders.size)));let o=e.value;if(null!=o){let t="number"==typeof o?"number":null,n=new vs;n.clip(us.fromRect(r)),i.append(n);let a,s=e.format;if(s||"number"!=t||o==Math.floor(o)||(s="0.##############"),s?(a=Sb.textAndColor(o,s),o=a.text,a.type&&(t=a.type)):o+="",!e.textAlign)switch(t){case"number":case"date":case"percent":case"currency":e.textAlign="right";break;case"boolean":e.textAlign="center"}!function(e,t,n,i){tk||(tk=document.createElement("div"),tk.style.position="fixed",tk.style.left="0px",tk.style.top="0px",tk.style.visibility="hidden",tk.style.overflow="hidden",tk.style.boxSizing="border-box",tk.style.lineHeight="normal",document.body.appendChild(tk));tk.firstChild&&tk.removeChild(tk.firstChild);tk.style.padding="2px 4px",tk.style.color=t,tk.style.font=function(e){let t=[];e.italic&&t.push("italic");e.bold&&t.push("bold");return t.push((e.fontSize||12)+"px"),t.push(e.fontFamily||"Arial"),t.join(" ")}(n),tk.style.width=n.width+"px",tk.style.textAlign=n.textAlign||"left",tk.style.textDecoration=n.underline?"underline":"none",uk(n,tk.style),n.wrap?(tk.style.whiteSpace="pre-wrap",tk.style.overflowWrap=tk.style.wordWrap="break-word"):(tk.style.whiteSpace="pre",tk.style.overflowWrap=tk.style.wordWrap="normal");tk.appendChild(document.createTextNode(e));let r=0;switch(n.verticalAlign){case"center":r=n.height-tk.offsetHeight>>1;break;case void 0:case null:case"bottom":r=n.height-tk.offsetHeight}r<0&&(r=0);let o=Au(tk);o.transform(Do.translate(n.left,n.top+r)),i.append(o)}(o,a&&a.color||e.color||"#000",e,n)}}(t,o,i),s.add(t,e)}));let f=new vs;s.vert.forEach((function(e){e.forEach((function(e){e.rendered||(e.rendered=!0,f.append((new us).moveTo(e.x,e.top).lineTo(e.x,e.bottom).close().stroke(e.color,e.size)))}))})),s.horiz.forEach((function(e){e.forEach((function(e){e.rendered||(e.rendered=!0,f.append((new us).moveTo(e.left,e.y).lineTo(e.right,e.y).close().stroke(e.color,e.size)))}))})),o.append(f),g.forEach((function(t){let n=t.drawing,i=n.image;if(null!=i){let r=t.box,a=e._workbook.imageUrl(i);o.append(new n.Image(a,new Yo([r.left,r.top],[r.width,r.height])).opacity(n.opacity))}}))}}}function uk(e,t){if(e.indent){let n=1.4*e.indent;switch(t.textAlign){case null:case"left":t.paddingLeft=n+"ch";break;case"right":t.paddingRight=n+"ch";break;case"center":t.paddingLeft=n/2+"ch",t.paddingRight=n/2+"ch"}}}function hk(e,t,n,i){null==n&&null==i&&(i=t,n={},t=qv),null==i&&(i=n,t instanceof Range||t instanceof Ov||"string"==typeof t?n={}:(n=t,t=qv)),n=Object.assign({},{paperSize:"A4",landscape:!0,margin:"1cm",guidelines:!0,guideColor:"#aaa",emptyCells:!0,fitWidth:!1,center:!1,headerRows:null,maxEmpty:.2,scale:1},n);let r=new vs,o=function(e){if("function"!=typeof e){let t=e;e=function(e,n){return e in t?t[e]:n}}let t=e("paperSize",Qw.a4);if(!t)return{};if("string"==typeof t&&(t=Qw[t.toLowerCase()],null==t))throw new Error("Unknown paper size");t[0]=ek(t[0]),t[1]=ek(t[1]),e("landscape",!1)&&(t=[Math.max(t[0],t[1]),Math.min(t[0],t[1])]);let n=e("margin");return n&&("string"==typeof n||"number"==typeof n?(n=ek(n,0),n={left:n,top:n,right:n,bottom:n}):n={left:ek(n.left,0),top:ek(n.top,0),right:ek(n.right,0),bottom:ek(n.bottom,0)},e("addMargin")&&(t[0]+=n.left+n.right,t[1]+=n.top+n.bottom)),{paperSize:t,margin:n}}(n);r.options.set("pdf",{author:n.author,creator:n.creator,date:n.date,keywords:n.keywords,margin:o.margin,multiPage:!0,paperSize:o.paperSize,subject:n.subject,title:n.title,autoPrint:n.autoPrint});let a=o.paperSize[0],s=o.paperSize[1];o.margin&&(a-=o.margin.left+o.margin.right+1,s-=o.margin.top+o.margin.bottom+1),n.pageWidth=a,n.pageHeight=s;let l=rk(e,e._ref(t),n);dk(e,l,r,n),i(r)}function pk(){}function fk(){let e=new pk,t=new pk;function n(e,n,i,r,o,a){let s=t[n]||(t[n]=new pk),l=e>0&&s[e-1];l&&ok(l,i)?(s[e]=l,l.bottom=a):s[e]={size:i.size,color:i.color||"#000",x:r,top:o,bottom:a}}function i(t,n,i,r,o,a){let s=e[t]||(e[t]=new pk),l=n>0&&s[n-1];l&&ok(l,i)?(s[n]=l,l.right=a):s[n]={size:i.size,color:i.color||"#000",y:r,left:o,right:a}}return{add:function(e,t){if(t){let n=t._properties,i=t._grid;e.borderLeft=n.get("vBorders",i.index(e.row,e.col)),e.borderRight=n.get("vBorders",i.index(e.row,e.col+e.colspan)),e.borderTop=n.get("hBorders",i.index(e.row,e.col)),e.borderBottom=n.get("hBorders",i.index(e.row+e.rowspan,e.col))}e.borderLeft&&n(e.row,e.col,e.borderLeft,e.left,e.top,e.bottom),e.borderRight&&n(e.row,e.col+e.colspan,e.borderRight,e.right,e.top,e.bottom),e.borderTop&&i(e.row,e.col,e.borderTop,e.top,e.left,e.right),e.borderBottom&&i(e.row+e.rowspan,e.col,e.borderBottom,e.bottom,e.left,e.right)},horiz:e,vert:t}}Kw.prototype.draw=function(e,t,n){let i=this;i._workbook?i.recalc(i._workbook._context,(function(){hk(i,e,t,n)})):hk(i,e,t,n)},pk.prototype={forEach:function(e){Object.keys(this).forEach((function(t){e(this[t],t,this)}),this)}};const mk={Borders:fk,doLayout:rk,applyIndent:uk},gk=".",vk={view:"k-spreadsheet-view",fixedContainer:"k-spreadsheet-fixed-container",editContainer:"k-spreadsheet-edit-container",scroller:"k-spreadsheet-scroller",viewSize:"k-spreadsheet-view-size",clipboard:"k-spreadsheet-clipboard",cellEditor:"k-spreadsheet-cell-editor",barEditor:"k-spreadsheet-editor",topCorner:"k-spreadsheet-top-corner",filterHeadersWrapper:"k-filter-wrapper",filterRange:"k-filter-range",filterButton:"k-spreadsheet-filter",filterButtonSelected:"k-selected",horizontalResize:"k-horizontal-resize",verticalResize:"k-vertical-resize",icon:"k-icon",iconFilterDefault:"k-i-caret-alt-down",sheetsBar:"k-spreadsheet-sheets-bar",sheetsBarActive:"k-spreadsheet-sheets-bar-active",sheetsBarInactive:"k-spreadsheet-sheets-bar-inactive",cellContextMenu:"k-spreadsheet-cell-context-menu",rowHeaderContextMenu:"k-spreadsheet-row-header-context-menu",colHeaderContextMenu:"k-spreadsheet-col-header-context-menu",drawingContextMenu:"k-spreadsheet-drawing-context-menu"},_k={cell:"k-spreadsheet-cell",vaxis:"k-spreadsheet-vaxis",haxis:"k-spreadsheet-haxis",vborder:"k-spreadsheet-vborder",hborder:"k-spreadsheet-hborder",rowHeader:"k-spreadsheet-row-header",columnHeader:"k-spreadsheet-column-header",pane:"k-spreadsheet-pane",data:"k-spreadsheet-data",mergedCell:"k-spreadsheet-merged-cell",mergedCellsWrapper:"k-merged-cells-wrapper",activeCell:"k-spreadsheet-active-cell",selection:"k-spreadsheet-selection",selectionWrapper:"k-selection-wrapper",autoFillWrapper:"k-auto-fill-wrapper",single:"k-single",top:"k-top",right:"k-right",bottom:"k-bottom",left:"k-left",resizeHandle:"k-resize-handle",columnResizeHandle:"k-column-resize-handle",rowResizeHandle:"k-row-resize-handle",resizeHint:"k-resize-hint",resizeHintHandle:"k-resize-hint-handle",resizeHintMarker:"k-resize-hint-marker",resizeHintVertical:"k-resize-hint-vertical",selectionHighlight:"k-spreadsheet-selection-highlight",series:["k-series-a","k-series-b","k-series-c","k-series-d","k-series-e","k-series-f"]};function bk(e){return(e.size||1)+"px solid "+(e.color||"#000")}function yk(e){return/:\/\//.test(e)||(e="http://"+e),e}function wk(e,t,n,i){function r(e){let n=t.link;if(n||"object"==typeof t.value&&(n=t.value.link),n){let i={textDecoration:"none"};return t.color&&(i.color=t.color),t.underline&&(i.textDecoration="underline"),fb.element("a",{href:yk(n),style:i,target:"_blank"},e?[e]:[])}return e}let o=null!=t.value||null!=t.validation&&!t.validation.value||t.background||t.merged||t.comment||t.dBorders;if(!n&&!o)return;let a={background:[]},s=t.background;if(s){let e=s;i&&(e=jr(e).toHSV(),e.v*=.9,e=e.toCssRgba()),e=bk({color:e}),a.outline=e}t.dBorders&&(2&t.dBorders.type&&a.background.push("linear-gradient(to top left, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0) calc(50% - "+t.dBorders.size+"px), "+t.dBorders.color+" 50%, rgba(0, 0, 0, 0) calc(50% + "+t.dBorders.size+"px), rgba(0, 0, 0, 0) 100%)"),1&t.dBorders.type&&a.background.push("linear-gradient(to top right, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0) calc(50% - "+t.dBorders.size+"px), "+t.dBorders.color+" 50%, rgba(0, 0, 0, 0) calc(50% + "+t.dBorders.size+"px), rgba(0, 0, 0, 0) 100%)")),s&&a.background.push(s),t.color&&(a.color=t.color),t.fontFamily&&(a.fontFamily=t.fontFamily),t.underline&&(a.textDecoration="underline"),t.italic&&(a.fontStyle="italic"),t.textAlign&&(a.textAlign=t.textAlign),t.bold&&(a.fontWeight="bold"),t.fontSize&&(a.fontSize=t.fontSize+"px"),!0===t.wrap?(a.whiteSpace="pre-wrap",a.overflowWrap="break-word",a.wordWrap="break-word"):(a.whiteSpace="pre",a.overflowWrap="normal",a.wordWrap="normal"),a.left=t.left+1+"px",a.top=t.top+1+"px",a.width=t.width-1+"px",a.height=t.height-1+"px";let l=t.value,c=typeof l,d=t.format;if(d||"number"!==c||l===Math.floor(l)||(d="0.##############"),d&&null!=l?(l=Sb.format(l,d),l.__dataType&&(c=l.__dataType)):null!=l&&(l=t.html?fb.html(l):fb.text(l)),!a.textAlign)switch(c){case"number":case"date":case"percent":case"currency":a.textAlign="right";break;case"boolean":a.textAlign="center"}mk.applyIndent(t,a);let u=[_k.cell];n&&u.push(n),!1===t.enable&&u.push("k-disabled"),t.merged&&(u.push("k-spreadsheet-merged-cell"),t.enable||e.push(fb.element("div",{className:"k-spreadsheet-disabled-mask",style:{left:t.left+1+"px",top:t.top+1+"px",width:t.width-1+"px",height:t.height-1+"px"}}))),t.comment&&u.push("k-spreadsheet-has-comment");let h=t.verticalAlign||"bottom";l=h&&l?fb.element("div",{className:"k-vertical-align-"+h},[r(l)]):r(l),a.background.length?a.background=a.background.join(","):delete a.background;let p=l?[l]:[],f={style:a},m=t.validation;m&&!m.value&&(p.push(fb.element("span",{className:"k-dirty"})),u.push("k-dirty-cell"),f.title=m.message),f.className=u.join(" ");let g=fb.element("div",f,p);return e.push(g),g}let kk=class e{constructor(e,t,n){this._sheet=e,this._grid=t,this.getIconHTMLString=n}refresh(e,t){this._grid.refresh(e,t)}isVisible(e,t,n){return this._grid.view(e,t).ref.intersects(n)}render(t){let n=t.scroller,i=n.scrollLeft,r=n.scrollTop;r<0&&(r=0),i<0&&(i=0);let o=e.classNames,a=this._sheet,s=this._grid,l=s.view(i,r);this._currentView=l,this._currentRect=this._rectangle(l.ref),this._selectedHeaders=a.selectedHeaders();let c=[];if(c.push(this.renderData(t)),a._activeDrawing||c.push(this.renderSelection(n)),c.push(this.renderAutoFill()),c.push(this.renderEditorSelection()),c.push(this.renderFilterHeaders()),s.hasRowHeader){let e=fb.element("div",{className:o.rowHeader,style:{width:s.headerWidth+"px",top:l.rowOffset+"px"}});c.push(e),a.forEach(l.ref.leftColumn(),function(t){if(!a.isHiddenRow(t)){let n=t+1,i=a.rowHeight(t);e.children.push(fb.element("div",{className:this.headerClassName(t,"row"),style:{width:s.headerWidth+"px",height:i+"px"}},[fb.element("div",{className:"k-vertical-align-center"},[fb.text(n+"")])]))}}.bind(this))}if(s.hasColumnHeader){let e=fb.element("div",{className:o.columnHeader,style:{top:"0px",left:l.columnOffset+"px",width:this._currentRect.width+"px",height:s.headerHeight+"px"}});c.push(e);let t=0;a.forEach(l.ref.topRow(),function(n,i){if(!a.isHiddenColumn(i)){let n=Ov.display(null,1/0,i),r=a.columnWidth(i);e.children.push(fb.element("div",{className:this.headerClassName(i,"col"),style:{position:"absolute",left:t+"px",width:r+"px",height:s.headerHeight+"px"}},[fb.element("div",{className:"k-vertical-align-center"},[fb.text(n+"")])])),t+=r}}.bind(this))}a.resizeHandlePosition()&&(s.hasColumnHeader||s.hasRowHeader)&&(a.resizeHintPosition()||this.renderResizeHandle(c));let d=[o.pane];return s.hasColumnHeader&&d.push(o.top),s.hasRowHeader&&d.push(o.left),fb.element("div",{style:s.style,className:d.join(" ")},c)}headerClassName(e,t){let n,i,r=this._selectedHeaders;"row"===t?(n=r.rows[e],i=r.allRows):(n=r.cols[e],i=r.allCols);let o=n||(r.all?"full":i?"partial":"none");return o&&(o="k-selection-"+o),o}renderData(t){let n,i=this._sheet,r=this._currentView,o=fb.element("div",{className:e.classNames.data,style:{position:"relative",left:r.columnOffset+"px",top:r.rowOffset+"px"}}),a=this._currentRect,s=mk.doLayout(i,r.ref,{forScreen:!0}),l=this._grid,c=i._showGridLines;c&&(n=null,s.xCoords.forEach((function(e){e!==n&&(n=e,o.children.push(fb.element("div",{className:_k.vaxis,style:{left:e+"px",height:a.height+"px",borderColor:i.gridLinesColor()}})))})),n=null,s.yCoords.forEach((function(e){e!==n&&(n=e,o.children.push(fb.element("div",{className:_k.haxis,style:{top:e+"px",width:a.width+"px",borderColor:i.gridLinesColor()}})))})));let d=mk.Borders(),u=i.activeCell().toRangeRef(),h=u.topLeft;return s.cells.forEach((function(n){let a=null,s=n.row+r.ref.topLeft.row,p=n.col+r.ref.topLeft.col;if(i._activeDrawing){let e=i._activeDrawing.topLeftCell;e&&e.row===s&&e.col===p&&(a="k-spreadsheet-drawing-anchor-cell")}else s===h.row&&p===h.col&&(a=[e.classNames.activeCell].concat(this._activeFormulaColor(),this._directionClasses(u)),i.singleCellSelection()&&a.push(e.classNames.single),a=a.join(" "));if(d.add(n),wk(o.children,n,a,c),n.comment&&i._commentRef&&s===i._commentRef.row&&p===i._commentRef.col){let e=4,i=n.right+l.left+r.columnOffset+e,o={top:n.top+l.top+r.rowOffset+"px"};i+200>t.contentWidth?o.right=t.contentWidth-l.left-n.left-r.columnOffset+e+"px":o.left=i+"px";let a=fb.element("div",{className:"k-tooltip k-spreadsheet-cell-comment",style:o},[fb.text(n.comment)]);t.toplevelElements.push(a)}}),this),d.vert.forEach((function(e){e.forEach((function(e){if(!e.rendered){e.rendered=!0;let t={left:e.x+"px",top:e.top+"px",height:e.bottom-e.top+1+"px",borderWidth:e.size+"px",borderColor:e.color};1!==e.size&&(t.transform="translateX(-"+(e.size-1)/2+"px)"),o.children.push(fb.element("div",{className:_k.vborder,style:t}))}}))})),d.horiz.forEach((function(e){e.forEach((function(e){if(!e.rendered){e.rendered=!0;let t={top:e.y+"px",left:e.left+"px",width:e.right-e.left+"px",borderWidth:e.size+"px",borderColor:e.color};1!==e.size&&(t.transform="translateY(-"+(e.size-1)/2+"px)"),o.children.push(fb.element("div",{className:_k.hborder,style:t}))}}))})),this.renderDrawings(s,o.children),o}renderDrawings(e,t){let n=this._sheet,i=n._workbook;e.drawings.forEach((function(e){let r=e.drawing,o=e.box.toDiv("k-spreadsheet-drawing");r.image&&o.children.push(fb.element("div",{className:"k-spreadsheet-drawing-image",style:{backgroundImage:"url('"+i.imageUrl(r.image)+"')",opacity:r.opacity}})),r===n._activeDrawing&&(o.attr.className+=" k-spreadsheet-active-drawing",function(e){["N","NE","E","SE","S","SW","W","NW"].forEach((function(t){e.push(fb.element("div",{className:"k-spreadsheet-drawing-handle "+t,"data-direction":t}))}))}(o.children)),t.push(o)}))}renderResizeHandle(t){let n,i=this._sheet.resizeHandlePosition(),r=this._rectangle(i),o=[e.classNames.resizeHandle];if(i.col!==-1/0){if(this._grid.rows._start>0)return;n={height:this._grid.headerHeight+"px",width:"7px",left:r.right-3.5+"px",top:"0px"},o.push(vk.horizontalResize)}else{if(this._grid.columns._start>0)return;n={height:"7px",width:this._grid.headerWidth+"px",top:r.bottom-3.5+"px",left:"0px"},o.push(vk.verticalResize)}t.push(fb.element("div",{className:o.join(" "),style:n}))}filterIconRect(e){return new pw(e.right-16-3,e.top+3,16,16)}icon(e){return"function"==typeof this.getIconHTMLString?fb.element(this.getIconHTMLString(e)):fb.element("span",{className:vk.icon+" "+e})}renderFilterHeaders(){let e=this,t=this._sheet,n=[],i=vk,r=t.filter();return r&&this._addDiv(n,r.ref,i.filterRange),t.forEachFilterHeader(this._currentView.ref,function(t){let o=this._rectangle(t),a=this.filterIconRect(o),s=this._sheet.filterColumn(t),l=function(t,n,i){let o={left:n.left+"px",top:n.top+"px"},a=r&&r.columns.some((function(e){return e.index===i})),s=t.filterButton;return a&&(s+=" "+t.filterButtonSelected),fb.element("span",{className:s,style:o},[e.icon(t.iconFilterDefault)])}(i,a,s);n.push(l)}.bind(this)),fb.element("div",{className:i.filterHeadersWrapper},n)}renderEditorSelection(){let t=e.classNames,n=this._sheet,i=[];return n._formulaSelections.forEach(function(e){let n=e.ref;n!==Vv&&this._addDiv(i,n,t.selectionHighlight+" "+e.colorClass)}.bind(this)),fb.element("div",{className:t.selectionWrapper},i)}renderSelection(t){let n=e.classNames,i=[],r=[n.selection],o=this._sheet,a=o.activeCell().toRangeRef(),s=o.select();return r=r.concat(this._activeFormulaColor()),1===s.size()&&r.push("k-single-selection"),this._sheet.autoFillPunch()&&r.push("k-dim-auto-fill-handle"),s.forEach(function(e){e!==Vv&&this._addDiv(i,e,r.join(" "))}.bind(this)),this._renderCustomEditorButton(i,a,t),fb.element("div",{className:n.selectionWrapper},i)}renderAutoFill(){let t=[];if(this._sheet.autoFillInProgress()){let e=this._sheet.autoFillRef(),n=this._sheet.autoFillPunch(),i=this._sheet._autoFillDirection;if(this._addDiv(t,e,"k-auto-fill"),n)this._addDiv(t,n,"k-auto-fill-punch");else if(void 0!==i){let n,r;switch(i){case 0:case 1:n=e.bottomRight,r="k-auto-fill-br-hint";break;case 2:n=new $v(e.topLeft.row,e.bottomRight.col),r="k-auto-fill-tr-hint";break;case 3:n=new $v(e.bottomRight.row,e.topLeft.col),r="k-auto-fill-bl-hint"}let o=this._addDiv(t,n,r);if(o){let e=fb.element("span",{className:"k-tooltip"},[fb.text(this._sheet._autoFillHint)]);o.children.push(e)}}}return fb.element("div",{className:e.classNames.autoFillWrapper},t)}_addDiv(e,t,n){let i;return this._currentView.ref.intersects(t)&&(i=this._rectangle(t).resize(1,1).toDiv(n),e.push(i)),i}_renderCustomEditorButton(e,t,n){let i=this,r=i._sheet,o=i._currentView,a=i._grid.columns._axis._count,s=r.activeCellCustomEditor();if(s&&o.ref.intersects(t)){let o=i._rectangle(t);r.forEach(t.collapse(),(function(t,r,l){l.left=o.left,l.top=o.top,l.width=o.width,l.height=o.height;let c="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-spreadsheet-editor-button",d=r===a-1||i._buttonOutOfVisiblePane(t,r,n);d&&(c+=" k-spreadsheet-last-column"),i._editorInLastColumn=d;let u=fb.element("div",{className:c,style:{left:l.left+(d?0:l.width)+"px",top:l.top+"px",height:l.height+"px"}});s.icon&&u.children.push(i.icon(s.icon)),e.push(u)}))}}_activeFormulaColor(){let e,t=[];return this._sheet.isInEditMode()&&(e=this._sheet._formulaSelections.filter((function(e){return e.active&&"ref"===e.type}))[0],e&&t.push(e.colorClass)),t}_directionClasses(t){let n=[],i=e.classNames,r=this._currentView.ref;return t.move(0,-1).intersects(r)||n.push(i.left),t.move(-1,0).intersects(r)||n.push(i.top),t.move(0,1).intersects(r)||n.push(i.right),t.move(1,0).intersects(r)||n.push(i.bottom),n}_rectangle(e){return this._grid.boundingRectangle(e.toRangeRef()).offset(-this._currentView.mergedCellLeft,-this._currentView.mergedCellTop)}_buttonOutOfVisiblePane(e,t,n){let i=this._grid,r=this._sheet,o=r.range(e,t)._ref,a=i.scrollBoundaries(o),s=i.columns.frozen?0:n.scrollLeft;if(a.right+20>s||t+1===r.frozenColumns())return!0}};kk.classNames=_k;let xk=["font-family","font-size","font-stretch","font-style","font-weight","letter-spacing","text-transform","line-height"],Ck={27:"esc",37:"left",39:"right",35:"end",36:"home",32:"spacebar"},Sk=/(^_|[^a-z0-9]$)/i;class Tk extends rw{constructor(e,t){const n=Object.assign({},{name:"FormulaInput",autoScale:!1,filterOperator:"startswith",scalePadding:30,minLength:1,formulaBarWidth:null},t);super(e,n),this.events=["keyup","focus"],this.input=t.input,e&&(this.bind(this.events,this.options),e.classList.add(Tk.classNames.wrapper),n&&n.formulaBarWidth,this._highlightedRefs=[],this._formulaSource(),this._formulaList(),this._tooltip(),this._sync=this._sync.bind(this),this.scale=this.scale.bind(this),this._keydown=this._keydown.bind(this),this._keyup=this._keyup.bind(this),this._blur=this._blur.bind(this),this._input=this._input.bind(this),this._focus=this._focus.bind(this),this._paste=this._paste.bind(this),this.options.autoScale&&e.addEventListener("input",this.scale),e.addEventListener("keydown",this._keydown),e.addEventListener("keyup",this._keyup),e.addEventListener("blur",this._blur),e.addEventListener("input",this._input),e.addEventListener("click",this._input),e.addEventListener("focus",this._focus),e.addEventListener("paste",this._paste))}enable(e){if(void 0===e)return"true"===this.element.getAttribute("contenteditable");e?this.element.setAttribute("contenteditable",e):this.element.removeAttribute("contenteditable"),this.element.classList.toggle("k-disabled",!e)}getPos(){let e=this.element,t=window.getSelection(),n=r(t.focusNode,t.focusOffset),i=r(t.anchorNode,t.anchorOffset);if(null!=n&&null!=i){if(n>i){let e=n;n=i,i=e}return{begin:n,end:i,collapsed:n===i}}function r(t,n){try{!function e(i){if(i===t)throw n;if(1===i.nodeType)for(let t=i.firstChild;t;t=t.nextSibling)e(t);else 3===i.nodeType&&(n+=i.nodeValue.length)}(e)}catch(e){return e}}}setPos(e,t){let n=this.element;function i(e,t){try{!function e(n){if(3===n.nodeType){let e=n.nodeValue.length;if(e>=t)throw n;t-=e}else if(1===n.nodeType)for(let t=n.firstChild;t;t=t.nextSibling)e(t)}(e)}catch(e){return{node:e,pos:t}}}e=i(n,e),t=null!=t?i(n,t):e,e&&t&&this._setRange(e,t)}end(){this.setPos(this.length())}home(){this.setPos(0)}select(){this.setPos(0,this.length())}length(){return this.value().length}_setRange(e,t){let n=document.createRange();n.setStart(e.node,e.pos),n.setEnd(t.node,t.pos);let i=window.getSelection(),r=i.getRangeAt(0);var o,a;a=r,((o=n).startOffset!==a.startOffset||o.endOffset!==a.endOffset||o.startContainer!==a.endContainer||o.endContainer!==a.endContainer)&&(i.removeAllRanges(),i.addRange(n))}_formulaSource(){let e,t=[];for(let n in z_.runtime.FUNCS)Sk.test(n)||(e=n.toUpperCase(),t.push({value:e,text:e}));this.formulaSource=t}get list(){return this.input.current.list}get popup(){return this.input.current.popup}_formulaList(){this.list.data(this.formulaSource),this.list.itemClick((e=>{this._formulaListChange(e)}))}_formulaListChange(e){let t=this._tokenContext();if(!t||this._mute)return;let n=t.token,i=e,r={replace:!0,token:n,end:n.end};t.nextToken&&"("===t.nextToken.value||(i+="("),this._replaceAt(r,i),this.popup.close()}_blur(){this.popup.close(),clearTimeout(this._focusId),this.trigger("blur")}_isFormula(){return/^=/.test(this.value())}_keydown(e){let t=e.keyCode,n=this;Ck[t]?(n.popup.close(),n._navigated=!0):n._move(t)&&(n._navigated=!0,e.preventDefault()),n._keyDownTimeout=setTimeout(n._syntaxHighlight.bind(n))}_keyup(){let e,t=this.popup;if(this._isFormula()&&!this._navigated){e=((this._tokenContext()||{}).token||{}).value;const n=this.filter(e);e&&n.length?(t[t.visible()?"position":"open"](),setTimeout((()=>{this.list.focusFirst()}),0)):t.close()}this._navigated=!1,this._syntaxHighlight(),this.trigger("keyup")}_input(){this._syntaxHighlight()}_focus(){setTimeout(this._sync.bind(this)),this._focusTimeout=setTimeout(this._syntaxHighlight.bind(this)),this.trigger("focus")}_paste(e){e.preventDefault();let t,n=this.getPos();t=e.clipboardData.getData("text/plain");let i=this.value();i=i.substr(0,n.begin)+t+i.substr(n.end),this.value(i),this.setPos(n.begin+t.length),this.scale()}_move(e){let t=this.list,n=this.popup;if(n.visible()){if(e===e_)return t.focusNext(),!0;if(e===Jv)return t.focusPrev(),!0;if(e===Zv||e===Xv){let e="function"==typeof t.focusIndex?t.focusIndex():t.focus();return t.data()[e]&&this._formulaListChange(t.data()[e].value),n.close(),!0}if(e===t_)return t.focusFirst(),!0;if(e===n_)return t.focusLast(),!0}return!1}_tokenContext(){let e=this.getPos(),t=this.value();if(!t||!e||!e.collapsed)return null;let n,i=z_.tokenize(t,this.row(),this.col());for(let t=0;t<i.length;++t)if(n=i[t],Ak(n,e)&&/^(?:str|sym|func)$/.test(n.type))return{token:n,nextToken:i[t+1]};return null}_sync(){this._editorToSync&&this.isActive()&&this._editorToSync.value(this.value())}_textContainer(){let e=function(e,t){let n,i={};return document.defaultView&&document.defaultView.getComputedStyle?(n=document.defaultView.getComputedStyle(e,""),t&&t.forEach((function(e){i[e]=n.getPropertyValue(e)}))):(n=e.currentStyle,t&&t.forEach((function(e){var t;i[e]=n[(t=e,t.replace(/\-(\w)/g,(function(e,t){return t.toUpperCase()})))]}))),function(e){let t,n=0;for(t in e)e.hasOwnProperty(t)&&"toJSON"!==t&&n++;return n}(i)||(i=n),i}(this.element,xk);e.position="absolute",e.visibility="hidden",e.whiteSpace="pre",e.top=-3333,e.left=-3333,this._span=document.createElement("span"),this._span.style.whiteSpace="pre";for(const t in e)Object.hasOwnProperty.call(e,t)&&(this._span.style[t]=e[t]);k_(this._span,this.element)}_tooltip(){this._cellTooltip=document.createElement("div"),this._cellTooltip.className="k-widget k-tooltip",this._cellTooltip.style.position="absolute",this._cellTooltip.style.display="none",this._cellTooltip.appendChild(document.createTextNode("A1")),k_(this._cellTooltip,this.element)}tooltip(e){for(;this._cellTooltip.firstChild;)this._cellTooltip.removeChild(this._cellTooltip.firstChild);this._cellTooltip.appendChild(document.createTextNode(e))}toggleTooltip(e){this._cellTooltip.style.display=e?"":"none"}isActive(){return this.element===function(){try{return document.activeElement}catch(e){return document.documentElement.activeElement}}()}filter(e){if(!e||e.length<this.options.minLength)return;const t=this.formulaSource.filter((t=>String(t.value).toLowerCase().startsWith(e.toLowerCase())));return this.list.data(t),t}hide(){this.enable(!1),this.element.style.display="none",this._cellTooltip.style.display="none"}show(){this.enable(!0),this.element.style.display="block"}row(){if(this.activeCell)return this.activeCell.row}col(){if(this.activeCell)return this.activeCell.col}position(e){e&&(this.show(),this.element.style.top=e.top+1+"px",this.element.style.left=e.left+1+"px",this._cellTooltip.style.top=e.top-this._cellTooltip.offsetHeight-10+"px",this._cellTooltip.style.left=e.left+"px")}resize(e){e&&(this.element.style.width=e.width-1+"px",this.element.style.height=e.height-1+"px")}canInsertRef(e){return this._canInsertRef(e)}_canInsertRef(e){if(this.popup.visible())return null;let t,n,i,r=e,o=this.getPos();if(o&&this._isFormula()){if(0===o.begin)return null;for(t=z_.tokenize(this.value(),this.row(),this.col()),i=0;i<t.length;++i){if(n=t[i],Ak(n,o))return s(n);if(a(n))return l(t[i-1],n)}return l(n,null)}return null;function a(e){return e.begin>o.begin}function s(e){if(e){if(/^(?:num|str|bool|sym|ref)$/.test(e.type))return{replace:!0,token:e,end:e.end};if(/^(?:op|punc|startexp)$/.test(e.type))return e.end===o.end?l(e,t[i+1]):l(t[i-1],e)}}function l(e,t){if(null==e)return null;if(null==t)return/^(?:op|startexp)$/.test(e.type)||Dk(e.value)?{token:e,end:o.end}:null;if(r){if("op"===e.type&&/^(?:punc|op)$/.test(t.type))return{token:e,end:o.end}}else{if("startexp"===e.type)return{token:e,end:o.end};if(/^(?:op|punc)$/.test(e.type)&&/^[,;({]$/.test(e.value))return{token:e,end:o.end};if(/^(?:ref|sym)/.test(e.type))return{token:e,replace:!0,end:e.end};if(/^(?:ref|sym)/.test(t.type))return{token:t,replace:!0,end:t.end}}return!1}}refAtPoint(e){let t=this._canInsertRef();if(t){let n=e.selection()._ref.simplify().clone().relative(0,0,3);e.isMerged(n)&&(n=n.topLeft),e!==this.activeSheet&&(n=n.setSheet(e.name(),!0)),this._replaceAt(t,n.print(0,0))}}_replaceAt(e,t){let n=this.value(),i=e.token,r=n.substr(e.end);n=n.substr(0,e.replace?i.begin:e.end)+t;let o=n.length;n+=r,this._value(n),this.setPos(o),this.scale(),this._syntaxHighlight()}syncWith(e){this._editorToSync=e,this.element&&(this.element.removeEventListener("input",this._sync),this.element.addEventListener("input",this._sync))}scale(){let e,t,n=this.element;this._span||this._textContainer(),this._span.innerHTML=n.innerHTML,e=this._span.offsetWidth+this.options.scalePadding,t=this._span.offsetHeight,e>n.offsetWidth&&(n.style.width=e+"px");t-1>n.offsetHeight&&(n.style.height=t-1+"px"),this._sync()}_value(e){if((this.element.innerText||this.element.textContent).replace(/\n$/,"")!==e){for(;this.element.firstChild;)this.element.removeChild(this.element.firstChild);this.element.appendChild(document.createTextNode(e))}}value(e){let t=(this.element.innerText||this.element.textContent).replace(/\n$/,"");if(void 0===e)return t;t!==e&&(this._value(e),this._syntaxHighlight())}highlightedRefs(){return this._highlightedRefs.slice()}_syntaxHighlight(){let e=this.getPos(),t=this.value(),n=kk.classNames.series,i=[],r=0,o=[],a=[];e&&!e.collapsed||(/^=/.test(t)?(a=z_.tokenize(t,this.row(),this.col()),a.forEach((function(t){if(t.active=!1,t.cls=["k-syntax-"+t.type],"ref"===t.type&&(t.colorClass=n[r++%n.length],t.cls.push(t.colorClass),i.push(t)),e&&"punc"===t.type)if(Dk(t.value))o.unshift(t);else if(")"===(a=t.value)||"]"===a||"}"===a){let n=o.shift();n?!function(e,t){return"("===t?")"===e:"["===t?"]"===e:"{"===t&&"}"===e}(t.value,n.value)?(t.cls.push("k-syntax-error"),n.cls.push("k-syntax-error")):(Ak(t,e)||Ak(n,e))&&(t.cls.push("k-syntax-paren-match"),n.cls.push("k-syntax-paren-match")):t.cls.push("k-syntax-error")}var a;e&&Ak(t,e)&&(t.cls.push("k-syntax-at-point"),t.active=!0),"func"!==t.type||function(e){return z_.runtime.FUNCS[e.toLowerCase()]}(t.value)||e&&Ak(t,e)||t.cls.push("k-syntax-error")})),a.reverse().forEach((function(e){let n=e.begin,i=e.end,r=function(e){return String(e).replace(aw,"&amp;").replace(sw,"&lt;").replace(dw,"&gt;").replace(lw,"&quot;").replace(cw,"&#39;")}(t.substring(n,i));t=t.substr(0,n)+"<span class='"+e.cls.join(" ")+"'>"+r+"</span>"+t.substr(i)})),this.element.innerHTML=t,e&&this.setPos(e.begin,e.end),this._highlightedRefs=i):this._highlightedRefs.length&&(this._highlightedRefs=[],this._value(t)))}destroy(){this._editorToSync=null,this.element.removeEventListener("input",this.scale),this.element.removeEventListener("keydown",this._keydown),this.element.removeEventListener("keyup",this._keyup),this.element.removeEventListener("blur",this._blur),this.element.removeEventListener("input",this._input),this.element.removeEventListener("click",this._input),this.element.removeEventListener("focus",this._focus),this.element.removeEventListener("paste",this._paste),clearTimeout(this._focusTimeout),clearTimeout(this._keyDownTimeout),this._cellTooltip=null,this._span=null,super.destroy()}insertNewline(){let e=this.value(),t=this.getPos(),n=t.end===e.length;e=e.substr(0,t.begin)+(n?"\n\n":"\n"+e.substr(t.end)),this.value(e),this.setPos(t.begin+1)}}function Dk(e){return"("===e||"["===e||"{"===e}function Ak(e,t){return e.begin<=t.begin&&e.end>=t.end}Tk.classNames={wrapper:"k-spreadsheet-formula-input",listWrapper:"k-spreadsheet-formula-list"};class Mk extends rw{constructor(e,t){super(e,t);const n=e&&e.querySelector(".k-spreadsheet-formula-input:not(.k-spreadsheet-cell-editor)");this.formulaInput=new Tk(n,this.options)}destroy(){this.formulaInput&&this.formulaInput.destroy(),this.formulaInput=null}}class Ek extends rw{readData(){const e=[];return this._workbook.forEachName((function(t){!t.hidden&&t.value instanceof Ov&&e.push({name:t.name})})),e}value(e){if(this.options.combobox.current)return this.options.combobox.current.value(e)}}class Ik extends rw{constructor(e,t){super(e,Object.assign({},{name:"SheetsBar"},t)),this.events=["select","reorder","rename"]}onSheetReorderEnd(e){this.trigger("reorder",{oldIndex:e.oldIndex,newIndex:e.newIndex})}onSheetRemove(e){this.trigger("remove",{name:e,confirmation:!0})}onSheetSelect(e){this.trigger("select",{name:e,isAddButton:!1})}onSheetRename(e,t){this.trigger("rename",{name:e,sheetIndex:t})}onAddSelect(){this.trigger("select",{isAddButton:!0})}destroy(){super.destroy()}}class zk{constructor(){this.cols=[],this.trs=[],this._height=0,this._width=0}addColumn(e){this._width+=e;let t=fb.element("col",{style:{width:e+"px"}});t.visible=e>0,this.cols.push(t)}addRow(e){let t=null;t={style:{height:e+"px"}},this._height+=e;let n=fb.element("tr",t);n.visible=e>0,this.trs.push(n)}addCell(e,t,n,i,r){null==t&&(t=""),t instanceof fb.Node||(t=fb.text(t));let o=[t];r&&!r.value&&(o.push(fb.element("span",{className:"k-dirty"})),i=(i||"")+(i?" ":"")+"k-dirty-cell",n.title=r.message),i&&(n.className=i);let a=fb.element("td",n,o);return this.trs[e].children.push(a),a}toDomTree(e,t,n){this.trs=this.trs.filter((function(e){return e.visible}));let i=0;return this.cols=this.cols.filter((function(e,t){return e.visible||(this.trs.forEach((function(e){e.children.splice(t-i,1)})),i++),e.visible}),this),fb.element("table",{style:{left:e+"px",top:t+"px",height:this._height+"px",width:this._width+"px"},className:n,role:"presentation"},[fb.element("colgroup",null,this.cols),fb.element("tbody",null,this.trs)])}}function Pk(e,t,n){return e>=t&&e<=n}class Hk extends iw{constructor(e,t){super();let n=Hk.classNames;if(this.element=e,this.options=__({},{messages:Gv.view},this.options,t),this.events=["update","message"],this._chrome(),this._dialogs=[],this._formulaInput(),this.wrapper=e.querySelector(gk+n.view),this.container=e.querySelector(gk+n.fixedContainer),this.scroller=e.querySelector(gk+n.scroller),this.clipboard=e.querySelector(gk+n.clipboard),this.viewSize=this.scroller?this.scroller.querySelector(".k-spreadsheet-view-size")||this.scroller.firstElementChild:null,!this.viewSize)throw new Error("The scroller element does not contain a view size element.");this.tree=new fb.Tree(this.container),this.clipboardContents=new fb.Tree(this.clipboard),this.editor=new ow(this),this._sheetsbar(),this.options.createContextMenus?.()}enableClipboard(e){this.isClipboardDeactivated=!e,e?this.clipboard.setAttribute("contenteditable",e):this.clipboard.removeAttribute("contenteditable")}_resize(){}_chrome(){let e=this.element.querySelector(".k-spreadsheet-name-editor");this.nameEditor=new Ek(e,{combobox:this.options.nameBoxRef});let t=this.element.querySelector(".k-spreadsheet-formula-bar");this.formulaBar=new Mk(t,{input:this.options.formulaBarInputRef}),this._tabstrip()}_formulaInput(){let e=this.element.querySelector(gk+Hk.classNames.cellEditor);this.formulaInput=new Tk(e,{autoScale:!0,input:this.options.formulaCellInputRef})}_sheetsbar(){this.options.sheetsbar&&(this.sheetsbar=new Ik(this.element.querySelector(gk+Hk.classNames.sheetsBar),this.options.sheetsbar),this.options.createSheetBar?.(this.options.openDialogCallback))}_tabstrip(){this.tabstrip=this.options.createTabStrip?.()}_executeCommand(e){this._sheet.trigger("commandRequest",e)}workbook(e){this._workbook=e,e._view=this,this.nameEditor._workbook=e}sheet(e){this._sheet=e}activeCellRectangle(){return this.cellRectangle(this._sheet._viewActiveCell())}_rectangle(e,t){return e._grid.boundingRectangle(t.toRangeRef())}isColumnResizer(e,t,n){return e-=this._sheet._grid._headerWidth,t._grid.columns.frozen||(e+=this.scroller.scrollLeft),null===(n=this._sheet._grid._columns.locate(0,n,(function(t){return Math.abs(e-t)<=3.5})))||this._sheet.isHiddenColumn(n)?null:n}isRowResizer(e,t,n){return e-=this._sheet._grid._headerHeight,t._grid.rows.frozen||(e+=this.scroller.scrollTop),null===(n=this._sheet._grid._rows.locate(0,n,(function(t){return Math.abs(e-t)<=3.5})))||this._sheet.isHiddenRow(n)?null:n}isFilterIcon(e,t,n,i){let r=this,o=n._grid,a=o.rows.frozen?0:r.scroller.scrollTop,s=o.columns.frozen?0:r.scroller.scrollLeft;return e-=r._sheet._grid._headerWidth-s,t-=r._sheet._grid._headerHeight-a,f_((function(o){r._sheet.forEachFilterHeader(i,(function(i){let a=r._rectangle(n,i);n.filterIconRect(a).intersects(e,t)&&o(!0)}))}))}isAutoFill(e,t,n){let i=this._sheet.select();if(i.size>1)return!1;e-=this._sheet._grid._headerWidth,t-=this._sheet._grid._headerHeight,n._grid.columns.frozen||(e+=this.scroller.scrollLeft),n._grid.rows.frozen||(t+=this.scroller.scrollTop);let r=this._rectangle(n,i);return Math.abs(r.right-e)<8&&Math.abs(r.bottom-t)<8}isEditButton(e,t,n){if(this._sheet.activeCellCustomEditor()){let i=this.activeCellRectangle();if(t>=i.top&&t<=i.bottom)return n._editorInLastColumn?e<i.left&&e>=i.left-20:e>i.right&&e<=i.right+20}}drawingAt(e,t,n){e-=this._sheet._grid._headerWidth,t-=this._sheet._grid._headerHeight,n._grid.columns.frozen||(e+=this.scroller.scrollLeft),n._grid.rows.frozen||(t+=this.scroller.scrollTop);let i=this._sheet,r=this._sheet._drawings;for(let n=r.length;--n>=0;){let o=r[n],a=i.drawingBoundingBox(o);if(a.intersects(e,t))return{drawing:o,drx:a.left-e,dry:a.top-t}}}objectAt(e,t,n){let i,r,o=this._sheet._grid;if(e<0||t<0||e>this.scroller.clientWidth||t>this.scroller.clientHeight)i={type:"outside"};else if(e<o._headerWidth&&t<o._headerHeight)i={type:"topcorner"};else if(r=this.paneAt(e,t),r){if(!n){let n=this.drawingAt(e,t,r);if(n)return{type:"drawing",drawing:n.drawing,drx:n.drx,dry:n.dry,pane:r,startX:e,startY:t}}let a=r._grid.rows.indexVisible(t,this.scroller.scrollTop),s=r._grid.columns.indexVisible(e,this.scroller.scrollLeft),l="cell",c=new $v(a,s),d=this._sheet.selectionInProgress();this.isAutoFill(e,t,r)?l="autofill":this.isFilterIcon(e,t,r,c)?l="filtericon":!d&&e<o._headerWidth?(l="rowheader",null!==(a=this.isRowResizer(t,r,a))&&(c=new $v(a,-1/0),l="rowresizehandle")):!d&&t<o._headerHeight?(l="columnheader",null!==(s=this.isColumnResizer(e,r,s))&&(c=new $v(-1/0,s),l="columnresizehandle")):this.isEditButton(e,t,r)&&(l="editor"),i={type:l,ref:c}}else i={type:"outside"};return i.pane=r,i.x=e,i.y=t,i}paneAt(e,t){return this.panes.filter((function(n){let i=n._grid;return Pk(t,i.top,i.bottom)&&Pk(e,i.left,i.right)}))[0]}containingPane(e){return this.panes.filter((function(t){return!!t._grid.contains(e)}))[0]}cellRectangle(e){let t=this.containingPane(e)._grid;return this._sheet._grid.rectangle(e).offset(t.headerWidth-(t.columns.frozen?0:this.scroller.scrollLeft),t.headerHeight-(t.rows.frozen?0:this.scroller.scrollTop))}refresh(e){let t=this._sheet;if(this.trigger("update",{reason:e,range:t.range(t.activeCell()),sheet:t}),this._resize(),this.viewSize.style.height=t._grid.totalHeight()+"px",this.viewSize.style.width=t._grid.totalWidth()+"px",e.layout){let e=t.frozenColumns(),n=t.frozenRows();this.panes=[this._pane(n,e)],e>0&&this.panes.push(this._pane(n,0,null,e)),n>0&&this.panes.push(this._pane(0,e,n,null)),n>0&&e>0&&this.panes.push(this._pane(0,0,n,e))}e.filter&&this._destroyFilterMenu(),e.activeCell&&(this._focus=t.activeCell().toRangeRef())}createFilterMenu(e){this._destroyFilterMenu();let t=this._sheet,n=t.filter().ref,i={column:e,range:new Wy(n,t)};return this._filterMenu=this.options.createFilterMenu(i),this._filterMenu}selectClipboardContents(){this.isClipboardDeactivated||(this.clipboard.focus({preventScroll:!0}),function(e){let t=window.getSelection();t.removeAllRanges();let n=document.createRange();n.selectNodeContents(e),t.addRange(n)}(this.clipboard))}scrollIntoView(e){let t=!1,n=this.containingPane(e)._grid,i=n.scrollBoundaries(e),r=this.scroller,o=n.rows.frozen?0:r.scrollTop,a=n.columns.frozen?0:r.scrollLeft;return i.top<o&&(t=!0,r.scrollTop=i.scrollTop),i.bottom>o&&(t=!0,r.scrollTop=i.scrollBottom),i.left<a&&(t=!0,r.scrollLeft=i.scrollLeft),i.right>a&&(t=!0,r.scrollLeft=i.scrollRight),t}_destroyDialog(){this._dialogs.pop()}openCustomEditor(){let e=this,t=e._sheet.activeCell().first(),n=e._sheet.activeCellCustomEditor(),i=e._sheet.range(t);n.edit({range:i,rect:e.activeCellRectangle(),view:this,validation:this._sheet.validation(t),callback:function(t,n){e._executeCommand({command:"EditCommand",options:{operatingRange:i,editRange:i,property:n?"input":"value",value:t}})}})}openDialog(e,t){let n=this._sheet;return n.withCultureDecimals(function(){let i=n.activeCell(),r=new Wy(i,n),o={...t,name:e,ref:i,range:r};return this.trigger("message",o),o.dialog}.bind(this))}showError(e,t){let n=this._dialogs,i=this.options.messages.errors;if(n.length>0)return;let r=function(){n.pop(),this.selectClipboardContents(),t&&t()}.bind(this);const o={title:e.title||"Error",text:e.body?e.body:i[e.type],close:r};n.push(o),this.openDialog(e.type||"message",o)}destroy(){this.unbind(),[this.tree,this.clipboardContents].forEach((e=>{for(;e&&e.root&&e.root.lastChild;)e.root.removeChild(e.root.lastChild)})),this.tree=this.clipboardContents=null,this.tabstrip&&(this.tabstrip.destroy(),this.tabstrip=null),this._destroyFilterMenu()}_destroyFilterMenu(){this._filterMenu&&(this._filterMenu.destroy(),this._filterMenu=void 0)}render(e){let t=this._sheet,n=t.focus(),i=w_(),r=this.wrapper.clientWidth-i,o=this.wrapper.clientHeight-i;if(n&&this.scrollIntoView(n))return;let a=t.resizingInProgress()?t.resizeHandlePosition().col===-1/0?"column":"row":"none";this.wrapper.classList.toggle(vk.editContainer,this.editor.isActive()),this.wrapper.classList.toggle(vk.horizontalResize,"row"===a),this.wrapper.classList.toggle(vk.verticalResize,"column"===a);let s=t._grid,l=[],c={scroller:this.scroller,toplevelElements:l,contentWidth:r,contentHeight:o};this.panes.forEach((function(e){l.push(e.render(c))}));let d=fb.element("div",{style:{width:s._headerWidth+"px",height:s._headerHeight+"px"},className:Hk.classNames.topCorner});l.push(d),t.resizeHandlePosition()&&t.resizeHintPosition()&&l.push(this.renderResizeHint()),this.tree.render(l),this.container.style.width=r+"px",this.container.style.height=o+"px",this.editor.isActive()?this.editor.toggleTooltip(this.activeCellRectangle()):e.resize||e.comment||t.selectionInProgress()||t.resizingInProgress()||t.draggingInProgress()||t.isInEditMode()||this.renderClipboardContents()}renderResizeHint(){let e,t=this._sheet,n=t.resizeHandlePosition().col!==-1/0;e=n?{height:this.scroller.clientHeight+"px",width:"7px",left:t.resizeHintPosition().x+"px",top:"0px"}:{height:"7px",width:this.scroller.clientWidth+"px",top:t.resizeHintPosition().y+"px",left:"0px"};let i=kk.classNames;return fb.element("div",{className:i.resizeHint+(n?"":" "+i.resizeHintVertical),style:e},[fb.element("div",{className:i.resizeHintHandle}),fb.element("div",{className:i.resizeHintMarker})])}renderClipboardContents(){let e=this._sheet,t=e._grid,n=t.normalize(e.select().toRangeRef()),i=this._workbook.clipboard().canCopy();if(!1===i.canCopy&&i.multiSelection)return this.clipboardContents.render([]),void this.selectClipboardContents();n=e.trim(n);let r=new zk,o=t.rangeDimensions(n);o.rows.forEach((function(e){r.addRow(e)})),o.columns.forEach((function(e){r.addColumn(e)}));let a=e._getMergedCells(n),s=a.primary,l=a.secondary;e.forEach(n,(function(e,t,i){let o=new $v(e,t).print();if(!l[o]){let t=function(e,t,n){let i={};n.background&&(i.backgroundColor=n.background),n.color&&(i.color=n.color),n.fontFamily&&(i.fontFamily=n.fontFamily),n.underline&&(i.textDecoration="underline"),n.italic&&(i.fontStyle="italic"),n.textAlign&&(i.textAlign=n.textAlign),n.verticalAlign&&(i.verticalAlign="center"===n.verticalAlign?"middle":n.verticalAlign),n.bold&&(i.fontWeight="bold"),n.fontSize&&(i.fontSize=n.fontSize+"px"),!0===n.wrap&&(i.whiteSpace="pre-wrap"),n.borderRight?i.borderRight=bk(n.borderRight):n.background&&(i.borderRightColor=n.background),n.borderBottom?i.borderBottom=bk(n.borderBottom):n.background&&(i.borderBottomColor=n.background);let r=n.value,o=typeof r,a=n.format;a||"number"!==o||r===Math.floor(r)||(a="0.##############"),a&&null!=r&&(r=Sb.format(r,a),r.__dataType&&(o=r.__dataType));let s={style:i};if(!i.textAlign)switch(o){case"number":case"date":case"percent":case"currency":i.textAlign="right";break;case"boolean":i.textAlign="center"}/^(?:string|undefined)$/.test(o)||(s.sdval=n.value,s["data-sheets-value"]=JSON.stringify({1:3,3:n.value}),a&&(s.sdnum=a,s["data-sheets-numberformat"]=JSON.stringify({1:2,2:a,3:1}))),n.formula&&(s["data-sheets-formula"]="="+n.formula.print());let l=null;!1===n.enable&&(l="k-disabled");let c,d,u=e.addCell(t,r,s,l,n.validation);return n.borderLeft?(d=function(e,t){let n=e.trs[t].children;return n[n.length-2]}(e,t),c=bk(n.borderLeft),d&&c&&(d.attr.style.borderRight=c)):n.background&&(i.borderLeftColor=n.background),n.borderTop?(d=function(e,t){let n=e.trs[t-1],i=e.trs[t].children.length-1;if(n&&i>=0)return n.children[i]}(e,t),c=bk(n.borderTop),d&&c&&(d.attr.style.borderBottom=c)):n.background&&(i.borderTopColor=n.background),u}(r,e-n.topLeft.row,i),a=s[o];a&&(t.attr.colspan=a.width(),t.attr.rowspan=a.height())}})),this.clipboardContents.render([r.toDomTree(0,0,"kendo-clipboard-"+this._workbook.clipboard()._uid)]),this.selectClipboardContents()}_pane(e,t,n,i){let r=new kk(this._sheet,this._sheet._grid.pane({row:e,column:t,rowCount:n,columnCount:i}),this.options.getIconHTMLString);return r.refresh(this.scroller.clientWidth,this.scroller.clientHeight),r}}Hk.classNames=vk;const Fk=/<table[^>]+>/gim,Rk=e=>(e||"").match(Fk)||[];class Lk{constructor(e){this._content={},this._externalContent={},this._internalContent={},this.workbook=e,this.origin=Vv,this.iframe=document.createElement("iframe"),this.iframe.className="k-spreadsheet-clipboard-paste",this.iframe.setAttribute("title","Spreadsheet clipboard iframe"),this.menuInvoked=!1,this._uid=function(){let e,t,n="";for(n+="abcdef"[Math.floor(Math.random()*Math.floor(6))],e=1;e<32;e++)t=16*Math.random()|0,8!==e&&12!==e&&16!==e&&20!==e||(n+="-"),n+=(12===e?4:16===e?3&t|8:t).toString(16);return n}(),document.body.appendChild(this.iframe)}destroy(){this.iframe&&this.iframe.parentNode&&this.iframe.parentNode.removeChild(this.iframe)}canCopy(){let e={canCopy:!0},t=this.workbook.activeSheet().select();return t===Vv&&(e.canCopy=!1),t instanceof Wv&&(e.canCopy=!1,e.multiSelection=!0),this.menuInvoked&&(e.canCopy=!1,e.menuInvoked=!0),e}canPaste(){let e=this.workbook.activeSheet(),t=this.pasteRef(),n={canPaste:!0,pasteOnMerged:!1,pasteOnDisabled:!1};return e.range(t).enable()||(n.canPaste=!1,n.pasteOnDisabled=!0),t.eq(e.unionWithMerged(t))||(n.canPaste=!1,n.pasteOnMerged=!0),this.menuInvoked&&(n.canPaste=!1,n.menuInvoked=!0),n}intersectsMerged(){let e=this.workbook.activeSheet();this.parse(),this.origin=this._content.origRef;let t=this.pasteRef();return!t.eq(e.unionWithMerged(t))}copy(){let e=this.workbook.activeSheet();this.origin=e.select(),this._internalContent=e.selection().getState(),delete this._externalContent.html,delete this._externalContent.plain}cut(){let e=this.workbook.activeSheet();this.copy(),e.range(e.select()).clear()}pasteRef(){let e=this.workbook.activeSheet();if(this.origin===Vv)return e.select();let t=e.activeCell().first(),n=this.origin.first(),i=n.row-t.row,r=n.col-t.col;return this.origin.relative(i,r,3)}paste(){let e=this.workbook.activeSheet(),t=this.pasteRef();(t.bottomRight.row>=e._rows._count||t.bottomRight.col>=e._columns._count)&&e.resize(Math.max(t.bottomRight.row+1,e._rows._count),Math.max(t.bottomRight.col+1,e._columns._count)),e.range(t).setState(this._content,this),e.triggerChange({recalc:!0,ref:t})}external(e){if(!e||!e.html&&!e.plain)return this._externalContent;this._externalContent=e}isExternal(){return!this._isInternal()}parse(){let e;if(this._isInternal())e=this._internalContent;else{let t=this._externalContent;if(e=t.plain?function(e){let t=Bk();if(-1===e.indexOf("\t")&&-1===e.indexOf("\n"))Ok(t,0,0,{value:e});else{let n=e.split("\n");for(let e=0;e<n.length;e++){let i=n[e].split("\t");for(let n=0;n<i.length;n++)Ok(t,e,n,{value:i[n]})}}return t}(t.plain):Bk(),t.html){let n=this.iframe.contentWindow.document;n.open(),n.write(t.html),n.close();let i=n.querySelector("table"),r=n.head.querySelector("meta[name=ProgId]")?.getAttribute("content");if(i){let t=function(e,t){let n=Bk(),i=[],r=0,o=0;for(let t=0;t<e.rows.length;++t)i.push([]);let a=new z_.runtime.Matrix,s=new z_.runtime.Matrix;for(let l=0;l<e.rows.length;++l,++r){let c=e.rows[l];o=0;for(let e=0;e<c.cells.length;++e){let l=c.cells[e],d=l.rowSpan,u=l.colSpan;for(;i[r][o];)o++;let h=l.getAttribute("style"),p=/mso-ignore:colspan/.test(h);Ok(n,r,o,Nk(r,o,l,a,s,t)),(d>1||u>1&&!p)&&n.mergedCells.push(new Uv(new $v(r,o),new $v(r+d-1,o+u-1)).toString());for(let e=r+d;--e>=r;)for(let t=o+u;--t>=o;)e<i.length&&(i[e][t]=!0,e===r&&t===o||Ok(n,e,t,{}))}}return n}(i,r);t.data.forEach((function(t,n){t.forEach((function(t,i){/^\s*#+\s*$/.test(t.value)&&(t.value=e.data[n][i].value)}))})),e=t}}this.origin=e.origRef}this._content=e}_isInternal(){if(void 0===this._externalContent.html)return!0;const e="kendo-clipboard-"+this._uid,t=t=>t.some((t=>t.includes(e)));return t(Rk(this._externalContent.html))||t(Rk(this._externalContent.plain))}}function Bk(){let e=new $v(0,0,0);return{ref:e,mergedCells:[],data:[],foreign:!0,origRef:e.toRangeRef()}}function Ok(e,t,n,i){let r=e.data||(e.data=[]);r[t]||(r[t]=[]),r[t][n]=i;let o=e.origRef.bottomRight;o.row=Math.max(o.row,t),o.col=Math.max(o.col,n)}function Vk(e){return e.replace(/^-(?:ms|moz|webkit)-/,"")}function Nk(e,t,n,i,r,o){let a,s,l,c=window.getComputedStyle(n),d="string"==typeof o&&o.indexOf("Excel")>-1;!d&&(a=n.getAttribute("data-sheets-value"))&&(a=JSON.parse(a),a=a[a[1]]),!d&&(s=n.getAttribute("data-sheets-numberformat"))&&(s=JSON.parse(s),s=s[s[1]]),l=n.getAttribute("data-sheets-formula"),d||null!=a||null!=s||null!=l||(a=n.getAttribute("sdval"),s=n.getAttribute("sdnum"),s&&(s=s.replace(/^1033;(?:0;)?/,""))),null==a&&(a=(n.innerText||n.textContent).replace(/\t$/,""));let u=function(e,t){e.className||(t=e.style);let n={};return["borderBottom","borderRight","borderLeft","borderTop"].forEach((function(e){let i=t[e+"Width"];i&&(i=parseInt(i,10)),i&&(n[e]={size:i,color:t[e+"Color"]||"#000"})})),n}(n,c),h={value:""===a?null:a,formula:l,borderTop:u.borderTop||i.get(e,t)||null,borderBottom:u.borderBottom||i.get(e+1,t)||null,borderLeft:u.borderLeft||r.get(e,t)||null,borderRight:u.borderRight||r.get(e,t+1)||null,fontSize:parseInt(c.fontSize,10)};null!=s&&(h.format=s),i.set(e,t,h.borderTop),i.set(e+1,t,h.borderBottom),r.set(e,t,h.borderLeft),r.set(e,t+1,h.borderRight),"rgb(0, 0, 0)"!==c.backgroundColor&&"rgba(0, 0, 0, 0)"!==c.backgroundColor&&(h.background=c.backgroundColor),"right"!==Vk(c.textAlign)&&(h.textAlign=Vk(c.textAlign)),"middle"!==c.verticalAlign&&(h.verticalAlign=c.verticalAlign),"normal"!==c.wordWrap&&(h.wrap=!0);const p=n.querySelector("font");return p&&(c=window.getComputedStyle(p)),"rgb(0, 0, 0)"!==c.color&&"rgba(0, 0, 0, 0)"!==c.color&&(h.color=c.color),/^underline/.test(c.textDecoration)&&(h.underline=!0),"italic"==c.fontStyle&&(h.italic=!0),/^(?:bold|[67]00)$/i.test(c.fontWeight)&&(h.bold=!0),h}let $k="autoFill",Uk="clear",Wk="cut",jk="edit",qk="paste",Gk="validation";const Kk=()=>{};class Yk{constructor(e){this.options=e,this._workbook=e.workbook,this._property=e&&e.property,this._state={}}range(e){return void 0!==e&&this._setRange(e),this._range}_setRange(e){this._range=e}redo(){this.range().select(),this.exec()}undo(){this.setState(this._state)}getState(){this._state=this.range().getState(this._property)}setState(e){this.range().setState(e)}rejectState(e){return this.undo(),{title:e.title,body:e.message,reason:"error",type:"validationError"}}_forEachCell(e){let t=this.range();t._ref.forEach(function(n){t.sheet().forEach(n.toRangeRef(),e.bind(this))}.bind(this))}usesImage(){return!1}}class Qk extends Yk{constructor(e){super(e),this._sheet=e.sheet,this._drawing=e.drawing,this._orig=this._drawing.clone(),this._previous=e.previous}exec(){}undo(){this._drawing.reset(this._previous),this._sheet._activeDrawing=this._drawing,this._sheet.triggerChange({layout:!0})}redo(){this._drawing.reset(this._orig),this._sheet._activeDrawing=this._drawing,this._sheet.triggerChange({layout:!0})}usesImage(e){return this._drawing.image===e||this._orig.image===e||this._previous.image===e}}class Xk extends Yk{constructor(e){super(e),this._drawing=e.drawing}usesImage(e){return this._drawing.image===e}}class Zk extends Xk{constructor(e){super(e),this._blob=e.blob,this._width=e.width,this._height=e.height}exec(){let e=this.range(),t=e.sheet(),n=this._width,i=this._height,r=n/i;n>i?(n=Math.min(n,300),i=n/r):(i=Math.min(i,300),n=i*r),this._drawing=t.addDrawing({topLeftCell:e.topLeft(),offsetX:5,offsetY:5,width:n,height:i,opacity:1,image:this._workbook.addImage(this._blob)},!0),this._blob=null}undo(){let e=this.range().sheet();e._activeDrawing=null,e.removeDrawing(this._drawing)}redo(){let e=this.range().sheet();e._activeDrawing=this._drawing,e.addDrawing(this._drawing)}}class Jk extends Xk{exec(){let e=this.range().sheet();e._activeDrawing=null,e.removeDrawing(this._drawing)}undo(){let e=this.range().sheet();e._activeDrawing=this._drawing,e.addDrawing(this._drawing)}redo(){this.exec()}}class ex extends Xk{exec(){let e=this.range().sheet();this._origIndex=e._drawings.indexOf(this._drawing),e._drawings.splice(this._origIndex,1),this._newIndex=this._reorder(),e._drawings.splice(this._newIndex,0,this._drawing),e.triggerChange({drawings:!0})}undo(){let e=this.range().sheet();e._drawings.splice(this._newIndex,1),e._drawings.splice(this._origIndex,0,this._drawing),e.triggerChange({drawings:!0})}}class tx extends ex{_reorder(){return this.range().sheet()._drawings.length}}class nx extends ex{_reorder(){return 0}}class ix extends Yk{constructor(e){super(e),this._target=e.target,this._value=e.value}exec(){this.getState(),this.setState(this._value)}}class rx extends ix{getState(){this._state=this.range().sheet().columnWidth(this._target)}setState(e){this.range().sheet().columnWidth(this._target,e)}}class ox extends ix{getState(){this._state=this.range().sheet().rowHeight(this._target)}setState(e){this.range().sheet().rowHeight(this._target,e)}}class ax extends Yk{constructor(e){super(e),this._link=e.link}exec(){let e=this.range();this._prevLink=e.link(),this._prevUnderline=e.underline(),e.link(this._link),e.underline(!0),null==e.value()&&(this._hasSetValue=!0,e.value(this._link))}undo(){let e=this.range();e.link(this._prevLink),e.underline(this._prevUnderline),this._hasSetValue&&e.value(null)}}class sx extends ix{getState(){this._state=this._range.sheet().showGridLines()}setState(e){this._range.sheet().showGridLines(e)}}class lx extends Yk{_setRange(e){Yk.prototype._setRange.call(this,e.skipHiddenCells())}constructor(e){super(e),this._value=e.value}exec(){let e=this.range();e.enable()&&(this.getState(),"format"===this.options.property&&this._workbook.trigger("changeFormat",{range:e}),e[this._property](this._value))}}class cx extends lx{exec(){let e=this.range();e.enable()&&(this.getState(),e.clearFormat())}}class dx extends Yk{exec(){let e,t,n,i,r,o=[];return this.range().enable()?this.range().canEditArrayFormula()?(this.getState(),e=this.range().skipHiddenCells(),e._ref.refs&&e._ref.refs.length>1?e._ref.refs.forEach((function(t){r=e.sheet().range(t),o=o.concat(r.values())})):o=e.values(),n=[],o.forEach((function(e){t=[],e.forEach((function(){t.push(null)})),n.push(t)})),e.sheet().trigger("changing",{data:n,range:e,changeType:Uk})?void 0:(e.clearContent(),i=e._getValidationState(),i?this.rejectState(i):void 0)):{reason:"error",type:"intersectsArray"}:{reason:"error",type:"cannotModifyDisabled"}}undo(){let e,t=this.range().skipHiddenCells(),n=t.sheet(),i=this._state.data,r=[];i.forEach((function(t){e=[],t.forEach((function(t){e.push(t.value)})),r.push(e)})),n.trigger("changing",{data:r,range:t,changeType:Uk})||this.setState(this._state)}}class ux extends lx{constructor(e){e.property=e.property||"input",super(e)}_setRange(e){lx.prototype._setRange.apply(this,arguments),this._editRange=this.options.arrayFormula?e:e.sheet().activeCellSelection()}getState(){this._state=this.range().getState()}exec(){return this.range().sheet().withCultureDecimals(this._exec.bind(this))}undo(){let e=this._editRange,t=this._state;e.sheet().trigger("changing",{data:t.data[0][0].value,range:e,changeType:jk})||this.setState(this._state)}_exec(){let e=this.options.arrayFormula,t=this._editRange;if(!t.enable())return{reason:"error",type:"rangeDisabled"};if(!t.canEditArrayFormula())return{reason:"error",type:"intersectsArray"};let n=this._value;if(this.getState(),!this.range().sheet().trigger("changing",{data:n,range:this._editRange,changeType:jk}))if("value"!==this._property)try{t.link(null),""===n?t.value(null):(t.input(n,{arrayFormula:e}),/\n/.test(t.value())&&t.wrap(!0)),t._adjustRowHeight();let i=t._getValidationState();if(i)return this.rejectState(i)}catch(e){if(e instanceof z_.runtime.ParseError)return{title:"Error in formula",body:e+"",reason:"error"};throw e}else t.value(n)}}class hx extends lx{constructor(e){e.property="comment",super(e)}}class px extends lx{constructor(e){e.property="wrap",super(e),this._value=e.value}getState(){let e={};this.range().forEachRow((function(t){let n=t.topLeft().row;e[n]=t.sheet().rowHeight(n)})),this._state=this.range().getState(this._property),this._rowHeight=e}undo(){let e=this.range().sheet(),t=this._rowHeight;this.range().setState(this._state);for(let n in t)e.rowHeight(n,t[n])}}class fx extends Yk{constructor(e){e.property="format",super(e),this._delta=e.value}exec(){let e=this.range().sheet(),t=this._delta;this.getState(),e.batch(function(){this.range().forEachCell((function(n,i,r){let o=r.format;if(!o){let e=r.value;"number"==typeof e&&/\./.test(e)&&(o="0."+String(e).split(".")[1].replace(/\d/g,"0"))}(o||t>0)&&(o=Sb.adjustDecimals(o||"0",t),e.range(n,i).format(o))}))}.bind(this))}}class mx extends Yk{constructor(e){e.property="border",super(e),this._type=e.border,this._style=e.style}_batch(e){return this.range().sheet().batch(e,{})}exec(){let e=this;e._type&&(e.getState(),e._batch((function(){e[e._type](e._style)})))}noBorders(){this.range().insideBorders(null),this.outsideBorders(null)}allBorders(e){this.range().insideBorders(e),this.outsideBorders(e)}leftBorder(e){this.range().leftColumn().borderLeft(e)}rightBorder(e){this.range().rightColumn().borderRight(e)}topBorder(e){this.range().topRow().borderTop(e)}bottomBorder(e){this.range().bottomRow().borderBottom(e)}outsideBorders(e){let t=this.range();t.leftColumn().borderLeft(e),t.topRow().borderTop(e),t.rightColumn().borderRight(e),t.bottomRow().borderBottom(e)}insideBorders(e){this.range().insideBorders(e),this.outsideBorders(null)}insideHorizontalBorders(e){this.range().insideHorizontalBorders(e)}insideVerticalBorders(e){this.range().insideVerticalBorders(e)}}class gx extends Yk{constructor(e){super(e),this._type=e.value}exec(){this.getState(),this[this._type](),this.range().sheet().triggerChange({recalc:!0})}activate(e){this.range().sheet().activeCell(e)}getState(){this._state=this.range().getState()}undo(){"unmerge"!==this._type&&(this.range().unmerge(),this.activate(this.range().topLeft())),this.range().setState(this._state)}cells(){let e=this.range(),t=e._ref;e.merge(),this.activate(t)}horizontally(){let e=this.range().topRow()._ref;this.range().forEachRow((function(e){e.merge()})),this.activate(e)}vertically(){let e=this.range().leftColumn()._ref;this.range().forEachColumn((function(e){e.merge()})),this.activate(e)}unmerge(){let e=this.range(),t=e._ref.topLeft;e.unmerge(),this.activate(t)}}class vx extends Yk{constructor(e){super(e),this._type=e.value}exec(){this.getState(),this._topLeft=this.range().topLeft(),this[this._type]()}getState(){this._state=this.range().sheet().getState()}undo(){this.range().sheet().setState(this._state)}panes(){let e=this._topLeft;this.range().sheet().frozenColumns(e.col).frozenRows(e.row)}rows(){let e=this._topLeft;this.range().sheet().frozenRows(e.row)}columns(){let e=this._topLeft;this.range().sheet().frozenColumns(e.col)}unfreeze(){this.range().sheet().frozenRows(0).frozenColumns(0)}}class _x extends Yk{constructor(e){super(e),this._clipboard=e.workbook.clipboard(),this._clipboard.parse(),this._event=e.event,this._clipboardContent=this._clipboard._content,this._sheet=this._workbook.activeSheet(),this._range=this._sheet.selection?this._sheet.selection():this._sheet.range(this._clipboard.pasteRef()),this._state=this._range.getState(),this._targetRangeRefs=(this._range._ref instanceof Wv?this._range._ref.refs:[this._range._ref]).map((function(e){return e.toRangeRef()}))}exec(){return this.range().sheet().withCultureDecimals(this._exec.bind(this))}undo(){let e=this._sheet,t=this._range;e.trigger("changing",{data:this._state.data,range:t,changeType:qk})||this.setState(this._state)}_exec(){let e=this._clipboard.canPaste();if(!e.canPaste)return e.menuInvoked?{reason:"error",type:"useKeyboard"}:e.pasteOnMerged?{reason:"error",type:"modifyMerged"}:e.pasteOnDisabled?(this._event.preventDefault(),{reason:"error",type:"cannotModifyDisabled"}):{reason:"error"};let t=this._sheet,n=this._range;this._workbook.trigger("paste",{range:n,clipboardContent:this._clipboardContent})||t.trigger("changing",{data:this._clipboardContent.data,range:n,changeType:qk})?this._event.preventDefault():this._processPaste()}_adjustPasteTarget(e,t,n){let i,r,o,a,s,l,c,d=this,u=d._targetRangeRefs,h=d._sheet,p=[],f=function(e,t){let n=0,i=e.topLeft,r=t.topLeft;return i.row>r.row?n=1:i.row<r.row?n=-1:i.col>r.col?n=1:i.col<r.col&&(n=-1),n};for(l=0;l<u.length;l+=1)o=u[l],s=e[l],a=o.topLeft,c={row:s.rows*t+a.row-1,col:s.cols*n+a.col-1},i=new Uv(a,c),p.push(i);1===p.length?r=h.range(i):(p.sort(f),r=h.range(new Wv(p))),r.select(),d._range=r,d._state=d._range.getState()}_processPaste(){let e,t=this,n=t._sheet,i=t._clipboardContent,r=t._range,o=i.data,a=o.length,s=o[0].length,l=t._targetRangeRefs,c=t._targetRanges(a,s),d=this._clipboard.pasteRef();(d.bottomRight.row>=n._rows._count||d.bottomRight.col>=n._columns._count)&&n.resize(Math.max(d.bottomRight.row+1,n._rows._count),Math.max(d.bottomRight.col+1,n._columns._count)),t._adjustPasteTarget(c,a,s),n.batch((function(){for(e=0;e<l.length;e++)t._populateTargetRange(l[e],a,s,c[e])}),{recalc:!0,ref:t._range._ref}),r._adjustRowHeight()}_populateTargetRange(e,t,n,i){let r,o,a,s=e.topLeft;for(o=0;o<i.rows;o++)for(a=0;a<i.cols;a++)r=this._sheet.range(s.row+t*o,s.col+n*a),r.setState(this._clipboardContent,this._clipboard)}_targetRangeDimensions(e,t,n){let i=e.topLeft,r=e.bottomRight,o=r.row-i.row+1,a=r.col-i.col+1,s=1,l=1;return o%t==0&&a%n==0&&(s=o/t,l=a/n),{rows:s,cols:l}}_targetRanges(e,t){let n,i=this._targetRangeRefs,r=[];for(n=0;n<i.length;n++)r.push(this._targetRangeDimensions(i[n],e,t));return r}}class bx extends Yk{exec(){let e=this.options,t=this._workbook.activeSheet();(e.range||t.range(e.rowIndex))._adjustRowHeight()}}class yx extends Yk{exec(){if(!xx().paste)return{reason:"error",type:"useKeyboard"};this._workbook._view.clipboard.focus(),document.execCommand("paste")}}class wx extends Yk{constructor(e){super(e),this._eventType="cut",this._clipboard=e.workbook.clipboard(),this._event=e.event}exec(){let e,t,n=this._clipboard.canCopy(),i=[];if(!n.canCopy)return n.menuInvoked?{reason:"error",type:"useKeyboard"}:n.multiSelection?{reason:"error",type:"unsupportedSelection"}:void 0;let r=this._workbook.activeSheet().selection();if("cut"===this._eventType){if(!r.enable())return this._event.preventDefault(),{reason:"error",type:"cannotModifyDisabled"};this.getState()}if(this._workbook.trigger(this._eventType,{range:r}))this._event.preventDefault();else if("cut"===this._eventType){if(e=r.values(),e.forEach((function(e){t=[],e.forEach((function(){t.push({})})),i.push(t)})),r.sheet().trigger("changing",{data:i,range:r,changeType:Wk}))return;this._clipboard.cut()}else this._clipboard.copy()}undo(){let e=this.range();e.sheet().trigger("changing",{data:this._state.data,range:e,changeType:Wk})||this.setState(this._state)}}class kx extends wx{constructor(e){super(e),this._eventType="copy",this.undo=Kk}}function xx(){return{copy:!!document.queryCommandSupported&&document.queryCommandSupported("copy"),cut:!!document.queryCommandSupported&&document.queryCommandSupported("cut"),paste:!!document.queryCommandSupported&&document.queryCommandSupported("paste")}}class Cx extends Yk{constructor(e){super(e),this._clipboard=e.workbook.clipboard(),this.cannotUndo=!0}exec(){if(!xx().copy)return{reason:"error",type:"useKeyboard"};document.execCommand("copy")}}class Sx extends Yk{constructor(e){super(e)}origin(e){this._origin=e}exec(){let e,t=this.range();if(!t.enable())return{reason:"error",type:"rangeDisabled"};if(t.intersectingArrayFormula())return{reason:"error",type:"intersectsArray"};this.getState();try{if(e=t._previewFillFrom(this._origin),t.sheet().trigger("changing",{data:e.props,range:e.dest,changeType:$k}))return;e.dest._properties(e.props,!0)}catch(e){if(e instanceof Wy.FillError)return{reason:"error",type:e.code};throw e}}undo(){let e=this.range(),t=this._state;e.sheet().trigger("changing",{data:t.data,range:e,changeType:$k})||this.setState(this._state)}}class Tx extends Yk{constructor(e){super(e),this._clipboard=e.workbook.clipboard(),this.cannotUndo=!0}exec(){if(!xx().copy)return{reason:"error",type:"useKeyboard"};document.execCommand("cut")}}class Dx extends Yk{undo(){this.range().filter(this._state)}exec(){let e=this.range();this._state=e.hasFilter(),e.filter(!this._state)}}class Ax extends Yk{undo(){this.range().sheet().setState(this._state)}exec(){let e=this.range(),t=e.sheet(),n=t.activeCell(),i=this.options.sheet?n.topLeft.col:this.options.column||0,r="asc"===this.options.value;this._state=t.getState(),this.options.sheet&&(e=this.expandRange());let o=e.cantSort();if(o)return{reason:"error",type:o.code};e.sort({column:i,ascending:r})}expandRange(){let e=this.range().sheet();return new Wy(e._sheetRef,e)}}class Mx extends Yk{column(){return this.options.column||0}undo(){this.range().sheet().clearFilter(this.column()),this._state.length&&this.range().filter(this._state)}getState(){let e=this.range().sheet().filter();e&&(this._state=e.columns.filter(function(e){return e.index===this.column()}.bind(this)))}exec(){let e,t,n=this.range(),i=this.column(),r=n.sheet().filter(),o=!1;this.options.valueFilter?t={column:i,filter:new Rw(this.options.valueFilter)}:this.options.customFilter&&(t={column:i,filter:new Lw(this.options.customFilter)}),this.getState(),r&&r.ref.eq(n._ref)&&r.columns.length?(r.columns.forEach((function(e){e.index===i&&(o=!0)})),e=r.columns.map((function(e){return e.index===i?t:{column:e.index,filter:e.filter}})),o||e.push(t)):e=t,n.filter(e)}}class Ex extends Mx{exec(){let e=this.range(),t=this.column();this.getState(),e.clearFilter(t)}}class Ix extends Yk{constructor(e){super(e),this.axis=e.axis}undo(){this.range().sheet().setAxisState(this._state)}exec(){let e=this.range().sheet();this._state=e.getAxisState(),"row"===this.axis?e.axisManager().hideSelectedRows():e.axisManager().hideSelectedColumns()}}class zx extends Ix{exec(){let e=this.range().sheet();this._state=e.getAxisState(),"row"===this.axis?e.axisManager().unhideSelectedRows():e.axisManager().unhideSelectedColumns()}}class Px extends Yk{exec(){this._expandedRange=this._expand(this.range()),this._state=this._expandedRange.getState(),this._indexes=this._exec(this._expandedRange.sheet())}undo(){let e=this,t=e._expandedRange,n=t.sheet();n.batch((function(){e._indexes.forEach((function(t){e._undoOne(n,t),n._restoreModifiedFormulas(t.formulas)})),t.setState(e._state)}),{layout:!0,recalc:!0,ref:t._ref,isValue:!0})}}class Hx extends Px{_expand(e){return e.resize({left:-1/0,right:1/0})}_exec(e){return e.axisManager().deleteSelectedRows()}_undoOne(e,t){e.insertRow(t.index),e.rowHeight(t.index,t.height)}}class Fx extends Px{_expand(e){return e.resize({top:-1/0,bottom:1/0})}_exec(e){return e.axisManager().deleteSelectedColumns()}_undoOne(e,t){e.insertColumn(t.index),e.columnWidth(t.index,t.width)}}class Rx extends Yk{constructor(e){super(e),this._value=e.value}undo(){let e=this,t=e.range().sheet();t.batch((function(){for(let n=e._pos.count;--n>=0;)e._undoOne(t,e._pos.base)}),{layout:!0,recalc:!0})}}class Lx extends Rx{exec(){let e=this._value,t=this.range().sheet();this._pos="left"===e?t.axisManager().addColumnLeft():t.axisManager().addColumnRight()}_undoOne(e,t){e.deleteColumn(t)}}class Bx extends Rx{exec(){let e=this._value,t=this.range().sheet();this._pos="above"===e?t.axisManager().addRowAbove():t.axisManager().addRowBelow()}_undoOne(e,t){e.deleteRow(t)}}class Ox extends Yk{constructor(e){super(e),this._value=e.value}exec(){let e=this,t=e.range().sheet();if(this.getState(),!t.trigger("changing",{data:e._value,range:e.range(),changeType:Gk}))try{t.withCultureDecimals((function(){e.range().validation(e._value)}))}catch(e){if(e instanceof z_.runtime.ParseError)return{title:"Error in formula",body:e+"",reason:"error"};throw e}}undo(){let e=this.range(),t=this._state;e.sheet().trigger("changing",{data:t.data[0][0].validation,range:e,changeType:Gk})||this.setState(this._state)}}class Vx extends Yk{constructor(e){super(e),this.cannotUndo=!0}exec(){if(null===this.options.file.name.match(/.xlsx$/i))return{reason:"error",type:"openUnsupported"};let e=this.options.workbook;e.fromFile(this.options.file);let t=e.excelImportErrors;t&&t.length&&e._view.openDialog("importError",{errors:t})}}class Nx extends Yk{constructor(e){super(e),this.cannotUndo=!0}exec(){let e=this.options.name+this.options.extension;if(".xlsx"===this.options.extension)return this.options.workbook.saveAsExcel({fileName:e});".pdf"===this.options.extension&&this.options.workbook.saveAsPDF(__(this.options.pdf,{workbook:this.options.workbook,fileName:e}))}}class $x extends Yk{constructor(e){super(e),this._name=e.name,this._value=e.value}getState(){this._state=this._workbook.nameDefinition(this._name)}setState(){this._workbook.nameDefinition(this._name,this._state),this._workbook.trigger("change",{recalc:!0})}}class Ux extends $x{exec(){this.getState();try{this._workbook.defineName(this._name,this._value),this._workbook.trigger("change",{recalc:!0})}catch(e){return{title:"Error",body:e+"",reason:"error"}}}}class Wx extends $x{exec(){this.getState(),this._workbook.undefineName(this._name),this._workbook.trigger("change",{recalc:!0})}}var jx=Object.freeze({__proto__:null,AddColumnCommand:Lx,AddCommand:Rx,AddRowCommand:Bx,AdjustDecimalsCommand:fx,AdjustRowHeightCommand:bx,ApplyFilterCommand:Mx,AutoFillCommand:Sx,BorderChangeCommand:mx,BringToFrontCommand:tx,ClearContentCommand:dx,ClearFilterCommand:Ex,ColumnWidthCommand:rx,Command:Yk,CopyCommand:kx,CutCommand:wx,DefineNameCommand:Ux,DeleteColumnCommand:Fx,DeleteCommand:Px,DeleteDrawingCommand:Jk,DeleteNameCommand:Wx,DeleteRowCommand:Hx,DrawingCommand:Xk,DrawingUpdateCommand:Qk,EditCommand:ux,EditValidationCommand:Ox,FilterCommand:Dx,FreezePanesCommand:vx,GridLinesChangeCommand:sx,HideLineCommand:Ix,HyperlinkCommand:ax,InsertCommentCommand:hx,InsertImageCommand:Zk,MergeCellCommand:gx,NameCommand:$x,OpenCommand:Vx,PasteCommand:_x,PropertyChangeCommand:lx,PropertyCleanCommand:cx,ReorderDrawingsCommand:ex,RowHeightCommand:ox,SaveAsCommand:Nx,SendToBackCommand:nx,SortCommand:Ax,TargetValueCommand:ix,TextWrapCommand:px,ToolbarCopyCommand:Cx,ToolbarCutCommand:Tx,ToolbarPasteCommand:yx,UnHideLineCommand:zx});class qx extends iw{constructor(e){super(),this.options=e,this.events=["undo","redo"],this.clear()}push(e){this.stack=this.stack.slice(0,this.currentCommandIndex+1),this.currentCommandIndex=this.stack.push(e)-1}undo(){if(this.canUndo()){let e=this.stack[this.currentCommandIndex--];e.undo(),this.trigger("undo",{command:e})}}redo(){if(this.canRedo()){let e=this.stack[++this.currentCommandIndex];e.redo(),this.trigger("redo",{command:e})}}clear(){this.stack=[],this.currentCommandIndex=-1}canUndo(){return this.currentCommandIndex>=0}canRedo(){return this.currentCommandIndex!==this.stack.length-1}}let Gx=String.fromCharCode,Kx={amp:38,lt:60,gt:62,quot:34,apos:39,nbsp:160};function Yx(e){let t=[];for(let n=0;n<e.length;++n)t.push(e.charCodeAt(n));return t}function Qx(e,t){t>65535?(t-=65536,e.push(t>>>10&1023|55296,56320|1023&t)):e.push(t)}let Xx=Yx("<![CDATA["),Zx=Yx("]]>"),Jx=Yx("--\x3e"),eC=Yx("!--"),tC=Yx("/>"),nC=Yx("</"),iC=Yx("?>"),rC=Yx("?"),oC=Yx("<"),aC=Yx(">"),sC=Yx(";"),lC=Yx("="),cC=Yx("&"),dC=Yx('"'),uC=Yx("'"),hC=Yx("#"),pC=Yx("x"),fC=Yx("X"),mC={};function gC(e,t){let n=0,i=[],r={is:function(e){let t=i.length,n=e.length;for(;--t>=0&&--n>=0;)if(i[t].$tag!==e[n]&&"*"!==e[n])return!1;return n<0?i[i.length-1]:null},exit:function(){throw mC},stack:i};function o(t){let i=e[n++];240&i^240?224&i^224?192&i^192?t.push(i):Qx(t,(31&i)<<6|63&e[n++]):Qx(t,(15&i)<<12|(63&e[n++])<<6|63&e[n++]):Qx(t,(3&i)<<18|(63&e[n++])<<12|(63&e[n++])<<6|63&e[n++])}function a(e){throw new Error(e+", at "+n)}function s(t){let i=[];for(;n<e.length&&t(e[n]);)i.push(e[n++]);return i}function l(e){return Gx.apply(0,s(e))}function c(){s(h)}function d(t){let i=n;for(let r=0;r<t.length;++r)if(e[n++]!==t[r])return n=i,!1;return t}function u(e){d(e)||a("Expecting "+e.join(", "))}function h(e){return 9===e||10===e||13===e||32===e}function p(e){return e>=48&&e<=57}function f(e){return e>=48&&e<=57||(e|=32)>=97&&e<=102}function m(e){return 58===e||95===e||(e|=32)>=97&&e<=122}function g(e){return 45===e||p(e)||m(e)}function v(){let t,r;d(rC)?(k("decl",_(),w()),u(iC)):d(eC)?function(){let t=[];for(;n<e.length;){if(d(Jx))return k("comment",Gx.apply(0,t));o(t)}}():(t=_(),r=w(t),i.push(r),d(tC)?k("enter",t,r,!0):(u(aC),k("enter",t,r),function(t){let i=[];for(;n<e.length;){if(d(nC))return i.length&&k("text",Gx.apply(0,i));if(d(Xx))for(;n<e.length&&!d(Zx);)o(i);else d(oC)?(i.length&&k("text",Gx.apply(0,i)),v(),i=[]):d(cC)?y(i):o(i)}a("Unclosed tag "+t)}(t),t!==_()&&a("Bad closing tag"),k("leave",t,r),c(),u(aC)),i.pop())}function _(){return m(e[n])||a("Expecting XML name"),l(g)}function b(){let t=d(dC)||d(uC);t||a("Expecting string");let i=[];for(;n<e.length;){if(d(t))return Gx.apply(0,i);d(cC)?y(i):o(i)}a("Unfinished string")}function y(e){let t;if(d(hC))t=d(pC)||d(fC)?parseInt(l(f),16):parseInt(l(p),10),isNaN(t)&&a("Bad numeric entity");else{let e=_();t=Kx[e],void 0===t&&a("Unknown entity "+e)}Qx(e,t),u(sC)}function w(t){let i={$tag:t};for(;n<e.length;){c();let t=e[n];if(63===t||62===t||47===t)break;i[_()]=(u(lC),b())}return i}function k(e,n,i,o){let a=t&&t[e];a&&a.call(r,n,i,o)}let x=[];for(o(x),65279!==x[0]&&(n=0);n<e.length;)c(),u(oC),v(),c()}const vC=function(){try{return gC.apply(this,arguments)}catch(e){if(e!==mC)throw e}};class _C{constructor(){this._progressHandlers=[],this._resolved=!1,this._rejected=!1,this.promise=new window.Promise(((e,t)=>{this._resolve=t=>{this._resolved||this._rejected||(this._resolved=!0,e(t))},this._reject=e=>{this._resolved||this._rejected||(this._rejected=!0,t(e))}}))}resolve(e){return this._resolve(e),this}reject(e){return this._reject(e),this}notify(e){this._resolved||this._rejected||this._progressHandlers.forEach((t=>t(e)))}progress(e){return this._progressHandlers.push(e),this}then(e,t,n){return n&&this.progress(n),this.promise.then(e,t)}promise(){return this.promise}}let bC={greaterThanOrEqual:"greaterThanOrEqualTo",lessThanOrEqual:"lessThanOrEqualTo"},yC=null;function wC(e,t,n){let i=new FileReader;i.onload=async function(e){Fn.loadAsync(e.target.result).then((async e=>await async function(e,t,n){yC=t.excelImportErrors=[];let i=await async function(e){let t=[],n=null;return await aS(e,"xl/sharedStrings.xml",{leave:function(){this.is(PC)&&(t.push(n),n=null)},text:function(e){this.is(zC)&&(null==n&&(n=""),n+=e)}}),t}(e),r=await sS(e,"_rels/workbook.xml"),o=await async function(e,t){let n=[],i={colorScheme:n},r=YC(t);e.file(r)&&(await aS(e,r,{enter:function(e,t){this.is(gS)?n.push(bS("window"===t.val?"FFFFFFFF":"FF000000")):this.is(mS)&&n.push(bS("FF"+t.val))}}),n.length>3&&(o(n,0,1),o(n,2,3)));function o(e,t,n){let i=e[t];e[t]=e[n],e[n]=i}return i}(e,r.byType.theme[0]),a=await async function(e,t){let n={fonts:[],numFmts:{},fills:[],borders:[],namedStyles:[],inlineStyles:[]},i=null,r=null,o=null,a=null;function s(e){let t={borderId:vS(e.borderId),fillId:vS(e.fillId),fontId:vS(e.fontId),numFmtId:vS(e.numFmtId),pivotButton:_S(e.pivotButton),quotePrefix:_S(e.quotePrefix),xfId:vS(e.xfId)};function n(n){if(null!=e[n])return t[n]=_S(e[n])}return n("applyAlignment"),n("applyBorder"),n("applyFill"),n("applyFont"),n("applyNumberFormat"),n("applyProtection")&&(t.protection={locked:!0}),t}function l(e,n){if(e.rgb)return bS(e.rgb);if(e.indexed)return fS[vS(e.indexed)];if(e.theme){let i=t.colorScheme[vS(e.theme)];if(!i)return n;let r=jr(i);if(e.tint){r=r.toHSL();let t=parseFloat(e.tint);r.l=t<0?r.l*(1+t):r.l*(1-t)+(100-100*(1-t))}return r.toCssRgba()}}return await aS(e,"xl/styles.xml",{enter:function(e,t,c){if(this.is(pS))n.numFmts[t.numFmtId]=t;else if(this.is(dS))n.fonts.push(i={}),c&&(i=null);else if(i)"sz"===e?i.size=parseFloat(t.val):"name"===e?i.name=t.val:"b"===e?i.bold=_S(t.val,!0):"i"===e?i.italic=_S(t.val,!0):"u"===e?i.underline=null==t.val||"single"===t.val:"color"===e&&(i.color=l(t,null));else if(this.is(cS))n.fills.push(r={}),c&&(r=null);else if(r)"patternFill"===e?r.type=t.patternType:("fgColor"===e&&"solid"===r.type||"bgColor"===e&&"solid"!==r.type)&&(r.color=l(t,fS[0]));else if(this.is(lS))n.borders.push(o={diagonalUp:+_S(t.diagonalUp,0),diagonalDown:+_S(t.diagonalDown,0)}),c&&(o=null);else if(o){if(/^(?:left|top|right|bottom|diagonal)$/.test(e)&&(o[e]={style:t.style||"none"},"diagonal"===e&&(o.diagonal.up=o.diagonalUp,o.diagonal.down=o.diagonalDown)),"color"===e){let e=this.stack[this.stack.length-2].$tag;o[e].color=l(t,fS[0])}}else this.is(hS)?(a=s(t),n.namedStyles.push(a),c&&(a=null)):this.is(uS)?(a=s(t),n.inlineStyles.push(a),c&&(a=null)):a&&("alignment"===e?(/^(?:left|center|right|justify)$/.test(t.horizontal)&&(a.textAlign=t.horizontal),/^(?:top|center|bottom)$/.test(t.vertical)&&(a.verticalAlign=t.vertical),null!=t.wrapText&&(a.wrapText=_S(t.wrapText)),null!=t.indent&&(a.indent=vS(t.indent))):"protection"==e&&(a.protection={locked:_S(t.locked)}))},leave:function(e){this.is(dS)?i=null:this.is(cS)?r=null:this.is(lS)?o=null:"xf"===e&&(a=null)}}),n}(e,o),s=[],l=0;await aS(e,"xl/workbook.xml",{enter:function(n,o){if(this.is(EC)){let n=o["r:id"],l=r.byId[n],c=o.name,d=o.state,u=function(e){let t,n={rows:0,cols:0};return vC(e,{enter:function(e,i){"dimension"===e?(t=z_.parseReference(i.ref),t.bottomRight&&(n.cols=t.bottomRight.col+1,n.rows=t.bottomRight.row+1)):"sheetFormatPr"===e?(i.defaultColWidth&&(n.columnWidth=XC(parseFloat(i.defaultColWidth))),i.defaultRowHeight&&(n.rowHeight=ZC(parseFloat(i.defaultRowHeight)))):this.is(AC)&&i.r?n.rows=Math.max(n.rows,+i.r):this.is(kC)&&i.r&&(t=z_.parseReference(i.r),n.rows=Math.max(n.rows,t.row+1),n.cols=Math.max(n.cols,t.col+1))}}),n}(r.bytes[l]);t.options.columnWidth=u.columnWidth||t.options.columnWidth,t.options.rowHeight=u.rowHeight||t.options.rowHeight,s.push({workbook:t,zip:e,strings:i,styles:a,file:l,options:{state:d,name:c,rows:Math.max(t.options.rows||0,u.rows),columns:Math.max(t.options.columns||0,u.cols),columnWidth:u.columnWidth,rowHeight:u.rowHeight}})}else this.is(FC)&&o.activeTab&&(l=vS(o.activeTab))},text:function(e){let n=this.is(CC);if(n&&!_S(n.function)&&!_S(n.vbProcedure)){let i=n.localSheetId,r=null;null!=i&&(r=s[i].options.name);let o=n.name;"_xlnm._FilterDatabase"!==o&&(r&&(o="'"+r.replace(/\'/g,"\\'")+"'!"+o),iS(r,null,(function(){t.defineName(o,e,_S(n.hidden))}),"reading user-defined name: "+o))}}});let c=new _C;c.progress((function(e){n&&n.notify(e)})).then((function(){let e=t.sheets();!function(e){for(let t=0;t<e.length;t++)e[t].suspendChanges(!1).triggerChange({recalc:!0})}(e),t.activeSheet(e[l]),n&&n.resolve()})),function(e,t,n){let i=window.Promise.resolve();for(let r=0;r<e.length;r++)!function(r,o){i=i.then((function(){let i=t.insertSheet(r.options);i.suspendChanges(!0);let a=QC(i,r),s={sheet:i,progress:1===o?1:o/(e.length-1)};return a.then((function(){n.notify(s)})),a}))}(e[r],r);i.then((function(){n.resolve()}))}(s,t,c)}(e,t,n)))},i.readAsArrayBuffer(e)}let kC=["sheetData","row","c"],xC=["cols","col"],CC=["definedNames","definedName"],SC=["sheetData","row","c","f"],TC=["mergeCells","mergeCell"],DC=["sheetViews","sheetView","pane"],AC=["sheetData","row"],MC=["sheetViews","sheetView","selection"],EC=["sheets","sheet"],IC=["sheetData","row","c","is"],zC=["t"],PC=["si"],HC=["sheetData","row","c","v"],FC=["bookViews","workbookView"],RC=["sheetViews","sheetView"],LC=["hyperlinks","hyperlink"],BC=["sheetProtection"],OC=["dataValidations","dataValidation"],VC=["dataValidations","dataValidation","formula1"],NC=["dataValidations","dataValidation","formula2"],$C=["x14:dataValidations","x14:dataValidation"],UC=["x14:dataValidations","x14:dataValidation","xm:sqref"],WC=["x14:dataValidations","x14:dataValidation","x14:formula1","xm:f"],jC=["x14:dataValidations","x14:dataValidation","x14:formula2","xm:f"],qC=["commentList","comment"],GC=["authors","author"],KC=["t"];function YC(e){return/^\//.test(e)?e=e.substr(1):/^xl\//.test(e)||(e="xl/"+e),e}function QC(e,t){let n=new _C;return setTimeout((async function(){await async function(e,t,n,i,r){let o,a,s,l,c,d,u,h,p,f,m,g,v,_,b={},y=n._columns._count,w=null,k=t.replace(/worksheets\//,"worksheets/_rels/"),x=await sS(e,k),C=[],S=[];if(yC=n._workbook.excelImportErrors,t=YC(t),await aS(e,t,{enter:function(e,t,i){let r;if(this.is(SC))i&&"shared"===t.t&&null!=t.si&&(l=n.range(b[t.si])._get("formula"));else if(this.is(kC)){s=null,l=null,o=t.r,c=null,null==o&&(o=z_.parseReference(w),o.col++,o=o.toString()),w=o,a=t.t;let e=t.s;null!=e&&S.push({ref:o,sty:+e})}else if(this.is(TC))n.range(t.ref).merge();else if(this.is(xC)){let e,i=vS(t.min)-1,r=Math.min(y,vS(t.max))-1;if(t.width&&(e=XC(parseFloat(t.width)),0!==e&&n._columns.values.value(i,r,e)),"1"===t.hidden||0===e)for(let e=i;e<=r;e++)n.hideColumn(e);null!=t.style&&S.unshift({ref:new Uv(new $v(-1/0,i),new $v(1/0,r)),sty:+t.style})}else if(this.is(AC)){let e,i=vS(t.r)-1;t.ht&&(e=ZC(parseFloat(t.ht)),0!==e&&n._rows.values.value(i,i,e)),"1"!==t.hidden&&0!==e||n.hideRow(i)}else if(this.is(MC)){if(t.activeCell){let e=z_.parseReference(t.activeCell);n.select(e,!0)}}else if(this.is(DC))t.state&&t.state.indexOf("frozen")>-1&&(t.xSplit&&n.frozenColumns(vS(t.xSplit)),t.ySplit&&n.frozenRows(vS(t.ySplit)));else if(this.is(RC))n.showGridLines(_S(t.showGridLines,!0));else if(this.is(LC)){let e=t["r:id"],i=x.byId[e];i&&n.range(t.ref).link(i)}else this.is(BC)?t.sheet&&n.range(qv).enable(!1):this.is(["autoFilter"])?(p=t.ref,i&&T()):p&&(this.is(["filterColumn"])?f=parseInt(t.colId,10):this.is(["customFilters"])?(m=_S(t.and)?"and":"or",g=[]):this.is(["customFilter"])?(r=function(e,t){let n={equal:"eq",notEqual:"ne",greaterThan:"gt",greaterThanOrEqual:"gte",lessThan:"lt",lessThanOrEqual:"lte"}[e];if(t=nS(t),n&&"number"==typeof t)return{operator:n,value:t};if(("notEqual"===e||!e)&&"string"==typeof t)return{operator:e?"doesnotmatch":"matches",value:t}}(t.operator,t.val),r&&g.push({operator:r.operator,value:r.value})):this.is(["dynamicFilter"])?C.push({column:f,filter:new Ow({type:tS(t.type)})}):this.is(["top10"])?C.push({column:f,filter:new Bw({value:nS(t.val),type:function(e,t){return e&&t?"topPercent":t?"topNumber":e?"bottomPercent":"bottomNumber"}(_S(t.percent),_S(t.top))})}):this.is(["filters"])?(v=_S(t.blank),_=[]):this.is(["filter"])&&_.push(nS(t.val)))},leave:function(e,t){if(this.is(SC))l||"shared"!==t.t||null==t.si||(l=n.range(b[t.si])._get("formula"));else if(this.is(kC)){if(null!=l){iS(n,c||o,(function(){n.range(c||o).formula(l,d)}),"parsing formula")&&n.range(c||o).value(l).background("#ffaaaa")}else if(null!=s){let e=n.range(o);e._get("formula")||(a&&"n"!==a?"s"===a?s=i[vS(s)]:"b"===a?s="1"===s:"d"===a&&(s=E_().parseDate(s)):s=parseFloat(s),null!=s&&e.value(s))}}else this.is(OC)||this.is($C)?function(){let e=z_.parseSqref(t.sqref),i=t.type.toLowerCase(),r=t.operator;/^(?:whole|decimal)$/.test(i)?i="number":"list"===i&&(r="list"),!r&&/^(?:number|date)$/.test(i)&&(r="between"),e.forEach((function(e){iS(n,e,(function(){n.range(e).validation({type:_S(t.showErrorMessage,!0)?"reject":"warning",from:u,to:h,dataType:i,comparerType:bC[r]||r,allowNulls:_S(t.allowBlank),showButton:_S(t.showDropDown)||"date"===i||"list"===i,messageTemplate:t.error,titleTemplate:t.errorTitle})}),"parsing validation")}))}():"cols"===e?n._columns._refresh():"sheetData"===e?n._rows._refresh():"autoFilter"===e?T():p&&("customFilters"===e?C.push({column:f,filter:new Lw({logic:m,criteria:g})}):"filters"===e&&C.push({column:f,filter:new Rw({values:_,blanks:v})}))},text:function(e){let t;this.is(HC)||this.is(IC)?s=e:(t=this.is(SC))?(l=e,d="array"===t.t,d?c=t.ref:"shared"===t.t&&(b[t.si]=o)):this.is(VC)||this.is(WC)?u=e:this.is(NC)||this.is(jC)?h=e:this.is(UC)&&(this.stack[this.stack.length-2].sqref=e)}}),S.forEach((({ref:e,sty:t})=>function(e,t,n,i){let r,o,a=e.range(t),s=n.inlineStyles[i];s.xfId&&(r=n.namedStyles[s.xfId]);h("applyBorder","borderId")&&u(n.borders[o]);h("applyFont","fontId")&&d(n.fonts[o]);h("applyAlignment","textAlign")&&a.textAlign(o);h("applyAlignment","verticalAlign")&&a.verticalAlign(o);h("applyAlignment","indent")&&a.indent(o);h("applyAlignment","wrapText")&&a._property("wrap",o);h("applyFill","fillId")&&c(n.fills[o]);h("applyNumberFormat","numFmtId")&&l(n.numFmts[o]||oS[o]);h("applyProtection","protection")&&a.enable(!s.protection.locked);function l(e){let t="string"==typeof e?e:e.formatCode;null==t||/^general$/i.test(t)||(t=t.replace(/^\[\$-[0-9]+\]/,""),a.format(t))}function c(e){"solid"===e.type&&a.background(e.color)}function d(e){a.fontFamily(e.name),e.size&&a._property("fontSize",4*e.size/3),e.bold&&a.bold(!0),e.italic&&a.italic(!0),e.underline&&a.underline(!0),e.color&&a.color(e.color)}function u(e){function t(t,n){let i=e[t];if(!i)return;let r=rS[i.style];if(!r)return;let o=i.color;null==o&&(o="#000");let s={size:r,color:o};"diagonal"===t&&(s.type=i.up<<1|i.down),a._property(n,s)}t("left","borderLeft"),t("top","borderTop"),t("right","borderRight"),t("bottom","borderBottom"),t("diagonal","dBorders")}function h(e,t){let n=s[e];if(null!=n&&!n)return!1;if(o=s[t],r&&null==o){if(n=r[e],null!=n&&!n)return!1;o=r[t]}return null!=o}}(n,e,r,t))),x.byType.comments){let i=yS(t,x.byType.comments[0]);await async function(e,t,n){let i,r,o=[];await aS(e,t,{enter:function(e,t){this.is(qC)?r={author:o[t.authorId],ref:t.ref,text:""}:this.is(GC)&&(i="")},leave:function(){this.is(qC)?n.range(r.ref).comment(r.text):this.is(GC)&&o.push(i)},text:function(e){this.is(KC)?r.text+=e:this.is(GC)&&(i+=e)}})}(e,i,n)}if(x.byType.drawing){let i=yS(t,x.byType.drawing[0]);await async function(e,t,n){let i,r,o,a,s=["xdr:twoCellAnchor"],l=["xdr:ext"],c=["xdr:oneCellAnchor"],d=["xdr:from"],u=["xdr:to"],h=["xdr:row"],p=["xdr:col"],f=["xdr:rowOff"],m=["xdr:colOff"],g=["xdr:blipFill","a:blip"],v=t.replace(/drawings\//,"drawings/_rels/"),_=await sS(e,v);if(_.byType.image){let i=Object.keys(_.byId);for(let r=0;r<i.length;++r){let o=i[r],a=yS(t,_.byId[o]),s=JC(a);if(s){let t=await e.file(a).async("arraybuffer"),i=eS(a),r=i&&!Qi.edge?new window.File([t],i,{type:s}):new window.Blob([t],{type:s});_.byId[o]=n._workbook.addImage(r)}}}await aS(e,t,{enter:function(e,t){if(this.is(s)||this.is(c))i={};else if(this.is(d)||this.is(u))r={};else if(this.is(g)){let e=t["r:embed"];i.image=_.byId[e]}else this.is(l)&&(o=wS(parseFloat(t.cx)),a=wS(parseFloat(t.cy)))},leave:function(){if(this.is(d))i.topLeftCell=new $v(r.row,r.col),i.offsetX=wS(r.colOffset),i.offsetY=wS(r.rowOffset);else if(this.is(u))i.brCell=new $v(r.row,r.col),i.brX=wS(r.colOffset),i.brY=wS(r.rowOffset);else if(this.is(s)&&i.image){let e=n._columns.sum(0,i.topLeftCell.col-1)+i.offsetX,t=n._rows.sum(0,i.topLeftCell.row-1)+i.offsetY,r=n._columns.sum(0,i.brCell.col-1)+i.brX,s=n._rows.sum(0,i.brCell.row-1)+i.brY;n.addDrawing({topLeftCell:i.topLeftCell,offsetX:i.offsetX,offsetY:i.offsetY,width:null!=o?o:r-e,height:null!=a?a:s-t,image:i.image,opacity:1})}else this.is(c)&&i.image&&n.addDrawing({topLeftCell:i.topLeftCell,offsetX:i.offsetX,offsetY:i.offsetY,width:o,height:a,image:i.image,opacity:1})},text:function(e){this.is(h)?r.row=parseFloat(e):this.is(p)?r.col=parseFloat(e):this.is(f)?r.rowOffset=parseFloat(e):this.is(m)&&(r.colOffset=parseFloat(e))}})}(e,i,n)}function T(){n.range(p).filter(C),p=null}}(t.zip,t.file,e,t.strings,t.styles),n.resolve()}),0),n}function XC(e){return 7*((256*e+Math.floor(128/7))/256)}function ZC(e){return e*(4/3)}function JC(e){let t=/\.([^.]+)$/.exec(e);if(t&&t[1])return{jpg:"image/jpeg",jpeg:"image/jpeg",png:"image/png",gif:"image/gif",wmf:"image/wmf"}[t[1].toLowerCase()]}function eS(e){let t=/[^/]+$/.exec(e);return t&&t[0]}function tS(e){return{Q1:"quarter1",Q2:"quarter2",Q3:"quarter3",Q4:"quarter4",M1:"january",M2:"february",M3:"march",M4:"april",M5:"may",M6:"june",M7:"july",M8:"august",M9:"september",M10:"october",M11:"november",M12:"december"}[e.toUpperCase()]||e}function nS(e){let t=parseFloat(e);return isNaN(t)||t!==e?e:t}function iS(e,t,n,i){try{return n(),!1}catch(n){let r={context:i,error:String(n)};return e&&e.name?r.sheet=e.name():e&&(r.sheet=e),t&&(r.location=String(t)),yC.push(r),!0}}let rS={none:0,thin:1,medium:2,dashed:1,dotted:1,thick:3,double:3,hair:1,mediumDashed:2,dashDot:1,mediumDashDot:2,dashDotDot:1,mediumDashDotDot:2,slantDashDot:1},oS={0:"General",1:"0",2:"0.00",3:"#,##0",4:"#,##0.00",9:"0%",10:"0.00%",11:"0.00E+00",12:"# ?/?",13:"# ??/??",14:"mm-dd-yy",15:"d-mmm-yy",16:"d-mmm",17:"mmm-yy",18:"h:mm AM/PM",19:"h:mm:ss AM/PM",20:"h:mm",21:"h:mm:ss",22:"m/d/yy h:mm",37:"#,##0 ;(#,##0)",38:"#,##0 ;[Red](#,##0)",39:"#,##0.00;(#,##0.00)",40:"#,##0.00;[Red](#,##0.00)",45:"mm:ss",46:"[h]:mm:ss",47:"mmss.0",48:"##0.0E+0",49:"@"};function aS(e,t,n){return new window.Promise((i=>{let r=e.file(t);r?r.async("uint8array").then((e=>{vC(e,n),i()})):i()}))}async function sS(e,t){let n={byId:{},byType:{theme:[]},bytes:{}};await aS(e,YC(t)+".rels",{enter:function(e,t){if("Relationship"===e){n.byId[t.Id]=t.Target;let e=t.Type.match(/\w+$/)[0],i=n.byType[e]||[];i.push(t.Target),n.byType[e]=i}}});let i=[],r=[];Object.keys(n.byId).forEach((t=>{let o=n.byId[t],a=e.file(YC(o));a&&(i.push(o),r.push(a.async("uint8array")))}));let o=await window.Promise.all(r);return i.forEach(((e,t)=>n.bytes[e]=o[t])),n}let lS=["borders","border"],cS=["fills","fill"],dS=["fonts","font"],uS=["cellXfs","xf"],hS=["cellStyleXfs","xf"],pS=["numFmts","numFmt"],fS=[bS("FF000000"),bS("FFFFFFFF"),bS("FFFF0000"),bS("FF00FF00"),bS("FF0000FF"),bS("FFFFFF00"),bS("FFFF00FF"),bS("FF00FFFF"),bS("FF000000"),bS("FFFFFFFF"),bS("FFFF0000"),bS("FF00FF00"),bS("FF0000FF"),bS("FFFFFF00"),bS("FFFF00FF"),bS("FF00FFFF"),bS("FF800000"),bS("FF008000"),bS("FF000080"),bS("FF808000"),bS("FF800080"),bS("FF008080"),bS("FFC0C0C0"),bS("FF808080"),bS("FF9999FF"),bS("FF993366"),bS("FFFFFFCC"),bS("FFCCFFFF"),bS("FF660066"),bS("FFFF8080"),bS("FF0066CC"),bS("FFCCCCFF"),bS("FF000080"),bS("FFFF00FF"),bS("FFFFFF00"),bS("FF00FFFF"),bS("FF800080"),bS("FF800000"),bS("FF008080"),bS("FF0000FF"),bS("FF00CCFF"),bS("FFCCFFFF"),bS("FFCCFFCC"),bS("FFFFFF99"),bS("FF99CCFF"),bS("FFFF99CC"),bS("FFCC99FF"),bS("FFFFCC99"),bS("FF3366FF"),bS("FF33CCCC"),bS("FF99CC00"),bS("FFFFCC00"),bS("FFFF9900"),bS("FFFF6600"),bS("FF666699"),bS("FF969696"),bS("FF003366"),bS("FF339966"),bS("FF003300"),bS("FF333300"),bS("FF993300"),bS("FF993366"),bS("FF333399"),bS("FF333333"),bS("FF000000"),bS("FFFFFFFF")];let mS=["a:clrScheme","*","a:srgbClr"],gS=["a:clrScheme","*","a:sysClr"];function vS(e){return null==e?null:parseInt(e,10)}function _S(e,t){return null==e?t:"true"===e||!0===e||1===e||"1"===e}function bS(e){let t=/^([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})$/i.exec(e);return"rgba("+parseInt(t[2],16)+", "+parseInt(t[3],16)+", "+parseInt(t[4],16)+", "+parseInt(t[1],16)/255+")"}function yS(e,t){for(e=e.split(/\/+/),t=t.split(/\/+/),e.pop();t.length;){let n=t.shift();if(""===n)e=[];else{if("."===n)continue;".."===n?e.pop():e.push(n)}}return e.join("/")}function wS(e){return e/9525}const kS=["cut","copy","paste","changing","change","contextmenu","excelImport","excelExport","insertSheet","removeSheet","selectSheet","renameSheet","insertRow","insertColumn","deleteRow","deleteColumn","hideRow","hideColumn","unhideRow","unhideColumn","select","changeFormat","dataBinding","dataBound","progress"];function xS(e,t){let n=new XMLHttpRequest;n.onload=function(){t(n.response,n.getResponseHeader("Content-Type"))},n.onerror=function(){t(null)},n.open("GET",e),n.responseType="arraybuffer",n.send()}class CS extends iw{constructor(e,t){super(),this.events=kS,this.options=e,this._view=t,this._sheets=[],this._images={},this._imgID=0,this._sheetsSearchCache={},this._sheet=this.insertSheet({rows:this.options.rows,columns:this.options.columns,rowHeight:this.options.rowHeight,columnWidth:this.options.columnWidth,headerHeight:this.options.headerHeight,headerWidth:this.options.headerWidth,dataSource:this.options.dataSource}),this.undoRedoStack=new qx,this.undoRedoStack.bind(["undo","redo"],this._onUndoRedo.bind(this)),this._context=new ey(this),this._validationContext=new ty(this),this._names=Object.create(null),this.fromJSON(this.options)}clipboard(){return this._clipboard||(this._clipboard=new Lk(this)),this._clipboard}destroy(){this.unbind(),this._clipboard&&this._clipboard.destroy()}_sheetChanging(e){this.trigger("changing",e)&&e.preventDefault()}_sheetChange(e){this.trigger("change",e)}_sheetInsertRow(e){this.trigger("insertRow",{sheet:e.sender,index:e.index})&&e.preventDefault()}_sheetInsertColumn(e){this.trigger("insertColumn",{sheet:e.sender,index:e.index})&&e.preventDefault()}_sheetDeleteRow(e){this.trigger("deleteRow",{sheet:e.sender,index:e.index})&&e.preventDefault()}_sheetDeleteColumn(e){this.trigger("deleteColumn",{sheet:e.sender,index:e.index})&&e.preventDefault()}_sheetHideRow(e){this.trigger("hideRow",{sheet:e.sender,index:e.index})&&e.preventDefault()}_sheetHideColumn(e){this.trigger("hideColumn",{sheet:e.sender,index:e.index})&&e.preventDefault()}_sheetUnhideRow(e){this.trigger("unhideRow",{sheet:e.sender,index:e.index})&&e.preventDefault()}_sheetUnhideColumn(e){this.trigger("unhideColumn",{sheet:e.sender,index:e.index})&&e.preventDefault()}_sheetSelect(e){this.trigger("select",e)}_sheetDataBinding(e){this.trigger("dataBinding",{sheet:e.sender})&&e.preventDefault()}_sheetDataBound(e){this.trigger("dataBound",{sheet:e.sender})}_sheetProgress(e){let t=this;setTimeout((function(){t.trigger("progress",{toggle:e.toggle})}))}_sheetCommandRequest(e){this.trigger("commandRequest",e)}_inputForRef(e){let t=this;return t._sheet.withCultureDecimals((function(){return new Wy(e,t._sheet).input()}))}_onUndoRedo(e){e.command.range().select()}execute(e){let t,n=Object.assign({},{workbook:this},e.options);this.options.getWorkbookCommand&&(t=this.options.getWorkbookCommand(e.command,n)),t=t||new jx[e.command](n);let i=this.activeSheet();n.origin&&t.origin(n.origin),n.operatingRange?t.range(n.operatingRange):t.range(i.selection()),n.editRange&&(t._editRange=n.editRange);let r=t.exec();return r&&"error"===r.reason||t.cannotUndo||this.undoRedoStack.push(t),this.cleanupImages(),r}resetFormulas(){this._sheets.forEach((function(e){e.resetFormulas()}))}resetValidations(){this._sheets.forEach((function(e){e.resetValidations()}))}refresh(e){e.recalc&&(this.resetFormulas(),this.resetValidations(),this._sheet.recalc(this._context),this._sheet.revalidate(this._validationContext))}activeSheet(e){if(void 0===e)return this._sheet;this.sheetByName(e.name())&&(this._sheet=e,e.triggerChange(Yv))}moveSheetToIndex(e,t){let n=this.sheetIndex(e),i=this._sheets;-1!==n&&(this._sheetsSearchCache={},i.splice(t,0,i.splice(n,1)[0]),this.trigger("change",{sheetSelection:!0}))}insertSheet(e){let t,n=this,i="number"==typeof(e=e||{}).index?e.index:n._sheets.length,r=n._sheets;const o=this.options.messages;let a=function(e){e=e||1;let t=o.workbook.defaultSheetName+e;return n.sheetByName(t)?a(e+1):t};if(e.name&&n.sheetByName(e.name))return;this._sheetsSearchCache={},t=e.name||a();let s=new Kw(e.rows||this.options.rows,e.columns||this.options.columns,e.rowHeight||this.options.rowHeight,e.columnWidth||this.options.columnWidth,e.headerHeight||this.options.headerHeight,e.headerWidth||this.options.headerWidth,e.defaultCellStyle||this.options.defaultCellStyle,e.createSheetDataSource||this.options.createSheetDataSource);return s._workbook=this,s._name(t),s._state(e.state),this._bindSheetEvents(s),r.splice(i,0,s),e.data&&s.fromJSON(e.data),e.dataSource&&s.setDataSource(e.dataSource),this.trigger("change",{sheetSelection:!0}),s}_bindSheetEvents(e){e.bind("changing",this._sheetChanging.bind(this)),e.bind("change",this._sheetChange.bind(this)),e.bind("insertRow",this._sheetInsertRow.bind(this)),e.bind("insertColumn",this._sheetInsertColumn.bind(this)),e.bind("deleteRow",this._sheetDeleteRow.bind(this)),e.bind("deleteColumn",this._sheetDeleteColumn.bind(this)),e.bind("hideRow",this._sheetHideRow.bind(this)),e.bind("hideColumn",this._sheetHideColumn.bind(this)),e.bind("unhideRow",this._sheetUnhideRow.bind(this)),e.bind("unhideColumn",this._sheetUnhideColumn.bind(this)),e.bind("select",this._sheetSelect.bind(this)),e.bind("commandRequest",this._sheetCommandRequest.bind(this)),e.bind("dataBinding",this._sheetDataBinding.bind(this)),e.bind("dataBound",this._sheetDataBound.bind(this)),e.bind("progress",this._sheetProgress.bind(this))}sheets(){return this._sheets.slice()}sheetByName(e){return this._sheets[this.sheetIndex(e)]}sheetByIndex(e){return this._sheets[e]}sheetIndex(e){let t=this._sheets,n=("string"==typeof e?e:e.name()).toLowerCase(),i=this._sheetsSearchCache[n];if(i>=0)return i;for(i=0;i<t.length;i++){let e=t[i].name().toLowerCase();if(this._sheetsSearchCache[e]=i,e===n)return i}return-1}renameSheet(e,t){let n=e.name().toLowerCase();if(t&&n!==t.toLowerCase()&&!this.sheetByName(t)&&(e=this.sheetByName(n))&&(this._sheetsSearchCache={},!this.trigger("renameSheet",{sheet:e,newSheetName:t})))return this._sheets.forEach((function(e){e._forFormulas((function(e){e.renameSheet(n,t)}))})),this.forEachName(function(e,i){e.nameref.renameSheet(n,t)&&(this.undefineName(i),e.name=e.nameref.print(),this.nameDefinition(e.name,e)),(e.value instanceof Ov||e.value instanceof z_.runtime.Formula)&&e.value.renameSheet(n,t)}.bind(this)),e._name(t),this.trigger("change",{sheetSelection:!0}),e}removeSheet(e){let t=this,n=t._sheets,i=e.name(),r=t.sheetIndex(e);if(1!==n.length&&!this.trigger("removeSheet",{sheet:e})&&(this._sheetsSearchCache={},r>-1))if(e.unbind(),n.splice(r,1),t.activeSheet().name()===i){let e=n[r===n.length?r-1:r];t.activeSheet(e)}else this.trigger("change",{recalc:!0,sheetSelection:!0})}_clearSheets(){for(let e=0;e<this._sheets.length;e++)this._sheets[e]._activeDrawing=[],this._sheets[e]._drawings=[],this._sheets[e].unbind();this._sheets=[],this._sheetsSearchCache={},this._names={},this._images={},this._imgID=0}_loadImages(){let e=this,t=Object.keys(e._images),n=t.length;function i(){--n<=0&&e.activeSheet().triggerChange({layout:!0})}n?t.forEach((function(t){let n=e._images[t];n.blob||xS(n.url,(function(e,t){null!=e&&(n.blob=new Blob([e],{type:t}),delete n.url),i()}))})):i()}fromJSON(e){if(e.sheets){this._clearSheets(),e.images&&(this._imgID=0,this._images={},Object.keys(e.images).forEach((function(t){if(!isNaN(t)){let e=parseFloat(t);isFinite(e)&&(this._imgID=Math.max(this._imgID,e))}this._images[t]={url:e.images[t]}}),this),this._loadImages());for(let t=0;t<e.sheets.length;t++){let n=e.sheets[t],i=SS(n,this.options),r=this.insertSheet({rows:i.rowCount,columns:i.columnCount,rowHeight:i.rowHeight,columnWidth:i.columnWidth,headerHeight:i.headerHeight,headerWidth:i.headerWidth,data:n});n.dataSource&&r.setDataSource(n.dataSource)}}e.activeSheet?this.activeSheet(this.sheetByName(e.activeSheet)):this.activeSheet(this._sheets[0]),e.names&&e.names.forEach((function(e){this.defineName(e.name,e.value,e.hidden)}),this)}toJSON(){this.resetFormulas(),this.resetValidations();let e=Object.keys(this._names).map((function(e){let t=this._names[e],n=t.value;return n=n instanceof Ov||n instanceof z_.runtime.Formula?n.print(0,0,!0):n instanceof A_?String(n):JSON.stringify(n),{value:n,hidden:t.hidden,name:t.name,sheet:t.nameref.sheet,localName:t.nameref.name}}),this);return{activeSheet:this.activeSheet().name(),sheets:this._sheets.map((function(e){return e.recalc(this._context),e.revalidate(this._validationContext),e.toJSON()}),this),names:e,images:{},columnWidth:this.options.columnWidth,rowHeight:this.options.rowHeight}}saveJSON(){let e=this,t=e.toJSON(),n=Object.keys(e._images).filter((function(t){return 1===e.usesImage(t)})),i=n.length;const r=[];return i&&n.forEach((function(n){let i=e._images[n];if(i.blob){const e=new Promise((e=>{let r=new FileReader;r.onload=function(){t.images[n]=r.result,e()},r.readAsDataURL(i.blob)}));r.push(e)}else t.images[n]=i.url})),Promise.all(r).then((()=>t))}fromFile(e){const t=new _C;return e&&!this.trigger("excelImport",{file:e,deferred:t})&&(this._clearSheets(),this._readExcel(e,this,t)),t.promise}_readExcel(e,t,n){wC(e,t,n)}saveAsExcel(e){let t=this;e=__({},t.options.excel,e);let n=t.toJSON();if(t.trigger("excelExport",{workbook:n}))return;let i=Object.keys(t._images).filter((function(e){return 1===t.usesImage(e)})),r=i.length,o=r?{}:null;const a=[];return r?(i.forEach((function(e){let n=t._images[e];if(n.blob){const t=new Promise((t=>{let i=new FileReader;i.onload=function(){o[e]={type:n.blob.type,name:n.blob.name,data:i.result},r--,t()},i.readAsArrayBuffer(n.blob)}));a.push(t)}else{const t=new Promise((t=>{xS(n.url,(function(n,i){o[e]={type:i,data:n},r--,t()}))}));a.push(t)}})),Promise.all(a).then((()=>s()))):s();function s(){if(--r<=0){n.images=o;let t=new e.Workbook(n);const i=e.forceProxy?t.toDataURL():t.toBlob();return e.saveAs?i.then((t=>{e.saveAs(t,n.fileName||e.fileName,{proxyURL:e.proxyURL,forceProxy:e.forceProxy})})):i}return Promise.resolve()}}draw(e,t){"function"!=typeof e||t||(t=e,e={});let n=[],i=this._sheets;!function r(o){if(o<i.length)i[o].draw(qv,e,(function(e){n.push(e),r(o+1)}));else{let e=n[0];for(o=1;o<n.length;++o)e.children=e.children.concat(n[o].children);t(e)}}(0)}nameForRef(e,t){void 0===t&&(t=e.sheet),t=t.toLowerCase();let n=String(e);for(let e in this._names){let i=this._names[e],r=i.value;if(r instanceof Ov&&(!r.sheet||r.sheet&&t===r.sheet.toLowerCase())&&String(r)===n)return i}return{name:n}}defineName(e,t,n){let i=z_.parseNameDefinition(e,t);e=i.name.print(),this._names[e.toLowerCase()]={value:i.value,hidden:n,name:e,nameref:i.name}}undefineName(e){delete this._names[e.toLowerCase()]}nameValue(e){return(e=e.toLowerCase())in this._names?this._names[e].value:null}nameDefinition(e,t){return e=e.toLowerCase(),arguments.length>1&&(void 0===t?delete this._names[e]:this._names[e]=t),this._names[e]}forEachName(e){Object.keys(this._names).forEach((function(t){e(this._names[t],t)}),this)}adjustNames(e,t,n,i){e=e.toLowerCase(),Object.keys(this._names).forEach((function(r){let o=this._names[r],a=o.value;a instanceof Ov&&a.sheet.toLowerCase()===e?o.value=a.adjust(null,null,null,null,t,n,i):a instanceof z_.runtime.Formula&&a.adjust(e,t?"row":"col",n,i)}),this)}addImage(e){let t=String(++this._imgID);return this._images[t]="string"==typeof e?{url:e}:{blob:e},t}imageUrl(e){let t=this._images[e],n=t.url;return n||(n=t.url=window.URL.createObjectURL(t.blob)),n}cleanupImages(){Object.keys(this._images).forEach((function(e){if(!this.usesImage(e)){let t=this._images[e].url;t&&window.URL.revokeObjectURL(t),delete this._images[e]}}),this)}usesImage(e){let t,n=this._sheets;for(t=n.length;--t>=0;)if(n[t].usesImage(e))return 1;let i=this.undoRedoStack.stack;for(t=i.length;--t>=0;)if(i[t].usesImage(e))return 2;return!1}}function SS(e,t){function n(e,t,n){return void 0!==e?e:void 0!==t?t:n}let i=n(e.rowCount,t.rows,200),r=n(e.columnCount,t.columns,50),o=n(e.rowHeight,t.rowHeight,20),a=n(e.columnWidth,t.columnWidth,64),s=n(e.headerHeight,t.headerHeight,20),l=n(e.headerWidth,t.headerWidth,32);if(void 0!==e.rows)for(let t=0;t<e.rows.length;++t){let o=e.rows[t],a=n(o.index,t);if(a>=i&&(i=a+1),o.cells)for(let e=0;e<o.cells.length;++e){let t=n(o.cells[e].index,e);t>=r&&(r=t+1)}}return{rowCount:i,columnCount:r,rowHeight:o,columnWidth:a,headerHeight:s,headerWidth:l}}const TS=["cut","copy","paste","pdfExport","excelExport","excelImport","changing","change","render","removeSheet","selectSheet","renameSheet","insertRow","insertColumn","deleteRow","insertSheet","deleteColumn","hideRow","hideColumn","unhideRow","unhideColumn","select","changeFormat","dataBinding","dataBound","update","message","contextmenu"];const{FUNCS:DS,defineBuiltinFunction:AS,limitPrecision:MS,packDate:ES,unpackDate:IS,daysInMonth:zS,daysInYear:PS,isLeapYear:HS}=z_.runtime;function FS(e,t){return e="string"==typeof e?e.toLowerCase():e,t="string"==typeof t?t.toLowerCase():t,!1===e&&null==t||(!1===t&&null==e||(0===e&&null==t||(0===t&&null==e||(""===e&&null==t||(""===t&&null==e||e===t)))))}function RS(e,t,n){return"string"==typeof e&&"string"!=typeof t&&(t=null==t?"":t+""),"string"!=typeof e&&"string"==typeof t&&(e=null==e?"":e+""),"number"==typeof e&&null==t&&(t=0),"number"==typeof t&&null==e&&(e=0),"string"==typeof e&&"string"==typeof t&&(e=e.toLowerCase(),t=t.toLowerCase()),typeof t==typeof e?n(e=N_(e,15),t=N_(t,15)):new A_("VALUE")}function LS(e){return(Math.exp(e)+Math.exp(-e))/2}function BS(e){return(Math.exp(e)-Math.exp(-e))/2}function OS(e){return BS(e)/LS(e)}function VS(e,t){for(;t;){var n=e%t;e=t,t=n}return e}function NS(e,t){return Math.abs(e*t)/VS(e,t)}function $S(e,t){for(var n=[],i=0,r=e[0];i<e.length;)n.push({matrix:e[i++],pred:lT(e[i++])});for(var o=0;o<r.height;++o)e:for(var a=0;a<r.width;++a){for(i=0;i<n.length;++i){var s=n[i].matrix.get(o,a);if(!n[i].pred(null==s||""===s?0:s))continue e}t(o,a)}}function US(e){return function(t,n,i,r){var o=this;if(r instanceof Ov){var a=r.clone().toRangeRef();if(a.width()!=n.width||a.height()!=n.height)return isFinite(a.topLeft.row)||(a.topLeft.row=0),isFinite(a.topLeft.col)||(a.topLeft.col=0),a.bottomRight.row=a.topLeft.row+n.height-1,a.bottomRight.col=a.topLeft.col+n.width-1,o.resolveCells([a],(function(){t(e(n,i,o.asMatrix(a)))}))}t(e(n,i,o.asMatrix(r)))}}function WS(e,t,n){var i=[],r=e.each((function(e){if(e instanceof A_)return e;"number"==typeof e&&i.push(e)}));return r||(t>i.length?new A_("NUM"):i.sort(n)[t-1])}function jS(e){return e.reduce((function(e,t){return e+t}),0)/e.length}function qS(e,t,n){return null==n&&(n=jS(e)),e.reduce((function(e,t){return e+Math.pow(t-n,2)}),0)/t}function GS(e,t){return Math.sqrt(qS(e,t))}function KS(e,t,n){var i=0,r=0,o=null,a=null,s=!1;return e.forEach((function(e){e<t?(i++,o=null==o?e:Math.max(o,e)):e>t?(r++,a=null==a?e:Math.min(a,e)):s=!0})),i||r?s?n?(i+1)/(e.length+1):i/(i+r):((a-t)*KS(e,o,n)+(t-o)*KS(e,a,n))/(a-o):new A_("N/A")}function YS(e,t,n){for(var i=0,r=jS(e),o=jS(t),a=e.length,s=0;s<a;++s)i+=(e[s]-r)*(t[s]-o);return i/n}AS("binary+",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||null==o&&(o=0,1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a&&(a=0,1)?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return e+t})),AS("binary-",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||null==o&&(o=0,1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a&&(a=0,1)?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return e-t})),AS("binary*",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||null==o&&(o=0,1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a&&(a=0,1)?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return e*t})),AS("binary/",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||null==o&&(o=0,1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||0==a&&(r="DIV/0",1)?a instanceof A_?a:new A_(r):(n.push(a),2<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return e/t})),AS("binary^",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||null==o&&(o=0,1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a&&(a=0,1)?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return Math.pow(e,t)})),AS("binary&",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||("string"==typeof o||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1))||"boolean"==typeof o||null==o))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||("string"==typeof a||"boolean"==typeof a||"number"==typeof a?(a+="",1):void 0===a&&(a="",1))||"boolean"==typeof a||null==a?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return null==e&&(e=""),null==t&&(t=""),""+e+t})),AS("binary=",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(r=this.force(r),!(n<=e.length))return r instanceof A_?r:new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new A_("N/A"):t):o instanceof A_?o:new A_(i))},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return FS(e,t)})),AS("binary<>",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(r=this.force(r),!(n<=e.length))return r instanceof A_?r:new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new A_("N/A"):t):o instanceof A_?o:new A_(i))},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return!FS(e,t)})),AS("binary<",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(r=this.force(r),!(n<=e.length))return r instanceof A_?r:new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new A_("N/A"):t):o instanceof A_?o:new A_(i))},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return RS(e,t,((e,t)=>e<t))})),AS("binary<=",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(r=this.force(r),!(n<=e.length))return r instanceof A_?r:new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new A_("N/A"):t):o instanceof A_?o:new A_(i))},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return RS(e,t,((e,t)=>e<=t))})),AS("binary>",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(r=this.force(r),!(n<=e.length))return r instanceof A_?r:new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new A_("N/A"):t):o instanceof A_?o:new A_(i))},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return RS(e,t,((e,t)=>e>t))})),AS("binary>=",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(r=this.force(r),!(n<=e.length))return r instanceof A_?r:new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:(o=this.force(o),n<=e.length?(t.push(o),n<e.length?new A_("N/A"):t):o instanceof A_?o:new A_(i))},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return RS(e,t,((e,t)=>e>=t))})),AS("unary+",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))||null==r&&(r=0,1)?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e})),AS("unary-",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))||null==r&&(r=0,1)?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return-e})),AS("unary%",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))||null==r&&(r=0,1)?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e/100})),AS("binary:",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(!(r instanceof $v))return new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:o instanceof $v?(t.push(o),2<e.length?new A_("N/A"):t):new A_(i)}},(function(e,t){return new Uv(e,t).setSheet(e.sheet||this.formula.sheet,e.hasSheet())})),AS("binary,",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(!(r instanceof Ov))return new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:o instanceof Ov?(t.push(o),2<e.length?new A_("N/A"):t):new A_(i)}},(function(e,t){return new Wv([e,t])})),AS("binary ",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(!(r instanceof Ov))return new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:o instanceof Ov?(t.push(o),2<e.length?new A_("N/A"):t):new A_(i)}},(function(e,t){return e.intersect(t)})),AS("not",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:null!=(i=this.force(i))&&1<=e.length||null==i&&(i=0,1)?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return!this.bool(e)})),AS("isblank",!1,{check:function(e){var t=[],n=0,i=e[n++];return 1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):new A_("VALUE")},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e instanceof $v&&null==(e=this.getRefData(e))})),AS("iserror",!1,{check:function(e){var t=[],n=0,i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e instanceof A_})),AS("iserr",!1,{check:function(e){var t=[],n=0,i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e instanceof A_&&"N/A"!=e.code})),AS("isna",!1,{check:function(e){var t=[],n=0,i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e instanceof A_&&"N/A"==e.code})),AS("islogical",!1,{check:function(e){var t=[],n=0,i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return"boolean"==typeof e})),AS("isnontext",!1,{check:function(e){var t=[],n=0,i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return"string"!=typeof e})),AS("istext",!1,{check:function(e){var t=[],n=0,i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return"string"==typeof e})),AS("isnumber",!1,{check:function(e){var t=[],n=0,i=e[n++];return i=this.force(i),1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return"number"==typeof e})),AS("isref",!1,{check:function(e){var t=[],n=0,i=e[n++];return 1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):new A_("VALUE")},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e instanceof $v||e instanceof Uv})),AS("_matrix",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:(t=this.asMatrix(r))&&(r=t)||("string"==typeof r||"boolean"==typeof r||"number"==typeof r?(r+="",1):void 0===r&&(r="",1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return"string"==typeof e&&(e=this.asMatrix([e.split(/\s*,\s*/)])),e})),DS[",getname"]=function(e,t){this.fetchName(t[0],e)},AS("abs",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},Math.abs),AS("cos",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},Math.cos),AS("sin",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},Math.sin),AS("acos",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},Math.acos),AS("asin",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},Math.asin),AS("tan",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},Math.tan),AS("atan",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},Math.atan),AS("exp",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},Math.exp),AS("sqrt",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},Math.sqrt),AS("ln",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},Math.log),AS("log",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a>0||(r="NUM",0))||null==a&&(a=10,1)?(n.push(a),1==a&&(r="DIV/0",1)?new A_(r):2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return Math.log(e)/Math.log(t)})),AS("log10",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))&&(o>0||(r="NUM",0))?(n.push(o),1<e.length?new A_("N/A"):n):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return Math.log(e)/Math.log(10)})),AS("pi",!1,{check:function(e){return 0<e.length?new A_("N/A"):[]}},(function(){return Math.PI})),AS("sqrtpi",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))&&(o>=0||(r="NUM",0))?(n.push(o),1<e.length?new A_("N/A"):n):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return Math.sqrt(e*Math.PI)})),AS("degrees",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return 180*e/Math.PI%360})),AS("radians",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return Math.PI*e/180})),AS("cosh",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},LS),AS("acosh",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:"number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))?(n.push(o),o>=1||(r="N/A",0)?1<e.length?new A_("N/A"):n:new A_(r)):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return Math.log(e+Math.sqrt(e-1)*Math.sqrt(e+1))})),AS("sinh",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},BS),AS("asinh",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return Math.log(e+Math.sqrt(e*e+1))})),AS("sec",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return 1/Math.cos(e)})),AS("sech",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return 1/LS(e)})),AS("csc",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return 1/Math.sin(e)})),AS("csch",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return 1/BS(e)})),AS("atan2",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||0==o&&(r="DIV/0",1))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return Math.atan(t/e)})),AS("tanh",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},OS),AS("atanh",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))&&(o>-1&&o<1||(r="NUM",0))?(n.push(o),1<e.length?new A_("N/A"):n):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return Math.log(Math.sqrt(1-e*e)/(1-e))})),AS("cot",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||0==o&&(r="DIV/0",1)?o instanceof A_?o:new A_(r):(n.push(o),1<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return 1/Math.tan(e)})),AS("coth",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||0==o&&(r="DIV/0",1)?o instanceof A_?o:new A_(r):(n.push(o),1<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return 1/OS(e)})),AS("acot",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return Math.PI/2-Math.atan(e)})),AS("acoth",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:"number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))?(n.push(o),o<-1||(r="N/A",0)||o>1||(r="N/A",0)?1<e.length?new A_("N/A"):n:new A_(r)):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return Math.log((e+1)/(e-1))/2})),AS("power",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return Math.pow(e,t)})),AS("mod",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||0==a&&(r="DIV/0",1)?a instanceof A_?a:new A_(r):(n.push(a),2<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return e%t})),AS("quotient",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||0==a&&(r="DIV/0",1)?a instanceof A_?a:new A_(r):(n.push(a),2<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return Math.floor(e/t)})),AS("ceiling",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),a>=0||o<0||(r="N/A",0)?2<e.length?new A_("N/A"):n:new A_(r)):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return t?t*Math.ceil(e/t):0})),AS("ceiling.precise",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a&&(a=1,1)?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return(t=Math.abs(t))?t*Math.ceil(e/t):0})),z_.runtime.defineAlias("iso.ceiling","ceiling.precise"),AS("ceiling.math",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a&&(a=o<0?-1:1,1)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)||null==s&&(s=0,1)?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);return l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n){return t&&e?(e<0&&(!n&&t<0||n&&t>0)&&(t=-t),t?t*Math.ceil(e/t):0):0})),AS("floor",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),a>=0||o<0||(r="N/A",0)?2<e.length?new A_("N/A"):n:new A_(r)):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return t?t*Math.floor(e/t):0})),AS("floor.precise",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a&&(a=1,1)?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return(t=Math.abs(t))?t*Math.floor(e/t):0})),AS("floor.math",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a&&(a=o<0?-1:1,1)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)||null==s&&(s=0,1)?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);return l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n){return t&&e?(e<0&&(!n&&t<0||n&&t>0)&&(t=-t),t?t*Math.floor(e/t):0):0})),AS("int",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},Math.floor),AS("mround",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return t?t*Math.round(e/t):0})),AS("round",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){var n=e<0?-1:1;return n<0&&(e=-e),t=Math.pow(10,t),e=MS(e*t),n*(e=Math.round(e))/t})),AS("roundup",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return t=Math.pow(10,t),(e=(e=MS(e*t))<0?Math.floor(e):Math.ceil(e))/t})),AS("rounddown",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return t=Math.pow(10,t),(e=(e=MS(e*t))<0?Math.ceil(e):Math.floor(e))/t})),AS("even",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){var t=e<0?Math.floor(e):Math.ceil(e);return t%2?t+(t<0?-1:1):t})),AS("odd",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){var t=e<0?Math.floor(e):Math.ceil(e);return t%2?t:t+(t<0?-1:1)})),AS("sign",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e<0?-1:e>0?1:0})),AS("gcd",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){for(var t=e[0],n=1;n<e.length;++n)t=VS(t,e[n]);return t})),AS("lcm",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){for(var t=e[0],n=1;n<e.length;++n)t=NS(t,e[n]);return t})),AS("sum",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return e.reduce((function(e,t){return e+t}),0)})),AS("product",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return e.reduce((function(e,t){return e*t}),1)})),AS("sumproduct",!1,{check:function(e){var t,n,i=[],r=[],o=0,a="VALUE",s=e[o++];if(s instanceof A_)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof A_?s:new A_(a);if(r.push(s),o>=e.length)return new A_("N/A");r.push(t=[]),i.push(r),r=t;do{var l=e[o++];if(l instanceof A_)return l;if(!(n=this.asMatrix(l))||!(l=n)||l.width!=s.width&&(a="N/A",1)||l.height!=s.height&&(a="N/A",1))return l instanceof A_?l:new A_(a);r.push(l)}while(o<e.length);return r=i.pop(),o<e.length?new A_("N/A"):r},resolve:function(e,t){var n=[],i=0;for(n.push(e[i++]);i<e.length;)n.push(e[i++]);this.resolveCells(n,t)}},(function(e,t){var n=0;return e.each((function(e,i,r){if("number"==typeof e){for(var o=0;o<t.length;++o){var a=t[o].get(i,r);if("number"!=typeof a)return;e*=a}n+=e}})),n})),AS("sumsq",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return e.reduce((function(e,t){return e+t*t}),0)})),AS("sumx2my2",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:!(t=this.asMatrix(a))||!(a=t)||a.width!=o.width&&(r="N/A",1)||a.height!=o.height&&(r="N/A",1)?a instanceof A_?a:new A_(r):(n.push(a),2<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){var n=0;return e.each((function(e,i,r){var o=t.get(i,r);"number"==typeof e&&"number"==typeof o&&(n+=e*e-o*o)})),n})),AS("sumx2py2",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:!(t=this.asMatrix(a))||!(a=t)||a.width!=o.width&&(r="N/A",1)||a.height!=o.height&&(r="N/A",1)?a instanceof A_?a:new A_(r):(n.push(a),2<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){var n=0;return e.each((function(e,i,r){var o=t.get(i,r);"number"==typeof e&&"number"==typeof o&&(n+=e*e+o*o)})),n})),AS("sumxmy2",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:!(t=this.asMatrix(a))||!(a=t)||a.width!=o.width&&(r="N/A",1)||a.height!=o.height&&(r="N/A",1)?a instanceof A_?a:new A_(r):(n.push(a),2<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){var n=0;return e.each((function(e,i,r){var o=t.get(i,r);"number"==typeof e&&"number"==typeof o&&(n+=(e-o)*(e-o))})),n})),AS("seriessum",!1,{check:function(e){var t,n,i=[],r=0,o="VALUE",a=e[r++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(o);i.push(a);var s=e[r++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))))return s instanceof A_?s:new A_(o);i.push(s);var l=e[r++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))))return l instanceof A_?l:new A_(o);i.push(l);var c=e[r++];return c instanceof A_?c:(n=this.asMatrix(c))&&(c=n)?(i.push(c),4<e.length?new A_("N/A"):i):c instanceof A_?c:new A_(o)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){var r=0;return i.each((function(i){if("number"!=typeof i)throw new A_("VALUE");r+=i*Math.pow(e,t),t+=n})),r})),AS("min",!1,{check:function(e){var t=[],n=0;try{var i=this.cellValues(e.slice(n)).reduce(function(e,t){if(t instanceof A_)throw t;return"number"==typeof t&&(t=MS(t),1)&&e.push(t),e}.bind(this),[]);n=e.length,t.push(i)}catch(e){if(e instanceof A_)return e;throw e}return n<e.length?new A_("N/A"):t},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return e.length?Math.min.apply(Math,e):0})),AS("max",!1,{check:function(e){var t=[],n=0;try{var i=this.cellValues(e.slice(n)).reduce(function(e,t){if(t instanceof A_)throw t;return"number"==typeof t&&(t=MS(t),1)&&e.push(t),e}.bind(this),[]);n=e.length,t.push(i)}catch(e){if(e instanceof A_)return e;throw e}return n<e.length?new A_("N/A"):t},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return e.length?Math.max.apply(Math,e):0})),AS("counta",!1,{check:function(e){var t=[],n=0;try{var i=this.cellValues(e.slice(n)).reduce(function(t,i){return null!=i&&n<=e.length&&t.push(i),t}.bind(this),[]);n=e.length,t.push(i)}catch(e){if(e instanceof A_)return e;throw e}return n<e.length?new A_("N/A"):t},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return e.length})),AS("count",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i)).reduce(function(e,n){return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return e.length})),AS("countunique",!1,{check:function(e){var t=[],n=0;try{var i=this.cellValues(e.slice(n)).reduce(function(t,i){return null!=i&&n<=e.length&&t.push(i),t}.bind(this),[]);n=e.length,t.push(i)}catch(e){if(e instanceof A_)return e;throw e}return n<e.length?new A_("N/A"):t},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){var t=0,n=[];return e.forEach((function(e){n.indexOf(e)<0&&(t++,n.push(e))})),t})),AS("countblank",!1,{check:function(e){var t,n,i=[],r=[],o=0;if(o>=e.length)return new A_("N/A");r.push(t=[]),i.push(r),r=t;do{var a=e[o++];if(a instanceof A_)return a;if(!((n=this.asMatrix(a))&&(a=n)||null!=a&&o<=e.length))return a instanceof A_?a:new A_("VALUE");r.push(a)}while(o<e.length);return r=i.pop(),o<e.length?new A_("N/A"):r},resolve:function(e,t){for(var n=[],i=0;i<e.length;)n.push(e[i++]);this.resolveCells(n,t)}},(function(e){var t=0;function n(e){null!=e&&""!==e||t++}return function(e){for(var t=0;t<e.length;++t){var i=e[t];i instanceof R_?i.each(n,!0):n(i)}}(e),t})),AS("iseven",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e%2==0})),AS("isodd",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e%2!=0})),AS("n",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:null!=(i=this.force(i))&&1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return"boolean"==typeof e?e?1:0:"number"==typeof e?e:0})),AS("na",!1,{check:function(e){return 0<e.length?new A_("N/A"):[]}},(function(){return new A_("N/A")})),AS("countifs",!1,{check:function(e){var t,n,i=[],r=[],o=0,a="VALUE",s=e[o++];if(s instanceof A_)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof A_?s:new A_(a);r.push(s);var l=e[o++];if(l instanceof A_)return l;if(!(null!=(l=this.force(l))&&o<=e.length))return l instanceof A_?l:new A_(a);for(r.push(l),r.push(t=[]),i.push(r),r=t;o<e.length;){var c=e[o++];if(c instanceof A_)return c;if(!(n=this.asMatrix(c))||!(c=n))return c instanceof A_?c:new A_(a);r.push(c);var d=e[o++];if(d instanceof A_)return d;if(!(null!=(d=this.force(d))&&o<=e.length))return d instanceof A_?d:new A_(a);r.push(d)}return r=i.pop(),o<e.length?new A_("N/A"):r},resolve:function(e,t){var n=[],i=0;for(n.push(e[i++]),n.push(e[i++]);i<e.length;)n.push(e[i++]),n.push(e[i++]);this.resolveCells(n,t)}},(function(e,t,n){var i=0;return n.unshift(e,t),$S(n,(function(){i++})),i})),AS("sumifs",!1,{check:function(e){var t,n,i=[],r=[],o=0,a="VALUE",s=e[o++];if(s instanceof A_)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof A_?s:new A_(a);r.push(s);var l=e[o++];if(l instanceof A_)return l;if(!(n=this.asMatrix(l))||!(l=n))return l instanceof A_?l:new A_(a);r.push(l);var c=e[o++];if(c instanceof A_)return c;if(!(null!=(c=this.force(c))&&o<=e.length))return c instanceof A_?c:new A_(a);for(r.push(c),r.push(t=[]),i.push(r),r=t;o<e.length;){var d=e[o++];if(d instanceof A_)return d;if(!(n=this.asMatrix(d))||!(d=n))return d instanceof A_?d:new A_(a);r.push(d);var u=e[o++];if(u instanceof A_)return u;if(!(null!=(u=this.force(u))&&o<=e.length))return u instanceof A_?u:new A_(a);r.push(u)}return r=i.pop(),o<e.length?new A_("N/A"):r},resolve:function(e,t){var n=[],i=0;for(n.push(e[i++]),n.push(e[i++]),n.push(e[i++]);i<e.length;)n.push(e[i++]),n.push(e[i++]);this.resolveCells(n,t)}},(function(e,t,n,i){i.unshift(e,cT,t,n);var r=0;return $S(i,(function(t,n){var i=e.get(t,n);i&&(r+=i)})),r})),AS("averageifs",!1,{check:function(e){var t,n,i=[],r=[],o=0,a="VALUE",s=e[o++];if(s instanceof A_)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof A_?s:new A_(a);r.push(s);var l=e[o++];if(l instanceof A_)return l;if(!(n=this.asMatrix(l))||!(l=n))return l instanceof A_?l:new A_(a);r.push(l);var c=e[o++];if(c instanceof A_)return c;if(!(null!=(c=this.force(c))&&o<=e.length))return c instanceof A_?c:new A_(a);for(r.push(c),r.push(t=[]),i.push(r),r=t;o<e.length;){var d=e[o++];if(d instanceof A_)return d;if(!(n=this.asMatrix(d))||!(d=n))return d instanceof A_?d:new A_(a);r.push(d);var u=e[o++];if(u instanceof A_)return u;if(!(null!=(u=this.force(u))&&o<=e.length))return u instanceof A_?u:new A_(a);r.push(u)}return r=i.pop(),o<e.length?new A_("N/A"):r},resolve:function(e,t){var n=[],i=0;for(n.push(e[i++]),n.push(e[i++]),n.push(e[i++]);i<e.length;)n.push(e[i++]),n.push(e[i++]);this.resolveCells(n,t)}},(function(e,t,n,i){i.unshift(e,cT,t,n);var r=0,o=0;return $S(i,(function(t,n){var i=e.get(t,n);null!=i&&""!==i||(i=0),r+=i,o++})),o?r/o:new A_("DIV/0")})),AS("countif",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:null!=(a=this.force(a))&&2<=e.length?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0;t.push(e[o++]),r.push(!1);var a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){t=lT(t);var n=0;return e.each((function(e){t(e)&&n++})),n})),AS("sumif",!0,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!(null!=(a=this.force(a))&&i<=e.length))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:s instanceof $v||s instanceof Uv||(t=this.asMatrix(s))&&(s=t)||null==(s=this.force(s))&&(s=o,1)?(n.push(s),i<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0;t.push(e[o++]),r.push(!1);var a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,t.push(e[o++]),r.push(!1),{args:t,width:n,height:i,arrays:r}}},US((function(e,t,n){var i=0;return t=lT(t),e.each((function(e,r,o){if(t(e)){var a=n.get(r,o);cT(a)&&(i+=a||0)}})),i}))),AS("averageif",!0,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!(null!=(a=this.force(a))&&i<=e.length))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:s instanceof $v||s instanceof Uv||(t=this.asMatrix(s))&&(s=t)||null==(s=this.force(s))&&(s=o,1)?(n.push(s),i<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0;t.push(e[o++]),r.push(!1);var a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,t.push(e[o++]),r.push(!1),{args:t,width:n,height:i,arrays:r}}},US((function(e,t,n){var i=0,r=0;return t=lT(t),e.each((function(e,o,a){if(t(e)){var s=n.get(o,a);cT(s)&&(i+=s||0,r++)}})),r?i/r:new A_("DIV/0")}))),AS("large",!1,{check:function(e){var t,n,i=[],r=0,o="VALUE",a=e[r++];if(a instanceof A_)return a;if(!(n=this.asMatrix(a))||!(a=n))return a instanceof A_?a:new A_(o);i.push(a);var s=e[r++];return s instanceof A_?s:("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&(s>0||(o="NUM",0))?(i.push(s),2<e.length?new A_("N/A"):i):s instanceof A_?s:new A_(o)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0;t.push(e[o++]),r.push(!1);var a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return WS(e,t,uT)})),AS("small",!1,{check:function(e){var t,n,i=[],r=0,o="VALUE",a=e[r++];if(a instanceof A_)return a;if(!(n=this.asMatrix(a))||!(a=n))return a instanceof A_?a:new A_(o);i.push(a);var s=e[r++];return s instanceof A_?s:("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&(s>0||(o="NUM",0))?(i.push(s),2<e.length?new A_("N/A"):i):s instanceof A_?s:new A_(o)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0;t.push(e[o++]),r.push(!1);var a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return WS(e,t,dT)})),AS("stdev.s",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}return o.length>=2||(r="NUM",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return GS(e,e.length-1)})),AS("stdev.p",!1,{check:function(e){var t=[],n=0,i="VALUE";try{var r=this.cellValues(e.slice(n)).reduce(function(e,t){if(t instanceof A_)throw t;return"number"==typeof t&&(t=MS(t),1)&&e.push(t),e}.bind(this),[]);n=e.length,t.push(r)}catch(e){if(e instanceof A_)return e;throw e}return r.length>=1||(i="NUM",0)?n<e.length?new A_("N/A"):t:new A_(i)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return GS(e,e.length)})),AS("var.s",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}return o.length>=2||(r="NUM",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return qS(e,e.length-1)})),AS("var.p",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}return o.length>=2||(r="NUM",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return qS(e,e.length)})),AS("median",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}return o.length>0||(r="N/A",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){var t=e.length;return e.sort(dT),t%2?e[t>>1]:(e[t>>=1]+e[t-1])/2})),AS("mode.sngl",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){e.sort(dT);for(var t=null,n=0,i=1,r=null,o=0;o<e.length;++o){var a=e[o];a!=t?(n=1,t=a):n++,n>i&&(i=n,r=a)}return null==r?new A_("N/A"):r})),AS("mode.mult",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){var t=Object.create(null),n=2,i=[];e.forEach((function(e){var r=t[e]||0;t[e]=++r,r==n?i.push(e):r>n&&(n=r,i=[e])}));var r=new R_(this);return i.forEach((function(e,t){r.set(t,0,e)})),r})),AS("geomean",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}return o.length>0||(r="NUM",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){var t=e.length,n=e.reduce((function(e,t){if(t<0)throw new A_("NUM");return e*t}),1);return Math.pow(n,1/t)})),AS("harmean",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}return o.length>0||(r="NUM",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return e.length/e.reduce((function(e,t){if(!t)throw new A_("DIV/0");return e+1/t}),0)})),AS("trimmean",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a>=0&&a<1||(r="NUM",0))?(n.push(a),o.length>0||(r="NUM",0)?i<e.length?new A_("N/A"):n:new A_(r)):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){var n=e.length;e.sort(dT);var i=Math.floor(n*t);i%2&&--i;for(var r=0,o=i/=2;o<n-i;++o)r+=e[o];return r/(n-2*i)})),AS("frequency",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e,t){e.sort(dT),t.sort(dT);var n=-1/0,i=0;function r(t){for(var r=0;i<e.length&&e[i]>n&&e[i]<=t;)++r,++i;return r}var o=new R_(this);return t.forEach((function(e,t){var i=r(e);n=e,o.set(t,0,i)})),o.set(o.height,0,e.length-i),o})),AS("rank.eq",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}var s=e[i++];return s instanceof A_?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)||null==s&&(s=!1,1)?(n.push(s),i<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){t.sort(n?dT:uT);var i=t.indexOf(e);return i<0?new A_("N/A"):i+1})),z_.runtime.defineAlias("rank","rank.eq"),AS("rank.avg",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);try{var a=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}var s=e[i++];return s instanceof A_?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)||null==s&&(s=!1,1)?(n.push(s),i<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){t.sort(n?dT:uT);var i=t.indexOf(e);if(i<0)return new A_("N/A");for(var r=i;t[r]==e;++r);return(i+r+1)/2})),AS("kurt",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}return o.length>=4||(r="NUM",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){var t=e.length,n=jS(e),i=qS(e,t-1,n),r=Math.sqrt(i);return t*(t+1)/((t-1)*(t-2)*(t-3))*e.reduce((function(e,t){return e+Math.pow((t-n)/r,4)}),0)-3*Math.pow(t-1,2)/((t-2)*(t-3))})),AS("percentrank.inc",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:null==(s=this.force(s))&&(s=3,1)||("number"==typeof s||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&((s|=0)>0||(r="NUM",0))?(n.push(s),o.length>0||(r="NUM",0)?i<e.length?new A_("N/A"):n:new A_(r)):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){var i=KS(e,t,0);return i=i.toFixed(n+1),parseFloat(i.substr(0,i.length-1))})),AS("percentrank.exc",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:null==(s=this.force(s))&&(s=3,1)||("number"==typeof s||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&((s|=0)>0||(r="NUM",0))?(n.push(s),o.length>0||(r="NUM",0)?i<e.length?new A_("N/A"):n:new A_(r)):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){var i=KS(e,t,1);return i=i.toFixed(n+1),parseFloat(i.substr(0,i.length-1))})),z_.runtime.defineAlias("percentrank","percentrank.inc"),AS("covariance.p",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}return o.length!=a.length&&(r="N/A",1)?new A_(r):o.length>0||(r="DIV/0",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e,t){return YS(e,t,e.length)})),AS("covariance.s",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}return o.length!=a.length&&(r="N/A",1)?new A_(r):o.length>1||(r="DIV/0",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e,t){return YS(e,t,e.length-1)})),z_.runtime.defineAlias("covar","covariance.p");var QS=p_((function(e){for(var t=2,n=1;t<=e;++t)n*=t;return n}));AS("fact",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))&&((o|=0)>=0||(r="NUM",0))?(n.push(o),1<e.length?new A_("N/A"):n):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},QS),AS("factdouble",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))&&((o|=0)>=0||(r="NUM",0))?(n.push(o),1<e.length?new A_("N/A"):n):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){for(var t=2+(1&e),n=1;t<=e;t+=2)n*=t;return n})),AS("multinomial",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){var t=1,n=0;return e.forEach((function(e){if(e<0)throw new A_("NUM");n+=e,t*=QS(e)})),QS(n)/t}));var XS=p_((function(e,t){for(var n=t+1,i=1,r=1,o=1;i<=e-t;++n,++i)r*=n,o*=i;return r/o}));function ZS(e,t){e.sort(dT);var n=e.length,i=0|t,r=t-i;return 0===i?e[0]:i>=n?e[n-1]:e[--i]+r*(e[i+1]-e[i])}function JS(e,t){return ZS(e,t*(e.length-1)+1)}function eT(e,t){return ZS(e,t*(e.length+1))}AS("combin",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a|=0,1)&&(a>=0&&a<=o||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},XS),AS("combina",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a|=0,1)&&(a>=1&&a<=o||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return XS(e+t-1,e-1)})),AS("average",!1,{check:function(e){var t=[],n=0,i="VALUE";try{var r=this.cellValues(e.slice(n)).reduce(function(e,t){if(t instanceof A_)throw t;return"number"==typeof t&&(t=MS(t),1)&&e.push(t),e}.bind(this),[]);n=e.length,t.push(r)}catch(e){if(e instanceof A_)return e;throw e}return r.length>0||(i="DIV/0",0)?n<e.length?new A_("N/A"):t:new A_(i)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){return e.reduce((function(e,t){return e+t}),0)/e.length})),AS("averagea",!1,{check:function(e){var t=[],n=0;try{var i=this.cellValues(e.slice(n)).reduce(function(t,i){if(i instanceof A_)throw i;return null!=i&&n<=e.length&&t.push(i),t}.bind(this),[]);n=e.length,t.push(i)}catch(e){if(e instanceof A_)return e;throw e}return n<e.length?new A_("N/A"):t},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){var t=0,n=0;return e.forEach((function(e){"string"!=typeof e&&(t+=e),++n})),n?t/n:new A_("DIV/0")})),AS("percentile.inc",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a>=0&&a<=1||(r="NUM",0))?(n.push(a),i<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e[i++]),this.resolveCells(n,t)}},JS),AS("percentile.exc",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a>0&&a<1||(r="NUM",0))?(n.push(a),i<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e[i++]),this.resolveCells(n,t)}},eT),AS("quartile.inc",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}var o=e[i++];return o instanceof A_?o:0!==(o=this.force(o))&&1!==o&&2!==o&&3!==o&&4!==o?o instanceof A_?o:new A_("VALUE"):(n.push(o),i<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){return JS(e,t/4)})),AS("quartile.exc",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}var o=e[i++];return o instanceof A_?o:0!==(o=this.force(o))&&1!==o&&2!==o&&3!==o&&4!==o?o instanceof A_?o:new A_("VALUE"):(n.push(o),i<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){return eT(e,t/4)})),z_.runtime.defineAlias("quartile","quartile.inc"),z_.runtime.defineAlias("percentile","percentile.inc");var tT=["AVERAGE","COUNT","COUNTA","MAX","MIN","PRODUCT","STDEV.S","STDEV.P","SUM","VAR.S","VAR.P","MEDIAN","MODE.SNGL","LARGE","SMALL","PERCENTILE.INC","QUARTILE.INC","PERCENTILE.EXC","QUARTILE.EXC"];function nT(e,t,n){var i=[];return function t(r){if(r instanceof Ov)e.getRefCells(r,!0).forEach((function(e){var t=e.value;if(!(1&n&&e.hidden)){if(e.formula){var r=e.formula.print(e.row,e.col);if(/^\s*(?:aggregate|subtotal)\s*\(/i.test(r)&&!(4&n))return}2&n&&t instanceof A_||("number"==typeof t||t instanceof A_)&&i.push(t)}}));else if(Array.isArray(r))for(var o=0;o<r.length;++o)t(r[o]);else r instanceof R_?r.each(t):("number"==typeof r||r instanceof A_&&!(2&n))&&i.push(r)}(t),i}function iT(e,t,n,i){if(i){for(var r=0,o=0;o<=e;++o)r+=XS(t,o)*Math.pow(n,o)*Math.pow(1-n,t-o);return r}return XS(t,e)*Math.pow(n,e)*Math.pow(1-n,t-e)}function rT(e){var t=IS(ES(e,0,1));return 4==t.day||3==t.day&&z_.runtime.isLeapYear(e)?53:52}function oT(e,t,n){var i=IS(e),r=IS(t);return n?(31==i.date&&(i.date=30),31==r.date&&(r.date=30)):(1==i.month&&1==r.month&&i.date==zS(i.year,1)&&r.date==zS(r.year,1)&&(r.date=30),i.date==zS(i.year,i.month)?(i.date=30,31==r.date&&(r.date=30)):30==i.date&&31==r.date&&(r.date=30)),360*(r.year-i.year)+30*(r.month-i.month)+(r.date-i.date)}AS("aggregate",!0,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(1!==(r=this.force(r))&&2!==r&&3!==r&&4!==r&&5!==r&&6!==r&&7!==r&&8!==r&&9!==r&&10!==r&&11!==r&&12!==r&&13!==r&&14!==r&&15!==r&&16!==r&&17!==r&&18!==r&&19!==r)return r instanceof A_?r:new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:null==(o=this.force(o))&&(o=0,1)||0===o||1===o||2===o||3===o||4===o||5===o||6===o||7===o?(t.push(o),t.push(e.slice(n)),(n=e.length)<e.length?new A_("N/A"):t):o instanceof A_?o:new A_(i)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){var r=this;r.resolveCells(i,(function(){var o;if(t>12){o=nT(r,i[0],n);var a=i[1];if(a instanceof $v&&(a=r.getRefData(a)),"number"!=typeof a)return e(new A_("VALUE"))}else o=nT(r,i,n);r.func(tT[t-1],e,o)}))})),AS("subtotal",!0,{check:function(e){var t,n,i=[],r=[],o=0,a="VALUE",s=e[o++];if(s instanceof A_)return s;if(1!==(s=this.force(s))&&2!==s&&3!==s&&4!==s&&5!==s&&6!==s&&7!==s&&8!==s&&9!==s&&10!==s&&11!==s&&101!==s&&102!==s&&103!==s&&104!==s&&105!==s&&106!==s&&107!==s&&108!==s&&109!==s&&110!==s&&111!==s)return s instanceof A_?s:new A_(a);if(r.push(s),o>=e.length)return new A_("N/A");r.push(t=[]),i.push(r),r=t;do{var l=e[o++];if(l instanceof A_)return l;if(!(l instanceof Ov||(n=this.asMatrix(l))&&(l=n)))return new A_(a);r.push(l)}while(o<e.length);return r=i.pop(),o<e.length?new A_("N/A"):r},resolve:function(e,t){var n=[],i=0;for(n.push(e[i++]);i<e.length;)i++;this.resolveCells(n,t)}},(function(e,t){var n=this,i=t>100;i&&(t-=100);for(var r=[],o=2;o<arguments.length;++o)r.push(arguments[o]);n.resolveCells(r,(function(){var o=nT(n,r,i?1:0);n.func(tT[t-1],e,o)}))})),AS("avedev",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}return o.length>=2||(r="NUM",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e){var t=e.reduce((function(e,t){return e+t}),0)/e.length;return e.reduce((function(e,n){return e+Math.abs(n-t)}),0)/e.length})),AS("binom.dist",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!(("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a|=0,1)&&(a>=o||(r="N/A",0))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>=0&&s<=1||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},iT),z_.runtime.defineAlias("binomdist","binom.dist"),AS("binom.inv",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>=0&&a<=1||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&(s>=0&&s<=1||(r="NUM",0))?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){for(var i=0;i<=e;++i)if(iT(i,e,t,!0)>=n)return i;return new A_("N/A")})),z_.runtime.defineAlias("critbinom","binom.inv"),AS("binom.dist.range",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>=0&&a<=1||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!(("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&(s|=0,1)&&(s>=0&&s<=o||(r="NUM",0))))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&(l|=0,1)&&(l>=s&&l<=o||(r="NUM",0))||null==l&&(l=s,1)?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){for(var r=0,o=n;o<=i;++o)r+=XS(e,o)*Math.pow(t,o)*Math.pow(1-t,e-o);return r})),AS("negbinom.dist",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>=0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>=0&&s<=1||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){if(i){for(var r=0;e>=0;)r+=XS(e+t-1,e)*Math.pow(n,t)*Math.pow(1-n,e),e--;return r}return XS(e+t-1,e)*Math.pow(n,t)*Math.pow(1-n,e)})),z_.runtime.defineAlias("negbinomdist","negbinom.dist"),AS("address",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!(null==(s=this.force(s))&&(s=1,1)||1===s||2===s||3===s||4===s))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!(null==(l=this.force(l))&&(l=!0,1)||"boolean"==typeof l||"number"==typeof l&&(l=!!l,1)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:null==(c=this.force(c))||("string"==typeof c||"boolean"==typeof c||"number"==typeof c?(c+="",1):void 0===c&&(c="",1))?(n.push(c),5<e.length?new A_("N/A"):n):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){var o=new $v(e-1,t-1,n-1);return r&&o.setSheet(r,!0),i?o.print(0,0):o.print()})),AS("areas",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:i instanceof Ov?(t.push(i),1<e.length?new A_("N/A"):t):new A_("VALUE")}},(function(e){var t=0;return function e(n){n instanceof $v||n instanceof Uv?t++:n instanceof Wv&&n.refs.forEach(e)}(e),t})),AS("choose",!1,{check:function(e){var t,n=[],i=[],r=0,o="VALUE",a=e[r++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(o);if(i.push(a),r>=e.length)return new A_("N/A");i.push(t=[]),n.push(i),i=t;do{var s=e[r++];if(s instanceof A_)return s;if(!(r<=e.length))return new A_(o);i.push(s)}while(r<e.length);return i=n.pop(),r<e.length?new A_("N/A"):i},resolve:function(e,t){var n=[],i=0;for(n.push(e[i++]);i<e.length;)i++;this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);for(a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;o<e.length;)t.push(e[o++]),r.push(!1);return{args:t,width:n,height:i,arrays:r}}},(function(e,t){return e>t.length?new A_("N/A"):t[e-1]})),AS("column",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:i instanceof $v||i instanceof Uv||null==(i=this.force(i))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return e?e instanceof $v?e.col+1:this.asMatrix(e).mapCol((function(t){return t+e.topLeft.col+1})):this.formula.col+1})),AS("columns",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:r instanceof $v||r instanceof Uv||(t=this.asMatrix(r))&&(r=t)?(n.push(r),1<e.length?new A_("N/A"):n):new A_("VALUE")}},(function(e){return e instanceof Ov?e.width():e.width})),AS("formulatext",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:i instanceof Ov?(t.push(i),1<e.length?new A_("N/A"):t):new A_("VALUE")}},(function(e){var t=this.getRefCells(e)[0];return t.formula?t.formula.print(t.row,t.col):new A_("N/A")})),AS("hlookup",!1,{check:function(e){var t,n,i=[],r=0,o="VALUE",a=e[r++];if(a instanceof A_)return a;if(!(null!=(a=this.force(a))&&r<=e.length))return a instanceof A_?a:new A_(o);i.push(a);var s=e[r++];if(s instanceof A_)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof A_?s:new A_(o);i.push(s);var l=e[r++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!((l|=0)>0||(o="NUM",0)))return l instanceof A_?l:new A_(o);i.push(l);var c=e[r++];return c instanceof A_?c:"boolean"==typeof(c=this.force(c))||"number"==typeof c&&(c=!!c,1)||null==c&&(c=!0,1)?(i.push(c),r<e.length?new A_("N/A"):i):c instanceof A_?c:new A_(o)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){var r=null;return t.eachCol((function(n){var o=t.get(0,n);if(i){if(o>e)return!0;r=n}else if(o===e)return r=n,!0})),null==r?new A_("N/A"):t.get(n-1,r)})),AS("index",!0,{check:function(e){var t,n,i=[],r=0,o="VALUE",a=e[r++];if(a instanceof A_)return a;if(!(a instanceof Ov||(n=this.asMatrix(a))&&(a=n)))return a instanceof A_?a:new A_(o);i.push(a);var s=e[r++];if(s instanceof A_)return s;if(!(("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&((s|=0)>=0||(o="NUM",0))||null==s))return s instanceof A_?s:new A_(o);i.push(s);var l=e[r++];if(l instanceof A_)return l;if(!(("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&((l|=0)>=0||(o="NUM",0))||null==l))return l instanceof A_?l:new A_(o);i.push(l);var c=e[r++];return c instanceof A_?c:("number"==typeof(c=this.force(c))||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))&&((c|=0)>0||(o="NUM",0))||null==c&&(c=1,1)?(i.push(c),4<e.length?new A_("N/A"):i):c instanceof A_?c:new A_(o)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){var o=this;if(t instanceof Wv&&(t=t.refs[r-1]),!n&&!i||!t)return e(new A_("N/A"));if(t instanceof $v&&(t=t.toRangeRef()),t instanceof Uv){if(n&&i){if(i>t.width()||n>t.height())return e(new A_("REF"));var a=t.toCell(n-1,i-1);return void o.resolveCells([a],(function(){e(o.getRefData(a))}))}if(!n){var s=t.toColumn(i-1);return void o.resolveCells([s],(function(){e(o.asMatrix(s))}))}if(!i){var l=t.toRow(n-1);return void o.resolveCells([l],(function(){e(o.asMatrix(l))}))}}else if(t instanceof R_){if(t.width>1&&t.height>1){if(n&&i)return e(t.get(n-1,i-1));if(!n)return e(t.mapRow((function(e){return t.get(e,i-1)})));if(!i)return e(t.mapCol((function(e){return t.get(n-1,e)})))}if(1==t.width)return e(t.get((n||1)-1,0));if(1==t.height)return e(t.get(0,(i||1)-1))}else e(new A_("REF"))})),AS("indirect",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){try{var t=this.formula,n=z_.parseFormula(t.sheet,t.row,t.col,e).ast;if(n instanceof Nv&&(n=this.ss.nameValue(n,t.sheet,t.row,t.col)),!(n instanceof Ov))throw 1;return n.absolute(t.row,t.col)}catch(e){return new A_("REF")}})),AS("match",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(null!=(o=this.force(o))&&i<=e.length))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!(t=this.asMatrix(a))||!(a=t))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:-1===(s=this.force(s))||0===s||1===s||null==s&&(s=1,1)?(n.push(s),i<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){var i,r=1;return 0===n?i=lT(e):-1===n?i=lT("<="+e):1===n&&(i=lT(">="+e)),t.each((function(t){if(null!=t&&i(t))return 0!==n&&e!=t&&--r,!0;r++}),!0)&&r>0?r:new A_("N/A")})),AS("offset",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(o instanceof $v||o instanceof Uv))return new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!(("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&((l|=0)>0||(r="NUM",0))||null==l&&(l=o.height(),1)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:("number"==typeof(c=this.force(c))||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))&&((c|=0)>0||(r="NUM",0))||null==c&&(c=o.width(),1)?(n.push(c),5<e.length?new A_("N/A"):n):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;i++,n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0;t.push(e[o++]),r.push(!1);var a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var c=this._arrayArg(e[o]);return c?(t.push(c),n=Math.max(n,c.width),i=Math.max(i,c.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n,i,r){var o=(e instanceof $v?e:e.topLeft).clone();return o.row+=t,o.col+=n,o.row<0||o.col<0?new A_("VALUE"):i>1||r>1?new Uv(o,new $v(o.row+i-1,o.col+r-1)).setSheet(e.sheet,e.hasSheet()):o})),AS("row",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:i instanceof $v||i instanceof Uv||null==(i=this.force(i))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return e?e instanceof $v?e.row+1:this.asMatrix(e).mapRow((function(t){return t+e.topLeft.row+1})):this.formula.row+1})),AS("rows",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:r instanceof $v||r instanceof Uv||(t=this.asMatrix(r))&&(r=t)?(n.push(r),1<e.length?new A_("N/A"):n):new A_("VALUE")}},(function(e){return e instanceof Ov?e.height():e.height})),AS("vlookup",!1,{check:function(e){var t,n,i=[],r=0,o="VALUE",a=e[r++];if(a instanceof A_)return a;if(!(null!=(a=this.force(a))&&r<=e.length))return a instanceof A_?a:new A_(o);i.push(a);var s=e[r++];if(s instanceof A_)return s;if(!(n=this.asMatrix(s))||!(s=n))return s instanceof A_?s:new A_(o);i.push(s);var l=e[r++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!((l|=0)>0||(o="NUM",0)))return l instanceof A_?l:new A_(o);i.push(l);var c=e[r++];return c instanceof A_?c:"boolean"==typeof(c=this.force(c))||"number"==typeof c&&(c=!!c,1)||null==c&&(c=!0,1)?(i.push(c),r<e.length?new A_("N/A"):i):c instanceof A_?c:new A_(o)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){var r=null;return"number"!=typeof e&&(i=!1),"string"==typeof e&&(e=e.toLowerCase()),t.eachRow((function(n){var o=t.get(n,0);if(i){if(o>e)return!0;r=n}else if("string"==typeof o&&(o=o.toLowerCase()),o===e)return r=n,!0})),null==r?new A_("N/A"):t.get(r,n-1)})),AS("date",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0)?s instanceof A_?s:new A_(r):(n.push(s),3<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);return l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n){return ES(e,t-1,n)})),AS("day",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof A_?r:new A_("VALUE"):(n.push(r),1<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return IS(e).date})),AS("month",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof A_?r:new A_("VALUE"):(n.push(r),1<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return IS(e).month+1})),AS("year",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof A_?r:new A_("VALUE"):(n.push(r),1<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return IS(e).year})),AS("weekday",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof A_?r:new A_("VALUE"):(n.push(r),1<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return IS(e).day+1})),AS("weeknum",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:null==(a=this.force(a))&&(a=1,1)||1===a||2===a||11===a||12===a||13===a||14===a||15===a||16===a||17===a||21===a?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){var n,i=ES(IS(e).year,0,1),r=IS(i);return 21==t?((n=3-(r.day+6)%7)<0&&(n+=7),i+=n,r.date+=n,r.day=4,t=1):t=1==t?0:2==t?1:(t-10)%7,(n=r.day-t)<0&&(n+=7),i-=n,Math.ceil((e+1-i)/7)})),AS("isoweeknum",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof A_?r:new A_("VALUE"):(n.push(r),1<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){var t=IS(e),n=t.day||7,i=Math.floor((t.ord-n+10)/7);return i<1?rT(t.year-1):53==i&&i>rT(t.year)?1:i})),AS("now",!1,{check:function(e){return 0<e.length?new A_("N/A"):[]}},(function(){return z_.runtime.dateToSerial(new Date)})),AS("today",!1,{check:function(e){return 0<e.length?new A_("N/A"):[]}},(function(){return 0|z_.runtime.dateToSerial(new Date)})),AS("time",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0)?s instanceof A_?s:new A_(r):(n.push(s),3<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);return l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n){return z_.runtime.packTime(e,t,n,0)})),AS("hour",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return z_.runtime.unpackTime(e).hours})),AS("minute",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return z_.runtime.unpackTime(e).minutes})),AS("second",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return z_.runtime.unpackTime(e).seconds})),AS("edate",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0)?a instanceof A_?a:new A_(r):(n.push(a),2<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){var n=IS(e),i=n.month+t,r=n.year+Math.floor(i/12);return(i%=12)<0&&(i+=12),n=Math.min(n.date,zS(r,i)),ES(r,i,n)})),AS("eomonth",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0)?a instanceof A_?a:new A_(r):(n.push(a),2<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){var n=IS(e),i=n.month+t,r=n.year+Math.floor(i/12);return(i%=12)<0&&(i+=12),n=zS(r,i),ES(r,i,n)})),AS("workday",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);try{var s=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&(n|=0,1)&&e.push(n),e}.bind(this),[]);i=e.length,n.push(s)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e.slice(2)),this.resolveCells(n,t)}},(function(e,t,n){var i=t>0?1:-1;t=Math.abs(t);for(var r=IS(e).day;t>0;)e+=i,(r=(r+i)%7)>0&&r<6&&n.indexOf(e)<0&&--t;return e})),AS("networkdays",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);try{var s=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&(n|=0,1)&&e.push(n),e}.bind(this),[]);i=e.length,n.push(s)}catch(e){if(e instanceof A_)return e;throw e}return i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e.slice(2)),this.resolveCells(n,t)}},(function(e,t,n){if(e>t){var i=e;e=t,t=i}for(var r=0,o=IS(e).day;e<=t;)o>0&&o<6&&n.indexOf(e)<0&&r++,e++,o=(o+1)%7;return r})),AS("days",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0)?a instanceof A_?a:new A_(r):(n.push(a),2<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return e-t})),z_.runtime._days_360=oT,AS("days360",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)||null==s&&(s=!1,1)?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);return l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},oT),AS("yearfrac",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:null==(s=this.force(s))&&(s=0,1)||0===s||1===s||2===s||3===s||4===s?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);return l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n){switch(n){case 0:return oT(e,t,!1)/360;case 1:return(t-e)/PS(IS(e).year);case 2:return(t-e)/360;case 3:return(t-e)/365;case 4:return oT(e,t,!0)/360}})),AS("datevalue",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){var t=z_.runtime.parseDate(e);return t?z_.runtime.dateToSerial(t):new A_("VALUE")})),AS("timevalue",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){var t=e.toLowerCase().match(/(\d+):(\d+)(:(\d+)(\.(\d+))?)?\s*(am?|pm?)?/);if(t){var n=parseFloat(t[1]),i=parseFloat(t[2]),r=t[3]?parseFloat(t[4]):0,o=t[7];return o&&(n>12||n<1)?new A_("VALUE"):(/^p/.test(o)&&(n+=12),z_.runtime.packTime(n,i,r,0))}return new A_("VALUE")})),AS("mdeterm",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:!(t=this.asMatrix(o))||!(o=t)||o.width!=o.height&&(r="N/A",1)?o instanceof A_?o:new A_(r):(n.push(o),1<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return e.each((function(e){if("number"!=typeof e)return new A_("VALUE")}),!0)||e.determinant()})),AS("transpose",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:(t=this.asMatrix(r))&&(r=t)?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return e.transpose()})),AS("mmult",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:!(t=this.asMatrix(a))||!(a=t)||a.height!=o.width&&(r="N/A",1)?a instanceof A_?a:new A_(r):(n.push(a),2<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){return e.multiply(t)})),AS("munit",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))&&((o|=0)>=0||(r="NUM",0))?(n.push(o),1<e.length?new A_("N/A"):n):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return new R_(this).unit(e)})),AS("minverse",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:!(t=this.asMatrix(o))||!(o=t)||o.width!=o.height&&(r="N/A",1)?o instanceof A_?o:new A_(r):(n.push(o),1<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return e.each((function(e){if("number"!=typeof e)return new A_("VALUE")}),!0)||e.inverse()||new A_("VALUE")})),AS("rand",!1,{check:function(e){return 0<e.length?new A_("N/A"):[]}},(function(){return Math.random()})),AS("randbetween",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a|=0,1)&&(a>=o||(r="N/A",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){return e+Math.floor((t-e+1)*Math.random())})),AS("true",!1,{check:function(e){return 0<e.length?new A_("N/A"):[]}},(function(){return!0})),AS("false",!1,{check:function(e){return 0<e.length?new A_("N/A"):[]}},(function(){return!0})),AS("roman",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:!("number"==typeof(r=this.force(r))||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1)))||(r|=0,0)?r instanceof A_?r:new A_("VALUE"):(n.push(r),1<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return function(e){let t={1:"i",10:"x",100:"c",2:"ii",20:"xx",200:"cc",3:"iii",30:"xxx",300:"ccc",4:"iv",40:"xl",400:"cd",5:"v",50:"l",500:"d",6:"vi",60:"lx",600:"dc",7:"vii",70:"lxx",700:"dcc",8:"viii",80:"lxxx",800:"dccc",9:"ix",90:"xc",900:"cm",1e3:"m"},n=[1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],i="";for(;e>0;)e<n[0]?n.shift():(i+=t[n[0]],e-=n[0]);return i}(e).toUpperCase()})),AS("arabic",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){var t=function(e){e=e.toLowerCase();let t={i:1,v:5,x:10,l:50,c:100,d:500,m:1e3},n=0,i=0;for(let r=0;r<e.length;++r){let o=t[e.charAt(r)];if(!o)return null;n+=o,o>i&&(n-=2*i),i=o}return n}(e);return null==t?new A_("VALUE"):t})),AS("base",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!(("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a|=0,1)&&(a>=2&&a<=36||(r="NUM",0))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&((s|=0)>=0||(r="NUM",0))||null==s&&(s=0,1)?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);return l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n){for(var i=e.toString(t).toUpperCase();i.length<n;)i="0"+i;return i})),AS("decimal",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a|=0,1)&&(a>=2&&a<=36||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){e=e.toUpperCase();for(var n=0,i=0;i<e.length;++i){var r=e.charCodeAt(i);if(r>=48&&r<=57)r-=48;else{if(!(r>=65&&r<55+t))return new A_("VALUE");r-=55}n=n*t+r}return n})),AS("char",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))&&((o|=0)>=0||(r="NUM",0))?(n.push(o),1<e.length?new A_("N/A"):n):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return String.fromCharCode(e)}));var aT=/[\0-\x1F\x7F-\x9F\xAD\u0378\u0379\u037F-\u0383\u038B\u038D\u03A2\u0528-\u0530\u0557\u0558\u0560\u0588\u058B-\u058E\u0590\u05C8-\u05CF\u05EB-\u05EF\u05F5-\u0605\u061C\u061D\u06DD\u070E\u070F\u074B\u074C\u07B2-\u07BF\u07FB-\u07FF\u082E\u082F\u083F\u085C\u085D\u085F-\u089F\u08A1\u08AD-\u08E3\u08FF\u0978\u0980\u0984\u098D\u098E\u0991\u0992\u09A9\u09B1\u09B3-\u09B5\u09BA\u09BB\u09C5\u09C6\u09C9\u09CA\u09CF-\u09D6\u09D8-\u09DB\u09DE\u09E4\u09E5\u09FC-\u0A00\u0A04\u0A0B-\u0A0E\u0A11\u0A12\u0A29\u0A31\u0A34\u0A37\u0A3A\u0A3B\u0A3D\u0A43-\u0A46\u0A49\u0A4A\u0A4E-\u0A50\u0A52-\u0A58\u0A5D\u0A5F-\u0A65\u0A76-\u0A80\u0A84\u0A8E\u0A92\u0AA9\u0AB1\u0AB4\u0ABA\u0ABB\u0AC6\u0ACA\u0ACE\u0ACF\u0AD1-\u0ADF\u0AE4\u0AE5\u0AF2-\u0B00\u0B04\u0B0D\u0B0E\u0B11\u0B12\u0B29\u0B31\u0B34\u0B3A\u0B3B\u0B45\u0B46\u0B49\u0B4A\u0B4E-\u0B55\u0B58-\u0B5B\u0B5E\u0B64\u0B65\u0B78-\u0B81\u0B84\u0B8B-\u0B8D\u0B91\u0B96-\u0B98\u0B9B\u0B9D\u0BA0-\u0BA2\u0BA5-\u0BA7\u0BAB-\u0BAD\u0BBA-\u0BBD\u0BC3-\u0BC5\u0BC9\u0BCE\u0BCF\u0BD1-\u0BD6\u0BD8-\u0BE5\u0BFB-\u0C00\u0C04\u0C0D\u0C11\u0C29\u0C34\u0C3A-\u0C3C\u0C45\u0C49\u0C4E-\u0C54\u0C57\u0C5A-\u0C5F\u0C64\u0C65\u0C70-\u0C77\u0C80\u0C81\u0C84\u0C8D\u0C91\u0CA9\u0CB4\u0CBA\u0CBB\u0CC5\u0CC9\u0CCE-\u0CD4\u0CD7-\u0CDD\u0CDF\u0CE4\u0CE5\u0CF0\u0CF3-\u0D01\u0D04\u0D0D\u0D11\u0D3B\u0D3C\u0D45\u0D49\u0D4F-\u0D56\u0D58-\u0D5F\u0D64\u0D65\u0D76-\u0D78\u0D80\u0D81\u0D84\u0D97-\u0D99\u0DB2\u0DBC\u0DBE\u0DBF\u0DC7-\u0DC9\u0DCB-\u0DCE\u0DD5\u0DD7\u0DE0-\u0DF1\u0DF5-\u0E00\u0E3B-\u0E3E\u0E5C-\u0E80\u0E83\u0E85\u0E86\u0E89\u0E8B\u0E8C\u0E8E-\u0E93\u0E98\u0EA0\u0EA4\u0EA6\u0EA8\u0EA9\u0EAC\u0EBA\u0EBE\u0EBF\u0EC5\u0EC7\u0ECE\u0ECF\u0EDA\u0EDB\u0EE0-\u0EFF\u0F48\u0F6D-\u0F70\u0F98\u0FBD\u0FCD\u0FDB-\u0FFF\u10C6\u10C8-\u10CC\u10CE\u10CF\u1249\u124E\u124F\u1257\u1259\u125E\u125F\u1289\u128E\u128F\u12B1\u12B6\u12B7\u12BF\u12C1\u12C6\u12C7\u12D7\u1311\u1316\u1317\u135B\u135C\u137D-\u137F\u139A-\u139F\u13F5-\u13FF\u169D-\u169F\u16F1-\u16FF\u170D\u1715-\u171F\u1737-\u173F\u1754-\u175F\u176D\u1771\u1774-\u177F\u17DE\u17DF\u17EA-\u17EF\u17FA-\u17FF\u180F\u181A-\u181F\u1878-\u187F\u18AB-\u18AF\u18F6-\u18FF\u191D-\u191F\u192C-\u192F\u193C-\u193F\u1941-\u1943\u196E\u196F\u1975-\u197F\u19AC-\u19AF\u19CA-\u19CF\u19DB-\u19DD\u1A1C\u1A1D\u1A5F\u1A7D\u1A7E\u1A8A-\u1A8F\u1A9A-\u1A9F\u1AAE-\u1AFF\u1B4C-\u1B4F\u1B7D-\u1B7F\u1BF4-\u1BFB\u1C38-\u1C3A\u1C4A-\u1C4C\u1C80-\u1CBF\u1CC8-\u1CCF\u1CF7-\u1CFF\u1DE7-\u1DFB\u1F16\u1F17\u1F1E\u1F1F\u1F46\u1F47\u1F4E\u1F4F\u1F58\u1F5A\u1F5C\u1F5E\u1F7E\u1F7F\u1FB5\u1FC5\u1FD4\u1FD5\u1FDC\u1FF0\u1FF1\u1FF5\u1FFF\u200B-\u200F\u202A-\u202E\u2060-\u206F\u2072\u2073\u208F\u209D-\u209F\u20BB-\u20CF\u20F1-\u20FF\u218A-\u218F\u23F4-\u23FF\u2427-\u243F\u244B-\u245F\u2700\u2B4D-\u2B4F\u2B5A-\u2BFF\u2C2F\u2C5F\u2CF4-\u2CF8\u2D26\u2D28-\u2D2C\u2D2E\u2D2F\u2D68-\u2D6E\u2D71-\u2D7E\u2D97-\u2D9F\u2DA7\u2DAF\u2DB7\u2DBF\u2DC7\u2DCF\u2DD7\u2DDF\u2E3C-\u2E7F\u2E9A\u2EF4-\u2EFF\u2FD6-\u2FEF\u2FFC-\u2FFF\u3040\u3097\u3098\u3100-\u3104\u312E-\u3130\u318F\u31BB-\u31BF\u31E4-\u31EF\u321F\u32FF\u4DB6-\u4DBF\u9FCD-\u9FFF\uA48D-\uA48F\uA4C7-\uA4CF\uA62C-\uA63F\uA698-\uA69E\uA6F8-\uA6FF\uA78F\uA794-\uA79F\uA7AB-\uA7F7\uA82C-\uA82F\uA83A-\uA83F\uA878-\uA87F\uA8C5-\uA8CD\uA8DA-\uA8DF\uA8FC-\uA8FF\uA954-\uA95E\uA97D-\uA97F\uA9CE\uA9DA-\uA9DD\uA9E0-\uA9FF\uAA37-\uAA3F\uAA4E\uAA4F\uAA5A\uAA5B\uAA7C-\uAA7F\uAAC3-\uAADA\uAAF7-\uAB00\uAB07\uAB08\uAB0F\uAB10\uAB17-\uAB1F\uAB27\uAB2F-\uABBF\uABEE\uABEF\uABFA-\uABFF\uD7A4-\uD7AF\uD7C7-\uD7CA\uD7FC-\uF8FF\uFA6E\uFA6F\uFADA-\uFAFF\uFB07-\uFB12\uFB18-\uFB1C\uFB37\uFB3D\uFB3F\uFB42\uFB45\uFBC2-\uFBD2\uFD40-\uFD4F\uFD90\uFD91\uFDC8-\uFDEF\uFDFE\uFDFF\uFE1A-\uFE1F\uFE27-\uFE2F\uFE53\uFE67\uFE6C-\uFE6F\uFE75\uFEFD-\uFF00\uFFBF-\uFFC1\uFFC8\uFFC9\uFFD0\uFFD1\uFFD8\uFFD9\uFFDD-\uFFDF\uFFE7\uFFEF-\uFFFB\uFFFE\uFFFF]/g;function sT(e,t){this.link=e,this.text=t}AS("clean",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e.replace(aT,"")})),AS("code",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e.charAt(0)})),z_.runtime.defineAlias("unichar","char"),z_.runtime.defineAlias("unicode","code"),AS("concatenate",!1,{check:function(e){var t,n=[],i=[],r=0;if(r>=e.length)return new A_("N/A");i.push(t=[]),n.push(i),i=t;do{var o=e[r++];if(o instanceof A_)return o;if(!("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1)))return o instanceof A_?o:new A_("VALUE");i.push(o)}while(r<e.length);return i=n.pop(),r<e.length?new A_("N/A"):i},resolve:function(e,t){for(var n=[],i=0;i<e.length;)n.push(e[i++]);this.resolveCells(n,t)},arrayArgs:function(e){for(var t=[],n=0,i=0,r=[],o=0;o<e.length;){var a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++}return{args:t,width:n,height:i,arrays:r}}},(function(e){for(var t="",n=0;n<e.length;++n)t+=e[n];return t})),AS("dollar",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a|=0,1)||null==a&&(a=2,1)?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){for(var n="$#,##0DECIMALS;($#,##0DECIMALS)",i="",r=1;t-- >0;)i+="0";for(;++t<0;)r*=10;return""!==i?i="."+i:1!==r&&(e=Math.round(e/r)*r),n=n.replace(/DECIMALS/g,i),Sb.text(e,n)})),AS("exact",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(!("string"==typeof(r=this.force(r))||"boolean"==typeof r||"number"==typeof r?(r+="",1):void 0===r&&(r="",1)))return r instanceof A_?r:new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1))?(t.push(o),2<e.length?new A_("N/A"):t):o instanceof A_?o:new A_(i)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return e===t})),AS("find",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("string"==typeof(a=this.force(a))||"boolean"==typeof a||"number"==typeof a?(a+="",1):void 0===a&&(a="",1)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&((s|=0)>0||(r="NUM",0))||null==s&&(s=1,1)?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);return l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n){var i=t.indexOf(e,n-1);return i<0?new A_("VALUE"):i+1})),AS("fixed",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!(("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&(a|=0,1)||null==a&&(a=2,1)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:"boolean"==typeof(s=this.force(s))||null==s&&(s=!1,1)?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);return l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n){var i=Math.pow(10,t);e=Math.round(e*i)/i;var r=n?"0":"#,##0";if(t>0)for(r+=".";t-- >0;)r+="0";return Sb.text(e,r)})),AS("left",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>=0||(r="NUM",0))||null==a&&(a=1,1)?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return e.substr(0,t)})),AS("right",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>=0||(r="NUM",0))||null==a&&(a=1,1)?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return e.substr(-t)})),AS("len",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e.length})),AS("lower",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e.toLowerCase()})),AS("upper",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e.toUpperCase()})),AS("ltrim",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e.replace(/^\s+/,"")})),AS("rtrim",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e.replace(/\s+$/,"")})),AS("trim",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e.replace(/^\s+|\s+$/,"")})),AS("mid",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&((s|=0)>=0||(r="NUM",0))?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);return l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n){return e.substr(t-1,n)})),AS("proper",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:("string"==typeof(i=this.force(i))||"boolean"==typeof i||"number"==typeof i?(i+="",1):void 0===i&&(i="",1))?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return e.toLowerCase().replace(/\b./g,(function(e){return e.toUpperCase()}))})),AS("replace",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!((s|=0)>=0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:("string"==typeof(l=this.force(l))||"boolean"==typeof l||"number"==typeof l?(l+="",1):void 0===l&&(l="",1))?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var c=this._arrayArg(e[o]);return c?(t.push(c),n=Math.max(n,c.width),i=Math.max(i,c.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n,i){return e.substr(0,--t)+i+e.substr(t+n)})),AS("rept",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>=0||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){for(var n="";t-- >0;)n+=e;return n})),AS("search",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("string"==typeof(a=this.force(a))||"boolean"==typeof a||"number"==typeof a?(a+="",1):void 0===a&&(a="",1)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&((s|=0)>0||(r="NUM",0))||null==s&&(s=1,1)?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);return l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n){var i=t.toLowerCase().indexOf(e.toLowerCase(),n-1);return i<0?new A_("VALUE"):i+1})),AS("substitute",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("string"==typeof(a=this.force(a))||"boolean"==typeof a||"number"==typeof a?(a+="",1):void 0===a&&(a="",1)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("string"==typeof(s=this.force(s))||"boolean"==typeof s||"number"==typeof s?(s+="",1):void 0===s&&(s="",1)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&((l|=0)>0||(r="NUM",0))||null==l?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var l=this._arrayArg(e[o]);l?(t.push(l),n=Math.max(n,l.width),i=Math.max(i,l.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var c=this._arrayArg(e[o]);return c?(t.push(c),n=Math.max(n,c.width),i=Math.max(i,c.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t,n,i){if(t===n)return e;var r=e.split(t);if(null==i)return r.join(n);e="",i--;for(var o=0;o<r.length;++o)e+=r[o],o<r.length-1&&(e+=o===i?n:t);return e})),AS("t",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:null!=(i=this.force(i))&&1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return"string"==typeof e?e:""})),AS("text",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(!(null!=(r=this.force(r))&&n<=e.length))return r instanceof A_?r:new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1))?(t.push(o),n<e.length?new A_("N/A"):t):o instanceof A_?o:new A_(i)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return Sb.text(e,t)})),AS("value",!1,{check:function(e){var t=[],n=0,i=e[n++];return i instanceof A_?i:null!=(i=this.force(i))&&1<=e.length?(t.push(i),1<e.length?new A_("N/A"):t):i instanceof A_?i:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);return a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e){return"number"==typeof e?e:"boolean"==typeof e?+e:(e=(e+"").replace(/[$€,]/g,""),e=parseFloat(e),isNaN(e)?new A_("VALUE"):e)})),sT.prototype.toString=function(){return this.text},AS("hyperlink",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r instanceof A_)return r;if(!("string"==typeof(r=this.force(r))||"boolean"==typeof r||"number"==typeof r?(r+="",1):void 0===r&&(r="",1)))return r instanceof A_?r:new A_(i);t.push(r);var o=e[n++];return o instanceof A_?o:("string"==typeof(o=this.force(o))||"boolean"==typeof o||"number"==typeof o?(o+="",1):void 0===o&&(o="",1))||null==o&&(o=r,1)?(t.push(o),2<e.length?new A_("N/A"):t):o instanceof A_?o:new A_(i)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return new sT(e,t)})),AS("iferror",!1,{check:function(e){var t=[],n=0,i="VALUE",r=e[n++];if(r=this.force(r),!(n<=e.length))return new A_(i);t.push(r);var o=e[n++];return null!=(o=this.force(o))&&n<=e.length?(t.push(o),n<e.length?new A_("N/A"):t):new A_(i)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)},arrayArgs:function(e){var t=[],n=0,i=0,r=[],o=0,a=this._arrayArg(e[o]);a?(t.push(a),n=Math.max(n,a.width),i=Math.max(i,a.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++;var s=this._arrayArg(e[o]);return s?(t.push(s),n=Math.max(n,s.width),i=Math.max(i,s.height),r.push(!0)):(t.push(e[o]),r.push(!1)),o++,{args:t,width:n,height:i,arrays:r}}},(function(e,t){return e instanceof A_?t:e}));var lT=function(){var e=Object.create(null);function t(e,t){if("string"==typeof t){var n=parseFloat(t);isNaN(n)||n!=t||(t=n)}return function(n){var i=t;return"string"==typeof n&&"string"==typeof i&&(n=n.toLowerCase(),i=i.toLowerCase()),e(n,i)}}function n(e){var t,n;return"string"==typeof e&&(e=e.toLowerCase()),/^[0-9.]+%$/.test(e)?(n=e.substr(0,e.length-1),t=parseFloat(n),isNaN(t)||t!=n||(e=t/100)):/^[0-9.]+$/.test(e)&&(t=parseFloat(e),isNaN(t)||t!=e||(e=t)),e}function i(e,t){return n(e)<n(t)}function r(e,t){return n(e)<=n(t)}function o(e,t){return n(e)>n(t)}function a(e,t){return n(e)>=n(t)}function s(e,t){return!l(e,t)}function l(e,t){return t instanceof RegExp?t.test(e):("string"!=typeof e&&"string"!=typeof t||(e=String(e),t=String(t)),n(e)==n(t))}return function(n){if("function"==typeof n)return n;var c;if(c=/^=(.*)$/.exec(n))return t(l,c[1]);if(c=/^<>(.*)$/.exec(n))return t(s,c[1]);if(c=/^<=(.*)$/.exec(n))return t(r,c[1]);if(c=/^<(.*)$/.exec(n))return t(i,c[1]);if(c=/^>=(.*)$/.exec(n))return t(a,c[1]);if(c=/^>(.*)$/.exec(n))return t(o,c[1]);if(/[?*]/.exec(n)){var d=e[n];return d||(d=n.replace(/(~\?|~\*|[\]({\+\.\|\^\$\\})\[]|[?*])/g,(function(e){switch(e){case"~?":return"\\?";case"~*":return"\\*";case"?":return".";case"*":return".*";default:return"\\"+e}})),d=e[n]=new RegExp("^"+d+"$","i")),t(l,d)}return t(l,n)}}();function cT(e){return"number"==typeof e||"boolean"==typeof e||null==e||""===e}function dT(e,t){return e===t?0:e<t?-1:1}function uT(e,t){return e===t?0:e<t?1:-1}AS("ERF",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){return null==t?gT(e):gT(t)-gT(e)})),AS("ERFC",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},vT),AS("GAMMALN",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))&&(o>0||(r="NUM",0))?(n.push(o),1<e.length?new A_("N/A"):n):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},_T),AS("GAMMA",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},bT),AS("GAMMA.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},xT),AS("GAMMA.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0&&o<=1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&(s>0||(r="NUM",0))?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},CT),AS("NORM.S.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:"boolean"==typeof(a=this.force(a))||"number"==typeof a&&(a=!!a,1)?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},ST),AS("NORM.S.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))&&(o>=0&&o<=1||(r="NUM",0))?(n.push(o),1<e.length?new A_("N/A"):n):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},TT),AS("NORM.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){if(!i)return Math.exp(-(e-t)*(e-t)/(2*n*n))/(n*Math.sqrt(2*Math.PI));return ST((e-t)/n,!0)})),AS("NORM.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0&&o<=1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&(s>0||(r="NUM",0))?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},DT),AS("BETADIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:"number"==typeof(c=this.force(c))&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1))||null==c&&(c=1,1)?(n.push(c),(o>=l||(r="NUM",0))&&(o<=c||(r="NUM",0))&&(l<c||(r="NUM",0))?5<e.length?new A_("N/A"):n:new A_(r)):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){return AT((e-i)/(r-i),t,n)})),AS("BETA.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];if(c instanceof A_)return c;if(!("number"==typeof(c=this.force(c))&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1))||null==c&&(c=0,1)))return c instanceof A_?c:new A_(r);n.push(c);var d=e[i++];return d instanceof A_?d:"number"==typeof(d=this.force(d))&&(d=MS(d),1)||"boolean"==typeof d&&(d=+d,1)||"string"==typeof d&&!/^(?:=|true|false)/i.test(d)&&(t=z_.parse(0,0,0,d),/^date|number|percent$/.test(t.type)&&(d=+t.value,1))||null==d&&(d=1,1)?(n.push(d),(o>=c||(r="NUM",0))&&(o<=d||(r="NUM",0))&&(c<d||(r="NUM",0))?6<e.length?new A_("N/A"):n:new A_(r)):d instanceof A_?d:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r,o){if(i)return AT((e-r)/(o-r),t,n);return function(e,t,n){return Math.exp((t-1)*Math.log(e)+(n-1)*Math.log(1-e)-yT(t,n))}((e-r)/(o-r),t,n)/(o-r)})),AS("BETA.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0&&o<=1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:"number"==typeof(c=this.force(c))&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1))||null==c&&(c=1,1)?(n.push(c),5<e.length?new A_("N/A"):n):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},IT),AS("CHISQ.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},zT),AS("CHISQ.DIST.RT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>0||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},PT),AS("CHISQ.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0&&o<=1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>0||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},HT),AS("CHISQ.INV.RT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0&&o<=1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>0||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){return HT(1-e,t)})),AS("CHISQ.TEST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:(t=this.asMatrix(a))&&(a=t)?(n.push(a),o.width!=a.width&&(r="N/A",1)||o.height!=a.height&&(r="N/A",1)?new A_(r):2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){return function(e,t){var n,i,r=e.length,o=e[0].length,a=0;for(n=0;n<r;n++)for(i=0;i<o;i++){var s=t[n][i],l=e[n][i]-s;a+=(l*=l)/s}return PT(a,(r-1)*(o-1))}(e.data,t.data)})),AS("EXPON.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){if(n)return 1-Math.exp(-t*e);return t*Math.exp(-t*e)})),AS("POISSON.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!((o|=0)>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>=0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){if(n)return 1-zT(2*t,2*(e+1),!0);for(var i=0,r=2;r<=e;r++)i+=Math.log(r);return Math.exp(e*Math.log(t)-t-i)})),AS("F.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!((s|=0)>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},FT),AS("F.DIST.RT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&((s|=0)>0||(r="NUM",0))?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){return 1-FT(e,t,n,!0)})),AS("F.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0&&o<=1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&((s|=0)>0||(r="NUM",0))?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){return n/t*(1/IT(1-e,n/2,t/2,0,1)-1)})),AS("F.INV.RT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0&&o<=1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&((s|=0)>0||(r="NUM",0))?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){return n/t*(1/IT(e,n/2,t/2,0,1)-1)})),AS("F.TEST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}return(o.length>=2||(r="DIV/0",0))&&(a.length>=2||(r="DIV/0",0))?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e,t){var n=e.length-1,i=t.length-1,r=LT(e,RT(e)),o=LT(t,RT(t));if(!r||!o)throw new A_("DIV/0");return 2*FT(r/o,n,i,!0)})),AS("FISHER",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];return o instanceof A_?o:("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))&&(o>-1&&o<1||(r="NUM",0))?(n.push(o),1<e.length?new A_("N/A"):n):o instanceof A_?o:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return.5*Math.log((1+e)/(1-e))})),AS("FISHERINV",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){var t=Math.exp(2*e);return(t-1)/(t+1)})),AS("T.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!((a|=0)>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:"boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},BT),AS("T.DIST.RT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>0||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},OT),AS("T.DIST.2T",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>0||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},VT),AS("T.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0&&o<=1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>0||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},NT),AS("T.INV.2T",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0&&o<=1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>0||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){return NT(1-e/2,t)})),AS("T.TEST",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0)||1!==s&&2!==s)return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:!("number"==typeof(l=this.force(l))||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||(l|=0,0)||1!==l&&2!==l&&3!==l?l instanceof A_?l:new A_(r):(n.push(l),1==l&&o.length!=a.length&&(r="N/A",1)?new A_(r):(o.length>=2||(r="DIV/0",0))&&(a.length>=2||(r="DIV/0",0))?i<e.length?new A_("N/A"):n:new A_(r))},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e.slice(i)),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){var r,o,a=e.length,s=t.length;if(1==i){for(var l=0,c=0,d=0;d<a;d++){var u=e[d]-t[d];l+=u,c+=u*u}var h=l/a;return r=h/Math.sqrt((c-l*h)/(a*(a-1))),1==n?OT(r,a-1):VT(r,a-1)}var p=RT(e),f=RT(t),m=LT(e,p),g=LT(t,f);if(3==i){var v=m/a,_=g/s,b=v+_,y=v/b,w=_/b;return o=1/(y*y/(a-1)+w*w/(s-1)),r=mT(p-f)/Math.sqrt(b),1==n?OT(r,o):VT(r,o)}return o=a+s-2,r=mT(p-f)*Math.sqrt(o*a*s/((a+s)*((a-1)*m+(s-1)*g))),1==n?OT(r,o):VT(r,o)})),AS("CONFIDENCE.T",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0&&o<1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!((s|=0)>0||(r="NUM",0))||1==s&&(r="DIV/0",1)?s instanceof A_?s:new A_(r):(n.push(s),3<e.length?new A_("N/A"):n)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){return-NT(e/2,n-1)*t/Math.sqrt(n)})),AS("CONFIDENCE.NORM",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0&&o<1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&((s|=0)>0||(r="NUM",0))?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){return-TT(e/2)*t/Math.sqrt(n)})),AS("GAUSS",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return ST(e,!0)-.5})),AS("PHI",!1,{check:function(e){var t,n=[],i=0,r=e[i++];return r instanceof A_?r:"number"==typeof(r=this.force(r))&&(r=MS(r),1)||"boolean"==typeof r&&(r=+r,1)||"string"==typeof r&&!/^(?:=|true|false)/i.test(r)&&(t=z_.parse(0,0,0,r),/^date|number|percent$/.test(t.type)&&(r=+t.value,1))?(n.push(r),1<e.length?new A_("N/A"):n):r instanceof A_?r:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),this.resolveCells(n,t)}},(function(e){return ST(e)})),AS("LOGNORM.DIST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){if(i)return.5+.5*gT((Math.log(e)-t)/(n*Math.sqrt(2)));var r=Math.log(e)-t;return Math.exp(-r*r/(2*n*n))/(e*n*Math.sqrt(2*Math.PI))})),AS("LOGNORM.INV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0&&o<1||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&(s>0||(r="NUM",0))?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){return Math.exp(DT(e,t,n))})),AS("PROB",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=s,1)?(n.push(l),a.length!=o.length&&(r="N/A",1)?new A_(r):i<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e.slice(i)),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){var r,o=e.length,a=0;for(r=0;r<o;r++){if(t[r]<=0||t[r]>1)throw new A_("NUM");a+=t[r]}if(1!=a)throw new A_("NUM");var s=0;for(r=0;r<o;r++){var l=e[r];l>=n&&l<=i&&(s+=t[r])}return s})),AS("SLOPE",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}return a.length!=o.length&&(r="N/A",1)?new A_(r):a.length>0&&o.length>0||(r="N/A",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e,t){for(var n=RT(t),i=RT(e),r=0,o=0,a=0,s=e.length;a<s;a++){var l=t[a]-n;r+=l*(e[a]-i),o+=l*l}return r/o})),AS("INTERCEPT",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}return a.length!=o.length&&(r="N/A",1)?new A_(r):a.length>0&&o.length>0||(r="N/A",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e,t){for(var n=RT(t),i=RT(e),r=0,o=0,a=0,s=e.length;a<s;a++){var l=t[a]-n;r+=l*(e[a]-i),o+=l*l}return i-r*n/o})),AS("PEARSON",!1,{check:function(e){var t=[],n=0,i="VALUE";try{var r=this.cellValues(e.slice(n,n+1),!0).reduce(function(t,i){if(i instanceof A_)throw i;return n<=e.length&&t.push(i),t}.bind(this),[]);n+=1,t.push(r)}catch(e){if(e instanceof A_)return e;throw e}try{var o=this.cellValues(e.slice(n,n+1),!0).reduce(function(t,i){if(i instanceof A_)throw i;return n<=e.length&&t.push(i),t}.bind(this),[]);n+=1,t.push(o)}catch(e){if(e instanceof A_)return e;throw e}return o.length!=r.length&&(i="N/A",1)?new A_(i):o.length>0&&r.length>0||(i="N/A",0)?n<e.length?new A_("N/A"):t:new A_(i)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),n.push(e.slice(1)),this.resolveCells(n,t)}},$T),AS("RSQ",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}return a.length!=o.length&&(r="N/A",1)?new A_(r):(a.length>0&&o.length>0||(r="N/A",0))&&(1!=a.length&&1!=o.length||(r="N/A",0))?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e,t){var n=$T(e,t);return n*n})),AS("STEYX",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}return a.length!=o.length&&(r="N/A",1)?new A_(r):a.length>=3&&o.length>=3||(r="DIV/0",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e,t){for(var n=t.length,i=RT(t),r=RT(e),o=0,a=0,s=0,l=0;l<n;l++){var c=t[l]-i,d=e[l]-r;o+=d*d,a+=c*d,s+=c*c}return Math.sqrt((o-a*a/s)/(n-2))})),AS("FORECAST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}try{var s=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(s)}catch(e){if(e instanceof A_)return e;throw e}return s.length!=a.length&&(r="N/A",1)?new A_(r):s.length>0&&a.length>0||(r="N/A",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e,t,n){for(var i=RT(n),r=RT(t),o=0,a=0,s=0,l=n.length;s<l;s++){var c=n[s]-i;o+=c*(t[s]-r),a+=c*c}if(0===a)throw new A_("N/A");var d=o/a;return r-d*i+d*e})),AS("LINEST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!((t=this.asMatrix(a))&&(a=t)||null==a))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)||null==s&&(s=!0,1)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)||null==l&&(l=!1,1)?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},jT),AS("LOGEST",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!((t=this.asMatrix(a))&&(a=t)||null==a))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("boolean"==typeof(s=this.force(s))||"number"==typeof s&&(s=!!s,1)||null==s&&(s=!0,1)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)||null==l&&(l=!1,1)?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){return jT.call(this,e.map(Math.log),t,n,i).map(Math.exp)})),AS("TREND",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!((t=this.asMatrix(a))&&(a=t)||null==a))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!((t=this.asMatrix(s))&&(s=t)||null==s))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)||null==l&&(l=!0,1)?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},qT),AS("GROWTH",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!(t=this.asMatrix(o))||!(o=t))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!((t=this.asMatrix(a))&&(a=t)||null==a))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!((t=this.asMatrix(s))&&(s=t)||null==s))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"boolean"==typeof(l=this.force(l))||"number"==typeof l&&(l=!!l,1)||null==l&&(l=!0,1)?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){return qT.call(this,e.map(Math.log),t,n,i).map(Math.exp)})),AS("FV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))||null==s&&(s=0,1)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:0===(c=this.force(c))||1===c||null==c&&(c=0,1)?(n.push(c),s||l||(r="N/A",0)?5<e.length?new A_("N/A"):n:new A_(r)):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},KT),AS("PV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))||null==s&&(s=0,1)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:0===(c=this.force(c))||1===c||null==c&&(c=0,1)?(n.push(c),5<e.length?new A_("N/A"):n):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){if(!e)return-i-n*t;var o=Math.pow(1+e,t);return-(i+n*(o-1)/e*(1+e*r))/o})),AS("PMT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:0===(c=this.force(c))||1===c||null==c&&(c=0,1)?(n.push(c),5<e.length?new A_("N/A"):n):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},YT),AS("NPER",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:0===(c=this.force(c))||1===c||null==c&&(c=0,1)?(n.push(c),5<e.length?new A_("N/A"):n):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){if(!e)return-(i+n)/t;var o=t*(1+e*r);return Math.log((o-i*e)/(o+n*e))/Math.log(1+e)})),AS("RATE",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))||null==a&&(a=0,1)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))||null==l&&(l=0,1)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];if(c instanceof A_)return c;if(!(0===(c=this.force(c))||1===c||null==c&&(c=0,1)))return c instanceof A_?c:new A_(r);n.push(c);var d=e[i++];return d instanceof A_?d:("number"==typeof(d=this.force(d))&&(d=MS(d),1)||"boolean"==typeof d&&(d=+d,1)||"string"==typeof d&&!/^(?:=|true|false)/i.test(d)&&(t=z_.parse(0,0,0,d),/^date|number|percent$/.test(t.type)&&(d=+t.value,1)))&&(d>0||(r="NUM",0))||null==d&&(d=.01,1)?(n.push(d),a||l||(r="N/A",0)?6<e.length?new A_("N/A"):n:new A_(r)):d instanceof A_?d:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r,o){return GT((function(o){var a=Math.pow(1+o,e-1),s=a*(1+o);return[n*s+t*(1/o+r)*(s-1)+i,e*n*a+t*(-(s-1)/(o*o)+(1/o+r)*e*a)]}),o)})),AS("IPMT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];if(c instanceof A_)return c;if(!("number"==typeof(c=this.force(c))&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1))||null==c&&(c=0,1)))return c instanceof A_?c:new A_(r);n.push(c);var d=e[i++];return d instanceof A_?d:0===(d=this.force(d))||1===d||null==d&&(d=0,1)?(n.push(d),a>=1&&a<=s||(r="N/A",0)?6<e.length?new A_("N/A"):n:new A_(r)):d instanceof A_?d:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},QT),AS("PPMT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];if(c instanceof A_)return c;if(!("number"==typeof(c=this.force(c))&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1))||null==c&&(c=0,1)))return c instanceof A_?c:new A_(r);n.push(c);var d=e[i++];return d instanceof A_?d:0===(d=this.force(d))||1===d||null==d&&(d=0,1)?(n.push(d),a>=1&&a<=s||(r="N/A",0)?6<e.length?new A_("N/A"):n:new A_(r)):d instanceof A_?d:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r,o){return YT(e,n,i,r,o)-QT(e,t,n,i,r,o)})),AS("CUMPRINC",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];if(c instanceof A_)return c;if(!("number"==typeof(c=this.force(c))&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))||!(c>0||(r="NUM",0)))return c instanceof A_?c:new A_(r);n.push(c);var d=e[i++];return d instanceof A_?d:0===(d=this.force(d))||1===d||null==d&&(d=0,1)?(n.push(d),c>=l||(r="NUM",0)?6<e.length?new A_("N/A"):n:new A_(r)):d instanceof A_?d:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r,o){1==o&&(i--,r--);var a=Math.pow(1+e,t),s=Math.pow(1+e,i-1),l=Math.pow(1+e,r),c=e*n*a/(a-1);return l*n-(l-1)/e*c-(s*n-(s-1)/e*c)})),AS("CUMIPMT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];if(c instanceof A_)return c;if(!("number"==typeof(c=this.force(c))&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))||!(c>0||(r="NUM",0)))return c instanceof A_?c:new A_(r);n.push(c);var d=e[i++];return d instanceof A_?d:0===(d=this.force(d))||1===d||null==d&&(d=0,1)?(n.push(d),c>=l||(r="NUM",0)?6<e.length?new A_("N/A"):n:new A_(r)):d instanceof A_?d:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r,o){for(var a=0,s=i;s<=r;s++)a+=QT(e,s,t,n,0,o);return a})),AS("NPV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);try{var a=this.cellValues(e.slice(i)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i=e.length,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}return a.length>0||(r="N/A",0)?i<e.length?new A_("N/A"):n:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e,t){for(var n=0,i=0,r=t.length;i<r;i++)n+=t[i]*Math.pow(1+e,-i-1);return n})),AS("IRR",!1,{check:function(e){var t,n=[],i=0;try{var r=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(r)}catch(e){if(e instanceof A_)return e;throw e}var o=e[i++];return o instanceof A_?o:"number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))||null==o&&(o=.1,1)?(n.push(o),i<e.length?new A_("N/A"):n):o instanceof A_?o:new A_("VALUE")},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){return GT((function(t){for(var n=0,i=0,r=0,o=e.length;r<o;r++)n+=e[r]*Math.pow(1+t,-r-1),i+=-r*e[r]*Math.pow(1+t,-r-2);return[n,i]}),t)})),AS("EFFECT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>0||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){return Math.pow(1+e/t,t)-1})),AS("NOMINAL",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];return a instanceof A_?a:("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))&&((a|=0)>0||(r="NUM",0))?(n.push(a),2<e.length?new A_("N/A"):n):a instanceof A_?a:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t){return t*(Math.pow(e+1,1/t)-1)})),AS("XNPV",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}try{var s=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&(n|=0,1)&&e.push(n),e}.bind(this),[]);i+=1,n.push(s)}catch(e){if(e instanceof A_)return e;throw e}return a.length!=s.length&&(r="NUM",1)?new A_(r):i<e.length?new A_("N/A"):n},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(1)),n.push(e.slice(1)),this.resolveCells(n,t)}},(function(e,t,n){for(var i=0,r=0,o=t.length;r<o;r++)i+=t[r]*Math.pow(1+e,(n[0]-n[r])/365);return i})),AS("XIRR",!1,{check:function(e){var t,n=[],i=0,r="VALUE";try{var o=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n&&(n=MS(n),1)||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&e.push(n),e}.bind(this),[]);i+=1,n.push(o)}catch(e){if(e instanceof A_)return e;throw e}try{var a=this.cellValues(e.slice(i,i+1)).reduce(function(e,n){if(n instanceof A_)throw n;return("number"==typeof n||"boolean"==typeof n&&(n=+n,1)||"string"==typeof n&&!/^(?:=|true|false)/i.test(n)&&(t=z_.parse(0,0,0,n),/^date|number|percent$/.test(t.type)&&(n=+t.value,1)))&&(n|=0,1)&&e.push(n),e}.bind(this),[]);i+=1,n.push(a)}catch(e){if(e instanceof A_)return e;throw e}var s=e[i++];return s instanceof A_?s:"number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1))||null==s&&(s=.1,1)?(n.push(s),o.length!=a.length&&(r="NUM",1)?new A_(r):i<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e.slice(i)),n.push(e.slice(i)),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){return GT((function(n){for(var i=e[0],r=0,o=1,a=e.length;o<a;o++){var s=(t[0]-t[o])/365;i+=e[o]*Math.pow(1+n,s),r+=s*e[o]*Math.pow(1+n,s-1)}return[i,r]}),n)})),AS("ISPMT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:"number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1))?(n.push(l),a>=1&&a<=s||(r="N/A",0)?4<e.length?new A_("N/A"):n:new A_(r)):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){return-i*e*(1-t/n)})),AS("DB",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:"number"==typeof(c=this.force(c))&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1))||null==c&&(c=12,1)?(n.push(c),5<e.length?new A_("N/A"):n):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){var o=1-Math.pow(t/e,1/n);o=Math.floor(1e3*o+.5)/1e3;var a=e*o*r/12;if(1==i)return a;for(var s=1;s<n;s++){if(s==i-1)return(e-a)*o;a+=(e-a)*o}return(e-a)*o*(12-r)/12})),AS("DDB",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:"number"==typeof(c=this.force(c))&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1))||null==c&&(c=2,1)?(n.push(c),5<e.length?new A_("N/A"):n):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){var o=r/n,a=-e*(Math.pow(1-o,i-1)-1),s=(e-a)*o;return s=Math.min(s,Math.max(0,e-a-t))})),AS("SLN",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];return s instanceof A_?s:("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))&&(s>0||(r="NUM",0))?(n.push(s),3<e.length?new A_("N/A"):n):s instanceof A_?s:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){return(e-t)/n})),AS("SYD",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1))))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1))))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&(l>0||(r="NUM",0))?(n.push(l),4<e.length?new A_("N/A"):n):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){return(e-t)*(n-i+1)*2/(n*(n+1))})),AS("VDB",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))&&(o=MS(o),1)||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||!(o>=0||(r="NUM",0)))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))&&(a=MS(a),1)||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||!(a>=0||(r="NUM",0)))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>=0||(r="NUM",0)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];if(c instanceof A_)return c;if(!("number"==typeof(c=this.force(c))&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))||!(c>=0||(r="NUM",0)))return c instanceof A_?c:new A_(r);n.push(c);var d=e[i++];if(d instanceof A_)return d;if(!(("number"==typeof(d=this.force(d))&&(d=MS(d),1)||"boolean"==typeof d&&(d=+d,1)||"string"==typeof d&&!/^(?:=|true|false)/i.test(d)&&(t=z_.parse(0,0,0,d),/^date|number|percent$/.test(t.type)&&(d=+t.value,1)))&&(d>=0||(r="NUM",0))||null==d&&(d=2,1)))return d instanceof A_?d:new A_(r);n.push(d);var u=e[i++];return u instanceof A_?u:"boolean"==typeof(u=this.force(u))||"number"==typeof u&&(u=!!u,1)||null==u&&(u=!1,1)?(n.push(u),c>=l||(r="NUM",0)?7<e.length?new A_("N/A"):n:new A_(r)):u instanceof A_?u:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r,o,a){var s=o>=n?1:o/n;function l(e,n){var i,r,o;return r=1==s?1==n?e:0:e*Math.pow(1-s,n-1),(i=(o=e*Math.pow(1-s,n))<t?r-t:r-o)<0?0:i}function c(e,n,i){for(var r,o=e-t,a=Math.ceil(i),s=0,c=0,d=!1,u=1;u<=a;u++){if(d)r=s;else{var h=l(e,u);(s=o/(n-u+1))>h?(r=s,d=!0):(r=h,o-=h)}u==a&&(r*=i+1-a),c+=r}return c}var d=Math.floor(i),u=Math.ceil(r),h=0;if(a)for(var p=d+1;p<=u;p++){var f=l(e,p);p==d+1?f*=Math.min(r,d+1)-i:p==u&&(f*=r+1-u),h+=f}else{var m=n;if(i!=Math.floor(i)&&o>1&&i>=n/2){var g=i-n/2;i=n/2,r-=g,m+=1}e-=c(e,m,i),h=c(e,n-i,r-i)}return h})),AS("COUPDAYBS",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0)||1!==s&&2!==s&&4!==s)return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:null==(l=this.force(l))&&(l=0,1)||("number"==typeof l||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&(l|=0,1)&&(0===l||1===l||2===l||3===l||4===l)?(n.push(l),o<a||(r="NUM",0)?4<e.length?new A_("N/A"):n:new A_(r)):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){return ZT(JT(e,t,n)[0],e,i)})),AS("COUPDAYS",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0)||1!==s&&2!==s&&4!==s)return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:null==(l=this.force(l))&&(l=0,1)||("number"==typeof l||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&(l|=0,1)&&(0===l||1===l||2===l||3===l||4===l)?(n.push(l),o<a||(r="NUM",0)?4<e.length?new A_("N/A"):n:new A_(r)):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){if(1==i){var r=JT(e,t,n);return ZT(r[0],r[1],1)}if(3==i)return 365/n;return 360/n})),AS("COUPDAYSNC",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0)||1!==s&&2!==s&&4!==s)return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:null==(l=this.force(l))&&(l=0,1)||("number"==typeof l||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&(l|=0,1)&&(0===l||1===l||2===l||3===l||4===l)?(n.push(l),o<a||(r="NUM",0)?4<e.length?new A_("N/A"):n:new A_(r)):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i){var r=JT(e,t,n)[1];return ZT(e,r,i)})),AS("COUPPCD",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0)||1!==s&&2!==s&&4!==s)return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:null==(l=this.force(l))&&(l=0,1)||("number"==typeof l||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&(l|=0,1)&&(0===l||1===l||2===l||3===l||4===l)?(n.push(l),o<a||(r="NUM",0)?4<e.length?new A_("N/A"):n:new A_(r)):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){return JT(e,t,n)[0]})),AS("COUPNCD",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0)||1!==s&&2!==s&&4!==s)return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:null==(l=this.force(l))&&(l=0,1)||("number"==typeof l||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&(l|=0,1)&&(0===l||1===l||2===l||3===l||4===l)?(n.push(l),o<a||(r="NUM",0)?4<e.length?new A_("N/A"):n:new A_(r)):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){return JT(e,t,n)[1]})),AS("COUPNUM",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0)||1!==s&&2!==s&&4!==s)return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];return l instanceof A_?l:null==(l=this.force(l))&&(l=0,1)||("number"==typeof l||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&(l|=0,1)&&(0===l||1===l||2===l||3===l||4===l)?(n.push(l),o<a||(r="NUM",0)?4<e.length?new A_("N/A"):n:new A_(r)):l instanceof A_?l:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n){var i=IS(e),r=IS(t);return 1+((12*(r.year-i.year)+r.month-i.month)*n/12|0)})),AS("ACCRINTM",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!(null==(l=this.force(l))&&(l=1e3,1)||("number"==typeof l&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))&&(l>0||(r="NUM",0))))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:null==(c=this.force(c))&&(c=0,1)||("number"==typeof c||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))&&(c|=0,1)&&(0===c||1===c||2===c||3===c||4===c)?(n.push(c),o<a||(r="NUM",0)?5<e.length?new A_("N/A"):n:new A_(r)):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){var o=eD(IS(t).year,r);return n*i*ZT(e,t,r)/o})),AS("ACCRINT",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||(s|=0,0))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];if(c instanceof A_)return c;if(!(null==(c=this.force(c))&&(c=1e3,1)||("number"==typeof c&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))&&(c>0||(r="NUM",0))))return c instanceof A_?c:new A_(r);n.push(c);var d=e[i++];if(d instanceof A_)return d;if(!("number"==typeof(d=this.force(d))||"boolean"==typeof d&&(d=+d,1)||"string"==typeof d&&!/^(?:=|true|false)/i.test(d)&&(t=z_.parse(0,0,0,d),/^date|number|percent$/.test(t.type)&&(d=+t.value,1)))||(d|=0,0)||1!==d&&2!==d&&4!==d)return d instanceof A_?d:new A_(r);n.push(d);var u=e[i++];if(u instanceof A_)return u;if(!(null==(u=this.force(u))&&(u=0,1)||("number"==typeof u||"boolean"==typeof u&&(u=+u,1)||"string"==typeof u&&!/^(?:=|true|false)/i.test(u)&&(t=z_.parse(0,0,0,u),/^date|number|percent$/.test(t.type)&&(u=+t.value,1)))&&(u|=0,1)&&(0===u||1===u||2===u||3===u||4===u)))return u instanceof A_?u:new A_(r);n.push(u);var h=e[i++];return h instanceof A_?h:"boolean"==typeof(h=this.force(h))||"number"==typeof h&&(h=!!h,1)||null==h&&(h=!0,1)?(n.push(h),o<s||(r="NUM",0)?8<e.length?new A_("N/A"):n:new A_(r)):h instanceof A_?h:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r,o,a,s){var l,c,d,u,h,p,f=0,m=r*i/o,g=a%2==0?360:365;function v(e,t){return(t-e)*o/g|0}return n<=t?(c=(l=JT(n,t,o))[0],d=l[1],c<=e?m*ZT(e,n,a)/ZT(c,d,a):(u=(l=JT(e,c,o))[0],m*((p=v(h=l[1],n))+ZT(e,h,a)/ZT(u,h,a)+(n<d?ZT(c,n,a)/ZT(c,d,a):0)))):(l=function(e,t,n){var i=IS(t),r=IS(e),o=i.year-r.year;o>0&&(o=(o-1)*n);var a,s=e,l=12/n;for(;t>s;)a=s,s=XT(e,++o*l);return[a,s]}(t,n,o),c=l[0],d=l[1],p=v(t,n),f=d==n?m*p:m*(p+ZT(c,n,a)/ZT(c,d,a)),s?(c=(l=JT(e,t,o))[0],d=l[1],f+=m*((p=v(e,t))+ZT(e,d,a)/ZT(c,d,a))):f)})),AS("DISC",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:null==(c=this.force(c))&&(c=0,1)||("number"==typeof c||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))&&(c|=0,1)&&(0===c||1===c||2===c||3===c||4===c)?(n.push(c),o<a||(r="NUM",0)?5<e.length?new A_("N/A"):n:new A_(r)):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){var o=r%2==0?360:HS(IS(e).year)?366:365;return(i-n)/i*o/ZT(e,t,r)})),AS("INTRATE",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:null==(c=this.force(c))&&(c=0,1)||("number"==typeof c||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))&&(c|=0,1)&&(0===c||1===c||2===c||3===c||4===c)?(n.push(c),o<a||(r="NUM",0)?5<e.length?new A_("N/A"):n:new A_(r)):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){var o=r%2==0?360:HS(IS(e).year)?366:365;return(i-n)/n*o/ZT(e,t,r)})),AS("RECEIVED",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:null==(c=this.force(c))&&(c=0,1)||("number"==typeof c||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))&&(c|=0,1)&&(0===c||1===c||2===c||3===c||4===c)?(n.push(c),o<a||(r="NUM",0)?5<e.length?new A_("N/A"):n:new A_(r)):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){var o=r%2==0?360:HS(IS(e).year)?366:365;return n/(1-i*ZT(e,t,r)/o)})),AS("PRICE",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];if(c instanceof A_)return c;if(!("number"==typeof(c=this.force(c))&&(c=MS(c),1)||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))||!(c>0||(r="NUM",0)))return c instanceof A_?c:new A_(r);n.push(c);var d=e[i++];if(d instanceof A_)return d;if(!("number"==typeof(d=this.force(d))||"boolean"==typeof d&&(d=+d,1)||"string"==typeof d&&!/^(?:=|true|false)/i.test(d)&&(t=z_.parse(0,0,0,d),/^date|number|percent$/.test(t.type)&&(d=+t.value,1)))||(d|=0,0)||1!==d&&2!==d&&4!==d)return d instanceof A_?d:new A_(r);n.push(d);var u=e[i++];return u instanceof A_?u:null==(u=this.force(u))&&(u=0,1)||("number"==typeof u||"boolean"==typeof u&&(u=+u,1)||"string"==typeof u&&!/^(?:=|true|false)/i.test(u)&&(t=z_.parse(0,0,0,u),/^date|number|percent$/.test(t.type)&&(u=+t.value,1)))&&(u|=0,1)&&(0===u||1===u||2===u||3===u||4===u)?(n.push(u),o<a||(r="NUM",0)?7<e.length?new A_("N/A"):n:new A_(r)):u instanceof A_?u:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r,o,a){var s=1+((t-e)*o/(a%2==0?360:365)|0),l=JT(e,t,o),c=l[0],d=l[1],u=ZT(c,e,a),h=ZT(e,d,a),p=ZT(c,d,a),f=100*n/o,m=i/o,g=h/p;if(1==s)return(r+f)/(1+g*m)-u/p*f;return r/Math.pow(1+m,s-1+g)+f*Math.pow(1+m,1-s-g)*(Math.pow(1+m,s)-1)/m-u/p*f})),AS("PRICEDISC",!1,{check:function(e){var t,n=[],i=0,r="VALUE",o=e[i++];if(o instanceof A_)return o;if(!("number"==typeof(o=this.force(o))||"boolean"==typeof o&&(o=+o,1)||"string"==typeof o&&!/^(?:=|true|false)/i.test(o)&&(t=z_.parse(0,0,0,o),/^date|number|percent$/.test(t.type)&&(o=+t.value,1)))||(o|=0,0))return o instanceof A_?o:new A_(r);n.push(o);var a=e[i++];if(a instanceof A_)return a;if(!("number"==typeof(a=this.force(a))||"boolean"==typeof a&&(a=+a,1)||"string"==typeof a&&!/^(?:=|true|false)/i.test(a)&&(t=z_.parse(0,0,0,a),/^date|number|percent$/.test(t.type)&&(a=+t.value,1)))||(a|=0,0))return a instanceof A_?a:new A_(r);n.push(a);var s=e[i++];if(s instanceof A_)return s;if(!("number"==typeof(s=this.force(s))&&(s=MS(s),1)||"boolean"==typeof s&&(s=+s,1)||"string"==typeof s&&!/^(?:=|true|false)/i.test(s)&&(t=z_.parse(0,0,0,s),/^date|number|percent$/.test(t.type)&&(s=+t.value,1)))||!(s>0||(r="NUM",0)))return s instanceof A_?s:new A_(r);n.push(s);var l=e[i++];if(l instanceof A_)return l;if(!("number"==typeof(l=this.force(l))&&(l=MS(l),1)||"boolean"==typeof l&&(l=+l,1)||"string"==typeof l&&!/^(?:=|true|false)/i.test(l)&&(t=z_.parse(0,0,0,l),/^date|number|percent$/.test(t.type)&&(l=+t.value,1)))||!(l>0||(r="NUM",0)))return l instanceof A_?l:new A_(r);n.push(l);var c=e[i++];return c instanceof A_?c:null==(c=this.force(c))&&(c=0,1)||("number"==typeof c||"boolean"==typeof c&&(c=+c,1)||"string"==typeof c&&!/^(?:=|true|false)/i.test(c)&&(t=z_.parse(0,0,0,c),/^date|number|percent$/.test(t.type)&&(c=+t.value,1)))&&(c|=0,1)&&(0===c||1===c||2===c||3===c||4===c)?(n.push(c),o<a||(r="NUM",0)?5<e.length?new A_("N/A"):n:new A_(r)):c instanceof A_?c:new A_(r)},resolve:function(e,t){var n=[],i=0;n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),n.push(e[i++]),this.resolveCells(n,t)}},(function(e,t,n,i,r){var o=ZT(e,t,r),a=eD(IS(t).year,r);return i-n*i*o/a}));var hT=300,pT=22204e-20,fT=1e-30,mT=Math.abs;function gT(e){if(mT(e)>=3.3)return 1-vT(e);var t=e>0?1:-1;-1==t&&(e=-e);for(var n=0,i=1,r=1;r<100;r++)n+=i,i*=2*e*e/(2*r+1);return 2*t/Math.sqrt(Math.PI)*e*Math.exp(-e*e)*n}function vT(e){if(mT(e)<3.3)return 1-gT(e);var t=1;e<0&&(t=-1,e=-e);for(var n=e,i=8;i>=1;i-=.5)n=e+i/n;return n=1/(e+n),1==t?Math.exp(-e*e)/Math.sqrt(Math.PI)*n:2-Math.exp(-e*e)/Math.sqrt(Math.PI)*n}function _T(e){var t=[1.000000000190015,76.18009172947146,-86.50532032941678,24.01409824083091,-1.231739572450155,.001208650973866179,-5395239384953e-18],n=e,i=e+5.5,r=t[0];i-=(e+.5)*Math.log(i);for(var o=1;o<=6;o++)r+=t[o]/(n+=1);return-i+Math.log(Math.sqrt(2*Math.PI)*r/e)}function bT(e){if(e>0)return Math.exp(_T(e));var t=Math.PI,n=-e;return-t/(n*bT(n)*Math.sin(t*n))}function yT(e,t){return _T(e)+_T(t)-_T(e+t)}function wT(e,t){return Math.exp(yT(e,t))}function kT(e,t){return t<e+1?function(e,t){var n,i=1/e,r=i,o=e,a=_T(e);for(n=1;n<=hT&&(i+=r*=t/++o,!(mT(r)<mT(i)*pT));n++);return i*Math.exp(-t+e*Math.log(t)-a)}(e,t):1-function(e,t){for(var n=fT,i=n,r=0,o=1,a=t+1-e,s=_T(e),l=1;l<=hT;l++){mT(r=a+o*r)<fT&&(r=fT),mT(i=a+o/i)<fT&&(i=fT);var c=i*(r=1/r);if(n*=c,mT(c-1)<pT)break;a+=2,o=-l*(l-e)}return n*Math.exp(-t-s+e*Math.log(t))}(e,t)}function xT(e,t,n,i){return i?kT(t,e/n):Math.pow(e/n,t-1)*Math.exp(-e/n)/(n*bT(t))}function CT(e,t,n){if(0===e)return 0;if(1==e)return 1/0;var i=0,r=10,o=0,a=t*n;a>1&&(r*=a);for(var s=0;s<hT;s++){var l=xT(o=.5*(i+r),t,n,!0);if(mT(e-l)<1e-16)break;l>e?r=o:i=o}return o}function ST(e,t){return t?.5+.5*gT(e/Math.sqrt(2)):Math.exp(-e*e/2)/Math.sqrt(2*Math.PI)}function TT(e){var t,n,i=[-39.69683028665376,220.9460984245205,-275.9285104469687,138.357751867269,-30.66479806614716,2.506628277459239],r=[-54.47609879822406,161.5858368580409,-155.6989798598866,66.80131188771972,-13.28068155288572],o=[-.007784894002430293,-.3223964580411365,-2.400758277161838,-2.549732539343734,4.374664141464968,2.938163982698783],a=[.007784695709041462,.3224671290700398,2.445134137142996,3.754408661907416],s=.02425;return e<s?(t=Math.sqrt(-2*Math.log(e)),(((((o[0]*t+o[1])*t+o[2])*t+o[3])*t+o[4])*t+o[5])/((((a[0]*t+a[1])*t+a[2])*t+a[3])*t+1)):.97575<e?(t=Math.sqrt(-2*Math.log(1-e)),-(((((o[0]*t+o[1])*t+o[2])*t+o[3])*t+o[4])*t+o[5])/((((a[0]*t+a[1])*t+a[2])*t+a[3])*t+1)):(((((i[0]*(n=(t=e-.5)*t)+i[1])*n+i[2])*n+i[3])*n+i[4])*n+i[5])*t/(((((r[0]*n+r[1])*n+r[2])*n+r[3])*n+r[4])*n+1)}function DT(e,t,n){return t+n*TT(e)}function AT(e,t,n){var i=Math.exp(t*Math.log(e)+n*Math.log(1-e)-yT(t,n));return e<(t+1)/(t+n+2)?i*MT(t,n,e)/t:1-i*MT(n,t,1-e)/n}function MT(e,t,n){var i,r,o,a,s,l,c,d,u,h;for(u=e-1,a=1,mT(s=1-(d=e+t)*n/(h=e+1))<fT&&(s=fT),c=s=1/s,i=1;i<=hT&&(mT(s=1+(o=i*(t-i)*n/((u+(r=2*i))*(e+r)))*s)<fT&&(s=fT),mT(a=1+o/a)<fT&&(a=fT),c*=(s=1/s)*a,mT(s=1+(o=-(e+i)*(d+i)*n/((e+r)*(h+r)))*s)<fT&&(s=fT),mT(a=1+o/a)<fT&&(a=fT),c*=l=(s=1/s)*a,!(mT(l-1)<pT));i++);return c}function ET(e,t,n){for(var i=0,r=1,o=0,a=0;a<hT;a++){var s=AT(o=.5*(i+r),t,n);if(mT(e-s)<pT)break;s>e?r=o:i=o}return o}function IT(e,t,n,i,r){return i+(r-i)*ET(e,t,n)}function zT(e,t,n){return xT(e,t/2,2,n)}function PT(e,t){return 1-zT(e,t,!0)}function HT(e,t){return CT(e,t/2,2)}function FT(e,t,n,i){if(i)return AT(t*e/(n+t*e),t/2,n/2);var r=t/n;return r/wT(t/=2,n/=2)*Math.pow(r*e,t-1)/Math.pow(1+r*e,t+n)}function RT(e){for(var t=0,n=e.length,i=0;i<n;i++)t+=e[i];return t/n}function LT(e,t){for(var n=0,i=e.length,r=0;r<i;r++){var o=e[r]-t;n+=o*o}return n/(i-1)}function BT(e,t,n){return n?1-.5*AT(t/(e*e+t),t/2,.5):1/(Math.sqrt(t)*wT(.5,t/2))*Math.pow(1+e*e/t,-(t+1)/2)}function OT(e,t){return 1-BT(e,t,!0)}function VT(e,t){return e<0&&(e=-e),2*OT(e,t)}function NT(e,t){var n=ET(2*Math.min(e,1-e),t/2,.5);return n=Math.sqrt(t*(1-n)/n),e>.5?n:-n}function $T(e,t){!function(e,t){for(var n=e.length;--n>=0;)"number"==typeof e[n]&&"number"==typeof t[n]||(e.splice(n,1),t.splice(n,1))}(e,t);for(var n=RT(e),i=RT(t),r=0,o=0,a=0,s=0,l=e.length;s<l;s++){var c=e[s]-n,d=t[s]-i;r+=c*d,o+=c*c,a+=d*d}return r/Math.sqrt(o*a)}function UT(e){for(var t=e.height,n=0,i=0;i<t;i++)n+=e.data[i][0];return n/t}function WT(e,t){for(var n=e.height,i=0,r=0;r<n;r++){var o=e.data[r][0]-t;i+=o*o}return i}function jT(e,t,n,i){var r=0;t||(t=e.map((function(){return++r}))),n&&((t=t.clone()).eachRow((function(e){t.data[e].unshift(1)})),++t.width);var o=t.transpose(),a=o.multiply(t).inverse().multiply(o).multiply(e),s=[];for(r=a.height-1;r>=0;r--)s.push(a.data[r][0]);if(n||s.push(0),!i)return this.asMatrix([s]);var l=t.multiply(a),c=e.adds(l,!0),d=WT(l,n?UT(l):0),u=WT(c,n?UT(c):0),h=[];h.push(d,u);var p=d/(d+u),f=e.height-t.width,m=Math.sqrt(u/f),g=[];g.push(p,m);var v=n?d/(t.width-1)/(u/f):p/t.width/((1-p)/f),_=[];_.push(v,f);var b=o.multiply(t).inverse(),y=[];for(r=b.height-1;r>=0;r--)y.push(Math.sqrt(b.data[r][r]*u/f));return this.asMatrix([s,y,g,_,h])}function qT(e,t,n,i){var r=0;t||(t=e.map((function(){return++r}))),i&&((t=t.clone()).eachRow((function(e){t.data[e].unshift(1)})),++t.width);var o=t.transpose(),a=o.multiply(t).inverse().multiply(o).multiply(e);return n?i&&((n=n.clone()).eachRow((function(e){n.data[e].unshift(1)})),++n.width):n=t,n.multiply(a)}function GT(e,t,n,i){for(var r=n||20,o=i||1e-7,a=t,s=1;s<=r;s++){var l=e(a),c=l[0]/l[1];if(a-=c,Math.abs(c)<o)return a}return new A_("NUM")}function KT(e,t,n,i,r){var o=Math.pow(1+e,t);return-(i*o+n*(e?(o-1)/e:t)*(1+e*r))}function YT(e,t,n,i,r){if(!e)return-(i+n)/t;var o=Math.pow(1+e,t);return-e*(i+n*o)/((1+e*r)*(o-1))}function QT(e,t,n,i,r,o){if(1==o&&1==t)return 0;var a=KT(e,t-1,YT(e,n,i,r,o),i,o)*e;return o?a/(1+e):a}function XT(e,t){var n=IS(e),i=n.month+t,r=n.year+Math.floor(i/12);return(i%=12)<0&&(i+=12),n=Math.min(n.date,zS(r,i)),ES(r,i,n)}function ZT(e,t,n){return 1==n||2==n||3==n?t-e:oT(e,t,n)}function JT(e,t,n){var i=IS(e),r=IS(t).year-i.year;r>0&&(r=(r-1)*n);var o,a=12/n;do{o=XT(t,-++r*a)}while(e<o);return[o,XT(t,- --r*a)]}function eD(e,t){return 3==t?365:1==t?HS(e)?366:365:360}const{packDate:tD,unpackDate:nD,packTime:iD,unpackTime:rD,serialToDate:oD,dateToSerial:aD,defineAlias:sD}=z_.runtime;var lD=Object.freeze({__proto__:null,ALL_PROPERTIES:By,ALL_REASONS:Yv,AddColumnCommand:Lx,AddCommand:Rx,AddRowCommand:Bx,AdjustDecimalsCommand:fx,AdjustRowHeightCommand:bx,ApplyFilterCommand:Mx,AutoFillCalculator:_w,AutoFillCommand:Sx,Axis:uw,AxisManager:vw,BorderChangeCommand:mx,BringToFrontCommand:tx,CalcError:A_,CellRef:$v,ClearContentCommand:dx,ClearFilterCommand:Ex,Clipboard:Lk,ColumnWidthCommand:rx,Command:Yk,Context:H_,Controller:gy,CopyCommand:kx,CustomFilter:Lw,CutCommand:wx,Deferred:_C,DefineNameCommand:Ux,DeleteColumnCommand:Fx,DeleteCommand:Px,DeleteDrawingCommand:Jk,DeleteNameCommand:Wx,DeleteRowCommand:Hx,Drawing:Yw,DrawingCommand:Xk,DrawingUpdateCommand:Qk,DynamicFilter:Ow,EditCommand:ux,EditValidationCommand:Ox,EventListener:iy,FIRSTREF:jv,Filter:Fw,FilterCommand:Dx,FormulaBar:Mk,FormulaContext:ey,FormulaInput:Tk,FreezePanesCommand:vx,Grid:fw,GridLinesChangeCommand:sx,HideLineCommand:Ix,HyperlinkCommand:ax,InsertCommentCommand:hx,InsertImageCommand:Zk,Matrix:R_,MergeCellCommand:gx,NULLREF:Vv,NameCommand:$x,NameEditor:Ek,NameRef:Nv,OpenCommand:Vx,Pane:kk,PaneAxis:hw,PaneGrid:mw,PasteCommand:_x,PropertyBag:Fy,PropertyChangeCommand:lx,PropertyCleanCommand:cx,Range:Wy,RangeList:My,RangeRef:Uv,RangeTree:Cy,Ref:Ov,ReorderDrawingsCommand:ex,RowHeightCommand:ox,SHEETREF:qv,SaveAsCommand:Nx,SendToBackCommand:nx,Sheet:Kw,SheetDataSourceBinder:Cw,SheetEditor:ow,SheetNavigator:yw,SortCommand:Ax,Sorter:gw,SpreadsheetWidget:class extends rw{constructor(e,t){super(e,__({},Kv,t)),this.events=TS,this.bind(this.events,this.options),E_({locale:this.options.locale,...this.options.intl}),Vw(),this._view=new Hk(this.element,{messages:this.options.messages.view,toolbar:this.options.toolbar,sheetsbar:this.options.sheetsbar,formulaBarInputRef:this.options.formulaBarInputRef,formulaCellInputRef:this.options.formulaCellInputRef,nameBoxRef:this.options.nameBoxRef,createTabStrip:this.options.createTabStrip,createFilterMenu:this.options.createFilterMenu,createContextMenus:this.options.createContextMenus,createSheetBar:this.options.createSheetBar,getIconHTMLString:this.options.getIconHTMLString,openDialogCallback:this.openDialog.bind(this)}),this._workbook=new CS(this.options,this._view),this._controller=new gy(this._view,this._workbook),this._autoRefresh=!0,this._bindWorkbookEvents(),this._bindViewEvents(),this._view.workbook(this._workbook),this._view.enableClipboard(!1),this.refresh(),this._view.enableClipboard(!0),this._resizeHandler=this.resize.bind(this),window.addEventListener("resize",this._resizeHandler),this._keyDownHandler=this._keyDown.bind(this),this.element.addEventListener("keydown",this._keyDownHandler)}get view(){return this._view}get workbook(){return this._workbook}_keyDown(e){let t=e.keyCode,n=e.ctrlKey||e.metaKey;if(this.trigger("keydown",e),t===r_&&e.shiftKey)return this._view.sheetsbar.onAddSelect(),void e.preventDefault();if(e.altKey&&t===n_){let e=this.sheetIndex(this.activeSheet()),t=this.sheetByIndex(e+1)?.name();t&&this._view.sheetsbar.onSheetSelect(t)}else if(e.altKey&&t===t_){let e=this.sheetIndex(this.activeSheet()),t=this.sheetByIndex(e-1)?.name();t&&this._view.sheetsbar.onSheetSelect(t)}else{if(e.altKey&&t===Qv)return this._view.sheetsbar.onSheetRemove(this.activeSheet()._name()),void e.preventDefault();if(e.altKey&&t===u_)return this.options.createSheetEditor?.(),void e.preventDefault();if(n&&t===o_)this._handleTypographicalEmphasis("bold");else if(n&&t===a_)this._handleTypographicalEmphasis("italic");else if(n&&t===s_)this._handleTypographicalEmphasis("underline");else{if(e.altKey&&t===c_)return this._view.tabstrip?.select("home"),void e.preventDefault();if(e.altKey&&t===l_)return this._view.tabstrip?.select("insert"),void e.preventDefault();if(e.altKey&&t===d_)return this._view.tabstrip?.select("data"),void e.preventDefault();t===i_&&(e.preventDefault(),this._view.tabstrip?.focus())}}}_handleTypographicalEmphasis(e){const t=this.activeSheet();t&&this.executeCommand({command:"PropertyChangeCommand",options:{property:e,value:!t.range(t.activeCell())[e]()}})}_resize(){this.refresh({layout:!0})}_workbookChanging(e){this.trigger("changing",e)&&e.preventDefault()}_workbookChange(e){if(this._autoRefresh&&this.refresh(e),e.recalc&&e.ref){let t=e.range||new Wy(e.ref,this.activeSheet());this.trigger("change",{range:t})}}_workbookCut(e){this.trigger("cut",e)}_workbookCopy(e){this.trigger("copy",e)}_workbookPaste(e){this.trigger("paste",e)}activeSheet(e){return this._workbook.activeSheet(e)}moveSheetToIndex(e,t){return this._workbook.moveSheetToIndex(e,t)}insertSheet(e){return this._workbook.insertSheet(e)}sheets(){return this._workbook.sheets()}removeSheet(e){return this._workbook.removeSheet(e)}sheetByName(e){return this._workbook.sheetByName(e)}sheetIndex(e){return this._workbook.sheetIndex(e)}sheetByIndex(e){return this._workbook.sheetByIndex(e)}renameSheet(e,t){return this._workbook.renameSheet(e,t)}executeCommand(e){return this._controller.executeCommand(e)}refresh(e){return e||(e=Yv),e.editorClose||(this._view.sheet(this._workbook.activeSheet()),this._controller.sheet(this._workbook.activeSheet()),this._workbook.refresh(e)),e.editorChange||(this._view.refresh(e),this._controller.refresh(),this._view.render(e),this.trigger("render")),this}openDialog(e,t){return this._view.openDialog(e,t)}autoRefresh(e){return void 0!==e?(this._autoRefresh=e,!0===e&&this.refresh(),this):this._autoRefresh}toJSON(){return this._workbook.toJSON()}fromJSON(e){e.sheets?(this._workbook.destroy(),this._workbook=new CS(__({},this.options,e)),this._bindWorkbookEvents(),this._view.workbook(this._workbook),this._controller.workbook(this._workbook),this.activeSheet(this.activeSheet())):this.refresh()}saveJSON(){return this._workbook.saveJSON()}fromFile(e){return this._workbook.fromFile(e)}saveAsPDF(e){this._workbook.saveAsPDF(__({},this.options.pdf,e,{workbook:this._workbook}))}saveAsExcel(e){return this._workbook.saveAsExcel(e)}draw(e,t){this._workbook.draw(e,t)}_workbookExcelExport(e){this.trigger("excelExport",e)&&e.preventDefault()}_workbookExcelImport(e){this.trigger("excelImport",e)&&e.preventDefault()}_workbookPdfExport(e){this.trigger("pdfExport",e)&&e.preventDefault()}_workbookInsertSheet(e){this.trigger("insertSheet",e)&&e.preventDefault()}_workbookRemoveSheet(e){this.trigger("removeSheet",e)&&e.preventDefault()}_workbookSelectSheet(e){this.trigger("selectSheet",e)&&e.preventDefault()}_workbookRenameSheet(e){this.trigger("renameSheet",e)&&e.preventDefault()}_workbookInsertRow(e){this.trigger("insertRow",e)&&e.preventDefault()}_workbookInsertColumn(e){this.trigger("insertColumn",e)&&e.preventDefault()}_workbookDeleteRow(e){this.trigger("deleteRow",e)&&e.preventDefault()}_workbookDeleteColumn(e){this.trigger("deleteColumn",e)&&e.preventDefault()}_workbookHideRow(e){this.trigger("hideRow",e)&&e.preventDefault()}_workbookHideColumn(e){this.trigger("hideColumn",e)&&e.preventDefault()}_workbookUnhideRow(e){this.trigger("unhideRow",e)&&e.preventDefault()}_workbookUnhideColumn(e){this.trigger("unhideColumn",e)&&e.preventDefault()}_workbookSelect(e){this.trigger("select",e)}_workbookChangeFormat(e){this.trigger("changeFormat",e)}_workbookDataBinding(e){this.trigger("dataBinding",e)&&e.preventDefault()}_workbookDataBound(e){this.trigger("dataBound",e)}_workbookProgress(){}_viewUpdate(e){this.trigger("update",e)}_viewMessage(e){this.trigger("message",e)}_onContextMenu(e){this.trigger("contextmenu",e)}_bindWorkbookEvents(){this._workbook.bind("cut",this._workbookCut.bind(this)),this._workbook.bind("copy",this._workbookCopy.bind(this)),this._workbook.bind("paste",this._workbookPaste.bind(this)),this._workbook.bind("changing",this._workbookChanging.bind(this)),this._workbook.bind("change",this._workbookChange.bind(this)),this._workbook.bind("excelExport",this._workbookExcelExport.bind(this)),this._workbook.bind("excelImport",this._workbookExcelImport.bind(this)),this._workbook.bind("pdfExport",this._workbookPdfExport.bind(this)),this._workbook.bind("insertSheet",this._workbookInsertSheet.bind(this)),this._workbook.bind("removeSheet",this._workbookRemoveSheet.bind(this)),this._workbook.bind("selectSheet",this._workbookSelectSheet.bind(this)),this._workbook.bind("renameSheet",this._workbookRenameSheet.bind(this)),this._workbook.bind("insertRow",this._workbookInsertRow.bind(this)),this._workbook.bind("insertColumn",this._workbookInsertColumn.bind(this)),this._workbook.bind("deleteRow",this._workbookDeleteRow.bind(this)),this._workbook.bind("deleteColumn",this._workbookDeleteColumn.bind(this)),this._workbook.bind("hideRow",this._workbookHideRow.bind(this)),this._workbook.bind("hideColumn",this._workbookHideColumn.bind(this)),this._workbook.bind("unhideRow",this._workbookUnhideRow.bind(this)),this._workbook.bind("unhideColumn",this._workbookUnhideColumn.bind(this)),this._workbook.bind("select",this._workbookSelect.bind(this)),this._workbook.bind("changeFormat",this._workbookChangeFormat.bind(this)),this._workbook.bind("dataBinding",this._workbookDataBinding.bind(this)),this._workbook.bind("dataBound",this._workbookDataBound.bind(this)),this._workbook.bind("progress",this._workbookProgress.bind(this)),this._workbook.bind("contextmenu",this._onContextMenu.bind(this))}_bindViewEvents(){this._view.bind("update",this._viewUpdate.bind(this)),this._view.bind("message",this._viewMessage.bind(this))}destroy(){window.removeEventListener("resize",this._resizeHandler),this.element.removeEventListener("keydown",this._keyDownHandler),this.unbind(),this._workbook.destroy(),this._controller.destroy(),this._view.destroy()}defineName(e,t,n){return this._workbook.defineName(e,t,n)}undefineName(e){return this._workbook.undefineName(e)}nameValue(e){return this._workbook.nameValue(e)}forEachName(e){return this._workbook.forEachName(e)}cellContextMenu(){return this._view.cellContextMenu}rowHeaderContextMenu(){return this._view.rowHeaderContextMenu}colHeaderContextMenu(){return this._view.colHeaderContextMenu}addImage(e){return this._workbook.addImage(e)}cleanupImages(){return this._workbook.cleanupImages()}},TargetValueCommand:ix,TextWrapCommand:px,ToolbarCopyCommand:Cx,ToolbarCutCommand:Tx,ToolbarPasteCommand:yx,TopFilter:Bw,UnHideLineCommand:zx,UnionRef:Wv,ValidationFormulaContext:ty,ValueFilter:Rw,View:Hk,Workbook:CS,calc:z_,dateToNumber:function(e){return null==e?null:z_.runtime.dateToSerial(e)},dateToSerial:aD,defineAlias:sD,defineFunction:function(e,t){return e=e.toLowerCase(),P_[e]=t,{args:function(n,i){var r=O_(0,n);return i&&(r.arrayArgs&&window.console.log(r.arrayArgs.toString()),r.resolve&&window.console.log(r.resolve.toString()),r.check&&window.console.log(r.check.toString())),(P_[e]=U_(t,r.resolve,r.check,r.arrayArgs)).kendoSpreadsheetArgs=n,this},argsAsync:function(n,i){var r=O_(0,n);return i&&(r.arrayArgs&&window.console.log(r.arrayArgs.toString()),r.resolve&&window.console.log(r.resolve.toString()),r.check&&window.console.log(r.check.toString())),(P_[e]=W_(t,r.resolve,r.check,r.arrayArgs)).kendoSpreadsheetArgs=n,this}}},draw:mk,drawCell:wk,formatting:Sb,initDynamicFilter:Vw,intl:E_,numberToDate:kw,packDate:tD,packTime:iD,registerEditor:function(e,t){Gw[e]=t},serialToDate:oD,unpackDate:nD,unpackTime:rD,validation:Ny});function cD(e,t){return t||(t={}),Object.assign?Object.assign(t,e):Object.keys(e).reduce((function(t,n){return t[n]=e[n],t}),t)}!function(e){e.jQuery.extend(e.spreadsheet,lD),e.spreadsheet.commonEngine=lD}(kendo),function(e){var t=e.jQuery,n=e.data.ObservableObject,i=e.spreadsheet.messages.dialogs={apply:"Apply",save:"Save",cancel:"Cancel",remove:"Remove",retry:"Retry",revert:"Revert",okText:"OK",formatCellsDialog:{title:"Format",categories:{number:"Number",currency:"Currency",date:"Date"}},fontFamilyDialog:{title:"Font"},fontSizeDialog:{title:"Font size"},bordersDialog:{title:"Borders"},alignmentDialog:{title:"Alignment",buttons:{justifyLeft:"Align left",justifyCenter:"Center",justifyRight:"Align right",justifyFull:"Justify",alignTop:"Align top",alignMiddle:"Align middle",alignBottom:"Align bottom"}},mergeDialog:{title:"Merge cells",buttons:{mergeCells:"Merge all",mergeHorizontally:"Merge horizontally",mergeVertically:"Merge vertically",unmerge:"Unmerge"}},freezeDialog:{title:"Freeze panes",buttons:{freezePanes:"Freeze panes",freezeRows:"Freeze rows",freezeColumns:"Freeze columns",unfreeze:"Unfreeze panes"}},confirmationDialog:{text:"Are you sure you want to remove this sheet?",title:"Sheet remove"},validationDialog:{title:"Data Validation",hintMessage:"Please enter a valid {0} value {1}.",hintTitle:"Validation {0}",criteria:{any:"Any value",number:"Number",text:"Text",date:"Date",custom:"Custom Formula",list:"List"},comparers:{greaterThan:"greater than",lessThan:"less than",between:"between",notBetween:"not between",equalTo:"equal to",notEqualTo:"not equal to",greaterThanOrEqualTo:"greater than or equal to",lessThanOrEqualTo:"less than or equal to"},comparerMessages:{greaterThan:"greater than {0}",lessThan:"less than {0}",between:"between {0} and {1}",notBetween:"not between {0} and {1}",equalTo:"equal to {0}",notEqualTo:"not equal to {0}",greaterThanOrEqualTo:"greater than or equal to {0}",lessThanOrEqualTo:"less than or equal to {0}",custom:"that satisfies the formula: {0}"},labels:{criteria:"Criteria",comparer:"Comparer",min:"Min",max:"Max",value:"Value",start:"Start",end:"End",onInvalidData:"On invalid data",rejectInput:"Reject input",showWarning:"Show warning",showHint:"Show hint",hintTitle:"Hint title",hintMessage:"Hint message",ignoreBlank:"Ignore blank",showListButton:"Display button to show list",showCalendarButton:"Display button to show calendar"},placeholders:{typeTitle:"Type title",typeMessage:"Type message"}},exportAsDialog:{title:"Export...",defaultFileName:"Workbook",xlsx:{description:"Excel Workbook (.xlsx)"},pdf:{description:"Portable Document Format (.pdf)",area:{workbook:"Entire Workbook",sheet:"Active Sheet",selection:"Selection"},paper:{a2:"A2 (420 mm × 594 mm)",a3:"A3 (297 mm x 420 mm)",a4:"A4 (210 mm x 297 mm)",a5:"A5 (148 mm x 210 mm)",b3:"B3 (353 mm × 500 mm)",b4:"B4 (250 mm x 353 mm)",b5:"B5 (176 mm x 250 mm)",folio:'Folio (8.5" x 13")',legal:'Legal (8.5" x 14")',letter:'Letter (8.5" x 11")',tabloid:'Tabloid (11" x 17")',executive:'Executive (7.25" x 10.5")'},margin:{normal:"Normal",narrow:"Narrow",wide:"Wide"}},labels:{scale:"Scale",fit:"Fit to page",fileName:"File name",saveAsType:"Save as type",exportArea:"Export",paperSize:"Paper size",margins:"Margins",orientation:"Orientation",print:"Print",guidelines:"Guidelines",center:"Center",horizontally:"Horizontally",vertically:"Vertically"}},modifyMergedDialog:{errorMessage:"Cannot change part of a merged cell."},rangeDisabledDialog:{errorMessage:"Destination range contains disabled cells."},intersectsArrayDialog:{errorMessage:"You cannot alter part of an array"},incompatibleRangesDialog:{errorMessage:"Incompatible ranges"},noFillDirectionDialog:{errorMessage:"Cannot determine fill direction"},duplicateSheetNameDialog:{errorMessage:"Duplicate sheet name"},overflowDialog:{errorMessage:"Cannot paste, because the copy area and the paste area are not the same size and shape."},useKeyboardDialog:{title:"Copying and pasting",errorMessage:"These actions cannot be invoked through the menu. Please use the keyboard shortcuts instead:",labels:{forCopy:"for copy",forCut:"for cut",forPaste:"for paste"}},unsupportedSelectionDialog:{errorMessage:"That action cannot be performed on multiple selection."},linkDialog:{title:"Hyperlink",labels:{text:"Text",url:"Address",removeLink:"Remove link"}},sheetRenameDialog:{title:"Rename Sheet",labels:{text:"Rename Sheet",rename:"Rename"}},insertCommentDialog:{title:"Insert comment",labels:{comment:"Comment",removeComment:"Remove comment"}},insertImageDialog:{title:"Insert image",info:"Drag an image here, or click to select",typeError:"Please select a JPEG, PNG or GIF image"}},r={};e.spreadsheet.dialogs={register:function(e,t){r[e]=t},registered:function(e){return!!r[e]},create:function(e,t){var n=r[e];if(n)return new n(t)}};var o=e.spreadsheet.SpreadsheetDialog=e.Observable.extend({init:function(n){e.Observable.fn.init.call(this,n),this.options=H(t.extend(!0,{},this.options,n)),this.bind(this.events,n)},events:["close","activate"],options:{autoFocus:!0},dialog:function(){if(!this._dialog){var n={autoFocus:!1,scrollable:!1,resizable:!1,modal:!0,visible:!1,width:this.options.width||320,title:this.options.title,open:function(){this.center()},close:this._onDialogClose.bind(this),activate:this._onDialogActivate.bind(this),deactivate:this._onDialogDeactivate.bind(this)};this._dialog=t("<div class='k-spreadsheet-window k-action-window k-popup-edit-form' />").addClass(this.options.className||"").append(e.template(this.options.template)({messages:e.spreadsheet.messages.dialogs||i,ns:e.ns,errors:this.options.errors})).kendoWindow(n).data("kendoWindow")}return this._dialog},_onDialogClose:function(){this.trigger("close",{action:this._action})},_onDialogActivate:function(){this.trigger("activate")},_onDialogDeactivate:function(){this.trigger("deactivate"),this.destroy()},destroy:function(){this._dialog&&(this._dialog.destroy(),this._dialog=null)},open:function(){this.dialog().open(),this.dialog().element.find(".k-button-solid-primary").trigger("focus")},apply:function(){this.close()},close:function(){this._action="close",this.dialog().close()}});function a(t,n){return e.spreadsheet.formatting.text(t,n)}var s=e.spreadsheet.FormatCellsViewModel=n.extend({init:function(e){n.fn.init.call(this,e),this.useCategory(this.category)},useCategory:function(e){var t=e&&e.type||"number",n="currency"==t;this.category=e,this.set("showCurrencyFilter",n&&this.currencies.length>1),n?this.currency(this.currencies[0]):this.set("formats",this.allFormats[t+"Formats"]),this.useFirstFormat()},useFirstFormat:function(){this.formats.length&&this.set("format",this.formats[0].value)},currency:function(e){if(void 0!==e){this._currency=e;var t=e.value,n=[{currency:t,decimals:!0},{currency:t,decimals:!0,iso:!0},{currency:t,decimals:!1}];n=n.map((function(e){return{value:e=s.convert.currency(e),name:a(1e3,e)}})),this.set("formats",n),this.useFirstFormat()}return this._currency||this.currencies[0]},categoryFilter:function(e){return void 0!==e&&this.useCategory(e),this.category},preview:function(){var e=this.get("format"),t=this.value||0;return e&&e.length?a(t,e):t}});function l(e,n){for(var i=[],r=[],o=0;o<n.length;o++)-1==t.inArray(n[o][e],r)&&(i.push(n[o]),r.push(n[o][e]));return i}s.convert={currency:function(e){var t,n,i=e.currency,r=i.pattern[1];return e.decimals&&(r=r.replace(/n/g,"n"+i["."]+(t="0",n=i.decimals,new Array(n+1).join(t)))),r=(r=e.iso?'"'+i.abbr+'" '+r.replace(/\s*\$\s*/g,""):r.replace(/\$/g,JSON.stringify(i.symbol))).replace(/n/g,"?")},date:function(e){return/T|Z/.test(e)?"":e.toLowerCase().replace(/tt/g,"AM/PM").replace(/'/g,'"')}};var c=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.formatCellsDialog||i,a={title:r.title,categories:[{type:"number",name:r.categories.number},{type:"currency",name:r.categories.currency},{type:"date",name:r.categories.date}]};o.fn.init.call(this,t.extend(a,n)),this._generateFormats()},options:{className:"k-spreadsheet-format-cells",template:t=>{let n;return n=`<div class='k-edit-form-container'><div class='k-root-tabs' data-${e.htmlEncode(t.ns)}role='tabstrip' data-${e.htmlEncode(t.ns)}text-field='name' data-${e.htmlEncode(t.ns)}bind='source: categories, value: categoryFilter' data-${e.htmlEncode(t.ns)}animation='false'></div>\n    <div class='k-spreadsheet-preview' data-${e.htmlEncode(t.ns)}bind='text: preview'></div><select data-${e.htmlEncode(t.ns)}role='dropdownlist' class='k-format-filter' data-${e.htmlEncode(t.ns)}text-field='description' data-${e.htmlEncode(t.ns)}value-field='value.name' data-${e.htmlEncode(t.ns)}bind='visible: showCurrencyFilter, value: currency, source: currencies'></select><ul data-${e.htmlEncode(t.ns)}role='staticlist' tabindex='0' id='formats-list' aria-label='formats list' class='k-list k-reset' bind:data-${e.htmlEncode(t.ns)}template='formatItemTemplate' data-${e.htmlEncode(t.ns)}value-primitive='true' data-${e.htmlEncode(t.ns)}value-field='value' data-${e.htmlEncode(t.ns)}bind='source: formats, value: format'></ul>\n    <div class='k-actions'><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary' data-${e.htmlEncode(t.ns)}bind='click: apply'><span class='k-button-text'>${e.htmlEncode(t.messages.apply)}</span></button><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base' data-${e.htmlEncode(t.ns)}bind='click: close'><span class='k-button-text'>${e.htmlEncode(t.messages.cancel)}</span></button></div>\n</div>`,n}},_generateFormats:function(){var n=this.options;if(n.currencies||(n.currencies=c.currenciesFrom(e.cultures)),n.numberFormats||(n.numberFormats=[{value:"#.00%",name:"100.00%"},{value:"#%",name:"100%"},{value:"#.00",name:"1024.00"},{value:"#,###.00",name:"1,024.00"}]),!n.dateFormats){var i=e.cultures.current.calendars.standard.patterns;n.dateFormats=l("value",t.map(i,(function(e){if(e=s.convert.date(e))return{value:e,name:a(34567.7678,e)}})))}},open:function(t){var n,i=this.options,r=t.value(),a=i.categories.slice(0);this.viewModel=new s({currencies:i.currencies.slice(0),allFormats:{numberFormats:i.numberFormats.slice(0),dateFormats:i.dateFormats.slice(0)},categories:a,format:t.format(),category:r instanceof Date?a[2]:a[0],apply:this.apply.bind(this),close:this.close.bind(this),value:r,formatItemTemplate:t=>e.htmlEncode(t.name)}),o.fn.open.call(this),n=this.dialog().element,e.bind(n,this.viewModel);var l=n.find("select.k-format-filter").data("kendoDropDownList");i.currencies.length>10&&l.setOptions({filter:"contains"}),n.find(e.roleSelector("staticlist")).parent().addClass("k-list-wrapper"),n.find(".k-tabstrip-item").attr("aria-controls","formats-list")},apply:function(){var e=this.viewModel.format;o.fn.apply.call(this),this.trigger("action",{command:"PropertyChangeCommand",options:{property:"format",value:e}})}});c.currenciesFrom=function(n){return l("description",t.map(n,(function(t,n){if(/-/.test(n)){var i=t.numberFormat.currency;return{description:e.format("{0} ({1}, {2})",i.name,i.abbr,i.symbol),value:i}}})))},e.spreadsheet.dialogs.register("formatCells",c),e.spreadsheet.dialogs.FormatCellsDialog=c;var d=o.extend({options:{className:"k-spreadsheet-message",title:"",messageId:"",text:"",template:t=>{let n;return n=`<div class='k-spreadsheet-message-content' data-${e.htmlEncode(t.ns)}bind='text: text'></div>\n<div class='k-actions'><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary'\n        data-${e.htmlEncode(t.ns)}bind='click: close'><span\n            class='k-button-text'>${t.messages.okText}</span></button></div>`,n}},open:function(){o.fn.open.call(this);var t=this.options,n=t.text;t.messageId&&(n=e.getter(t.messageId,!0)(e.spreadsheet.messages.dialogs)),e.bind(this.dialog().element,{text:n,close:this.close.bind(this)})}});e.spreadsheet.dialogs.register("message",d);var u=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.confirmationDialog||i,a={title:r.title,text:r.text};o.fn.init.call(this,t.extend(a,n))},options:{className:"k-spreadsheet-message",messageId:"",template:t=>{let n;return n=`<div class='k-spreadsheet-message-content' data-${e.htmlEncode(t.ns)}bind='text: text'></div>\n<div class='k-actions'><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary'\n        data-${e.htmlEncode(t.ns)}bind='click: confirm'><span\n            class='k-button-text'>${t.messages.okText}</span></button><button\n        class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base'\n        data-${e.htmlEncode(t.ns)}bind='click: cancel'><span\n            class='k-button-text'>${t.messages.cancel}</span></button></div>`,n}},open:function(){o.fn.open.call(this);var t=this.options,n=t.text;t.messageId&&(n=e.getter(t.messageId,!0)(e.spreadsheet.messages.dialogs)),e.bind(this.dialog().element,{text:n,confirm:this.confirm.bind(this),cancel:this.close.bind(this)})},isConfirmed:function(){return this._confirmed},confirm:function(){this._confirmed=!0,this.close()}});e.spreadsheet.dialogs.register("confirmation",u);var h=o.extend({options:{className:"k-spreadsheet-message",title:"",messageId:"",text:"",template:t=>{let n;return n=`<div class='k-spreadsheet-message-content' data-${e.htmlEncode(t.ns)}bind='text: text'></div><div class='k-actions'><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary' data-${e.htmlEncode(t.ns)}bind='click: retry'><span class='k-button-text'>${t.messages.retry}</span></button><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base' data-${e.htmlEncode(t.ns)}bind='click: cancel'><span class='k-button-text'>${t.messages.cancel}</span></button></div>`,n}},open:function(){o.fn.open.call(this);var t=this.options,n=t.text;t.messageId&&(n=e.getter(t.messageId,!0)(e.spreadsheet.messages.dialogs)),e.bind(this.dialog().element,{text:n,retry:this.retry.bind(this),cancel:this.close.bind(this)})},retry:function(){this._retry=!0,this.close()}});e.spreadsheet.dialogs.register("validationError",h);var p=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.fontFamilyDialog||i;o.fn.init.call(this,t.extend({title:r.title},n)),this._list()},options:{template:()=>"<ul class='k-list k-reset'></ul>"},_list:function(){var t=this.dialog().element.find("ul"),n=this.options.options,i=this.options.default;this.list=new e.ui.StaticList(t,{dataSource:new e.data.DataSource({data:n}),template:t=>e.htmlEncode(t),value:i,change:this.apply.bind(this)}),this.list.dataSource.fetch()},apply:function(e){o.fn.apply.call(this),this.trigger("action",{command:"PropertyChangeCommand",options:{property:"fontFamily",value:e.sender.value()[0]}})}});e.spreadsheet.dialogs.register("fontFamily",p);var f=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.fontSizeDialog||i;o.fn.init.call(this,t.extend({title:r.title},n)),this._list()},options:{template:()=>"<ul class='k-list k-reset'></ul>"},_list:function(){var t=this.dialog().element.find("ul"),n=this.options.options,i=this.options.default;this.list=new e.ui.StaticList(t,{dataSource:new e.data.DataSource({data:n}),template:t=>e.htmlEncode(t),value:i,change:this.apply.bind(this)}),this.list.dataSource.fetch()},apply:function(t){o.fn.apply.call(this),this.trigger("action",{command:"PropertyChangeCommand",options:{property:"fontSize",value:e.parseInt(t.sender.value()[0])}})}});e.spreadsheet.dialogs.register("fontSize",f);var m=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.bordersDialog||i;o.fn.init.call(this,t.extend({title:r.title},n)),this.element=this.dialog().element,this._borderPalette(),this.viewModel=e.observable({apply:this.apply.bind(this),close:this.close.bind(this)}),e.bind(this.element.find(".k-actions"),this.viewModel)},options:{template:t=>{let n;return n=`<div></div>\n<div class='k-actions'><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary'\n        data-${e.htmlEncode(t.ns)}bind='click: apply'><span\n            class='k-button-text'>${e.htmlEncode(t.messages.apply)}</span></button><button\n        class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base'\n        data-${e.htmlEncode(t.ns)}bind='click: close'><span\n            class='k-button-text'>${e.htmlEncode(t.messages.cancel)}</span></button></div>`,n}},apply:function(){o.fn.apply.call(this);var e=this.borderPalette.value();e.color&&e.type&&this.trigger("action",{command:"BorderChangeCommand",options:{border:e.type,style:{size:1,color:e.color}}})},_borderPalette:function(){var t=this.dialog().element.find("div").first();this.borderPalette=new e.spreadsheet.BorderPalette(t,{change:this.value.bind(this)})},value:function(e){if(void 0===e)return this._state;this._state=e}});e.spreadsheet.dialogs.register("borders",m);var g=o.extend({init:function(t){o.fn.init.call(this,t),this.element=this.dialog().element,this.property=t.property,this.options.title=t.title,this.viewModel=e.observable({apply:this.apply.bind(this),close:this.close.bind(this)}),e.bind(this.element.find(".k-actions"),this.viewModel)},options:{template:t=>{let n;return n=`<div></div>\n<div class='k-actions'><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary'\n        data-${e.htmlEncode(t.ns)}bind='click: apply'><span\n            class='k-button-text'>${e.htmlEncode(t.messages.apply)}</span></button><button\n        class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base'\n        data-${e.htmlEncode(t.ns)}bind='click: close'><span\n            class='k-button-text'>${e.htmlEncode(t.messages.cancel)}</span></button></div>`,n}},apply:function(){o.fn.apply.call(this),this.trigger("action",{command:"PropertyChangeCommand",options:{property:this.property,value:this.value()}})},value:function(e){if(void 0===e)return this._value;this._value=e.value}}),v=g.extend({init:function(e){e.width=177,g.fn.init.call(this,e),this._colorPalette()},_colorPalette:function(){var e=this.dialog().element.find("div").first();this.colorPalette=e.kendoColorPalette({palette:["#ffffff","#000000","#d6ecff","#4e5b6f","#7fd13b","#ea157a","#feb80a","#00addc","#738ac8","#1ab39f","#f2f2f2","#7f7f7f","#a7d6ff","#d9dde4","#e5f5d7","#fad0e4","#fef0cd","#c5f2ff","#e2e7f4","#c9f7f1","#d8d8d8","#595959","#60b5ff","#b3bcca","#cbecb0","#f6a1c9","#fee29c","#8be6ff","#c7d0e9","#94efe3","#bfbfbf","#3f3f3f","#007dea","#8d9baf","#b2e389","#f272af","#fed46b","#51d9ff","#aab8de","#5fe7d5","#a5a5a5","#262626","#003e75","#3a4453","#5ea226","#af0f5b","#c58c00","#0081a5","#425ea9","#138677","#7f7f7f","#0c0c0c","#00192e","#272d37","#3f6c19","#750a3d","#835d00","#00566e","#2c3f71","#0c594f"],change:this.value.bind(this)}).data("kendoColorPalette")}});e.spreadsheet.dialogs.register("colorPicker",v);var _=g.extend({init:function(e){e.width=268,g.fn.init.call(this,e),this.dialog().setOptions({animation:!1}),this.dialog().one("activate",this._colorPicker.bind(this))},_colorPicker:function(){var e=this.dialog().element.find("div").first();this.colorPicker=e.kendoFlatColorPicker({change:this.value.bind(this)}).data("kendoFlatColorPicker")}});e.spreadsheet.dialogs.register("customColor",_);var b=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.alignmentDialog||i,a={title:r.title,buttons:[{property:"textAlign",value:"left",iconClass:"align-left",text:r.buttons.justifyLeft},{property:"textAlign",value:"center",iconClass:"align-center",text:r.buttons.justifyCenter},{property:"textAlign",value:"right",iconClass:"align-right",text:r.buttons.justifyRight},{property:"textAlign",value:"justify",iconClass:"align-justify",text:r.buttons.justifyFull},{property:"verticalAlign",value:"top",iconClass:"align-top",text:r.buttons.alignTop},{property:"verticalAlign",value:"center",iconClass:"align-middle",text:r.buttons.alignMiddle},{property:"verticalAlign",value:"bottom",iconClass:"align-bottom",text:r.buttons.alignBottom}]};o.fn.init.call(this,t.extend(a,n)),this._list()},options:{template:()=>"<ul class='k-list k-reset'></ul>"},_list:function(){var t=this.dialog().element.find("ul");this.list=new e.ui.StaticList(t,{dataSource:new e.data.DataSource({data:this.options.buttons}),template:t=>`<a role='button' title='${t.text}' data-property='${t.property}' data-value='${t.value}'>\n                                ${e.ui.icon(t.iconClass)} ${t.text}\n                           </a>`,change:this.apply.bind(this)}),this.list.dataSource.fetch()},apply:function(e){var t=e.sender.value()[0];o.fn.apply.call(this),this.trigger("action",{command:"PropertyChangeCommand",options:{property:t.property,value:t.value}})}});e.spreadsheet.dialogs.register("alignment",b);var y=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.mergeDialog||i,a={title:r.title,buttons:[{value:"cells",iconClass:"cells-merge",text:r.buttons.mergeCells},{value:"horizontally",iconClass:"cells-merge-horizontally",text:r.buttons.mergeHorizontally},{value:"vertically",iconClass:"cells-merge-vertically",text:r.buttons.mergeVertically},{value:"unmerge",iconClass:"table-unmerge",text:r.buttons.unmerge}]};o.fn.init.call(this,t.extend(a,n)),this._list()},options:{template:()=>"<ul class='k-list k-reset'></ul>"},_list:function(){var t=this.dialog().element.find("ul");this.list=new e.ui.StaticList(t,{dataSource:new e.data.DataSource({data:this.options.buttons}),template:t=>`<a role='button' title='${t.text}' data-value='${t.value}'>${e.ui.icon(t.iconClass)}${t.text}</a>`,change:this.apply.bind(this)}),this.list.dataSource.fetch()},apply:function(e){var t=e.sender.value()[0];o.fn.apply.call(this),this.trigger("action",{command:"MergeCellCommand",options:{value:t.value}})}});e.spreadsheet.dialogs.register("merge",y);var w=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.freezeDialog||i,a={title:r.title,buttons:[{value:"panes",iconClass:"pane-freeze",text:r.buttons.freezePanes},{value:"rows",iconClass:"row-freeze",text:r.buttons.freezeRows},{value:"columns",iconClass:"column-freeze",text:r.buttons.freezeColumns},{value:"unfreeze",iconClass:"table-unmerge",text:r.buttons.unfreeze}]};o.fn.init.call(this,t.extend(a,n)),this._list()},options:{template:()=>"<ul class='k-list k-reset'></ul>"},_list:function(){var t=this.dialog().element.find("ul");this.list=new e.ui.StaticList(t,{dataSource:new e.data.DataSource({data:this.options.buttons}),template:t=>`<a role='button' title='${t.text}' data-value='${t.value}'>${e.ui.icon(t.iconClass)}${t.text}</a>`,change:this.apply.bind(this)}),this.list.dataSource.fetch()},apply:function(e){var t=e.sender.value()[0];o.fn.apply.call(this),this.trigger("action",{command:"FreezePanesCommand",options:{value:t.value}})}});e.spreadsheet.dialogs.register("freeze",w);var k=e.spreadsheet.ValidationCellsViewModel=n.extend({init:function(e){n.fn.init.call(this,e),this.bind("change",function(e){"criterion"===e.field&&(this.reset(),"custom"!==this.criterion&&"list"!==this.criterion||this.setHintMessageTemplate()),"comparer"===e.field&&this.setHintMessageTemplate(),"hintMessage"!=e.field&&"hintTitle"!=e.field||this._mute||(this.shouldBuild=!1),"from"!=e.field&&"to"!=e.field&&"hintMessageTemplate"!=e.field&&"type"!=e.field||!this.shouldBuild||this.buildMessages()}.bind(this)),this.reset()},buildMessages:function(){this._mute=!0,this.set("hintTitle",this.hintTitleTemplate?e.format(this.hintTitleTemplate,this.type):""),this.set("hintMessage",this.hintMessageTemplate?e.format(this.hintMessageTemplate,this.from,this.to):""),this._mute=!1},reset:function(){this.setComparers(),this.set("comparer",this.comparers[0].type),this.set("from",null),this.set("to",null),this.set("useCustomMessages",!1),this.shouldBuild=!0,this.hintTitleTemplate=this.defaultHintTitle,this.buildMessages()},setComparers:function(){var e=this.defaultComparers,t=[];if("text"===this.criterion)for(var n=["equalTo","notEqualTo"],i=0;i<e.length;i++)n[0]==e[i].type&&(t.push(e[i]),n.shift());else t=e.slice();this.set("comparers",t)},setHintMessageTemplate:function(){"custom"!==this.criterion&&"list"!==this.criterion?this.set("hintMessageTemplate",e.format(this.defaultHintMessage,this.criterion,this.comparerMessages[this.comparer])):(this.set("hintMessageTemplate",""),this.set("hintMessage",""))},isAny:function(){return"any"===this.get("criterion")},isNumber:function(){return"number"===this.get("criterion")},showToForNumber:function(){return this.showTo()&&this.isNumber()},showToForDate:function(){return this.showTo()&&this.isDate()},isText:function(){return"text"===this.get("criterion")},isDate:function(){return"date"===this.get("criterion")},isList:function(){return"list"===this.get("criterion")},isCustom:function(){return"custom"===this.get("criterion")},showRemove:function(){return this.get("hasValidation")},showTo:function(){return"between"==this.get("comparer")||"notBetween"==this.get("comparer")},update:function(e){this.set("hasValidation",!!e),e&&this.fromValidationObject(e)},fromValidationObject:function(e){this.set("criterion",e.dataType),this.set("comparer",e.comparerType),this.set("from",e.from),this.set("to",e.to),this.set("type",e.type),this.set("ignoreBlank",e.allowNulls),this.set("showButton",e.showButton),e.messageTemplate||e.titleTemplate?(this.hintMessageTemplate=e.messageTemplate,this.hintMessage=e.messageTemplate,this.hintTitleTemplate=e.titleTemplate,this.hintTitle=e.titleTemplate,this.useCustomMessages=!0,this.buildMessages()):this.useCustomMessages=!1},toValidationObject:function(){if("any"===this.criterion)return null;var e={type:this.type,dataType:this.criterion,comparerType:this.comparer,from:this.from,to:this.to,allowNulls:this.ignoreBlank,showButton:this.showButton};return this.useCustomMessages&&(e.messageTemplate=this.shouldBuild?this.hintMessageTemplate:this.hintMessage,e.titleTemplate=this.hintTitle),e}}),x=o.extend({init:function(n){var r=e.spreadsheet.messages.dialogs.validationDialog||i,a={title:r.title,hintMessage:r.hintMessage,hintTitle:r.hintTitle,criteria:[{type:"any",name:r.criteria.any},{type:"number",name:r.criteria.number},{type:"text",name:r.criteria.text},{type:"date",name:r.criteria.date},{type:"custom",name:r.criteria.custom},{type:"list",name:r.criteria.list}],comparers:[{type:"greaterThan",name:r.comparers.greaterThan},{type:"lessThan",name:r.comparers.lessThan},{type:"between",name:r.comparers.between},{type:"notBetween",name:r.comparers.notBetween},{type:"equalTo",name:r.comparers.equalTo},{type:"notEqualTo",name:r.comparers.notEqualTo},{type:"greaterThanOrEqualTo",name:r.comparers.greaterThanOrEqualTo},{type:"lessThanOrEqualTo",name:r.comparers.lessThanOrEqualTo}],comparerMessages:r.comparerMessages};o.fn.init.call(this,t.extend(a,n))},options:{width:450,criterion:"any",type:"reject",ignoreBlank:!0,showButton:!0,useCustomMessages:!1,errorTemplate:t=>`<div class="k-tooltip k-tooltip-error k-validator-tooltip">\n                    ${e.ui.icon({icon:"exclamation-circle",iconClass:"k-tooltip-icon"})}\n                    <span class="k-tooltip-content">${t.message}</span>\n                    <span class="k-callout k-callout-n"></span>\n                </div>`,template:t=>{let n;return n=`<div class="k-edit-form-container">\n                    <div class="k-edit-label"><label for="criteria">${e.htmlEncode(t.messages.validationDialog.labels.criteria)}:</label></div>\n                    <div class="k-edit-field"><select id="criteria" data-${e.htmlEncode(t.ns)}role="dropdownlist" title="${e.htmlEncode(t.messages.validationDialog.labels.criteria)}" data-${e.htmlEncode(t.ns)}text-field="name" data-${e.htmlEncode(t.ns)}value-field="type" data-${e.htmlEncode(t.ns)}bind="value: criterion, source: criteria"></select></div>\n                    <div data-${e.htmlEncode(t.ns)}bind="visible: isNumber">\n                    <div class="k-edit-label"><label for="number-comparer">${e.htmlEncode(t.messages.validationDialog.labels.comparer)}:</label></div>\n                    <div class="k-edit-field"><select id="number-comparer" data-${e.htmlEncode(t.ns)}role="dropdownlist" title="${e.htmlEncode(t.messages.validationDialog.labels.comparer)}" data-${e.htmlEncode(t.ns)}text-field="name" data-${e.htmlEncode(t.ns)}value-field="type" data-${e.htmlEncode(t.ns)}bind="value: comparer, source: comparers"></select></div>\n                    <div class="k-edit-label"><label for="comparer-min">${e.htmlEncode(t.messages.validationDialog.labels.min)}:</label></div>\n                    <div class="k-edit-field"><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input id="comparer-min" name="${e.htmlEncode(t.messages.validationDialog.labels.min)}" title="${e.htmlEncode(t.messages.validationDialog.labels.min)}" placeholder="e.g. 10" class="k-input-inner" data-${e.htmlEncode(t.ns)}bind="value: from, enabled: isNumber" required="required" /></span></div>\n                    <div data-${e.htmlEncode(t.ns)}bind="visible: showTo">\n                    <div class="k-edit-label"><label for="comparer-max">${e.htmlEncode(t.messages.validationDialog.labels.max)}:</label></div>\n                    <div class="k-edit-field"><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input id="comparer-max" name="${e.htmlEncode(t.messages.validationDialog.labels.max)}" title="${e.htmlEncode(t.messages.validationDialog.labels.max)}" placeholder="e.g. 100" class="k-input-inner" data-${e.htmlEncode(t.ns)}bind="value: to, enabled: showToForNumber" required="required" /></span></div>\n                    </div>\n                    </div><div data-${e.htmlEncode(t.ns)}bind="visible: isText">\n                    <div class="k-edit-label"><label for="text-comparer">${e.htmlEncode(t.messages.validationDialog.labels.comparer)}:</label></div>\n                    <div class="k-edit-field"><select id="text-comparer" data-${e.htmlEncode(t.ns)}role="dropdownlist" title="${e.htmlEncode(t.messages.validationDialog.labels.comparer)}" data-${e.htmlEncode(t.ns)}text-field="name" data-${e.htmlEncode(t.ns)}value-field="type" data-${e.htmlEncode(t.ns)}bind="value: comparer, source: comparers"></select></div>\n                    <div class="k-edit-label"><label for="text-comparer-value">${e.htmlEncode(t.messages.validationDialog.labels.value)}:</label></div>\n                    <div class="k-edit-field"><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input id="text-comparer-value" name="${e.htmlEncode(t.messages.validationDialog.labels.value)}" title="${e.htmlEncode(t.messages.validationDialog.labels.value)}" class="k-input-inner" data-${e.htmlEncode(t.ns)}bind="value: from, enabled: isText" required="required" /></span></div>\n                    </div><div data-${e.htmlEncode(t.ns)}bind="visible: isDate">\n                    <div class="k-edit-label"><label for="date-comparer">${e.htmlEncode(t.messages.validationDialog.labels.comparer)}:</label></div>\n                    <div class="k-edit-field"><select id="date-comparer" data-${e.htmlEncode(t.ns)}role="dropdownlist" title="${e.htmlEncode(t.messages.validationDialog.labels.comparer)}" data-${e.htmlEncode(t.ns)}text-field="name" data-${e.htmlEncode(t.ns)}value-field="type" data-${e.htmlEncode(t.ns)}bind="value: comparer, source: comparers"></select></div>\n                    <div class="k-edit-label"><label for="date-comparer-start">${e.htmlEncode(t.messages.validationDialog.labels.start)}:</label></div>\n                    <div class="k-edit-field"><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input id="date-comparer-start" name="${e.htmlEncode(t.messages.validationDialog.labels.start)}" title="${e.htmlEncode(t.messages.validationDialog.labels.start)}" class="k-input-inner" data-${e.htmlEncode(t.ns)}bind="value: from, enabled: isDate" required="required" /></span></div>\n                    <div data-${e.htmlEncode(t.ns)}bind="visible: showTo">\n                    <div class="k-edit-label"><label for="date-comparer-end">${e.htmlEncode(t.messages.validationDialog.labels.end)}:</label></div>\n                    <div class="k-edit-field"><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input id="date-comparer-end" name="${e.htmlEncode(t.messages.validationDialog.labels.end)}" title="${e.htmlEncode(t.messages.validationDialog.labels.end)}" class="k-input-inner" data-${e.htmlEncode(t.ns)}bind="value: to, enabled: showToForDate" required="required" /></span></div>\n                    </div></div><div data-${e.htmlEncode(t.ns)}bind="visible: isCustom">\n                    <div class="k-edit-label"><label for="custom-comparer-value">${e.htmlEncode(t.messages.validationDialog.labels.value)}:</label></div>\n                    <div class="k-edit-field"><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input id="custom-comparer-value" name="${e.htmlEncode(t.messages.validationDialog.labels.value)}" title="${e.htmlEncode(t.messages.validationDialog.labels.value)}" class="k-input-inner" data-${e.htmlEncode(t.ns)}bind="value: from, enabled: isCustom" required="required" /></span></div>\n                    </div><div data-${e.htmlEncode(t.ns)}bind="visible: isList">\n                    <div class="k-edit-label"><label for="list-comparer-value">${e.htmlEncode(t.messages.validationDialog.labels.value)}:</label></div>\n                    <div class="k-edit-field"><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input id="list-comparer-value" name="${e.htmlEncode(t.messages.validationDialog.labels.value)}" title="${e.htmlEncode(t.messages.validationDialog.labels.value)}" class="k-input-inner" data-${e.htmlEncode(t.ns)}bind="value: from, enabled: isList" required="required" /></span></div>\n                    </div><div data-${e.htmlEncode(t.ns)}bind="visible: isList">\n                    <div class="k-edit-field"><input type="checkbox" name="showButton" id="listShowButton" class="k-checkbox k-checkbox-md k-rounded-md" data-${e.htmlEncode(t.ns)}bind="checked: showButton" /><label for="listShowButton" class="k-checkbox-label"> ${e.htmlEncode(t.messages.validationDialog.labels.showListButton)}</label></div>\n                    </div><div data-${e.htmlEncode(t.ns)}bind="visible: isDate">\n                    <div class="k-edit-field"><input type="checkbox" name="showButton" id="dateShowButton" class="k-checkbox k-checkbox-md k-rounded-md" data-${e.htmlEncode(t.ns)}bind="checked: showButton" /><label for="dateShowButton" class="k-checkbox-label"> ${e.htmlEncode(t.messages.validationDialog.labels.showCalendarButton)}</label></div>\n                    </div><div data-${e.htmlEncode(t.ns)}bind="invisible: isAny">\n                    <div class="k-edit-field"><input type="checkbox" title="${e.htmlEncode(t.messages.validationDialog.labels.ignoreBlank)}" name="ignoreBlank" id="ignoreBlank" class="k-checkbox k-checkbox-md k-rounded-md" data-${e.htmlEncode(t.ns)}bind="checked: ignoreBlank" /><label for="ignoreBlank" class="k-checkbox-label"> ${e.htmlEncode(t.messages.validationDialog.labels.ignoreBlank)}</label></div>\n                    </div><div data-${e.htmlEncode(t.ns)}bind="invisible: isAny">\n                    <div class="k-hr"></div>\n                    <div class="k-edit-label"><label>${e.htmlEncode(t.messages.validationDialog.labels.onInvalidData)}:</label></div>\n                    <div class="k-edit-field"><input type="radio" title="${e.htmlEncode(t.messages.validationDialog.labels.rejectInput)}" id="validationTypeReject" name="validationType" value="reject" data-${e.htmlEncode(t.ns)}bind="checked: type" class="k-radio k-radio-md" /><label for="validationTypeReject" class="k-radio-label">${e.htmlEncode(t.messages.validationDialog.labels.rejectInput)}</label> <input type="radio" title="${e.htmlEncode(t.messages.validationDialog.labels.showWarning)}" id="validationTypeWarning" name="validationType" value="warning" data-${e.htmlEncode(t.ns)}bind="checked: type" class="k-radio k-radio-md" /><label for="validationTypeWarning" class="k-radio-label">${e.htmlEncode(t.messages.validationDialog.labels.showWarning)}</label></div>\n                    </div><div data-${e.htmlEncode(t.ns)}bind="invisible: isAny" class="hint-wrapper">\n                    <div class="k-edit-field"><input type="checkbox" title="${e.htmlEncode(t.messages.validationDialog.labels.showHint)}" name="useCustomMessages" id="useCustomMessages" class="k-checkbox k-checkbox-md k-rounded-md" data-${e.htmlEncode(t.ns)}bind="checked: useCustomMessages" /><label class="k-checkbox-label" for="useCustomMessages"> ${e.htmlEncode(t.messages.validationDialog.labels.showHint)}</label></div>\n                    <div data-${e.htmlEncode(t.ns)}bind="visible: useCustomMessages">\n                    <div class="k-edit-label"><label for="hint-title">${e.htmlEncode(t.messages.validationDialog.labels.hintTitle)}:</label></div>\n                    <div class="k-edit-field"><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input id="hint-title" name="hint-title" class="k-input-inner" title="${e.htmlEncode(t.messages.validationDialog.labels.hintTitle)}" placeholder="${e.htmlEncode(t.messages.validationDialog.placeholders.typeTitle)}" data-${e.htmlEncode(t.ns)}bind="value: hintTitle" /></span></div>\n                    <div class="k-edit-label"><label for="hint-message">${e.htmlEncode(t.messages.validationDialog.labels.hintMessage)}:</label></div>\n                    <div class="k-edit-field"><span class="k-textbox k-input k-input-md k-rounded-md k-input-solid"><input id="hint-message" class="k-input-inner" title="${e.htmlEncode(t.messages.validationDialog.labels.hintMessage)}" placeholder="${e.htmlEncode(t.messages.validationDialog.placeholders.typeMessage)}" data-${e.htmlEncode(t.ns)}bind="value: hintMessage" /></span></div>\n                    </div></div>\n                    <div class="k-actions"><button class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base" data-${e.htmlEncode(t.ns)}bind="visible: showRemove, click: remove"><span class="k-button-text">${e.htmlEncode(t.messages.remove)}</span></button><button class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary" data-${e.htmlEncode(t.ns)}bind="click: apply"><span class="k-button-text">${e.htmlEncode(t.messages.apply)}</span></button><button class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base" data-${e.htmlEncode(t.ns)}bind="click: close"><span class="k-button-text">${e.htmlEncode(t.messages.cancel)}</span></button></div>\n                    </div>`,n}},open:function(t){var n,i=this.options;this.viewModel=new k({type:i.type,defaultHintMessage:i.hintMessage,defaultHintTitle:i.hintTitle,defaultComparers:i.comparers.slice(0),comparerMessages:i.comparerMessages,criteria:i.criteria.slice(0),criterion:i.criterion,ignoreBlank:i.ignoreBlank,showButton:i.showButton,apply:this.apply.bind(this),close:this.close.bind(this),remove:this.remove.bind(this)}),this.viewModel.update(t.validation()),o.fn.open.call(this),n=this.dialog().element,this.validatable&&this.validatable.destroy(),e.bind(n,this.viewModel),this.validatable=new e.ui.Validator(n.find(".k-edit-form-container"),{validateOnBlur:!1,errorTemplate:this.options.errorTemplate||void 0})},apply:function(){this.validatable.validate()&&(o.fn.apply.call(this),this.trigger("action",{command:"EditValidationCommand",options:{value:this.viewModel.toValidationObject()}}))},remove:function(){this.viewModel.set("criterion","any"),this.apply()}});e.spreadsheet.dialogs.register("validation",x),e.spreadsheet.dialogs.ValidationDialog=x;var C=o.extend({init:function(t){o.fn.init.call(this,t),t=this.options,this.viewModel=e.observable({title:t.title,name:t.name,extension:t.extension,fileFormats:t.fileFormats,excel:t.excelExport,pdf:{proxyURL:t.pdfExport.proxyURL,forceProxy:t.pdfExport.forceProxy,title:t.pdfExport.title,author:t.pdfExport.author,autoPrint:t.pdfExport.autoPrint,subject:t.pdfExport.subject,keywords:t.pdfExport.keywords,creator:t.pdfExport.creator,date:t.pdfExport.date,fitWidth:t.pdf.fitWidth,area:t.pdf.area,areas:t.pdf.areas,paperSize:t.pdf.paperSize,paperSizes:t.pdf.paperSizes,margin:t.pdf.margin,margins:t.pdf.margins,landscape:t.pdf.landscape,guidelines:t.pdf.guidelines,hCenter:t.pdf.hCenter,vCenter:t.pdf.vCenter},apply:this.apply.bind(this),close:this.close.bind(this)});var n=this.dialog();this.viewModel.bind("change",(function(e){"extension"===e.field&&(this.set("showPdfOptions",".pdf"===this.extension),n.center())})),e.bind(n.element,this.viewModel)},options:{title:P("exportAsDialog.title","Export..."),name:P("exportAsDialog.defaultFileName","Workbook"),extension:".xlsx",fileFormats:[{description:P("exportAsDialog.xlsx.description","Excel Workbook (.xlsx)"),extension:".xlsx"},{description:P("exportAsDialog.pdf.description","Portable Document Format (.pdf)"),extension:".pdf"}],pdf:{fitWidth:!0,area:"workbook",areas:[{area:"workbook",text:P("exportAsDialog.pdf.area.workbook","Entire Workbook")},{area:"sheet",text:P("exportAsDialog.pdf.area.sheet","Active Sheet")},{area:"selection",text:P("exportAsDialog.pdf.area.selection","Selection")}],paperSize:"a4",paperSizes:["a2","a3","a4","a5","b3","b4","b5","folio","legal","letter","tabloid","executive"].map((function(e){return{value:e,text:P("exportAsDialog.pdf.paper."+e)}})),margin:{bottom:"0.75in",left:"0.7in",right:"0.7in",top:"0.75in"},margins:[{value:{bottom:"0.75in",left:"0.7in",right:"0.7in",top:"0.75in"},text:P("exportAsDialog.pdf.margin.normal","Normal")},{value:{bottom:"0.75in",left:"0.25in",right:"0.25in",top:"0.75in"},text:P("exportAsDialog.pdf.margin.narrow","Narrow")},{value:{bottom:"1in",left:"1in",right:"1in",top:"1in"},text:P("exportAsDialog.pdf.margin.wide","Wide")}],landscape:!0,guidelines:!0,hCenter:!0,vCenter:!0},width:520,template:n=>{let i;return i=`<div class='k-edit-label'><label id='name-label'>${e.htmlEncode(n.messages.exportAsDialog.labels.fileName)}:</label></div>\n                    <div class='k-edit-field'><span class='k-textbox k-input k-input-md k-rounded-md k-input-solid'><input aria-labelledby='name-label' class='k-input-inner' data-${e.htmlEncode(n.ns)}bind='value: name' /></span></div>\n                    <div >\n                       <div class='k-edit-label'><label id='file-format-label'>${e.htmlEncode(n.messages.exportAsDialog.labels.saveAsType)}:</label></div>\n                       <div class='k-edit-field'><select aria-labelledby='file-format-label' data-${e.htmlEncode(n.ns)}role='dropdownlist' class='k-file-format' data-${e.htmlEncode(n.ns)}text-field='description' data-${e.htmlEncode(n.ns)}value-field='extension' data-${e.htmlEncode(n.ns)}bind='value: extension, source: fileFormats'></select></div>\n                    </div>\n                    <div class='k-export-config' data-${e.htmlEncode(n.ns)}bind='visible: showPdfOptions'>\n                    <hr class='k-hr' />\n                    <div class='k-edit-label'><label id='export-area-label'>${e.htmlEncode(n.messages.exportAsDialog.labels.exportArea)}:</label></div>\n                    <div class='k-edit-field'><select aria-labelledby='export-area-label' data-${e.htmlEncode(n.ns)}role='dropdownlist' class='k-file-format' data-${e.htmlEncode(n.ns)}text-field='text' data-${e.htmlEncode(n.ns)}value-field='area' data-${e.htmlEncode(n.ns)}bind='value: pdf.area, source: pdf.areas'></select></div>\n                    <div class='k-edit-label'><label id='paper-size-label'>${e.htmlEncode(n.messages.exportAsDialog.labels.paperSize)}:</label></div>\n                    <div class='k-edit-field'><select aria-labelledby='paper-size-label' data-${e.htmlEncode(n.ns)}role='dropdownlist' class='k-file-format' data-${e.htmlEncode(n.ns)}text-field='text' data-${e.htmlEncode(n.ns)}value-field='value' data-${e.htmlEncode(n.ns)}bind='value: pdf.paperSize, source: pdf.paperSizes'></select></div>\n                    <div class='k-edit-label'><label id='margins-label'>${e.htmlEncode(n.messages.exportAsDialog.labels.margins)}:</label></div>\n                    <div class='k-edit-field'><select aria-labelledby='margins-label' data-${e.htmlEncode(n.ns)}role='dropdownlist' class='k-file-format' data-${e.htmlEncode(n.ns)}value-primitive='true'data-${e.htmlEncode(n.ns)}text-field='text' data-${e.htmlEncode(n.ns)}value-field='value' data-${e.htmlEncode(n.ns)}bind='value: pdf.margin, source: pdf.margins'></select></div>\n                    <div class='k-edit-label'><label>${e.htmlEncode(n.messages.exportAsDialog.labels.orientation)}:</label></div>\n                    <div class='k-edit-field'>\n                       <div class='k-button-group'>\n                          <input type='radio' id='k-orientation-portrait' aria-label='orientation portrait' name='orientation' data-${e.htmlEncode(n.ns)}type='boolean' data-${e.htmlEncode(n.ns)}bind='checked: pdf.landscape' value='false' />\n                          <label class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-icon-button k-group-start k-orientation-button' for='k-orientation-portrait'>\n                          ${e.ui.icon({icon:"file",iconClass:"k-button-icon"})}\n                          </label>\n                          <input type='radio' id='k-orientation-landscape' aria-label='orientation landscape' name='orientation' data-${e.htmlEncode(n.ns)}type='boolean' data-${e.htmlEncode(n.ns)}bind='checked: pdf.landscape' value='true' />\n                          <label class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-icon-button k-group-end k-orientation-button' for='k-orientation-landscape'>\n                          ${e.ui.icon({icon:"file-horizontal",iconClass:"k-button-icon"})}\n                          </label>\n                       </div>\n                    </div>\n                    <div class='k-edit-label'><label>${e.htmlEncode(n.messages.exportAsDialog.labels.print)}:</label></div>\n                    <div class='k-edit-field'><input class='k-checkbox k-checkbox-md k-rounded-md' id='guidelines' type='checkbox' data-${e.htmlEncode(n.ns)}bind='checked: pdf.guidelines'/><label class='k-checkbox-label' for='guidelines'>${e.htmlEncode(n.messages.exportAsDialog.labels.guidelines)}</label></div>\n                    <div class='k-edit-label'><label>${e.htmlEncode(n.messages.exportAsDialog.labels.scale)}:</label></div>\n                    <div class='k-edit-field'><input class='k-checkbox k-checkbox-md k-rounded-md' id='fitWidth' type='checkbox' data-${e.htmlEncode(n.ns)}bind='checked: pdf.fitWidth'/><label class='k-checkbox-label' for='fitWidth'>${e.htmlEncode(n.messages.exportAsDialog.labels.fit)}</label></div>\n                    <div class='k-edit-label'><label>${e.htmlEncode(n.messages.exportAsDialog.labels.center)}:</label></div>\n                    <div class='k-edit-field'><input class='k-checkbox k-checkbox-md k-rounded-md' id='hCenter' type='checkbox' data-${e.htmlEncode(n.ns)}bind='checked: pdf.hCenter'/><label class='k-checkbox-label' for='hCenter'>${e.htmlEncode(n.messages.exportAsDialog.labels.horizontally)}</label><input class='k-checkbox k-checkbox-md k-rounded-md' id='vCenter' type='checkbox' data-${e.htmlEncode(n.ns)}bind='checked: pdf.vCenter'/><label class='k-checkbox-label' for='vCenter'>${e.htmlEncode(n.messages.exportAsDialog.labels.vertically)}</label></div>\n                    <div class='k-page-orientation'>\n                       ${e.ui.icon(t(`<span data-${n.ns}bind='invisible: pdf.landscape'></span>`),{icon:"file"})}\n                       ${e.ui.icon(t(`<span data-${n.ns}bind='visible: pdf.landscape'></span>`),{icon:"file-horizontal"})}\n                    </div>\n                    </div>\n                    <div class='k-actions'><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary' data-${e.htmlEncode(n.ns)}bind='click: apply'><span class='k-button-text'>${e.htmlEncode(n.messages.save)}</span></button><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base' data-${e.htmlEncode(n.ns)}bind='click: close'><span class='k-button-text'>${e.htmlEncode(n.messages.cancel)}</span></button></div>`,i}},apply:function(){o.fn.apply.call(this),this.trigger("action",{command:"SaveAsCommand",options:this.viewModel})}});function S(t,n){e.spreadsheet.dialogs.register(t,d.extend({options:{messageId:n}}))}e.spreadsheet.dialogs.register("exportAs",C),S("modifyMerged","modifyMergedDialog.errorMessage"),S("rangeDisabled","rangeDisabledDialog.errorMessage"),S("intersectsArray","intersectsArrayDialog.errorMessage"),S("overflow","overflowDialog.errorMessage"),S("unsupportedSelection","unsupportedSelectionDialog.errorMessage"),S("incompatibleRanges","incompatibleRangesDialog.errorMessage"),S("noFillDirection","noFillDirectionDialog.errorMessage"),S("duplicateSheetName","duplicateSheetNameDialog.errorMessage");var T=d.extend({options:{width:640,title:"Errors in import",template:t=>{let n;n=`<div class='k-spreadsheet-message-content k-spreadsheet-import-errors'><div class='k--header-message'>We encountered ${t.errors.length} errors while reading this file.  Please be aware that some formulas might be missing, or contain invalid results.</div><div class='k--errors'><table><thead><tr><th>Context</th><th>Error message</th></tr></thead>`;for(let t=0;t<errors.length;++t){n+="";let i=errors[t];n+=`<tr><td>${e.htmlEncode(i.context)}</td><td>${e.htmlEncode(i.error)}</td></tr>`}return n+=`</table></div></div><div class='k-actions'><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary' data-${e.htmlEncode(t.ns)}bind='click: close'><span class='k-button-text'>${e.htmlEncode(t.messages.okText)}</span></button></div>`,n}}});e.spreadsheet.dialogs.register("importError",T);var D=d.extend({options:{title:P("useKeyboardDialog.title","Copying and pasting"),template:t=>{let n;return n=`${e.htmlEncode(t.messages.useKeyboardDialog.errorMessage)}\n                <div>Ctrl+C ${e.htmlEncode(t.messages.useKeyboardDialog.labels.forCopy)}</div>\n                <div>Ctrl+X ${e.htmlEncode(t.messages.useKeyboardDialog.labels.forCut)}</div>\n                <div>Ctrl+V ${e.htmlEncode(t.messages.useKeyboardDialog.labels.forPaste)}</div>\n                <div class="k-actions"><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary'\n                        data-${e.htmlEncode(t.ns)}bind='click: close'><span\n                            class='k-button-text'>${t.messages.okText}</span></button></div>`,n}}});e.spreadsheet.dialogs.register("useKeyboard",D);var A=o.extend({options:{title:P("linkDialog.title","Hyperlink"),template:t=>{let n;return n=`<div class='k-edit-label'><label id='url-label'>${e.htmlEncode(t.messages.linkDialog.labels.url)}:</label></div>\n<div class='k-edit-field'><span class='k-textbox k-input k-input-md k-rounded-md k-input-solid'><input\n            class='k-input-inner' data-${e.htmlEncode(t.ns)}bind='value: url'\n            title='${e.htmlEncode(t.messages.linkDialog.labels.url)}' aria-labelledby='url-label' /></span></div>\n<div class='k-actions'><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-left'\n        data-${e.htmlEncode(t.ns)}bind='click: remove'><span\n            class='k-button-text'>${t.messages.linkDialog.labels.removeLink}</span></button><button\n        class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary'\n        data-${e.htmlEncode(t.ns)}bind='click: apply'><span\n            class='k-button-text'>${t.messages.okText}</span></button><button\n        class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base'\n        data-${e.htmlEncode(t.ns)}bind='click: cancel'><span\n            class='k-button-text'>${t.messages.cancel}</span></button></div>`,n},autoFocus:!1},open:function(n){var i=this;o.fn.open.apply(i,arguments);var r=i.dialog().element,a=e.observable({url:n.link(),apply:function(){/\S/.test(a.url)||(a.url=null),i.trigger("action",{command:"HyperlinkCommand",options:{link:a.url}}),i.close()},remove:function(){a.url=null,a.apply()},cancel:i.close.bind(i)});e.bind(r,a),r.find("input").trigger("focus").on("keydown",(function(e){13==e.keyCode?(a.url=t(this).val(),e.stopPropagation(),e.preventDefault(),a.apply()):27==e.keyCode&&(e.stopPropagation(),e.preventDefault(),a.cancel())}))}});e.spreadsheet.dialogs.register("hyperlink",A);var M=o.extend({options:{title:P("sheetRenameDialog.title","Rename Sheet"),template:t=>{let n;return n=`<div class='k-edit-label'><label id='sheet-name-label'>${e.htmlEncode(t.messages.sheetRenameDialog.labels.text)}:</label></div>\n<div class='k-edit-field'><span class='k-textbox k-input k-input-md k-rounded-md k-input-solid'><input\n            class='k-input-inner' data-${e.htmlEncode(t.ns)}bind='value: sheetName'\n            title='${e.htmlEncode(t.messages.sheetRenameDialog.labels.text)}' aria-labelledby='sheet-name-label' /></span></div>\n<div class='k-actions'><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary'\n        data-${e.htmlEncode(t.ns)}bind='click: apply'><span\n            class='k-button-text'>${t.messages.sheetRenameDialog.labels.rename}</span></button><button\n        class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base'\n        data-${e.htmlEncode(t.ns)}bind='click: cancel'><span\n            class='k-button-text'>${t.messages.cancel}</span></button></div>`,n},autoFocus:!1},open:function(n,i){let r=n.sheet(),a=this;o.fn.open.apply(a,arguments);let s=a.dialog().element,l=e.observable({sheetName:i?._oldSheetName||r.name(),apply:function(){a._newSheetName=l.sheetName,a.close()},cancel:a.close.bind(a)});e.bind(s,l),s.find("input").trigger("focus").on("keydown",(function(e){13==e.keyCode?(l.sheetName=t(this).val(),e.stopPropagation(),e.preventDefault(),l.apply()):27==e.keyCode&&(e.stopPropagation(),e.preventDefault(),l.cancel())}))}});e.spreadsheet.dialogs.register("renameSheet",M);var E=o.extend({options:{className:"k-spreadsheet-insert-comment",template:t=>{let n;return n=`<div class='k-edit-label'><label id='comment-label'>${e.htmlEncode(t.messages.insertCommentDialog.labels.comment)}:</label></div>\n                <div class='k-edit-field'><span class='k-input k-textarea k-input-solid k-input-md k-rounded-md'><textarea\n                    aria-labelledby='comment-label' rows='5' class='k-input-inner'\n                    data-${e.htmlEncode(t.ns)}bind='value: comment'></textarea></span></div>\n                <div class='k-actions'> <button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-left'\n                    data-${e.htmlEncode(t.ns)}bind='click: remove'><span\n                    class='k-button-text'>${e.htmlEncode(t.messages.insertCommentDialog.labels.removeComment)}</span></button>\n                <button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary'\n                    data-${e.htmlEncode(t.ns)}bind='click: apply'><span\n                    class='k-button-text'>${e.htmlEncode(t.messages.okText)}</span></button> <button\n                    class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base'\n                    data-${e.htmlEncode(t.ns)}bind='click: cancel'><span\n                    class='k-button-text'>${t.messages.cancel}</span></button></div>`,n},title:P("insertCommentDialog.title","Insert comment"),autoFocus:!1,width:450},open:function(t){var n=this;o.fn.open.apply(n,arguments);var i=n.dialog().element,r=e.observable({comment:t.comment(),apply:function(){/\S/.test(r.comment)||(r.comment=null),n.trigger("action",{command:"InsertCommentCommand",options:{value:r.comment}}),n.close()},remove:function(){r.comment=null,r.apply()},cancel:n.close.bind(n)});e.bind(i,r),i.find("textarea").trigger("focus")}});e.spreadsheet.dialogs.register("insertComment",E);var I=o.extend({options:{template:t=>{let n;return n=`<div class='k-spreadsheet-insert-image-dialog'> <label\n        data-${e.htmlEncode(t.ns)}bind='style: { background-image: imageUrl }, css: { k-spreadsheet-has-image: hasImage, k-hover: isHovered }, events: { dragenter: dragEnter, dragover: stopEvent, dragleave: dragLeave, drop: drop }'>\n        <div data-${e.htmlEncode(t.ns)}bind='text: info'></div>\n        <input type='file' data-${e.htmlEncode(t.ns)}bind='events: { change: change }'\n            accept='image/png, image/jpeg, image/gif' />\n    </label></div>\n<div class='k-actions'> <button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary'\n        data-${e.htmlEncode(t.ns)}bind='enabled: okEnabled, click: apply'><span\n            class='k-button-text'>${e.htmlEncode(t.messages.okText)}</span></button> <button\n        class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base'\n        data-${e.htmlEncode(t.ns)}bind='click: cancel'><span\n            class='k-button-text'>${t.messages.cancel}</span></button></div>`,n},title:P("insertImageDialog.title","Insert image"),width:"auto"},open:function(){var t=this;o.fn.open.apply(t,arguments);var n=t.dialog().element,i=e.observable({okEnabled:!1,info:e.spreadsheet.messages.dialogs.insertImageDialog.info,imageUrl:"",hasImage:!1,isHovered:!1,_url:null,_image:null,apply:function(){window.URL.revokeObjectURL(i._url),t.trigger("action",{command:"InsertImageCommand",options:{blob:i._image,width:i._width,height:i._height}}),t.close()},cancel:t.close.bind(t),stopEvent:function(e){e.stopPropagation(),e.preventDefault()},drop:function(e){i.stopEvent(e),i.selectFile(e.originalEvent.dataTransfer.files),i.set("isHovered",!1)},dragEnter:function(e){i.stopEvent(e),i.set("isHovered",!0)},dragLeave:function(e){i.stopEvent(e),i.set("isHovered",!1)},change:function(e){i.selectFile(e.target.files)},selectFile:function(t){for(var n,r=0;r<t.length;++r)if(/^image\//i.test(t[r].type)){n=t[r];break}if(i._url&&window.URL.revokeObjectURL(i._url),n){i._image=n,i._url=window.URL.createObjectURL(n);var o=new Image;o.src=i._url,o.onload=function(){i._width=o.width,i._height=o.height,i.set("info",e.spreadsheet.messages.dialogs.insertImageDialog.info),i.set("okEnabled",!0),i.set("imageUrl","url('"+i._url+"')"),i.set("hasImage",!0)}}else i._image=null,i.set("info",e.spreadsheet.messages.dialogs.insertImageDialog.typeError),i.set("okEnabled",!1),i.set("imageUrl",""),i.set("hasImage",!1)}});e.bind(n,i)}});function z(e,t){this.path=e.split("."),this.def=t}function P(e,t){return new z(e,t)}function H(e){return e instanceof z?e.trans():Array.isArray(e)?e.map(H):null!=e&&"object"==typeof e?Object.keys(e).reduce((function(t,n){return t[n]=H(e[n]),t}),{}):e}e.spreadsheet.dialogs.register("insertImage",I),z.prototype.trans=function(){for(var t=e.spreadsheet.messages.dialogs,n=0;n<this.path.length;++n)if(!(t=t[this.path[n]]))return this.def;return t}}(window.kendo),function(e){var t=e.jQuery,n=["allBorders","insideBorders","insideHorizontalBorders","insideVerticalBorders","outsideBorders","leftBorder","topBorder","rightBorder","bottomBorder","noBorders"],i={allBorders:"bordersAll",insideBorders:"bordersInside",insideHorizontalBorders:"bordersInsideHorizontal",insideVerticalBorders:"bordersInsideVertical",outsideBorders:"bordersOutside",leftBorder:"borderLeft",topBorder:"borderTop",rightBorder:"borderRight",bottomBorder:"borderBottom",noBorders:"bordersNone"},r=e.spreadsheet.messages.borderPalette={allBorders:"All borders",insideBorders:"Inside borders",insideHorizontalBorders:"Inside horizontal borders",insideVerticalBorders:"Inside vertical borders",outsideBorders:"Outside borders",leftBorder:"Left border",topBorder:"Top border",rightBorder:"Right border",bottomBorder:"Bottom border",noBorders:"No border"},o=["#ffffff","#000000","#d6ecff","#4e5b6f","#7fd13b","#ea157a","#feb80a","#00addc","#738ac8","#1ab39f","#f2f2f2","#7f7f7f","#a7d6ff","#d9dde4","#e5f5d7","#fad0e4","#fef0cd","#c5f2ff","#e2e7f4","#c9f7f1","#d8d8d8","#595959","#60b5ff","#b3bcca","#cbecb0","#f6a1c9","#fee29c","#8be6ff","#c7d0e9","#94efe3","#bfbfbf","#3f3f3f","#007dea","#8d9baf","#b2e389","#f272af","#fed46b","#51d9ff","#aab8de","#5fe7d5","#a5a5a5","#262626","#003e75","#3a4453","#5ea226","#af0f5b","#c58c00","#0081a5","#425ea9","#138677","#7f7f7f","#0c0c0c","#00192e","#272d37","#3f6c19","#750a3d","#835d00","#00566e","#2c3f71","#0c594f"],a=e.ui.Widget.extend({init:function(t,n){e.ui.Widget.call(this,t,n),this.element=t,this.color="#000",this.element.addClass("k-spreadsheet-popup"),this._borderTypePalette(),this._borderColorPalette()},options:{name:"BorderPalette"},events:["change"],destroy:function(){this.colorChooser.destroy(),e.destroy(this.element.find(".k-spreadsheet-border-type-palette"))},value:function(){return{type:this.type,color:this.color}},_borderTypePalette:function(){var o=this,a=r,s=t("<div />",{class:"k-spreadsheet-border-type-palette"});t('<span class="k-column-menu-group-header"><span class="k-column-menu-group-header-text">Border type</span></span>').appendTo(this.element),s.appendTo(this.element),n.map((function(n){t('<button title="'+a[n]+'" aria-label="'+a[n]+'" data-border-type="'+n+'">').appendTo(s).kendoToggleButton({icon:e.toHyphens(i[n]),toggle:o._toggle.bind(o)})}))},_borderColorPalette:function(){var n=t("<div />",{class:"k-spreadsheet-border-color-palette"});t('<span class="k-column-menu-group-header"><span class="k-column-menu-group-header-text">Border color</span></span>').appendTo(this.element),n.appendTo(this.element),this.colorChooser=new e.ui.FlatColorPicker(n,{buttons:!this.options.change,color:this.color,view:"palette",palette:o,input:!1,change:this._change.bind(this)}),this.colorChooser.wrapper.find(".k-coloreditor-apply").on("click",this._apply.bind(this)),this.colorChooser.wrapper.find(".k-coloreditor-cancel").on("click",this._cancel.bind(this))},_change:function(){this.color=this.colorChooser.value()},_toggle:function(e){var t=e.target.data("borderType"),n=e.target.siblings(".k-selected").data("kendoToggleButton");!0===e.checked?(n&&n.toggle(!1),this.type=t):this.type=null},_apply:function(){this.trigger("change",{type:this.type,color:this.color})},_cancel:function(){this.trigger("change",{type:null,color:null})}});e.spreadsheet.BorderPalette=a}(window.kendo),function(e){var t=e.jQuery;function n(t){return`<button role="button">${e.ui.icon({icon:t,iconClass:"k-button-icon"})}<span class="k-button-text">${e.ui.icon("caret-alt-down")}</span></button>`}var i=e.ui.ToolBar,r=e.spreadsheet.messages.toolbar={addColumnLeft:"Add column left",addColumnRight:"Add column right",addRowAbove:"Add row above",addRowBelow:"Add row below",alignment:"Alignment",alignmentButtons:{justifyLeft:"Align left",justifyCenter:"Center",justifyRight:"Align right",justifyFull:"Justify",alignTop:"Align top",alignMiddle:"Align middle",alignBottom:"Align bottom"},backgroundColor:"Background",increaseFontSize:"Increase font size",decreaseFontSize:"Decrease font size",bold:"Bold",borders:"Borders",copy:"Copy",cut:"Cut",deleteColumn:"Delete column",deleteRow:"Delete row",filter:"Filter",fontFamily:"Font",fontSize:"Font size",format:"Custom format...",formatTypes:{automatic:"Automatic",text:"Text",number:"Number",percent:"Percent",financial:"Financial",currency:"Currency",date:"Date",time:"Time",dateTime:"Date time",duration:"Duration",moreFormats:"More formats..."},formatDecreaseDecimal:"Decrease decimal",formatIncreaseDecimal:"Increase decimal",freeze:"Freeze panes",freezeButtons:{freezePanes:"Freeze panes",freezeRows:"Freeze rows",freezeColumns:"Freeze columns",unfreeze:"Unfreeze panes"},insertComment:"Insert comment",insertImage:"Insert image",italic:"Italic",merge:"Merge cells",mergeButtons:{mergeCells:"Merge all",mergeHorizontally:"Merge horizontally",mergeVertically:"Merge vertically",unmerge:"Unmerge"},open:"Open...",paste:"Paste",redo:"Redo",undo:"Undo",exportAs:"Export...",toggleGridlines:"Toggle gridlines",sort:"Sort",sortButtons:{sortRangeAsc:"Sort range A to Z",sortRangeDesc:"Sort range Z to A"},textColor:"Text Color",textWrap:"Wrap text",underline:"Underline",validation:"Data validation...",hyperlink:"Link"},o=e.spreadsheet.formats={automatic:null,text:"@",number:"#,0.00",percent:"0.00%",financial:'_("$"* #,##0.00_);_("$"* (#,##0.00);_("$"* "-"??_);_(@_)',currency:"$#,##0.00;[Red]$#,##0.00",date:"m/d/yyyy",time:"h:mm:ss AM/PM",dateTime:"m/d/yyyy h:mm",duration:"[h]:mm:ss"},a=["#ffffff","#000000","#d6ecff","#4e5b6f","#7fd13b","#ea157a","#feb80a","#00addc","#738ac8","#1ab39f","#f2f2f2","#7f7f7f","#a7d6ff","#d9dde4","#e5f5d7","#fad0e4","#fef0cd","#c5f2ff","#e2e7f4","#c9f7f1","#d8d8d8","#595959","#60b5ff","#b3bcca","#cbecb0","#f6a1c9","#fee29c","#8be6ff","#c7d0e9","#94efe3","#bfbfbf","#3f3f3f","#007dea","#8d9baf","#b2e389","#f272af","#fed46b","#51d9ff","#aab8de","#5fe7d5","#a5a5a5","#262626","#003e75","#3a4453","#5ea226","#af0f5b","#c58c00","#0081a5","#425ea9","#138677","#7f7f7f","#0c0c0c","#00192e","#272d37","#3f6c19","#750a3d","#835d00","#00566e","#2c3f71","#0c594f"],s=e.spreadsheet.messages.colorPicker={reset:"Reset color",customColor:"Custom color...",apply:"Apply",cancel:"Cancel"},l={undo:{type:"button",name:"undo",icon:"undo",command:"undo"},redo:{type:"button",name:"redo",icon:"redo",command:"redo"},separator:{type:"separator"},open:{type:"open",name:"open",icon:"folder-open",extensions:".xlsx",command:"OpenCommand"},exportAs:{type:"button",name:"exportAs",dialog:"exportAs",overflow:"never",icon:"download"},bold:{type:"button",command:"PropertyChangeCommand",property:"bold",value:!0,icon:"bold",togglable:!0},italic:{type:"button",command:"PropertyChangeCommand",property:"italic",value:!0,icon:"italic",togglable:!0},underline:{type:"button",command:"PropertyChangeCommand",property:"underline",value:!0,icon:"underline",togglable:!0},formatDecreaseDecimal:{type:"button",name:"formatDecreaseDecimal",command:"AdjustDecimalsCommand",value:-1,icon:"decimal-decrease"},formatIncreaseDecimal:{type:"button",name:"formatIncreaseDecimal",command:"AdjustDecimalsCommand",value:1,icon:"decimal-increase"},textWrap:{type:"button",name:"textWrap",command:"TextWrapCommand",property:"wrap",value:!0,icon:"text-wrap",togglable:!0},cut:{type:"button",name:"cut",command:"ToolbarCutCommand",icon:"cut"},copy:{type:"button",name:"copy",command:"ToolbarCopyCommand",icon:"copy"},paste:{type:"button",name:"paste",command:"ToolbarPasteCommand",icon:"clipboard"},alignment:{type:"component",name:"alignment",property:"alignment",component:"DropDownButton",element:n("align-left"),overflowComponent:{type:"button",dialog:"alignment",icon:"align-left"},componentOptions:{fillMode:"flat",items:[{attributes:{"data-value":"left","data-property":"textAlign","data-command":"PropertyChangeCommand"},icon:"align-left",text:r.alignmentButtons.justifyLeft},{attributes:{"data-value":"center","data-property":"textAlign","data-command":"PropertyChangeCommand"},icon:"align-center",text:r.alignmentButtons.justifyCenter},{attributes:{"data-value":"right","data-property":"textAlign","data-command":"PropertyChangeCommand"},icon:"align-right",text:r.alignmentButtons.justifyRight},{attributes:{"data-value":"justify","data-property":"textAlign","data-command":"PropertyChangeCommand"},icon:"align-justify",text:r.alignmentButtons.justifyFull},{attributes:{class:"k-separator"}},{attributes:{"data-value":"top","data-property":"verticalAlign","data-command":"PropertyChangeCommand"},icon:"align-top",text:r.alignmentButtons.alignTop},{attributes:{"data-value":"center","data-property":"verticalAlign","data-command":"PropertyChangeCommand"},icon:"align-middle",text:r.alignmentButtons.alignMiddle},{attributes:{"data-value":"bottom","data-property":"verticalAlign","data-command":"PropertyChangeCommand"},icon:"align-bottom",text:r.alignmentButtons.alignBottom}],commandOn:"click"}},backgroundColor:{type:"component",name:"backgroundColor",commandOn:"change",command:"PropertyChangeCommand",property:"background",component:"ColorPicker",componentOptions:{view:"palette",toolIcon:"droplet",fillMode:"flat",palette:a,clearButton:!0,messages:s,input:!1,commandOn:"change"},overflowComponent:{type:"button",dialog:"colorPicker",icon:"droplet",property:"background"}},textColor:{type:"component",name:"textColor",commandOn:"change",command:"PropertyChangeCommand",property:"color",component:"ColorPicker",componentOptions:{view:"palette",fillMode:"flat",toolIcon:"foreground-color",palette:a,clearButton:!0,messages:s,input:!1,commandOn:"change"},overflowComponent:{type:"button",dialog:"colorPicker",icon:"foreground-color",property:"color"}},fontFamily:{type:"component",name:"fontFamily",command:"PropertyChangeCommand",property:"fontFamily",component:"DropDownList",overflowComponent:{type:"button",dialog:"fontFamily",icon:"font-family"},componentOptions:{dataSource:["Arial","Courier New","Georgia","Times New Roman","Trebuchet MS","Verdana"],value:"Arial",fillMode:"flat",commandOn:"change"}},fontSize:{type:"component",name:"fontSize",command:"PropertyChangeCommand",property:"fontSize",component:"ComboBox",overflowComponent:{type:"button",dialog:"fontSize",icon:"font-size"},componentOptions:{dataSource:[8,9,10,11,12,13,14,16,18,20,22,24,26,28,36,48,72],value:12,fillMode:"flat",commandOn:"change"}},increaseFontSize:{type:"button",name:"increaseFontSize",command:"IncreaseFontSize",property:"fontSize",icon:"font-grow"},decreaseFontSize:{type:"button",name:"decreaseFontSize",command:"DecreaseFontSize",property:"fontSize",icon:"font-shrink"},format:{type:"component",name:"format",component:"DropDownButton",element:n("custom-format"),overflowComponent:{type:"button",dialog:"formatCells",icon:"custom-format"},componentOptions:{fillMode:"flat",items:[{attributes:{"data-value":o.automatic,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.automatic},{attributes:{"data-value":o.text,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.text},{attributes:{"data-value":o.number,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.number,sample:"1,499.99"},{attributes:{"data-value":o.percent,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.percent,sample:"14.50%"},{attributes:{"data-value":o.financial,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.financial,sample:"(1,000.12)"},{attributes:{"data-value":o.currency,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.currency,sample:"$1,499.99"},{attributes:{"data-value":o.date,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.date,sample:"4/21/2012"},{attributes:{"data-value":o.time,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.time,sample:"5:49:00 PM"},{attributes:{"data-value":o.dateTime,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.dateTime,sample:"4/21/2012 5:49:00"},{attributes:{"data-value":o.duration,"data-command":"PropertyChangeCommand","data-property":"format"},text:r.formatTypes.duration,sample:"168:05:00"},{attributes:{"data-value":"popup","data-popup":"formatCells"},text:r.formatTypes.moreFormats}],itemTemplate:t=>{let n;return n='<span class="k-link k-menu-link"><span class="k-menu-link-text">',t.sample&&(n+=`<span class='k-spreadsheet-sample'>${e.htmlEncode(t.sample)}</span> `),n+=`${e.htmlEncode(t.text)}</span></span>`,n},commandOn:"click"}},filter:{type:"button",name:"filter",property:"hasFilter",icon:"filter",command:"FilterCommand",togglable:!0,enable:!1},merge:{type:"component",name:"merge",component:"DropDownButton",element:n("cells-merge"),overflowComponent:{type:"button",dialog:"merge",icon:"cells-merge"},componentOptions:{fillMode:"flat",items:[{attributes:{"data-value":"cells","data-command":"MergeCellCommand"},icon:"cells-merge",text:r.mergeButtons.mergeCells},{attributes:{"data-value":"horizontally","data-command":"MergeCellCommand"},icon:"cells-merge-horizontally",text:r.mergeButtons.mergeHorizontally},{attributes:{"data-value":"vertically","data-command":"MergeCellCommand"},icon:"cells-merge-vertically",text:r.mergeButtons.mergeVertically},{attributes:{"data-value":"unmerge","data-command":"MergeCellCommand"},icon:"table-unmerge",text:r.mergeButtons.unmerge}],commandOn:"click"}},freeze:{type:"component",name:"freeze",component:"DropDownButton",element:n("pane-freeze"),overflowComponent:{type:"button",dialog:"freeze",icon:"pane-freeze"},componentOptions:{fillMode:"flat",items:[{attributes:{"data-value":"panes","data-command":"FreezePanesCommand"},icon:"pane-freeze",text:r.freezeButtons.freezePanes},{attributes:{"data-value":"rows","data-command":"FreezePanesCommand"},icon:"row-freeze",text:r.freezeButtons.freezeRows},{attributes:{"data-value":"columns","data-command":"FreezePanesCommand"},icon:"column-freeze",text:r.freezeButtons.freezeColumns},{attributes:{"data-value":"unfreeze","data-command":"FreezePanesCommand"},icon:"table-unmerge",text:r.freezeButtons.unfreeze}],commandOn:"click"}},borders:{type:"popupButton",name:"borders",icon:"borders-all",popupComponent:e.spreadsheet.BorderPalette,commandOn:"change",command:"BorderChangeCommand",overflowComponent:{type:"button",dialog:"borders"}},formatCells:{type:"button",dialog:"formatCells",overflow:"never"},hyperlink:{type:"button",name:"hyperlink",dialog:"hyperlink",icon:"link"},toggleGridlines:{type:"button",name:"toggleGridlines",command:"GridLinesChangeCommand",property:"gridLines",value:!0,icon:"borders-none",togglable:!0,selected:!0},insertComment:{type:"button",name:"insertComment",dialog:"insertComment",property:"comment",togglable:!0,icon:"comment"},insertImage:{type:"button",name:"insertImage",dialog:"insertImage",icon:"image"},addColumnLeft:{type:"button",name:"addColumnLeft",command:"AddColumnCommand",value:"left",icon:"table-column-insert-left"},addColumnRight:{type:"button",name:"addColumnRight",command:"AddColumnCommand",value:"right",icon:"table-column-insert-right"},addRowBelow:{type:"button",name:"addRowBelow",command:"AddRowCommand",value:"below",icon:"table-row-insert-below"},addRowAbove:{type:"button",name:"addRowAbove",command:"AddRowCommand",value:"above",icon:"table-row-insert-above"},deleteColumn:{type:"button",name:"deleteColumn",command:"DeleteColumnCommand",icon:"table-column-delete"},deleteRow:{type:"button",name:"deleteRow",command:"DeleteRowCommand",icon:"table-row-delete"},sort:{type:"component",name:"sort",component:"DropDownButton",element:n("sort-desc"),overflowComponent:{type:"button",dialog:"sort",icon:"sort-desc"},componentOptions:{fillMode:"flat",items:[{attributes:{"data-value":"asc","data-command":"SortCommand"},sheet:!1,text:r.sortButtons.sortRangeAsc,icon:"sort-asc"},{attributes:{"data-value":"desc","data-command":"SortCommand"},sheet:!1,text:r.sortButtons.sortRangeDesc,icon:"sort-desc"}],commandOn:"click"}},validation:{type:"button",name:"validation",dialog:"validation",icon:"exclamation-circle"}},c=i.extend({init:function(e,t){Object.keys(l).forEach((e=>{"validation"!==e&&(l[e].showText="overflow")})),t.tools=t.tools||c.prototype.options.tools[t.toolbarName],t.parentMessages=r,t.defaultTools=l,i.fn.init.call(this,e,t);var n=this._click.bind(this);this.element.addClass("k-spreadsheet-toolbar k-toolbar-md"),this.bind({click:n,toggle:n,change:n})},_click:function(e){var t=e.target,n=t.data("property"),i=e.value||t.data("value")||e.target.val(),r=t.data("command"),o=t.data("dialog"),a=t.data("options")||{};if("popup"===i&&(o=t.data("popup")),"IncreaseFontSize"===r&&(r="PropertyChangeCommand",i++),"DecreaseFontSize"===r&&(r="PropertyChangeCommand",i--),a.property=n||null,a.value=i||null,o)this.dialog({name:o,options:a});else if(r){var s={command:r,options:a};"boolean"==typeof s.options.value&&(s.options.value=!!e.checked||null),this.action(s)}},events:["action","dialog"],options:{name:"SpreadsheetToolBar",resizable:!0,tools:{file:["open","exportAs"],format:["format","formatDecreaseDecimal","formatIncreaseDecimal"],home:[["undo","redo"],"separator",["cut","copy","paste"],"separator","fontFamily","fontSize","increaseFontSize","decreaseFontSize","separator",["bold","italic","underline"],"separator","textColor","separator","backgroundColor","borders","separator","alignment","textWrap"],insert:["insertComment","separator","hyperlink","separator","insertImage","separator",["addColumnLeft","addColumnRight","addRowBelow","addRowAbove"],"separator",["deleteColumn","deleteRow"]],data:["sort","separator","filter","separator","validation"],view:["freeze","merge","toggleGridlines"]},fillMode:"flat"},action:function(e){this.trigger("action",e)},dialog:function(e){this.trigger("dialog",e)},refresh:function(t){for(var n=t,i=this._tools(),r=0;r<i.length;r++){var o=i[r].property,a=i[r].tool,s=e.isFunction(n[o])?n[o]():n;"gridLines"==o&&(s=n.sheet().showGridLines()),this._updateTool(a,s,o,n)}this.resize(!0)},_tools:function(){return this.element.find("[data-property]").toArray().map(function(e){return{property:(e=t(e)).attr("data-property"),tool:this._getItem(e)}}.bind(this))},_updateTool:function(t,n,i,r){var o,a,s,l,c,d,u=t.component,h=t.toolbarEl,p=e.widgetInstance(h.find("[data-role]")),f=t.menuItem,m=!1;if("hasFilter"===i)(l=r.sheet().selection())&&l._ref&&l._ref.height&&(c=n||l._ref.height()>1,this.enable(h,c));else if("alignment"===i)o=n.verticalAlign(),a=n.textAlign(),(s=u.menu.element).find(".k-item .k-link").removeClass("k-selected"),s.find(".k-item[data-property=textAlign][data-value="+a+"] .k-link").addClass("k-selected"),s.find(".k-item[data-property=verticalAlign][data-value="+o+"] .k-link").addClass("k-selected");else if("background"===i||"color"===i)p.value(n);else if("fontFamily"===i||"fontSize"===i){if(h.is("button"))return h.attr("data-value",n),void h.data("value",n);d=f.find(".k-menu-link-text").text().split("(")[0].trim(),f.find(".k-menu-link-text").text(d+" ("+n+") ..."),p.value(n)}u&&u.toggle&&("boolean"==typeof n?m=!!n:"string"==typeof n&&(m=h.data("value")?h.data("value")===n:null!=n),this.toggle(h,m))}});e.cssProperties.propertyDictionary.SpreadsheetToolBar=e.cssProperties.propertyDictionary.ToolBar,e.spreadsheet.ToolBar=c,e.spreadsheet.Menu=e.ui.Menu}(window.kendo);var dD={},uD=function(e,t){var n=t+":"+e,i=dD[n];if(!i){var r,o=document.createElement("div");o.style.position="fixed",o.style.left="-10000px",o.style.top="-10000px",o.style.fontFamily=e,o.style.fontSize=t+"px",o.style.whiteSpace="pre";for(var a=32;a<128;++a)(r=document.createElement("span")).appendChild(document.createTextNode(String.fromCharCode(a))),o.appendChild(r);document.body.appendChild(o);var s={};for(a=32,r=o.firstChild;a<128&&r;++a,r=r.nextSibling)s[a]=r.offsetWidth;for(;r=o.firstChild;)o.removeChild(r);i=dD[n]=function(e){var t=e.charCodeAt(0),n=s[t];return null==n&&((r=document.createElement("span")).appendChild(document.createTextNode(String.fromCharCode(t))),o.appendChild(r),n=s[t]=r.offsetWidth,o.removeChild(r)),n}}return i};kendo.spreadsheet.drawTabularData=function(e){var t=new $.Deferred,n=t.promise();e=cD(e,{dataSource:null,guidelines:!0,guideColor:"#000",columns:null,headerBackground:"#999",headerColor:"#000",oddBackground:null,evenBackground:null,fontFamily:"Arial",fontSize:12,paperSize:"A4",margin:"1cm",landscape:!0,fitWidth:!1,scale:1,rowHeight:20,maxEmpty:1,useGridFormat:!0}),kendo.drawing.pdf.defineFont(kendo.drawing.drawDOM.getFontFaces(document));var i=uD(e.fontFamily,e.fontSize);function r(e){if(null!=e){for(var t=12,n=e.length;--n>=0;)t+=i(e.charAt(n));return t}return 0}var o=e.guidelines?{size:1,color:e.guideColor}:null;function a(e){return o?cD(e,{borderLeft:o,borderTop:o,borderRight:o,borderBottom:o}):e}return e.dataSource.fetch((function(){var n=e.dataSource.data();if(!n.length)return t.reject("Empty dataset");var i=e.columns.map((function(e){return"string"==typeof e?{title:e,field:e}:e})),o=i.map((function(e){return e.title||e.field})),s=o.map(r),l=n.map((function(t,n){return{cells:i.map((function(i,o){var l=t[i.field];return e.useGridFormat&&(null!=l&&(i.format?l=kendo.format(i.format,l):l+=""),s[o]=Math.max(r(l),s[o])),a({value:l,format:e.useGridFormat?null:i.format,background:n%2?e.evenBackground:e.oddBackground})}))}}));l.unshift({cells:o.map((function(t){return a({value:t,background:e.headerBackground,color:e.headerColor})}))});var c=new kendo.spreadsheet.Sheet(l.length+1,i.length+1,e.rowHeight,50,20,20,{fontFamily:e.fontFamily,fontSize:e.fontSize,verticalAlign:"center"});c.fromJSON({name:"Sheet1",rows:l,columns:s.map((function(e,t){return{index:t,width:e}}))}),c.draw({paperSize:e.paperSize,landscape:e.landscape,margin:e.margin,guidelines:!1,scale:e.scale,fitWidth:e.fitWidth,maxEmpty:e.maxEmpty,headerRows:1},t.resolve.bind(t))})),n},function(e){"use strict";let t=e.spreadsheet.registerEditor;var n=e.jQuery;t("_validation_date",(function(){var t,i,r;function o(){i||(i=n("<div>").kendoCalendar(),r=n("<div>").kendoPopup(),i.appendTo(r),i=i.getKendoCalendar(),r=r.getKendoPopup(),i.bind("change",(function(){r.close();var n=i.value();t.range.format()||t.range.format("yyyy-mm-dd"),t.callback(e.spreadsheet.dateToNumber(n))}))),r.setOptions({anchor:t.view.element.querySelector(".k-spreadsheet-editor-button"),origin:t.alignLeft?"bottom right":"bottom left",position:t.alignLeft?"top right":"top left"});var o=t.range.value(),s=t.range.sheet();null!=o?i.value(e.spreadsheet.numberToDate(o)):i.value(null);var l=t.validation;if(l){var c=e.ui.Calendar.fn.options.min,d=e.ui.Calendar.fn.options.max,u=l.from,h=l.to,p=e.spreadsheet.calc.runtime.Formula;/^(?:greaterThan|between)/.test(l.comparerType)&&(c=u instanceof p&&a(u.value)?e.spreadsheet.numberToDate(s.range(u.value.row,u.value.col).value()):e.spreadsheet.numberToDate(u.value)),"between"==l.comparerType&&(d=h instanceof p&&a(h.value)?e.spreadsheet.numberToDate(s.range(h.value.row,h.value.col).value()):e.spreadsheet.numberToDate(l.to.value)),"lessThan"!=l.comparerType&&"lessThanOrEqualTo"!=l.comparerType||(d=u instanceof p&&a(u.value)?e.spreadsheet.numberToDate(s.range(u.value.row,u.value.col).value()):e.spreadsheet.numberToDate(l.from.value)),i.setOptions({disableDates:function(t){var n,i;return n=u&&u instanceof p&&a(u.value)?s.range(u.value.row,u.value.col).value():u?0|u.value:0,i=h&&h instanceof p&&a(h.value)?s.range(h.value.row,h.value.col).value():h?0|h.value:0,t=0|e.spreadsheet.dateToNumber(t),!e.spreadsheet.validation.validationComparers[l.comparerType](t,n,i)},min:c,max:d})}else i.setOptions({disableDates:null,min:null,max:null});r.open()}function a(e){return e&&null!==e.row&&null!==e.col&&e.row>-1&&e.col>-1}return{edit:function(e){t=e,o()},icon:"calendar"}})),t("_validation_list",(function(){var t,i,r;function o(){i||(i=n("<ul class='k-list k-reset'/>").kendoStaticList({template:"#:value#",selectable:!0,autoBind:!1}),r=n("<div class='k-spreadsheet-list-popup'>").kendoPopup(),i.appendTo(r),r=r.getKendoPopup(),(i=i.getKendoStaticList()).bind("change",(function(){r.close();var e=i.value()[0];e&&t.callback(e.value)}))),r.setOptions({anchor:t.view.element.querySelector(".k-spreadsheet-editor-button"),origin:t.alignLeft?"bottom right":"bottom left",position:t.alignLeft?"top right":"top left"});var o=t.validation.from.value,a=[],s=function(e){a.push({value:e})};o instanceof e.spreadsheet.calc.runtime.Matrix?o.each(s):(o+"").split(/\s*,\s*/).forEach(s);var l=new e.data.DataSource({data:a});i.setDataSource(l),l.read(),r.open()}return{edit:function(e){t=e,o()},icon:"caret-alt-down"}}))}(window.kendo),function(e){var t=e.jQuery,n=e._outerWidth,i=".",r=" ",o=e.ui.Widget.extend({init:function(t,n){var r=o.classNames;e.ui.Widget.call(this,t,n),(t=this.element).addClass(r.sheetsBarWrapper),this._openDialog=n.openDialog,this._addButton(),this._menuButton(),this._tree=new e.dom.Tree(t[0]),this._tree.render([this._createSheetsWrapper([])]),this._initSheetDropDownButtons(),this._toggleScrollEvents(!0),this._createSortable(),this._sortable.bind("start",this._onSheetReorderStart.bind(this)),this._sortable.bind("end",this._onSheetReorderEnd.bind(this)),t.on("click","[ref-sheetsbar-more-button]",this._onSheetContextMenu.bind(this)),t.on("click","li",this._onSheetSelect.bind(this)),t.on("dblclick","li."+r.sheetsBarKItem+i+r.sheetsBarKItem,this._createEditor.bind(this))},options:{name:"SheetsBar",scrollable:{distance:200}},events:["select","reorder","rename"],_createEditor:function(){this._editor||(this._renderSheets(this._sheets,this._selectedIndex,!0),this._editor=this.element.find(e.format("input{0}{1}",i,o.classNames.sheetsBarEditor)).trigger("focus").on("keydown",this._onEditorKeydown.bind(this)).on("blur",this._onEditorBlur.bind(this)))},_destroyEditor:function(e){var t=e?null:this._editor.val();this._editor.off(),this._editor=null,this._renderSheets(this._sheets,this._selectedIndex,!1),this._onSheetRename(t)},renderSheets:function(e,t){!e||t<0||this._renderSheets(e,t,!1)},_renderSheets:function(t,n,i){var a=this,s=o.classNames;(a._isRtl=e.support.isRtl(a.element),a._sheets=t,a._selectedIndex=n,a._renderHtml(i,!0),a._scrollableAllowed())&&(a._sheetsWrapper().addClass(s.sheetsBarScrollable+r+s.sheetsBarSheetsWrapper),a._toggleScrollButtons())},_toggleScrollButtons:function(t){var n=this,r=n._sheetsGroup(),a=n._sheetsWrapper(),s=e.scrollLeft(r),l=a.find(i+o.classNames.sheetsBarPrev),c=a.find(i+o.classNames.sheetsBarNext);!1===t?(l.addClass("k-disabled"),c.addClass("k-disabled")):(l.toggleClass("k-disabled",!(n._isRtl?s<r[0].scrollWidth-r[0].offsetWidth-1:0!==s)),c.toggleClass("k-disabled",!(n._isRtl?0!==s:s<r[0].scrollWidth-r[0].offsetWidth-1)))},_toggleScrollEvents:function(e){var t,n,r=this,a=o.classNames,s=r.options,l=r._sheetsWrapper();t=l.find(i+a.sheetsBarPrev),n=l.find(i+a.sheetsBarNext),e?(t.on("mousedown",(function(e){e.preventDefault(),e.stopPropagation(),r._nowScrollingSheets=!0,r._scrollSheetsByDelta(s.scrollable.distance*(r._isRtl?1:-1))})),n.on("mousedown",(function(e){e.preventDefault(),e.stopPropagation(),r._nowScrollingSheets=!0,r._scrollSheetsByDelta(s.scrollable.distance*(r._isRtl?-1:1))})),t.add(n).on("mouseup",(function(){r._nowScrollingSheets=!1}))):(t.off(),n.off())},_renderHtml:function(n,i){var a,s=[],l=e.dom,c=l.element,d=this._sheets,u=this._selectedIndex,h=o.classNames;for(a=0;a<d.length;a++){var p=d[a],f=a===u,m={className:h.sheetsBarKItem+r,role:"tab"},g=[];if("visible"!==p.state()&&(m.className+="k-hidden "),f&&(m.className+=h.sheetsBarKActive),f&&n)g.push(c("input",{type:"text",value:p.name(),className:h.sheetsBarKTextbox+r+h.sheetsBarEditor,maxlength:50},[]));else{g.push(c("span",{className:h.sheetsBarKLink,title:p.name()},[c("span",{className:h.sheetsBarKLinkText},[l.text(p.name())])]));let n=c(t(e.html.renderButton(t(`<button ref-sheetsbar-more-button data-sheet-name="${p.name()}" class="k-menu-button"></button>`),{icon:h.sheetsBarMoreIcon,fillMode:"flat"}))[0]);g.push(c("span",{className:"k-item-actions","data-type":"context-menu"},[n]))}s.push(c("li",m,g))}e.destroy(this._sheetsWrapper()),this._addButton(),this._menuButton(),this._tree.render([this._createSheetsWrapper(s,i)]),this._initSheetDropDownButtons()},_initSheetDropDownButtons:function(){let e=this;this.element.find("[ref-sheetsbar-more-button]").each((function(n,i){let r=t(i),a=e._sheets||[],s=a.filter((e=>"visible"===e.state())),l=!e._sheets||e._sheets&&s.length<2,c=r.data("sheetName"),d=!(l||e._sheets&&n==a.length-1),u=!(l||e._sheets&&0===n);r.kendoDropDownButton({icon:o.classNames.sheetsBarMoreIcon,fillMode:"flat",items:[{text:"Delete",icon:"trash",attributes:{"data-command":"delete","data-sheet-name":c},enabled:!l},{text:"Duplicate",icon:"copy",attributes:{"data-command":"duplicate","data-sheet-name":c}},{text:"Rename",icon:"pencil",attributes:{"data-command":"rename","data-sheet-name":c}},{text:"Hide",icon:"eye-slash",attributes:{"data-command":"hide","data-sheet-name":c},enabled:!l},{text:"Move Right",icon:"arrow-right",attributes:{"data-command":"move-right","data-sheet-name":c},enabled:d},{text:"Move Left",icon:"arrow-left",attributes:{"data-command":"move-left","data-sheet-name":c},enabled:u}],click:e._onSheetContextMenu.bind(e)})}))},_createSheetsWrapper:function(n,i){var a=e.dom.element,s=o.classNames,l=a("div",{className:"k-tabstrip-items-wrapper k-hstack"}),c=[a("ul",{className:s.sheetsBarKReset,role:"tablist"},n),null,null];var d=s.sheetsBarKButton+r+s.sheetsBarKButtonBare+r;return c[1]=a("button",{ariaHidden:"true",tabIndex:-1,className:d+s.sheetsBarPrev},[a(t(e.ui.icon({icon:s.sheetsBarArrowWIcon,iconClass:"k-button-icon"}))[0])]),c[2]=a("button",{ariaHidden:"true",tabIndex:-1,className:d+s.sheetsBarNext},[a(t(e.ui.icon({icon:s.sheetsBarArrowEIcon,iconClass:"k-button-icon"}))[0])]),l.children=c,a("div",{className:s.sheetsBarItems},[l])},_createSortable:function(){var n=o.classNames;this._sortable=new e.ui.Sortable(this.element,{filter:`ul li.${n.sheetsBarKItem}`,container:i+n.sheetsBarItems,axis:"x",animation:!1,ignore:"input",end:function(){this.draggable.hint&&this.draggable.hint.remove()},hint:function(e){return t(e).clone().attr("ref-sheetsbar-sortable-hint","").wrap("<div class='"+n.sheetsBarHintWrapper+"'><ul class='"+n.sheetsBarKResetItems+"'></ul></div>").closest("div")}})},_onEditorKeydown:function(e){this._editor&&(13===e.which&&this._destroyEditor(),27===e.which&&this._destroyEditor(!0))},_onEditorBlur:function(){this._editor&&this._destroyEditor()},_onSheetReorderEnd:function(e){e.preventDefault(),this.trigger("reorder",{oldIndex:e.oldIndex,newIndex:e.newIndex})},_onSheetReorderStart:function(e){this._editor&&e.preventDefault()},_onSheetContextMenu:function(e){let n=t(e.target).closest("li").data("sheetName"),i=t(e.target).closest("li").data("command");if(this._editor&&this._destroyEditor(),n&&i)switch(i){case"delete":this._onSheetRemove(e);break;case"duplicate":this._onSheetDuplicate(n);break;case"rename":this._renamePrompt(n);break;case"hide":this._hideSheet(n);break;case"move-right":this._moveSheet(n,1);break;case"move-left":this._moveSheet(n,-1)}},_onSheetDuplicate:function(e){this.trigger("duplicate",{name:e})},_renamePrompt:function(e){let t=this._sheets.findIndex((t=>t.name()==e)),n=function(n){let i=n.sender;i._newSheetName&&i._newSheetName!==e&&this.trigger("rename",{name:i._newSheetName,sheetIndex:t})}.bind(this);this._openDialog("renameSheet",{close:n,_oldSheetName:e})},_hideSheet:function(e){this.trigger("hide",{name:e})},_moveSheet:function(e,t){let n=this._sheets.findIndex((t=>t.name()===e)),i=n+t;i<0||i>=this._sheets.length||this.trigger("reorder",{oldIndex:n,newIndex:i})},_onSheetRemove:function(e){var n=t(e.target).closest("li").data("sheetName");this._editor&&this._destroyEditor();var i=function(e){e.sender.isConfirmed()&&this.trigger("remove",{name:n,confirmation:!0})}.bind(this);this._openDialog("confirmation",{close:i})},_onSheetSelect:function(e){var n=t(e.target).text();!t(e.target).is(i+o.classNames.sheetsBarEditor)&&n?(this._editor&&this._destroyEditor(),this._scrollSheetsToItem(t(e.target).closest("li")),this.trigger("select",{name:n,isAddButton:!1})):e.preventDefault()},_onSheetRename:function(e){this._sheets[this._selectedIndex].name()!==e&&null!==e&&this.trigger("rename",{name:e,sheetIndex:this._selectedIndex})},_onAddSelect:function(e){e.sender.element.removeClass("k-focus"),this.trigger("select",{isAddButton:!0})},_onMenuSelect:function(e){let n=t(e.target).closest("li").data("sheetName");n&&this.trigger("show",{name:n})},_addButton:function(){var n=o.classNames;let i=this.element.find("."+n.sheetsBarAdd);i.length?e.destroy(i):i=t(`<button class="${n.sheetsBarAdd}" aria-label="Add new sheet"></button>`).appendTo(this.element),i.kendoButton({icon:n.sheetsBarPlusIcon,fillMode:"flat",click:this._onAddSelect.bind(this)})},_menuButton:function(){var n=o.classNames;let i=this.element.find("."+n.sheetsBarSheetsMenu);i.length?e.destroy(i):i=t(`<button class="${n.sheetsBarSheetsMenu}"></button>`).appendTo(this.element),i.kendoDropDownButton({icon:n.sheetsBarMenuIcon,fillMode:"flat",items:(this._sheets||[]).map((e=>({text:e.name(),attributes:{"data-sheet-name":e.name()},icon:"visible"===e.state()?"eye":"eye-slash",cssClass:n}))),click:this._onMenuSelect.bind(this)})},destroy:function(){this._sortable.destroy()},_scrollableAllowed:function(){var e=this.options;return e.scrollable&&!isNaN(e.scrollable.distance)},_scrollSheetsToItem:function(t){var i,r=this,o=r._sheetsGroup(),a=e.scrollLeft(o),s=n(t),l=r._isRtl?t.position().left:t.position().left-o.children().first().position().left,c=o[0].offsetWidth;r._isRtl?l<0?i=a+l-(c-a):l+s>c&&(i=a+l-s):a+c<l+s?i=l+s-c:a>l&&(i=l),o.finish().animate({scrollLeft:i},"fast","linear",(function(){r._toggleScrollButtons()}))},_sheetsGroup:function(){return this._sheetsWrapper().find("ul")},_sheetsWrapper:function(){return this.element.find(i+o.classNames.sheetsBarItems)},_scrollSheetsByDelta:function(t){var n=this,i=n._sheetsGroup(),r=e.scrollLeft(i);i.finish().animate({scrollLeft:r+t},"fast","linear",(function(){n._nowScrollingSheets?n._scrollSheetsByDelta(t):n._toggleScrollButtons()}))}});e.spreadsheet.SheetsBar=o,t.extend(!0,o,{classNames:{sheetsBarWrapper:"k-spreadsheet-sheets-bar",sheetsBarSheetsWrapper:"k-tabstrip k-tabstrip-bottom",sheetsBarAdd:"k-spreadsheet-sheet-add",sheetsBarSheetsMenu:"k-spreadsheet-sheets-menu",sheetsBarRemove:"k-spreadsheet-sheets-remove",sheetsBarItems:"k-spreadsheet-sheets",sheetsBarEditor:"k-spreadsheet-sheets-editor",sheetsBarScrollable:"k-tabstrip-scrollable",sheetsBarNext:"k-tabstrip-next",sheetsBarPrev:"k-tabstrip-prev",sheetsBarKItem:"k-item",sheetsBarKActive:"k-active",sheetsBarKTextbox:"k-textbox",sheetsBarKLink:"k-link",sheetsBarKLinkText:"k-link-text",sheetsBarKIcon:"k-icon",sheetsBarKFontIcon:"k-icon",sheetsBarKButton:"k-button k-icon-button",sheetsBarKButtonDefaults:"k-button-md k-rounded-md k-button-solid k-button-solid-base",sheetsBarKButtonBare:"k-button-md k-rounded-md k-button-flat k-button-flat-base",sheetsBarArrowWIcon:"caret-alt-left",sheetsBarArrowEIcon:"caret-alt-right",sheetsBarKReset:"k-reset k-tabstrip-items k-tabstrip-items-start",sheetsBarXIcon:"x",sheetsBarMoreIcon:"caret-alt-down",sheetsBarKSprite:"k-sprite",sheetsBarPlusIcon:"plus",sheetsBarMenuIcon:"menu",sheetsBarHintWrapper:"k-widget k-tabstrip k-tabstrip-bottom k-spreadsheet-sheets-items-hint",sheetsBarKResetItems:"k-reset k-tabstrip-items k-tabstrip-items-start"}})}(window.kendo),function(e){var t=e.jQuery,n=e.ui.Widget,i={details:"k-details",button:"k-button",detailsSummary:"k-details-summary",detailsContent:"k-details-content",icon:"k-icon",iconCollapseName:"caret-br",iconExpandName:"caret-alt-right",iconSearchName:"search",textbox:"k-textbox",wrapper:"k-spreadsheet-filter-menu",filterByCondition:"k-spreadsheet-condition-filter",filterByValue:"k-spreadsheet-value-filter",valuesTreeViewWrapper:"k-spreadsheet-value-treeview-wrapper",actionButtons:"k-actions"};e.spreadsheet.messages.filterMenu={all:"All",sortAscending:"Sort range A to Z",sortDescending:"Sort range Z to A",filterByValue:"Filter by value",filterByCondition:"Filter by condition",apply:"Apply",search:"Search",addToCurrent:"Add to current selection",clear:"Clear",blanks:"(Blanks)",operatorNone:"None",and:"AND",or:"OR",operators:{string:{contains:"Text contains",doesnotcontain:"Text does not contain",startswith:"Text starts with",endswith:"Text ends with",matches:"Text matches",doesnotmatch:"Text does not match"},date:{eq:"Date is",neq:"Date is not",lt:"Date is before",gt:"Date is after"},number:{eq:"Is equal to",neq:"Is not equal to",gte:"Is greater than or equal to",gt:"Is greater than",lte:"Is less than or equal to",lt:"Is less than"}}};var r=n.extend({init:function(i,r){n.fn.init.call(this,i,r),this.element.addClass(u.classNames.details),this._summary=this.element.find("."+u.classNames.detailsSummary).on("click",this._toggle.bind(this));var o=r.expanded?u.classNames.iconCollapseName:u.classNames.iconExpandName;this._icon=t(e.ui.icon(o)).prependTo(this._summary),this._container=e.wrap(this._summary.next(),!0),r.expanded||this._container.hide()},options:{name:"Details"},events:["toggle"],visible:function(){return this.options.expanded},toggle:function(t){e.fx(this._container).expand("vertical").stop()[t?"reverse":"play"](),e.ui.icon(this._icon,{icon:t?u.classNames.iconExpandName:u.classNames.iconCollapseName}),this.options.expanded=!t},_toggle:function(){var e=this.visible();this.toggle(e),this.trigger("toggle",{show:e})}});e.data.binders.spreadsheetFilterValue=e.data.Binder.extend({init:function(n,i,r){e.data.Binder.fn.init.call(this,n,i,r),this._change=this.change.bind(this),t(this.element).on("change",this._change)},refresh:function(){var e=this.bindings.spreadsheetFilterValue.get();t(this.element).val(e instanceof Date?"":e)},change:function(){var e=this.element.value;this.bindings.spreadsheetFilterValue.set(e)}}),e.data.binders.widget.spreadsheetFilterValue=e.data.Binder.extend({init:function(t,n,i){e.data.Binder.fn.init.call(this,t.element[0],n,i),this.widget=t,this._change=this.change.bind(this),this.widget.first("change",this._change)},refresh:function(){var e=this.bindings.spreadsheetFilterValue.get(),n=t(this.widget.element).data("filterType");"date"===n&&e instanceof Date||"number"===n&&!isNaN(e)?this.widget.value(e):this.widget.value(null)},change:function(){var e=this.widget.value();this.bindings.spreadsheetFilterValue.set(e)}});var o={filterByValue:t=>`<div class='${i.detailsSummary}'>${t.messages.filterByValue}</div><div class='${i.detailsContent}'><div class='k-searchbox k-input k-input-md k-rounded-md k-input-solid'>`+e.ui.icon({icon:"search",iconClass:"k-input-icon"})+`<input class='k-input-inner' autocomplete='off' placeholder='${t.messages.search}' data-${t.ns}bind='events: { input: filterValues }' /></div>`+`<div data-${t.ns}bind='visible: hasActiveSearch'><input class='k-checkbox k-checkbox-md k-rounded-md' type='checkbox' data-${t.ns}bind='checked: appendToSearch' id='_${t.guid}'/><label class='k-checkbox-label' for='_${t.guid}'>${t.messages.addToCurrent}</label></div>`+`<div class='${i.valuesTreeViewWrapper}'>`+`<div data-${t.ns}role='treeview' `+`bind:data-${t.ns}checkboxes='checkboxesConfig' `+`data-${t.ns}bind='source: valuesDataSource, events: { check: valuesChange, select: valueSelect }' ></div></div></div>`,filterByCondition:e=>`<div class='${i.detailsSummary}'>${e.messages.filterByCondition}</div><div class='${i.detailsContent}'><div><select aria-label="${e.messages.filterByCondition}" data-${e.ns}role="dropdownlist"data-${e.ns}bind="value: operator, source: operators, events: { change: operatorChange } "data-${e.ns}value-primitive="false"data-${e.ns}option-label="${e.messages.operatorNone}"data-${e.ns}height="auto"data-${e.ns}text-field="text"data-${e.ns}value-field="unique"></select></div><div data-${e.ns}bind="visible: isString"><input aria-label="string-value" data-filter-type="string" data-${e.ns}bind="spreadsheetFilterValue: customFilter.criteria[0].value" class="k-textbox" /></div><div data-${e.ns}bind="visible: isNumber"><input aria-label="number-value" data-filter-type="number" data-${e.ns}role="numerictextbox" data-${e.ns}bind="spreadsheetFilterValue: customFilter.criteria[0].value" /></div><div data-${e.ns}bind="visible: isDate"><input aria-label="date-value" data-filter-type="date" data-${e.ns}role="datepicker" data-${e.ns}bind="spreadsheetFilterValue: customFilter.criteria[0].value" /></div></div>`,menuItem:t=>`<li data-command='${t.command}' data-dir='${t.dir}'>${e.ui.icon(t.iconClass)}${t.text}</li>`,actionButtons:e=>`<button data-${e.ns}bind='click: apply' class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary'><span class='k-button-text'>${e.messages.apply}</span></button><button data-${e.ns}bind='click: clear' class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base'><span class='k-button-text'>${e.messages.clear}</span></button>`};function a(t,n){for(var i=!1,r=t instanceof e.data.HierarchicalDataSource&&t.data(),o=this.values,s=0;s<r.length;s++){var l=r[s],c=l.text.toString().toLocaleLowerCase(e.culture().name),d=!0===n||""===n||c.indexOf(n)>=0,u=a.bind(this)(l.children,n);i=i||u||d,l.hidden=!d&&!u,n.length||o&&!o.length?l.checked=!l.hidden:o&&-1!=o.indexOf(l.text)&&(l.checked=!0)}return r&&t.filter({field:"hidden",operator:"neq",value:!0}),i}function s(t){for(var n=t instanceof e.data.HierarchicalDataSource&&t.data(),i=0;i<n.length;i++){var r=n[i];r.checked=!1,r.hasChildren&&s(r.children)}}var l=e.spreadsheet.FilterMenuViewModel=e.data.ObservableObject.extend({valuesChange:function(t){var n=(t?t.sender.dataSource:this.valuesDataSource).data().toJSON()[0].items,i=n.filter((function(e){return"blank"===e.dataType}));i=!!i.length&&i[0].checked,n=n.filter((function(e){return e.checked})).map((function(t){return"date"===t.dataType?e.spreadsheet.dateToNumber(t.value):t.value})),this.appendToSearch&&this.valueFilter&&this.valueFilter.values.length&&(n=n.concat(this.valueFilter.values.toJSON()).sort().filter((function(e,t,n){return n.lastIndexOf(e)===t}))),this.set("valueFilter",{values:n,blanks:i})},valueSelect:function(e){e.preventDefault();var t=e.sender.dataItem(e.node);t.set("checked",!t.checked)},hasActiveSearch:!1,appendToSearch:!1,filterValues:function(n){var i="string"==typeof n?n:t(n.target).val().toLocaleLowerCase(e.culture().name),r=this.valuesDataSource;this.set("hasActiveSearch",!!i);var o=a.bind(this.valueFilter);s(r),o(r,i)},reset:function(){this.set("customFilter",{logic:"and",criteria:[{operator:null,value:null}]}),this.set("valueFilter",{values:[]})},operatorChange:function(e){var t=e.sender.dataItem();this.set("operatorType",t.type),this.get("customFilter")||this.reset(),this.set("customFilter.criteria[0].operator",t.value)},isNone:function(){return void 0===this.get("operatorType")},isString:function(){return"string"===this.get("operatorType")},isNumber:function(){return"number"===this.get("operatorType")},isDate:function(){return"date"===this.get("operatorType")}});function c(t){var n=e.spreadsheet.messages.filterMenu.operators,i=[];for(var r in t)if(t.hasOwnProperty(r))for(var o in t[r])t[r].hasOwnProperty(o)&&i.push({text:n[r][o],value:o,unique:r+"_"+o,type:r});return i}var d=e.spreadsheet.FilterMenuController={valuesTree:function(t,n){return[{text:e.spreadsheet.messages.filterMenu.all,expanded:!0,checked:!1,items:this.values(t.resize({top:1}),n)}]},values:function(t,n){var i=[],r=e.spreadsheet.messages.filterMenu,o=t.column(n),a=t.sheet();return o.forEachCell((function(t,n,o){var s=!0;a.isHiddenRow(t)&&(s=!1);var l=o.value,c=o.dataType,d=o.text;c=void 0===l?"blank":o.format?e.spreadsheet.formatting.type(l,o.format):typeof l,d=null!==l&&o.format?e.spreadsheet.formatting.text(l,o.format):"blank"==c?r.blanks:l,"percent"!==c&&"currency"!==c||(c="number"),"date"===c&&(l=e.spreadsheet.numberToDate(l)),i.push({dataType:c,value:l,text:d,checked:s})})),i=function(e){for(var t={},n=[],i=0;i<e.length;i++)t[e[i].value]?!t[e[i].value].checked&&e[i].checked&&(t[e[i].value].checked=!0):(t[e[i].value]=e[i],n.push(e[i]));return n}(i),i.sort((function(e,t){return e.dataType===t.dataType?0:"blank"===e.dataType||"blank"===t.dataType?"blank"===e.dataType?-1:1:"number"===e.dataType||"number"===t.dataType?"number"===e.dataType?-1:1:"date"===e.dataType||"date"===t.dataType?"date"===e.dataType?-1:1:0})),i},filterType:function(e,t){var n,i=e.sheet(),r=this.filterForColumn(t,i);if((r=r&&r.filter.toJSON())&&"custom"==r.filter){var o=r.criteria[0].value;o instanceof Date?n="date":"string"==typeof o?n="string":"number"==typeof o&&(n="number")}if(!n){var a=this.values(e.row(1),t)[0];"blank"==(n=a&&a.dataType)&&(n=null)}return n},filterForColumn:function(e,t){var n,i=t.filter();return i&&(n=i.columns.filter((function(t){return t.index===e}))[0]),n},filter:function(e,t){var n=this.filterForColumn(e,t);if(n){var i=n.filter.toJSON(),r=i.filter;delete i.filter;var o={type:r,options:i},a=i.criteria;return a&&a.length&&(o.operator=a[0].operator),o}}},u=n.extend({init:function(e,t){n.call(this,e,t),this.element.addClass(u.classNames.wrapper),this.viewModel=new l({active:"value",checkboxesConfig:{checkChildren:!0},operator:null,operators:c(this.options.operators),clear:this.clear.bind(this),apply:this.apply.bind(this)}),this._filterInit(),this._popup(),this._sort(),this._filterByCondition(),this._filterByValue(),this._actionButtons()},options:{name:"FilterMenu",column:0,range:null,operators:{string:{contains:"Text contains",doesnotcontain:"Text does not contain",startswith:"Text starts with",endswith:"Text ends with",matches:"Text matches",doesnotmatch:"Text does not match"},date:{eq:"Date is",neq:"Date is not",lt:"Date is before",gt:"Date is after"},number:{eq:"Is equal to",neq:"Is not equal to",gte:"Is greater than or equal to",gt:"Is greater than",lte:"Is less than or equal to",lt:"Is less than"}}},events:["action"],destroy:function(){n.fn.destroy.call(this),this.menu.destroy(),this.valuesTreeView.destroy(),this.popup.destroy()},openFor:function(e,n){t(e).hasClass("k-spreadsheet-view-size")?this.popup.open(n.pageX,n.pageY):(this.popup.setOptions({anchor:e}),this.popup.open())},close:function(){this.popup.close()},clear:function(){this.action({command:"ClearFilterCommand",options:{column:this.options.column}}),this.viewModel.reset(),this.close()},apply:function(){this._active();var e,t,n={operatingRange:this.options.range,column:this.options.column};"value"===this.viewModel.active?(this.viewModel.valuesChange({sender:this.valuesTreeView}),((e=this.viewModel.valueFilter.toJSON()).blanks||e.values&&e.values.length)&&(n.valueFilter=e)):"custom"===this.viewModel.active&&(t=this.viewModel.customFilter.toJSON()).criteria.length&&null!==t.criteria[0].value&&(n.customFilter=t),(n.valueFilter||n.customFilter)&&this.action({command:"ApplyFilterCommand",options:n})},action:function(e){this.trigger("action",t.extend({},e))},_filterInit:function(){var e=this.options.column,t=this.options.range,n=t.sheet(),i=d.filter(e,n);if(i){var r=d.filterType(t,e);this.viewModel.set("active",i.type),this.viewModel.set(i.type+"Filter",i.options),"custom"==i.type&&(this.viewModel.set("operator",r+"_"+i.operator),this.viewModel.set("operatorType",r))}else this.viewModel.reset()},_popup:function(){this.popup=this.element.kendoPopup({copyAnchorStyles:!1}).data("kendoPopup")},_sort:function(){var n=e.template(u.templates.menuItem),i=e.spreadsheet.messages.filterMenu,r=[{command:"sort",dir:"asc",text:i.sortAscending,iconClass:"sort-asc"},{command:"sort",dir:"desc",text:i.sortDescending,iconClass:"sort-desc"}],o=t("<ul></ul>",{html:e.render(n,r)}).appendTo(this.element);this.menu=o.kendoMenu({orientation:"vertical",select:function(e){var n={value:t(e.item).data("dir"),sheet:!1,operatingRange:this.options.range.resize({top:1}),column:this.options.column};this.action({command:"SortCommand",options:n})}.bind(this)}).data("kendoMenu")},_appendTemplate:function(n,i,o,a){var s=e.template(n),l=t("<div class='"+i+"'/>").html(s({messages:e.spreadsheet.messages.filterMenu,guid:e.guid(),ns:e.ns}));return this.element.append(l),o&&(o=new r(l,{expanded:a,toggle:this._detailToggle.bind(this)})),e.bind(l,this.viewModel),l},_detailToggle:function(t){this.element.find("["+e.attr("role")+"=details]").not(t.sender.element).data("kendoDetails").toggle(!t.show)},_filterByCondition:function(){var e="custom"===this.viewModel.active;this._appendTemplate(u.templates.filterByCondition,u.classNames.filterByCondition,!0,e)},_filterByValue:function(){var t="value"===this.viewModel.active,n=this._appendTemplate(u.templates.filterByValue,u.classNames.filterByValue,!0,t);this.valuesTreeView=n.find("["+e.attr("role")+"=treeview]").data("kendoTreeView");var i=d.valuesTree(this.options.range,this.options.column);this.viewModel.set("valuesDataSource",new e.data.HierarchicalDataSource({data:i,accentFoldingFiltering:e.culture().name}))},_actionButtons:function(){this._appendTemplate(u.templates.actionButtons,u.classNames.actionButtons,!1)},_active:function(){var n=this.element.find("["+e.attr("role")+"=details]").filter((function(e,n){return t(n).data("kendoDetails").visible()}));n.hasClass(u.classNames.filterByValue)?this.viewModel.set("active","value"):n.hasClass(u.classNames.filterByCondition)&&this.viewModel.set("active","custom")}});e.spreadsheet.FilterMenu=u,t.extend(!0,u,{classNames:i,templates:o})}(window.kendo),function(e){e.spreadsheet.messages.workbook={defaultSheetName:"Sheet"},e.spreadsheet.messages.view={nameBox:"Name Box",formulaInput:"Formula Input",errors:{openUnsupported:"Unsupported format. Please select an .xlsx file.",shiftingNonblankCells:"Cannot insert cells due to data loss possibility. Select another insert location or delete the data from the end of your worksheet.",insertColumnWhenRowIsSelected:"Cannot insert column when all columns are selected.",insertRowWhenColumnIsSelected:"Cannot insert row when all rows are selected.",filterRangeContainingMerges:"Cannot create a filter within a range containing merges",sortRangeContainingMerges:"Cannot sort a range containing merges",cantSortMultipleSelection:"Cannot sort multiple selection",cantSortNullRef:"Cannot sort empty selection",cantSortMixedCells:"Cannot sort range containing cells of mixed shapes",validationError:"The value that you entered violates the validation rules set on the cell.",cannotModifyDisabled:"Cannot modify disabled cells.",insertRowBelowLastRow:"Cannot insert row below the last row.",insertColAfterLastCol:"Cannot insert column to the right of the last column."},tabs:{file:"File",home:"Home",insert:"Insert",format:"Format",data:"Data",view:"View"}},e.spreadsheet.messages.menus={cut:"Cut",copy:"Copy",paste:"Paste",merge:"Merge",unmerge:"Unmerge",delete:"Delete",hide:"Hide",unhide:"Unhide",bringToFront:"Bring to front",sendToBack:"Send to back"}}(window.kendo),function(e){let t=e.jQuery;if(e.PDFMixin){let n=function(e){var n=new t.Deferred,i=function(e){n.resolve(e)};switch(e.area){case"workbook":e.workbook.draw(e,i);break;case"sheet":e.workbook.activeSheet().draw(e,i);break;case"selection":e.workbook.activeSheet().selection().draw(e,i)}return n.promise()},i=function(r){-1===this.events.indexOf("pdfExport")&&(e.PDFMixin.extend(this),this.saveAsPDF=i,this._drawPDF=n);var o=new t.Deferred,a=o.promise(),s={promise:a};if(!this.trigger("pdfExport",s))return this._drawPDF(r,o).then((function(t){let n=r.forceProxy?e.pdf.exportPDF(t):e.pdf.exportPDFToBlob(t);return e.convertPromiseToDeferred(n)})).done((function(t){e.saveAs({dataURI:t,fileName:r.fileName,proxyURL:r.proxyURL,forceProxy:r.forceProxy,proxyTarget:r.proxyTarget}),o.resolve()})).fail((function(e){o.reject(e)})),a};e.spreadsheet.Workbook.prototype.saveAsPDF=i,e.spreadsheet.Workbook.prototype._drawPDF=n}}(kendo);!function(e,t){if(e.support.browser.msie&&e.support.browser.version<9)return;const n="k-active";let i=e.jQuery,r=e.ui.Widget,o=".kendoSpreadsheet",a=e.spreadsheet.commonEngine,s=e.spreadsheet.FormulaInput,l=e.spreadsheet.SheetsBar;function c(e){return e.map((function(e){return'[data-action="'+e+'"]'})).join(",")}let d=c(["cut","copy","paste","insert-left","insert-right","insert-above","insert-below"]),u=c(["unhide-row","unhide-column"]),h=a.View.classNames;e.spreadsheet.ContextMenu=e.ui.ContextMenu;let p=e.ui.StaticList.extend({data:function(e){return this.dataSource.data(e)},itemClick:function(e){this.bind("change",(function(t){e(this.value()[0])}))}});class f{constructor({list:e,popup:t}){this.current={list:e,popup:t},this.clone=function(){return this}}}class m{constructor({nameEditor:e,container:n}){let i=this.initializeComboBox(n,e);this.current={value:e=>{if(e===t){const e=i.value();return e&&e.name||e}i.value(e||"")}},this.nameEditor=e,this.clone=function(){return this}}initializeComboBox(t){let n=this,r=new e.data.DataSource({transport:{read:function(e){let t=n.nameEditor()?.readData()||[];e.success(t)},cache:!1}}),o=i(t).kendoComboBox({clearButton:!1,dataTextField:"name",dataValueField:"name",template:({name:t})=>`${e.htmlEncode(t)}<a role='button' class='k-button-delete' href='\\#'>${e.ui.icon("x")}</a>`,dataSource:r,autoBind:!1,ignoreCase:!0,change:n.onChange.bind(n),noDataTemplate:()=>"<div></div>",open:function(){r.read()}}).data("kendoComboBox");return o.input.on("keydown",n.onKeyDown.bind(this)),o.popup.element.addClass("k-spreadsheet-names-popup").on("mousemove",(function(e){e.stopPropagation()})).on("click",".k-button-delete",(function(e){e.preventDefault(),e.stopPropagation();let t=i(e.target).closest(".k-list-item");t=o.dataItem(t),n.onDelete(t.name)})),o}onChange(e){const t=this.nameEditor();t&&e.sender.value()&&t.trigger("select",{name:e.sender.value()})}onDelete(e){this.nameEditor()?.trigger("delete",{name:e})}onKeyDown(e){const t=this.nameEditor();if(t)if("Enter"===e.key){const n=e.target.value;t.trigger("enter",{value:n})}else"Escape"===e.key&&t.trigger("cancel")}}let g=e.ui.Widget.extend({_renderInnerContent:function(t){i(t).append((({messages:t})=>`\n                            <div ref-header-container class="k-spreadsheet-header"><div ref-header-menu></div><div ref-header-toolbar></div></div>\n                            <div class="k-spreadsheet-action-bar">\n                                <div class="k-spreadsheet-name-editor">\n                                    <input ref-namebox-input title="${t.nameBox||"Name Box"}" aria-label="${t.nameBox||"Name Box"}"></input>\n                                </div>\n                                <div class="k-spreadsheet-formula-bar">\n                                    ${e.ui.icon("formula-fx")}\n                                    <div class="k-spreadsheet-formula-input"\n                                        role="combobox"\n                                        title="${t.view.formulaInput}"\n                                        aria-haspopup="menu"\n                                        aria-expanded="false"\n                                        contentEditable="true"\n                                        spellCheck="false">\n                                    </div>\n                                </div>\n                            </div>\n                            <div class="k-spreadsheet-view">\n                                <div class="k-spreadsheet-fixed-container"></div>\n                                <div class="k-spreadsheet-scroller">\n                                    <div class="k-spreadsheet-view-size"></div>\n                                </div>\n                                <div tabIndex="0" class="k-spreadsheet-clipboard" contentEditable="true" ></div>\n                                <div contentEditable="true"\n                                    spellCheck="false"\n                                    role="combobox"\n                                    title="${t.view.formulaInput}"\n                                    aria-haspopup="menu"\n                                    aria-expanded="false"\n                                    class="k-spreadsheet-formula-input k-spreadsheet-cell-editor">\n                                </div>\n                            </div>\n                            <div ref-sheets-bar></div>`)(this.options))},init:function(t,n){let a=this;r.fn.init.call(this,t,n),this.options.messages=i.extend(!0,{view:e.spreadsheet.messages.view,tabs:e.spreadsheet.messages.view.tabs,menus:e.spreadsheet.messages.menus,workbook:{defaultSheetName:"Sheet"}},this.options.messages),this.element.addClass(g.classNames.wrapper),this.element.attr("role","application"),this._renderInnerContent(this.element),this._createFormulaInputs(),a.spreadsheetRef=this._initSpreadsheetWidget(),this._bindWorkbookEvents();const s=this.activeSheet();this._onUpdateTools({range:s.range(s.activeCell())}),this._resizeHandler=function(){a.resize()},i(window).on("resize"+o,this._resizeHandler),this._showWatermarkOverlay&&this._showWatermarkOverlay(this.element[0])},_initSpreadsheetWidget:function(){let t=this,n=i.extend({},t.options,{sheetsbar:0!=t.options.sheetsbar?t.options.sheetsbar:{},formulaBarInputRef:new f({list:this._formulaBarInputRefList,popup:this._formulaBarInputRefPopup}),formulaCellInputRef:new f({list:this._formulaCellInputRefList,popup:this._formulaCellInputRefPopup}),nameBoxRef:new m({container:t.element.find(".k-spreadsheet-name-editor [ref-namebox-input]"),nameEditor:function(){return t.spreadsheetRef?.view.nameEditor}}),createFilterMenu:function(n){let r=i("<div></div>").appendTo(t.element);return new e.spreadsheet.FilterMenu(r,n)},createTabStrip:function(e){if(t.options.toolbar)return t._initHeader(),{focus:function(){t.menu.wrapper.trigger("focus")},select:function(e){t.menu.element.find(`li[ref-tab-name="${e}"]`).click()},destroy:function(){t.menu.destroy()}}},createSheetEditor:function(e){t.sheetsBar._createEditor()},createSheetBar:function(e){t._sheetsBar(e)},createContextMenus:function(e){t._dialogs=[],t._initContextMenus()},createSheetDataSource:function(t){return e.data.DataSource.create(t)},getWorkbookCommand:function(t,n){return new e.spreadsheet[t](n)},getIconHTMLString:function(t){return i(e.ui.icon(t))[0]},update:function(e){t._onUpdateTools(e),e.reason.sheetSelection&&t.sheetsBar&&t.sheetsBar.renderSheets(e.sender.sheets(),e.sender.sheetIndex(e.sheet))},message:n=>{let{sender:r,name:o,ref:a,range:s,...l}=n,c=i.extend({},{pdfExport:t.options.pdf,excelExport:t.options.excel},l),d=e.spreadsheet.dialogs.create(n.name,c);d&&(d.bind("action",(function(n){if("SaveAsCommand"==n.command){let{sender:r,...o}=n,a=n.options.name+n.options.extension;if(".xlsx"===n.options.extension)return t.spreadsheetRef.saveAsExcel(i.extend(o,{fileName:a,Workbook:e.ooxml.Workbook,saveAs:function(t,n,i){e.saveAs({dataURI:t,fileName:n,...i})}}));if(".pdf"===this.options.extension)return t.spreadsheetRef.saveAsPDF(i.extend(n.options.pdf,{workbook:this.options.workbook,fileName:a}))}t.spreadsheetRef.executeCommand(n)})),d.bind("deactivate",(()=>{d.destroy(),t._dialogs.pop()})),t._dialogs.push(d),d.open(n.range,n),n.dialog=d)},contextmenu:e=>{const{objectRef:t,targetType:n,showUnhide:i,showUnmerge:r,originalEvent:o,isComposite:a}=e,s=e.sender.activeSheet().select(),{topLeft:l,bottomRight:c}=s;let h;this.cellContextMenu.close(),this.colHeaderContextMenu.close(),this.rowHeaderContextMenu.close(),this.drawingContextMenu.close(),h="columnheader"==n?this.colHeaderContextMenu:"rowheader"==n?this.rowHeaderContextMenu:"drawing"==n?this.drawingContextMenu:this.cellContextMenu,h.element.find(d).toggle(!a),h.element.find(u).toggle(i),h.element.find("[data-action=unmerge]").toggle(r),setTimeout((function(){h.open(e.originalEvent.pageX,e.originalEvent.pageY)}))},locale:e.cultures.current.name,intl:e.kendoCultureToIntl()});return new e.spreadsheet.commonEngine.SpreadsheetWidget(this.element[0],n)},_createFormulaInputs:function(){let t=this.element.find(".k-spreadsheet-action-bar .k-spreadsheet-formula-input"),n=e.guid();t.attr("aria-controls",n),this._formulaBarInputRefList=new p(i(`<ul id="${n}" />`).addClass(s.classNames.listWrapper).insertAfter(t),{aria:{role:"menu",itemRole:"menuitem"},autoBind:!1,selectable:!0,dataTextField:"text",dataValueField:"value",template:({text:e,value:t})=>`${e||t}`}),this._formulaBarInputRefList.element.on("mousedown",(function(e){e.preventDefault()})),this._formulaBarInputRefPopup=new e.ui.Popup(this._formulaBarInputRefList.element,{anchor:this.element.find(".k-spreadsheet-formula-input:not(.k-spreadsheet-cell-editor)"),open:function(e){t.attr("aria-expanded",!0)},close:function(e){t.attr("aria-expanded",!1)}});let r=this.element.find(".k-spreadsheet-cell-editor"),o=e.guid();r.attr("aria-controls",o),this._formulaCellInputRefList=new p(i(`<ul id="${o}" />`).addClass(s.classNames.listWrapper).insertAfter(r),{aria:{role:"menu",itemRole:"menuitem"},autoBind:!1,selectable:!0,dataValueField:"value",dataTextField:"text",template:({text:e,value:t})=>`${e||t}`}),this._formulaCellInputRefList.element.on("mousedown",(function(e){e.preventDefault()})),this._formulaCellInputRefPopup=new e.ui.Popup(this._formulaCellInputRefList.element,{anchor:this.element.find("."+a.View.classNames.cellEditor),open:function(e){r.attr("aria-expanded",!0)},close:function(e){r.attr("aria-expanded",!1)}})},_initContextMenus:function(){let t=this,n={target:this.element,animation:!1,showOn:"never"};this.cellContextMenu=new e.spreadsheet.ContextMenu(i((({messages:e})=>`\n                    <ul class="${h.cellContextMenu}">\n                        <li data-action="cut">${e.menus.cut}</li>\n                        <li data-action="copy">${e.menus.copy}</li>\n                        <li data-action="paste">${e.menus.paste}</li>\n                        <li class="k-separator"></li>\n                        <li data-action="merge">${e.menus.merge}</li>\n                        <li data-action="unmerge">${e.menus.unmerge}</li>\n                    </ul>`)(t.options)).appendTo(t.element),n),this.colHeaderContextMenu=new e.spreadsheet.ContextMenu(i((({messages:e})=>`\n                    <ul class="${h.colHeaderContextMenu}">\n                        <li data-action="cut">${e.menus.cut}</li>\n                        <li data-action="copy">${e.menus.copy}</li>\n                        <li data-action="paste">${e.menus.paste}</li>\n                        <li class="k-separator"></li>\n                        <li data-action="delete-column">${e.menus.delete}</li>\n                        <li data-action="hide-column">${e.menus.hide}</li>\n                        <li data-action="unhide-column">${e.menus.unhide}</li>\n                    </ul>`)(t.options)).appendTo(t.element),n),this.rowHeaderContextMenu=new e.spreadsheet.ContextMenu(i((({messages:e})=>`\n                    <ul class="${h.rowHeaderContextMenu}">\n                        <li data-action="cut">${e.menus.cut}</li>\n                        <li data-action="copy">${e.menus.copy}</li>\n                        <li data-action="paste">${e.menus.paste}</li>\n                        <li class="k-separator"></li>\n                        <li data-action="delete-row">${e.menus.delete}</li>\n                        <li data-action="hide-row">${e.menus.hide}</li>\n                        <li data-action="unhide-row">${e.menus.unhide}</li>\n                    </ul>`)(t.options)).appendTo(t.element),n),this.drawingContextMenu=new e.spreadsheet.ContextMenu(i((({messages:e})=>`\n                    <ul class="${h.drawingContextMenu}">\n                        <li data-action="bring-to-front">${e.menus.bringToFront}</li>\n                        <li data-action="send-to-back">${e.menus.sendToBack}</li>\n                        <li class="k-separator"></li>\n                        <li data-action="delete-drawing">${e.menus.delete}</li>\n                    </ul>`)(t.options)).appendTo(t.element),n),this.cellContextMenu.bind("select",this.onContextMenuSelect.bind(this)),this.rowHeaderContextMenu.bind("select",this.onContextMenuSelect.bind(this)),this.colHeaderContextMenu.bind("select",this.onContextMenuSelect.bind(this)),this.drawingContextMenu.bind("select",this.onContextMenuSelect.bind(this))},onContextMenuSelect:function(e){let t,n=this;switch(i(e.item).data("action")){case"cut":t={command:"ToolbarCutCommand",options:{workbook:this.spreadsheetRef.workbook}};break;case"copy":t={command:"ToolbarCopyCommand",options:{workbook:this.spreadsheetRef.workbook}};break;case"paste":t={command:"ToolbarPasteCommand",options:{workbook:this.spreadsheetRef.workbook}};break;case"delete-drawing":t={command:"DeleteDrawingCommand",options:{drawing:this.spreadsheetRef._controller.navigator._sheet._activeDrawing}};break;case"bring-to-front":t={command:"BringToFrontCommand",options:{drawing:this.spreadsheetRef._controller.navigator._sheet._activeDrawing}};break;case"send-to-back":t={command:"SendToBackCommand",options:{drawing:this.spreadsheetRef._controller.navigator._sheet._activeDrawing}};break;case"unmerge":t={command:"MergeCellCommand",options:{value:"unmerge"}};break;case"merge":this.spreadsheetRef.openDialog("merge");break;case"hide-row":t={command:"HideLineCommand",options:{axis:"row"}};break;case"hide-column":t={command:"HideLineCommand",options:{axis:"column"}};break;case"unhide-row":t={command:"UnHideLineCommand",options:{axis:"row"}};break;case"unhide-column":t={command:"UnHideLineCommand",options:{axis:"column"}};break;case"delete-row":t={command:"DeleteRowCommand"};break;case"delete-column":t={command:"DeleteColumnCommand"}}t&&n.spreadsheetRef.executeCommand(t)},_onUpdateTools:function(e){let t=e.reason;t&&(t.overElement||t.comment)||this.toolbar?.refresh(e.range)},_getCopyRegex:function(e){const t=e.replaceAll("(","\\(").replaceAll(")","\\)");return new RegExp(`(${t})\\s?\\(`,"s")},_sheetsBar:function(e){let t=this;if(t.options.sheetsbar){let n=i.extend(!0,{openDialog:e},t.options.sheetsbar);t.sheetsBar=new l(t.element[0].querySelector("[ref-sheets-bar]"),n),t.sheetsBar.bind("select",(function(e){e.isAddButton?t.spreadsheetRef.view.sheetsbar.onAddSelect():t.spreadsheetRef.view.sheetsbar.onSheetSelect(e.name)})),t.sheetsBar.bind("reorder",(function(e){t.spreadsheetRef.view.sheetsbar.onSheetReorderEnd(e)})),t.sheetsBar.bind("rename",(function(e){t.spreadsheetRef.view.sheetsbar.onSheetRename(e.name,e.sheetIndex)})),t.sheetsBar.bind("duplicate",(function(e){let n=e.name,i=t.sheetByName(n),r=t.sheetIndex(i),o=0;const a=t._getCopyRegex(n);t.sheets().forEach((e=>{a.test(e.name())&&(o+=1)}));const s=`${n} (${o+1})`;t.insertSheet({data:{...i.toJSON(),name:s},index:r+1}),t.spreadsheetRef.view.sheetsbar.onSheetSelect(s)})),t.sheetsBar.bind("remove",(function(e){t.spreadsheetRef.view.sheetsbar.onSheetRemove(e.name)})),t.sheetsBar.bind("hide",(function(e){let n=e.name,i=t.sheetByName(n),r=t.sheets().filter((e=>"visible"===e.state())),o=r.findIndex((e=>e.name()===n)),a=r[o+1]||r[o-1];i._state("hidden"),t.spreadsheetRef.workbook._sheetsSearchCache={},t.spreadsheetRef.view.sheetsbar.onSheetSelect(a.name())})),t.sheetsBar.bind("show",(function(e){let n=e.name;t.sheetByName(n)._state("visible"),t.spreadsheetRef.workbook._sheetsSearchCache={},t.spreadsheetRef.view.sheetsbar.onSheetSelect(e.name)}))}},_createToolBar:function(n,i,r){let o=this;o.toolbar&&(o.toolbar.destroy(),o.toolbar.element.empty());let a=i.findIndex((e=>e.id===r)),s=i[a],l=n[s.id];o._activeToolBar=s.text,o.toolbar=new e.spreadsheet.ToolBar(this.element.find("[ref-header-toolbar]"),{tools:"boolean"==typeof l?t:l,toolbarName:s.id,fillMode:"flat",action:function(e){"undo"!==e.command&&"redo"!==e.command?("OpenCommand"==e.command?e.options.file=e.options.value:"BorderChangeCommand"===e.command&&(e.options.border=e.options.border||e.options.value.type,e.options.style=e.options.style||e.options.value.style||{color:e.options.value.color,size:1}),o.spreadsheetRef.executeCommand(e)):o.spreadsheetRef.workbook.undoRedoStack[e.command]()},dialog:function(e){o.spreadsheetRef.openDialog(e.name,e.options)}}),o.toolbar.element.attr("aria-label",s.text)},_initHeader:function(){let t=this,r=this.options.messages.tabs,o=i.extend(!0,{file:!0,home:!0,insert:!0,format:!0,data:!0,view:!0},this.options.toolbar),a=[];this.menu&&(this.menu.destroy(),this.menu.empty()),this.toolbar&&(this.toolbar.destroy(),this.toolbar.empty());for(let e in o)(!0===o[e]||o[e]instanceof Array)&&a.push({id:e,text:r[e],content:"",attr:{"ref-tab-name":e}});if(this.menu=new e.spreadsheet.Menu(this.element.find("[ref-header-menu]"),{dataSource:a,toolbarOptions:o,select:function(e){let r=i(e.item).text();if(t._activeToolBar!==r){i(e.item).addClass(n).siblings("li").removeClass(n),t._createToolBar(o,a,a.find((e=>e.text===r)).id);const s=t.activeSheet();t._onUpdateTools({range:s.range(s.activeCell())})}}}),a.length){let e=a.find((e=>"home"===e.id));this.menu.element.find('li[ref-tab-name="home"]').addClass(n),t._createToolBar(o,a,e?e.id:a[0].id)}},executeCommand(e){return this.spreadsheetRef.executeCommand(e)},_resize:function(){this.refresh({layout:!0})},_workbookChanging:function(e){this.trigger("changing",e)&&e.preventDefault()},_workbookChange:function(t){if(this._autoRefresh&&this.refresh(t),t.recalc&&t.ref){let n=t.range||new e.spreadsheet.Range(t.ref,this.activeSheet());this.trigger("change",{range:n})}},_workbookCut:function(e){this.trigger("cut",e)},_workbookCopy:function(e){this.trigger("copy",e)},_workbookPaste:function(e){this.trigger("paste",e)},activeSheet:function(e){return this.spreadsheetRef.activeSheet(e)},moveSheetToIndex:function(e,t){return this.spreadsheetRef.moveSheetToIndex(e,t)},insertSheet:function(e){return this.spreadsheetRef.insertSheet(e)},sheets:function(){return this.spreadsheetRef.sheets()},removeSheet:function(e){return this.spreadsheetRef.removeSheet(e)},sheetByName:function(e){return this.spreadsheetRef.sheetByName(e)},sheetIndex:function(e){return this.spreadsheetRef.sheetIndex(e)},sheetByIndex:function(e){return this.spreadsheetRef.sheetByIndex(e)},renameSheet:function(e,t){return this.spreadsheetRef.renameSheet(e,t)},refresh:function(e){return this.spreadsheetRef.refresh(e),this},openDialog:function(e,t){return this.spreadsheetRef.openDialog(e,t)},autoRefresh:function(e){return e!==t?(this._autoRefresh=e,!0===e&&this.refresh(),this):this._autoRefresh},toJSON:function(){return this.spreadsheetRef.toJSON()},fromJSON:function(e){this.spreadsheetRef.fromJSON(e)},saveJSON:function(){return this.spreadsheetRef.saveJSON()},fromFile:function(e,t){return this.spreadsheetRef.fromFile(e,t)},saveAsPDF:function(e){this.spreadsheetRef.saveAsPDF(i.extend({},this.options.pdf,e,{workbook:this.spreadsheetRef._workbook}))},saveAsExcel:function(e){this.spreadsheetRef.saveAsExcel(e)},draw:function(e,t){this.spreadsheetRef.draw(e,t)},_workbookExcelExport:function(e){this.trigger("excelExport",e)&&e.preventDefault()},_workbookExcelImport:function(e){this.trigger("excelImport",e)?e.preventDefault():this._initProgress(e.deferred)},_initProgress:function(t){let n=i("<div class='k-loading-mask' style='width: 100%; height: 100%; top: 0;'><div class='k-loading-color'></div></div>").appendTo(this.element),r=i("<div class='k-loading-progress'>").appendTo(n).kendoProgressBar({type:"chunk",chunkCount:10,min:0,max:1,value:0}).data("kendoProgressBar");t.progress((function(e){r.value(e.progress)})).promise.finally((function(){e.destroy(n),n.remove()}))},_workbookPdfExport:function(e){this.trigger("pdfExport",e)&&e.preventDefault()},_workbookInsertSheet:function(e){this.trigger("insertSheet",e)&&e.preventDefault()},_workbookRemoveSheet:function(e){this.trigger("removeSheet",e)&&e.preventDefault()},_workbookSelectSheet:function(e){this.trigger("selectSheet",e)&&e.preventDefault()},_workbookRenameSheet:function(e){this.trigger("renameSheet",e)&&e.preventDefault()},_workbookInsertRow:function(e){this.trigger("insertRow",e)&&e.preventDefault()},_workbookInsertColumn:function(e){this.trigger("insertColumn",e)&&e.preventDefault()},_workbookDeleteRow:function(e){this.trigger("deleteRow",e)&&e.preventDefault()},_workbookDeleteColumn:function(e){this.trigger("deleteColumn",e)&&e.preventDefault()},_workbookHideRow:function(e){this.trigger("hideRow",e)&&e.preventDefault()},_workbookHideColumn:function(e){this.trigger("hideColumn",e)&&e.preventDefault()},_workbookUnhideRow:function(e){this.trigger("unhideRow",e)&&e.preventDefault()},_workbookUnhideColumn:function(e){this.trigger("unhideColumn",e)&&e.preventDefault()},_workbookSelect:function(e){this.trigger("select",e)},_workbookChangeFormat:function(e){this.trigger("changeFormat",e)},_workbookDataBinding:function(e){this.trigger("dataBinding",e)&&e.preventDefault()},_workbookDataBound:function(e){this.trigger("dataBound",e)},_workbookProgress:function(t){e.ui.progress(this.element,t.toggle)},_bindWorkbookEvents:function(){this.spreadsheetRef.bind("cut",this._workbookCut.bind(this)),this.spreadsheetRef.bind("copy",this._workbookCopy.bind(this)),this.spreadsheetRef.bind("paste",this._workbookPaste.bind(this)),this.spreadsheetRef.bind("changing",this._workbookChanging.bind(this)),this.spreadsheetRef.bind("change",this._workbookChange.bind(this)),this.spreadsheetRef.bind("excelExport",this._workbookExcelExport.bind(this)),this.spreadsheetRef.bind("excelImport",this._workbookExcelImport.bind(this)),this.spreadsheetRef.bind("pdfExport",this._workbookPdfExport.bind(this)),this.spreadsheetRef.bind("insertSheet",this._workbookInsertSheet.bind(this)),this.spreadsheetRef.bind("removeSheet",this._workbookRemoveSheet.bind(this)),this.spreadsheetRef.bind("selectSheet",this._workbookSelectSheet.bind(this)),this.spreadsheetRef.bind("renameSheet",this._workbookRenameSheet.bind(this)),this.spreadsheetRef.bind("insertRow",this._workbookInsertRow.bind(this)),this.spreadsheetRef.bind("insertColumn",this._workbookInsertColumn.bind(this)),this.spreadsheetRef.bind("deleteRow",this._workbookDeleteRow.bind(this)),this.spreadsheetRef.bind("deleteColumn",this._workbookDeleteColumn.bind(this)),this.spreadsheetRef.bind("hideRow",this._workbookHideRow.bind(this)),this.spreadsheetRef.bind("hideColumn",this._workbookHideColumn.bind(this)),this.spreadsheetRef.bind("unhideRow",this._workbookUnhideRow.bind(this)),this.spreadsheetRef.bind("unhideColumn",this._workbookUnhideColumn.bind(this)),this.spreadsheetRef.bind("select",this._workbookSelect.bind(this)),this.spreadsheetRef.bind("changeFormat",this._workbookChangeFormat.bind(this)),this.spreadsheetRef.bind("dataBinding",this._workbookDataBinding.bind(this)),this.spreadsheetRef.bind("dataBound",this._workbookDataBound.bind(this)),this.spreadsheetRef.bind("progress",this._workbookProgress.bind(this))},destroy:function(){e.ui.Widget.fn.destroy.call(this),this._formulaBarInputRefPopup?.destroy(),this._formulaCellInputRefPopup?.destroy(),this._formulaBarInputRefList?.destroy(),this._formulaCellInputRefList?.destroy(),this._formulaBarInputRefList=this._formulaCellInputRefList=null,this._formulaBarInputRefPopup=this._formulaCellInputRefPopup=null,this.menu&&this.menu.destroy(),this.toolbar&&this.toolbar.destroy(),this.sheetsBar&&this.sheetsBar.destroy(),this._dialogs?.forEach((function(e){e?.destroy()})),this.spreadsheetRef?.destroy(),this.cellContextMenu?.destroy(),this.rowHeaderContextMenu?.destroy(),this.colHeaderContextMenu?.destroy(),this.drawingContextMenu?.destroy(),this.cellContextMenu=this.rowHeaderContextMenu=this.colHeaderContextMenu=this.drawingContextMenu=null,this._resizeHandler&&i(window).off("resize"+o,this._resizeHandler),e.destroy(this.element)},options:{name:"Spreadsheet",toolbar:!0,sheetsbar:!0,rows:200,columns:50,rowHeight:30,columnWidth:64,headerHeight:30,headerWidth:32,excel:{proxyURL:"",fileName:"Workbook.xlsx"},messages:{},pdf:{area:"workbook",fileName:"Workbook.pdf",proxyURL:"",paperSize:"a4",landscape:!0,margin:null,title:null,author:null,subject:null,keywords:null,creator:"Kendo UI PDF Generator v."+e.version,date:null},defaultCellStyle:{fontFamily:"Arial",fontSize:12},useCultureDecimals:!1},defineName:function(e,t,n){return this.spreadsheetRef.defineName(e,t,n)},undefineName:function(e){return this.spreadsheetRef.undefineName(e)},nameValue:function(e){return this.spreadsheetRef.nameValue(e)},forEachName:function(e){return this.spreadsheetRef.forEachName(e)},cellContextMenu:function(){return this.cellContextMenu},rowHeaderContextMenu:function(){return this.rowHeaderContextMenu},colHeaderContextMenu:function(){return this.colHeaderContextMenu},addImage:function(e){return this.spreadsheetRef.addImage(e)},cleanupImages:function(){return this.spreadsheetRef.cleanupImages()},events:["cut","copy","paste","pdfExport","excelExport","excelImport","changing","change","render","removeSheet","selectSheet","renameSheet","insertRow","insertColumn","deleteRow","insertSheet","deleteColumn","hideRow","hideColumn","unhideRow","unhideColumn","select","changeFormat","dataBinding","dataBound"]});e.ui.plugin(g),i.extend(!0,g,{classNames:{wrapper:"k-spreadsheet"}})}(window.kendo);kendo;!function(e){var t=window.kendo,n=t.ui,i=t.htmlEncode,r=n.Widget,o=".kendoPivotConfigurator",a="mouseenter"+o+" mouseleave"+o,s=({name:e})=>`<div class="k-pivotgrid-target k-pivotgrid-configurator-section"><strong>${i(e)}</strong><div class="k-pivotgrid-target-wrap"></div>`;function l(e){for(var t,n=0,i=e.length;n<i;n++)if(2==e[n].type){t=!0;break}t&&e.splice(n+1,0,{caption:"KPIs",defaultHierarchy:"[KPIs]",name:"KPIs",uniqueName:"[KPIs]"})}function c(e){return{name:e.uniqueName,type:e.type}}function d(e){for(var t=0,n=e.length;t<n;t++)e[t].uniqueName=e[t].name,e[t].type="kpi";return e}function u(t){var n=e(t).closest(".k-pivot-setting");return n.length?n.data("kendoPivotSettingTarget"):null}var h=r.extend({init:function(e,n){r.fn.init.call(this,e,n),this._ariaId=this.element.attr("id")||t.guid(),this.element.addClass("k-pivotgrid-configurator"),this.element.attr({role:"dialog","aria-hidden":!0,"aria-labelledby":`${this._ariaId}-configurator-header`}),this._dataSource(),this.options.navigatable&&this._initPivotGridConfiguratorNavigation(),this._layout(),this.refresh(),n.height&&this.element.height(n.height),t.notify(this)},events:[],options:{name:"PivotConfiguratorV2",orientation:"vertical",filterable:!1,sortable:!1,messages:{title:"Settings",cancelButtonText:"Cancel",applyButtonText:"Apply",measures:"Select some fields to begin setup",columns:"Select some fields to begin setup",rows:"Select some fields to begin setup"}},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.measures&&this.measures.setDataSource(e),this.rows&&this.rows.setDataSource(e),this.columns&&this.columns.setDataSource(e),this.refresh()},_initPivotGridConfiguratorNavigation:function(){var e=this;e.configuratorNavigation=new Iv({tabIndex:0}),e.configuratorNavigation.start(e.element[0]);const t=e.configuratorNavigation.first;t&&t.setAttribute("tabindex","0")},_dataSource:function(){var e=this;e.dataSource&&e._refreshHandler?e.dataSource.unbind("change",e._refreshHandler).unbind("error",e._errorHandler).unbind("progress",e._progressHandler):(e._errorHandler=e._error.bind(e),e._refreshHandler=e.refresh.bind(e),e._progressHandler=e._requestStart.bind(e)),e.dataSource=t.data.PivotDataSourceV2.create(e.options.dataSource),e.dataSource.bind("change",e._refreshHandler).bind("error",e._errorHandler).bind("progress",e._progressHandler)},_layout:function(){var n=this,r=n.options,a=r.messages,s="horizontal"==r.orientation,l=e("<div class='k-pivotgrid-configurator-panel k-pivotgrid-configurator-push'></div>");l.addClass(s?"k-pivotgrid-configurator-horizontal":"k-pivotgrid-configurator-vertical"),n.element.append(l),n.panel=l,e((({title:e,headerTextId:t})=>`<div class="k-pivotgrid-configurator-header"><div class="k-pivotgrid-configurator-header-text" id="${t}">${i(e)}</div></div>`)({title:this.options.messages.title,headerTextId:`${n._ariaId}-configurator-header`})).appendTo(n.panel),e((({formClass:e,horizontal:t,ariaId:n})=>`<div class="k-pivotgrid-configurator-content"><form class="${i(e)}">`+(t?'<div class="k-form-field-wrapper">':"")+'<div class="k-form-field">'+`<label class="k-label" id="${n}-configurator-fields">Fields</label></div><div class="k-form-field"><div class="k-fields-list-wrapper"></div></div>`+(t?'</div><div class="k-form-field-wrapper">':"")+'<div class="k-form-field">'+`<label class="k-label" id="${n}-configurator-columns">Columns</label></div><div class="k-chip-list k-column-fields"></div><div class="k-form-field">`+`<label class="k-label" id="${n}-configurator-rows">Rows</label></div><div class="k-chip-list k-row-fields"></div>`+(t?'</div><div class="k-form-field-wrapper">':"")+'<div class="k-form-field">'+`<label class="k-label" id="${n}-configurator-values">Values</label></div><div class="k-chip-list k-column-fields"></div>`+(t?"</div>":"")+"</form></div>")({formClass:s?"k-form k-form-md k-form-horizontal":"k-form k-form-md",filterable:r.filterable,horizontal:s,ariaId:n._ariaId})).appendTo(n.panel).find(".k-chip-list").each((function(n,i){t.html.renderChipList(i,e.extend({},r)),e(i).attr({role:"listbox","aria-orientation":"horizontal"})})),n._fields(),e((({cancelText:e,applyText:t})=>`<div class="k-pivotgrid-configurator-actions k-actions k-hstack k-justify-content-end"><button class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base" aria-disabled="false"><span class="k-button-text">${i(e)}</span></button><button class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary" aria-disabled="false"><span class="k-button-text">${i(t)}</span></button></div>`)({cancelText:a.cancelButtonText,applyText:a.applyButtonText})).appendTo(n.panel),n._targets(),n.element.on("click"+o,".k-pivotgrid-configurator-actions > button",n._actions.bind(n))},_actions:function(t){t.preventDefault(),e(t.currentTarget).closest(":not(path,svg)").index()?(this.columns._applyState(),this.rows._applyState(),this.measures._applyState(),this.dataSource.read()):(this.columns._cancelChanges(),this.rows._cancelChanges(),this.measures._cancelChanges(),this.treeView.dataSource.read())},_targets:function(){var n=this,r=n.panel.find(".k-column-fields").first(),o=n.panel.find(".k-row-fields"),a=n.panel.find(".k-chip-list").last(),s=this.options,l=({name:n,menuenabled:r})=>{var o=t.html.renderChip((({name:e})=>`<span><span class="k-chip-label">${i(e)}</span></span>`)({name:n,menuenabled:r}),e.extend({},s,{fillMode:"solid",themeColor:"base",rounded:"md",removable:!0,removeIcon:"x-circle",actions:r?[{icon:"more-vertical"}]:null}));return o};this.columns=this._createTarget(r,{navigatable:s.navigatable,filterable:s.filterable,sortable:s.sortable,template:l,connectWith:o,messages:{empty:s.messages.columns,fieldMenu:this.options.messages.fieldMenu},configuratorNavigation:n.configuratorNavigation}),this.columns.element.attr("aria-labelledby",`${this._ariaId}-configurator-header ${this._ariaId}-configurator-columns`),this.rows=this._createTarget(o,{navigatable:s.navigatable,filterable:s.filterable,sortable:s.sortable,template:l,setting:"rows",connectWith:r,messages:{empty:this.options.messages.rows,fieldMenu:this.options.messages.fieldMenu},configuratorNavigation:n.configuratorNavigation}),this.rows.element.attr("aria-labelledby",`${this._ariaId}-configurator-header ${this._ariaId}-configurator-rows`),this.measures=this._createTarget(a,{navigatable:s.navigatable,filterable:!1,sortable:!1,setting:"measures",template:l,messages:{empty:s.messages.measures,fieldMenu:this.options.messages.fieldMenu},configuratorNavigation:n.configuratorNavigation}),this.measures.element.attr("aria-labelledby",`${this._ariaId}-configurator-header ${this._ariaId}-configurator-values`),[this.columns,this.rows,this.measures].forEach((e=>e.element.find(".k-chip").attr("role","option")))},_createTarget:function(n,i){var r=this;return new t.ui.PivotSettingTargetV2(n,e.extend({dataSource:this.dataSource,hint:function(e){return e.clone()},remove:function(e){var n=r.treeView.wrapper.find("[data-name='"+e.name+"']").closest("li"),i=n.attr(t.attr("uid")),o=r.treeView.dataSource.getByUid(i);o&&(o.checked=!1,n.find("input").attr("checked",!1))},template:i.template},i))},_fields:function(){var t=this,n=t.element.find(".k-fields-list-wrapper");this.treeView=e(`<div aria-labelledby="${this._ariaId}-configurator-header ${this._ariaId}-configurator-fields" />`).appendTo(n).kendoTreeView({checkboxes:{checkChildren:!0,template:({item:e})=>{var t="";return(e.hasChildren||e.aggregator||e.local)&&"[KPIs]"!==e.uniqueName&&"[Measures]"!==e.uniqueName&&"Measures"!==e.uniqueName&&(t+=`<input type="checkbox" data-name="${i(e.uniqueName)}" ${e.checked?"checked":""} class="k-checkbox k-checkbox-md k-rounded-md" id="${i(e.uid)}" tabindex="-1">`),t}},dataTextField:"caption",autoBind:!1,check:function(e){var n=e.sender.dataItem(e.node),i={type:Mg.toggleSelection,payload:n},r={columnAxes:t.columns._state(),rowAxes:t.rows._state(),measureAxes:t.measures._state()},o=zg(r,i);t.dataSource.cubeSchema&&o.measureAxes&&o.measureAxes.length&&o.measureAxes.length>r.measureAxes.length&&t.dataSource.cubeSchema.restoreMeasure(o.measureAxes,n),n.defaultHierarchy&&n.items&&n.items.length&&(t._checkMembers([{name:n.defaultHierarchy}],n.items),n.items.trigger("change")),o.columnAxes&&(t.columns._state(o.columnAxes),t.columns._redraw()),o.rowAxes&&(t.rows._state(o.rowAxes),t.rows._redraw()),o.measureAxes&&(t.measures._state(o.measureAxes),t.measures._redraw())},dataSource:this._treeViewDataSource()}).data("kendoTreeView"),this.treeView.wrapper.off("click",this.treeView._clickHandler)},_treeViewDataSource:function(){var n=this;return t.data.HierarchicalDataSource.create({schema:{model:{id:"uniqueName",hasChildren:function(e){return n.dataSource.cubeSchema&&"Measures"!==e.uniqueName?(e.local=!0,!1):!("hierarchyUniqueName"in e)&&!("aggregator"in e)}}},transport:{read:function(t){var i,r,o,a=n.dataSource.transport,s=a.catalog(),c=a.cube(),u={url:a.options.read},h=n.columns._state(),p=n.rows._state(),f=n.measures._state(),g=h.concat(p).concat(f);e.isEmptyObject(t.data)?n.dataSource.cubeSchema?(r=n.dataSource.cubeSchema.dimensions(),n._checkMembers(g,r),t.success(r)):rg(u,{connection:{catalog:s,cube:c},restrictions:{catalogName:s,cubeName:c},command:"schemaDimensions"}).then((function(e){n._checkMembers(g,e),l(e),t.success(e)})):(i=n.treeView.dataSource.get(t.data.uniqueName),n.dataSource.cubeSchema?(o=n.dataSource.measures(),n._checkMembers(g,o),t.success(o)):"[KPIs]"===i.uniqueName?rg(u,n._getKPIOptions(s,c)).then((function(e){t.success(d(e))})):"kpi"==i.type?t.success(m(i)):rg(u,n._loadFieldsCommand(i,s,c)).then((function(e){n._checkMembers(g,e),t.success(e)})))}}})},_checkMembers:function(e,t){var n={},i=0;for(i=0;i<e.length;i++)n[e[i].name]=!0;for(i=0;i<t.length;i++)n[t[i].uniqueName]&&(t[i].checked=!0)},_getKPIOptions:function(e,t){return{connection:{catalog:e,cube:t},restrictions:{catalogName:e,cubeName:t},command:"schemaKPIs"}},_loadFieldsCommand:function(e,t,n){var i,r,o;return 2===e.type?i="schemaMeasures":e.dimensionUniqueName?(i="schemaLevels",o=e.uniqueName):(i="schemaHierarchies",r=e.uniqueName),{connection:{catalog:t,cube:n},restrictions:{catalogName:t,cubeName:n,hierarchyUniqueName:o,dimensionUniqueName:r},command:i}},_progress:function(e){t.ui.progress(this.element,e)},_error:function(){this._progress(!1)},_requestStart:function(){this._progress(!0)},destroy:function(){r.fn.destroy.call(this),this.dataSource.unbind("change",this._refreshHandler),this.element.off(o),this.rows.destroy(),this.columns.destroy(),this.measures.destroy(),this.treeView.destroy(),this.element=null,this._refreshHandler=null},refresh:function(){this.treeView&&this.treeView.dataSource.fetch(),this._progress(!1)}});n.plugin(h);var p=r.extend({init:function(e,n){r.fn.init.call(this,e,n),this.element.addClass("k-pivotgrid-configurator-panel kendo-jquery"),this.options.height&&this.element.outerHeight(this.options.height),this._dataSource(),this._layout(),this.refresh(),t.notify(this)},events:[],options:{name:"PivotConfigurator",filterable:!1,sortable:!1,messages:{measures:"Drop Data Fields Here",columns:"Drop Column Fields Here",rows:"Drop Rows Fields Here",measuresLabel:"Measures",columnsLabel:"Columns",rowsLabel:"Rows",fieldsLabel:"Fields"}},_dataSource:function(){var e=this;e.dataSource&&e._refreshHandler?e.dataSource.unbind("change",e._refreshHandler).unbind("error",e._errorHandler).unbind("progress",e._progressHandler):(e._errorHandler=e._error.bind(e),e._refreshHandler=e.refresh.bind(e),e._progressHandler=e._requestStart.bind(e)),e.dataSource=t.data.PivotDataSource.create(e.options.dataSource),e.dataSource.bind("change",e._refreshHandler).bind("error",e._errorHandler).bind("progress",e._progressHandler)},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.measures&&this.measures.setDataSource(e),this.rows&&this.rows.setDataSource(e),this.columns&&this.columns.setDataSource(e),this.refresh()},_treeViewDataSource:function(){var n=this;return t.data.HierarchicalDataSource.create({schema:{model:{id:"uniqueName",hasChildren:function(e){return!("hierarchyUniqueName"in e)&&!("aggregator"in e)}}},transport:{read:function(t){var i,r;e.isEmptyObject(t.data)?n.dataSource.schemaDimensions().done((function(e){n.dataSource.cubeBuilder||l(e),t.success(e)})).fail(t.error):("[KPIs]"===(i=n.treeView.dataSource.get(t.data.uniqueName)).uniqueName?(r=!0,n.dataSource.schemaKPIs().done((function(e){t.success(d(e))})).fail(t.error)):"kpi"==i.type&&(r=!0,t.success(m(i))),r||(2==i.type?n.dataSource.schemaMeasures():i.dimensionUniqueName?n.dataSource.schemaLevels(t.data.uniqueName):n.dataSource.schemaHierarchies(t.data.uniqueName)).done(t.success).fail(t.error))}}})},_progress:function(e){t.ui.progress(this.element,e)},_error:function(){this._progress(!1)},_requestStart:function(){this._progress(!0)},_layout:function(){e('<div class="k-pivotgrid-configurator"><div class="k-pivotgrid-configurator-content"></div></div>').appendTo(this.element),this.form=this.element.find(".k-pivotgrid-configurator-content"),this._fields(),this._targets()},_fields:function(){var n=e('<div class="k-pivotgrid-fields k-pivotgrid-configurator-section"><strong>'+i(this.options.messages.fieldsLabel)+'</strong><div class="k-fields-list-wrapper"></div></div>').appendTo(this.form);this.treeView=e("<div/>").appendTo(n.find(".k-fields-list-wrapper")).kendoTreeView({template:({item:e})=>{var n="";return 2==e.type||"[KPIs]"==e.uniqueName?n+=t.ui.icon(2==e.type?"sum":"caret-alt-expand"):e.type&&"kpi"!==e.type&&(n+=t.ui.icon("arrows-axes")),n+=`${i(e.caption||e.name)}`},dataTextField:"caption",dragAndDrop:!0,autoBind:!1,dataSource:this._treeViewDataSource(),dragstart:function(e){var t=this.dataItem(e.sourceNode);(t.hasChildren||t.aggregator||t.measure)&&2!=t.type&&"[KPIs]"!==t.uniqueName||e.preventDefault()},drag:function(e){var t="cancel",n=u(e.dropTarget);n&&n.validate(this.dataItem(e.sourceNode))&&(t="plus"),e.setStatusClass(t)},drop:function(e){e.preventDefault();var t,n,i,r,o=u(e.dropTarget),a=this.dataItem(e.sourceNode);if(o&&o.validate(a)){if(r=a.defaultHierarchy||a.uniqueName,"kpi"===a.type)for(n=(i=m(a)).length,r=[],t=0;t<n;t++)r.push(c(i[t]));else a.kpi&&(r=[c(a)]);o.add(r)}}}).data("kendoTreeView")},_createTarget:function(n,i){var r;return r=({name:e,sortIcon:n})=>`<div class="k-chip k-chip-md k-rounded-md k-chip-solid k-chip-solid-base" data-${t.ns}name="${e}"><span class="k-chip-content"><span class="k-chip-label">${e}</span></span><span class="k-chip-actions k-field-actions">`+function(e,n){var i=n.sortable,r="";return i&&(r+=e?`<span class="k-chip-action k-chip-more-action">${t.ui.icon(e+"-sm")}</span>`:""),(n.filterable||i)&&(r+=`<span class="k-setting-fieldmenu k-chip-action">${t.ui.icon("more-vertical")}</span>`),r+`<span class="k-setting-delete k-chip-action">${t.ui.icon("x")}</span>`}(n,i)+"</span></div>",new t.ui.PivotSettingTarget(n,e.extend({dataSource:this.dataSource,template:r,emptyTemplate:e=>`<span class="k-empty">${e}</span>`},i))},_targets:function(){var t=e('<div class="k-pivotgrid-targets"/>').appendTo(this.form),n=e(s({name:this.options.messages.columnsLabel,icon:"columns"})).appendTo(t),i=e('<div class="k-column-fields k-chip-list" />').appendTo(n.find(".k-pivotgrid-target-wrap")),r=e(s({name:this.options.messages.rowsLabel,icon:"rows"})).appendTo(t),o=e('<div class="k-column-fields k-chip-list" />').appendTo(r.find(".k-pivotgrid-target-wrap")),l=e(s({name:this.options.messages.measuresLabel,icon:"sum"})).appendTo(t),c=e('<div class="k-column-fields k-chip-list" />').appendTo(l.find(".k-pivotgrid-target-wrap")),d=this.options;this.columns=this._createTarget(i,{filterable:d.filterable,sortable:d.sortable,connectWith:o,messages:{empty:d.messages.columns,fieldMenu:d.messages.fieldMenu}}),this.rows=this._createTarget(o,{filterable:d.filterable,sortable:d.sortable,setting:"rows",connectWith:i,messages:{empty:this.options.messages.rows,fieldMenu:this.options.messages.fieldMenu}}),this.measures=this._createTarget(c,{setting:"measures",messages:{empty:d.messages.measures}}),i.add(o).add(c).on(a,".k-item:not(.k-empty)",this._toggleHover)},_toggleHover:function(t){e(t.currentTarget).closest(":not(path,svg)").toggleClass("k-hover","mouseenter"===t.type)},_resize:function(){var e=this.element,t=this.options.height;t&&e.outerHeight(t)},refresh:function(){var e=this.dataSource;(e.cubeBuilder||this._cube!==e.cube()||this._catalog!==e.catalog())&&this.treeView.dataSource.fetch(),this._catalog=this.dataSource.catalog(),this._cube=this.dataSource.cube(),this._resize(),this._progress(!1)},destroy:function(){r.fn.destroy.call(this),this.dataSource.unbind("change",this._refreshHandler),this.form.find(".k-pivot-setting").off(o),this.rows.destroy(),this.columns.destroy(),this.measures.destroy(),this.treeView.destroy(),this.element=null,this._refreshHandler=null}});function f(e,t,n){return{hierarchyUniqueName:e,uniqueName:t,caption:t,measure:t,name:t,type:n,kpi:!0}}function m(e){var t=e.name;return[f(t,e.value,"value"),f(t,e.goal,"goal"),f(t,e.status,"status"),f(t,e.trend,"trend")]}t.cssProperties.registerPrefix("HTMLChip","k-chip-"),t.cssProperties.registerValues("HTMLChip",[{prop:"rounded",values:t.cssProperties.roundedValues.concat([["md","md"]])}]),n.plugin(p)}(window.kendo.jQuery);kendo;var hD=function(e,t,n){var i=function(){n(),e.removeEventListener(t,i,!1)},r=function(){return e.addEventListener(t,i,!1)};return r(),{remove:r}},pD=function(e,t){return function(n){var i,r=n.target,o=r.document||r.ownerDocument;if((i=t.container?t.container(r):function(e,t){if(e.closest)return e.closest(t);for(var n=Element.prototype.matches?function(e,t){return e.matches(t)}:function(e,t){return e.msMatchesSelector(t)},i=e;i;){if(n(i,t))return i;i=i.parentElement}}(r,e),i)&&!(/focus/i.test(n.type)&&i.classList.contains("k-ripple-target")))if(r.classList.contains("k-checkbox")||r.classList.contains("k-radio"))n.target.classList.remove("k-ripple-focus"),"animationend"!==n.type&&n.target.classList.add("k-ripple-focus");else{i.classList.add("k-ripple-target");var a=function(e){var t=e.createElement("div");t.className="k-ripple";var n=e.createElement("div");return n.className="k-ripple-blob",t.appendChild(n),[t,n]}(o),s=a[0],l=a[1],c={animated:!1,released:!1,blob:l,container:i,ripple:s},d={focusin:"focusout",keydown:"keyup",mousedown:"mouseup",pointerdown:"pointerup",touchdown:"touchup",animationstart:"animationend"}[n.type];hD(n.currentTarget,d,(function(){return mD(c)})),i.appendChild(s),window.getComputedStyle(s).getPropertyValue("opacity");var u=i.getBoundingClientRect(),h=0,p=0;/mouse|pointer|touch/.test(n.type)?(h=n.clientX-u.left,p=n.clientY-u.top):(h=u.width/2,p=u.height/2);var f=h-(h<u.width/2?u.width:0),m=p-(p<u.height/2?u.height:0),g=2*Math.sqrt(f*f+m*m);if(l.style.width=l.style.height=g+"px",l.offsetWidth<0)throw new Error("Inconceivable!");l.style.cssText="\n        width: "+g+"px;\n        height: "+g+"px;\n        transform: translate(-50%, -50%) scale(1);\n        left: "+h+"px;\n        top: "+p+"px;\n    ",setTimeout((function(){return fD(c)}),500)}}},fD=function(e){e.animated=!0,gD(e)},mD=function(e){e.released=!0,gD(e)},gD=function(e){if(e.released&&e.animated){var t=e.blob,n=e.ripple,i=e.container;i&&hD(i,"blur",(function(){return i.classList.remove("k-ripple-target")})),t&&(hD(t,"transitionend",(function(){n&&n.parentNode&&n.parentNode.removeChild(n)})),t.style.transition="opacity 200ms linear",t.style.opacity="0")}};!function(e){var t=window.kendo.ui,n=t.Widget,i=e.extend,r=n.extend({init:function(e,t){var r=this;n.fn.init.call(r,e),(e=r.wrapper=r.element).addClass("k-ripple-container"),r.options=i({},r.options,t),r.registerListeners()},options:{name:"RippleContainer",elements:[{selector:".k-button:not(li)"},{selector:".k-list-ul > .k-list-item",options:{global:!0}},{selector:".k-checkbox-label, .k-radio-label"},{selector:".k-checkbox, .k-radio",options:{events:["focusin","animationend","click"]}}]},removeListeners:function(){},registerListeners:function(){var e=this,t=e.element[0],n=e.options.elements;e.removeListeners();var i=function(e,t){var n,i=(n=t.map((function(t){var n={events:["mousedown","touchdown"],global:!1},i=t.selector,r=t.options,o=void 0===r?n:r,a=pD(i,o),s=o.events||n.events,l=o.global?document.body:e;return s.forEach((function(e){return l.addEventListener(e,a,!1)})),{events:s,options:o,activator:a}})),[].concat.apply([],n));return function(){e&&(i.forEach((function(t){var n=t.events,i=t.options,r=t.activator,o=i.global?document.body:e;n.forEach((function(e){return o.removeEventListener(e,r,!1)}))})),e=null)}}(t,n);e.removeListeners=i},destroy:function(){n.fn.destroy.call(this),this.removeListeners()}});t.plugin(r)}(window.kendo.jQuery);kendo;var vD=function(e,t){return function(n){return t(e(n))}},_D=function(e,t,n){return e.addEventListener&&e.addEventListener(t,n)},bD=function(e,t,n){return e&&e.removeEventListener&&e.removeEventListener(t,n)},yD=function(){},wD=function(e){return e.preventDefault()},kD=/touch/;function xD(e){return e.type.match(kD)?{pageX:e.changedTouches[0].pageX,pageY:e.changedTouches[0].pageY,clientX:e.changedTouches[0].clientX,clientY:e.changedTouches[0].clientY,type:e.type,originalEvent:e,isTouch:!0}:{pageX:e.pageX,pageY:e.pageY,clientX:e.clientX,clientY:e.clientY,offsetX:e.offsetX,offsetY:e.offsetY,type:e.type,ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,altKey:e.altKey,originalEvent:e}}var CD=function(e){var t=this,n=e.press;void 0===n&&(n=yD);var i=e.drag;void 0===i&&(i=yD);var r=e.release;void 0===r&&(r=yD);var o=e.mouseOnly;void 0===o&&(o=!1),this._pressHandler=vD(xD,n),this._dragHandler=vD(xD,i),this._releaseHandler=vD(xD,r),this._ignoreMouse=!1,this._mouseOnly=o,this._touchstart=function(e){1===e.touches.length&&t._pressHandler(e)},this._touchmove=function(e){1===e.touches.length&&t._dragHandler(e)},this._touchend=function(e){0===e.touches.length&&1===e.changedTouches.length&&(t._releaseHandler(e),t._ignoreMouse=!0,setTimeout(t._restoreMouse,2e3))},this._restoreMouse=function(){t._ignoreMouse=!1},this._mousedown=function(e){var n=e.which;n&&n>1||t._ignoreMouse||(_D(t.document,"mousemove",t._mousemove),_D(t.document,"mouseup",t._mouseup),t._pressHandler(e))},this._mousemove=function(e){t._dragHandler(e)},this._mouseup=function(e){bD(t.document,"mousemove",t._mousemove),bD(t.document,"mouseup",t._mouseup),t._releaseHandler(e)},this._pointerdown=function(e){e.isPrimary&&0===e.button&&(_D(t.document,"pointermove",t._pointermove),_D(t.document,"pointerup",t._pointerup),_D(t.document,"pointercancel",t._pointerup),_D(t.document,"contextmenu",wD),t._pressHandler(e))},this._pointermove=function(e){e.isPrimary&&t._dragHandler(e)},this._pointerup=function(e){e.isPrimary&&(bD(t.document,"pointermove",t._pointermove),bD(t.document,"pointerup",t._pointerup),bD(t.document,"pointercancel",t._pointerup),bD(t.document,"contextmenu",wD),t._releaseHandler(e))}},SD={document:{configurable:!0}};CD.supportPointerEvent=function(){return"undefined"!=typeof window&&window.PointerEvent},SD.document.get=function(){return this._element?this._element.ownerDocument:document},CD.prototype.cancelDrag=function(){bD(this.document,"pointermove",this._pointermove),bD(this.document,"pointerup",this._pointerup),bD(this.document,"pointercancel",this._pointerup)},CD.prototype.bindTo=function(e){e!==this._element&&(this._element&&this._unbindFromCurrent(),this._element=e,this._bindToCurrent())},CD.prototype._bindToCurrent=function(){var e=this._element;this._usePointers()?_D(e,"pointerdown",this._pointerdown):(_D(e,"mousedown",this._mousedown),this._mouseOnly||(_D(e,"touchstart",this._touchstart),_D(e,"touchmove",this._touchmove),_D(e,"touchend",this._touchend)))},CD.prototype._unbindFromCurrent=function(){var e=this._element;if(this._usePointers())return bD(e,"pointerdown",this._pointerdown),bD(this.document,"pointermove",this._pointermove),bD(this.document,"pointerup",this._pointerup),bD(this.document,"contextmenu",wD),void bD(this.document,"pointercancel",this._pointerup);bD(e,"mousedown",this._mousedown),this._mouseOnly||(bD(e,"touchstart",this._touchstart),bD(e,"touchmove",this._touchmove),bD(e,"touchend",this._touchend))},CD.prototype._usePointers=function(){return!this._mouseOnly&&CD.supportPointerEvent()},CD.prototype.update=function(e){var t=e.press;void 0===t&&(t=yD);var n=e.drag;void 0===n&&(n=yD);var i=e.release;void 0===i&&(i=yD);var r=e.mouseOnly;void 0===r&&(r=!1),this._pressHandler=vD(xD,t),this._dragHandler=vD(xD,n),this._releaseHandler=vD(xD,i),this._mouseOnly=r},CD.prototype.destroy=function(){this._unbindFromCurrent(),this._element=null},Object.defineProperties(CD.prototype,SD),CD.default=CD;function TD(e,t,n){void 0===n&&(n={});var i=ID;if(n.forceProxy&&!n.proxyURL)throw new Error("No proxyURL is set, but forceProxy is true");n.forceProxy||(AD()&&(i=ED),navigator.msSaveBlob&&(i=MD)),i(e,t,n)}var DD=function(){return document.createElement("a")},AD=function(){return"download"in DD()};function MD(e,t){var n=e;if("string"==typeof e){for(var i=e.split(";base64,"),r=i[0],o=atob(i[1]),a=new Uint8Array(o.length),s=0;s<o.length;s++)a[s]=o.charCodeAt(s);n=new Blob([a.buffer],{type:r})}navigator.msSaveBlob(n,t)}function ED(e,t){var n=e;window.Blob&&e instanceof Blob&&(n=URL.createObjectURL(e));var i=DD();i.download=t,i.href=n;var r=document.createEvent("MouseEvents");r.initMouseEvent("click",!0,!1,window,0,0,0,0,0,!1,!1,!1,!1,0,null),i.dispatchEvent(r),setTimeout((function(){return URL.revokeObjectURL(n)}))}function ID(e,t,n){if(n.proxyURL){var i=document.createElement("form");i.setAttribute("action",n.proxyURL),i.setAttribute("method","POST"),i.setAttribute("target",n.proxyTarget||"_self");var r=n.proxyData||{};r.fileName=t;var o=e.split(";base64,");for(var a in r.contentType=o[0].replace("data:",""),r.base64=o[1],r)if(r.hasOwnProperty(a)){var s=document.createElement("input");s.setAttribute("type","hidden"),s.setAttribute("name",a),s.setAttribute("value",r[a]),i.appendChild(s)}document.body.appendChild(i),i.submit(),document.body.removeChild(i)}}String.fromCharCode;const{shadow:zD,AnnotationEditorType:PD,FeatureTest:HD,setLayerDimensions:FD,AnnotationEditorParamsType:RD,PixelsPerInch:LD,DOMSVGFactory:BD,PDFDateString:OD,Util:VD,XfaLayer:ND,getDocument:$D,AnnotationMode:UD,AbortException:WD,TextLayer:jD,fetchData:qD,noContextMenu:GD}=window.pdfjsLib||{AnnotationEditorType:{DISABLE:-1,NONE:0,FREETEXT:3,HIGHLIGHT:9,STAMP:13,INK:15}},KD=(...e)=>Object.assign(...e),YD=e=>e&&"object"==typeof e&&!Array.isArray(e),QD=e=>e instanceof HTMLElement,XD=e=>e&&window&&window.DotNet&&window.DotNet.DotNetObject&&e instanceof DotNet.DotNetObject,ZD=(e,...t)=>{if(!t.length)return e;const n=t.shift();if(YD(e)&&YD(n))for(const t in n)n[t]instanceof eA||QD(n[t])||"dotNetInstance"===t||XD(n[t])||n[t]&&n[t].buffer&&n[t].buffer instanceof ArrayBuffer||YD(n[t])&&Object.getPrototypeOf(n[t])!==Object.prototype?e[t]=n[t]:YD(n[t])?(e[t]&&YD(e[t])||KD(e,{[t]:{}}),ZD(e[t],n[t])):KD(e,{[t]:n[t]});return ZD(e,...t)},JD=function(){};class eA{constructor(e,t){this.options={events:{}},this.element=e,this.options=t}destroy(){this.element=null}extendOptions(e){this.options=ZD(this.options,e)}setOptions(e){this.options=e}trigger(e,t={}){const n={defaultPrevented:!1,preventDefault:()=>{n.defaultPrevented=!0}};return"function"==typeof this.options.events[e]&&this.options.events[e](KD(n,t,{sender:this})),n.defaultPrevented}}const tA=function(e,t,n={}){let i,r,o,a,s=0;const l=function(){s=!1===n.leading?0:(new Date).getTime(),i=void 0,a=e.apply(r,o),i||(r=o=null)};return function(){const c=(new Date).getTime();s||!1!==n.leading||(s=c);const d=t-(c-s);return r=void 0,o=arguments,d<=0||d>t?(i&&(clearTimeout(i),i=void 0),s=c,a=e.apply(r,o),i||(r=o=null)):i||!1===n.trailing||(i=window.setTimeout(l,d)),a}},nA=1e3/60,iA="scroll";let rA=class extends eA{constructor(e,t){super(e,t),this.options={events:{[iA]:JD},filter:"",panScrollThrottleDelay:nA,scrollDirectionModifier:-1,scrollThrottleDelay:nA},this.onElementScroll=e=>{const t=this.element;this.shouldTrackScrollEvents()&&(this.state.trackNextElementScroll?this.scrollTo(t.scrollLeft,t.scrollTop):this.state.trackNextElementScroll=!0,this.trigger(iA,{originalEvent:e}))},this.onDragStart=e=>{if(this.state.dragStarted=!1,!this.shouldTrackPanEvents())return;const t=e.target||(e.originalEvent||{}).target;this.options.filter&&!((e,t)=>!(!e||!t)&&e.closest(t))(t,this.options.filter)||((e=>{e.preventDefault&&e.preventDefault(),e.originalEvent&&e.originalEvent.preventDefault()})(e),this.setState({dragStarted:!0,location:{pageX:e.pageX,pageY:e.pageY},locationDelta:{x:0,y:0}}))},this.onDrag=e=>{if(!this.shouldTrackPanEvents()||!this.state.dragStarted)return;this.calculateEventLocationDelta(e),this.setState({location:{pageX:e.pageX,pageY:e.pageY}});const t=this.options.scrollDirectionModifier,n=this.element.scrollLeft+t*this.state.locationDelta.x,i=this.element.scrollTop+t*this.state.locationDelta.y;this.scrollTo(n,i)},this.onDragEnd=()=>{this.shouldTrackPanEvents()},this.extendOptions(t),this.resetState(),this.bindEvents()}destroy(){this.unbindEvents()}initDraggable(){this.destroyDraggable(),this.options.panScrollThrottleDelay>0?this.throttledOnDrag=tA(this.onDrag,this.options.panScrollThrottleDelay):this.throttledOnDrag=this.onDrag,this.draggable=new CD({mouseOnly:!1,press:this.onDragStart,drag:this.throttledOnDrag,release:this.onDragEnd}),this.draggable.bindTo(this.element)}destroyDraggable(){this.draggable&&this.draggable.destroy&&(this.draggable.destroy(),this.throttledOnDrag&&this.throttledOnDrag.cancel&&(this.throttledOnDrag.cancel(),this.throttledOnDrag=null))}bindEvents(){this.bindDraggableEvents(),this.bindElementScroll()}bindDraggableEvents(){this.initDraggable()}bindElementScroll(){this.options.scrollThrottleDelay>0?this.throttledOnElementScroll=tA(this.onElementScroll,this.options.scrollThrottleDelay):this.throttledOnElementScroll=this.onElementScroll,this.element.addEventListener(iA,this.throttledOnElementScroll)}unbindEvents(){this.unbindElementScroll(),this.unbindDraggableEvents()}unbindDraggableEvents(){this.destroyDraggable()}unbindElementScroll(){this.throttledOnElementScroll&&this.throttledOnElementScroll.cancel&&(this.throttledOnElementScroll.cancel(),this.throttledOnElementScroll=null),this.element.removeEventListener(iA,this.throttledOnElementScroll)}setState(e){this.state=Object.assign({},this.state||{},e)}resetState(){this.setState({trackPanEvents:!1,trackScrollEvents:!1,trackNextElementScroll:!1,location:{pageX:0,pageY:0},locationDelta:{x:0,y:0}})}enablePanEventsTracking(){this.state.trackPanEvents=!0,this.bindDraggableEvents()}disablePanEventsTracking(){this.unbindDraggableEvents(),this.state.trackPanEvents=!1}shouldTrackPanEvents(){return this.state.trackPanEvents}enableScrollEventsTracking(){this.state.trackScrollEvents=!0,this.unbindElementScroll(),this.bindElementScroll()}disableScrollEventsTracking(){this.unbindElementScroll(),this.state.trackScrollEvents=!1}shouldTrackScrollEvents(){return this.state.trackScrollEvents}calculateEventLocationDelta(e){this.state.locationDelta={x:e.pageX-this.state.location.pageX,y:e.pageY-this.state.location.pageY}}scrollTo(e,t,n={trackScrollEvent:!0}){n.trackScrollEvent||(this.state.trackNextElementScroll=!1),this.element.scrollLeft=e,this.element.scrollTop=t}};const oA=e=>{const t=e.parentElement;e&&t&&t.replaceWith(...Array.from(t.childNodes))},aA=(e,t)=>{t.classList.add(e)},sA=e=>`.${e}`,lA="data-char-index",cA="data-match-index";class dA{constructor(e){this.options={highlightClass:"k-search-highlight",highlightMarkClass:"k-search-highlight-mark",charClass:"k-text-char",textContainers:[]},this.extendOptions(e),this.resetState()}destroy(){this.clearSearch()}extendOptions(e){this.options=Object.assign({},this.options,e)}setState(e){this.state=Object.assign({},this.state||{},e)}resetState(){this.setState({text:"",textNodes:[],charIndex:0,activeMatchIndex:0,matches:[]})}escapeRegExp(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}search({text:e,matchCase:t}){const n=this.escapeRegExp(e),i=new RegExp(n,t?"g":"ig");let r;if(this.shouldTransformText()&&this.transformTextForSearch(),this.state.matches=[],this.state.activeMatchIndex=0,this.removeIndicators(),""===n)return[];for(r=i.exec(this.state.text);r;)this.state.matches.push({startOffset:r.index,endOffset:r.index+r[0].length}),r=i.exec(this.state.text);return this.highlightAllMatches(),this.addActiveMatchMark(),this.state.matches}clearSearch(){this.removeIndicators(),this.restoreOriginalText()}restoreOriginalText(){this.forEachTextContainer((e=>{Array.from(e.querySelectorAll("span:not(."+this.options.charClass+")")).forEach((e=>{e.innerHTML=e.textContent}))}))}shouldTransformText(){return!this.state.text}transformTextForSearch(){this.state.textNodes=[],this.state.charIndex=0,this.state.text="",this.forEachTextContainer((e=>{this.extractTextNodes(e)})),this.transformTextNodesForSearch(this.state.textNodes)}extractTextNodes(e){if(e.nodeType===Node.TEXT_NODE)this.state.textNodes.push(e);else for(let t=0;t<e.childNodes.length;t++)this.extractTextNodes(e.childNodes[t])}transformTextNodesForSearch(e){for(let t=0;t<e.length;t++)this.transformTextNodeForSearch(e[t])}transformTextNodeForSearch(e){const t=e.textContent;if(t.length<=0)return;this.state.text=this.state.text+t;const n=document.createElement("span");((e,t)=>{e.parentNode&&(e.parentNode.insertBefore(t,e),t.appendChild(e))})(e,n);const i=this.splitTextByChars(t);n.innerHTML=i,oA(n.childNodes[0])}splitTextByChars(e){let t="";for(let n=0;n<e.length;n++)t+=`<span class='${this.options.charClass}' ${lA}=${this.state.charIndex}>${e[n]}</span>`,this.state.charIndex++;return t}forEachTextContainer(e){for(let t=0;t<this.options.textContainers.length;t++){e(this.options.textContainers[t],t)}}highlightAllMatches(){this.state.matches.forEach(((e,t)=>{this.addMatchHighlight(e.startOffset,e.endOffset,t)}))}addMatchHighlight(e,t,n){for(let i=e;i<t;i++)this.forEachTextContainer((e=>{Array.from(e.querySelectorAll(sA(`${this.options.charClass}[${lA}='${i}']`))).forEach((e=>{aA(this.options.highlightClass,e),e.setAttribute(cA,n)}))}))}removeMatchHighlights(){this.forEachTextContainer((e=>{Array.from(e.querySelectorAll(sA(this.options.highlightClass))).forEach((e=>{((e,t)=>{t.classList.remove(e)})(this.options.highlightClass,e),e.removeAttribute(cA)}))}))}addActiveMatchMark(){this.state.activeMatchIndex||0===this.state.activeMatchIndex?this.state.activeMatchIndex>this.state.matches.length?this.state.activeMatchIndex=this.state.matches.length:this.removeActiveMatchMark():this.state.activeMatchIndex=0;const e=document.createElement("span");e.classList.add(this.options.highlightMarkClass),this.forEachTextContainer((t=>{Array.from(t.querySelectorAll(sA(this.options.charClass+"["+cA+"='"+this.state.activeMatchIndex+"']"))).forEach((t=>{((e,t)=>{if(e&&e.parentNode&&t)for(e.appendChild(t);e.firstChild&&e.firstChild!==t;)t.appendChild(e.firstChild)})(t,e.cloneNode(!0))}))}))}removeActiveMatchMark(){this.forEachTextContainer((e=>{const t=Array.from(e.querySelectorAll(sA(this.options.highlightMarkClass))).flatMap((e=>Array.from(e.childNodes)));(e=>{if(e&&e.length&&!(e.length<=0))for(let t=0;t<e.length;t++)oA(e[t])})(t)}))}removeIndicators(){this.removeActiveMatchMark(),this.removeMatchHighlights()}markNextMatch(){this.markNextMatchIndex(),this.addActiveMatchMark()}markPreviousMatch(){this.markPreviousMatchIndex(),this.addActiveMatchMark()}markNextMatchIndex(){this.moveActiveMatchIndex(1)}markPreviousMatchIndex(){this.moveActiveMatchIndex(-1)}moveActiveMatchIndex(e){this.state.activeMatchIndex+=e,this.state.activeMatchIndex<0?this.state.activeMatchIndex=Math.max(this.state.matches.length-1,0):this.state.activeMatchIndex>this.state.matches.length-1&&(this.state.activeMatchIndex=0)}getActiveMatchElement(){let e;return this.forEachTextContainer((t=>{const n=t.querySelector(sA(this.options.highlightMarkClass));n&&(e=n)})),e}}class uA{constructor(e,t,n,i,r,o){this.container=e,this.viewport=t,this.zoom=r,this.annotation=n,this.pdfDoc=i,this.rootElement=o}destroy(){}}class hA extends uA{constructor(e,t,n,i,r,o){super(e,t,n,i,r,o),this.onLinkClick=e=>{const t=e.target.getAttribute("href");t&&0===t.indexOf("#")&&(this.navigateToDestination(t),e.preventDefault())},this.linkElement=null,this.renderAnnotation(),this.bindEvents()}destroy(){this.unbindEvents()}bindEvents(){this.linkElement.addEventListener("click",this.onLinkClick)}unbindEvents(){this.linkElement.removeEventListener("click",this.onLinkClick)}navigateToDestination(e){const t=e.split("#")[1];this.pdfDoc.getDestination(t).then((e=>{this.pdfDoc.getPageIndex(e[0]).then((e=>this.goToPage(e)))}))}goToPage(e){TA(this.rootElement,e)}renderAnnotation(){const e=this.annotation,t=this.viewport,n=e.rect,i=[[n[0],n[1]],[n[2],n[3]]],r=t.rawDims.pageHeight,o=Math.min(i[0][0],i[1][0])*this.zoom,a=(r-Math.max(i[0][1],i[1][1]))*this.zoom,s=(i[1][0]-i[0][0])*this.zoom,l=(i[1][1]-i[0][1])*this.zoom,c=e.url||e.dest&&`#${encodeURI(e.dest)}`,d=kA("span","",{position:"absolute",left:o+"pt",top:a+"pt"}),u=this.linkElement=kA("a","",{width:s+"pt",height:l+"pt",display:"inline-block",pointerEvents:"auto"});u.setAttribute("href",c),d.append(u),this.container.append(d)}}const pA=268435456,fA=1.25,mA=()=>/iPad|iPhone|iPod/.test(navigator.userAgent)||navigator.maxTouchPoints&&navigator.maxTouchPoints>2&&/Macintosh/i.test(navigator.userAgent)?devicePixelRatio:3*devicePixelRatio,gA=e=>atob(e.replace(/^(data:application\/pdf;base64,)/gi,"")),vA=(e,t,n)=>{0===n&&(e=>{for(;e.firstChild;)e.removeChild(e.firstChild)})(e),e.appendChild(t)},_A=e=>{const t=(e=>{let t={verbosity:0,isEvalSupported:!1};return"string"==typeof e.data?t.data=gA(e.data):"string"==typeof e.url?t.url=e.url:e.arrayBuffer instanceof ArrayBuffer?t=e.arrayBuffer:e.typedArray&&(t=e.typedArray),t})(e),{dom:n,zoom:i,done:r,error:o,rootElement:a}=e,s=e.loadOnDemandPageSize||2;$D(t).promise.then((e=>{const t=[];for(let n=1;n<=e.numPages;n++)t.push(e.getPage(n));return{pages:t,pdfDoc:e}})).then((({pages:t,pdfDoc:l})=>{Promise.all(t).then((t=>t.map(((t,r)=>{const c=yA(t,i,l,a);return vA(n,c.pageElement,r),e.loadOnDemand?r<s&&CA(t,c,o):CA(t,c,o),t._pageInfo.emptyPage=c,t})))).then((t=>{const n=new CSSStyleSheet;n.replaceSync(".hiddenCanvasElement {\n                        position: absolute;\n                        top: 0;\n                        left: 0;\n                        width: 0;\n                        height: 0;\n                        display: none;\n                    }"),e.dom.ownerDocument.adoptedStyleSheets=[n],r({pdfPages:t,pdfDoc:l,zoom:i})})).catch((t=>{e.error(t)}))})).catch((t=>{e.error(t)}))},bA=(e,t,n,i,r)=>{const o=window.open("","","innerWidth="+t+",innerHeight="+n+"location=no,titlebar=no,toolbar=no");if(o&&o.document){if(o){o.document.body.style.margin="0",o.document.body.appendChild(e),o.focus(),setTimeout((()=>{o.print(),i()}));const t=()=>{o.removeEventListener("afterprint",t),o.close()};o.addEventListener("afterprint",t)}}else r()},yA=(e,t,n,i)=>{const{canvasContext:r,viewport:o,pageElement:a,styles:s}=MA(e,t,"k-page");return{canvasContext:r,viewport:o,pageElement:a,styles:s,zoom:t,pdfDoc:n,rootElement:i}},wA=(e,t,n)=>{const{canvasContext:i,viewport:r,scaleNum:o,canvas:a,pageElement:s}=MA(e);return e.render({canvasContext:i,viewport:r}).promise.then((()=>{const e=new Image(Math.floor(r.width/o),Math.floor(r.height/o));e.src=a.toDataURL();const n=()=>{e.removeEventListener("load",n),t(s)};e.addEventListener("load",n)})).catch(n),r},kA=function(e,t,n){const i=document.createElement(e);return t&&(i.className=t),Object.keys(n).forEach((e=>i.style[e]=n[e])),i},xA={0:"",90:"rotate(90deg) translateY(-100%)",180:"rotate(180deg) translate(-100%, -100%)",270:"rotate(270deg) translateX(-100%)"},CA=(e,t,n)=>{const{canvasContext:i,viewport:r,pageElement:o,styles:a,zoom:s,pdfDoc:l,rootElement:c}=t;return e._pageInfo.renderInProgress=!0,e.render({canvasContext:i,viewport:r}).promise.then((()=>{e.getTextContent().then((e=>{const t=kA("div","k-text-layer",a);new jD({textContentSource:e,container:t,viewport:r}).render().then((()=>{t.style.width=t.style.width.replace(/px/g,"pt"),t.style.height=t.style.height.replace(/px/g,"pt");const e=t.getAttribute("data-main-rotation")||"0";xA[e]&&(t.style.transform=xA[e],t.style.transformOrigin="top left"),t.querySelectorAll("span").forEach((e=>{e.style.fontSize&&(e.style.fontSize=e.style.fontSize.replace(/px/g,"pt"))})),o.prepend(t)})).catch(n)})),e.getAnnotations({intent:"display"}).then((e=>{const t=kA("div","k-annotations-layer",{position:"absolute",top:"0",left:"0",overflow:"hidden",height:a.height,width:a.width,pointerEvents:"none"});o.appendChild(t);for(const n of e)if("Link"===n.subtype)new hA(t,r,n,l,s,c)}))})).then((()=>{e._pageInfo.rendered=!0,e._pageInfo.renderInProgress=!1})).catch(n),o},SA=(e,t)=>{if(!e)return;const n=e.closest(".k-text-char"),i=n?n.closest('span[role="presentation"]'):null;if(!i)return;const r=i.closest(".k-page");if(!r)return;const o=r.offsetLeft+-1*t.scroller.element.offsetLeft+i.offsetLeft+0,a=r.offsetTop+-1*t.scroller.element.offsetTop+i.offsetTop+-64;t.scroller.scrollTo(o,a,{trackScrollEvent:!1})},TA=(e,t)=>{const n=e.querySelectorAll(".k-page"),i=n[0];if(i instanceof HTMLDivElement){const e=(i.offsetHeight+i.offsetTop)*Math.max(0,Math.min(t,n.length-1)),r=i.closest(".k-pdf-viewer-canvas");r&&r.scrollTo({top:e,behavior:"auto"})}},DA=e=>{const t=e.querySelector(".k-pdf-viewer-canvas"),n=e.querySelector(".k-page");return t&&n?Math.floor(Math.round(t.scrollTop)/(n.offsetHeight+n.offsetTop)+.01):0},AA=(e,t)=>{const{maxWidth:n,maxHeight:i,maxArea:r}=(e=>{const t=dr(e),n=cr(e);return t&&t.mozilla||n&&"firefox"===n.browser})(navigator.userAgent)?{maxWidth:32767,maxHeight:32767,maxArea:124992400}:(e=>dr(e).safari||cr(e)&&"mobilesafari"===cr(e).browser)(navigator.userAgent)?{maxWidth:4194303,maxHeight:8388607,maxArea:pA}:{maxWidth:65535,maxHeight:65535,maxArea:pA};let o=e,a=t;const s=e/t;if(e>n){o=n;a=t-(e-n)/s}if(a>i){const e=a-i;a=i,o-=e*s}const l=o*a;if(l>r){const e=Math.sqrt(r/l);o*=e,a*=e}const c=o/e;return{adjustedWidth:o!==e?Math.floor(o/2):e,adjustedHeight:a!==t?Math.floor(a/2):t,adjustRatio:1!==c?c/2:1}},MA=(e,t=1,n="")=>{const i=mA(),r=e.getViewport({scale:i}),{adjustedWidth:o,adjustedHeight:a,adjustRatio:s}=AA(r.width,r.height),l={width:Math.floor(r.width/i)*t+"pt",height:Math.floor(r.height/i)*t+"pt"},c=kA("div",n,l),d=kA("canvas","",{width:"100%",height:"100%"});d.height=a,d.width=o;const u=d.getContext("2d");c.appendChild(d);const h=s*i;return r.width=o,r.height=a,r.scale=h,{canvasContext:u,viewport:r,scaleNum:i,canvas:d,pageElement:c,styles:l}},EA=(e,t)=>{t.classList.add(e)},IA=1.35,zA="pdfjs_internal_editor_",PA=3,HA=9,FA=1,RA=2,LA=3,BA=4,OA=5;function VA(e,t,n,i=!1){return Object.defineProperty(e,t,{value:n,enumerable:!i,configurable:!0,writable:!1}),n}const NA=Array.from(Array(256).keys(),(e=>e.toString(16).padStart(2,"0")));class $A{static makeHexColor(e,t,n){return`${NA[e]}${NA[t]}${NA[n]}`}static normalizeRect(e){const t=e.slice(0);return e[0]>e[2]&&(t[0]=e[2],t[2]=e[0]),e[1]>e[3]&&(t[1]=e[3],t[3]=e[1]),t}}const UA="pdfjs_internal_id_";var WA,jA,qA,GA,KA,YA,QA,XA,ZA,JA,eM,tM,nM,iM,rM,oM,aM,sM,lM,cM,dM,uM,hM,pM,fM,mM,gM,vM,_M,bM,yM,wM,kM,xM,CM,SM,TM,DM,AM,MM,EM,IM,zM,PM,HM,FM,RM,LM,BM,OM,VM,NM,$M,UM,WM,jM,qM,GM;class KM{constructor(e=zA){WA.set(this,0),this.idPrefix=zA,Object.defineProperty(this,"reset",{value:()=>yp(this,WA,0,"f")}),this.idPrefix=e}get id(){var e,t;return`${this.idPrefix}${yp(this,WA,(t=bp(this,WA,"f"),e=t++,t),"f"),e}`}}WA=new WeakMap;class YM{constructor(e=128){jA.set(this,[]),qA.set(this,!1),GA.set(this,void 0),KA.set(this,-1),yp(this,GA,e,"f")}add({cmd:e,undo:t,post:n,mustExec:i,type:r=NaN,overwriteIfSameType:o=!1,keepUndo:a=!1}){if(i&&e(),bp(this,qA,"f"))return;const s={cmd:e,undo:t,post:n,type:r};if(-1===bp(this,KA,"f"))return bp(this,jA,"f").length>0&&(bp(this,jA,"f").length=0),yp(this,KA,0,"f"),void bp(this,jA,"f").push(s);if(o&&bp(this,jA,"f")[bp(this,KA,"f")].type===r)return a&&(s.undo=bp(this,jA,"f")[bp(this,KA,"f")].undo),void(bp(this,jA,"f")[bp(this,KA,"f")]=s);const l=bp(this,KA,"f")+1;l===bp(this,GA,"f")?bp(this,jA,"f").splice(0,1):(yp(this,KA,l,"f"),l<bp(this,jA,"f").length&&bp(this,jA,"f").splice(l)),bp(this,jA,"f").push(s)}undo(){if(-1===bp(this,KA,"f"))return;yp(this,qA,!0,"f");const{undo:e,post:t}=bp(this,jA,"f")[bp(this,KA,"f")];e(),null==t||t(),yp(this,qA,!1,"f"),yp(this,KA,bp(this,KA,"f")-1,"f")}redo(){if(bp(this,KA,"f")<bp(this,jA,"f").length-1){yp(this,KA,bp(this,KA,"f")+1,"f"),yp(this,qA,!0,"f");const{cmd:e,post:t}=bp(this,jA,"f")[bp(this,KA,"f")];e(),null==t||t(),yp(this,qA,!1,"f")}}hasSomethingToUndo(){return-1!==bp(this,KA,"f")}hasSomethingToRedo(){return bp(this,KA,"f")<bp(this,jA,"f").length-1}destroy(){yp(this,jA,null,"f")}}jA=new WeakMap,qA=new WeakMap,GA=new WeakMap,KA=new WeakMap;class QM{constructor({container:e=null,viewer:t,pdfViewer:n,eventBus:i,pdfDocument:r,highlightColors:o=""}){YA.add(this),this.pdfViewer=null,this.annotationEditorMode=PD.NONE,this.viewParameters={},this.isShiftKeyDown=!1,this._eventBus=null,QA.set(this,new AbortController),XA.set(this,null),ZA.set(this,new Map),JA.set(this,new Map),eM.set(this,null),tM.set(this,null),nM.set(this,new YM),iM.set(this,0),rM.set(this,new Set),oM.set(this,null),aM.set(this,null),sM.set(this,new Set),lM.set(this,!0),cM.set(this,null),dM.set(this,null),uM.set(this,""),hM.set(this,!1),pM.set(this,null),fM.set(this,new KM),mM.set(this,!1),gM.set(this,!1),vM.set(this,null),_M.set(this,PD.NONE),bM.set(this,new Set),yM.set(this,null),wM.set(this,null),kM.set(this,{isEditing:!1,isEmpty:!0,hasSomethingToUndo:!1,hasSomethingToRedo:!1,hasSelectedEditor:!1,hasSelectedText:!1}),xM.set(this,[0,0]),CM.set(this,null),SM.set(this,null),TM.set(this,null);const a=this._signal=bp(this,QA,"f").signal;yp(this,SM,e,"f"),yp(this,TM,t,"f"),this.pdfViewer=n,this._eventBus=i,this._eventBus._on("editingaction",this.onEditingAction.bind(this),{signal:a}),this._eventBus._on("pagechanging",this.onPageChanging.bind(this),{signal:a}),this._eventBus._on("scalechanging",this.onScaleChanging.bind(this),{signal:a}),this._eventBus._on("rotationchanging",this.onRotationChanging.bind(this),{signal:a}),this._eventBus._on("setpreference",this.onSetPreference.bind(this),{signal:a}),bp(this,YA,"m",zM).call(this),bp(this,YA,"m",OM).call(this),bp(this,YA,"m",FM).call(this),yp(this,eM,r.annotationStorage,"f"),yp(this,uM,o||"","f"),this.viewParameters={realScale:LD.PDF_TO_CSS_UNITS,rotation:0}}destroy(){var e;null===(e=bp(this,QA,"f"))||void 0===e||e.abort(),yp(this,QA,null,"f"),this._signal=null;for(const e of bp(this,JA,"f").values())e.destroy();bp(this,JA,"f").clear(),bp(this,ZA,"f").clear(),bp(this,sM,"f").clear(),yp(this,XA,null,"f"),bp(this,bM,"f").clear(),bp(this,nM,"f").destroy(),bp(this,cM,"f")&&(clearTimeout(bp(this,cM,"f")),yp(this,cM,null,"f")),bp(this,CM,"f")&&(clearTimeout(bp(this,CM,"f")),yp(this,CM,null,"f"))}getTextLayerForAnchor(e){return e?e.closest(".textLayer")||e.closest(".k-text-layer"):null}combinedSignal(e){return AbortSignal&&AbortSignal.any?AbortSignal.any([this._signal,e.signal]):this._signal||e.signal}get direction(){return zD(this,"direction",getComputedStyle(bp(this,SM,"f")).direction)}get highlightColors(){return zD(this,"highlightColors",bp(this,uM,"f")?new Map:null)}get highlightColorNames(){return zD(this,"highlightColorNames",this.highlightColors?new Map(Array.from(this.highlightColors,(e=>e.reverse()))):null)}switchToMode(e,t){this._eventBus.on("annotationeditormodechanged",t,{once:!0,signal:this._signal,mode:e}),this._eventBus.dispatch("showannotationeditorui",{source:this,mode:e})}setPreference(e,t){this._eventBus.dispatch("setpreference",{source:this,name:e,value:t})}onSetPreference({name:e}){e}onPageChanging({pageNumber:e}){yp(this,iM,e-1,"f")}focusMainContainer(){var e;null===(e=bp(this,SM,"f"))||void 0===e||e.focus()}findParent(e,t){for(const n of bp(this,JA,"f").values()){const{x:i,y:r,width:o,height:a}=n.div.getBoundingClientRect();if(e>=i&&e<=i+o&&t>=r&&t<=r+a)return n}return null}disableUserSelect(e=!1){var t;null===(t=bp(this,TM,"f"))||void 0===t||t.classList.toggle("noUserSelect",e)}addShouldRescale(e){bp(this,sM,"f").add(e)}removeShouldRescale(e){bp(this,sM,"f").delete(e)}onScaleChanging({scale:e}){this.commitOrRemove(),this.viewParameters.realScale=e*LD.PDF_TO_CSS_UNITS;for(const e of bp(this,sM,"f"))e.onScaleChanging()}onRotationChanging({pagesRotation:e}){this.commitOrRemove(),this.viewParameters.rotation=e}highlightSelection(e=""){const t=document.getSelection();if(!t||t.isCollapsed)return;const{anchorNode:n,anchorOffset:i,focusNode:r,focusOffset:o}=t,a=t.toString(),s=bp(this,YA,"m",DM).call(this,t),l=this.getTextLayerForAnchor(s),c=this.getSelectionBoxes(l);if(!c)return;t.empty();const d=bp(this,YA,"m",AM).call(this,l),u=bp(this,_M,"f")===PD.NONE,h=()=>{null==d||d.createAndAddNewEditor({x:0,y:0},!1,{methodOfCreation:e,boxes:c,anchorNode:n,anchorOffset:i,focusNode:r,focusOffset:o,text:a}),u&&this.showAllEditors("highlight",!0)};u?this.switchToMode(PD.HIGHLIGHT,h):h()}showEditorToolBar(e){if(!e)return;const t=this.getMode();if(t===PD.HIGHLIGHT){if(!e.closest(".highlightEditor"))return}if(t===PD.FREETEXT){if(!e.closest(".freeTextEditor"))return}t!==PD.HIGHLIGHT&&t!==PD.FREETEXT||this._eventBus.dispatch("kendoAnnotationEditorToolBarShow",{source:this,anchor:e})}hideEditorToolBar(){this._eventBus.dispatch("kendoAnnotationEditorToolBarHide",{source:this})}addToAnnotationStorage(e){e.isEmpty()||!bp(this,eM,"f")||bp(this,eM,"f").has(e.id)||bp(this,eM,"f").setValue(e.id,e)}blur(){if(this.isShiftKeyDown=!1,bp(this,hM,"f")&&(yp(this,hM,!1,"f"),bp(this,YA,"m",IM).call(this,"main_toolbar")),!this.hasSelection)return;const{activeElement:e}=document;for(const t of bp(this,bM,"f"))if(t.div.contains(e)){yp(this,vM,[t,e],"f"),t._focusEventsAllowed=!1;break}}focus(){if(!bp(this,vM,"f"))return;const[e,t]=bp(this,vM,"f");yp(this,vM,null,"f"),t.addEventListener("focusin",(()=>{e._focusEventsAllowed=!0}),{once:!0,signal:this._signal}),t.focus()}addEditListeners(){bp(this,YA,"m",FM).call(this),bp(this,YA,"m",LM).call(this)}removeEditListeners(){bp(this,YA,"m",RM).call(this),bp(this,YA,"m",BM).call(this)}dragOver(e){for(const{type:t}of e.dataTransfer.items)for(const n of bp(this,aM,"f"))if(n.isHandlingMimeForPasting(t))return e.dataTransfer.dropEffect="copy",void e.preventDefault()}drop(e){for(const t of e.dataTransfer.items)for(const n of bp(this,aM,"f"))if(n.isHandlingMimeForPasting(t.type))return n.paste(t,this.currentLayer),void e.preventDefault()}copy(e){var t;if(e.preventDefault(),null===(t=bp(this,XA,"f"))||void 0===t||t.commitOrRemove(),!this.hasSelection)return;const n=[];for(const e of bp(this,bM,"f")){const t=e.serialize(!0);t&&n.push(t)}0!==n.length&&e.clipboardData.setData("application/pdfjs",JSON.stringify(n))}cut(e){this.copy(e),this.delete()}paste(e){e.preventDefault();const{clipboardData:t}=e;for(const e of t.items)for(const t of bp(this,aM,"f"))if(t.isHandlingMimeForPasting(e.type))return void t.paste(e,this.currentLayer);let n=t.getData("application/pdfjs");if(!n)return;try{n=JSON.parse(n)}catch(e){return}if(!Array.isArray(n))return;this.unselectAll();const i=this.currentLayer;try{const e=[];for(const t of n){const n=i.deserialize(t);if(!n)return;e.push(n)}const t=()=>{for(const t of e)bp(this,YA,"m",WM).call(this,t);bp(this,YA,"m",GM).call(this,e)},r=()=>{for(const t of e)t.remove()};this.addCommands({cmd:t,undo:r,mustExec:!0})}catch(e){}}onEditingAction({name:e}){switch(e){case"undo":case"redo":case"delete":case"selectAll":this[e]();break;case"highlightSelection":this.highlightSelection("context_menu")}}setEditingState(e){e?(bp(this,YA,"m",PM).call(this),bp(this,YA,"m",LM).call(this),bp(this,YA,"m",VM).call(this,{isEditing:bp(this,_M,"f")!==PD.NONE,isEmpty:bp(this,YA,"m",qM).call(this),hasSomethingToUndo:bp(this,nM,"f").hasSomethingToUndo(),hasSomethingToRedo:bp(this,nM,"f").hasSomethingToRedo(),hasSelectedEditor:!1})):(bp(this,YA,"m",HM).call(this),bp(this,YA,"m",BM).call(this),bp(this,YA,"m",VM).call(this,{isEditing:!1}),this.disableUserSelect(!1))}registerEditorTypes(e){if(!bp(this,aM,"f")){yp(this,aM,e,"f");for(const e of bp(this,aM,"f"))bp(this,YA,"m",NM).call(this,e.defaultPropertiesToUpdate)}}getId(){return bp(this,fM,"f").id}get currentLayer(){return bp(this,JA,"f").get(bp(this,iM,"f"))}getLayer(e){return bp(this,JA,"f").get(e)}get currentPageIndex(){return bp(this,iM,"f")}addLayer(e){bp(this,JA,"f").set(e.pageIndex,e),bp(this,mM,"f")?e.enable():e.disable()}removeLayer(e){bp(this,JA,"f").delete(e.pageIndex)}updateMode(e,t=null,n=!1){if(bp(this,_M,"f")!==e){if(yp(this,_M,e,"f"),e===PD.NONE)return this.setEditingState(!1),void bp(this,YA,"m",UM).call(this);this.setEditingState(!0),bp(this,YA,"m",$M).call(this),this.unselectAll();for(const t of bp(this,JA,"f").values())t.updateMode(e);if(t||!n){if(t)for(const e of bp(this,ZA,"f").values())if(e.annotationElementId===t){this.setSelected(e),e.enterInEditMode();break}}else this.addNewEditorFromKeyboard()}}addNewEditorFromKeyboard(){this.currentLayer.canCreateNewEmptyEditor()&&this.currentLayer.addNewEditor()}updateToolbar(e){e!==bp(this,_M,"f")&&this._eventBus.dispatch("switchannotationeditormode",{source:this,mode:e})}updateParams(e,t){if(bp(this,aM,"f")){switch(e){case RD.CREATE:return void this.currentLayer.addNewEditor();case RD.HIGHLIGHT_DEFAULT_COLOR:break;case RD.HIGHLIGHT_SHOW_ALL:yp(this,wM,bp(this,wM,"f")||new Map,"f").set(e,t),this.showAllEditors("highlight",t)}for(const n of bp(this,bM,"f"))n.updateParams(e,t);for(const n of bp(this,aM,"f"))n.updateDefaultParams(e,t)}}showAllEditors(e,t){var n,i;for(const n of bp(this,ZA,"f").values())n.editorType===e&&n.show(t);(null===(i=null===(n=bp(this,wM,"f"))||void 0===n?void 0:n.get(RD.HIGHLIGHT_SHOW_ALL))||void 0===i||i)!==t&&bp(this,YA,"m",NM).call(this,[[RD.HIGHLIGHT_SHOW_ALL,t]])}enableWaiting(e=!1){if(bp(this,gM,"f")!==e){yp(this,gM,e,"f");for(const t of bp(this,JA,"f").values())e?t.disableClick():t.enableClick(),t.div.classList.toggle("waiting",e)}}getEditors(e){const t=[];for(const n of bp(this,ZA,"f").values())n.pageIndex===e&&t.push(n);return t}getEditor(e){return bp(this,ZA,"f").get(e)}addEditor(e){bp(this,ZA,"f").set(e.id,e)}removeEditor(e){var t;e.div.contains(document.activeElement)&&(bp(this,cM,"f")&&clearTimeout(bp(this,cM,"f")),yp(this,cM,setTimeout((()=>{this.focusMainContainer(),yp(this,cM,null,"f")}),0),"f")),bp(this,ZA,"f").delete(e.id),this.unselect(e),e.annotationElementId&&bp(this,rM,"f").has(e.annotationElementId)||null===(t=bp(this,eM,"f"))||void 0===t||t.remove(e.id)}addDeletedAnnotationElement(e){bp(this,rM,"f").add(e.annotationElementId),this.addChangedExistingAnnotation(e),e.deleted=!0}isDeletedAnnotationElement(e){return bp(this,rM,"f").has(e)}removeDeletedAnnotationElement(e){bp(this,rM,"f").delete(e.annotationElementId),this.removeChangedExistingAnnotation(e),e.deleted=!1}setActiveEditor(e){bp(this,XA,"f")!==e&&(yp(this,XA,e,"f"),e&&bp(this,YA,"m",NM).call(this,e.propertiesToUpdate))}updateUI(e){bp(this,YA,"a",jM)===e&&bp(this,YA,"m",NM).call(this,e.propertiesToUpdate)}toggleSelected(e){if(bp(this,bM,"f").has(e))return bp(this,bM,"f").delete(e),e.unselect(),void bp(this,YA,"m",VM).call(this,{hasSelectedEditor:this.hasSelection});bp(this,bM,"f").add(e),e.select(),bp(this,YA,"m",NM).call(this,e.propertiesToUpdate),bp(this,YA,"m",VM).call(this,{hasSelectedEditor:!0})}setSelected(e){for(const t of bp(this,bM,"f"))t!==e&&t.unselect();bp(this,bM,"f").clear(),bp(this,bM,"f").add(e),e.select(),bp(this,YA,"m",NM).call(this,e.propertiesToUpdate),bp(this,YA,"m",VM).call(this,{hasSelectedEditor:!0})}isSelected(e){return bp(this,bM,"f").has(e)}get firstSelectedEditor(){return bp(this,bM,"f").values().next().value}unselect(e){e.unselect(),bp(this,bM,"f").delete(e),bp(this,YA,"m",VM).call(this,{hasSelectedEditor:this.hasSelection})}get hasSelection(){return 0!==bp(this,bM,"f").size}get isEnterHandled(){return 1===bp(this,bM,"f").size&&this.firstSelectedEditor.isEnterHandled}undo(){bp(this,nM,"f").undo(),bp(this,YA,"m",VM).call(this,{hasSomethingToUndo:bp(this,nM,"f").hasSomethingToUndo(),hasSomethingToRedo:!0,isEmpty:bp(this,YA,"m",qM).call(this)})}redo(){bp(this,nM,"f").redo(),bp(this,YA,"m",VM).call(this,{hasSomethingToUndo:!0,hasSomethingToRedo:bp(this,nM,"f").hasSomethingToRedo(),isEmpty:bp(this,YA,"m",qM).call(this)})}addCommands(e){bp(this,nM,"f").add(e),bp(this,YA,"m",VM).call(this,{hasSomethingToUndo:!0,hasSomethingToRedo:!1,isEmpty:bp(this,YA,"m",qM).call(this)})}delete(){if(this.commitOrRemove(),!this.hasSelection)return;const e=[...bp(this,bM,"f")];this.addCommands({cmd:()=>{for(const t of e)t.remove()},undo:()=>{for(const t of e)bp(this,YA,"m",WM).call(this,t)},mustExec:!0})}commitOrRemove(){var e;null===(e=bp(this,XA,"f"))||void 0===e||e.commitOrRemove()}hasSomethingToControl(){return bp(this,XA,"f")||this.hasSelection}selectAll(){for(const e of bp(this,bM,"f"))e.commit();bp(this,YA,"m",GM).call(this,bp(this,ZA,"f").values())}unselectAll(){if((!bp(this,XA,"f")||(bp(this,XA,"f").commitOrRemove(),bp(this,_M,"f")===PD.NONE))&&this.hasSelection){for(const e of bp(this,bM,"f"))e.unselect();bp(this,bM,"f").clear(),bp(this,YA,"m",VM).call(this,{hasSelectedEditor:!1})}}translateSelectedEditors(e,t,n=!1){if(n||this.commitOrRemove(),!this.hasSelection)return;bp(this,xM,"f")[0]+=e,bp(this,xM,"f")[1]+=t;const[i,r]=bp(this,xM,"f"),o=[...bp(this,bM,"f")];bp(this,CM,"f")&&clearTimeout(bp(this,CM,"f")),yp(this,CM,setTimeout((()=>{yp(this,CM,null,"f"),bp(this,xM,"f")[0]=bp(this,xM,"f")[1]=0,this.addCommands({cmd:()=>{for(const e of o)bp(this,ZA,"f").has(e.id)&&e.translateInPage(i,r)},undo:()=>{for(const e of o)bp(this,ZA,"f").has(e.id)&&e.translateInPage(-i,-r)},mustExec:!1})}),1e3),"f");for(const n of o)n.translateInPage(e,t)}setUpDragSession(){if(this.hasSelection){this.disableUserSelect(!0),yp(this,oM,new Map,"f");for(const e of bp(this,bM,"f"))bp(this,oM,"f").set(e,{savedX:e.x,savedY:e.y,savedPageIndex:e.pageIndex,newX:0,newY:0,newPageIndex:-1})}}endDragSession(){if(!bp(this,oM,"f"))return!1;this.disableUserSelect(!1);const e=bp(this,oM,"f");yp(this,oM,null,"f");let t=!1;for(const[{x:n,y:i,pageIndex:r},o]of e)o.newX=n,o.newY=i,o.newPageIndex=r,t||(t=n!==o.savedX||i!==o.savedY||r!==o.savedPageIndex);if(!t)return!1;const n=(e,t,n,i)=>{if(bp(this,ZA,"f").has(e.id)){const r=bp(this,JA,"f").get(i);r?e._setParentAndPosition(r,t,n):(e.pageIndex=i,e.x=t,e.y=n)}};return this.addCommands({cmd:()=>{for(const[t,{newX:i,newY:r,newPageIndex:o}]of e)n(t,i,r,o)},undo:()=>{for(const[t,{savedX:i,savedY:r,savedPageIndex:o}]of e)n(t,i,r,o)},mustExec:!0}),!0}dragSelectedEditors(e,t){if(bp(this,oM,"f"))for(const n of bp(this,oM,"f").keys())n.drag(e,t)}rebuild(e){if(null===e.parent){const t=this.getLayer(e.pageIndex);t?(t.changeParent(e),t.addOrRebuild(e)):(this.addEditor(e),this.addToAnnotationStorage(e),e.rebuild())}else e.parent.addOrRebuild(e)}isActive(e){return bp(this,XA,"f")===e}getActive(){return bp(this,XA,"f")}getActiveEditor(){return bp(this,XA,"f")}getMode(){return bp(this,_M,"f")}getSelectionBoxes(e){if(!e)return null;const t=document.getSelection();for(let n=0,i=t.rangeCount;n<i;n++)if(!e.contains(t.getRangeAt(n).commonAncestorContainer))return null;const{x:n,y:i,width:r,height:o}=e.getBoundingClientRect();let a;switch(e.getAttribute("data-main-rotation")){case"90":a=(e,t,a,s)=>({x:(t-i)/o,y:1-(e+a-n)/r,width:s/o,height:a/r});break;case"180":a=(e,t,a,s)=>({x:1-(e+a-n)/r,y:1-(t+s-i)/o,width:a/r,height:s/o});break;case"270":a=(e,t,a,s)=>({x:1-(t+s-i)/o,y:(e-n)/r,width:s/o,height:a/r});break;default:a=(e,t,a,s)=>({x:(e-n)/r,y:(t-i)/o,width:a/r,height:s/o})}const s=[];for(let e=0,n=t.rangeCount;e<n;e++){const n=t.getRangeAt(e);if(!n.collapsed)for(const{x:e,y:t,width:i,height:r}of n.getClientRects())0!==i&&0!==r&&s.push(a(e,t,i,r))}return 0===s.length?null:s}addChangedExistingAnnotation({annotationElementId:e,id:t}){yp(this,tM,bp(this,tM,"f")||new Map,"f").set(e,t)}removeChangedExistingAnnotation({annotationElementId:e}){var t;null===(t=bp(this,tM,"f"))||void 0===t||t.delete(e)}renderAnnotationElement(e){var t;const n=null===(t=bp(this,tM,"f"))||void 0===t?void 0:t.get(e.data.id);if(!n)return;const i=bp(this,eM,"f").getRawValue(n);i&&(bp(this,_M,"f")!==PD.NONE||i.hasBeenModified)&&i.renderAnnotationElement(e)}}QA=new WeakMap,XA=new WeakMap,ZA=new WeakMap,JA=new WeakMap,eM=new WeakMap,tM=new WeakMap,nM=new WeakMap,iM=new WeakMap,rM=new WeakMap,oM=new WeakMap,aM=new WeakMap,sM=new WeakMap,lM=new WeakMap,cM=new WeakMap,dM=new WeakMap,uM=new WeakMap,hM=new WeakMap,pM=new WeakMap,fM=new WeakMap,mM=new WeakMap,gM=new WeakMap,vM=new WeakMap,_M=new WeakMap,bM=new WeakMap,yM=new WeakMap,wM=new WeakMap,kM=new WeakMap,xM=new WeakMap,CM=new WeakMap,SM=new WeakMap,TM=new WeakMap,YA=new WeakSet,DM=function({anchorNode:e}){return e.nodeType===Node.TEXT_NODE?e.parentElement:e},AM=function(e){const{currentLayer:t}=this;if(t.hasTextLayer(e))return t;for(const t of bp(this,JA,"f").values())if(t.hasTextLayer(e))return t;return null},MM=function(){const e=document.getSelection();if(!e||e.isCollapsed)return;const t=bp(this,YA,"m",DM).call(this,e),n=this.getTextLayerForAnchor(t);this.getSelectionBoxes(n)&&this.showEditorToolBar(t)},EM=function(){var e,t;const n=document.getSelection();if(!n||n.isCollapsed)return void(bp(this,yM,"f")&&(yp(this,yM,null,"f"),bp(this,YA,"m",VM).call(this,{hasSelectedText:!1})));const{anchorNode:i}=n;if(i===bp(this,yM,"f"))return;const r=bp(this,YA,"m",DM).call(this,n),o=this.getTextLayerForAnchor(r);if(o){if(null===(t=bp(this,pM,"f"))||void 0===t||t.hide(),yp(this,yM,i,"f"),bp(this,YA,"m",VM).call(this,{hasSelectedText:!0}),(bp(this,_M,"f")===PD.HIGHLIGHT||bp(this,_M,"f")===PD.NONE)&&(bp(this,_M,"f")===PD.HIGHLIGHT&&this.showAllEditors("highlight",!0),!this.isShiftKeyDown)){const e=bp(this,_M,"f")===PD.HIGHLIGHT?bp(this,YA,"m",AM).call(this,o):null;null==e||e.toggleDrawing();const t=new AbortController,n=this.combinedSignal(t),i=n=>{"pointerup"===n.type&&0!==n.button||(t.abort(),null==e||e.toggleDrawing(!0),"pointerup"===n.type&&bp(this,YA,"m",IM).call(this,"main_toolbar"))};window.removeEventListener("pointerup",i),window.addEventListener("pointerup",i,{signal:n}),window.removeEventListener("blur",i),window.addEventListener("blur",i,{signal:n})}}else bp(this,yM,"f")&&(null===(e=bp(this,pM,"f"))||void 0===e||e.hide(),yp(this,yM,null,"f"),bp(this,YA,"m",VM).call(this,{hasSelectedText:!1}))},IM=function(e=""){bp(this,_M,"f")===PD.HIGHLIGHT?this.highlightSelection(e):bp(this,lM,"f")&&bp(this,YA,"m",MM).call(this)},zM=function(){document.addEventListener("selectionchange",bp(this,YA,"m",EM).bind(this),{signal:this._signal})},PM=function(){if(bp(this,dM,"f"))return;yp(this,dM,new AbortController,"f");const e=this.combinedSignal(bp(this,dM,"f"));window.addEventListener("focus",this.focus.bind(this),{signal:e}),window.addEventListener("blur",this.blur.bind(this),{signal:e})},HM=function(){var e;null===(e=bp(this,dM,"f"))||void 0===e||e.abort(),yp(this,dM,null,"f")},FM=function(){},RM=function(){},LM=function(){},BM=function(){},OM=function(){const e=this._signal;document.addEventListener("dragover",this.dragOver.bind(this),{signal:e}),document.addEventListener("drop",this.drop.bind(this),{signal:e})},VM=function(e){if(!e)return;const t=Object.entries(e).some((([e,t])=>bp(this,kM,"f")[e]!==t));t&&(this._eventBus.dispatch("annotationeditorstateschanged",{source:this,details:Object.assign(bp(this,kM,"f"),e)}),bp(this,_M,"f")===PD.HIGHLIGHT&&!1===e.hasSelectedEditor&&bp(this,YA,"m",NM).call(this,[[RD.HIGHLIGHT_FREE,!0]]))},NM=function(e){this._eventBus.dispatch("annotationeditorparamschanged",{source:this,details:e})},$M=function(){if(!bp(this,mM,"f")){yp(this,mM,!0,"f");for(const e of bp(this,JA,"f").values())e.enable();for(const e of bp(this,ZA,"f").values())e.enable()}},UM=function(){if(this.unselectAll(),bp(this,mM,"f")){yp(this,mM,!1,"f");for(const e of bp(this,JA,"f").values())e.disable();for(const e of bp(this,ZA,"f").values())e.disable()}},WM=function(e){const t=bp(this,JA,"f").get(e.pageIndex);t?t.addOrRebuild(e):(this.addEditor(e),this.addToAnnotationStorage(e))},jM=function(){let e=null;for(e of bp(this,bM,"f"));return e},qM=function(){if(0===bp(this,ZA,"f").size)return!0;if(1===bp(this,ZA,"f").size)for(const e of bp(this,ZA,"f").values())return e.isEmpty();return!1},GM=function(e){for(const e of bp(this,bM,"f"))e.unselect();bp(this,bM,"f").clear();for(const t of e)t.isEmpty()||(bp(this,bM,"f").add(t),t.select());bp(this,YA,"m",VM).call(this,{hasSelectedEditor:this.hasSelection})},QM.TRANSLATE_SMALL=1,QM.TRANSLATE_BIG=10;new WeakMap;const XM=1,ZM=3,JM=1;function eE(e,t,n=0){let i=n,r=e.length-1;if(r<0||!t(e[r]))return e.length;if(t(e[i]))return i;for(;i<r;){const n=i+r>>1;t(e[n])?r=n:i=n+1}return i}var tE,nE,iE,rE,oE,aE,sE,lE,cE,dE,uE,hE,pE,fE,mE,gE,vE,_E,bE,yE,wE,kE,xE,CE,SE,TE,DE,AE,ME,EE,IE,zE,PE,HE,FE,RE,LE,BE,OE,VE,NE,$E,UE,WE,jE,qE,GE,KE,YE,QE,XE,ZE,JE,eI,tI;class nI{constructor(){tE.add(this),iE.set(this,!1),rE.set(this,null),oE.set(this,new Map),aE.set(this,new Map)}setTextMapping(e){yp(this,rE,e,"f")}enable(){if(bp(this,iE,"f"),!bp(this,rE,"f"))throw new Error("Text divs and strings have not been set.");if(yp(this,iE,!0,"f"),yp(this,rE,bp(this,rE,"f").slice(),"f"),bp(this,rE,"f").sort(bp(nE,nE,"m",sE)),bp(this,oE,"f").size>0){const e=bp(this,rE,"f");for(const[t,n]of bp(this,oE,"f")){document.getElementById(t)?bp(this,tE,"m",lE).call(this,t,e[n]):bp(this,oE,"f").delete(t)}}for(const[e,t]of bp(this,aE,"f"))this.addPointerInTextLayer(e,t);bp(this,aE,"f").clear()}disable(){bp(this,iE,"f")&&(bp(this,aE,"f").clear(),yp(this,rE,null,"f"),yp(this,iE,!1,"f"))}removePointerInTextLayer(e){if(!bp(this,iE,"f"))return void bp(this,aE,"f").delete(e);const t=bp(this,rE,"f");if(!t||0===t.length)return;const{id:n}=e,i=bp(this,oE,"f").get(n);if(void 0===i)return;const r=t[i];bp(this,oE,"f").delete(n);let o=r.getAttribute("aria-owns");(null==o?void 0:o.includes(n))&&(o=o.split(" ").filter((e=>e!==n)).join(" "),o?r.setAttribute("aria-owns",o):(r.removeAttribute("aria-owns"),r.setAttribute("role","presentation")))}addPointerInTextLayer(e,t){if(!e)return void console.warn("no element");const{id:n}=e;if(!n)return null;if(!bp(this,iE,"f"))return bp(this,aE,"f").set(e,t),null;t&&this.removePointerInTextLayer(e);const i=bp(this,rE,"f");if(!i||0===i.length)return null;const r=eE(i,(t=>bp(nE,nE,"m",sE).call(nE,e,t)<0)),o=Math.max(0,r-1),a=i[o];bp(this,tE,"m",lE).call(this,n,a),bp(this,oE,"f").set(n,o);const s=a.parentNode;return(null==s?void 0:s.classList.contains("markedContent"))||(null==s?void 0:s.classList.contains("k-marked-content"))?s.id:null}moveElementInDOM(e,t,n,i){const r=this.addPointerInTextLayer(n,i);if(!e.hasChildNodes())return e.append(t),r;const o=Array.from(e.children).filter((e=>e!==t));if(0===o.length)return r;const a=n||t,s=eE(o,(e=>bp(nE,nE,"m",sE).call(nE,a,e)<0));return 0===s?o[0].before(t):o[s-1].after(t),r}}nE=nI,iE=new WeakMap,rE=new WeakMap,oE=new WeakMap,aE=new WeakMap,tE=new WeakSet,sE=function(e,t){const n=e.getBoundingClientRect(),i=t.getBoundingClientRect();if(0===n.width&&0===n.height)return 1;if(0===i.width&&0===i.height)return-1;const r=n.y,o=n.y+n.height,a=n.y+n.height/2,s=i.y,l=i.y+i.height,c=i.y+i.height/2;if(a<=s&&c>=o)return-1;if(c<=r&&a>=l)return 1;return n.x+n.width/2-(i.x+i.width/2)},lE=function(e,t){const n=t.getAttribute("aria-owns");(null==n?void 0:n.includes(e))||t.setAttribute("aria-owns",n?`${n} ${e}`:e),t.removeAttribute("role")};class iI{constructor({pdfPage:e,accessibilityManager:t,styles:n,onAppend:i=null}){cE.add(this),this.pdfPage=null,this.div=null,this.accessibilityManager=null,uE.set(this,null),hE.set(this,null),this.pdfPage=e,this.accessibilityManager=t,yp(this,uE,i,"f"),this.div=document.createElement("div"),this.div.tabIndex=0,this.div.classList.add("k-text-layer"),Object.keys(n).forEach((e=>this.div.style[e]=n[e]))}render(e){return _p(this,arguments,void 0,(function*(e,t=null){var n,i,r;if(bp(this,hE,"f"))return bp(this,hE,"f").update({viewport:e,onBefore:this.hide.bind(this)}),void this.show();this.cancel(),yp(this,hE,new jD({textContentSource:this.pdfPage.streamTextContent(t||{includeMarkedContent:!1,disableNormalization:!0}),container:this.div,viewport:e}),"f");const{textDivs:o}=bp(this,hE,"f");null===(n=this.accessibilityManager)||void 0===n||n.setTextMapping(o),yield bp(this,hE,"f").render();const a=Array.from(this.div.querySelectorAll(".markedContent")||[])||[];if(a.forEach((e=>EA("k-marked-content",e))),a&&a.length>0){const e=document.createElement("div");e.className="endOfContent",this.div.append(e),bp(this,cE,"m",mE).call(this,e)}null===(i=bp(this,uE,"f"))||void 0===i||i.call(this,this.div),null===(r=this.accessibilityManager)||void 0===r||r.enable()}))}hide(){this.div.hidden||(this.div.hidden=!0)}show(){this.div.hidden&&(this.div.hidden=!1)}cancel(){var e,t;null===(e=bp(this,hE,"f"))||void 0===e||e.cancel(),yp(this,hE,null,"f"),null===(t=this.accessibilityManager)||void 0===t||t.disable(),bp(dE,dE,"m",gE).call(dE,this.div)}}function rI(e){return Math.floor(255*Math.max(0,Math.min(1,e))).toString(16).padStart(2,"0")}function oI(e){return Math.max(0,Math.min(255,255*e))}dE=iI,uE=new WeakMap,hE=new WeakMap,cE=new WeakSet,mE=function(e){const{div:t}=this;bp(dE,dE,"f",pE).set(t,e),bp(dE,dE,"m",vE).call(dE)},gE=function(e){var t;bp(this,dE,"f",pE).delete(e),0===bp(this,dE,"f",pE).size&&(null===(t=bp(this,dE,"f",fE))||void 0===t||t.abort(),yp(this,dE,null,"f",fE))},vE=function(){},pE={value:new Map},fE={value:null};class aI{static CMYK_G([e,t,n,i]){return["G",1-Math.min(1,.3*e+.59*n+.11*t+i)]}static G_CMYK([e]){return["CMYK",0,0,0,1-e]}static G_RGB([e]){return["RGB",e,e,e]}static G_rgb([e]){return[e=oI(e),e,e]}static G_HTML([e]){const t=rI(e);return`#${t}${t}${t}`}static RGB_G([e,t,n]){return["G",.3*e+.59*t+.11*n]}static RGB_rgb(e){return e.map(oI)}static RGB_HTML(e){return`#${e.map(rI).join("")}`}static T_HTML(){return"#00000000"}static T_rgb(){return[null]}static CMYK_RGB([e,t,n,i]){return["RGB",1-Math.min(1,e+i),1-Math.min(1,n+i),1-Math.min(1,t+i)]}static CMYK_rgb([e,t,n,i]){return[oI(1-Math.min(1,e+i)),oI(1-Math.min(1,n+i)),oI(1-Math.min(1,t+i))]}static CMYK_HTML(e){const t=this.CMYK_RGB(e).slice(1);return this.RGB_HTML(t)}static RGB_CMYK([e,t,n]){const i=1-e,r=1-t,o=1-n;return["CMYK",i,r,o,Math.min(i,r,o)]}}const sI=new WeakSet;function lI(e){return{width:e[2]-e[0],height:e[3]-e[1]}}class cI{constructor(e,{isRenderable:t=!1,ignoreBorder:n=!1,createQuadrilaterals:i=!1}={}){_E.add(this),this.isRenderable=null,this.data=null,this.layer=null,this.linkService=null,this.downloadManager=null,this.imageResourcesPath=null,this.renderForms=null,this.svgFactory=null,this.annotationStorage=null,this.enableScripting=null,this.hasJSActions=null,this._fieldObjects=null,this.parent=null,this.container=null,this.popup=null,this.annotationEditorType=null,bE.set(this,null),yE.set(this,!1),wE.set(this,null),this.isRenderable=t,this.data=e.data,this.layer=e.layer,this.linkService=e.linkService,this.downloadManager=e.downloadManager,this.imageResourcesPath=e.imageResourcesPath,this.renderForms=e.renderForms,this.svgFactory=e.svgFactory,this.annotationStorage=e.annotationStorage,this.enableScripting=e.enableScripting,this.hasJSActions=e.hasJSActions,this._fieldObjects=e.fieldObjects,this.parent=e.parent,t&&(this.container=this._createContainer(n)),i&&this._createQuadrilaterals()}static _hasPopupData({titleObj:e,contentsObj:t,richText:n}){return!!((null==e?void 0:e.str)||(null==t?void 0:t.str)||(null==n?void 0:n.str))}get _isEditable(){return this.data.isEditable}get hasPopupData(){return cI._hasPopupData(this.data)}updateEdited(e){var t;if(!this.container)return;yp(this,bE,bp(this,bE,"f")||{rect:this.data.rect.slice(0)},"f");const{rect:n}=e;n&&bp(this,_E,"m",kE).call(this,n),null===(t=bp(this,wE,"f"))||void 0===t||t.popup.updateEdited(e)}resetEdited(){var e;bp(this,bE,"f")&&(bp(this,_E,"m",kE).call(this,bp(this,bE,"f").rect),null===(e=bp(this,wE,"f"))||void 0===e||e.popup.resetEdited(),yp(this,bE,null,"f"))}_createContainer(e){const{data:t,parent:{page:n,viewport:i}}=this,r=document.createElement("section");r.setAttribute("data-annotation-id",t.id),this instanceof dI||(r.tabIndex=0);const{style:o}=r;if(o.zIndex=(this.parent.zIndex++).toString(),t.popupRef&&r.setAttribute("aria-haspopup","dialog"),t.alternativeText&&(r.title=t.alternativeText),t.noRotate,!t.rect||this instanceof hI){const{rotation:e}=t;return t.hasOwnCanvas||0===e||this.setRotation(e,r),r}const{width:a,height:s}=lI(t.rect);if(!e&&t.borderStyle.width>0){o.borderWidth=`${t.borderStyle.width}px`;const e=t.borderStyle.horizontalCornerRadius,n=t.borderStyle.verticalCornerRadius;if(e>0||n>0){const t=`calc(${e}px * var(--scale-factor)) / calc(${n}px * var(--scale-factor))`;o.borderRadius=t}else if(this instanceof uI){const e=`calc(${a}px * var(--scale-factor)) / calc(${s}px * var(--scale-factor))`;o.borderRadius=e}switch(t.borderStyle.style){case FA:o.borderStyle="solid";break;case RA:o.borderStyle="dashed";break;case LA:case BA:break;case OA:o.borderBottomStyle="solid"}const i=t.borderColor||null;i?(yp(this,yE,!0,"f"),o.borderColor=VD.makeHexColor(0|i[0],0|i[1],0|i[2])):o.borderWidth=(0).toString()}const l=VD.normalizeRect([t.rect[0],n.view[3]-t.rect[1]+n.view[1],t.rect[2],n.view[3]-t.rect[3]+n.view[1]]),{pageWidth:c,pageHeight:d,pageX:u,pageY:h}=i.rawDims;o.left=100*(l[0]-u)/c+"%",o.top=100*(l[1]-h)/d+"%";const{rotation:p}=t;return t.hasOwnCanvas||0===p?(o.width=100*a/c+"%",o.height=100*s/d+"%"):this.setRotation(p,r),r}setRotation(e,t=this.container){if(!this.data.rect)return;const{pageWidth:n,pageHeight:i}=this.parent.viewport.rawDims,{width:r,height:o}=lI(this.data.rect);let a,s;e%180==0?(a=100*r/n,s=100*o/i):(a=100*o/n,s=100*r/i),t.style.width=`${a}%`,t.style.height=`${s}%`,t.setAttribute("data-main-rotation",(360-e)%360)}get _commonActions(){const e=(e,t,n)=>{const i=n.detail[e],r=i[0],o=i.slice(1);n.target.style[t]=aI[`${r}_HTML`](o),this.annotationStorage.setValue(this.data.id,{[t]:aI[`${r}_rgb`](o)})};return zD(this,"_commonActions",{display:e=>{const{display:t}=e.detail,n=t%2==1;this.container.style.visibility=n?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noView:n,noPrint:1===t||2===t})},print:e=>{this.annotationStorage.setValue(this.data.id,{noPrint:!e.detail.print})},hidden:e=>{const{hidden:t}=e.detail;this.container.style.visibility=t?"hidden":"visible",this.annotationStorage.setValue(this.data.id,{noPrint:t,noView:t})},focus:e=>{setTimeout((()=>e.target.focus({preventScroll:!1})),0)},userName:e=>{e.target.title=e.detail.userName},readonly:e=>{e.target.disabled=e.detail.readonly},required:e=>{this._setRequired(e.target,e.detail.required)},bgColor:t=>{e("bgColor","backgroundColor",t)},fillColor:t=>{e("fillColor","backgroundColor",t)},fgColor:t=>{e("fgColor","color",t)},textColor:t=>{e("textColor","color",t)},borderColor:t=>{e("borderColor","borderColor",t)},strokeColor:t=>{e("strokeColor","borderColor",t)},rotation:e=>{const t=e.detail.rotation;this.setRotation(t),this.annotationStorage.setValue(this.data.id,{rotation:t})}})}_dispatchEventFromSandbox(e,t){const n=this._commonActions;for(const i of Object.keys(t.detail)){const r=e[i]||n[i];null==r||r(t)}}_setDefaultPropertiesFromJS(e){if(!this.enableScripting)return;const t=this.annotationStorage.getRawValue(this.data.id);if(!t)return;const n=this._commonActions;for(const[i,r]of Object.entries(t)){const o=n[i];if(o){o({detail:{[i]:r},target:e}),delete t[i]}}}_createQuadrilaterals(){if(!this.container)return;const{quadPoints:e}=this.data;if(!e)return;const[t,n,i,r]=this.data.rect.map((e=>Math.fround(e)));if(8===e.length){const[o,a,s,l]=e.subarray(2,6);if(i===o&&r===a&&t===s&&n===l)return}const{style:o}=this.container;let a;if(bp(this,yE,"f")){const{borderColor:e,borderWidth:t}=o;o.borderWidth=0,a=["url('data:image/svg+xml;utf8,",'<svg xmlns="http://www.w3.org/2000/svg"',' preserveAspectRatio="none" viewBox="0 0 1 1">',`<g fill="transparent" stroke="${e}" stroke-width="${t}">`]}const s=i-t,l=r-n,{svgFactory:c}=this,d=c.createElement("svg");d.setAttribute("width",0),d.setAttribute("height",0);const u=c.createElement("defs");d.append(u);const h=c.createElement("clipPath"),p=`clippath_${this.data.id}`;h.setAttribute("id",p),h.setAttribute("clipPathUnits","objectBoundingBox"),u.append(h);for(let n=2,i=e.length;n<i;n+=8){const i=e[n],o=e[n+1],d=e[n+2],u=e[n+3],p=c.createElement("rect"),f=(d-t)/s,m=(r-o)/l,g=(i-d)/s,v=(o-u)/l;p.setAttribute("x",f),p.setAttribute("y",m),p.setAttribute("width",g),p.setAttribute("height",v),h.append(p),null==a||a.push(`<rect vector-effect="non-scaling-stroke" x="${f}" y="${m}" width="${g}" height="${v}"/>`)}bp(this,yE,"f")&&(a.push("</g></svg>')"),o.backgroundImage=a.join("")),this.container.append(d),this.container.style.clipPath=`url(#${p})`}_createPopup(){}render(){}_getElementsByName(e,t=null){const n=[];if(this._fieldObjects){const i=this._fieldObjects[e];if(i)for(const{page:e,id:r,exportValues:o}of i){if(-1===e)continue;if(r===t)continue;const i="string"==typeof o?o:null,a=document.querySelector(`[data-element-id="${r}"]`);a&&!sI.has(a)||n.push({id:r,exportValue:i,domElement:a})}return n}for(const i of document.getElementsByName(e)){const{exportValue:e}=i,r=i.getAttribute("data-element-id");r!==t&&(sI.has(i)&&n.push({id:r,exportValue:e,domElement:i}))}return n}show(){var e;this.container&&(this.container.hidden=!1),null===(e=this.popup)||void 0===e||e.maybeShow()}hide(){var e;this.container&&(this.container.hidden=!0),null===(e=this.popup)||void 0===e||e.forceHide()}getElementsToTriggerPopup(){return this.container}addHighlightArea(){const e=this.getElementsToTriggerPopup();Array.isArray(e)}_editOnDoubleClick(){if(!this._isEditable)return;const{annotationEditorType:e,data:{id:t}}=this;this.container.addEventListener("dblclick",(()=>{var n,i;null===(i=null===(n=this.linkService)||void 0===n?void 0:n.eventBus)||void 0===i||i.dispatch("switchannotationeditormode",{source:this,mode:e,editId:t})}))}_setRequired(e,t){t?e.setAttribute("required",!0):e.removeAttribute("required"),e.setAttribute("aria-required",t)}}bE=new WeakMap,yE=new WeakMap,wE=new WeakMap,_E=new WeakSet,kE=function(e){const{container:{style:t},data:{rect:n,rotation:i},parent:{viewport:{rawDims:{pageWidth:r,pageHeight:o,pageX:a,pageY:s}}}}=this;null==n||n.splice(0,4,...e);const{width:l,height:c}=lI(e);t.left=100*(e[0]-a)/r+"%",t.top=100*(o-e[3]+s)/o+"%",0===i?(t.width=100*l/r+"%",t.height=100*c/o+"%"):this.setRotation(i)};xE=new WeakSet,CE=function(){this.container.setAttribute("data-internal-link","")};class dI extends cI{render(){return this.container}showElementAndHideCanvas(e){var t;this.data.hasOwnCanvas&&("CANVAS"===(null===(t=e.previousSibling)||void 0===t?void 0:t.nodeName)&&(e.previousSibling.hidden=!0),e.hidden=!1)}_getKeyModifier(e){return HD.platform.isMac?e.metaKey:e.ctrlKey}_setEventListener(e,t,n,i,r){n.includes("mouse")?e.addEventListener(n,(e=>{var t;null===(t=this.linkService.eventBus)||void 0===t||t.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:i,value:r(e),shift:e.shiftKey,modifier:this._getKeyModifier(e)}})})):e.addEventListener(n,(e=>{var o;if("blur"===n){if(!t.focused||!e.relatedTarget)return;t.focused=!1}else if("focus"===n){if(t.focused)return;t.focused=!0}r&&(null===(o=this.linkService.eventBus)||void 0===o||o.dispatch("dispatcheventinsandbox",{source:this,detail:{id:this.data.id,name:i,value:r(e)}}))}))}_setEventListeners(e,t,n,i){var r,o,a;for(const[s,l]of n)("Action"===l||(null===(r=this.data.actions)||void 0===r?void 0:r[l]))&&("Focus"!==l&&"Blur"!==l||t||(t={focused:!1}),this._setEventListener(e,t,s,l,i),"Focus"!==l||(null===(o=this.data.actions)||void 0===o?void 0:o.Blur)?"Blur"!==l||(null===(a=this.data.actions)||void 0===a?void 0:a.Focus)||this._setEventListener(e,t,"focus","Focus",null):this._setEventListener(e,t,"blur","Blur",null))}_setBackgroundColor(e){const t=this.data.backgroundColor||null;e.style.backgroundColor=null===t?"transparent":VD.makeHexColor(t[0],t[1],t[2])}_setTextStyle(e){const t=["left","center","right"],{fontColor:n}=this.data.defaultAppearanceData,i=this.data.defaultAppearanceData.fontSize||9,r=e.style;let o;const a=e=>Math.round(10*e)/10;if(this.data.multiLine){const e=Math.abs(this.data.rect[3]-this.data.rect[1]-2),t=e/(Math.round(e/(IA*i))||1);o=Math.min(i,a(t/IA))}else{const e=Math.abs(this.data.rect[3]-this.data.rect[1]-2);o=Math.min(i,a(e/IA))}r.fontSize=`calc(${o}px * var(--scale-factor))`,r.color=VD.makeHexColor(n[0],n[1],n[2]),null!==this.data.textAlignment&&(r.textAlign=t[this.data.textAlignment])}_setRequired(e,t){t?e.setAttribute("required",!0):e.removeAttribute("required"),e.setAttribute("aria-required",t)}}class uI extends dI{constructor(e){super(e,{isRenderable:e.renderForms})}render(){this.container.classList.add("buttonWidgetAnnotation","radioButton");const e=this.annotationStorage,t=this.data,n=t.id;let i=e.getValue(n,{value:t.fieldValue===t.buttonValue}).value;if("string"==typeof i&&(i=i!==t.buttonValue,e.setValue(n,{value:i})),i)for(const i of this._getElementsByName(t.fieldName,n))e.setValue(i.id,{value:!1});const r=document.createElement("input");if(sI.add(r),r.setAttribute("data-element-id",n),r.disabled=t.readOnly,this._setRequired(r,this.data.required),r.type="radio",r.name=t.fieldName,i&&r.setAttribute("checked",(!0).toString()),r.tabIndex=0,r.addEventListener("change",(t=>{const{name:i,checked:r}=t.target;for(const t of this._getElementsByName(i,n))e.setValue(t.id,{value:!1});e.setValue(n,{value:r})})),r.addEventListener("resetform",(e=>{const n=t.defaultFieldValue;e.target.checked=null!=n&&n===t.buttonValue})),this.enableScripting&&this.hasJSActions){const i=t.buttonValue;r.addEventListener("updatefromsandbox",(t=>{const r={value:t=>{const r=i===t.detail.value;for(const i of this._getElementsByName(t.target.name)){const t=r&&i.id===n;i.domElement&&(i.domElement.checked=t),e.setValue(i.id,{value:t})}}};this._dispatchEventFromSandbox(r,t)})),this._setEventListeners(r,null,[["change","Validate"],["change","Action"],["focus","Focus"],["blur","Blur"],["mousedown","Mouse Down"],["mouseenter","Mouse Enter"],["mouseleave","Mouse Exit"],["mouseup","Mouse Up"]],(e=>e.target.checked))}return this._setBackgroundColor(r),this._setDefaultPropertiesFromJS(r),this.container.append(r),this.container}}class hI extends cI{constructor(e){const{data:t,elements:n}=e;super(e,{isRenderable:cI._hasPopupData(t)}),this.elements=[],this.elements=n,this.popup=null}render(){this.container.classList.add("popupAnnotation");const e=this.popup=new pI({container:this.container,color:this.data.color,titleObj:this.data.titleObj,modificationDate:this.data.modificationDate,contentsObj:this.data.contentsObj,richText:this.data.richText,rect:this.data.rect,parentRect:this.data.parentRect||null,parent:this.parent,elements:this.elements,open:this.data.open}),t=[];for(const n of this.elements)n.popup=e,t.push(n.data.id),n.addHighlightArea();return this.container.setAttribute("aria-controls",t.map((e=>`${UA}${e}`)).join(",")),this.container}}class pI{constructor({container:e,color:t,elements:n,titleObj:i,modificationDate:r,contentsObj:o,richText:a,parent:s,rect:l,parentRect:c,open:d}){var u;SE.add(this),this.trigger=null,TE.set(this,bp(this,SE,"m",YE).bind(this)),DE.set(this,bp(this,SE,"m",JE).bind(this)),AE.set(this,bp(this,SE,"m",ZE).bind(this)),ME.set(this,bp(this,SE,"m",XE).bind(this)),EE.set(this,null),IE.set(this,null),zE.set(this,null),PE.set(this,null),HE.set(this,null),FE.set(this,null),RE.set(this,null),LE.set(this,!1),BE.set(this,null),OE.set(this,null),VE.set(this,null),NE.set(this,null),$E.set(this,null),UE.set(this,null),WE.set(this,!1),yp(this,IE,e,"f"),yp(this,$E,i,"f"),yp(this,zE,o,"f"),yp(this,NE,a,"f"),yp(this,FE,s,"f"),yp(this,EE,t,"f"),yp(this,VE,l,"f"),yp(this,RE,c,"f"),yp(this,HE,n,"f"),yp(this,PE,OD.toDateObject(r),"f"),this.trigger=n.flatMap((e=>e.getElementsToTriggerPopup()));for(const e of this.trigger)e.addEventListener("click",bp(this,ME,"f")),e.addEventListener("mouseenter",bp(this,AE,"f")),e.addEventListener("mouseleave",bp(this,DE,"f")),e.classList.add("popupTriggerArea");for(const e of n)null===(u=e.container)||void 0===u||u.addEventListener("keydown",bp(this,TE,"f"));bp(this,IE,"f").hidden=!0,d&&bp(this,SE,"m",XE).call(this),bp(this,FE,"f").popupShow.push((()=>_p(this,void 0,void 0,(function*(){bp(this,IE,"f").hidden&&bp(this,SE,"m",ZE).call(this)}))))}render(){if(bp(this,BE,"f"))return;const e=yp(this,BE,document.createElement("div"),"f");if(e.className="popup",bp(this,EE,"f")){const t=e.style.outlineColor=VD.makeHexColor(...bp(this,EE,"f"));if(CSS.supports("background-color","color-mix(in srgb, red 30%, white)"))e.style.backgroundColor=`color-mix(in srgb, ${t} 30%, white)`;else{const t=.7;e.style.backgroundColor=VD.makeHexColor(...bp(this,EE,"f").map((e=>Math.floor(t*(255-e)+e))))}}const t=document.createElement("span");t.className="header";const n=document.createElement("h1");if(t.append(n),({dir:n.dir,str:n.textContent}=bp(this,$E,"f")),e.append(t),bp(this,PE,"f")){const e=document.createElement("span");e.classList.add("popupDate"),e.setAttribute("data-l10n-id","pdfjs-annotation-date-string"),e.setAttribute("data-l10n-args",JSON.stringify({date:bp(this,PE,"f").toLocaleDateString(),time:bp(this,PE,"f").toLocaleTimeString()})),t.append(e)}const i=bp(this,SE,"a",jE);if(i)ND.render({xfaHtml:i,intent:"richText",div:e}),e.lastChild.classList.add("richText","popupContent");else{const t=this._formatContents(bp(this,zE,"f"));e.append(t)}bp(this,IE,"f").append(e)}_formatContents({str:e,dir:t}){const n=document.createElement("p");n.classList.add("popupContent"),n.dir=t;const i=e.split(/(?:\r\n?|\n)/);for(let e=0,t=i.length;e<t;++e){const r=i[e];n.append(document.createTextNode(r)),e<t-1&&n.append(document.createElement("br"))}return n}updateEdited({rect:e,popupContent:t}){var n;yp(this,UE,bp(this,UE,"f")||{contentsObj:bp(this,zE,"f"),richText:bp(this,NE,"f")},"f"),e&&yp(this,OE,null,"f"),t&&(yp(this,NE,bp(this,SE,"m",KE).call(this,t),"f"),yp(this,zE,null,"f")),null===(n=bp(this,BE,"f"))||void 0===n||n.remove(),yp(this,BE,null,"f")}resetEdited(){var e,t,n;bp(this,UE,"f")&&(t=this,n=this,({contentsObj:{set value(e){yp(t,zE,e,"f")}}.value,richText:{set value(e){yp(n,NE,e,"f")}}.value}=bp(this,UE,"f")),yp(this,UE,null,"f"),null===(e=bp(this,BE,"f"))||void 0===e||e.remove(),yp(this,BE,null,"f"),yp(this,OE,null,"f"))}forceHide(){yp(this,WE,this.isVisible,"f"),bp(this,WE,"f")&&(bp(this,IE,"f").hidden=!0)}maybeShow(){bp(this,WE,"f")&&(bp(this,BE,"f")||bp(this,SE,"m",ZE).call(this),yp(this,WE,!1,"f"),bp(this,IE,"f").hidden=!1)}get isVisible(){return!1===bp(this,IE,"f").hidden}}TE=new WeakMap,DE=new WeakMap,AE=new WeakMap,ME=new WeakMap,EE=new WeakMap,IE=new WeakMap,zE=new WeakMap,PE=new WeakMap,HE=new WeakMap,FE=new WeakMap,RE=new WeakMap,LE=new WeakMap,BE=new WeakMap,OE=new WeakMap,VE=new WeakMap,NE=new WeakMap,$E=new WeakMap,UE=new WeakMap,WE=new WeakMap,SE=new WeakSet,jE=function(){const e=bp(this,NE,"f"),t=bp(this,zE,"f");return!(null==e?void 0:e.str)||(null==t?void 0:t.str)&&t.str!==e.str?null:bp(this,NE,"f").html||null},qE=function(){var e,t,n;return(null===(n=null===(t=null===(e=bp(this,SE,"a",jE))||void 0===e?void 0:e.attributes)||void 0===t?void 0:t.style)||void 0===n?void 0:n.fontSize)||0},GE=function(){var e,t,n;return(null===(n=null===(t=null===(e=bp(this,SE,"a",jE))||void 0===e?void 0:e.attributes)||void 0===t?void 0:t.style)||void 0===n?void 0:n.color)||null},KE=function(e){const t=[],n={str:e,html:{name:"div",attributes:{dir:"auto"},children:[{name:"p",children:t}]}},i={style:{color:bp(this,SE,"a",GE),fontSize:bp(this,SE,"a",qE)?`calc(${bp(this,SE,"a",qE)}px * var(--scale-factor))`:""}};for(const n of e.split("\n"))t.push({name:"span",value:n,attributes:i});return n},YE=function(e){e.altKey||e.shiftKey||e.ctrlKey||e.metaKey||("Enter"===e.key||"Escape"===e.key&&bp(this,LE,"f"))&&bp(this,SE,"m",XE).call(this)},QE=function(){if(null!==bp(this,OE,"f"))return;const{page:{view:e},viewport:{rawDims:{pageWidth:t,pageHeight:n,pageX:i,pageY:r}}}=bp(this,FE,"f");let o=!!bp(this,RE,"f"),a=bp(this,o?RE:VE,"f");for(const e of bp(this,HE,"f"))if(!a||null!==VD.intersect(e.data.rect,a)){a=e.data.rect,o=!0;break}const s=VD.normalizeRect([a[0],e[3]-a[1]+e[1],a[2],e[3]-a[3]+e[1]]),l=o?a[2]-a[0]+5:0,c=s[0]+l,d=s[1];yp(this,OE,[100*(c-i)/t,100*(d-r)/n],"f");const{style:u}=bp(this,IE,"f");u.left=`${bp(this,OE,"f")[0]}%`,u.top=`${bp(this,OE,"f")[1]}%`},XE=function(){yp(this,LE,!bp(this,LE,"f"),"f"),bp(this,LE,"f")?(bp(this,SE,"m",ZE).call(this),bp(this,IE,"f").addEventListener("click",bp(this,ME,"f")),bp(this,IE,"f").addEventListener("keydown",bp(this,TE,"f"))):(bp(this,SE,"m",JE).call(this),bp(this,IE,"f").removeEventListener("click",bp(this,ME,"f")),bp(this,IE,"f").removeEventListener("keydown",bp(this,TE,"f")))},ZE=function(){bp(this,BE,"f")||this.render(),this.isVisible?bp(this,LE,"f")&&bp(this,IE,"f").classList.add("focused"):(bp(this,SE,"m",QE).call(this),bp(this,IE,"f").hidden=!1,bp(this,IE,"f").style.zIndex=(parseInt(bp(this,IE,"f").style.zIndex,10)+1e3).toString())},JE=function(){bp(this,IE,"f").classList.remove("focused"),!bp(this,LE,"f")&&this.isVisible&&(bp(this,IE,"f").hidden=!0,bp(this,IE,"f").style.zIndex=(parseInt(bp(this,IE,"f").style.zIndex,10)-1e3).toString())};class fI extends cI{constructor(e){super(e,{isRenderable:!0,ignoreBorder:!0}),this.textContent=null,this.textPosition=null,this.textContent=e.data.textContent,this.textPosition=e.data.textPosition,this.annotationEditorType=PD.FREETEXT}render(){if(this.container.classList.add("k-free-text-annotation"),this.textContent){const e=document.createElement("div");e.classList.add("k-annotation-text-content"),e.setAttribute("role","comment");for(const t of this.textContent){const n=document.createElement("span");n.textContent=t,e.append(n)}this.container.append(e)}return this._editOnDoubleClick(),this.container}}var mI,gI,vI,_I,bI,yI,wI,kI,xI,CI,SI,TI,DI,AI,MI,EI,II,zI,PI,HI,FI,RI,LI,BI,OI,VI,NI,$I,UI,WI,jI,qI,GI,KI,YI,QI,XI,ZI,JI,ez,tz,nz,iz,rz,oz,az,sz,lz;eI=new WeakMap,tI=new WeakMap,new WeakMap,new WeakSet;new WeakMap,new WeakMap,new WeakSet;class cz{constructor({pageIndex:e}){mI.add(this),this.pageIndex=0,vI.set(this,null),_I.set(this,0),bI.set(this,new Map),yI.set(this,new Map),this.pageIndex=e}setParent(e){if(bp(this,vI,"f")){if(bp(this,vI,"f")!==e){if(bp(this,bI,"f").size>0)for(const t of bp(this,bI,"f").values())t.remove(),e.append(t);yp(this,vI,e,"f")}}else yp(this,vI,e,"f")}static get _svgFactory(){return zD(this,"_svgFactory",new BD)}highlight(e,t,n,i=!1){var r,o;const a=(yp(this,_I,(o=bp(this,_I,"f"),r=o++,o),"f"),r),s=bp(this,mI,"m",kI).call(this,e.box);s.classList.add("k-highlight"),e.free;const l=gI._svgFactory.createElement("defs");s.append(l);const c=gI._svgFactory.createElement("path");l.append(c);const d=`path_p${this.pageIndex}_${a}`;c.setAttribute("id",d),c.setAttribute("d",e.toSVGPath()),i&&bp(this,yI,"f").set(a,c);const u=bp(this,mI,"m",xI).call(this,l,d),h=gI._svgFactory.createElement("use");return s.append(h),s.setAttribute("fill",t),s.setAttribute("fill-opacity",n),h.setAttribute("href",`#${d}`),bp(this,bI,"f").set(a,s),{id:a,clipPathId:`url(#${u})`}}highlightOutline(e){var t,n;const i=(yp(this,_I,(n=bp(this,_I,"f"),t=n++,n),"f"),t),r=bp(this,mI,"m",kI).call(this,e.box);r.classList.add("k-highlight-outline");const o=gI._svgFactory.createElement("defs");r.append(o);const a=gI._svgFactory.createElement("path");o.append(a);const s=`path_p${this.pageIndex}_${i}`;let l;if(a.setAttribute("id",s),a.setAttribute("d",e.toSVGPath()),a.setAttribute("vector-effect","non-scaling-stroke"),e.free){const e=gI._svgFactory.createElement("mask");o.append(e),l=`mask_p${this.pageIndex}_${i}`,e.setAttribute("id",l),e.setAttribute("maskUnits","objectBoundingBox");const t=gI._svgFactory.createElement("rect");e.append(t),t.setAttribute("width","1"),t.setAttribute("height","1"),t.setAttribute("fill","white");const n=gI._svgFactory.createElement("use");e.append(n),n.setAttribute("href",`#${s}`),n.setAttribute("stroke","none"),n.setAttribute("fill","black"),n.setAttribute("fill-rule","nonzero")}const c=gI._svgFactory.createElement("use");r.append(c),c.setAttribute("href",`#${s}`),l&&c.setAttribute("mask",`url(#${l})`);const d=c.cloneNode();return r.append(d),bp(this,bI,"f").set(i,r),i}finalizeLine(e,t){const n=bp(this,yI,"f").get(e);bp(this,yI,"f").delete(e),this.updateBox(e,t.box),n.setAttribute("d",t.toSVGPath())}updateLine(e,t){bp(this,bI,"f").get(e).firstChild.firstChild.setAttribute("d",t.toSVGPath())}removeFreeHighlight(e){this.remove(e),bp(this,yI,"f").delete(e)}updatePath(e,t){bp(this,yI,"f").get(e).setAttribute("d",t.toSVGPath())}updateBox(e,t){bp(gI,gI,"m",wI).call(gI,bp(this,bI,"f").get(e),t)}show(e,t){bp(this,bI,"f").get(e).classList.toggle("k-hidden",!t)}rotate(e,t){bp(this,bI,"f").get(e).setAttribute("data-main-rotation",t)}changeColor(e,t){bp(this,bI,"f").get(e).setAttribute("fill",t)}changeOpacity(e,t){bp(this,bI,"f").get(e).setAttribute("fill-opacity",t)}addClass(e,t){bp(this,bI,"f").get(e).classList.add(t)}removeClass(e,t){bp(this,bI,"f").get(e).classList.remove(t)}remove(e){null!==bp(this,vI,"f")&&(bp(this,bI,"f").get(e).remove(),bp(this,bI,"f").delete(e))}destroy(){yp(this,vI,null,"f");for(const e of bp(this,bI,"f").values())e.remove();bp(this,bI,"f").clear()}}gI=cz,vI=new WeakMap,_I=new WeakMap,bI=new WeakMap,yI=new WeakMap,mI=new WeakSet,wI=function(e,{x:t=0,y:n=0,width:i=1,height:r=1}={}){const{style:o}=e;o.top=100*n+"%",o.left=100*t+"%",o.width=100*i-.2+"%",o.height=100*r-.2+"%"},kI=function(e){const t=gI._svgFactory.create(1,1,!0);return bp(this,vI,"f").append(t),t.setAttribute("aria-hidden",!0),bp(gI,gI,"m",wI).call(gI,t,e),t},xI=function(e,t){const n=gI._svgFactory.createElement("clipPath");e.append(n);const i=`clip_${t}`;n.setAttribute("id",i),n.setAttribute("clipPathUnits","objectBoundingBox");const r=gI._svgFactory.createElement("use");return n.append(r),r.setAttribute("href",`#${t}`),i};function dz(e){if(e.startsWith("#")){const t=parseInt(e.slice(1),16);return[(16711680&t)>>16,(65280&t)>>8,255&t]}return e.startsWith("rgb(")?e.slice(4,-1).split(",").map((e=>parseInt(e,10))):e.startsWith("rgba(")?e.slice(5,-1).split(",").map((e=>parseInt(e,10))).slice(0,3):[0,0,0]}new WeakMap;class uz{get _colors(){if("undefined"==typeof document)return VA(this,"_colors",uz._colorsMapping);const e=new Map([["CanvasText",null],["Canvas",null]]);return function(e){const t=document.createElement("span");t.style.visibility="hidden",document.body.append(t);for(const n of e.keys()){t.style.color=n;const i=window.getComputedStyle(t).color;e.set(n,dz(i))}t.remove()}(e),VA(this,"_colors",e)}convert(e){const t=dz(e);if(!window.matchMedia("(forced-colors: active)").matches)return t;for(const[e,n]of this._colors)if(n.every(((e,n)=>e===t[n])))return uz._colorsMapping.get(e);return t}getHexCode(e){const t=this._colors.get(e);return t?$A.makeHexColor(...t):e}}function hz(e,t,n){for(const i of n)t.addEventListener(i,e[i].bind(e))}uz._colorsMapping=new Map([["CanvasText",[0,0,0]],["Canvas",[255,255,255]]]);class pz{constructor(e){CI.add(this),this.parent=null,this.id=null,this.width=null,this.height=null,this.pageIndex=0,this.name="",this.div=null,this.annotationElementId=null,this._willKeepAspectRatio=!1,this._structTreeParentId=null,this.rotation=0,this.pageRotation=0,this.pageDimensions=[],this.pageTranslation=[],TI.set(this,0),DI.set(this,0),this.isAttachedToDOM=!1,this.deleted=!1,AI.set(this,!1),MI.set(this,!1),EI.set(this,null),II.set(this,!1),zI.set(this,null),PI.set(this,!1),HI.set(this,!1),FI.set(this,null),RI.set(this,0),LI.set(this,0),this._editToolbar=null,this._initialOptions=Object.create(null),this._isVisible=!0,this._uiManager=null,this._focusEventsAllowed=!0,this._l10nPromise=null,BI.set(this,!1),OI.set(this,SI._zIndex++),this.parent=e.parent,this.id=e.id||SI.idManager.id,this.width=this.height=null,this.pageIndex=e.parent.pageIndex,this.name=e.name,this.div=null,this._uiManager=e.uiManager,this.annotationElementId=null,this._willKeepAspectRatio=!1,this._initialOptions.isCentered=e.isCentered,this._structTreeParentId=null;const{rotation:t,rawDims:{pageWidth:n,pageHeight:i,pageX:r,pageY:o}}=this.parent.viewport;this.rotation=t,this.pageRotation=(360+t-this._uiManager.viewParameters.rotation)%360,this.pageDimensions=[n,i],this.pageTranslation=[r,o];const[a,s]=this.parentDimensions;this.x=e.x/a,this.y=e.y/s,this.isAttachedToDOM=!1,this.deleted=!1}get x(){return bp(this,TI,"f")}set x(e){yp(this,TI,e,"f")}get y(){return bp(this,DI,"f")}set y(e){yp(this,DI,e,"f")}get editorType(){return Object.getPrototypeOf(this).constructor._type}static get _defaultLineColor(){return zD(this,"_defaultLineColor",this._colorManager.getHexCode("CanvasText"))}static deleteAnnotationElement(e){const t=new fz({id:e.parent.getNextId(),parent:e.parent,uiManager:e._uiManager});t.annotationElementId=e.annotationElementId,t.deleted=!0,t._uiManager.addToAnnotationStorage(t)}static initialize(e,t,n){}static updateDefaultParams(e,t){}static get defaultPropertiesToUpdate(){return[]}static isHandlingMimeForPasting(e){if(e)return!1}static paste(e,t){}get propertiesToUpdate(){return[]}get _isDraggable(){return bp(this,BI,"f")}set _isDraggable(e){var t;yp(this,BI,e,"f"),null===(t=this.div)||void 0===t||t.classList.toggle("k-draggable",e)}get isEnterHandled(){return!0}center(){const[e,t]=this.pageDimensions;switch(this.parentRotation){case 90:this.x-=this.height*t/(2*e),this.y+=this.width*e/(2*t);break;case 180:this.x+=this.width/2,this.y+=this.height/2;break;case 270:this.x+=this.height*t/(2*e),this.y-=this.width*e/(2*t);break;default:this.x-=this.width/2,this.y-=this.height/2}this.fixAndSetPosition()}addCommands(e){this._uiManager.addCommands(e)}get currentLayer(){return this._uiManager.currentLayer}setInBackground(){this.div.style.zIndex=0}setInForeground(){this.div.style.zIndex=bp(this,OI,"f")}setParent(e){null!==e?(this.pageIndex=e.pageIndex,this.pageDimensions=e.pageDimensions):bp(this,CI,"m",jI).call(this),this.parent=e}focusin(e){e&&this._focusEventsAllowed&&(bp(this,II,"f")?yp(this,II,!1,"f"):this.parent.setSelected(this))}focusout(e){var t;if(!this._focusEventsAllowed)return;if(!this.isAttachedToDOM)return;const n=e.relatedTarget;(null==n?void 0:n.closest(`#${this.id}`))||(e.preventDefault(),(null===(t=this.parent)||void 0===t?void 0:t.isMultipleSelection)||this.commitOrRemove())}commitOrRemove(){this.isEmpty()?this.remove():this.commit()}commit(){this.addToAnnotationStorage()}addToAnnotationStorage(){this._uiManager.addToAnnotationStorage(this)}setAt(e,t,n,i){const[r,o]=this.parentDimensions;[n,i]=this.screenToPageTranslation(n,i),this.x=(e+n)/r,this.y=(t+i)/o,this.fixAndSetPosition()}translate(e,t){bp(this,CI,"m",VI).call(this,this.parentDimensions,e,t)}translateInPage(e,t){yp(this,zI,bp(this,zI,"f")||[this.x,this.y],"f"),bp(this,CI,"m",VI).call(this,this.pageDimensions,e,t),this.div.scrollIntoView({block:"nearest"})}drag(e,t){yp(this,zI,bp(this,zI,"f")||[this.x,this.y],"f");const[n,i]=this.parentDimensions;if(this.x+=e/n,this.y+=t/i,this.parent&&(this.x<0||this.x>1||this.y<0||this.y>1)){const{x:e,y:t}=this.div.getBoundingClientRect();this.parent.findNewParent(this,e,t)&&(this.x-=Math.floor(this.x),this.y-=Math.floor(this.y))}let{x:r,y:o}=this;const[a,s]=this.getBaseTranslation();r+=a,o+=s,this.div.style.left=`${(100*r).toFixed(2)}%`,this.div.style.top=`${(100*o).toFixed(2)}%`,this.div.scrollIntoView({block:"nearest"})}get _hasBeenMoved(){return!!bp(this,zI,"f")&&(bp(this,zI,"f")[0]!==this.x||bp(this,zI,"f")[1]!==this.y)}getBaseTranslation(){const[e,t]=this.parentDimensions,{_borderLineWidth:n}=SI,i=n/e,r=n/t;switch(this.rotation){case 90:return[-i,r];case 180:return[i,r];case 270:return[i,-r];default:return[-i,-r]}}get _mustFixPosition(){return!0}fixAndSetPosition(e=this.rotation){if(void 0===e)return;const[t,n]=this.pageDimensions;let{x:i,y:r,width:o,height:a}=this;if(o*=t,a*=n,i*=t,r*=n,this._mustFixPosition)switch(e){case 0:i=Math.max(0,Math.min(t-o,i)),r=Math.max(0,Math.min(n-a,r));break;case 90:i=Math.max(0,Math.min(t-a,i)),r=Math.min(n,Math.max(o,r));break;case 180:i=Math.min(t,Math.max(o,i)),r=Math.min(n,Math.max(a,r));break;case 270:i=Math.min(t,Math.max(a,i)),r=Math.max(0,Math.min(n-o,r))}this.x=i/=t,this.y=r/=n;const[s,l]=this.getBaseTranslation();i+=s,r+=l;const{style:c}=this.div;c.left=`${(100*i).toFixed(2)}%`,c.top=`${(100*r).toFixed(2)}%`,this.moveInDOM()}screenToPageTranslation(e,t){return bp(SI,SI,"m",NI).call(SI,e,t,this.parentRotation)}pageTranslationToScreen(e,t){return bp(SI,SI,"m",NI).call(SI,e,t,360-this.parentRotation)}get parentScale(){return this._uiManager.viewParameters.realScale}get parentRotation(){return(this._uiManager.viewParameters.rotation+this.pageRotation)%360}get parentDimensions(){const{parentScale:e,pageDimensions:[t,n]}=this,i=t*e,r=n*e;return HD.isCSSRoundSupported?[Math.round(i),Math.round(r)]:[i,r]}setDims(e,t){const[n,i]=this.parentDimensions;this.div.style.width=`${(100*e/n).toFixed(2)}%`,bp(this,MI,"f")||(this.div.style.height=`${(100*t/i).toFixed(2)}%`)}fixDims(){}getInitialTranslation(){return[0,0]}addEditToolbar(){var e;null===(e=this._uiManager)||void 0===e||e.showEditorToolBar(this.div)}removeEditToolbar(){this._uiManager.hideEditorToolBar()}getClientDimensions(){return this.div.getBoundingClientRect()}render(){this.div=document.createElement("div"),this.div.setAttribute("data-editor-rotation",(360-this.rotation)%360),this.div.className=this.name,this.div.setAttribute("id",this.id),this.div.tabIndex=bp(this,AI,"f")?-1:0,this._isVisible||this.div.classList.add("k-hidden"),this.setInForeground(),bp(this,CI,"m",WI).call(this);const[e,t]=this.parentDimensions;this.parentRotation%180!=0&&(this.div.style.maxWidth=`${(100*t/e).toFixed(2)}%`,this.div.style.maxHeight=`${(100*e/t).toFixed(2)}%`);const[n,i]=this.getInitialTranslation();return this.translate(n,i),hz(this,this.div,["pointerdown"]),this.div}pointerdown(e){var t;const{isMac:n}=HD.platform;if(0!==e.button||e.ctrlKey&&n)e.preventDefault();else{if(yp(this,II,!0,"f"),this._isDraggable)return null===(t=this._uiManager)||void 0===t||t.hideEditorToolBar(),void bp(this,CI,"m",UI).call(this,e);bp(this,CI,"m",$I).call(this,e)}}moveInDOM(){bp(this,FI,"f")&&clearTimeout(bp(this,FI,"f")),yp(this,FI,setTimeout((()=>{var e;yp(this,FI,null,"f"),null===(e=this.parent)||void 0===e||e.moveEditorInDOM(this)}),0),"f")}_setParentAndPosition(e,t,n){e.changeParent(this),this.x=t,this.y=n,this.fixAndSetPosition()}getRect(e,t,n=this.rotation){const i=this.parentScale,[r,o]=this.pageDimensions,[a,s]=this.pageTranslation,l=e/i,c=t/i,d=this.x*r,u=this.y*o,h=this.width*r,p=this.height*o;switch(n){case 0:return[d+l+a,o-u-c-p+s,d+l+h+a,o-u-c+s];case 90:return[d+c+a,o-u+l+s,d+c+p+a,o-u+l+h+s];case 180:return[d-l-h+a,o-u+c+s,d-l+a,o-u+c+p+s];case 270:return[d-c-p+a,o-u-l-h+s,d-c+a,o-u-l+s];default:throw new Error("Invalid rotation")}}getRectInCurrentCoords(e,t){const[n,i,r,o]=e,a=r-n,s=o-i;switch(this.rotation){case 0:return[n,t-o,a,s];case 90:return[n,t-i,s,a];case 180:return[r,t-i,a,s];case 270:return[r,t-o,s,a]}}onceAdded(){}isEmpty(){return!1}enableEditMode(){yp(this,HI,!0,"f")}disableEditMode(){yp(this,HI,!1,"f")}isInEditMode(){return bp(this,HI,"f")}needsToBeRebuilt(){return this.div&&!this.isAttachedToDOM}rebuild(){bp(this,CI,"m",WI).call(this)}rotate(e){}serialize(e=!1,t=null){}static deserialize(e,t,n){const i=new this.prototype.constructor({parent:t,id:t.getNextId(),uiManager:n});i.rotation=e.rotation;const[r,o]=i.pageDimensions,[a,s,l,c]=i.getRectInCurrentCoords(e.rect,o);return i.x=a/r,i.y=s/o,i.width=l/r,i.height=c/o,i}get hasBeenModified(){return!!this.annotationElementId&&(this.deleted||null!==this.serialize())}remove(){var e;null===(e=bp(this,EI,"f"))||void 0===e||e.abort(),yp(this,EI,null,"f"),this.isEmpty()||this.commit(),this.parent?this.parent.remove(this):this._uiManager.removeEditor(this),bp(this,FI,"f")&&(clearTimeout(bp(this,FI,"f")),yp(this,FI,null,"f")),bp(this,CI,"m",jI).call(this),this.removeEditToolbar(),this.parent=null}get isResizable(){return!1}makeResizable(){}get toolbarPosition(){return null}_stopResizingWithKeyboard(){}select(){var e;null===(e=this.div)||void 0===e||e.classList.add("k-selected"),this.addEditToolbar()}unselect(){var e,t;null===(e=this.div)||void 0===e||e.classList.remove("k-selected"),(null===(t=this.div)||void 0===t?void 0:t.contains(document.activeElement))&&this._uiManager.currentLayer.div.focus({preventScroll:!0})}updateParams(e,t){}disableEditing(){}enableEditing(){}enterInEditMode(){}getImageForAltText(){return null}get contentDiv(){return this.div}get isEditing(){return bp(this,PI,"f")}set isEditing(e){yp(this,PI,e,"f"),this.parent&&(e?(this.parent.setSelected(this),this.parent.setActiveEditor(this)):this.parent.setActiveEditor(null))}setAspectRatio(e,t){yp(this,MI,!0,"f");const n=e/t,{style:i}=this.div;i.aspectRatio=n,i.height="auto"}static get MIN_SIZE(){return 16}static canCreateNewEmptyEditor(){return!0}get telemetryInitialData(){return{action:"added"}}get telemetryFinalData(){return null}_reportTelemetry(){}show(e=this._isVisible){this.div.classList.toggle("k-hidden",!e),this._isVisible=e}enable(){this.div&&(this.div.tabIndex=0),yp(this,AI,!1,"f")}disable(){this.div&&(this.div.tabIndex=-1),yp(this,AI,!0,"f")}renderAnnotationElement(e){let t=e.container.querySelector(".annotationContent")||e.container.querySelector(".k-annotation-content ");if(t){if("CANVAS"===t.nodeName){const e=t;t=document.createElement("div"),t.classList.add("k-annotation-content ",this.editorType),e.before(t)}}else t=document.createElement("div"),t.classList.add("k-annotation-content ",this.editorType),e.container.prepend(t);return t}resetAnnotationElement(e){const{firstChild:t}=e.container;"DIV"===t.nodeName&&(t.classList.contains("annotationContent")||t.classList.contains("k-annotation-content "))&&t.remove()}}SI=pz,TI=new WeakMap,DI=new WeakMap,AI=new WeakMap,MI=new WeakMap,EI=new WeakMap,II=new WeakMap,zI=new WeakMap,PI=new WeakMap,HI=new WeakMap,FI=new WeakMap,RI=new WeakMap,LI=new WeakMap,BI=new WeakMap,OI=new WeakMap,CI=new WeakSet,VI=function([e,t],n,i){[n,i]=this.screenToPageTranslation(n,i),this.x+=n/e,this.y+=i/t,this.fixAndSetPosition()},NI=function(e,t,n){switch(n){case 90:return[t,-e];case 180:return[-e,-t];case 270:return[-t,e];default:return[e,t]}},$I=function(e){const{isMac:t}=HD.platform,n=e.target.closest(".k-highlight-editor"),i=e.target.closest(".k-free-text-editor"),r=this._uiManager.getMode();r===HA&&!n||r===PA&&!i||(e.ctrlKey&&!t||e.shiftKey||e.metaKey&&t?this.parent.toggleSelected(this):this.parent.setSelected(this))},UI=function(e){const t=this._uiManager.isSelected(this);this._uiManager.setUpDragSession();const n=new AbortController,i=this._uiManager.combinedSignal(n);if(t){yp(this,RI,e.clientX,"f"),yp(this,LI,e.clientY,"f");const t=e=>{const{clientX:t,clientY:n}=e,[i,r]=this.screenToPageTranslation(t-bp(this,RI,"f"),n-bp(this,LI,"f"));yp(this,RI,t,"f"),yp(this,LI,n,"f"),this._uiManager.dragSelectedEditors(i,r)};window.addEventListener("pointermove",t,{passive:!0,capture:!0,signal:i})}const r=()=>{n.abort(),t&&this.div.classList.remove("moving"),yp(this,II,!1,"f"),this._uiManager.endDragSession()||bp(this,CI,"m",$I).call(this,e)};window.addEventListener("pointerup",r,{signal:i}),window.addEventListener("blur",r,{signal:i})},WI=function(){if(bp(this,EI,"f")||!this.div)return;yp(this,EI,new AbortController,"f");const e=this._uiManager.combinedSignal(bp(this,EI,"f"));this.div.addEventListener("focusin",this.focusin.bind(this),{signal:e}),this.div.addEventListener("focusout",this.focusout.bind(this),{signal:e})},jI=function(){},pz.idManager=new KM("annotation_editor_id_"),pz._borderLineWidth=-1,pz._colorManager=new uz,pz._zIndex=1,pz._telemetryTimeout=1e3;class fz extends pz{constructor(e){super(e),this.annotationElementId=e.annotationElementId,this.deleted=!0}serialize(){return{id:this.annotationElementId,deleted:!0,pageIndex:this.pageIndex}}}const mz=/\r\n?|\n/g;class gz extends pz{constructor(e){super(Object.assign(Object.assign({},e),{name:"k-free-text-editor freeTextEditor"})),qI.add(this),this.editorDiv=null,this.overlayDiv=null,KI.set(this,void 0),YI.set(this,""),QI.set(this,`${this.id}-editor`),XI.set(this,null),ZI.set(this,void 0),JI.set(this,null),yp(this,KI,e.color||GI._defaultColor||pz._defaultLineColor,"f"),yp(this,ZI,e.fontSize||GI._defaultFontSize,"f")}static initialize(e,t){pz.initialize(e,t,{strings:["pdfjs-free-text-default-content"]});const n=getComputedStyle(document.documentElement);this._internalPadding=parseFloat(n.getPropertyValue("--freetext-padding"))||2}static updateDefaultParams(e,t){switch(e){case RD.FREETEXT_SIZE:GI._defaultFontSize=t;break;case RD.FREETEXT_COLOR:GI._defaultColor=t}}updateParams(e,t){switch(e){case RD.FREETEXT_SIZE:bp(this,qI,"m",ez).call(this,t);break;case RD.FREETEXT_COLOR:bp(this,qI,"m",tz).call(this,t)}}static get defaultPropertiesToUpdate(){return[[RD.FREETEXT_SIZE,GI._defaultFontSize],[RD.FREETEXT_COLOR,GI._defaultColor||pz._defaultLineColor]]}get propertiesToUpdate(){return[[RD.FREETEXT_SIZE,bp(this,ZI,"f")],[RD.FREETEXT_COLOR,bp(this,KI,"f")]]}_translateEmpty(e,t){this._uiManager.translateSelectedEditors(e,t,!0)}getInitialTranslation(){const e=this.parentScale;return[-GI._internalPadding*e,-(GI._internalPadding+bp(this,ZI,"f"))*e]}rebuild(){this.parent&&(super.rebuild(),null!==this.div&&(this.isAttachedToDOM||this.parent.add(this)))}enableEditMode(){if(this.isInEditMode())return;this.parent.setEditingState(!1),this.parent.updateToolbar(PD.FREETEXT),super.enableEditMode(),this.overlayDiv.classList.remove("enabled"),this.editorDiv.contentEditable=!0,this._isDraggable=!1,this.div.removeAttribute("aria-activedescendant"),yp(this,XI,new AbortController,"f");const e=this._uiManager.combinedSignal(bp(this,XI,"f"));this.editorDiv.addEventListener("keydown",this.editorDivKeydown.bind(this),{signal:e}),this.editorDiv.addEventListener("focus",this.editorDivFocus.bind(this),{signal:e}),this.editorDiv.addEventListener("blur",this.editorDivBlur.bind(this),{signal:e}),this.editorDiv.addEventListener("input",this.editorDivInput.bind(this),{signal:e}),this.editorDiv.addEventListener("paste",this.editorDivPaste.bind(this),{signal:e})}disableEditMode(){var e;this.isInEditMode()&&(this.parent.setEditingState(!0),super.disableEditMode(),this.editorDiv.contentEditable=!1,this.div.setAttribute("aria-activedescendant",bp(this,QI,"f")),this._isDraggable=!0,null===(e=bp(this,XI,"f"))||void 0===e||e.abort(),yp(this,XI,null,"f"),this.div.focus({preventScroll:!0}),this.isEditing=!1)}focusin(e){var t;this._focusEventsAllowed&&(null===(t=this._uiManager)||void 0===t?void 0:t.getMode())===PD.FREETEXT&&(super.focusin(e),e.target!==this.editorDiv&&this.editorDiv.focus())}onceAdded(){var e;this.width||(this.enableEditMode(),this.editorDiv.focus(),(null===(e=this._initialOptions)||void 0===e?void 0:e.isCentered)&&this.center(),this._initialOptions=null)}isEmpty(){var e,t;return!this.editorDiv||""===(null===(t=null===(e=this.editorDiv)||void 0===e?void 0:e.innerText)||void 0===t?void 0:t.trim())}remove(){this.isEditing=!1,this.parent&&this.parent.setEditingState(!0),super.remove()}commit(){if(!this.isInEditMode())return;super.commit(),this.disableEditMode();const e=bp(this,YI,"f"),t=yp(this,YI,bp(this,qI,"m",nz).call(this).trimEnd(),"f");if(e===t)return;const n=e=>{yp(this,YI,e,"f"),e?(bp(this,qI,"m",oz).call(this),this._uiManager.rebuild(this),bp(this,qI,"m",iz).call(this)):this.remove()};this.addCommands({cmd:()=>{n(t)},undo:()=>{n(e)},mustExec:!1}),bp(this,qI,"m",iz).call(this)}shouldGetKeyboardEvents(){return this.isInEditMode()}enterInEditMode(){this.enableEditMode(),this.editorDiv.focus()}dblclick(e){e&&this.enterInEditMode()}keydown(e){e.target===this.div&&"Enter"===e.key&&(this.enterInEditMode(),e.preventDefault())}editorDivKeydown(){}editorDivFocus(){this.isEditing=!0}editorDivBlur(){this.isEditing=!1}editorDivInput(){}disableEditing(){this.editorDiv.setAttribute("role","comment"),this.editorDiv.removeAttribute("aria-multiline")}enableEditing(){this.editorDiv.setAttribute("role","textbox"),this.editorDiv.setAttribute("aria-multiline",!0)}render(){var e;if(this.div)return this.div;let t,n;this.width&&(t=this.x,n=this.y),super.render(),this.editorDiv=document.createElement("div"),this.editorDiv.className="k-internal internal",this.editorDiv.setAttribute("id",bp(this,QI,"f")),this.editorDiv.setAttribute("data-l10n-id","pdfjs-free-text"),this.enableEditing(),null===(e=this.editorDiv)||void 0===e||e.setAttribute("default-content",this._uiManager.pdfViewer.options.messages.freeTextEditorPlaceholder),this.editorDiv.contentEditable=!0;const{style:i}=this.editorDiv;if(i.fontSize=`calc(${bp(this,ZI,"f")}px * var(--scale-factor))`,i.color=bp(this,KI,"f"),this.div.append(this.editorDiv),this.overlayDiv=document.createElement("div"),this.div.append(this.overlayDiv),hz(this,this.div,["dblclick","keydown"]),this.width){const[e,i]=this.parentDimensions;if(this.annotationElementId){const{position:r}=bp(this,JI,"f");let[o,a]=this.getInitialTranslation();[o,a]=this.pageTranslationToScreen(o,a);const[s,l]=this.pageDimensions,[c,d]=this.pageTranslation;let u,h;switch(this.rotation){case 0:u=t+(r[0]-c)/s,h=n+this.height-(r[1]-d)/l;break;case 90:u=t+(r[0]-c)/s,h=n-(r[1]-d)/l,[o,a]=[a,-o];break;case 180:u=t-this.width+(r[0]-c)/s,h=n-(r[1]-d)/l,[o,a]=[-o,-a];break;case 270:u=t+(r[0]-c-this.height*l)/s,h=n+(r[1]-d-this.width*s)/l,[o,a]=[-a,o]}this.setAt(u*e,h*i,o,a)}else this.setAt(t*e,n*i,this.width*e,this.height*i);bp(this,qI,"m",oz).call(this),this._isDraggable=!0,this.editorDiv.contentEditable=!1}else this._isDraggable=!1,this.editorDiv.contentEditable=!0;return this.div}editorDivPaste(e){const t=e.clipboardData||window.clipboardData,{types:n}=t;if(1===n.length&&"text/plain"===n[0])return;e.preventDefault();const i=bp(GI,GI,"m",sz).call(GI,t.getData("text")||"").replaceAll(mz,"\n");if(!i)return;const r=window.getSelection();if(!r.rangeCount)return;this.editorDiv.normalize(),r.deleteFromDocument();const o=r.getRangeAt(0);if(!i.includes("\n"))return o.insertNode(document.createTextNode(i)),this.editorDiv.normalize(),void r.collapseToStart();const{startContainer:a,startOffset:s}=o,l=[],c=[];if(a.nodeType===Node.TEXT_NODE){const e=a.parentElement;if(c.push(a.nodeValue.slice(s).replaceAll(mz,"")),e!==this.editorDiv){let t=l;for(const n of this.editorDiv.childNodes)n!==e?t.push(bp(GI,GI,"m",rz).call(GI,n)):t=c}l.push(a.nodeValue.slice(0,s).replaceAll(mz,""))}else if(a===this.editorDiv){let e=l,t=0;for(const n of this.editorDiv.childNodes)t++===s&&(e=c),e.push(bp(GI,GI,"m",rz).call(GI,n))}yp(this,YI,`${l.join("\n")}${i}${c.join("\n")}`,"f"),bp(this,qI,"m",oz).call(this);const d=new Range;let u=l.reduce(((e,t)=>e+t.length),0);for(const{firstChild:e}of this.editorDiv.childNodes)if(e.nodeType===Node.TEXT_NODE){const t=e.nodeValue.length;if(u<=t){d.setStart(e,u),d.setEnd(e,u);break}u-=t}r.removeAllRanges(),r.addRange(d)}get contentDiv(){return this.editorDiv}static deserialize(e,t,n){let i=null;if(e instanceof fI){const{data:{defaultAppearanceData:{fontSize:t,fontColor:n},rect:r,rotation:o,id:a},textContent:s,textPosition:l,parent:{page:{pageNumber:c}}}=e;if(!s||0===s.length)return null;i=e={annotationType:PD.FREETEXT,color:Array.from(n),fontSize:t,value:s.join("\n"),position:l,pageIndex:c-1,rect:r.slice(0),rotation:o,id:a,deleted:!1}}const r=super.deserialize(e,t,n);return yp(r,ZI,e.fontSize,"f"),yp(r,KI,VD.makeHexColor(...e.color),"f"),yp(r,YI,bp(GI,GI,"m",sz).call(GI,e.value),"f"),r.annotationElementId=e.id||null,yp(r,JI,i,"f"),r}serialize(e=!1){if(this.isEmpty())return null;if(this.deleted)return{pageIndex:this.pageIndex,id:this.annotationElementId,deleted:!0};const t=GI._internalPadding*this.parentScale,n=this.getRect(t,t),i=pz._colorManager.convert(this.isAttachedToDOM?getComputedStyle(this.editorDiv).color:bp(this,KI,"f")),r={annotationType:PD.FREETEXT,color:i,fontSize:bp(this,ZI,"f"),value:bp(this,qI,"m",az).call(this),pageIndex:this.pageIndex,rect:n,rotation:this.rotation,structTreeParentId:this._structTreeParentId};return e?r:this.annotationElementId&&!bp(this,qI,"m",lz).call(this,r)?null:(r.id=this.annotationElementId,r)}renderAnnotationElement(e){const t=super.renderAnnotationElement(e);if(this.deleted)return t;const{style:n}=t;n.fontSize=`calc(${bp(this,ZI,"f")}px * var(--scale-factor))`,n.color=bp(this,KI,"f"),t.replaceChildren();for(const e of bp(this,YI,"f").split("\n")){const n=document.createElement("div");n.append(e?document.createTextNode(e):document.createElement("br")),t.append(n)}const i=GI._internalPadding*this.parentScale;return e.updateEdited({rect:this.getRect(i,i),popupContent:bp(this,YI,"f")}),t}resetAnnotationElement(e){super.resetAnnotationElement(e),e.resetEdited()}toJSON(){return this.serialize()}}var vz,_z,bz,yz,wz,kz,xz,Cz,Sz,Tz,Dz,Az,Mz,Ez,Iz,zz,Pz,Hz,Fz,Rz,Lz,Bz,Oz,Vz,Nz,$z,Uz,Wz,jz,qz,Gz,Kz,Yz,Qz,Xz,Zz,Jz,eP,tP,nP,iP,rP,oP,aP,sP,lP,cP,dP,uP,hP,pP,fP,mP,gP,vP,_P,bP,yP,wP,kP,xP,CP,SP,TP,DP,AP,MP,EP,IP,zP,PP,HP,FP,RP,LP,BP,OP,VP,NP,$P,UP,WP,jP,qP,GP,KP,YP,QP,XP,ZP,JP,eH,tH,nH,iH,rH,oH,aH;GI=gz,KI=new WeakMap,YI=new WeakMap,QI=new WeakMap,XI=new WeakMap,ZI=new WeakMap,JI=new WeakMap,qI=new WeakSet,ez=function(e){const t=e=>{this.editorDiv.style.fontSize=`calc(${e}px * var(--scale-factor))`,this.translate(0,-(e-bp(this,ZI,"f"))*this.parentScale),yp(this,ZI,e,"f"),bp(this,qI,"m",iz).call(this)},n=bp(this,ZI,"f");this.addCommands({cmd:t.bind(this,e),undo:t.bind(this,n),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:RD.FREETEXT_SIZE,overwriteIfSameType:!0,keepUndo:!0})},tz=function(e){const t=e=>{yp(this,KI,this.editorDiv.style.color=e,"f")},n=bp(this,KI,"f");this.addCommands({cmd:t.bind(this,e),undo:t.bind(this,n),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:RD.FREETEXT_COLOR,overwriteIfSameType:!0,keepUndo:!0})},nz=function(){const e=[];this.editorDiv.normalize();for(const t of this.editorDiv.childNodes)e.push(bp(GI,GI,"m",rz).call(GI,t));return e.join("\n")},iz=function(){const[e,t]=this.parentDimensions;let n;if(this.isAttachedToDOM)n=this.div.getBoundingClientRect();else{const{currentLayer:e,div:t}=this,i=t.style.display,r=t.classList.contains("hidden")||t.classList.contains("k-hidden");t.classList.remove("hidden"),t.classList.remove("k-hidden"),t.style.display="hidden",e.div.append(this.div),n=t.getBoundingClientRect(),t.remove(),t.style.display=i,t.classList.toggle("k-hidden",r)}this.rotation%180==this.parentRotation%180?(this.width=n.width/e,this.height=n.height/t):(this.width=n.height/e,this.height=n.width/t),this.fixAndSetPosition()},rz=function(e){return(e.nodeType===Node.TEXT_NODE?e.nodeValue:e.innerText).replaceAll(mz,"")},oz=function(){if(this.editorDiv.replaceChildren(),bp(this,YI,"f"))for(const e of bp(this,YI,"f").split("\n")){const t=document.createElement("div");t.append(e?document.createTextNode(e):document.createElement("br")),this.editorDiv.append(t)}},az=function(){return bp(this,YI,"f").replaceAll(" "," ")},sz=function(e){return e.replaceAll(" "," ")},lz=function(e){const{value:t,fontSize:n,color:i,pageIndex:r}=bp(this,JI,"f");return this._hasBeenMoved||e.value!==t||e.fontSize!==n||e.color.some(((e,t)=>e!==i[t]))||e.pageIndex!==r},gz._freeTextDefaultContent="",gz._internalPadding=0,gz._defaultColor="#000000",gz._defaultFontSize=10,gz._type="freetext",gz._editorType=PD.FREETEXT;class sH{constructor(e,t=0,n=0,i=!0){vz.add(this),_z.set(this,void 0),bz.set(this,[]),yz.set(this,[]);let r=1/0,o=-1/0,a=1/0,s=-1/0;const l=Math.pow(10,-4);for(const{x:n,y:i,width:c,height:d}of e){const e=Math.floor((n-t)/l)*l,u=Math.ceil((n+c+t)/l)*l,h=Math.floor((i-t)/l)*l,p=Math.ceil((i+d+t)/l)*l,f=[e,h,p,!0],m=[u,h,p,!1];bp(this,bz,"f").push(f,m),r=Math.min(r,e),o=Math.max(o,u),a=Math.min(a,h),s=Math.max(s,p)}const c=o-r+2*n,d=s-a+2*n,u=r-n,h=a-n,p=bp(this,bz,"f").at(i?-1:-2),f=[p[0],p[2]];for(const e of bp(this,bz,"f")){const[t,n,i]=e;e[0]=(t-u)/c,e[1]=(n-h)/d,e[2]=(i-h)/d}yp(this,_z,{x:u,y:h,width:c,height:d,lastPoint:f},"f")}getOutlines(){bp(this,bz,"f").sort(((e,t)=>e[0]-t[0]||e[1]-t[1]||e[2]-t[2]));const e=[];for(const t of bp(this,bz,"f"))t[3]?(e.push(...bp(this,vz,"m",Sz).call(this,t)),bp(this,vz,"m",xz).call(this,t)):(bp(this,vz,"m",Cz).call(this,t),e.push(...bp(this,vz,"m",Sz).call(this,t)));return bp(this,vz,"m",wz).call(this,e)}}_z=new WeakMap,bz=new WeakMap,yz=new WeakMap,vz=new WeakSet,wz=function(e){const t=[],n=new Set;for(const n of e){const[e,i,r]=n;t.push([e,i,n],[e,r,n])}t.sort(((e,t)=>e[1]-t[1]||e[0]-t[0]));for(let e=0,i=t.length;e<i;e+=2){const i=t[e][2],r=t[e+1][2];i.push(r),r.push(i),n.add(i),n.add(r)}const i=[];let r;for(;n.size>0;){const e=n.values().next().value;let[t,o,a,s,l]=e;n.delete(e);let c=t,d=o;for(r=[t,a],i.push(r);;){let e;if(n.has(s))e=s;else{if(!n.has(l))break;e=l}n.delete(e),[t,o,a,s,l]=e,c!==t&&(r.push(c,d,t,d===o?o:a),c=t),d=d===o?a:o}r.push(c,d)}return new cH(i,bp(this,_z,"f"))},kz=function(e){const t=bp(this,yz,"f");let n=0,i=t.length-1;for(;n<=i;){const r=n+i>>1,o=t[r][0];if(o===e)return r;o<e?n=r+1:i=r-1}return i+1},xz=function([,e,t]){const n=bp(this,vz,"m",kz).call(this,e);bp(this,yz,"f").splice(n,0,[e,t])},Cz=function([,e,t]){const n=bp(this,vz,"m",kz).call(this,e);for(let i=n;i<bp(this,yz,"f").length;i++){const[n,r]=bp(this,yz,"f")[i];if(n!==e)break;if(n===e&&r===t)return void bp(this,yz,"f").splice(i,1)}for(let i=n-1;i>=0;i--){const[n,r]=bp(this,yz,"f")[i];if(n!==e)break;if(n===e&&r===t)return void bp(this,yz,"f").splice(i,1)}},Sz=function(e){const[t,n,i]=e,r=[[t,n,i]],o=bp(this,vz,"m",kz).call(this,i);for(let e=0;e<o;e++){const[n,i]=bp(this,yz,"f")[e];for(let e=0,o=r.length;e<o;e++){const[,a,s]=r[e];if(!(i<=a||s<=n))if(a>=n)if(s>i)r[e][1]=i;else{if(1===o)return[];r.splice(e,1),e--,o--}else r[e][2]=n,s>i&&r.push([t,i,s])}}return r};class lH{toSVGPath(){throw new Error("Abstract method `toSVGPath` must be implemented.")}get box(){throw new Error("Abstract getter `box` must be implemented.")}serialize([e,t,n,i]){}get free(){return this instanceof uH}}class cH extends lH{constructor(e,t){super(),Tz.set(this,void 0),Dz.set(this,void 0),yp(this,Dz,e,"f"),yp(this,Tz,t,"f")}toSVGPath(){const e=[];for(const t of bp(this,Dz,"f")){let[n,i]=t;e.push(`M${n} ${i}`);for(let r=2;r<t.length;r+=2){const o=t[r],a=t[r+1];o===n?(e.push(`V${a}`),i=a):a===i&&(e.push(`H${o}`),n=o)}e.push("Z")}return e.join(" ")}serialize([e,t,n,i]){const r=[],o=n-e,a=i-t;for(const t of bp(this,Dz,"f")){const n=new Array(t.length);for(let r=0;r<t.length;r+=2)n[r]=e+t[r]*o,n[r+1]=i-t[r+1]*a;r.push(n)}return r}get box(){return bp(this,Tz,"f")}}Tz=new WeakMap,Dz=new WeakMap;class dH{constructor({x:e,y:t},n,i,r,o,a=0){Az.add(this),Ez.set(this,void 0),Iz.set(this,[]),zz.set(this,void 0),Pz.set(this,void 0),Hz.set(this,[]),Fz.set(this,new Float64Array(18)),Rz.set(this,void 0),Lz.set(this,void 0),Bz.set(this,void 0),Oz.set(this,void 0),Vz.set(this,void 0),Nz.set(this,void 0),$z.set(this,[]),yp(this,Ez,n,"f"),yp(this,Nz,r*i,"f"),yp(this,Pz,o,"f"),bp(this,Fz,"f").set([NaN,NaN,NaN,NaN,e,t],6),yp(this,zz,a,"f"),yp(this,Oz,bp(Mz,Mz,"f",Uz)*i,"f"),yp(this,Bz,bp(Mz,Mz,"f",jz)*i,"f"),yp(this,Vz,i,"f"),bp(this,$z,"f").push(e,t)}get free(){return!0}isEmpty(){return isNaN(bp(this,Fz,"f")[8])}add({x:e,y:t}){var n;yp(this,Rz,e,"f"),yp(this,Lz,t,"f");const[i,r,o,a]=bp(this,Ez,"f");let[s,l,c,d]=bp(this,Fz,"f").subarray(8,12);const u=e-c,h=t-d,p=Math.hypot(u,h);if(p<bp(this,Bz,"f"))return!1;const f=p-bp(this,Oz,"f"),m=f/p,g=m*u,v=m*h;let _=s,b=l;s=c,l=d,c+=g,d+=v,null===(n=bp(this,$z,"f"))||void 0===n||n.push(e,t);const y=g/f,w=-v/f*bp(this,Nz,"f"),k=y*bp(this,Nz,"f");if(bp(this,Fz,"f").set(bp(this,Fz,"f").subarray(2,8),0),bp(this,Fz,"f").set([c+w,d+k],4),bp(this,Fz,"f").set(bp(this,Fz,"f").subarray(14,18),12),bp(this,Fz,"f").set([c-w,d-k],16),isNaN(bp(this,Fz,"f")[6]))return 0===bp(this,Hz,"f").length&&(bp(this,Fz,"f").set([s+w,l+k],2),bp(this,Hz,"f").push(NaN,NaN,NaN,NaN,(s+w-i)/o,(l+k-r)/a),bp(this,Fz,"f").set([s-w,l-k],14),bp(this,Iz,"f").push(NaN,NaN,NaN,NaN,(s-w-i)/o,(l-k-r)/a)),bp(this,Fz,"f").set([_,b,s,l,c,d],6),!this.isEmpty();bp(this,Fz,"f").set([_,b,s,l,c,d],6);return Math.abs(Math.atan2(b-l,_-s)-Math.atan2(v,g))<Math.PI/2?([s,l,c,d]=bp(this,Fz,"f").subarray(2,6),bp(this,Hz,"f").push(NaN,NaN,NaN,NaN,((s+c)/2-i)/o,((l+d)/2-r)/a),[s,l,_,b]=bp(this,Fz,"f").subarray(14,18),bp(this,Iz,"f").push(NaN,NaN,NaN,NaN,((_+s)/2-i)/o,((b+l)/2-r)/a),!0):([_,b,s,l,c,d]=bp(this,Fz,"f").subarray(0,6),bp(this,Hz,"f").push(((_+5*s)/6-i)/o,((b+5*l)/6-r)/a,((5*s+c)/6-i)/o,((5*l+d)/6-r)/a,((s+c)/2-i)/o,((l+d)/2-r)/a),[c,d,s,l,_,b]=bp(this,Fz,"f").subarray(12,18),bp(this,Iz,"f").push(((_+5*s)/6-i)/o,((b+5*l)/6-r)/a,((5*s+c)/6-i)/o,((5*l+d)/6-r)/a,((s+c)/2-i)/o,((l+d)/2-r)/a),!0)}toSVGPath(){if(this.isEmpty())return"";const e=bp(this,Hz,"f"),t=bp(this,Iz,"f"),n=bp(this,Fz,"f").subarray(4,6),i=bp(this,Fz,"f").subarray(16,18),[r,o,a,s]=bp(this,Ez,"f"),[l,c,d,u]=bp(this,Az,"m",qz).call(this);if(isNaN(bp(this,Fz,"f")[6])&&!this.isEmpty())return`M${(bp(this,Fz,"f")[2]-r)/a} ${(bp(this,Fz,"f")[3]-o)/s} L${(bp(this,Fz,"f")[4]-r)/a} ${(bp(this,Fz,"f")[5]-o)/s} L${l} ${c} L${d} ${u} L${(bp(this,Fz,"f")[16]-r)/a} ${(bp(this,Fz,"f")[17]-o)/s} L${(bp(this,Fz,"f")[14]-r)/a} ${(bp(this,Fz,"f")[15]-o)/s} Z`;const h=[];h.push(`M${e[4]} ${e[5]}`);for(let t=6;t<e.length;t+=6)isNaN(e[t])?h.push(`L${e[t+4]} ${e[t+5]}`):h.push(`C${e[t]} ${e[t+1]} ${e[t+2]} ${e[t+3]} ${e[t+4]} ${e[t+5]}`);h.push(`L${(n[0]-r)/a} ${(n[1]-o)/s} L${l} ${c} L${d} ${u} L${(i[0]-r)/a} ${(i[1]-o)/s}`);for(let e=t.length-6;e>=6;e-=6)isNaN(t[e])?h.push(`L${t[e+4]} ${t[e+5]}`):h.push(`C${t[e]} ${t[e+1]} ${t[e+2]} ${t[e+3]} ${t[e+4]} ${t[e+5]}`);return h.push(`L${t[4]} ${t[5]} Z`),h.join(" ")}getOutlines(){var e,t;const n=bp(this,Hz,"f"),i=bp(this,Iz,"f"),r=bp(this,Fz,"f"),o=r.subarray(4,6),a=r.subarray(16,18),[s,l,c,d]=bp(this,Ez,"f"),u=new Float64Array((null!==(t=null===(e=bp(this,$z,"f"))||void 0===e?void 0:e.length)&&void 0!==t?t:0)+2);for(let e=0,t=u.length-2;e<t;e+=2)u[e]=(bp(this,$z,"f")[e]-s)/c,u[e+1]=(bp(this,$z,"f")[e+1]-l)/d;u[u.length-2]=(bp(this,Rz,"f")-s)/c,u[u.length-1]=(bp(this,Lz,"f")-l)/d;const[h,p,f,m]=bp(this,Az,"m",qz).call(this);if(isNaN(r[6])&&!this.isEmpty()){const e=new Float64Array(36);return e.set([NaN,NaN,NaN,NaN,(r[2]-s)/c,(r[3]-l)/d,NaN,NaN,NaN,NaN,(r[4]-s)/c,(r[5]-l)/d,NaN,NaN,NaN,NaN,h,p,NaN,NaN,NaN,NaN,f,m,NaN,NaN,NaN,NaN,(r[16]-s)/c,(r[17]-l)/d,NaN,NaN,NaN,NaN,(r[14]-s)/c,(r[15]-l)/d],0),new uH(e,u,bp(this,Ez,"f"),bp(this,Vz,"f"),bp(this,zz,"f"),bp(this,Pz,"f"))}const g=new Float64Array(bp(this,Hz,"f").length+24+bp(this,Iz,"f").length);let v=n.length;for(let e=0;e<v;e+=2)isNaN(n[e])?g[e]=g[e+1]=NaN:(g[e]=n[e],g[e+1]=n[e+1]);g.set([NaN,NaN,NaN,NaN,(o[0]-s)/c,(o[1]-l)/d,NaN,NaN,NaN,NaN,h,p,NaN,NaN,NaN,NaN,f,m,NaN,NaN,NaN,NaN,(a[0]-s)/c,(a[1]-l)/d],v),v+=24;for(let e=i.length-6;e>=6;e-=6)for(let t=0;t<6;t+=2)isNaN(i[e+t])?(g[v]=g[v+1]=NaN,v+=2):(g[v]=i[e+t],g[v+1]=i[e+t+1],v+=2);return g.set([NaN,NaN,NaN,NaN,i[4],i[5]],v),new uH(g,u,bp(this,Ez,"f"),bp(this,Vz,"f"),bp(this,zz,"f"),bp(this,Pz,"f"))}}Mz=dH,Ez=new WeakMap,Iz=new WeakMap,zz=new WeakMap,Pz=new WeakMap,Hz=new WeakMap,Fz=new WeakMap,Rz=new WeakMap,Lz=new WeakMap,Bz=new WeakMap,Oz=new WeakMap,Vz=new WeakMap,Nz=new WeakMap,$z=new WeakMap,Az=new WeakSet,qz=function(){const e=bp(this,Fz,"f").subarray(4,6),t=bp(this,Fz,"f").subarray(16,18),[n,i,r,o]=bp(this,Ez,"f");return[(bp(this,Rz,"f")+(e[0]-t[0])/2-n)/r,(bp(this,Lz,"f")+(e[1]-t[1])/2-i)/o,(bp(this,Rz,"f")+(t[0]-e[0])/2-n)/r,(bp(this,Lz,"f")+(t[1]-e[1])/2-i)/o]},Wz={value:2},jz={value:bp(Mz,Mz,"f",Uz={value:8})+bp(Mz,Mz,"f",Wz)};class uH extends lH{constructor(e,t,n,i,r,o){super(),Gz.add(this),Kz.set(this,void 0),Yz.set(this,null),Qz.set(this,void 0),Xz.set(this,void 0),Zz.set(this,void 0),Jz.set(this,void 0),eP.set(this,void 0),yp(this,eP,e,"f"),yp(this,Zz,t,"f"),yp(this,Kz,n,"f"),yp(this,Jz,i,"f"),yp(this,Qz,r,"f"),yp(this,Xz,o,"f"),bp(this,Gz,"m",iP).call(this,o);const{x:a,y:s,width:l,height:c}=bp(this,Yz,"f");for(let t=0,n=e.length;t<n;t+=2)e[t]=(e[t]-a)/l,e[t+1]=(e[t+1]-s)/c;for(let e=0,n=t.length;e<n;e+=2)t[e]=(t[e]-a)/l,t[e+1]=(t[e+1]-s)/c}toSVGPath(){const e=[`M${bp(this,eP,"f")[4]} ${bp(this,eP,"f")[5]}`];for(let t=6,n=bp(this,eP,"f").length;t<n;t+=6)isNaN(bp(this,eP,"f")[t])?e.push(`L${bp(this,eP,"f")[t+4]} ${bp(this,eP,"f")[t+5]}`):e.push(`C${bp(this,eP,"f")[t]} ${bp(this,eP,"f")[t+1]} ${bp(this,eP,"f")[t+2]} ${bp(this,eP,"f")[t+3]} ${bp(this,eP,"f")[t+4]} ${bp(this,eP,"f")[t+5]}`);return e.push("Z"),e.join(" ")}serialize([e,t,n,i],r){const o=n-e,a=i-t;let s,l;switch(r){case 0:s=bp(this,Gz,"m",tP).call(this,bp(this,eP,"f"),e,i,o,-a),l=bp(this,Gz,"m",tP).call(this,bp(this,Zz,"f"),e,i,o,-a);break;case 90:s=bp(this,Gz,"m",nP).call(this,bp(this,eP,"f"),e,t,o,a),l=bp(this,Gz,"m",nP).call(this,bp(this,Zz,"f"),e,t,o,a);break;case 180:s=bp(this,Gz,"m",tP).call(this,bp(this,eP,"f"),n,t,-o,a),l=bp(this,Gz,"m",tP).call(this,bp(this,Zz,"f"),n,t,-o,a);break;case 270:s=bp(this,Gz,"m",nP).call(this,bp(this,eP,"f"),n,i,-o,-a),l=bp(this,Gz,"m",nP).call(this,bp(this,Zz,"f"),n,i,-o,-a)}return{outline:Array.from(s),points:[Array.from(l)]}}get box(){return bp(this,Yz,"f")}getNewOutline(e,t){const{x:n,y:i,width:r,height:o}=bp(this,Yz,"f"),[a,s,l,c]=bp(this,Kz,"f"),d=r*l,u=o*c,h=n*l+a,p=i*c+s,f=new dH({x:bp(this,Zz,"f")[0]*d+h,y:bp(this,Zz,"f")[1]*u+p},bp(this,Kz,"f"),bp(this,Jz,"f"),e,bp(this,Xz,"f"),null!=t?t:bp(this,Qz,"f"));for(let e=2;e<bp(this,Zz,"f").length;e+=2)f.add({x:bp(this,Zz,"f")[e]*d+h,y:bp(this,Zz,"f")[e+1]*u+p});return f.getOutlines()}}Kz=new WeakMap,Yz=new WeakMap,Qz=new WeakMap,Xz=new WeakMap,Zz=new WeakMap,Jz=new WeakMap,eP=new WeakMap,Gz=new WeakSet,tP=function(e,t,n,i,r){const o=new Float64Array(e.length);for(let a=0,s=e.length;a<s;a+=2)o[a]=t+e[a]*i,o[a+1]=n+e[a+1]*r;return o},nP=function(e,t,n,i,r){const o=new Float64Array(e.length);for(let a=0,s=e.length;a<s;a+=2)o[a]=t+e[a+1]*i,o[a+1]=n+e[a]*r;return o},iP=function(e){const t=bp(this,eP,"f");let n=t[4],i=t[5],r=n,o=i,a=n,s=i,l=n,c=i;const d=e?Math.max:Math.min;for(let e=6,u=t.length;e<u;e+=6){if(isNaN(t[e]))r=Math.min(r,t[e+4]),o=Math.min(o,t[e+5]),a=Math.max(a,t[e+4]),s=Math.max(s,t[e+5]),c<t[e+5]?(l=t[e+4],c=t[e+5]):c===t[e+5]&&(l=d(l,t[e+4]));else{const u=VD.bezierBoundingBox(n,i,...t.slice(e,e+6));r=Math.min(r,u[0]),o=Math.min(o,u[1]),a=Math.max(a,u[2]),s=Math.max(s,u[3]),c<u[3]?(l=u[2],c=u[3]):c===u[3]&&(l=d(l,u[2]))}n=t[e+4],i=t[e+5]}const u=r-bp(this,Qz,"f"),h=o-bp(this,Qz,"f"),p=a-r+2*bp(this,Qz,"f"),f=s-o+2*bp(this,Qz,"f");yp(this,Yz,{x:u,y:h,width:p,height:f,lastPoint:[l,c]},"f")};class hH extends pz{constructor(e){super(Object.assign(Object.assign({},e),{name:"k-highlight-editor highlightEditor"})),rP.add(this),this.color="",aP.set(this,null),sP.set(this,0),lP.set(this,void 0),cP.set(this,null),dP.set(this,null),uP.set(this,null),hP.set(this,0),pP.set(this,null),fP.set(this,null),mP.set(this,null),gP.set(this,!1),vP.set(this,null),_P.set(this,void 0),bP.set(this,null),yP.set(this,""),wP.set(this,void 0),kP.set(this,""),this.color=e.color||oP._defaultColor,yp(this,wP,e.thickness||oP._defaultThickness,"f"),yp(this,_P,e.opacity||oP._defaultOpacity,"f"),yp(this,lP,e.boxes||null,"f"),yp(this,kP,e.methodOfCreation||"","f"),yp(this,yP,e.text||"","f"),this._isDraggable=!1,e.highlightId>-1?(yp(this,gP,!0,"f"),bp(this,rP,"m",CP).call(this,e),bp(this,rP,"m",AP).call(this)):(yp(this,aP,e.anchorNode,"f"),yp(this,sP,e.anchorOffset,"f"),yp(this,uP,e.focusNode,"f"),yp(this,hP,e.focusOffset,"f"),bp(this,rP,"m",xP).call(this),bp(this,rP,"m",AP).call(this),this.rotate(this.rotation))}get telemetryInitialData(){return{action:"added",type:bp(this,gP,"f")?"free_highlight":"highlight",color:this._uiManager.highlightColorNames.get(this.color),thickness:bp(this,wP,"f"),methodOfCreation:bp(this,kP,"f")}}get telemetryFinalData(){return{type:"highlight",color:this._uiManager.highlightColorNames.get(this.color)}}static computeTelemetryFinalData(e){return{numberOfColors:e.get("color").size}}static initialize(e,t){var n,i,r,o;pz.initialize(e,t,{}),oP._defaultColor||(oP._defaultColor=(null===(o=null===(r=null===(i=null===(n=t.viewer)||void 0===n?void 0:n.options)||void 0===i?void 0:i.annotations)||void 0===r?void 0:r.highlight)||void 0===o?void 0:o.color)||"#ffff00")}static updateDefaultParams(e,t){switch(e){case RD.HIGHLIGHT_DEFAULT_COLOR:oP._defaultColor=t;break;case RD.HIGHLIGHT_THICKNESS:oP._defaultThickness=t}}translateInPage(){}get toolbarPosition(){return bp(this,vP,"f")}updateParams(e,t){switch(e){case RD.HIGHLIGHT_COLOR:bp(this,rP,"m",SP).call(this,t);break;case RD.HIGHLIGHT_THICKNESS:bp(this,rP,"m",TP).call(this,t)}}static get defaultPropertiesToUpdate(){return[[RD.HIGHLIGHT_DEFAULT_COLOR,oP._defaultColor],[RD.HIGHLIGHT_THICKNESS,oP._defaultThickness]]}get propertiesToUpdate(){return[[RD.HIGHLIGHT_COLOR,this.color||oP._defaultColor],[RD.HIGHLIGHT_THICKNESS,bp(this,wP,"f")||oP._defaultThickness],[RD.HIGHLIGHT_FREE,bp(this,gP,"f")]]}disableEditing(){super.disableEditing(),this.div.classList.toggle("disabled",!0)}enableEditing(){super.enableEditing(),this.div.classList.toggle("disabled",!1)}fixAndSetPosition(){return super.fixAndSetPosition(bp(this,rP,"m",zP).call(this))}getBaseTranslation(){return[0,0]}getRect(e,t){return super.getRect(e,t,bp(this,rP,"m",zP).call(this))}onceAdded(){this.parent.addUndoableEditor(this),this.div.focus()}remove(){bp(this,rP,"m",DP).call(this),super.remove()}rebuild(){this.parent&&(super.rebuild(),null!==this.div&&(bp(this,rP,"m",AP).call(this),this.isAttachedToDOM||this.parent.add(this)))}setParent(e){var t,n;let i=!1;this.parent&&!e?bp(this,rP,"m",DP).call(this):e&&(bp(this,rP,"m",AP).call(this,e),i=!this.parent&&((null===(t=this.div)||void 0===t?void 0:t.classList.contains("selectedEditor"))||(null===(n=this.div)||void 0===n?void 0:n.classList.contains("k-selected")))),super.setParent(e),this.show(this._isVisible),i&&this.select()}rotate(e){const{drawLayer:t}=this.parent;let n;bp(this,gP,"f")?(e=(e-this.rotation+360)%360,n=bp(oP,oP,"m",MP).call(oP,bp(this,fP,"f").box,e)):n=bp(oP,oP,"m",MP).call(oP,this,e),t.rotate(bp(this,mP,"f"),e),t.rotate(bp(this,bP,"f"),e),t.updateBox(bp(this,mP,"f"),n),t.updateBox(bp(this,bP,"f"),bp(oP,oP,"m",MP).call(oP,bp(this,dP,"f").box,e))}render(){if(this.div)return this.div;const e=super.render();bp(this,yP,"f")&&(e.setAttribute("aria-label",bp(this,yP,"f")),e.setAttribute("role","mark")),bp(this,gP,"f")?e.classList.add("free"):this.div.addEventListener("keydown",bp(this,rP,"m",EP).bind(this),{signal:this._uiManager._signal});const t=yp(this,pP,document.createElement("div"),"f");e.append(t),t.setAttribute("aria-hidden","true"),t.className="k-internal internal",t.style.clipPath=bp(this,cP,"f");const[n,i]=this.parentDimensions;return this.setDims(this.width*n,this.height*i),hz(this,bp(this,pP,"f"),["pointerover","pointerleave"]),this.enableEditing(),e}pointerover(){this.parent.drawLayer.addClass(bp(this,bP,"f"),"hovered")}pointerleave(){this.parent.drawLayer.removeClass(bp(this,bP,"f"),"hovered")}_moveCaret(e){switch(this.parent.unselect(this),e){case 0:case 2:bp(this,rP,"m",IP).call(this,!0);break;case 1:case 3:bp(this,rP,"m",IP).call(this,!1)}}select(){var e,t,n;super.select(),bp(this,bP,"f")&&(null===(e=this.parent)||void 0===e||e.drawLayer.removeClass(bp(this,bP,"f"),"hovered"),null===(t=this.parent)||void 0===t||t.drawLayer.addClass(bp(this,bP,"f"),"selected"),null===(n=this.parent)||void 0===n||n.drawLayer.addClass(bp(this,bP,"f"),"k-selected"))}unselect(){var e,t;super.unselect(),bp(this,bP,"f")&&(null===(e=this.parent)||void 0===e||e.drawLayer.removeClass(bp(this,bP,"f"),"selected"),null===(t=this.parent)||void 0===t||t.drawLayer.removeClass(bp(this,bP,"f"),"k-selected"),bp(this,gP,"f")||bp(this,rP,"m",IP).call(this,!1))}get _mustFixPosition(){return!bp(this,gP,"f")}show(e=this._isVisible){super.show(e),this.parent&&(this.parent.drawLayer.show(bp(this,mP,"f"),e),this.parent.drawLayer.show(bp(this,bP,"f"),e))}static startHighlighting(e,t,{target:n,x:i,y:r}){const{x:o,y:a,width:s,height:l}=n.getBoundingClientRect(),c=new AbortController,d=e.combinedSignal(c),u=t=>{c.abort(),bp(this,oP,"m",RP).call(this,e,t)};window.addEventListener("blur",u,{signal:d}),window.addEventListener("pointerup",u,{signal:d}),window.addEventListener("pointerdown",(e=>{e.preventDefault(),e.stopPropagation()}),{capture:!0,passive:!1,signal:d}),window.addEventListener("contextmenu",GD,{signal:d}),n.addEventListener("pointermove",bp(this,oP,"m",FP).bind(this,e),{signal:d}),this._freeHighlight=new dH({x:i,y:r},[o,a,s,l],e.scale,this._defaultThickness/2,t,.001),({id:this._freeHighlightId,clipPathId:this._freeHighlightClipId}=e.drawLayer.highlight(this._freeHighlight,this._defaultColor,this._defaultOpacity,!0))}static deserialize(e,t,n){const i=super.deserialize(e,t,n),{rect:[r,o,a,s],color:l,quadPoints:c}=e;i.color=VD.makeHexColor(...l),yp(i,_P,e.opacity,"f");const[d,u]=i.pageDimensions;i.width=(a-r)/d,i.height=(s-o)/u;const h=yp(i,lP,[],"f");for(let e=0;e<c.length;e+=8)h.push({x:(c[4]-a)/d,y:(s-(1-c[e+5]))/u,width:(c[e+2]-c[e])/d,height:(c[e+5]-c[e+1])/u});return bp(i,rP,"m",xP).call(i),i}serialize(e=!1){if(this.isEmpty()||e)return null;const t=this.getRect(0,0),n=pz._colorManager.convert(this.color);return{annotationType:PD.HIGHLIGHT,color:n,opacity:bp(this,_P,"f"),thickness:bp(this,wP,"f"),quadPoints:bp(this,rP,"m",PP).call(this),outlines:bp(this,rP,"m",HP).call(this,t),pageIndex:this.pageIndex,rect:t,rotation:bp(this,rP,"m",zP).call(this),structTreeParentId:this._structTreeParentId}}static canCreateNewEmptyEditor(){return!1}toJSON(){return this.serialize()}}oP=hH,aP=new WeakMap,sP=new WeakMap,lP=new WeakMap,cP=new WeakMap,dP=new WeakMap,uP=new WeakMap,hP=new WeakMap,pP=new WeakMap,fP=new WeakMap,mP=new WeakMap,gP=new WeakMap,vP=new WeakMap,_P=new WeakMap,bP=new WeakMap,yP=new WeakMap,wP=new WeakMap,kP=new WeakMap,rP=new WeakSet,xP=function(){const e=new sH(bp(this,lP,"f"),.001);yp(this,fP,e.getOutlines(),"f"),({x:this.x,y:this.y,width:this.width,height:this.height}=bp(this,fP,"f").box);const t=new sH(bp(this,lP,"f"),.0025,.001,"ltr"===this._uiManager.direction);yp(this,dP,t.getOutlines(),"f");const{lastPoint:n}=bp(this,dP,"f").box;yp(this,vP,[(n[0]-this.x)/this.width,(n[1]-this.y)/this.height],"f")},CP=function({highlightOutlines:e,highlightId:t,clipPathId:n}){yp(this,fP,e,"f");if(yp(this,dP,e.getNewOutline(bp(this,wP,"f")/2+1.5,.0025),"f"),t>=0)yp(this,mP,t,"f"),yp(this,cP,n,"f"),this.parent.drawLayer.finalizeLine(t,e),yp(this,bP,this.parent.drawLayer.highlightOutline(bp(this,dP,"f")),"f");else if(this.parent){const t=this.parent.viewport.rotation;this.parent.drawLayer.updateLine(bp(this,mP,"f"),e),this.parent.drawLayer.updateBox(bp(this,mP,"f"),bp(oP,oP,"m",MP).call(oP,bp(this,fP,"f").box,(t-this.rotation+360)%360)),this.parent.drawLayer.updateLine(bp(this,bP,"f"),bp(this,dP,"f")),this.parent.drawLayer.updateBox(bp(this,bP,"f"),bp(oP,oP,"m",MP).call(oP,bp(this,dP,"f").box,t))}const{x:i,y:r,width:o,height:a}=e.box;switch(this.rotation){case 0:this.x=i,this.y=r,this.width=o,this.height=a;break;case 90:{const[e,t]=this.parentDimensions;this.x=r,this.y=1-i,this.width=o*t/e,this.height=a*e/t;break}case 180:this.x=1-i,this.y=1-r,this.width=o,this.height=a;break;case 270:{const[e,t]=this.parentDimensions;this.x=1-r,this.y=i,this.width=o*t/e,this.height=a*e/t;break}}const{lastPoint:s}=bp(this,dP,"f").box;yp(this,vP,[(s[0]-i)/o,(s[1]-r)/a],"f")},SP=function(e){if(!e)return;const t=e=>{var t;this.color=e,null===(t=this.parent)||void 0===t||t.drawLayer.changeColor(bp(this,mP,"f"),e)},n=this.color;this.addCommands({cmd:t.bind(this,e),undo:t.bind(this,n),post:this._uiManager.updateUI.bind(this._uiManager,this),mustExec:!0,type:RD.HIGHLIGHT_COLOR,overwriteIfSameType:!0,keepUndo:!0})},TP=function(e){},DP=function(){null!==bp(this,mP,"f")&&this.parent&&(this.parent.drawLayer.remove(bp(this,mP,"f")),yp(this,mP,null,"f"),this.parent.drawLayer.remove(bp(this,bP,"f")),yp(this,bP,null,"f"))},AP=function(e=this.parent){var t,n;null===bp(this,mP,"f")&&(t=this,n=this,({id:{set value(e){yp(t,mP,e,"f")}}.value,clipPathId:{set value(e){yp(n,cP,e,"f")}}.value}=e.drawLayer.highlight(bp(this,fP,"f"),this.color,bp(this,_P,"f"))),yp(this,bP,e.drawLayer.highlightOutline(bp(this,dP,"f")),"f"),bp(this,pP,"f")&&(bp(this,pP,"f").style.clipPath=bp(this,cP,"f")))},MP=function({x:e,y:t,width:n,height:i},r){switch(r){case 90:return{x:1-t-i,y:e,width:i,height:n};case 180:return{x:1-e-n,y:1-t-i,width:n,height:i};case 270:return{x:t,y:1-e-n,width:i,height:n}}return{x:e,y:t,width:n,height:i}},EP=function(e){},IP=function(e){if(!bp(this,aP,"f"))return;const t=window.getSelection();e?t.setPosition(bp(this,aP,"f"),bp(this,sP,"f")):t.setPosition(bp(this,uP,"f"),bp(this,hP,"f"))},zP=function(){return bp(this,gP,"f")?this.rotation:0},PP=function(){if(bp(this,gP,"f"))return null;const[e,t]=this.pageDimensions,[n,i]=this.pageTranslation,r=bp(this,lP,"f"),o=new Float32Array(8*r.length);let a=0;for(const{x:s,y:l,width:c,height:d}of r){const r=s*e+n,u=(1-l-d)*t+i;o[a]=o[a+4]=r,o[a+1]=o[a+3]=u,o[a+2]=o[a+6]=r+c*e,o[a+5]=o[a+7]=u+d*t,a+=8}return o},HP=function(e){return bp(this,fP,"f").serialize(e,bp(this,rP,"m",zP).call(this))},FP=function(e,t){this._freeHighlight.add(t)&&e.drawLayer.updatePath(this._freeHighlightId,this._freeHighlight)},RP=function(e,t){this._freeHighlight.isEmpty()?e.drawLayer.removeFreeHighlight(this._freeHighlightId):e.createAndAddNewEditor(t,!1,{highlightId:this._freeHighlightId,highlightOutlines:this._freeHighlight.getOutlines(),clipPathId:this._freeHighlightClipId,methodOfCreation:"main_toolbar"}),this._freeHighlightId=-1,this._freeHighlight=null,this._freeHighlightClipId=""},hH._defaultColor=null,hH._defaultOpacity=1,hH._defaultThickness=12,hH._type="highlight",hH._editorType=PD.HIGHLIGHT,hH._freeHighlightId=-1,hH._freeHighlight=null,hH._freeHighlightClipId="";class pH{constructor({uiManager:e,pageIndex:t,div:n,accessibilityManager:i,annotationLayer:r,drawLayer:o,textLayer:a,viewport:s}){LP.add(this),this.drawLayer=null,this.pageIndex=0,this.div=null,this.viewport=null,OP.set(this,void 0),VP.set(this,!1),NP.set(this,null),$P.set(this,null),UP.set(this,null),WP.set(this,new Map),jP.set(this,!1),qP.set(this,!1),GP.set(this,!1),KP.set(this,null),YP.set(this,null),QP.set(this,null);const l=[...bp(BP,BP,"f",XP).values()];if(!BP._initialized){BP._initialized=!0;for(const t of l)t.initialize({},e)}e.registerEditorTypes(l),yp(this,QP,e,"f"),this.pageIndex=t,this.div=n,yp(this,OP,i,"f"),yp(this,NP,r,"f"),this.viewport=s,yp(this,KP,a,"f"),this.drawLayer=o,bp(this,QP,"f").addLayer(this),bp(this,NP,"f")&&bp(this,KP,"f")}hide(){this.div&&(this.div.hidden=!0)}show(){this.div&&!this.isInvisible&&(this.div.hidden=!1)}get isEmpty(){return 0===bp(this,WP,"f").size}get isInvisible(){return this.isEmpty&&bp(this,QP,"f").getMode()===PD.NONE}updateToolbar(){}updateMode(e=bp(this,QP,"f").getMode()){switch(bp(this,LP,"m",nH).call(this),e){case PD.NONE:return this.disableTextSelection(),this.togglePointerEvents(!1),this.toggleAnnotationLayerPointerEvents(!0),void this.disableClick();case PD.INK:this.addInkEditorIfNeeded(!1),this.disableTextSelection(),this.togglePointerEvents(!0),this.disableClick();break;case PD.HIGHLIGHT:this.enableTextSelection(),this.togglePointerEvents(!1),this.disableClick();break;default:this.disableTextSelection(),this.togglePointerEvents(!0),this.enableClick()}this.toggleAnnotationLayerPointerEvents(!1);const{classList:t}=this.div;for(const n of bp(BP,BP,"f",XP).values())t.toggle(`${n._type}Editing`,e===n._editorType);this.div.hidden=!1}hasTextLayer(e){var t;return e===(null===(t=bp(this,KP,"f"))||void 0===t?void 0:t.div)}addInkEditorIfNeeded(e){if(bp(this,QP,"f").getMode()!==PD.INK)return;if(!e)for(const e of bp(this,WP,"f").values())if(e.isEmpty())return void e.setInBackground();this.createAndAddNewEditor({offsetX:0,offsetY:0},!1).setInBackground()}setEditingState(e){bp(this,QP,"f").setEditingState(e)}addCommands(e){bp(this,QP,"f").addCommands(e)}toggleDrawing(e=!1){this.div.classList.toggle("drawing",!e)}togglePointerEvents(e=!1){this.div.classList.toggle("k-annotation-editor-layer-disabled",!e)}toggleAnnotationLayerPointerEvents(e=!1){var t;null===(t=bp(this,NP,"f"))||void 0===t||t.div.classList.toggle("k-annotation-editor-layer-disabled",!e)}enable(){this.div.tabIndex=0,this.togglePointerEvents(!0);const e=new Set;for(const t of bp(this,WP,"f").values())t.enableEditing(),t.show(!0),t.annotationElementId&&(bp(this,QP,"f").removeChangedExistingAnnotation(t),e.add(t.annotationElementId));if(!bp(this,NP,"f"))return;const t=bp(this,NP,"f").getEditableAnnotations();for(const n of t){if(n.hide(),bp(this,QP,"f").isDeletedAnnotationElement(n.data.id))continue;if(e.has(n.data.id))continue;const t=this.deserialize(n);t&&(this.addOrRebuild(t),t.enableEditing())}}disable(){var e;yp(this,GP,!0,"f"),this.div.tabIndex=-1,this.togglePointerEvents(!1);const t=new Map,n=new Map;for(const i of bp(this,WP,"f").values())i.disableEditing(),i.annotationElementId&&(null===i.serialize()?(n.set(i.annotationElementId,i),null===(e=this.getEditableAnnotation(i.annotationElementId))||void 0===e||e.show(),i.remove()):t.set(i.annotationElementId,i));if(bp(this,NP,"f")){const e=bp(this,NP,"f").getEditableAnnotations();for(const i of e){const{id:e}=i.data;if(bp(this,QP,"f").isDeletedAnnotationElement(e))continue;let r=n.get(e);r?(r.resetAnnotationElement(i),r.show(!1),i.show()):(r=t.get(e),r&&(bp(this,QP,"f").addChangedExistingAnnotation(r),r.renderAnnotationElement(i),r.show(!1)),i.show())}}bp(this,LP,"m",nH).call(this),this.isEmpty&&(this.div.hidden=!0);const{classList:i}=this.div;for(const e of bp(BP,BP,"f",XP).values())i.remove(`${e._type}Editing`);this.disableTextSelection(),this.toggleAnnotationLayerPointerEvents(!0),yp(this,GP,!1,"f")}getEditableAnnotation(e){var t;return(null===(t=bp(this,NP,"f"))||void 0===t?void 0:t.getEditableAnnotation(e))||null}setActiveEditor(e){bp(this,QP,"f").getActive()!==e&&bp(this,QP,"f").setActiveEditor(e)}enableTextSelection(){var e;if(this.div.tabIndex=-1,(null===(e=bp(this,KP,"f"))||void 0===e?void 0:e.div)&&!bp(this,YP,"f")){yp(this,YP,new AbortController,"f");const e=bp(this,QP,"f").combinedSignal(bp(this,YP,"f"));bp(this,KP,"f").div.addEventListener("pointerdown",bp(this,LP,"m",ZP).bind(this),{signal:e})}}disableTextSelection(){var e;this.div.tabIndex=0,(null===(e=bp(this,KP,"f"))||void 0===e?void 0:e.div)&&bp(this,YP,"f")&&(bp(this,YP,"f").abort(),yp(this,YP,null,"f"),bp(this,KP,"f").div.classList.remove("highlighting"))}enableClick(){if(bp(this,$P,"f"))return;yp(this,$P,new AbortController,"f");const e=bp(this,QP,"f").combinedSignal(bp(this,$P,"f"));this.div.addEventListener("pointerdown",this.pointerdown.bind(this),{signal:e}),this.div.addEventListener("pointerup",this.pointerup.bind(this),{signal:e})}disableClick(){var e;null===(e=bp(this,$P,"f"))||void 0===e||e.abort(),yp(this,$P,null,"f")}attach(e){bp(this,WP,"f").set(e.id,e);const{annotationElementId:t}=e;t&&bp(this,QP,"f").isDeletedAnnotationElement(t)&&bp(this,QP,"f").removeDeletedAnnotationElement(e)}detach(e){var t;bp(this,WP,"f").delete(e.id),null===(t=bp(this,OP,"f"))||void 0===t||t.removePointerInTextLayer(e.contentDiv),!bp(this,GP,"f")&&e.annotationElementId&&bp(this,QP,"f").addDeletedAnnotationElement(e)}remove(e){this.detach(e),bp(this,QP,"f").removeEditor(e),e.div.remove(),e.isAttachedToDOM=!1,bp(this,qP,"f")||this.addInkEditorIfNeeded(!1)}changeParent(e){var t;e.parent!==this&&(e.parent&&e.annotationElementId&&(bp(this,QP,"f").addDeletedAnnotationElement(e.annotationElementId),pz.deleteAnnotationElement(e),e.annotationElementId=null),this.attach(e),null===(t=e.parent)||void 0===t||t.detach(e),e.setParent(this),e.div&&e.isAttachedToDOM&&(e.div.remove(),this.div.append(e.div)))}add(e){if(e.parent!==this||!e.isAttachedToDOM){if(this.changeParent(e),bp(this,QP,"f").addEditor(e),this.attach(e),!e.isAttachedToDOM){const t=e.render();this.div.append(t),e.isAttachedToDOM=!0}e.fixAndSetPosition(),e.onceAdded(),bp(this,QP,"f").addToAnnotationStorage(e)}}moveEditorInDOM(e){var t;if(!e.isAttachedToDOM)return;const{activeElement:n}=document;e.div.contains(n)&&!bp(this,UP,"f")&&(e._focusEventsAllowed=!1,yp(this,UP,setTimeout((()=>{yp(this,UP,null,"f"),e.div.contains(document.activeElement)?e._focusEventsAllowed=!0:(e.div.addEventListener("focusin",(()=>{e._focusEventsAllowed=!0}),{once:!0,signal:bp(this,QP,"f")._signal}),n.focus())}),0),"f")),e._structTreeParentId=null===(t=bp(this,OP,"f"))||void 0===t?void 0:t.moveElementInDOM(this.div,e.div,e.contentDiv,!0)}addOrRebuild(e){e.needsToBeRebuilt()?(e.parent||(e.parent=this),e.rebuild(),e.show()):this.add(e)}addUndoableEditor(e){this.addCommands({cmd:()=>e._uiManager.rebuild(e),undo:()=>{e.remove()},mustExec:!1})}getNextId(){return bp(this,QP,"f").getId()}combinedSignal(e){return bp(this,QP,"f").combinedSignal(e)}canCreateNewEmptyEditor(){var e;return null===(e=bp(this,LP,"a",JP))||void 0===e?void 0:e.canCreateNewEmptyEditor()}pasteEditor(e,t){bp(this,QP,"f").updateToolbar(e),bp(this,QP,"f").updateMode(e);const{offsetX:n,offsetY:i}=bp(this,LP,"m",tH).call(this),r=this.getNextId(),o=bp(this,LP,"m",eH).call(this,Object.assign({parent:this,id:r,x:n,y:i,uiManager:bp(this,QP,"f"),isCentered:!0},t));o&&this.add(o)}deserialize(e){var t,n;return(null===(n=bp(BP,BP,"f",XP).get(null!==(t=e.annotationType)&&void 0!==t?t:e.annotationEditorType))||void 0===n?void 0:n.deserialize(e,this,bp(this,QP,"f")))||null}createAndAddNewEditor(e,t,n={}){const i=this.getNextId(),r=bp(this,LP,"m",eH).call(this,Object.assign({parent:this,id:i,x:e.offsetX,y:e.offsetY,uiManager:bp(this,QP,"f"),isCentered:t},n));return r&&this.add(r),r}addNewEditor(){this.createAndAddNewEditor(bp(this,LP,"m",tH).call(this),!0)}setSelected(e){bp(this,QP,"f").setSelected(e)}toggleSelected(e){bp(this,QP,"f").toggleSelected(e)}isSelected(e){return bp(this,QP,"f").isSelected(e)}unselect(e){bp(this,QP,"f").unselect(e)}pointerup(e){const{isMac:t}=HD.platform;0!==e.button||e.ctrlKey&&t||e.target===this.div&&bp(this,jP,"f")&&(yp(this,jP,!1,"f"),bp(this,VP,"f")?bp(this,QP,"f").getMode()!==PD.STAMP?this.createAndAddNewEditor(e,!1):bp(this,QP,"f").unselectAll():yp(this,VP,!0,"f"))}pointerdown(e){if(bp(this,QP,"f").getMode()===PD.HIGHLIGHT&&this.enableTextSelection(),bp(this,jP,"f"))return void yp(this,jP,!1,"f");const{isMac:t}=HD.platform;if(0!==e.button||e.ctrlKey&&t)return;if(e.target!==this.div)return;yp(this,jP,!0,"f");const n=bp(this,QP,"f").getActive();yp(this,VP,!n||n.isEmpty(),"f")}findNewParent(e,t,n){const i=bp(this,QP,"f").findParent(t,n);return null!==i&&i!==this&&(i.changeParent(e),!0)}destroy(){var e,t;(null===(e=bp(this,QP,"f").getActive())||void 0===e?void 0:e.parent)===this&&(bp(this,QP,"f").commitOrRemove(),bp(this,QP,"f").setActiveEditor(null)),bp(this,UP,"f")&&(clearTimeout(bp(this,UP,"f")),yp(this,UP,null,"f"));for(const e of bp(this,WP,"f").values())null===(t=bp(this,OP,"f"))||void 0===t||t.removePointerInTextLayer(e.contentDiv),e.setParent(null),e.isAttachedToDOM=!1,e.div.remove();this.div=null,bp(this,WP,"f").clear(),bp(this,QP,"f").removeLayer(this)}render({viewport:e}){this.viewport=e,FD(this.div,e);for(const e of bp(this,QP,"f").getEditors(this.pageIndex))this.add(e),e.rebuild();this.updateMode()}update({viewport:e}){bp(this,QP,"f").commitOrRemove(),bp(this,LP,"m",nH).call(this);const t=this.viewport.rotation,n=e.rotation;if(this.viewport=e,FD(this.div,e),t!==n)for(const e of bp(this,WP,"f").values())e.rotate(n);this.addInkEditorIfNeeded(!1)}get pageDimensions(){const{pageWidth:e,pageHeight:t}=this.viewport.rawDims;return[e,t]}get scale(){return bp(this,QP,"f").viewParameters.realScale}}BP=pH,OP=new WeakMap,VP=new WeakMap,NP=new WeakMap,$P=new WeakMap,UP=new WeakMap,WP=new WeakMap,jP=new WeakMap,qP=new WeakMap,GP=new WeakMap,KP=new WeakMap,YP=new WeakMap,QP=new WeakMap,LP=new WeakSet,ZP=function(e){bp(this,QP,"f").unselectAll();const{target:t}=e;if(t===bp(this,KP,"f").div||t.classList.contains("endOfContent")&&bp(this,KP,"f").div.contains(t)){const{isMac:t}=HD.platform;if(0!==e.button||e.ctrlKey&&t)return;if(bp(this,QP,"f").showAllEditors("highlight",!0),bp(this,QP,"f").getMode()===PD.NONE)return;bp(this,KP,"f").div.addEventListener("pointerup",(()=>{bp(this,KP,"f").div.classList.remove("free"),this.toggleDrawing(!0)}),{once:!0,signal:bp(this,QP,"f")._signal}),e.preventDefault()}},JP=function(){return bp(BP,BP,"f",XP).get(bp(this,QP,"f").getMode())},eH=function(e){const t=bp(this,LP,"a",JP);return t?new t(e):null},tH=function(){const{x:e,y:t,width:n,height:i}=this.div.getBoundingClientRect(),r=Math.max(0,e),o=Math.max(0,t),a=(r+Math.min(window.innerWidth,e+n))/2-e,s=(o+Math.min(window.innerHeight,t+i))/2-t,[l,c]=this.viewport.rotation%180==0?[a,s]:[s,a];return{offsetX:l,offsetY:c}},nH=function(){yp(this,qP,!0,"f");for(const e of bp(this,WP,"f").values())e.isEmpty()&&e.remove();yp(this,qP,!1,"f")},pH._initialized=!1,XP={value:new Map([gz,hH].map((e=>[e._editorType,e])))};new WeakMap,new WeakMap,new WeakMap,new WeakMap,new WeakMap;const fH=new Map([["canvasWrapper",0],["textLayer",1],["annotationLayer",2],["annotationEditorLayer",3],["xfaLayer",3]]);new WeakMap,new WeakMap,new WeakMap,rH=new WeakMap,new WeakMap,new WeakMap,new WeakMap,oH=new WeakMap,iH=new WeakSet,aH=function(e,t){this.eventBus.dispatch(e,{source:this,pageNumber:this.id,error:t})};var mH;Object.freeze({map:null,hash:"",transfer:void 0});mH=new WeakMap,new WeakMap,new WeakMap,new WeakSet;var gH,vH;new WeakMap;const _H=0,bH=1,yH=2,wH=3,kH=4;class xH{constructor({eventBus:e=null,externalLinkTarget:t=null,externalLinkRel:n=null,ignoreDestinationZoom:i=!1}={}){this.eventBus=null,this.externalLinkTarget=null,this.externalLinkRel=null,this._ignoreDestinationZoom=null,this.baseUrl=null,this.pdfDocument=null,this.pdfViewer=null,this.pdfHistory=null,this.externalLinkEnabled=!0,this.eventBus=e,this.externalLinkTarget=t,this.externalLinkRel=n,this._ignoreDestinationZoom=i,this.baseUrl=null,this.pdfDocument=null,this.pdfViewer=null,this.pdfHistory=null}setDocument(e,t=null){this.baseUrl=t,this.pdfDocument=e}setViewer(e){this.pdfViewer=e}setHistory(e){this.pdfHistory=e}get pagesCount(){return this.pdfDocument?this.pdfDocument.numPages:0}get page(){return this.pdfDocument?this.pdfViewer.currentPageNumber:1}set page(e){this.pdfDocument&&(this.pdfViewer.currentPageNumber=e)}get rotation(){return this.pdfDocument?this.pdfViewer.pagesRotation:0}set rotation(e){this.pdfDocument&&(this.pdfViewer.pagesRotation=e)}get isInPresentationMode(){return!!this.pdfDocument&&this.pdfViewer.isInPresentationMode}goToDestination(e){return _p(this,void 0,void 0,(function*(){if(!this.pdfDocument)return;let t,n,i;if("string"==typeof e?(t=e,n=yield this.pdfDocument.getDestination(e)):(t=null,n=yield e),!Array.isArray(n))return;const[r]=n;if(r&&"object"==typeof r){if(i=this.pdfDocument.cachedPageNumber(r),!i)try{i=(yield this.pdfDocument.getPageIndex(r))+1}catch(t){return void console.error(`goToDestination: "${r}" is not a valid page reference, for dest="${e}".`)}}else Number.isInteger(r)&&(i=r+1);!i||i<1||i>this.pagesCount?console.error(`goToDestination: "${i}" is not a valid page number, for dest="${e}".`):(this.pdfHistory&&(this.pdfHistory.pushCurrentPosition(),this.pdfHistory.push({namedDest:t,explicitDest:n,pageNumber:i})),this.pdfViewer.scrollPageIntoView({pageNumber:i,destArray:n,ignoreDestinationZoom:this._ignoreDestinationZoom}))}))}goToPage(e){if(!this.pdfDocument)return;const t="string"==typeof e&&this.pdfViewer.pageLabelToPageNumber(e)||0|e;Number.isInteger(t)&&t>0&&t<=this.pagesCount?(this.pdfHistory&&(this.pdfHistory.pushCurrentPosition(),this.pdfHistory.pushPage(t)),this.pdfViewer.scrollPageIntoView({pageNumber:t})):console.error(`PDFLinkService.goToPage: "${e}" is not a valid page.`)}addLinkAttributes(e,t,n=!1){if(!t||"string"!=typeof t)throw new Error('A valid "url" parameter must provided.');const i=n?yH:this.externalLinkTarget,r=this.externalLinkRel;this.externalLinkEnabled?e.href=e.title=t:(e.href="",e.title=`Disabled: ${t}`,e.onclick=()=>!1);let o="";switch(i){case _H:break;case bH:o="_self";break;case yH:o="_blank";break;case wH:o="_parent";break;case kH:o="_top"}e.target=o,e.rel="string"==typeof r?r:"noopener noreferrer nofollow"}getDestinationHash(e){if("string"==typeof e){if(e.length>0)return this.getAnchorUrl("#"+escape(e))}else if(Array.isArray(e)){const t=JSON.stringify(e);if(t.length>0)return this.getAnchorUrl("#"+escape(t))}return this.getAnchorUrl("")}getAnchorUrl(e){return this.baseUrl?this.baseUrl+e:e}setHash(e){if(!this.pdfDocument)return;let t,n;if(e.includes("=")){const i=function(e){const t=new Map,n=new URLSearchParams(e);for(const[e,i]of n)t.set(e.toLowerCase(),i);return t}(e);if(i.has("search")){const e=i.get("search").replaceAll('"',""),t="true"===i.get("phrase");this.eventBus.dispatch("findfromurlhash",{source:this,query:t?e:e.match(/\S+/g)})}if(i.has("page")&&(t=0|i.get("page")||1),i.has("zoom")){const e=i.get("zoom").split(","),t=e[0],r=parseFloat(t);t.includes("Fit")?"Fit"===t||"FitB"===t?n=[null,{name:t}]:"FitH"===t||"FitBH"===t||"FitV"===t||"FitBV"===t?n=[null,{name:t},e.length>1?0|e[1]:null]:"FitR"===t?5!==e.length?console.error('PDFLinkService.setHash: Not enough parameters for "FitR".'):n=[null,{name:t},0|e[1],0|e[2],0|e[3],0|e[4]]:console.error(`PDFLinkService.setHash: "${t}" is not a valid zoom value.`):n=[null,{name:"XYZ"},e.length>1?0|e[1]:null,e.length>2?0|e[2]:null,r?r/100:t]}return n?this.pdfViewer.scrollPageIntoView({pageNumber:t||this.page,destArray:n,allowNegativeOffset:!0}):t&&(this.page=t),i.has("pagemode")&&this.eventBus.dispatch("pagemode",{source:this,mode:i.get("pagemode")}),void(i.has("nameddest")&&this.goToDestination(i.get("nameddest")))}n=unescape(e);try{n=JSON.parse(n),Array.isArray(n)||(n=n.toString())}catch(e){if(!e)return}("string"==typeof n||bp(gH,gH,"m",vH).call(gH,n))&&this.goToDestination(n)}executeNamedAction(e){var t,n;if(this.pdfDocument){switch(e){case"GoBack":null===(t=this.pdfHistory)||void 0===t||t.back();break;case"GoForward":null===(n=this.pdfHistory)||void 0===n||n.forward();break;case"NextPage":this.pdfViewer.nextPage();break;case"PrevPage":this.pdfViewer.previousPage();break;case"LastPage":this.page=this.pagesCount;break;case"FirstPage":this.page=1}this.eventBus.dispatch("namedaction",{source:this,action:e})}}executeSetOCGState(e){return _p(this,void 0,void 0,(function*(){if(!this.pdfDocument)return;const t=this.pdfDocument,n=yield this.pdfViewer.optionalContentConfigPromise;t===this.pdfDocument&&(n.setOCGState(e),this.pdfViewer.optionalContentConfigPromise=Promise.resolve(n))}))}}var CH;gH=xH,vH=function(e){if(!Array.isArray(e)||e.length<2)return!1;const[t,n,...i]=e;if(!("object"==typeof t&&Number.isInteger(null==t?void 0:t.num)&&Number.isInteger(null==t?void 0:t.gen)||Number.isInteger(t)))return!1;if("object"!=typeof n||"string"!=typeof(null==n?void 0:n.name))return!1;const r=i.length;let o=!0;switch(n.name){case"XYZ":if(r<2||r>3)return!1;break;case"Fit":case"FitB":return 0===r;case"FitH":case"FitBH":case"FitV":case"FitBV":if(r>1)return!1;break;case"FitR":if(4!==r)return!1;o=!1;break;default:return!1}for(const e of i)if(!("number"==typeof e||o&&null===e))return!1;return!0},function(e){e[e.TextSelection=0]="TextSelection",e[e.Pan=1]="Pan"}(CH||(CH={}));new WeakMap,new WeakMap,new WeakMap,new WeakMap,new WeakSet,function(e){var t=window.kendo,n=e.extend,i=t.Class.extend({init:function(e,t){var n=this;n.options=e,n.read=e.read,n.upload=e.upload,n.download=e.download,n.viewer=t},fetchDocument:function(){var n=this,i=e.Deferred(),r=n.viewer.options.messages.errorMessages;return n.read?(e.ajax({type:n.read.type,url:n.read.url,dataType:n.read.dataType,success:function(e){"string"!=typeof e&&(e=t.stringify(e)),i.resolve(JSON.parse(e))},error:function(e){n.viewer._triggerError({error:e.responseText,message:r.parseError})}}),i):i.resolve()},fetchPageData:function(t){var n=this,i=e.Deferred(),r=n.viewer.document.pages[t-1],o={};return o[n.read.pageField]=t,r.geometries.length?i.resolve(r):e.ajax({type:n.read.type,url:n.read.url,data:o,success:function(e){i.resolve(JSON.parse(e))},error:function(e){n.viewer._triggerError({error:e.responseText,message:n.viewer.options.messages.errorMessages.parseError})}}),i},downloadFile:function(e){window.location=this.download.url+"?file="+e},fromJSON:function(e){var t=this.viewer;t._clearPages(),t.document=e,t.document.total=t.document.pages.length,t._renderPages(),t.resize(!0),t.activatePage(1)}});n(t,{pdfviewer:{dpl:{processor:i}}})}(window.kendo.jQuery),kendo.pdfviewer.pdfjs={lib:window.pdfjsLib},function(e){var t=kendo.Class,n=e.extend,i=JSON.parse,r=kendo.ui.progress,o=(t=kendo.Class,t.extend({init:function(e){this.viewer=e,this.errorMessages=this.viewer.options.messages.errorMessages,this.upload=this.viewer.processor&&this.viewer.processor.upload},_initUpload:function(t,i){var r=n({select:this._onSelect.bind(this),success:this._onSuccess.bind(this),error:this._onError.bind(this),complete:this._onComplete.bind(this),showFileList:!1,multiple:!1,validation:{allowedExtensions:[".pdf"]}},i||{});return this.upload&&n(r,{async:{saveUrl:this.upload.url,autoUpload:!0,saveField:this.upload.saveField}}),(t||e('<input name="files" accept=".pdf" type="file" />')).kendoUpload(r).getKendoUpload()},_onComplete:function(){r(this.viewer.pageContainer,!1)},_onSuccess:function(t){var n=i(t.response);e.isPlainObject(n)?this.viewer.processor.fromJSON(n):this.viewer._triggerError({error:n,message:this.errorMessages.parseError})},_onError:function(e){this.viewer._triggerError({error:e.XMLHttpRequest.responseText,message:this.errorMessages.notSupported})},_onSelect:function(e){var t=this,n=e.files[0];if(r(t.viewer.pageContainer,!0),!t.viewer.trigger("open",{file:n})&&!t.upload)if(".pdf"===n.extension.toLowerCase()){var i=new FileReader;i.onload=function(e){var n=e.target.result;t.viewer.fromFile(n)},i.onerror=function(){t.viewer._triggerError({error:n,message:t.errorMessages.parseError})},i.readAsArrayBuffer(n.rawFile)}else t.viewer._triggerError({error:n,message:t.errorMessages.notSupported})}}));n(kendo.pdfviewer,{UploadHelper:o})}(window.kendo.jQuery),function(e){var t=e.extend,n=e.noop,i=kendo.drawing,r=i.Group,o=i.Surface,a=kendo.Class,s=kendo.pdfviewer.UploadHelper,l={Path:"path",MultiPath:"multipath",Rect:"rect",Image:"image",Text:"text"},c=a.extend({init:function(t,n){this.viewer=n,this.processor=t.processor,this.options=t,this.pageNumber=t.number,this.element=e("<div class='k-page' />"),this.element.attr(kendo.attr("number"),this.pageNumber),this._updatePageSize(t),this.width=t.width,this.height=t.height},resize:function(e){var t=this.element;this._updatePageSize({width:Math.min(t.width()*e,this.width),height:Math.min(t.height()*e,this.height)})},_updatePageSize:function(e){this.element.width(e.width).height(e.height)},destroy:function(){kendo.destroy(this.element)},render:n}),d=c.extend({init:function(t,n){this.viewer=n,this.options=t,this._externalDropZoneId=`${n.element.attr("id")}-external-dropzone`,this.element=e(`<div class="k-page k-blank-page">\n        <div id="${this._externalDropZoneId}" class="k-external-dropzone">\n            <div class="k-dropzone-inner">\n                <span class="k-dropzone-icon k-icon k-svg-icon k-icon-xxxl k-svg-i-upload">\n                    <svg aria-hidden="true" focusable="false" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\n                        <path d="M32 384v96h448v-96H32zm192-64h64V192h96L256 32 128 192h96v128z"></path>\n                    </svg>\n                </span>\n                <span class="k-dropzone-hint">Drag and drop files here to upload</span>\n            </div>\n        </div>\n        <input name="files" accept=".pdf" type="file" ref-pdfviewer-blank-page-upload>\n    </div>`),this._uploadHelper=new s(n)},_initUpload:function(){this._upload=this._uploadHelper._initUpload(this.element.find("input[ref-pdfviewer-blank-page-upload]"),{dropZone:`#${this._externalDropZoneId}`,showFileList:!1,async:{autoUpload:!1,saveUrl:"save"}})},resize:n,_updatePageSize:n,destroy:function(){this._upload&&this._upload.destroy(),kendo.destroy(this.element)},render:n}),u=c.extend({draw:function(){var e=this,t=e.options.geometries;e.group=new r,e.surface.draw(e.group),e._drawGeometries(t),e.viewer.trigger("render",{page:this}),kendo.ui.progress(e.element,!1)},load:function(){var e=this;!e.loaded&&e.processor&&(e.processor.fetchPageData(e.pageNumber).then((function(t){e.options=t,e._initSurface(),e.draw()})),e.loaded=!0)},_initSurface:function(){var e={width:this.element.width(),height:this.element.height()},n=t({width:this.width,height:this.height},this.viewer.options.view);this.surface=new o(this.element,n),this._updatePageSize(e)},_drawGeometries:function(e){var t,n=this;if(e)for(var i=0;i<=e.length;i++){var r=e[i];if(r){switch(r.type){case l.Path:case l.MultiPath:t=n._drawPath(r);break;case l.Rect:t=n._drawRect(r);break;case l.Image:t=n._drawImage(r);break;case l.Text:t=n._drawText(r);break;default:t=null}t&&n.group.append(t)}}},_drawRect:function(e){var t=new kendo.geometry.Rect(e.point,e.size);return new i.Rect(t,{transform:this._getMatrix(e.transform),fill:e.fillOptions,stroke:e.strokeOptions})},_drawImage:function(e){var t=new kendo.geometry.Rect(e.point,e.size);return new i.Image(e.src,t,{transform:this._getMatrix(e.transform)})},_drawText:function(e){var t={transform:this._getMatrix(e.transform),stroke:e.strokeOptions,fill:e.fillOptions,font:e.font};return new kendo.drawing.Text(e.content,e.point,t)},_drawPath:function(e){for(var t={transform:this._getMatrix(e.transform),stroke:e.strokeOptions,fill:e.fillOptions},n=new i.MultiPath(t),r=0;r<e.paths.length;r++){var o=e.paths[r];if(!o.segments)return;n.moveTo.apply(n,o.point);for(var a=0;a<o.segments.length;a++){var s=o.segments[a];(1===s.points.length?n.lineTo:n.curveTo).apply(n,s.points)}o.closed&&n.close()}return n},_getMatrix:function(e){var t=Object.create(kendo.geometry.Matrix.prototype);return kendo.geometry.Matrix.apply(t,e),t}});t(kendo.pdfviewer.dpl,{geometryTypes:l,Page:u}),t(kendo.pdfviewer,{BlankPage:d})}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=(JSON.parse,t.ui.progress),r=t.Class,o=t.pdfviewer.UploadHelper,a=r.extend({init:function(e){this.options=e,this.viewer=e.viewer,this.errorMessages=this.viewer.options.messages.errorMessages}}),s=a.extend({init:function(e){a.fn.init.call(this,e),this._uploadHelper=new o(this.viewer)},exec:function(){this.viewer._upload=this.viewer._upload||this._uploadHelper._initUpload(),this.viewer._upload.element.click()}}),l=a.extend({exec:function(){var e,t,n=this.options.value,i=this.viewer;if(isNaN(n))switch(e=i._pageNum,t=i.document.total||i.document.numPages,n){case"first":n=1;break;case"prev":n=e>1?e-1:1;break;case"next":n=e<t?e+1:t;break;case"last":n=t}else n=Number(n);i.activatePage(n,!1)}}),c=a.extend({exec:function(){const e=this;if(!e.viewer.document)return void e.viewer._triggerError({message:e.errorMessages.notFound});const t=e.viewer.document.info&&e.viewer.document.info.title||e.viewer.options.messages.defaultFileName;e.viewer._isDPLProcessor()?e.viewer.processor.downloadFile(t):((e,t="Document",n={},i)=>{e.pdf&&e.pdf.getData().then((e=>new Blob([e],{type:"application/pdf"}))).then((e=>{i(e,t,n)||TD(e,t,n)})).catch((t=>{e.error.call(void 0,t)}))})({pdf:this.viewer.document,error:t=>{e.viewer._triggerError({message:t.message})}},t,{},((e,t,n)=>!1))}}),d=a.extend({init:function(t){t=e.extend(t,this.options),a.fn.init.call(this,t)},exec:function(){var e=this.viewer._saveDialog||this._initDialog();e._updateModel({pagesCount:this.viewer.document&&this.viewer.document.total||1,page:this.viewer.options.page}),e.open()},apply:function(e){var t=e.extension;".png"===t?this.viewer.exportImage(e):".svg"===t&&this.viewer.exportSVG(e)},_initDialog:function(){return this.viewer._saveDialog=new t.pdfviewer.dialogs.ExportAsDialog({apply:this.apply.bind(this),pagesCount:this.viewer.document&&this.viewer.document.total||1,messages:this.viewer.options.messages}),this.viewer._saveDialog}}),u=a.extend({exec:function(){this.viewer._toggleSelection(!0)}}),h=a.extend({exec:function(){this.viewer._toggleSelection(!1)}});const p=a.extend({init:function(e){const n=this;n.viewer=e.viewer,n.viewer.searchDialog||(n.viewer.searchDialog=new t.pdfviewer.dialogs.SearchDialog({pageContainer:n.viewer.pageContainerWrapper,position:{top:n.viewer.pageContainer.offset().top,left:n.viewer.pageContainer.offset().left},messages:n.viewer.options.messages.dialogs.search,open:n._open.bind(n),next:n._next.bind(n),prev:n._prev.bind(n),close:n._close.bind(n)})),a.fn.init.call(n,e)},exec:function(){this.viewer.searchDialog.open()},_open:function(){const e=this;e.searchService||Promise.all(e.viewer._loadAllPages()).then((()=>{e.searchService=new dA({textContainers:e.viewer.pageContainer.find(".k-text-layer").get()||[]}),e.changeHandler=e._change.bind(e),e.viewer.searchDialog.searchModel.bind("change",e.changeHandler)}))},_close:function(){const e=this;e.searchService.destroy(),e.searchService=null,e.viewer.toolbar.element.find("[tabindex=0]").trigger("focus"),e.viewer.searchDialog.searchModel.unbind("change",e.changeHandler),e.matches=[],e.matchIndex=null,e._updateSearchModel()},_change:function(e){const t=this,n=t.viewer.searchDialog.searchModel.searchText,i=t.viewer.searchDialog.searchModel.matchCase;"searchText"!==e.field&&"matchCase"!==e.field||(t.matches=t.searchService.search({text:n,matchCase:i}),t.matchIndex=t.matches.length?1:0,t._updateSearchModel())},_next:function(){const e=this,t=e.viewer.pdfScroller;(e=>{e.search.markNextMatch();const t=e.search.getActiveMatchElement();SA(t,e)})({search:e.searchService,scroller:t}),e.matchIndex=e.matchIndex+1>e.matches.length?1:e.matchIndex+1,e._updateSearchModel()},_prev:function(){const e=this,t=e.viewer.pdfScroller;(e=>{e.search.markPreviousMatch();const t=e.search.getActiveMatchElement();SA(t,e)})({search:e.searchService,scroller:t}),e.matchIndex=e.matchIndex-1<1?e.matches.length:e.matchIndex-1,e._updateSearchModel()},_updateSearchModel:function(){const e=this,t=e.viewer.searchDialog.searchModel;e.matches&&e.matches.length?(t.set("matches",e.matches.length),t.set("matchIndex",e.matchIndex)):(t.set("searchText",""),t.set("matches",0),t.set("matchIndex",0))},_closeDialog:function(){this.viewer.searchDialog.close()}});var f=a.extend({exec:function(){const e=this,t=e.options,n=e.viewer;let i=t.value||t.scale;"dpl"!==n.processingLib&&(i=e._calculateZoom(),i&&(n.zoomScale=i,n._setPageContainerScaleFactor(i),e.viewer.document&&(e=>{const{pdfDoc:t,zoom:n,dom:i,done:r,error:o,loadOnDemand:a,rootElement:s}=e,l=[];let c=0;a&&s&&(c=DA(s));for(let e=1;e<=t.numPages;e++)l.push(t.getPage(e));Promise.all(l).then((e=>e.map(((e,r)=>{e._pageInfo.rendered=!1;const l=yA(e,n,t,s);return vA(i,l.pageElement,r),a||CA(e,l,o),e._pageInfo.emptyPage=l,e})))).then((e=>{if(a){const t=e[c];CA(t,t._pageInfo.emptyPage,o),TA(s,c)}r(e)})).catch(o)})({pdfDoc:n.document,zoom:i,dom:n.pageContainer[0],rootElement:n.element[0],loadOnDemand:!0,done:t=>{const r=DA(n.element[0]);n._pageRenderPromise(t[r],!0),e._triggerZoomEnd(i)},error:t=>{e._triggerZoomEnd(i)}})))},_calculateZoom:function(){var e,n=this.options,i=this.viewer,r=i.options,o=i.pageContainer,a=n.value||n.scale,s=a;if(i._allowResize=!1,i._autoFit=!1,n.zoomIn?s=a=i.zoomScale+r.zoomRate:n.zoomOut?s=a=i.zoomScale-r.zoomRate:"auto"===a?(i._allowResize=!0,s=i._autoZoomScale):"string"!=typeof a||t.parseFloat(a)?a&&a.toString().match(/^[0-9]+%?$/)?s=a=parseInt(a.replace("%",""),10)/100:e=isNaN(a):s=((e,t,n,i)=>{const r=i.closest(".k-pdf-viewer-canvas"),o=i.querySelector(".k-page"),a=o.offsetWidth,s=o.offsetHeight;let l=e;return"ActualWidth"===t?l=1:"FitToWidth"===t?l=r.offsetWidth/(a/n):"FitToPage"===t&&(l=r.offsetHeight/(s/n)),l})(0,a,i.zoomScale,o[0]),e||(e=a<r.zoomMin||a>r.zoomMax),!e&&!i.trigger("zoomStart",{scale:a}))return n.updateComboBox&&i.toolbar&&i._updateZoomComboBox(a),s},_triggerZoomEnd:function(e){this.viewer.trigger("zoomEnd",{scale:e})}}),m=a.extend({init:function(e){a.fn.init.call(this,e)},exec:function(){const e=this;e.viewer.document?(i(e.viewer.pageContainer,!0),Promise.all(e.viewer._loadAllPages()).then((()=>{((e,t,n)=>{const i=document.createElement("div"),r=e.map((()=>!1)),o=mA();e.forEach(((e,a)=>{const s=wA(e,(e=>{i.appendChild(e),r[a]=!0,r.every(Boolean)&&bA(i,Math.floor(s.width/o),Math.floor(s.height/o),t,n)}),n)}))})(e.viewer.pages,e.onPrintComplete.bind(e),e.onPrintError.bind(e))}))):e.viewer._triggerError({message:this.errorMessages.notFound})},onPrintComplete:function(){i(this.viewer.pageContainer,!1)},onPrintError:function(){const e=this;i(e.viewer.pageContainer,!1),e.viewer._triggerError({message:e.errorMessages.popupBlocked})}});n(t.pdfviewer,{OpenCommand:s,PageChangeCommand:l,DownloadCommand:c,EnableSelectionCommand:u,EnablePanCommand:h,ExportCommand:d,PrintCommand:m,OpenSearchCommand:p,ZoomCommand:f})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.htmlEncode,i=e.extend,r=t.Class,o=t.ui.Draggable,a=t._outerWidth,s=".svg",l=".png",c=t.keys,d=r.extend({init:function(t){this.options=i(t,{actions:[{text:t.messages.dialogs.okText}]}),this._dialog=e("<div />").kendoDialog(this.options).getKendoDialog()},open:function(){this._dialog.center().open()}}),u=r.extend({init:function(e){return this.options=i(e,this.options,{fileFormats:[{description:e.messages.dialogs.exportAsDialog.png,extension:l},{description:e.messages.dialogs.exportAsDialog.svg,extension:s}],title:e.messages.dialogs.exportAsDialog.title,open:function(){this.center()}}),this._initializeDialog(),this},options:{extension:l,autoFocus:!0,resizable:!1,modal:{preventScroll:!0},width:"90%",maxWidth:520,template:({messages:e,total:t})=>`<div class='k-edit-label'><label>${n(e.exportAsDialog.labels.fileName)}:</label></div><div class='k-edit-field'><span class='k-textbox k-input k-input-md k-rounded-md k-input-solid'><input class='k-input-inner' data-bind='value: name' /></span></div><div><div class='k-edit-label'><label>${n(e.exportAsDialog.labels.saveAsType)}:</label></div><div class='k-edit-field'><select data-role='dropdownlist' class='k-file-format' data-text-field='description' data-value-field='extension' data-bind='value: extension, source: fileFormats'></select></div></div><div class='k-edit-label'><label>${n(e.exportAsDialog.labels.page)}:</label></div><div class='k-edit-field'><input data-role='numerictextbox' data-format='n0' data-min='1' data-max='${n(t)}' data-bind='value: page' /></div><div class='k-actions'><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-primary' data-bind='click: apply'><span class='k-button-text'>${n(e.save)}</span></button><button class='k-button k-button-md k-rounded-md k-button-solid k-button-solid-base' data-bind='click: close'><span class='k-button-text'>${n(e.cancel)}</span></button></div>`},_updateModel:function(e){e.pagesCount&&this.viewModel.set("pagesCount",e.pagesCount),e.page&&this.viewModel.set("page",e.page)},_initializeDialog:function(){var n=this,i=n.options,r=i.messages.dialogs,o=e("<div class='k-pdf-viewer-window k-action-window k-popup-edit-form' />").append(t.template(i.template)({total:i.pagesCount,messages:r})).kendoWindow(i).getKendoWindow();return n.viewModel=t.observable({title:r.exportAsDialog.title,name:r.exportAsDialog.defaultFileName,extension:i.extension,fileFormats:i.fileFormats,pagesCount:i.pagesCount,page:1,apply:n.apply.bind(this),close:function(){o.close()}}),n._dialog=o,t.bind(o.element,n.viewModel),o},open:function(){this._dialog.center().open()},apply:function(){this._dialog.close(),this.options.apply({fileName:this.viewModel.name+this.viewModel.extension,extension:this.viewModel.extension,page:this.viewModel.page})}}),h=r.extend({init:function(e){this.options=i({},e,this.options)},options:{resizable:!1,template:({messages:e})=>`<div class="k-search-panel k-pos-sticky k-top-center"><button aria-label='${n(e.dragHandle)}' class='k-button k-button-md k-rounded-md k-button-flat k-button-flat-base k-icon-button k-search-dialog-draghandle'>${t.ui.icon({icon:"handle-drag",iconClass:"k-button-icon"})}</button><span class='k-textbox k-input k-input-md k-rounded-md k-input-solid'><input class='k-search-dialog-input k-input-inner' data-bind='value: boundValue, events: { keyup: onKeyup, input: onInput }' aria-label='${n(e.inputLabel)}' title='${n(e.inputLabel)}' /><span class='k-input-suffix'><button class='k-button k-button-md k-rounded-md k-button-flat k-button-flat-base k-icon-button k-match-case-button k-match-case-button' data-bind='css: {k-selected: matchCase}, click: matchCaseClick' aria-label='${n(e.matchCase)}' title='${n(e.matchCase)}'>${t.ui.icon({icon:"convert-lowercase",iconClass:"k-button-icon"})}</button></span></span><span class='k-search-matches'><span data-bind='text: matchIndex'></span> ${n(e.of)} <span data-bind='text: matches'></span></span><button class='k-button k-button-md k-rounded-md k-button-flat k-button-flat-base k-icon-button' data-bind='click: prev' aria-label='${n(e.previous)}' title='${n(e.previous)}'>${t.ui.icon({icon:"arrow-up",iconClass:"k-button-icon"})}</button><button class='k-button k-button-md k-rounded-md k-button-flat k-button-flat-base k-icon-button' data-bind='click: next' aria-label='${n(e.next)}' title='${n(e.next)}'>${t.ui.icon({icon:"arrow-down",iconClass:"k-button-icon"})}</button><button class='k-button k-button-md k-rounded-md k-button-flat k-button-flat-base k-icon-button' data-bind='click: close' aria-label='${n(e.close)}' title='${n(e.close)}'>${t.ui.icon({icon:"x",iconClass:"k-button-icon"})}</button></div>`},open:function(){var e=this;e.dialog||e._initializeDialog(),e.options.open(),e._showSearchDialog()},close:function(){this.options.close(),this._hideSearchDialog()},_showSearchDialog:function(){var e=this;e.dialog.css("left",e.options.pageContainer.innerWidth()/2-a(e.dialog,!0)/2+"px"),e.dialog.kendoStop().kendoAnimate({effects:{zoom:{direction:"in"},fade:{direction:"in"}},duration:350,complete:function(t){e.dialog.find(".k-search-dialog-input").trigger("focus")}})},_hideSearchDialog:function(){this.dialog.kendoStop().kendoAnimate({effects:{zoom:{direction:"out",properties:{scale:.7}},fade:{direction:"out"}},duration:350,hide:!0})},_initializeDialog:function(){var n=this,i=t.template(n.options.template),r=e(i({messages:n.options.messages}));n.options.pageContainer.prepend(r),n.dialog=r,n._draggable=new o(r,{filter:".k-search-dialog-draghandle",axis:"x",dragstart:function(e){var i=n.dialog,r=n.options.pageContainer;if(i.startPosition={left:e.x.client-t.getOffset(i,"position").left},!r)return null;r._innerWidth=r.innerWidth(),parseInt(r._innerWidth,10)>r[0].clientWidth&&(r._innerWidth-=t.support.scrollbar()),i.maxLeft=r._innerWidth-a(i,!0)},drag:function(e){var t,i=n.dialog,r={};(t=e.x.client-i.startPosition.left)&&isNaN(t)&&t.toString().indexOf("px")<0?r.left=t:r.left=Math.max(Math.min(parseInt(t,10),parseInt(i.maxLeft,10)),0),i.css(r)}}),n._draggable.userEvents.stopPropagation=!1,n.searchModel=t.observable({boundValue:"",searchText:"",matchCase:!1,matchIndex:0,matches:0,matchCaseClick:function(){this.set("matchCase",!this.matchCase)},next:n.options.next,prev:n.options.prev,close:function(){this.set("boundValue",""),n.close()},onKeyup:function(e){var t=e.keyCode,n=e.shiftKey?this.prev:this.next;t===c.ENTER?(n(),e.preventDefault()):t==c.ESC&&this.close()},onInput:function(e){this.set("searchText",e.target.value)}}),t.bind(r,n.searchModel)}});i(t.pdfviewer,{dialogs:{ErrorDialog:d,ExportAsDialog:u,SearchDialog:h}})}(window.kendo.jQuery);!function(e){var t,n=".kendoPDFViewer",i=window.kendo,r=i.ui,o=e.extend,a=i.drawing,s=e.extend({PLUS:187,MINUS:189,ZERO:48,NUMPAD_ZERO:96},i.keys),l=i.pdfviewer.BlankPage,c=r.Widget,d=i.ui.progress,u="scroll",h="render",p="error",f="keydown"+n,m="DOMMouseScroll"+n+" mousewheel"+n,g="update",v="pagechange",_="ZoomCommand",b="change",y="k-disabled",w="pdfjs",k="dpl",x="k-pdf-viewer",C="k-canvas k-pdf-viewer-canvas k-pos-relative k-overflow-auto",S="k-enable-text-select",T="k-enable-panning",D="auto",A="ActualWidth",M="FitToWidth",E="FitToPage",I=c.extend({init:function(e,t){var n=this;c.fn.init.call(n,e,i.deepExtend({},this.options,t)),n._processMessages(),n._wrapper(),n.options.toolbar&&n._renderToolbar(),n._initProcessor(t||{}),n._renderPageContainer(),n._isDPLProcessor()?n._loadDPLDocument():n._loadPdfJSDocument(),i.notify(n,i.ui),n._showWatermarkOverlay&&n._showWatermarkOverlay(n.wrapper[0])},events:[h,"open",p,"zoomStart","zoomEnd"],options:{name:"PDFViewer",view:{type:"canvas"},pdfjsProcessing:{file:null,loadOnDemand:!0},dplProcessing:{read:{url:null,type:"GET",dataType:"json",pageField:"pageNumber"},upload:{url:null,saveField:"file"},download:{url:null},loadOnDemand:!1},toolbar:{items:[]},width:1e3,height:1200,page:1,defaultPageSize:{width:794,height:1123},scale:null,zoomMin:.5,zoomMax:4,zoomRate:.25,messages:{defaultFileName:"Document",toolbar:{zoom:{zoomLevel:"zoom level",zoomOut:"Zoom Out",zoomIn:"Zoom In",actualWidth:"Actual Width",autoWidth:"Automatic Width",fitToWidth:"Fit to Width",fitToPage:"Fit to Page"},open:"Open",exportAs:"Export",download:"Download",print:"Print",toggleSelection:"Enable Selection",togglePan:"Enable Panning",search:"Search"},errorMessages:{notSupported:"Only pdf files allowed.",parseError:"PDF file fails to process.",notFound:"File is not found.",popupBlocked:"Popup is blocked."},dialogs:{exportAsDialog:{title:"Export...",defaultFileName:"Document",pdf:"Portable Document Format (.pdf)",png:"Portable Network Graphics (.png)",svg:"Scalable Vector Graphics (.svg)",labels:{fileName:"File name",saveAsType:"Save as",page:"Page"}},okText:"OK",save:"Save",cancel:"Cancel",search:{inputLabel:"Search Text",matchCase:"Match Case",next:"Next Match",previous:"Previous Match",close:"Close",of:"of",dragHandle:"Drag search"}}}},defaultTools:{pager:{type:"component",name:"pager",overflow:"never",component:"Pager",element:"<div></div>",componentOptions:{navigatable:!0,_isToolbarItem:!0}},spacer:{type:"spacer"},zoomInOut:{type:"buttonGroup",fillMode:"flat",buttons:[{type:"button",icon:"zoom-out",name:"zoomOut",command:"ZoomCommand",showText:"overflow",options:'{ "zoomOut": true, "updateComboBox": true }',fillMode:"flat"},{type:"button",icon:"zoom-in",name:"zoomIn",command:"ZoomCommand",showText:"overflow",options:'{ "zoomIn": true, "updateComboBox": true }',fillMode:"flat"}]},zoom:{type:"component",name:"zoom",command:"ZoomCommand",overflow:"never",component:"ComboBox",data:[50,100,150,200,300,400],componentOptions:{enable:!1,dataTextField:"text",dataValueField:"percent",valuePrimitive:!0,clearOnEscape:!1,commandOn:"change",fillMode:"flat"}},toggleSelection:{type:"buttonGroup",fillMode:"flat",buttons:[{togglable:!0,command:"EnableSelectionCommand",icon:"pointer",showText:"overflow",name:"toggleSelection",group:"toggle-pan",fillMode:"flat"},{togglable:!0,command:"EnablePanCommand",icon:"hand",showText:"overflow",name:"togglePan",group:"toggle-pan",selected:!0,fillMode:"flat"}]},spacer2:{type:"spacer"},search:{type:"button",command:"OpenSearchCommand",icon:"search",name:"search",showText:"overflow",enable:!1,fillMode:"flat"},open:{type:"button",showText:"overflow",name:"open",icon:"folder-open",command:"OpenCommand",fillMode:"flat"},download:{type:"button",showText:"overflow",name:"download",icon:"download",command:"DownloadCommand",enable:!1,fillMode:"flat"},print:{type:"button",showText:"overflow",name:"print",icon:"print",command:"PrintCommand",enable:!1,fillMode:"flat"}},exportAsTool:{exportAs:{type:"button",showText:"overflow",name:"exportAs",icon:"image-export",command:"ExportCommand",fillMode:"flat"}},_processMessages:function(){var t=this.options.messages.toolbar.zoom;e.isPlainObject(t)&&(this.options.messages.toolbar=e.extend({},this.options.messages.toolbar,t),this.options.messages.toolbar.zoom=t.zoomLevel||this.options.messages.toolbar.zoom)},_wrapper:function(){var e=this,t=e.options;e.wrapper=e.element,e.wrapper.width(t.width).height(t.height).addClass(x).on(f,e._keydown.bind(e)),e._allowResize=null===e.options.scale,e._autoZoomScale=fA,e.zoomScale=e.options.scale||e._autoZoomScale,e._resizeHandler=i.onResize((function(){e.resize()})),e._pageNum=e.options.page},_keydown:function(e){var t=[s.PLUS,s.NUMPAD_PLUS],n=[s.MINUS,s.NUMPAD_MINUS],i=[s.ZERO,s.NUMPAD_ZERO],r=!1,o={command:_,options:{updateComboBox:!0}};e.ctrlKey&&!this._blankPage&&this.processingLib!==k&&(t.includes(e.keyCode)?(o.options.zoomIn=!0,r=!0):n.includes(e.keyCode)?(o.options.zoomOut=!0,r=!0):i.includes(e.keyCode)&&(o.options.value=fA,r=!0),r&&(this.execute(o),e.preventDefault()))},_handlePageChangeEvent:function(e){const t=this;t._pageChangeFromScroll||(this.activatePage(e.index,!1),t._showPagerInputLabels()),delete t._pageChangeFromScroll},_showPagerInputLabels:function(){const t=this.pager.element.find(".k-pager-input").children();if(t){const n=t.eq(0).add(t.eq(2));e(n).is(":visible")||n.show()}},_resizePager:function(){const e=this;if(!e.pager||!e.pager.options.responsive)return;const t=i._outerWidth(e.pager.element),n=Array.from(e.toolbar.element.children(":not(.k-hidden):not(:has(.k-pager))")),r=i._outerWidth(e.element);let o=0;const a=Number(e.toolbar.element.css("gap").replace(/(em|ex|%|px|cm|mm|in|pt|pc|ch|rem|vh|vw|vmin|vmax)$/,""));if(n.length>0){let e=0;for(let t=0;t<n.length;t++)e+=i._outerWidth(n[t])+a;e&&(o=e)}const s=e.pager.element.find(".k-pager-nav");if(t+o+a>r)for(var l=s.length-1;l>=0;l--){s.eq(l).addClass("k-hidden")}if(t+o+a<r){const t=e.pager.element.find(".k-hidden");for(l=0;l<t.length;l++){t.eq(l).removeClass("k-hidden")}}e.pager.options.input&&e._showPagerInputLabels()},_initProcessor:function(e){var n,r=this;n=e.dplProcessing?r.options.dplProcessing:r.options.pdfjsProcessing,r.processingLib=e.dplProcessing?k:w,r._isDPLProcessor()?(r.processor=new i.pdfviewer[r.processingLib].processor(n,r),t=i.pdfviewer[r.processingLib].Page):window.pdfjsLib?window.pdfjsLib?.GlobalWorkerOptions?.workerSrc||window.pdfjsWorker||console?.error('The pdf.worker.mjs script is not loaded. The PDF.JS library will not work correctly.\n    Either load the script:\n    \n    <script src="https://cdnjs.cloudflare.com/ajax/libs/pdf.js/4.3.136/pdf.worker.mjs" type="module"><\/script>\n    \n    Or set it to the GlobalWorkerOptions.workerSrc property:\n    \n    <script type="module">\n        pdfjsLib.GlobalWorkerOptions.workerSrc = \'https://cdnjs.cloudflare.com/ajax/libs/pdf.js/4.3.136/pdf.worker.mjs\';\n    <\/script>'):console?.error('PDF.JS library is required. Make sure that it is properly loaded <script src="https://cdnjs.cloudflare.com/ajax/libs/pdf.js/4.3.136/pdf.mjs" type="module"><\/script>')},_isDPLProcessor:function(){return this.processingLib===k},_hasPagerTool:function(e){let t,n=!1;for(let i=0;i<e.length;i++){const r=e[i];if("string"==typeof r?(n="pager"===r.toLowerCase(),t=i):r.type?(n="pager"===r.type.toLowerCase(),t=i):r.name&&(n="pager"===r.name.toLowerCase(),n&&delete r.name,t=i),n)break}return{hasPager:n,index:t}},_renderToolbar:function(){var t=this,n=t.options,r=o({},n.toolbar),a=r.items&&r.items.length?r.items:Object.keys(t.defaultTools);const{hasPager:s,index:l}=t._hasPagerTool(a);if(a=t._processTools(a),s){let i=t.options.messages.toolbar.pager;i&&i.of&&(i.of=`${i.of} {0}`,i.pages&&(i.of=i.of+" "+i.pages,delete i.pages)),t.defaultTools.pager.componentOptions.messages=i,n.messages.toolbar.pager="Pager";const r=t.defaultTools.pager.componentOptions;"string"!=typeof a[l]&&(t.defaultTools.pager.componentOptions=e.extend(a[l],r),a[l]=t.defaultTools.pager)}r={defaultTools:e.extend({},t.defaultTools,t.exportAsTool),parentMessages:n.messages.toolbar,tools:a,resizable:!0,fillMode:"flat"};var c=e("<div />");return c.appendTo(t.element),t.toolbar=new i.ui.ToolBar(c,r),t.options.toolbar=t.toolbar.options,t.toolbar.bind("toggle",t._toolbarClick.bind(t)),t.toolbar.bind("click",t._toolbarClick.bind(t)),t.toolbar.bind(b,t._toolbarClick.bind(t)),s&&(t.pager=t.toolbar.element.find(".k-pager"),t.pager.length>0&&(t.pager=t.pager.data("kendoPager")),t.pager.bind(b,t._handlePageChangeEvent.bind(t))),t.bind({update:t._updateToolbar.bind(t)}),t.toolbar},_processTools:function(t){var n=this,i=n.options.messages.toolbar;return t=t.flatMap((t=>{if("zoom"===t&&(t=n.defaultTools.zoom),"zoom"===t.name){t=e.extend({},n.defaultTools.zoom,t);var r=[{percent:D,text:i.autoWidth},{percent:A,text:i.actualWidth},{percent:M,text:i.fitToWidth},{percent:E,text:i.fitToPage}],o=t.data.map((e=>({percent:e,text:e+"%"}))),a=n.options.scale?100*n.options.scale+"%":"auto";r=r.concat(o),t.componentOptions.dataSource=r,t.componentOptions.value=a}return t})),t},_updateToolbar:function(e){var t={page:e.page||1,total:e.total||1},n=this.toolbar,i=n.element,r=i.find("[data-command=ZoomCommand][data-role=combobox]").data("kendoComboBox"),o=i.find(".k-focus");0===o.length&&0===(o=i.find("[tabindex=0]").first()).length&&(o=n._getAllItems().first()),r&&(r.enable(!e.isBlank),"zoom"===e.action&&this._updateZoomComboBox(e.zoom)),("pagechange"===e.action&&!1!==e.updatePager||e.isBlank)&&this.pager&&(e.updatePager&&(t.updatePager=!0),e.pageChangeFromScroll&&(t.pageChangeFromScroll=!0),this._updatePager(t)),this._updateOnBlank(e.isBlank),n._resetTabIndex(o)},_updateOnBlank:function(e){var t=this.toolbar,n=t.element;t.enable(n.find("[data-command=EnableSelectionCommand]").parent(),!e),t.enable(n.find("[data-command=ZoomCommand][role=button]").parent(),!e),t.enable(n.find("[data-command='OpenSearchCommand']"),!e),t.enable(n.find("[data-command='DownloadCommand']"),!e),t.enable(n.find("[data-command='PrintCommand']"),!e)},_updatePager:function(e){const t=this;if(e.updatePager){const e="dpl"===t.processingLib?t.document&&t.document.pages?t.document.pages:[]:t.pages??[],n=new i.data.DataSource({data:e??[],pageSize:1});t.pager.setDataSource(n),t._resizePager()}else{t.pager.page()!==e.page&&(e.pageChangeFromScroll&&(t._pageChangeFromScroll=!0),t.pager.page(e.page))}t._showPagerInputLabels(),t._togglePagerDisabledClass()},_togglePagerDisabledClass:function(){const e=this.pager;e.totalPages()<=1?e.element.addClass(y):e.element.hasClass(y)&&e.element.removeClass(y)},_updateZoomComboBox:function(e){var t=e===D||e===A||e===E||e===M,n=this.toolbar.element.find("[data-command=ZoomCommand][data-role=combobox]").data("kendoComboBox");t||(e=Math.round(100*e)+"%"),n&&n.value(e)},_toolbarClick:function(t){let n=e(t.target),i=n.data("command"),r=n.data("options");i||r||(n=e(t.currentTarget),i=n.data("command"),r=n.data("options")),r=o({},{value:n.val()},r),i&&this.execute({command:i,options:r})},_initErrorDialog:function(e){var t=this;if(!t._errorDialog){e=o(e,{messages:t.options.messages});var n=new i.pdfviewer.dialogs.ErrorDialog(e);t._errorDialog=n._dialog}return t._errorDialog},_renderPageContainer:function(){var t=this;t.pageContainer||(t.pageContainerWrapper=e("<div />"),t.pageContainerWrapper.addClass(C),t.pageContainer=e('<div class="k-pdf-viewer-pages" />'),t.pageContainer[0].style.setProperty("--scale-factor",t.zoomScale),t.pageContainer.attr("tabindex",0),t.pageContainerWrapper.append(t.pageContainer),t.wrapper.append(t.pageContainerWrapper))},_setPageContainerScaleFactor(e){this.pageContainer&&this.pageContainer[0].style.setProperty("--scale-factor",e)},_triggerError:function(e){var t=this._initErrorDialog();o(e,{dialog:t}),this.pageContainer&&d(this.pageContainer,!1),this.trigger(p,e)||t.open().content(e.message)},_renderPages:function(){var e,n=this,i=n.document;if(n.pages=[],i&&i.total){e=i.pages;for(var r=1;r<=i.total;r++){var a,s={processor:n.processor,number:r};e&&e.length&&(s=o(s,e[r-1])),a=new t(s,n),n.pages.push(a),n.pageContainer.append(a.element)}n._attachContainerEvents(),n._getVisiblePagesCount(),n._updatePager({updatePager:!0})}else n._renderBlankPage()},_renderBlankPage:function(){this._blankPage=new l(this.options.defaultPageSize,this),this.pageContainer.append(this._blankPage.element),this._blankPage._initUpload(),this.trigger(g,{isBlank:!0})},_resize:function(){var e,t=this;t._allowResize&&(t.pages&&t.pages.length?(t.toolbar&&t.toolbar.resize(!0),t._resizeHandler&&clearTimeout(t._resizeHandler),t._resizeHandler=setTimeout(t._resizePages.bind(t),100)):t._blankPage&&(e=undefined/t._blankPage.element.width(),t._blankPage.resize(e)))},_resizePages:function(){const t=this,n=t.pageContainer[0].clientWidth;let i=0;t.pages.forEach((function(t){const r=t.element?t.element.width():e(t._pageInfo.emptyPage.pageElement).width(),o=n/r;o>i&&(i=o)})),t._autoFit?t.zoom(t._autoFit,!0):(i=Math.min(Math.max(i,t.options.zoomMin),fA),i!=t.zoomScale&&(t.zoom(i,!0),t.zoomScale=i,t._allowResize=!0),t.pager&&t.pager.element&&t._resizePager())},_attachContainerEvents:function(){var e=this;e._wheel=i.throttle(e._wheel.bind(e),300),e.processingLib!==k&&e.pageContainer.on(m,(function(t){t.ctrlKey&&(document.activeElement!==e.pageContainer[0]&&e.pageContainer.trigger("focus"),e._wheel(t),t.preventDefault())})),e.pageContainer.addClass(T),e._isDPLProcessor()?e.pageContainerWrapper.bind(u,e._scroll.bind(e)):e.pageContainerWrapper.bind(u,e._onDemandScroll.bind(e))},_scroll:function(e){var t,n=this,i=n.pageContainerWrapper.height(),r=n.pages.length,o=n._pageNum,a=o-1;if(n._preventScroll||!r)return void(n._preventScroll=!1);n._scrollingStarted=!0;const s=DA(n.element[0]);if(n.pages[a],o!==(t=o+s-a)&&t>=1&&t<=r){if(n.pages[t-1].element.offset().top>i)return;n._pageNum=t,n._loadVisiblePages(),n.trigger(g,{action:v,page:t,total:r,pageChangeFromScroll:!0})}},_onDemandScroll:function(e){const t=this,n=DA(t.element[0])+1;t.loadPage(n),t.loadPage(n+1),t.loadPage(n-1),t.trigger(g,{action:v,page:n,total:t.pages.length,pageChangeFromScroll:!0})},_wheel:function(e){var t=e.originalEvent,n=(t.wheelDelta?-t.wheelDelta:t.detail)<0;this.execute({command:_,options:{zoomIn:n,zoomOut:!n,updateComboBox:!0}}),e.preventDefault()},zoom:function(e,t){return e?this.execute({command:_,options:{value:e,updateComboBox:!t}}):this.zoomScale},execute:function(e){var t=o({viewer:this},e.options);return new i.pdfviewer[e.command](t).exec()},_loadDPLDocument:function(){var e=this,t=e.options.page;d(e.pageContainer,!0),e.processor.fetchDocument().done((function(n){e._clearPages(),e.document=n,e._renderPages(),e.resize(!0),n&&(t=t>=1&&t<=n.total?t:1,e.activatePage(t,!0)),e.pdfScroller&&e.pdfScroller.destroy(),e.pdfScroller=new rA(e.pageContainer[0].parentNode,{filter:".k-page",events:{}}),e.pdfScroller.enablePanEventsTracking(),d(e.pageContainer,!1)}))},_loadPdfJSDocument:function(t){const n=this,i=n.options,r=i.page;let o;o=t||i.pdfjsProcessing.file,o?("string"==typeof o?o={url:o}:o instanceof ArrayBuffer&&(o={arrayBuffer:o}),d(n.pageContainer,!0),_A(e.extend({},{rootElement:n.element[0],dom:n.pageContainer[0],zoom:n.zoomScale,loadOnDemandPageSize:1,done:e=>{n.document=e.pdfDoc,n.pages=e.pdfPages,n.pdfScroller&&n.pdfScroller.destroy(),n.pdfScroller=new rA(n.pageContainer[0].parentNode,{filter:".k-page",events:{}}),n._attachContainerEvents(),n.pdfScroller.enablePanEventsTracking(),n._pageRenderPromise(n.pages[0]),n.activatePage(r,!0),n.trigger(g),d(n.pageContainer,!1)},error:e=>{const t=e.name.includes("Missing"),i=n.options.messages.errorMessages,r=t?i.notFound:i.parseError;n._triggerError({error:e.message,message:r})},loadOnDemand:n.options.pdfjsProcessing.loadOnDemand},o))):n._renderBlankPage()},_setPageNumberAttributes:function(){this.pageContainer.find(".k-page").each(((t,n)=>{e(n).attr(i.attr("number"),t+1)}))},_pageRenderPromise:function(e,t){const n=this;return new Promise((i=>{const r=setInterval((()=>{e._pageInfo.rendered&&!e._pageInfo.renderInProgress&&(clearInterval(r),n._setPageNumberAttributes(),t||n.trigger(h,{page:e}),i())}),100)}))},loadPage:function(e){const t=this,n=t.options.messages.errorMessages,i=t.pages&&t.pages[e-1];if(i)return t._isDPLProcessor()?i.load(t.zoomScale):i._pageInfo.rendered||i._pageInfo.renderInProgress?Promise.resolve():(CA(i,i._pageInfo.emptyPage,(e=>{t._triggerError({error:e.message,message:n.parseError})})),t._pageRenderPromise(i))},activatePage:function(e,t){const n=this;n.pages&&n.pages[e-1]&&(n._pageNum=e,n._isDPLProcessor()?(n._loadVisiblePages(),n._scrollToActivatedPage(e,t)):n.loadPage(e).then((()=>{n._scrollToActivatedPage(e,t)})))},_scrollToActivatedPage:function(e,t){const n=this,i=n.pageContainerWrapper;n._preventScroll=!0,TA(i[0],e-1),n.trigger(g,{action:v,page:e,total:n.pages.length,updatePager:t})},_getVisiblePagesCount:function(){for(var e=this,t=0,n=0,i=e.pageContainer[0].clientHeight,r=0;t<=i&&r<e.pages.length;)t+=e.pages[r].element.height(),n++,r++;e._visiblePagesCount=n},_loadVisiblePages:function(){var e=this.pages&&this.pages.length,t=Math.max(this._pageNum-this._visiblePagesCount,1),n=Math.min(this._pageNum+this._visiblePagesCount,e);this._visiblePages=this.pages.slice(t-1,n);for(var i=t;i<=n;i++)this.loadPage(i)},_loadAllPages:function(){const e=this.pages&&this.pages.length,t=[];for(var n=0;n<=e;n++)t.push(this.loadPage(n));return t},fromFile:function(e){const t=this;t._isDPLProcessor()?(t.zoomScale=t.options.scale||fA,t.zoom(t.zoomScale,!0),t.trigger(g,{action:"zoom",zoom:t.options.scale||"auto"}),t.processor._updateDocument(e),t._loadDPLDocument()):t._loadPdfJSDocument(e)},exportImage:function(e){var t=this,n=e.page,r=t.pages[n-1]||t._blankPage,o=new a.Group;r.load();var s=i.drawing.Path.fromRect(new i.geometry.Rect([0,0],[r.width,r.height]),{fill:{color:"#ffffff"},stroke:null});d(t.pageContainer,!0),o.append(s,r.group),a.exportImage(o).done((function(n){d(t.pageContainer,!1),i.saveAs({dataURI:n,fileName:e.fileName,proxyURL:e.proxyURL||"",forceProxy:e.forceProxy,proxyTarget:e.proxyTarget})}))},exportSVG:function(e){var t=this,n=e.page,r=t.pages[n-1]||t._blankPage;d(t.pageContainer,!0),r.load(),a.exportSVG(r.group).done((function(n){d(t.pageContainer,!1),i.saveAs({dataURI:n,fileName:e.fileName,proxyURL:e.proxyURL||"",forceProxy:e.forceProxy,proxyTarget:e.proxyTarget})}))},setOptions:function(t){var n=this;(t.pdfjsProcessing||t.dplProcessing)&&n._initProcessor(t||{}),t=e.extend(n.options,t),c.fn.setOptions.call(n,t),t.page&&(n._pageNum=t.page,n.activatePage(t.page,!1)),t.width&&n.element.width(t.width),t.height&&n.element.height(t.height)},destroy:function(){this._resizeHandler&&i.unbindResize(this._resizeHandler),this._errorDialog&&this._errorDialog.destroy(),this._saveDialog&&this._saveDialog.destroy(),this._upload&&this._upload.destroy(),this.pager&&this.pager.destroy(),this.toolbar&&(this.toolbar.unbind(),this.toolbar.destroy(),this.toolbar=null),this.pages&&this.pages.length&&this._isDPLProcessor()&&(this.pages.forEach((function(e){e.destroy()})),this.pages=[]),this.pdfScroller&&this.pdfScroller.destroy(),this.pageContainer.off(n),this.pageContainerWrapper.off(n),c.fn.destroy.call(this)},_clearPages:function(){this.pages=[],this.document=null,this._pageNum=1,this.pageContainer.off(n),this.pageContainer.empty(),this.pdfScroller&&this.pdfScroller.destroy()},_toggleSelection:function(e){var t=this;undefined===e&&(e=!0),t.pdfScroller&&(e?t.pdfScroller.disablePanEventsTracking():t.pdfScroller.enablePanEventsTracking()),t.pageContainer.toggleClass(S,e),t.pageContainer.toggleClass(T,!e)}});r.plugin(I)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=n.htmlEncode,o=".kendoRating",a=i.Widget,s=e.extend,l=n.keys,c=n.parseFloat,d="change",u="select",h="selected",p="hovered",f="disabled",m="readonly",g="keydown"+o,v="click"+o,_="mouseenter"+o,b="mouseleave"+o,y="mousemove"+o,w="mousedown"+o,k="focus"+o,x="blur"+o,C="aria-label",S="aria-labelledby",T="aria-valuenow",D="aria-disabled",A="aria-readonly",M="k-rating-precision-part",E="k-rating-precision-complement",I=.5,z="k-rating-item",P="k-focus",H="tabindex",F=".",R="min",L="max",B="single",O="continuous",V="item",N="half",$={item:"itemTemplate",hovered:"hoveredTemplate",selected:"selectedTemplate"},U={selected:"k-selected",hovered:"k-hover",hoveredPrecise:"k-hover-precise"},W="part-value",j="data-value",q="value",G="title",K={widget:"k-rating",container:"k-rating-container",item:"k-rating-item",icon:"star-outline",iconSelected:"star",label:"k-rating-label",disabled:"k-disabled",readonly:"k-state-readonly",active:"k-active",hidden:"k-hidden"},Y=({value:e,maxValue:t})=>`<span>${r(e)} / ${r(t)}</span>`,Q=({styles:e,value:t})=>`<span class="${r(e.item)}" data-value="${r(t)}"></span>`,X=({icon:e})=>n.ui.icon({icon:e,size:"xlarge"}),Z=a.extend({init:function(e,t){var i=this;a.fn.init.call(i,e,t),i.options=s({},i.options,t),i._element(),i._wrapper(),i._aria(),i._initSettings(),i._renderItems(),i._renderTooltip(),i._renderLabel(),i._selectInitial(),i._attachEvents(),n.notify(this)},events:[u,d],options:{name:"Rating",messages:{},min:1,max:5,selection:O,precision:V,tooltip:!0,label:!0,readonly:!1,enabled:!0,selectValueOnFocus:null,itemTemplate:null,selectedTemplate:null,hoveredTemplate:null},_element:function(){this.element.addClass(K.hidden)},_wrapper:function(){var t=this;t.wrapper=e((({styles:e})=>`<span class="${r(e.widget)}"></span>`)({styles:K})),t.wrapper=t.element.wrap(t.wrapper).parent(),t.wrapper.addClass(t.element[0].className.replace(K.hidden,"")).append(e((({styles:e})=>`<span class="${r(e.container)}"></span>`)({styles:K}))),t.wrapper[0].style.cssText=t.element[0].style.cssText,t.container=t.wrapper.find(F+K.container)},_aria:function(){var t=this,i=t.wrapper,r=t.element,o=r.attr("id"),a=e('label[for="'+o+'"]'),s=r.attr(C),l=r.attr(S),d=c(t.element.attr(R))||t.options.min,u=c(t.element.attr(L))||t.options.max;if(t.wrapper.attr(H,0).attr("role","slider").attr("aria-valuemin",d).attr("aria-valuemax",u).attr(T,t.options.value||(d+u)/2),s)i.attr(C,s);else if(l)i.attr(S,l);else if(a.length){var h=a.attr("id");h||(h=(o||n.guid())+"_label",a.attr("id",h)),i.attr(S,h)}},_initSettings:function(){var e=this,t=e.options.precision!=V,n=e.options;n.value=c(n.value),null===n.value&&(n.value=c(e.element.val())),n.min=c(e.element.attr(R))||e.options.min,n.max=c(e.element.attr(L))||e.options.max,e._valueMin=t?e.options.min-I:e.options.min,n.enabled=n.enabled&&!e.element.attr(f),n.readonly=n.readonly||!!e.element.attr(m),e._setState()},_renderItems:function(){for(var t=this,i=t.container,r=t.options.min,o=t.options.max,a=t.options.itemTemplate?n.template(t.options.itemTemplate):X,s=r;s<=o;s+=1){var l=e(Q({styles:K,value:s}));l.append(a({icon:K.icon,index:s})),i.append(l)}},_renderTooltip:function(){var t=this.container.find(F+z);if(!0===this.options.tooltip)for(var n=0;n<t.length;n+=1)e(t[n]).attr(G,e(t[n]).data(q));else t.removeAttr(G)},_renderLabel:function(){var i=this,o=i.wrapper.find(F+K.label),a=!0===i.options.label||i.options.label.template!==t,s=i.options.label&&i.options.label.template?n.template(i.options.label.template):Y;if(!a||null===i.value())return o.remove(),void(i.label=null);o.length||(i.label=o=e((({styles:e})=>`<span class="${r(e.label)}"></span>`)({styles:K})),i.wrapper.append(o)),o.html(s({styles:K,value:i.value()%1==0?i.value():i._format(i.value()),maxValue:i.options.max}))},_selectInitial:function(){var e=this;isNaN(e.options.value)||e.value(e.options.value)},_attachEvents:function(){var e=this,t=e.options.precision==N;e.wrapper.on(k,e._focus.bind(e)).on(x,e._blur.bind(e)).on(g,e._keydown.bind(e)),e.container.on(v,F+z,e._click.bind(e)).on(_,F+z,e._mouseenter.bind(e)).on(b,F+z,e._mouseleave.bind(e)).on(w,e._mousedown.bind(e)),t&&e.container.on(y,F+z,e._mousemove.bind(e))},_focus:function(){var e,t,n,i=this,r=i.container,o=i.wrapper,a=i.container.find(F+P),s=i.options.selectValueOnFocus,l=r.children().first();!i.options.enabled||i.options.readonly||i.preventFocus?i.options.readonly&&i.wrapper.addClass(P):(o.addClass(P),a.removeClass(P),null===i.value()&&null!==s&&i.value(s),e=r.find(F+U.selected).last(),t=r.find(F+U.hovered).last(),(n=(n=e.length?e:t).length?n:l).addClass(P))},_blur:function(){var e=this;e.preventFocus=!1,e.wrapper.removeClass(P),e.container.find(F+P).removeClass(P),e.element.trigger("blur")},_mousedown:function(){this.preventFocus=!0},_keydown:function(t){var i,r,o,a,s=this,c=s.container,d=s.parsedValue,u=s.options.precision!=V?I:1,h=c.find(F+z),p=c.find(F+P),f=h.index(p),m=n.support.isRtl(s.wrapper),g=isNaN(d),v=t.keyCode;s.options.enabled&&!s.options.readonly&&(i=v===l.RIGHT&&m||v===l.LEFT&&!m,r=v===l.LEFT&&m||v===l.RIGHT&&!m,i||v===l.DOWN?(o=g?h.eq(0):e(h[f-1]),a=g?s._valueMin:d-u,s._select(o,a),t.preventDefault()):r||v===l.UP?(o=g?h.eq(0):e(h[f+1]),a=g?s._valueMin:d+u,s._select(o,a),t.preventDefault()):v===l.HOME?(o=h.eq(0),s._select(o,s._valueMin),t.preventDefault()):v===l.END&&(o=h.eq(h.length-1),s._select(o),t.preventDefault()))},_getTemplateType:function(e){return this.options[e]?n.template(this.options[e]):X},_renderTemplate:function(t,n){var i=this._getTemplateType(n),r=K.icon;n!=$.selected&&n!=$.hovered||(r=K.iconSelected);for(var o=0;o<t.length;o+=1)e(t[o]).html(i({icon:r,index:e(t[o]).index()}))},_updateItemTemplates:function(e,t){var n=this,i=B==n.options.selection,r=n.options.precision==N,o=n.container.find(F+U.selected),a=i?t:t.prevAll().addBack(),s=i?o:t.nextAll(),l=$[e],c=U[e];s.removeClass(c),a.addClass(c),n._renderTemplate(a,l),(!i||i&&e==h&&a.get(0)!=o.get(0))&&n._renderTemplate(s,$.item),r&&n._renderTemplate(t,$.item)},_change:function(e,t){var n=this,i=n.value();n.value(t),n.trigger(d,{target:e,oldValue:i,newValue:n.value()})},_click:function(t){var n=this,i=e(t.target).closest(F+z),r=i.attr(j);n.options.enabled&&!n.options.readonly&&(i.data(W)&&(r=i.data(W)),n._select(i,r))},_select:function(e,t){var n=this,i=isNaN(t)?e.attr(j):t;i==n.value()||i<n._valueMin||i>n.options.max||(n.trigger(u,{target:e}),n._change(e,i),n._focus())},_mouseenter:function(t){var n=this,i=e(t.target),r=i.closest(F+z);n.options.enabled&&!n.options.readonly&&(n.enableMove=!0,i.is(F+z)&&n._updateItemTemplates(p,r))},_mouseleave:function(t){var n,i,r=this,o=r.options.selection,a=r.options.precision==N,s=o==B,l=e(t.target).closest(F+z),c=r.container.find(F+z);r.enableMove=!1;var d=function(e){n=r.parsedValue%1!=0&&e.is(r.container.find("[data-value="+Math.ceil(r.parsedValue)+"]")),i=!e.hasClass(U.selected)&&!e.hasClass(U.hovered)||n?$.item:$.selected,r._renderTemplate(e,i),a&&n&&e.hasClass(U.selected)&&r._togglePrecisionElements(e,h)};if(c.removeClass(U.hovered),s)d(l);else for(var u=0;u<c.length;u+=1){d(e(c[u]))}},_mousemove:function(t){var n,i,r,o=this,a=e(t.target).closest(F+z);o.enableMove&&(a.length&&(n=t.clientX,i=a.offset().left,r=Math.abs(n-i),o._togglePrecisionElements(a,p),o._updatePrecisionElements(a,r)),t.preventDefault())},_insetCss:function(){return n.support.isRtl(this.wrapper)?"inset(0 0 0 50%)":"inset(0 50% 0 0)"},_togglePrecisionElements:function(t,n){var i,r,o=this,a=t.find(F+M),s=o._getTemplateType($[n]);a.length?a.html(s({icon:K.iconSelected})):(i=o.parsedValue%1!=0,r=o._getItemWidth(t),(a=e("<span></span>").addClass(M)).append(s({icon:K.iconSelected})),a.css("clip-path",i?o._insetCss():""),t.append(a),t.append(e("<span></span>").css({width:r,height:r,display:"block"})),o._createUpdatePrecisionComplement(t,i))},_updatePrecisionElements:function(e,t){var i=this,r=e.find(F+M),o=n.parseFloat(e.data(q)),a=n.support.isRtl(this.wrapper),s=c(e.outerWidth()/2),l=a?t>s:t<s;e.length&&r.length&&(r.css("clip-path",l?i._insetCss():""),this.options.tooltip&&e.attr(G,l?i._format(o-I):o),e.data(W,l?o-I:o),i._createUpdatePrecisionComplement(e,l))},_createUpdatePrecisionComplement:function(t,n){var i=t.find(F+E),r=t.children().first();i.length||(i=r.wrap(e("<span></span>").addClass(E)).parent())},_calculateItemWidthFromStyles:function(e){if(e)return c(e.find(".k-icon,.k-svg-icon").css("font-size"))},_getItemWidth:function(e){if(e)return e.width()||this._calculateItemWidthFromStyles(e)||0},_updateElement:function(e){var t=this,n=null===e?"":e,i=c(t.element.attr(R))||t.options.min,r=c(t.element.attr(L))||t.options.max;t.element.val(t._format(n)),t.wrapper.attr(T,t._format(e)||(i+r)/2)},_updateItemsRendering:function(e){var t=this,n=t.options.precision==N,i=null===e?"item":h,r=null===e?t.container.find(F+U.selected).last():t.container.find(F+z+"[data-value='"+Math.ceil(e)+"']");null===e&&t.container.find(F+z).removeClass(U.selected),t._updateItemTemplates(i,r),n&&null!==e&&t._togglePrecisionElements(r,h),t._renderLabel()},_setState:function(){var e=this,t=e.element,n=e.wrapper,i=e.options.readonly,r=e.options.enabled;i&&r?(t.attr(m,m),n.attr(A,!0)):(t.prop(m,!1),n.removeAttr(A)),r?(t.prop(f,!1),n.removeAttr(D),n.attr(H,0)):(t.attr(f,f),n.attr(D,!0),n.removeAttr(H)),n.toggleClass(K.disabled,!r),n.toggleClass(K.readonly,i&&r)},_format:function(e){return n.toString(e,"n1",n.getCulture().name)},value:function(e){var t=this,n=t.options.precision==N;return null===e?(t._updateElement(e),void t._updateItemsRendering(e)):null===(e=c(e))?e=c(t.element.val()):(e=Math.max(t._valueMin,Math.min(e,t.options.max)),t.parsedValue=n?c(t._format(Math.ceil(2*e)/2)):Math.round(e),t._updateElement(e),void t._updateItemsRendering(e))},reset:function(){this.value(null)},enable:function(e){var t=this;void 0===e&&(e=!0),t.options.enabled=e,t.options.readonly=!1,t._setState()},readonly:function(e){var t=this;void 0===e&&(e=!0),t.options.readonly=e,t.options.enabled=!0,t._setState()},setOptions:function(n){var i=this;i.options=e.extend(i.options,n),n.enabled!==t&&i.enable(n.enabled),n.readonly!==t&&i.readonly(n.readonly),n.label!==t&&i._renderLabel(),n.tooltip!==t&&i._renderTooltip(),n.value!==t&&i.value(n.value),(n.min||n.max!==t||n.itemTemplate!==t||n.selectedTemplate!==t||n.hoveredTemplate!==t)&&(i.container.empty(),i._renderItems(),i._renderLabel(),i._renderTooltip(),i._selectInitial(),i._precisionStrategyMemo=Z.prototype._precisionStrategyMemo)},destroy:function(){var e=this;e.wrapper.off(o),e.container.off(o),a.fn.destroy.call(e)}});i.plugin(Z)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=e.extend,i=e.Deferred,r=t.Class,o=r.extend({init:function(e){this.options=e,this.filemanager=e.filemanager}}),a=o.extend({init:function(e){o.fn.init.call(this,e)},exec:function(){var e=this,t=e.filemanager,n=t._commandStack,i=t._viewDataSource||t.dataSource,r=e._remove.bind(e);e._item=i._createNewModel(),n.push({item:e._item.toJSON()}).fail(r),i.add(e._item)},_remove:function(){var e=this.filemanager;(e._viewDataSource||e.dataSource).pushDestroy(this._item)}}),s=o.extend({init:function(e){o.fn.init.call(this,e)},exec:function(){var e=this,t=e.options.target,n=e.filemanager,i=n._commandStack,r=n._view.widgetComponent.dataItem(t);t&&r?(i.push({target:t,item:r}),e.filemanager._view.edit(t)):e._renameTreeViewItem(t)},_renameTreeViewItem:function(e){var t=this,n=t.filemanager._commandStack,i=e.data("uid"),r=t.filemanager.treeView.widgetComponent.dataSource.getByUid(i),o=t.filemanager.dataSource.get(r.id);t.filemanager._prompt({type:"rename",defaultInput:o.name,target:e}).done((function(t){n.push({target:e,item:o}),o.set("name",t)}))}}),l=o.extend({init:function(e){o.fn.init.call(this,e)},exec:function(){var e,t=this,n=t.options.target,i=t.filemanager,r=i.getSelected(),o=t.filemanager._view.widgetComponent.dataItem(n);if(n&&n.is(".k-selected")&&r&&r.length)e=r;else if(n&&o)e=o;else if(n){var a=n.data("uid"),s=t.filemanager.treeView.widgetComponent.dataSource.getByUid(a),l=t.filemanager.dataSource.get(s.id);e=l}i._confirm({type:"delete",target:n}).done((function(){t.removeItems(e)}))},removeItems:function(e){this._itemsToRemove=Array.isArray(e)?e:[e],this._removeItem()},_removeItem:function(){var e=this,t=e.filemanager,n=t._commandStack,i=t.dataSource,r=!!e._itemsToRemove.length&&e._itemsToRemove.splice(0,1)[0];r&&(n.push({item:r}).then(e._removeItem.bind(e),e._removeItem.bind(e)),i.remove(r))}}),c=o.extend({init:function(e){o.fn.init.call(this,e)},exec:function(){for(var e=this,t=e.filemanager,n=t.dataSource,i=t._commandStack,r=e.options.items,o=n.get(e.options.target),a=o.children,s=0;s<r.length;s++){var l=n.get(r[s]).toJSON();l.fileManagerNewItem=!0,i.push({item:l,target:o}),a.add(l)}}}),d=o.extend({init:function(e){o.fn.init.call(this,e),this._itemsToRemove=[]},exec:function(){for(var e=this,n=e.filemanager,i=n._commandStack,r=n.dataSource,o=e.options.items,a=r.get(e.options.target),s=a.children,l=[],c=0;c<o.length;c++){var d=r.get(o[c]),u=d.toJSON();u.fileManagerNewItem=!0;var h=i.push({item:d,target:a}).then(e._delete.bind(e));l.push(h),s.add(u)}t.whenAll(l).always(e._removeItem.bind(e))},_delete:function(e){this._itemsToRemove.push(e.item)},_removeItem:function(){var e=this,t=e.filemanager,n=t._commandStack,i=t.dataSource,r=!!e._itemsToRemove.length&&e._itemsToRemove.splice(0,1)[0];r&&(n.push({item:r}).then(e._removeItem.bind(e),e._removeItem.bind(e)),i.remove(r))}}),u=o.extend({init:function(e){o.fn.init.call(this,e)},exec:function(){var e=this.options,t=this.filemanager,i=t.defaultSortOption;n(i,{dir:e.dir,field:e.field}),t._view.widgetComponent.dataSource.sort([t.folderSortOption,i])}}),h=o.extend({init:function(e){o.fn.init.call(this,e)},exec:function(){var e=this.options,t=this.filemanager,n={field:e.field,operator:e.operator,value:e.value||""};t._view.widgetComponent.dataSource.filter(n)}}),p=o.extend({init:function(e){o.fn.init.call(this,e)},exec:function(){var e=this.options,t=this.filemanager;t.view(e.value),t.resize(!0)}}),f=o.extend({init:function(e){o.fn.init.call(this,e)},exec:function(){var e=this,n=e.filemanager[e.options.type];n?n.open():window.console.warn(t.format("The {0} dialog is not available!",e.options.type))}}),m=o.extend({init:function(e){o.fn.init.call(this,e)},exec:function(){var e=this,t=e.filemanager,n=t[e.options.type],i=e.getResizable();n&&(n.toggle(),i&&t.wrapper.find(i.options.handle).toggle())},getResizable:function(){var e=this.filemanager,t=this.options.type;if(e._resizeDraggable)return e._resizeDraggable[t]}}),g=r.extend({init:function(){this._stack={},this._keys=[]},push:function(e){var n=this,r=t.guid();return n._keys.push(r),n._stack[r]={guid:r,data:e,deferred:i()},n._stack[r].deferred},next:function(){var e=this.keys().splice(0,1);return this._stack[e]},resolve:function(e){delete this._stack[e.guid],e.deferred.resolve(e.data)},reject:function(e){delete this._stack[e.guid],e.deferred.reject(e.data)},keys:function(){return this._keys},empty:function(){return 0===this.keys().length}});n(t.ui,{filemanager:{FileManagerCommand:o,CommandStack:g,commands:{CreateFolderCommand:a,RenameCommand:s,DeleteCommand:l,MoveCommand:d,CopyCommand:c,SortCommand:u,SearchCommand:h,ChangeViewCommand:p,OpenDialogCommand:f,TogglePaneCommand:m}}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.ui,i=t.Observable,r=e.extend,o=t.htmlEncode,a=t.keys,s="select",l="change",c="open",d="keydown",u="keydownAction",h=".kendoFileManagerViewComponent",p=[],f=null,m=i.extend({init:function(e,t,n){var r=this;if(r.element=t,r.options=n,!e)throw new Error("The widget for the ViewComponent is not available! Please add the corresponding scripts!");r.widgetComponent=new e(t,n),i.fn.init.call(r)},_bindEvents:function(){this.widgetComponent.bind("dataBinding",this._binding.bind(this)),this.widgetComponent.bind("dataBound",this._bound.bind(this))},_binding:function(e){this.trigger("dataBinding",e)&&e.preventDefault()},_bound:function(){this.trigger("dataBound")},_setDSOptions:function(e,t){!e.dataSource&&t&&(e.dataSource=t)},_initDragAndDrop:function(e,t){var n=this;t=t||n.options.dropFilter,e=e||n.element,n.draggable=e.kendoDraggable({filter:t,hint:n._hint.bind(n),cursorOffset:{top:-10,left:-50},holdToDrag:!0,ignore:"input, .k-focusable",hold:n._hold.bind(n)}).data("kendoDraggable"),n.draggable.userEvents.minHold=150,n.droptarget=e.kendoDropTargetArea({filter:t,drop:n._onDrop.bind(n),dragenter:function(e){e.dropTarget.addClass("k-filemanager-drop-target")},dragleave:function(e){e.dropTarget.removeClass("k-filemanager-drop-target")}}).data("kendoDraggable")},_hold:function(e){var t=this,n=e.currentTarget;n.is(".k-selected")||(t.widgetComponent.selectable&&t.widgetComponent.selectable.clear(),t.widgetComponent.select(n)),t.widgetComponent.selectable&&t.widgetComponent.selectable.userEvents.cancel()},_hint:function(e){var n=this,i=n.widgetComponent.dataItem(e),r=n.widgetComponent.select();return f=n.widgetComponent,p=r,r.length>1?`<div class='k-filemanager-drag-hint'>${t.ui.icon("file")} <span>${r.length} ${n.options.messages.items}</span></div>`:`<div class='k-filemanager-drag-hint'>${t.ui.icon(i.isDirectory?"folder":"file")} <span>${i.name}</span></div>`},_onDrop:function(e){var t=this.widgetComponent.dataItem(e.dropTarget),n=t.id,i=[];if(t.isDirectory){for(var r=0;r<p.length;r++){var o=f.dataItem(p[r]).id;i.push(o)}this.trigger("drop",{target:n,items:i})}},getSelected:function(){throw new Error("Not Implemented!")},refresh:function(e){this.widgetComponent.setDataSource(e)},destroy:function(){t.destroy(this.element)}});r(t.ui.filemanager,{ViewComponent:m,ViewComponents:{},registerViewComponent:function(e,t){n.filemanager.ViewComponents[e]=t},getViewComponent:function(e){return n.filemanager.ViewComponents[e]||null}});var g=m.extend({init:function(e,t,i){var o=this,a=i.dataSource,s=i.messages;t=r({},o.defaultOptions,t,{messages:s,ariaLabel:i.ariaLabel}),o._setDSOptions(t,a),t.kendoKeydown=t.kendoKeydown||o._kendoKeydown.bind(o),m.fn.init.call(this,n.ListView,e,t),o.listView=o.widgetComponent,o._bindEvents(),!1===i.draggable||a.isLocalBinding||o._initDragAndDrop()},defaultOptions:{layout:"flex",flex:{direction:"row",wrap:"wrap"},selectable:t.support.mobileOS?"row":"multiple",template:({name:e,extension:n,isDirectory:i})=>`<div class='k-listview-item' title='${o(e)}${o(n??"")}'><div class='k-file-preview'>${t.ui.icon({icon:i?"folder":t.getFileGroup(n,!0),iconClass:"k-file-icon",size:"xxxlarge"})}</div><div class='k-file-name file-name'>${o(e)}${o(n??"")}</div></div>`,editTemplate:({extension:e,isDirectory:n})=>`<div class='k-listview-item'><div class='k-file-preview'>${t.ui.icon({icon:n?"folder":t.getFileGroup(e,!0),iconClass:"k-file-icon",size:"xxxlarge"})}</div><div class='k-file-name'><span class='k-textbox k-input k-input-md k-rounded-md k-input-solid'><input type='text' class='k-input-inner' data-bind='value:name' name='name' required='required' /><span></div></div>`,dropFilter:".k-listview-item",navigatable:!0},_bindEvents:function(){var e=this,t=e.listView;t.bind(l,e._select.bind(e)),t.element.on("dblclick"+h,e._dblClick.bind(e)),t.element.on("mousedown"+h,".k-listview-item:not(.k-edit-item)",e._mousedown.bind(e)),t.element.on(d+h,".k-edit-item",e._keydown.bind(e)),t.element.on(d+h,e._keydownAction.bind(e)),t.bind("edit",(function(t){var n=t.sender;t.item.find("input").on("blur",(function(){var t=n._modelFromElement(n.editable.element).dirty;n._closeEditable(),t||e.trigger("cancel")}))})),t.bind("cancel",(function(){e.trigger("cancel")})),m.fn._bindEvents.call(this)},_select:function(){var e=this.getSelected();this.trigger(s,{entries:e})},_keydown:function(e){e.keyCode===t.keys.ESC&&(this.listView._closeEditable(),this.trigger("cancel"))},_keydownAction:function(t){var n=e(t.target).find(".k-focus");n.length&&!n.is(".k-edit-item")&&this.trigger(u,{target:n,keyCode:t.keyCode})},_mousedown:function(t){var n=e(t.target).closest(".k-listview-item");3!==t.which||n.is(".k-selected")||(this.listView.selectable.clear(),this.listView.select(n))},_kendoKeydown:function(e){e.keyCode!==a.ENTER||e.preventKendoKeydown||this._handleEnterKey(e)},_handleEnterKey:function(t){var n=this,i=e(t.target),r=n.listView.current();n.widgetComponent.editable&&i.is("input")?i.trigger("blur"):n.widgetComponent.editable||n._triggerOpen(r),t.preventKendoKeydown=!0},_dblClick:function(t){var n=e(t.target).closest(".k-listview-item");this._triggerOpen(n)},_triggerOpen:function(e){if(!e.is(".k-edit-item")){var t=this.listView.dataItem(e);t&&this.trigger(c,{entry:t})}},addFolder:function(){this.listView.add()},edit:function(e){var t=this.listView.select();this.listView.edit(e||t)},getSelected:function(){for(var e=this.listView.select(),t=[],n=0;n<e.length;n++){var i=this.listView.dataItem(e[n]);i&&t.push(i)}return t},destroy:function(){this.listView.element.off(h),m.fn.destroy.call(this)}});n.filemanager.registerViewComponent("list",g);var v=m.extend({init:function(e,t,i){var o=this,a=i.messages;t=r({},o.defaultOptions,t,{messages:a}),m.fn.init.call(this,n.TreeView,e,t),o.treeView=o.widgetComponent,o._bindEvents(),!1===i.draggable||i.isLocalBinding||o._initDragAndDrop()},defaultOptions:{dataTextField:"name",dropFilter:".k-treeview-item"},_refreshDataSource:function(n){var i=this,o=i.treeView,a=n.action,s=n.node,l=null,c=o.element,d=c.attr("aria-activedescendant"),u=n.items.filter((function(e){return e.isDirectory})).map((function(e){return r({},e.toJSON(),{id:e.id||t.guid(),hasChildren:e.hasChildren,items:[]})}));if(s&&(l=o.findByUid(o.dataSource.get(s.id).uid),s&&u.length&&o._progress(l,!1)),u.length){if("itemloaded"==a||l&&"sync"===a)l.find(".k-treeview-item").each((function(e,t){o.remove(t)})),o.append(u,l),i._shouldFocus&&(o.current(l),o.focus());else if("remove"==a)this._remove(u[0].id);else if("itemchange"==a){var h=o.dataSource.get(u[0].id);h?h.set(n.field,u[0][n.field]):o.append(u[0],l)}else o.dataSource.data().length?("sync"===a||undefined===a&&!l)&&(o.items().each((function(e,t){o.remove(t)})),o.append(u),i._shouldFocus&&(o.current(o._nextVisible(e())),o.focus())):o.append(u);d&&0===c.find("#"+d).length&&c.removeAttr("aria-activedescendant")}},_remove:function(e){var t,n=this.treeView,i=n.dataSource.get(e);i&&(t=n.findByUid(i.uid),n.remove(t))},_bindEvents:function(){var e=this;e.treeView.bind(s,e._navigate.bind(e)),e.treeView.bind("expand",e._expand.bind(e)),e.treeView.element.on(d,e._keydownAction.bind(e))},_keydownAction:function(t){var n=e(t.target).find(".k-focus").closest(".k-treeview-item");this.trigger(u,{target:n,keyCode:t.keyCode})},_expand:function(e){var t=this.treeView.dataItem(e.node);e.preventDefault(),this.trigger("load",{entryId:t.id})},_navigate:function(e){var t=e.node,n=this.treeView.dataItem(t),i=n.id;e.preventDefault(),this.trigger("navigate",{path:i,entry:n.toJSON()})},_hold:e.noop,getSelected:function(){var e=this.treeView.element.find(".k-selected").closest(".k-treeview-item");return this.treeView.dataItem(e)},refresh:function(e){var t=this.treeView,n=t.dataSource.get(e),i=n&&t.findByUid(n.uid);n&&i&&(t.element.find(".k-selected").removeClass("k-selected"),i.find("> div .k-treeview-leaf").removeClass("k-hover").addClass("k-selected"))},reload:function(){this.treeView.dataSource.read()}});if(n.filemanager.registerViewComponent("tree",v),t.ui.Grid){var _=m.extend({init:function(e,t,i){var o=this,a=i.dataSource,s=i.messages;t=r({},o.defaultOptions,t,{messages:s}),o._setDSOptions(t,a),o._setupColumns(t,s),t.kendoKeydown=t.kendoKeydown||o._kendoKeydown.bind(o),m.fn.init.call(this,n.Grid,e,t),o.grid=o.widgetComponent,o._bindEvents(),!1===i.draggable||a.isLocalBinding||o._initDragAndDrop(),i.ariaLabel&&o.element.find("[role=grid]").attr("aria-label",i.ariaLabel)},defaultOptions:{selectable:t.support.mobileOS?"row":"multiple",editable:{mode:"inline",confirmation:!1},sortable:!0,dropFilter:"tr:not(.k-grid-edit-row)",navigatable:!0},_setupColumns:function(e,n){e.columns||(e.columns=[{field:"name",title:n.nameField||"Name",template:function(e){let n=e.isDirectory?"folder":t.getFileGroup(e.extension,!0),i=t.htmlEncode(e.name+(e.extension??""));return"<div class='file-group-icon'>"+t.ui.icon(n)+"</div><div class='file-name'>"+i+"<div>"}},{field:"created",title:n.dateCreatedField,format:"{0:G}"},{field:"size",title:n.sizeField,template:function(e){return e.size>0?t.getFileSizeMessage(e.size):""}}])},_bindEvents:function(){var t=this,n=t.grid;n.bind(l,t._select.bind(t)),n.table.on("dblclick"+h,t._dblClick.bind(t)),n.table.on("mousedown"+h,"tr:not(.k-grid-edit-row)",t._mousedown.bind(t)),n.table.on(d+h,".k-grid-edit-row",t._keydown.bind(t)),n.table.on(d+h,t._keydownAction.bind(t)),n.bind("edit",(function(){t._toggleFocusable(!0)})),n.bind("cancel",(function(){t.trigger("cancel")})),n.saveRow=e.noop,m.fn._bindEvents.call(this)},_kendoKeydown:function(e){var t=this.grid.current(),n=t?t.closest("tr[data-uid]"):null;n&&e.keyCode===a.ENTER&&!e.preventKendoKeydown&&(this._triggerOpen(n),e.preventKendoKeydown=!0),e.keyCode===a.F2&&(e.preventKendoKeydown=!0)},_keydownAction:function(t){var n=e(t.target).find(".k-focus").closest("tr");n.length&&!n.is(".k-grid-edit-row")&&this.trigger(u,{target:n,keyCode:t.keyCode})},_keydown:function(n){var i=this,r=i.grid;e(n.target).closest(".k-grid-edit-row").length&&(n.keyCode===t.keys.ENTER&&(setTimeout((function(){(i.grid._editContainer||e()).find("input").trigger("blur"),i._closeEditable()})),i._tryCancel()),n.keyCode===t.keys.ESC&&(r.cancelChanges(),i.trigger("cancel")))},_mousedown:function(t){var n=this,i=e(t.target).closest("tr[data-uid]");1===t.which&&n.grid.editable&&(setTimeout((function(){n._closeEditable()})),n._tryCancel()),3!==t.which||i.is(".k-selected")||(n.grid.selectable.clear(),n.grid.select(i))},_tryCancel:function(){var e=this,t=e.grid;t.editable&&(t._editContainer.find("input").val()||t.cancelChanges()),setTimeout((function(){e._toggleFocusable(!1)}))},_toggleFocusable:function(e){this.grid.table.find("tr,td").children().addBack().toggleClass("k-focusable",e)},_closeEditable:function(){var e,t=this;t.grid.editable&&!t.grid.editable.options.model.dirty&&(e=t.grid._editContainer,t.grid._destroyEditable(),t.grid._displayRow(e),t.trigger("cancel"))},_select:function(){var e=this.getSelected();this.trigger(s,{entries:e})},_dblClick:function(t){var n=e(t.target).closest("tr[data-uid]");this._triggerOpen(n)},_triggerOpen:function(e){if(!e.is(".k-grid-edit-row")){var t=this.grid.dataItem(e);t&&this.trigger(c,{entry:t})}},getSelected:function(){for(var e=this.grid.select(),t=[],n=0;n<e.length;n++)t.push(this.grid.dataItem(e[n]));return t},addFolder:function(){this.grid.addRow()},edit:function(e){var t=this.grid.select();this.grid.editRow(e||t)},destroy:function(){this.grid.table.off(h),this.grid.element.off(h),m.fn.destroy.call(this)}});n.filemanager.registerViewComponent("grid",_)}}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.data,r=i.Node,o=i.HierarchicalDataSource,a=i.DataSource;n(!0,t.data,{schemas:{filemanager:{data:function(e){return e.items||e||[]},model:{id:"path",hasChildren:"hasDirectories",fields:{name:{editable:!0,type:"string",defaultValue:"New Folder"},size:{editable:!1,type:"number"},path:{editable:!1,type:"string"},extension:{editable:!1,type:"string"},isDirectory:{editable:!1,defaultValue:!0,type:"boolean"},hasDirectories:{editable:!1,defaultValue:!1,type:"boolean"},created:{type:"date",editable:!1},createdUtc:{type:"date",editable:!1},modified:{type:"date",editable:!1},modifiedUtc:{type:"date",editable:!1}}}}}});var s=r.define({init:function(e){var n=this,i=this.isDirectory;if(r.fn.init.call(this,e),"string"==typeof i&&(i=t.getter(i)),t.isFunction(i)){var o=i.call(n,n);o&&0===o.length?n.isDirectory=!1:n.isDirectory=!!o}n.isDirectory&&n._initChildren()},_initChildren:function(){var e,n,i,r=this;r.children instanceof t.data.FileManagerDataSource||(n=(e=r.children=new t.data.FileManagerDataSource(r._childrenOptions)).transport,i=n.parameterMap,n.parameterMap=function(e,t){return"read"!==t&&"create"!==t||(e.target=r.id),i&&(e=i.call(r,e,t)),e},e.parent=function(){return r},e.bind("change",(function(e){e.node=e.node||r,r.trigger("change",e)})),e.bind("error",(function(e){var t=r.parent();t&&(e.node=e.node||r,t.trigger("error",e))})),r._updateChildrenField())},isNew:function(){return this.fileManagerNewItem?(delete this.fileManagerNewItem,!0):this.id===this._defaultId}}),l=o.extend({init:function(n){var i=s.define({children:n});n.filter&&!n.serverFiltering&&(this._hierarchicalFilter=n.filter,n.filter=null),a.fn.init.call(this,e.extend(!0,{},{schema:{modelBase:i,model:i}},n)),this.isLocalBinding=this.transport instanceof t.data.LocalTransport,this._attachBubbleHandlers()},insert:function(e,t){var n=this.parent();return n&&n._initChildren&&(t&&t.isDirectory&&(n.hasDirectories=!0),n.hasChildren=!0,n._initChildren()),a.fn.insert.call(this,e,t)},remove:function(e){var t,n=e.parentNode(),i=this;return n&&n._initChildren&&(i=n.children),this._cleanDestroyed(e),t=a.fn.remove.call(i,e),n&&i.data()&&!i.data().length?n.hasChildren=!1:n&&!this._hasDirectories(n)&&(n.hasDirectories=!1),t},_cleanDestroyed:function(e){var t=this;e.parentNode&&e.parentNode()?((t=(e=e.parentNode()).children)._destroyed=[],this._cleanDestroyed(e)):t._destroyed=[]},_hasDirectories:function(e){return!!e.children.data()&&!!e.children.data().filter((function(e){return e.isDirectory})).length}});l.create=function(e){var t=(e=e&&e.push?{data:e}:e)||{},n=t.data;return n&&n._dataSource?n._dataSource:(t.data=n,t instanceof l?t:new l(t))},t.observableFileManagerData=function(e){var n=l.create({data:e,schema:t.data.schemas.filemanager});return n.fetch(),n._data._dataSource=n,n._data},n(t.data,{FileManagerDataSource:l,FileEntry:s})}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.template,r=t.ui.ContextMenu,o="action",a=r.extend({init:function(e,t){var n=this;r.fn.init.call(n,e,t),n._overrideTemplates(),n._initDefaultItems(),n._extendItems(),n.bind("select",n._onSelect.bind(n)),n.bind("open",n._onOpen.bind(n))},_overrideTemplates:function(){this.templates.sprite=i((({spriteCssClass:e,icon:n})=>e?`<span class="${e}"></span>`:n?t.ui.icon(n):""))},_initDefaultItems:function(){var e=this,t=e.options.messages;e.options.isLocalBinding?e.defaultItems={}:e.defaultItems={rename:{text:t.rename,icon:"pencil",command:"RenameCommand"},delete:{text:t.delete,icon:"trash",command:"DeleteCommand"}}},events:r.fn.events.concat([o]),_extendItems:function(){var t,n=this,i=n.options.items;if(i&&i.length)for(var r=0;r<i.length;r++)t=i[r],e.isPlainObject(t)&&1===Object.keys(t).length&&t.name&&(t=t.name),e.isPlainObject(t)?(n._extendItem(t),n.append(t)):n.defaultItems[t]&&(t=n.defaultItems[t],n._extendItem(t),n.append(t));else for(var o in n.defaultItems)t=n.defaultItems[o],n._extendItem(t),n.append(t)},_extendItem:function(e){var t=this.options.messages;n(e,{text:t[e.text],spriteCssClass:e.spriteCssClass||"",attr:{"data-command":e.command}})},_onSelect:function(t){var n=e(t.item).data("command"),i=e(t.target);n&&this.action({command:n,options:{target:i}})},_onOpen:function(t){!t.sender.options.items&&e.isEmptyObject(this.defaultItems)&&t.preventDefault()},action:function(e){this.trigger(o,e)}});n(t.ui.filemanager,{ContextMenu:a})}(window.kendo.jQuery);!function(e){var t=kendo.ui,n=e.extend,i=kendo.htmlEncode,r=e.isPlainObject,o=Array.isArray,a=t.DataBoundWidget,s=kendo.template,l=kendo._outerHeight,c="navigate",d="select",u="open",h="error",p="change",f="close",m="dataBinding",g="dataBound",v="drop",_="execute",b="command",y="keydownAction",w="tree",k=".",x={wrapper:"k-widget k-filemanager",header:"k-filemanager-header",navigation:"k-filemanager-navigation",contentContainer:"k-filemanager-content-container",content:"k-filemanager-content",preview:"k-filemanager-preview",toolbar:"k-filemanager-toolbar",treeview:"k-filemanager-treeview",breadcrumb:"k-filemanager-breadcrumb",view:"k-filemanager-view",grid:"k-filemanager-grid",list:"k-filemanager-listview",upload:"k-filemanager-upload",uploadDialog:"k-filemanager-upload-dialog",splitBar:"k-splitbar",splitBarHorizontal:"k-splitbar-horizontal k-splitbar-draggable-horizontal",splitBarHover:"k-splitbar-horizontal-hover",splitBarIcon:"k-icon k-resize-handle",splitBarNavigation:"k-filemanager-splitbar-navigation",splitBarPreview:"k-filemanager-splitbar-preview",resizable:"k-filemanager-resizable"},C={filePreview:"k-file-preview",fileInfo:"k-file-info",fileName:"k-file-name",fileMeta:"k-file-meta",metaLabel:"k-file-meta-label",metaValue:"k-file-meta-value",extension:"k-file-type",size:"k-file-size",created:"k-file-created",modified:"k-file-modified"},S=a.extend({init:function(e,n){var i=this;a.fn.init.call(i,e,n),i.options=kendo.deepExtend({},i.options,n),i.defaultSortOption={field:"name",dir:"asc"},i.folderSortOption={field:"isDirectory",dir:"desc"},i._commandStack=new t.filemanager.CommandStack,i._dataSource(),i._wrapper(),i._renderHeader(),i._renderContentContainer(),i._initContextMenu(),i._renderNavigation(),i._renderContent(),i._renderPreview(),i._initUploadDialog(),i._resizable(),i._attachKeyDown(),i.resize(),kendo.notify(i,kendo.ui)},options:{name:"FileManager",height:500,resizable:!0,initialView:"list",toolbar:{resizable:!0},contextMenu:{},upload:{},uploadUrl:"",views:{},breadcrumb:{},draggable:!0,dialogs:{upload:{width:530},moveConfirm:{width:350,closable:!0},deleteConfirm:{width:360,closable:!0},renamePrompt:{width:350,closable:!0}},previewPane:{metaFields:["extension","size","created","modified"],noFileTemplate:({styles:e,messages:t})=>`<div class="${i(e.fileInfo)}"><div class="${i(e.filePreview)}"><span class="k-file-icon k-icon k-svg-icon k-i-none" aria-hidden="true"></span></div><span class="${i(e.fileName)}" k-no-file-selected>${i(t.noFileSelected)}</span></div>`,singleFileTemplate:({styles:e,selection:t,metaFields:n,messages:r})=>{let o="";if(o+=`<div class="${i(e.fileInfo)}"><div class="${i(e.filePreview)}">`+kendo.ui.icon({icon:t[0].isDirectory?"folder":i(kendo.getFileGroup(t[0].extension,!0)),iconClass:"k-file-icon",size:"xxxlarge"})+"</div>"+`<span class="${i(e.fileName)}">${i(t[0].name)}</span>`,n){o+=`<dl class="${i(e.fileMeta)}">`;for(var a=0;a<n.length;a+=1){var s=n[a];o+=`<dt class="${i(e.metaLabel)}">${i(r[s])}: </dt><dd class="${i(e.metaValue)} ${i(e[s])}">`,"size"==s?o+=` ${i(kendo.getFileSizeMessage(t[0][s]))}`:t[0][s]instanceof Date?o+=` ${i(kendo.toString(t[0][s],"G"))}`:o+="extension"==s?` ${i(t[0].isDirectory?"folder":kendo.getFileGroup(t[0].extension))}`:` ${i(t[0][s])}`,o+='</dd><dd class="k-line-break"></dd>'}o+="</dl>"}return o+="</div>",o},multipleFilesTemplate:({styles:e,selection:t,messages:n})=>`<div class="${i(e.fileInfo)}"><div class="${i(e.filePreview)}">`+kendo.ui.icon({icon:"file",iconClass:"k-file-icon",size:"xxxlarge"})+"</div>"+`<span class="${i(e.fileName)}">`+`${i(t.length)} `+`${i(n.items)}</span></div>`},messages:{toolbar:{createFolder:"New Folder",upload:"Upload",sortDirection:"Sort Direction",sortDirectionAsc:"Sort Direction Ascending",sortDirectionDesc:"Sort Direction Descending",sortField:"Sort By",nameField:"Name",sizeField:"File Size",typeField:"Type",dateModifiedField:"Date Modified",dateCreatedField:"Date Created",listView:"List View",gridView:"Grid View",search:"Search",details:"View Details",detailsChecked:"On",detailsUnchecked:"Off",delete:"Delete",rename:"Rename"},views:{nameField:"Name",sizeField:"File Size",typeField:"Type",dateModifiedField:"Date Modified",dateCreatedField:"Date Created",items:"items",listLabel:"FileManager ListView",gridLabel:"FileManager Grid",treeLabel:"FileManager TreeView"},dialogs:{upload:{title:"Upload Files",clear:"Clear List",done:"Done"},moveConfirm:{title:"Confirm",content:"<p class='k-text-center'>Do you want to move or copy?</p>",okText:"Copy",cancel:"Move",close:"close"},deleteConfirm:{title:"Confirm",content:"<p class='k-text-center'>Are you sure you want to delete the selected file(s)?</br>You cannot undo this action.</p>",okText:"Delete",cancel:"Cancel",close:"close"},renamePrompt:{title:"Prompt",content:"<p class='k-text-center'>Enter new name for the file.</p>",okText:"Rename",cancel:"Cancel",close:"close"}},previewPane:{noFileSelected:"No File Selected",extension:"Type",size:"Size",created:"Date Created",createdUtc:"Date Created UTC",modified:"Date Modified",modifiedUtc:"Date Modified UTC",items:"items"}}},events:[c,d,u,m,g,h,v,_,b],defaultTools:{createFolder:{type:"button",name:"createFolder",command:"CreateFolderCommand",rules:{remote:!0}},upload:{type:"button",name:"upload",command:"OpenDialogCommand",options:'{ "type": "uploadDialog" }',rules:{remote:!0}},sortDirection:{type:"buttonGroup",buttons:[{name:"sortDirectionAsc",showText:"overflow",icon:"sort-asc-small",togglable:!0,group:"sortDirection",command:"SortCommand",options:'{ "dir": "asc" }',selected:!0},{name:"sortDirectionDesc",showText:"overflow",icon:"sort-desc-small",togglable:!0,group:"sortDirection",command:"SortCommand",options:'{ "dir": "desc" }'}]},sortField:{type:"splitButton",name:"sortField",command:"SortCommand",menuButtons:[{name:"nameField",options:'{"field": "name"}',command:"SortCommand"},{name:"typeField",options:'{"field": "extension"}',command:"SortCommand"},{name:"sizeField",options:'{"field": "size"}',command:"SortCommand"},{name:"dateCreatedField",options:'{"field": "created"}',command:"SortCommand"},{name:"dateModifiedField",options:'{"field": "modified"}',command:"SortCommand"}]},changeView:{type:"buttonGroup",buttons:[{name:"gridView",showText:"overflow",icon:"grid-layout",togglable:!0,group:"changeView",command:"ChangeViewCommand",options:"grid"},{name:"listView",showText:"overflow",icon:"grid",togglable:!0,group:"changeView",command:"ChangeViewCommand",options:"list"}]},spacer:{type:"spacer"},details:{type:"component",name:"details",items:[{template:function(e){return"<label for='details-toggle'>"+i(e.componentOptions.messages.text)+"</label>"},overflow:"never",componentOptions:{messages:{text:"details"}}},{name:"details",command:"TogglePaneCommand",options:'{ "type": "preview" }',overflow:"never",element:"<input id='details-toggle' class='k-filemanager-details-toggle' />",component:"Switch",componentOptions:{messages:{checked:"detailsChecked",unchecked:"detailsUnchecked"},commandOn:"change"}}]},search:{type:"component",name:"search",command:"SearchCommand",options:'{ "field": "name", "operator": "startswith" }',overflow:"never",component:"TextBox",componentOptions:{placeholder:"search",icon:"search",commandOn:"input"}}},_attachKeyDown:function(){var e=this;e.wrapper.on("keydown.kendoFileManager",(t=>{t.keyCode===kendo.keys.F10&&(t.preventDefault(),e.toolbar.element.find("[tabindex=0]").first().trigger("focus"))}))},_dataSource:function(){var e,t=this,i=t.options.dataSource||{},a=t.folderSortOption,s=t.defaultSortOption;i instanceof kendo.data.FileManagerDataSource?e=i:(e=o(i)?{data:i,autoSync:!1,sort:[a,s]}:n(!0,i,{autoSync:!1,sort:[a,s]}),i&&r(i.schema)?e.schema=i.schema:r(kendo.data.schemas.filemanager)&&(e.schema=kendo.data.schemas.filemanager)),t.dataSource&&t._errorHandler?(t.dataSource.unbind(h,t._errorHandler),t.dataSource.unbind(p,t._changeHandler)):(t._errorHandler=t._error.bind(t),t._changeHandler=t._change.bind(t)),t.dataSource=kendo.data.FileManagerDataSource.create(e).bind(h,t._errorHandler).bind(p,t._changeHandler)},_error:function(e){this.trigger(h,e)||window.console.warn("Error! The requested URL returned "+e.xhr.status+" - "+e.xhr.statusText)},_wrapper:function(){var e=this,t=e.options,n=t.width,i=t.height;e.wrapper=e.element.addClass(x.wrapper),n&&e.wrapper.width(n),i&&e.wrapper.height(i),e._resizeHandler=kendo.onResize((function(){e.resize(!0)}))},_renderHeader:function(){var t=this,n=t.options;n.toolbar&&(t.header=e("<div />").addClass(x.header)),t.wrapper.append(t.header),n.toolbar&&(t._initToolbar(),t.toolbar._tabIndex())},_renderContentContainer:function(){var t=this,n=e("<div />").addClass(x.contentContainer);t.contentContainer=n,t.wrapper.append(t.contentContainer)},_initContextMenu:function(){var e=this,i=e.options,r=n({},i.contextMenu,{filemanager:e,messages:i.messages.toolbar,target:e.contentContainer,filter:"[data-uid]",action:e.executeCommand.bind(e),isLocalBinding:e.dataSource.isLocalBinding});!1!==i.contextMenu&&(e.contextMenu=new t.filemanager.ContextMenu("<ul></ul>",r),e.contextMenu.bind(u,e._cacheFocus.bind(e)))},_renderNavigation:function(){var t=this;t.navigation=e("<div />").addClass(x.navigation),t.navigation.append(t._initTreeView().element),t.contentContainer.append(t.navigation)},_renderContent:function(){var t=this,n=t.options,i=t.toolbar;t.content=e("<div />").addClass(x.content),n.breadcrumb&&t.content.append(t._initBreadcrumb().element),t.content.append(t._initView()),i&&t._isToolEnabled(t.defaultTools.upload.name)||t.content.append(t._initUpload().wrapper.hide()),t.contentContainer.append(t.content)},_renderPreview:function(){var t=this;t.options.previewPane&&(t.preview=e("<div tabindex='0' />").addClass(x.preview),t.previewContainer=e("<div />").addClass(x.previewContainer),t.preview.append(t.previewContainer),t._setPreviewPaneContent(),t.contentContainer.append(t.preview.hide()))},_setPreviewPaneContent:function(){var e,t=this,n=t.options,i=n.messages.previewPane,r=n.previewPane,o=t.getSelected();if(!o)return e=s(r.noFileTemplate)({styles:C,messages:i}),void t.previewContainer.html(e);e=1===o.length?r.singleFileTemplate:r.multipleFilesTemplate,e=s(e)({styles:C,messages:i,selection:o,metaFields:r.metaFields}),t.previewContainer.html(e)},_initToolbar:function(){var t=this,i=t.options,r=e("<div />").addClass(x.toolbar),o=n({},i.toolbar),a=o.items?o.items:Object.keys(t.defaultTools);return a=t._processTools(a),o.tools=a,o.defaultTools=t.defaultTools,o.parentMessages=t.options.messages.toolbar,t.header.append(r),t.toolbar=new kendo.ui.ToolBar(r,o),t.options.toolbar=t.toolbar.options,t.toolbar.bind("toggle",t._toolbarClick.bind(t)),t.toolbar.bind(f,t._toolbarClick.bind(t)),t.toolbar.bind("click",t._toolbarClick.bind(t)),t.toolbar.bind(p,t._toolbarClick.bind(t)),t.toolbar},_processTools:function(e){var t=this;return e.forEach((e=>{var n=e.rules||(t.defaultTools[e]?t.defaultTools[e].rules:null);n&&n.remote&&t.dataSource.isLocalBinding&&(e.rules?e.hidden=!0:t.defaultTools[e].hidden=!0),"changeView"===e.name?t.defaultTools[e.name].buttons.forEach(((n,i)=>{n.options===t.options.initialView&&(t.defaultTools[e.name].buttons[i].selected=!0)})):e.buttons&&"changeView"===e.buttons[0].group&&e.buttons.forEach(((n,i)=>{n.options===t.options.initialView&&(e.buttons[i].selected=!0)}))})),e},_toolbarClick:function(t){var i=e(t.target).data("command"),r=e(t.target).data("options");e(t.target).val()&&(r=n({},r,{value:e(t.target).val()})),i&&this.executeCommand({command:i,options:r})},_isToolEnabled:function(e){for(var t=this.options.toolbar.items||this.defaultTools,n=!1,i=0;i<t.length;i++)if(t[i].name==e){n=!0;break}return t[e]||n},_initTreeView:function(){var i=this,r=e("<div />").addClass(x.treeview),o=i.options.views[w],a=n(!0,{},{dataSource:i.options.dataSource,messages:i.options.messages.views,draggable:i.options.draggable,isLocalBinding:i.dataSource.isLocalBinding});return i.treeView=new t.filemanager.ViewComponents[w](r,o,a),i.treeView.bind(c,i._navigate.bind(i)).bind("load",i._load.bind(i)).bind(v,i._drop.bind(i)).bind(y,i._keydownAction.bind(i)),i.treeView},_drop:function(e){var t=this;!t.trigger(v,e)&&e.items.indexOf(e.target)<0&&t._confirm({type:"move",target:e.target}).done((function(){t.executeCommand({command:"CopyCommand",options:e})})).fail((function(){t.executeCommand({command:"MoveCommand",options:e})}))},_keydownAction:function(e){var t=e.keyCode,n=kendo.keys;t===n.DELETE&&this.executeCommand({command:"DeleteCommand",options:{target:e.target}}),t===n.F2&&this.executeCommand({command:"RenameCommand",options:{target:e.target}})},_confirm:function(t){var i=this,r=i.options.messages.dialogs[t.type+"Confirm"],o=e("<div></div>").kendoConfirm(n({},{title:r.title,content:r.content,messages:r},i.options.dialogs[t.type+"Confirm"])).data("kendoConfirm");return o.bind(u,i._cacheFocus.bind(i)),o.bind("hide",i._restoreFocus.bind(i,t.target)),o.open(),o.wrapper.removeClass("k-confirm"),o.result},_prompt:function(t){var i=this,r=this.options.messages.dialogs[t.type+"Prompt"],o=e("<div></div>").kendoPrompt(n({},{title:r.title,content:r.content,messages:r,value:t.defaultInput},this.options.dialogs[t.type+"Prompt"])).data("kendoPrompt");return o.bind(u,i._cacheFocus.bind(i)),o.bind(f,i._restoreFocus.bind(i,t.target)),o.open(),o.wrapper.removeClass("k-prompt"),o.result},_cacheFocus:function(){var t=this,n=e(document.activeElement),i=t.view(),r=t.treeView.widgetComponent;if(!t.contextMenu||!t.contextMenu.popup.visible()){if(t.treeView._shouldFocus=!1,r.current()&&r.current().find(".k-focus").length||n.hasClass(x.treeview))return t.treeView._shouldFocus=!0,void(i._focusElement=n);i._focusElement=n.hasClass(x[t._viewType])?n:null}},_restoreFocus:function(e){var t=this.view();e&&(t._focusElement?t._focusElement.trigger("focus"):e.closest&&e.closest(":kendoFocusable").length&&e.closest(":kendoFocusable").trigger("focus"))},_initView:function(){var t=this,n=e("<div />").addClass(x.view),i=t.options.initialView;return t.viewWrapper=n,t.viewWrapper.append(t.view(i)),n},_initBreadcrumb:function(){var i=this,r=i.options,o=e("<nav />").addClass(x.breadcrumb),a=n({},{items:[{type:"rootitem",text:""}],change:i._breadcrumbChange.bind(i)},r.breadcrumb);return i.breadcrumb=new t.Breadcrumb(o,a),i.breadcrumb},_breadcrumbChange:function(e){var t=e.sender.items().filter((function(t){return t.path===e.value.substring(1)})).shift();this._navigate({path:t?t.id:""})},_initUploadDialog:function(){var i,r=this,o=r.options,a=o.messages.dialogs.upload,s=e("<div />"),l=n({},{title:a.title,modal:!0,visible:!1,width:500,actions:[{text:()=>a.done,primary:!0},{text:()=>a.clear,action:r._clearUploadFilesList.bind(r)}],messages:a},o.dialogs.upload);if(r._shouldInitUpload())return i=r._initUpload(),r.uploadDialog=new t.Dialog(s,l),r.uploadDialog.wrapper.addClass(x.uploadDialog),r.uploadDialog.element.append(i.wrapper),r.uploadDialog.bind(u,r._toggleUploadDropZone.bind(r,"")),r.uploadDialog.bind(f,r._toggleUploadDropZone.bind(r,r.viewWrapper)),r.uploadDialog},_shouldInitUpload:function(){var e=this.options,t=!1;return(e.uploadUrl||e.upload.async&&e.upload.async.saveUrl)&&!1!==e.upload&&(t=!0),t},_initUpload:function(){var i=this,r=i.options,o=e("<input type='file' name='file'/>").addClass(x.upload),a=n(!0,{async:{autoUpload:!0,saveUrl:r.uploadUrl},dropZone:i.viewWrapper},r.upload);return i.upload=new t.Upload(o[0],a),i.upload.bind("upload",i._sendUploadPathParameter.bind(i)),i.upload.bind("success",i._success.bind(i)),i.upload},_sendUploadPathParameter:function(e){e.data=n(e.data,{path:this.path()})},_success:function(){this._view.widgetComponent.dataSource.read()},_clearUploadFilesList:function(){var e=this.upload;e&&e.clearAllFiles()},_toggleUploadDropZone:function(e){var t=this.upload;t&&t.setOptions({dropZone:e})},_binding:function(e){this.trigger(m,{source:"view",action:e.action,items:e.items,index:e.index})&&e.preventDefault()},_bound:function(){this.options.previewPane&&this._setPreviewPaneContent(),this.trigger(g)},_createResizableSplitBar:function(t){var n=e("<div />").addClass(x.splitBar).addClass(x.splitBarHorizontal).addClass(t),i=e("<span />").addClass(x.splitBarIcon);return n.append(i),n.hover((function(){e(this).toggleClass(x.splitBarHover)})),n},_initResizableNavigation:function(){var e,t,n=this,i=n.wrapper,r=n._createResizableSplitBar(x.splitBarNavigation),o=i.find(k+x.content),a=i.find(k+x.navigation);r.insertAfter(a),n._resizeDraggable.navigation=n.wrapper.find(r).end().kendoResizable({handle:k+x.splitBarNavigation,start:function(){e=o.width(),t=a.width()},resize:function(n){var r=n.x.initialDelta;kendo.support.isRtl(i)&&(r*=-1),t+r<-2||e-r<-2||a.width(t+r)}}).getKendoResizable()},_initResizablePreview:function(){var e,t,n=this,i=n.wrapper,r=n._createResizableSplitBar(x.splitBarPreview),o=i.find(k+x.content),a=i.find(k+x.preview);n.options.previewPane&&(r.insertBefore(a).hide(),n._resizeDraggable.preview=i.find(r).end().kendoResizable({handle:k+x.splitBarPreview,start:function(){e=o.width(),t=a.width()},resize:function(n){var r=n.x.initialDelta;kendo.support.isRtl(i)&&(r*=-1),t-r<-2||e+r<-2||a.width(t-r)}}).getKendoResizable())},_resizable:function(){var e=this,t=e.options;e._resizeDraggable={},t.resizable&&(e.wrapper.addClass(x.resizable),e._initResizableNavigation(),e._initResizablePreview())},view:function(i){var r=this,o=e("<div></div>"),a=r.options.views[i],s=n(!0,{},{dataSource:r._viewDataSource||r.dataSource,messages:r.options.messages.views,draggable:r.options.draggable,ariaLabel:r.options.messages.views[i+"Label"]});if(undefined===i)return r._view;if(!t.filemanager.ViewComponents[i])throw new Error(kendo.format("There is no {0} ViewComponent registered!",i));if(r._view&&r._view.destroy&&(r._view.destroy(),r.viewWrapper.empty()),r._viewType=i,r._view=new t.filemanager.ViewComponents[i](o,a,s),r._view.bind(d,r._select.bind(r)),r._view.bind(u,r._open.bind(r)),r._view.bind(m,r._binding.bind(r)),r._view.bind(g,r._bound.bind(r)),r._view.bind(v,r._drop.bind(r)),r._view.bind(y,r._keydownAction.bind(r)),r._view.bind("cancel",r._cancel.bind(r)),r._view.element.addClass(x[i]),r.viewWrapper.removeClass(Object.keys(t.filemanager.ViewComponents).map((function(e){return x.view+"-"+e})).join(" ")).addClass(x.view+"-"+i),r.toolbar){let e=r.toolbar.wrapper.find(`[data-options="${i}"]`);e&&r.toolbar.toggle(e,!0)}r.viewWrapper.append(r._view.element)},executeCommand:function(e){var i=e.command,o=n({filemanager:this},r(e.options)?e.options:{value:e.options}),a=new t.filemanager.commands[i](o);if(!this.trigger(_,e))return a.exec()},_navigate:function(e){var t=e.path;this.trigger(c,{path:t})||this.navigate(t)},_load:function(e){this.dataSource.get(e.entryId).load()},_select:function(e){this.options.previewPane&&this._setPreviewPaneContent(),this.trigger(d,{entries:e.entries})},_open:function(e){var t=e.entry;this.trigger(u,{entry:t}),t.isDirectory&&this._navigate({path:t.id})},_cancel:function(){var e=this._commandStack,t=e.next();e.reject(t),this.trigger(b,{status:"cancel",action:"itemchange",data:t.data})},_change:function(e){var t=this,n=t._commandStack,i=e.node?e.node.children:t.dataSource;if(!t.trigger(m,{source:"tree",action:e.action,items:e.items,index:e.index})){if(t.treeView._refreshDataSource(e),"remove"===e.action||"itemchange"===e.action||"add"===e.action)if(n.empty())i.sync();else{var r=n.next();i.sync().then((function(i){n.resolve(r),t.trigger(b,{status:"success",action:e.action,data:r.data,response:i})})).fail((function(i){n.reject(r),t.trigger(b,{status:"fail",action:e.action,data:r.data,response:i})}))}"remove"===e.action&&t._viewDataSource&&t._viewDataSource.parent()&&e.items[0]===t._viewDataSource.parent()&&t._navigateToParent(e.items[0]),"itemchange"==e.action&&t._viewDataSource&&t._viewDataSource.parent()&&t.path().indexOf(e.items[0].id)>=0&&t._navigateToParent(e.items[0]),"itemchange"===e.action&&e.items[0].loaded(!1)}},_navigateToParent:function(e){var t=e.parentNode(),n=t?t.id:"";this._navigate({path:n})},_buildBreadcrumbPath:function(e){for(var t=this.breadcrumb,n=[];e;)n.push({id:e.id,text:e.name,path:e.path}),e=e.parentNode&&e.parentNode();n.push({type:"rootItem",id:"",text:""}),t.items(n.reverse())},_adjustDimensions:function(){var e=this,t=e.wrapper,n=k+x.grid,i=k+x.list,r=k+x.contentContainer,o=t.height(),a=0,s=0;e.toolbar&&(a=l(e.toolbar.wrapper)),e.breadcrumb&&(s=l(e.breadcrumb.wrapper)),"auto"!==e.options.height&&(t.find([n].join(",")).height(o-(a+s+1)),t.find(i).parent().height(o-(a+s+1)),t.find(r).height(o-a))},_resize:function(){this._adjustDimensions(),kendo.resize(this.element.children())},setDataSource:function(e){var t=this;t.options.dataSource=e,t._dataSource(),t.toolbar&&(t.toolbar.destroy(),t.header.empty(),t._initToolbar(),t.toolbar._tabIndex()),t.treeView&&(t.treeView.destroy(),t.navigation.empty(),t.navigation.append(t._initTreeView().element)),t._view&&t.view(t._viewType||t.options.initialView),t._initContextMenu()},refresh:function(){(this._viewDataSource||this.dataSource).read()},getSize:function(){return kendo.dimensions(this.wrapper)},getSelected:function(){var e=this,t=e._view.getSelected(),n=e.treeView;if(t&&t.length)return t;var i=n.getSelected();return i?[e.dataSource.get(i.id)]:void 0},path:function(){return this._path||""},navigate:function(t){var n=this,i=n.dataSource,r=i.get(t.replace(/^\//,"")),o=n._view,a=n.treeView,s=n.breadcrumb,l=""===t||"/"===t;if(r||l){if(n._path=t,!n.trigger(m,{source:"navigation",action:"rebind",items:[r]})){if(s&&n._buildBreadcrumbPath(r),l)return i.sort([n.folderSortOption,n.defaultSortOption]),n._viewDataSource=i,o.refresh(n._viewDataSource),a.treeView.select(e()),void(n.options.previewPane&&n._setPreviewPaneContent());r.loaded&&!r.loaded()&&r.load(),o&&(n._viewDataSource=r.children,n._viewDataSource._sort=[n.folderSortOption,n.defaultSortOption],o.refresh(n._viewDataSource)),a&&a.refresh(r.id),n.options.previewPane&&n._setPreviewPaneContent()}}else window.console.warn("Error! Could not navigate to the folder at the requested path("+t+"). Make sure that the parent folder of the target folder has already been loaded.")},items:function(){return this.treeView.widgetComponent.items().add(this._view.widgetComponent.items())},destroy:function(){var e=this;a.fn.destroy.call(e),e.dataSource.unbind(h,e._errorHandler).unbind(p,e._changeHandler),e._resizeDraggable.navigation&&(e._resizeDraggable.navigation.destroy(),e._resizeDraggable.navigation=null),e._resizeDraggable.preview&&(e._resizeDraggable.preview.destroy(),e._resizeDraggable.preview=null),e.uploadDialog&&(e.uploadDialog.destroy(),e.uploadDialog=null),e.upload&&(e.upload.destroy(),e.upload=null),e.contextMenu&&(e.contextMenu.destroy(),e.contextMenu=null),kendo.unbindResize(e._resizeHandler),e.dataSource=null,e._viewDataSource=null,kendo.destroy(e.element)}});t.plugin(S)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.keys,o=e.extend,a=n.htmlEncode,s=".kendoStepper",l="click",c="activate",d="select",u=".",h=" ",p="vertical",f="tabindex",m="aria-current",g="aria-disabled",v="aria-invalid",_="k-step",b="k-step-first",y="k-step-last",w="k-step-done",k="k-step-success",x="k-step-error",C="k-step-current",S="k-focus",T="k-disabled",D="k-step-link",A="k-step-indicator",M="k-stepper",E="k-stepper-linear",I="k-step-list",z="k-step-list-horizontal",P="k-step-list-vertical",H=n.Class.extend({init:function(e){this.options=o({},this.options,e),this._render()},options:{label:"",icon:"",successIcon:"",iconTemplate:null,enabled:!0,error:!1,selected:!1,isFirstStep:!1,isLastStep:!1,indicatorVisible:!0,labelVisible:!0,index:0,previous:!1,selectable:!0},_indicatorTemplate:({successIcon:e,index:t,icon:i,previous:r,error:o})=>{let s;return s=e&&r&&!o?n.ui.icon({icon:a(e),iconClass:"k-step-indicator-icon"}):i?n.ui.icon({icon:a(i),iconClass:"k-step-indicator-icon"}):r&&!o?n.ui.icon({icon:"check",iconClass:"k-step-indicator-icon"}):`<span class="k-step-indicator-text">${a(t+1)}</span>`,'<span class="k-step-indicator" aria-hidden="true">'+s+"</span>"},_labelTemplate:({label:t,indicatorVisible:i,previous:r,error:o})=>'<span class="k-step-label"><span class="k-step-text">'+a(t)+"</span> "+(o||!i&&!o&&r?n.ui.icon(e('<span aria-hidden="true"></span>'),{icon:o?"warning-circle":"check-circle"}):"")+"</span>",deselect:function(){this.options.selected=!1,this._link(),this._stepClasses()},enable:function(e){this.options.enabled!==e&&(this.options.enabled=e,this.options.selectable=e,this._link(),this._stepClasses())},select:function(){this.options.selected=!0,this._link(),this._stepClasses()},getEnabled:function(){return this.options.enabled},getIndex:function(){return this.options.index},setPrevious:function(e){this.options.previous=e,this._link(),this._stepClasses()},getSelectable:function(){return this.options.selectable},getSelected:function(){return this.options.selected},setValid:function(e){this.options.error===e&&(this.options.error=!e,this._link(),this._stepClasses())},_indicator:function(){var t,i=this.options;i.iconTemplate?(t=e("<span>").addClass(A).attr("aria-hidden","true")).append(n.template(i.iconTemplate)(i)):t=n.template(this._indicatorTemplate)(i),this.element.find(u+D).append(t)},_label:function(){var e=n.template(this._labelTemplate)(this.options);this.element.find(u+D).append(e)},_link:function(){var e=this.options;this.element.find(u+D).empty(),this._linkAttributes(),e.indicatorVisible&&this._indicator(),e.labelVisible&&this._label()},_linkAttributes:function(){var e=this.options,t=this.element.find(u+D);t.removeAttr(g+h+v+h+m+h+f),e.selected?t.attr(m,"step"):t.attr(f,"-1"),e.enabled&&e.selectable||t.attr(g,"true"),e.error&&t.attr(v,"true")},_render:function(){var t=e("<a href='#'>").addClass(D).attr("title",this.options.label);this.element=e("<li>").append(t),this._link(),this._stepClasses()},_stepClasses:function(){var e=this.options,t=_;e.isFirstStep&&(t+=h+b),e.isLastStep&&(t+=h+y),e.enabled||(t+=h+T),e.error&&(t+=h+x),e.previous?(t+=h+w,e.error||(t+=h+k)):e.selected&&(t+=h+C,t+=h+S),this.element.removeClass().addClass(t)}}),F=i.extend({init:function(e,t){var r=this;t=t||{},i.fn.init.call(r,e,t),r._indicatorAndLabel(),r._wrapper(),t.steps&&t.steps.length&&(r._processSteps(t.steps),r._progressBar()),r._attachEvents(),r._resizeHandler=n.onResize((function(){r.resize()}))},options:{orientation:"horizontal",linear:!0,indicator:!0,label:!0,selectOnFocus:!1,steps:null,name:"Stepper"},events:[c,d,"kendoKeydown"],destroy:function(){var e=this;e.progressBar&&i.fn.destroy.call(e.progressBar),i.fn.destroy.call(e),n.unbindResize(e._resizeHandler),e.wrapper.off(s)},setOptions:function(e){var t=this;i.fn.setOptions.call(t,e),t.progressBar&&i.fn.destroy.call(t.progressBar),t._indicatorAndLabel(),t._addStepList(),t.options.steps&&t.options.steps.length&&(t._processSteps(t.options.steps),t._progressBar())},enable:function(e){var t=this.steps(),n=this.options.steps;e?this.wrapper.removeAttr(g):this.wrapper.attr(g,"true"),this.progressBar.enable(e),t.forEach((function(t,i){t.enable(e),n[i]=t.options}))},insertAt:function(e,t){var n,i=this.options.steps;t&&!isNaN(e)&&(e<0&&(e=i.length+e),e<0||(i||(i=[]),(0===i.length||e>=i.length)&&(e=i.length),i.forEach((function(e){e.selected&&(n=e)})),!0===t.selected&&(n.selected=!1),i.splice(e,0,t),this._createSteps(),this._renderSteps(),this._resetProgressBar(),this._calculateDimensions()))},next:function(){if(this._steps&&!(this._steps.length<=1)){var e=this.selectedStep.getIndex();e+1!==this._steps.length&&this._select(e+1)}},previous:function(){if(this._steps&&!(this._steps.length<=1)){var e=this.selectedStep.getIndex();0!==e&&this._select(e-1)}},removeAt:function(e){var t,n,i=this.options.steps;isNaN(e)||!i||i.length<2||e>=i.length||(e<0&&(e=i.length+e),e<0||(!0===i.splice(e,1)[0].selected&&i.length>0&&("string"==typeof(t=i[n=e>0?e-1:0])&&(t={label:t},i[n]=t),t.selected=!0,t.previous=!1),this._createSteps(),this._renderSteps(),this._resetProgressBar(),this._calculateDimensions()))},resize:function(){this._calculateDimensions()},select:function(e){var n=this;if(e===t||null===e||isNaN(e))return n.selectedStep;e>=n._steps.length||e<0||(e=Number(e),n._select(e))},steps:function(e){if(e===t)return this._steps;this._processSteps(e),this._resetProgressBar(),this._calculateDimensions()},_processSteps:function(e){var t,n=this;e.forEach((function(e){e.selected&&(t=e)})),t||("string"==typeof e[0]&&(e[0]={label:e[0]}),e[0].selected=!0),n.options.steps=e,n._createSteps(),n._renderSteps()},_addStepList:function(){var t=this;t.wrapper.empty().append(e("<ol />").addClass(I)),t._stepList=t.wrapper.find(u+I),t.options.orientation===p?t._stepList.addClass(P):t._stepList.addClass(z)},_attachEvents:function(){var e=this;e.wrapper.on(l+s,u+_,e._selectClickHandler.bind(e)).on(l+s,e._wrapperClickHandler.bind(e)).on("focusout"+s,e._focusout.bind(e)).on("keydown"+s,e,e._keydown.bind(e))},_calculateDimensions:function(){var e=this.options.orientation,t=this._steps.length,i=this._stepList,r=i.find(u+_),o=i.width()/t,a=i.height()/t,s=this.progressBar.element,l="margin-left",c={};e===p?(r.css("max-height",100/t+"%"),s.css({"margin-top":-1*(i.height()-16),height:a*(t-1)})):(r.css("max-width",100/t+"%"),n.support.isRtl(this.wrapper)&&(l="margin-right"),c[l]=o/2,c.width=o*(t-1),s.css(c))},_createStep:function(e,t,n){var i=0===t,r=this.options,a=r.indicator,s=r.label;return e=o({},e,{enabled:!1!==e.enabled}),e=o({},e,{isFirstStep:i,isLastStep:n,indicatorVisible:a,labelVisible:s,index:t}),new H(e)},_createSteps:function(){var e,n,i,r,o=this,a=o.options.steps,s=!1;for(o._steps=[],n=0;n<a.length;n++)"string"==typeof(r=a[n])&&(r={label:r}),r!==t&&(i=n===a.length-1,r.selected?s=!0:r=o._selectablePreviousState(r,s,n),e=o._createStep(r,n,i),o._steps.push(e),e.getSelected()&&(o.selectedStep=e))},_indicatorAndLabel:function(){this.options.indicator||this.options.label||(this.options.indicator=!0,this.options.label=!0)},_focusout:function(e){var t=this;t.wrapper.get(0).contains(e.relatedTarget)||setTimeout((function(){t._leaveStepper()}))},_focusStep:function(e){var t=this.wrapper.find(u+S),n=this.wrapper.find(u+D);e.length>0&&(t.removeClass(S),n.attr(f,"-1"),e.find(u+D).removeAttr(f)[0].focus())},_focusNextStep:function(){var t=e(document.activeElement).closest(u+_).next();this._focusStep(t)},_focusPreviousStep:function(){var t=e(document.activeElement).closest(u+_).prev();this._focusStep(t)},_focusFirstStep:function(){var e=this.wrapper.find(u+b);this._focusStep(e)},_focusLastStep:function(){var e=this.wrapper.find(u+y);this._focusStep(e)},_keydown:function(t){var n=this,i=t.keyCode,o=e(document.activeElement).closest(u+_).index(),a=n.steps().length;i===r.TAB?t.shiftKey&&o>0?(t.preventDefault(),n._tabKey(t,-1)):!t.shiftKey&&o<a-1&&(t.preventDefault(),n._tabKey(t,1)):i>34&&i<41?(t.preventDefault(),n._navKeys(t)):i===r.ENTER||i===r.SPACEBAR?(t.preventDefault(),n._selectHandler(t,e(document.activeElement).closest(u+_))):t.preventDefault()},_leaveStepper:function(){var e=this.wrapper.find(u+C);this.wrapper.find(u+D).removeClass(S).attr(f,"-1"),e.addClass(S),e.find(u+D).removeAttr(f)},_navKeys:function(e){this.options.selectOnFocus?this._navKeysSelect(e):this._navKeysFocus(e)},_navKeysFocus:function(e){var t=e.keyCode,i=n.support.isRtl(this.wrapper),o=this.options.orientation;switch(t){case r.DOWN:i&&o!==p?this._focusPreviousStep():this._focusNextStep();break;case r.RIGHT:i?this._focusPreviousStep():this._focusNextStep();break;case r.UP:i&&o!==p?this._focusNextStep():this._focusPreviousStep();break;case r.LEFT:i?this._focusNextStep():this._focusPreviousStep();break;case r.HOME:this._focusFirstStep();break;case r.END:this._focusLastStep()}},_navKeysSelect:function(t){var i,o=t.keyCode,a=e(document.activeElement).closest(u+_).index(),s=n.support.isRtl(this.wrapper),l=this.steps(),c=this.options.orientation;switch(o){case r.DOWN:i=s&&c!==p?l[a-1]:l[a+1];break;case r.RIGHT:i=s?l[a-1]:l[a+1];break;case r.UP:i=s&&c!==p?l[a+1]:l[a-1];break;case r.LEFT:i=s?l[a+1]:l[a-1];break;case r.HOME:i=l[0];break;case r.END:i=l[l.length-1]}i&&(this._focusStep(i.element),this._selectHandlerOnKey(t,i.element))},_progressBar:function(){var t=this.wrapper,n=this._progressOptions();this.progressBar=e("<div>").kendoProgressBar(n).getKendoProgressBar(),this.progressBar.element.css("position","absolute"),this._calculateDimensions(),t.append(this.progressBar.element)},_progressOptions:function(){var e,t=this.options,n=t.orientation,i=t.steps;if(i&&0!==i.length)return e={max:i.length-1,value:this.select().getIndex(),orientation:n,showStatus:!1},n===p&&(e.reverse=!0),e},_resetProgressBar:function(){var e,t=this.progressBar;t&&(e=this._progressOptions(),t.setOptions(e))},_renderSteps:function(){var e,t,n=this._steps,i=this._stepList;for(i.empty(),t=0;t<n.length;t++)e=n[t],i.append(e.element)},_resetStep:function(e,t,n){var i=this._steps[e];e===t?(i.options.previous=!1,i.options.selected=!0):(n||e>t)&&(!n||e<t)&&(i.options.selected=!1,i.options.previous=n),this.options.linear&&(e<t-1||e>t+1)?i.options.selectable=!1:i.options.selectable=!0,i._link(),i._stepClasses(),this.options.steps[e]=i.options},_select:function(e){var t,n,i,r,o=this.options,a=o.linear,s=this.select().getIndex(),l=o.steps,c=this._steps[e];if(c&&c.getEnabled()){for(e>s?(t=!0,a?(i=Math.max(s-1,0),r=Math.min(e+1,l.length-1)):(i=s,r=e)):(t=!1,a?(i=Math.max(e-1,0),r=Math.min(s+1,l.length-1)):(i=e,r=s)),n=i;n<=r;n++)this._resetStep(n,e,t);this.selectedStep=c,this.progressBar.value(e)}},_selectablePreviousState:function(e,t,n){var i=this.options.steps,r=this.options.linear;return t?r&&!i[n-1].selected?e.selectable=!1:e.selectable=!0:(e.previous=!0,r&&!i[n+1].selected?e.selectable=!1:e.selectable=!0),e},_selectClickHandler:function(t){var n=e(t.target).closest(u+_);t.preventDefault(),this._preventWrapperClick=!0,this._selectHandler(t,n)},_selectHandler:function(e,t){var n=this,i=n._steps[t.index()],r=this.select();i&&i.getIndex()!==r.getIndex()&&i.getEnabled()&&i.getSelectable()?n.trigger(d,{sender:n,originalEvent:e,step:i})||(n._select(i.getIndex()),t.find(u+D)[0].focus(),n.trigger(c,{sender:n,originalEvent:e,step:i})):n._focusStep(r.element)},_selectHandlerOnKey:function(e,t){var n=this,i=n._steps[t.index()];i.getEnabled()&&i.getSelectable()&&(n.trigger(d,{sender:n,originalEvent:e,step:i})||(n._select(i.getIndex()),t.find(u+D)[0].focus(),n.trigger(c,{sender:n,originalEvent:e,step:i})))},_tabKey:function(t,n){var i=this.options.selectOnFocus,r=e(document.activeElement).closest(u+_),o=r.index(),a=e(r.parent().find(u+_)[o+n]);this._focusStep(a),i&&this._selectHandlerOnKey(t,a)},_wrapper:function(){var e=this,t=e.element;e.wrapper=t,e.wrapper.addClass(M),e.options.linear&&e.wrapper.addClass(E),this._addStepList()},_wrapperClickHandler:function(e){var t=this.select();this._preventWrapperClick?this._preventWrapperClick=!1:(e.preventDefault(),this._focusStep(t.element))}});n.stepper={Step:H},n.ui.plugin(F)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=n.Widget,r=n.Draggable,o=t.keys,a=t.selectorFromClasses,s="resize",l="reorder",c=".kendoTileLayout",d="k-cursor-move",u=i.extend({init:function(t,n){var r=this;i.fn.init.call(r,t,n),r.element=e(t).addClass(u.styles.wrapper).attr({role:"list"}),r._setWrapperStyles(),r._initContainers(),r._resizable(),r._navigatable(),r._reorderable(),r._showWatermarkOverlay&&r._showWatermarkOverlay(r.element[0])},events:[s,l],options:{name:"TileLayout",columns:null,gap:{columns:16,rows:16},containers:[],resizable:!1,reorderable:!1,navigatable:!1,columnsWidth:"1fr",rowsHeight:"1fr",height:"",width:""},destroy:function(){i.fn.destroy.call(this),this._draggableInstance&&(this.element.find(".k-tilelayout-item").each((function(){var t=e(this);t.data("kendoDropTarget")&&t.data("kendoDropTarget").destroy()})),this._draggableInstance.destroy(),this._draggableInstance=null),this.resizable&&(this.resizable.destroy(),this.resizable=null),this.resizeHandle&&(this.resizeHandle.off(c).remove(),this.resizeHandle=null),this.element.off(c)},setOptions:function(e){this.destroy(),t.deepExtend(this.options,e),this.element.empty(),this.init(this.element,this.options)},getOptions:function(){var n=e.extend(!0,{},this.options);return n.containers=t.deepExtend([],this.items),n},_initContainers:function(){var n,i,r,o,a,s,l,c=this,h=c.options.containers,p=c.element.children(),f=!!p.length;if(c.items=[],c.itemsMap={},f)p.each((function(i,r){n=t.guid();var o=e(r).addClass(u.styles.item).attr({id:n,role:"listitem","aria-keyshortcuts":"Enter"});c._addContainer(o,h[i],i,n)}));else for(var m=0;m<h.length;m++){if(n=t.guid(),s=h[m],i=e("<div></div>").addClass(u.styles.item).attr({id:n,role:"listitem","aria-keyshortcuts":"Enter"}),(o=s.header)&&(o.template||o.text)&&(r=e("<div></div>").addClass(u.styles.itemHeader),c.options.reorderable&&r.addClass(d),l=o.text?"<div class='"+u.styles.itemHeaderTitle+"'>"+o.text+"</div>":null,r.append(l||t.template(o.template)({})),r.appendTo(i)),a=e("<div></div>").addClass(u.styles.itemBody),!s.bodyTemplate)throw new Error("Having a bodyTemplate for the container is mandatory");a.append(t.template(s.bodyTemplate)({})),a.appendTo(i),i.appendTo(c.element),c._addContainer(i,s,m,n)}},_addContainer:function(e,n,i,r){var o=this;n.order="number"==typeof n.order?n.order:i,e.attr(t.attr("index"),n.order),n.id=r,o._setContainerCoordinates(e,n),o.itemsMap[r]=n,o.items.push(o.itemsMap[r])},_setWrapperStyles:function(){var e=this.options;this.element.css({"grid-template-columns":t.format("repeat({0}, minmax(0, {1}))",e.columns,"string"==typeof e.columnsWidth?e.columnsWidth:e.columnsWidth+"px"),"grid-auto-rows":t.format("minmax(0, {0})","string"==typeof e.rowsHeight?e.rowsHeight:e.rowsHeight+"px"),"column-gap":e.gap.columns+"px",width:"string"==typeof e.width?e.width:e.width+"px",height:"string"==typeof e.height?e.height:e.height+"px",padding:e.gap.rows+"px "+e.gap.columns+"px ","row-gap":e.gap.rows+"px"})},_setContainerCoordinates:function(e,n){n&&e.css({order:n.order,"grid-column-end":t.format("span {0}",n.colSpan),"grid-row-end":t.format("span {0}",n.rowSpan)}).attr(t.attr("index"),n.order)},_updateContainers:function(){for(var e=this,t=0;t<e.items.length;t++)e._setContainerCoordinates(e.element.find("#"+e.items[t].id),e.items[t])},_createResizeHandle:function(t,n,i){var r=this;r._isresizing||(r.resizeHandle&&r.resizeHandle.data("div")[0]!==t[0]&&(r.resizeHandle.off(c).remove(),r.resizeHandle=null),r.resizeHandle||(r.resizeHandle=e('<div class="k-resize-handle"></div>'),r.resizeHandle.appendTo(t)),r._positionResizeHandle(t,n,i))},_positionResizeHandle:function(e,n,i){var r,o=parseFloat(e.css("borderRightWidth")),a=parseFloat(e.css("borderBottomWidth")),s=e.height(),l=e.width(),c=i?s-6.5-a:0,d=n?l-4.5-o:0,u=9,h=9;n&&i?(h=u=25,c-=12.5,d-=12.5,r=t.support.isRtl(this.element)?"k-cursor-nesw-resize":"k-cursor-nwse-resize"):n&&!i?(h=s,r="k-cursor-ew-resize"):!n&&i&&(u=l,r="k-cursor-ns-resize"),this.resizeHandle.css({top:c,left:d,height:h,width:u}).attr("side",n).attr("down",i).removeClass("k-cursor-nesw-resize k-cursor-nwse-resize k-cursor-ew-resize k-cursor-ns-resize").addClass(r).data("div",e).show()},_createResizeHint:function(t){if(!this.hint){var n=t.css("grid-column-end"),i=t.css("grid-row-end"),r=t.css("order");this.hint=e("<div class='"+u.styles.resizeHint+"'></div>").css({order:r,"grid-column-end":n,"grid-row-end":i}).insertAfter(t)}},_removeResizeHint:function(){this._isresizing||this.hint&&(this.hint.remove(),this.hint=null)},_positionHint:function(e,n){e&&this.hint.css("grid-column-end",t.format("span {0}",e)),n&&this.hint.css("grid-row-end",t.format("span {0}",n))},_removeAbsoluteStyles:function(e){e.css("position",""),e.css("left",""),e.css("top",""),e.css("width",""),e.css("height",""),e.css("z-index","")},_positionAbsolutely:function(e){if("absolute"!=e.css("position")){var t=e.position(),n=e.outerWidth(),i=e.outerHeight();e.css("position","absolute"),e.css("left",t.left),e.css("top",t.top),e.css("width",n),e.css("height",i),e.css("z-index",2)}},_navigatable:function(){if(this.options.navigatable){var e=this;e.element.children().attr("tabindex",0),e.element.on("keydown"+c,e,e._keyDown.bind(e))}},_keyDown:function(t){var n=e(t.target),i=!1;n.is(".k-tilelayout-item.k-card")&&(t.ctrlKey&&t.keyCode==o.LEFT&&(i=!0,this._resizeItem(n,"horizontal",-1)),t.ctrlKey&&t.keyCode==o.RIGHT&&(i=!0,this._resizeItem(n,"horizontal",1)),t.ctrlKey&&t.keyCode==o.UP&&(i=!0,this._resizeItem(n,"vertical",-1)),t.ctrlKey&&t.keyCode==o.DOWN&&(i=!0,this._resizeItem(n,"vertical",1)),t.shiftKey&&t.keyCode==o.LEFT&&(i=!0,this._reorderItem(n,-1)),t.shiftKey&&t.keyCode==o.RIGHT&&(i=!0,this._reorderItem(n,1)),i&&t.preventDefault())},_resizeItem:function(e,n,i){var r,o=this,a=e.attr("id");o.options.resizable&&("horizontal"===n?(r=parseInt(e.css("grid-column-end").replace("span",""),10)+i,o.element.css("grid-template-columns").split(" ").length>=r&&r>0&&(o.itemsMap[a].colSpan=r,e.css({"grid-column-end":t.format("span {0}",r)}),o.trigger(s,{container:e}))):(r=parseInt(e.css("grid-row-end").replace("span",""),10)+i,o.element.css("grid-template-rows").split(" ").length>=r&&r>0&&(o.itemsMap[a].rowSpan=r,e.css({"grid-row-end":t.format("span {0}",r)}),o.trigger(s,{container:e}))))},_reorderItem:function(e,n){if(this.options.reorderable){var i=parseInt(e.css("order"),10),r=this.element.children().length;if((n=i+n)>=0&&n<r){var o=this.element.find("> ["+t.attr("index")+"='"+n+"']");this.itemsMap[e.attr("id")].order=n,this.itemsMap[o.attr("id")].order=i,this._updateContainers(),this._updateDOM(),e.trigger("focus"),this.trigger(l,{newIndex:n,oldIndex:i,container:e})}}},_sortContainers:function(n){var i=t.attr("index");return[].sort.call(n,(function(t,n){t=e(t),n=e(n);var r=t.attr(i),o=n.attr(i);return void 0===r&&(r=e(t).index()),void 0===o&&(o=e(n).index()),(r=parseInt(r,10))>(o=parseInt(o,10))?1:r<o?-1:0}))},_updateDOM:function(){var t=this,n=t.element.children(":visible");(n=t._sortContainers(n)).each((function(){e(this).appendTo(t.element)}))},_resizable:function(){var t,i,r,o,l,d,h,p=this,f=0,m=0,g=0,v=0,_=0,b=0,y=0;p.options.resizable&&(p.element.on("mousemove"+c,a(u.styles.item),(function(t){var n,i,r=e(this),o=r[0].getBoundingClientRect();n=Math.abs(o.right-t.clientX)<16,i=Math.abs(o.bottom-t.clientY)<16,n&&i?p._createResizeHandle(r,!0,!0):n?p._createResizeHandle(r,!0,!1):i&&p._createResizeHandle(r,!1,!0)})),p.resizable=new n.Resizable(p.element,{handle:"div.k-tilelayout-item > .k-resize-handle",start:function(n){var a=e(n.currentTarget);d=a.data("div"),r=d.attr("id"),t=a.attr("side"),i=a.attr("down"),h=p.element.css("grid-template-rows").split(" ").length,t&&(o=p._calculateFractionWidth(),y=p._calculateRightEndSide(o),f=n.x.location,g=d.width(),_=parseInt(d.css("grid-column-end").replace("span",""),10)),i&&(l=(p.element[0].scrollHeight-(h+1)*p.options.gap.rows)/h,m=n.y.location,v=d.height(),b=parseInt(d.css("grid-row-end").replace("span",""),10)),p._isresizing=!0},resize:function(e){var n,a,s=0,c=0,u=0,h=0,w=0,k=0,x=0,C=p.element[0].getBoundingClientRect(),S=!!p.element[0].style.height;p._positionAbsolutely(d),p._createResizeHint(d),"true"==t&&(u=e.x.location-f,n=C.left+y-window.scrollX-e.x.location<p.options.gap.columns,a=g+u<o,n||a?u=0:(x=u/(o+p.options.gap.columns),w=u-Math.floor(x)*(o+p.options.gap.columns),s=_+Math.floor(x)+(w>=o/2?1:0),p.itemsMap[r].colSpan=Math.max(s,1))),"true"==i&&(h=e.y.location-m,n=C.bottom+window.scrollY-e.y.location<p.options.gap.rows,(a=v+h<=l)||n&&S?h=0:(k=h/(l+p.options.gap.rows),w=h-Math.floor(k)*(l+p.options.gap.rows),c=b+Math.floor(k)+(w>=l/2?1:0),p.itemsMap[r].rowSpan=Math.max(c,1))),p._positionHint(s,c),p._positionResizeHandle(d,"true"==t,"true"==i),h&&d.css("height",v+h),u&&d.css("width",g+u)},resizeend:function(){p._isresizing=!1,p._setContainerCoordinates(d,p.itemsMap[r]),p._removeAbsoluteStyles(d),p._removeResizeHint(),p.trigger(s,{container:d})}}))},_calculateFractionWidth:function(){var e=this,t=e.element.children().first(),n=e.itemsMap[t.attr("id")].colSpan;return(t.outerWidth()-(n-1)*e.options.gap.columns)/n},_calculateRightEndSide:function(e){var t=this.options.columns,n=this.options.gap.columns;return t*(e+n)+n},_createDropHint:function(n){this.dropHint=e("<div class='"+u.styles.reorderHint+"'></div>").css({order:n.order,"grid-column-end":n.columnEnd,"grid-row-end":n.rowEnd}).attr(t.attr("index"),n.order).attr("direction",n.direction)},_insertDropHint:function(e,t){"right"==t?this.dropHint.insertAfter(e):this.dropHint.insertBefore(e)},_removeDropHint:function(){this.dropHint&&(this.dropHint.remove(),this.dropHint=null)},_reorderable:function(){if(this.options.reorderable){var n,i=this,o=i.element,s=a(u.styles.item),c=a(u.styles.itemHeader),p=t.guid();this._draggableInstance=new r(this.element,{filter:c+",.k-layout-item-hint-reorder",autoScroll:!0,ignore:":input",group:p,clickMoveClick:!1!==this.options.reorderable.clickMoveClick,hint:function(e){var t=e.closest(s),n=t.width(),i=t.height(),r=t.clone();return r.find(c).removeClass(d).addClass("k-cursor-grabbing"),r.width(n).height(i)},dragstart:function(t){n=e(t.currentTarget).closest(s),document.body.style.cursor="move"},drag:function(r){var o,a,l,c,d=t.elementUnderCursor(r),p=r.sender.hint,f=i._draggableInstance.currentTarget.closest(s);if(h(p[0],d)){if(p.hide(),d=t.elementUnderCursor(r),!h(n[0],d)){if(i.dropHint&&i.dropHint[0]==d[0])return void p.show();if((o=(o=e(d)).hasClass(u.styles.item)?o:o.closest(s)).hasClass(u.styles.item))if(a=o[0].getBoundingClientRect(),l=r.clientX-a.left>a.right-r.clientX?"right":"left",c=o.css("order"),i.dropHint&&i.dropHint.attr("direction")!==l){var m=i.dropHint.clone();m.css("order",c),i.dropHint.remove(),i.dropHint=m,i._insertDropHint(o,l),i.dropHint.attr("direction",l).attr(t.attr("index"),c)}else if(!i.dropHint){("right"==l?o.next():o.prev())[0]!=n[0]&&(i._createDropHint({order:c,columnEnd:f.css("grid-column-end"),rowEnd:f.css("grid-row-end"),direction:l}),n.hide(),i._insertDropHint(o,l))}}p.show()}},dragend:function(e){if(document.body.style.cursor="auto",!i.dropHint)return e.sender.hint.remove(),void i._removeDropHint();var n,r,o,a,c=parseInt(i.dropHint.css("order"),10),d=e.currentTarget.closest(s),u=i.element.find(s),h=parseInt(d.css("order"),10),p=d.attr("id"),f=i.element.children(":visible");c=(f=i._sortContainers(f)).index(i.dropHint[0]),r=Math.max(c,h),n=Math.min(c,h),i.itemsMap[p].order=c,"left"==(a=c>h?"right":"left")?r--:n++;for(var m=n;m<=r;m++)o=u.filter("["+t.attr("index")+"='"+m+"']"),i.itemsMap[o.attr("id")].order+="left"==a?1:-1;d.show(),i._updateContainers(),e.sender.hint.remove(),i._removeDropHint(),i.options.navigatable&&i._updateDOM(),i.trigger(l,{newIndex:c,oldIndex:h,container:d})},dragcancel:function(){document.body.style.cursor="auto",i._removeDropHint(),n&&n.show()}}),o.find(s).kendoDropTarget({group:p,dragenter:function(t){if(!i._isresizing){var r,o,a=e(t.dropTarget),l=i._draggableInstance.currentTarget.closest(s);if(n[0]!=a[0]){if(r=a[0].getBoundingClientRect(),("right"==(o=t.clientX-r.left>r.right-t.clientX?"right":"left")?a.next():a.prev())[0]==n[0])return;i._removeDropHint(),n.hide(),i._createDropHint({order:a.css("order"),columnEnd:l.css("grid-column-end"),rowEnd:l.css("grid-row-end"),direction:o}),n.hide(),i._insertDropHint(a,o)}}}})}}});function h(t,n){try{return e.contains(t,n)||t==n}catch(e){return!1}}n.plugin(u),e.extend(!0,u,{styles:{wrapper:"k-tilelayout k-pos-relative",item:"k-tilelayout-item k-card",itemHeader:"k-tilelayout-item-header k-card-header",itemHeaderTitle:"k-card-title",itemBody:"k-tilelayout-item-body k-card-body",reorderHint:"k-layout-item-hint k-layout-item-hint-reorder",resizeHint:"k-layout-item-hint k-layout-item-hint-resize"}})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=e.extend,o=n.htmlEncode,a=".kendoWizard",s="click",l="activate",c="select",d="reset",u="submit",h="previous",p="next",f="done",m="error",g="contentLoad",v="formValidateFailed",_="k-hidden",b="k-step-link",y="aria-selected",w="aria-hidden",k="aria-label",x="bottom",C="right",S="left",T=".",D="id",A="role",M="data-wizard-",E="k-wizard",I="k-wizard-horizontal",z="k-wizard-vertical",P="k-wizard-right",H="k-wizard-left",F="k-wizard-steps",R="k-wizard-step",L="k-wizard-content",B="k-wizard-buttons",O="k-wizard-buttons-left",V="k-wizard-buttons-right",N="k-wizard-pager",$=n.Class.extend({init:function(e){this.options=r({},this.options,e),this.options.actionBar&&this._processButtons(),this._render()},options:{name:"WizardStep",index:0,content:"",contentUrl:null,contentId:null,markupContainer:null,form:null,actionBar:!0,buttons:[],pager:!0,selected:!1,enabled:!0,className:"",totalSteps:1,wizardId:"wizard",formTag:"form",messages:{}},_defaultButtonsConfiguration:{first:[d,p],middle:[d,h,p],last:[d,h,f]},_pagerTemplate:({step:e,currentStep:t,of:n,totalSteps:i})=>`<span class="k-wizard-pager">${o(e)} ${o(t)} ${o(n)} ${o(i)}</span>`,buttons:function(){return this._buttons},load:function(){this.options.contentUrl&&this._ajaxRequest()},resetButtons:function(){var e=this.element.find(T+B);n.destroy(e),e.remove(),this.options.buttons=[],this._processButtons(),this._buttonsContainer()},_ajaxRequest:function(t,i){var r=this,o=r.options.contentUrl,a=r.element,s={type:"GET",cache:!1,url:o,dataType:"html",data:{},error:function(e,n){t&&t._triggerError(e,n,r)},complete:function(){t&&i&&t._triggerActivate(r)},success:function(e){var i=a.find(T+L);try{n.destroy(i),i.html(e),t&&t._triggerContentLoad(r)}catch(e){this.error(this.xhr,"error")}}};"object"==typeof o&&(s=e.extend(!0,{},s,o)),e.ajax(s)},_ariaAttributes:function(){var e=this.element,t=this.options,n=t.messages,i=n.step+" "+(t.index+1)+" "+n.of+" "+t.totalSteps;e.attr(A,"tabpanel").attr("tabindex",0).attr(D,t.wizardId+"-"+t.index).attr(k,i)},_buttonFactory:function(t){var n=e("<button type='button'><span></span></button>").kendoButton({themeColor:t.primary?"primary":"base"}).getKendoButton(),i=n.element;i.attr(M+t.name,""),i.find("span").text(t.text),t.click&&n.bind(s,t.click),!1===t.enabled&&n.enable(!1),t.position===S?this._leftButtonsContainer.append(i):this._rightButtonsContainer.append(i),"done"===t.name&&"form"!==this.options.formTag&&n.element.attr("type",u),this._buttons.push(n)},_buttonsContainer:function(){var t=e("<div>").addClass(B);this._leftButtonsContainer=e("<span>").addClass(O),this._rightButtonsContainer=e("<span>").addClass(V),t.append(this._leftButtonsContainer),t.append(this._rightButtonsContainer),this.element.append(t),this._buttons=[],this.options.buttons.map(this._buttonFactory.bind(this)),this.options.pager&&this._pager()},_content:function(){var t=this.options,i=!!t.contentUrl,r=e("<div>").addClass(L);!i&&t.contentId?r.html(e("#"+t.contentId).html()):!i&&t.content&&r.append(t.content),t.markupContainer&&(i||t.contentId||t.content||r.append(t.markupContainer.html()),n.destroy(t.markupContainer),t.markupContainer.remove()),this.element.prepend(r)},_form:function(){var t="<"+this.options.formTag+">",n=e(t).hide(),i=e("<div>").addClass(L),r=this.options.form;e("body").append(n),this.element.prepend(i),r.buttonsTemplate=r.buttonsTemplate||(()=>""),this.form=n.kendoForm(r).getKendoForm(),i.append(n.show())},_iterateButton:function(e){var t=this.options.messages;return"string"==typeof e&&(e={name:e}),e.text||(e.text=t[e.name]||e.name.charAt(0).toUpperCase()+e.name.slice(1)),!1===e.primary||e.name!==f&&e.name!==p||(e.primary=!0),e.position||e.name!==d?e.position||(e.position=C):e.position=S,e},_pager:function(){var e=this.options,t=e.messages,i={step:t.step,currentStep:e.index+1,of:t.of,totalSteps:e.totalSteps},r=n.template(this._pagerTemplate)(i);this._leftButtonsContainer.append(r)},_processButtons:function(){var e=this.options,t=e.buttons,n=this._defaultButtonsConfiguration;t&&t.length&&0!==t.length||(this.options.defaultButtons=!0,t=0===e.index?n.first:e.index+1===e.totalSteps?n.last:n.middle),this.options.buttons=t.map(this._iterateButton.bind(this))},_render:function(){this.element=e("<div>").addClass(R),this.options.className&&this.element.addClass(this.options.className),this._ariaAttributes(),this.options.selected||(this.element.addClass(_),this.element.attr(w,!0)),this.options.actionBar&&this._buttonsContainer(),this.options.form?this._form():this._content()}}),U=i.extend({init:function(e,t){var n=this;t=t||{},i.fn.init.call(n,e,t),n._wrapper(),n._createSteps(),n._stepper(),n._attachEvents()},options:{name:"Wizard",contentPosition:x,actionBar:!0,pager:!0,loadOnDemand:!1,reloadOnSelect:!1,validateForms:!0,stepper:{},steps:[],messages:{reset:"Reset",previous:"Previous",next:"Next",done:"Done",step:"Step",of:"of"}},events:[l,c,d,f,m,g,v],destroy:function(){var e=this;i.fn.destroy.call(e.stepper),i.fn.destroy.call(e),e.wrapper.off(a)},activeStep:function(){return this.currentStep},enableStep:function(e,n){var i,r=this;e===t||null===e||isNaN(e)||e>=r._steps.length||e<0||(e=Number(e),(i=r._steps[e]).options.enabled!==n&&(i.options.enabled=n,r.stepper.steps()[e].enable(n)))},insertAt:function(e,n){var i,r,o,a=this._steps,s=a.length,l=this.options.messages;null===e||e===t||isNaN(e)||e<0||e>s||n&&(r=this._mapStepForStepper(n),this.stepper.insertAt(e,r),n.totalSteps=s+1,n.messages=l,n.index=e,n.formTag=this.wrapper.is("form")?"div":"form",!1===this.options.pager&&!0!==n.pager&&(n.pager=!1),i=new $(n),a.forEach((function(t,n){var i;n>=e&&(t.options.index+=1),t.options.totalSteps+=1,t.element.find(T+N).remove(),t._pager(),i=l.step+" "+(t.options.index+1)+" "+l.of+" "+(s+1),t.element.attr(k,i)})),a.splice(e,0,i),0!==e&&e!==s||(o=a[0===e?1:s-1]).options.defaultButtons&&o.resetButtons(),this._insertStepElementAtIndex(e,i.element),this._stepperAriaAttributes(),this._steps.forEach(this._iterateAriaStep))},next:function(){var e=this,t=e._steps.length,n=e.currentStep.options.index;n+1!==t&&e.steps()[n+1].options.enabled&&(e._select(n+1),e._selectStepper(n+1))},previous:function(){var e=this,t=e.currentStep.options.index;0!==t&&e.steps()[t-1].options.enabled&&(e._select(t-1),e._selectStepper(t-1))},removeAt:function(i){var r,o,a,s,l,c=this._steps,d=c.length,u=e(this.element.find(T+R).get(i)),h=this.options.messages;if(!(null===i||i===t||isNaN(i)||i<0||i>d||1===d)){for(this.stepper.removeAt(i),c.splice(i,1)[0],u.hasClass(_)||(r=0===i?0:i-1,this.select(r)),n.destroy(u),u.remove(),a=0;a<d-1;a+=1)(s=c[a]).options.index=a,s.options.totalSteps=d-1,s.element.find(T+N).remove(),s._pager(),l=h.step+" "+(a+1)+" "+h.of+" "+(d-1),s.element.attr(k,l);0!==i&&i!==d-1||(o=c[0===i?0:d-2]).options.defaultButtons&&o.resetButtons(),this._stepperAriaAttributes(),this._steps.forEach(this._iterateAriaStep)}},select:function(e){var n=this;e===t||null===e||isNaN(e)||e>=n._steps.length||e<0||(e=Number(e),n._steps[e].options.enabled&&(n._select(e),n._selectStepper(e)))},steps:function(){return this._steps},_attachEvents:function(){var e=this,t=function(){e._doneClicked=!0};e.stepper.bind(c,e._stepperSelectHandler.bind(e)),e.wrapper.on(s+a,"["+M+d+"]",e._resetClickHandler.bind(e)).on(s+a,"["+M+h+"]",e._previousClickHandler.bind(e)).on(s+a,"["+M+p+"]",e._nextClickHandler.bind(e)),e.wrapper.is("form")?(e.wrapper.on(s+a,"["+M+f+"]",t),e.wrapper.on(u+a,e._doneHandler.bind(e))):(e.wrapper.on(s+a,"["+M+f+"]",t),e.wrapper.on(s+a,"["+M+f+"]",e._doneHandler.bind(e)))},_changeStep:function(e){var t=this.wrapper.find(T+R);this.currentStep=e,t.addClass(_),t.attr(w,!0),e.element.removeClass(_),e.element.removeAttr(w)},_createStep:function(t,n,i,o){var a=this.wrapper,s=this.wrapper.children("ol, ul").children("li");return"string"==typeof t&&(t={title:t}),t.totalSteps=o,t.messages=this.options.messages,t.index=n,t.formTag=this.wrapper.is("form")?"div":"form",0===n&&(t.selected=!0),!1===this.options.actionBar&&(t.actionBar=!1),i.length>0&&i[n]&&(t.markupContainer=e(i[n]),t.title||(t.title=s[n]?s[n].textContent:(n+1).toString(),this.options.steps||(this.options.steps=[]))),a.attr(D)&&(t.wizardId=a.attr(D)),!1===this.options.pager&&!0!==t.pager&&(t.pager=!1),this.options.steps[n]=r(!0,{},t),new $(t)},_createSteps:function(){var t,i,r,o,a=this,s=a.wrapper,l=a.options.steps,c=s.children("div");if(t=e("<div>").addClass(F),a._steps=[],!l||0===l.length)for(l=[],i=0;i<c.length;i+=1)l.push({});for(i=0;i<l.length;i+=1)r=l[i],o=a._createStep(r,i,c,l.length),!r.contentUrl||0!==i&&a.options.loadOnDemand||(n.ui.progress(a.wrapper,!0),o._ajaxRequest(a)),t.append(o.element),a._steps.push(o);s.children("ol, ul").remove(),s.empty(),s.append(t),a._refreshEditorWidgets(),a.currentStep=a._steps[0]},_doneHandler:function(t){var n,i,r=this._steps,o=this.currentStep,a=[];if(this._doneClicked){if(this._doneClicked=!1,this.options.validateForms&&o.form&&!o.form.validator.validate())return t.preventDefault(),void this.trigger(v,{sender:this,step:o,form:o.form});for(i=0;i<r.length;i+=1)(n=r[i].form)&&a.push(n);this.trigger(f,{sender:this,forms:a,originalEvent:t,button:e(t.target).getKendoButton()})}},_insertStepElementAtIndex:function(e,t){var n=this.wrapper.find(T+F);0===e?n.prepend(t):n.find(T+R+":nth-child("+e+")").after(t)},_isEmpty:function(e){return!n.trim(e.html())},_iterateAriaStep:function(e){e._ariaAttributes()},_mapStepForStepper:function(e){var t=r(!0,{},e);return t.label=t.title,delete t.buttons,delete t.pager,delete t.content,delete t.contentUrl,delete t.contentId,delete t.formTag,delete t.wizardId,delete t.messages,t},_select:function(e){var t=this._steps[e],i=this.options;t.options.contentUrl&&(i.reloadOnSelect||i.loadOnDemand&&this._isEmpty(t.element.find(T+L)))?(this.ajaxLoad=!0,n.ui.progress(this.wrapper,!0),t._ajaxRequest(this,!0)):this._changeStep(t)},_nextClickHandler:function(t){var n=this,i=n._steps,r=n._steps.length,o=n.currentStep,a=o.options.index,s=e(t.target).getKendoButton(),d=i[a+1];r!==a+1&&d.options.enabled&&(n.options.validateForms&&o.form&&!o.form.validator.validate()?n.trigger(v,{sender:n,step:o,form:o.form}):n.trigger(c,{sender:n,originalEvent:t.originalEvent,step:d,button:s})||(n._select(a+1),n._selectStepper(a+1),n.ajaxLoad||n.trigger(l,{sender:n,step:d}),n.ajaxLoad=!1))},_previousClickHandler:function(t){var n=this,i=n.options.validateForms,r=n._steps,o=n.currentStep,a=o.options.index,s=e(t.target).getKendoButton(),d=r[a-1];0!==a&&d.options.enabled&&(i&&!1!==i.validateOnPrevious&&o.form&&!o.form.validator.validate()?n.trigger(v,{sender:n,step:o,form:o.form}):n.trigger(c,{sender:n,originalEvent:t.originalEvent,step:d,button:s})||(n._select(a-1),n._selectStepper(a-1),n.ajaxLoad||n.trigger(l,{sender:n,step:d}),n.ajaxLoad=!1))},_refreshEditorWidgets:function(){var t,n=this.wrapper.find("[data-role='editor']");for(t=0;t<n.length;t+=1)e(n[t]).getKendoEditor().refresh()},_resetClickHandler:function(t){this.trigger(d,{sender:this,originalEvent:t,button:e(t.target).getKendoButton()})},_selectStepper:function(e){var t=this.stepper,n=t.steps()[e].element.find(T+b);t.select(e),t.wrapper.find(T+b).attr(y,!1),n.attr(y,!0).trigger("focus")},_stepper:function(){var t=this.wrapper,i=e("<div>").prependTo(t),r=this.options,o=r.stepper,a=r.steps.map(this._mapStepForStepper);o.steps=a,o.orientation=r.contentPosition===x?"horizontal":"vertical",o.selectOnFocus=!0,o.kendoKeydown=function(e){e.keyCode===n.keys.TAB&&(e.preventKendoKeydown=!0)},this.stepper=i.kendoStepper(o).getKendoStepper(),this._stepperAriaAttributes()},_stepperAriaAttributes:function(){var e,t,n=this.stepper,i=this.wrapper.attr(D)||"wizard",r=n.steps();if(r)for(n.element.find(".k-step-list").attr(A,"tablist"),t=0;t<r.length;t+=1)e=!1,0===t&&(e=!0),r[t].element.attr(A,"none").find("a").attr(A,"tab").attr("aria-controls",i+"-"+t).attr(y,e)},_stepperSelectHandler:function(e){var t=this,n=t.options.validateForms,i=e.sender,r=e.step,o=t.currentStep.options.index,a=r.getIndex(),s=t._steps[a],d=t.currentStep;return a>o&&n&&d.form&&!d.form.validator.validate()||a<o&&n&&!1!==n.validateOnPrevious&&d.form&&!d.form.validator.validate()?(e.preventDefault(),void t.trigger(v,{sender:t,step:d,form:d.form})):void(t.trigger(c,{sender:t,originalEvent:e.originalEvent,step:s,stepper:i})?e.preventDefault():(t._select(a),i.wrapper.find(T+b).attr(y,!1),r.element.find(T+b).attr(y,!0),t.ajaxLoad||t.trigger(l,{sender:t,step:s}),t.ajaxLoad=!1))},_triggerActivate:function(e){this._changeStep(e),this.trigger(l,{sender:this,step:e})},_triggerError:function(e,t,i){n.ui.progress(this.wrapper,!1),this.trigger(m,{sender:this,xhr:e,status:t,step:i})},_triggerContentLoad:function(e){n.ui.progress(this.wrapper,!1),this.trigger(g,{sender:this,step:e})},_wrapper:function(){var e=this,t=e.element,n=e.options.contentPosition;e.wrapper=t,e.wrapper.addClass(E),n===C?e.wrapper.addClass(z+" "+P):n===S?e.wrapper.addClass(z+" "+H):e.wrapper.addClass(I)}});n.wizard={Step:$},n.ui.plugin(U)}(window.kendo.jQuery);kendo;var SH=()=>"<span class='k-appbar-spacer'></span>";!function(e){var t=window.kendo,n=t.ui,i=n.Widget,r="resize",o=i.extend({init:function(t,n){var r=this;i.fn.init.call(r,t,n),r.element=e(t).addClass("k-appbar"),"none"!=r.options.position&&r.element.addClass("k-appbar-"+r.options.position),r.element.addClass("k-appbar-"+r.options.positionMode+" k-appbar-"+r.options.themeColor).attr("role","toolbar"),r._initItems(),r._attachEvents()},events:[r],options:{name:"AppBar",positionMode:"static",position:"none",themeColor:"light",items:[]},destroy:function(){this.resizeHandler&&(t.unbindResize(this.resizeHandler),this.resizeHandler=null),i.fn.destroy.call(this)},setOptions:function(e){var n=this;"none"!=n.options.position&&n.element.removeClass("k-appbar-"+n.options.position),n.element.removeClass("k-appbar-"+n.options.positionMode+" k-appbar-"+n.options.themeColor),t.deepExtend(n.options,e),this.destroy(),this.element.empty(),this.init(this.element,this.options)},_initItems:function(){for(var n,i,r=this.options.items,o="",a=0;a<r.length;a++)if("spacer"==(n=r[a]).type)i=e(t.template(SH)({})).addClass(n.className),n.width&&(i.addClass("k-appbar-spacer-sized"),i.css("width","string"==typeof n.width?n.width:n.width+"px")),o+=i[0].outerHTML;else{if(!n.template)throw new Error("Having a template for the contentItem is mandatory");n.className?o+="<div class='k-appbar-section "+n.className+"'>":o+="<div class='k-appbar-section'>",o+=t.template(n.template)({}),o+="</div>"}this.element.html(o)},_resize:function(){this.trigger(r)},_attachEvents:function(){var e=this;e.resizeHandler=e._resize.bind(e),t.onResize(e.resizeHandler)}});n.plugin(o)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=e.extend,i=t.Class,r=".k-imageeditor-pane",o="k-imageeditor-pane-form",a="k-imageeditor-crop-overlay",s="k-imageeditor-crop",l="k-resize-handle",c="k-resize-";const d="[ref-pane-button]";var u=function(e){return Math.round(1e3*e)/1e3},h=i.extend({init:function(t){var n=this;n.imageeditor=t,n.imageeditor.currentPaneTool&&n.imageeditor.currentPaneTool.destroy(),n.element=e("<div role='form' aria-label='Image edit pane.'></div>").addClass(o)},open:function(){var e=this,i=e.imageeditor,r=i.options.messages.common;i.paneWrapper.append(e.element),e.formWidget=new t.ui.Form(e.element,n(e.formSettings(),{buttonsTemplate:()=>t.html.renderButton(`<button ref-pane-button data-action='confirm'>${r.confirm}</button>`,{icon:"check",themeColor:"primary"})+t.html.renderButton(`<button ref-pane-button data-action='cancel'>${r.cancel}</button>`,{icon:"cancel-outline"})})),e.bindButtonEvents(),i.paneWrapper.show(),i.currentPaneTool=e},bindButtonEvents:function(){var e=this,t=e.formWidget.element.find(d);e._clickHandler=e._click.bind(e),t.on("click"+r,e._clickHandler)},_click:function(t){var n=e(t.target).closest(d).data("action");this[n]&&this[n]()},cancel:function(){this.imageeditor.toolbar.element.find("[tabindex=0]").trigger("focus"),this.destroy()},confirm:function(){window.console.error("Pane's confirm method is not implemented!"),this.destroy()},refresh:function(){},destroy:function(){var e=this,t=e.imageeditor;e.formWidget.element.find(d).off(r),e.formWidget.destroy(),t.paneWrapper.html(""),t.paneWrapper.hide(),delete t.currentPaneTool}}),p=h.extend({init:function(e){var t=this;h.fn.init.call(t,e),t.buildCropModel(),t.canvasUI()},confirm:function(){var e=this,t=e.formWidget._model.toJSON();e.destroy(),e.imageeditor.executeCommand({command:"CropImageEditorCommand",options:t})},formSettings:function(){var e=this,t=e.imageeditor.options.messages.panes.crop,n=e.imageeditor.options.messages.common,i=t.aspectRatioItems,r=[];if(i)for(var o in i)r.push({value:o,text:i[o]});else r=[{value:"originalRatio",text:"Original ratio"},{value:"1:1",text:"1:1 (Square)"},{value:"4:5",text:"4:5 (8:10)"},{value:"5:7",text:"5:7"},{value:"2:3",text:"2:3 (4:6)"},{value:"16:9",text:"16:9"}];return{formData:e._model,change:e.onChange.bind(e),items:[{type:"group",label:t.title||"Crop Image",layout:"grid",grid:{cols:2,gutter:"0 8px"},items:[{label:t.aspectRatio||"Aspect ratio:",field:"aspectRatio",editor:"DropDownList",editorOptions:{dataValueField:"value",dataTextField:"text",dataSource:r},colSpan:2},{label:t.orientation,field:"orientation",editor:e._orientationEditor.bind(e),colSpan:2},{label:n.width||"Width:",field:"width",attributes:{style:"max-width: 100px;"},editor:"NumericTextBox",editorOptions:{format:"n0",max:e._model.width,min:0},colSpan:1},{label:n.height||"Height:",field:"height",attributes:{style:"max-width: 100px;"},editor:"NumericTextBox",editorOptions:{format:"n0",max:e._model.height,min:0},colSpan:1},{label:n.lockAspectRatio||"Lock aspect ratio",field:"lockAspectRatio",colSpan:2}]}]}},_orientationEditor:function(t,n){var i=this.imageeditor.options.messages.panes.crop,r=n.model[n.field];this._orientationWidget=e("<div name='"+n.field+"'></div>").appendTo(t).kendoButtonGroup({items:[{text:i.portrait||"Portrait",attributes:{"data-value":"portrait"},selected:"portrait"===r},{text:i.landscape||"Landscape",attributes:{"data-value":"landscape"},selected:"landscape"===r}],select:function(e){var t=e.sender.wrapper.find(".k-selected").data("value");n.model.set(n.field,t)}}).data("kendoButtonGroup")},buildCropModel:function(){var e=this.imageeditor.getCanvasElement(),t=e.width,n=e.height;this._model={top:0,left:0,aspectRatio:"originalRatio",width:t,height:n,orientation:t-n<0?"portrait":"landscape",lockAspectRatio:!0}},canvasUI:function(){for(var n=this,i=n.imageeditor,r=n.imageeditor.canvasContainer,o=e("<div></div>").addClass(a),d=e("<div></div>").addClass(s),u="<span class='"+l+"'></span>",h=["nw","n","ne","w","e","sw","s","se"],p=i.getZoomLevel(),f=0;f<h.length;f++){var m=e(u).addClass(c+h[f]).attr("data-orientation",h[f]);n._initResizeHandle(m),d.append(m)}n.cropElement=d,n._canvasUI=o.append(d).appendTo(r);var g=Math.round(n._model.width*p),v=Math.round(n._model.height*p),_=parseInt(n.cropElement.css("border-top-width"),10);n.cropElement.css({width:g,height:v,backgroundImage:"url('"+i._image.src+"')",backgroundSize:t.format("{0}px {1}px",g,v),backgroundClip:"content-box",backgroundPosition:t.format("-{0}px -{0}px",_)}),n.cropElement.kendoDraggable({ignore:"."+l,drag:function(e){n._adjustTopLeft(e.target.offsetTop+e.y.delta,e.target.offsetLeft+e.x.delta)}})},refresh:function(){var e=this,n=e.formWidget._model,i=e.imageeditor.getZoomLevel(),r=Math.round(n.width*i),o=Math.round(n.height*i),a=Math.round(n.top*i),s=Math.round(n.left*i),l=parseInt(e.cropElement.css("border-top-width"),10);e.cropElement.css({top:a,left:s,width:r,height:o,backgroundSize:t.format("{0}px {1}px",e._model.width*i,e._model.height*i),backgroundPosition:t.format("-{0}px -{1}px",s+l,a+l)})},_initResizeHandle:function(t){var n=this;t.kendoDraggable({drag:function(t){var i=e(t.sender.element),r=n.formWidget._model,o=n._model,a=i.data("orientation"),s={},l=n.imageeditor.getZoomLevel(),c=r.left*l,d=r.top*l;a.indexOf("w")>=0?(s.left=n.cropElement[0].offsetLeft+t.x.delta,s.width=n.cropElement[0].offsetWidth-t.x.delta):a.indexOf("e")>=0&&(s.width=n.cropElement[0].offsetWidth+t.x.delta),a.indexOf("n")>=0?(s.top=n.cropElement[0].offsetTop+t.y.delta,s.height=n.cropElement[0].offsetHeight-t.y.delta):a.indexOf("s")>=0&&(s.height=n.cropElement[0].offsetHeight+t.y.delta),s.width&&(s.left||c)+s.width<=o.width*l&&r.set("width",Math.round(s.width/l)),s.height&&(s.top||d)+s.height<=o.height*l&&r.set("height",Math.round(s.height/l)),(s.top||s.left)&&n._adjustTopLeft(s.top,s.left)}})},_adjustTopLeft:function(e,t,n){var i=this,r=n||i.formWidget._model,o=i.formWidget._model,a=i._model,s=i.imageeditor.getZoomLevel();e>=0&&e/s+r.height<=a.height&&o.set("top",Math.round(e/s)),t>=0&&t/s+r.width<=a.width&&o.set("left",Math.round(t/s))},onChange:function(e){var i=this,r=i.imageeditor.getZoomLevel(),o=e.sender._model,a=i._model,s=a.width,l=a.height,c=(a.width,a.height),d=i._gcd(a.width,a.height);if(c=a.width/d+":"+a.height/d,"aspectRatio"===e.field&&"originalRatio"===e.value)o.set("top",0),o.set("left",0),o.set("orientation",a.orientation),o.set("width",a.width),o.set("height",a.height);else if("orientation"===e.field){var u=n({},o,{width:o.height,height:o.width}),h=i._calcSize(u,c,s,l);o.set("width",h.width),o.set("height",h.height),i._orientationWidget.select("portrait"===e.value?0:1)}else if(o.lockAspectRatio){var p=e.field,f=i._calcSize(o,c,s,l,p);o.set("width",f.width),o.set("height",f.height)}var m=Math.round(o.width*r),g=Math.round(o.height*r),v=Math.round(o.top*r),_=Math.round(o.left*r),b=parseInt(i.cropElement.css("border-top-width"),10);i.cropElement.css({top:v,left:_,width:m,height:g,backgroundPosition:t.format("-{0}px -{1}px",_+b,v+b)})},_calcSize:function(e,t,n,i,r){var o=Math.min(e.width,n),a=Math.min(e.height,i),s="portrait"===e.orientation,l=e.aspectRatio;l.indexOf(":")<0&&(l=t),l=l.split(":").map((function(e){return parseInt(e,10)}));var c=s?Math.min(l[0],l[1]):Math.max(l[0],l[1]),d=s?Math.max(l[0],l[1]):Math.min(l[0],l[1]),h=u(c/d),p=u(o/a),f={width:Math.round(a*h),height:Math.round(o/h)};return"width"===r?{width:o,height:f.height}:"height"===r?{width:f.width,height:a}:(p>h?o=f.width:p<h&&(a=f.height),{width:o,height:a})},_gcd:function(e,t){return 0===t?e:this._gcd(t,e%t)},destroy:function(){t.destroy(this._canvasUI),this._canvasUI.remove(),h.fn.destroy.call(this)}}),f=h.extend({init:function(e){h.fn.init.call(this,e),this.buildResizeModel()},confirm:function(){var e=this,t=e._model.width,n=e._model.height,i=e.formWidget._model.toJSON();"percents"===i.measure&&(i.width=t*(i.width/100),i.height=n*(i.height/100)),e.imageeditor.executeCommand({command:"ResizeImageEditorCommand",options:i}),e.destroy()},formSettings:function(){var e=this,t=e.imageeditor.options.messages.panes.resize,n=e.imageeditor.options.messages.common;return{formData:e._model,change:e.onChange.bind(e),items:[{type:"group",label:t.title||"Resize image",layout:"grid",grid:{cols:2,gutter:"0 8px"},items:[{label:n.width||"Width:",field:"width",attributes:{style:"max-width: 100px;"},editor:"NumericTextBox",editorOptions:{format:"n0",min:0},colSpan:1},{field:"measureW",editor:"DropDownList",attributes:{style:"max-width: 100px;"},label:{text:"&nbsp;",encoded:!1},editorOptions:{dataTextField:"text",dataValueField:"value",dataSource:[{text:t.pixels||"Pixels",value:"pixels"},{text:t.percents||"Percents",value:"percents"}]},colSpan:1},{label:n.height||"Height:",field:"height",attributes:{style:"max-width: 100px;"},editor:"NumericTextBox",editorOptions:{format:"n0",min:0},colSpan:1},{field:"measureH",label:{text:"&nbsp;",encoded:!1},attributes:{style:"max-width: 100px;"},editor:"DropDownList",editorOptions:{dataTextField:"text",dataValueField:"value",dataSource:[{text:t.pixels||"Pixels",value:"pixels"},{text:t.percents||"Percents",value:"percents"}]},colSpan:1},{label:n.lockAspectRatio||"Lock aspect ratio",field:"lockAspectRatio",colSpan:2}]}]}},buildResizeModel:function(){var e=this.imageeditor.getCanvasElement(),t=e.width,n=e.height;this._model={width:t,height:n,measure:"pixels",measureW:"pixels",measureH:"pixels",lockAspectRatio:!0,ratio:u(t/n)}},onChange:function(e){var t=this,n=e.sender._model,i=n.lockAspectRatio;"measureW"===e.field||"measureH"===e.field?(n.set("measureW",e.value),n.set("measureH",e.value),n.set("measure",e.value)):"measure"===e.field?t.resetNumericsTo(e.value):"width"===e.field&&i&&!t._preventChange?n.set("height",n.width/n.ratio):"height"===e.field&&i&&!t._preventChange&&n.set("width",n.height*n.ratio),n.set("ratio",u(n.width/n.height))},resetNumericsTo:function(e){var t=this,n=t._model.width,i=t._model.height,r=t.formWidget,o=r._model,a=r.element.find("[name=width]").data("kendoNumericTextBox"),s=r.element.find("[name=height]").data("kendoNumericTextBox"),l="percents"===e,c={percents:{format:"#\\%"},pixels:{format:"n0"}};a.setOptions(c[e]),s.setOptions(c[e]),t._preventChange=!0,o.set("width",l?n/a.value()*100:n*(a.value()/100)),o.set("height",l?i/s.value()*100:i*(s.value()/100)),t._preventChange=!1}});n(t.ui,{imageeditor:{ImageEditorPane:h,panes:{crop:p,resize:f}}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.ui.imageeditor,i=e.extend,r=t.Class.extend({init:function(e){this.options=i({},e,this.options),this.imageeditor=e.imageeditor}}),o=r.extend({init:function(e){r.fn.init.call(this,e)},exec:function(){var e=this.imageeditor,t=new n.panes[this.options.value](e);t.open(),t.element.find(":kendoFocusable").first().trigger("focus")}}),a=r.extend({options:{zoomStep:.05,spacing:20},init:function(e){r.fn.init.call(this,e)},exec:function(){var t,n=this,i=n.options.value,r=n.imageeditor,o=r._image.height,a=r.getZoomLevel(),s="zoomIn"===i||"zoomOut"===i;isNaN(i)?"string"==typeof i&&(i=n._processStringValue(i,a)):i=parseFloat(i),(t=Math.round(o*i))>0&&(e(r._canvas).css("height",t),r._zoomLevel=i),r.currentPaneTool&&r.currentPaneTool.refresh(),s&&r.toolbar.element.find("[tabindex=0]").trigger("focus")},_processStringValue:function(e,t){var n=this.options,i=this.imageeditor,r=i._image.height,o=i.canvasWrapper.height()-n.spacing,a=n.zoomStep;switch(e){case"zoomIn":return t+a;case"zoomOut":return t-a;case"fitToScreen":return Math.round(o/r*100)/100;default:return 1}}}),s=r.extend({init:function(e){r.fn.init.call(this,e)},exec:function(){var e=this.options,t=this.imageeditor,n=t.getCanvasElement(),i=t.getCurrent2dContext(),r=i.getImageData(e.left,e.top,e.width,e.height);i.clearRect(0,0,n.width,n.height),n.width=e.width,n.height=e.height,i.putImageData(r,0,0),t.drawImage(n.toDataURL()).done((function(e){t.drawCanvas(e),t.toolbar.element.find("[tabindex=0]").trigger("focus")})).fail((function(e){t.trigger("error",e)}))}}),l=r.extend({init:function(e){r.fn.init.call(this,e)},exec:function(){var e=this.options,t=this.imageeditor,n=t.getCanvasElement(),i=t.getCurrent2dContext(),r=t.getCurrentImage();i.clearRect(0,0,n.width,n.height),n.width=e.width,n.height=e.height,i.drawImage(r,0,0,e.width,e.height),t.drawImage(n.toDataURL()).done((function(e){t.drawCanvas(e),t.toolbar.element.find("[tabindex=0]").trigger("focus")})).fail((function(e){t.trigger("error",e)}))}}),c=r.extend({exec:function(){var e=this.imageeditor,t=e.getCanvasElement(),n=e.getCurrent2dContext(),i=e.undoStack.pop();i&&(e.redoStack.push(e.getCurrentImage()),delete e._image,n.clearRect(0,0,t.width,t.height),t.width=i.width,t.height=i.height,n.drawImage(i,0,0,i.width,i.height),e.drawImage(t.toDataURL()).done((function(t){e.drawCanvas(t),e.toolbar.element.find("[tabindex=0]").trigger("focus")})).fail((function(t){e.trigger("error",t)})))}}),d=r.extend({exec:function(){var e=this.imageeditor,t=e.getCanvasElement(),n=e.getCurrent2dContext(),i=e.redoStack.pop();i&&(e.undoStack.push(e.getCurrentImage()),delete e._image,n.clearRect(0,0,t.width,t.height),t.width=i.width,t.height=i.height,n.drawImage(i,0,0,i.width,i.height),e.drawImage(t.toDataURL()).done((function(t){e.drawCanvas(t),e.toolbar.element.find("[tabindex=0]").trigger("focus")})).fail((function(t){e.trigger("error",t)})))}}),u=r.extend({exec:function(){var e=this.imageeditor,n=e.getCanvasElement();t.saveAs(i({},e.options.saveAs,{dataURI:n.toDataURL()})),e.toolbar.element.find("[data-command=SaveImageEditorCommand]").trigger("focus")}}),h=r.extend({exec:function(){var t=this,n=t.imageeditor,i=n._upload;if(!i){var r=e("<input type='file' />");r.kendoUpload({select:t.onSelect.bind(t),error:t.onError.bind(t),multiple:!1,validation:{allowedExtensions:[".jpg",".jpeg",".gif",".png",".bmp",".tiff",".webp"]}}),n._upload=i=r.getKendoUpload()}i.element.click()},onSelect:function(e){var t=this.imageeditor,n=e.files[0].rawFile,i=new FileReader;i.addEventListener("load",(function(){t.drawImage(i.result).done((function(e){t.trigger("imageLoaded",{image:e})||(t.drawCanvas(e),t._initUndoRedoStack(),t._toggleTools())})).fail((function(e){t.trigger("error",e)}))}),!1),n&&i.readAsDataURL(n)},onError:function(e){this.imageeditor.trigger("error",e)}});i(t.ui.imageeditor,{ImageEditorCommand:r,commands:{OpenPaneImageEditorCommand:o,ZoomImageEditorCommand:a,CropImageEditorCommand:s,ResizeImageEditorCommand:l,UndoImageEditorCommand:c,RedoImageEditorCommand:d,SaveImageEditorCommand:u,OpenImageEditorCommand:h}})}(window.kendo.jQuery);!function(e){var t=window.kendo,n=e.extend,i=e.isPlainObject,r=t.ui.Widget,o=t.ui,a=".kendoImageEditor",s=t._outerHeight,l="error",c="imageLoaded",d="imageRendered",u="execute",h=e=>`<canvas role='img' aria-label='${e}'>Canvas element</canvas>`,p="k-imageeditor",f="k-imageeditor-header",m="k-imageeditor-toolbar",g="k-imageeditor-action-pane",v="k-imageeditor-content",_="k-imageeditor-canvas-container",b="k-imageeditor-canvas",y=r.extend({init:function(n,i){var o=this;r.fn.init.call(o,n,i),i=e.extend(!0,{},i),o._wrapper(),o._renderHeader(),o._contentWrapper(),o._keyHandler(),i.imageUrl&&o._drawCanvas(),o._initUndoRedoStack(),o._toggleTools(),t.notify(o)},options:{name:"ImageEditor",width:"100%",height:570,imageUrl:"",imageLabel:"",toolbar:{},saveAs:{fileName:"image.png"},messages:{toolbar:{open:"Open Image",save:"Save Image",undo:"Undo",redo:"Redo",crop:"Crop",resize:"Resize",zoomIn:"Zoom In",zoomOut:"Zoom Out",zoomDropdown:"Zoom options",zoomActualSize:"Show actual size",zoomFitToScreen:"Fit to screen"},panes:{crop:{title:"Crop Image",aspectRatio:"Aspect Ratio:",aspectRatioItems:{originalRatio:"Original ratio","1:1":"1:1 (Square)","4:5":"4:5 (8:10)","5:7":"5:7","2:3":"2:3 (4:6)","16:9":"16:9"},orientation:"Orientation:",portrait:"Portrait",landscape:"Landscape"},resize:{title:"Resize image",pixels:"Pixels",percents:"Percents"}},common:{width:"Width:",height:"Height:",cancel:"Cancel",confirm:"Confirm",lockAspectRatio:"Lock aspect ratio"}}},events:[l,c,d,u],defaultTools:{open:{type:"button",icon:"upload",name:"open",command:"OpenImageEditorCommand",showText:"overflow"},save:{type:"button",icon:"download",name:"save",command:"SaveImageEditorCommand",showText:"overflow",toggleCondition:"canExport"},separator:{type:"separator"},undo:{type:"button",icon:"undo",name:"undo",command:"UndoImageEditorCommand",showText:"overflow",toggleCondition:"undo"},redo:{type:"button",icon:"redo",name:"redo",command:"RedoImageEditorCommand",showText:"overflow",toggleCondition:"redo"},separator1:{type:"separator"},crop:{type:"button",icon:"crop",name:"crop",command:"OpenPaneImageEditorCommand",options:"crop",showText:"overflow",toggleCondition:"canExport"},resize:{type:"button",icon:"image-resize",name:"resize",command:"OpenPaneImageEditorCommand",options:"resize",showText:"overflow",toggleCondition:"canExport"},zoomIn:{type:"button",icon:"zoom-in",name:"zoomIn",command:"ZoomImageEditorCommand",showText:"overflow",options:"zoomIn",toggleCondition:"enable"},zoomOut:{type:"button",icon:"zoom-out",name:"zoomOut",command:"ZoomImageEditorCommand",showText:"overflow",options:"zoomOut",toggleCondition:"enable"},zoomDropdown:{type:"component",name:"zoomDropdown",command:"ZoomImageEditorCommand",toggleCondition:"enable",overflow:"never",component:"DropDownList",componentOptions:{placeholder:"Search",icon:"search",dataSource:[{name:"zoomActualSize",icon:"zoom-actual-size",value:"actualSize"},{name:"zoomFitToScreen",icon:"zoom-best-fit",value:"fitToScreen"}],dataTextField:"text",dataValueField:"value",valuePrimitive:!0,template:({icon:e,text:n})=>`${t.ui.icon(t.htmlEncode(e))} ${t.htmlEncode(n)}`,commandOn:"change",optionLabel:"Zoom options",dataBound:e=>{e.sender.list.find(".k-list-optionlabel").hide()}}}},_wrapper:function(){var e=this,n=e.options,i=n.width,r=n.height;e.wrapper=e.element.addClass(p),i&&e.wrapper.width(i),r&&e.wrapper.height(r),e._resizeHandler=t.onResize((function(){e.resize(!0)}))},_renderHeader:function(){var t=this,n=t.options;t.header=e("<div />").addClass(f),t.wrapper.append(t.header),n.toolbar&&(t._initToolbar(),t.toolbar._tabIndex())},_initToolbar:function(){var i=this,r=i.options,o=e("<div></div>").addClass(m),a=n({},r.toolbar),s=a.items?a.items:Object.keys(i.defaultTools);return a.tools=s,a.defaultTools=i.defaultTools,a.parentMessages=i.options.messages.toolbar,i.header.append(o),i.toolbar=new t.ui.ToolBar(o,a),i.options.toolbar=i.toolbar.options,i.toolbar.toggleTools(),i.toolbar.bind("click",i._toolbarClick.bind(i)),i.toolbar.bind("toggle",i._toolbarClick.bind(i)),i.toolbar.bind("change",i._toolbarClick.bind(i)),i.toolbar},_toolbarClick:function(t){var n=e(t.target).data("command"),i=e(t.target).data("options");i=e(t.target).val()||i,n&&this.executeCommand({command:n,options:i})},_contentWrapper:function(){var t=this,n=e("<div></div>").addClass(v),i=e("<div></div>").addClass(_),r=e("<div></div>").addClass(b),o=e("<div></div>").addClass(g).hide(),a=s(t.header);t.canvasWrapper=i,t.canvasContainer=r,t.paneWrapper=o,i.append(r),n.height(s(t.wrapper)-a),n.append(i).append(o),t.wrapper.append(n)},_keyHandler:function(){var e=this,t=!1;e.wrapper.on("keydown"+a,(function(n){if(n.ctrlKey){switch(n.keyCode){case 48:e.executeCommand({command:"ZoomImageEditorCommand",options:"fitToScreen"}),t=!0;break;case 189:e.executeCommand({command:"ZoomImageEditorCommand",options:"zoomOut"}),t=!0;break;case 187:e.executeCommand({command:"ZoomImageEditorCommand",options:"zoomIn"}),t=!0;break;case 90:e.executeCommand({command:"UndoImageEditorCommand"}),t=!0;break;case 89:e.executeCommand({command:"RedoImageEditorCommand"}),t=!0}t&&n.preventDefault()}}))},_drawCanvas:function(){var e=this,t=e.options.imageUrl;e.drawImage(t).done((function(t){e.trigger(c,{image:t})||e.drawCanvas(t)})).fail((function(t){e.trigger(l,t)}))},_initUndoRedoStack:function(){this.undoStack=[],this.redoStack=[]},_toggleTools:function(){var e=this,t=e.redoStack.length>0,n=e.undoStack.length>0,i=!!e._image,r=!0;try{e._canvas.toDataURL()}catch(e){r=!1}e.toolbar&&e.toolbar.toggleTools({redo:t,undo:n,enable:i,canExport:r})},drawImage:function(n){var i=this,r=new e.Deferred,o=new Image;return o.onload=function(){t.ui.progress(i.canvasContainer,!1),r.resolve(o)},o.onerror=function(){t.ui.progress(i.canvasContainer,!1),r.reject(arguments)},t.ui.progress(i.canvasContainer,!0),o.src=n,r.promise()},drawCanvas:function(n){var i=this,r=e(t.template(h)(i.options.imageLabel))[0],o=r.getContext("2d");i._canvas&&e(i._canvas).remove(),i._image&&i.undoStack.push(i._image),i._canvas=r,i._ctx=o,i._image=n,r.width=n.width,r.height=n.height,o.drawImage(n,0,0),i.canvasContainer.append(r),n.height>i.canvasWrapper.height()?i.executeCommand({command:"ZoomImageEditorCommand",options:"fitToScreen"}):i.executeCommand({command:"ZoomImageEditorCommand",options:i.getZoomLevel()}),i.trigger(d,{canvas:r,ctx:o,image:n}),i._toggleTools()},getCanvasElement:function(){return this._canvas},getCurrent2dContext:function(){return this._ctx},getCurrentImage:function(){return this._image},executeCommand:function(e){var t=e.command,r=n({imageeditor:this},i(e.options)?e.options:{value:e.options}),a=new o.imageeditor.commands[t](r);if(!this.trigger(u,e))return this._toggleTools(),a.exec()},getZoomLevel:function(){return this._zoomLevel||1},destroy:function(){var e=this;e.element.off(a),e.currentPaneTool&&e.currentPaneTool.destroy(),e.toolbar&&e.toolbar.destroy(),e._upload&&e._upload.destroy(),r.fn.destroy.call(e)}});o.plugin(y)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui.Widget,r=".kendoFloatingActionButton",o=n.ui,a=n.keys,s=n.support,l=e.extend,c=n.htmlEncode,d=".",u="id",h="left",p="right",f="bottom",m="aria-disabled",g="aria-expanded",v="role",_="click",b="expand",y="collapse",w="mouseenter"+r+" mouseleave"+r,k={widget:"k-fab",text:"k-fab-text",icon:"k-fab-icon",list:"k-fab-items",listTop:"k-fab-items-top",listBottom:"k-fab-items-bottom",listTextLeft:"k-text-left",listTextRight:"k-text-right",item:"k-fab-item",itemIcon:"k-fab-item-icon",itemText:"k-fab-item-text",popup:"k-fab-popup",popupTransparent:"k-popup-transparent",disabled:"k-disabled",hover:"k-hover",focus:"k-focus"},x=({icon:e})=>n.ui.icon({icon:c(e),iconClass:"k-fab-icon"}),C=({text:e})=>`<span class="k-fab-text">${c(e)}</span>`,S=({text:e,icon:t})=>(e?`<span class="k-fab-item-text" aria-hidden="true">${c(e)}</span>`:"")+(t?n.ui.icon({icon:c(t),iconClass:"k-fab-item-icon"}):""),T=i.extend({init:function(e,t){var r=this;i.fn.init.call(r,e,t),r._wrapper(),r._content(),r._appearance(),r._renderList(),r._initPopup(),r._aria(),r._attachEvents(),n.notify(r)},options:{name:"FloatingActionButton",icon:"",text:"",items:[],themeColor:"primary",fillMode:"solid",size:"medium",rounded:"full",align:"bottom end",alignOffset:{x:16,y:16},positionMode:"fixed",visible:!0,enable:!0,enabled:!0,_classNames:[]},events:[_,b,y],_offsetMap:{start:h,end:p,top:"top",bottom:f},_reversedOffsetMap:{start:p,end:h},_getAlignment:function(){var e=this.options.align.split(" ");return{vertical:e[0],horizontal:e[1]}},_getOffset:function(){var e=this,t=e.options,n=s.isRtl(e.element),i=e._getAlignment(),r=t.alignOffset,o=n?e._reversedOffsetMap:e._offsetMap,a=n?e._offsetMap:e._reversedOffsetMap,l={};return l[e._offsetMap[i.vertical]]=r.y,l[o[i.horizontal]]=r.x,l[a[i.horizontal]]="auto",l},_wrapper:function(){var e=this;e.wrapper=e.element.addClass(k.widget),e.wrapper.css(e._getOffset())},_content:function(){var e=this,t=e.options,n=t.text,i=t.icon;e.icon(i),e.text(""!==n?n:e.element.text())},_appearance:function(){var e=this,t=e.options;e._align=t.align,e._visible=t.visible,e._enabled=t.enabled,e._updateClassNames()},_updateClassNames:function(){var t=this,n=[k.widget],i=t.options._classNames,r=t._align,o=t._visible,a=t._enabled;e(t.element[0].classList).each((function(){var e=this+"";0===e.indexOf("k-")&&-1===i.indexOf(e)&&t.element.removeClass(e)})),"string"==typeof r&&2==r.split(" ").length&&n.push("k-"+r.replace(" ","-")),!1===o&&n.push("k-hidden"),!1===a&&n.push(k.disabled),t.element.addClass(n.join(" ")),t._applyCssClasses()},_aria:function(){var e=this,t=e.element,n=e._list,i=e._enabled;t.attr(m,!i),t.attr("aria-haspopup",!!n||null),t.attr(g,!n&&null),t.attr("aria-controls",n?n.attr(u):null),n&&(n.attr(v,"menu"),n.find(d+k.item).attr(v,"menuitem").attr("tabindex",-1))},_renderList:function(){var t=this,n=t.options.items,i=document.body,r=e("<ul>").addClass(k.list);n.length&&(t._list=r.appendTo(i),n.forEach(t._renderListItem.bind(t)),r.addClass(t._getListOrientation()))},_renderListItem:function(t){var i=this,r=n.template(S),o=t.template?n.template(t.template):r,a=e("<li>").addClass(k.item);a.addClass(i._getListItemsAlignment()),a.addClass(t.cssClass),a.attr("aria-label",t.title||t.label||""),i._enableListItem(a,t.enabled),a.append(o({icon:t.icon,text:t.label})),i._list.append(a)},_enableListItem:function(e,n){e&&n!==t&&(e.toggleClass(k.disabled,!n),n?e.removeAttr(m):e.attr(m,!0))},_getListOrientation:function(){return this._getAlignment().vertical===f?k.listTop:k.listBottom},_getListItemsAlignment:function(){var e=s.isRtl(this.element),t=this._getAlignment();return"start"===t.horizontal||"center"===t.horizontal?e?k.listTextRight:k.listTextLeft:e?k.listTextLeft:k.listTextRight},_getListItemOffset:function(){var e=this,t=e.element,n=e._list.find(d+k.itemIcon),i=0;return t.length&&n.length&&!e.options.text&&(i=t.outerWidth()/2-n.first().outerWidth()/2),i},_initPopup:function(){var e,t,i=this,r=i.element,a=i.options,s=i._list;s&&(t=s.wrap("<div>").parent(),e=i._getPopupPosition(),i._popup=new o.Popup(t,l({},a.popup,{anchor:r,appendTo:t.parent(),copyAnchorStyles:!1,autosize:!1,collision:"",position:e.position,origin:e.origin,animation:{open:{effects:n.parseEffects(o.Popup.fn.options.animation.open.effects,e.flipped)}},open:i._popupOpenHandler.bind(i),close:i._popupCloseHandler.bind(i),activate:i._popupExpandHandler.bind(i),deactivate:i._popupCollapseHandler.bind(i)})),i._popup.element.addClass([k.popup,k.popupTransparent].join(" ")),i._setPopupListId())},_setPopupListId:function(){var e=this.element.attr(u);e||(e=n.guid()),this._list.attr(u,e+"-list")},_getPopupPosition:function(){var e,t,n=this.options.align,i=s.isRtl(this.element),r=i?p:h,o=i?h:p,a=!1;switch(n){case"top end":case"middle end":e="bottom "+o,t="top "+o;break;case"bottom start":case"bottom center":e="top "+r,t="bottom "+r,a=!0;break;case"bottom end":e="top "+o,t="bottom "+o,a=!0;break;default:e="bottom "+r,t="top "+r}return{origin:e,position:t,flipped:a}},_popupOpenHandler:function(){var e=this._popup,t=this._getListItemOffset();this.element.attr(g,!0),e.element.css({paddingLeft:t}),e.element.css({paddingRight:t})},_popupCloseHandler:function(){this.element.attr(g,!1)},_popupExpandHandler:function(e){this.trigger(b)&&e.preventDefault(),this._popup.element.find(d+k.item).first().trigger("focus")},_popupCollapseHandler:function(e){this.trigger(y)&&e.preventDefault()},_attachEvents:function(){var e=this,t=e._list;e.element.on(_+r,e._click.bind(e)),t&&t.on(_+r,d+k.item,e._itemClick.bind(e)).on("keydown"+r,d+k.item,e._itemKeydown.bind(e)).on(w,d+k.item,e._itemHover.bind(e))},_click:function(e){var t=this,n=t.options,i=t._popup;t.trigger(_,{event:e})?e.preventDefault():(i||n.items.length)&&(i.visible()?i.close():i.open())},_itemClick:function(t){var i,r,o,a,s=this,l=e(t.target);l&&(i=l.closest(d+k.item)).length&&(r=s.options.items[i.index()],a={sender:s,target:i,item:r},(o=r.click&&n.isFunction(r.click)?r.click:null)&&(s.element.trigger("focus"),s._popup.close(),o.call(s,a)))},_itemKeydown:function(t){var n=this,i=e(t.target),r=t.keyCode,o=n.element,s=n._popup,l=n._getAlignment().vertical===f,c=i.hasClass(k.disabled),u=n._list.children(),h=u.index(t.target);if(i.is(d+k.item)){if(t.preventDefault(),r!==a.ENTER&&r!==a.SPACEBAR||c||n._itemClick(t),!l&&r===a.DOWN||l&&r===a.UP){if(h===u.length-1)return void u.first().trigger("focus");e(u[h+1]).trigger("focus")}if(!l&&r===a.UP||l&&r===a.DOWN){if(0===h)return void u.last().trigger("focus");e(u[h-1]).trigger("focus")}r!==a.ESC&&r!==a.TAB||(s.close(),o.trigger("focus")),r===a.HOME&&u.first().trigger("focus"),r===a.END&&u.last().trigger("focus")}},_itemHover:function(t){var i=e(n.eventTarget(t)||t.target).closest(d+k.item);i.hasClass(k.item)&&(i.siblings().removeClass(k.hover),i.toggleClass(k.hover))},text:function(i){var r=this,o=r.element,a=o.find(d+k.text),s=n.template(C);return 0===arguments.length||i===t?r._text:(r.options.text=r._text=n.htmlEncode(i),o.contents().filter((function(){return 3===this.nodeType})).remove(),!1===i||null===i||""===i?(r._text="",void a.remove()):void(a.length?a.text(i):a=e(s({text:i})).appendTo(o)))},icon:function(e){var i=this,r=i.element,o=r.find(d+k.icon),a=n.template(x);return 0===arguments.length||e===t?i._icon:(i.options.icon=i._icon=n.htmlEncode(e),!1===e||null===e||""===e?(i._icon="",void o.remove()):(o.remove(),void r.prepend(a({icon:e}))))},themeColor:function(e){if(e===t)return this.options.themeColor;this.setOptions({themeColor:e})},hide:function(){var e=this;e.options.visible=e._visible=!1,e._updateClassNames()},show:function(){var e=this;e.options.visible=e._visible=!0,e._updateClassNames()},enable:function(e){var n=this;e===t&&(e=!0),n.options.enabled=n._enabled=e,n._updateClassNames(),n.element.attr(m,!e)},setOptions:function(e){var t=this;i.fn.setOptions.call(t,e),t.element.removeAttr("style"),t.element.css(t._getOffset()),t._content(),t._appearance(),(e.align||e.items)&&(t.element.off(r),t.destroyPopup(),t._renderList(),t._initPopup(),t._attachEvents()),t._aria()},destroyPopup:function(){var e=this;e._popup&&(e._list.off(r),e._list.remove(),e._list=null,e._popup.destroy(),e._popup=null)},destroy:function(){var e=this;e.destroyPopup(),e.element.off(r),i.fn.destroy.call(e)}});n.cssProperties.registerPrefix("FloatingActionButton","k-fab-"),n.cssProperties.registerValues("FloatingActionButton",[{prop:"fillMode",values:["solid"]},{prop:"themeColor",values:["primary","secondary","tertiary","info","success","warning","error","dark","light","inverse"]},{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),o.plugin(T)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=i.Widget,o=e.extend,a="change",s="focus",l="select",c=".",d="disabled",u="required",h=r.extend({init:function(e,t){var n=this;r.fn.init.call(n,e,t),n.options=o({},n.options,t),n._iterateMarkupItems(),n._parseItems(n.options.items),n._wrapper(),n.value(n.options.value),n._attachEvents()},options:{name:"InputGroupBase"},events:[a,s,l],ITEM_TEMPLATE:"",NS:".kendoInputGroupBase",groupStyles:{},destroy:function(){var t=this;this.items().each((function(t,i){var r=n.widgetInstance(e(i));r&&r.destroy()})),t.element.off(t.NS),r.fn.destroy.call(t)},item:function(t){if(this._indexIsPresent(t))return e(this.items().get(t))},items:function(){return this.wrapper.find(c+this.groupStyles.input)},enable:function(e){var t;!1!==e&&!0!==e||(t=this.element.find(c+this.groupStyles.item),this._disabledOnElements(t,!e))},enableItem:function(t,n){if(!1===t||!0===t){if(this._indexIsPresent(n))n=e(this.element.find(c+this.groupStyles.item).get(n));else{if(!(n instanceof jQuery))return;if(n.is("input"))n=n.closest(c+this.groupStyles.item);else if(!n.is("li"))return}this._disabledOnElements(n,!t)}},value:function(){return!1},_attachEvents:function(){var e=this;e.element.on(s+e.NS,c+e.groupStyles.input,e._focusHandler.bind(e)).on(a+e.NS,c+e.groupStyles.input,e._changeHandler.bind(e)).on("click"+e.NS,c+e.groupStyles.input,e._clickHandler.bind(e))},_clickHandler:function(t){var n=e(t.target);this.trigger(l,{target:n})&&(t.preventDefault(),t.stopPropagation(),this._targetForPreventedChange=t.target)},_changeHandler:function(){return!1},_dataValRequired:function(){return!1},_disabledOnElements:function(e,t){var n=e.find("input");t?(n.attr(d,""),e.addClass(this.groupStyles.disabled)):(n.prop(d,!1),e.removeClass(this.groupStyles.disabled))},_focusHandler:function(t){var n=e(t.target);this.trigger(s,{target:n})},_indexIsPresent:function(e){return!isNaN(e)&&null!==e&&!0!==e&&!1!==e&&this.wrapper.find(c+this.groupStyles.input).length>e},_initializeItem:function(t,n){var i=e(this.wrapper.find(c+this.groupStyles.item).get(n)||this.ITEM_TEMPLATE);this._preInitItem(t,i),this._initItem(t,i),this._postInitItem(t,i)},_preInitItem:function(e,n){var i=n.find(c+this.groupStyles.label),r=n.find(c+this.groupStyles.input);0===n.closest(c+this.groupStyles.list).length&&this.element.append(n),null!==e.value&&e.value!==t&&r.val(e.value),e.id&&(r.attr("id",e.id),i.attr("for",e.id))},_initItem:function(t,n){var i=n.find(c+this.groupStyles.label),r=n.find(c+this.groupStyles.input),o=e.extend({},t,{rounded:this.options.inputRounded,size:this.options.inputSize});delete o.name,t.label&&i.length>0&&i.remove(),r[this.COMPONENT](o)},_postInitItem:function(e,t){var n=t.find(c+this.groupStyles.label),i=t.find(c+this.groupStyles.input);e.name&&i.attr("name",e.name),e.labelAfter||n.after(i.parent()),e.attributes&&t.attr(e.attributes),e.cssClass&&t.addClass(e.cssClass),e.enabled||this._disabledOnElements(t,!0),e.validation&&i.attr(e.validation)},_iterateMarkupItems:function(){var e=this.element;e.children("li").length>0&&e.find("li").each(this._markupItem.bind(this))},_markupItem:function(t,n){n.querySelector("input").hasAttribute("disabled")&&e(n).addClass(this.groupStyles.disabled)},_parseItem:function(e,i){var r=this.options,a=this._items;"string"!=typeof e&&"number"!=typeof e||(e={value:e,label:e}),!1!==e.encoded&&(e.encoded=!0),"after"===r.labelPosition&&(e.labelAfter=!0),e.enabled===t&&(e.enabled=r.enabled),e.id||(e.id=n.guid()),e.name=r.inputName||this.element.attr("name")||this.element.attr("id"),a.length>i?a[i]=o({},a[i],e):a.push(e)},_parseItems:function(e){this._items||(this._items=[]),e&&e.forEach(this._parseItem.bind(this))},_validationSettings:function(){var e=this.wrapper,t=this._items,n={};e.is("[required]")&&(n.required=u,e.prop(u,!1)),e.is("[data-val=true]")&&(n["data-val"]="true",e.removeAttr("data-val")),e.is("[data-val-required]")&&(this._dataValRequired(n),e.removeAttr("data-val-required")),e.is("[data-val-server]")&&(n["data-val-server"]=e.attr("data-val-server")),Object.keys(n).length>0&&(!t||0===t.length)&&e.find("li").each((function(){t.push({})})),t.forEach((function(e){e.validation=n}))},_wrapper:function(){var e=this.wrapper=this.element,t=this._items,n=e.find("li"),i=e.find("input");e.addClass(this.groupStyles.list),"vertical"===this.options.layout?e.addClass(this.groupStyles.vertical):e.addClass(this.groupStyles.horizontal),n.length>0&&i.length>0&&(n.addClass(this.groupStyles.item),i.addClass(this.groupStyles.input),e.find("label").addClass(this.groupStyles.label)),this._validationSettings(),t.forEach(this._initializeItem.bind(this))}});i.plugin(h)}(window.kendo.jQuery);kendo;!function(){var e=window.kendo,t=e.ui,n=t.ToggleInputBase,i=n.extend({init:function(e,t){n.fn.init.call(this,e,t),t&&t.value&&t.value.length&&this.element.attr("value",t.value)},options:{name:"RadioButton",checked:null,value:"",enabled:!0,encoded:!0,label:null,size:"medium",wrapperClass:"k-radio-wrap"},RENDER_INPUT:e.html.renderRadioButton,NS:".kendoRadioButton"});e.cssProperties.registerPrefix("RadioButton","k-radio-"),t.plugin(i)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo.ui,n=t.InputGroupBase,i="checked",r="role",o=n.extend({options:{name:"RadioGroup",inputName:"",inputSize:"medium",enabled:!0,labelPosition:"after",layout:"vertical",items:[]},ITEM_TEMPLATE:'<li class="k-radio-list-item"><input type="radio" class="k-radio" ><label class="k-radio-label" ></label></li>',NS:".kendoRadioGroup",COMPONENT:"kendoRadioButton",groupStyles:{item:"k-radio-list-item",input:"k-radio",label:"k-radio-label",list:"k-radio-list",vertical:"k-list-vertical",horizontal:"k-list-horizontal",disabled:"k-disabled"},item:function(t){var n=this.wrapper.find("input:checked");return this._indexIsPresent(t)?e(this.items().get(t)):n.length?n:void 0},value:function(e){var t=this,n=t.element.find("[value='"+e+"']");if(undefined===e)return t._value;null===e&&(t._value=null,t.element.find("."+t.groupStyles.input).prop(i,!1)),n.length>0&&(t._value=e,t.element.find("."+t.groupStyles.input).prop(i,!1),n.prop(i,!0))},_changeHandler:function(t){var n=e(t.target),i=this._value;this._targetForPreventedChange!==t.target?(this._value=n.val(),this.trigger("change",{oldValue:i,newValue:this._value,target:n})):this._targetForPreventedChange=null},_dataValRequired:function(e){e["data-val-required"]=this.wrapper.attr("data-val-required")},_wrapper:function(){n.fn._wrapper.call(this),this.wrapper.find("."+this.groupStyles.item).attr(r,"none"),this.wrapper.attr(r,"radiogroup")}});t.plugin(o)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=n.InputGroupBase,r="checked",o=i.extend({options:{name:"CheckBoxGroup",inputName:"",inputRounded:"medium",inputSize:"medium",enabled:!0,labelPosition:"after",layout:"vertical",items:[]},ITEM_TEMPLATE:'<li class="k-checkbox-list-item"><input type="checkbox" class="k-checkbox" ></li>',NS:".kendoCheckBoxGroup",COMPONENT:"kendoCheckBox",groupStyles:{item:"k-checkbox-list-item",input:"k-checkbox",label:"k-checkbox-label",list:"k-checkbox-list",vertical:"k-list-vertical",horizontal:"k-list-horizontal",disabled:"k-disabled"},checkAll:function(e){var t=this,n=t.element.find("input");!0===e?(n.prop(r,!0),t._value=[],n.each((function(e,n){t._value.push(n.value)}))):!1===e&&(n.prop(r,!1),t._value=[])},value:function(e){var t,n,i,o,a=this,s=[];if(undefined===e)return a._value||(a._value=[]),a._value;if(null===e||0===e.length)return a._value=[],void a.element.find("."+a.groupStyles.input).prop(r,!1);if(e&&!(e.length<1)){for((n=a.element.find("input[value='"+e[0]+"']")).length&&s.push(e[0]),o=1;o<e.length;o++)t=a.element.find("input[value='"+e[o]+"']"),(i=n.add(t)).length>n.length&&(n=i,s.push(e[o]));a._value=s,a.element.find("."+a.groupStyles.input).prop(r,!1),n.prop(r,!0)}},_changeHandler:function(t){var n=e(t.target),i=n.val();this._targetForPreventedChange!==t.target?(this._value||(this._value=[]),n.is(":checked")?this._value.push(i):this._value=this._value.filter((function(e){return e!==i})),this.trigger("change",{target:n})):this._targetForPreventedChange=null},_dataValRequired:function(e){e["data-msg-required"]=this.wrapper.attr("data-val-required"),e["data-rule-required"]="true"}});t.cssProperties.registerPrefix("CheckBoxGroup","k-checkbox-"),t.cssProperties.registerValues("CheckBoxGroup",[{prop:"rounded",values:t.cssProperties.roundedValues.concat([["full","full"]])}]),n.plugin(o)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=n.Widget,r=e.extend,o=t.template,a=t.keys,s=e.isPlainObject,l=e.isEmptyObject,c=".kendoBottomNavigation",d=".",u="select",h=function(e){return"string"==typeof e},p={widget:"k-bottom-nav",item:"k-bottom-nav-item",navIcon:"k-bottom-nav-item-icon",icon:"k-icon",text:"k-bottom-nav-item-text",itemFlow:{vertical:"k-bottom-nav-item-flow-vertical",horizontal:"k-bottom-nav-item-flow-horizontal"},selected:"k-selected",disabled:"k-disabled",border:"k-bottom-nav-border",shadow:"k-bottom-nav-shadow",focus:"k-focus"},f={item:o((()=>`<span class="${p.item}"></span>`)),anchor:o((({url:e})=>`<a class="${p.item}"  href="${t.htmlEncode(e)}"></a>`)),text:o((({text:e})=>`<span class="${p.text}" >${e}</span>`)),icon:o((({icon:n})=>t.ui.icon(e(`<span class="${p.navIcon}"></span>`),{icon:n,size:"xlarge"})))},m=i.extend({init:function(t,n){var r=this;n=n||{},i.fn.init.call(r,t,n),r.element=e(t),null===this.options.fillMode&&(this.options.fillMode=this.options.fill),r._updateCssClasses(),r._items(),r._bindEvents()},options:{name:"BottomNavigation",positionMode:"fixed",items:[],themeColor:"primary",itemFlow:"vertical",fillMode:null,fill:"flat",shadow:!1,border:!0,template:null},events:[u],destroy:function(){this.element.off(c),i.fn.destroy.call(this)},_tabindex:function(e){var n=this.element,i="tabindex",r=n.attr("data-"+t.ns+i),o=e.attr(i)||n.attr(i)||r;r||(n.removeAttr(i),n.attr("data-"+t.ns+i,o)),e.attr(i,isNaN(o)?0:o)},_updateCssClasses:function(){var e=this,n=e.options,i=p;e.element.removeClass((function(t,n){0===n.indexOf("k-")&&e.element.removeClass(n)})),e.element.addClass(i.widget),e.element.addClass(t.getValidCssClass("k-pos-","positionMode",n.positionMode)),e.element.toggleClass(i.border,n.border),e.element.toggleClass(i.shadow,n.shadow),e._itemFlow(n.itemFlow),e._applyCssClasses()},_itemFlow:function(e){var t=p.itemFlow;this._toggleClassGroup(this.element,e,t)},_toggleClassGroup:function(e,t,n){if(h(n[t])){for(var i in n)e.removeClass(n[i]);e.addClass(n[t])}},_items:function(){for(var e,t=this,n=t.options.items,i=0;i<n.length;i++)e=t._renderItem(n[i]),t.element.append(e)},_renderItem:function(n){var i,a,s=n.template||this.options.template,l=n.url&&h(n.url);return(i=e(l?o(f.anchor)(n):o(f.item)(n))).toggleClass(p.selected,!0===n.selected).toggleClass(p.disabled,!1===n.enabled).addClass(n.cssClass).attr(r({},n.attributes,{"aria-disabled":!1===n.enabled})).data(n.data),this._tabindex(i),i.attr("role")||l||i.attr("role","link"),s?(i.append(o(s)(n)),i):(n=r({},{icon:""},n),a=e(f.icon(n)).addClass(n.iconClass),i.append(a),n.text&&(n.text=!1===n.encoded?n.text:t.htmlEncode(n.text),i.append(e(f.text(n)))),i)},_bindEvents:function(){var e=this,t=e._click.bind(e),n=e._keydown.bind(e);e.element.on("click"+c,d+p.item,t).on("keydown"+c,d+p.item,n)},_click:function(t){var n=e(t.target).closest(d+p.item);n.is(d+p.disabled)?t.preventDefault():this._triggerSelect(n,t)},_triggerSelect:function(e,t){e.is(d+p.disabled)||this.trigger(u,{originalEvent:t,item:e,data:e.data()})||this.select(e)},_keydown:function(t){var n=e(t.target),i=t.keyCode;i!==a.ENTER&&i!==a.SPACEBAR||this._isItem(n)&&(this._triggerSelect(n,t),i===a.SPACEBAR&&t.preventDefault())},_isItem:function(t){return(t=e(t)).is(d+p.item)&&!!this.element.find(t).length},items:function(){return this.element.children()},select:function(t,n){var i=this.items().filter(d+p.selected);if(!t)return i;n=!1!==n,this._isItem(t)&&(i.removeClass(p.selected),e(t).toggleClass(p.selected,n))},enable:function(t,n){n=!1===n,t&&this._isItem(t)&&(e(t).toggleClass(p.disabled,n),e(t).attr("aria-disabled",n))},item:function(e){return isNaN(e)?null:this.items().eq(e)},itemById:function(e){return this.element.find("#"+e)},add:function(t,n){var i=this,r="append",o=i.element;n&&i._isItem(n)&&(r="before",o=e(n)),t&&s(t)&&!l(t)&&o[r](i._renderItem(t))},remove:function(e){e&&this._isItem(e)&&e.remove()},showText:function(e){e=!1!==e,this.items().find(d+p.text).toggle(e)},setOptions:function(e){var t=this;i.fn.setOptions.call(this,e),t._updateCssClasses(),("items"in e||"template"in e)&&(t.element.empty(),t._items())}});n.plugin(m),t.cssProperties.registerPrefix("BottomNavigation","k-bottom-nav-")}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=n.Widget,r=i.extend({init:function(t,n){var r=this;i.fn.init.call(r,t,n),r.element=e(t).addClass("k-skeleton-container"),r._setWrapperStyles(),r._initItems(),r._initTemplate(),r._aria()},options:{name:"SkeletonContainer",animation:"pulse",grid:null,template:null,height:"",width:""},setOptions:function(e){t.deepExtend(this.options,e),this.element.empty(),this.init(this.element,this.options)},getOptions:function(){return e.extend(!0,{},this.options)},_aria:function(){this.element.attr({role:"alert","aria-live":"polite","aria-label":t.ui.progress.messages.loading})},_initItems:function(){if(this.options.grid)for(var n,i,r,o=this.options.grid.items,a=0;a<o.length;a++)i=o[a],r=e("<div></div>"),n=i.shape.toLowerCase(),r.css({"grid-column":t.format("{0} / span {1}",i.colStart,i.colSpan),"grid-row":t.format("{0} / span {1}",i.rowStart,i.rowSpan)}).addClass("k-skeleton").addClass(t.format("k-skeleton-{0}","rectangle"===n?"rect":n)),r.appendTo(this.element)},_initTemplate:function(){if(this.options.template&&!this.options.grid){var e=t.template(this.options.template)({});e=e.replace(/data-animation/gi,"k-skeleton").replace(/data-shape/gi,"k-skeleton").replace(/k-skeleton-rectangle/gi,"k-skeleton-rect"),this.element.append(e),this._addClasses()}},_addClasses:function(){for(var e=["circle","rect","text"],t=["wave","pulse"],n=0;n<e.length;n++)this.element.find("[k-skeleton-"+e[n]+"]").removeAttr("k-skeleton-"+e[n]).addClass("k-skeleton k-skeleton-"+e[n]);for(var i=0;i<t.length;i++)this.element.find("[k-skeleton-"+t[i]+"]").removeAttr("k-skeleton-"+t[i]).addClass("k-skeleton-"+t[i])},_setWrapperStyles:function(){var e=this,n=e.options,i=n.grid,r=n.animation.toLowerCase();i&&e.element.css({"grid-template-columns":t.format("repeat({0}, 1fr)",i.columns),"grid-template-rows":t.format("repeat({0}, 1fr)",i.rows),"column-gap":(i.gap||{}).columns+"px","row-gap":(i.gap||{}).rows+"px"}).addClass("k-d-grid"),e.element.css({width:"string"==typeof n.width?n.width:n.width+"px",height:"string"==typeof n.height?n.height:n.height+"px"}),"none"!==r&&e.element.addClass("wave"==r?"k-skeleton-wave":"k-skeleton-pulse")}});n.plugin(r)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=t.Observable,r=t.htmlEncode,o=e.extend,a=".",s=".kendoTaskBoardColumn",l="click",c="action";function d(e){e.preventDefault()}var u=i.extend({init:function(e,t){var n=this;n._dataItem=t,n.options=o(!0,{},e),n.sortableUniqueClass=n.options.sortableIdentifier+u.styles.sortableSuffix,n._render(),n._attachEvents(),e.states.isReorderable&&n._initSortable(),i.fn.init.call(n)},empty:function(){this.container.empty()},addCard:function(e){this.container.append(e)},edit:function(){var e=u.styles;this.element.addClass(e.editColumn),this._renderEditHeader()},getDataItem:function(){return this._dataItem},cards:function(){return this.container.children()},template:e=>`<div class="${r(e.styles.headerText)} ${r(e.styles.ellipsis)}">${t.getter(e.dataTextField)(e)}</div><span class="${r(e.styles.spacer)}"></span>${e.buttons}`,editTemplate:e=>`<div class="${r(e.styles.headerText)} ${r(e.styles.ellipsis)}"><span class="${r(e.styles.textbox)}"><input class="${r(e.styles.input)}" placeholder="${r(t.getter(e.dataTextField)(e)?e.messages.editColumn:e.messages.newColumn)}" ${r(t.attr("command"))}="SaveColumnCommand" value="${r(t.getter(e.dataTextField)(e))}" /></span></div><span class="${r(e.styles.spacer)}"></span>${e.buttons}`,actionButton:({styles:e,icon:n,spriteCssClass:i,text:o,command:a,options:s})=>t.html.renderButton(`<button class="${r(e.actionButton)}" title="${r(o)}" ${r(t.attr("command"))}="${r(a)}" ${s?r(t.attr("options"))+"="+r(s):""}></button>`,{icon:r(n),iconClass:`k-button-icon ${r(i)}`,fillMode:"flat"}),builtinButtons:{editColumn:{name:"editColumn",icon:"pencil",text:"Edit Column",command:"EditColumnCommand",rules:"isEditable"},addCard:{name:"addCard",icon:"plus",text:"Add Card",command:"AddCardCommand",rules:"isEditable"},deleteColumn:{name:"deleteColumn",icon:"x",text:"Delete Column",command:"DeleteColumnCommand",rules:"isEditable"}},defaultButtons:["editColumn","addCard","deleteColumn"],_render:function(){var n=this,i=u.styles,r=t.guid(),o=e("<div class='"+i.element+"'></div>").attr(t.attr("uid"),n._dataItem.uid).css({width:n.options.width}).attr("role","list").attr("aria-labelledby",r),a=e("<div class='"+i.header+"'></div>"),s=e("<div class='"+i.cardsContainer+"'></div>"),l=e("<div class='"+i.columnCards+"'></div>");n.header=a.appendTo(o).attr("id",r),n._renderHeader(),s.appendTo(o),n.container=l.appendTo(s).addClass(n.sortableUniqueClass),n.element=o},_renderHeader:function(){var e=this,n=u.styles,i=e.options,r=i.template?i.template:e.template;e.header.append(t.template(r)(o(!0,{},{styles:n,buttons:e._buildActionsHtml(),dataTextField:i.dataTextField},e._dataItem)))},_renderEditHeader:function(){var e=this,n=u.styles,i=e.options,r=i.editTemplate?i.editTemplate:e.editTemplate;e.header.html(""),e.header.append(t.template(r)(o(!0,{},{styles:n,messages:i.messages,buttons:e._buildActionsHtml(),dataTextField:i.dataTextField},e._dataItem))),setTimeout((function(){e.header.find("input").trigger("focus")}),0),e.header.find(a+n.actions).addClass(n.disabled)},_buildActionsHtml:function(){for(var n=this,i=n.options,r=i.messages,a=i.buttons||n.defaultButtons,s=u.styles,l="<div class='"+s.actions+"'>",c=0;c<a.length;c++){var d=a[c];"string"==typeof(d=e.isPlainObject(d)&&1===Object.keys(d).length&&d.name?d.name:d)?d=o(!0,{},n.builtinButtons[d]||{spriteCssClass:d,command:d+"Command"},{text:r[d]||d}):e.isPlainObject(d)&&d.name&&(d=o(!0,d,{text:r[d.name]})),n._validateRules(d)&&(d.spriteCssClass=d.spriteCssClass||"",l+=t.template(n.actionButton)(o(!0,{},{styles:s,options:!1},d)))}return l+="</div>"},_validateRules:function(e){var t=this.options.states,n=e.rules?e.rules.split(";"):[];if(!n.length)return!0;for(var i=0;i<n.length;i++)if(!t[n[i]])return!1;return!0},_actionClick:function(n){var i=e(n.target).closest("["+t.attr("command")+"]"),r=i.attr(t.attr("command")),a=i.attr(t.attr("options"));a="string"==typeof a?{value:a}:a,r&&this.trigger(c,{command:r,options:o({target:i},a)})},_textboxBlur:function(n){var i=e(n.target).closest("["+t.attr("command")+"]"),r=i.attr(t.attr("command")),a=i.attr(t.attr("options"));a="string"==typeof a?{value:a}:a,r&&this.trigger(c,{command:r,options:o({target:i},a)})},_attachEvents:function(){var e=this;e.header.on(l+s,a+u.styles.actionButton,e._actionClick.bind(e)),e.header.on("blur"+s,a+u.styles.input,e._textboxBlur.bind(e)),e.header.on("keyup"+s,a+u.styles.input,(function(n){n.keyCode===t.keys.ENTER&&e._textboxBlur(n)})),e.container&&(e.container.on(l+s,a+u.styles.card+" ["+t.attr("command")+"]",e._actionClick.bind(e)),e.container.on(l+s,a+u.styles.card+" a."+u.styles.cardTitle,d))},_initSortable:function(){var t=this,i=t.options.states.isRtl?" k-rtl":"",r=t.container;t.container&&(t.sortable=new n.Sortable(r,{ignore:a+u.styles.ignoreDrag+" *",connectWith:a+t.sortableUniqueClass,filter:a+u.styles.card,hint:function(e){return e.clone().addClass(u.styles.dragHint+" "+u.styles.grabbingCursor+i).css({width:e[0].offsetWidth,height:e[0].offsetHeight})},placeholder:function(t){return e("<div></div>").addClass(u.styles.dragPlaceholder).css({height:t[0].offsetHeight})},move:t._move.bind(t),start:t._start.bind(t),end:t._end.bind(t),change:t._change.bind(t)}),t.sortable.draggable.userEvents.unbind("select"),t.sortable.draggable.userEvents.bind("select",t._select.bind(t)))},_select:function(t){for(var n=u.ignoreDragSelectors,i=e(t.event.target),r=0;r<n.length;r++)if(i.is(n[r])){t.preventDefault();break}},_move:function(e){o(e,{columnElement:e.sender.element.parents(a+u.styles.element)}),this.trigger("move",e)},_start:function(e){o(e,{columnElement:e.sender.element.parents(a+u.styles.element)}),this.trigger("moveStart",e)},_end:function(e){o(e,{columnElement:e.sender.element.parents(a+u.styles.element)}),this.trigger("moveEnd",e)},_change:function(e){o(e,{columnElement:e.sender.element.parents(a+u.styles.element)}),this.trigger("change",e),("receive"===e.action&&e.newIndex>=0||"sort"===e.action&&e.newIndex!==e.oldIndex)&&this.trigger(c,{command:"MoveCardCommand",options:e})},destroy:function(){var e=this;e.header.off(s),e.container.off(s),e.sortable&&e.sortable.destroy()}}),h=u.extend({_render:function(){var n=this,i=u.styles,r=e("<div class='"+i.element+"'></div>").addClass(i.newColumn).attr(t.attr("uid"),n._dataItem.uid),o=e("<div class='"+i.header+"'></div>");n.header=o.appendTo(r),n._renderEditHeader(),n.element=r}});o(t.ui,{taskboard:{Column:u,NewColumn:h}}),o(!0,t.ui.taskboard.Column,{styles:{element:"k-taskboard-column",header:"k-taskboard-column-header",headerText:"k-taskboard-column-header-text",ellipsis:"k-text-ellipsis",spacer:"k-spacer",actions:"k-taskboard-column-header-actions",cardsContainer:"k-taskboard-column-cards-container",columnCards:"k-taskboard-column-cards",actionButton:"k-taskboard-column-action-button",card:"k-taskboard-card",cardTitle:"k-card-title",sortableSuffix:"-kendosortable",textbox:"k-textbox k-input k-input-md k-rounded-md k-input-solid",input:"k-input-inner",newColumn:"k-taskboard-column-new",editColumn:"k-taskboard-column-edit",disabled:"k-disabled",dragPlaceholder:"k-taskboard-drag-placeholder",dragHint:"k-taskboard-drag-hint",ignoreDrag:"k-taskboard-drag-ignore",grabbingCursor:"k-cursor-grabbing"},ignoreDragSelectors:["img"]})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Observable,i=t.htmlEncode,r=e.extend,o=n.extend({init:function(e,t,i){var o=this;o._dataItem=t,o.resources=i,o.options=r(!0,{},e),o._render(),n.fn.init.call(o)},contentTemplate:e=>`<div class="${i(e.styles.header)} ${i(e.styles.hbox)}"><a class="${i(e.styles.title)} ${i(e.styles.link)}" href="#" ${e.selectable?t.attr("command")+"=SelectCardCommand":""}>${i(t.getter(e.dataTitleField)(e))}</a><span class="${i(e.styles.spacer)}"></span>${e.cardMenuButton}</div><div class="${i(e.styles.body)}"><p>${i(t.getter(e.dataDescriptionField)(e))}</p></div>`,cardMenuButtonTemplate:({styles:e})=>`<div class="${i(e.headerActions)}"><button aria-label="menu" class="${i(e.button)} ${i(e.flatButton)} ${i(e.cardMenuButton)}">`+t.ui.icon({icon:i(e.actionsIcon),iconClass:"k-button-icon"})+"</button></div>",_render:function(){var n,i=this,a=i.options,s=o.styles,l=a.template||i.contentTemplate,c=e("<div class='"+s.element+" "+s.card+" "+s.moveCursor+"'></div>"),d=a.cardMenu?i.cardMenuButtonTemplate:"",u=i._resources(i._dataItem),h=a.states.isRtl?"borderRightColor":"borderLeftColor";c.attr(t.attr("uid"),i._dataItem.uid).attr("aria-disabled",!a.states.isDisabled).attr("role","listitem").toggleClass(s.disabled,a.states.isDisabled),(n=u[a.dataCategoryField]&&u[a.dataCategoryField].color||i._dataItem.get(a.dataCategoryField))&&c.addClass(s.categoryBorder).css(h,n),c.append(t.template(l)(r(!0,{},{styles:s,cardMenuButton:t.template(d)({styles:s}),selectable:a.states.isSelectable,resources:u,dataTitleField:a.dataTitleField,dataDescriptionField:a.dataDescriptionField},i._dataItem))),i.element=c},_resources:function(e){var n=this,i={};if(!n.resources)return i;for(var r in n.resources){var o=n.resources[r],a=o.field,s=t.getter(a)(e);if(s){o.multiple||(s=[s]);for(var l=o.dataSource.view(),c=0;c<s.length;c++){var d=null,u=s[c];o.valuePrimitive||(u=t.getter(o.dataValueField)(u));for(var h=0;h<l.length;h++)if(l[h].get(o.dataValueField)==u){d=l[h];break}if(null!==d){var p=t.getter(o.dataColorField)(d),f={field:o.field,title:o.title,name:o.name,text:t.getter(o.dataTextField)(d),value:u,color:p};o.multiple?i[o.field]?i[o.field].push(f):i[o.field]=[f]:i[o.field]=f}}}}return i},_buildTemplate:function(){var e=this,n=e.options;return t.format(e.headerTemplate,n.dataTitleField)+t.format(e.bodyTemplate,n.dataDescriptionField)}});r(t.ui.taskboard,{Card:o}),r(!0,t.ui.taskboard.Card,{styles:{element:"k-taskboard-card",card:"k-card",header:"k-card-header",hbox:"k-hbox",title:"k-card-title",link:"k-link",spacer:"k-spacer",button:"k-button",cardMenuButton:"k-taskboard-card-menu-button k-icon-button",flatButton:"k-button-md k-rounded-md k-button-flat k-button-flat-base",body:"k-card-body",actionsIcon:"more-vertical",moveCursor:"k-cursor-move",categoryBorder:"k-taskboard-card-category",headerActions:"k-card-header-actions",disabled:"k-disabled"}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=(t.template,t.ui.ContextMenu),r=t.htmlEncode,o="action",a=i.extend({init:function(e,t){var n=this;i.fn.init.call(n,e,t),n._overrideTemplates(),n._extendItems(),n.bind("select",n._onSelect.bind(n)),n.bind("open",n._onOpen.bind(n)),n.bind("activate",n._focus.bind(n))},_overrideTemplates:function(){this.templates.sprite=({icon:e,spriteCssClass:n})=>`${e||n?t.ui.icon({icon:r(e||""),iconClass:r(n||"")}):""}`},defaultItems:{editCard:{name:"editCard",text:"Edit card",icon:"pencil",command:"EditCardCommand",rules:"isEditable"},deleteCard:{name:"deleteCard",text:"Delete card",icon:"trash",command:"DeleteCardCommand",rules:"isEditable"}},events:i.fn.events.concat([o]),_extendItems:function(){var t,n=this,i=n.options.items;if(i&&i.length)for(var r=0;r<i.length;r++)t=i[r],e.isPlainObject(t)&&1===Object.keys(t).length&&t.name&&(t=t.name),e.isPlainObject(t)?n._append(t):n.defaultItems[t]?(t=n.defaultItems[t],n._append(t)):"string"==typeof t&&(t={name:t,text:t,spriteCssClass:t,command:t+"Command"},n._append(t));else for(var o in n.defaultItems)t=n.defaultItems[o],n._append(t)},_append:function(e){var t=this;t._extendItem(e),t._validateRules(e)&&t.append(e)},_extendItem:function(e){var i=this.options.messages,r={};r[t.attr("command")]=e.command,e.options&&(r[t.attr("options")]=e.options),n(e,{text:i[e.name],icon:e.icon||"",spriteCssClass:e.spriteCssClass||"",attr:r,uid:t.guid()})},_validateRules:function(e){var t=this.options.states,n=e.rules?e.rules.split(";"):[];if(!n.length)return!0;for(var i=0;i<n.length;i++)if(!t[n[i]])return!1;return!0},_onSelect:function(i){var r=e(i.item).attr(t.attr("command")),o=e(i.item).attr(t.attr("options")),a=e(i.target);o="string"==typeof o?{value:o}:o,r&&this.action({command:r,options:n({target:a},o)})},_onOpen:function(t){!t.sender.options.items&&e.isEmptyObject(this.defaultItems)&&t.preventDefault()},_focus:function(e){e.sender&&e.sender.element.trigger("focus")},action:function(e){this.trigger(o,e)}});n(t.ui.taskboard,{CardMenu:a})}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=e.isPlainObject,r=t.Class.extend({init:function(e){this.options=e,this.taskboard=e.taskboard},_confirm:function(t,r,o,a){var s,l=this.taskboard.options;if(i(l.editable)&&!1===l.editable.confirmation){var c=e.Deferred();return c.resolve(),c}return(s=e("<div></div>").kendoConfirm(n({},{title:t,content:r,messages:{okText:o,cancel:a},buttonLayout:"normal"})).data("kendoConfirm")).open(),setTimeout((function(){s.element.trigger("focus")})),s.result}}),o=r.extend({exec:function(){var e=this.taskboard;e.trigger("editColumn",{column:null})||(e.columns().each((function(t,n){e.enableByColumn(n,!1)})),e.addColumn())}}),a=r.extend({exec:function(){var e=this.options,t=this.taskboard;t.trigger("editColumn",{column:e.column})||(t.columns().each((function(e,n){t.enableByColumn(n,!1)})),t.editColumn(e.columnElement))}}),s=r.extend({exec:function(){var e=this,t=e.options,n=e.taskboard,i=n.options.messages,r=n.columnsDataSource;e._confirm(i.deleteColumn,i.deleteColumnConfirm,i.delete,i.cancel).done((function(){n.trigger("deleteColumn",{column:t.column})?n.dataSource.cancelChanges():(r.remove(t.column),r.sync())}))}}),l=r.extend({exec:function(){var e=this.options,t=this.taskboard,n=t.options.columnSettings,i=t.columnsDataSource,r=e.column,o=e.target.val();t.trigger("saveColumn",{column:e.column})?t.dataSource.cancelChanges():(r.set(n.dataTextField,o),i.sync())}}),c=r.extend({exec:function(){this.taskboard.columnsDataSource.cancelChanges()}}),d=r.extend({exec:function(){var e,t,n=this,i=n.taskboard,r=n.options,o=r.cardElement,a=r.columnElement,s=i.columns(),l=a.index(),c=r.value;switch(c){case"left":e=Math.max(0,l-1);break;case"right":e=Math.min(s.length-1,l+1);break;default:e=l}n.columns=s,n.columnIndex=e,n.column=t=i._getColumnByElement(s.eq(e)),n.cards=t.cards(),o?n._moveFromCardFocus(c,o):a&&"down"===c?n.cards.eq(0).trigger("focus"):s.eq(e).trigger("focus")},_moveFromCardFocus:function(e,t){var n,i,r=this,o=t.index(),a=!1;switch(e){case"up":i=o-1;break;case"down":i=o+1;break;default:a=!0,i=o}!(n=r.cards.eq(i)).length&&a&&(n=r._getFocusableCard(i,e)),i>=0?n.trigger("focus"):r.options.columnElement.focus()},_getFocusableCard:function(e,t){var n=this,i=n.cards.length-1,r=n.cards.eq(Math.min(e,i));if(r.length)return r;if(!(n.columnIndex<=0||n.columnIndex>=n.columns.length-1)){switch(t){case"left":n.columnIndex=Math.max(0,n.columnIndex-1);break;case"right":n.columnIndex=Math.min(n.columns.length-1,n.columnIndex+1)}return n.column=n.taskboard._getColumnByElement(n.columns.eq(n.columnIndex)),n.cards=n.column.cards(),n._getFocusableCard(e,t)}}}),u=r.extend({_updateOrder:function(e,t){var n,i=this.taskboard,r=i.options.dataOrderField,o=this.options,a=o.card,s=o.cardElement?o.cardElement.index():e.cards().length,l=t,c=e.cards().map((function(e,t){return i.dataItem(t)})),d=c[s-1];a.set(r,l),d&&d.get(r)>=a.get(r)&&a.set(r,d.get(r)+1);for(var u=l+1;u<c.length&&(n=c[u]).get(r)<=a.get(r);u++)n.set(r,a.get(r)+1),a=n}}),h=r.extend({exec:function(){var e=this.taskboard,t=this.options.cardElement;e._select(t,!0),t.focus()}}),p=u.extend({exec:function(){var t=this,n=t.taskboard,i=n.options,r=t.options,o=r.card.get(i.dataStatusField),a=n._getColumn(o),s=e(document.activeElement);s.length&&s.trigger("change"),n.pane&&n.pane.form&&!n.pane.form.validate()||(n.trigger("saveCard",{card:r.card})?n.dataSource.cancelChanges():(a&&i.dataOrderField&&t._updateOrder(a,r.card.get(i.dataOrderField)),n.dataSource.sync().then((function(){n.columns().eq(0).trigger("focus")}))))}}),f=r.extend({exec:function(){var e=this,t=e.taskboard,n=t.options.messages,i=e.options;e._confirm(n.deleteCard,n.deleteCardConfirm,n.delete,n.cancel).done((function(){t.trigger("deleteCard",{card:i.card})?t.dataSource.cancelChanges():(t.dataSource.remove(i.card),t.dataSource.sync().then((function(){t.columns().eq(0).trigger("focus")})))})).fail((function(){i.cardElement.trigger("focus")}))}}),m=u.extend({exec:function(){var e=this,t=e.taskboard,n=t.options,i=n.columnSettings,r=e.options,o=r.column.get(i.dataStatusField);r.card.set(n.dataStatusField,o),n.dataOrderField&&e._updateOrder(t._getColumn(o),r.newIndex),t.dataSource.sync()}}),g=r.extend({exec:function(){var e=this.taskboard,t=this.options;e.trigger("editCard",{card:t.card})||e._openPane(n({pane:"Edit"},t))}}),v=r.extend({exec:function(){var e=this.taskboard,t=this.options;e.trigger("editCard",{card:null})||(e.dataSource.cancelChanges(),e._openPane(n({pane:"Create"},t)))}}),_=r.extend({exec:function(){var e=this.options;this.taskboard._openPane({pane:e.value,card:e.card,cardElement:e.cardElement,column:e.column,columnElement:e.columnElement})}}),b=r.extend({exec:function(){var e=this.taskboard;e._closePane(),e.dataSource.cancelChanges()}}),y=r.extend({exec:function(){var e,t=this,n=t.options.value,i=t.taskboard,r=i.options,o=r.search,a=o.operator,s=o&&o.fields||[r.dataTitleField,r.dataDescriptionField];e=t._buildFilters(s,a,n),i.dataSource.filter(e)},_buildFilters:function(e,t,n){return{logic:"or",filters:e.map((function(e){return{field:e,operator:t,value:n}}))}}});n(t.ui.taskboard,{Command:r,commands:{AddColumnCommand:o,EditColumnCommand:a,DeleteColumnCommand:s,SaveColumnCommand:l,CancelEditColumnCommand:c,OpenPaneCommand:_,ClosePaneCommand:b,SelectCardCommand:h,MoveFocusCommand:d,SaveChangesCommand:p,DeleteCardCommand:f,MoveCardCommand:m,EditCardCommand:g,AddCardCommand:v,SearchCommand:y}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=e.extend,i=t.Observable,r=t.htmlEncode,o=t.ui.Form,a=".kendoTaskBoardPane",s=i.extend({init:function(e,r,o,s){var l=this;l.taskboard=e,l._dataItem=o,l.resources=s,l.options=n(!0,{},r),l._render(),l.element.on("click"+a,"["+t.attr("command")+"]",l._commandClick.bind(l)),i.fn.init.call(l)},headerTemplate:({styles:e,messages:n,fieldFormat:i})=>`<div class="${r(e.headerText)}">${i}</div><span class="${r(e.spacer)}"></span><div class="${r(e.headerActions)}">`+t.html.renderButton(`<button title="${r(n.close)}" ${r(t.attr("command"))}="ClosePaneCommand"></button>`,{icon:"x",iconClass:"k-button-icon",fillMode:"flat"})+"</div>",buttonTemplate:({styles:e,icon:n,spriteCssClass:i,text:o,fillMode:a,themeColor:s,command:l,options:c})=>t.html.renderButton(`<button title="${r(o)}" ${r(t.attr("command"))}="${r(l)}" ${r(t.attr("options"))}="${r(c)}">${r(o)}</button>`,{icon:r(n),iconClass:`k-button-icon ${r(i)}`,fillMode:a,themeColor:s}),contentTemplate:()=>"",builtinButtons:{edit:{name:"edit",icon:"pencil",text:"Edit",themeColor:"primary",command:"EditCardCommand",rules:"isEditable"},delete:{name:"delete",icon:"trash",text:"Delete",command:"DeleteCardCommand",rules:"isEditable",fillMode:"flat",themeColor:"primary"},cancel:{name:"cancel",icon:"cancel-outline",text:"Cancel",command:"ClosePaneCommand"},saveChanges:{name:"saveChanges",icon:"save",text:"Save",command:"SaveChangesCommand",themeColor:"primary",rules:"isEditable"},create:{name:"create",icon:"save",text:"Create",command:"SaveChangesCommand",themeColor:"primary",rules:"isEditable"}},defaultButtons:[],_render:function(){var t=this,n=s.styles,i=e("<div class='"+n.element+"'></div>"),r=e("<div class='"+n.header+"'></div>"),o=e("<div class='"+n.content+"'></div>"),a=e("<div class='"+n.footerActions+" "+n.footerActionButtons+"'></div>");t.header=r.appendTo(i),t._renderHeader(),t.content=o.appendTo(i),t._renderContent(),t.buttonsContainer=a.appendTo(i),t.buttonsContainer.append(t._buildButtonsHtml()),t.element=i},_renderHeader:function(){var e=this,i=s.styles,r=e.options,o=r.messages,a=r.headerTemplate?r.headerTemplate:e.headerTemplate,l=e._resources(e._dataItem);e.header.append(t.template(a)(n(!0,{},{styles:i,messages:o,resources:l,fieldFormat:e._buildHeaderTemplate(e._dataItem)},e._dataItem)))},_buildHeaderTemplate:function(e){return r(t.getter(this.options.dataTitleField)(e))},_renderContent:function(){var e=this,i=s.styles,r=e.options,o=r.messages,a=r.template||e.contentTemplate,l=e._resources(e._dataItem);e.content.append(t.template(a)(n(!0,{},{styles:i,messages:o,resources:l},e._dataItem)))},_resources:function(e){var n=this,i={};if(!n.resources)return i;for(var r in n.resources){var o=n.resources[r],a=o.field,s=t.getter(a)(e);if(s){o.multiple||(s=[s]);for(var l=o.dataSource.view(),c=0;c<s.length;c++){var d=null,u=s[c];o.valuePrimitive||(u=t.getter(o.dataValueField)(u));for(var h=0;h<l.length;h++)if(l[h].get(o.dataValueField)==u){d=l[h];break}if(null!==d){var p=t.getter(o.dataColorField)(d),f={field:o.field,title:o.title,name:o.name,text:t.getter(o.dataTextField)(d),value:u,color:p};o.multiple?i[o.field]?i[o.field].push(f):i[o.field]=[f]:i[o.field]=f}}}}return i},_buildButtonsHtml:function(){for(var i=this,r=i.options,o=r.messages,a=r.buttons||i.defaultButtons,l=s.styles,c="",d=0;d<a.length;d++){var u=a[d];if("string"==typeof(u=e.isPlainObject(u)&&1===Object.keys(u).length&&u.name?u.name:u)){if("spacer"===u){c+='<span class="k-spacer"></span>';continue}u=n(!0,{},i.builtinButtons[u]||{spriteCssClass:u,command:u+"Command"},{text:o[u]||u})}else e.isPlainObject(u)&&u.name&&(u=n(!0,u,{text:o[u.name]}));i._validateRules(u)&&(u.spriteCssClass=u.spriteCssClass||"",c+=t.template(i.buttonTemplate)(n(!0,{},{styles:l,messages:o,primary:!1,options:null},u)))}return c},_commandClick:function(i){var r=e(i.target).closest("["+t.attr("command")+"]"),o=r.attr(t.attr("command")),a=r.attr(t.attr("options")),s=this._dataItem;a="string"==typeof a?{value:a}:a,o&&this.trigger("action",{command:o,options:n({card:s},a)})},_validateRules:function(e){var t=this.options.states,n=e.rules?e.rules.split(";"):[];if(!n.length)return!0;for(var i=0;i<n.length;i++)if(!t[n[i]])return!1;return!0},destroy:function(){this.element.off(a),this.element.remove()}}),l=s.extend({init:function(e,i,o,a){var l=this;i=n({},i.previewPane,{dataTitleField:i.dataTitleField,dataDescriptionField:i.dataDescriptionField,messages:i.messages,states:i.states}),l.contentTemplate=e=>r(t.getter(i.dataDescriptionField)(e)),s.fn.init.call(l,e,i,o,a),l.element.addClass(s.styles.preview)},defaultButtons:["edit","spacer","delete"]}),c=s.extend({init:function(e,t,i){var r=this;t=n({},t.editable,{dataTitleField:t.dataTitleField,dataDescriptionField:t.dataDescriptionField,messages:t.messages,states:t.states}),r.formSettings=n(r.formSettings,{items:[{field:t.dataTitleField,label:t.messages[t.dataTitleField]},{field:t.dataDescriptionField,label:t.messages[t.dataDescriptionField]}]},t.form),s.fn.init.call(r,e,t,i),r.element.addClass(s.styles.edit)},defaultButtons:["saveChanges","cancel"],formSettings:{buttonsTemplate:()=>""},_buildHeaderTemplate:function(e){return`${this.options.messages.edit} ${r(t.getter(this.options.dataTitleField)(e))}`},_renderContent:function(){var i=this,r=i.options,a=s.styles,l=r.form||i.formSettings,c=t.guid(),d=e("<div></div>").attr("role","form").attr("aria-labelledby",c),u=!r.form||undefined===r.form.focusFirst||r.form.focusFirst;i.header.find("."+a.headerText).attr("id",c),i.content.append(d),i.form=new o(d,n({},l,{formData:i._dataItem,focusFirst:u}))}}),d=c.extend({init:function(e,t,i,r,o){var a=t.columnSettings.dataStatusField,s=e.columnsDataSource.view().at(0),l=o?o[a]:s[a],d=n({},i);for(var u in(i=e.dataSource.add()).set(t.dataStatusField,l),d)i.set(u,d[u]);c.fn.init.call(this,e,t,i,r)},_buildHeaderTemplate:function(e){return this.options.messages.createNewCard},defaultButtons:["create","cancel"]});n(t.ui.taskboard,{Pane:s,panes:{Preview:l,Edit:c,Create:d}}),n(!0,t.ui.taskboard.Pane,{styles:{element:"k-taskboard-pane",edit:"k-taskboard-edit-pane",preview:"k-taskboard-preview-pane",header:"k-taskboard-pane-header",headerText:"k-taskboard-pane-header-text",spacer:"k-spacer",headerActions:"k-taskboard-pane-header-actions",content:"k-taskboard-pane-content",footerActions:"k-taskboard-pane-actions",footerActionButtons:"k-actions k-hstack k-justify-content-start",baseButton:"k-button-solid-base",primaryButton:"k-button-solid-primary"}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Observable,i=e.extend,r=".kendoKeyboardManager",o=n.extend({init:function(e){var t=this;t.register={},t.element=e,t._attachEvents(),n.fn.init.call(t)},registerShortcut:function(e,t,n){var r=this;r.register[e]||(r.register[e]=[]),t.keyCode&&isNaN(t.keyCode)&&t.keyCode.toUpperCase&&(t.keyCode=t.keyCode.toUpperCase().charCodeAt(0)),r.register[e].push({shortcut:i({keyCode:null,ctrlKey:!1,shiftKey:!1,altKey:!1},t),options:n})},_attachEvents:function(){var e=this,t=e._handler.bind(e);e.element.on("keydown"+r,t)},_handler:function(t){var n,i,r=this,o=e(t.target);for(var a in r.register)if(o.is(a)&&(n=r.register[a],i=r._getAction(n,t))){r._trigger(i,t);break}},_trigger:function(t,n){var r=e(n.target);t.command&&this.trigger("action",i({},n,{command:t.command,options:i({},{target:r},t.options)})),t.handler&&t.handler(n)},_getAction:function(e,t){for(var n=0;n<e.length;n++)if(this._compareShortcut(e[n].shortcut,t))return e[n].options},_compareShortcut:function(e,t){for(var n in e){var i=!1;if("ctrlKey"===n)i=e[n]!==this._getShortcutModifier(t);else i=e[n]!==t[n];if(i)return!1}return!0},_getShortcutModifier:function(e){return navigator.platform.toUpperCase().indexOf("MAC")>=0?e.metaKey:e.ctrlKey},destroy:function(){this.element.off(r)}});i(t.ui.taskboard,{KeyboardManager:o})}(window.kendo.jQuery);var TH={wrapper:"k-taskboard",header:"k-taskboard-header",content:"k-taskboard-content",toolbar:"k-taskboard-toolbar",columnsContainer:"k-taskboard-columns-container",card:"k-taskboard-card",column:"k-taskboard-column",selected:"k-selected",disabled:"k-disabled",ignoreDrag:"k-taskboard-drag-ignore"},DH=function(e){e.preventDefault()};!function(e,t){var n=window.kendo,i=n.ui.Widget,r=n.data.DataSource,o=e.extend,a=n.ui,s=Array.isArray,l=e.isPlainObject,c="_generic",d=".",u="move",h="moveStart",p="moveEnd",f="select",m="execute",g="action",v="change",_="change",b="dataBinding",y="dataBound",w="columnsDataBinding",k="columnsDataBound",x=i.extend({init:function(e,t){var r=this;i.fn.init.call(r,e,t),e=r.wrapper=r.element,r._sortableIdentifier=r.element.attr("id")||n.guid(),r._wrapper(),r._columnsDataSource(),r._initResources(),r._dataSource(),r._initToolbar(),r._initCardMenu(),r._initKeyboard(),r.options.autoBind&&r.load(),n.notify(r)},events:[u,h,p,v,m,f,b,y,w,k,"editCard","saveCard","deleteCard","editColumn","saveColumn","deleteColumn"],options:{name:"TaskBoard",autoBind:!0,height:600,width:"100%",toolbar:!0,dataStatusField:"status",dataTitleField:"title",dataDescriptionField:"description",dataCategoryField:"category",dataOrderField:null,cardMenu:!0,editable:!0,selectable:!0,reorderable:!0,previewPane:!0,search:{operator:"contains"},dataSource:[],columns:[],columnSettings:{dataStatusField:"status",dataTextField:"text",dataOrderField:null},resources:[],messages:{edit:"Edit",createNewCard:"Create new card",create:"Create",search:"Search",previewCard:"Preview card",addCard:"Add card",editCard:"Edit card",deleteCard:"Delete Card",addColumn:"Add column",editColumn:"Edit column",deleteColumn:"Delete column",close:"Close",cancel:"Cancel",delete:"Delete",saveChanges:"Save changes",title:"Title:",description:"Description:",newColumn:"New column",deleteColumnConfirm:"Are you sure you want to delete this column?",deleteCardConfirm:"Are you sure you want to delete this card?"}},defaultTools:{addColumn:{type:"button",name:"addColumn",command:"AddColumnCommand",icon:"plus",rules:"isEditable"},spacer:{type:"spacer"},search:{type:"component",name:"search",command:"SearchCommand",options:'{ "field": "name", "operator": "startswith" }',rules:"isSearchable",overflow:"never",component:"TextBox",componentOptions:{placeholder:"search",icon:"search",commandOn:"input"}}},items:function(){var t=e([]);for(var n in this._columns)e.merge(t,this._columns[n].cards());return t},itemsByStatus:function(e){return this._getColumn(e).cards()},itemsByColumn:function(e){var t=this._getColumnByElement(e);if(t)return t.cards()},load:function(){var t=this,n=[];for(var i in t._progress(!0),n.push(t.columnsDataSource.fetch()),t.resources)n.push(t.resources[i].dataSource.fetch());e.when.apply(null,n).then(t.dataSource.read.bind(t.dataSource))},dataItem:function(t){var i,r=this.dataSource;return i=(t=e(t)).attr(n.attr("uid")),r.getByUid(i)},columnDataItem:function(t){var i,r=this.columnsDataSource;return i=(t=e(t)).attr(n.attr("uid")),r.getByUid(i)},columns:function(){var t=e([]);for(var n in this._columns)e.merge(t,this._columns[n].element);return t},columnByStatus:function(e){return this._getColumn(e).element},select:function(t,n){if(!t)return this.element.find(d+x.styles.card+d+x.styles.selected).eq(0);t=e(t),(n=!1!==n)&&this.element.find(d+x.styles.card+d+x.styles.selected).removeClass(x.styles.selected),t.toggleClass(x.styles.selected,n)},previewCard:function(e){var t=this,n=t.options,i=t._extendExecArgs({target:e});n.previewPane&&t._openPane(o({pane:"Preview"},i))},editCard:function(t){var n,i=this,r=i.options;t=e(t),n=i._extendExecArgs({target:t}),r.editable&&i._openPane(o({pane:"Edit"},n))},saveCard:function(){this.dataSource.sync()},deleteCard:function(e){var t=this,n=t.dataItem(e);t.dataSource.remove(n),t.dataSource.sync()},addCard:function(e){var t={card:e};this.options.editable&&this._openPane(o({pane:"Create"},t))},addColumn:function(e,t){var n,i,r,s=this,l=o(!0,{},s.options.columnSettings,{messages:s.options.messages,states:s._buildStates(),sortableIdentifier:s._sortableIdentifier});isNaN(e)&&!t&&(t=e,e=null),i=s.columnsDataSource._createNewModel(t),e=isNaN(e)||null===e?s.columnsDataSource.data().length:e,r=s.columns().eq(e),s.columnsDataSource.insert(e,i),n=new a.taskboard.NewColumn(l,i),isNaN(e)||!r.length?s.columnsContainer.append(n.element):r.before(n.element),n.bind(g,s.executeCommand.bind(s))},editColumn:function(t){t=e(t),this._getColumnByElement(t).edit()},saveColumn:function(){this.columnsDataSource.sync()},deleteColumn:function(e){var t=this,n=t.columnDataItem(e);t.columnsDataSource.remove(n),t.columnsDataSource.sync()},registerShortcut:function(e,t,n){this.keyboardManager.registerShortcut(e,t,n)},enable:function(t,n){(t=e(t)).toggleClass(x.styles.disabled,!1===n),t.attr("aria-disabled",!1===n)},enableByColumn:function(t,n){var i=this;t=e(t),i.itemsByColumn(t).each((function(e,t){i.enable(t,n)}))},readOnly:function(t,i){i=!1!==i,(t=e(t)).find("["+n.attr("command")+"]").toggleClass(x.styles.disabled,i),t.find("a,button").toggleClass(x.styles.disabled,i),t.toggleClass(x.styles.ignoreDrag,i),t.attr("aria-readonly",i)},readOnlyByColumn:function(t,n){var i=this;t=e(t),i.itemsByColumn(t).each((function(e,t){i.readOnly(t,n)}))},setDataSource:function(e){var t=this;t.options.dataSource=e,t._dataSource(),t.options.autoBind&&t.dataSource.read()},setColumnsDataSource:function(e){var t=this;t.options.columns=e,t._columnsDataSource(),t.options.autoBind&&t.columnsDataSource.fetch((function(){t._renderCards(t.dataSource.view())}))},_getColumn:function(e){return this._columns[e]},_getColumnByElement:function(t){var n=this;for(var i in t=e(t),n._columns)if(n._columns[i].element[0]===t[0])return n._columns[i]},_openPane:function(e){var t,i=this,r=new a.taskboard.panes[e.pane](i,o({},i.options,{states:i._buildStates()}),e.card,i.resources,e.column);i.pane&&i._closePane(),i.pane=r,i.content.after(i.pane.element),i.content.css("margin-right",i.pane.element.outerWidth()-parseInt(i.content.css("paddingRight"),10)),i.pane.bind(g,i.executeCommand.bind(i)),i.pane.keyboardManager=t=new a.taskboard.KeyboardManager(i.pane.element),t.bind(g,i.executeCommand.bind(i)),t.registerShortcut("*",{keyCode:n.keys.ESC},{command:"ClosePaneCommand"}),t.registerShortcut("*",{keyCode:n.keys.ENTER},{command:"SaveChangesCommand",options:{card:i.pane._dataItem}}),this.options.editable&&this.options.editable.form&&!1===this.options.editable.form.focusFirst&&setTimeout((function(){i.pane.element.find("button").eq(0).trigger("focus")}),0)},_closePane:function(){var e=this;e.pane&&(e.pane.keyboardManager.destroy(),e.pane.unbind(g),e.pane.destroy(),delete e.pane,e.content.css("margin-right",""))},_wrapper:function(){var t=this,n=t.options,i=x.styles,r="<div class='"+i.header+"'></div>",o="<div class='"+i.content+"'></div>",a="<div class='"+i.columnsContainer+"'></div>";t.element.addClass(i.wrapper).width(n.width).height(n.height).attr("role","application"),t.header=e(r).appendTo(t.element),t.content=e(o).appendTo(t.element),t.columnsContainer=e(a).appendTo(t.content)},_initToolbar:function(){var t,i=this,r=x.styles,o=i.options,a=e("<div class='"+r.toolbar+"'></div>"),l=s(o.toolbar)?{items:o.toolbar}:o.toolbar;!1!==o.toolbar&&(!0===l&&(l={}),t=l.items?l.items:Object.keys(i.defaultTools),t=i._processTools(t),l.tools=t,l.defaultTools=i.defaultTools,l.parentMessages=i.options.messages,i.header.append(a),i.toolbar=new n.ui.ToolBar(a,l),i.options.toolbar=i.toolbar.options,i.toolbar.bind("click",i._toolbarClick.bind(i)),i.toolbar.bind("toggle",i._toolbarClick.bind(i)),i.toolbar.bind(v,i._toolbarClick.bind(i)))},_processTools:function(e){var t,n=this,i=n._buildStates();return e.forEach((e=>{var r=e.rules||n.defaultTools[e]?n.defaultTools[e].rules:null;if(t=l(e)&&Object.keys(e).length>=1&&e.name&&n.defaultTools[e.name]){var a=o({},e);o(e,n.defaultTools[e.name],a)}if(t&&"search"==e.name&&o(e.componentOptions,{icon:e.icon||n.defaultTools[e.name].componentOptions.icon,placeholder:e.text||n.options.messages.search}),r&&(r=r.split(";")).length)for(var s=0;s<r.length;s++)i[r[s]]||(e.rules?e.hidden=!0:n.defaultTools[e].hidden=!0)})),e},_toolbarClick:function(t){var n=e(t.target).data("command"),i=e(t.target).data("options");i=o({},i,{value:e(t.target).val()}),n&&this.executeCommand({command:n,options:i})},_isToolEnabled:function(e){for(var t=this.options.toolbar.items||this.defaultTools,n=!1,i=0;i<t.length;i++)if(t[i].name==e){n=!0;break}return t[e]||n},_buildStates:function(){var e=this;return{isEditable:e._isEditable(),isReorderable:e._isReorderable(),isSelectable:e._isSelectable(),isReadOnly:!e._isReorderable()&&!e._isEditable(),isDisabled:!e._isReorderable()&&!e._isEditable()&&!e._isSelectable(),isSearchable:e._isSearchable(),notLocalColumns:!(e.columnsDataSource.transport instanceof n.data.LocalTransport),isRtl:n.support.isRtl(e.wrapper)}},_isSearchable:function(){return!!this.options.search},_isEditable:function(){return!!this.options.editable},_isReorderable:function(){return!!this.options.reorderable},_isSelectable:function(){return!!this.options.selectable},executeCommand:function(e){var t=e.command,i=o({taskboard:this},l(e.options)?this._extendExecArgs(e.options):{value:e.options}),r=a.taskboard.commands[t]&&new a.taskboard.commands[t](i);this.trigger(m,e)||(r?r.exec():window.console.warn(n.format("Trying to use {0} command, but such is not available in the kendo.ui.taskboard.commands namespace!",t)))},_extendExecArgs:function(i){var r,a,s,l,c=this,u=i.draggableEvent?i.item:i.target;return i.card&&(u=c.items().filter((function(t,r){return e(r).attr(n.attr("uid"))===i.card.get("uid")}))),u&&u&&u.length?(r=i.columnElement||(u.is(d+x.styles.column)?u:u.parents(d+x.styles.column)),s=c.columnsDataSource.getByUid(r.data(n.ns+"uid")),a=u.is(d+x.styles.card)?u:u.closest(d+x.styles.card),l=c.dataSource.getByUid(a.data(n.ns+"uid")),o(i,{card:l,cardElement:a.length?a:t,column:s,columnElement:r.length?r:t})):i},_select:function(e,t){var n=this;null===t&&(t=!0),n.trigger(f,{card:e})||(n.select(e,t),n.previewCard(e))},_columnsDataSource:function(){var e=this,t=e.options,i=t.columnSettings,o=t.columns;if(o=s(o)?{data:o}:o,i.dataOrderField&&!o.sort&&(o.sort={field:i.dataOrderField,dir:"asc"}),!o.schema){var a={};a[i.dataStatusField]={type:"string",defaultValue:function(){return n.guid().split("-")[0]}},a[i.dataTextField]={type:"string"},i.dataOrderField&&(a[i.dataOrderField]={type:"number"}),o.schema={model:{fields:a}}}e.columnsDataSource&&e._columnsChangeHandler?(e.columnsDataSource.unbind(v,e._columnsChangeHandler),e.columnsDataSource.unbind(v,e._columnsErrorHandler)):(e._columnsChangeHandler=e._columnsDataSourceChange.bind(e),e._columnsErrorHandler=e._error.bind(e)),e.columnsDataSource=r.create(o).bind(v,e._columnsChangeHandler).bind(_,e._columnsErrorHandler)},_columnsDataSourceChange:function(e){var n=this,i=n.columnsDataSource.view(),r=o(!0,{},n.options.columnSettings,{messages:n.options.messages,states:n._buildStates(),sortableIdentifier:n._sortableIdentifier}),s=r.dataStatusField;if(!(e.action&&"sync"!==e.action||n.trigger(w,e))){n._progress(!0),n._columns={},n.columnsContainer.html("");for(var l=0;l<i.length;l++){var d,f=i[l],m=f[s]||c;d=n._columns[m]=new a.taskboard.Column(r,f),n.columnsContainer.append(d.element),d.bind(g,n.executeCommand.bind(n)),d.bind(u,n._move.bind(n)),d.bind(p,n._moveEnd.bind(n)),d.bind(h,n._moveStart.bind(n)),d.bind(v,n._changeOrder.bind(n)),n._tabindex(d.element)}"sync"!==e.action&&e.action!==t||n._renderCards(n.dataSource.view()),n._progress(!1),n.trigger(k,e)}},_move:function(e){this.trigger(u,this._extendExecArgs(e))},_moveEnd:function(e){this.trigger(p,this._extendExecArgs(e))},_moveStart:function(e){this.trigger(h,this._extendExecArgs(e))},_changeOrder:function(e){this.trigger(v,this._extendExecArgs(e))},_dataSource:function(){var e=this,t=e.options,n=t.dataSource;if(n=s(n)?{data:n}:n,t.dataOrderField&&!n.sort&&(n.sort={field:t.dataOrderField,dir:"asc"}),!n.schema){var i={};i[t.dataStatusField]={type:"string"},i[t.dataTitleField]={type:"string"},i[t.dataDescriptionField]={type:"string"},i[t.dataCategoryField]={type:"string"},t.dataOrderField&&(i[t.dataOrderField]={type:"number"}),n.schema={model:{fields:i}}}e.dataSource&&e._changeHandler?(e.dataSource.unbind(v,e._changeHandler),e.dataSource.unbind(_,e._errorHandler)):(e._changeHandler=e._change.bind(e),e._errorHandler=e._error.bind(e)),e.dataSource=r.create(n).bind(v,e._changeHandler)},_change:function(e){var t=this;e.action&&"sync"!==e.action||t.trigger(b,e)||(t._progress(!0),t._clearColumns(),t._renderCards(t.dataSource.view()),t._closePane(),t.trigger(y,e),t._progress(!1))},_error:function(){this._progress(!1)},_renderCards:function(e){for(var t=0;t<e.length;t++)this._renderCard(e[t])},_renderCard:function(e){var t=this,n=o({},t.options,{states:t._buildStates()}),i=e[n.dataStatusField]||c;i&&t._columns[i]&&(e=new a.taskboard.Card(n,e,t.resources),t._columns[i].addCard(e.element),t._tabindex(e.element))},_clearColumns:function(){for(var e in this._columns)this._columns[e].empty()},_initCardMenu:function(){var e=this,t=e.options,n=s(t.cardMenu)?{items:t.cardMenu}:t.cardMenu;n=o({},{messages:t.messages,target:e.columnsContainer,filter:".k-taskboard-card-menu-button",action:e.executeCommand.bind(e),showOn:"click",alignToAnchor:!0,states:e._buildStates()},n),!1!==t.cardMenu&&(e.cardMenu=new a.taskboard.CardMenu("<ul></ul>",n))},_initResources:function(){for(var e=this.options.resources,t=0;t<e.length;t++)this._addResource(e[t])},_addResource:function(e){var t=this;t.resources||(t.resources={}),t.resources[e.field]={field:e.field,name:e.name,title:e.title||e.field,dataTextField:e.dataTextField||"text",dataValueField:e.dataValueField||"value",dataColorField:e.dataColorField||"color",valuePrimitive:!1!==e.valuePrimitive,multiple:e.multiple||!1,dataSource:t._resourceDataSource(e.dataSource)}},_resourceDataSource:function(e){var t=s(e)?{data:e}:e;return n.data.DataSource.create(t)},_progress:function(e){n.ui.progress(this.element,e)},_initKeyboard:function(){var e=this;e.keyboardManager=new a.taskboard.KeyboardManager(e.element),e.keyboardManager.bind(g,e.executeCommand.bind(e)),e._registerShortcuts()},_registerShortcuts:function(){var e=this,t=e._buildStates();t.isEditable&&(e.keyboardManager.registerShortcut(d+x.styles.column,{keyCode:n.keys.DELETE},{command:"DeleteColumnCommand"}),e.keyboardManager.registerShortcut(d+x.styles.column,{keyCode:"e",ctrlKey:!0},{command:"EditColumnCommand",handler:DH}),e.keyboardManager.registerShortcut(d+x.styles.column,{keyCode:"a",ctrlKey:!0},{command:"AddCardCommand",handler:DH}),e.keyboardManager.registerShortcut(d+x.styles.column+" *",{keyCode:n.keys.ESC},{command:"CancelEditColumnCommand"}),e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:n.keys.DELETE},{command:"DeleteCardCommand"}),e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:"e",ctrlKey:!0},{command:"EditCardCommand",handler:DH})),t.isSelectable&&e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:n.keys.ENTER},{command:"SelectCardCommand",handler:DH}),e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:n.keys.UP},{command:"MoveFocusCommand",options:{value:"up"},handler:DH}),e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:n.keys.DOWN},{command:"MoveFocusCommand",options:{value:"down"},handler:DH}),e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:n.keys.LEFT},{command:"MoveFocusCommand",options:{value:"left"},handler:DH}),e.keyboardManager.registerShortcut(d+x.styles.card,{keyCode:n.keys.RIGHT},{command:"MoveFocusCommand",options:{value:"right"},handler:DH}),e.keyboardManager.registerShortcut(d+x.styles.column,{keyCode:n.keys.LEFT},{command:"MoveFocusCommand",options:{value:"left"},handler:DH}),e.keyboardManager.registerShortcut(d+x.styles.column,{keyCode:n.keys.RIGHT},{command:"MoveFocusCommand",options:{value:"right"},handler:DH}),e.keyboardManager.registerShortcut(d+x.styles.column,{keyCode:n.keys.DOWN},{command:"MoveFocusCommand",options:{value:"down"},handler:DH})},destroy:function(){var e=this;for(var t in e._columnsChangeHandler&&(e.columnsDataSource.unbind(v,e._columnsChangeHandler),e.columnsDataSource.unbind(v,e._columnsErrorHandler)),e._changeHandler&&(e.dataSource.unbind(v,e._changeHandler),e.dataSource.unbind(_,e._errorHandler)),e._columns)e._columns[t].destroy();e.toolbar&&e.toolbar.destroy(),e.cardMenu&&e.cardMenu.destroy(),e.keyboardManager&&e.keyboardManager.destroy(),e.pane&&e._closePane(),i.fn.destroy.call(e)}});n.ui.plugin(x),o(!0,x,{styles:TH})}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=e.extend,r=e.ajax,o=t.isFunction,a=".kendoCaptcha",s="click",l="change",c="requestStart",d="requestEnd",u="error",h=n.extend({init:function(e,i){var r=this;n.fn.init.call(r,e,i),r._captchaField=r.options.dataCaptchaField,r._valueField=r.element.attr("name")||"captcha",r._captchaIdField=r.options.dataCaptchaIdField,r._wrapper(),r._idInput(),r._captchaImage(),(r.options.audioButton||r.options.resetButton)&&r._buttons(),r.options.captcha&&r.options.captchaId||r._resetHandler(),r.options.validateOnBlur&&r.element.on("blur"+a,(function(){r._validationHandler()})),r.element.on(l+a,(function(e){delete r._isValid,r.trigger(l,{value:r.element.val(),originalEvent:e})})),t.notify(r)},events:[l,c,d,u],options:{name:"Captcha",dataCaptchaField:"captcha",dataCaptchaIdField:"captchaId",captchaId:"",captcha:null,handler:null,audioHandler:null,validationHandler:null,validateOnBlur:!1,resetButton:!0,audioButton:!0,volumeControl:!0,messages:{reset:"Reset captcha",audio:"Speak captcha",imageAlt:"Type the Captcha code from the image",success:"Verification successful"}},destroy:function(){var e=this;e.textbox.destroy(),e.resetButton&&e.resetButton.off(a),e.audioButton&&e.audioButton.off(a),e.element.off(a),e._audioEnded(),n.fn.destroy.call(e)},_wrapper:function(){var t=this,n=h.styles,i="<div class='"+n.wrapper+"'><div class='"+n.inputWrapper+"'></div></div>",r="<div class='"+n.imageWrapper+"'></div>",o=t.element[0].style.cssText;t.element.css("width","auto"),t.element.css("height","auto"),t.textbox=t.element.kendoTextBox({clearButton:!0}).data("kendoTextBox"),t._inputWrapper=t.textbox.wrapper,t.wrapper=t._inputWrapper.wrap(i).parent().parent(),t.wrapper[0].style.cssText=o,t.imageWrapper=e(r),t.wrapper.prepend(t.imageWrapper)},_captchaImage:function(){var t=this,n=t.options,i=n.messages,r=h.styles;t.captchaImage=e('<div class="'+r.captchaImage+'"><img alt="'+i.imageAlt+'" src= "'+(n.captcha||"")+'"/></div>').find("img"),t.imageWrapper.append(t.captchaImage.parent()),t._tabindex(t.captchaImage),t._attachImageErrorHandler()},_attachImageErrorHandler:function(){var e=this;e.captchaImage.off("error"),e.captchaImage.one("error",(function(t){e.trigger(u,{type:"image",originalEvent:t})}))},_idInput:function(){var n=this,i=n.options,r=n._captchaIdField;n.idInput=e('<input type="hidden" name="'+r+'" value="'+i.captchaId+'" data-'+t.ns+'stop="true" />'),n._inputWrapper.after(n.idInput)},_buttons:function(){var t=this,n=h.styles;t.buttonsWrapper=e('<div class="'+n.buttonsWrapper+'"></div>'),t.imageWrapper.append(t.buttonsWrapper),t.options.audioButton&&t._audioButton(),t.options.resetButton&&t._resetButton()},_resetButton:function(){var n=this,i=n.options.messages,r=h.styles;n.resetButton=e('<button type="button" title="'+i.reset+'" class="'+r.button+" "+r.iconButton+'">'+t.ui.icon({icon:r.resetIcon,iconClass:"k-button-icon"})+"</button>"),n.buttonsWrapper.append(n.resetButton),n.resetButton.on(s+a,n._resetHandler.bind(n,!0))},_audioButton:function(){var n=this,i=n.options.messages,r=h.styles;n.audioButton=e('<button type="button" title="'+i.audio+'" class="'+r.button+" "+r.iconButton+'">'+t.ui.icon({icon:r.audioIcon,iconClass:"k-button-icon"})+"</button>"),n.buttonsWrapper.append(n.audioButton),n.audioButton.on(s+a,n._audioHandler.bind(n))},_resetHandler:function(t){var n=this,i=n.options.handler,r=e.Deferred(),o=n._resetCaptcha.bind(n,r);return delete n._isValid,n._toggleSuccessMessage(!1),n._audioEnded(),n._progress(!0),i?(n._callHandler("reset",i,o).done((function(){t&&n.resetButton.trigger("focus")})).fail((function(e){n._progress(!1),r.reject(e)})),r.promise()):(window.console.error("Captcha's handler option is not defined!"),r.reject({msg:"Captcha's handler option is not defined!",error:"handler_not_defined"}),n._progress(!1),r.promise())},_audioHandler:function(){var t=this,n=t.options.audioHandler,i=e.Deferred(),r=t._playAudio.bind(t,i),o={};return o[t._captchaIdField]=t.idInput.val(),n?(t._callHandler("audio",n,r,o).fail(i.reject),i.promise()):(window.console.error("Captcha's audioHandler option is not defined!"),i.reject({msg:"Captcha's audioHandler option is not defined!",error:"handler_not_defined"}),i.promise())},_validationHandler:function(){var t=this,n=t.options.validationHandler,i=e.Deferred(),r=t._validate.bind(t,i),o={};return delete t._isValid,o[t._captchaIdField]=t.idInput.val(),o[t._valueField]=t.element.val(),n?(t._callHandler("validation",n,r,o).fail(i.reject),i.promise()):(window.console.error("Captcha's validationHandler option is not defined!"),i.reject({msg:"Captcha's validationHandler option is not defined!",error:"handler_not_defined"}),i.promise())},_callHandler:function(t,n,a,s){var l,d=this,u=d._error.bind(d,t),h=d._requestEnd.bind(d,t);return o(n)?(n({success:a,data:s}),e.Deferred().promise()):((l="string"==typeof n?{url:n,cache:!1}:i({},n)).success=a,l.data=i({},s,l.data),d.trigger(c,{type:t,data:s})?void 0:r(l).done(h).fail(u))},_requestEnd:function(e,t){this.trigger(d,{type:e,data:t})},_error:function(e,t,n,i){this.trigger(u,{type:e,jqXHR:t,textStatus:n,errorThrown:i})},_resetCaptcha:function(e,t){var n=this,i=t[n._captchaIdField],r=t[n._captchaField];n.idInput.val(i),n.captchaImage.attr("src",r||""),n.captchaImage.off("load"),n.captchaImage.one("load",(function(){n._progress(!1)})),n._attachImageErrorHandler(),e.resolve(t)},_playAudio:function(t,n){var i=this;if(i._canPlayWav()){if(i.audioElement)return;i.audioElement=new Audio(n),i.audioElement.volume=i._audioVolume||i.audioElement.volume,i.options.volumeControl&&e(i.audioElement).on("loadeddata"+a,(function(){i._showVolumeControl(i.audioElement.volume)})),e(i.audioElement).on("ended"+a+" error"+a,i._audioEnded.bind(i,t)),i.audioElement.play()}},_showVolumeControl:function(t){var n=this,i=h.styles,r=e('<div class="'+i.volumeControlWrapper+'"></div>');n.volumeControl||(n.volumeControlElm=e("<input />"),n.volumeControlWrapper=r.append(n.volumeControlElm),n.imageWrapper.append(r),n.volumeControlWrapper.css(n._isRtl()?"right":"left",n.wrapper.width()),n.volumeControl=n.volumeControlElm.kendoSlider({min:0,max:1,smallStep:.1,largeStep:.5,orientation:"vertical",showButtons:!1,tickPlacement:"none",value:t,tooltip:{enabled:!1},change:function(e){n._audioVolume=n.audioElement.volume=e.value}}).data("kendoSlider"))},_audioEnded:function(t){var n=this;e(document.activeElement).is("a.k-draghandle")&&n.audioButton.trigger("focus"),n.volumeControl&&(n.volumeControl.destroy(),n.volumeControl.wrapper.remove(),delete n.volumeControl,n.volumeControlElm.remove(),n.volumeControlWrapper.remove(),delete n.volumeControlElm,delete n.volumeControlWrapper),n.audioElement&&n.audioElement.pause(),e(n.audioElement).off(a),e(n.audioElement).remove(),delete n.audioElement,t&&t.resolve&&t.resolve()},_canPlayWav:function(){var e,t=this;return t._canPlayAudio||(e=new Audio,t._canPlayAudio=""!==e.canPlayType("audio/wav").replace(/no/gi,"")),t._canPlayAudio},_validate:function(e,t){var n=this;n._isValid=t,n._toggleSuccessMessage(n._isValid),e.resolve(t)},_toggleSuccessMessage:function(n){var i=this,r=(i.element.attr("id")||i.element.attr("name"))+"-success",o=i.options.messages;e(i.successMessage).remove(),i.element.removeAttr("aria-describedby"),n&&(i.successMessage=e('<span id="'+r+'" class="'+h.styles.success+'">'+t.htmlEncode(o.success)+"</span>"),i._inputWrapper.after(i.successMessage),i.element.attr("aria-describedby",r))},_toggleButtons:function(e){var t=this;t.resetButton&&t.resetButton.prop("disabled",!e),t.audioButton&&t.audioButton.prop("disabled",!e)},_progress:function(e){var t=this;t.wrapper.toggleClass(h.styles.loading,e),t._inputWrapper.toggleClass(h.styles.disabled,e),t._toggleButtons(!e),t._toggleSkeleton(e)},_toggleSkeleton:function(t){var n=this;n.skeleton&&n.skeleton.remove(),t&&(n.skeleton=e("<span class='k-skeleton k-skeleton-rect k-skeleton-pulse'></span>").css({width:"100%",height:"100%"}),n.captchaImage.before(n.skeleton))},_isRtl:function(){return t.support.isRtl(this.wrapper)},value:function(){return this.element.val()},getCaptchaId:function(){return this.idInput.val()},toJSON:function(){var e=this,t={};return t[e._valueField]=e.value(),t[e._captchaIdField]=e.getCaptchaId(),t},validate:function(){return this._validationHandler()},isValid:function(){return this._isValid},enable:function(e){var t=this;e=!1!==e,t._toggleButtons(e),t.textbox.enable(e),e?(t.captchaImage.removeAttr("tabIndex"),t._tabindex(t.captchaImage)):t.captchaImage.attr("tabIndex","-1"),t.captchaImage.toggleClass(h.styles.disabled,!e),t.wrapper.toggleClass(h.styles.disabled,!e)},readonly:function(e){var t=this;e=!1!==e,t.resetButton&&t.resetButton.prop("disabled",e),t.textbox.readonly(e)},speak:function(){return this._audioHandler()},reset:function(){return this._resetHandler()}});t.ui.plugin(h),i(!0,h,{styles:{wrapper:"k-captcha",textbox:"k-textbox",button:"k-button k-button-md k-rounded-md k-button-solid k-button-solid-base",buttonIcon:"k-button-icon",iconButton:"k-icon-button",resetIcon:"arrow-rotate-cw",audioIcon:"volume-up",disabled:"k-disabled",inputWrapper:"k-captcha-input k-vstack",imageWrapper:"k-captcha-image-wrap k-hstack",captchaImage:"k-captcha-image",buttonsWrapper:"k-captcha-image-controls k-vstack",volumeControlWrapper:"k-captcha-volume-control k-vstack k-pos-absolute",hidden:"k-hidden",success:"k-captcha-validation-message k-text-success",loading:"k-captcha-loading"}})}(window.kendo.jQuery);kendo;!function(e,t){var n=e.extend,i=kendo.data,r=i.Query,o=i.DataSource,a=i.TreeListDataSource,s=i.Model,l=i.ObservableArray,c=s.define({id:"id",parentId:"parentId",fields:{id:{type:"number",editable:!1},parentId:{type:"number",nullable:!0},name:{type:"string",validation:{required:!0}},title:{type:"string"},avatar:{type:"string"}},init:function(e){s.fn.init.call(this,e),this._loaded=!1,this.parentIdField||(this.parentIdField="parentId"),this.nameField||(this.nameField="name"),this.titleField||(this.titleField="title"),this.avatarField||(this.avatarField="avatar"),this.parentId=this.get(this.parentIdField),this.name=this.get(this.nameField),this.title=this.get(this.titleField),this.avatar=this.get(this.avatarField)},accept:function(e){s.fn.accept.call(this,e),this.parentId=this.get(this.parentIdField),this.name=this.get(this.nameField),this.title=this.get(this.titleField),this.avatar=this.get(this.avatarField)},set:function(e,t,n){"parentId"==e&&"parentId"!=this.nameField&&(this[this.parentIdField]=t),"name"==e&&"name"!=this.nameField&&(this[this.nameField]=t),"title"==e&&"title"!=this.titleField&&(this[this.titleField]=t),"avatar"==e&&"avatar"!=this.avatarField&&(this[this.avatarField]=t),s.fn.set.call(this,e,t,n),e==this.parentIdField&&(this.parentId=this.get(this.parentIdField)),e==this.nameField&&(this.name=this.get(this.nameField)),e==this.titleField&&(this.title=this.get(this.titleField)),e==this.avatarField&&(this.avatar=this.get(this.avatarField))},loaded:function(e){if(e===t)return this._loaded;this._loaded=e},shouldSerialize:function(e){return s.fn.shouldSerialize.call(this,e)&&"_loaded"!==e&&"_error"!=e&&"_edit"!=e&&!("parentId"!==this.parentIdField&&"parentId"===e)}});c.parentIdField="parentId",c.nameField="name",c.titleField="title",c.avatarField="avatar",c.define=function(e,n){n===t&&(n=e,e=c);var i=n.parentId||"parentId",r=n.name||"name",o=n.title||"title",a=n.avatar||"avatar";n.parentIdField=i,n.nameField=r,n.titleField=o,n.avatarField=a;var l=s.define(e,n);return i&&(l.parentIdField=i),r&&(l.nameField=r),o&&(l.titleField=o),a&&(l.avatarField=a),l};var d=a.extend({init:function(e){a.fn.init.call(this,n(!0,{},{schema:{modelBase:c,model:c}},e))},groupedItemsTree:function(e){var t=this._childrenMap(this.view()),n=t[this._defaultParentId()]||[],i=new r(n).group({field:e}).toArray();return this._innerGroupedItemsTree(e,i,t)},itemChildren:function(e,n){var i,o,a={field:"parentId",operator:"eq",value:null},s=this._sort&&this._sort.length?this._sort:{};if(o=n?this.view():this.data(),e){if((i=e.get("id"))===t||null===i||""===i)return[];a.value=i}return o=new r(o).filter(a).sort(s).toArray()},itemsTree:function(e,i){var o,a,s,l=[],c=this.itemChildren(e,!0);for(s=0;s<c.length;s++)(o=c[s]).get("expanded")&&(a=this.itemsTree(o,i),(o=n(!0,{},o)).children=a),o=n(!0,{},o),l.push(o);return null!==i&&i!==t&&(l=new r(l).group({field:i}).toArray()),l},prospectParents:function(e,t){var n,i,r,o=[],a=this.itemChildren(t,!1);for(r=0;r<a.length;r++)(n=a[r]).get("id")!==e.get("id")&&(o.push(n),n.get("hasChildren")&&(i=this.prospectParents(e,n),o=o.concat(i)));return o},read:function(e){return o.fn.read.call(this,e).then(this._loadExpanded.bind(this,e))},toggleChildren:function(n,i){var r=e.Deferred().resolve().promise(),o=n.loaded();return n._error&&(n.expanded=!1,n._error=t),void 0===i&&(i=!n.expanded),n.expanded=i,o||(r=this.load(n)),r},_innerGroupedItemsTree:function(e,t,n){var i,o,a,s,l,c,d;for(o=0;o<t.length;o++){for(i=t[o],c=[],a=0;a<i.items.length;a++)d=i.items[a],!i.hasChildren&&d.hasChildren&&(i.hasChildren=!0),d.expanded&&(i.expanded=!0),s=i.items[a].get("id"),c=c.concat(n[s]);i.expanded&&(l=new r(c).group({field:e}).toArray(),i.children=this._innerGroupedItemsTree(e,l,n)),!i.hasChildren&&c.length>0&&(i.hasChildren=!0)}return t},_loadExpanded:function(e){var n,i,r;if(e)for(n=null!==e.id&&e.id!==t?this._byParentId(e.id):this._byParentId(this._defaultParentId()),i=0;i<n.length;i++)(r=n[i]).expanded&&!r.loaded()&&this.toggleChildren(r,!0)}});d.create=function(e){if(Array.isArray(e)?e={data:e}:e instanceof l&&(e={data:e.toJSON()}),!(e instanceof d)&&e instanceof o)throw new Error("Incorrect DataSource type. Only OrgChartDataSource instances are supported");return e instanceof d?e:new d(e)},n(!0,kendo.data,{OrgChartModel:c,OrgChartDataSource:d})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.keys,i=t.htmlEncode,r=e.extend,o=".kendoOrgChartView",a="click",s="collapse",l="expand",c="menu",d="select",u=".",h=" ",p="#",f="tabindex",m="uid",g="px",v="plus",_="minus",b="aria-owns",y="aria-selected",w="k-orgchart",k="k-orgchart-line",x="k-orgchart-line-v",C="k-orgchart-line-h",S="k-orgchart-line-v-top",T="k-orgchart-group",D="k-orgchart-group-v",A="k-orgchart-group-h",M="k-orgchart-node-group",E="k-orgchart-node-group-container",I="k-orgchart-node-container",z="k-orgchart-node",P="k-orgchart-card",H="k-orgchart-card-menu",F="k-orgchart-button",R="k-focus",L=".k-i-plus,.k-svg-i-plus",B="k-vstack",O="k-hstack",V=({label:e})=>`<div role="tree" aria-orientation="horizontal" aria-label="${i(e)}" class="k-orgchart-group k-orgchart-level-1 k-pos-absolute k-hstack k-justify-content-center"></div>`,N=({guid:e,level:t})=>`<div role="group" id="${i(e)}" class="k-orgchart-level-${i(t)} k-orgchart-group k-pos-absolute k-justify-content-around"></div>`,$=({hasChildren:e,guid:t,expanded:n,level:r})=>{var o='<div role="treeitem" ';return e&&t&&(o+=`aria-owns=${i(t)} `,o+=n?'aria-expanded="true" ':'aria-expanded="false" '),o+=`aria-keyshortcuts="Enter" aria-level="${i(r)}" aria-selected="false" class="k-orgchart-node-group-container">`},U=({label:e,buttonSign:n})=>t.html.renderButton(`<button aria-label="${i(e)}" tabindex="-1" class="k-orgchart-button"></button>`,{icon:i(n)}),W=({color:e,avatar:n,name:r,title:o,editable:a,menuLabel:s})=>{var l=`<div class="k-card-body k-hstack" ${t.attr("style-border-color")}="${i(e)}">`;return n&&(l+=`<div class="k-avatar k-avatar-solid-primary k-avatar-solid k-avatar-lg k-rounded-full"><span class="k-avatar-image"><img alt="${i(r)}" src="${i(n)}"></span></div>`),l+=`<div class="k-vstack k-card-title-wrap"><div class="k-card-title k-text-ellipsis">${i(r)}</div>`,o&&(l+=`<span class="k-spacer"></span><div class="k-card-subtitle k-text-ellipsis">${i(o)}</div>`),l+="</div>",a&&(l+='<span class="k-spacer"></span><div class="k-card-body-actions">'+t.html.renderButton(`<button class="k-orgchart-card-menu" role="button" aria-label="${i(s)}" tabindex="-1"></button>`,{icon:"more-vertical",fillMode:"flat"})+"</div>"),l+="</div>"},j=({uid:e,guid:t,hasChildren:n,expanded:r,cssClass:o,level:a})=>{var s=`<div role="treeitem" data-uid="${i(e)}" `;return n&&t&&(s+=`aria-owns=${i(t)} `,s+=r?'aria-expanded="true" ':'aria-expanded="false" '),s+='class="k-orgchart-card k-card ',o&&(s+=`${i(o)}`),s+=`" aria-keyshortcuts="Enter" aria-level="${i(a)}" aria-selected="false"></div>`},q=({uid:e,level:t,cssClass:n})=>`<div role="treeitem" data-uid="${i(e)}" aria-level="${i(t)}" aria-selected="false" aria-keyshortcuts="Enter" class="k-orgchart-card k-card ${n?i(n):""}"></div>`,G=t.Observable.extend({init:function(e,n){this.element=e,this.options=n||{},t.Observable.fn.init.call(this),this._attachEvents()},events:[s,l,d,c],destroy:function(){t.ui.Widget.fn.destroy.call(this),this.element.off(o)},collapse:function(){return!1},expand:function(){return!1},jqueryGroupElement:function(e){if(e){var t=this._processItem(e);return t.hasClass(E)||(t=t.closest(u+E)),t&&t.length?t:null}},jqueryItemElement:function(e){if(e){var t=this._processItem(e);return t.hasClass(P)||(t=t.closest(u+P)),t&&t.length?t:null}},refresh:function(){this._cacheFocused(),this._clearContent(),this._generateItemsTree(),this._calculateLevels(),this._render()},select:function(e){var t=this._getToSelect(e),n=this.element.find("[tabindex=0]");t&&(n.removeAttr(f).removeClass(R).attr(y,!1),t.attr(f,"0").addClass(R).trigger("focus").attr(y,!0))},_attachEvents:function(){var e=u+P+","+u+E;this.element.on("keydown"+o,e,this._onKeyDown.bind(this)).on(a+o,e,this._onSelect.bind(this)).on(a+o,u+F,this._onButtonClick.bind(this)).on("focus"+o,e,this._onFocus.bind(this)).on("blur"+o,u+R,this._onBlur.bind(this))},_cacheFocused:function(){var e=this.element.find("[tabindex='0']"),t=this._dataItems(e);e.length&&t&&t.length&&!this._idTabIndex&&(this._idTabIndex=t[0].get("id"),e.hasClass(R)?this._shouldRestoreSelection=!0:this._shouldRestoreSelection=!1)},_calculateDimensions:function(){var e=this.element.find(u+this._selector).first();this._buttonHeight||(this._buttonHeight=this.element.find(u+F).first().outerHeight()),this._spacing||(this._spacing=this.element.find(u+x).first().outerHeight()),this._itemWidth||(this._itemWidth=this._calculateItemWidth()),this._itemHeight||(this._itemHeight=e.outerHeight(!0))},_calculateItemWidth:function(){return!1},_calculateLevel:function(){return!1},_calculateLevels:function(){return!1},_clearContent:function(){this.element.empty()},_dataItem:function(e){var t=this.jqueryItemElement(e);if(t&&t.data(m))return this.dataSource.getByUid(t.data(m))},_dataItems:function(){return!1},_generateItemsTree:function(){return!1},_getToSelect:function(){return!1},_groupIsVertical:function(){return!1},_keyCollapse:function(){return!1},_keyExpand:function(){return!1},_keyNext:function(){return!1},_keyPrev:function(){return!1},_keyEnter:function(){return!1},_keyEscape:function(){return!1},_keyEnd:function(){var e=this.element.find(u+P).last();this.element.find("[tabindex=0]")[0]!==e[0]&&this.trigger(d,{item:e,dataItems:[this._dataItem(e)]})},_keyHome:function(){var e=this.element.find(u+P).first();this.element.find("[tabindex=0]")[0]!==e[0]&&this.trigger(d,{item:e,dataItems:[this._dataItem(e)]})},_onBlur:function(){this.element.find(u+R).removeClass(R)},_onKeyDown:function(e){var i=e.keyCode,r=this.element.find("[tabindex=0]"),o=t.support.isRtl(this.element),a=o?[n.LEFT]:[n.RIGHT],s=o?[n.RIGHT]:[n.LEFT],l=n.DOWN,c=n.UP;r&&(this._groupIsVertical(r)&&(a.push(n.DOWN),s.push(n.UP)),i===n.HOME?this._keyHome():i===n.END?this._keyEnd():a.indexOf(i)>-1?(e.preventDefault(),e.stopPropagation(),this._keyNext(r)):s.indexOf(i)>-1?(e.preventDefault(),e.stopPropagation(),this._keyPrev(r)):i===l?(e.preventDefault(),e.stopPropagation(),this._keyExpand(r)):i===c?(e.preventDefault(),e.stopPropagation(),this._keyCollapse(r)):i===n.ENTER?this._keyEnter(r):i===n.ESC&&this._keyEscape(r))},_onButtonClick:function(t){var n,i=this,r=e(t.currentTarget),o=r.find(L).length>0,a=r.siblings(u+this._selector),c=this._dataItems(a);if(o){if(i.trigger(l,{item:a,dataItems:c}))return}else if(i.trigger(s,{item:a,dataItems:c}))return;for(n=0;n<c.length;n++)i.dataSource.toggleChildren(c[n],o).then(this.refresh.bind(this))},_onFocus:function(){return!1},_onSelect:function(){return!1},_orientation:function(){return!1},_processItem:function(n){var i;return"string"===t.type(n)?i=this.element.find(n):t.isElement(n)?i=e(n):n instanceof jQuery&&(i=n),i},_render:function(){var n,i=this._itemsTree,r=e(t.template(V)({label:this.options.messages.label})),o=this.element,a=this._total,s=o.closest(u+w).css("padding-left");o.append(r),this._renderGroup(r,i,1,this._total,0),n=a*this._itemWidth+(a-1)*this._spacing,r.width(n),o.width(n+Number(s.split(g)[0])),this._setHeight(),this._restoreSelection()},_renderNode:function(n,i,o,a,s){var l,c,d=this.options.messages,u=this.options.cardsColors||t.getSeriesColors(),h=e('<div class="k-orgchart-node k-vstack k-align-items-center"></div>');return c=e(n(r(!0,{},o,{menuLabel:d.menuLabel,level:a,guid:s,editable:!!this.options.editable,color:u[a-1]||u[0]}))),o.attributes&&c.attr(JSON.parse(JSON.stringify(o.attributes))),l=e(i(r(!0,{},o,{menuLabel:d.menuLabel,level:a,guid:s,editable:!!this.options.editable,color:u[a-1]||u[0]}))),c.append(l),h.append(c),t.applyStylesFromKendoAttributes(h,["border-color"]),h},_renderGroup:function(){return!1},_restoreSelection:function(){var e,t;this._idTabIndex?((t=(e=this.dataSource.get(this._idTabIndex))?this._getToFocus(e):this.element.find(u+this._selector).first()).attr(f,"0"),this._idTabIndex=null):(t=this.element.find(u+this._selector).first()).attr(f,"0"),this._shouldRestoreSelection&&(this._shouldRestoreSelection=!1,this._preventTriggerSelect=!0,t.trigger("focus"),t.addClass(R))},_setHeight:function(){var t,n=this._selector,i=this.element.find(u+F+","+u+n),r=Number.MAX_VALUE,o=0;this._calculateDimensions(),t=this._buttonHeight,this.element.find(u+S).height(this._spacing+t/2),i.each((function(t,n){var i=e(n).offset().top,a=i+e(n).outerHeight(!0);i<r&&(r=i),a>o&&(o=a)})),this.element.height(o-r)}}),K=G.extend({init:function(e,t){G.fn.init.call(this,e,t),this._selector=P},collapse:function(e){var t=this.jqueryItemElement(e);t&&this.dataSource.toggleChildren(this._dataItem(t),!1).then(this.refresh.bind(this))},expand:function(e){var t=this.jqueryItemElement(e);t&&this.dataSource.toggleChildren(this._dataItem(t),!0).then(this.refresh.bind(this))},_calculateItemWidth:function(){return this.element.find(u+this._selector).first().outerWidth(!0)},_calculateLevel:function(e,t){var n,i,r,o=e.length,a=this._maxColumnsPerLevel,s=!1,l=!1;for((!a[t]||a[t]<o)&&(n=a[t],l=!0,a[t]=o),i=0;i<o;i++)(r=e[i]).hasChildren&&(s=!0,r.expanded&&this._calculateLevel(r.children,t+1));!s&&l&&t>0&&(l=!1,a[t]=n||1)},_calculateLevels:function(){var e,t=this._itemsTree,n=this._maxColumnsPerLevel=[],i=1;for(this._calculateLevel(t,0),e=0;e<n.length;e++)i*=n[e];this._total=i},_dataItems:function(e){var t=this.dataSource.getByUid(e.data(m));return t?[t]:null},_generateItemsTree:function(){this._itemsTree=this.dataSource.itemsTree()},_getToFocus:function(e){return this.element.find("[data-uid='"+e.get(m)+"']")},_getToSelect:function(e){return this.jqueryItemElement(e)},_groupIsVertical:function(e){return e.closest(u+T).hasClass(D)},_keyCollapse:function(e){var t,n,i=this._dataItem(e);i.expanded?this.trigger(s,{item:e,dataItems:[i]})||this.collapse(e):i.parentId&&(t=this.dataSource.get(i.parentId).get(m),n=this.element.find("[data-uid='"+t+"']"),this.trigger(d,{item:n,dataItems:[this._dataItem(n)]}))},_keyEnter:function(e){e.find(u+H).length>0&&this.trigger(c,e)},_keyExpand:function(e){var t,n=this._dataItem(e),i=this.element.find(p+e.attr(b));n.hasChildren&&(n.expanded?(t=i.find(u+this._selector).first(),this.trigger(d,{item:t,dataItems:[this._dataItem(t)]})):this.trigger(l,{item:e,dataItems:[n]})||this.expand(e))},_keyNext:function(e){var t=this._dataItem(e),n=e.parent().next(u+z).find(u+P),i=this.element.find(p+e.attr(b));!n.length&&t.hasChildren&&t.expanded&&(n=i.find(u+P).first()),0===n.length||n.hasClass(R)||this.trigger(d,{item:n,dataItems:[this._dataItem(n)]})},_keyPrev:function(e){var t,n=this._dataItem(e),i=e.parent().prev(u+z).find(u+P);!i.length&&n.parentId&&(t=this.dataSource.get(n.parentId).get(m),i=this.element.find("[data-uid='"+t+"']")),0===i.length||i.hasClass(R)||this.trigger(d,{item:i,dataItems:[this._dataItem(i)]})},_onFocus:function(t){var n=e(t.currentTarget),i=e(t.target);if(this._preventTriggerSelect)return t.stopPropagation(),void(this._preventTriggerSelect=!1);if(i.hasClass(H)){if(i.closest("[tabindex='0']").length>0)return void t.stopPropagation();this._preventTriggerSelect=!0}n.hasClass(P)||(n=n.closest(u+P)),n.hasClass(R)||this.trigger(d,{item:n,dataItems:[this._dataItem(n)]})},_onSelect:function(t){var n=e(t.currentTarget),i=n.hasClass(P)?n:n.closest(u+P);(e(t.target).hasClass(H)?e(t.target):e(t.target).closest(u+H)).length>0||n.hasClass(R)||this.trigger(d,{item:i,dataItems:[this._dataItem(i)]})},_orientation:function(t,n,i){var r=e("<div>").addClass(k+h+x);i&&n>1?(t.addClass(D+h+B),t.find(u+I).addClass(B),0===t.find(u+F).length||1===t.find(u+P).length?(t.find(u+P).before(r.clone()),t.find(u+z).first().find(u+x).addClass(S)):n>1&&t.find(u+P).first().before(r.clone())):(t.addClass(A+h+O),t.find(u+I).addClass(O),n>1&&t.find(u+P).before(r.clone().addClass(S)))},_renderGroup:function(t,n,i,r,o){var a,s;s=e('<div class="k-orgchart-node-container k-justify-content-around"></div>').css("width","100%"),t.append(s),a=this._renderInner(s,n,i,r,o),this._orientation(t,i,a)},_renderInner:function(n,i,r,o,a){var s,l,c,d,p,f,m,b,y,w=t.template(U),S=t.template(j),T=o/i.length,D=!0,M=e("<div>").addClass(k+h+x),E=e("<div>").addClass(k+h+C),I=this.options.messages;for(y=this.options.template?"function"==typeof this.options.template?this.options.template:t.template(this.options.template):t.template(W),s=0;s<i.length;s++)l=i[s],c=t.guid(),d=this._renderNode(S,y,l,r,c),l.hasChildren&&(d.append(M.clone()),p=e(w({buttonSign:l.expanded?_:v,label:l.expanded?I.collapse:I.expand})),d.append(p)),n.append(d),this._calculateDimensions(),m=this._itemWidth,b=this._spacing,l.hasChildren&&(D=!1,l.expanded&&(f=this._renderInnerGroup(l,T,a,s,r,c))),f&&f.hasClass(A)&&l.expanded&&l.children&&l.children.length>1&&p.after(E.clone().css({width:(T-T/l.children.length)*(m+b)+g,"margin-top":this._buttonHeight/-2+g}));return T>1&&!D&&n.find(u+z).width((T-1)*(b+m)),D},_renderInnerGroup:function(n,i,r,o,a,s){var l,c=this._itemWidth,d=this._spacing,u=i*c+(i-1)*d,h=o*i*c+r,p=t.template(N),f=t.support.isRtl(this.element)?"right":"left",m=a*(this._itemHeight+this._buttonHeight+d)+d*(a-1)-this._buttonHeight/2;return o>0&&(h+=o*i*d),(l=e(p({guid:s,level:a+1}))).css({width:u+g,top:m+g}),l.css(f,h+g),this.element.append(l),this._renderGroup(l,n.children,a+1,i,h),l}}),Y=G.extend({init:function(e,t){G.fn.init.call(this,e,t),this._selector=E},collapse:function(e){var t,n,i=this.jqueryGroupElement(e);if(i)for(t=this._dataItems(i),n=0;n<t.length;n++)this.dataSource.toggleChildren(t[n],!1).then(this.refresh.bind(this))},expand:function(e){var t,n,i=this.jqueryGroupElement(e);if(i)for(t=this._dataItems(i),n=0;n<t.length;n++)this.dataSource.toggleChildren(t[n],!0).then(this.refresh.bind(this))},_dataItems:function(e){var t,n,i=this.dataSource,r=[];return e.hasClass(P)?(t=i.getByUid(e.data(m)))&&r.push(t):e.hasClass(E)&&(this._groupFocused=!0,e.find(u+P).each((function(e,t){(n=i.getByUid(t.getAttribute("data-uid")))&&r.push(n)}))),r},_calculateItemWidth:function(){var e=this.element.find(u+this._selector).first();return this.element.find(u+P).first().outerWidth(!0)+2*Number(e.css("padding-left").split(g)[0])+2*Number(e.css("border-left").split(g)[0])},_calculateLevel:function(e,t){var n,i,r,o=e.length,a=!1,s=0;for(this._maxColumnsPerLevel[t]=this._maxColumnsPerLevel[t]||0,this._maxGroups[t]=this._maxGroups[t]||0,i=0;i<o;i++)(n=(r=e[i]).items.length)>s&&(s=n),(r=e[i]).hasChildren&&(a=!0,r.expanded&&this._calculateLevel(r.children,t+1));o>this._maxGroups[t]&&(this._maxGroups[t]=o),a||(s=1),s>this._maxColumnsPerLevel[t]&&(this._maxColumnsPerLevel[t]=s)},_calculateLevels:function(){var e,t,n=this._itemsTree,i=this._maxColumnsPerLevel=[],r=this._maxGroups=[],o=1;for(this._calculateLevel(n,0),e=i.length-1;e>=0;e--)t=i[e]*r[e],o>i[e]?o*=r[e]:o<t&&(o=t);this._total=o},_generateItemsTree:function(){this._itemsTree=this.dataSource.groupedItemsTree(this.options.groupField)},_getToFocus:function(e){return this._groupFocused?(this._groupFocused=!1,this.element.find("[data-uid='"+e.get(m)+"']").closest(u+E)):this.element.find("[data-uid='"+e.get(m)+"']")},_getToSelect:function(e){return this.jqueryItemElement(e)||this.jqueryGroupElement(e)},_groupIsVertical:function(e){return e.closest(u+I).hasClass(B)},_keyCollapse:function(e){var t,n=[];(n=this._dataItems(e)).some((function(e){return e.expanded}))?(e.hasClass(P)&&(e=e.closest(u+E),n=this._dataItems(e)),this.trigger(s,{item:e,dataItems:n})||this.collapse(e)):n[0].parentId&&(t=this.dataSource.get(n[0].parentId).get(m),this.trigger(d,{item:this.element.find("[data-uid='"+t+"']").closest(u+this._selector),dataItems:n}))},_keyEnter:function(e){var t,n=[];e.hasClass(P)&&e.find(u+H).length>0?this.trigger(c,e):(t=e.find(u+P).first(),n=this._dataItems(t),this.trigger(d,{item:t,dataItems:n}))},_keyEscape:function(e){if(e.hasClass(P)){var t=e.closest(u+E),n=this._dataItems(t);this.trigger(d,{item:t,dataItems:n})}},_keyExpand:function(e){var t,n,i,r=e.attr(b)||e.closest(u+this._selector).attr(b),o=this.element.find(p+r),a=this._dataItems(e);t=a.some((function(e){return e.hasChildren})),t&&(n=a.some((function(e){return e.expanded})),n?(i=o.find(u+this._selector).first(),this.trigger(d,{item:i,dataItems:this._dataItems(i)})):(e.hasClass(P)&&(e=e.closest(u+E),a=this._dataItems(e)),this.trigger(l,{item:e,dataItems:a})||this.expand(e)))},_keyNext:function(e){var t,n=this.element.find(p+e.attr(b)),i=this._dataItems(e),r=i.some((function(e){return e.hasChildren})),o=i.some((function(e){return e.expanded}));!(t=e.hasClass(P)?e.parent().next(u+z).find(u+P):e.parent().next(u+M).find(u+E)).length&&r&&o&&(t=n.find(u+this._selector).first()),0!==t.length&&this.trigger(d,{item:t,dataItems:this._dataItems(t)})},_keyPrev:function(e){var t,n,i=this._dataItems(e);!(n=e.hasClass(P)?e.parent().prev(u+z).find(u+P):e.parent().prev(u+M).find(u+E)).length&&i[0].parentId&&(t=this.dataSource.get(i[0].parentId).get(m),n=this.element.find("[data-uid='"+t+"']").closest(u+this._selector)),0!==n.length&&this.trigger(d,{item:n,dataItems:this._dataItems(n)})},_onFocus:function(t){var n,i,r=e(t.target);if(this._preventTriggerSelect)return t.stopPropagation(),void(this._preventTriggerSelect=!1);if(r.hasClass(H)){if(r.closest("[tabindex='0']").length>0)return void t.stopPropagation();this._preventTriggerSelect=!0}r.hasClass(P)||r.hasClass(E)||((i=r.closest(u+P)).length||(i=r.closest(u+E)),r=i),0!==r.length&&(n=this._dataItems(r),r.hasClass(R)||(t.stopPropagation(),this.trigger(d,{item:r,dataItems:n})))},_onSelect:function(t){var n,i,r=e(t.target),o=this.element.find("[tabindex=0]");r.hasClass(P)||r.hasClass(E)||((i=r.closest(u+P)).length||(i=r.closest(u+E)),r=i),0!==r.length&&o[0]!==r[0]&&(n=this._dataItems(r),this.trigger(d,{item:r,dataItems:n}))},_orientation:function(t,n,i){var r=e("<div>").addClass(k+h+x+h+S);t.addClass(O),n>1&&t.find(u+E).before(r.clone()),i&&n>1?(t.find(u+I).removeClass(O),t.find(u+I).addClass(B)):t.addClass(A)},_renderChildren:function(n,i,r,o,a,s,l){var c,d,u,p,f,m,b,y=t.template(U),w=t.template(N),S=e("<div>").addClass(k+h+x),T=e("<div>").addClass(k+h+C),D=this.options.messages,A=!0,M=t.support.isRtl(this.element)?"right":"left";return n.hasChildren&&(A=!1,a.append(S.clone()),d=e(y({buttonSign:n.expanded?_:v,label:n.expanded?D.collapse:D.expand})),a.append(d),this._calculateDimensions(),m=this._itemWidth,b=this._spacing,n.expanded&&(f=m*r+(r-1)*b,u=i*r*m+s,p=o*(this._itemHeight+this._buttonHeight+b)+b*(o-1)-this._buttonHeight/2,i>0&&(u+=i*r*b),(c=e(w({guid:l,level:o+1}))).css({width:f+g,top:p+g}),c.css(M,u+g),this.element.append(c),this._renderGroup(c,n.children,o+1,r,u))),c&&n.expanded&&n.children&&n.children.length>1&&d.after(T.clone().css({width:(r-r/n.children.length)*(m+b)+g,"margin-top":this._buttonHeight/-2+g})),A},_renderGroup:function(e,n,i,o,a){var s,l,c,d,h,p,f=!0,m=o/n.length;for(c=0;c<n.length;c++)d=t.guid(),p=n[c],l=(s=this._renderNodesContainer(e,r(!0,{},p,{guid:d,level:i}))).closest(u+M),this._renderItems(s,p.items,i,d),h=this._renderChildren(p,c,m,i,l,a,d),f&&(f=h);var g=this._itemWidth*m+(m-1)*this._spacing;e.find(u+M).width(g),this._orientation(e,i,f)},_renderItems:function(e,n,i,r){var o,a,s,l,c=t.template(q);for(l=this.options.template?"function"==typeof this.options.template?this.options.template:t.template(this.options.template):t.template(W),o=0;o<n.length;o++)a=n[o],s=this._renderNode(c,l,a,i,r),e.append(s)},_renderNodesContainer:function(n,i){var r,o=t.template($),a=e('<div class="k-orgchart-node-group k-align-items-center k-vstack">'),s=e('<div role="group" class="k-orgchart-node-container k-justify-content-around k-hstack"></div>').css("width","100%"),l=e(o(i));return r="function"==typeof this.options.groupHeaderTemplate?this.options.groupHeaderTemplate:t.template(this.options.groupHeaderTemplate),l.append(r({value:i.value,field:i.field})),l.append(s),a.append(l),n.append(a),s}});t.orgChart={View:G,SingleView:K,GroupedView:Y}}(window.kendo.jQuery);!function(e){var t=window.kendo,n=t.htmlEncode,i=t.ui.DataBoundWidget,r=t.data.OrgChartDataSource,o=t.ui.ContextMenu,a=e.extend,s=Array.isArray,l="cancel",c="change",d="click",u="collapse",h="create",p="dataBinding",f="dataBound",m="delete",g="edit",v="error",_="expand",b="progress",y="save",w="select",k="requestStart",x=".",C="k-orgchart",S="k-orgchart-group",T="k-orgchart-node-group",D="k-orgchart-node",A="k-orgchart-card",M="k-orgchart-card-menu",E="k-focus",I="k-item",z="k-orgchart-avatar-preview",P="k-orgchart-update",H="k-orgchart-cancel",F=({edit:e})=>`<li data-action='edit'>${n(e)}</li>`,R=({create:e})=>`<li data-action='create'>${n(e)}</li>`,L=({destroy:e})=>`<li data-action='destroy'>${n(e)}</li>`,B=({avatar:e,name:i,destroy:r,fileName:o})=>`<div class="k-orgchart-avatar-preview k-hstack k-align-items-center k-pb-lg"><div class="k-avatar k-avatar-solid-primary k-avatar-solid k-avatar-lg k-rounded-full"><span class="k-avatar-image"><img src="${n(e)}" alt="${n(i)}"></span></div><div class="k-px-md">${n(o)}</div>`+t.html.renderButton(`<button aria-label="${n(r)}"></button>`,{icon:"trash",fillMode:"flat"})+"</div>",O=({cancel:e,save:i})=>'<div class="k-edit-buttons">'+t.html.renderButton(`<button class="k-orgchart-update">${n(i)}</button>`,{icon:"save",themeColor:"primary"})+t.html.renderButton(`<button class="k-orgchart-cancel">${n(e)}</button>`,{icon:"cancel-outline"})+"</div>",V=i.extend({init:function(e,n,r){s(n)&&(n={dataSource:n}),n=n||{},i.fn.init.call(this,e,n),r&&(this._events=r),this._wrapper(),this._view(),this._dataSource(),this._contextMenu(),this.options.autoBind&&this.dataSource.fetch(),t.notify(this)},options:{name:"OrgChart",autoBind:!0,cardsColors:null,dataSource:{},editable:{create:!0,destroy:!0,fields:!0,form:{buttonsTemplate:()=>"",orientation:"vertical"},parent:!0},groupField:null,groupHeaderTemplate:({value:e,field:t})=>`<div><div class="k-orgchart-node-group-title">${n(e)}</div><div class="k-orgchart-node-group-subtitle">${n(t)}</div></div>`,template:null,messages:{label:"Org Chart",edit:"Edit",create:"Create",destroy:"Delete",destroyContent:"Are you sure you want to delete this item and all its children?",destroyTitle:"Delete item",cancel:"Cancel",save:"Save",menuLabel:"Edit menu",uploadAvatar:"Upload new avatar",parent:"Parent",name:"Name",title:"Title",none:"--None--",expand:"expand",collapse:"collapse"}},events:[l,c,u,h,p,f,m,g,_,"kendoKeydown",y,w],destroy:function(){this._menu&&this._menu.destroy(),this._editWindow&&this._editWindow.destroy(),this._confirmDestroy&&this._confirmDestroy.destroy(),this.view.destroy(),i.fn.destroy.call(this),this.wrapper.off(".kendoOrgChart")},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.options.autoBind&&e.fetch()},setOptions:function(e){i.fn.setOptions.call(this,e)},append:function(e,t){var n=this,i=n.view.jqueryItemElement(t),r=n.dataItem(i);i&&r&&(r.loaded()?(n.dataSource.add(a({},e,{parentId:r.id})),n.dataSource.sync()):n.dataSource.read({id:r.id}).then((function(){n.dataSource.add(a({},e,{parentId:r.id})),n.dataSource.sync()})))},cancelChanges:function(){this.dataSource.hasChanges()&&this.dataSource.cancelChanges()},collapse:function(e){return this.view.collapse(e)},dataItem:function(e){var t=this.view.jqueryItemElement(e);if(t&&t.data("uid"))return this.dataSource.getByUid(t.data("uid"))},delete:function(e){var t=this.view.jqueryItemElement(e);t&&(this.dataSource.remove(this.dataItem(t)),this.dataSource.sync())},edit:function(e){var t=this.view.jqueryItemElement(e),n=this.dataItem(t);t&&n&&this._edit(n)},expand:function(e){return this.view.expand(e)},getCollapsedNodes:function(){return this.wrapper.find("[aria-expanded='false']")},items:function(){return this.wrapper.find(x+A)},parent:function(e){var t,n=this.view.jqueryItemElement(e);if(n)return t=n.closest(x+S).attr("id"),this.wrapper.find("[aria-owns='"+t+"']")},saveChanges:function(){this.dataSource.sync()},select:function(e){var t=this.view._getToSelect(e);return t?this.view.select(t):void 0},_avatarPreview:function(e,n){var i,r,o=this._form,a=e.avatar;o&&(n||(n=a.split("\\").pop().split("/").pop())&&-1!=n.indexOf(".")||(n=e.name),r={name:e.name,avatar:a,fileName:n,destroy:this.options.messages.destroy},(i=o.wrapper).find(x+z).remove(),i.find('[type="file"]').closest(".k-form-field").prepend(t.template(B)(r)),i.find(x+z+" "+".k-button").on(d,(function(){i.find(x+z).remove(),e.set("avatar",null)})))},_contextMenu:function(){var e,t=this.options,n=t.editable,i=t.messages,r={target:this.wrapper,filter:x+M,select:this._onMenuItemClick.bind(this),activate:this._onMenuOpen.bind(this),deactivate:this._onMenuClose.bind(this),showOn:"click",animation:!1};(!0===n||!1!==n&&(n.create||n.destroy||n.fields||n.parent))&&(e=((e,t)=>{var n="<ul>";return!0===t?(n+=F(e),n+=R(e),n+=L(e)):((t.fields||t.parent)&&(n+=F(e)),t.create&&(n+=R(e)),t.destroy&&(n+=L(e))),n})(i,n),this._menu=new o(e,r))},_dataSource:function(){var e=this.dataSource,t=this.options.dataSource;e&&(e.unbind(c,this._dataSourceChangeHandler),e.unbind(v,this._errorHandler),e.unbind(b,this._progressHandler),e.unbind(k,this._requestStartHandler)),this._dataSourceChangeHandler=this._onDataSourceChange.bind(this),this._errorHandler=this._onDataSourceError.bind(this),this._progressHandler=this._progress.bind(this),this._requestStartHandler=this._onDataSourceRequestStart.bind(this),(e=this.dataSource=r.create(t)).bind(c,this._dataSourceChangeHandler),e.bind(v,this._errorHandler),e.bind(b,this._progressHandler),e.bind(k,this._requestStartHandler),this.view.dataSource=e},_destroyItem:function(n){var i=this,r=e("<div></div>"),o=i.options.messages,a=this._confirmDestroy=new t.ui.Confirm(r,{title:o.destroyTitle,content:o.destroyContent,messages:{okText:o.destroy,cancel:o.cancel},show:function(){setTimeout((function(){a.element.trigger("focus")}))}});a.open(),a.result.done((function(){i.trigger(m,{dataItem:n})||(i.dataSource.remove(n),i.dataSource.sync()),i.view._shouldRestoreSelection=!0,i.view._restoreSelection()})),a.result.fail((function(){i.wrapper.find(x+A+"[tabindex=0],"+x+T+"[tabindex=0]").addClass(E).trigger("focus")}))},_edit:function(n){var i,r=this,o=e("<div>"),a=e("<div>"),s=this.options.messages,c=this._formOptions(n);c&&(r._form=new t.ui.Form(o,c),n.avatar&&r._avatarPreview(n),a.append(o),r._editWindow=new t.ui.Window(a,{title:s.edit,width:"380 px",modal:!0,close:function(e){i?i=!1:r.trigger(l,{dataItem:n})?e.preventDefault():r.cancelChanges()},deactivate:function(){r._editWindow.wrapper.off(d),r._editWindow.destroy(),r._editWindow=null,r.view._restoreSelection()}}),a.after(t.template(O)({save:s.save,cancel:s.cancel})),r._editWindow.center().open(),r._editWindow.wrapper.on(d,x+P,(function(){r._form.validate()&&(i=!0,r.trigger(y,{dataItem:n})||(r._editWindow.close(),r.saveChanges()))})),r._editWindow.wrapper.on(d,x+H,(function(){r._editWindow.close()})))},_formOptions:function(e){var t,n,i=this.options,r=i.messages,o=i.editable.form,s=[];return o&&(n=o.items),n&&0!==n.length||!(!0===i.editable||i.editable&&i.editable.parent)||(t=[{id:null,name:r.none}].concat(this.dataSource.prospectParents(e)),s.push({field:"parentId",editor:"DropDownList",label:r.parent,editorOptions:{dataSource:t,dataValueField:"id",dataTextField:"name",valuePrimitive:!0}})),n&&0!==n.length||!(!0===i.editable||i.editable&&i.editable.fields)||(s=s.concat([{field:"name",label:r.name,validation:{required:!0}},{field:"title",label:r.title},{field:"avatar",label:r.uploadAvatar,editor:this._uploadEditor.bind(this,e)}])),o&&delete o.formData,!!(s.length>0||n&&n.length>0)&&a(!0,{},{formData:e,items:s},o)},_onDataSourceChange:function(e){"add"===e.action||"itemchange"===e.action&&this._editWindow||(e.action&&"sync"!==e.action||!this.trigger(p,e)?(this._progress(!0),this.view.refresh(),e.action&&"sync"!==e.action||this.trigger(f),this._progress(!1)):this._progress(!1))},_onDataSourceError:function(){this._progress(!1)},_onDataSourceRequestStart:function(){this.view._cacheFocused()},_onMenuClose:function(){0===e(document.activeElement).closest("[role='alertdialog']").length&&this.wrapper.find("[tabindex='0']").addClass(E).trigger("focus")},_onMenuItemClick:function(t){var n,i=this,r=e(t.target).closest(x+D).find(x+A),o=i.dataItem(r),a=e(t.item).data("action");o&&(a===g?i.trigger(g,{dataItem:o})||i._edit(o):a===h?i.trigger(h,{dataItem:o})||(o.loaded()?(n=i.dataSource.add({parentId:o.id}),i._edit(n)):i.dataSource.read({id:o.id}).then((function(){n=i.dataSource.add({parentId:o.id}),i._edit(n)}))):"destroy"===a&&i._destroyItem(o))},_onMenuOpen:function(){this.view._cacheFocused(),this.wrapper.find(x+E).removeClass(E),this._menu.element.find(x+I).first().trigger("focus")},_openMenu:function(e){this._menu&&this._menu.open(e.find(x+M))},_progress:function(e){t.ui.progress(this.container,e)},_triggerCollapse:function(e){this.trigger(u,{item:e.item,dataItems:e.dataItems})&&e.preventDefault()},_triggerExpand:function(e){this.trigger(_,{item:e.item,dataItems:e.dataItems})&&e.preventDefault()},_triggerSelect:function(e){this.trigger(w,{item:e.item,dataItems:e.dataItems})||(this.view.select(e.item),this.trigger(c,{item:e.item,dataItems:e.dataItems}))},_uploadEditor:function(t,n){var i=this;e('<input type="file">').appendTo(n).kendoUpload({async:!1,multiple:!1,select:function(e){var n=e.files[0],r=n.rawFile,o=new FileReader;n.validationErrors&&n.validationErrors.length>0||r&&(o.onloadend=function(){t.set("avatar",this.result),i._avatarPreview(t,r.name)},o.readAsDataURL(r))},validation:{allowedExtensions:[".gif",".jpg",".png"],maxFileSize:1048576}})},_view:function(){null!==this.options.groupField&&undefined!==this.options.groupField?this.view=new t.orgChart.GroupedView(this.container,this.options):this.view=new t.orgChart.SingleView(this.container,this.options),this.view.bind(w,this._triggerSelect.bind(this)),this.view.bind(_,this._triggerExpand.bind(this)),this.view.bind(u,this._triggerCollapse.bind(this)),this.view.bind("menu",this._openMenu.bind(this))},_wrapper:function(){var t=e("<div class='k-orgchart-container'>");this.wrapper=this.element,this.container=t,this.wrapper.addClass(C),this.wrapper.append(t)}});t.ui.plugin(V)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Popup,i=t.ui.TooltipBase,r=e.extend,o=e(document),a=".kendoPopover",s=({index:e,text:n})=>t.html.renderButton(`<button ${e}>${n}</button>`,{fillMode:"flat",themeColor:"primary"}),l=({index:e,text:n,icon:i,iconClass:r})=>t.html.renderButton(`<button ${e}>${n}</button>`,{icon:i,iconClass:"k-button-icon"+(r?` ${r}`:"")}),c=({index:e,icon:n,iconClass:i})=>t.html.renderButton(`<button ${e}></button>`,{icon:n,iconClass:"k-button-icon"+(i?` ${i}`:"")}),d=({callout:e,dir:t})=>'<div role="tooltip" class="k-popover">'+(e?'<div class="k-popover-callout k-callout-'+t+'"></div><div class="k-popover-inner"></div>':"")+"</div>",u="show",h="hide",p={top:"bottom",bottom:"top",left:"right",right:"left",center:"center"},f={bottom:{origin:"bottom center",position:"top center"},top:{origin:"top center",position:"bottom center"},left:{origin:"center left",position:"center right",collision:"fit flip"},right:{origin:"center right",position:"center left",collision:"fit flip"},center:{position:"center center",origin:"center center"}},m={bottom:"n",top:"s",left:"e",right:"w",center:"n"},g={mouseenter:"mouseleave",focus:"blur",focusin:"focusout"},v={horizontal:{offset:"top",size:"outerHeight"},vertical:{offset:"left",size:"outerWidth"}},_=i.extend({init:function(n,r){var o,s=this;i.fn.init.call(s,n,r),o=s.options.position.match(/left|right/)?"horizontal":"vertical",s.dimensions=v[o],s._saveTitle=e.noop,s._documentKeyDownHandler=s._documentKeyDown.bind(s),s._actionsHandler=s._actionsClick.bind(s),s.options.toggleOnClick&&s._isShownOnClick()&&s.element.on((t.support.touch?t.support.mousedown:s.options.showOn)+a,s.options.filter,s._showAction.bind(s)),s._isShownOnClick()||s.element.on(g[s.options.showOn],s.options.filter,s._dismissAction.bind(s))},options:{name:"Popover",filter:"",actions:[],actionsLayout:"center",position:"bottom",showOn:"mouseenter",toggleOnClick:!1,width:null,height:null,animation:{open:{effects:"fade:in",duration:0},close:{duration:40,hide:!0}}},events:[u,h],_addAria:function(){var e,n=this,i=n.options;n._isShownOnClick()&&n.wrapper.find("a,input,select,textarea,button").length?(n.wrapper.attr("role","dialog"),n._isDialog=!0,i.header&&(e=t.guid(),n.wrapper.attr("aria-labelledby",e).find(".k-popover-header").attr("id",e)),i.body&&(e=t.guid(),n.wrapper.attr("aria-describedby",e).find(".k-popover-body").attr("id",e))):n.wrapper.attr("role","tooltip")},_appendContent:function(e){var n=this,i=n.options,r=n.wrapper.find(".k-popover-inner"),o=n.options.template,a=()=>"";r.length?r.children().remove():n.wrapper.children(":not(.k-popover-callout)").remove(),r=r.length?r:n.wrapper,o?r.append(t.template(o)({target:e})):r.append((({header:e,actions:t,body:n,positioning:i})=>(e?'<div class="k-popover-header">'+e+"</div>":"")+`<div class="k-popover-body">${n}</div>`+(t?'<div class="k-popover-actions k-actions k-actions-horizontal k-justify-content-'+i+'">'+t+"</div>":""))({header:t.template(i.header||a)({target:e}),body:t.template(i.body||a)({target:e}),actions:n._buildActions(i.actions),positioning:i.actionsLayout}))},_actionsClick:function(n){var i=this,r=i.options.actions,o=e(n.currentTarget),a=r[parseInt(o.attr(t.attr("index")),10)];a.click&&a.click.call(i,{sender:i,target:o})},_attachActions:function(){this.wrapper.on("click"+a,".k-popover-actions .k-button",this._actionsHandler)},_dettachActions:function(){var e=this;e.wrapper&&e.wrapper.off("click"+a,e._actionsHandler)},_buildActions:function(e){if(e.length){for(var n,i="",r=0;r<e.length;r++)(n=e[r]).text&&(n.icon||n.iconClass)?i+=t.template(l)({text:n.text,index:t.attr("index")+"="+r,icon:n.icon,iconClass:n.iconClass}):!n.icon&&!n.iconClass||n.text?i+=t.template(s)({text:n.text,index:t.attr("index")+"="+r}):i+=t.template(c)({index:t.attr("index")+"="+r,icon:n.icon,iconClass:n.iconClass});return i}},_documentKeyDown:function(e){if(e.keyCode===t.keys.ESC&&(this._shown=!1,this._dismissAction()),e.keyCode===t.keys.TAB){var n=this.wrapper.find(":kendoFocusable"),i=n.first(),r=n.last();e.shiftKey?document.activeElement===i[0]&&(r.trigger("focus"),e.preventDefault()):document.activeElement===r[0]&&(i.trigger("focus"),e.preventDefault())}},_initPopup:function(){var i=this,s=i.options,l=e(t.template(d)({callout:s.callout&&"center"!==s.position,dir:m[s.position]}));i.wrapper=l,i.popup=new n(l,r({activate:function(){i._offset(i.options.position,i.options.offset,28),i._positionCallout(),i._attachActions(),o.on("keydown"+a,i._documentKeyDownHandler),i._isDialog?i.wrapper.find(":kendoFocusable").first().trigger("focus"):i._addDescribedBy(),i.trigger(u),i.popup._hovered=undefined},close:function(e){i.options.toggleOnClick&&i._shown?e.preventDefault():i.trigger(h)},copyAnchorStyles:!1,animation:s.animation},f[s.position])),l.css({width:s.width,height:s.height}),i._isShownOnMouseEnter()&&l.on("mouseleave"+a,i._dismissAction.bind(i)),i.arrow=l.find(".k-popover-callout")},_dismissAction:function(){var e=this;clearTimeout(e.timeout),e.timeout=setTimeout((function(){e.popup&&!e.popup._hovered&&e.popup.close()}),e.options.hideAfter)},_showAction:function(){var e=this;e._shown=!e._shown,e._shown||e.popup.close()},_show:function(e){var t=this,n=t.target();t.popup||t._initPopup(),n&&n[0]!=e[0]&&(t.popup.close(),t.popup.element.parent().kendoStop(!0,!0)),n&&n[0]==e[0]||(t._appendContent(e),t._addAria(),t.popup.options.anchor=e),t.popup.one("deactivate",(function(){o.off("keydown"+a,t._documentKeyDownHandler),t._isDialog||(t._removeDescribedBy(t.target()),this.element.removeAttr("id")),t._dettachActions()})),t._openPopup()},_positionCallout:function(){var e=this,t=e.options.position,n=e.popup,i=m[n.flipped?p[t]:t];e.arrow.removeClass("k-callout-s k-callout-w k-callout-e k-callout-n").addClass("k-callout-"+i)},destroy:function(){this.element.off(a),this._dettachActions(),clearTimeout(this.timeout),o.off("keydown"+a,this._documentKeyDownHandler),i.fn.destroy.call(this)}});t.ui.plugin(_)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui.Widget,i=".k-icon,.k-svg-icon",r="k-avatar",o="k-avatar-bordered",a="icon",s="image",l="text",c=n.extend({init:function(e,t){t=t||{},n.fn.init.call(this,e,t),this._fromMarkup(),this._wrapper(),this._markupContent&&this._markupContent.length>0?this._contentFromMarkup():this._content()},options:{name:"Avatar",alt:null,border:!1,className:null,fillMode:"solid",icon:null,image:null,rounded:"full",size:"medium",style:null,text:null,themeColor:"primary",type:l},events:[],setOptions:function(t){var i=this.options,r=this.wrapper,a=e.extend({},i,t);n.fn.setOptions.call(this,t),a[a.type]||(i=this._optionsFromWrapper(i)),!1===a.border&&r.removeClass(o),r.empty(),this.options=i,this._wrapper(),this._content()},_content:function(){var n,i=this.wrapper.find("> span"),r=this.options,o=r.type;o===a?n=e(t.html.renderIcon({icon:r.icon})):o===s?(n=e("<img src='"+r.image+"'>"),r.alt&&n.attr("alt",r.alt)):o===l&&(n=e("<span>"+r.text+"</span>")),i.append(n)},_contentFromMarkup:function(){this.wrapper.find("> span").first().append(this._markupContent)},_fromMarkup:function(){var e,t,n=this.element,r=this.options;n.children().slice(1).remove(),e=n.children("img"),t=n.children(i),e.length>0?(r.type=s,this._markupContent=e.first()):t.length>0?(r.type=a,this._markupContent=t.first()):n.children().length>0&&(r.type=l,this._markupContent=n.children())},_optionsFromWrapper:function(e){var t,n=this.wrapper;return e.type===l?e.text=n.text().trim():e.type===a?n.find(i).attr("class").split(/\s+/).forEach((function(t){0===t.indexOf("k-i-")?e.icon=t.substring(4):0===t.indexOf("k-svg-i-")&&(e.icon=t.replace(/^k-svg-i-/,""))})):e.type===s&&(t=n.find("img"),e.image=t.attr("src"),t.attr("alt")&&(e.alt=t.attr("alt"))),e},_wrapper:function(){var t=this.element,n=this.options,i=e("<span>");this.wrapper=t,t.addClass(r),this._applyCssClasses(),n.border&&t.addClass(o),n.style&&t.css(n.style),n.className&&t.addClass(n.className),i.addClass(r+"-"+n.type),t.prepend(i)}});t.cssProperties.registerPrefix("Avatar","k-avatar-"),t.cssProperties.registerValues("Avatar",[{prop:"rounded",values:t.cssProperties.roundedValues.concat([["full","full"]])}]),t.ui.plugin(c)}(window.kendo.jQuery);kendo;var AH="arc",MH="ArrowUp",EH="ArrowDown",IH="ArrowLeft",zH="ArrowRight",PH="aria-activedescendant",HH="axisLabelClick",FH="#000",RH="bottom",LH="center",BH="circle",OH="cross",VH="date",NH="12px sans-serif",$H=10,UH=600,WH="end",jH="Enter",qH="Escape",GH=/\{\d+:?/,KH="height",YH="inside",QH="inherit",XH="left",ZH=Number.MAX_VALUE,JH=-Number.MAX_VALUE,eF="none",tF="noteClick",nF="noteHover",iF="noteLeave",rF="object",oF="outside",aF="right",sF="roundedRect",lF="start",cF="string",dF="top",uF="triangle",hF="square",pF="rect",fF="value",mF="#fff",gF="width",vF="x",_F="y",bF="pointer",yF="horizontal",wF="vertical",kF=Object.freeze({__proto__:null,ARC:AH,ARIA_ACTIVE_DESCENDANT:PH,ARROW_DOWN:EH,ARROW_LEFT:IH,ARROW_RIGHT:zH,ARROW_UP:MH,AXIS_LABEL_CLICK:HH,BLACK:FH,BOTTOM:RH,CENTER:LH,CIRCLE:BH,COORD_PRECISION:3,CROSS:OH,DATE:VH,DEFAULT_FONT:NH,DEFAULT_HEIGHT:400,DEFAULT_PRECISION:$H,DEFAULT_SERIES_OPACITY:1,DEFAULT_WIDTH:UH,END:WH,ENTER:jH,ESCAPE:qH,FORMAT_REGEX:GH,HEIGHT:KH,HIGHLIGHT_ZINDEX:100,HORIZONTAL:yF,INHERIT:QH,INSIDE:YH,LEFT:XH,MAX_VALUE:ZH,MIN_VALUE:JH,NONE:eF,NOTE_CLICK:tF,NOTE_HOVER:nF,NOTE_LEAVE:iF,OBJECT:rF,OUTSIDE:oF,POINTER:bF,RECT:pF,RIGHT:aF,ROUNDED_RECT:sF,SQUARE:hF,START:lF,STRING:cF,TAB:"Tab",TOP:dF,TRIANGLE:uF,VALUE:fF,VERTICAL:wF,WHITE:mF,WIDTH:gF,X:vF,Y:_F});function xF(e){return Array.isArray(e)}function CF(e,t){for(var n=xF(t)?t:[t],i=0;i<n.length;i++){var r=n[i];-1===e.className.indexOf(r)&&(e.className+=" "+r)}}var SF=/\s+/g;function TF(e,t){e&&e.className&&(e.className=e.className.replace(t,"").replace(SF," "))}function DF(e){var t=.5;e.options.stroke&&Zr(e.options.stroke.width)&&e.options.stroke.width%2==0&&(t=0);for(var n=0;n<e.segments.length;n++)e.segments[n].anchor().round(0).translate(t,t);return e}function AF(e,t){return-e.x*t.y+e.y*t.x<0}function MF(e){return"number"==typeof e&&!isNaN(e)}function EF(e){return typeof e===cF}function IF(e){return MF(e)||EF(e)&&isFinite(e)}function zF(e,t){return(e+1)%t}function PF(e,t){var n=e-1;return n<0?t-1:n}function HF(e,t){return 1===t||e%t==0?0:e<0?t+e%t:e>=t?e%t:e}function FF(e){return"function"==typeof e}var RF="object";function LF(e,t){for(var n in t)if("__proto__"!==n&&"constructor"!==n){var i=t[n],r=typeof i,o=void 0;if((o=r===RF&&null!==i?i.constructor:null)&&o!==Array)if(i instanceof Date)e[n]=new Date(i.getTime());else if(FF(i.clone))e[n]=i.clone();else{var a=e[n];e[n]=typeof a===RF&&a||{},LF(e[n],i)}else"undefined"!==r&&(e[n]=i)}return e}function BF(e){for(var t=arguments,n=arguments.length,i=1;i<n;i++)LF(e,t[i]);return e}function OF(e){return"object"==typeof e}function VF(e){return MF(e)?e+"px":e}var NF=/width|height|top|left|bottom|right/i;function $F(e){return NF.test(e)}function UF(e,t){var n=EF(t)?[t]:t;if(xF(n)){for(var i={},r=window.getComputedStyle(e),o=0;o<n.length;o++){var a=n[o];i[a]=$F(a)?parseFloat(r[a]):r[a]}return i}if(OF(t))for(var s in t)e.style[s]=VF(t[s])}function WF(e,t){void 0===t&&(t=0);var n={top:0,right:0,bottom:0,left:0};return"number"==typeof e?n[dF]=n[aF]=n[RH]=n[XH]=e:(n[dF]=e[dF]||t,n[aF]=e[aF]||t,n[RH]=e[RH]||t,n[XH]=e[XH]||t),n}var jF={compile:function(e){return e}},qF=function(){};function GF(e){var t;return void 0===e&&(e={}),e.template?e.template=t=qF.compile(e.template):FF(e.content)&&(t=e.content),t}function KF(e){var t;return void 0===e&&(e={}),e.ariaTemplate?e.ariaTemplate=t=qF.compile(e.ariaTemplate):FF(e.ariaContent)&&(t=e.ariaContent),t}qF.register=function(e){jF=e},qF.compile=function(e,t){return jF.compile(e,t)};var YF=/\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g,QF={};function XF(e){if(QF[e])return QF[e];var t=[];return e.replace(YF,(function(e,n,i,r){t.push(Zr(n)?n:i||r)})),QF[e]=function(e){for(var n=e,i=0;i<t.length&&n;i++)n=n[t[i]];return n},QF[e]}function ZF(e,t){for(var n=e.length,i=[],r=0;r<n;r++)t(e[r])&&i.push(e[r]);return i}function JF(e,t){if(e.className)for(var n=t.split(" "),i=0;i<n.length;i++)if(e.className.indexOf&&-1!==e.className.indexOf(n[i]))return!0}QF[void 0]=function(e){return e};var eR=function(){this._map=new Map};function tR(e,t){if(t)return-1!==t.indexOf(e)}function nR(e,t,n){return _o(e+(t-e)*n,3)}eR.prototype.get=function(e){return this._map.get(e)},eR.prototype.set=function(e,t){this._map.set(e,t)};var iR="trigger",rR=function(e,t){this.observer=e,this.handlerMap=BF({},this.handlerMap,t)};function oR(e){return"[object Object]"===Object.prototype.toString.call(e)}function aR(e,t){for(var n=e.length,i=[],r=0;r<n;r++){var o=t(e[r]);Zr(o)&&i.push(o)}return i}rR.prototype.trigger=function(e,t){var n,i=this.observer,r=this.handlerMap;return r[e]?n=this.callObserver(r[e],t):i[iR]&&(n=this.callObserver(iR,e,t)),n},rR.prototype.callObserver=function(e){for(var t=[],n=arguments.length-1;n-- >0;)t[n]=arguments[n+1];return this.observer[e].apply(this.observer,t)},rR.prototype.requiresHandlers=function(e){if(this.observer.requiresHandlers)return this.observer.requiresHandlers(e);for(var t=0;t<e.length;t++)if(this.handlerMap[e[t]])return!0};var sR=Ir.browser||{};function lR(e){var t=0;return e.wheelDelta?(t=-e.wheelDelta/120,sR.webkit&&(t/=2*Math.max(window.devicePixelRatio,.625))):e.detail&&(t=e.detail/3),t=t>0?Math.ceil(t):Math.floor(t)}var cR=Vo,dR=cR.append,uR=cR.bindEvents,hR=cR.defined,pR=cR.deg,fR=cR.elementOffset,mR=cR.elementSize,gR=cR.eventCoordinates,vR=cR.eventElement,_R=cR.hashKey,bR=cR.last,yR=cR.limitValue,wR=cR.objectKey,kR=cR.rad,xR=cR.round,CR=cR.unbindEvents,SR=cR.valueOrDefault,TR=function(){};function DR(e,t){var n=e.prototype;n.options?n.options=BF({},n.options,t):n.options=t}TR.fetchFonts=function(e,t,n){void 0===n&&(n={depth:0});!e||n.depth>5||!document.fonts||Object.keys(e).forEach((function(i){var r=e[i];"dataSource"!==i&&"$"!==i[0]&&r&&("font"===i?t.push(r):"object"==typeof r&&(n.depth++,TR.fetchFonts(r,t,n),n.depth--))}))},TR.loadFonts=function(e,t){var n=[];if(e.length>0&&document.fonts){try{n=e.map((function(e){return document.fonts.load(e)}))}catch(e){Ar(e)}Promise.all(n).then(t,t)}else t()},TR.preloadFonts=function(e,t){var n=[];TR.fetchFonts(e,n),TR.loadFonts(n,t)};var AR="k-i-",MR="k-svg-i-",ER=function(e,t){this.element=e,this.options=BF({},this.options,t),this.wrapper()};ER.prototype.wrapper=function(){this.addClasses()},ER.prototype.addClasses=function(){},ER.prototype.html=function(){return this.element.outerHTML},DR(ER,{name:"",size:"none",themeColor:"none",flip:"default",iconClass:"",stylingOptions:["size","themeColor","fill"]});var IR=function(e){function t(t,n){e.call(this,t,n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.wrapper=function(){var t=this.element.className.split(" ").find((function(e){return e.startsWith(AR)})),n=this.options.icon?""+(this.options.icon.startsWith(AR)?"":AR)+this.options.icon:"";this._className=n,CF(this.element,"k-icon"),CF(this.element,"k-font-icon"),TF(this.element,t),CF(this.element,n),CF(this.element,this.options.iconClass||""),e.prototype.wrapper.call(this)},t}(ER);DR(IR,{name:"HTMLFontIcon",icon:null});var zR=function(e){function t(t,n){t.innerHTML="",e.call(this,t,n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.wrapper=function(){var t=this.options.icon,n=this.options.iconClass,i=this.element.className.split(" ").find((function(e){return e.startsWith(MR)}));if(!t&&n){var r=n.match(/k-i-(\w+(?:-\w+)*)/);r&&(t=r[1],n=n.replace(r[0],""))}EF(t)&&(t=t.replace("k-i-","").replace(/-./g,(function(e){return e[1].toUpperCase()})),t=this.options.svgIcons[t]||this.options.svgIcons[t+"Icon"]);var o=t&&t.name?""+MR+t.name:"";if(this._className=o,CF(this.element,"k-svg-icon"),TF(this.element,i),CF(this.element,o),CF(this.element,n||""),this.element.setAttribute("aria-hidden","true"),t&&oR(t)){var a=document.createElementNS("http://www.w3.org/2000/svg","svg");a.setAttribute("viewBox",t.viewBox||""),a.setAttribute("focusable","false"),a.innerHTML=t.content||"",this.element.appendChild(a)}e.prototype.wrapper.call(this)},t}(ER);DR(zR,{name:"HTMLSvgIcon",icon:null,svgIcons:{}});var PR={svg:zR,font:IR};function HR(e,t){var n=e,i=t;return n&&(!OF(n)||n instanceof HTMLElement)&&!EF(n)||(i=n,n=document.createElement("span")),EF(i)&&(i={icon:i}),i.type||(i.type="svg"),PR[i.type]?new PR[i.type](n,i).html():null}function FR(e){for(var t=ZH,n=JH,i=0,r=e.length;i<r;i++){var o=e[i];null!==o&&isFinite(o)&&(t=Math.min(t,o),n=Math.max(n,o))}return{min:t===ZH?void 0:t,max:n===JH?void 0:n}}function RR(e,t){for(var n=0;n<e.length;n++){var i=e[n];if(t(i,n,e))return i}}var LR=Do,BR=/matrix\((.*)\)/;function OR(e){var t=getComputedStyle(e).transform;return"none"===t?LR.unit():function(e){var t=e.match(BR);if(null===t||2!==t.length)return LR.unit();var n=t[1].split(",").map((function(e){return parseFloat(e)}));return new(Function.prototype.bind.apply(LR,[null].concat(n)))}(t)}function VR(e){if(!e)return LR.unit();for(var t=OR(e),n=e.parentElement;n;){var i=OR(n);t=t.multiplyCopy(i),n=n.parentElement}return t.b=t.c=t.e=t.f=0,t}function NR(e){return new qr(e).isDark()?mF:FH}var $R={},UR=function(e){this._index={},this._values=e?e.slice(0):[];for(var t=0;t<this._values.length;t++)this._index[this._values[t]]=t},WR={size:{configurable:!0}};UR.prototype.values=function(){return this._values.filter((function(e){return e!==$R}))},UR.prototype.has=function(e){return void 0!==this._index[e]},UR.prototype.add=function(e){this.has(e)||(this._index[e]=this._values.length,this._values.push(e))},UR.prototype.delete=function(e){var t=this._index[e];void 0!==t&&(this._values[t]=$R,delete this._index[e])},UR.prototype.clear=function(){this._index={},this._values=[]},WR.size.get=function(){return this._values.length},Object.defineProperties(UR.prototype,WR);var jR=function(e){this._set=new Set(e)},qR={size:{configurable:!0}};jR.prototype.values=function(){return Array.from(this._set)},jR.prototype.has=function(e){return this._set.has(e)},jR.prototype.add=function(e){this._set.add(e)},jR.prototype.delete=function(e){this._set.delete(e)},jR.prototype.clear=function(){this._set.clear()},qR.size.get=function(){return this._set.size},Object.defineProperties(jR.prototype,qR);function GR(e){return t=!1,"function"==typeof Set&&(t=new Set([1]).has(1)),t?new jR(e):new UR(e);var t}function KR(e){throw e}var YR={INSERT:45,DELETE:46,BACKSPACE:8,TAB:9,ENTER:13,ESC:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,END:35,HOME:36,SPACEBAR:32,PAGEUP:33,PAGEDOWN:34,F2:113,F10:121,F12:123,NUMPAD_PLUS:107,NUMPAD_MINUS:109,NUMPAD_DOT:110};function QR(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var XR=function(){this.height=0,this.width=0,this.data=[]};XR.prototype.clone=function(){var e=new XR;return e.height=this.height,e.width=this.width,e.data=this.data.map((function(e){return e.slice()})),e},XR.prototype.get=function(e,t){var n=this.data[e];return n?n[t]:null},XR.prototype.set=function(e,t,n){var i=this.data[e];null==i&&(i=this.data[e]=[]),i[t]=n,e>=this.height&&(this.height=e+1),t>=this.width&&(this.width=t+1)},XR.prototype.each=function(e,t){for(var n=0;n<this.height;++n)for(var i=0;i<this.width;++i){var r=this.get(n,i);if((t||null!=r)&&void 0!==(r=e(r,n,i)))return r}},XR.prototype.map=function(e,t){var n=new XR;return this.each((function(t,i,r){n.set(i,r,e(t,i,r))}),t),n},XR.prototype.transpose=function(){var e=new XR;return this.each((function(t,n,i){e.set(i,n,t)})),e},XR.prototype.unit=function(e){this.width=this.height=e;for(var t=this.data=new Array(e),n=e;--n>=0;)for(var i=t[n]=new Array(e),r=e;--r>=0;)i[r]=n===r?1:0;return this},XR.prototype.multiply=function(e){for(var t=this,n=new XR,i=0;i<t.height;++i)for(var r=0;r<e.width;++r){for(var o=0,a=0;a<t.width;++a){var s=t.get(i,a),l=e.get(a,r);"number"==typeof s&&"number"==typeof l&&(o+=s*l)}n.set(i,r,o)}return n},XR.prototype.inverse=function(){for(var e=this.width,t=this.augment((new XR).unit(e)),n=t.data,i=function(t){var i=function(e,t,n){for(var i=n(e),r=e,o=e+1;o<t;o++){var a=n(e);a>i&&(i=a,r=e)}return r}(t,e,(function(e){return n[e][t]}));if(!n[i][t])return{v:null};if(t!==i){var r=n[t];n[t]=n[i],n[i]=r}for(var o=t+1;o<e;++o){for(var a=t+1;a<2*e;++a)n[o][a]-=n[t][a]*n[o][t]/n[t][t];n[o][t]=0}},r=0;r<e;++r){var o=i(r);if(o)return o.v}for(var a=0;a<e;++a)for(var s=n[a][a],l=0;l<2*e;++l)n[a][l]/=s;for(var c=e;--c>=0;)for(var d=c;--d>=0;)if(n[d][c])for(var u=2*e;--u>=e;)n[d][u]-=n[c][u]*n[d][c];return t.slice(0,e,e,e)},XR.prototype.augment=function(e){var t=this.clone(),n=t.width;return e.each((function(e,i,r){t.set(i,r+n,e)})),t},XR.prototype.slice=function(e,t,n,i){for(var r=new XR,o=0;o<n;++o)for(var a=0;a<i;++a)r.set(o,a,this.get(e+o,t+a));return r};var ZR={down:"pointerdown",move:"pointermove",up:"pointerup",cancel:"pointercancel pointerleave"};function JR(e){return ZR[e]||e}var eL=function(e){return e.replace(/([^ ]+)/g,JR)};function tL(){var e,t,n="";for(e=0;e<32;e++)t=16*Math.random()|0,8!==e&&12!==e&&16!==e&&20!==e||(n+="-"),n+=(12===e?4:16===e?3&t|8:t).toString(16);return n}var nL=new WeakMap,iL=Symbol("id");function rL(e,t,n,i,r){!function(e,t,n,i,r){var o=xF(t)?t:(t||"").split(" ");o.forEach((function(t){!function(e,t,n,i,r){var o,a=i;n&&FF(n)&&!i?a=n:n&&function(e){return"string"==typeof e}(n)&&FF(a)&&(o=n);var s=function(t){var n=t.target?t.target.closest(o):null;if(!o||o&&t.target&&n){var i=o?n:t.currentTarget;Object.defineProperty(t,"currentTarget",{value:i}),Object.defineProperty(t,"delegateTarget",{value:e}),a(t)}};a[iL]=tL();var l=nL.get(e);l||(l=new Map,nL.set(e,l));l.set(a[iL],s),e.addEventListener(t,s,Boolean(r))}(e,t,n,i,r)}))}(e,t,n,i,r)}function oL(e,t,n,i,r){!function(e,t,n,i){var r=xF(t)?t:(t||"").split(" ");r.forEach((function(t){!function(e,t,n,i){var r=nL.get(e);if(r&&n&&n[iL]){var o=n[iL],a=r.get(o);r.delete(o),a&&e.removeEventListener(t,a,Boolean(i))}}(e,t,n,i)}))}(e,t,n,i)}function aL(){var e=function(e){var t=!1,n={wp:/(Windows Phone(?: OS)?)\s(\d+)\.(\d+(\.\d+)?)/,fire:/(Silk)\/(\d+)\.(\d+(\.\d+)?)/,android:/(Android|Android.*(?:Opera|Firefox).*?\/)\s*(\d+)\.?(\d+(\.\d+)?)?/,iphone:/(iPhone|iPod).*OS\s+(\d+)[\._]([\d\._]+)/,ipad:/(iPad).*OS\s+(\d+)[\._]([\d_]+)/,playbook:/(PlayBook).*?Tablet\s*OS\s*(\d+)\.(\d+(\.\d+)?)/,windows:/(MSIE)\s+(\d+)\.(\d+(\.\d+)?)/,tizen:/(tizen).*?Version\/(\d+)\.(\d+(\.\d+)?)/i,sailfish:/(sailfish).*rv:(\d+)\.(\d+(\.\d+)?).*firefox/i},i={ios:/^i(phone|pad|pod)$/i,android:/^android|fire$/i,windows:/windows/,wp:/wp/,flat:/sailfish|ffos|tizen/i};for(var r in n){if(e.match(n[r])){if("windows"===r&&"plugins"in navigator)return!1;(t={}).device=r,t.name=sL(r,i),t[t.name]=!0;break}}return t}(navigator.userAgent),t={};return t.mobileOS=e,t}function sL(e,t,n){for(var i in t)if(t[i].test(e))return i;return void 0!==n?n:e}function lL(){}function cL(){return(new Date).getTime()}var dL="string",uL="function",hL=function(){this._defaultPrevented=!0},pL=function(){return!0===this._defaultPrevented},fL=function(e){function t(){e.call(this),this._events={}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this.unbind()},t.prototype.bind=function(e,t,n){var i,r,o,a,s=this,l=typeof e===dL?[e]:e||[],c=typeof t===uL;if(void 0===t){for(i in e)s.bind(i,e[i]);return s}var d=function(){var e=l[i];(a=c?t:t[e])&&(n&&(o=a,a=function(){s.unbind(e,a),o.apply(s,arguments)},a.original=o),(s._events[e]=s._events[e]||[]).push(a))};for(i=0,r=l.length;i<r;i++)d();return s},t.prototype.one=function(e,t){return this.bind(e,t,!0)},t.prototype.first=function(e,t){var n,i,r,o=this,a=typeof e===dL?[e]:e,s=typeof t===uL;for(n=0,i=a.length;n<i;n++){var l=a[n];(r=s?t:t[l])&&(o._events[l]=o._events[l]||[]).unshift(r)}return o},t.prototype.trigger=function(e,t){var n,i,r=this,o=r._events[e];if(o){var a=t||{};for(a.sender=r,a._defaultPrevented=!1,a.preventDefault=hL,a.isDefaultPrevented=pL,n=0,i=(o=o.slice()).length;n<i;n++)o[n].call(r,a);return!0===a._defaultPrevented}return!1},t.prototype.unbind=function(e,t){var n,i=this,r=i._events[e];if(void 0===e)i._events={};else if(r)if(t)for(n=r.length-1;n>=0;n--)r[n]!==t&&r[n].original!==t||r.splice(n,1);else i._events[e]=[];return i},t.prototype._setEvents=function(e){for(var t=this,n=(this.events||[]).length,i=0;i<n;i++){var r=t.events[i];t.options[r]&&e[r]&&(t.unbind(r,t.options[r]),t._events&&t._events[r]&&delete t._events[r])}this.bind(this.events,e)},t}(fr),mL=Object.assign,gL=function(e){e.preventDefault()},vL=800,_L=0,bL="press",yL="hold",wL="select",kL="start",xL="move",CL="end",SL="cancel",TL="tap",DL="doubleTap",AL="release",ML="gesturechange",EL="gestureend",IL="gesturetap",zL={api:0,touch:0,mouse:9,pointer:9};function PL(e){var t=[],n=e.originalEvent||e,i=e.currentTarget;return e.api?t.push({id:2,event:e,target:e.target,currentTarget:e.target,location:e,type:"api"}):t.push({location:n,event:e,target:e.target,currentTarget:i,id:n.pointerId,type:"pointer"}),t}var HL=function(e){function t(t,n){e.call(this);var i=this;i.support=aL(),i.invalidZeroEvents=this.support.mobileOS&&this.support.mobileOS.android,i.axis=t,i._updateLocationData(n),i.startLocation=i.location,i.velocity=i.delta=0,i.timeStamp=cL()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.move=function(e){var t=this,n=e["page"+t.axis],i=cL(),r=i-t.timeStamp||1;!n&&this.invalidZeroEvents||(t.delta=n-t.location,t._updateLocationData(e),t.initialDelta=n-t.startLocation,t.velocity=t.delta/r,t.timeStamp=i)},t.prototype._updateLocationData=function(e){var t=this,n=t.axis;t.location=e["page"+n],t.client=e["client"+n],t.screen=e["screen"+n]},t}(fr),FL=function(e){function t(t,n,i){e.call(this),mL(this,{x:new HL("X",i.location),y:new HL("Y",i.location),type:i.type,threshold:t.threshold||zL[i.type],userEvents:t,target:n,currentTarget:i.currentTarget,initialTouch:i.target,id:i.id,pressEvent:i,_clicks:t._clicks,supportDoubleTap:t.supportDoubleTap,_moved:!1,_finished:!1})}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.press=function(){var e=this;this._holdTimeout=setTimeout((function(){return e._hold()}),this.userEvents.minHold),this._trigger(bL,this.pressEvent)},t.prototype._tap=function(e){var t=this;t.userEvents._clicks++,1===t.userEvents._clicks&&(t._clickTimeout=setTimeout((function(){1===t.userEvents._clicks?t._trigger(TL,e):t._trigger(DL,e),t.userEvents._clicks=0}),300))},t.prototype._hold=function(){this._trigger(yL,this.pressEvent)},t.prototype.move=function(e){var t=this,n="api"!==e.type&&t.userEvents._shouldNotMove;if(!t._finished&&!n){if(t.x.move(e.location),t.y.move(e.location),!t._moved){if(t._withinIgnoreThreshold())return;if(LL.current&&LL.current!==t.userEvents)return t.dispose();t._start(e)}t._finished||t._trigger(xL,e)}},t.prototype.end=function(e){this.endTime=cL(),this._finished||(this._finished=!0,this._trigger(AL,e),this._moved?this._trigger(CL,e):this.supportDoubleTap?this._tap(e):this._trigger(TL,e),clearTimeout(this._holdTimeout),this.dispose())},t.prototype.dispose=function(){var e=this.userEvents.touches||[];this._finished=!0,this.pressEvent=null,clearTimeout(this._holdTimeout);var t=e.indexOf(this);e.splice(t,1)},t.prototype.skip=function(){this.dispose()},t.prototype.cancel=function(){this.dispose()},t.prototype.isMoved=function(){return this._moved},t.prototype._start=function(e){clearTimeout(this._holdTimeout),this.startTime=cL(),this._moved=!0,this._trigger(kL,e)},t.prototype._trigger=function(e,t){var n=t.event,i={touch:this,x:this.x,y:this.y,target:this.target,event:n};this.userEvents.notify(e,i)&&n.preventDefault()},t.prototype._withinIgnoreThreshold=function(){var e=this.x.initialDelta,t=this.y.initialDelta;return Math.sqrt(e*e+t*t)<=this.threshold},t}(fr);function RL(e){for(var t=ZR.up.split(" "),n=0,i=t.length;n<i;n++)e(t[n])}var LL=function(e){function t(t,n){e.call(this);var i,r=this,o=aL();if(this.support=o,n=n||{},this.options=n,i=r.filter=n.filter,r.threshold=n.threshold||_L,r.minHold=n.minHold||vL,r.touches=[],r._maxTouches=n.multiTouch?2:1,r.allowSelection=n.allowSelection,r.captureUpIfMoved=n.captureUpIfMoved,r._clicks=0,r.supportDoubleTap=n.supportDoubleTap,mL(r,{element:t,surface:n.surface||t,stopPropagation:n.stopPropagation,pressed:!1}),this._surfaceMoveHandler=this._move.bind(this),rL(r.surface,eL("move"),this._surfaceMoveHandler),this._surfaceEndHandler=this._end.bind(this),rL(r.surface,eL("up cancel"),this._surfaceEndHandler),this._elementStartHandler=this._start.bind(this),rL(t,eL("down"),i,this._elementStartHandler),t.style["touch-action"]=n.touchAction||"none",n.preventDragEvent&&(this._elementDragStartHandler=gL,rL(t,eL("dragstart"),this._elementDragStartHandler)),this._elementSelectHandler=this._select.bind(this),rL(t,eL("mousedown"),i,this._elementSelectHandler),r.captureUpIfMoved){var a=r.surface,s=r.preventIfMoving.bind(r);RL((function(e){a.addEventListener(e,s,!0)}))}r.bind([bL,yL,TL,DL,kL,xL,CL,AL,SL,"gesturestart",ML,EL,IL,wL],n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.preventIfMoving=function(e){this._isMoved()&&e.preventDefault()},t.prototype.destroy=function(){var e=this,t=this.options,n=this.element;if(!e._destroyed){if(e._destroyed=!0,e.captureUpIfMoved){var i=e.surface;RL((function(t){i.removeEventListener(t,e.preventIfMoving)}))}oL(e.surface,eL("move"),this._surfaceMoveHandler),oL(e.surface,eL("up cancel"),this._surfaceEndHandler),oL(n,eL("down"),this._elementStartHandler),t.preventDragEvent&&oL(n,eL("dragstart"),this._elementDragStartHandler),oL(n,eL("mousedown"),this._elementSelectHandler),e._disposeAll(),e.unbind(),delete e.surface,delete e.element,delete e.currentTarget}},t.prototype.capture=function(){t.current=this},t.prototype.cancel=function(){this._disposeAll(),this.trigger(SL)},t.prototype.notify=function(e,t){var n,i,r,o,a,s,l,c,d=this.touches,u=e;if(this._isMultiTouch()){switch(u){case xL:u=ML;break;case CL:u=EL;break;case TL:u=IL}mL(t,{touches:d},(n=d[0],i=d[1],r=n.x.location,o=n.y.location,a=i.x.location,s=i.y.location,l=r-a,c=o-s,{center:{x:(r+a)/2,y:(o+s)/2},distance:Math.sqrt(l*l+c*c)}))}return this.trigger(u,mL(t,{type:u}))},t.prototype.press=function(e,t,n){this._apiCall("_start",e,t,n)},t.prototype.move=function(e,t){this._apiCall("_move",e,t)},t.prototype.end=function(e,t){this._apiCall("_end",e,t)},t.prototype._isMultiTouch=function(){return this.touches.length>1},t.prototype._maxTouchesReached=function(){return this.touches.length>=this._maxTouches},t.prototype._disposeAll=function(){for(var e=this.touches;e.length>0;)e.pop().dispose()},t.prototype._isMoved=function(){return ZF(this.touches,(function(e){return e.isMoved()})).length},t.prototype._select=function(e){this.allowSelection&&!this.trigger(wL,{event:e})||e.preventDefault()},t.prototype._start=function(e){var n=this;if(!(e.which&&e.which>1||this._maxTouchesReached())){var i;t.current=null,this.currentTarget=e.currentTarget,this.stopPropagation&&e.stopPropagation();for(var r=PL(e),o=0;o<r.length&&!n._maxTouchesReached();o++){var a=r[o];if(!(i=n.filter?a.currentTarget:n.element)||0!==i.length){var s=new FL(n,i,a);n.touches.push(s),s.press(),n._isMultiTouch()&&n.notify("gesturestart",{})}}}},t.prototype._move=function(e){this._eachTouch("move",e)},t.prototype._end=function(e){this._eachTouch("end",e)},t.prototype._eachTouch=function(e,t){var n,i,r,o,a={},s=PL(t),l=this.touches;for(n=0;n<l.length;n++)a[(i=l[n]).id]=i;for(n=0;n<s.length;n++){if(o=a[(r=s[n]).id])"move"===e&&"pointer"===r.type&&!this.surface.hasPointerCapture(r.id)&&this.surface.setPointerCapture(r.id),o[e](r)}},t.prototype._apiCall=function(e,t,n,i){this[e]({api:!0,pageX:t,pageY:n,clientX:t,clientY:n,target:i||this.element,stopPropagation:lL,preventDefault:lL})},t.defaultThreshold=function(e){_L=e},t.minHold=function(e){vL=e},t}(fL);function BL(e,t){var n=xR(t-e,9);if(0===n){if(0===t)return.1;n=Math.abs(t)}var i=Math.pow(10,Math.floor(Math.log(n)/Math.log(10))),r=xR(n/i,$H);return xR(i*(r<1.904762?.2:r<4.761904?.5:r<9.523809?1:2),$H)}var OL=function(e){function t(t,n){e.call(this),this.x=t||0,this.y=n||0}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.clone=function(){return new t(this.x,this.y)},t.prototype.equals=function(e){return e&&this.x===e.x&&this.y===e.y},t.prototype.rotate=function(e,t){var n=kR(t),i=Math.cos(n),r=Math.sin(n),o=e.x,a=e.y,s=this.x,l=this.y;return this.x=xR(o+(s-o)*i+(l-a)*r,3),this.y=xR(a+(l-a)*i-(s-o)*r,3),this},t.prototype.multiply=function(e){return this.x*=e,this.y*=e,this},t.prototype.distanceTo=function(e){var t=this.x-e.x,n=this.y-e.y;return Math.sqrt(t*t+n*n)},t.onCircle=function(e,n,i){var r=kR(n);return new t(e.x-i*Math.cos(r),e.y-i*Math.sin(r))},t}(fr),VL=function(e){function t(t,n,i,r){e.call(this),this.x1=t||0,this.y1=n||0,this.x2=i||0,this.y2=r||0}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.equals=function(e){return this.x1===e.x1&&this.x2===e.x2&&this.y1===e.y1&&this.y2===e.y2},t.prototype.width=function(){return this.x2-this.x1},t.prototype.height=function(){return this.y2-this.y1},t.prototype.translate=function(e,t){return this.x1+=e,this.x2+=e,this.y1+=t,this.y2+=t,this},t.prototype.move=function(e,t){var n=this.height(),i=this.width();return hR(e)&&(this.x1=e,this.x2=this.x1+i),hR(t)&&(this.y1=t,this.y2=this.y1+n),this},t.prototype.wrap=function(e){return this.x1=Math.min(this.x1,e.x1),this.y1=Math.min(this.y1,e.y1),this.x2=Math.max(this.x2,e.x2),this.y2=Math.max(this.y2,e.y2),this},t.prototype.wrapPoint=function(e){var n=xF(e),i=n?e[0]:e.x,r=n?e[1]:e.y;return this.wrap(new t(i,r,i,r)),this},t.prototype.snapTo=function(e,t){return t!==vF&&t||(this.x1=e.x1,this.x2=e.x2),t!==_F&&t||(this.y1=e.y1,this.y2=e.y2),this},t.prototype.alignTo=function(e,t){var n=this.height(),i=this.width(),r=t===dF||t===RH?_F:vF,o=r===_F?n:i;if(t===LH){var a=e.center(),s=this.center();this.x1+=a.x-s.x,this.y1+=a.y-s.y}else this[r+1]=t===dF||t===XH?e[r+1]-o:e[r+2];return this.x2=this.x1+i,this.y2=this.y1+n,this},t.prototype.shrink=function(e,t){return this.x2-=e,this.y2-=t,this},t.prototype.expand=function(e,t){return this.shrink(-e,-t),this},t.prototype.pad=function(e){var t=WF(e);return this.x1-=t.left,this.x2+=t.right,this.y1-=t.top,this.y2+=t.bottom,this},t.prototype.unpad=function(e){var t=WF(e);return t.left=-t.left,t.top=-t.top,t.right=-t.right,t.bottom=-t.bottom,this.pad(t)},t.prototype.clone=function(){return new t(this.x1,this.y1,this.x2,this.y2)},t.prototype.center=function(){return new OL(this.x1+this.width()/2,this.y1+this.height()/2)},t.prototype.containsPoint=function(e){return e.x>=this.x1&&e.x<=this.x2&&e.y>=this.y1&&e.y<=this.y2},t.prototype.points=function(){return[new OL(this.x1,this.y1),new OL(this.x2,this.y1),new OL(this.x2,this.y2),new OL(this.x1,this.y2)]},t.prototype.getHash=function(){return[this.x1,this.y1,this.x2,this.y2].join(",")},t.prototype.overlaps=function(e){return!(e.y2<this.y1||this.y2<e.y1||e.x2<this.x1||this.x2<e.x1)},t.prototype.rotate=function(e){var t=this.width(),n=this.height(),i=this.center(),r=i.x,o=i.y,a=NL(0,0,r,o,e),s=NL(t,0,r,o,e),l=NL(t,n,r,o,e),c=NL(0,n,r,o,e);return t=Math.max(a.x,s.x,l.x,c.x)-Math.min(a.x,s.x,l.x,c.x),n=Math.max(a.y,s.y,l.y,c.y)-Math.min(a.y,s.y,l.y,c.y),this.x2=this.x1+t,this.y2=this.y1+n,this},t.prototype.toRect=function(){return new Yo([this.x1,this.y1],[this.width(),this.height()])},t.prototype.hasSize=function(){return 0!==this.width()&&0!==this.height()},t.prototype.align=function(e,t,n){var i=t+1,r=t+2,o=t===vF?gF:KH,a=this[o]();tR(n,[XH,dF])?(this[i]=e[i],this[r]=this[i]+a):tR(n,[aF,RH])?(this[r]=e[r],this[i]=this[r]-a):n===LH&&(this[i]=e[i]+(e[o]()-a)/2,this[r]=this[i]+a)},t}(fr);function NL(e,t,n,i,r){var o=kR(r);return new OL(n+(e-n)*Math.cos(o)+(t-i)*Math.sin(o),i-(e-n)*Math.sin(o)+(t-i)*Math.cos(o))}var $L=function(e){function t(t,n,i,r,o){e.call(this),this.center=t,this.innerRadius=n,this.radius=i,this.startAngle=r,this.angle=o}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.clone=function(){return new t(this.center,this.innerRadius,this.radius,this.startAngle,this.angle)},t.prototype.middle=function(){return this.startAngle+this.angle/2},t.prototype.setRadius=function(e,t){return t?this.innerRadius=e:this.radius=e,this},t.prototype.point=function(e,t){var n=kR(e),i=Math.cos(n),r=Math.sin(n),o=t?this.innerRadius:this.radius,a=xR(this.center.x-i*o,3),s=xR(this.center.y-r*o,3);return new OL(a,s)},t.prototype.adjacentBox=function(e,t,n){var i=this.clone().expand(e),r=i.middle(),o=i.point(r),a=t/2,s=n/2,l=Math.sin(kR(r)),c=Math.cos(kR(r)),d=o.x-a,u=o.y-s;return Math.abs(l)<.9&&(d+=a*-c/Math.abs(c)),Math.abs(c)<.9&&(u+=s*-l/Math.abs(l)),new VL(d,u,d+t,u+n)},t.prototype.containsPoint=function(e){var t=this.center,n=this.innerRadius,i=this.radius,r=this.startAngle,o=this.startAngle+this.angle,a=e.x-t.x,s=e.y-t.y,l=new OL(a,s),c=this.point(r),d=new OL(c.x-t.x,c.y-t.y),u=this.point(o),h=new OL(u.x-t.x,u.y-t.y),p=xR(a*a+s*s,3);return(d.equals(l)||AF(d,l))&&!AF(h,l)&&p>=n*n&&p<=i*i},t.prototype.getBBox=function(){var e,t=new VL(ZH,ZH,JH,JH),n=xR(this.startAngle%360),i=xR((n+this.angle)%360),r=this.innerRadius,o=[0,90,180,270,n,i].sort(UL),a=o.indexOf(n),s=o.indexOf(i);e=n===i?o:a<s?o.slice(a,s+1):[].concat(o.slice(0,s+1),o.slice(a,o.length));for(var l=0;l<e.length;l++){var c=this.point(e[l]);t.wrapPoint(c),t.wrapPoint(c,r)}return r||t.wrapPoint(this.center),t},t.prototype.expand=function(e){return this.radius+=e,this},t}(fr);function UL(e,t){return e-t}var WL=function(e){function t(t,n,i,r){e.call(this,t,0,n,i,r)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.expand=function(t){return e.prototype.expand.call(this,t)},t.prototype.clone=function(){return new t(this.center,this.radius,this.startAngle,this.angle)},t.prototype.setRadius=function(e){return this.radius=e,this},t}($L),jL=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createRing=function(e,t){var n=e.startAngle+180,i=e.angle+n;(0===e.angle||e.angle>0&&n===i)&&(i+=.001);var r=new Go(e.center.x,e.center.y),o=Math.max(e.radius,0),a=Math.max(e.innerRadius,0),s=new ga(r,{startAngle:n,endAngle:i,radiusX:o,radiusY:o}),l=us.fromArc(s,t).close();if(a){s.radiusX=s.radiusY=a;var c=s.pointAt(i);l.lineTo(c.x,c.y),l.arc(i,n,a,a,!0)}else l.lineTo(r.x,r.y);return l},t}(fr);jL.current=new jL;var qL=function(e){function t(t){e.call(this),this.children=[],this.options=BF({},this.options,this.initUserOptions(t))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initUserOptions=function(e){return e},t.prototype.reflow=function(e){for(var t,n=this.children,i=0;i<n.length;i++){var r=n[i];r.reflow(e),t=t?t.wrap(r.box):r.box.clone()}this.box=t||e},t.prototype.destroy=function(){var e=this.children;this.animation&&this.animation.destroy();for(var t=0;t<e.length;t++)e[t].destroy()},t.prototype.getRoot=function(){var e=this.parent;return e?e.getRoot():null},t.prototype.getSender=function(){var e=this.getService();if(e)return e.sender},t.prototype.getService=function(){for(var e=this;e;){if(e.chartService)return e.chartService;e=e.parent}},t.prototype.translateChildren=function(e,t){for(var n=this.children,i=n.length,r=0;r<i;r++)n[r].box.translate(e,t)},t.prototype.append=function(){for(var e=arguments,t=0;t<arguments.length;t++){var n=e[t];this.children.push(n),n.parent=this}},t.prototype.renderVisual=function(){!1!==this.options.visible&&(this.createVisual(),this.addVisual(),this.renderChildren(),this.createAnimation(),this.renderComplete())},t.prototype.addVisual=function(){this.visual&&(this.visual.chartElement=this,this.parent&&this.parent.appendVisual(this.visual))},t.prototype.renderChildren=function(){for(var e=this.children,t=e.length,n=0;n<t;n++)e[n].renderVisual()},t.prototype.createVisual=function(){this.visual=new vs({zIndex:this.options.zIndex,visible:SR(this.options.visible,!0)})},t.prototype.createAnimation=function(){this.visual&&this.options.animation&&(this.animation=nl.create(this.visual,this.options.animation))},t.prototype.appendVisual=function(e){e.chartElement||(e.chartElement=this),e.options.noclip?this.clipRoot().visual.append(e):hR(e.options.zIndex)?this.stackRoot().stackVisual(e):this.isStackRoot?this.stackVisual(e):this.visual?this.visual.append(e):this.parent.appendVisual(e)},t.prototype.clipRoot=function(){return this.parent?this.parent.clipRoot():this},t.prototype.stackRoot=function(){return this.parent?this.parent.stackRoot():this},t.prototype.stackVisual=function(e){var t,n=e.options.zIndex||0,i=this.visual.children,r=i.length;for(t=0;t<r;t++){var o=i[t];if(SR(o.options.zIndex,0)>n)break}this.visual.insert(t,e)},t.prototype.traverse=function(e){for(var t=this.children,n=t.length,i=0;i<n;i++){var r=t[i];e(r),r.traverse&&r.traverse(e)}},t.prototype.closest=function(e){for(var t=this,n=!1;t&&!n;)(n=e(t))||(t=t.parent);if(n)return t},t.prototype.renderComplete=function(){},t.prototype.hasHighlight=function(){var e=(this.options||{}).highlight;return!(!this.createHighlight||e&&!1===e.visible||!1===this.visible)},t.prototype.toggleHighlight=function(e,t){var n=this,i=(this.options||{}).highlight||{},r=i.visual,o=this._highlight;if(!o){var a={fill:{color:mF,opacity:t||.2},stroke:{color:mF,width:1,opacity:t||.2}};if(r){if(!(o=this._highlight=r(Object.assign(this.highlightVisualArgs(),{createVisual:function(){return n.createHighlight(a)},sender:this.getSender(),series:this.series,dataItem:this.dataItem,category:this.category,value:this.value,percentage:this.percentage,runningTotal:this.runningTotal,total:this.total}))))return}else o=this._highlight=this.createHighlight(a);hR(o.options.zIndex)||(o.options.zIndex=SR(i.zIndex,this.options.zIndex)),this.appendVisual(o)}o.visible(e)},t.prototype.toggleFocusHighlight=function(e){var t=((this.options||{}).accessibility||{}).highlight||{},n=this._focusHighlight;if(e||n){if(!n){var i=NR(this.getRoot().options.background),r={fill:{opacity:t.opacity,color:t.color},stroke:Object.assign({},{color:i},t.border),zIndex:t.zIndex};n=this._focusHighlight=this.createFocusHighlight(r),this.appendVisual(n)}n.visible(e)}},t.prototype.createGradientOverlay=function(e,t,n){var i=new us(Object.assign({stroke:{color:"none"},fill:this.createGradient(n),closed:e.options.closed},t));return i.segments.elements(e.segments.elements()),i},t.prototype.createGradient=function(e){if(this.parent)return this.parent.createGradient(e)},t.prototype.supportsPointInactiveOpacity=function(){return!0},t}(fr);qL.prototype.options={};var GL={dots:Gs,verticalStripes:Ks,crosshatch:Ys,diagonalStripes:Qs,grid:Xs};function KL(e,t,n){var i=function(e,t){return FF(e)?e(t):e}(e,n),r=i&&GL[i.type];return r?r(Object.assign({},t,i)):t}var YL=function(e){function t(t){e.call(this,t),this.options.margin=WF(this.options.margin),this.options.padding=WF(this.options.padding)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(t){var n,i=this,r=this.options,o=r.width,a=r.height,s=r.shrinkToFit,l=o&&a,c=r.margin,d=r.padding,u=r.border.width,h=function(){i.align(t,vF,r.align),i.align(t,_F,r.vAlign),i.paddingBox=n.clone().unpad(c).unpad(u)},p=t.clone();l&&(p.x2=p.x1+o,p.y2=p.y1+a),s&&p.unpad(c).unpad(u).unpad(d),e.prototype.reflow.call(this,p),n=l?this.box=new VL(0,0,o,a):this.box,s&&l?(h(),p=this.contentBox=this.paddingBox.clone().unpad(d)):(p=this.contentBox=n.clone(),n.pad(d).pad(u).pad(c),h()),this.translateChildren(n.x1-p.x1+c.left+u+d.left,n.y1-p.y1+c.top+u+d.top);for(var f=this.children,m=0;m<f.length;m++){var g=f[m];g.reflow(g.box)}},t.prototype.align=function(e,t,n){this.box.align(e,t,n)},t.prototype.hasBox=function(){var e=this.options;return e.border.width||e.background},t.prototype.createVisual=function(){e.prototype.createVisual.call(this),this.options.visible&&this.hasBox()&&this.visual.append(us.fromRect(this.paddingBox.toRect(),this.visualStyle()))},t.prototype.visualStyle=function(){var e=this.options,t=e.border||{};return{stroke:{width:t.width,color:t.color,opacity:SR(t.opacity,e.opacity),dashType:t.dashType},fill:KL(e.pattern,{color:e.background,opacity:e.opacity},void 0),cursor:e.cursor}},t}(qL);function QL(e,t){t&&(e.options.className=t.className,e.options.role=t.role,e.options.ariaLabel=t.ariaLabel,e.options.ariaRoleDescription=t.ariaRoleDescription,e.options.ariaChecked=t.ariaChecked)}DR(YL,{align:XH,vAlign:dF,margin:{},padding:{},border:{color:FH,width:0},background:"",shrinkToFit:!1,width:0,height:0,visible:!0});var XL=function(e){function t(t,n){e.call(this,t),this.pointData=n}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getElement=function(){var e=this.options,t=this.paddingBox,n=e.type,i=e.rotation,r=t.center(),o=t.width()/2,a=t.height()/2;if(!e.visible||!this.hasBox())return null;var s,l=this.visualStyle();if(n===BH)s=new ua(new oa([xR(t.x1+o,3),xR(t.y1+a,3)],Math.min(o,a)),l);else if(n===uF)s=us.fromPoints([[t.x1+o,t.y1],[t.x1,t.y2],[t.x2,t.y2]],l).close();else if(n===OH)(s=new hs(l)).moveTo(t.x1,t.y1).lineTo(t.x2,t.y2),s.moveTo(t.x1,t.y2).lineTo(t.x2,t.y1);else{var c=t.toRect();if(n===sF){var d=SR(e.borderRadius,c.width()/5);c.setCornerRadius(d)}s=us.fromRect(c,l)}return i&&s.transform(Xo().rotate(-i,[r.x,r.y])),s.options.zIndex=e.zIndex,s},t.prototype.createElement=function(){var e=this,t=this.options.visual,n=this.pointData||{};return t?t({value:n.value,dataItem:n.dataItem,sender:this.getSender(),series:n.series,category:n.category,rect:this.paddingBox.toRect(),options:this.visualOptions(),createVisual:function(){return e.getElement()}}):this.getElement()},t.prototype.visualOptions=function(){var e=this.options;return{background:e.background,border:e.border,margin:e.margin,padding:e.padding,type:e.type,size:e.width,visible:e.visible}},t.prototype.createVisual=function(){this.visual=this.createElement(),QL(this.visual,this.options.accessibilityOptions)},t}(YL);DR(XL,{type:BH,align:LH,vAlign:LH});var ZL="radial",JL={glass:{type:"linear",rotation:0,stops:[{offset:0,color:mF,opacity:0},{offset:.25,color:mF,opacity:.3},{offset:1,color:mF,opacity:0}]},sharpBevel:{type:ZL,stops:[{offset:0,color:mF,opacity:.55},{offset:.65,color:mF,opacity:0},{offset:.95,color:mF,opacity:.25}]},roundedBevel:{type:ZL,stops:[{offset:.33,color:mF,opacity:.06},{offset:.83,color:mF,opacity:.2},{offset:.95,color:mF,opacity:0}]},roundedGlass:{type:ZL,supportVML:!1,stops:[{offset:0,color:mF,opacity:0},{offset:.5,color:mF,opacity:.3},{offset:.99,color:mF,opacity:0}]},sharpGlass:{type:ZL,supportVML:!1,stops:[{offset:0,color:mF,opacity:.2},{offset:.15,color:mF,opacity:.15},{offset:.17,color:mF,opacity:.35},{offset:.85,color:mF,opacity:.05},{offset:.87,color:mF,opacity:.15},{offset:.99,color:mF,opacity:0}]},bubbleShadow:{type:ZL,center:[.5,.5],radius:.5}};function eB(e,t){if(e.x1===t.x1&&e.y1===t.y1&&e.x2===t.x2&&e.y2===t.y2)return t;var n=Math.min(e.x1,t.x1),i=Math.max(e.x1,t.x1),r=Math.min(e.x2,t.x2),o=Math.max(e.x2,t.x2),a=Math.min(e.y1,t.y1),s=Math.max(e.y1,t.y1),l=Math.min(e.y2,t.y2),c=Math.max(e.y2,t.y2),d=[];return d[0]=new VL(i,a,r,s),d[1]=new VL(n,s,i,l),d[2]=new VL(r,s,o,l),d[3]=new VL(i,l,r,c),e.x1===n&&e.y1===a||t.x1===n&&t.y1===a?(d[4]=new VL(n,a,i,s),d[5]=new VL(r,l,o,c)):(d[4]=new VL(r,a,o,s),d[5]=new VL(n,l,i,c)),ZF(d,(function(e){return e.height()>0&&e.width()>0}))[0]}var tB=function(e){function t(t){e.call(this,t);var n=this.options;n.width=parseInt(n.width,10),n.height=parseInt(n.height,10),this.gradients={}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(){var e=this.options,t=this.children,n=new VL(0,0,e.width,e.height);this.box=n.unpad(e.margin);for(var i=0;i<t.length;i++)t[i].reflow(n),n=eB(n,t[i].box)||new VL},t.prototype.createVisual=function(){this.visual=new vs,this.createBackground()},t.prototype.createBackground=function(){var e=this.options,t=e.border||{},n=this.box.clone().pad(e.margin).unpad(t.width),i=us.fromRect(n.toRect(),{stroke:{color:t.width?t.color:"",width:t.width,dashType:t.dashType},fill:{color:e.background,opacity:e.opacity},zIndex:-10});this.visual.append(i)},t.prototype.getRoot=function(){return this},t.prototype.createGradient=function(e){var t,n=this.gradients,i=wR(e),r=JL[e.gradient];if(n[i])t=n[i];else{var o=Object.assign({},r,e);"linear"===r.type?t=new Rs(o):(e.innerRadius&&(o.stops=function(e){for(var t=e.stops,n=e.innerRadius/e.radius*100,i=t.length,r=[],o=0;o<i;o++){var a=Object.assign({},t[o]);a.offset=(a.offset*(100-n)+n)/100,r.push(a)}return r}(o)),(t=new Ls(o)).supportVML=!1!==r.supportVML),n[i]=t}return t},t.prototype.cleanGradients=function(){var e=this.gradients;for(var t in e)e[t]._observers=[]},t.prototype.size=function(){var e=this.options;return new VL(0,0,e.width,e.height)},t}(qL);DR(tB,{width:UH,height:400,background:mF,border:{color:FH,width:0},margin:WF(5),zIndex:-2});var nB=function(e){function t(t){e.call(this,t),this._initDirection()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._initDirection=function(){var e=this.options;e.vertical?(this.groupAxis=vF,this.elementAxis=_F,this.groupSizeField=gF,this.elementSizeField=KH,this.groupSpacing=e.spacing,this.elementSpacing=e.vSpacing):(this.groupAxis=_F,this.elementAxis=vF,this.groupSizeField=KH,this.elementSizeField=gF,this.groupSpacing=e.vSpacing,this.elementSpacing=e.spacing)},t.prototype.reflow=function(e){this.box=e.clone(),this.reflowChildren()},t.prototype.reflowChildren=function(){var e=this,t=this,n=t.box,i=t.elementAxis,r=t.groupAxis,o=t.elementSizeField,a=t.groupSizeField,s=this.groupOptions(),l=s.groups,c=s.groupsSize,d=s.maxGroupElementsSize,u=l.length,h=n[r+1]+this.alignStart(c,n[a]());if(u){for(var p=h,f=0;f<u;f++){for(var m=l[f],g=m.groupElements,v=n[i+1],_=g.length,b=0;b<_;b++){var y=g[b],w=e.elementSize(y),k=p+e.alignStart(w[a],m.groupSize),x=new VL;x[r+1]=k,x[r+2]=k+w[a],x[i+1]=v,x[i+2]=v+w[o],y.reflow(x),v+=w[o]+e.elementSpacing}p+=m.groupSize+e.groupSpacing}n[r+1]=h,n[r+2]=h+c,n[i+2]=n[i+1]+d}},t.prototype.alignStart=function(e,t){var n=0,i=this.options.align;return i===aF||i===RH?n=t-e:i===LH&&(n=(t-e)/2),n},t.prototype.groupOptions=function(){for(var e=this,t=e.box,n=e.children,i=e.elementSizeField,r=e.groupSizeField,o=e.elementSpacing,a=e.groupSpacing,s=xR(t[i]()),l=n.length,c=[],d=0,u=0,h=0,p=0,f=[],m=0;m<l;m++){var g=n[m];g.box||g.reflow(t);var v=this.elementSize(g);this.options.wrap&&xR(u+o+v[i])>s&&(c.push({groupElements:f,groupSize:d,groupElementsSize:u}),p=Math.max(p,u),h+=a+d,d=0,u=0,f=[]),d=Math.max(d,v[r]),u>0&&(u+=o),u+=v[i],f.push(g)}return c.push({groupElements:f,groupSize:d,groupElementsSize:u}),{groups:c,groupsSize:h+=d,maxGroupElementsSize:p=Math.max(p,u)}},t.prototype.elementSize=function(e){return{width:e.box.width(),height:e.box.height()}},t.prototype.createVisual=function(){},t}(qL);DR(nB,{vertical:!0,wrap:!0,vSpacing:0,spacing:0});var iB=fs,rB=function(e){function t(t,n){e.call(this,n),this.content=t,this.reflow(new VL)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(e){var t=this.options,n=t.size=Oo(this.content,{font:t.font});this.baseline=n.baseline,this.box=new VL(e.x1,e.y1,e.x1+n.width,e.y1+n.height)},t.prototype.createVisual=function(){var e=this.options,t=e.font,n=e.color,i=e.opacity,r=e.cursor,o=e.stroke,a=e.paintOrder;this.visual=new iB(this.content,this.box.toRect().topLeft(),{font:t,fill:{color:n,opacity:i},cursor:r,stroke:o,paintOrder:a})},t}(qL);function oB(e){var t=e.origin,n=e.bottomRight();return new VL(t.x,t.y,n.x,n.y)}DR(rB,{font:NH,color:FH});var aB=/\n/m,sB=function(e){function t(t,n,i){e.call(this,n),this.content=t,this.data=i,this._initContainer(),!1!==this.options._autoReflow&&this.reflow(new VL)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._initContainer=function(){var e=this.options,t=String(this.content).split(aB),n=new nB({vertical:!0,align:e.align,wrap:!1}),i=BF({},e,{opacity:1,animation:null});this.container=n,this.append(n);for(var r=0;r<t.length;r++){var o=new rB(t[r].trim(),i);n.append(o)}},t.prototype.reflow=function(t){var n=this.options,i=n.visual;if(this.container.options.align=n.align,i&&!this._boxReflow){var r=t;r.hasSize()||(this._boxReflow=!0,this.reflow(r),this._boxReflow=!1,r=this.box);var o=this.visual=i(this.visualContext(r));o&&(r=oB(o.clippedBBox()||new Yo),o.options.zIndex=n.zIndex),this.box=this.contentBox=this.paddingBox=r}else if(e.prototype.reflow.call(this,t),n.rotation){var a=WF(n.margin),s=this.box.unpad(a);this.targetBox=t,this.normalBox=s.clone(),(s=this.rotate()).translate(a.left-a.right,a.top-a.bottom),this.rotatedBox=s.clone(),s.pad(a)}},t.prototype.createVisual=function(){var e=this.options;if(this.visual=new vs({transform:this.rotationTransform(),zIndex:e.zIndex,noclip:e.noclip}),this.hasBox()){var t=us.fromRect(this.paddingBox.toRect(),this.visualStyle());this.visual.append(t)}},t.prototype.renderVisual=function(){if(this.options.visible)if(this.options.visual){var t=this.visual;t&&!hR(t.options.noclip)&&(t.options.noclip=this.options.noclip),this.addVisual(),this.createAnimation()}else e.prototype.renderVisual.call(this)},t.prototype.visualContext=function(e){var t=this,n={text:this.content,rect:e.toRect(),sender:this.getSender(),options:this.options,createVisual:function(){return t._boxReflow=!0,t.reflow(e),t._boxReflow=!1,t.getDefaultVisual()}};return this.data&&Object.assign(n,this.data),n},t.prototype.getDefaultVisual=function(){this.createVisual(),this.renderChildren();var e=this.visual;return delete this.visual,e},t.prototype.rotate=function(){var e=this.options;return this.box.rotate(e.rotation),this.align(this.targetBox,vF,e.align),this.align(this.targetBox,_F,e.vAlign),this.box},t.prototype.rotationTransform=function(){var e=this.options.rotation;if(!e)return null;var t=this.normalBox.center(),n=t.x,i=t.y,r=this.rotatedBox.center();return Xo().translate(r.x-n,r.y-i).rotate(e,[n,i])},t}(YL),lB=function(e){function t(t){e.call(this,t),this._textBox=new sB(this.options.text,Object.assign({},this.options,{vAlign:this.options.position})),this.append(this._textBox)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(t){e.prototype.reflow.call(this,t),this.box.snapTo(t,vF)},t.buildTitle=function(e,n){var i,r=e;return"string"==typeof e&&(r={text:e}),(r=Object.assign({visible:!0},n,r))&&r.visible&&r.text&&(i=new t(r)),i},t.orderTitles=function(e){var t=[].concat(e),n=t.filter((function(e){return e&&e.options.position!==RH})),i=t.filter((function(e){return e&&e.options.position===RH}));return cB(n),cB(i),i.reverse(),n.concat(i)},t}(qL);function cB(e){for(var t=1;t<e.length;t++){var n=e[t]._textBox,i=e[t-1]._textBox;i.options.margin=Object.assign(WF(i.options.margin),{bottom:0}),n.options.margin=Object.assign(WF(n.options.margin),{top:0})}}DR(lB,{color:FH,position:dF,align:LH,margin:WF(5),padding:WF(5)});var dB=function(e){function t(t,n,i,r,o){e.call(this,n,o),this.text=n,this.value=t,this.index=i,this.dataItem=r,this.reflow(new VL)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.visualContext=function(t){var n=e.prototype.visualContext.call(this,t);return n.value=this.value,n.dataItem=this.dataItem,n.format=this.options.format,n.culture=this.options.culture,n},t.prototype.click=function(e,t){e.trigger(HH,{element:vR(t),value:this.value,text:this.text,index:this.index,dataItem:this.dataItem,axis:this.parent.options})},t.prototype.rotate=function(){if(this.options.alignRotation!==LH){var t=this.normalBox.toRect(),n=this.rotationTransform();this.box=oB(t.bbox(n.matrix()))}else e.prototype.rotate.call(this);return this.box},t.prototype.rotationTransform=function(){var t=this.options,n=t.rotation;if(!n)return null;if(t.alignRotation===LH)return e.prototype.rotationTransform.call(this);var i=Xo().rotate(n).matrix(),r=this.normalBox.toRect(),o=this.targetBox.toRect(),a=t.rotationOrigin||dF,s=a===dF||a===RH?vF:_F,l=a===dF||a===RH?_F:vF,c=a===dF||a===XH?o.origin:o.bottomRight(),d=r.topLeft().transformCopy(i),u=r.topRight().transformCopy(i),h=r.bottomRight().transformCopy(i),p=r.bottomLeft().transformCopy(i),f=Yo.fromPoints(d,u,h,p),m={};m[l]=o.origin[l]-f.origin[l];var g,v,_=Math.abs(d[l]+m[l]-c[l]),b=Math.abs(u[l]+m[l]-c[l]);xR(_,$H)===xR(b,$H)?(g=d,v=u):b<_?(g=u,v=h):(g=d,v=p);var y=g[s]+(v[s]-g[s])/2;return m[s]=o.center()[s]-y,Xo().translate(m.x,m.y).rotate(n)},t}(sB);DR(dB,{_autoReflow:!1});var uB=function(e){function t(t,n,i){e.call(this,n),this.fields=t,this.chartService=i,this.render()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.hide=function(){this.options.visible=!1},t.prototype.show=function(){this.options.visible=!0},t.prototype.render=function(){var e=this,t=this.options;if(t.visible){var n,i,r=t.label,o=t.icon,a=new VL,s=function(){return e},l=o.size,c=this.fields.text;if(hR(r)&&r.visible){var d=GF(r);d?c=d(this.fields):r.format&&(c=this.chartService.format.auto(r.format,c)),r.color||(r.color=r.position===YH?"#fff":o.background),this.label=new sB(c,BF({},r)),this.label.aliasFor=s,r.position!==YH||hR(l)||(o.type===BH?l=Math.max(this.label.box.width(),this.label.box.height()):(n=this.label.box.width(),i=this.label.box.height()),a.wrap(this.label.box))}o.width=n||l||7,o.height=i||l||7;var u=new XL(BF({},o));u.aliasFor=s,this.marker=u,this.append(u),this.label&&this.append(this.label),u.reflow(new VL),this.wrapperBox=a.wrap(u.box)}},t.prototype.reflow=function(e){var t,n,i,r=this,o=r.options,a=r.label,s=r.marker,l=r.wrapperBox,c=e.center(),d=o.line.length,u=o.position;o.visible&&(tR(u,[XH,aF])?u===XH?(i=l.alignTo(e,u).translate(-d,e.center().y-l.center().y),o.line.visible&&(t=[e.x1,c.y],this.linePoints=[t,[i.x2,c.y]],n=i.clone().wrapPoint(t))):(i=l.alignTo(e,u).translate(d,e.center().y-l.center().y),o.line.visible&&(t=[e.x2,c.y],this.linePoints=[t,[i.x1,c.y]],n=i.clone().wrapPoint(t))):u===RH?(i=l.alignTo(e,u).translate(e.center().x-l.center().x,d),o.line.visible&&(t=[c.x,e.y2],this.linePoints=[t,[c.x,i.y1]],n=i.clone().wrapPoint(t))):(i=l.alignTo(e,u).translate(e.center().x-l.center().x,-d),o.line.visible&&(t=[c.x,e.y1],this.linePoints=[t,[c.x,i.y2]],n=i.clone().wrapPoint(t))),s&&s.reflow(i),a&&(a.reflow(i),s&&(o.label.position===oF&&a.box.alignTo(s.box,u),a.reflow(a.box))),this.contentBox=i,this.targetBox=e,this.box=n||i)},t.prototype.createVisual=function(){e.prototype.createVisual.call(this),this.visual.options.noclip=this.options.noclip,this.options.visible&&this.createLine()},t.prototype.renderVisual=function(){var t=this,n=this.options,i=n.visual;n.visible&&i?(this.visual=i(Object.assign(this.fields,{sender:this.getSender(),rect:this.targetBox.toRect(),options:{background:n.background,border:n.background,icon:n.icon,label:n.label,line:n.line,position:n.position,visible:n.visible},createVisual:function(){t.createVisual(),t.renderChildren();var e=t.visual;return delete t.visual,e}})),this.addVisual()):e.prototype.renderVisual.call(this)},t.prototype.createLine=function(){var e=this.options.line;if(this.linePoints){var t=us.fromPoints(this.linePoints,{stroke:{color:e.color,width:e.width,dashType:e.dashType}});DF(t),this.visual.append(t)}},t.prototype.click=function(e,t){var n=this.eventArgs(t);e.trigger(tF,n)||t.preventDefault()},t.prototype.over=function(e,t){var n=this.eventArgs(t);e.trigger(nF,n)||t.preventDefault()},t.prototype.out=function(e,t){var n=this.eventArgs(t);e.trigger(iF,n)},t.prototype.eventArgs=function(e){var t=this.options;return Object.assign(this.fields,{element:vR(e),text:hR(t.label)?t.label.text:"",visual:this.visual})},t}(YL);DR(uB,{icon:{visible:!0,type:BH},label:{position:YH,visible:!0,align:LH,vAlign:LH},line:{visible:!0},visible:!0,position:dF,zIndex:2});var hB={format:function(e,t){return t},toString:function(e){return e},parseDate:function(e){return new Date(e)},firstDay:function(){return 0}},pB=hB,fB=function(){},mB={implementation:{configurable:!0}};fB.register=function(e){pB=e},mB.implementation.get=function(){return pB},Object.defineProperties(fB,mB);var gB=/\{(\d+)(:[^\}]+)?\}/g,vB=function(e){this._intlService=e},_B={intl:{configurable:!0}};_B.intl.get=function(){return this._intlService||fB.implementation},_B.intl.set=function(e){this._intlService=e},vB.prototype.auto=function(e){for(var t=[],n=arguments.length-1;n-- >0;)t[n]=arguments[n+1];var i=this.intl;return EF(e)&&e.match(GH)?i.format.apply(i,[e].concat(t)):i.toString(t[0],e)},vB.prototype.localeAuto=function(e,t,n){var i,r=this.intl;return i=EF(e)&&e.match(GH)?e.replace(gB,(function(e,i,o){var a=t[parseInt(i,10)];return r.toString(a,o?o.substring(1):"",n)})):r.toString(t[0],e,n),i},Object.defineProperties(vB.prototype,_B);var bB,yB=function(e,t){void 0===t&&(t={}),this._intlService=t.intlService,this.sender=t.sender||e,this.format=new vB(t.intlService),this.chart=e,this.rtl=Boolean(t.rtl)},wB={intl:{configurable:!0}};wB.intl.get=function(){return this._intlService||fB.implementation},wB.intl.set=function(e){this._intlService=e,this.format.intl=e},yB.prototype.notify=function(e,t){this.chart&&this.chart.trigger(e,t)},yB.prototype.isPannable=function(e){var t=((this.chart||{}).options||{}).pannable;return t&&t.lock!==e},Object.defineProperties(yB.prototype,wB);var kB=function(){};kB.register=function(e){bB=e},kB.create=function(e,t){return bB?bB.create(e,t):new LL(e,Object.assign({},{multiTouch:!0},t))};var xB=Object.freeze({__proto__:null,ChartService:yB,DomEventsBuilder:kB,FormatService:vB,IntlService:fB,TemplateService:qF});function CB(e,t){var n=e.tickX,i=e.tickY,r=e.position,o=new us({stroke:{width:t.width,color:t.color}});return e.vertical?o.moveTo(n,r).lineTo(n+t.size,r):o.moveTo(r,i).lineTo(r,i+t.size),DF(o),o}function SB(e,t){var n=e.lineStart,i=e.lineEnd,r=e.position,o=new us({stroke:{width:t.width,color:t.color,dashType:t.dashType}});return e.vertical?o.moveTo(n,r).lineTo(i,r):o.moveTo(r,n).lineTo(r,i),DF(o),o}var TB=function(e){function t(t,n){void 0===n&&(n=new yB),e.call(this,t),this.chartService=n,this.options.visible||(this.options=BF({},this.options,{labels:{visible:!1},line:{visible:!1},margin:0,majorTickSize:0,minorTickSize:0})),this.options.minorTicks=BF({},{color:this.options.line.color,width:this.options.line.width,visible:this.options.minorTickType!==eF},this.options.minorTicks,{size:this.options.minorTickSize,align:this.options.minorTickType}),this.options.majorTicks=BF({},{color:this.options.line.color,width:this.options.line.width,visible:this.options.majorTickType!==eF},this.options.majorTicks,{size:this.options.majorTickSize,align:this.options.majorTickType}),this.initFields(),this.options._deferLabels||this.createLabels(),this.createTitle(),this.createNotes()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initFields=function(){},t.prototype.labelsRange=function(){return{min:this.options.labels.skip,max:this.labelsCount()}},t.prototype.normalizeLabelRotation=function(e){var t=e.rotation;OF(t)&&(e.alignRotation=t.align,e.rotation=t.angle)},t.prototype.createLabels=function(){var e=this,t=this.options,n=t.vertical?aF:LH,i=BF({},t.labels,{align:n,zIndex:t.zIndex}),r=Math.max(1,i.step);if(this.clearLabels(),i.visible){this.normalizeLabelRotation(i),"auto"===i.rotation&&(i.rotation=0,t.autoRotateLabels=!0);for(var o=this.labelsRange(),a=o.min;a<o.max;a+=r){var s={index:a,count:o.max},l=e.createAxisLabel(a,i,s);l&&(e.append(l),e.labels.push(l))}}},t.prototype.clearLabels=function(){this.children=ZF(this.children,(function(e){return!(e instanceof dB)})),this.labels=[]},t.prototype.clearTitle=function(){var e=this;this.title&&(this.children=ZF(this.children,(function(t){return t!==e.title})),this.title=void 0)},t.prototype.clear=function(){this.clearLabels(),this.clearTitle()},t.prototype.lineBox=function(){var e=this.options,t=this.box,n=e.vertical,i=e.labels.mirror,r=i?t.x1:t.x2,o=i?t.y2:t.y1,a=e.line.width||0;return n?new VL(r,t.y1,r,t.y2-a):new VL(t.x1,o,t.x2-a,o)},t.prototype.createTitle=function(){var e=this.options,t=BF({rotation:e.vertical?-90:0,text:"",zIndex:1,visualSize:!0},e.title);if(t.visible&&t.text){var n=new sB(t.text,t);this.append(n),this.title=n}},t.prototype.createNotes=function(){var e=this,t=this.options,n=t.notes,i=n.data||[];this.notes=[];for(var r=0;r<i.length;r++){var o=BF({},n,i[r]);o.value=e.parseNoteValue(o.value);var a=new uB({value:o.value,text:o.label.text,dataItem:o},o,e.chartService);a.options.visible&&(hR(a.options.position)?t.vertical&&!tR(a.options.position,[XH,aF])?a.options.position=t.reverse?XH:aF:t.vertical||tR(a.options.position,[dF,RH])||(a.options.position=t.reverse?RH:dF):t.vertical?a.options.position=t.reverse?XH:aF:a.options.position=t.reverse?RH:dF,e.append(a),e.notes.push(a))}},t.prototype.parseNoteValue=function(e){return e},t.prototype.renderVisual=function(){e.prototype.renderVisual.call(this),this.createPlotBands()},t.prototype.createVisual=function(){e.prototype.createVisual.call(this),this.createBackground(),this.createLine()},t.prototype.gridLinesVisual=function(){var e=this._gridLines;return e||(e=this._gridLines=new vs({zIndex:-2}),this.appendVisual(this._gridLines)),e},t.prototype.createTicks=function(e){var t=this.options,n=this.lineBox(),i=t.labels.mirror,r=t.majorTicks.visible?t.majorUnit:0,o={vertical:t.vertical};function a(t,r,a){var s=t.length,l=Math.max(1,r.step);if(r.visible)for(var c=r.skip;c<s;c+=l)hR(a)&&c%a==0||(o.tickX=i?n.x2:n.x2-r.size,o.tickY=i?n.y1-r.size:n.y1,o.position=t[c],e.append(CB(o,r)))}a(this.getMajorTickPositions(),t.majorTicks),a(this.getMinorTickPositions(),t.minorTicks,r/t.minorUnit)},t.prototype.createLine=function(){var e=this.options,t=e.line,n=this.lineBox();if(t.width>0&&t.visible){var i=new us({stroke:{width:t.width,color:t.color,dashType:t.dashType}});i.moveTo(n.x1,n.y1).lineTo(n.x2,n.y2),e._alignLines&&DF(i);var r=this._lineGroup=new vs;r.append(i),this.visual.append(r),this.createTicks(r)}},t.prototype.getActualTickSize=function(){var e=this.options,t=0;return e.majorTicks.visible&&e.minorTicks.visible?t=Math.max(e.majorTicks.size,e.minorTicks.size):e.majorTicks.visible?t=e.majorTicks.size:e.minorTicks.visible&&(t=e.minorTicks.size),t},t.prototype.createBackground=function(){var e=this.options,t=this.box,n=e.background;n&&(this._backgroundPath=us.fromRect(t.toRect(),{fill:{color:n},stroke:null}),this.visual.append(this._backgroundPath))},t.prototype.createPlotBands=function(){var e=this,t=this.options,n=t.plotBands||[],i=t.vertical,r=this.plotArea;if(0!==n.length){for(var o=this._plotbandGroup=new vs({zIndex:-1}),a=ZF(this.pane.axes,(function(t){return t.options.vertical!==e.options.vertical}))[0],s=0;s<n.length;s++){var l=n[s],c=void 0,d=void 0,u=l.label,h=void 0;if(i?(c=(a||r.axisX).lineBox(),d=e.getSlot(l.from,l.to,!0)):(c=e.getSlot(l.from,l.to,!0),d=(a||r.axisY).lineBox()),u&&(u.vAlign=u.position||XH,h=e.createPlotBandLabel(u,l,new VL(c.x1,d.y1,c.x2,d.y2))),0!==c.width()&&0!==d.height()){var p=new Yo([c.x1,d.y1],[c.width(),d.height()]),f=us.fromRect(p,{fill:{color:l.color,opacity:l.opacity},stroke:null});o.append(f),h&&o.append(h)}}this.appendVisual(o)}},t.prototype.createPlotBandLabel=function(e,t,n){if(!1===e.visible)return null;var i,r=e.text;if(hR(e)&&e.visible){var o=GF(e);o?r=o({text:r,item:t}):e.format&&(r=this.chartService.format.auto(e.format,r)),e.color||(e.color=this.options.labels.color)}return(i=new sB(r,e)).reflow(n),i.renderVisual(),i.visual},t.prototype.createGridLines=function(e){var t=this.options,n=t.minorGridLines,i=t.majorGridLines,r=t.minorUnit,o=t.vertical,a=e.options.line.visible,s=i.visible?t.majorUnit:0,l=e.lineBox(),c=l[o?"y1":"x1"],d={lineStart:l[o?"x1":"y1"],lineEnd:l[o?"x2":"y2"],vertical:o},u=[],h=this.gridLinesVisual();function p(e,t,n){var i=e.length,r=Math.max(1,t.step);if(t.visible)for(var o=t.skip;o<i;o+=r){var s=xR(e[o]);tR(s,u)||o%n==0||a&&c===s||(d.position=s,h.append(SB(d,t)),u.push(s))}}return p(this.getMajorTickPositions(),i),p(this.getMinorTickPositions(),n,s/r),h.children},t.prototype.reflow=function(e){for(var t=this,n=t.options,i=t.labels,r=t.title,o=n.vertical,a=i.length,s=o?gF:KH,l=r?r.box[s]():0,c=this.getActualTickSize()+n.margin+l,d=((this.getRoot()||{}).box||e)[s](),u=0,h=0;h<a;h++){var p=i[h].box[s]();p+c<=d&&(u=Math.max(u,p))}this.box=o?new VL(e.x1,e.y1,e.x1+u+c,e.y2):new VL(e.x1,e.y1,e.x2,e.y1+u+c),this.arrangeTitle(),this.arrangeLabels(),this.arrangeNotes()},t.prototype.getLabelsTickPositions=function(){return this.getMajorTickPositions()},t.prototype.labelTickIndex=function(e){return e.index},t.prototype.arrangeLabels=function(){for(var e=this.options,t=this.labels,n=this.labelsBetweenTicks(),i=e.vertical,r=e.labels.mirror,o=this.getLabelsTickPositions(),a=0;a<t.length;a++){var s=t[a],l=this.labelTickIndex(s),c=i?s.box.height():s.box.width(),d=o[l],u=o[l+1],h=void 0,p=void 0;if(i){if(n)h=d+(u-d)/2-c/2;else h=d-c/2;p=h}else n?(h=d,p=u):p=(h=d-c/2)+c;this.positionLabel(s,r,h,p)}},t.prototype.positionLabel=function(e,t,n,i){void 0===i&&(i=n);var r,o=this.options,a=o.vertical,s=this.lineBox(),l=this.getActualTickSize()+o.margin;if(a){var c=s.x2;t?(c+=l,e.options.rotationOrigin=XH):(c-=l+e.box.width(),e.options.rotationOrigin=aF),r=e.box.move(c,n)}else{var d=s.y1;t?(d-=l+e.box.height(),e.options.rotationOrigin=RH):(d+=l,e.options.rotationOrigin=dF),r=new VL(n,d,i,d+e.box.height())}e.reflow(r)},t.prototype.autoRotateLabelAngle=function(e,t){return e.width()<t?0:e.height()>t?-90:-45},t.prototype.autoRotateLabels=function(){if(!this.options.autoRotateLabels||this.options.vertical)return!1;for(var e=this.getMajorTickPositions(),t=this.labels,n=Math.min(t.length,e.length-1),i=0,r=0;r<n;r++){var o=Math.abs(e[r+1]-e[r]),a=t[r].box,s=this.autoRotateLabelAngle(a,o);if(0!==s&&(i=s),-90===i)break}if(0!==i){for(var l=0;l<t.length;l++)t[l].options.rotation=i,t[l].reflow(new VL);return!0}},t.prototype.arrangeTitle=function(){var e=this.options,t=this.title,n=e.labels.mirror,i=e.vertical;t&&(i?(t.options.align=n?aF:XH,t.options.vAlign=t.options.position):(t.options.align=t.options.position,t.options.vAlign=n?dF:RH),t.reflow(this.box))},t.prototype.arrangeNotes=function(){for(var e=this,t=0;t<this.notes.length;t++){var n=e.notes[t],i=n.options.value,r=void 0;hR(i)?(e.shouldRenderNote(i)?n.show():n.hide(),r=e.noteSlot(i)):n.hide(),n.reflow(r||e.lineBox())}},t.prototype.noteSlot=function(e){return this.getSlot(e)},t.prototype.alignTo=function(e){var t=e.lineBox(),n=this.options.vertical,i=n?_F:vF;this.box.snapTo(t,i),n?this.box.shrink(0,this.lineBox().height()-t.height()):this.box.shrink(this.lineBox().width()-t.width(),0),this.box[i+1]-=this.lineBox()[i+1]-t[i+1],this.box[i+2]-=this.lineBox()[i+2]-t[i+2]},t.prototype.axisLabelText=function(e,t,n){var i,r=this,o=GF(t),a=function(){return t.format?r.chartService.format.localeAuto(t.format,[e],t.culture):e};o?i=o(Object.assign({},n,{get text(){return a()},value:e,format:t.format,culture:t.culture})):i=a();return i},t.prototype.slot=function(e,t,n){var i=this.getSlot(e,t,n);if(i)return i.toRect()},t.prototype.contentBox=function(){var e=this.box.clone(),t=this.labels;if(t.length){var n=this.options.vertical?_F:vF;if(this.chartService.isPannable(n)){var i=this.maxLabelOffset();e[n+1]-=i.start,e[n+2]+=i.end}else{t[0].options.visible&&e.wrap(t[0].box);var r=t[t.length-1];r.options.visible&&e.wrap(r.box)}}return e},t.prototype.maxLabelOffset=function(){for(var e=this.options,t=e.vertical,n=e.reverse,i=this.labelsBetweenTicks(),r=this.getLabelsTickPositions(),o=t?_F:vF,a=this.labels,s=n?1:0,l=n?0:1,c=0,d=0,u=0;u<a.length;u++){var h=a[u],p=this.labelTickIndex(h),f=void 0,m=void 0;i?(f=r[p+s],m=r[p+l]):f=m=r[p],c=Math.max(c,f-h.box[o+1]),d=Math.max(d,h.box[o+2]-m)}return{start:c,end:d}},t.prototype.limitRange=function(e,t,n,i,r){var o=this.options;if(e<n&&r<0&&(!hR(o.min)||o.min<=n)||i<t&&r>0&&(!hR(o.max)||i<=o.max))return null;if(t<n&&r>0||i<e&&r<0)return{min:e,max:t};var a=t-e,s=e,l=t;return e<n&&r<0?(s=yR(e,n,i),l=yR(e+a,n+a,i)):t>i&&r>0&&(l=yR(t,n,i),s=yR(t-a,n,i-a)),{min:s,max:l}},t.prototype.valueRange=function(){return{min:this.seriesMin,max:this.seriesMax}},t.prototype.lineDir=function(){var e=this.options;return(e.vertical?-1:1)*(e.reverse?-1:1)},t.prototype.lineInfo=function(){var e=this.options.vertical,t=this.lineBox(),n=e?t.height():t.width(),i=e?_F:vF,r=this.lineDir(),o=i+(1===r?1:2).toString();return{axis:i,axisOrigin:o,axisDir:r,lineBox:t,lineSize:n,lineStart:t[o]}},t.prototype.pointOffset=function(e){var t=this.lineInfo(),n=t.axis,i=t.axisDir,r=t.axisOrigin,o=t.lineBox,a=t.lineSize;return(i>0?e[n]-o[r]:o[r]-e[n])/a},t.prototype.scaleToDelta=function(e,t){var n=yR(e,-.999,.999);return n>0?t*Math.min(1,n):t-t/(1+n)},t.prototype.labelsBetweenTicks=function(){return!this.options.justified},t.prototype.prepareUserOptions=function(){},t}(qL);DR(TB,{labels:{visible:!0,rotation:0,mirror:!1,step:1,skip:0},line:{width:1,color:FH,visible:!0},title:{visible:!0,position:LH},majorTicks:{align:oF,size:4,skip:0,step:1},minorTicks:{align:oF,size:3,skip:0,step:1},axisCrossingValue:0,majorTickType:oF,minorTickType:eF,majorGridLines:{skip:0,step:1},minorGridLines:{visible:!1,width:1,color:FH,skip:0,step:1},margin:5,visible:!0,reverse:!1,justified:!0,notes:{label:{text:""}},_alignLines:!0,_deferLabels:!1});var DB="milliseconds",AB="seconds",MB="minutes",EB="hours",IB="days",zB="weeks",PB="months",HB="years",FB=1e3,RB=6e4,LB=36e5,BB=864e5,OB=6048e5,VB=26784e5,NB=31536e6,$B={years:NB,months:VB,weeks:OB,days:BB,hours:LB,minutes:RB,seconds:FB,milliseconds:1};function UB(e,t){return e.getTime()-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*RB}function WB(e,t){return new Date(e.getTime()+t)}function jB(e){var t;return e instanceof Date?t=e:e&&(t=new Date(e)),t}function qB(e,t){void 0===t&&(t=0);var n=0,i=e.getDay();if(!isNaN(i))for(;i!==t;)0===i?i=6:i--,n++;return WB(e,-n*BB)}function GB(e,t){return 0===t&&23===e.getHours()&&(e.setHours(e.getHours()+2),!0)}function KB(e,t,n,i){var r=e;if(e){var o=jB(e),a=o.getHours();n===HB?GB(r=new Date(o.getFullYear()+t,0,1),0):n===PB?GB(r=new Date(o.getFullYear(),o.getMonth()+t,1),a):n===zB?GB(r=KB(qB(o,i),7*t,IB),a):n===IB?GB(r=new Date(o.getFullYear(),o.getMonth(),o.getDate()+t),a):n===EB?r=function(e,t){var n=new Date(e);n.setMinutes(0,0,0);var i=(e.getTimezoneOffset()-n.getTimezoneOffset())*RB;return WB(n,i+t*LB)}(o,t):n===MB?(r=WB(o,t*RB)).getSeconds()>0&&r.setSeconds(0):n===AB?r=WB(o,t*FB):n===DB&&(r=WB(o,t)),n!==DB&&r.getMilliseconds()>0&&r.setMilliseconds(0)}return r}function YB(e,t,n){return KB(jB(e),0,t,n)}function QB(e,t,n){var i=jB(e);return i&&YB(i,t,n).getTime()===i.getTime()?i:KB(i,1,t,n)}function XB(e,t){return e&&t?e.getTime()-t.getTime():-1}function ZB(e,t){return e.getTime()-t}function JB(e){if(xF(e)){for(var t=[],n=0;n<e.length;n++)t.push(JB(e[n]));return t}if(e)return jB(e).getTime()}function eO(e,t){return e&&t?JB(e)===JB(t):e===t}function tO(e,t,n){return UB(e,t)/$B[n]}function nO(e,t,n,i){var r=jB(e),o=jB(t);return(n===PB?r.getMonth()-o.getMonth()+12*(r.getFullYear()-o.getFullYear())+tO(r,new Date(r.getFullYear(),r.getMonth()),IB)/new Date(r.getFullYear(),r.getMonth()+1,0).getDate():n===HB?r.getFullYear()-o.getFullYear()+nO(r,new Date(r.getFullYear(),0),PB,1)/12:n===IB||n===zB?tO(r,o,n):ZB(r,t)/$B[n])/i}function iO(e,t,n){return n===HB?t.getFullYear()-e.getFullYear():n===PB?12*iO(e,t,HB)+t.getMonth()-e.getMonth():n===IB?Math.floor(ZB(t,e)/BB):Math.floor(ZB(t,e)/$B[n])}function rO(e,t){return EF(t)&&e.parseDate(t)||jB(t)}function oO(e,t){if(xF(t)){for(var n=[],i=0;i<t.length;i++)n.push(rO(e,t[i]));return n}return rO(e,t)}function aO(e,t){return MF(e.weekStartDay)?e.weekStartDay:t&&t.firstDay?t.firstDay():0}var sO=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initFields=function(){this._ticks={}},t.prototype.categoriesHash=function(){return""},t.prototype.clone=function(){var e=new t(Object.assign({},this.options,{categories:this.options.srcCategories}),this.chartService);return e.createLabels(),e},t.prototype.initUserOptions=function(e){var t=e.categories||[],n=hR(e.min),i=hR(e.max);if(e.srcCategories=e.categories=t,(n||i)&&t.length){var r,o=n?Math.floor(e.min):0;r=i?e.justified?Math.floor(e.max)+1:Math.ceil(e.max):t.length,e.categories=e.categories.slice(o,r)}return e},t.prototype.rangeIndices=function(){var e=this.options,t=e.categories.length||1;return{min:MF(e.min)?e.min%1:0,max:MF(e.max)&&e.max%1!=0&&e.max<this.totalRange().max?t-(1-e.max%1):t-(e.justified?1:0)}},t.prototype.range=function(){var e=this.options;return{min:MF(e.min)?e.min:0,max:MF(e.max)?e.max:this.totalRange().max}},t.prototype.roundedRange=function(){return this.range()},t.prototype.totalRange=function(){var e=this.options;return{min:0,max:Math.max(this._seriesMax||0,e.srcCategories.length)-(e.justified?1:0)}},t.prototype.scaleOptions=function(){var e=this.rangeIndices(),t=e.min,n=e.max,i=this.lineBox();return{scale:(this.options.vertical?i.height():i.width())/(n-t||1)*(this.options.reverse?-1:1),box:i,min:t,max:n}},t.prototype.arrangeLabels=function(){e.prototype.arrangeLabels.call(this),this.hideOutOfRangeLabels()},t.prototype.hideOutOfRangeLabels=function(){var e=this.box,t=this.labels;if(t.length>0){var n=this.options.vertical?_F:vF,i=e[n+1],r=e[n+2],o=t[0],a=bR(t);(o.box[n+1]>r||o.box[n+2]<i)&&(o.options.visible=!1),(a.box[n+1]>r||a.box[n+2]<i)&&(a.options.visible=!1)}},t.prototype.getMajorTickPositions=function(){return this.getTicks().majorTicks},t.prototype.getMinorTickPositions=function(){return this.getTicks().minorTicks},t.prototype.getLabelsTickPositions=function(){return this.getTicks().labelTicks},t.prototype.tickIndices=function(e){for(var t=this.rangeIndices(),n=t.min,i=t.max,r=Math.ceil(i),o=Math.floor(n),a=[];o<=r;)a.push(o),o+=e;return a},t.prototype.getTickPositions=function(e){for(var t=this.options,n=t.vertical,i=t.reverse,r=this.scaleOptions(),o=r.scale,a=r.box,s=r.min,l=a[(n?_F:vF)+(i?2:1)],c=this.tickIndices(e),d=[],u=0;u<c.length;u++)d.push(l+xR(o*(c[u]-s),3));return d},t.prototype.getTicks=function(){var e=this.options,t=this._ticks,n=this.rangeIndices(),i=this.lineBox(),r=i.getHash()+n.min+","+n.max+e.reverse+e.justified;if(t._hash!==r){var o=e.minorTicks.visible||e.minorGridLines.visible;t._hash=r,t.labelTicks=this.getTickPositions(1),t.majorTicks=this.filterOutOfRangePositions(t.labelTicks,i),t.minorTicks=o?this.filterOutOfRangePositions(this.getTickPositions(.5),i):[]}return t},t.prototype.filterOutOfRangePositions=function(e,t){if(!e.length)return e;for(var n=this.options.vertical?_F:vF,i=function(e){return t[n+1]<=e&&e<=t[n+2]},r=e.length-1,o=0;!i(e[o])&&o<=r;)o++;for(var a=r;!i(e[a])&&a>=0;)a--;return e.slice(o,a+1)},t.prototype.lineInfo=function(){var e=this.options,t=e.vertical,n=e.reverse,i=this.lineBox(),r=t?i.height():i.width(),o=t?_F:vF,a=n?-1:1,s=o+(1===a?1:2).toString();return{axis:o,axisOrigin:s,axisDir:a,lineBox:i,lineSize:r,lineStart:i[s]}},t.prototype.lineDir=function(){return this.options.reverse?-1:1},t.prototype.getSlot=function(e,t,n){var i=this.options,r=i.reverse,o=i.justified,a=this.scaleOptions(),s=a.scale,l=a.box,c=a.min,d=this.lineInfo(),u=d.axis,h=d.lineStart,p=l.clone(),f=!hR(t),m=SR(e,0),g=SR(t,m);g=Math.max(g-1,m);var v=h+(m-c)*s,_=h+((g=Math.max(m,g))+1-c)*s;return f&&o&&(_=v),n&&(v=yR(v,l[u+1],l[u+2]),_=yR(_,l[u+1],l[u+2])),p[u+1]=r?_:v,p[u+2]=r?v:_,p},t.prototype.limitSlot=function(e){var t=this.options.vertical?_F:vF,n=this.lineBox(),i=e.clone();return i[t+1]=yR(e[t+1],n[t+1],n[t+2]),i[t+2]=yR(e[t+2],n[t+1],n[t+2]),i},t.prototype.slot=function(t,n,i){var r=Math.floor(this.options.min||0),o=t,a=n;return"string"==typeof o?o=this.categoryIndex(o):MF(o)&&(o-=r),"string"==typeof a?a=this.categoryIndex(a):MF(a)&&(a-=r),e.prototype.slot.call(this,o,a,i)},t.prototype.pointCategoryIndex=function(e){var t=this.options,n=t.reverse,i=t.justified,r=t.vertical?_F:vF,o=this.scaleOptions(),a=o.scale,s=o.box,l=o.min,c=o.max,d=n?c:l,u=s[r+1],h=s[r+2],p=e[r];if(p<u||p>h)return null;var f=d+(p-u)/a,m=f%1;return i?f=Math.round(f):0===m&&f>0&&f--,Math.floor(f)},t.prototype.getCategory=function(e){var t=this.pointCategoryIndex(e);return null===t?null:this.options.categories[t]},t.prototype.categoryIndex=function(e){return this.totalIndex(e)-Math.floor(this.options.min||0)},t.prototype.categoryAt=function(e,t){var n=this.options;return(t?n.srcCategories:n.categories)[e]},t.prototype.categoriesCount=function(){return(this.options.categories||[]).length},t.prototype.translateRange=function(e){var t=this.options,n=this.lineBox(),i=t.vertical?n.height():n.width(),r=t.categories.length,o=xR(e/(i/r),$H);return{min:o,max:r+o}},t.prototype.scaleRange=function(e,t){var n=Math.abs(this.pointOffset(t)),i=this.limitedRangeIndices(),r=i.max-i.min,o=this.scaleToDelta(e,r),a=n*o,s=(1-n)*o,l=i.min+a,c=i.max-s;return c-l<.1&&(c=l+.1),{min:l,max:c}},t.prototype.zoomRange=function(e,t){var n=this.totalRange(),i=n.min,r=n.max,o=this.scaleRange(e,t);return{min:yR(o.min,i,r),max:yR(o.max,i,r)}},t.prototype.labelsCount=function(){var e=this.labelsRange();return e.max-e.min},t.prototype.labelsRange=function(){var e=this.options,t=e.justified,n=e.labels,i=this.limitedRangeIndices(!0),r=i.min,o=i.max,a=Math.floor(r);return t?(r=Math.ceil(r),o=Math.floor(o)):(r=Math.floor(r),o=Math.ceil(o)),{min:(r>n.skip?n.skip+n.step*Math.ceil((r-n.skip)/n.step):n.skip)-a,max:(e.categories.length?o+(t?1:0):0)-a}},t.prototype.createAxisLabel=function(e,t,n){var i=this.options,r=i.dataItems?i.dataItems[e]:null,o=SR(i.categories[e],"");n.dataItem=r;var a=this.axisLabelText(o,t,n);return new dB(o,a,e,r,t)},t.prototype.shouldRenderNote=function(e){var t=this.limitedRangeIndices();return Math.floor(t.min)<=e&&e<=Math.ceil(t.max)},t.prototype.noteSlot=function(e){var t=this.options,n=e-Math.floor(t.min||0);return this.getSlot(n)},t.prototype.arrangeNotes=function(){e.prototype.arrangeNotes.call(this),this.hideOutOfRangeNotes()},t.prototype.hideOutOfRangeNotes=function(){var e=this.notes,t=this.box;if(e&&e.length)for(var n=this.options.vertical?_F:vF,i=t[n+1],r=t[n+2],o=0;o<e.length;o++){var a=e[o];a.box&&(r<a.box[n+1]||a.box[n+2]<i)&&a.hide()}},t.prototype.pan=function(e){var t=this.limitedRangeIndices(!0),n=this.scaleOptions().scale,i=xR(e/n,$H),r=this.totalRange(),o=t.min+i,a=t.max+i;return this.limitRange(o,a,0,r.max,i)},t.prototype.pointsRange=function(e,t){var n=this.options,i=n.reverse,r=n.vertical?_F:vF,o=this.limitedRangeIndices(!0),a=this.scaleOptions(),s=a.scale,l=a.box[r+(i?2:1)],c=e[r]-l,d=t[r]-l,u=o.min+c/s,h=o.min+d/s,p=Math.min(u,h),f=Math.max(u,h);if(f-p>=.01)return{min:p,max:f}},t.prototype.valueRange=function(){return this.range()},t.prototype.totalIndex=function(e){var t=this.options,n=this._categoriesMap?this._categoriesMap.get(e):function(e,t){if(e instanceof Date){for(var n=t.length,i=0;i<n;i++)if(eO(t[i],e))return i;return-1}return t.indexOf(e)}(e,t.srcCategories);return n},t.prototype.currentRangeIndices=function(){var e=this.options,t=0;return MF(e.min)&&(t=Math.floor(e.min)),{min:t,max:MF(e.max)?e.justified?Math.floor(e.max):Math.ceil(e.max)-1:this.totalCount()-1}},t.prototype.limitedRangeIndices=function(e){var t,n=this.options,i=MF(n.min)?n.min:0;if(t=MF(n.max)?n.max:MF(n.min)?i+n.categories.length:this.totalRange().max||1,e){var r=this.totalRange();i=yR(i,0,r.max),t=yR(t,0,r.max)}return{min:i,max:t}},t.prototype.totalRangeIndices=function(){return{min:0,max:this.totalRange().max||1}},t.prototype.indexCategories=function(){if(!this._categoriesMap)for(var e=this._categoriesMap=new eR,t=this.options.srcCategories,n=0;n<t.length;n++)e.set(t[n],n)},t.prototype.totalCount=function(){return Math.max(this.options.srcCategories.length,this._seriesMax||0)},t}(TB);DR(sO,{type:"category",vertical:!1,majorGridLines:{visible:!1,width:1,color:FH},labels:{zIndex:1},justified:!1,_deferLabels:!0});var lO=3e5,cO={milliseconds:"HH:mm:ss.fff",seconds:"HH:mm:ss",minutes:"HH:mm",hours:"HH:mm",days:"M/d",weeks:"M/d",months:"MMM 'yy",years:"yyyy"},dO=[DB,AB,MB,EB,IB,zB,PB,HB],uO="fit";function hO(e,t){t&&(e._range=void 0);var n=e._range;return n||((n=e._range=FR(e)).min=jB(n.min),n.max=jB(n.max)),n}var pO=function(e){this.options=e};pO.prototype.displayIndices=function(){return{min:0,max:1}},pO.prototype.displayRange=function(){return{}},pO.prototype.total=function(){return{}},pO.prototype.valueRange=function(){return{}},pO.prototype.valueIndex=function(){return-1},pO.prototype.values=function(){return[]},pO.prototype.totalIndex=function(){return-1},pO.prototype.valuesCount=function(){return 0},pO.prototype.totalCount=function(){return 0},pO.prototype.dateAt=function(){return null};var fO=function(e,t,n){this.options=n,n.baseUnitStep=n.baseUnitStep||1;var i=n.roundToBaseUnit,r=n.justified;this.start=KB(e,0,n.baseUnit,n.weekStartDay);var o=this.roundToTotalStep(t),a=!r&&eO(t,o)&&!n.justifyEnd;this.end=this.roundToTotalStep(t,!r,a?1:0);var s=n.min||e;this.valueStart=this.roundToTotalStep(s),this.displayStart=i?this.valueStart:s;var l=n.max;if(l){var c=!r&&eO(l,this.roundToTotalStep(l))?-1:0;this.valueEnd=this.roundToTotalStep(l,!1,c),this.displayEnd=i?this.roundToTotalStep(l,!r):n.max}else this.valueEnd=o,this.displayEnd=i||a?this.end:t;this.valueEnd<this.valueStart&&(this.valueEnd=this.valueStart),this.displayEnd<=this.displayStart&&(this.displayEnd=this.roundToTotalStep(this.displayStart,!1,1))};function mO(e,t,n){for(var i,r,o,a=hO(e.categories),s=(e.max||a.max)-(e.min||a.min),l=e.autoBaseUnitSteps,c=e.maxDateGroups,d=e.baseUnit===uO,u=t?dO.indexOf(t):0,h=d?dO[u++]:e.baseUnit,p=s/$B[h],f=p;!r||p>=c;){i=i||l[h].slice(0);do{o=i.shift()}while(o&&t===h&&o<n);if(o)p=f/(r=o);else{if(h===bR(dO)){r=Math.ceil(f/c);break}if(!d){p>c&&(r=Math.ceil(f/c));break}h=dO[u++]||bR(dO),f=s/$B[h],i=null}}e.baseUnitStep=r,e.baseUnit=h}function gO(e){var t=(e.baseUnit||"").toLowerCase();return t!==uO&&!tR(t,dO)&&function(e){for(var t,n,i=e.categories,r=hR(i)?i.length:0,o=ZH,a=0;a<r;a++){var s=i[a];if(s&&t){var l=Math.abs(UB(s,t));0!==l&&(n=(o=Math.min(o,l))>=NB?HB:o>=24192e5?PB:o>=OB?zB:o>=BB?IB:o>=LB?EB:o>=RB?MB:AB)}t=s}e.baseUnit=n||IB}(e),t!==uO&&"auto"!==e.baseUnitStep||mO(e),e}fO.prototype.displayRange=function(){return{min:this.displayStart,max:this.displayEnd}},fO.prototype.displayIndices=function(){if(!this._indices){var e=this.options,t=e.baseUnit,n=e.baseUnitStep,i=nO(this.displayStart,this.valueStart,t,n),r=nO(this.displayEnd,this.valueStart,t,n);this._indices={min:i,max:r}}return this._indices},fO.prototype.total=function(){return{min:this.start,max:this.end}},fO.prototype.totalCount=function(){return this.totalIndex(this.end)+(this.options.justified?1:0)},fO.prototype.valueRange=function(){return{min:this.valueStart,max:this.valueEnd}},fO.prototype.valueIndex=function(e){var t=this.options;return Math.floor(nO(e,this.valueStart,t.baseUnit,t.baseUnitStep))},fO.prototype.totalIndex=function(e){var t=this.options;return Math.floor(nO(e,this.start,t.baseUnit,t.baseUnitStep))},fO.prototype.dateIndex=function(e){var t=this.options;return nO(e,this.valueStart,t.baseUnit,t.baseUnitStep)},fO.prototype.valuesCount=function(){return this.valueIndex(this.valueEnd)+1},fO.prototype.values=function(){var e=this._values;if(!e){var t=this.options,n=this.valueRange();this._values=e=[];for(var i=n.min;i<=n.max;)e.push(i),i=KB(i,t.baseUnitStep,t.baseUnit,t.weekStartDay)}return e},fO.prototype.dateAt=function(e,t){var n=this.options;return KB(t?this.start:this.valueStart,n.baseUnitStep*e,n.baseUnit,n.weekStartDay)},fO.prototype.roundToTotalStep=function(e,t,n){var i=this.options,r=i.baseUnit,o=i.baseUnitStep,a=i.weekStartDay,s=this.start,l=nO(e,s,r,o),c=t?Math.ceil(l):Math.floor(l);return n&&(c+=n),KB(s,c*o,r,a)};var vO=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.clone=function(){var e=new t(Object.assign({},this.options),this.chartService);return e.createLabels(),e},t.prototype.categoriesHash=function(){var e=this.dataRange.total().min;return this.options.baseUnit+this.options.baseUnitStep+e},t.prototype.initUserOptions=function(e){return e},t.prototype.initFields=function(){e.prototype.initFields.call(this);var t=this.chartService,n=t.intl,i=this.options,r=i.categories||[];if(r._parsed||((r=oO(n,r))._parsed=!0),i=BF({roundToBaseUnit:!0},i,{categories:r,min:rO(n,i.min),max:rO(n,i.max),weekStartDay:aO(i,n)}),t.panning&&t.isPannable(i.vertical?_F:vF)&&(i.roundToBaseUnit=!1),i.userSetBaseUnit=i.userSetBaseUnit||i.baseUnit,i.userSetBaseUnitStep=i.userSetBaseUnitStep||i.baseUnitStep,this.options=i,i.srcCategories=r,r.length>0){var o=hO(r,!0),a=i.maxDivisions,s=gO(i),l=i._forecast;if(l&&(l.before>0&&(o.min=KB(o.min,-l.before,s.baseUnit,s.weekStartDay)),l.after>0&&(o.max=KB(o.max,l.after,s.baseUnit,s.weekStartDay))),this.dataRange=new fO(o.min,o.max,s),a){var c=this.dataRange.displayRange(),d=Object.assign({},i,{justified:!0,roundToBaseUnit:!1,baseUnit:"fit",min:c.min,max:c.max,maxDateGroups:a}),u=this.dataRange.options;mO(d,u.baseUnit,u.baseUnitStep),this.divisionRange=new fO(o.min,o.max,d)}else this.divisionRange=this.dataRange}else i.baseUnit=i.baseUnit||IB,this.dataRange=this.divisionRange=new pO(i);this.rangeLabels=[]},t.prototype.tickIndices=function(t){var n=this.dataRange,i=this.divisionRange,r=i.valuesCount();if(!this.options.maxDivisions||!r)return e.prototype.tickIndices.call(this,t);var o=[],a=i.values(),s=0;this.options.justified||(a=a.concat(i.dateAt(r)),s=.5);for(var l=0;l<a.length;l++)if(o.push(n.dateIndex(a[l])+s),1!==t&&l>=1){var c=o.length-1;o.splice(l,0,o[c-1]+(o[c]-o[c-1])*t)}return o},t.prototype.shouldRenderNote=function(e){var t=this.range(),n=this.options.categories||[];return XB(e,t.min)>=0&&XB(e,t.max)<=0&&n.length},t.prototype.parseNoteValue=function(e){return rO(this.chartService.intl,e)},t.prototype.noteSlot=function(e){return this.getSlot(e)},t.prototype.translateRange=function(e){var t=this.options,n=t.baseUnit,i=t.weekStartDay,r=t.vertical,o=this.lineBox(),a=r?o.height():o.width(),s=this.range(),l=a/(s.max-s.min),c=xR(e/l,$H);if(s.min&&s.max){var d=WB(t.min||s.min,c),u=WB(t.max||s.max,c);s={min:KB(d,0,n,i),max:KB(u,0,n,i)}}return s},t.prototype.labelsRange=function(){return{min:this.options.labels.skip,max:this.divisionRange.valuesCount()}},t.prototype.pan=function(e){if(this.isEmpty())return null;var t=this.options,n=this.lineBox(),i=t.vertical?n.height():n.width(),r=this.dataRange.displayRange(),o=r.min,a=r.max,s=this.dataRange.total(),l=xR(e/(i/(a-o)),$H)*(t.reverse?-1:1),c=WB(o,l),d=WB(a,l),u=this.limitRange(JB(c),JB(d),JB(s.min),JB(s.max),l);return u?(u.min=jB(u.min),u.max=jB(u.max),u.baseUnit=t.baseUnit,u.baseUnitStep=t.baseUnitStep||1,u.userSetBaseUnit=t.userSetBaseUnit,u.userSetBaseUnitStep=t.userSetBaseUnitStep,u):void 0},t.prototype.pointsRange=function(t,n){if(this.isEmpty())return null;var i=e.prototype.pointsRange.call(this,t,n),r=this.dataRange.displayRange(),o=this.dataRange.displayIndices(),a=ZB(r.max,r.min)/(o.max-o.min),s=this.options;return{min:WB(r.min,i.min*a),max:WB(r.min,i.max*a),baseUnit:s.userSetBaseUnit||s.baseUnit,baseUnitStep:s.userSetBaseUnitStep||s.baseUnitStep}},t.prototype.scaleRange=function(e,t){if(this.isEmpty())return{};var n=this.options,i=n.userSetBaseUnit===uO,r=this.dataRange.total(),o=this.dataRange.displayRange(),a=o.min,s=o.max,l=Math.abs(this.pointOffset(t)),c=s-a,d=this.scaleToDelta(e,c),u=Math.round(l*d),h=Math.round((1-l)*d),p=this.dataRange.options.baseUnit,f=new Date(a.getTime()+u),m=new Date(s.getTime()-h);if(i){var g,v,_=n.autoBaseUnitSteps,b=n.maxDateGroups,y=bR(_[p])*b*$B[p],w=ZB(s,a),k=ZB(m,f),x=dO.indexOf(p);if(k<$B[p]&&p!==DB)p=dO[x-1],f=WB(a,v=(w-(b-1)*(g=bR(_[p]))*$B[p])/2),m=WB(s,-v);else if(k>y&&p!==HB){var C=0;do{x++,p=dO[x],C=0,v=2*$B[p];do{g=_[p][C],C++}while(C<_[p].length&&v*g<w)}while(p!==HB&&v*g<w);(v=(v*g-w)/2)>0&&(f=WB(a,-v),m=WB(s,v),f=WB(f,yR(m,r.min,r.max)-m),m=WB(m,yR(f,r.min,r.max)-f))}}return f&&m&&ZB(m,f)>0?{min:f,max:m,baseUnit:n.userSetBaseUnit||n.baseUnit,baseUnitStep:n.userSetBaseUnitStep||n.baseUnitStep}:void 0},t.prototype.zoomRange=function(e,t){var n=this.dataRange.total(),i=this.scaleRange(e,t);return i&&(i.min<n.min&&(i.min=n.min),i.max>n.max&&(i.max=n.max)),i},t.prototype.range=function(){return this.dataRange.displayRange()},t.prototype.createLabels=function(){e.prototype.createLabels.call(this),this.createRangeLabels()},t.prototype.clearLabels=function(){e.prototype.clearLabels.call(this),this.rangeLabels=[]},t.prototype.arrangeLabels=function(){this.arrangeRangeLabels(),e.prototype.arrangeLabels.call(this)},t.prototype.arrangeRangeLabels=function(){var e=this.options,t=this.rangeLabels;if(0!==t.length){var n=this.lineBox(),i=e.vertical,r=e.rangeLabels.mirror||e.labels.mirror,o=t[0];if(o){var a=i?n.y1-o.box.height()/2:n.x1;this.positionLabel(o,r,a)}var s=t[1];if(s){var l=i?n.y2-s.box.height()/2:n.x2;this.positionLabel(s,r,l)}}},t.prototype.autoRotateLabels=function(){e.prototype.autoRotateLabels.call(this),this.autoRotateRangeLabels()},t.prototype.hideOutOfRangeLabels=function(){e.prototype.hideOutOfRangeLabels.call(this),this.hideOverlappingLabels()},t.prototype.hideOverlappingLabels=function(){var e=this.rangeLabels,t=this.labels;if(0!==e.length){var n=e[0];if(n&&n.options.visible)for(var i=0;i<t.length;i++){if(!a(n,t[i]))break}var r=e[1];if(r&&r.options.visible)for(var o=t.length-1;o>0;--o){if(!a(r,t[o]))break}}function a(e,t){return!(t.options.visible&&!t.box.overlaps(e.box))&&(t.options.visible=!1,!0)}},t.prototype.contentBox=function(){for(var t=e.prototype.contentBox.call(this),n=this.rangeLabels,i=0;i<n.length;i++){var r=n[i];r.options.visible&&t.wrap(r.box)}return t},t.prototype.createAxisLabel=function(e,t,n){void 0===n&&(n={});var i=this.options,r=i.dataItems&&!i.maxDivisions?i.dataItems[e]:null,o=this.divisionRange.dateAt(e),a=t.dateFormats[this.divisionRange.options.baseUnit];t.format=t.format||a,n.dataItem=r;var s=this.axisLabelText(o,t,n);if(s)return new dB(o,s,e,r,t)},t.prototype.createRangeLabels=function(){var e=this,t=this.divisionRange,n=t.displayStart,i=t.displayEnd,r=this.options,o=Object.assign({},r.labels,r.rangeLabels,{align:LH,zIndex:r.zIndex});if(!0===o.visible){this.normalizeLabelRotation(o),o.alignRotation=LH,"auto"===o.rotation&&(o.rotation=0,r.autoRotateRangeLabels=!0);var a=o.dateFormats[this.divisionRange.options.baseUnit];o.format=o.format||a;var s=function(t,n,i){if(i){var r=new dB(n,i,t,null,o);e.append(r),e.rangeLabels.push(r)}};s(0,n,this.axisLabelText(n,o,{index:0,count:2})),s(1,i,this.axisLabelText(i,o,{index:1,count:2}))}},t.prototype.autoRotateRangeLabels=function(){var e=this,t=this.rangeLabels;if(this.options.autoRotateRangeLabels&&!this.options.vertical&&2===t.length){var n=function(t,n,i){var r=2*Math.abs(n[i+1]-n[i]),o=e.autoRotateLabelAngle(t.box,r);0!==o&&(t.options.rotation=o,t.reflow(new VL))},i=this.getMajorTickPositions();n(t[0],i,0),n(t[1],i,i.length-2)}},t.prototype.categoryIndex=function(e){return this.dataRange.valueIndex(e)},t.prototype.slot=function(e,t,n){var i=this.dataRange,r=e,o=t;r instanceof Date&&(r=i.dateIndex(r)),o instanceof Date&&(o=i.dateIndex(o));var a=this.getSlot(r,o,n);if(a)return a.toRect()},t.prototype.getSlot=function(t,n,i){var r=t,o=n;return typeof r===rF&&(r=this.categoryIndex(r)),typeof o===rF&&(o=this.categoryIndex(o)),e.prototype.getSlot.call(this,r,o,i)},t.prototype.valueRange=function(){var e=hO(this.options.srcCategories);return{min:jB(e.min),max:jB(e.max)}},t.prototype.categoryAt=function(e,t){return this.dataRange.dateAt(e,t)},t.prototype.categoriesCount=function(){return this.dataRange.valuesCount()},t.prototype.rangeIndices=function(){return this.dataRange.displayIndices()},t.prototype.labelsBetweenTicks=function(){return!this.divisionRange.options.justified},t.prototype.prepareUserOptions=function(){this.isEmpty()||(this.options.categories=this.dataRange.values())},t.prototype.getCategory=function(e){var t=this.pointCategoryIndex(e);return null===t?null:this.dataRange.dateAt(t)},t.prototype.totalIndex=function(e){return this.dataRange.totalIndex(e)},t.prototype.currentRangeIndices=function(){var e=this.dataRange.valueRange();return{min:this.dataRange.totalIndex(e.min),max:this.dataRange.totalIndex(e.max)}},t.prototype.totalRange=function(){return this.dataRange.total()},t.prototype.totalRangeIndices=function(){var e=this.dataRange.total();return{min:this.dataRange.totalIndex(e.min),max:this.dataRange.totalIndex(e.max)}},t.prototype.totalCount=function(){return this.dataRange.totalCount()},t.prototype.isEmpty=function(){return!this.options.srcCategories.length},t.prototype.roundedRange=function(){if(!1!==this.options.roundToBaseUnit||this.isEmpty())return this.range();var e=this.options,t=hO(e.srcCategories);return new fO(t.min,t.max,Object.assign({},e,{justified:!1,roundToBaseUnit:!0,justifyEnd:!1})).displayRange()},t}(sO);function _O(e,t){return xR(Math.floor(e/t)*t,$H)}function bO(e,t){return xR(Math.ceil(e/t)*t,$H)}function yO(e){return Math.max(Math.min(e,lO),-3e5)}DR(vO,{type:VH,labels:{dateFormats:cO},rangeLabels:{visible:!1},autoBaseUnitSteps:{milliseconds:[1,10,100],seconds:[1,2,5,15,30],minutes:[1,2,5,15,30],hours:[1,2,3],days:[1,2,3],weeks:[1,2],months:[1,2,3,6],years:[1,2,3,5,10,25,50]},maxDateGroups:10});var wO=Math.pow(10,-9),kO=function(e){function t(t,n,i,r){e.call(this,Object.assign({},i,{seriesMin:t,seriesMax:n}),r)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initUserOptions=function(e){var t=function(e,t,n){var i=n.narrowRange,r=function(e,t,n){if(!e&&!t)return 0;var i;if(e>=0&&t>=0){var r=e===t?0:e;if(!1===n||!n&&(t-r)/t>.2)return 0;i=Math.max(0,r-(t-r)/2)}else i=e;return i}(e,t,i),o=function(e,t,n){if(!e&&!t)return 1;var i;if(e<=0&&t<=0){var r=e===t?0:t,o=Math.abs((r-e)/r);if(!1===n||!n&&o>.2)return 0;i=Math.min(0,r-(e-r)/2)}else i=t;return i}(e,t,i),a=BL(r,o),s={majorUnit:a};!1!==n.roundToMajorUnit&&(r<0&&xO(r,a,1/3)&&(r-=a),o>0&&xO(o,a,1/3)&&(o+=a));return s.min=_O(r,a),s.max=bO(o,a),s}(e.seriesMin,e.seriesMax,e);return this.totalOptions=function(e,t){return{min:hR(t.min)?Math.min(e.min,t.min):e.min,max:hR(t.max)?Math.max(e.max,t.max):e.max,majorUnit:e.majorUnit}}(t,e),function(e,t){var n,i,r=t;if(t){!function(e,t){for(var n=0;n<t.length;n++){var i=t[n];null===e[i]&&(e[i]=void 0)}}(t,["min","max"]),n=hR(t.min),i=hR(t.max);var o=n||i;o&&t.min===t.max&&(t.min>0?t.min=0:t.max=1),t.majorUnit?(e.min=_O(e.min,t.majorUnit),e.max=bO(e.max,t.majorUnit)):o&&(r=BF(e,t),e.majorUnit=BL(r.min,r.max))}e.minorUnit=(r.majorUnit||e.majorUnit)/5;var a=BF(e,r);a.min>=a.max&&(n&&!i?a.max=a.min+a.majorUnit:!n&&i&&(a.min=a.max-a.majorUnit));return a}(t,e)},t.prototype.initFields=function(){this.totalMin=this.totalOptions.min,this.totalMax=this.totalOptions.max,this.totalMajorUnit=this.totalOptions.majorUnit,this.seriesMin=this.options.seriesMin,this.seriesMax=this.options.seriesMax},t.prototype.clone=function(){return new t(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)},t.prototype.startValue=function(){return 0},t.prototype.range=function(){var e=this.options;return{min:e.min,max:e.max}},t.prototype.getDivisions=function(e){if(0===e)return 1;var t=this.options,n=t.max-t.min;return Math.floor(xR(n/e,3))+1},t.prototype.getTickPositions=function(e,t){var n=this.options,i=this.lineInfo(),r=i.axisDir,o=i.axisOrigin,a=i.lineBox,s=e*(i.lineSize/(n.max-n.min)),l=this.getDivisions(e),c=[],d=a[o],u=0;t&&(u=t/e);for(var h=0;h<l;h++)h%u!=0&&c.push(xR(d,3)),d+=s*r;return c},t.prototype.getMajorTickPositions=function(){return this.getTickPositions(this.options.majorUnit)},t.prototype.getMinorTickPositions=function(){return this.getTickPositions(this.options.minorUnit)},t.prototype.getSlot=function(e,t,n){void 0===n&&(n=!1);var i=this.options,r=this.lineInfo(),o=r.axis,a=r.axisDir,s=r.lineBox,l=r.lineSize,c=r.lineStart,d=a*(l/(i.max-i.min)),u=SR(e,t||0),h=SR(t,e||0);n&&(u=yR(u,i.min,i.max),h=yR(h,i.min,i.max));var p=Math.min(u,h)-i.min,f=Math.max(u,h)-i.min,m=new VL(s.x1,s.y1,s.x1,s.y1);return m[o+1]=yO(c+d*(a>0?p:f)),m[o+2]=yO(c+d*(a>0?f:p)),m},t.prototype.getValue=function(e){var t=this.options,n=Number(t.max),i=Number(t.min),r=this.pointOffset(e);return r<0||r>1?null:xR(i+r*(n-i),$H)},t.prototype.translateRange=function(e){var t=this.options,n=t.vertical,i=t.reverse,r=t.max,o=t.min,a=this.lineInfo().lineSize,s=xR(e/(a/(r-o)),$H);return!n&&!i||n&&i||(s=-s),{min:o+s,max:r+s,offset:s}},t.prototype.labelsCount=function(){return this.getDivisions(this.options.majorUnit)},t.prototype.createAxisLabel=function(e,t,n){var i=this.options,r=xR(i.min+e*i.majorUnit,$H),o=this.axisLabelText(r,t,n);return new dB(r,o,e,null,t)},t.prototype.shouldRenderNote=function(e){var t=this.range();return t.min<=e&&e<=t.max},t.prototype.pan=function(e){var t=this.translateRange(e);return this.limitRange(t.min,t.max,this.totalMin,this.totalMax,t.offset)},t.prototype.pointsRange=function(e,t){var n=this.getValue(e),i=this.getValue(t),r=Math.min(n,i),o=Math.max(n,i);if(this.isValidRange(r,o))return{min:r,max:o}},t.prototype.scaleRange=function(e,t){var n=Math.abs(this.pointOffset(t)),i=this.options.max-this.options.min,r=this.scaleToDelta(e,i),o=n*r,a=(1-n)*r,s=xR(this.options.min+o,$H),l=xR(this.options.max-a,$H);return l-s<wO&&(l=s+wO),{min:s,max:l}},t.prototype.zoomRange=function(e,t){var n=this.totalMin,i=this.totalMax,r=this.scaleRange(e,t);return{min:yR(r.min,n,i),max:yR(r.max,n,i),narrowRange:!1}},t.prototype.isValidRange=function(e,t){return t-e>wO},t}(TB);function xO(e,t,n){var i=xR(Math.abs(e%t),$H);return 0===i||i>t*(1-n)}DR(kO,{type:"numeric",min:0,max:1,vertical:!0,majorGridLines:{visible:!0,width:1,color:FH},labels:{format:"#.####################"},zIndex:1});var CO=function(e){function t(t,n,i,r){var o=jB(t),a=jB(n),s=r.intl,l=i||{};l=function(e,t,n){var i=n.min||e,r=n.max||t,o=n.baseUnit||(r&&i?function(e){var t=EB;e>=NB?t=HB:e>=VB?t=PB:e>=OB?t=zB:e>=BB&&(t=IB);return t}(UB(r,i)):EB),a=$B[o],s=n.weekStartDay||0,l=YB(JB(i)-1,o,s)||jB(r),c=QB(JB(r)+1,o,s),d=n.majorUnit?n.majorUnit:void 0,u=d||bO(BL(l.getTime(),c.getTime()),a)/a,h=iO(l,c,o),p=bO(h,u)-h,f=Math.floor(p/2),m=p-f;n.baseUnit||delete n.baseUnit;return n.baseUnit=n.baseUnit||o,n.min=n.min||KB(l,-f,o,s),n.max=n.max||KB(c,m,o,s),n.minorUnit=n.minorUnit||u/5,n.majorUnit=u,n}(o,a,l=BF(l||{},{min:rO(s,l.min),max:rO(s,l.max),axisCrossingValue:oO(s,l.axisCrossingValues||l.axisCrossingValue),weekStartDay:aO(l,s)})),e.call(this,l,r),this.intlService=s,this.seriesMin=o,this.seriesMax=a;var c=l.weekStartDay||0;this.totalMin=JB(YB(JB(o)-1,l.baseUnit,c)),this.totalMax=JB(QB(JB(a)+1,l.baseUnit,c))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.clone=function(){return new t(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)},t.prototype.range=function(){var e=this.options;return{min:e.min,max:e.max}},t.prototype.getDivisions=function(e){var t=this.options;return Math.floor(iO(t.min,t.max,t.baseUnit)/e+1)},t.prototype.getTickPositions=function(e){for(var t=this.options,n=this.lineInfo(),i=n.axisDir,r=n.lineSize,o=n.lineStart,a=this.getDivisions(e),s=r/ZB(t.max,t.min),l=t.weekStartDay||0,c=[o],d=1;d<a;d++){var u=o+ZB(KB(t.min,d*e,t.baseUnit,l),t.min)*s*i;c.push(xR(u,3))}return c},t.prototype.getMajorTickPositions=function(){return this.getTickPositions(this.options.majorUnit)},t.prototype.getMinorTickPositions=function(){return this.getTickPositions(this.options.minorUnit)},t.prototype.getSlot=function(e,t,n){return kO.prototype.getSlot.call(this,rO(this.intlService,e),rO(this.intlService,t),n)},t.prototype.getValue=function(e){var t=kO.prototype.getValue.call(this,e);return null!==t?jB(t):null},t.prototype.labelsCount=function(){return this.getDivisions(this.options.majorUnit)},t.prototype.createAxisLabel=function(e,t,n){var i=this.options,r=e*i.majorUnit,o=i.weekStartDay||0,a=i.min;r>0&&(a=KB(a,r,i.baseUnit,o));var s=t.dateFormats[i.baseUnit];t.format=t.format||s;var l=this.axisLabelText(a,t,n);return new dB(a,l,e,null,t)},t.prototype.translateRange=function(e){var t=this.options,n=this.lineBox(),i=t.vertical,r=t.reverse,o=i?n.height():n.width(),a=this.range(),s=o/ZB(a.max,a.min),l=xR(e/s,$H);return!i&&!r||i&&r||(l=-l),{min:WB(t.min,l),max:WB(t.max,l),offset:l}},t.prototype.shouldRenderNote=function(e){var t=this.range();return XB(e,t.min)>=0&&XB(e,t.max)<=0},t.prototype.pan=function(e){var t=this.translateRange(e,!0),n=this.limitRange(JB(t.min),JB(t.max),this.totalMin,this.totalMax,t.offset);if(n)return{min:jB(n.min),max:jB(n.max)}},t.prototype.pointsRange=function(e,t){var n=this.getValue(e),i=this.getValue(t),r=Math.min(n,i),o=Math.max(n,i);return{min:jB(r),max:jB(o)}},t.prototype.scaleRange=function(e,t){var n=Math.abs(this.pointOffset(t)),i=this.options.max-this.options.min,r=this.scaleToDelta(e,i),o=n*r,a=(1-n)*r,s=jB(JB(this.options.min)+o),l=jB(JB(this.options.max)-a);return l-s<1e3&&(l=jB(JB(s)+1e3)),{min:s,max:l}},t.prototype.zoomRange=function(e,t){var n=this.scaleRange(e,t);return{min:jB(yR(JB(n.min),this.totalMin,this.totalMax)),max:jB(yR(JB(n.max),this.totalMin,this.totalMax))}},t}(TB);DR(CO,{type:VH,majorGridLines:{visible:!0,width:1,color:FH},labels:{dateFormats:cO}});var SO=1e-6,TO=function(e){function t(t,n,i,r){var o=BF({majorUnit:10,min:t,max:n},i),a=o.majorUnit,s=function(e,t){var n,i=xR(AO(e,t),$H)%1;n=e<=0?t:0!==i&&(i<.3||i>.9)?Math.pow(t,AO(e,t)+.2):Math.pow(t,Math.ceil(AO(e,t)));return n}(n,a),l=function(e,t,n){var i=n.majorUnit,r=e;e<=0?r=t<=1?Math.pow(i,-2):1:n.narrowRange||(r=Math.pow(i,Math.floor(AO(e,i))));return r}(t,n,o),c=function(e,t,n,i){var r=n.min,o=n.max;hR(n.axisCrossingValue)&&n.axisCrossingValue<=0&&DO();hR(i.max)?i.max<=0&&DO():o=t;hR(i.min)?i.min<=0&&DO():r=e;return{min:r,max:o}}(l,s,o,i);o.max=c.max,o.min=c.min,o.minorUnit=i.minorUnit||xR(a-1,$H),e.call(this,o,r),this.totalMin=hR(i.min)?Math.min(l,i.min):l,this.totalMax=hR(i.max)?Math.max(s,i.max):s,this.logMin=xR(AO(c.min,a),$H),this.logMax=xR(AO(c.max,a),$H),this.seriesMin=t,this.seriesMax=n,this.createLabels()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.clone=function(){return new t(this.seriesMin,this.seriesMax,Object.assign({},this.options),this.chartService)},t.prototype.startValue=function(){return this.options.min},t.prototype.getSlot=function(e,t,n){var i=this,r=i.options,o=i.logMin,a=i.logMax,s=r.majorUnit,l=r.min,c=r.max,d=this.lineInfo(),u=d.axis,h=d.axisDir,p=d.lineBox,f=d.lineSize,m=d.lineStart,g=h*(f/(a-o)),v=SR(e,t||1),_=SR(t,e||1);if(v<=0||_<=0)return null;n&&(v=yR(v,l,c),_=yR(_,l,c)),v=AO(v,s),_=AO(_,s);var b=Math.min(v,_)-o,y=Math.max(v,_)-o,w=new VL(p.x1,p.y1,p.x1,p.y1);return w[u+1]=yO(m+g*(h>0?b:y)),w[u+2]=yO(m+g*(h>0?y:b)),w},t.prototype.getValue=function(e){var t=this,n=t.options,i=t.logMin,r=t.logMax,o=n.majorUnit,a=this.lineInfo(),s=a.axis,l=a.axisDir,c=a.lineStart,d=a.lineSize,u=(r-i)/d,h=l*(e[s]-c);if(h<0||h>d)return null;var p=i+h*u;return xR(Math.pow(o,p),$H)},t.prototype.range=function(){var e=this.options;return{min:e.min,max:e.max}},t.prototype.translateRange=function(e){var t=this,n=t.options,i=t.logMin,r=t.logMax,o=n.reverse,a=n.vertical,s=n.majorUnit,l=this.lineBox(),c=a?l.height():l.width(),d=xR(e/(c/(r-i)),$H);return!a&&!o||a&&o||(d=-d),{min:Math.pow(s,i+d),max:Math.pow(s,r+d),offset:d}},t.prototype.labelsCount=function(){var e=Math.floor(this.logMax);return Math.floor(e-this.logMin)+1},t.prototype.getMajorTickPositions=function(){var e=[];return this.traverseMajorTicksPositions((function(t){e.push(t)}),{step:1,skip:0}),e},t.prototype.createTicks=function(e){var t=this.options,n=t.majorTicks,i=t.minorTicks,r=t.vertical,o=t.labels.mirror,a=this.lineBox(),s={vertical:r};function l(t,n){s.tickX=o?a.x2:a.x2-n.size,s.tickY=o?a.y1-n.size:a.y1,s.position=t,e.append(CB(s,n))}return n.visible&&this.traverseMajorTicksPositions(l,n),i.visible&&this.traverseMinorTicksPositions(l,i),[]},t.prototype.createGridLines=function(e){var t=this.options,n=t.minorGridLines,i=t.majorGridLines,r=t.vertical,o=e.lineBox(),a={lineStart:o[r?"x1":"y1"],lineEnd:o[r?"x2":"y2"],vertical:r},s=[],l=this.gridLinesVisual();function c(e,t){tR(e,s)||(a.position=e,l.append(SB(a,t)),s.push(e))}return i.visible&&this.traverseMajorTicksPositions(c,i),n.visible&&this.traverseMinorTicksPositions(c,n),l.children},t.prototype.traverseMajorTicksPositions=function(e,t){for(var n=this.lineInfo(),i=n.lineStart,r=n.step,o=this.logMin,a=this.logMax,s=Math.ceil(o)+t.skip;s<=a;s+=t.step){e(xR(i+r*(s-o),$H),t)}},t.prototype.traverseMinorTicksPositions=function(e,t){for(var n=this.options,i=n.min,r=n.max,o=n.minorUnit,a=n.majorUnit,s=this.lineInfo(),l=s.lineStart,c=s.step,d=this.logMin,u=this.logMax,h=Math.floor(d);h<u;h++)for(var p=this._minorIntervalOptions(h),f=t.skip;f<o;f+=t.step){var m=p.value+f*p.minorStep;if(m>r)break;if(m>=i)e(xR(l+c*(AO(m,a)-d),$H),t)}},t.prototype.createAxisLabel=function(e,t,n){var i=Math.ceil(this.logMin+e),r=Math.pow(this.options.majorUnit,i),o=this.axisLabelText(r,t,n);return new dB(r,o,e,null,t)},t.prototype.shouldRenderNote=function(e){var t=this.range();return t.min<=e&&e<=t.max},t.prototype.pan=function(e){var t=this.translateRange(e);return this.limitRange(t.min,t.max,this.totalMin,this.totalMax,t.offset)},t.prototype.pointsRange=function(e,t){var n=this.getValue(e),i=this.getValue(t);return{min:Math.min(n,i),max:Math.max(n,i)}},t.prototype.scaleRange=function(e,t){var n=this.options.majorUnit,i=AO(this.options.min,n),r=AO(this.options.max,n),o=Math.abs(this.pointOffset(t)),a=r-i,s=this.scaleToDelta(e,a),l=Math.pow(n,i+o*s),c=Math.pow(n,r-(1-o)*s);return c-l<SO&&(c=l+SO),{min:l,max:c}},t.prototype.zoomRange=function(e,t){var n=this.scaleRange(e,t),i=this.totalMin,r=this.totalMax;return{min:yR(n.min,i,r),max:yR(n.max,i,r)}},t.prototype._minorIntervalOptions=function(e){var t=this.options,n=t.minorUnit,i=t.majorUnit,r=Math.pow(i,e);return{value:r,minorStep:(Math.pow(i,e+1)-r)/n}},t.prototype.lineInfo=function(){var t=e.prototype.lineInfo.call(this);return t.step=t.axisDir*(t.lineSize/(this.logMax-this.logMin)),t},t}(TB);function DO(){throw new Error("Non positive values cannot be used for a logarithmic axis")}function AO(e,t){return Math.log(e)/Math.log(t)}DR(TO,{type:"log",majorUnit:10,minorUnit:1,axisCrossingValue:1,vertical:!0,majorGridLines:{visible:!0,width:1,color:FH},zIndex:1,_deferLabels:!0});var MO={createGridLines:function(e){var t,n,i=this.options,r=Math.abs(this.box.center().y-e.lineBox().y1),o=[],a=!1;return i.majorGridLines.visible&&(t=this.majorGridLineAngles(e),a=!0,o=this.renderMajorGridLines(t,r,i.majorGridLines)),i.minorGridLines.visible&&(n=this.minorGridLineAngles(e,a),dR(o,this.renderMinorGridLines(n,r,i.minorGridLines,e,a))),o},renderMajorGridLines:function(e,t,n){return this.renderGridLines(e,t,n)},renderMinorGridLines:function(e,t,n,i,r){var o=this.radiusCallback&&this.radiusCallback(t,i,r);return this.renderGridLines(e,t,n,o)},renderGridLines:function(e,t,n,i){for(var r={stroke:{width:n.width,color:n.color,dashType:n.dashType}},o=this.box.center(),a=new oa([o.x,o.y],t),s=this.gridLinesVisual(),l=0;l<e.length;l++){var c=new us(r);i&&(a.radius=i(e[l])),c.moveTo(a.center).lineTo(a.pointAt(e[l]+180)),s.append(c)}return s.children},gridLineAngles:function(e,t,n,i,r){var o=this,a=this.intervals(t,n,i,r),s=e.options,l=s.visible&&!1!==(s.line||{}).visible;return aR(a,(function(e){var t=o.intervalAngle(e);if(!l||90!==t)return t}))}},EO=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.range=function(){return{min:0,max:this.options.categories.length}},t.prototype.reflow=function(e){this.box=e,this.reflowLabels()},t.prototype.lineBox=function(){return this.box},t.prototype.reflowLabels=function(){for(var e=this.labels,t=this.options.labels,n=t.skip||0,i=t.step||1,r=new VL,o=0;o<e.length;o++){e[o].reflow(r);var a=e[o].box;e[o].reflow(this.getSlot(n+o*i).adjacentBox(0,a.width(),a.height()))}},t.prototype.intervals=function(e,t,n,i){void 0===i&&(i=!1);for(var r=this.options,o=r.categories.length/e||1,a=360/o,s=n||1,l=[],c=0,d=t||0;d<o;d+=s)c=r.reverse?360-d*a:d*a,c=xR(c,3)%360,i&&tR(c,i)||l.push(c);return l},t.prototype.majorIntervals=function(){return this.intervals(1)},t.prototype.minorIntervals=function(){return this.intervals(.5)},t.prototype.intervalAngle=function(e){return(360+e+this.options.startAngle)%360},t.prototype.majorAngles=function(){var e=this;return aR(this.majorIntervals(),(function(t){return e.intervalAngle(t)}))},t.prototype.createLine=function(){return[]},t.prototype.majorGridLineAngles=function(e){var t=this.options.majorGridLines;return this.gridLineAngles(e,1,t.skip,t.step)},t.prototype.minorGridLineAngles=function(e,t){var n=this.options,i=n.minorGridLines,r=n.majorGridLines,o=t?this.intervals(1,r.skip,r.step):null;return this.gridLineAngles(e,.5,i.skip,i.step,o)},t.prototype.radiusCallback=function(e,t,n){if(t.options.type!==AH){var i=kR(360/(2*this.options.categories.length)),r=Math.cos(i)*e,o=this.majorAngles(),a=function(t){return!n&&tR(t,o)?e:r};return a}},t.prototype.createPlotBands=function(){for(var e=this.options.plotBands||[],t=this._plotbandGroup=new vs({zIndex:-1}),n=0;n<e.length;n++){var i=e[n],r=this.plotBandSlot(i),o=this.getSlot(i.from),a=i.from-Math.floor(i.from);r.startAngle+=a*o.angle;var s=Math.ceil(i.to)-i.to;r.angle-=(s+a)*o.angle;var l=jL.current.createRing(r,{fill:{color:i.color,opacity:i.opacity},stroke:{opacity:i.opacity}});t.append(l)}this.appendVisual(t)},t.prototype.plotBandSlot=function(e){return this.getSlot(e.from,e.to-1)},t.prototype.getSlot=function(e,t){var n=this.options,i=n.justified,r=this.box,o=this.majorAngles(),a=o.length,s=360/a,l=e;n.reverse&&!i&&(l=(l+1)%a);var c=o[l=yR(Math.floor(l),0,a-1)];i&&(c-=s/2)<0&&(c+=360);var d=s*(yR(Math.ceil(t||l),l,a-1)-l+1);return new $L(r.center(),0,r.height()/2,c,d)},t.prototype.slot=function(e,t){var n=this.getSlot(e,t),i=n.startAngle+180,r=i+n.angle;return new ga([n.center.x,n.center.y],{startAngle:i,endAngle:r,radiusX:n.radius,radiusY:n.radius})},t.prototype.pointCategoryIndex=function(e){for(var t=this.options.categories.length,n=null,i=0;i<t;i++){if(this.getSlot(i).containsPoint(e)){n=i;break}}return n},t}(sO);DR(EO,{startAngle:90,labels:{margin:WF(10)},majorGridLines:{visible:!0},justified:!0}),BF(EO.prototype,MO);var IO=function(e){function t(t,n){e.call(this,t,n);var i=this.options;i.minorUnit=i.minorUnit||i.majorUnit/2}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getDivisions=function(e){return kO.prototype.getDivisions.call(this,e)-1},t.prototype.reflow=function(e){this.box=e,this.reflowLabels()},t.prototype.reflowLabels=function(){for(var e=this,t=e.options,n=e.labels,i=e.options.labels,r=i.skip||0,o=i.step||1,a=new VL,s=this.intervals(t.majorUnit,r,o),l=0;l<n.length;l++){n[l].reflow(a);var c=n[l].box;n[l].reflow(this.getSlot(s[l]).adjacentBox(0,c.width(),c.height()))}},t.prototype.lineBox=function(){return this.box},t.prototype.intervals=function(e,t,n,i){void 0===i&&(i=!1);for(var r=this.options.min,o=this.getDivisions(e),a=[],s=n||1,l=t||0;l<o;l+=s){var c=(360+r+l*e)%360;i&&tR(c,i)||a.push(c)}return a},t.prototype.majorIntervals=function(){return this.intervals(this.options.majorUnit)},t.prototype.minorIntervals=function(){return this.intervals(this.options.minorUnit)},t.prototype.intervalAngle=function(e){return(540-e-this.options.startAngle)%360},t.prototype.createLine=function(){return[]},t.prototype.majorGridLineAngles=function(e){var t=this.options.majorGridLines;return this.gridLineAngles(e,this.options.majorUnit,t.skip,t.step)},t.prototype.minorGridLineAngles=function(e,t){var n=this.options,i=n.minorGridLines,r=n.majorGridLines,o=t?this.intervals(n.majorUnit,r.skip,r.step):null;return this.gridLineAngles(e,n.minorUnit,i.skip,i.step,o)},t.prototype.plotBandSlot=function(e){return this.getSlot(e.from,e.to)},t.prototype.getSlot=function(e,t){var n=this.options,i=this.box,r=n.startAngle,o=yR(e,n.min,n.max),a=yR(t||o,o,n.max);if(n.reverse&&(o*=-1,a*=-1),(a=(540-a-r)%360)<(o=(540-o-r)%360)){var s=o;o=a,a=s}return new $L(i.center(),0,i.height()/2,o,a-o)},t.prototype.slot=function(e,t){void 0===t&&(t=e);var n,i,r=this.options,o=360-r.startAngle,a=this.getSlot(e,t),s=Math.min(e,t),l=Math.max(e,t);return r.reverse?(n=s,i=l):(n=360-l,i=360-s),n=(n+o)%360,i=(i+o)%360,new ga([a.center.x,a.center.y],{startAngle:n,endAngle:i,radiusX:a.radius,radiusY:a.radius})},t.prototype.getValue=function(e){var t=this.options,n=this.box.center(),i=e.x-n.x,r=e.y-n.y,o=Math.round(pR(Math.atan2(r,i))),a=t.startAngle;return t.reverse||(o*=-1,a*=-1),(o+a+360)%360},t.prototype.valueRange=function(){return{min:0,max:2*Math.PI}},t}(TB);DR(IO,{type:"polar",startAngle:0,reverse:!1,majorUnit:60,min:0,max:360,labels:{margin:WF(10)},majorGridLines:{color:FH,visible:!0,width:1},minorGridLines:{color:"#aaa"}}),BF(IO.prototype,MO,{createPlotBands:EO.prototype.createPlotBands,majorAngles:EO.prototype.majorAngles,range:kO.prototype.range,labelsCount:kO.prototype.labelsCount,createAxisLabel:kO.prototype.createAxisLabel});var zO={options:{majorGridLines:{visible:!0}},createPlotBands:function(){var e=this.options,t=e.majorGridLines.type,n=e.plotBands;void 0===n&&(n=[]);for(var i=this.plotArea.polarAxis,r=i.majorAngles(),o=i.box.center(),a=this._plotbandGroup=new vs({zIndex:-1}),s=0;s<n.length;s++){var l=n[s],c={fill:{color:l.color,opacity:l.opacity},stroke:{opacity:l.opacity}},d=this.getSlot(l.from,l.to,!0),u=new $L(o,o.y-d.y2,o.y-d.y1,0,360),h=void 0;h=t===AH?jL.current.createRing(u,c):us.fromPoints(this.plotBandPoints(u,r),c).close(),a.append(h)}this.appendVisual(a)},plotBandPoints:function(e,t){for(var n=[],i=[],r=[e.center.x,e.center.y],o=new oa(r,e.innerRadius),a=new oa(r,e.radius),s=0;s<t.length;s++)n.push(o.pointAt(t[s]+180)),i.push(a.pointAt(t[s]+180));return n.reverse(),n.push(n[0]),i.push(i[0]),i.concat(n)},createGridLines:function(e){var t=this.options,n=this.radarMajorGridLinePositions(),i=e.majorAngles(),r=e.box.center(),o=[];if(t.majorGridLines.visible&&(o=this.renderGridLines(r,n,i,t.majorGridLines)),t.minorGridLines.visible){var a=this.radarMinorGridLinePositions();dR(o,this.renderGridLines(r,a,i,t.minorGridLines))}return o},renderGridLines:function(e,t,n,i){var r={stroke:{width:i.width,color:i.color,dashType:i.dashType}},o=i.skip;void 0===o&&(o=0);var a=i.step;void 0===a&&(a=0);for(var s=this.gridLinesVisual(),l=o;l<t.length;l+=a){var c=e.y-t[l];if(c>0){var d=new oa([e.x,e.y],c);if(i.type===AH)s.append(new ua(d,r));else{for(var u=new us(r),h=0;h<n.length;h++)u.lineTo(d.pointAt(n[h]+180));u.close(),s.append(u)}}}return s.children},getValue:function(e){var t=this.lineBox(),n=this.plotArea.polarAxis,i=n.majorAngles(),r=n.box.center(),o=e.distanceTo(r),a=o;if(this.options.majorGridLines.type!==AH&&i.length>1){var s=e.x-r.x,l=e.y-r.y,c=(pR(Math.atan2(l,s))+540)%360;i.sort((function(e,t){return PO(e,c)-PO(t,c)}));var d=90-PO(i[0],i[1])/2,u=180-PO(c,i[0])-d;a=o*(Math.sin(kR(u))/Math.sin(kR(d)))}return this.axisType().prototype.getValue.call(this,new OL(t.x1,t.y2-a))}};function PO(e,t){return 180-Math.abs(Math.abs(e-t)-180)}var HO=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.radarMajorGridLinePositions=function(){return this.getTickPositions(this.options.majorUnit)},t.prototype.radarMinorGridLinePositions=function(){var e=this.options,t=0;return e.majorGridLines.visible&&(t=e.majorUnit),this.getTickPositions(e.minorUnit,t)},t.prototype.axisType=function(){return e},t}(kO);BF(HO.prototype,zO);var FO=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.radarMajorGridLinePositions=function(){var e=[];return this.traverseMajorTicksPositions((function(t){e.push(t)}),this.options.majorGridLines),e},t.prototype.radarMinorGridLinePositions=function(){var e=[];return this.traverseMinorTicksPositions((function(t){e.push(t)}),this.options.minorGridLines),e},t.prototype.axisType=function(){return e},t}(TO);BF(FO.prototype,zO);var RO=function(e){function t(t){e.call(this),this.closed=t}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.process=function(e){var t=e.slice(0),n=[],i=this.closed,r=t.length;if(r>2&&(this.removeDuplicates(0,t),r=t.length),r<2||2===r&&t[0].equals(t[1]))return n;var o,a,s=t[0],l=t[1],c=t[2];for(n.push(new La(s));s.equals(t[r-1]);)i=!0,t.pop(),r--;if(2===r){var d=this.tangent(s,l,vF,_F);return bR(n).controlOut(this.firstControlPoint(d,s,l,vF,_F)),n.push(new La(l,this.secondControlPoint(d,s,l,vF,_F))),n}if(i){s=t[r-1],l=t[0],c=t[1];var u=this.controlPoints(s,l,c);o=u[1],a=u[0]}else{var h=this.tangent(s,l,vF,_F);o=this.firstControlPoint(h,s,l,vF,_F)}for(var p=o,f=0;f<=r-3;f++)if(this.removeDuplicates(f,t),f+3<=(r=t.length)){s=t[f],l=t[f+1],c=t[f+2];var m=this.controlPoints(s,l,c);bR(n).controlOut(p),p=m[1];var g=m[0];n.push(new La(l,g))}if(i){s=t[r-2],l=t[r-1],c=t[0];var v=this.controlPoints(s,l,c);bR(n).controlOut(p),n.push(new La(l,v[0])),bR(n).controlOut(v[1]),n.push(new La(c,a))}else{var _=this.tangent(l,c,vF,_F);bR(n).controlOut(p),n.push(new La(c,this.secondControlPoint(_,l,c,vF,_F)))}return n},t.prototype.removeDuplicates=function(e,t){for(;t[e+1]&&(t[e].equals(t[e+1])||t[e+1].equals(t[e+2]));)t.splice(e+1,1)},t.prototype.invertAxis=function(e,t,n){var i=!1;if(e.x===t.x)i=!0;else if(t.x===n.x)(t.y<n.y&&e.y<=t.y||n.y<t.y&&t.y<=e.y)&&(i=!0);else{var r=this.lineFunction(e,t),o=this.calculateFunction(r,n.x);e.y<=t.y&&n.y<=o||t.y<=e.y&&n.y>=o||(i=!0)}return i},t.prototype.isLine=function(e,t,n){var i=this.lineFunction(e,t),r=this.calculateFunction(i,n.x);return e.x===t.x&&t.x===n.x||xR(r,1)===xR(n.y,1)},t.prototype.lineFunction=function(e,t){var n=(t.y-e.y)/(t.x-e.x);return[e.y-n*e.x,n]},t.prototype.controlPoints=function(e,t,n){var i,r=vF,o=_F,a=!1,s=!1;if(this.isLine(e,t,n))i=this.tangent(e,t,vF,_F);else{var l={x:this.isMonotonicByField(e,t,n,vF),y:this.isMonotonicByField(e,t,n,_F)};if(l.x&&l.y)i=this.tangent(e,n,vF,_F),a=!0;else if(this.invertAxis(e,t,n)&&(r=_F,o=vF),l[r])i=0;else i=.01*(n[o]<e[o]&&e[o]<=t[o]||e[o]<n[o]&&t[o]<=e[o]?LO((n[o]-e[o])*(t[r]-e[r])):-LO((n[r]-e[r])*(t[o]-e[o]))),s=!0}var c=this.secondControlPoint(i,e,t,r,o);if(s){var d=r;r=o,o=d}var u=this.firstControlPoint(i,t,n,r,o);return a&&(this.restrictControlPoint(e,t,c,i),this.restrictControlPoint(t,n,u,i)),[c,u]},t.prototype.restrictControlPoint=function(e,t,n,i){e.y<t.y?t.y<n.y?(n.x=e.x+(t.y-e.y)/i,n.y=t.y):n.y<e.y&&(n.x=t.x-(t.y-e.y)/i,n.y=e.y):n.y<t.y?(n.x=e.x-(e.y-t.y)/i,n.y=t.y):e.y<n.y&&(n.x=t.x+(e.y-t.y)/i,n.y=e.y)},t.prototype.tangent=function(e,t,n,i){var r,o=t[n]-e[n],a=t[i]-e[i];return r=0===o?0:a/o,r},t.prototype.isMonotonicByField=function(e,t,n,i){return n[i]>t[i]&&t[i]>e[i]||n[i]<t[i]&&t[i]<e[i]},t.prototype.firstControlPoint=function(e,t,n,i,r){var o=t[i],a=.333*(n[i]-o);return this.point(o+a,t[r]+a*e,i,r)},t.prototype.secondControlPoint=function(e,t,n,i,r){var o=t[i],a=n[i],s=.333*(a-o);return this.point(a-s,n[r]-s*e,i,r)},t.prototype.point=function(e,t,n,i){var r=new Go;return r[n]=e,r[i]=t,r},t.prototype.calculateFunction=function(e,t){for(var n=e.length,i=0,r=0;r<n;r++)i+=Math.pow(t,r)*e[r];return i},t}(fr);function LO(e){return e<=0?-1:1}var BO=Object.freeze({__proto__:null,Axis:TB,AxisLabel:dB,Box:VL,BoxElement:YL,CategoryAxis:sO,ChartElement:qL,Class:fr,CurveProcessor:RO,DateCategoryAxis:vO,DateValueAxis:CO,FloatElement:nB,FontLoader:TR,Gradients:JL,HashMap:eR,InstanceObserver:rR,LogarithmicAxis:TO,Matrix:XR,Note:uB,NumericAxis:kO,Observable:fL,Point:OL,PolarAxis:IO,RadarCategoryAxis:EO,RadarLogarithmicAxis:FO,RadarNumericAxis:HO,Ring:$L,RootElement:tB,Sector:WL,ShapeBuilder:jL,ShapeElement:XL,Text:rB,TextBox:sB,Title:lB,UserEvents:LL,absoluteDateDiff:UB,addClass:CF,addDuration:KB,addTicks:WB,alignPathToPixel:DF,append:dR,applyEventMap:eL,autoMajorUnit:BL,autoTextColor:NR,bindEvents:uR,ceilDate:QB,clockwise:AF,constants:kF,convertableToNumber:IF,createHashSet:GR,createPatternFill:KL,cycleDown:PF,cycleIndex:HF,cycleUp:zF,dateComparer:XB,dateDiff:ZB,dateEquals:eO,dateIndex:nO,deepExtend:BF,defaultErrorHandler:KR,defined:hR,deg:pR,duration:iO,elementOffset:fR,elementScale:VR,elementSize:mR,elementStyles:UF,eventCoordinates:gR,eventElement:vR,eventMap:ZR,find:RR,firstDay:aO,floorDate:YB,getAriaTemplate:KF,getSpacing:WF,getSupportedFeatures:aL,getTemplate:GF,getter:XF,grep:ZF,hasClasses:JF,hasOwnProperty:QR,hashKey:_R,inArray:tR,interpolateValue:nR,isArray:xF,isFunction:FF,isNumber:MF,isObject:OF,isPlainObject:oR,isString:EF,keys:YR,last:bR,limitValue:yR,logToConsole:Ar,lteDateIndex:function(e,t){for(var n,i=0,r=t.length-1;i<=r;){var o=t[n=Math.floor((i+r)/2)];if(o<e)i=n+1;else{if(!(o>e)){for(;eO(t[n-1],e);)n--;return n}r=n-1}}return t[n]<=e?n:n-1},map:aR,mousewheelDelta:lR,noop:lL,now:cL,objectKey:wR,off:oL,on:rL,parseDate:rO,parseDates:oO,rad:kR,rectToBox:oB,removeClass:TF,renderIcon:HR,round:xR,services:xB,setDefaultOptions:DR,sparseArrayLimits:FR,startOfWeek:qB,styleValue:VF,toDate:jB,toTime:JB,unbindEvents:CR,valueOrDefault:SR}),OO=function(e){function t(t){e.call(this),this._axis=t,this.options=t.options}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.value=function(e){var t=this._axis,n=t.getCategory?t.getCategory(e):t.getValue(e);return n},t.prototype.slot=function(e,t,n){return void 0===n&&(n=!0),this._axis.slot(e,t,n)},t.prototype.range=function(){return this._axis.range()},t.prototype.valueRange=function(){return this._axis.valueRange()},t}(fr);function VO(e,t){for(var n=0;n<t.length;n++)if(t[n].options.name===e)return t[n].prepareUserOptions(),new OO(t[n])}var NO=function(e){this.visual=e.visual,this.chartsVisual=e.chartContainer.visual,this._pane=e};NO.prototype.findAxisByName=function(e){return VO(e,this._pane.axes)};var $O=function(e){function t(t){e.call(this),this._plotArea=t,this.visual=t.visual,this.backgroundVisual=t._bgVisual}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(fr);function UO(e){for(var t=e.length,n=0,i=0;i<t;i++){MF(e[i])&&n++}return n}var WO={min:function(e){for(var t=e.length,n=ZH,i=0;i<t;i++){var r=e[i];MF(r)&&(n=Math.min(n,r))}return n===ZH?e[0]:n},max:function(e){for(var t=e.length,n=JH,i=0;i<t;i++){var r=e[i];MF(r)&&(n=Math.max(n,r))}return n===JH?e[0]:n},sum:function(e){for(var t=e.length,n=0,i=0;i<t;i++){var r=e[i];MF(r)&&(n+=r)}return n},sumOrNull:function(e){var t=null;return UO(e)&&(t=WO.sum(e)),t},count:function(e){for(var t=e.length,n=0,i=0;i<t;i++){var r=e[i];null!==r&&hR(r)&&n++}return n},avg:function(e){var t=UO(e),n=e[0];return t>0&&(n=WO.sum(e)/t),n},first:function(e){for(var t=e.length,n=0;n<t;n++){var i=e[n];if(null!==i&&hR(i))return i}return e[0]}};function jO(e,t){return null===t?t:XF(e)(t)}var qO=function(e){function t(){e.call(this),this._valueFields={},this._otherFields={},this._nullValue={},this._undefinedValue={}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.register=function(e,t,n){var i=this;void 0===t&&(t=[fF]),void 0===n&&(n={});for(var r=0;r<e.length;r++){var o=e[r];i._valueFields[o]=t,i._otherFields[o]=n,i._nullValue[o]=i._makeValue(t,null),i._undefinedValue[o]=i._makeValue(t,void 0)}},t.prototype.canonicalFields=function(e){return this.valueFields(e).concat(this.otherFields(e))},t.prototype.valueFields=function(e){return this._valueFields[e.type]||[fF]},t.prototype.otherFields=function(e){return this._otherFields[e.type]||[fF]},t.prototype.bindPoint=function(e,t,n){var i,r,o=e.data,a=hR(n)?n:o[t],s={valueFields:{value:a}},l=this.valueFields(e),c=this._otherFields[e.type];if(null===a)r=this._nullValue[e.type];else if(hR(a)){if(Array.isArray(a)){var d=a.slice(l.length);r=this._bindFromArray(a,l),i=this._bindFromArray(d,c)}else if("object"==typeof a){var u=this.sourceFields(e,l),h=this.sourceFields(e,c);r=this._bindFromObject(a,l,u),i=this._bindFromObject(a,c,h)}}else r=this._undefinedValue[e.type];return hR(r)&&(1===l.length?s.valueFields.value=r[l[0]]:s.valueFields=r),s.fields=i||{},s},t.prototype._makeValue=function(e,t){for(var n={},i=e.length,r=0;r<i;r++){n[e[r]]=t}return n},t.prototype._bindFromArray=function(e,t){var n={};if(t)for(var i=Math.min(t.length,e.length),r=0;r<i;r++)n[t[r]]=e[r];return n},t.prototype._bindFromObject=function(e,t,n){void 0===n&&(n=t);var i={};if(t)for(var r=t.length,o=0;o<r;o++){var a=t[o],s=n[o];null!==s&&(i[a]=jO(s,e))}return i},t.prototype.sourceFields=function(e,t){var n=[];if(t)for(var i=t.length,r=0;r<i;r++){var o=t[r],a=o===fF?"field":o+"Field";n.push(null!==e[a]?e[a]||o:null)}return n},t}(fr);qO.current=new qO;var GO=/percent(?:\w*)\((\d+)\)/,KO=new RegExp("^stddev(?:\\((\\d+(?:\\.\\d+)?)\\))?$"),YO=function(e){function t(t,n,i){e.call(this),this.initGlobalRanges(t,n,i)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initGlobalRanges=function(e,t,n){var i=t.data,r=KO.exec(e);if(r){this.valueGetter=this.createValueGetter(t,n);var o=this.getAverage(i),a=this.getStandardDeviation(i,o,!1),s=r[1]?parseFloat(r[1]):1,l={low:o.value-a*s,high:o.value+a*s};this.globalRange=function(){return l}}else if(e.indexOf&&e.indexOf("stderr")>=0){this.valueGetter=this.createValueGetter(t,n);var c=this.getStandardError(i,this.getAverage(i));this.globalRange=function(e){return{low:e-c,high:e+c}}}},t.prototype.createValueGetter=function(e,t){var n,i=e.data,r=qO.current,o=r.valueFields(e),a=hR(i[0])?i[0]:{};if(xF(a))n=XF("["+(t?o.indexOf(t):0)+"]");else if(MF(a))n=XF();else if(typeof a===rF){n=XF(r.sourceFields(e,o)[o.indexOf(t)])}return n},t.prototype.getErrorRange=function(e,t){var n,i,r;if(!hR(t))return null;if(this.globalRange)return this.globalRange(e);if(xF(t))n=e-t[0],i=e+t[1];else if(MF(r=parseFloat(t)))n=e-r,i=e+r;else{if(!(r=GO.exec(t)))throw new Error("Invalid ErrorBar value: "+t);var o=e*(parseFloat(r[1])/100);n=e-Math.abs(o),i=e+Math.abs(o)}return{low:n,high:i}},t.prototype.getStandardError=function(e,t){return this.getStandardDeviation(e,t,!0)/Math.sqrt(t.count)},t.prototype.getStandardDeviation=function(e,t,n){for(var i=e.length,r=n?t.count-1:t.count,o=0,a=0;a<i;a++){var s=this.valueGetter(e[a]);MF(s)&&(o+=Math.pow(s-t.value,2))}return Math.sqrt(o/r)},t.prototype.getAverage=function(e){for(var t=e.length,n=0,i=0,r=0;r<t;r++){var o=this.valueGetter(e[r]);MF(o)&&(n+=o,i++)}return{value:n/i,count:i}},t}(fr),QO=Ir.browser||{},XO=600,ZO="fadeIn",JO=.8,eV=QO.msie?.001:0,tV="errorLow",nV="errorHigh",iV="xErrorLow",rV="xErrorHigh",oV="yErrorLow",aV="yErrorHigh",sV="zero",lV="interpolate",cV="gap",dV="above",uV="below",hV="smooth",pV="step",fV="area",mV="bar",gV="boxPlot",vV="bubble",_V="bullet",bV="candlestick",yV="column",wV="donut",kV="funnel",xV="pyramid",CV="heatmap",SV="horizontalWaterfall",TV="line",DV="ohlc",AV="pie",MV="polarArea",EV="polarLine",IV="polarScatter",zV="radarArea",PV="radarColumn",HV="radarLine",FV="rangeArea",RV="rangeBar",LV="rangeColumn",BV="scatter",OV="scatterLine",VV="verticalArea",NV="verticalBoxPlot",$V="verticalBullet",UV="verticalLine",WV="verticalRangeArea",jV="waterfall",qV=[mV,yV,DV,bV,gV,NV,_V,LV,RV,jV,SV],GV="exponentialTrendline",KV="linearTrendline",YV="logarithmicTrendline",QV="movingAverageTrendline",XV="polynomialTrendline",ZV="powerTrendline",JV=[GV,KV,YV,QV,XV,ZV],eN="legendItemClick",tN="legendItemHover",nN="legendItemLeave",iN="seriesClick",rN="seriesHover",oN="seriesOver",aN="seriesLeave",sN="plotAreaClick",lN="plotAreaHover",cN="plotAreaLeave",dN="drag",uN="dragEnd",hN="dragStart",pN="zoomStart",fN="zoom",mN="zoomEnd",gN="selectStart",vN="select",_N="selectEnd",bN="render",yN="showTooltip",wN="hideTooltip",kN="paneRender",xN="graphics-symbol",CN="k-chart-point",SN="Point",TN="checkbox",DN="k-chart-legend-item",AN="Legend item",MN="log",EN="category",IN="insideEnd",zN="insideBase",PN="outsideEnd",HN="wheel",FN=150,RN="drilldown",LN="drilldown",BN="pattern",ON=Object.freeze({__proto__:null,ABOVE:dV,AREA:fV,BAR:mV,BELOW:uV,BORDER_BRIGHTNESS:JO,BOTTOM:"bottom",BOX_PLOT:gV,BUBBLE:vV,BULLET:_V,CANDLESTICK:bV,CATEGORY:EN,CHART_POINT_CLASSNAME:CN,CHART_POINT_ROLE:xN,CHART_POINT_ROLE_DESCRIPTION:SN,COLUMN:yV,DONUT:wV,DRAG:dN,DRAG_END:uN,DRAG_START:hN,DRILLDOWN:RN,DRILLDOWN_FIELD:LN,EQUALLY_SPACED_SERIES:qV,ERROR_HIGH_FIELD:nV,ERROR_LOW_FIELD:tV,FADEIN:ZO,FUNNEL:kV,GAP:cV,GLASS:"glass",HEATMAP:CV,HIDE_TOOLTIP:wN,HORIZONTAL_WATERFALL:SV,INITIAL_ANIMATION_DURATION:XO,INSIDE_BASE:zN,INSIDE_END:IN,INTERPOLATE:lV,LEGEND_ITEM_ARIA_ROLE_DESCRIPTION:AN,LEGEND_ITEM_CLASSNAME:DN,LEGEND_ITEM_CLICK:eN,LEGEND_ITEM_HOVER:tN,LEGEND_ITEM_LEAVE:nN,LEGEND_ITEM_ROLE:TN,LINE:TV,LINE_MARKER_SIZE:8,LOGARITHMIC:MN,MIN_MOVING_AVERAGE_PERIOD:2,MOUSEWHEEL:HN,MOUSEWHEEL_DELAY:FN,MOUSEWHEEL_ZOOM_RATE:.3,OHLC:DV,OUTSIDE_END:PN,PANE_RENDER:kN,PATTERN_FIELD:BN,PIE:AV,PLOT_AREA_CLICK:sN,PLOT_AREA_HOVER:lN,PLOT_AREA_LEAVE:cN,POLAR_AREA:MV,POLAR_LINE:EV,POLAR_SCATTER:IV,PYRAMID:xV,RADAR_AREA:zV,RADAR_COLUMN:PV,RADAR_LINE:HV,RANGE_AREA:FV,RANGE_BAR:RV,RANGE_COLUMN:LV,RENDER:bN,SCATTER:BV,SCATTER_LINE:OV,SELECT:vN,SELECT_END:_N,SELECT_START:gN,SERIES_CLICK:iN,SERIES_HOVER:rN,SERIES_LEAVE:aN,SERIES_OVER:oN,SHOW_TOOLTIP:yN,SMOOTH:hV,START_SCALE:eV,STEP:pV,TOOLTIP_OFFSET:5,TRENDLINE_EXPONENTIAL:GV,TRENDLINE_LINEAR:KV,TRENDLINE_LOGARITHMIC:YV,TRENDLINE_MOVING_AVERAGE:QV,TRENDLINE_POLYNOMIAL:XV,TRENDLINE_POWER:ZV,TRENDLINE_SERIES:JV,VERTICAL_AREA:VV,VERTICAL_BOX_PLOT:NV,VERTICAL_BULLET:$V,VERTICAL_LINE:UV,VERTICAL_RANGE_AREA:WV,WATERFALL:jV,X_ERROR_HIGH_FIELD:rV,X_ERROR_LOW_FIELD:iV,Y_ERROR_HIGH_FIELD:aV,Y_ERROR_LOW_FIELD:oV,ZERO:sV,ZOOM:fN,ZOOM_END:mN,ZOOM_START:pN}),VN=function(e){function t(t,n,i,r,o,a){e.call(this,a),this.low=t,this.high=n,this.isVertical=i,this.chart=r,this.series=o}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(e){var t,n=this.options.endCaps,i=this.isVertical,r=this.getAxis().getSlot(this.low,this.high),o=e.center(),a=this.getCapsWidth(e,i),s=i?o.x:o.y,l=s-a,c=s+a;i?(t=[new OL(o.x,r.y1),new OL(o.x,r.y2)],n&&t.push(new OL(l,r.y1),new OL(c,r.y1),new OL(l,r.y2),new OL(c,r.y2)),this.box=new VL(l,r.y1,c,r.y2)):(t=[new OL(r.x1,o.y),new OL(r.x2,o.y)],n&&t.push(new OL(r.x1,l),new OL(r.x1,c),new OL(r.x2,l),new OL(r.x2,c)),this.box=new VL(r.x1,l,r.x2,c)),this.linePoints=t},t.prototype.getCapsWidth=function(e,t){var n=t?e.width():e.height();return Math.min(Math.floor(n/2),4)||4},t.prototype.createVisual=function(){var e=this,t=this.options,n=t.visual;n?this.visual=n({low:this.low,high:this.high,rect:this.box.toRect(),sender:this.getSender(),options:{endCaps:t.endCaps,color:t.color,line:t.line},createVisual:function(){e.createDefaultVisual();var t=e.visual;return delete e.visual,t}}):this.createDefaultVisual()},t.prototype.createDefaultVisual=function(){var t=this.options,n=this.linePoints,i={stroke:{color:t.color,width:t.line.width,dashType:t.line.dashType}};e.prototype.createVisual.call(this);for(var r=0;r<n.length;r+=2){var o=new us(i).moveTo(n[r].x,n[r].y).lineTo(n[r+1].x,n[r+1].y);DF(o),this.visual.append(o)}},t}(qL);DR(VN,{animation:{type:ZO,delay:XO},endCaps:!0,line:{width:2},zIndex:1});var NN=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getAxis=function(){return this.chart.seriesValueAxis(this.series)},t}(VN);function $N(e){for(var t=0;t<e.length;t++)if(hR(e[t].zIndex))return!0}function UN(e,t){null!==t&&e.push(t)}function WN(e){return UO(e)===e.length}function jN(e,t,n){var i=t.visible;if(hR(i))return i;var r=e.pointVisibility;return r?r[n]:void 0}function qN(e){for(var t=e.data,n=[],i=0,r=0,o=0;o<t.length;o++){var a=qO.current.bindPoint(e,o),s=a.valueFields.value;EF(s)&&(s=parseFloat(s)),MF(s)?(a.visible=!1!==jN(e,a.fields,o),a.value=Math.abs(s),n.push(a),a.visible&&(i+=a.value),0!==s&&r++):n.push(null)}return{total:i,points:n,count:r}}function GN(e){for(var t=e.length,n=0,i=0;i<t;i++)n=Math.max(n,e[i].data.length);return n}function KN(e,t){return e&&t?e.toLowerCase()===t.toLowerCase():e===t}function YN(e,t,n,i){void 0===n&&(n={}),void 0===i&&(i=!1);var r=n.defaults=n.defaults||{},o=n.depth=n.depth||0,a=!1;if(n.excluded=n.excluded||[],o>5)return null;for(var s in e)if(!tR(s,n.excluded)&&QR(e,s)){var l=e[s];FF(l)?(a=!0,i||(e[s]=SR(l(t),r[s]))):OF(l)&&(i||(n.defaults=r[s]),n.depth++,a=YN(l,t,n,i)||a,n.depth--)}return a}function QN(e,t){for(var n=[],i=[].concat(t),r=0;r<e.length;r++){var o=e[r];tR(o.type,i)&&n.push(o)}return n}var XN=new WeakMap;function ZN(e,t,n){if(null===t||"object"!=typeof t)return rO(n,e);var i=XN.get(t);return i||(i=rO(n,e),XN.set(t,i)),i}function JN(e){var t=e.overlay;return t&&t.gradient&&"none"!==t.gradient}function e$(e){return hR(e)&&null!==e}function t$(e,t){var n=e.type,i=t instanceof Date;return!n&&i||KN(n,VH)}function n$(e){return 1===e.length?e[0]:e}var i$=/area/i;function r$(e,t){var n=qO.current.bindPoint(e,null,t).valueFields;for(var i in n)if(IF(n[i]))return!0}function o$(e){var t,n,i=e.start,r=e.dir,o=e.min,a=e.max,s=e.getter,l=e.hasItem,c=e.series,d=i;do{l(d+=r)&&(t=r$(c,(n=s(d)).item))}while(o<=d&&d<=a&&!t);if(t)return n}function a$(e,t,n,i,r){var o=t.min,a=t.max,s=o>0&&o<n,l=a+1<n;if(s||l){var c,d,u,h=function(e){return e.missingValues?e.missingValues:i$.test(e.type)||e.stack?sV:lV}(e);if(h!==lV)s&&(c=i(o-1)),l&&(d=i(a+1));else s&&(c=r$(e,(u=i(o-1)).item)?u:o$({start:o,dir:-1,min:0,max:n-1,getter:i,hasItem:r,series:e})),l&&(d=r$(e,(u=i(a+1)).item)?u:o$({start:a,dir:1,min:0,max:n-1,getter:i,hasItem:r,series:e}));c&&(e._outOfRangeMinPoint=c),d&&(e._outOfRangeMaxPoint=d)}}var s$=function(e){function t(t,n){e.call(this,n),this.plotArea=t,this.chartService=t.chartService,this.categoryAxis=t.seriesCategoryAxis(n.series[0]),this.valueAxisRanges={},this.points=[],this.categoryPoints=[],this.seriesPoints=[],this.seriesOptions=[],this._evalSeries=[],this.render()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){this.traverseDataPoints(this.addValue.bind(this))},t.prototype.pointOptions=function(e,t){var n=this.seriesOptions[t];if(!n){var i=this.pointType().prototype.defaults;this.seriesOptions[t]=n=BF({},i,{vertical:!this.options.invertAxes},e)}return n},t.prototype.plotValue=function(e){if(!e)return 0;if(this.options.isStacked100&&MF(e.value)){for(var t=e.categoryIx,n=this.categoryPoints[t],i=[],r=0,o=0;o<n.length;o++){var a=n[o];if(a){var s=e.series.stack,l=a.series.stack;if(s&&l&&s.group!==l.group)continue;MF(a.value)&&(r+=Math.abs(a.value),i.push(Math.abs(a.value)))}}if(r>0)return e.value/r}return e.value},t.prototype.plotRange=function(e,t){var n=this;void 0===t&&(t=0);var i=this.categoryPoints[e.categoryIx];if(this.options.isStacked){var r=this.plotValue(e),o=r>=0,a=t,s=!1,l=hR(e.series.stack)?e.series.stack:this.options.defaultStack,c=function(e){return!0===e||typeof e===rF&&!e.group};if(l)for(var d=0;d<i.length;d++){var u=i[d];if(e===u)break;var h=hR(u.series.stack)?u.series.stack:n.options.defaultStack;if(h&&((typeof l!==cF||l===h)&&(!c(l)||c(h))&&(!l.group||l.group===h.group))){var p=n.plotValue(u);(p>=0&&o||p<0&&!o)&&(0!==t&&0===p||(a+=p,r+=p,s=!0,n.options.isStacked100&&(r=Math.min(r,1))))}}return s&&(a-=t),[a,r]}var f=e.series,m=this.seriesValueAxis(f),g=this.categoryAxisCrossingValue(m);return[g,IF(e.value)?e.value:g]},t.prototype.stackLimits=function(e,t){for(var n=ZH,i=JH,r=0;r<this.categoryPoints.length;r++){var o=this.categoryPoints[r];if(o)for(var a=0;a<o.length;a++){var s=o[a];if(s&&(s.series.stack===t||s.series.axis===e)){var l=this.plotRange(s,0)[1];hR(l)&&isFinite(l)&&(i=Math.max(i,l),n=Math.min(n,l))}}}return{min:n,max:i}},t.prototype.updateStackRange=function(){var e=this,t=this.options,n=t.isStacked,i=t.series,r={};if(n)for(var o=0;o<i.length;o++){var a=i[o],s=a.axis,l=s+a.stack,c=r[l];if(!c){c=e.stackLimits(s,a.stack);var d=e.errorTotals;d&&(d.negative.length&&(c.min=Math.min(c.min,FR(d.negative).min)),d.positive.length&&(c.max=Math.max(c.max,FR(d.positive).max))),c.min!==ZH||c.max!==JH?r[l]=c:c=null}c&&(e.valueAxisRanges[s]=c)}},t.prototype.addErrorBar=function(e,t,n){var i,r=e.value,o=e.series,a=e.seriesIx,s=e.options.errorBars,l=t.fields[tV],c=t.fields[nV];MF(l)&&MF(c)?i={low:l,high:c}:s&&hR(s.value)&&(this.seriesErrorRanges=this.seriesErrorRanges||[],this.seriesErrorRanges[a]=this.seriesErrorRanges[a]||new YO(s.value,o,fF),i=this.seriesErrorRanges[a].getErrorRange(r,s.value)),i&&(e.low=i.low,e.high=i.high,this.addPointErrorBar(e,n))},t.prototype.addPointErrorBar=function(e,t){var n=!this.options.invertAxes,i=e.options.errorBars,r=e.series,o=e.low,a=e.high;if(this.options.isStacked){var s=this.stackedErrorRange(e,t);o=s.low,a=s.high}else{var l={categoryIx:t,series:r};this.updateRange({value:o},l),this.updateRange({value:a},l)}var c=new NN(o,a,n,this,r,i);e.errorBars=[c],e.append(c)},t.prototype.stackedErrorRange=function(e,t){var n=this.plotRange(e,0)[1]-e.value,i=e.low+n,r=e.high+n;return this.errorTotals=this.errorTotals||{positive:[],negative:[]},i<0&&(this.errorTotals.negative[t]=Math.min(this.errorTotals.negative[t]||0,i)),r>0&&(this.errorTotals.positive[t]=Math.max(this.errorTotals.positive[t]||0,r)),{low:i,high:r}},t.prototype.addValue=function(e,t){var n=t.categoryIx,i=t.series,r=t.seriesIx,o=this.categoryPoints[n];o||(this.categoryPoints[n]=o=[]);var a=this.seriesPoints[r];a||(this.seriesPoints[r]=a=[]);var s=this.createPoint(e,t);s&&(Object.assign(s,t),s.owner=this,s.noteText=e.fields.noteText,hR(s.dataItem)||(s.dataItem=i.data[n]),this.addErrorBar(s,e,n)),this.points.push(s),a.push(s),o.push(s),this.updateRange(e.valueFields,t)},t.prototype.evalPointOptions=function(e,t,n){var i=n.categoryIx,r=n.category,o=n.series,a=n.seriesIx,s={defaults:o._defaults,excluded:["data","aggregate","_events","tooltip","content","template","visual","toggle","_outOfRangeMinPoint","_outOfRangeMaxPoint","drilldownSeriesFactory","ariaTemplate","ariaContent"]},l=this._evalSeries[a];hR(l)||(this._evalSeries[a]=l=YN(e,{},s,!0));var c=e;return l&&YN(c=BF({},c),{value:t,category:r,index:i,series:o,dataItem:o.data[i]},s),c},t.prototype.updateRange=function(e,t){var n=t.series.axis,i=e.value,r=this.valueAxisRanges[n];isFinite(i)&&null!==i&&((r=this.valueAxisRanges[n]=r||{min:ZH,max:JH}).min=Math.min(r.min,i),r.max=Math.max(r.max,i))},t.prototype.seriesValueAxis=function(e){var t=this.plotArea,n=e.axis,i=n?t.namedValueAxes[n]:t.valueAxis;if(!i)throw new Error("Unable to locate value axis with name "+n);return i},t.prototype.reflow=function(e){var t=this,n=this.categorySlots=[],i=this.points,r=this.categoryAxis,o=0;this.traverseDataPoints((function(e,a){var s=a.categoryIx,l=a.series,c=t.seriesValueAxis(l),d=i[o++],u=n[s];if(u||(n[s]=u=t.categorySlot(r,s,c)),d){var h=t.plotRange(d,c.startValue()),p=t.valueSlot(c,h);if(p){var f=t.pointSlot(u,p);d.aboveAxis=t.aboveAxis(d,c),d.stackValue=h[1],t.options.isStacked100&&(d.percentage=t.plotValue(d)),t.reflowPoint(d,f)}else d.visible=!1}})),this.reflowCategories(n),!this.options.clip&&this.options.limitPoints&&this.points.length&&this.limitPoints(),this.box=e},t.prototype.valueSlot=function(e,t){return e.getSlot(t[0],t[1],!this.options.clip)},t.prototype.limitPoints=function(){for(var e=this.categoryPoints,t=e[0].concat(bR(e)),n=0;n<t.length;n++)t[n]&&this.limitPoint(t[n])},t.prototype.limitPoint=function(e){var t=this.categoryAxis.limitSlot(e.box);t.equals(e.box)||e.reflow(t)},t.prototype.aboveAxis=function(e,t){var n=this.categoryAxisCrossingValue(t),i=e.value;return t.options.reverse?i<n:i>=n},t.prototype.categoryAxisCrossingValue=function(e){var t=this.categoryAxis,n=e.options;return[].concat(n.axisCrossingValues||n.axisCrossingValue)[t.axisIndex||0]||0},t.prototype.reflowPoint=function(e,t){e.reflow(t)},t.prototype.reflowCategories=function(){},t.prototype.pointSlot=function(e,t){var n=this.options.invertAxes,i=n?t:e,r=n?e:t;return new VL(i.x1,r.y1,i.x2,r.y2)},t.prototype.categorySlot=function(e,t){return e.getSlot(t)},t.prototype.traverseDataPoints=function(e){for(var t=this,n=this.options.series,i=GN(n),r=n.length,o=0;o<r;o++)t._outOfRangeCallback(n[o],"_outOfRangeMinPoint",o,e);for(var a=0;a<i;a++)for(var s=0;s<r;s++){var l=n[s],c=t.categoryAxis.categoryAt(a);e(t.plotArea.bindPoint(l,a),{category:c,categoryIx:a,categoriesCount:i,series:l,seriesIx:s})}for(var d=0;d<r;d++)t._outOfRangeCallback(n[d],"_outOfRangeMaxPoint",d,e)},t.prototype._outOfRangeCallback=function(e,t,n,i){var r=e[t];if(r){var o=r.categoryIx;i(this.plotArea.bindPoint(e,o,r.item),{category:r.category,categoryIx:o,series:e,seriesIx:n,dataItem:r.item})}},t.prototype.formatPointValue=function(e,t){return null===e.value?"":this.chartService.format.auto(t,e.value)},t.prototype.pointValue=function(e){return e.valueFields.value},t}(qL);DR(s$,{series:[],invertAxes:!1,isStacked:!1,clip:!0,limitPoints:!0});var l$={click:function(e,t){return e.trigger(iN,this.eventArgs(t))},hover:function(e,t){return e.trigger(rN,this.eventArgs(t))},over:function(e,t){return e.trigger(oN,this.eventArgs(t))},out:function(e,t){return e.trigger(aN,this.eventArgs(t))},eventArgs:function(e){return{value:this.value,percentage:this.percentage,stackValue:this.stackValue,category:this.category,series:this.series,dataItem:this.dataItem,runningTotal:this.runningTotal,total:this.total,element:vR(e),originalEvent:e,point:this}}},c$={createNote:function(){var e=this.options.notes,t=this.noteText||e.label.text;!1!==e.visible&&hR(t)&&null!==t&&(this.note=new uB({value:this.value,text:t,dataItem:this.dataItem,category:this.category,series:this.series},this.options.notes,this.owner.chartService),this.append(this.note))}},d$=function(e){function t(t,n){e.call(this),this.value=t,this.options=n,this.aboveAxis=SR(this.options.aboveAxis,!0),this.tooltipTracking=!0,this._id=tL()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){var e=this.options.markers;this._rendered||(this._rendered=!0,e.visible&&e.size&&(this.marker=this.createMarker(),this.append(this.marker)),this.createLabel(),this.createNote(),this.errorBar&&this.append(this.errorBar))},t.prototype.createLabel=function(){var e=this.options.labels;e.visible&&(this.label=this.createLabelElement(e),this.append(this.label))},t.prototype.createLabelElement=function(e){return new sB(this.getLabelText(e),BF({align:LH,vAlign:LH,margin:{left:5,right:5},zIndex:SR(e.zIndex,this.series.zIndex)},e),this.pointData())},t.prototype.getLabelText=function(e){var t=GF(e);return t?t(this.pointData()):e.format?this.formatValue(e.format):this.value},t.prototype.getAriaLabelText=function(){var e=this.options.labels,t=KF(e);return t?t(this.pointData()):this.getLabelText(e)},t.prototype.markerBorder=function(){var e=this.options.markers,t=e.background,n=BF({color:this.color},e.border);return hR(n.color)||(n.color=new qr(t).brightness(JO).toHex()),n},t.prototype.createVisual=function(){},t.prototype.createMarker=function(){var e=this.options.markers;return new XL({type:e.type,width:e.size,height:e.size,rotation:e.rotation,background:e.background,border:this.markerBorder(),opacity:e.opacity,pattern:this.options.pattern,zIndex:SR(e.zIndex,this.series.zIndex),animation:e.animation,visual:e.visual,accessibilityOptions:BF({ariaLabel:this.getAriaLabelText(this.options.labels)},this.options.accessibility)},{dataItem:this.dataItem,value:this.value,series:this.series,category:this.category})},t.prototype.markerBox=function(){return this.marker||(this.marker=this.createMarker(),this.marker.reflow(this._childBox)),this.marker.box},t.prototype.reflow=function(e){var t=this.options,n=this.aboveAxis,i=t.vertical;this.render(),this.box=e;var r=e.clone();if(i?n?r.y1-=r.height():r.y2+=r.height():n?r.x1+=r.width():r.x2-=r.width(),this._childBox=r,this.marker&&this.marker.reflow(r),this.reflowLabel(r),this.errorBars)for(var o=0;o<this.errorBars.length;o++)this.errorBars[o].reflow(r);if(this.note){var a=this.markerBox();if(!t.markers.visible||!t.markers.size){var s=a.center();a=new VL(s.x,s.y,s.x,s.y)}this.note.reflow(a)}},t.prototype.reflowLabel=function(e){var t=this.options,n=this.label,i=t.labels.position;n&&(i=(i=i===dV?dF:i)===uV?RH:i,n.reflow(e),n.box.alignTo(this.markerBox(),i),n.reflow(n.box))},t.prototype.createHighlight=function(){var e=this.options.highlight.markers,t=this.markerBorder().color,n=this.options.markers,i=n.size+(n.border.width||0)+(e.border.width||0),r=new XL({type:n.type,width:i,height:i,rotation:n.rotation,background:e.color||t,border:{color:e.border.color,width:e.border.width,opacity:SR(e.border.opacity,1)},opacity:SR(e.opacity,1)});return r.reflow(this._childBox),r.getElement()},t.prototype.highlightVisual=function(){return(this.marker||{}).visual},t.prototype.highlightVisualArgs=function(){var e,t,n=this.marker;if(n)t=n.paddingBox.toRect(),e=n.visual;else{var i=this.options.markers.size,r=i/2,o=this.box.center();t=new Yo([o.x-r,o.y-r],[i,i])}return{options:this.options,rect:t,visual:e}},t.prototype.createFocusHighlight=function(){var e=this.options.markers,t=this.options.accessibility.highlight,n=e.size+(e.border.width||0),i=new XL({type:e.type,width:n,height:n,rotation:e.rotation,background:t.color,border:t.border,opacity:t.opacity,padding:t.border.width/2,zIndex:t.zIndex});return i.reflow(this._childBox),i.getElement()},t.prototype.tooltipAnchor=function(){var e=this.markerBox(),t=this.owner.pane.clipBox();if(!t||t.overlaps(e)){var n,i,r=e.x2+5,o=XH;return this.aboveAxis?(n=e.y1,i=RH):(n=e.y2,i=dF),{point:new OL(r,n),align:{horizontal:o,vertical:i}}}},t.prototype.formatValue=function(e){return this.owner.formatPointValue(this,e)},t.prototype.overlapsBox=function(e){return this.markerBox().overlaps(e)},t.prototype.unclipElements=function(){this.label&&(this.label.options.noclip=!0),this.note&&(this.note.options.noclip=!0)},t.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,percentage:this.percentage,stackValue:this.stackValue,series:this.series}},t.prototype.focusVisual=function(){this.marker&&(this.marker.visual&&this.marker.visual.options.set("id",this._id),this.toggleFocusHighlight(!0))},t.prototype.clearFocusFromVisual=function(){this.marker&&(this.marker.visual&&this.marker.visual.options.set("id",""),this.toggleFocusHighlight(!1))},t.prototype.getIndex=function(){return hR(this.categoryIx)?this.categoryIx:this.pointIx},t}(qL);d$.prototype.defaults={vertical:!0,markers:{visible:!0,background:mF,size:8,type:BH,border:{width:2},opacity:1},labels:{visible:!1,position:dV,margin:WF(3),padding:WF(4),animation:{type:ZO,delay:XO}},notes:{label:{}},highlight:{markers:{border:{color:"#fff",width:2}},zIndex:100},errorBars:{line:{width:1}},accessibility:{tabIndex:0,role:xN,className:CN,ariaRoleDescription:SN}},BF(d$.prototype,l$),BF(d$.prototype,c$);var u$=function(e){function t(t,n,i){e.call(this),this.linePoints=t,this.series=n,this.seriesIx=i}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.points=function(){return this.toGeometryPoints(this.linePoints)},t.prototype.toGeometryPoints=function(e){for(var t=[],n=0,i=e.length;n<i;n++)e[n]&&!1!==e[n].visible&&t.push(e[n]._childBox.toRect().center());return t},t.prototype.createVisual=function(){var e=this,t=this.series.visual;t?(this.visual=t({points:this.toGeometryPoints(this.linePoints),series:this.series,sender:this.getSender(),createVisual:function(){return e.segmentVisual(),e.visual}}),this.visual&&!hR(this.visual.options.zIndex)&&(this.visual.options.zIndex=this.series.zIndex)):this.segmentVisual()},t.prototype.segmentVisual=function(){var e=this.options,t=this.series,n=t.color,i=t._defaults;FF(n)&&i&&(n=i.color);var r=us.fromPoints(this.points(),{stroke:{color:n,width:t.width,opacity:t.opacity,dashType:t.dashType},zIndex:t.zIndex});e.closed&&r.close(),this.visual=r},t.prototype.aliasFor=function(e,t){return this.parent.getNearestPoint(t.x,t.y,this.seriesIx)},t}(qL);DR(u$,{closed:!1});var h$={calculateStepPoints:function(e){for(var t=this.parent.plotArea.seriesCategoryAxis(this.series).options,n=t.justified,i=t.vertical,r=t.reverse,o=i?vF:_F,a=i?_F:vF,s=r?2:1,l=s,c=p$(e[0],o,s,a,l),d=[c],u=1;u<e.length;u++){var h=p$(e[u],o,s,a,l);if(c[o]!==h[o]){var p=new Go;p[o]=c[o],p[a]=h[a],d.push(p,h)}c=h}return n?c!==bR(d)&&d.push(c):d.push(p$(bR(e),o,s,a,r?1:2)),d}};function p$(e,t,n,i,r){var o=e.box,a=new Go;return a[t]=o[t+n],a[i]=o[i+r],a}var f$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.points=function(){return this.calculateStepPoints(this.linePoints)},t}(u$);BF(f$.prototype,h$);var m$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.segmentVisual=function(){var e=this.series,t=e._defaults,n=e.color;FF(n)&&t&&(n=t.color);var i=new RO(this.options.closed).process(this.points()),r=new us({stroke:{color:n,width:e.width,opacity:e.opacity,dashType:e.dashType},zIndex:e.zIndex});r.segments.push.apply(r.segments,i),this.visual=r},t}(u$),g$={renderSegments:function(){var e,t=this,n=this.options,i=this.seriesPoints,r=n.series,o=i.length;this._segments=[];for(var a=0;a<o;a++){for(var s=r[a],l=t.sortPoints(i[a]),c=l.length,d=[],u=0;u<c;u++){var h=l[u];h?d.push(h):t.seriesMissingValues(s)!==lV&&(d.length>1&&(e=t.createSegment(d,s,a,e),t._addSegment(e)),d=[])}d.length>1&&(e=t.createSegment(d,s,a,e),t._addSegment(e))}this.children.unshift.apply(this.children,this._segments)},_addSegment:function(e){this._segments.push(e),e.parent=this},sortPoints:function(e){return e},seriesMissingValues:function(e){var t=e.missingValues;return!t&&this.options.isStacked?sV:t||lV},getNearestPoint:function(e,t,n){for(var i,r=new OL(e,t),o=this.seriesPoints[n],a=ZH,s=0;s<o.length;s++){var l=o[s];if(l&&hR(l.value)&&null!==l.value&&!1!==l.visible){var c=l.box.center().distanceTo(r);c<a&&(i=l,a=c)}}return i}},v$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setup=function(){this._setEnd(this.options.box.x1)},t.prototype.step=function(e){var t=this.options.box;this._setEnd(nR(t.x1,t.x2,e))},t.prototype._setEnd=function(e){var t=this.element,n=t.segments,i=n[1].anchor(),r=n[2].anchor();t.suspend(),i.setX(e),t.resume(),r.setX(e)},t}(nl);DR(v$,{duration:XO}),tl.current.register("clip",v$);var _$={createAnimation:function(){var e=this.getRoot();if(e&&!1!==(e.options||{}).transitions){var t=e.size(),n=us.fromRect(t.toRect());this.visual.clip(n),this.animation=new v$(n,{box:t}),$N(this.options.series)&&this._setChildrenAnimation(n)}},_setChildrenAnimation:function(e){for(var t=this.animationPoints(),n=0;n<t.length;n++){var i=t[n];i&&i.visual&&hR(i.visual.options.zIndex)&&i.visual.clip(e)}}},b$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){e.prototype.render.call(this),this.updateStackRange(),this.renderSegments()},t.prototype.pointType=function(){return d$},t.prototype.createPoint=function(e,t){var n=t.series,i=t.seriesIx,r=this.seriesMissingValues(n),o=e.valueFields.value;if(!hR(o)||null===o){if(r!==sV)return null;o=0}var a=this.pointOptions(n,i);a=this.evalPointOptions(a,o,t);var s=e.fields.color||n.color;FF(n.color)&&(s=a.color);var l=new d$(o,a);return l.color=s,this.append(l),l},t.prototype.plotRange=function(e){var t=this.plotValue(e);if(this.options.isStacked)for(var n=e.categoryIx,i=this.categoryPoints[n],r=0;r<i.length;r++){var o=i[r];if(e===o)break;t+=this.plotValue(o),this.options.isStacked100&&(t=Math.min(t,1))}return[t,t]},t.prototype.createSegment=function(e,t,n){var i=t.style;return new(i===pV?f$:i===hV?m$:u$)(e,t,n)},t.prototype.animationPoints=function(){for(var e=this.points,t=[],n=0;n<e.length;n++)t.push((e[n]||{}).marker);return t.concat(this._segments)},t.prototype.supportsPointInactiveOpacity=function(){return!1},t}(s$);BF(b$.prototype,g$,_$);var y$=function(e){function t(t,n,i,r,o){e.call(this,t,n,i),this.prevSegment=r,this.stackPoints=o}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createVisual=function(){var e=this.series,t=e._defaults,n=e.line||{},i=e.color;FF(i)&&t&&(i=t.color),this.visual=new vs({zIndex:e.zIndex}),this.createFill({fill:KL(e.pattern,{color:i,opacity:e.opacity}),stroke:null}),n.width>0&&!1!==n.visible&&this.createStroke({stroke:BF({color:i,opacity:e.opacity,lineCap:"butt"},n)})},t.prototype.strokeSegments=function(){var e=this._strokeSegments;return e||(e=this._strokeSegments=this.createStrokeSegments()),e},t.prototype.createStrokeSegments=function(){return this.segmentsFromPoints(this.points())},t.prototype.stackSegments=function(){return this.prevSegment?this.prevSegment.createStackSegments(this.stackPoints):this.createStackSegments(this.stackPoints)},t.prototype.createStackSegments=function(e){return this.segmentsFromPoints(this.toGeometryPoints(e)).reverse()},t.prototype.segmentsFromPoints=function(e){return e.map((function(e){return new La(e)}))},t.prototype.createStroke=function(e){var t=new us(e);t.segments.push.apply(t.segments,this.strokeSegments()),this.visual.append(t)},t.prototype.hasStackSegment=function(){return this.prevSegment||this.stackPoints&&this.stackPoints.length},t.prototype.createFill=function(e){var t=this.strokeSegments(),n=t.slice(0),i=this.hasStackSegment();if(i){var r=this.stackSegments();dR(n,r)}var o=new us(e);o.segments.push.apply(o.segments,n),!i&&t.length>1&&this.fillToAxes(o),this.visual.append(o)},t.prototype.fillToAxes=function(e){var t=this.parent,n=t.options.invertAxes,i=t.seriesValueAxis(this.series),r=t.categoryAxisCrossingValue(i),o=i.getSlot(r,r,!0),a=this.strokeSegments(),s=a[0].anchor(),l=bR(a).anchor(),c=n?o.x1:o.y1;n?e.lineTo(c,l.y).lineTo(c,s.y):e.lineTo(l.x,c).lineTo(s.x,c)},t}(u$),w$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createStrokeSegments=function(){return this.segmentsFromPoints(this.calculateStepPoints(this.linePoints))},t.prototype.createStackSegments=function(e){return this.segmentsFromPoints(this.calculateStepPoints(e)).reverse()},t}(y$);BF(w$.prototype,h$);var k$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createStrokeSegments=function(){var e=new RO(this.options.closed),t=this.points();return e.process(t)},t.prototype.createStackSegments=function(){for(var e=this.strokeSegments(),t=[],n=e.length-1;n>=0;n--){var i=e[n];t.push(new La(i.anchor(),i.controlOut(),i.controlIn()))}return t},t}(y$),x$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createSegment=function(e,t,n,i){var r,o,a=this.options.isStacked,s=(t.line||{}).style;a&&n>0&&i&&("gap"!==this.seriesMissingValues(t)?(o=i.linePoints,r=i):o=this._gapStackPoints(e,n,s));return new(s===pV?w$:s===hV?k$:y$)(e,t,n,r,o)},t.prototype.reflow=function(t){e.prototype.reflow.call(this,t);var n=this._stackPoints;if(n)for(var i=0;i<n.length;i++){var r=n[i],o=this.categoryAxis.getSlot(r.categoryIx);r.reflow(o)}},t.prototype._gapStackPoints=function(e,t,n){var i=this,r=this.seriesPoints,o=e[0].categoryIx,a=e.length;o<0&&(o=0,a--);var s=o+a,l=this.seriesOptions[0]._outOfRangeMinPoint?1:0,c=[];this._stackPoints=this._stackPoints||[];for(var d=o;d<s;d++){var u=d+l,h=t,p=void 0;do{p=r[--h][u]}while(h>0&&!p);if(p)n!==pV&&d>o&&!r[h][u-1]&&c.push(i._previousSegmentPoint(d,u,u-1,h)),c.push(p),n!==pV&&d+1<s&&!r[h][u+1]&&c.push(i._previousSegmentPoint(d,u,u+1,h));else{var f=i._createGapStackPoint(d);i._stackPoints.push(f),c.push(f)}}return c},t.prototype._previousSegmentPoint=function(e,t,n,i){for(var r,o=this.seriesPoints,a=i;a>0&&!r;)r=o[--a][n];return r?r=o[a][t]:(r=this._createGapStackPoint(e),this._stackPoints.push(r)),r},t.prototype._createGapStackPoint=function(e){var t=this.pointOptions({},0),n=new d$(0,t);return n.categoryIx=e,n.series={},n},t.prototype.seriesMissingValues=function(e){return e.missingValues||sV},t.prototype.supportsPointInactiveOpacity=function(){return!1},t}(b$),C$=function(e){function t(){e.call(this),this.axisRanges={}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.update=function(e){var t=this.axisRanges;for(var n in e){var i=e[n],r=t[n];t[n]=r=r||{min:ZH,max:JH},r.min=Math.min(r.min,i.min),r.max=Math.max(r.max,i.max)}},t.prototype.reset=function(e){this.axisRanges[e]=void 0},t.prototype.query=function(e){return this.axisRanges[e]},t}(fr),S$=function(e){function t(t,n,i){e.call(this,n),this.textBox=new sB(t,this.options,i),this.append(this.textBox)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createVisual=function(){this.textBox.options.noclip=this.options.noclip},t.prototype.reflow=function(e){var t=this.options,n=t.vertical,i=t.aboveAxis,r=this.children[0],o=r.options,a=r.box,s=r.options.padding,l=e;o.align=n?LH:XH,o.vAlign=n?dF:LH,t.position===IN?n?(o.vAlign=dF,!i&&a.height()<e.height()&&(o.vAlign=RH)):o.align=i?aF:XH:t.position===LH?(o.vAlign=LH,o.align=LH):t.position===zN?n?o.vAlign=i?RH:dF:o.align=i?XH:aF:t.position===PN&&(n?l=i?new VL(e.x1,e.y1-a.height(),e.x2,e.y1):new VL(e.x1,e.y2,e.x2,e.y2+a.height()):(o.align=LH,l=i?new VL(e.x2,e.y1,e.x2+a.width(),e.y2):new VL(e.x1-a.width(),e.y1,e.x1,e.y2))),t.rotation||(n?s.left=s.right=(l.width()-r.contentBox.width())/2:s.top=s.bottom=(l.height()-r.contentBox.height())/2),r.reflow(l)},t.prototype.alignToClipBox=function(e){var t=this.options.vertical?_F:vF,n=t+"1",i=t+"2",r=this.children[0],o=this.parent.box;if(o[n]<e[n]||e[i]<o[i]){var a=r.paddingBox.clone();a[n]=Math.max(o[n],e[n]),a[i]=Math.min(o[i],e[i]),this.reflow(a)}},t}(qL);DR(S$,{position:PN,margin:WF(3),padding:WF(4),color:FH,background:"",border:{width:1,color:""},aboveAxis:!0,vertical:!1,animation:{type:ZO,delay:XO},zIndex:2});var T$={addAccessibilityAttributesToVisual:function(){this._id=this._id||tL();var e=BF({ariaLabel:this.getAriaLabelText()},this.options.accessibility);QL(this.visual,e)},getAriaLabelText:function(){var e=this.options.labels,t=KF(e);return t?t(this.pointData()):this.getLabelText(e)},focusVisual:function(){this.visual.options.set("id",this._id),this.toggleFocusHighlight(!0)},clearFocusFromVisual:function(){this.visual.options.set("id",""),this.toggleFocusHighlight(!1)}},D$=function(e){function t(t,n){e.call(this),this.options=n,this.color=n.color||mF,this.aboveAxis=SR(this.options.aboveAxis,!0),this.value=t}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){this._rendered||(this._rendered=!0,this.createLabel(),this.createNote(),this.errorBar&&this.append(this.errorBar))},t.prototype.createLabel=function(){var e=this.options.labels;e.visible&&(this.label=this.createLabelElement(e),this.append(this.label))},t.prototype.createLabelElement=function(e){return new S$(this.getLabelText(e),BF({vertical:this.options.vertical},e),this.pointData())},t.prototype.getLabelText=function(e){var t=GF(e);return t?t(this.pointData()):this.formatValue(e.format)},t.prototype.formatValue=function(e){return this.owner.formatPointValue(this,e)},t.prototype.reflow=function(e){this.render();var t=this.label;if(this.box=e,t&&(t.options.aboveAxis=this.aboveAxis,t.reflow(e)),this.note&&this.note.reflow(e),this.errorBars)for(var n=0;n<this.errorBars.length;n++)this.errorBars[n].reflow(e)},t.prototype.createVisual=function(){var t=this,n=this.box,i=this.options,r=i.visual;if(!1!==this.visible)if(e.prototype.createVisual.call(this),this.addAccessibilityAttributesToVisual(),r){var o=this.rectVisual=r({category:this.category,dataItem:this.dataItem,value:this.value,sender:this.getSender(),series:this.series,percentage:this.percentage,stackValue:this.stackValue,runningTotal:this.runningTotal,total:this.total,rect:n.toRect(),createVisual:function(){var e=new vs;return t.createRect(e),e},options:i});o&&this.visual.append(o)}else n.width()>0&&n.height()>0&&this.createRect(this.visual)},t.prototype.createRect=function(e){var t=this.options,n=t.border,i=hR(n.opacity)?n.opacity:t.opacity,r=this.box.toRect();r.size.width=Math.round(r.size.width);var o=this.rectVisual=us.fromRect(r,{fill:KL(t.pattern,{color:this.color,opacity:t.opacity}),stroke:{color:this.getBorderColor(),width:n.width,opacity:i,dashType:n.dashType}}),a=this.box.width(),s=this.box.height();if((t.vertical?a:s)>6&&(DF(o),(a<1||s<1)&&(o.options.stroke.lineJoin="round")),e.append(o),JN(t)){var l=this.createGradientOverlay(o,{baseColor:this.color},BF({end:t.vertical?void 0:[0,1]},t.overlay));e.append(l)}},t.prototype.createHighlight=function(e){return DF(us.fromRect(this.box.toRect(),e))},t.prototype.highlightVisual=function(){return this.rectVisual},t.prototype.highlightVisualArgs=function(){return{options:this.options,rect:this.box.toRect(),visual:this.rectVisual}},t.prototype.createFocusHighlight=function(e){var t=this.options.accessibility.highlight.border.width;return DF(us.fromRect(this.box.pad(t/2).toRect(),e))},t.prototype.getBorderColor=function(){var e=this.color,t=this.options.border,n=t._brightness||JO,i=t.color;return hR(i)||(i=new qr(e).brightness(n).toHex()),i},t.prototype.tooltipAnchor=function(){var e,t,n=this,i=n.options,r=n.box,o=n.aboveAxis,a=this.owner.pane.clipBox()||r,s=XH,l=dF;if(i.vertical)e=Math.min(r.x2,a.x2)+5,o?t=Math.max(r.y1,a.y1):(t=Math.min(r.y2,a.y2),l=RH);else{var c=Math.max(r.x1,a.x1),d=Math.min(r.x2,a.x2);i.isStacked?(l=RH,o?(s=aF,e=d):e=c,t=Math.max(r.y1,a.y1)-5):(o?e=d+5:(e=c-5,s=aF),t=Math.max(r.y1,a.y1))}return{point:new OL(e,t),align:{horizontal:s,vertical:l}}},t.prototype.overlapsBox=function(e){return this.box.overlaps(e)},t.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,percentage:this.percentage,stackValue:this.stackValue,runningTotal:this.runningTotal,total:this.total,series:this.series}},t.prototype.getIndex=function(){return this.categoryIx},t}(qL);function A$(e,t){e.forEach(t)}function M$(e,t){for(var n=e.length,i=n-1;i>=0;i--)t(e[i],i-n-1)}BF(D$.prototype,l$),BF(D$.prototype,c$),BF(D$.prototype,T$),D$.prototype.defaults={border:{width:1},vertical:!0,overlay:{gradient:"glass"},labels:{visible:!1,format:"{0}"},opacity:1,notes:{label:{}},accessibility:{role:xN,className:CN,ariaRoleDescription:SN}};var E$=function(e){function t(t){e.call(this,t),this.forEach=t.rtl?M$:A$}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(e){var t=this.options,n=t.vertical,i=t.gap,r=t.spacing,o=this.children,a=o.length,s=n?_F:vF,l=a+i+r*(a-1),c=(n?e.height():e.width())/l,d=e[s+1]+c*(i/2);this.forEach(o,(function(t,n){var i=(t.box||e).clone();i[s+1]=d,i[s+2]=d+c,t.reflow(i),n<a-1&&(d+=c*r),d+=c}))},t}(qL);DR(E$,{vertical:!1,gap:0,spacing:0});var I$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(e){for(var t=this.options.vertical?vF:_F,n=this.children,i=n.length,r=this.box=new VL,o=0;o<i;o++){var a=n[o];if(!1!==a.visible){var s=a.box.clone();s.snapTo(e,t),0===o&&(r=this.box=s.clone()),a.reflow(s),r.wrap(s)}}},t}(qL);DR(I$,{vertical:!0});var z$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){e.prototype.render.call(this),this.updateStackRange()},t.prototype.pointType=function(){return D$},t.prototype.clusterType=function(){return E$},t.prototype.stackType=function(){return I$},t.prototype.stackLimits=function(t,n){return e.prototype.stackLimits.call(this,t,n)},t.prototype.createPoint=function(e,t){var n=t.categoryIx,i=t.series,r=t.seriesIx,o=this.options,a=this.children,s=hR(i.stack)?i.stack:o.defaultStack,l=this.pointValue(e),c=this.pointOptions(i,r),d=c.labels;s&&d.position===PN&&(d.position=IN),c.isStacked=s;var u=e.fields.color||i.color;l<0&&c.negativeColor&&(u=c.negativeColor),c=this.evalPointOptions(c,l,t),FF(i.color)&&(u=c.color);var h=new(this.pointType())(l,c);h.color=u;var p=a[n];p||(p=new(this.clusterType())({vertical:o.invertAxes,gap:o.gap,spacing:o.spacing,rtl:!o.invertAxes&&(this.chartService||{}).rtl}),this.append(p));o.isStacked?this.getStackWrap(s,p).append(h):p.append(h);return h},t.prototype.getStackWrap=function(e,t){var n,i=typeof e===rF?e.group||!0:e,r=t.children;if(typeof i===cF||!0===i)for(var o=0;o<r.length;o++)if(r[o]._stackGroup===i){n=r[o];break}n||((n=new(this.stackType())({vertical:!this.options.invertAxes}))._stackGroup=i,t.append(n));return n},t.prototype.categorySlot=function(e,t,n){var i=this.options,r=e.getSlot(t),o=n.startValue();if(i.isStacked){var a=n.getSlot(o,o,!0),s=i.invertAxes?vF:_F;r[s+1]=r[s+2]=a[s+1]}return r},t.prototype.reflowCategories=function(e){for(var t=this.children,n=t.length,i=0;i<n;i++)t[i].reflow(e[i])},t.prototype.createAnimation=function(){this._setAnimationOptions(),e.prototype.createAnimation.call(this),$N(this.options.series)&&this._setChildrenAnimation()},t.prototype._setChildrenAnimation=function(){for(var e=this.points,t=0;t<e.length;t++){var n=e[t],i=n.visual;i&&hR(i.options.zIndex)&&(n.options.animation=this.options.animation,n.createAnimation())}},t.prototype._setAnimationOptions=function(){var e,t=this.options,n=t.animation||{};if(t.isStacked){var i=this.seriesValueAxis(t.series[0]);e=i.getSlot(i.startValue())}else e=this.categoryAxis.getSlot(0);n.origin=new Go(e.x1,e.y1),n.vertical=!t.invertAxes},t}(s$);DR(z$,{animation:{type:mV}});var P$=function(e){function t(t,n){e.call(this,n),this.value=t}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getLabelText=function(e){return this.formatValue(e.format)},t.prototype.reflow=function(e){var t=this,n=t.options,i=t.value,r=t.owner.seriesValueAxis(n),o=r.getSlot(i.open,i.close),a=r.getSlot(i.low,i.high);o.x1=a.x1=e.x1,o.x2=a.x2=e.x2,this.realBody=o;var s=a.center().x,l=[];l.push([[s,a.y1],[s,o.y1]]),l.push([[s,o.y2],[s,a.y2]]),this.lines=l,this.box=a.clone().wrap(o),this._rendered||(this._rendered=!0,this.createNote()),this.reflowNote()},t.prototype.reflowNote=function(){this.note&&this.note.reflow(this.box)},t.prototype.createVisual=function(){e.prototype.createVisual.call(this),this.addAccessibilityAttributesToVisual(),this._mainVisual=this.mainVisual(this.options),this.visual.append(this._mainVisual),this.createOverlay()},t.prototype.mainVisual=function(e){var t=new vs;return this.createBody(t,e),this.createLines(t,e),t},t.prototype.createBody=function(e,t){var n=us.fromRect(this.realBody.toRect(),{fill:KL(t.pattern,{color:this.color,opacity:t.opacity}),stroke:null});t.border.width>0&&n.options.set("stroke",{color:this.getBorderColor(),width:t.border.width,dashType:t.border.dashType,opacity:SR(t.border.opacity,t.opacity)}),DF(n),e.append(n),JN(t)&&e.append(this.createGradientOverlay(n,{baseColor:this.color},BF({end:t.vertical?void 0:[0,1]},t.overlay)))},t.prototype.createLines=function(e,t){this.drawLines(e,t,this.lines,t.line)},t.prototype.drawLines=function(e,t,n,i){if(n)for(var r={stroke:{color:i.color||this.color,opacity:SR(i.opacity,t.opacity),width:i.width,dashType:i.dashType,lineCap:"butt"}},o=0;o<n.length;o++){var a=us.fromPoints(n[o],r);DF(a),e.append(a)}},t.prototype.getBorderColor=function(){var e=this.options.border,t=e.color;return hR(t)||(t=new qr(this.color).brightness(e._brightness).toHex()),t},t.prototype.createOverlay=function(){var e=us.fromRect(this.box.toRect(),{fill:{color:mF,opacity:0},stroke:null});this.visual.append(e)},t.prototype.createHighlight=function(){var e=this.options.highlight,t=this.color;this.color=e.color||this.color;var n=this.mainVisual(BF({},this.options,{line:{color:this.getBorderColor()}},e));return this.color=t,n},t.prototype.highlightVisual=function(){return this._mainVisual},t.prototype.highlightVisualArgs=function(){return{options:this.options,rect:this.box.toRect(),visual:this._mainVisual}},t.prototype.tooltipAnchor=function(){var e=this.box,t=this.owner.pane.clipBox()||e;return{point:new OL(e.x2+5,Math.max(e.y1,t.y1)+5),align:{horizontal:XH,vertical:dF}}},t.prototype.formatValue=function(e){return this.owner.formatPointValue(this,e)},t.prototype.overlapsBox=function(e){return this.box.overlaps(e)},t.prototype.pointData=function(){return{dataItem:this.dataItem,value:this.value,meanPoints:this.meanPoints,medianPoints:this.medianPoints,whiskerPoints:this.whiskerPoints,stackValue:this.stackValue,series:this.series}},t.prototype.getIndex=function(){return this.categoryIx},t}(qL);P$.prototype.createFocusHighlight=D$.prototype.createFocusHighlight,DR(P$,{vertical:!0,border:{_brightness:.8},line:{width:2},overlay:{gradient:"glass"},tooltip:{format:"<table><tr><th colspan='2'>{4:d}</th></tr><tr><td>Open:</td><td>{0:C}</td></tr><tr><td>High:</td><td>{1:C}</td></tr><tr><td>Low:</td><td>{2:C}</td></tr><tr><td>Close:</td><td>{3:C}</td></tr></table>"},labels:{format:""},highlight:{opacity:1,border:{width:1,opacity:1},line:{width:1,opacity:1}},notes:{visible:!0,label:{}},accessibility:{role:xN,className:CN,ariaRoleDescription:SN}}),BF(P$.prototype,l$),BF(P$.prototype,c$),BF(P$.prototype,T$);var H$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflowCategories=function(e){for(var t=this.children,n=t.length,i=0;i<n;i++)t[i].reflow(e[i])},t.prototype.addValue=function(e,t){var n,i=t.categoryIx,r=t.category,o=t.series,a=t.seriesIx,s=this.children,l=this.options,c=e.valueFields,d=WN(this.splitValue(c)),u=o.data[i],h=this.categoryPoints[i];h||(this.categoryPoints[i]=h=[]),d&&(n=this.createPoint(e,t));var p=s[i];p||(p=new E$({vertical:l.invertAxes,gap:l.gap,spacing:l.spacing,rtl:!l.invertAxes&&(this.chartService||{}).rtl}),this.append(p)),n&&(this.updateRange(c,t),p.append(n),n.categoryIx=i,n.category=r,n.series=o,n.seriesIx=a,n.owner=this,n.dataItem=u,n.noteText=e.fields.noteText),this.points.push(n),h.push(n)},t.prototype.pointType=function(){return P$},t.prototype.createPoint=function(e,t){var n=t.series,i=this.pointType(),r=e.valueFields,o=BF({},n),a=e.fields.color||n.color;o=this.evalPointOptions(o,r,t),n.type!==bV&&n.type!==DV||r.open>r.close&&(a=e.fields.downColor||n.downColor||n.color),FF(n.color)&&(a=o.color),o.vertical=!this.options.invertAxes;var s=new i(r,o);return s.color=a,s},t.prototype.splitValue=function(e){return[e.low,e.open,e.close,e.high]},t.prototype.updateRange=function(e,t){var n=t.series.axis,i=this.splitValue(e),r=this.valueAxisRanges[n]||{min:ZH,max:JH};this.valueAxisRanges[n]={min:Math.min.apply(Math,i.concat([r.min])),max:Math.max.apply(Math,i.concat([r.max]))}},t.prototype.formatPointValue=function(e,t){var n=e.value;return this.chartService.format.auto(t,n.open,n.high,n.low,n.close,e.category)},t.prototype.animationPoints=function(){return this.points},t}(s$);BF(H$.prototype,_$);var F$=function(e){function t(t,n){e.call(this,t,n),this.createNote()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(e){var t,n,i=this,r=i.options,o=i.value,a=i.owner.seriesValueAxis(r);this.boxSlot=n=a.getSlot(o.q1,o.q3),this.realBody=n,this.reflowBoxSlot(e),this.whiskerSlot=t=a.getSlot(o.lower,o.upper),this.reflowWhiskerSlot(e);var s=a.getSlot(o.median);if(o.mean){var l=a.getSlot(o.mean);this.meanPoints=this.calcMeanPoints(e,l)}this.whiskerPoints=this.calcWhiskerPoints(n,t),this.medianPoints=this.calcMedianPoints(e,s),this.box=t.clone().wrap(n),this.reflowNote()},t.prototype.reflowBoxSlot=function(e){this.boxSlot.x1=e.x1,this.boxSlot.x2=e.x2},t.prototype.reflowWhiskerSlot=function(e){this.whiskerSlot.x1=e.x1,this.whiskerSlot.x2=e.x2},t.prototype.calcMeanPoints=function(e,t){return[[[e.x1,t.y1],[e.x2,t.y1]]]},t.prototype.calcWhiskerPoints=function(e,t){var n=t.center().x;return[[[n-5,t.y1],[n+5,t.y1],[n,t.y1],[n,e.y1]],[[n-5,t.y2],[n+5,t.y2],[n,t.y2],[n,e.y2]]]},t.prototype.calcMedianPoints=function(e,t){return[[[e.x1,t.y1],[e.x2,t.y1]]]},t.prototype.renderOutliers=function(e){for(var t=this.value,n=t.outliers||[],i=3*Math.abs(t.q3-t.q1),r=[],o=e.markers||{},a=0;a<n.length;a++){var s=n[a],l=BF({},(o=s<t.q3+i&&s>t.q1-i?e.outliers:e.extremes).border);hR(l.color)||(hR(this.color)?l.color=this.color:l.color=new qr(o.background).brightness(JO).toHex());var c=new XL({type:o.type,width:o.size,height:o.size,rotation:o.rotation,background:o.background,border:l,opacity:o.opacity});c.value=s,r.push(c)}return this.reflowOutliers(r),r},t.prototype.reflowOutliers=function(e){for(var t=this,n=this.owner.seriesValueAxis(this.options),i=this.box.center(),r=0;r<e.length;r++){var o=e[r].value,a=n.getSlot(o);t.options.vertical?a.move(i.x):a.move(void 0,i.y),t.box=t.box.wrap(a),e[r].reflow(a)}},t.prototype.mainVisual=function(t){for(var n=e.prototype.mainVisual.call(this,t),i=this.renderOutliers(t),r=0;r<i.length;r++){var o=i[r].getElement();o&&n.append(o)}return n},t.prototype.createLines=function(e,t){this.drawLines(e,t,this.whiskerPoints,t.whiskers),this.drawLines(e,t,this.medianPoints,t.median),this.drawLines(e,t,this.meanPoints,t.mean)},t.prototype.getBorderColor=function(){return(this.options.border||{}).color?this.options.border.color:this.color?this.color:e.prototype.getBorderColor.call(this)},t}(P$);DR(F$,{border:{_brightness:.8},line:{width:2},median:{color:"#f6f6f6"},mean:{width:2,dashType:"dash",color:"#f6f6f6"},overlay:{gradient:"glass"},tooltip:{format:"<table><tr><th colspan='2'>{6:d}</th></tr><tr><td>Lower:</td><td>{0:C}</td></tr><tr><td>Q1:</td><td>{1:C}</td></tr><tr><td>Median:</td><td>{2:C}</td></tr><tr><td>Mean:</td><td>{5:C}</td></tr><tr><td>Q3:</td><td>{3:C}</td></tr><tr><td>Upper:</td><td>{4:C}</td></tr></table>"},highlight:{opacity:1,border:{width:1,opacity:1},line:{width:1,opacity:1}},notes:{visible:!0,label:{}},outliers:{visible:!0,size:8,type:OH,background:mF,border:{width:2,opacity:1},opacity:0},extremes:{visible:!0,size:8,type:BH,background:mF,border:{width:2,opacity:1},opacity:0}}),BF(F$.prototype,l$);var R$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflowBoxSlot=function(e){this.boxSlot.y1=e.y1,this.boxSlot.y2=e.y2},t.prototype.reflowWhiskerSlot=function(e){this.whiskerSlot.y1=e.y1,this.whiskerSlot.y2=e.y2},t.prototype.calcMeanPoints=function(e,t){return[[[t.x1,e.y1],[t.x1,e.y2]]]},t.prototype.calcWhiskerPoints=function(e,t){var n=t.center().y;return[[[t.x1,n-5],[t.x1,n+5],[t.x1,n],[e.x1,n]],[[t.x2,n-5],[t.x2,n+5],[t.x2,n],[e.x2,n]]]},t.prototype.calcMedianPoints=function(e,t){return[[[t.x1,e.y1],[t.x1,e.y2]]]},t}(F$),L$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.addValue=function(e,t){var n,i=t.categoryIx,r=t.category,o=t.series,a=t.seriesIx,s=this.children,l=this.options,c=e.valueFields,d=WN(this.splitValue(c)),u=o.data[i],h=this.categoryPoints[i];h||(this.categoryPoints[i]=h=[]),d&&(n=this.createPoint(e,t));var p=s[i];p||(p=new E$({vertical:l.invertAxes,gap:l.gap,spacing:l.spacing,rtl:!l.invertAxes&&(this.chartService||{}).rtl}),this.append(p)),n&&(this.updateRange(c,t),p.append(n),n.categoryIx=i,n.category=r,n.series=o,n.seriesIx=a,n.owner=this,n.dataItem=u),this.points.push(n),h.push(n)},t.prototype.pointType=function(){return this.options.invertAxes?R$:F$},t.prototype.splitValue=function(e){return[e.lower,e.q1,e.median,e.q3,e.upper]},t.prototype.updateRange=function(e,t){var n=t.series.axis,i=this.splitValue(e).concat(this.filterOutliers(e.outliers));hR(e.mean)&&(i=i.concat(e.mean));var r=this.valueAxisRanges[n]||{min:ZH,max:JH};this.valueAxisRanges[n]={min:Math.min.apply(Math,i.concat([r.min])),max:Math.max.apply(Math,i.concat([r.max]))}},t.prototype.formatPointValue=function(e,t){var n=e.value;return this.chartService.format.auto(t,n.lower,n.q1,n.median,n.q3,n.upper,n.mean,e.category)},t.prototype.filterOutliers=function(e){for(var t=(e||[]).length,n=[],i=0;i<t;i++){var r=e[i];hR(r)&&null!==r&&n.push(r)}return n},t.prototype.supportsPointInactiveOpacity=function(){return!1},t}(H$),B$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getAxis=function(){var e=this.chart.seriesAxes(this.series);return this.isVertical?e.y:e.x},t}(VN),O$=function(e){function t(t,n){e.call(this,n),this.plotArea=t,this.chartService=t.chartService,this._initFields(),this.render()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._initFields=function(){this.xAxisRanges={},this.yAxisRanges={},this.points=[],this.seriesPoints=[],this.seriesOptions=[],this._evalSeries=[]},t.prototype.render=function(){this.traverseDataPoints(this.addValue.bind(this))},t.prototype.addErrorBar=function(e,t,n){var i,r=e.value[t],o=t+"Value",a=t+"ErrorLow",s=t+"ErrorHigh",l=n.seriesIx,c=n.series,d=e.options.errorBars,u=n[a],h=n[s];MF(r)&&(MF(u)&&MF(h)&&(i={low:u,high:h}),d&&hR(d[o])&&(this.seriesErrorRanges=this.seriesErrorRanges||{x:[],y:[]},this.seriesErrorRanges[t][l]=this.seriesErrorRanges[t][l]||new YO(d[o],c,t),i=this.seriesErrorRanges[t][l].getErrorRange(r,d[o])),i&&this.addPointErrorBar(i,e,t))},t.prototype.addPointErrorBar=function(e,t,n){var i=e.low,r=e.high,o=t.series,a=t.options.errorBars,s=n===_F,l={};t[n+"Low"]=i,t[n+"High"]=r,t.errorBars=t.errorBars||[];var c=new B$(i,r,s,this,o,a);t.errorBars.push(c),t.append(c),l[n]=i,this.updateRange(l,o),l[n]=r,this.updateRange(l,o)},t.prototype.addValue=function(e,t){var n,i=e.x,r=e.y,o=t.seriesIx,a=this.options.series[o],s=this.seriesMissingValues(a),l=this.seriesPoints[o],c=e;e$(i)&&e$(r)||(c=this.createMissingValue(c,s)),c&&((n=this.createPoint(c,t))&&(Object.assign(n,t),this.addErrorBar(n,vF,t),this.addErrorBar(n,_F,t)),this.updateRange(c,t.series)),this.points.push(n),l.push(n)},t.prototype.seriesMissingValues=function(e){return e.missingValues},t.prototype.createMissingValue=function(){},t.prototype.updateRange=function(e,t){var n=this.chartService.intl,i=t.xAxis,r=t.yAxis,o=e.x,a=e.y,s=this.xAxisRanges[i],l=this.yAxisRanges[r];e$(o)&&(s=this.xAxisRanges[i]=s||{min:ZH,max:JH},EF(o)&&(o=rO(n,o)),s.min=Math.min(s.min,o),s.max=Math.max(s.max,o)),e$(a)&&(l=this.yAxisRanges[r]=l||{min:ZH,max:JH},EF(a)&&(a=rO(n,a)),l.min=Math.min(l.min,a),l.max=Math.max(l.max,a))},t.prototype.evalPointOptions=function(e,t,n){var i=n.series,r=n.seriesIx,o={defaults:i._defaults,excluded:["data","tooltip","content","template","visual","toggle","_outOfRangeMinPoint","_outOfRangeMaxPoint","drilldownSeriesFactory","ariaTemplate","ariaContent"]},a=this._evalSeries[r];hR(a)||(this._evalSeries[r]=a=YN(e,{},o,!0));var s=e;return a&&YN(s=BF({},e),{value:t,series:i,dataItem:n.dataItem},o),s},t.prototype.pointType=function(){return d$},t.prototype.pointOptions=function(e,t){var n=this.seriesOptions[t];if(!n){var i=this.pointType().prototype.defaults;this.seriesOptions[t]=n=BF({},i,{markers:{opacity:e.opacity},tooltip:{format:this.options.tooltip.format},labels:{format:this.options.labels.format}},e)}return n},t.prototype.createPoint=function(e,t){var n=t.series,i=this.pointOptions(n,t.seriesIx),r=t.color||n.color;i=this.evalPointOptions(i,e,t),FF(n.color)&&(r=i.color);var o=new d$(e,i);return o.color=r,this.append(o),o},t.prototype.seriesAxes=function(e){var t=e.xAxis,n=e.yAxis,i=this.plotArea,r=t?i.namedXAxes[t]:i.axisX,o=n?i.namedYAxes[n]:i.axisY;if(!r)throw new Error("Unable to locate X axis with name "+t);if(!o)throw new Error("Unable to locate Y axis with name "+n);return{x:r,y:o}},t.prototype.reflow=function(e){var t=this,n=this.points,i=!this.options.clip,r=0;this.traverseDataPoints((function(e,o){var a=n[r++],s=t.seriesAxes(o.series),l=s.x.getSlot(e.x,e.x,i),c=s.y.getSlot(e.y,e.y,i);if(a)if(l&&c){var d=t.pointSlot(l,c);a.reflow(d)}else a.visible=!1})),this.box=e},t.prototype.pointSlot=function(e,t){return new VL(e.x1,t.y1,e.x2,t.y2)},t.prototype.traverseDataPoints=function(e){for(var t=this.options.series,n=this.seriesPoints,i=0;i<t.length;i++){var r=t[i];n[i]||(n[i]=[]);for(var o=0;o<r.data.length;o++){var a=this.plotArea.bindPoint(r,o),s=a.valueFields,l=a.fields;e(s,BF({pointIx:o,series:r,seriesIx:i,dataItem:r.data[o],owner:this},l))}}},t.prototype.formatPointValue=function(e,t){var n=e.value;return this.chartService.format.auto(t,n.x,n.y)},t.prototype.animationPoints=function(){for(var e=this.points,t=[],n=0;n<e.length;n++)t.push((e[n]||{}).marker);return t},t}(qL);DR(O$,{series:[],tooltip:{format:"{0}, {1}"},labels:{format:"{0}, {1}"},clip:!0}),BF(O$.prototype,_$);var V$=function(e){function t(t,n){e.call(this,t,n),this.category=t.category}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createHighlight=function(){var e=this.options.highlight,t=e.border,n=this.options.markers,i=this.box.center(),r=(n.size+n.border.width+t.width)/2,o=new vs,a=new ua(new oa([i.x,i.y+r/5+t.width/2],r+t.width/2),{stroke:{color:"none"},fill:this.createGradient({gradient:"bubbleShadow",color:n.background,stops:[{offset:0,color:n.background,opacity:.3},{offset:1,color:n.background,opacity:0}]})}),s=new ua(new oa([i.x,i.y],r),{stroke:{color:t.color||new qr(n.background).brightness(JO).toHex(),width:t.width,opacity:t.opacity},fill:KL(this.options.pattern,{color:n.background,opacity:e.opacity})});return o.append(a,s),o},t.prototype.createFocusHighlight=function(e){var t=this.options.accessibility.highlight,n=this.options.markers,i=this.box.center(),r=(n.size+n.border.width)/2+t.border.width/2;return new ua(new oa([i.x,i.y],r),e)},t}(d$);V$.prototype.defaults=BF({},V$.prototype.defaults,{labels:{position:LH},highlight:{opacity:1,border:{color:"#fff",width:2,opacity:1}}}),V$.prototype.defaults.highlight.zIndex=void 0;var N$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._initFields=function(){this._maxSize=JH,e.prototype._initFields.call(this)},t.prototype.addValue=function(t,n){null!==t.size&&(t.size>0||t.size<0&&n.series.negativeValues.visible)?(this._maxSize=Math.max(this._maxSize,Math.abs(t.size)),e.prototype.addValue.call(this,t,n)):(this.points.push(null),this.seriesPoints[n.seriesIx].push(null))},t.prototype.reflow=function(t){this.updateBubblesSize(t),e.prototype.reflow.call(this,t)},t.prototype.pointType=function(){return V$},t.prototype.createPoint=function(e,t){var n=t.series,i=n.data.length,r=t.pointIx*(XO/i),o={delay:r,duration:XO-r,type:vV},a=t.color||n.color;e.size<0&&n.negativeValues.visible&&(a=SR(n.negativeValues.color,a));var s=BF({labels:{animation:{delay:r,duration:XO-r}}},this.pointOptions(n,t.seriesIx),{markers:{type:BH,border:n.border,opacity:n.opacity,animation:o}});s=this.evalPointOptions(s,e,t),FF(n.color)&&(a=s.color),s.markers.background=a;var l=new V$(e,s);return l.color=a,this.append(l),l},t.prototype.updateBubblesSize=function(e){for(var t=this.options.series,n=Math.min(e.width(),e.height()),i=0;i<t.length;i++)for(var r=t[i],o=this.seriesPoints[i],a=(r.minSize||Math.max(.02*n,10))/2,s=(r.maxSize||.2*n)/2,l=Math.PI*a*a,c=(Math.PI*s*s-l)/this._maxSize,d=0;d<o.length;d++){var u=o[d];if(u){var h=Math.abs(u.value.size)*c,p=Math.sqrt((l+h)/Math.PI),f=SR(u.options.zIndex,0)+(1-p/s);BF(u.options,{zIndex:f,markers:{size:2*p,zIndex:f},labels:{zIndex:f+1}})}}},t.prototype.formatPointValue=function(e,t){var n=e.value;return this.chartService.format.auto(t,n.x,n.y,n.size,e.category)},t.prototype.createAnimation=function(){},t.prototype.createVisual=function(){},t}(O$);DR(N$,{tooltip:{format:"{3}"},labels:{format:"{3}"}});var $$=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(XL);BF($$.prototype,l$);var U$=function(e){function t(t,n){e.call(this,n),this.aboveAxis=this.options.aboveAxis,this.color=n.color||mF,this.value=t}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){var e=this.options;this._rendered||(this._rendered=!0,hR(this.value.target)&&(this.target=new $$({type:e.target.shape,background:e.target.color||this.color,opacity:e.opacity,zIndex:e.zIndex,border:e.target.border,vAlign:dF,align:aF}),this.target.value=this.value,this.target.dataItem=this.dataItem,this.target.series=this.series,this.append(this.target)),this.createLabel(),this.createNote())},t.prototype.createLabel=function(){var e=this.options.labels;e.visible&&(this.label=this.createLabelElement(e),this.append(this.label))},t.prototype.createLabelElement=function(e){return new S$(this.getLabelText(e),e,this.pointData())},t.prototype.getLabelText=function(e){var t=GF(e);return t?t(this.pointData()):this.formatValue(e.format)},t.prototype.reflow=function(e){this.render();var t=this,n=t.options,i=t.target,r=t.owner,o=n.invertAxes,a=r.seriesValueAxis(this.options),s=r.categorySlot(r.categoryAxis,n.categoryIx,a),l=a.getSlot(this.value.target),c=o?l:s,d=o?s:l;if(i){var u=new VL(c.x1,d.y1,c.x2,d.y2);i.options.height=o?u.height():n.target.line.width,i.options.width=o?n.target.line.width:u.width(),i.reflow(u)}var h=this.label;h&&(h.options.aboveAxis=this.aboveAxis,h.reflow(e)),this.note&&this.note.reflow(e),this.box=e},t.prototype.createVisual=function(){e.prototype.createVisual.call(this),this.addAccessibilityAttributesToVisual();var t=this.options,n=us.fromRect(this.box.toRect(),{fill:KL(t.pattern,{color:this.color,opacity:t.opacity}),stroke:null});t.border.width>0&&n.options.set("stroke",{color:t.border.color||this.color,width:t.border.width,dashType:t.border.dashType,opacity:SR(t.border.opacity,t.opacity)}),this.bodyVisual=n,DF(n),this.visual.append(n)},t.prototype.createAnimation=function(){this.bodyVisual&&(this.animation=nl.create(this.bodyVisual,this.options.animation))},t.prototype.createHighlight=function(e){return us.fromRect(this.box.toRect(),e)},t.prototype.highlightVisual=function(){return this.bodyVisual},t.prototype.highlightVisualArgs=function(){return{rect:this.box.toRect(),visual:this.bodyVisual,options:this.options}},t.prototype.formatValue=function(e){return this.owner.formatPointValue(this,e)},t.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series}},t.prototype.overlapsBox=function(e){return this.box.overlaps(e)},t.prototype.getIndex=function(){return this.categoryIx},t}(qL);U$.prototype.tooltipAnchor=D$.prototype.tooltipAnchor,U$.prototype.createFocusHighlight=D$.prototype.createFocusHighlight,DR(U$,{border:{width:1},vertical:!1,opacity:1,target:{shape:"",border:{width:0,color:"green"},line:{width:2}},labels:{visible:!1},tooltip:{format:"Current: {0}<br />Target: {1}"},notes:{label:{}},accessibility:{role:xN,className:CN,ariaRoleDescription:SN}}),BF(U$.prototype,l$),BF(U$.prototype,c$),BF(U$.prototype,T$);var W$=function(e){function t(t,n){!function(e){for(var t=e.series,n=0;n<t.length;n++){var i=t[n],r=i.data;!r||xF(r[0])||OF(r[0])||(i.data=[r])}}(n),e.call(this,t,n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflowCategories=function(e){for(var t=this.children,n=t.length,i=0;i<n;i++)t[i].reflow(e[i])},t.prototype.plotRange=function(e){var t=e.series,n=this.seriesValueAxis(t),i=this.categoryAxisCrossingValue(n);return[i,e.value.current||i]},t.prototype.createPoint=function(e,t){var n=t.categoryIx,i=t.series,r=this.options,o=this.children,a=e.valueFields,s=BF({vertical:!r.invertAxes,overlay:i.overlay,categoryIx:n,invertAxes:r.invertAxes},i),l=e.fields.color||i.color;s=this.evalPointOptions(s,a,t),FF(i.color)&&(l=s.color);var c=new U$(a,s);c.color=l;var d=o[n];return d||(d=new E$({vertical:r.invertAxes,gap:r.gap,spacing:r.spacing,rtl:!r.invertAxes&&(this.chartService||{}).rtl}),this.append(d)),d.append(c),c},t.prototype.updateRange=function(e,t){var n=e.current,i=e.target,r=t.series.axis,o=this.valueAxisRanges[r];hR(n)&&!isNaN(n)&&hR(i&&!isNaN(i))&&((o=this.valueAxisRanges[r]=o||{min:ZH,max:JH}).min=Math.min(o.min,n,i),o.max=Math.max(o.max,n,i))},t.prototype.formatPointValue=function(e,t){return this.chartService.format.auto(t,e.value.current,e.value.target)},t.prototype.pointValue=function(e){return e.valueFields.current},t.prototype.aboveAxis=function(e){return e.value.current>0},t.prototype.createAnimation=function(){var e=this.points;this._setAnimationOptions();for(var t=0;t<e.length;t++){var n=e[t];n.options.animation=this.options.animation,n.createAnimation()}},t}(s$);W$.prototype._setAnimationOptions=z$.prototype._setAnimationOptions,DR(W$,{animation:{type:mV}});var j$=function(e){function t(t,n){e.call(this),this.chartService=t,this.options=BF({},this.options,n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getStyle=function(e,t){var n=e.background,i=e.border.color;if(t){var r=t.color||t.options.color;n=SR(n,r),i=SR(i,r)}var o=WF(e.padding||{},"auto");return{backgroundColor:n,borderColor:i,font:e.font,color:e.color,opacity:e.opacity,borderWidth:VF(e.border.width),paddingTop:VF(o.top),paddingBottom:VF(o.bottom),paddingLeft:VF(o.left),paddingRight:VF(o.right)}},t.prototype.show=function(e,t,n){e.format=t.format;var i=this.getStyle(t,n);e.style=i;var r=new qr(i.backgroundColor);hR(t.color)||r.isDark()||(e.className="k-chart-tooltip-inverse"),this.chartService.notify(yN,e),this.visible=!0},t.prototype.hide=function(){this.chartService&&this.chartService.notify(wN),this.visible=!1},t.prototype.destroy=function(){delete this.chartService},t}(fr);DR(j$,{border:{width:1},opacity:1});var q$=function(e){function t(t,n,i){e.call(this,t,i),this.crosshair=n,this.formatService=t.format,this.initAxisName()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initAxisName=function(){var e,t=this.crosshair.axis;e=t.plotArea.categoryAxis?t.getCategory?"categoryAxis":"valueAxis":t.options.vertical?"yAxis":"xAxis",this.axisName=e},t.prototype.showAt=function(e){var t=this.crosshair.axis,n=this.options,i=t[n.stickyMode?"getCategory":"getValue"](e),r=i;n.format?r=this.formatService.auto(n.format,i):t.options.type===VH&&(r=this.formatService.auto(t.options.labels.dateFormats[t.options.baseUnit],i)),this.show({point:e,anchor:this.getAnchor(),crosshair:this.crosshair,value:r,axisName:this.axisName,axisIndex:this.crosshair.axis.axisIndex},this.options)},t.prototype.hide=function(){this.chartService.notify(wN,{crosshair:this.crosshair,axisName:this.axisName,axisIndex:this.crosshair.axis.axisIndex})},t.prototype.getAnchor=function(){var e,t,n,i=this.crosshair,r=this.options,o=r.position,a=r.padding,s=!i.axis.options.vertical,l=i.line.bbox();return s?(e=LH,o===RH?(t=dF,n=l.bottomLeft().translate(0,a)):(t=RH,n=l.topLeft().translate(0,-a))):(t=LH,o===XH?(e=aF,n=l.topLeft().translate(-a,0)):(e=XH,n=l.topRight().translate(a,0))),{point:n,align:{horizontal:e,vertical:t}}},t}(j$);DR(q$,{padding:10});var G$=function(e){function t(t,n,i){e.call(this,i),this.axis=n,this.stickyMode=n instanceof sO;var r=this.options.tooltip;r.visible&&(this.tooltip=new q$(t,this,BF({},r,{stickyMode:this.stickyMode})))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.showAt=function(e){this.point=e,this.moveLine(),this.line.visible(!0),this.tooltip&&this.tooltip.showAt(e)},t.prototype.hide=function(){this.line.visible(!1),this.tooltip&&this.tooltip.hide()},t.prototype.moveLine=function(){var e,t=this.axis,n=this.point,i=t.options.vertical,r=this.getBox(),o=i?_F:vF,a=new Go(r.x1,r.y1);if(e=i?new Go(r.x2,r.y1):new Go(r.x1,r.y2),n)if(this.stickyMode){var s=t.getSlot(t.pointCategoryIndex(n));a[o]=e[o]=s.center()[o]}else a[o]=e[o]=n[o];this.box=r,this.line.moveTo(a).lineTo(e)},t.prototype.getBox=function(){for(var e,t=this.axis,n=t.pane.axes,i=n.length,r=t.options.vertical,o=t.lineBox().clone(),a=r?vF:_F,s=0;s<i;s++){var l=n[s];l.options.vertical!==r&&(e?e.wrap(l.lineBox()):e=l.lineBox().clone())}return o[a+1]=e[a+1],o[a+2]=e[a+2],o},t.prototype.createVisual=function(){e.prototype.createVisual.call(this);var t=this.options;this.line=new us({stroke:{color:t.color,width:t.width,opacity:t.opacity,dashType:t.dashType},visible:!1}),this.moveLine(),this.visual.append(this.line)},t.prototype.destroy=function(){this.tooltip&&this.tooltip.destroy(),e.prototype.destroy.call(this)},t}(qL);DR(G$,{color:FH,width:2,zIndex:-1,tooltip:{visible:!1}});var K$=function(e){function t(t,n){e.call(this,t),this.pane=n}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.shouldClip=function(){for(var e=this.children,t=e.length,n=0;n<t;n++)if(!0===e[n].options.clip)return!0;return!1},t.prototype._clipBox=function(){return this.pane.chartsBox()},t.prototype.createVisual=function(){if(this.visual=new vs({zIndex:0}),this.shouldClip()){var e=(this.clipBox=this._clipBox()).toRect(),t=us.fromRect(e);DF(t),this.visual.clip(t),this.unclipLabels()}},t.prototype.stackRoot=function(){return this},t.prototype.unclipLabels=function(){for(var e=this.children,t=this.clipBox,n=0;n<e.length;n++)for(var i=e[n].points||{},r=i.length,o=0;o<r;o++){var a=i[o];if(a&&!1!==a.visible&&a.overlapsBox&&a.overlapsBox(t))if(a.unclipElements)a.unclipElements();else{var s=a.label,l=a.note;s&&s.options.visible&&(s.alignToClipBox&&s.alignToClipBox(t),s.options.noclip=!0),l&&l.options.visible&&(l.options.noclip=!0)}}},t.prototype.destroy=function(){e.prototype.destroy.call(this),delete this.parent},t}(qL);K$.prototype.isStackRoot=!0;var Y$=function(e){function t(t){e.call(this,t),this.id="pane"+Q$++,this.createTitle(),this.content=new qL,this.chartContainer=new K$({},this),this.append(this.content),this.axes=[],this.charts=[]}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createTitle=function(){var e=this.options.title;OF(e)&&(e=BF({},e,{align:e.position,position:dF})),this.title=lB.buildTitle(e,t.prototype.options.title),this.title&&this.append(this.title)},t.prototype.appendAxis=function(e){this.content.append(e),this.axes.push(e),e.pane=this},t.prototype.appendAxisAt=function(e,t){this.content.append(e),this.axes.splice(t,0,e),e.pane=this},t.prototype.appendChart=function(e){this.chartContainer.parent!==this.content&&this.content.append(this.chartContainer),this.charts.push(e),this.chartContainer.append(e),e.pane=this},t.prototype.empty=function(){var e=this.parent;if(e){for(var t=0;t<this.axes.length;t++)e.removeAxis(this.axes[t]);for(var n=0;n<this.charts.length;n++)e.removeChart(this.charts[n])}this.axes=[],this.charts=[],this.content.destroy(),this.content.children=[],this.chartContainer.children=[]},t.prototype.reflow=function(t){var n;bR(this.children)===this.content&&(n=this.children.pop()),e.prototype.reflow.call(this,t),n&&this.children.push(n),this.title&&(this.contentBox.y1+=this.title.box.height())},t.prototype.visualStyle=function(){var t=e.prototype.visualStyle.call(this);return t.zIndex=-10,t},t.prototype.renderComplete=function(){this.options.visible&&this.createGridLines()},t.prototype.stackRoot=function(){return this},t.prototype.clipRoot=function(){return this},t.prototype.createGridLines=function(){for(var e=this.axes,t=e.concat(this.parent.axes),n=[],i=[],r=0;r<e.length;r++)for(var o=e[r],a=o.options.vertical,s=a?n:i,l=0;l<t.length;l++)if(0===s.length){var c=t[l];a!==c.options.vertical&&dR(s,o.createGridLines(c))}},t.prototype.refresh=function(){this.visual.clear(),this.content.parent=null,this.content.createGradient=this.createGradient.bind(this),this.content.renderVisual(),this.content.parent=this,this.title&&this.visual.append(this.title.visual),this.visual.append(this.content.visual),this.renderComplete(),this.notifyRender()},t.prototype.chartsBox=function(){for(var e=this.axes,t=e.length,n=new VL,i=0;i<t;i++){var r=e[i],o=r.options.vertical?_F:vF,a=r.lineBox();n[o+1]=a[o+1],n[o+2]=a[o+2]}if(0===n.x2)for(var s=this.parent.axes,l=s.length,c=0;c<l;c++){var d=s[c];if(!d.options.vertical){var u=d.lineBox();n.x1=u.x1,n.x2=u.x2}}return n},t.prototype.clipBox=function(){return this.chartContainer.clipBox},t.prototype.notifyRender=function(){var e=this.getService();e&&e.notify(kN,{pane:new NO(this),index:this.paneIndex,name:this.options.name})},t}(YL),Q$=1;Y$.prototype.isStackRoot=!0,DR(Y$,{zIndex:-1,shrinkToFit:!0,title:{align:XH},visible:!0});var X$=function(e){function t(t,n,i){e.call(this,n),this.initFields(t,n),this.series=t,this.initSeries(),this.charts=[],this.options.legend=this.options.legend||{},this.options.legend.data=[],this.axes=[],this.crosshairs=[],this.chartService=i,this.originalOptions=n,this.originalSeries=t,this._bindCache=new WeakMap,this.createPanes(),this.render(),this.createCrosshairs()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initFields=function(){},t.prototype.initSeries=function(){for(var e=this.series,t=0;t<e.length;t++)e[t].index=t},t.prototype.bindPoint=function(e,t,n){var i=this._bindCache.get(e);i||(i=[],this._bindCache.set(e,i));var r=i[t];return r||(r=i[t]=qO.current.bindPoint(e,t,n)),r},t.prototype.createPanes=function(){for(var e=this.options.title||{},t=this.options.paneDefaults,n=this.options.panes||[],i=Math.max(n.length,1),r=[],o=BF({title:{color:e.color}},t),a=0;a<i;a++){var s=BF({},o,n[a]);EF(s.title)&&(s.title=BF({text:s.title},o.title));var l=new Y$(s);l.paneIndex=a,r.push(l),this.append(l)}this.panes=r},t.prototype.crosshairOptions=function(e){return e.options.crosshair},t.prototype.createCrosshairs=function(e){var t=this;void 0===e&&(e=this.panes);for(var n=0;n<e.length;n++)for(var i=e[n],r=0;r<i.axes.length;r++){var o=i.axes[r],a=t.crosshairOptions(o);if(a&&a.visible){var s=new G$(t.chartService,o,a);t.crosshairs.push(s),i.content.append(s)}}},t.prototype.removeCrosshairs=function(e){for(var t=this.crosshairs,n=e.axes,i=t.length-1;i>=0;i--)for(var r=0;r<n.length;r++)if(t[i].axis===n[r]){t.splice(i,1);break}},t.prototype.hideCrosshairs=function(){for(var e=this.crosshairs,t=0;t<e.length;t++)e[t].hide()},t.prototype.findPane=function(e){for(var t,n=this.panes,i=0;i<n.length;i++)if(n[i].options.name===e){t=n[i];break}return t||n[0]},t.prototype.findPointPane=function(e){for(var t,n=this.panes,i=0;i<n.length;i++)if(n[i].box.containsPoint(e)){t=n[i];break}return t},t.prototype.appendAxis=function(e){this.findPane(e.options.pane).appendAxis(e),this.axes.push(e),e.plotArea=this},t.prototype.removeAxis=function(e){for(var t=[],n=0;n<this.axes.length;n++){var i=this.axes[n];e!==i?t.push(i):i.destroy()}this.axes=t},t.prototype.appendChart=function(e,t){this.charts.push(e),t?t.appendChart(e):this.append(e)},t.prototype.removeChart=function(e){for(var t=[],n=0;n<this.charts.length;n++){var i=this.charts[n];i!==e?t.push(i):i.destroy()}this.charts=t},t.prototype.addToLegend=function(e){for(var t=e.length,n=this.options.legend,i=n.labels||{},r=n.inactiveItems||{},o=r.labels||{},a=[],s=0;s<t;s++){var l=e[s],c=!1!==l.visible;if(!1!==l.visibleInLegend){var d=l.name,u=c?GF(i):GF(o)||GF(i);u&&(d=u({text:e$(d)?d:"",series:l}));var h=l._defaults,p=l.color;FF(p)&&h&&(p=h.color);var f=void 0,m=void 0;c?(f={},m=p):(f={color:o.color,font:o.font},m=r.markers.color),e$(d)&&""!==d&&a.push({text:d,labels:f,markerColor:m,series:l,active:c})}}dR(n.data,a)},t.prototype.groupAxes=function(e){for(var t=[],n=[],i=0;i<e.length;i++)for(var r=e[i].axes,o=0;o<r.length;o++){var a=r[o];a.options.vertical?n.push(a):t.push(a)}return{x:t,y:n,any:t.concat(n)}},t.prototype.groupSeriesByPane=function(){for(var e=this.series,t={},n=0;n<e.length;n++){var i=e[n],r=this.seriesPaneName(i);t[r]?t[r].push(i):t[r]=[i]}return t},t.prototype.filterVisibleSeries=function(e){for(var t=[],n=0;n<e.length;n++){var i=e[n];!1!==i.visible&&t.push(i)}return t},t.prototype.reflow=function(e){var t=this.options.plotArea,n=this.panes,i=WF(t.margin);this.box=e.clone().unpad(i),this.reflowPanes(),this.detachLabels(),this.reflowAxes(n),this.reflowCharts(n)},t.prototype.redraw=function(e){var t=[].concat(e);this.initSeries();var n=this.getRoot();n&&n.cleanGradients();for(var i=0;i<t.length;i++)this.removeCrosshairs(t[i]),t[i].empty();this._bindCache=new WeakMap,this.render(t),this.detachLabels(),this.reflowAxes(this.panes),this.reflowCharts(t),this.createCrosshairs(t);for(var r=0;r<t.length;r++)t[r].refresh()},t.prototype.axisCrossingValues=function(e,t){for(var n=e.options,i=[].concat(n.axisCrossingValues||n.axisCrossingValue),r=t.length-i.length,o=i[0]||0,a=0;a<r;a++)i.push(o);return i},t.prototype.alignAxisTo=function(e,t,n,i){var r=e.getSlot(n,n,!0),o=e.options.reverse?2:1,a=t.getSlot(i,i,!0),s=t.options.reverse?2:1,l=e.box.translate(a[vF+s]-r[vF+o],a[_F+s]-r[_F+o]);e.pane!==t.pane&&l.translate(0,e.pane.box.y1-t.pane.box.y1),e.reflow(l)},t.prototype.alignAxes=function(e,t){for(var n=this,i=e[0],r=t[0],o=this.axisCrossingValues(i,t),a=this.axisCrossingValues(r,e),s={},l={},c={},d={},u=0;u<t.length;u++){var h=t[u],p=h.pane,f=p.id,m=!1!==h.options.visible,g=eU(e,p)||i,v=o;if(g!==i&&(v=n.axisCrossingValues(g,t)),n.alignAxisTo(h,g,a[u],v[u]),!h.options._overlap){xR(h.lineBox().x1)===xR(g.lineBox().x1)&&(s[f]&&h.reflow(h.box.alignTo(s[f].box,XH).translate(-h.options.margin,0)),m&&(s[f]=h)),xR(h.lineBox().x2)===xR(g.lineBox().x2)&&(h._mirrored||(h.options.labels.mirror=!h.options.labels.mirror,h._mirrored=!0),n.alignAxisTo(h,g,a[u],v[u]),l[f]&&h.reflow(h.box.alignTo(l[f].box,aF).translate(h.options.margin,0)),m&&(l[f]=h));var _=eU(t,p)||r;_!==h&&(h.alignTo(_),h.reflow(h.box))}}for(var b=0;b<e.length;b++){var y=e[b],w=y.pane,k=w.id,x=!1!==y.options.visible,C=eU(t,w)||r,S=a;C!==r&&(S=n.axisCrossingValues(C,e)),n.alignAxisTo(y,C,o[b],S[b]),y.options._overlap||(xR(y.lineBox().y1)===xR(C.lineBox().y1)&&(y._mirrored||(y.options.labels.mirror=!y.options.labels.mirror,y._mirrored=!0),n.alignAxisTo(y,C,o[b],S[b]),c[k]&&y.reflow(y.box.alignTo(c[k].box,dF).translate(0,-y.options.margin)),x&&(c[k]=y)),xR(y.lineBox().y2,3)===xR(C.lineBox().y2,3)&&(d[k]&&y.reflow(y.box.alignTo(d[k].box,RH).translate(0,y.options.margin)),x&&(d[k]=y)),0!==b&&(y.alignTo(i),y.reflow(y.box)))}},t.prototype.shrinkAxisWidth=function(e){for(var t=this.groupAxes(e).any,n=J$(t),i=0,r=0;r<e.length;r++){var o=e[r];o.axes.length>0&&(i=Math.max(i,n.width()-o.contentBox.width()))}if(0!==i)for(var a=0;a<t.length;a++){var s=t[a];s.options.vertical||s.reflow(s.box.shrink(i,0))}},t.prototype.shrinkAxisHeight=function(e){for(var t,n=0;n<e.length;n++){var i=e[n],r=i.axes,o=Math.max(0,J$(r).height()-i.contentBox.height());if(0!==o){for(var a=0;a<r.length;a++){var s=r[a];s.options.vertical&&s.reflow(s.box.shrink(0,o))}t=!0}}return t},t.prototype.fitAxes=function(e){for(var t=this.groupAxes(e).any,n=0,i=0;i<e.length;i++){var r=e[i],o=r.axes,a=r.contentBox;if(o.length>0){var s=J$(o),l=Math.max(a.y1-s.y1,a.y2-s.y2);n=Math.max(n,a.x1-s.x1);for(var c=0;c<o.length;c++){var d=o[c];d.reflow(d.box.translate(0,l))}}}for(var u=0;u<t.length;u++){var h=t[u];h.reflow(h.box.translate(n,0))}},t.prototype.reflowAxes=function(e){for(var t=this.groupAxes(e),n=0;n<e.length;n++)this.reflowPaneAxes(e[n]);t.x.length>0&&t.y.length>0&&(this.alignAxes(t.x,t.y),this.shrinkAxisWidth(e),this.autoRotateAxisLabels(t),this.alignAxes(t.x,t.y),this.shrinkAxisWidth(e)&&this.alignAxes(t.x,t.y),this.shrinkAxisHeight(e),this.alignAxes(t.x,t.y),this.shrinkAxisHeight(e)&&this.alignAxes(t.x,t.y),this.fitAxes(e))},t.prototype.autoRotateAxisLabels=function(e){for(var t,n=this.panes,i=tU(n),r=0;r<i.length;r++){i[r].autoRotateLabels()&&(t=!0)}if(t){for(var o=0;o<n.length;o++)this.reflowPaneAxes(n[o]);e.x.length>0&&e.y.length>0&&(this.alignAxes(e.x,e.y),this.shrinkAxisWidth(n))}},t.prototype.reflowPaneAxes=function(e){var t=e.axes,n=t.length;if(n>0)for(var i=0;i<n;i++)t[i].reflow(e.contentBox)},t.prototype.reflowCharts=function(e){for(var t=this.charts,n=t.length,i=this.box,r=0;r<n;r++){var o=t[r].pane;o&&!tR(o,e)||t[r].reflow(i)}},t.prototype.reflowPanes=function(){for(var e=this.box,t=this.panes,n=t.length,i=e.height(),r=0,o=e.y1,a=0;a<n;a++){var s=t[a],l=s.options.height;if(s.options.width=e.width(),s.options.height){if(l.indexOf&&l.indexOf("%")){var c=parseInt(l,10)/100;s.options.height=c*e.height()}s.reflow(e.clone()),i-=s.options.height}else r++}for(var d=0;d<n;d++){var u=t[d];u.options.height||(u.options.height=i/r)}for(var h=0;h<n;h++){var p=t[h],f=e.clone().move(e.x1,o);p.reflow(f),o+=p.options.height}},t.prototype.backgroundBox=function(){for(var e,t=this.axes,n=t.length,i=0;i<n;i++)for(var r=t[i],o=0;o<n;o++){var a=t[o];if(r.options.vertical!==a.options.vertical){var s=r.lineBox().clone().wrap(a.lineBox());e=e?e.wrap(s):s}}return e||this.box},t.prototype.chartsBoxes=function(){for(var e=this.panes,t=[],n=0;n<e.length;n++)t.push(e[n].chartsBox());return t},t.prototype.addBackgroundPaths=function(e){for(var t=this.chartsBoxes(),n=0;n<t.length;n++)e.paths.push(us.fromRect(t[n].toRect()))},t.prototype.backgroundContainsPoint=function(e){for(var t=this.chartsBoxes(),n=0;n<t.length;n++)if(t[n].containsPoint(e))return!0},t.prototype.createVisual=function(){e.prototype.createVisual.call(this);var t,n=this.options.plotArea,i=n.opacity,r=n.background,o=n.border;void 0===o&&(o={}),""!==(t=r)&&null!==t&&"none"!==t&&"transparent"!==t&&hR(t)||(r=mF,i=0);var a=this._bgVisual=new hs({fill:{color:r,opacity:i},stroke:{color:o.width?o.color:"",width:o.width,dashType:o.dashType},zIndex:-1});this.addBackgroundPaths(a),this.appendVisual(a)},t.prototype.pointsByCategoryIndex=function(e){var t=this.charts,n=[];if(null!==e)for(var i=0;i<t.length;i++){if("_navigator"!==t[i].pane.options.name){var r=t[i].categoryPoints[e];if(r&&r.length)for(var o=0;o<r.length;o++){var a=r[o];a&&hR(a.value)&&null!==a.value&&n.push(a)}}}return n},t.prototype.pointsBySeriesIndex=function(e){return this.filterPoints((function(t){return t.series.index===e}))},t.prototype.pointsByPointIndex=function(e){return this.filterPoints((function(t){return t.getIndex()===e}))},t.prototype.pointsBySeriesName=function(e){return this.filterPoints((function(t){return t.series.name===e}))},t.prototype.filterPoints=function(e){for(var t=this.charts,n=[],i=0;i<t.length;i++)for(var r=t[i].points,o=0;o<r.length;o++){var a=r[o];a&&!1!==a.visible&&e(a)&&n.push(a)}return n},t.prototype.findPoint=function(e){for(var t=this.charts,n=0;n<t.length;n++)for(var i=t[n].points,r=0;r<i.length;r++){var o=i[r];if(o&&!1!==o.visible&&e(o))return o}},t.prototype.paneByPoint=function(e){for(var t=this.panes,n=0;n<t.length;n++){var i=t[n];if(i.box.containsPoint(e))return i}},t.prototype.detachLabels=function(){var e=this.groupAxes(this.panes),t=e.x,n=e.y;this.detachAxisGroupLabels(n,t),this.detachAxisGroupLabels(t,n)},t.prototype.detachAxisGroupLabels=function(e,t){for(var n=0,i=0;i<e.length;i++){var r=e[i],o=r.pane,a=eU(t,o)||t[0],s=i+n,l=this.createLabelAxis(r,s,a);if(l){n++;var c=o.axes.indexOf(r)+n;o.appendAxisAt(l,c)}}},t.prototype.createLabelAxis=function(e,t,n){var i=e.options.labels,r=i.position,o=r!==WH&&r!==lF,a=i.visible;if(o||!1===a)return null;var s=this.groupAxes(this.panes),l=n.options.vertical?s.x:s.y,c=this.axisCrossingValues(n,l),d=r===WH,u=n.range(),h=d?u.max:u.min;if(yR(c[t],u.min,u.max)-h==0)return null;c.splice(t+1,0,h),n.options.axisCrossingValues=c;var p=e.clone();return e.clear(),p.options.name=void 0,p.options.line.visible=!1,p.options.crosshair=void 0,p.options.notes=void 0,p.options.plotBands=void 0,p},t.prototype.isTrendline=function(e){return e&&tR(e.type,JV)},t.prototype.trendlineFactory=function(){},t.prototype.createTrendlineSeries=function(){var e=this,t=[];return this.series=this.series.map((function(n){if(!e.isTrendline(n))return n;var i=e.seriesByName(n.for);if(!i)throw new Error('Invalid Configuration: Unable to locate linked series "'+n.for+'" for trendline "'+n.name+'".');var r=qO.current.valueFields(i),o=bR(r),a=e.trendlineFactory(Object.assign({},{field:o},n),i);return a&&(!1===i.visible&&(a.visible=!1),a.color===QH&&(a.color=i.color),t.push(a)),a})).filter((function(e){return null!==e})),t},t.prototype.seriesByName=function(e){return this.series.find((function(t){return t.name===e}))},t.prototype.getFirstPoint=function(){return this.pointsBySeriesIndex(0)[0]},t.prototype.getPointBelow=function(e){return this._getNextPoint(e,this._pointsByVertical,1)},t.prototype.getPointAbove=function(e){return this._getNextPoint(e,this._pointsByVertical,-1)},t.prototype.getPointToTheRight=function(e){return this._getNextPoint(e,this._pointsByHorizontal,1)},t.prototype.getPointToTheLeft=function(e){return this._getNextPoint(e,this._pointsByHorizontal,-1)},t.prototype._getNextPoint=function(e,t,n){var i=this,r=t.call(this,e),o=r.indexOf(e)+n,a=function(n){var r,o=0;do{o+=n,r=t.call(i,e,o)}while(0===r.length);return r};return o<0?(r=a(-1)).at(-1):o>=r.length?(r=a(1)).at(0):r[o]},t.prototype._pointsByVertical=function(e){return this.pointsByPointIndex(e.getIndex())},t.prototype._pointsByHorizontal=function(e,t){void 0===t&&(t=0);var n=HF(e.series.index+t,this.series.length);return this.pointsBySeriesIndex(n)},t}(qL);function Z$(e){return!e.pane.axes.some((function(t){return t.options.vertical===e.options.vertical&&t!==e&&!1!==t.options.visible}))}function J$(e){for(var t,n=e.length,i=0;i<n;i++){var r=e[i],o=!1!==r.options.visible;if(o||Z$(r)){var a=o?r.contentBox():r.lineBox();t?t.wrap(a):t=a.clone()}}return t||new VL}function eU(e,t){for(var n=0;n<e.length;n++){var i=e[n];if(i&&i.pane===t)return i}}var tU=function(e){return e.reduce((function(e,t){return e.concat(t.axes)}),[])};DR(X$,{series:[],plotArea:{margin:{}},background:"",border:{color:FH,width:0},paneDefaults:{title:{}},legend:{inactiveItems:{labels:{color:"#919191"},markers:{color:"#919191"}}}});var nU={hover:function(e,t){this._dispatchEvent(e,t,lN)},click:function(e,t){this._dispatchEvent(e,t,sN)}},iU=function(e){function t(t,n,i){e.call(this);var r=n.canonicalFields(t),o=n.valueFields(t),a=n.sourceFields(t,r),s=this._seriesFields=[],l=i.query(t.type),c=t.aggregate||l;this._series=t,this._binder=n;for(var d=0;d<r.length;d++){var u=r[d],h=void 0;if(OF(c))h=c[u];else{if(0!==d&&!tR(u,o))break;h=c}h&&s.push({canonicalName:u,name:a[d],transform:FF(h)?h:WO[h]})}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.aggregatePoints=function(e,t){var n=this._series,i=this._seriesFields,r=this._bindPoints(e||[]),o=r.dataItems[0],a={};if(o&&!MF(o)&&!xF(o)){var s=function(){};s.prototype=o,a=new s}for(var l=0;l<i.length;l++){var c=i[l],d=this._bindField(r.values,c.canonicalName),u=c.transform(d,n,r.dataItems,t);if(!(null===u||!OF(u)||hR(u.length)||u instanceof Date)){a=u;break}hR(u)&&rU(c.name,a,u)}return a},t.prototype._bindPoints=function(e){for(var t=this._binder,n=this._series,i=[],r=[],o=0;o<e.length;o++){var a=e[o];i.push(t.bindPoint(n,a)),r.push(n.data[a])}return{values:i,dataItems:r}},t.prototype._bindField=function(e,t){for(var n=[],i=e.length,r=0;r<i;r++){var o=e[r],a=o.valueFields,s=void 0;s=hR(a[t])?a[t]:o.fields[t],n.push(s)}return n},t}(fr);function rU(e,t,n){var i=t,r=e;if(e.indexOf(".")>-1){for(var o=e.split(".");o.length>1;)r=o.shift(),hR(i[r])||(i[r]={}),i=i[r];r=o.shift()}i[r]=n}var oU=function(e){function t(){e.call(this),this._defaults={}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.register=function(e,t){for(var n=0;n<e.length;n++)this._defaults[e[n]]=t},t.prototype.query=function(e){return this._defaults[e]},t}(fr);oU.current=new oU;var aU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createLabel=function(){var e=this.options.labels,t=BF({},e,e.from),n=BF({},e,e.to);t.visible&&(this.labelFrom=this.createLabelElement(t),this.append(this.labelFrom)),n.visible&&(this.labelTo=this.createLabelElement(n),this.append(this.labelTo))},t.prototype.reflow=function(e){this.render();var t=this,n=t.labelFrom,i=t.labelTo,r=t.value;this.box=e,n&&(n.options.aboveAxis=r.from>r.to,n.reflow(e)),i&&(i.options.aboveAxis=r.to>r.from,i.reflow(e)),this.note&&this.note.reflow(e)},t}(D$);aU.prototype.defaults=BF({},aU.prototype.defaults,{labels:{format:"{0} - {1}"},tooltip:{format:"{1}"}});var sU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.pointType=function(){return aU},t.prototype.pointValue=function(e){return e.valueFields},t.prototype.formatPointValue=function(e,t){return null===e.value.from&&null===e.value.to?"":this.chartService.format.auto(t,e.value.from,e.value.to)},t.prototype.plotRange=function(e){return e?[e.value.from,e.value.to]:0},t.prototype.updateRange=function(e,t){var n=t.series.axis,i=e.from,r=e.to,o=this.valueAxisRanges[n];null!==e&&MF(i)&&MF(r)&&((o=this.valueAxisRanges[n]=o||{min:ZH,max:JH}).min=Math.min(o.min,i),o.max=Math.max(o.max,i),o.min=Math.min(o.min,r),o.max=Math.max(o.max,r))},t.prototype.aboveAxis=function(e){var t=e.value;return t.from<t.to},t}(z$);sU.prototype.plotLimits=s$.prototype.plotLimits;var lU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.aliasFor=function(){return this.parent},t}(d$),cU="auto",dU=function(e){function t(t,n){e.call(this),this.value=t,this.options=n,this.aboveAxis=SR(this.options.aboveAxis,!0),this.tooltipTracking=!0,this._id=tL(),this.initLabelsFormat()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){if(!this._rendered){this._rendered=!0;var e=this.options,t=e.markers,n=e.labels,i=this.value,r=this.fromPoint=new lU(i,BF({},this.options,{labels:n.from,markers:t.from})),o=this.toPoint=new lU(i,BF({},this.options,{labels:n.to,markers:t.to}));this.copyFields(r),this.copyFields(o),this.append(r),this.append(o)}},t.prototype.reflow=function(e){this.render();var t=e.from,n=e.to;this.positionLabels(t,n),this.fromPoint.reflow(t),this.toPoint.reflow(n),this.box=this.fromPoint.markerBox().clone().wrap(this.toPoint.markerBox())},t.prototype.createHighlight=function(){var e=new vs;return e.append(this.fromPoint.createHighlight()),e.append(this.toPoint.createHighlight()),e},t.prototype.highlightVisual=function(){return this.visual},t.prototype.highlightVisualArgs=function(){return{options:this.options,from:this.fromPoint.highlightVisualArgs(),to:this.toPoint.highlightVisualArgs()}},t.prototype.createFocusHighlight=function(){var e=new vs;return e.append(this.fromPoint.createFocusHighlight()),e.append(this.toPoint.createFocusHighlight()),e},t.prototype.tooltipAnchor=function(){var e=this.owner.pane.clipBox();if(!e||e.overlaps(this.box)){var t,n,i,r=this.box,o=r.center(),a=XH;return this.options.vertical?(t=o.x,n=r.y1-5,i=RH):(t=r.x2+5,n=o.y,i=LH),{point:new OL(t,n),align:{horizontal:a,vertical:i}}}},t.prototype.formatValue=function(e){return this.owner.formatPointValue(this,e)},t.prototype.overlapsBox=function(e){return this.box.overlaps(e)},t.prototype.unclipElements=function(){this.fromPoint.unclipElements(),this.toPoint.unclipElements()},t.prototype.initLabelsFormat=function(){var e=this.options.labels;e.format||(e.from&&e.from.format||(e.from=Object.assign({},e.from,{format:"{0}"})),e.to&&e.to.format||(e.to=Object.assign({},e.to,{format:"{1}"})))},t.prototype.positionLabels=function(e,t){var n,i,r=this.options,o=r.labels,a=r.vertical;o.position===cU&&(a?t.y1<=e.y1?(i=dV,n=uV):(i=uV,n=dV):t.x1<=e.x1?(i=XH,n=aF):(i=aF,n=XH),o.from&&o.from.position||(this.fromPoint.options.labels.position=n),o.to&&o.to.position||(this.toPoint.options.labels.position=i))},t.prototype.copyFields=function(e){e.dataItem=this.dataItem,e.category=this.category,e.series=this.series,e.color=this.color,e.owner=this.owner},t.prototype.focusVisual=function(){this.fromPoint.focusVisual()},t.prototype.clearFocusFromVisual=function(){this.toPoint.clearFocusFromVisual()},t.prototype.getIndex=function(){return this.categoryIx},t}(qL);BF(dU.prototype,l$),BF(dU.prototype,c$),dU.prototype.defaults={markers:{visible:!1,background:mF,size:8,type:BH,border:{width:2},opacity:1},labels:{visible:!1,margin:WF(3),padding:WF(4),animation:{type:ZO,delay:XO},position:cU},notes:{label:{}},highlight:{markers:{border:{color:mF,width:2}},zIndex:100},tooltip:{format:"{0} - {1}"},accessibility:{role:xN,className:CN,ariaRoleDescription:SN}};var uU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createStrokeSegments=function(){return this.segmentsFromPoints(this.toGeometryPoints(this.toPoints()))},t.prototype.stackSegments=function(){var e=this.fromSegments;return this.fromSegments||(e=this.fromSegments=this.segmentsFromPoints(this.toGeometryPoints(this.fromPoints().reverse()))),e},t.prototype.createStroke=function(e){var t=new us(e),n=new us(e);t.segments.push.apply(t.segments,this.strokeSegments()),n.segments.push.apply(n.segments,this.stackSegments()),this.visual.append(t),this.visual.append(n)},t.prototype.hasStackSegment=function(){return!0},t.prototype.fromPoints=function(){return this.linePoints.map((function(e){return e.fromPoint}))},t.prototype.toPoints=function(){return this.linePoints.map((function(e){return e.toPoint}))},t}(y$),hU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createStrokeSegments=function(){return this.createCurveSegments(this.toPoints())},t.prototype.stackSegments=function(){var e=this.fromSegments;return this.fromSegments||(e=this.fromSegments=this.createCurveSegments(this.fromPoints().reverse())),e},t.prototype.createCurveSegments=function(e){return(new RO).process(this.toGeometryPoints(e))},t}(uU),pU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createStrokeSegments=function(){return this.segmentsFromPoints(this.calculateStepPoints(this.toPoints()))},t.prototype.stackSegments=function(){var e=this.fromSegments;return this.fromSegments||(e=this.fromSegments=this.segmentsFromPoints(this.calculateStepPoints(this.fromPoints()))).reverse(),e},t}(uU);BF(pU.prototype,h$);var fU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){e.prototype.render.call(this),this.renderSegments()},t.prototype.pointType=function(){return dU},t.prototype.createPoint=function(e,t){var n=t.series,i=t.seriesIx,r=e.valueFields;if(!e$(r.from)&&!e$(r.to)){if(this.seriesMissingValues(n)!==sV)return null;r={from:0,to:0}}var o=this.pointOptions(n,i);o=this.evalPointOptions(o,r,t);var a=e.fields.color||n.color;FF(n.color)&&(a=o.color);var s=new dU(r,o);return s.color=a,this.append(s),s},t.prototype.createSegment=function(e,t,n){var i=(t.line||{}).style;return new("smooth"===i?hU:"step"===i?pU:uU)(e,t,n)},t.prototype.plotRange=function(e,t){return e?[e.value.from,e.value.to]:[t,t]},t.prototype.valueSlot=function(e,t){var n=e.getSlot(t[0],t[0],!this.options.clip),i=e.getSlot(t[1],t[1],!this.options.clip);if(n&&i)return{from:n,to:i}},t.prototype.pointSlot=function(e,t){var n,i,r=t.from,o=t.to;return this.options.invertAxes?(n=new VL(r.x1,e.y1,r.x2,e.y2),i=new VL(o.x1,e.y1,o.x2,e.y2)):(n=new VL(e.x1,r.y1,e.x2,r.y2),i=new VL(e.x1,o.y1,e.x2,o.y2)),{from:n,to:i}},t.prototype.addValue=function(t,n){var i=t.valueFields;MF(i.from)||(i.from=i.to),MF(i.to)||(i.to=i.from),e.prototype.addValue.call(this,t,n)},t.prototype.updateRange=function(e,t){if(null!==e&&MF(e.from)&&MF(e.to)){var n=t.series.axis,i=this.valueAxisRanges[n]=this.valueAxisRanges[n]||{min:ZH,max:JH},r=e.from,o=e.to;i.min=Math.min(i.min,r,o),i.max=Math.max(i.max,r,o)}},t.prototype.formatPointValue=function(e,t){var n=e.value;return this.chartService.format.auto(t,n.from,n.to)},t.prototype.animationPoints=function(){for(var e=this.points,t=[],n=0;n<e.length;n++){var i=e[n];i&&(t.push((i.fromPoint||{}).marker),t.push((i.toPoint||{}).marker))}return t.concat(this._segments)},t}(s$);BF(fU.prototype,g$,_$);var mU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(e){var t=this,n=t.options,i=t.value,r=t.owner.seriesValueAxis(n),o=[],a=[],s=[],l=r.getSlot(i.low,i.high),c=r.getSlot(i.open,i.open),d=r.getSlot(i.close,i.close);c.x1=d.x1=l.x1=e.x1,c.x2=d.x2=l.x2=e.x2;var u=l.center().x;o.push([c.x1,c.y1]),o.push([u,c.y1]),a.push([u,d.y1]),a.push([d.x2,d.y1]),s.push([u,l.y1]),s.push([u,l.y2]),this.lines=[o,a,s],this.box=l.clone().wrap(c.clone().wrap(d)),this.reflowNote()},t.prototype.createBody=function(){},t}(P$),gU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.pointType=function(){return mU},t}(H$),vU=function(e){function t(t,n,i){e.call(this),this.from=t,this.to=n,this.series=i}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.linePoints=function(){var e=this.from,t=this.from.box,n=this.to.box,i=[];if(e.isVertical){var r=e.aboveAxis?t.y1:t.y2;i.push([t.x1,r],[n.x2,r])}else{var o=e.aboveAxis?t.x2:t.x1;i.push([o,t.y1],[o,n.y2])}return i},t.prototype.createVisual=function(){e.prototype.createVisual.call(this);var t=this.series.line||{},n=us.fromPoints(this.linePoints(),{stroke:{color:t.color,width:t.width,opacity:t.opacity,dashType:t.dashType}});DF(n),this.visual.append(n)},t}(qL);DR(vU,{animation:{type:ZO,delay:XO}});var _U=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){e.prototype.render.call(this),this.createSegments()},t.prototype.traverseDataPoints=function(e){for(var t=this.options.series,n=GN(t),i=!this.options.invertAxes,r=0;r<t.length;r++)for(var o=t[r],a=0,s=0,l=0;l<n;l++){var c=qO.current.bindPoint(o,l),d=c.valueFields.value,u=c.fields.summary,h=a,p=void 0;u?"total"===u.toLowerCase()?(c.valueFields.value=a,h=0,p=a):(c.valueFields.value=s,p=h-s,s=0):MF(d)&&(s+=d,p=a+=d),e(c,{category:this.categoryAxis.categoryAt(l),categoryIx:l,series:o,seriesIx:r,total:a,runningTotal:s,from:h,to:p,isVertical:i})}},t.prototype.updateRange=function(t,n){e.prototype.updateRange.call(this,{value:n.to},n)},t.prototype.aboveAxis=function(e){return e.value>=0},t.prototype.plotRange=function(e){return[e.from,e.to]},t.prototype.createSegments=function(){for(var e=this.options.series,t=this.seriesPoints,n=this.segments=[],i=0;i<e.length;i++){var r=e[i],o=t[i];if(o)for(var a=void 0,s=0;s<o.length;s++){var l=o[s];if(l&&a){var c=new vU(a,l,r);n.push(c),this.append(c)}a=l}}},t}(z$);function bU(e,t,n){var i=e[String(t)];return i?i(n):null}function yU(e,t){for(var n,i,r=0,o=0,a=0,s=0,l=0,c=Number.MAX_VALUE,d=Number.MIN_VALUE,u=0;u<e.length;u++){var h=t(e[u]),p=h.xValue,f=h.yValue;isFinite(p)&&null!==p&&isFinite(f)&&null!==f&&(c=Math.min(p,c),d=Math.max(p,d),l++,r+=p,o+=f,a+=Math.pow(p,2),s+=p*f)}return l>0&&(i=(o-(n=(l*s-r*o)/(l*a-Math.pow(r,2)))*r)/l),{slope:n,intercept:i,count:l,xMin:c,xMax:d}}var wU=function(e,t){return e.every((function(e){var n=e.valueFields;return!e$(n[t])||n[t]>0}))};function kU(e,t){for(var n=[],i=t.totalRangeIndices(),r=t.currentRangeIndices(),o={min:Math.floor(Math.max(r.min-1,i.min)),max:Math.ceil(Math.min(r.max+2,i.max))},a=o.min;a<o.max;a++){var s=a+1;n[a]={category:t.categoryAt(a,!0),value:e(s)}}return n}var xU=function(e){return function(t){var n=t.categoryIx,i=t.valueFields;return{xValue:n+1,yValue:Math.log(i[e])}}};var CU=function(e){return function(t){return{xValue:t.categoryIx+1,yValue:t.valueFields[e]}}};var SU=function(e){return function(t){var n=t.categoryIx,i=t.valueFields;return{xValue:Math.log(n+1),yValue:i[e]}}};function TU(e,t,n){for(var i=[],r=[],o=Math.max(2,n)-1,a=0,s=0,l=0;l<e.length;l++){var c=t(e[l]),d=c.xValue,u=c.yValue;if(isFinite(u)&&null!==u?(r.push(u),s+=u,a=Math.max(l,a)):r.push(null),l>=o){var h=r.filter((function(e){return null!==e})).length,p=r.shift()||0;if(h>0){var f=s/h;i.push([d,f]),s-=p;continue}}i.push([d,null])}return i.slice(0,a+1)}var DU=function(e){return function(t){return{xValue:t.categoryIx,yValue:t.valueFields[e]}}};function AU(e,t,n){for(var i=Math.min(Math.max(n||1,1),6)+1,r=new XR,o=new XR,a=0,s=Number.MAX_VALUE,l=Number.MIN_VALUE,c=function(e){return e},d=[],u=0;u<e.length;u++){var h=t(e[u]),p=h.xValue,f=h.yValue;if(isFinite(p)&&null!==p&&isFinite(f)&&null!==f){s=Math.min(p,s),l=Math.max(p,l),a++,o.set(u,0,f),r.set(u,0,1),r.set(u,1,p);for(var m=2;m<=i;m++)r.set(u,m,Math.pow(r.get(u,1),m))}else r.set(u,0,0)}return r.width=Math.min(i,a),a>0&&(d=function(e,t){for(var n=e.transpose(),i=n.multiply(e).inverse().multiply(n).multiply(t),r=[],o=0;o<i.height;o++)r.push(i.get(o,0));return r}(r,o),c=function(e){return d.reduce((function(t,n,i){return t+n*Math.pow(e,i)}),0)}),{coefficients:d,count:a,valueMapper:c,xMin:s,xMax:l}}var MU=function(e){return function(t){return{xValue:t.categoryIx+1,yValue:t.valueFields[e]}}};var EU=function(e){return function(t){var n=t.categoryIx,i=t.valueFields;return{xValue:Math.log(n+1),yValue:Math.log(i[e])}}};var IU={};IU[GV]=function(e){var t=e.options,n=e.categoryAxis,i=function(e){var t=e.seriesValues,n=e.categoryAxis,i=e.options,r=t();if(!wU(r,i.field))return null;var o=yU(r,xU(i.field)),a=o.slope,s=o.intercept,l=o.count;if(l>0){var c=Math.exp(s),d=a;return kU((function(e){return c*Math.exp(d*e)}),n)}return null}({seriesValues:e.seriesValues,categoryAxis:n,options:t});return i?Object.assign({},t,{type:"line",data:i,categoryField:"category",field:"value"}):null},IU[KV]=function(e){var t=e.options,n=e.categoryAxis,i=function(e){var t=e.seriesValues,n=e.categoryAxis,i=e.options,r=yU(t(),CU(i.field)),o=r.slope,a=r.intercept,s=r.count;if(s>0)return kU((function(e){return o*e+a}),n);return null}({seriesValues:e.seriesValues,categoryAxis:n,options:t});return i?Object.assign({},t,{type:"line",data:i,categoryField:"category",field:"value"}):null},IU[YV]=function(e){var t=e.options,n=e.categoryAxis,i=function(e){var t=e.seriesValues,n=e.categoryAxis,i=e.options,r=yU(t(),SU(i.field)),o=r.slope,a=r.intercept,s=r.count;if(s>0){var l=o,c=a;return kU((function(e){return l*Math.log(e)+c}),n)}return null}({seriesValues:e.seriesValues,categoryAxis:n,options:t});return i?Object.assign({},t,{type:"line",data:i,categoryField:"category",field:"value"}):null},IU[QV]=function(e){var t=e.options,n=function(e){var t=e.categoryAxis,n=function(e){var t=e.options,n=e.categoryAxis,i=e.seriesValues,r=(t.trendline||{}).period||2,o=n.totalRangeIndices(),a=n.currentRangeIndices(),s={min:Math.floor(Math.max(a.min-r,o.min)),max:Math.ceil(Math.min(a.max+r+2,o.max))};return TU(i(s),DU(t.field),r)}(e),i=[];if(n.forEach((function(e){var n=e[0],r=e[1];i[n]={category:t.categoryAt(n,!0),value:r}})),i.length>0)return i;return null}(e);return n?Object.assign({},t,{type:"line",data:n,categoryField:"category",field:"value"}):null},IU[XV]=function(e){var t=e.options,n=e.categoryAxis,i=function(e){var t=e.seriesValues,n=e.categoryAxis,i=e.options,r=(i.trendline||{}).order,o=AU(t(),MU(i.field),r),a=o.count,s=o.valueMapper;if(a>0)return kU((function(e){return s(e)}),n);return null}({seriesValues:e.seriesValues,categoryAxis:n,options:t});return i?Object.assign({},t,{type:"line",data:i,categoryField:"category",field:"value"}):null},IU[ZV]=function(e){var t=e.options,n=e.categoryAxis,i=function(e){var t=e.seriesValues,n=e.categoryAxis,i=e.options,r=t();if(!wU(r,i.field))return null;var o=yU(r,EU(i.field)),a=o.slope,s=o.intercept,l=o.count;if(l>0){var c=Math.exp(s),d=a;return kU((function(e){return c*Math.pow(e,d)}),n)}return null}({seriesValues:e.seriesValues,categoryAxis:n,options:t});return i?Object.assign({},t,{type:"line",data:i,categoryField:"category",field:"value"}):null};var zU=[fV,VV,FV,WV],PU=[TV,UV].concat(zU),HU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initFields=function(e){if(this.namedCategoryAxes={},this.namedValueAxes={},this.valueAxisRangeTracker=new C$,this._seriesPointsCache={},this._currentPointsCache={},e.length>0){this.invertAxes=tR(e[0].type,[mV,_V,UV,VV,WV,RV,SV,NV]);for(var t=0;t<e.length;t++){var n=e[t].stack;if(n&&"100%"===n.type){this.stack100=!0;break}}}},t.prototype.render=function(e){void 0===e&&(e=this.panes),this.series=[].concat(this.originalSeries),this.createCategoryAxes(e),this.aggregateCategories(e),this.createTrendlineSeries(e),this.createCategoryAxesLabels(e),this.createCharts(e),this.createValueAxes(e)},t.prototype.removeAxis=function(t){var n=t.options.name;e.prototype.removeAxis.call(this,t),t instanceof sO?delete this.namedCategoryAxes[n]:(this.valueAxisRangeTracker.reset(n),delete this.namedValueAxes[n]),t===this.categoryAxis&&delete this.categoryAxis,t===this.valueAxis&&delete this.valueAxis},t.prototype.trendlineFactory=function(e,t){var n=this.seriesCategoryAxis(e),i=this.seriesValues.bind(this,t.index),r=bU(IU,e.type,{options:e,categoryAxis:n,seriesValues:i});return r?(r.categoryAxis=t.categoryAxis,r.valueAxis=t.valueAxis,this.filterSeries(r,n)):r},t.prototype.trendlineAggregateForecast=function(){return this.series.map((function(e){return(e.trendline||{}).forecast})).filter((function(e){return void 0!==e})).reduce((function(e,t){return{before:Math.max(e.before,t.before||0),after:Math.max(e.after,t.after||0)}}),{before:0,after:0})},t.prototype.seriesValues=function(e,t){var n=[],i=this.srcSeries[e],r=this.seriesCategoryAxis(i);KN(r.options.type,VH)&&(this._seriesPointsCache={},this._currentPointsCache={},r.options.dataItems=[],i=this.aggregateSeries(i,r,r.totalRangeIndices()));for(var o=t?t.min:0,a=t?t.max:i.data.length,s=o;s<a;s++){var l=this.bindPoint(i,s);n.push({categoryIx:s,category:l.fields.category,valueFields:l.valueFields})}return n},t.prototype.createCharts=function(e){for(var t=this,n=this.groupSeriesByPane(),i=0;i<e.length;i++){var r=e[i],o=n[r.options.name||"default"]||[];t.addToLegend(o);var a=t.filterVisibleSeries(o);if(a)for(var s=t.groupSeriesByCategoryAxis(a),l=0;l<s.length;l++)t.createChartGroup(s[l],r)}},t.prototype.createChartGroup=function(e,t){this.createAreaChart(QN(e,[fV,VV]),t),this.createRangeAreaChart(QN(e,[FV,WV]),t),this.createBarChart(QN(e,[yV,mV]),t),this.createRangeBarChart(QN(e,[LV,RV]),t),this.createBulletChart(QN(e,[_V,$V]),t),this.createCandlestickChart(QN(e,bV),t),this.createBoxPlotChart(QN(e,[gV,NV]),t),this.createOHLCChart(QN(e,DV),t),this.createWaterfallChart(QN(e,[jV,SV]),t),this.createLineChart(QN(e,[TV,UV]),t)},t.prototype.aggregateCategories=function(e){var t=this,n=[].concat(this.series),i=[];this._currentPointsCache={},this._seriesPointsCache=this._seriesPointsCache||{};for(var r=0;r<n.length;r++){var o=n[r];if(!t.isTrendline(o)){var a=t.seriesCategoryAxis(o),s=t.findPane(a.options.pane);o=(KN(a.options.type,VH)||o.categoryField)&&tR(s,e)?t.aggregateSeries(o,a,a.currentRangeIndices()):t.filterSeries(o,a)}i.push(o)}this._seriesPointsCache=this._currentPointsCache,this._currentPointsCache=null,this.srcSeries=n,this.series=i},t.prototype.filterSeries=function(e,t){var n=(e.data||{}).length;if(t._seriesMax=Math.max(t._seriesMax||0,n),!hR(t.options.min)&&!hR(t.options.max))return e;var i=t.currentRangeIndices(),r=tR(e.type,PU),o=BF({},e);return o.data=(o.data||[]).slice(i.min,i.max+1),r&&a$(o,i,n,(function(n){return{item:e.data[n],category:t.categoryAt(n,!0),categoryIx:n-i.min}}),(function(t){return hR(e.data[t])})),o},t.prototype.clearSeriesPointsCache=function(){this._seriesPointsCache={}},t.prototype.seriesSourcePoints=function(e,t){var n=e.index+";"+t.categoriesHash();if(this._seriesPointsCache&&this._seriesPointsCache[n])return this._currentPointsCache[n]=this._seriesPointsCache[n],this._seriesPointsCache[n];var i=t.options,r=i.srcCategories,o=KN(i.type,VH),a=e.data,s=[];o||t.indexCategories();for(var l=0;l<a.length;l++){var c=qO.current.bindPoint(e,l).fields.category;if(o&&(c=ZN(c,a[l],this.chartService.intl)),hR(c)||(c=r[l]),hR(c)&&null!==c){var d=t.totalIndex(c);s[d]=s[d]||{items:[],category:c},s[d].items.push(l)}}return this._currentPointsCache[n]=s,s},t.prototype.aggregateSeries=function(e,t,n){if(!e.data.length)return e;for(var i=this.seriesSourcePoints(e,t),r=BF({},e),o=new iU(BF({},e),qO.current,oU.current),a=r.data=[],s=t.options.dataItems||[],l=function(e){var r=e-n.min,a=i[e];if(a||(a=i[e]={}),a.categoryIx=r,!a.item){var s=t.categoryAt(e,!0);a.category=s,a.item=o.aggregatePoints(a.items,s)}return a},c=n.min;c<=n.max;c++){var d=l(c);a[d.categoryIx]=d.item,d.items&&d.items.length&&(s[d.categoryIx]=d.item)}return tR(r.type,PU)&&a$(r,n,t.totalCount(),l,(function(e){return i[e]})),t.options.dataItems=s,r},t.prototype.appendChart=function(t,n){var i=t.options.series,r=this.seriesCategoryAxis(i[0]),o=r.options.categories,a=Math.max(0,GN(i)-o.length);if(a>0)for(o=r.options.categories=r.options.categories.slice(0);a--;)o.push("");this.valueAxisRangeTracker.update(t.valueAxisRanges),e.prototype.appendChart.call(this,t,n)},t.prototype.seriesPaneName=function(e){var t=this.options,n=e.axis,i=ZF([].concat(t.valueAxis),(function(e){return e.name===n}))[0],r=((t.panes||[{}])[0]||{}).name||"default";return(i||{}).pane||r},t.prototype.seriesCategoryAxis=function(e){var t=e.categoryAxis,n=t?this.namedCategoryAxes[t]:this.categoryAxis;if(!n)throw new Error("Unable to locate category axis with name "+t);return n},t.prototype.stackableChartOptions=function(e,t){var n=e.some((function(e){return e.stack})),i=e.some((function(e){return e.stack&&"100%"===e.stack.type})),r=t.options.clip;return{defaultStack:e[0].stack,isStacked:n,isStacked100:i,clip:r}},t.prototype.groupSeriesByCategoryAxis=function(e){for(var t=[],n={},i=0;i<e.length;i++){var r=e[i].categoryAxis||"$$default$$";QR(n,r)||(n[r]=!0,t.push(r))}for(var o=[],a=0;a<t.length;a++){var s=RU(e,t[a],a);0!==s.length&&o.push(s)}return o},t.prototype.createBarChart=function(e,t){if(0!==e.length){var n=e[0],i=new z$(this,Object.assign({series:e,invertAxes:this.invertAxes,gap:n.gap,spacing:n.spacing},this.stackableChartOptions(e,t)));this.appendChart(i,t)}},t.prototype.createRangeBarChart=function(e,t){if(0!==e.length){var n=e[0],i=new sU(this,{series:e,invertAxes:this.invertAxes,gap:n.gap,spacing:n.spacing});this.appendChart(i,t)}},t.prototype.createBulletChart=function(e,t){if(0!==e.length){var n=e[0],i=new W$(this,{series:e,invertAxes:this.invertAxes,gap:n.gap,spacing:n.spacing,clip:t.options.clip});this.appendChart(i,t)}},t.prototype.createLineChart=function(e,t){if(0!==e.length){var n=new b$(this,Object.assign({invertAxes:this.invertAxes,series:e},this.stackableChartOptions(e,t)));this.appendChart(n,t)}},t.prototype.createAreaChart=function(e,t){if(0!==e.length){var n=new x$(this,Object.assign({invertAxes:this.invertAxes,series:e},this.stackableChartOptions(e,t)));this.appendChart(n,t)}},t.prototype.createRangeAreaChart=function(e,t){if(0!==e.length){var n=new fU(this,{invertAxes:this.invertAxes,series:e,clip:t.options.clip});this.appendChart(n,t)}},t.prototype.createOHLCChart=function(e,t){if(0!==e.length){var n=e[0],i=new gU(this,{invertAxes:this.invertAxes,gap:n.gap,series:e,spacing:n.spacing,clip:t.options.clip});this.appendChart(i,t)}},t.prototype.createCandlestickChart=function(e,t){if(0!==e.length){var n=e[0],i=new H$(this,{invertAxes:this.invertAxes,gap:n.gap,series:e,spacing:n.spacing,clip:t.options.clip});this.appendChart(i,t)}},t.prototype.createBoxPlotChart=function(e,t){if(0!==e.length){var n=e[0],i=new L$(this,{invertAxes:this.invertAxes,gap:n.gap,series:e,spacing:n.spacing,clip:t.options.clip});this.appendChart(i,t)}},t.prototype.createWaterfallChart=function(e,t){if(0!==e.length){var n=e[0],i=new _U(this,{series:e,invertAxes:this.invertAxes,gap:n.gap,spacing:n.spacing});this.appendChart(i,t)}},t.prototype.axisRequiresRounding=function(e,t){for(var n=QN(this.series,qV),i=0;i<this.series.length;i++){var r=this.series[i];if(tR(r.type,zU)){var o=r.line;o&&o.style===pV&&n.push(r)}}for(var a=0;a<n.length;a++){var s=n[a].categoryAxis||"";if(s===e||!s&&0===t)return!0}},t.prototype.aggregatedAxis=function(e,t){for(var n=this.series,i=0;i<n.length;i++){var r=n[i].categoryAxis||"";if((r===e||!r&&0===t)&&n[i].categoryField)return!0}},t.prototype.createCategoryAxesLabels=function(){for(var e=this.axes,t=0;t<e.length;t++)e[t]instanceof sO&&e[t].createLabels()},t.prototype.createCategoryAxes=function(e){for(var t=this,n=this.invertAxes,i=[].concat(this.options.categoryAxis),r=[],o=0;o<i.length;o++){var a=i[o];if(tR(t.findPane(a.pane),e)){var s=a.name,l=a.categories;void 0===l&&(l=[]),a=BF({vertical:n,reverse:!n&&t.chartService.rtl,axisCrossingValue:n?ZH:0},a),hR(a.justified)||(a.justified=t.isJustified()),t.axisRequiresRounding(s,o)&&(a.justified=!1);var c=void 0;if(t$(a,l[0])?(a._forecast=t.trendlineAggregateForecast(),c=new vO(a,t.chartService)):c=new sO(a,t.chartService),i[o].categories=c.options.srcCategories,s){if(t.namedCategoryAxes[s])throw new Error("Category axis with name "+s+" is already defined");t.namedCategoryAxes[s]=c}c.axisIndex=o,r.push(c),t.appendAxis(c)}}var d=this.categoryAxis||r[0];this.categoryAxis=d,n?this.axisY=d:this.axisX=d},t.prototype.isJustified=function(){for(var e=this.series,t=0;t<e.length;t++){if(!tR(e[t].type,zU))return!1}return!0},t.prototype.createValueAxes=function(e){var t=this,n=this.valueAxisRangeTracker,i=n.query(),r=[].concat(this.options.valueAxis),o=this.invertAxes,a={vertical:!o,reverse:o&&this.chartService.rtl},s=[];this.stack100&&(a.roundToMajorUnit=!1,a.labels={format:"P0"});for(var l=0;l<r.length;l++){var c=r[l];if(tR(t.findPane(c.pane),e)){var d=c.name,u=KN(c.type,MN)?{min:.1,max:1}:{min:0,max:1},h=n.query(d)||i||u;0===l&&h&&i&&(h.min=Math.min(h.min,i.min),h.max=Math.max(h.max,i.max));var p=new(KN(c.type,MN)?TO:kO)(h.min,h.max,BF({},a,c),t.chartService);if(d){if(t.namedValueAxes[d])throw new Error("Value axis with name "+d+" is already defined");t.namedValueAxes[d]=p}p.axisIndex=l,s.push(p),t.appendAxis(p)}}var f=this.valueAxis||s[0];this.valueAxis=f,o?this.axisX=f:this.axisY=f},t.prototype._dispatchEvent=function(e,t,n){var i=e._eventCoordinates(t),r=new OL(i.x,i.y),o=this.pointPane(r),a=[],s=[];if(o){for(var l=o.axes,c=0;c<l.length;c++){var d=l[c];d.getValue?UN(s,d.getValue(r)):UN(a,d.getCategory(r))}0===a.length&&UN(a,this.categoryAxis.getCategory(r)),a.length>0&&s.length>0&&e.trigger(n,{element:vR(t),originalEvent:t,category:n$(a),value:n$(s)})}},t.prototype.pointPane=function(e){for(var t=this.panes,n=0;n<t.length;n++){var i=t[n];if(i.contentBox.containsPoint(e))return i}},t.prototype.updateAxisOptions=function(e,t){FU(this.options,e,t),FU(this.originalOptions,e,t)},t.prototype._pointsByVertical=function(e,t){return void 0===t&&(t=0),this.invertAxes?this._siblingsBySeriesIndex(e.series.index,t):this._siblingsByPointIndex(e.getIndex())},t.prototype._pointsByHorizontal=function(e,t){if(void 0===t&&(t=0),this.invertAxes)return this._siblingsByPointIndex(e.getIndex());var n=this._siblingsBySeriesIndex(e.series.index,t);return this.chartService.rtl?n.reverse():n},t.prototype._siblingsByPointIndex=function(e){for(var t=this.charts,n=[],i=0;i<t.length;i++){var r=t[i];if(!r.pane||"_navigator"!==r.pane.options.name){var o=r.points.filter((function(t){return t&&!1!==t.visible&&t.getIndex()===e}));n.push.apply(n,o.sort(this._getSeriesCompareFn(o[0])))}}return n},t.prototype._siblingsBySeriesIndex=function(e,t){var n=HF(e+t,this.series.length);return this.pointsBySeriesIndex(n)},t.prototype._getSeriesCompareFn=function(e){var t=this._isInStackedSeries(e);return t&&this.invertAxes||!t&&!this.invertAxes?function(e,t){return e.box.center().x-t.box.center().x}:function(e,t){return e.box.center().y-t.box.center().y}},t.prototype._isInStackedSeries=function(e){var t=tR(e.series.type,[fV,VV,FV,WV,TV,UV,HV,zV]),n=tR(e.series.type,[yV,mV]);return t||n&&e.options.isStacked},t}(X$);function FU(e,t,n){BF([].concat(t instanceof sO?e.categoryAxis:e.valueAxis)[t.axisIndex],n)}function RU(e,t,n){return ZF(e,(function(e){return 0===n&&!e.categoryAxis||e.categoryAxis===t}))}DR(HU,{categoryAxis:{},valueAxis:{}}),BF(HU.prototype,nU);var LU=function(e){function t(){e.call(this),this._points=[]}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this._points=[]},t.prototype.show=function(e,t){var n=[].concat(e);this.hide();for(var i=0;i<n.length;i++){var r=n[i];r&&r.toggleHighlight&&r.hasHighlight()&&(this.togglePointHighlight(r,!0,t),this._points.push(r))}},t.prototype.togglePointHighlight=function(e,t,n){var i=(e.options.highlight||{}).toggle;if(i){var r={category:e.category,series:e.series,dataItem:e.dataItem,value:e.value,stackValue:e.stackValue,preventDefault:BU,visual:e.highlightVisual(),show:t};i(r),r._defaultPrevented||e.toggleHighlight(t,n)}else e.toggleHighlight(t,n)},t.prototype.hide=function(){for(var e=this._points;e.length;)this.togglePointHighlight(e.pop(),!1)},t.prototype.isHighlighted=function(e){for(var t=this._points,n=0;n<t.length;n++){if(e===t[n])return!0}return!1},t}(fr);function BU(){this._defaultPrevented=!0}function OU(e,t){var n=(t||"").toLowerCase(),i=e.event;return"none"===n&&!(i.ctrlKey||i.shiftKey||i.altKey)||i[n+"Key"]}function VU(e){for(var t={},n=0;n<e.length;n++){var i=e[n];i.axis.options.name&&(t[i.axis.options.name]={min:i.range.min,max:i.range.max})}return t}var NU=function(e){function t(t,n){e.call(this),this.plotArea=t,this.options=BF({},this.options,n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.start=function(e){return this._active=OU(e,this.options.key),this._active},t.prototype.move=function(e){if(this._active){var t=this.axisRanges=this._panAxes(e,vF).concat(this._panAxes(e,_F));if(t.length)return this.axisRanges=t,VU(t)}},t.prototype.end=function(){var e=this._active;return this._active=!1,e},t.prototype.pan=function(){var e=this.plotArea,t=this.axisRanges;if(t.length){for(var n=0;n<t.length;n++){var i=t[n];e.updateAxisOptions(i.axis,i.range)}e.redraw(e.panes)}},t.prototype.destroy=function(){delete this.plotArea},t.prototype._panAxes=function(e,t){var n=this.plotArea,i=-e[t].delta,r=(this.options.lock||"").toLowerCase(),o=[];if(0!==i&&(r||"").toLowerCase()!==t)for(var a=n.axes,s=0;s<a.length;s++){var l=a[s];if(t===vF&&!l.options.vertical||t===_F&&l.options.vertical){var c=l.pan(i);c&&(c.limitRange=!0,o.push({axis:l,range:c}))}}return o},t}(fr);NU.prototype.options={key:"none",lock:"none"};var $U=function(e){function t(t,n){e.call(this),this.chart=t,this.options=BF({},this.options,n),this.createElement()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createElement=function(){var e=this._marquee=document.createElement("div");e.className="k-marquee";var t=document.createElement("div");t.className="k-marquee-color",e.appendChild(t)},t.prototype.removeElement=function(){this._marquee.parentNode&&this._marquee.parentNode.removeChild(this._marquee)},t.prototype.setStyles=function(e){UF(this._marquee,e)},t.prototype.start=function(e){if(OU(e,this.options.key)){var t=this.chart,n=t._eventCoordinates(e),i=this._zoomPane=t._plotArea.paneByPoint(n),r=i?i.chartsBox().clone():null;if(i&&r){var o=this._elementOffset();return r.translate(o.left,o.top),this._zoomPaneClipBox=r,document.body.appendChild(this._marquee),this.setStyles({left:e.pageX+1,top:e.pageY+1,width:0,height:0}),!0}}return!1},t.prototype._elementOffset=function(){var e=this.chart.element,t=UF(e,["paddingLeft","paddingTop"]),n=t.paddingLeft,i=t.paddingTop,r=fR(e);return{left:n+r.left,top:i+r.top}},t.prototype.move=function(e){this._zoomPane&&this.setStyles(this._selectionPosition(e))},t.prototype.end=function(e){if(this._zoomPane){var t=this._elementOffset(),n=this._selectionPosition(e);n.left-=t.left,n.top-=t.top;var i={x:n.left,y:n.top},r={x:n.left+n.width,y:n.top+n.height};return this._updateAxisRanges(i,r),this.removeElement(),delete this._zoomPane,VU(this.axisRanges)}},t.prototype.zoom=function(){var e=this.axisRanges;if(e&&e.length){for(var t=this.chart._plotArea,n=0;n<e.length;n++){var i=e[n];t.updateAxisOptions(i.axis,i.range)}t.redraw(t.panes)}},t.prototype.destroy=function(){this.removeElement(),delete this._marquee,delete this.chart},t.prototype._updateAxisRanges=function(e,t){for(var n=(this.options.lock||"").toLowerCase(),i=[],r=this._zoomPane.axes,o=0;o<r.length;o++){var a=r[o],s=a.options.vertical;if((n!==vF||s)&&(n!==_F||!s)&&hR(a.axisIndex)){var l=a.pointsRange(e,t);l&&i.push({axis:a,range:l})}}this.axisRanges=i},t.prototype._selectionPosition=function(e){var t=this._zoomPaneClipBox,n={x:e.x.startLocation,y:e.y.startLocation},i=e.x.location,r=e.y.location,o=(this.options.lock||"").toLowerCase(),a=Math.min(n.x,i),s=Math.min(n.y,r),l=Math.abs(n.x-i),c=Math.abs(n.y-r);return o===vF&&(a=t.x1,l=t.width()),o===_F&&(s=t.y1,c=t.height()),i>t.x2&&(l=t.x2-n.x),i<t.x1&&(l=n.x-t.x1),r>t.y2&&(c=t.y2-n.y),r<t.y1&&(c=n.y-t.y1),{left:Math.max(a,t.x1),top:Math.max(s,t.y1),width:l,height:c}},t}(fr);$U.prototype.options={key:"shift",lock:"none"};var UU=function(e){function t(t,n){e.call(this),this.chart=t,this.options=BF({rate:.3},this.options,n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.updateRanges=function(e,t){for(var n=(this.options.lock||"").toLowerCase(),i=[],r=this.chart._plotArea.axes,o=0;o<r.length;o++){var a=r[o],s=a.options.vertical;if((n!==vF||s)&&(n!==_F||!s)&&a.zoomRange){var l=yR(this.options.rate,.01,.9),c=a.zoomRange(-e*l,t);c&&i.push({axis:a,range:c})}}return this.axisRanges=i,VU(i)},t.prototype.zoom=function(){var e=this.axisRanges,t=this.chart._plotArea;if(e&&e.length&&t.updateAxisOptions){for(var n=0;n<e.length;n++){var i=e[n];t.updateAxisOptions(i.axis,i.range)}t.redraw(t.panes)}},t.prototype.destroy=function(){delete this.chart},t}(fr),WU=function(e){function t(t,n){e.call(this,t),this.chartService=n}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){var e,t=this.children,n=this.options,i=n.vertical;this.visual=new Cs(null,{spacing:i?0:n.spacing,lineSpacing:i?n.spacing:0,orientation:i?wF:yF,reverse:n.rtl,alignItems:i?(e=n.rtl,e?WH:lF):LH});for(var r=0;r<t.length;r++){var o=t[r];o.reflow(new VL),o.renderVisual()}},t.prototype.reflow=function(e){this.visual.rect(e.toRect()),this.visual.reflow();var t=this.visual.clippedBBox();this.box=t?oB(t):new VL},t.prototype.renderVisual=function(){this.addVisual()},t.prototype.createVisual=function(){},t}(qL),jU=10,qU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.visualStyle=function(){var e=this.markerOptions(),t=e.border;return{stroke:{width:t.width,color:t.color,opacity:SR(t.opacity,e.opacity),dashType:t.dashType},fill:{color:e.background,opacity:e.opacity},cursor:e.cursor}},t.prototype.markerOptions=function(){return this.options},t.prototype.markerHighlightOptions=function(){var e=this.markerOptions(),t=e.highlight.border.width;return BF({},e,{background:e.border.color},e.highlight,e.type===OH?{background:e.highlight.border.color,border:{color:e.highlight.background,width:t/2},width:e.width,height:e.height,margin:{top:0,left:0}}:{})},t.prototype.createHighlight=function(){var t=new e(this.markerHighlightOptions()),n=this.paddingBox.clone();return t.reflow(n.pad(t.options.border.width)),this.highlight=[t.getElement()],this.highlight},t}(XL);DR(qU,{border:{width:2},width:8,height:8,background:mF,margin:{top:-1,left:-1},vAlign:dF,align:XH,highlight:{width:jU,height:jU,border:{color:mF,width:2}}});var GU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getElement=function(){var e=new vs,t=new hs(this.visualStyle()),n=this.paddingBox,i=n.height()/2;return t.moveTo(n.x1,n.y1+i).lineTo(n.x1,n.y2).lineTo(n.x2,n.y2),e.append(t),e},t}(XL);DR(GU,{width:15,height:15,align:aF,vAlign:RH,margin:{right:-2,bottom:2}});var KU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getElement=function(){var e=new vs,t=new hs({stroke:{color:this.options.border.color,opacity:this.options.opacity,width:this.options.height,dashType:this.options.dashType}}),n=this.paddingBox,i=n.center().y;return t.moveTo(n.x1,i).lineTo(n.x2,i),e.append(t),e},t.prototype.createHighlight=function(){return this.highlight=[this.createHighlightLine(),this.createHighlightMarker()],this.highlight},t.prototype.createHighlightLine=function(){var e=BF({},{border:{color:this.options.border.color,opacity:this.options.border.opacity,dashType:this.options.border.dashType}},this.options.highlight),t=new GU(e);return t.reflow(this.parent.paddingBox.clone()),this.highlightLine=t.getElement(),this.highlightLine},t.prototype.createHighlightMarker=function(){var t=BF({},{background:this.options.background},this.options.highlight.markers),n=new e(t),i=this.parent.paddingBox,r=t.border.width,o=this.parent.box.clone();return o.pad({left:r-i.x1,top:r-i.y1}),n.reflow(o),this.highlightMarker=n.getElement(),this.highlightMarker},t}(XL);DR(KU,{border:{width:0},type:pF,align:XH,vAlign:LH,highlight:{border:{width:2},markers:{type:BH,width:jU,height:jU,border:{width:2,color:mF},align:XH,vAlign:dF}}});var YU=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createHighlight=function(){var t=BF({},{background:this.options.background},this.options.highlight.markers),n=new e(t),i=this.paddingBox.clone(),r=this.parent.box.clone();return i.align(r,vF,XH),i.align(r,_F,dF),n.reflow(i),this.highlight=[n.getElement()],this.highlight},t}(XL);DR(YU,{highlight:{markers:{type:BH,width:jU,height:jU,border:{width:2,color:mF},margin:{top:-3,left:-3}}}});var QU=function(e){function t(t){e.call(this,t),this.createContainer(),t.rtl?(this.createLabel(),this.createMarker()):(this.createMarker(),this.createLabel()),this._id=tL(),this.options.accessibility.ariaChecked=t.active}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createContainer=function(){this.container=new nB({vertical:!1,wrap:!1,align:LH,spacing:this.options.spacing}),this.append(this.container)},t.prototype.createMarker=function(){this.markerWrap=new e({vertical:!1,shrinkToFit:!0,wrap:!1,margin:1,width:22,height:22}),this.container.append(this.markerWrap),this.createMarkerArea(),this.options.markers.visible&&(this._marker=this._createMarker(),this.markerWrap.append(this._marker))},t.prototype.createMarkerArea=function(){var e=this.options,t=e.markerColor,n=e.line;void 0===n&&(n={});var i={border:{color:n.color||t,opacity:n.opacity,dashType:n.dashType}};return this._createLine(i)||this._createMarkerLine(i,n)||this._createSquare()},t.prototype.markerOptions=function(){var e=this.options,t=e.markers;void 0===t&&(t={});var n=e.markerColor,i=t.border;return void 0===i&&(i={}),t.zIndex=void 0,BF({},t,{border:{color:i.color||n},highlight:e.highlight.markers})},t.prototype._highlightOptions=function(){var e=this.options;return BF({markers:{type:e.markers.type}},e.highlight)},t.prototype._createLine=function(e){var t=this.options;return t.type!==TV||t.markers.visible||(this._line=new KU(BF({},{background:t.markerColor,highlight:this._highlightOptions()},e,t.line)),this.markerWrap.append(this._line)),this._line},t.prototype._createMarkerLine=function(e,t){return this.options.type===TV&&(this._markerLineArea=new GU(BF({},{border:{width:t.height}},e)),this.markerWrap.append(this._markerLineArea)),this._markerLineArea},t.prototype._reduceSize=function(e,t,n){void 0===n&&(n=.6),"number"==typeof e[t]&&(e[t]=e[t]*n)},t.prototype._createSquare=function(){var e=this.options;if(e.type===fV){var t=e.pattern||(e.series||{}).pattern;t&&("function"==typeof t&&(t=t(e.series)),t=structuredClone(t),this._reduceSize(t,"gap"),this._reduceSize(t,"width"),this._reduceSize(t,"radius")),this._square=new YU(Object.assign({},{border:e.border,vAlign:e.markers.visible?RH:LH,highlight:this._highlightOptions()},e.area,{pattern:t,background:e.area.background||e.markerColor})),this.markerWrap.append(this._square)}return this._square},t.prototype._createMarker=function(){return new qU(this.markerOptions())},t.prototype._highlightMarkers=function(){this.options.active&&this._toggleHighlight(!0)},t.prototype._restoreMarkers=function(){this._toggleHighlight(!1)},t.prototype._toggleHighlight=function(e){var t=this;if(this.options.highlight.visible){var n=this._marker||this._square||this._line;if(n&&n===this._line&&this._line.visual.visible(!e),n){var i=n.highlight;i||(i=n.createHighlight()).forEach((function(e){return e&&t.markerWrap.appendVisual(e)})),i.forEach((function(t){return t&&t.visible(e)}))}}},t.prototype.createLabel=function(){var e=this.options,t=BF({},e.labels);this.container.append(new sB(e.text,t))},t.prototype.getAriaLabelText=function(){return this.options.text},t.prototype.focusVisual=function(){this.visual.options.set("id",this._id),this.toggleFocusHighlight(!0),this._highlightMarkers()},t.prototype.clearFocusFromVisual=function(){this.visual.options.set("id",""),this.toggleFocusHighlight(!1),this._restoreMarkers()},t.prototype.renderComplete=function(){e.prototype.renderComplete.call(this);var t=this.options.cursor||{},n=this._itemOverlay=us.fromRect(this.container.box.toRect(),{fill:{color:mF,opacity:0},stroke:null,cursor:t.style||t});this.appendVisual(n)},t.prototype.click=function(e,t){var n=this.eventArgs(t);!e.trigger(eN,n)&&t&&"contextmenu"===t.type&&t.preventDefault()},t.prototype.over=function(e,t){var n=this.eventArgs(t);return e.trigger(tN,n)||(e._legendItemHover(n.seriesIndex,n.pointIndex),this._highlightMarkers()),!0},t.prototype.out=function(e,t){e._unsetActivePoint(),this._restoreMarkers(),e.trigger(nN,this.eventArgs(t))},t.prototype.eventArgs=function(e){var t=this.options;return{element:vR(e),text:t.text,series:t.series,seriesIndex:t.series.index,pointIndex:t.pointIndex}},t.prototype.createVisual=function(){e.prototype.createVisual.call(this);var t=this.options;if(this.options.visible){var n=BF({ariaLabel:void 0!==t.accessibility.ariaLabel?t.accessibility.ariaLabel:t.text},t.accessibility);QL(this.visual,n)}},t.prototype.renderVisual=function(){var t=this,n=this.options,i=n.visual;i?(this.visual=i({active:n.active,series:n.series,sender:this.getSender(),pointIndex:n.pointIndex,options:{type:n.type,markers:BF({background:this.options.markerColor},this.markerOptions()),labels:n.labels},createVisual:function(){t.createVisual(),t.renderChildren(),t.renderComplete();var e=t.visual;return delete t.visual,e}}),this._marker=this._markerLineArea=this._square=this._line=null,this.addVisual()):e.prototype.renderVisual.call(this)},t.prototype.createFocusHighlight=function(e){var t=e.stroke.width;return us.fromRect(this.container.box.pad(t/2).toRect(),e)},t}(YL);DR(QU,{accessibility:{role:TN,className:DN,ariaRoleDescription:AN},markers:{},highlight:{visible:!0,markers:{}}});var XU="custom",ZU=function(e){function t(t,n){void 0===n&&(n={}),e.call(this,t),this.chartService=n,tR(this.options.position,[dF,aF,RH,XH,XU])||(this.options.position=aF),this.createContainers(),this.createLegendTitle(t.title),this.createItems()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createContainers=function(){var e=this.options,t=e.position,n=e.align,i=t,r=LH;t===XU?i=XH:tR(t,[dF,RH])?(i=n===lF?XH:n===WH?aF:LH,r=t):n&&(n===lF?r=dF:n===WH&&(r=RH)),this.container=new YL({margin:e.margin,padding:e.padding,background:e.background,border:e.border,vAlign:r,align:i,zIndex:e.zIndex,shrinkToFit:!0}),this.hasTitle()?this.itemsContainer=new YL({vAlign:r,align:i,zIndex:e.zIndex,shrinkToFit:!0}):this.itemsContainer=this.container,this.append(this.container)},t.prototype.createItems=function(){var e=this.getService(),t=this.options,n=this.isVertical(),i=new WU({vertical:n,spacing:t.spacing,rtl:e.rtl},e),r=t.data;t.reverse&&(r=r.slice(0).reverse());for(var o=r.length,a=0;a<o;a++){var s=r[a],l=s.series||{},c=l.markers;void 0===c&&(c={});var d=l.dashType,u=l.legendItem,h=l.opacity,p=BF({visible:!1!==c.visible,type:BH},c);delete p.size;var f=BF({},{markers:p,labels:t.labels,rtl:e.rtl,line:Object.assign({},{dashType:d},t.line),area:Object.assign({},{opacity:h},t.area),opacity:h,accessibility:t.accessibility},t.item,u,s,{markers:t.markers});i.append(new QU(f))}i.render(),this.itemsContainer.append(i)},t.prototype.isVertical=function(){var e=this.options,t=e.orientation,n=e.position;return n===XU&&t!==yF||(hR(t)?t!==yF:tR(n,[XH,aF]))},t.prototype.hasItems=function(){return this.container.children[0].children.length>0},t.prototype.getItems=function(){return this.itemsContainer.children[0].children},t.prototype.reflow=function(e){var t=this.options,n=e.clone();this.hasItems()?(t.position===XU?(this.containerCustomReflow(n),this.box=n):this.containerReflow(n),this.hasTitle()&&this.title.reflow(new VL(this.container.box.x1,this.title.box.y1,this.container.box.x2,this.title.box.y2))):this.box=n},t.prototype.containerReflow=function(e){var t=this.options,n=this.container,i=t.position,r=t.width,o=t.height,a=i===dF||i===RH?vF:_F,s=this.isVertical(),l=e.clone(),c=e.clone();i!==XH&&i!==aF||(c.y1=l.y1=0),s&&o?(c.y2=c.y1+o,c.align(l,_F,n.options.vAlign)):!s&&r&&(c.x2=c.x1+r,c.align(l,vF,n.options.align)),n.reflow(c);var d=(c=n.box).clone();(t.offsetX||t.offsetY)&&(c.translate(t.offsetX,t.offsetY),n.reflow(c)),d[a+1]=e[a+1],d[a+2]=e[a+2],this.box=d},t.prototype.containerCustomReflow=function(e){var t=this.options,n=this.container,i=t.offsetX,r=t.offsetY,o=t.width,a=t.height,s=this.isVertical(),l=e.clone();s&&a?l.y2=l.y1+a:!s&&o&&(l.x2=l.x1+o),n.reflow(l),l=n.box,n.reflow(new VL(i,r,i+l.width(),r+l.height()))},t.prototype.renderVisual=function(){this.hasItems()&&e.prototype.renderVisual.call(this)},t.prototype.createLegendTitle=function(e){var t=BF({},{color:FH,position:dF,align:LH},e),n=t.text;if(e&&!1!==e.visible&&e.text){if(hR(t)&&t.visible){var i=GF(t);i?n=i({text:n}):t.format&&(n=this.chartService.format.auto(t.format,n))}this.title=new sB(n,t),this.createTitleLayout(),this.appendTitleLayoutContent()}},t.prototype.createTitleLayout=function(){this.layout=new nB({vertical:!0,wrap:!1}),this.container.append(this.layout)},t.prototype.hasTitle=function(){return Boolean(this.options.title&&!1!==this.options.title.visible&&this.options.title.text)},t.prototype.appendTitleLayoutContent=function(){this.options.title.position===RH?(this.layout.append(this.itemsContainer),this.layout.append(this.title)):(this.layout.append(this.title),this.layout.append(this.itemsContainer))},t}(qL);DR(ZU,{position:aF,data:[],offsetX:0,offsetY:0,margin:WF(2),padding:WF(5),border:{color:FH,width:0},item:{cursor:bF,spacing:6},spacing:6,background:"",zIndex:1,markers:{},line:{width:20,height:2,cursor:bF,opacity:1},area:{type:hF,align:aF,width:15,height:15}});var JU=function(e){function t(){e.call(this),this._registry=[]}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.register=function(e,t){this._registry.push({type:e,seriesTypes:t})},t.prototype.create=function(e,t,n){for(var i,r=this._registry,o=r[0],a=0;a<r.length;a++){var s=r[a];i=QN(e,s.seriesTypes);var l=QN(e,JV);if(i.length-l.length>0){o=s;break}}return new o.type(i,t,n)},t}(fr);JU.current=new JU;function eW(e){var t=document.createElement("div");return e&&(t.className=e),t}function tW(e){for(var t=e;t&&!JF(t,"k-handle");)t=t.parentNode;return t}var nW=function(e){function t(t,n,i,r){e.call(this);var o=t.element;this.options=BF({},this.options,i),this.chart=t,this.observer=r,this.chartElement=o,this.categoryAxis=n,this._dateAxis=this.categoryAxis instanceof vO,this.initOptions(),this.visible=this.options.visible&&o.offsetHeight,this.visible&&(this.createElements(),this.set(this._index(this.options.from),this._index(this.options.to)),this.bindEvents())}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.onPane=function(e){return this.categoryAxis.pane===e},t.prototype.createElements=function(){var e=this.options,t=this.wrapper=eW("k-selector k-pointer-events-none");UF(t,{top:e.offset.top,left:e.offset.left,width:e.width,height:e.height,direction:"ltr"});var n=this.selection=eW("k-selection k-pointer-events-none");this.leftMask=eW("k-mask k-pointer-events-none"),this.rightMask=eW("k-mask k-pointer-events-none"),t.appendChild(this.leftMask),t.appendChild(this.rightMask),t.appendChild(n);var i=this.body=eW("k-selection-bg k-pointer-events-none");n.appendChild(i);var r=this.leftHandle=eW("k-handle k-left-handle k-pointer-events-auto"),o=this.rightHandle=eW("k-handle k-right-handle k-pointer-events-auto");r.appendChild(eW()),o.appendChild(eW()),n.appendChild(r),n.appendChild(o),this.chartElement.appendChild(t);var a=UF(n,["borderLeftWidth","borderRightWidth","height"]),s=UF(r,"height").height,l=UF(o,"height").height;e.selection={border:{left:a.borderLeftWidth,right:a.borderRightWidth}},UF(r,{top:(a.height-s)/2}),UF(o,{top:(a.height-l)/2}),t.style.cssText=t.style.cssText},t.prototype.bindEvents=function(){var e;!1!==this.options.mousewheel&&(this._mousewheelHandler=this._mousewheel.bind(this),uR(this.chartElement,((e={})[HN]=this._mousewheelHandler,e))),this._domEvents=kB.create(this.chartElement,{stopPropagation:!0,start:this._start.bind(this),move:this._move.bind(this),end:this._end.bind(this),tap:this._tap.bind(this),press:this._press.bind(this),gesturestart:this._gesturestart.bind(this),gesturechange:this._gesturechange.bind(this),gestureend:this._gestureend.bind(this)})},t.prototype.initOptions=function(){var e=this.options,t=this.categoryAxis.pane.chartsBox(),n=this.chart.chartService.intl;this._dateAxis&&BF(e,{min:rO(n,e.min),max:rO(n,e.max),from:rO(n,e.from),to:rO(n,e.to)});var i=UF(this.chartElement,["paddingLeft","paddingTop"]),r=i.paddingLeft,o=i.paddingTop;this.options=BF({},{width:t.width(),height:t.height()+.1,padding:{left:r,top:o},offset:{left:t.x1+r,top:t.y1+o},from:e.min,to:e.max},e)},t.prototype.destroy=function(){var e;this._domEvents&&(this._domEvents.destroy(),delete this._domEvents),clearTimeout(this._mwTimeout),this._state=null,this.wrapper&&(this._mousewheelHandler&&(CR(this.chartElement,((e={})[HN]=this._mousewheelHandler,e)),this._mousewheelHandler=null),this.chartElement.removeChild(this.wrapper),this.wrapper=null)},t.prototype._rangeEventArgs=function(e){return{axis:this.categoryAxis.options,from:this._value(e.from),to:this._value(e.to)}},t.prototype._pointInPane=function(e,t){var n=this.categoryAxis.pane.box,i=this.chart._toModelCoordinates(e,t);return n.containsPoint(i)},t.prototype._start=function(e){var t=this.options,n=vR(e);if(!this._state&&n){var i=gR(e);if(this._pointInPane(i.x,i.y)){var r=tW(n),o=this.body.getBoundingClientRect(),a=!r&&i.x>=o.x&&i.x<=o.x+o.width&&i.y>=o.y&&i.y<=o.y+o.height;this.chart._unsetActivePoint(),this._state={moveTarget:r,startLocation:e.x?e.x.location:0,inBody:a,range:{from:this._index(t.from),to:this._index(t.to)}};var s=this._rangeEventArgs({from:this._index(t.from),to:this._index(t.to)});this.trigger(gN,s)&&(this._state=null)}}},t.prototype._press=function(e){var t;(t=this._state?this._state.moveTarget:tW(vR(e)))&&CF(t,"k-handle-active")},t.prototype._move=function(e){if(this._state){var t=this,n=t._state,i=t.options,r=t.categoryAxis,o=n.range,a=n.moveTarget,s=r.options.reverse,l=this._index(i.from),c=this._index(i.to),d=this._index(i.min),u=this._index(i.max),h=n.startLocation-e.x.location,p=o.from,f=o.to,m=o.to-o.from,g=UF(this.wrapper,"width").width/(r.categoriesCount()-1),v=Math.round(h/g)*(s?-1:1);if(a||n.inBody){var _=a&&JF(a,"k-left-handle"),b=a&&JF(a,"k-right-handle");n.inBody?(o.from=Math.min(Math.max(d,l-v),u-m),o.to=Math.min(o.from+m,u)):_&&!s||b&&s?(o.from=Math.min(Math.max(d,l-v),u-1),o.to=Math.max(o.from+1,o.to)):(_&&s||b&&!s)&&(o.to=Math.min(Math.max(d+1,c-v),u),o.from=Math.min(o.to-1,o.from)),o.from===p&&o.to===f||(this.move(o.from,o.to),this.trigger(vN,this._rangeEventArgs(o)))}}},t.prototype._end=function(){if(this._state){var e=this._state.moveTarget;e&&TF(e,"k-handle-active");var t=this._state.range;this.set(t.from,t.to),this.trigger(_N,this._rangeEventArgs(t)),delete this._state}},t.prototype._tap=function(e){var t=this.options,n=this.categoryAxis,i=this.chart._eventCoordinates(e),r=n.pointCategoryIndex(new OL(i.x,n.box.y1)),o=this._index(t.from),a=this._index(t.to),s=this._index(t.min),l=this._index(t.max),c=a-o,d=o+c/2,u={},h=3===e.event.which,p=Math.round(d-r);this._state||h||(this.chart._unsetActivePoint(),n.options.justified||p--,u.from=Math.min(Math.max(s,o-p),l-c),u.to=Math.min(u.from+c,l),this._start(e),this._state&&(this._state.range=u,this.trigger(vN,this._rangeEventArgs(u)),this._end()))},t.prototype._mousewheel=function(e){var t=this,n=lR(e);if(this._start(e),this._state){var i=this._state.range;e.preventDefault(),e.stopPropagation(),Math.abs(n)>1&&(n*=3),this.options.mousewheel.reverse&&(n*=-1),this.expand(n)&&this.trigger(vN,{axis:this.categoryAxis.options,delta:n,originalEvent:e,from:this._value(i.from),to:this._value(i.to)}),this._mwTimeout&&clearTimeout(this._mwTimeout),this._mwTimeout=setTimeout((function(){t._end()}),FN)}},t.prototype._gesturestart=function(e){var t=this.options,n=e.touches[0];if(this._pointInPane(n.pageX,n.pageY)){this._state={range:{from:this._index(t.from),to:this._index(t.to)}};var i=this._rangeEventArgs(this._state.range);this.trigger(gN,i)?this._state=null:e.preventDefault()}},t.prototype._gestureend=function(){this._state&&(this.trigger(_N,this._rangeEventArgs(this._state.range)),delete this._state)},t.prototype._gesturechange=function(e){if(this._state){var t=this,n=t.chart,i=t._state,r=t.options,o=t.categoryAxis,a=i.range,s=n._toModelCoordinates(e.touches[0].x.location).x,l=n._toModelCoordinates(e.touches[1].x.location).x,c=Math.min(s,l),d=Math.max(s,l);e.preventDefault(),a.from=o.pointCategoryIndex(new OL(c))||r.min,a.to=o.pointCategoryIndex(new OL(d))||r.max,this.move(a.from,a.to),this.trigger(vN,this._rangeEventArgs(a))}},t.prototype._index=function(e){var t=e;return e instanceof Date&&(t=this.categoryAxis.categoryIndex(e)),t},t.prototype._value=function(e){var t=e;return this._dateAxis&&(t=this.categoryAxis.categoryAt(e))>this.options.max&&(t=this.options.max),t},t.prototype._slot=function(e){var t=this.categoryAxis,n=this._index(e);return t.getSlot(n,n,!0)},t.prototype.move=function(e,t){var n=this.options,i=this.categoryAxis.options.reverse,r=n.offset,o=n.padding,a=n.selection.border,s=i?t:e,l=i?e:t,c="x"+(i?2:1),d=this._slot(s),u=xR(d[c]-r.left+o.left);UF(this.leftMask,{width:u}),UF(this.selection,{left:u}),d=this._slot(l);var h=xR(n.width-(d[c]-r.left+o.left));UF(this.rightMask,{width:h});var p=n.width-h;p!==n.width&&(p+=a.right),UF(this.rightMask,{left:p}),UF(this.selection,{width:Math.max(n.width-(u+h)-a.right,0)})},t.prototype.set=function(e,t){var n=this.options,i=this._index(n.min),r=this._index(n.max),o=yR(this._index(e),i,r),a=yR(this._index(t),o+1,r);n.visible&&this.move(o,a),n.from=this._value(o),n.to=this._value(a)},t.prototype.expand=function(e){var t=this.options,n=this._index(t.min),i=this._index(t.max),r=t.mousewheel.zoom,o=this._index(t.from),a=this._index(t.to),s={from:o,to:a},l=BF({},s);if(this._state&&(s=this._state.range),r!==aF&&(s.from=yR(yR(o-e,0,a-1),n,i)),r!==XH&&(s.to=yR(yR(a+e,s.from+1,i),n,i)),s.from!==l.from||s.to!==l.to)return this.set(s.from,s.to),!0},t.prototype.zoom=function(e,t){var n=this.options,i=this._index(n.min),r=this._index(n.max),o=this._index(n.from),a=this._index(n.to),s={from:o,to:a},l=BF({},s),c=this.categoryAxis.options.reverse,d=vF+(c?"2":"1"),u=this.categoryAxis.lineBox(),h=Math.abs(u[d]-t[vF]),p=u.width(),f=xR(h/p,2),m=xR(f*e),g=xR((1-f)*e);if(this._state&&(s=this._state.range),s.from=yR(yR(o-m,0,a-1),i,r),s.to=yR(yR(a+g,s.from+1,r),i,r),s.from!==l.from||s.to!==l.to)return this.set(s.from,s.to),!0},t.prototype.trigger=function(e,t){return(this.observer||this.chart).trigger(e,t)},t}(fr);DR(nW,{visible:!0,mousewheel:{zoom:"both"},min:JH,max:ZH});var iW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.show=function(t){if(t&&t.tooltipAnchor&&(!this._current||this._current!==t)){var n=BF({},this.options,t.options.tooltip),i=t.tooltipAnchor();i?(this._current=t,e.prototype.show.call(this,{point:t,anchor:i},n,t)):this.hide()}},t.prototype.hide=function(){delete this._current,e.prototype.hide.call(this)},t}(j$),rW=function(e){function t(t,n){e.call(this,t.chartService,n),this.plotArea=t,this.formatService=t.chartService.format}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.showAt=function(e,t){var n=ZF(e,(function(e){var t=e.series.tooltip;return!(t&&!1===t.visible)}));if(n.length>0){var i=n[0],r=this.plotArea.categoryAxis.getSlot(i.categoryIx),o=t?this._slotAnchor(t,r):this._defaultAnchor(i,r);this.show({anchor:o,shared:!0,points:e,category:i.category,categoryText:this.formatService.auto(this.options.categoryFormat,i.category),series:this.plotArea.series},this.options)}},t.prototype._slotAnchor=function(e,t){return this.plotArea.categoryAxis.options.vertical||(e.x=t.center().x),{point:e,align:{horizontal:"left",vertical:"center"}}},t.prototype._defaultAnchor=function(e,t){var n=e.owner.pane.chartsBox(),i=this.plotArea.categoryAxis.options.vertical,r=n.center(),o=t.center();return{point:i?new OL(r.x,o.y):new OL(o.x,r.y),align:{horizontal:"center",vertical:"center"}}},t}(j$);DR(rW,{categoryFormat:"{0:d}"});var oW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setup=function(){var e=this.element,t=this.options;if(e.bbox()){this.origin=t.origin;var n=t.vertical?_F:vF,i=this.fromScale=new Go(1,1);i[n]=eV,e.transform(Xo().scale(i.x,i.y))}else this.abort()},t.prototype.step=function(e){var t=nR(this.fromScale.x,1,e),n=nR(this.fromScale.y,1,e);this.element.transform(Xo().scale(t,n,this.origin))},t.prototype.abort=function(){e.prototype.abort.call(this),this.element.transform(null)},t}(nl);DR(oW,{duration:XO}),tl.current.register(mV,oW);var aW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setup=function(){var e=this.center=this.element.bbox().center();this.element.transform(Xo().scale(eV,eV,e))},t.prototype.step=function(e){this.element.transform(Xo().scale(e,e,this.center))},t}(nl);DR(aW,{easing:"easeOutElastic"}),tl.current.register(vV,aW);var sW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setup=function(){this.fadeTo=this.element.opacity(),this.element.opacity(0)},t.prototype.step=function(e){this.element.opacity(e*this.fadeTo)},t}(nl);DR(sW,{duration:200,easing:"linear"}),tl.current.register(ZO,sW);var lW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setup=function(){this.element.transform(Xo().scale(eV,eV,this.options.center))},t.prototype.step=function(e){this.element.transform(Xo().scale(e,e,this.options.center))},t}(nl);DR(lW,{easing:"easeOutElastic",duration:XO}),tl.current.register(AV,lW);var cW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){e.prototype.render.call(this),this.renderSegments()},t.prototype.createSegment=function(e,t,n){return new(t.style===hV?m$:u$)(e,t,n)},t.prototype.animationPoints=function(){return e.prototype.animationPoints.call(this).concat(this._segments)},t.prototype.createMissingValue=function(e,t){if(t===sV){var n={x:e.x,y:e.y};return e$(n.x)||(n.x=0),e$(n.y)||(n.y=0),n}},t}(O$);function dW(e,t,n){var i=[],r=t.xMin,o=t.xMax,a=(n||{}).forecast;a&&(a.before>0&&(r-=a.before),a.after>0&&(o+=a.after));var s=(n||{}).samplingInterval,l=SR(s,BL(r,o)/10);s<=0&&(l=o-r);for(var c=r;c<=o;c+=l)i.push([c,e(c)]);return i}BF(cW.prototype,g$);var uW=function(e){return function(t){var n=t.valueFields;return{xValue:n.x,yValue:Math.log(n[e])}}};var hW=function(e){return function(t){var n=t.valueFields;return{xValue:n.x,yValue:n[e]}}};function pW(e,t){for(var n=Number.MAX_VALUE,i=Number.MIN_VALUE,r=0;r<e.length;r++){var o=t(e[r]),a=o.xValue,s=o.yValue;isFinite(a)&&null!==a&&isFinite(s)&&null!==s&&(n=Math.min(a,n),i=Math.max(a,i))}return{xMin:n,xMax:i}}var fW=function(e){return function(t){var n=t.valueFields;return{xValue:n.x,yValue:n[e]}}},mW=function(e){return function(t){var n=t.valueFields;return{xValue:Math.log(n.x),yValue:n[e]}}};var gW=function(e){return function(t){var n=t.valueFields;return{xValue:Math.log(n.x),yValue:Math.log(n[e])}}};var vW={};vW[GV]=function(e){var t=e.options,n=function(e){var t=e.seriesValues,n=e.options,i=t();if(!wU(i,n.field))return null;var r=yU(i,uW(n.field)),o=r.slope,a=r.intercept,s=r.count,l=r.xMin,c=r.xMax,d={xMin:l,xMax:c};if(s>0){var u=Math.exp(a),h=o;return dW((function(e){return u*Math.exp(h*e)}),d,n.trendline)}return null}({seriesValues:e.seriesValues,options:t});return n?Object.assign({},t,{type:"scatterLine",data:n}):null},vW[KV]=function(e){var t=e.options,n=function(e){var t=e.seriesValues,n=e.options,i=yU(t(),hW(n.field)),r=i.slope,o=i.intercept,a=i.count,s=i.xMin,l=i.xMax,c={xMin:s,xMax:l};if(a>0)return dW((function(e){return r*e+o}),c,n.trendline);return null}({seriesValues:e.seriesValues,options:t});return n?Object.assign({},t,{type:"scatterLine",data:n}):null},vW[YV]=function(e){var t=e.options,n=function(e){var t=e.seriesValues,n=e.options,i=t();if(!wU(i,"x"))return null;var r=yU(i,mW(n.field)),o=r.slope,a=r.intercept,s=r.count,l=pW(i,fW(n.field));if(s>0){var c=o,d=a;return dW((function(e){return c*Math.log(e)+d}),l,n.trendline)}return null}({seriesValues:e.seriesValues,options:t});return n?Object.assign({},t,{type:"scatterLine",data:n}):null},vW[QV]=function(e){var t=e.options,n=function(e){var t=e.options,n=e.seriesValues,i=(t.trendline||{}).period||2,r=TU(n({before:i,after:i}),hW(t.field),i);if(r.length>0)return r;return null}(e);return n?Object.assign({},t,{type:"scatterLine",data:n}):null},vW[XV]=function(e){var t=e.options,n=function(e){var t=e.seriesValues,n=e.options,i=(n.trendline||{}).order,r=hW(n.field),o=AU(t(),r,i),a=o.count,s=o.valueMapper,l=o.xMin,c=o.xMax,d={xMin:l,xMax:c};if(a>0)return dW(s,d,n.trendline);return null}({seriesValues:e.seriesValues,options:t});return n?Object.assign({},t,{type:"scatterLine",data:n}):null},vW[ZV]=function(e){var t=e.options,n=function(e){var t=e.seriesValues,n=e.options,i=t();if(!wU(i,"x"))return null;var r=yU(i,gW(n.field)),o=r.slope,a=r.intercept,s=r.count,l=pW(i,hW(n.field));if(s>0){var c=Math.exp(a),d=o;return dW((function(e){return c*Math.pow(e,d)}),l,n.trendline)}return null}({seriesValues:e.seriesValues,options:t});return n?Object.assign({},t,{type:"scatterLine",data:n}):null};var _W=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initFields=function(){this.namedXAxes={},this.namedYAxes={},this.xAxisRangeTracker=new C$,this.yAxisRangeTracker=new C$},t.prototype.render=function(e){var t=this;void 0===e&&(e=this.panes),this.series=[].concat(this.originalSeries),this.createTrendlineSeries();for(var n=this.groupSeriesByPane(),i=0;i<e.length;i++){var r=e[i],o=n[r.options.name||"default"]||[];t.addToLegend(o);var a=t.filterVisibleSeries(o);a&&(t.createScatterChart(QN(a,BV),r),t.createScatterLineChart(QN(a,OV),r),t.createBubbleChart(QN(a,vV),r))}this.createAxes(e)},t.prototype.appendChart=function(t,n){this.xAxisRangeTracker.update(t.xAxisRanges),this.yAxisRangeTracker.update(t.yAxisRanges),e.prototype.appendChart.call(this,t,n)},t.prototype.removeAxis=function(t){var n=t.options.name;e.prototype.removeAxis.call(this,t),t.options.vertical?(this.yAxisRangeTracker.reset(n),delete this.namedYAxes[n]):(this.xAxisRangeTracker.reset(n),delete this.namedXAxes[n]),t===this.axisX&&delete this.axisX,t===this.axisY&&delete this.axisY},t.prototype.seriesPaneName=function(e){var t=this.options,n=e.xAxis,i=ZF([].concat(t.xAxis),(function(e){return e.name===n}))[0],r=e.yAxis,o=ZF([].concat(t.yAxis),(function(e){return e.name===r}))[0],a=(t.panes||[{}])[0].name||"default";return(i||{}).pane||(o||{}).pane||a},t.prototype.createScatterChart=function(e,t){e.length>0&&this.appendChart(new O$(this,{series:e,clip:t.options.clip}),t)},t.prototype.createScatterLineChart=function(e,t){e.length>0&&this.appendChart(new cW(this,{series:e,clip:t.options.clip}),t)},t.prototype.createBubbleChart=function(e,t){e.length>0&&this.appendChart(new N$(this,{series:e,clip:t.options.clip}),t)},t.prototype.createXYAxis=function(e,t,n){for(var i,r=e.name,o=t?this.namedYAxes:this.namedXAxes,a=t?this.yAxisRangeTracker:this.xAxisRangeTracker,s=BF({reverse:!t&&this.chartService.rtl},e,{vertical:t}),l=KN(s.type,MN),c=a.query(),d=l?{min:.1,max:1}:{min:0,max:1},u=a.query(r)||c||d,h=[s.min,s.max],p=this.series,f=0;f<p.length;f++){var m=p[f],g=m[t?"yAxis":"xAxis"];if(g===s.name||0===n&&!g){var v=qO.current.bindPoint(m,0).valueFields;h.push(v[t?"y":"x"]);break}}0===n&&c&&(u.min=Math.min(u.min,c.min),u.max=Math.max(u.max,c.max));for(var _=0;_<h.length;_++)if(h[_]instanceof Date){i=!0;break}var b=new(KN(s.type,VH)||!s.type&&i?CO:l?TO:kO)(u.min,u.max,s,this.chartService);if(b.axisIndex=n,r){if(o[r])throw new Error((t?"Y":"X")+" axis with name "+r+" is already defined");o[r]=b}return this.appendAxis(b),b},t.prototype.createAxes=function(e){for(var t=this,n=this.options,i=[].concat(n.xAxis),r=[],o=[].concat(n.yAxis),a=[],s=0;s<i.length;s++){tR(t.findPane(i[s].pane),e)&&r.push(t.createXYAxis(i[s],!1,s))}for(var l=0;l<o.length;l++){tR(t.findPane(o[l].pane),e)&&a.push(t.createXYAxis(o[l],!0,l))}this.axisX=this.axisX||r[0],this.axisY=this.axisY||a[0]},t.prototype._dispatchEvent=function(e,t,n){for(var i=e._eventCoordinates(t),r=new OL(i.x,i.y),o=this.axes,a=o.length,s=[],l=[],c=0;c<a;c++){var d=o[c],u=d.options.vertical?l:s,h=d.getValue(r);null!==h&&u.push(h)}s.length>0&&l.length>0&&e.trigger(n,{element:vR(t),originalEvent:t,x:n$(s),y:n$(l)})},t.prototype.updateAxisOptions=function(e,t){var n=e.options.vertical,i=this.groupAxes(this.panes),r=(n?i.y:i.x).indexOf(e);bW(this.options,r,n,t),bW(this.originalOptions,r,n,t)},t.prototype.trendlineFactory=function(e,t){var n=this.seriesValues.bind(this,t.index),i=bU(vW,e.type,{options:e,seriesValues:n});return i&&(i.xAxis=t.xAxis,i.yAxis=t.yAxis),i},t.prototype.seriesValues=function(e){for(var t=[],n=this.series[e],i=0;i<n.data.length;i++){var r=this.bindPoint(n,i);t.push({pointIx:i,valueFields:r.valueFields})}return t},t}(X$);function bW(e,t,n,i){BF([].concat(n?e.yAxis:e.xAxis)[t],i)}DR(_W,{xAxis:{},yAxis:{}}),BF(_W.prototype,nU);var yW=function(e){function t(t,n,i){e.call(this,i),this.value=t,this.sector=n}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){this._rendered||!1===this.visible||(this._rendered=!0,this.createLabel())},t.prototype.createLabel=function(){var e=this.options.labels,t=this.owner.chartService,n=this.getLabelText(e);if(e.visible&&(n||0===n)){if(e.position===LH||e.position===IN)e.color||(e.color=NR(this.options.color)),e.background||(e.background=this.options.color);else{var i=t.theme.seriesDefaults.labels;e.color=e.color||i.color,e.background=e.background||i.background}this.label=new sB(n,BF({},e,{align:LH,vAlign:"",animation:{type:ZO,delay:this.animationDelay}}),this.pointData()),this.append(this.label)}},t.prototype.getLabelText=function(e){var t=GF(e);return t?t(this.pointData()):this.owner.chartService.format.auto(e.format,this.value)},t.prototype.reflow=function(e){this.render(),this.box=e,this.reflowLabel()},t.prototype.reflowLabel=function(){var e=this.options.labels,t=this.label,n=this.sector.clone(),i=e.distance,r=n.middle();if(t){var o,a=t.box.height(),s=t.box.width();if(e.position===LH)n.radius=Math.abs((n.radius-a)/2)+a,o=n.point(r),t.reflow(new VL(o.x,o.y-a/2,o.x,o.y));else if(e.position===IN)n.radius=n.radius-a/2,o=n.point(r),t.reflow(new VL(o.x,o.y-a/2,o.x,o.y));else{var l;(o=n.clone().expand(i).point(r)).x>=n.center.x?(l=o.x+s,t.orientation=aF):(l=o.x-s,t.orientation=XH),t.reflow(new VL(l,o.y-a,o.x,o.y))}}},t.prototype.createVisual=function(){var t=this,n=this.sector,i=this.options;if(e.prototype.createVisual.call(this),this.addAccessibilityAttributesToVisual(),this.value)if(i.visual){var r=(n.startAngle+180)%360,o=i.visual({category:this.category,dataItem:this.dataItem,value:this.value,series:this.series,percentage:this.percentage,center:new Go(n.center.x,n.center.y),radius:n.radius,innerRadius:n.innerRadius,startAngle:r,endAngle:r+n.angle,options:i,sender:this.getSender(),createVisual:function(){var e=new vs;return t.createSegmentVisual(e),e}});o&&this.visual.append(o)}else this.createSegmentVisual(this.visual)},t.prototype.createSegmentVisual=function(e){var t=this.sector,n=this.options,i=n.border||{},r=i.width>0?{stroke:{color:i.color,width:i.width,opacity:i.opacity,dashType:i.dashType}}:{},o=n.color,a=KL(n.pattern,{color:o,opacity:n.opacity}),s=this.createSegment(t,BF({fill:a,stroke:{opacity:n.opacity},zIndex:n.zIndex},r));e.append(s),JN(n)&&e.append(this.createGradientOverlay(s,{baseColor:o,fallbackFill:a},BF({center:[t.center.x,t.center.y],innerRadius:t.innerRadius,radius:t.radius,userSpace:!0},n.overlay)))},t.prototype.createSegment=function(e,t){return t.singleSegment?new ua(new oa(new Go(e.center.x,e.center.y),e.radius),t):jL.current.createRing(e,t)},t.prototype.createAnimation=function(){var t=this.options,n=this.sector.center;BF(t,{animation:{center:[n.x,n.y],delay:this.animationDelay}}),e.prototype.createAnimation.call(this)},t.prototype.createHighlight=function(e){var t=this.options.highlight||{},n=t.border||{};return this.createSegment(this.sector,BF({},e,{fill:{color:t.color,opacity:t.opacity},stroke:{opacity:n.opacity,width:n.width,color:n.color}}))},t.prototype.highlightVisual=function(){return this.visual.children[0]},t.prototype.highlightVisualArgs=function(){var e=this.sector;return{options:this.options,radius:e.radius,innerRadius:e.innerRadius,center:new Go(e.center.x,e.center.y),startAngle:e.startAngle,endAngle:e.angle+e.startAngle,visual:this.visual}},t.prototype.createFocusHighlight=function(e){var t=this.options.accessibility.highlight.border.width,n=this.createSegment(this.sector,BF({},e,{stroke:{width:2*t}})),i=new hs;return i.paths.push(us.fromRect(n.bbox())),i.paths.push(this.createSegment(this.sector,{})),n.clip(i),n},t.prototype.tooltipAnchor=function(){var e=this.sector.clone().expand(5),t=e.middle();return{point:e.point(t),align:xW(t+180)}},t.prototype.formatValue=function(e){return this.owner.formatPointValue(this,e)},t.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series,percentage:this.percentage}},t.prototype.getIndex=function(){return this.index},t}(qL),wW=xR(kR(30),$H),kW=xR(kR(60),$H);function xW(e){var t=kR(e),n=xR(Math.sin(t),$H),i=xR(Math.cos(t),$H);return{horizontal:Math.abs(n)>kW?LH:i<0?aF:XH,vertical:Math.abs(n)<wW?LH:n<0?RH:dF}}DR(yW,{color:mF,overlay:{gradient:"roundedBevel"},border:{width:.5},labels:{visible:!1,distance:35,font:NH,margin:WF(.5),align:BH,zIndex:1,position:PN},animation:{type:AV},highlight:{visible:!0,border:{width:1}},visible:!0,accessibility:{role:xN,className:CN,ariaRoleDescription:SN}}),BF(yW.prototype,l$),BF(yW.prototype,T$);var CW={createLegendItem:function(e,t,n){var i=this.options.legend||{},r=i.labels||{},o=i.inactiveItems||{},a=o.labels||{};if(n&&!1!==n.visibleInLegend){var s,l,c=!1!==n.visible,d=c?GF(r):GF(a)||GF(r),u=n.category;d&&(u=d({text:u,series:n.series,dataItem:n.dataItem,percentage:n.percentage,value:e})),c?(s={},l=t.color):(s={color:a.color,font:a.font},l=(o.markers||{}).color),e$(u)&&""!==u&&this.legendItems.push({active:c,pointIndex:n.index,text:u,series:n.series,markerColor:l,pattern:t.pattern,labels:s})}}},SW=function(e){function t(t,n){e.call(this,n),this.plotArea=t,this.chartService=t.chartService,this.points=[],this.legendItems=[],this.render()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){this.traverseDataPoints(this.addValue.bind(this))},t.prototype.traverseDataPoints=function(e){var t=this.options,n=this.plotArea.options.seriesColors;void 0===n&&(n=[]);for(var i=n.length,r=t.series,o=r.length,a=0;a<o;a++){var s=r[a],l=s.data,c=qN(s),d=c.total,u=c.points,h=c.count,p=360/d,f=void 0;isFinite(p)||(f=360/h);var m=void 0;m=hR(s.startAngle)?s.startAngle:t.startAngle,a!==o-1&&s.labels.position===PN&&(s.labels.position=LH);for(var g=0;g<u.length;g++){var v=u[g];if(v){var _=v.fields,b=v.value,y=v.visible,w=0!==b?f||b*p:0,k=1!==l.length&&Boolean(_.explode);FF(s.color)||(s.color=_.color||n[g%i]),e(b,new $L(null,0,0,m,w),{owner:this,category:hR(_.category)?_.category:"",pattern:hR(_.pattern)?_.pattern:s.pattern,index:g,series:s,seriesIx:a,dataItem:l[g],percentage:0!==d?b/d:0,explode:k,visibleInLegend:_.visibleInLegend,visible:y,zIndex:o-a,animationDelay:this.animationDelay(g,a,o)}),!1!==y&&(m+=w)}}}},t.prototype.evalSegmentOptions=function(e,t,n){var i=n.series;YN(e,{value:t,series:i,dataItem:n.dataItem,category:n.category,percentage:n.percentage},{defaults:i._defaults,excluded:["data","content","template","visual","toggle","ariaTemplate","ariaContent"]})},t.prototype.addValue=function(e,t,n){var i=BF({},n.series,{index:n.index});if(i.pattern=n.pattern||i.pattern,this.evalSegmentOptions(i,e,n),this.createLegendItem(e,i,n),!1!==n.visible){var r=new yW(e,t,i);Object.assign(r,n),this.append(r),this.points.push(r)}},t.prototype.reflow=function(e){var t=this,n=t.options,i=t.points,r=t.seriesConfigs;void 0===r&&(r=[]);var o=i.length,a=e.clone(),s=Math.min(a.width(),a.height()),l=s/2,c=s-.85*s,d=new VL(a.x1,a.y1,a.x1+s,a.y1+s),u=d.center(),h=a.center(),p=n.series.length,f=[],m=[],g=SR(n.padding,c);this.targetBox=e,g=g>l-5?l-5:g,d.translate(h.x-u.x,h.y-u.y);for(var v=l-g,_=new OL(v+d.x1+g,v+d.y1+g),b=0;b<o;b++){var y=i[b],w=y.sector,k=y.seriesIx;if(w.radius=v,w.center=_,r.length){var x=r[k];w.innerRadius=x.innerRadius,w.radius=x.radius}k===p-1&&y.explode&&(w.center=w.clone().setRadius(.15*w.radius).point(w.middle())),y.reflow(d);var C=y.label;C&&C.options.position===PN&&k===p-1&&(C.orientation===aF?m.push(C):f.push(C))}f.length>0&&(f.sort(this.labelComparator(!0)),this.leftLabelsReflow(f)),m.length>0&&(m.sort(this.labelComparator(!1)),this.rightLabelsReflow(m)),this.box=d},t.prototype.leftLabelsReflow=function(e){var t=this.distanceBetweenLabels(e);this.distributeLabels(t,e)},t.prototype.rightLabelsReflow=function(e){var t=this.distanceBetweenLabels(e);this.distributeLabels(t,e)},t.prototype.distanceBetweenLabels=function(e){var t=bR(this.points),n=t.sector,i=e.length-1,r=n.radius+t.options.labels.distance,o=[],a=e[0].box,s=xR(a.y1-(n.center.y-r-a.height()-a.height()/2));o.push(s);for(var l=0;l<i;l++){var c=e[l+1].box;a=e[l].box,s=xR(c.y1-a.y2),o.push(s)}return s=xR(n.center.y+r-e[i].box.y2-e[i].box.height()/2),o.push(s),o},t.prototype.distributeLabels=function(e,t){for(var n,i,r,o=e.length,a=0;a<o;a++)for(r=-e[a],n=i=a;r>0&&(n>=0||i<o);)r=this._takeDistance(e,a,--n,r),r=this._takeDistance(e,a,++i,r);this.reflowLabels(e,t)},t.prototype._takeDistance=function(e,t,n,i){var r=i;if(e[n]>0){var o=Math.min(e[n],r);r-=o,e[n]-=o,e[t]+=o}return r},t.prototype.reflowLabels=function(e,t){var n,i=bR(this.points),r=i.sector,o=i.options.labels,a=t.length,s=o.distance,l=r.center.y-(r.radius+s)-t[0].box.height();e[0]+=2;for(var c=0;c<a;c++){var d=t[c],u=d.box;l+=e[c],n=this.hAlignLabel(u.x2,r.clone().expand(s),l,l+u.height(),d.orientation===aF),d.orientation===aF?(o.align!==BH&&(n=r.radius+r.center.x+s),d.reflow(new VL(n+u.width(),l,n,l))):(o.align!==BH&&(n=r.center.x-r.radius-s),d.reflow(new VL(n-u.width(),l,n,l))),l+=u.height()}},t.prototype.createVisual=function(){var t=this,n=this.options.connectors,i=this.points,r=i.length;e.prototype.createVisual.call(this),this._connectorLines=[];for(var o=0;o<r;o++){var a=i[o],s=a.sector,l=a.label,c=s.middle(),d=(a.options.connectors||{}).color||n.color;if(l){var u=new us({stroke:{color:d,width:n.width},animation:{type:ZO,delay:a.animationDelay}});if(l.options.position===PN){var h=l.box,p=s.center,f=s.point(c),m=new OL(h.x1,h.center().y),g=void 0,v=void 0,_=void 0;f=s.clone().expand(n.padding).point(c),u.moveTo(f.x,f.y),l.orientation===aF?(_=TW(p,f,m,v=new OL(h.x1-n.padding,h.center().y)),m=new OL(v.x-4,v.y),(_=_||m).x=Math.min(_.x,m.x),t.pointInCircle(_,s.center,s.radius+4)||_.x<s.center.x?(g=s.center.x+s.radius+4,a.options.labels.align!==yV?g<m.x?u.lineTo(g,f.y):u.lineTo(f.x+8,f.y):u.lineTo(g,f.y),u.lineTo(m.x,v.y)):(_.y=v.y,u.lineTo(_.x,_.y))):(_=TW(p,f,m,v=new OL(h.x2+n.padding,h.center().y)),m=new OL(v.x+4,v.y),(_=_||m).x=Math.max(_.x,m.x),t.pointInCircle(_,s.center,s.radius+4)||_.x>s.center.x?(g=s.center.x-s.radius-4,a.options.labels.align!==yV?g>m.x?u.lineTo(g,f.y):u.lineTo(f.x-8,f.y):u.lineTo(g,f.y),u.lineTo(m.x,v.y)):(_.y=v.y,u.lineTo(_.x,_.y))),u.lineTo(v.x,v.y),t._connectorLines.push(u),t.visual.append(u)}}}},t.prototype.renderVisual=function(){if(e.prototype.renderVisual.call(this),RR(this.options.series,(function(e){return e.autoFit}))){var t=this.targetBox,n=this.box.center(),i=this.visual.bbox();if(!i)return;var r=i.bottomRight(),o=Math.min((n.y-t.y1)/(n.y-i.origin.y),(t.y2-n.y)/(r.y-n.y),(n.x-t.x1)/(n.x-i.origin.x),(t.x2-n.x)/(r.x-n.x));o<1&&this.visual.transform(Xo().scale(o,o,[n.x,n.y]))}},t.prototype.labelComparator=function(e){var t=e?-1:1;return function(e,n){return((e.parent.sector.middle()+270)%360-(n.parent.sector.middle()+270)%360)*t}},t.prototype.hAlignLabel=function(e,t,n,i,r){var o=t.radius,a=t.center,s=a.x,l=a.y,c=Math.min(Math.abs(l-n),Math.abs(l-i));return c>o?e:s+Math.sqrt(o*o-c*c)*(r?1:-1)},t.prototype.pointInCircle=function(e,t,n){return Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)<Math.pow(n,2)},t.prototype.formatPointValue=function(e,t){return this.chartService.format.auto(t,e.value)},t.prototype.animationDelay=function(e){return 70*e},t.prototype.stackRoot=function(){return this},t}(qL);function TW(e,t,n,i){var r,o=(i.x-n.x)*(e.y-n.y)-(i.y-n.y)*(e.x-n.x),a=(i.y-n.y)*(t.x-e.x)-(i.x-n.x)*(t.y-e.y);if(0!==a){var s=o/a;r=new OL(e.x+s*(t.x-e.x),e.y+s*(t.y-e.y))}return r}DR(SW,{startAngle:90,connectors:{width:2,color:"#939393",padding:8},inactiveItems:{markers:{},labels:{}}}),BF(SW.prototype,CW),SW.prototype.isStackRoot=!0;var DW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){this.createPieChart(this.series)},t.prototype.createPieChart=function(e){var t=e[0],n=new SW(this,{series:e,padding:t.padding,startAngle:t.startAngle,connectors:t.connectors,legend:this.options.legend});this.appendChart(n)},t.prototype.appendChart=function(t,n){e.prototype.appendChart.call(this,t,n),dR(this.options.legend.data,t.legendItems)},t.prototype.getPointBelow=function(e){return this.getPointToTheRight(e)},t.prototype.getPointAbove=function(e){return this.getPointToTheLeft(e)},t}(X$),AW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflowLabel=function(){var t=this.options.labels,n=this.label,i=this.sector.clone(),r=i.middle();if(n){var o=n.box.height();if(t.position===LH){i.radius-=(i.radius-i.innerRadius)/2;var a=i.point(r);n.reflow(new VL(a.x,a.y-o/2,a.x,a.y))}else e.prototype.reflowLabel.call(this)}},t.prototype.createSegment=function(e,t){return jL.current.createRing(e,t)},t}(yW);DR(AW,{overlay:{gradient:"roundedGlass"},labels:{position:LH},animation:{type:AV}}),BF(AW.prototype,l$);var MW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.addValue=function(e,t,n){var i=BF({},n.series,{index:n.index});if(i.pattern=n.pattern||i.pattern,this.evalSegmentOptions(i,e,n),this.createLegendItem(e,i,n),!1!==n.visible){var r=new AW(e,t,i);Object.assign(r,n),this.append(r),this.points.push(r)}},t.prototype.reflow=function(t){for(var n,i=this.options,r=t.clone(),o=Math.min(r.width(),r.height()),a=o/2,s=o-.85*o,l=i.series,c=l.length,d=SR(i.padding,s),u=a-(d=d>a-5?a-5:d),h=0,p=0;p<c;p++){var f=l[p];0===p&&hR(f.holeSize)&&(n=f.holeSize,u-=f.holeSize),hR(f.size)?u-=f.size:h++,hR(f.margin)&&p!==c-1&&(u-=f.margin)}hR(n)||(u-=n=.75*((a-d)/(c+.75)));var m,g=n,v=0;this.seriesConfigs=[];for(var _=0;_<c;_++){var b=l[_];m=(g+=v)+SR(b.size,u/h),this.seriesConfigs.push({innerRadius:g,radius:m}),v=b.margin||0,g=m}e.prototype.reflow.call(this,t)},t.prototype.animationDelay=function(e,t,n){return 50*e+XO*(t+1)/(n+1)},t}(SW);DR(MW,{startAngle:90,connectors:{width:2,color:"#939393",padding:8}});var EW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){this.createDonutChart(this.series)},t.prototype.createDonutChart=function(e){var t=e[0],n=new MW(this,{series:e,padding:t.padding,connectors:t.connectors,legend:this.options.legend});this.appendChart(n)},t.prototype.getPointBelow=function(e){return this._getNextPoint(e,this._pointsByVertical,-1)},t.prototype.getPointAbove=function(e){return this._getNextPoint(e,this._pointsByVertical,1)},t}(DW),IW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initFields=function(){this.valueAxisRangeTracker=new C$},t.prototype.render=function(){this.addToLegend(this.series),this.createPolarAxis(),this.createCharts(),this.createValueAxis()},t.prototype.alignAxes=function(){var e=this.valueAxis,t=e.range(),n=e.options.reverse?t.max:t.min,i=e.getSlot(n),r=this.polarAxis.getSlot(0).center,o=e.box.translate(r.x-i.x1,r.y-i.y1);e.reflow(o)},t.prototype.createValueAxis=function(){var e,t,n=this.valueAxisRangeTracker,i=n.query(),r=this.valueAxisOptions({roundToMajorUnit:!1,zIndex:-1});r.type===MN?(e=FO,t={min:.1,max:1}):(e=HO,t={min:0,max:1});var o=n.query(name)||i||t;o&&i&&(o.min=Math.min(o.min,i.min),o.max=Math.max(o.max,i.max));var a=new e(o.min,o.max,r,this.chartService);this.valueAxis=a,this.appendAxis(a)},t.prototype.reflowAxes=function(){var e=this,t=e.options.plotArea,n=e.valueAxis,i=e.polarAxis,r=e.box,o=.15*Math.min(r.width(),r.height()),a=WF(t.padding||{},o),s=r.clone().unpad(a),l=s.clone();l.y2=l.y1+Math.min(l.width(),l.height()),l.align(s,_F,LH);var c=l.clone().shrink(0,l.height()/2);i.reflow(l),n.reflow(c);var d=n.lineBox().height()-n.box.height();n.reflow(n.box.unpad({top:d})),this.axisBox=l,this.alignAxes(l)},t.prototype.backgroundBox=function(){return this.box},t.prototype.detachLabels=function(){},t}(X$),zW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.pointSlot=function(e,t){var n=e.center.y-t.y1,i=OL.onCircle(e.center,e.startAngle,n);return new VL(i.x,i.y,i.x,i.y)},t}(O$);DR(zW,{clip:!1});var PW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(cW);PW.prototype.pointSlot=zW.prototype.pointSlot,DR(PW,{clip:!1});var HW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.fillToAxes=function(e){var t=this._polarAxisCenter();e.lineTo(t.x,t.y)},t.prototype._polarAxisCenter=function(){return this.parent.plotArea.polarAxis.box.center()},t.prototype.strokeSegments=function(){var e=this._strokeSegments;if(!e){var t=this._polarAxisCenter(),n=new RO(!1),i=this.points();i.push(t),(e=this._strokeSegments=n.process(i)).pop()}return e},t}(k$),FW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.fillToAxes=function(e){var t=this.parent.plotArea.polarAxis.box.center(),n=new La([t.x,t.y]);e.segments.unshift(n),e.segments.push(n)},t}(y$),RW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createSegment=function(e,t,n){return(t.line||{}).style===hV?new HW(e,t,n):new FW(e,t,n)},t.prototype.createMissingValue=function(e,t){var n;return e$(e.x)&&t!==lV&&(n={x:e.x,y:e.y},t===sV&&(n.y=0)),n},t.prototype.seriesMissingValues=function(e){return e.missingValues||sV},t.prototype._hasMissingValuesGap=function(){for(var e=this.options.series,t=0;t<e.length;t++)if(this.seriesMissingValues(e[t])===cV)return!0},t.prototype.sortPoints=function(e){if(e.sort(LW),this._hasMissingValuesGap())for(var t=0;t<e.length;t++){var n=e[t];if(n)e$(n.value.y)||this.seriesMissingValues(n.series)!==cV||delete e[t]}return e},t}(PW);function LW(e,t){return e.value.x-t.value.x}var BW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createPolarAxis=function(){var e=new IO(this.options.xAxis,this.chartService);this.polarAxis=e,this.axisX=e,this.appendAxis(e)},t.prototype.render=function(){this.series=[].concat(this.originalSeries),this.createTrendlineSeries(),e.prototype.render.call(this)},t.prototype.valueAxisOptions=function(e){return BF(e,{majorGridLines:{type:AH},minorGridLines:{type:AH}},this.options.yAxis)},t.prototype.createValueAxis=function(){e.prototype.createValueAxis.call(this),this.axisY=this.valueAxis},t.prototype.trendlineFactory=function(e,t){var n=_W.prototype.trendlineFactory.call(this,e,t);return n&&(n.type=EV),n},t.prototype.appendChart=function(e,t){this.valueAxisRangeTracker.update(e.yAxisRanges),X$.prototype.appendChart.call(this,e,t)},t.prototype.createCharts=function(){var e=this.filterVisibleSeries(this.series),t=this.panes[0];this.createLineChart(QN(e,[EV]),t),this.createScatterChart(QN(e,[IV]),t),this.createAreaChart(QN(e,[MV]),t)},t.prototype.createLineChart=function(e,t){if(0!==e.length){var n=new PW(this,{series:e});this.appendChart(n,t)}},t.prototype.createScatterChart=function(e,t){if(0!==e.length){var n=new zW(this,{series:e});this.appendChart(n,t)}},t.prototype.createAreaChart=function(e,t){if(0!==e.length){var n=new RW(this,{series:e});this.appendChart(n,t)}},t.prototype._dispatchEvent=function(e,t,n){var i=e._eventCoordinates(t),r=new OL(i.x,i.y),o=this.axisX.getValue(r),a=this.axisY.getValue(r);null!==o&&null!==a&&e.trigger(n,{element:vR(t),x:o,y:a})},t.prototype.createCrosshairs=function(){},t}(IW);DR(BW,{xAxis:{},yAxis:{}}),BF(BW.prototype,nU,{seriesValues:_W.prototype.seriesValues});var OW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.pointSlot=function(e,t){var n=e.center.y-t.y1,i=OL.onCircle(e.center,e.middle(),n);return new VL(i.x,i.y,i.x,i.y)},t.prototype.renderSegments=function(){if(e.prototype.renderSegments.call(this),this._segments&&this._segments.length>1)for(var t=function(e){for(var t=[],n=0;n<e.length;n++){var i=e[n];t[i.seriesIx]=t[i.seriesIx]||[],t[i.seriesIx].push(i)}return t}(this._segments),n=0;n<t.length;n++){var i=t[n];if(i&&i.length>1){var r=i[0].linePoints[0],o=bR(i),a=bR(o.linePoints),s=0===r.categoryIx,l=a.categoryIx===a.categoriesCount-1;s&&l&&bR(i).linePoints.push(r)}}},t.prototype.createSegment=function(e,t,n){var i=new(t.style===hV?m$:u$)(e,t,n),r=this.seriesMissingValues(t);return e.length!==t.data.length&&r!==lV||(i.options.closed=!0),i},t}(b$);DR(OW,{clip:!1,limitPoints:!1});var VW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.fillToAxes=function(){},t}(k$),NW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.fillToAxes=function(){},t}(y$),$W=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createSegment=function(e,t,n,i){var r,o,a,s=this.options.isStacked,l=(t.line||{}).style;return s&&n>0&&i&&(o=i.linePoints.slice(0),r=i),l===hV?(a=new VW(e,t,n,r,o)).options.closed=!0:(e.push(e[0]),a=new NW(e,t,n,r,o)),a},t.prototype.seriesMissingValues=function(e){return e.missingValues||sV},t}(OW),UW=function(e){function t(t,n){e.call(this,t,null,n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getIndex=function(){return this.categoryIx},t}(AW);DR(UW,{overlay:{gradient:"none"},labels:{distance:10}});var WW=function(e){function t(t){e.call(this,t),this.forEach=t.rtl?M$:A$}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(e){var t=this.options,n=this.children,i=t.gap,r=t.spacing,o=n.length,a=o+i+r*(o-1),s=e.angle/a,l=e.startAngle+s*(i/2);this.forEach(n,(function(t){var n=e.clone();n.startAngle=l,n.angle=s,t.sector&&(n.radius=t.sector.radius),t.reflow(n),t.sector=n,l+=s+s*r}))},t}(qL);DR(WW,{gap:1,spacing:0});var jW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(e){var t=this.options.reverse,n=this.children,i=n.length,r=t?i-1:0,o=t?-1:1;this.box=new VL;for(var a=r;a>=0&&a<i;a+=o){var s=n[a].sector;s.startAngle=e.startAngle,s.angle=e.angle}},t}(qL),qW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.pointType=function(){return UW},t.prototype.clusterType=function(){return WW},t.prototype.stackType=function(){return jW},t.prototype.categorySlot=function(e,t){return e.getSlot(t)},t.prototype.pointSlot=function(e,t){var n=e.clone(),i=e.center.y;return n.radius=i-t.y1,n.innerRadius=i-t.y2,n},t.prototype.reflowPoint=function(e,t){e.sector=t,e.reflow()},t.prototype.createAnimation=function(){this.options.animation.center=this.box.toRect().center(),e.prototype.createAnimation.call(this)},t}(z$);qW.prototype.reflow=s$.prototype.reflow,DR(qW,{clip:!1,limitPoints:!1,animation:{type:"pie"}});var GW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createPolarAxis=function(){var e=new EO(this.options.categoryAxis,this.chartService);this.polarAxis=e,this.categoryAxis=e,this.appendAxis(e),this.aggregateCategories(),this.createTrendlineSeries(),this.createCategoryAxesLabels()},t.prototype.valueAxisOptions=function(e){return this._hasBarCharts&&BF(e,{majorGridLines:{type:AH},minorGridLines:{type:AH}}),this._isStacked100&&BF(e,{roundToMajorUnit:!1,labels:{format:"P0"}}),BF(e,this.options.valueAxis)},t.prototype.aggregateCategories=function(){HU.prototype.aggregateCategories.call(this,this.panes)},t.prototype.createCategoryAxesLabels=function(){HU.prototype.createCategoryAxesLabels.call(this,this.panes)},t.prototype.filterSeries=function(e){return e},t.prototype.trendlineFactory=function(e,t){var n=HU.prototype.trendlineFactory.call(this,e,t);return n&&(n.type=HV),n},t.prototype.createCharts=function(){var e=this.filterVisibleSeries(this.series),t=this.panes[0];this.createAreaChart(QN(e,[zV]),t),this.createLineChart(QN(e,[HV]),t),this.createBarChart(QN(e,[PV]),t)},t.prototype.chartOptions=function(e){var t={series:e},n=e[0];if(n){var i=this.filterVisibleSeries(e),r=n.stack;t.isStacked=r&&i.length>1,t.isStacked100=r&&"100%"===r.type&&i.length>1,t.isStacked100&&(this._isStacked100=!0)}return t},t.prototype.createAreaChart=function(e,t){if(0!==e.length){var n=new $W(this,this.chartOptions(e));this.appendChart(n,t)}},t.prototype.createLineChart=function(e,t){if(0!==e.length){var n=new OW(this,this.chartOptions(e));this.appendChart(n,t)}},t.prototype.createBarChart=function(e,t){if(0!==e.length){var n=e[0],i=this.chartOptions(e),r=this.filterVisibleSeries(e),o=r.some((function(e){return e.stack})),a=r.some((function(e){return e.stack&&"100%"===e.stack.type}));i.gap=n.gap,i.spacing=n.spacing,i.defaultStack=n.stack&&r.length>1,i.isStacked=o&&r.length>1,i.isStacked100=a&&r.length>1;var s=new qW(this,i);this.appendChart(s,t),this._hasBarCharts=!0}},t.prototype.seriesCategoryAxis=function(){return this.categoryAxis},t.prototype._dispatchEvent=function(e,t,n){var i=e._eventCoordinates(t),r=new OL(i.x,i.y),o=this.categoryAxis.getCategory(r),a=this.valueAxis.getValue(r);null!==o&&null!==a&&e.trigger(n,{element:vR(t),category:o,value:a})},t.prototype.createCrosshairs=function(){},t.prototype._pointsByVertical=function(t){return e.prototype._pointsByVertical.call(this,t).sort(this._getSeriesCompareFn())},t.prototype._getSeriesCompareFn=function(){return function(e,t){return t.value-e.value}},t}(IW);BF(GW.prototype,nU,{appendChart:HU.prototype.appendChart,aggregateSeries:HU.prototype.aggregateSeries,seriesSourcePoints:HU.prototype.seriesSourcePoints,seriesValues:HU.prototype.seriesValues}),DR(GW,{categoryAxis:{categories:[]},valueAxis:{}});var KW=function(e){function t(t,n,i){e.call(this,n),this.value=t,this.options.index=i.index}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getLabelText=function(e){var t=GF(e);return t?t(this.pointData()):e.format?this.formatValue(e.format):this.value},t.prototype.reflow=function(e){var t=this.points,n=this.children[0],i=Math.min(t[0].x,t[3].x),r=Math.max(t[1].x,t[2].x);this.box=new VL(i,t[0].y,r,t[2].y),n&&n.reflow(new VL(e.x1,t[0].y,e.x2,t[2].y))},t.prototype.createVisual=function(){var t,n=this,i=this.options;e.prototype.createVisual.call(this),this.addAccessibilityAttributesToVisual(),(t=i.visual?i.visual({category:this.category,dataItem:this.dataItem,value:this.value,series:this.series,percentage:this.percentage,points:this.points,options:i,sender:this.getSender(),createVisual:function(){return n.createPath()}}):this.createPath())&&this.visual.append(t)},t.prototype.createPath=function(){var e=this.options,t=e.border;return us.fromPoints(this.points,{fill:KL(e.pattern,{color:e.color,opacity:e.opacity}),stroke:{color:t.color,opacity:t.opacity,width:t.width}}).close()},t.prototype.createHighlight=function(e){return us.fromPoints(this.points,e)},t.prototype.highlightVisual=function(){return this.visual.children[0]},t.prototype.highlightVisualArgs=function(){var e=us.fromPoints(this.points).close();return{options:this.options,path:e}},t.prototype.createFocusHighlight=function(e){var t=this.options.accessibility.highlight.border.width,n=us.fromPoints(this.points,BF({},e,{stroke:{width:2*t}})).close(),i=new hs;return i.paths.push(us.fromRect(this.box.clone().pad(t).toRect())),i.paths.push(us.fromPoints(this.points)),n.clip(i),n},t.prototype.tooltipAnchor=function(){var e=this.box;return{point:new OL(e.center().x,e.y1),align:{horizontal:"center",vertical:"top"}}},t.prototype.formatValue=function(e){return this.owner.formatPointValue(this,e)},t.prototype.pointData=function(){return{dataItem:this.dataItem,category:this.category,value:this.value,series:this.series,percentage:this.percentage}},t.prototype.getIndex=function(){return this.index},t}(qL);DR(KW,{color:mF,border:{width:1},labels:{format:""},accessibility:{role:xN,className:CN,ariaRoleDescription:SN}}),BF(KW.prototype,l$),BF(KW.prototype,T$);var YW=function(e){function t(t,n){e.call(this,n),this.plotArea=t,this.chartService=t.chartService,this.points=[],this.labels=[],this.legendItems=[],this.render()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.formatPointValue=function(e,t){return this.plotArea.chartService.format.auto(t,e.value)},t.prototype.render=function(){var e=this,t=this.options,n=this.plotArea.options.seriesColors;void 0===n&&(n=[]);var i=t.series[0],r=i.data;if(r)for(var o=qN(i),a=o.total,s=o.points,l=0;l<s.length;l++){var c=s[l];if(c){var d=c.fields;FF(i.color)||(i.color=d.color||n[l%n.length]),d=BF({index:l,owner:e,series:i,seriesIx:0,dataItem:r[l],percentage:c.value/a},d,{visible:c.visible});var u=c.valueFields.value,h=e.createSegment(u,d),p=e.createLabel(u,d);h&&p&&h.append(p)}}},t.prototype.evalSegmentOptions=function(e,t,n){var i=n.series;YN(e,{value:t,series:i,dataItem:n.dataItem,index:n.index},{defaults:i._defaults,excluded:["data","content","template","toggle","visual","ariaTemplate","ariaContent"]})},t.prototype.createSegment=function(e,t){var n=BF({},t.series);if(n.pattern=t.pattern||n.pattern,this.evalSegmentOptions(n,e,t),this.createLegendItem(e,n,t),!1!==t.visible){var i=new KW(e,n,t);return Object.assign(i,t),this.append(i),this.points.push(i),i}},t.prototype.createLabel=function(e,t){var n=t.series,i=t.dataItem,r=BF({},this.options.labels,n.labels),o=e;if(r.visible){var a=GF(r),s={dataItem:i,value:e,percentage:t.percentage,category:t.category,series:n};a?o=a(s):r.format&&(o=this.chartService.format.auto(r.format,o)),r.color||(r.color=NR(n.color),r.background||(r.background=n.color)),this.evalSegmentOptions(r,e,t);var l=new sB(o,BF({vAlign:r.position},r),s);return this.labels.push(l),l}},t.prototype.labelPadding=function(){for(var e=this.labels,t={left:0,right:0},n=0;n<e.length;n++){var i=e[n].options.align;if(i!==LH){var r=e[n].box.width();i===XH?t.left=Math.max(t.left,r):t.right=Math.max(t.right,r)}}return t},t.prototype.dynamicSlopeReflow=function(e,t,n){for(var i=this.options,r=this.points,o=r.length,a=r[0],s=a,l=0;l<r.length;l++)r[l].percentage>s.percentage&&(s=r[l]);for(var c=a.percentage/s.percentage*t,d=(t-c)/2,u=0,h=0;h<o;h++){var p=r[h].percentage,f=r[h+1],m=f?f.percentage:p,g=r[h].points=[],v=i.dynamicHeight?n*p:n/o,_=void 0;_=yR(_=p?(t-c*(m/p))/2:m?0:t/2,0,t),g.push(new Go(e.x1+d,e.y1+u)),g.push(new Go(e.x1+t-d,e.y1+u)),g.push(new Go(e.x1+t-_,e.y1+v+u)),g.push(new Go(e.x1+_,e.y1+v+u)),d=_,u+=v+i.segmentSpacing,c=yR(t-2*_,0,t)}},t.prototype.constantSlopeReflow=function(e,t,n){for(var i=this.options,r=this.points,o=r.length,a=i.neckRatio<=1,s=a?i.neckRatio*t:t,l=a?0:(t-t/i.neckRatio)/2,c=((a?t:t-2*l)-s)/2,d=0,u=0;u<o;u++){var h=r[u].points=[],p=r[u].percentage,f=i.dynamicHeight?c*p:c/o,m=i.dynamicHeight?n*p:n/o;h.push(new Go(e.x1+l,e.y1+d)),h.push(new Go(e.x1+t-l,e.y1+d)),h.push(new Go(e.x1+t-l-f,e.y1+m+d)),h.push(new Go(e.x1+l+f,e.y1+m+d)),l+=f,d+=m+i.segmentSpacing}},t.prototype.reflow=function(e){var t=this.points,n=t.length;if(n){var i=this.options,r=e.clone().unpad(this.labelPadding()),o=r.height()-i.segmentSpacing*(n-1),a=r.width();i.dynamicSlope?this.dynamicSlopeReflow(r,a,o):this.constantSlopeReflow(r,a,o);for(var s=0;s<n;s++)t[s].reflow(e)}},t}(qL);DR(YW,{neckRatio:.3,width:300,dynamicSlope:!1,dynamicHeight:!0,segmentSpacing:0,labels:{visible:!1,align:LH,position:LH,zIndex:1}}),BF(YW.prototype,CW);var QW=function(e){function t(t,n){n.dynamicSlope=!1,n.neckRatio=1e6,e.call(this,t,n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(YW),XW=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){this.createChart(YW,QN(this.series,[kV])),this.createChart(QW,QN(this.series,[xV]))},t.prototype.createChart=function(e,t){var n=t[0];if(n){var i=new e(this,{series:t,legend:this.options.legend,neckRatio:n.neckRatio,dynamicHeight:n.dynamicHeight,dynamicSlope:n.dynamicSlope,segmentSpacing:n.segmentSpacing,highlight:n.highlight});this.appendChart(i)}},t.prototype.appendChart=function(t,n){e.prototype.appendChart.call(this,t,n),dR(this.options.legend.data,t.legendItems)},t.prototype._pointsByVertical=function(e){return this.pointsBySeriesIndex(e.series.index)},t.prototype.getPointToTheRight=function(e){return this.getPointBelow(e)},t.prototype.getPointToTheLeft=function(e){return this.getPointAbove(e)},t}(X$),ZW=function(e){function t(t,n){e.call(this),this.options=n,this.color=n.color||mF,this.value=t}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.render=function(){this._rendered||(this._rendered=!0,this.createMarker(),this.createLabel(),this.createNote())},t.prototype.createLabel=function(){var e=this.options.labels;e.visible&&(this.label=this.createLabelElement(e),this.append(this.label))},t.prototype.createLabelElement=function(e){var t=e.color;return t||(t=NR(this.color)),new sB(this.getLabelText(e),BF({align:LH,vAlign:LH,margin:{left:5,right:5},zIndex:SR(e.zIndex,this.series.zIndex)},e,{color:t}),this.pointData())},t.prototype.getLabelText=function(e){var t=GF(e);return t?t(this.pointData()):this.formatValue(e.format)},t.prototype.formatValue=function(e){return this.owner.formatPointValue(this,e)},t.prototype.reflow=function(e){this.render();var t=this.label;this.box=e,t&&t.reflow(this.markerBox()),this.note&&this.note.reflow(e),this.marker.reflow(this.markerBox())},t.prototype.createVisual=function(){e.prototype.createVisual.call(this),this.addAccessibilityAttributesToVisual()},t.prototype.markerBox=function(){var e=this.options.markers,t=e.border,n=this.box.toRect(),i=SR(e.type,"rect")===sF,r=SR(t.width,i?1:0),o=Math.round(r/2);if(e.size){var a=n.center();n.size.width=n.size.height=e.size,n.origin.x=Math.round(a.x-n.size.width/2),n.origin.y=Math.round(a.y-n.size.height/2)}return n.size.width-=r,n.size.height-=r,n.origin.y+=o+.5,n.origin.x+=o+.5,oB(n)},t.prototype.markerBorder=function(){var e=this.options,t=e.markers.border,n=SR(t.opacity,e.opacity);return{color:t.color||this.color,width:t.width,opacity:n,dashType:t.dashType}},t.prototype.createMarker=function(){var e=this.options,t=e.markers,n=new XL({type:SR(t.type,"rect"),width:t.size,height:t.size,rotation:t.rotation,background:this.color,border:this.markerBorder(),pattern:e.pattern,borderRadius:t.borderRadius,opacity:this.series.opacity||e.opacity,zIndex:SR(e.zIndex,this.series.zIndex),animation:e.animation,visual:e.visual},{dataItem:this.dataItem,value:this.value,series:this.series,category:this.category});this.marker=n,this.append(n)},t.prototype.createHighlight=function(e){var t=this.options,n=this.options.highlight.markers||this.options.markers,i=new XL({type:SR(n.type,"rect"),width:n.size,height:n.size,rotation:n.rotation,background:n.color||this.color,border:this.markerBorder(),borderRadius:n.borderRadius,opacity:this.series.opacity||t.opacity,zIndex:SR(t.zIndex,this.series.zIndex)});i.reflow(this.markerBox());var r=i.getElement();return r.options.fill=e.fill,r.options.stroke=e.stroke,r},t.prototype.highlightVisual=function(){return this.rectVisual},t.prototype.highlightVisualArgs=function(){return{options:this.options,rect:this.box.toRect(),visual:this.rectVisual}},t.prototype.createFocusHighlight=function(){var e=this.options.markers,t=this.options.accessibility.highlight,n=new XL({type:SR(e.type,"rect"),width:e.size,height:e.size,rotation:e.rotation,background:t.color,border:t.border,borderRadius:e.borderRadius,padding:t.border.width/2,zIndex:t.zIndex});return n.reflow(this.markerBox()),n.getElement()},t.prototype.tooltipAnchor=function(){var e=this.box.center().x,t=this.box.y1-5;return{point:new OL(e,t),align:{horizontal:LH,vertical:RH}}},t.prototype.overlapsBox=function(e){return this.box.overlaps(e)},t.prototype.unclipElements=function(){},t.prototype.pointData=function(){return{x:this.value.x,y:this.value.y,value:this.value.value,dataItem:this.dataItem,series:this.series}},t}(qL);BF(ZW.prototype,l$),BF(ZW.prototype,c$),BF(ZW.prototype,T$),ZW.prototype.defaults={markers:{type:"rect",borderRadius:4,border:{color:"transparent"}},padding:{top:1},labels:{visible:!1,padding:3},opacity:1,notes:{label:{}},accessibility:{role:xN,className:CN,ariaRoleDescription:SN}};var JW=function(e){function t(t,n){e.call(this,n),this.plotArea=t,this.chartService=t.chartService,this._initFields(),this.render()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._initFields=function(){this.points=[],this.seriesOptions=[],this.valueRange={min:ZH,max:JH},this._evalSeries=[]},t.prototype.render=function(){this.setRange(),this.traverseDataPoints(this.addValue.bind(this))},t.prototype.setRange=function(){for(var e=this,t=this.options.series,n=0;n<t.length;n++)for(var i=t[n],r=0;r<i.data.length;r++){var o=e.plotArea.bindPoint(i,r).valueFields;hR(o.value)&&null!==o.value&&(e.valueRange.min=Math.min(e.valueRange.min,o.value),e.valueRange.max=Math.max(e.valueRange.max,o.value))}},t.prototype.addValue=function(e,t){var n;e&&hR(e.value)&&null!==e.value&&(n=this.createPoint(e,t))&&Object.assign(n,t),this.points.push(n)},t.prototype.evalPointOptions=function(e,t,n){var i=n.series,r=n.seriesIx,o={defaults:i._defaults,excluded:["data","tooltip","content","template","visual","toggle","drilldownSeriesFactory","ariaTemplate","ariaContent"]},a=this._evalSeries[r];hR(a)||(this._evalSeries[r]=a=YN(e,{},o,!0));var s=e;return a&&YN(s=BF({},e),{value:t,series:i,dataItem:n.dataItem,min:this.valueRange.min,max:this.valueRange.max},o),s},t.prototype.pointType=function(){return ZW},t.prototype.pointOptions=function(e,t){var n=this.seriesOptions[t];if(!n){var i=this.pointType().prototype.defaults;this.seriesOptions[t]=n=BF({},i,{markers:{opacity:e.opacity},tooltip:{format:this.options.tooltip.format},labels:{format:this.options.labels.format}},e)}return Object.assign({},n)},t.prototype.createPoint=function(e,t){var n=t.series,i=this.pointOptions(n,t.seriesIx),r=t.color||n.color;if(i.pattern=t.pattern||i.pattern,i=this.evalPointOptions(i,e,t),FF(n.color))r=i.color;else if(0!==this.valueRange.max){var o=function(e,t){void 0===t&&(t=.05);var n=jr(e),i=1-t;return function(e){var t=n.toHSL(),r=100-t.l,o=i-e;return t.l+=Math.min(o*r,r),t.toCss()}}(r);r=o(e.value/this.valueRange.max)}var a=new ZW(e,i);return a.color=r,this.append(a),a},t.prototype.seriesAxes=function(e){var t=e.xAxis,n=e.yAxis,i=this.plotArea,r=t?i.namedXAxes[t]:i.axisX,o=n?i.namedYAxes[n]:i.axisY;if(!r)throw new Error("Unable to locate X axis with name "+t);if(!o)throw new Error("Unable to locate Y axis with name "+n);return{xAxis:r,yAxis:o}},t.prototype.reflow=function(e){var t=this,n=this.points,i=!this.options.clip,r=0;this.traverseDataPoints((function(e,o){var a=n[r++],s=t.seriesAxes(o.series),l=s.xAxis,c=s.yAxis,d=l.categoryIndex(e.x),u=c.categoryIndex(e.y),h=l.getSlot(d,d,i),p=c.getSlot(u,u,i);if(a)if(h&&p){var f=t.pointSlot(h,p);a.reflow(f)}else a.visible=!1})),this.box=e},t.prototype.pointSlot=function(e,t){return new VL(e.x1,t.y1,e.x2,t.y2)},t.prototype.traverseDataPoints=function(e){for(var t=this,n=this.options.series,i=0;i<n.length;i++)for(var r=n[i],o=t.seriesAxes(r),a=o.xAxis,s=o.yAxis,l=a.currentRangeIndices(),c=s.currentRangeIndices(),d=0;d<r.data.length;d++){var u=t.plotArea.bindPoint(r,d),h=u.valueFields,p=u.fields,f=a.totalIndex(h.x),m=s.totalIndex(h.y),g=l.min<=f&&f<=l.max,v=c.min<=m&&m<=c.max;g&&v&&e(h,BF({pointIx:d,series:r,seriesIx:i,dataItem:r.data[d],owner:t},p))}},t.prototype.formatPointValue=function(e,t){var n=e.value;return this.chartService.format.auto(t,n.x,n.y,n.value)},t.prototype.animationPoints=function(){for(var e=this.points,t=[],n=0;n<e.length;n++)t.push((e[n]||{}).marker);return t},t}(qL);DR(JW,{series:[],tooltip:{format:"{0}, {1}: {2}"},labels:{format:"{2}"},clip:!0});var ej=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initFields=function(){this.namedXAxes={},this.namedYAxes={}},t.prototype.render=function(e){void 0===e&&(e=this.panes),this.bindCategories(),this.createAxes(e),this.createCharts(e),this.createAxisLabels()},t.prototype.bindCategories=function(){for(var e=this.srcSeries||this.series,t=0;t<e.length;t++){for(var n=e[t],i=n.data||[],r=this.seriesAxes(n),o=r.xAxis,a=r.yAxis,s=GR(o.categories||[]),l=GR(a.categories||[]),c=0;c<i.length;c++){var d=qO.current.bindPoint(n,c).valueFields,u=d.x,h=d.y;s.has(u)||s.add(u),l.has(h)||l.add(h)}o.categories=s.values(),a.categories=l.values()}},t.prototype.createCharts=function(e){for(var t=this,n=this.groupSeriesByPane(),i=0;i<e.length;i++){var r=e[i],o=n[r.options.name||"default"]||[];t.addToLegend(o);var a=t.filterVisibleSeries(o);a&&t.createHeatmapChart(QN(a,[CV]),r)}},t.prototype.createHeatmapChart=function(e,t){var n=new JW(this,{series:e});this.appendChart(n,t)},t.prototype.seriesPaneName=function(e){var t=this.options,n=e.xAxis,i=ZF([].concat(t.xAxis),(function(e){return e.name===n}))[0],r=e.yAxis,o=ZF([].concat(t.yAxis),(function(e){return e.name===r}))[0],a=(t.panes||[{}])[0].name||"default";return(i||{}).pane||(o||{}).pane||a},t.prototype.seriesAxes=function(e){var t,n,i=this.options,r=[].concat(i.xAxis),o=e.xAxis;t=o?r.find((function(e){return e.name===o})):r[0];var a=[].concat(i.yAxis),s=e.yAxis;if(n=s?a.find((function(e){return e.name===s})):a[0],!t)throw new Error("Unable to locate X axis with name "+o);if(!n)throw new Error("Unable to locate Y axis with name "+s);return{xAxis:t,yAxis:n}},t.prototype.createAxisLabels=function(){for(var e=this.axes,t=0;t<e.length;t++)e[t].createLabels()},t.prototype.createXYAxis=function(e,t,n){for(var i,r=e.name,o=t?this.namedYAxes:this.namedXAxes,a=Object.assign({axisCrossingValue:0},e,{vertical:t,reverse:t||this.chartService.rtl?!e.reverse:e.reverse,justified:!1}),s=a.categories?a.categories[0]:null,l=[a.min,a.max,s],c=this.series,d=0;d<c.length;d++){var u=c[d],h=u[t?"yAxis":"xAxis"];if(h===a.name||0===n&&!h){var p=qO.current.bindPoint(u,0).valueFields;l.push(p[t?"y":"x"]);break}}for(var f=0;f<l.length;f++)if(l[f]instanceof Date){i=!0;break}var m=new(KN(a.type,VH)||!a.type&&i?vO:sO)(a,this.chartService);if(m.axisIndex=n,r){if(o[r])throw new Error((t?"Y":"X")+" axis with name "+r+" is already defined");o[r]=m}return this.appendAxis(m),m.indexCategories(),m},t.prototype.createAxes=function(e){for(var t=this,n=this.options,i=[].concat(n.xAxis),r=[],o=[].concat(n.yAxis),a=[],s=0;s<i.length;s++){tR(t.findPane(i[s].pane),e)&&r.push(t.createXYAxis(i[s],!1,s))}for(var l=0;l<o.length;l++){tR(t.findPane(o[l].pane),e)&&a.push(t.createXYAxis(o[l],!0,l))}this.axisX=this.axisX||r[0],this.axisY=this.axisY||a[0]},t.prototype.removeAxis=function(t){var n=t.options.name;e.prototype.removeAxis.call(this,t),t.options.vertical?delete this.namedYAxes[n]:delete this.namedXAxes[n],t===this.axisX&&delete this.axisX,t===this.axisY&&delete this.axisY},t.prototype._dispatchEvent=function(e,t,n){for(var i=e._eventCoordinates(t),r=new OL(i.x,i.y),o=this.axes,a=o.length,s=[],l=[],c=0;c<a;c++){var d=o[c];UN(d.options.vertical?l:s,d.getCategory(r))}s.length>0&&l.length>0&&e.trigger(n,{element:vR(t),originalEvent:t,x:n$(s),y:n$(l)})},t.prototype.updateAxisOptions=function(e,t){var n=e.options.vertical,i=this.groupAxes(this.panes),r=(n?i.y:i.x).indexOf(e);nj(this.options,r,n,t),nj(this.originalOptions,r,n,t)},t.prototype.crosshairOptions=function(e){return Object.assign({},e.options.crosshair,{zIndex:0})},t.prototype._pointsByVertical=function(e,t){var n=this;void 0===t&&(t=0);var i=this.axisX.options.reverse?-1*t:t,r=this.axisX.children,o=this._getPointAxisXIndex(e)+i,a=r[o=HF(o,r.length)].value,s=this.filterPoints((function(e){return tj(e.pointData().x,a)})).sort((function(e,t){return n._getPointAxisYIndex(e)-n._getPointAxisYIndex(t)}));return this.axisY.options.reverse?s.reverse():s},t.prototype._pointsByHorizontal=function(e,t){var n=this;void 0===t&&(t=0);var i=this.axisY.options.reverse?-1*t:t,r=this.axisY.children,o=this._getPointAxisYIndex(e)+i,a=r[o=HF(o,r.length)].value,s=this.filterPoints((function(e){return tj(e.pointData().y,a)})).sort((function(e,t){return n._getPointAxisXIndex(e)-n._getPointAxisXIndex(t)}));return this.axisX.options.reverse?s.reverse():s},t.prototype._getPointAxisXIndex=function(e){return this._getPointAxisIndex(this.axisX,e.pointData().x)},t.prototype._getPointAxisYIndex=function(e){return this._getPointAxisIndex(this.axisY,e.pointData().y)},t.prototype._getPointAxisIndex=function(e,t){return e.children.findIndex((function(e){return tj(t,e.value)}))},t}(X$);function tj(e,t){return e instanceof Date&&t instanceof Date?eO(e,t):e===t}function nj(e,t,n,i){BF([].concat(n?e.yAxis:e.xAxis)[t],i)}DR(ej,{xAxis:{},yAxis:{}}),BF(ej.prototype,nU);var ij="color",rj="first",oj="max",aj="min",sj="noteText";JU.current.register(HU,[mV,yV,TV,UV,fV,VV,bV,DV,_V,$V,gV,NV,LV,RV,jV,SV,FV,WV].concat(JV)),JU.current.register(_W,[BV,OV,vV].concat(JV)),JU.current.register(DW,[AV]),JU.current.register(EW,[wV]),JU.current.register(XW,[kV,xV]),JU.current.register(BW,[MV,EV,IV].concat(JV)),JU.current.register(GW,[zV,PV,HV].concat(JV)),JU.current.register(ej,[CV]),qO.current.register([mV,yV,TV,UV,fV,VV],[fF],[EN,ij,sj,tV,nV,LN,BN]),qO.current.register([LV,RV,FV,WV],["from","to"],[EN,ij,sj,LN,BN]),qO.current.register([jV,SV],[fF],[EN,ij,sj,"summary",LN,BN]),qO.current.register([MV,EV,IV],[vF,_F],[ij,LN,BN]),qO.current.register([zV,PV,HV],[fF],[EN,ij,LN,BN]),qO.current.register([kV,xV],[fF],[EN,ij,"visibleInLegend","visible",LN,BN]),oU.current.register([mV,yV,TV,UV,fV,VV,jV,SV],{value:oj,color:rj,noteText:rj,errorLow:aj,errorHigh:oj}),oU.current.register([LV,RV,FV,WV],{from:aj,to:oj,color:rj,noteText:rj}),oU.current.register([zV,PV,HV],{value:oj,color:rj}),qO.current.register([BV,OV,vV],[vF,_F],[ij,sj,iV,rV,oV,aV]),qO.current.register([vV],[vF,_F,"size"],[ij,EN,sj,BN]),qO.current.register([CV],[vF,_F,fF],[ij,sj,BN]),qO.current.register([bV,DV],["open","high","low","close"],[EN,ij,"downColor",sj,BN]),oU.current.register([bV,DV],{open:oj,high:oj,low:aj,close:oj,color:rj,downColor:rj,noteText:rj}),qO.current.register([gV,NV],["lower","q1","median","q3","upper","mean","outliers"],[EN,ij,sj,LN,BN]),oU.current.register([gV,NV],{lower:oj,q1:oj,median:oj,q3:oj,upper:oj,mean:oj,outliers:rj,color:rj,noteText:rj}),qO.current.register([_V,$V],["current","target"],[EN,ij,"visibleInLegend",sj,LN,BN]),oU.current.register([_V,$V],{current:oj,target:oj,color:rj,noteText:rj}),qO.current.register([AV,wV],[fF],[EN,ij,"explode","visibleInLegend","visible",LN,BN]);var lj=[EN,fF,vF,_F],cj="mousemove",dj="contextmenu",uj="mouseleave",hj="keydown",pj="focus",fj="blur",mj="k-chart-overlay-top",gj=function(e){function t(t,n,i,r){var o=this;void 0===r&&(r={}),e.call(this),this.observers=[],this.addObserver(r.observer),this.chartService=new yB(this,r),this.chartService.theme=i,this._initElement(t);var a=BF({},this.options,n);this._originalOptions=BF({},a),this._theme=i,this._initTheme(a,i),this._focusState={},this._initHandlers(),this._initSurface(),this.bindCategories(),TR.preloadFonts(n,(function(){o.fontLoaded=!0,o._destroyed||(o.trigger("init"),o._redraw(),o._attachEvents(),o._restoreOverlayElement())}))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._initElement=function(e){this._setElementClass(e),e.style.position="relative",e.tabIndex=e.getAttribute("tabindex")?e.getAttribute("tabindex"):0,e.setAttribute("role","graphics-document document");for(var t=e.childNodes.length-1;t>=0;t--){var n=e.childNodes[t];JF(n,"k-chart-overlay")?this.overlayElement=n:e.removeChild(n)}this.element=e},t.prototype._setElementClass=function(e){CF(e,"k-chart")},t.prototype._restoreOverlayElement=function(){this.overlayElement&&(this._hasSeriesData()?this.overlayElement.style.display="none":(!this.options.title||this.options.title&&this.options.title.position!==RH?CF(this.overlayElement,mj):TF(this.overlayElement,mj),this.overlayElement.style.display=""),this.overlayElement.parentElement!==this.element&&this.element.appendChild(this.overlayElement))},t.prototype._hasSeriesData=function(){var e=this.options.series||[],t=e.length>0&&e.some((function(e){return e.data&&e.data.length>0}));return t},t.prototype._initTheme=function(e,t){for(var n=[],i=e.series||[],r=0;r<i.length;r++)n.push(Object.assign({},i[r]));e.series=n,function(e){for(var t=lj,n=0;n<t.length;n++){var i=t[n]+"Axes";e[i]&&(e[t[n]+"Axis"]=e[i],delete e[i])}}(e),this.applyDefaults(e,t),null===e.seriesColors&&delete e.seriesColors,EF(e.title)&&(e.title={text:e.title}),this.options=BF({},t,e),this.applySeriesColors()},t.prototype.getSize=function(){var e=this.options.chartArea||{};return{width:e.width?parseInt(e.width,10):Math.floor(this.element.offsetWidth),height:e.height?parseInt(e.height,10):Math.floor(this.element.offsetHeight)}},t.prototype.resize=function(e){var t=this.getSize(),n=this._size,i=t.width>0||t.height>0;e||i&&(!n||t.width!==n.width||t.height!==n.height)?(this._size=t,this._resize(t,e),this.trigger("resize",t)):i&&this._selections&&RR(this._selections,(function(e){return!e.visible}))&&(this._destroySelections(),this._setupSelection())},t.prototype._resize=function(){this._noTransitionsRedraw()},t.prototype.redraw=function(e){if(this.applyDefaults(this.options),this.applySeriesColors(),e){var t=this._model._plotArea,n=t.findPane(e);t.redraw(n)}else this._redraw()},t.prototype.getAxis=function(e){return VO(e,this._plotArea.axes)},t.prototype.findAxisByName=function(e){return this.getAxis(e)},t.prototype.findPaneByName=function(e){for(var t=this._plotArea.panes,n=0;n<t.length;n++)if(t[n].options.name===e)return new NO(t[n])},t.prototype.findPaneByIndex=function(e){var t=this._plotArea.panes;if(t[e])return new NO(t[e])},t.prototype.plotArea=function(){return new $O(this._plotArea)},t.prototype.toggleHighlight=function(e,t){var n,i,r,o=this._plotArea,a=(o.srcSeries||o.series||[])[0];FF(t)?n=o.filterPoints(t):(OF(t)?(i=t.series,r=t.category):i=r=t,n=a.type===wV?vj(o.pointsBySeriesName(i),r):tR(a.type,[AV,kV,xV])?vj((o.charts[0]||{}).points,r):o.pointsBySeriesName(i));n&&this.togglePointsHighlight(e,n)},t.prototype.togglePointsHighlight=function(e,t){for(var n=this._highlight,i=0;i<t.length;i++)n.togglePointHighlight(t[i],e)},t.prototype.showTooltip=function(e){var t,n,i=this._sharedTooltip(),r=this._tooltip,o=this._plotArea;if(FF(e)?(t=o.findPoint(e))&&i&&(n=t.categoryIx):i&&hR(e)&&(n=o.categoryAxis.categoryIndex(e)),i){if(n>=0){var a=this._plotArea.pointsByCategoryIndex(n);r.showAt(a)}}else t&&r.show(t)},t.prototype.hideTooltip=function(){this._tooltip.hide()},t.prototype._initSurface=function(){var e=this.surface,t=this._surfaceWrap(),n=this.options.chartArea||{};n.width&&mR(t,{width:n.width}),n.height&&mR(t,{height:n.height}),e&&e.options.type===this.options.renderAs?(this.surface.clear(),this.surface.resize()):(this._destroySurface(),this.surface=vc.create(t,{type:this.options.renderAs}),this.surface.bind("mouseenter",this._surfaceMouseenterHandler),this.surface.bind("mouseleave",this._surfaceMouseleaveHandler)),this.element._kendoExportVisual=this._kendoExportVisual.bind(this)},t.prototype._surfaceWrap=function(){return this.element},t.prototype._redraw=function(){var e=this._getModel();this._size={width:e.options.width,height:e.options.height},this._destroyView(),this._setElementAccessibilityAttributes(),this._model=e,this._plotArea=e._plotArea,this._legend=e._legend,e.renderVisual(),!1!==this.options.transitions&&e.traverse((function(e){e.animation&&e.animation.setup()})),this._initSurface(),this.surface.draw(e.visual),!1!==this.options.transitions&&e.traverse((function(e){e.animation&&e.animation.play()})),this._tooltip=this._createTooltip(),this._highlight=new LU,this._setupSelection(),this._createPannable(),this._createZoomSelection(),this._createMousewheelZoom(),this._setComputedStyles(),this.trigger(bN),kj(this._plotArea.panes),this._navState||this._cancelDomEvents(),this._redrawFocusHighlight()},t.prototype._setComputedStyles=function(){var e=this.titleHeight();this.element.style.setProperty("--kendo-chart-computed-title-height",e+"px")},t.prototype._redrawFocusHighlight=function(){if(!this._destroyed){var e=this._focusState,t=e.legendInFocus,n=e.preserveHighlight;t&&n&&(this._focusElement(this._getFocusedLegendItem(),!1),this._focusState.preserveHighlight=!1)}},t.prototype._setElementAccessibilityAttributes=function(){var e=this.options.title,t=EF(e)?e:e.description||e.text;t&&this.element.setAttribute("aria-roledescription",t)},t.prototype._kendoExportVisual=function(e){if(e&&e.width&&e.height){var t=this._originalOptions.chartArea||{},n={width:t.width||e.width,height:t.height||e.height};return this.exportVisual(n)}return this.exportVisual()},t.prototype.exportVisual=function(e){var t;if(e&&(e.width||e.height||e.options)){var n=this.options,i=BF({},e.options,{chartArea:{width:e.width,height:e.height}});wj(this._originalOptions,i),this.options=BF({},this._originalOptions,i),this._initTheme(this.options,this._theme),this.bindCategories();var r=this._getModel();r.renderVisual(),kj(r._plotArea.panes),t=r.visual,this.options=n}else t=this.surface.exportVisual();return t},t.prototype._sharedTooltip=function(){return this._plotArea instanceof HU&&this.options.tooltip&&this.options.tooltip.shared},t.prototype._createPannable=function(){var e=this.options;!1!==e.pannable&&(this._pannable=new NU(this._plotArea,e.pannable))},t.prototype._createZoomSelection=function(){var e=this.options.zoomable,t=(e||{}).selection;!1!==e&&!1!==t&&(this._zoomSelection=new $U(this,t))},t.prototype._createMousewheelZoom=function(){var e=this.options.zoomable,t=(e||{}).mousewheel;!1!==e&&!1!==t&&(this._mousewheelZoom=new UU(this,t))},t.prototype._toggleDragZoomEvents=function(){var e=this.options.pannable,t=this.options.zoomable,n=(t||{}).selection,i=(t||{}).mousewheel,r=!(e||!1!==t&&!1!==n||this.requiresHandlers([hN,dN,uN])),o=(!1===t||!1===i)&&!this.requiresHandlers([pN,fN,mN]),a=this.element;this._dragZoomEnabled&&r&&o?(a.style.touchAction=this._touchAction||"",this._dragZoomEnabled=!1):this._dragZoomEnabled||r&&o||(a.style.touchAction="none",this._dragZoomEnabled=!0),this._toggleDomEvents(!r,!o)},t.prototype._toggleDomEvents=function(e,t){var n=this.domEvents;n&&(n.toggleDrag&&n.toggleDrag(e),n.toggleZoom&&n.toggleZoom(t))},t.prototype._createTooltip=function(){var e=this.options.tooltip;return this._sharedTooltip()?this._createSharedTooltip(e):new iW(this.chartService,e)},t.prototype._createSharedTooltip=function(e){return new rW(this._plotArea,e)},t.prototype.applyDefaults=function(e,t){!function(e,t){var n,i,r,o=(t||{}).axisDefaults||{};function a(e){var t=(e||{}).color||i.color,r=BF({},o,o[n],i,i[n],{line:{color:t},labels:{color:t},title:{color:t}},e);return delete r[n],r}for(var s=0;s<lj.length;s++)n=lj[s]+"Axis",i=e.axisDefaults||{},r=(r=[].concat(e[n])).map(a),e[n]=r.length>1?r:r[0]}(e,t),function(e,t){var n=e.series,i=n.length,r=e.seriesDefaults,o=BF({},e.seriesDefaults),a=t?BF({},t.seriesDefaults):{},s=BF({},a);_j(o),_j(s);for(var l=0;l<i;l++){var c=n[l].type||e.seriesDefaults.type,d=BF({data:[]},s,a[c],{tooltip:e.tooltip},o,r[c]);n[l]._defaults=d,n[l]=BF({},d,n[l]),n[l].data=n[l].data||[]}}(e,t)},t.prototype.applySeriesColors=function(){for(var e=this.options,t=e.series,n=e.seriesColors||[],i=0;i<t.length;i++){var r=t[i],o=n[i%n.length],a=r._defaults;r.color=r.color||o,a&&(a.color=a.color||o)}},t.prototype._getModel=function(){var e=this.options,t=this._createPlotArea(),n=new tB(this._modelOptions());n.chart=this,n._plotArea=t;var i=lB.buildTitle(e.title),r=lB.buildTitle(e.subtitle,{align:e.title.align,position:e.title.position});if(n.append.apply(n,lB.orderTitles([i,r])),e.legend&&e.legend.visible){var o=new ZU(t.options.legend,this.chartService);n.append(o),n._legend=o}return n.append(t),n.reflow(),this._setTitleBox(i,r),n},t.prototype._setTitleBox=function(e,t){if(e||t){this._titleBox=(e||t).box.clone();var n=e?e.options.position:"",i=t?t.options.position:"",r=i!==RH;n===i&&t?this._titleBox.wrap(t.box):e&&t&&r&&(this._titleBox=t.box.clone())}},t.prototype._modelOptions=function(){var e=this.options,t=this.getSize();return BF({transitions:e.transitions,width:t.width||UH,height:t.height||400},e.chartArea)},t.prototype._createPlotArea=function(e){var t=this.options;return JU.current.create(e?[]:t.series,t,this.chartService)},t.prototype._setupSelection=function(){for(var e=this._plotArea.axes,t=this._selections=[],n=0;n<e.length;n++){var i=e[n],r=i.options;if(i instanceof sO&&r.select&&!r.vertical){var o=i.range(),a=new nW(this,i,BF({min:o.min,max:o.max},r.select));t.push(a)}}},t.prototype._selectStart=function(e){return this.trigger(gN,e)},t.prototype._select=function(e){return this.trigger(vN,e)},t.prototype._selectEnd=function(e){return this.trigger(_N,e)},t.prototype._initHandlers=function(){this._clickHandler=this._click.bind(this),this._keydownHandler=this._keydown.bind(this),this._focusHandler=this._focus.bind(this),this._blurHandler=this._blur.bind(this),this._mousedownHandler=this._mousedown.bind(this),this._mousewheelHandler=this._mousewheel.bind(this),this._mouseleaveHandler=this._mouseleave.bind(this),this._surfaceMouseenterHandler=this._mouseover.bind(this),this._surfaceMouseleaveHandler=this._mouseout.bind(this),this._mousemove=Pr(this._mousemove.bind(this),20)},t.prototype.addObserver=function(e){e&&this.observers.push(e)},t.prototype.removeObserver=function(e){var t=this.observers.indexOf(e);t>=0&&this.observers.splice(t,1)},t.prototype.requiresHandlers=function(e){for(var t=this.observers,n=0;n<t.length;n++)if(t[n].requiresHandlers(e))return!0},t.prototype.trigger=function(e,t){void 0===t&&(t={}),t.sender=this,e===yN?t.anchor.point=this._toDocumentCoordinates(t.anchor.point):e===oN?this._updateDrilldownPoint(t.point):e===aN?this._resetDrilldownPoint():e===iN?(this._focusPoint(t.point),this._startDrilldown(t.point)):e===eN&&this._focusLegendItem(t);for(var n=this.observers,i=!1,r=0;r<n.length;r++)n[r].trigger(e,t)&&(i=!0);return i},t.prototype.titleHeight=function(){return this._titleBox?this._titleBox.height():0},t.prototype._attachEvents=function(){var e,t,n=this.element;this._touchAction=n.style.touchAction,uR(n,((e={})[dj]=this._clickHandler,e[HN]=this._mousewheelHandler,e[uj]=this._mouseleaveHandler,e[hj]=this._keydownHandler,e.mousedown=this._mousedownHandler,e[pj]=this._focusHandler,e[fj]=this._blurHandler,e)),this._shouldAttachMouseMove()&&uR(n,((t={})[cj]=this._mousemove,t)),this.domEvents=kB.create(this.element,{start:this._start.bind(this),move:this._move.bind(this),end:this._end.bind(this),tap:this._tap.bind(this),gesturestart:this._gesturestart.bind(this),gesturechange:this._gesturechange.bind(this),gestureend:this._gestureend.bind(this)}),this._toggleDragZoomEvents()},t.prototype._mouseleave=function(e){this._hoveredPoint&&(this._hoveredPoint.out(this,e),this._hoveredPoint=null),this._plotAreaHovered&&(this._plotAreaHovered=!1,this.trigger(cN)),this._hasInactiveOpacity()&&this._activeChartInstance&&(this._applySeriesOpacity(this._activeChartInstance.children,null,!0),this._updateSeriesOpacity(null,!0))},t.prototype._cancelDomEvents=function(){this.domEvents&&this.domEvents.cancel&&this.domEvents.cancel()},t.prototype._gesturestart=function(e){this._mousewheelZoom&&!this._stopChartHandlers(e)&&(this._gestureDistance=e.distance,this._unsetActivePoint(),this._clearFocusedElement(),this.surface.suspendTracking())},t.prototype._gestureend=function(e){this._zooming&&!this._stopChartHandlers(e)&&(this.surface&&this.surface.resumeTracking(),this._zooming=!1,this.trigger(mN,{}))},t.prototype._gesturechange=function(e){var t=this._mousewheelZoom;if(t&&!this._stopChartHandlers(e)){e.preventDefault();var n=this._gestureDistance,i=-e.distance/n+1;if(Math.abs(i)>=.1){i=Math.round(10*i),this._gestureDistance=e.distance;var r={delta:i,axisRanges:bj(this._plotArea.axes),originalEvent:e};if(this._zooming||!this.trigger(pN,r)){var o=this._eventCoordinates(e);this._zooming||(this._zooming=!0),(r.axisRanges=t.updateRanges(i,o))&&!this.trigger(fN,r)&&t.zoom()}}}},t.prototype._mouseout=function(e){if(e.element){var t=this._drawingChartElement(e.element,e);t&&t.leave&&t.leave(this,e.originalEvent)}},t.prototype._start=function(e){var t=this._eventCoordinates(e);!this._stopChartHandlers(e)&&this._plotArea.backgroundContainsPoint(t)&&(this.requiresHandlers([hN,dN,uN])&&this._startNavigation(e,t,hN),this._pannable&&this._pannable.start(e)&&(this.surface.suspendTracking(),this._unsetActivePoint(),this._clearFocusedElement(),this._suppressHover=!0,this.chartService.panning=!0),this._zoomSelection&&this._zoomSelection.start(e)&&this.trigger(pN,{axisRanges:bj(this._plotArea.axes),originalEvent:e}))},t.prototype._move=function(e){var t=this._navState,n=this._pannable;if(!this._stopChartHandlers(e)){if(n){var i=n.move(e);i&&!this.trigger(dN,{axisRanges:i,originalEvent:e})&&n.pan()}else if(t){for(var r={},o=t.axes,a=0;a<o.length;a++){var s=o[a];if(s.options.name){var l=s.options.vertical?e.y:e.x,c=l.startLocation-l.location;0!==c&&(r[s.options.name]=s.translateRange(c))}}t.axisRanges=r,this.trigger(dN,{axisRanges:r,originalEvent:e})}this._zoomSelection&&this._zoomSelection.move(e)}},t.prototype._end=function(e){if(!this._stopChartHandlers(e)){var t=this._pannable;if(t&&t.end(e)?(this.surface.resumeTracking(),this.trigger(uN,{axisRanges:bj(this._plotArea.axes),originalEvent:e}),this._suppressHover=!1,this.chartService.panning=!1):this._endNavigation(e,uN),this._zoomSelection){var n=this._zoomSelection.end(e);n&&!this.trigger(fN,{axisRanges:n,originalEvent:e})&&(this._zoomSelection.zoom(),this.trigger(mN,{axisRanges:n,originalEvent:e}))}}},t.prototype._stopChartHandlers=function(e){var t=this._selections||[];if(!t.length)return!1;var n=this._eventCoordinates(e),i=this._plotArea.paneByPoint(n);if(i)for(var r=0;r<t.length;r++)if(t[r].onPane(i))return!0},t.prototype._mousewheelZoomRate=function(){var e=(this.options.zoomable||{}).mousewheel||{};return SR(e.rate,.3)},t.prototype._mousewheel=function(e){var t=this,n=lR(e),i=this._mousewheelZoom,r=this._eventCoordinates(e);if(!this._stopChartHandlers(e)&&this._plotArea.backgroundContainsPoint(r))if(i){var o={delta:n,axisRanges:bj(this._plotArea.axes),originalEvent:e};!this._zooming&&this.trigger(pN,o)||(e.preventDefault(),this._zooming||(this._unsetActivePoint(),this._clearFocusedElement(),this.surface.suspendTracking(),this._zooming=!0),this._mwTimeout&&clearTimeout(this._mwTimeout),o.axisRanges=i.updateRanges(n,r),o.axisRanges&&!this.trigger(fN,o)&&i.zoom(),this._mwTimeout=setTimeout((function(){t.trigger(mN,o),t._zooming=!1,t.surface&&t.surface.resumeTracking()}),FN))}else{var a=this._navState;if(!a)this._startNavigation(e,r,pN)||(a=this._navState);if(a){var s=a.totalDelta||n;a.totalDelta=s+n;for(var l=this._navState.axes,c={},d=0;d<l.length;d++){var u=l[d],h=u.options.name;h&&(c[h]=u.scaleRange(-s*t._mousewheelZoomRate(),r))}this.trigger(fN,{delta:n,axisRanges:c,originalEvent:e}),this._mwTimeout&&clearTimeout(this._mwTimeout),this._mwTimeout=setTimeout((function(){t._endNavigation(e,mN)}),FN)}}},t.prototype._startNavigation=function(e,t,n){var i=this._model._plotArea,r=i.findPointPane(t),o=i.axes.slice(0);if(r){var a=bj(o);this.trigger(n,{axisRanges:a,originalEvent:e})?this._cancelDomEvents():(this._suppressHover=!0,this._unsetActivePoint(),this._clearFocusedElement(),this._navState={axisRanges:a,pane:r,axes:o})}},t.prototype._endNavigation=function(e,t){this._navState&&(this.trigger(t,{axisRanges:this._navState.axisRanges,originalEvent:e}),this._suppressHover=!1,this._navState=null)},t.prototype._getChartElement=function(e,t){var n=this.surface.eventTarget(e);if(n)return this._drawingChartElement(n,e,t)},t.prototype._drawingChartElement=function(e,t,n){for(var i,r=e;r&&!i;)i=r.chartElement,r=r.parent;if(i)return i.aliasFor&&(i=i.aliasFor(t,this._eventCoordinates(t))),n&&(i=i.closest(n))&&i.aliasFor&&(i=i.aliasFor()),i},t.prototype._eventCoordinates=function(e){var t=gR(e);return this._toModelCoordinates(t.x,t.y)},t.prototype._elementPadding=function(){if(!this._padding){var e=UF(this.element,["paddingLeft","paddingTop"]),t=e.paddingLeft,n=e.paddingTop;this._padding={top:n,left:t}}return this._padding},t.prototype._toDocumentCoordinates=function(e){var t=this._elementPadding(),n=fR(this.element);return{left:xR(e.x+t.left+n.left),top:xR(e.y+t.top+n.top)}},t.prototype._toModelCoordinates=function(e,t){var n=this.element,i=fR(n),r=this._elementPadding(),o=VR(n).invert(),a=new Go(e-i.left-r.left,t-i.top-r.top).transform(o);return new OL(a.x,a.y)},t.prototype._tap=function(e){var t=this,n=this.surface.eventTarget(e),i=this._drawingChartElement(n,e),r=this._sharedTooltip();this._startHover(n,e)||r||this._unsetActivePoint(),r&&this._trackSharedTooltip(this._eventCoordinates(e),e,!0),this._propagateClick(i,e),this.handlingTap=!0,setTimeout((function(){t.handlingTap=!1}),0)},t.prototype._click=function(e){var t=this._getChartElement(e);this._propagateClick(t,e)},t.prototype._propagateClick=function(e,t){for(var n=e;n;)n.click&&n.click(this,t),n=n.parent},t.prototype._isLegendBeforeChart=function(){var e=this.options.legend.position,t=this._legend;return t&&t.hasItems()&&(e===dF||e===XH)},t.prototype._focus=function(){this._preventInitialPointFocus||(this._isLegendBeforeChart()?this._focusFirstLegendItem():this._focusFirstPoint()),this._preventInitialPointFocus=!1},t.prototype._keydown=function(e){var t=this._focusState,n=t.legendInFocus,i=t.focusedElement,r=this._legend;if("Tab"===e.key){this._clearFocusedElement();var o=this._isLegendBeforeChart();n&&o!==e.shiftKey?this._navigatePoints(e):!n&&o===e.shiftKey&&r.hasItems()&&this._navigateLegend(e)}else e.key===qH?(i&&e.stopPropagation(),this._tooltip&&this._tooltip.visible?this._hideTooltip():this._blur()):e.key===jH?i&&(this._focusState.preserveHighlight=!0,this._propagateClick(i,e),this._focusElement(i)):n?this._navigateLegend(e):this._navigatePoints(e)},t.prototype._navigatePoints=function(e){var t=this,n=this._focusState,i=this._plotArea;if(n.legendInFocus=!1,!n.focusedElement)return this._focusFirstPoint(),void e.preventDefault();var r=function(i){n.focusedPoint=i,t._focusElement(n.focusedPoint),t._displayTooltip(i),e.preventDefault()};switch(e.key){case zH:r(i.getPointToTheRight(n.focusedPoint));break;case IH:r(i.getPointToTheLeft(n.focusedPoint));break;case EH:r(i.getPointBelow(n.focusedPoint));break;case MH:r(i.getPointAbove(n.focusedPoint))}},t.prototype._navigateLegend=function(e){var t=this,n=this,i=n._focusState,r=n._legend,o=n.chartService.rtl;if(i.legendInFocus=!0,!i.focusedElement)return this._focusFirstLegendItem(),void e.preventDefault();var a=r.getItems().length,s=function(n){i.focusedLegendItemIndex=n(i.focusedLegendItemIndex,a),t._focusElement(t._getFocusedLegendItem()),e.preventDefault()};switch(e.key){case MH:case IH:s(o?zF:PF);break;case EH:case zH:s(o?PF:zF)}},t.prototype._focusFirstPoint=function(){var e=this._focusState.focusedPoint=this._plotArea.getFirstPoint();e&&(this._focusElement(e),this._displayTooltip(e))},t.prototype._hasFocus=function(){return this.element.ownerDocument.activeElement===this.element},t.prototype._mousedown=function(){this._hasFocus()||(this._preventInitialPointFocus=!0)},t.prototype._focusChart=function(){this._hasFocus()||(this._preventInitialPointFocus=!0,this.element.focus())},t.prototype._focusPoint=function(e){this._focusState.focusedPoint=e,this._focusChart(),this._focusElement(e,!0)},t.prototype._focusFirstLegendItem=function(){var e=this._focusState;e.focusedLegendItemIndex=0,this._focusElement(this._getFocusedLegendItem()),e.legendInFocus=!0,this._hideTooltip()},t.prototype._focusLegendItem=function(e){var t=this._focusState;t.focusedLegendItemIndex=this._legend.getItems().findIndex((function(t){return t.options.series.index===e.seriesIndex&&t.options.pointIndex===e.pointIndex})),t.legendInFocus=!0,this._focusChart(),this._focusElement(this._getFocusedLegendItem(),!0)},t.prototype._getFocusedLegendItem=function(){var e=this._focusState;return this._legend.getItems()[e.focusedLegendItemIndex]},t.prototype._focusElement=function(e,t){var n=this._focusState;if(this._clearFocusedElement(),e&&(n.focusedElement=e,this._setElementActiveDescendant(e),!t))if(e.focusVisual(),n.legendInFocus){var i=e.options;this._showSeriesInactiveOpacity(i.series.index,i.pointIndex)}else this._showInactiveOpacity(e)},t.prototype._clearFocusedElement=function(){var e=this._focusState;e&&(e.focusedElement&&(e.focusedElement.clearFocusFromVisual(),this._clearElementActiveDescendant()),e.focusedElement=null)},t.prototype._setElementActiveDescendant=function(e){"canvas"===this.options.renderAs&&(this._pseudoFocusedElement=this._createPseudoFocusedElement(e),this.element.append(this._pseudoFocusedElement)),this.element.setAttribute(PH,e._id)},t.prototype._clearElementActiveDescendant=function(){this._pseudoFocusedElement&&(this._pseudoFocusedElement.remove(),this._pseudoFocusedElement=null),this.element.removeAttribute(PH)},t.prototype._createPseudoFocusedElement=function(e){var t=document.createElement("div"),n=e.options.accessibility;t.id=e._id,t.setAttribute("aria-label",e.getAriaLabelText()),t.setAttribute("role",n.role),t.setAttribute("aria-roledescription",n.ariaRoleDescription);var i=n.ariaChecked;return hR(i)&&t.setAttribute("aria-checked",i),t},t.prototype._blur=function(){this._focusState.legendInFocus=!1,this._clearFocusedElement(),this._hideInactiveOpacity()},t.prototype._startHover=function(e,t){if(this._suppressHover)return!1;var n=this._drawingChartElement(e,t,(function(e){return(e.hover||e.over)&&!(e instanceof X$)})),i=this._activePoint;return this._updateHoveredPoint(n,t),n&&i!==n&&n.hover&&(this._activePoint=n,this._sharedTooltip()||n.hover(this,t)||(this._displayTooltip(n),this._showInactiveOpacity(n))),n},t.prototype._displayTooltip=function(e){BF({},this.options.tooltip,e.options.tooltip).visible&&(this._sharedTooltip()&&e.box?this._trackSharedTooltip(e.box.center(),{}):this._tooltip.show(e))},t.prototype._hideTooltip=function(){this._tooltip&&this._tooltip.hide()},t.prototype._displayInactiveOpacity=function(e,t,n){var i=this._activeChartInstance=this._chartInstanceFromPoint(e);if(i)if(t)this._updateSeriesOpacity(e),this._applySeriesOpacity(i.children,null,!0),this._applySeriesOpacity(i.children,e.series),this._highlight.show(n||e);else{var r;if(!i.supportsPointInactiveOpacity())return void this._highlight.show(e);(r=this._getInactivePoints(e,i))&&r.length&&this._highlight.show(r,1-this._getInactiveOpacityForSeries(e.series))}},t.prototype._getInactivePoints=function(e,t){return this._getAllPointsOfType(t,e.constructor).filter((function(t){return t!==e}))},t.prototype._getAllPointsOfType=function(e,t){for(var n=[],i=0;i<e.children.length;i++){var r=e.children[i];r.constructor===t?n.push(r):r.children&&r.children.length&&(n=n.concat(this._getAllPointsOfType(r,t)))}return n},t.prototype._updateHoveredPoint=function(e,t){var n=this._hoveredPoint;n&&n!==e&&(n.out(this,t),this._hoveredPoint=null),e&&n!==e&&e.over&&(this._hoveredPoint=e,e.over(this,t))},t.prototype._updateDrilldownPoint=function(e){e&&e.series&&(qO.current.bindPoint(e.series,null,e.dataItem).fields.drilldown&&(this._drilldownState={cursor:this.element.style.cursor},this.element.style.cursor="pointer"))},t.prototype._resetDrilldownPoint=function(){this._drilldownState&&(this.element.style.cursor=this._drilldownState.cursor,this._drilldownState=null)},t.prototype._startDrilldown=function(e){if(e&&e.series){var t=e.series,n=qO.current.bindPoint(t,null,e.dataItem).fields.drilldown;if(n){var i={series:t,point:e,value:n,sender:this};this.trigger(RN,i)}}},t.prototype._updateSeriesOpacity=function(e,t){for(var n=this._plotArea,i=n.series.length,r=0;r<i;r++){var o=n.series[r],a=this._getDefaultOpacityForSeries(o),s=this._getInactiveOpacityForSeries(o);t||o===e.series?(o.opacity=a,o.line&&(o.line.opacity=a)):(o.defaultOpacity=a,o.opacity=s,o.line&&(o.line.opacity=s))}},t.prototype._applySeriesOpacity=function(e,t,n,i){for(var r=0;r<e.length;r++){var o=e[r],a=o.series||i;if(a&&(a.highlight||{}).visible&&o.visual){var s=i?i.opacity:o.series.opacity;(a!==t||n)&&o.visual.opacity(n?1:s)}o.children&&o.children.length&&this._applySeriesOpacity(o.children,t,n,o.series)}},t.prototype._chartInstanceFromPoint=function(e){for(var t=e.parent;t&&!t.plotArea;)t=t.parent;return t},t.prototype._showInactiveOpacity=function(e){var t=this._plotArea.series.length>1;this._hasInactiveOpacity()?this._displayInactiveOpacity(e,t):this._highlight.show(e)},t.prototype._hideInactiveOpacity=function(e){var t=this._plotArea.series.length>1;this._hasInactiveOpacity()&&(t&&this._activeChartInstance&&(this._updateSeriesOpacity(e,!0),this._applySeriesOpacity(this._activeChartInstance.children,null,!0),this._activeChartInstance=null),this._highlight&&this._highlight.hide(),this._activePoint=null)},t.prototype._hasInactiveOpacity=function(){var e=void 0!==this.options.seriesDefaults.highlight.inactiveOpacity,t=this.options.series.filter((function(e){return void 0!==e.highlight.inactiveOpacity})).length>0;return e||t},t.prototype._getInactiveOpacityForSeries=function(e){var t=this.options.seriesDefaults.highlight.inactiveOpacity;return e.highlight.inactiveOpacity||t||e.opacity||1},t.prototype._getDefaultOpacityForSeries=function(e){return e.defaultOpacity||e.opacity||1},t.prototype._mouseover=function(e){var t,n=this._startHover(e.element,e.originalEvent);n&&n.tooltipTracking&&!this._mouseMoveTrackHandler&&!this._sharedTooltip()&&(this._mouseMoveTrackHandler=this._mouseMoveTracking.bind(this),uR(document,((t={})[cj]=this._mouseMoveTrackHandler,t)))},t.prototype._mouseMoveTracking=function(e){var t,n=this,i=n.options,r=n._tooltip,o=n._highlight,a=n._activePoint,s=this._eventCoordinates(e);if(this._plotArea.box.containsPoint(s)){if(a&&a.tooltipTracking&&a.series&&a.parent.getNearestPoint){var l=a.parent.getNearestPoint(s.x,s.y,a.seriesIx);if(l&&l!==a)if(this._activePoint=l,!l.hover(this,e))BF({},i.tooltip,l.options.tooltip).visible&&r.show(l),o.show(l)}}else CR(document,((t={})[cj]=this._mouseMoveTrackHandler,t)),this._unsetActivePoint(),this._clearFocusedElement(),this._mouseMoveTrackHandler=null,this._hideInactiveOpacity(a)},t.prototype._mousemove=function(e){var t=this._eventCoordinates(e),n=this._plotArea;if(this._trackCrosshairs(t),n.hover){var i=n.backgroundContainsPoint(t);i?(this._plotAreaHovered=!0,this._plotArea.hover(this,e)):this._plotAreaHovered&&!i&&(this._plotAreaHovered=!1,this.trigger(cN))}this._sharedTooltip()&&this._trackSharedTooltip(t,e)},t.prototype._trackCrosshairs=function(e){for(var t=this._plotArea.crosshairs,n=0;n<t.length;n++){var i=t[n];i.box.containsPoint(e)?i.showAt(e):i.hide()}},t.prototype._trackSharedTooltip=function(e,t,n){if(!this._suppressHover){var i=this,r=i.options.tooltip,o=i._plotArea,a=i._plotArea.categoryAxis,s=i._tooltip,l=i._highlight;if(o.backgroundContainsPoint(e)){var c=a.pointCategoryIndex(e);if(c!==this._tooltipCategoryIx||!this._sharedHighlight&&n){var d=o.pointsByCategoryIndex(c),u=d.map((function(e){return e.eventArgs(t)})),h=u[0]||{};h.categoryPoints=u,d.length>0&&!this.trigger(rN,h)?(r.visible&&s.showAt(d,e),l.show(d),this._sharedHighlight=!0):s.hide(),this._tooltipCategoryIx=c}else n&&this._sharedHighlight&&(l.hide(),s.hide(),this._sharedHighlight=!1)}else this._sharedHighlight&&(l.hide(),s.hide(),this._tooltipCategoryIx=null,this._sharedHighlight=!1)}},t.prototype.hideElements=function(e){var t=this._plotArea;this._mousemove.cancel(),t.hideCrosshairs(),this._unsetActivePoint(e)},t.prototype._unsetActivePoint=function(e){var t=this._highlight;this._activePoint=null,this._hoveredPoint=null,e&&e.keepTooltipOpen||this._hideTooltip(),this._tooltipCategoryIx=null,this._sharedHighlight=!1,t&&t.hide()},t.prototype._deferRedraw=function(){this._redraw()},t.prototype._clearRedrawTimeout=function(){this._redrawTimeout&&(clearInterval(this._redrawTimeout),this._redrawTimeout=null)},t.prototype.bindCategories=function(){for(var e=this.options,t=[].concat(e.categoryAxis),n=0;n<t.length;n++){var i=t[n];!1!==i.autoBind&&this.bindCategoryAxisFromSeries(i,n)}},t.prototype.bindCategoryAxisFromSeries=function(e,t){var n=this,i=new Set,r=this.options.series.filter((function(n){return n.categoryAxis===e.name||!n.categoryAxis&&0===t})),o=r.some((function(e){return Boolean(e.categoryField)})),a=r.filter((function(e){return e.data&&e.data.length>0})),s=a.map((function(e){return qO.current.bindPoint(e,0).fields.category})),l=s.reduce((function(t,n){return t||t$(e,n)}),!1);if(a.filter((function(e,t){return e.categoryField||hR(s[t])})).forEach((function(e){return e.data.forEach((function(t,r){var o=qO.current.bindPoint(e,r).fields.category;if(l){var a=ZN(o,t,n.chartService.intl);o=a?a.getTime():void 0}i.add(o)}))})),i.size>0){var c=Array.from(i.values());l&&(c=c.sort().map((function(e){return e&&new Date(e)}))),e.categories=c}else o&&(e.categories=[])},t.prototype._isBindable=function(e){for(var t=qO.current.valueFields(e),n=!0,i=0;i<t.length;i++){var r=t[i];if(r===fF?r="field":r+="Field",!hR(e[r])){n=!1;break}}return n},t.prototype._noTransitionsRedraw=function(){var e,t=this.options;!1!==t.transitions&&(t.transitions=!1,e=!0),this._redraw(),e&&(t.transitions=!0)},t.prototype._legendItemHover=function(e,t){this._showSeriesInactiveOpacity(e,t)},t.prototype._showSeriesInactiveOpacity=function(e,t){var n,i=this._plotArea,r=this._highlight,o=(i.srcSeries||i.series)[e];if(n=tR(o.type,[AV,wV,kV,xV])?i.findPoint((function(n){return n.series.index===e&&n.index===t})):i.pointsBySeriesIndex(e),this._hasInactiveOpacity()&&o.visible&&n){var a=i.series.length>1,s=n.length?n[0]:n;this._displayInactiveOpacity(s,a,n)}else r.show(n)},t.prototype._shouldAttachMouseMove=function(){return this._plotArea.crosshairs.length||this._tooltip&&this._sharedTooltip()||this.requiresHandlers([lN,cN])},t.prototype.updateMouseMoveHandler=function(){var e,t;CR(this.element,((e={})[cj]=this._mousemove,e)),this._shouldAttachMouseMove()&&uR(this.element,((t={})[cj]=this._mousemove,t))},t.prototype.applyOptions=function(e,t){wj(this._originalOptions,e),this._originalOptions=BF(this._originalOptions,e),this.options=BF({},this._originalOptions),t&&(this._theme=t,this.chartService.theme=t),this._initTheme(this.options,this._theme),this._toggleDragZoomEvents()},t.prototype.setOptions=function(e,t){this.applyOptions(e,t),this.bindCategories(),this.redraw(),this.updateMouseMoveHandler(),this._restoreOverlayElement()},t.prototype.setDirection=function(e){this.chartService.rtl=Boolean(e),this.surface&&"svg"===this.surface.type&&this._destroySurface()},t.prototype.setIntlService=function(e){this.chartService.intl=e},t.prototype.noTransitionsRedraw=function(){this._noTransitionsRedraw()},t.prototype.destroy=function(){var e,t;this._destroyed=!0,CR(this.element,((e={})[dj]=this._clickHandler,e[HN]=this._mousewheelHandler,e[cj]=this._mousemove,e[uj]=this._mouseleaveHandler,e[hj]=this._keydownHandler,e[pj]=this._focusHandler,e[fj]=this._blurHandler,e)),this.domEvents&&(this.domEvents.destroy(),delete this.domEvents),this._mouseMoveTrackHandler&&CR(document,((t={})[cj]=this._mouseMoveTrackHandler,t)),this._focusState=null,this._destroyView(),this._destroySurface(),this._clearRedrawTimeout()},t.prototype._destroySurface=function(){var e=this.surface;e&&(e.unbind("mouseenter",this._surfaceMouseenterHandler),e.unbind("mouseleave",this._surfaceMouseleaveHandler),e.destroy(),this.surface=null)},t.prototype._destroySelections=function(){var e=this._selections;if(e)for(;e.length>0;)e.shift().destroy()},t.prototype._destroyView=function(){var e=this._model;e&&(e.destroy(),this._model=null),this._unsetActivePoint(),this._clearFocusedElement(),this._resetDrilldownPoint(),this._destroySelections(),this._tooltip&&this._tooltip.destroy(),this._highlight&&this._highlight.destroy(),this._zoomSelection&&(this._zoomSelection.destroy(),delete this._zoomSelection),this._pannable&&(this._pannable.destroy(),delete this._pannable),this._mousewheelZoom&&(this._mousewheelZoom.destroy(),delete this._mousewheelZoom)},t}(fr);function vj(e,t){if(e)for(var n=0;n<e.length;n++)if(e[n].category===t)return[e[n]]}function _j(e){delete e.bar,delete e.column,delete e.rangeColumn,delete e.line,delete e.verticalLine,delete e.pie,delete e.donut,delete e.area,delete e.verticalArea,delete e.scatter,delete e.scatterLine,delete e.bubble,delete e.candlestick,delete e.ohlc,delete e.boxPlot,delete e.bullet,delete e.verticalBullet,delete e.polarArea,delete e.polarLine,delete e.radarArea,delete e.radarLine,delete e.waterfall}function bj(e){for(var t={},n=0;n<e.length;n++){var i=e[n],r=i.options.name;r&&(t[r]=i.range())}return t}var yj=["data","categories"];function wj(e,t){for(var n in t)if(!tR(n,yj)&&QR(t,n)){var i=t[n],r=e[n];if(hR(r)){var o=null===i;o||!hR(i)?(delete e[n],o&&delete t[n]):r&&OF(i)&&OF(r)&&wj(r,i)}}}function kj(e){for(var t=0;t<e.length;t++)e[t].notifyRender()}DR(gj,{renderAs:"",chartArea:{},legend:{visible:!0,labels:{},accessibility:{highlight:{border:{opacity:1,color:FH,width:2}}}},categoryAxis:{},seriesDefaults:{type:yV,data:[],highlight:{visible:!0},labels:{},negativeValues:{visible:!1},accessibility:{highlight:{border:{opacity:1,width:2},zIndex:200}}},series:[],seriesColors:null,tooltip:{visible:!1},transitions:!0,valueAxis:{},plotArea:{},title:{},xAxis:{},yAxis:{},panes:[{}],pannable:!1,zoomable:!1});var xj=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._slotAnchor=function(e,t){var n=this.plotArea.categoryAxis.options.vertical,i=n?{horizontal:"left",vertical:"center"}:{horizontal:"center",vertical:"bottom"};return{point:n?new OL(this.plotArea.box.x2,t.center().y):new OL(t.center().x,-2),align:i}},t.prototype._defaultAnchor=function(e,t){return this._slotAnchor({},t)},t}(rW),Cj=[mV,_V];function Sj(e){for(var t=[],n=0;n<e.length;n++){var i=e[n];t[n]=i.style.display,i.style.display="none"}return t}function Tj(e,t){for(var n=0;n<e.length;n++)e[n].style.display=t[n]}function Dj(e){return MF(e)?[e]:e}var Aj=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._setElementClass=function(e){CF(e,"k-sparkline")},t.prototype._initElement=function(t){e.prototype._initElement.call(this,t),this._initialWidth=Math.floor(mR(t).width)},t.prototype._resize=function(){var t=this.element,n=Sj(t.childNodes);this._initialWidth=Math.floor(mR(t).width),Tj(t.childNodes,n),e.prototype._resize.call(this)},t.prototype._modelOptions=function(){var e=this.options,t=this._surfaceWrap(),n=Sj(t.childNodes),i=document.createElement("span");i.innerHTML="&nbsp;",t.appendChild(i);var r=BF({width:this._autoWidth,height:mR(t).height,transitions:e.transitions},e.chartArea,{inline:!0,align:!1});return mR(t,{width:r.width,height:r.height}),t.removeChild(i),Tj(t.childNodes,n),this.surface&&this.surface.resize(),r},t.prototype._surfaceWrap=function(){if(!this.stage){var e=this.stage=document.createElement("span");this.element.appendChild(e)}return this.stage},t.prototype._createPlotArea=function(t){var n=e.prototype._createPlotArea.call(this,t);return this._autoWidth=this._initialWidth||this._calculateWidth(n),n},t.prototype._calculateWidth=function(e){for(var t=this.options,n=WF(t.chartArea.margin),i=e.charts,r=this._surfaceWrap(),o=0,a=0;a<i.length;a++){var s=i[a],l=(s.options.series||[])[0];if(l){if(l.type===mV)return 150;if(l.type===_V)return 150;if(l.type===AV)return mR(r).height;var c=s.categoryAxis;if(c){var d=c.categoriesCount()*(!s.options.isStacked&&tR(l.type,[yV,$V])?s.seriesOptions.length:1);o=Math.max(o,d)}}}var u=o*t.pointWidth;return u>0&&(u+=n.left+n.right),u},t.prototype._createSharedTooltip=function(e){return new xj(this._plotArea,e)},t.normalizeOptions=function(e){var t=Dj(e);return(t=xF(t)?{seriesDefaults:{data:t}}:BF({},t)).series||(t.series=[{data:Dj(t.data)}]),BF(t,{seriesDefaults:{type:t.type}}),(tR(t.series[0].type,Cj)||tR(t.seriesDefaults.type,Cj))&&(t=BF({},{categoryAxis:{crosshair:{visible:!1}}},t)),t},t}(gj);DR(Aj,{chartArea:{margin:2},axisDefaults:{visible:!1,majorGridLines:{visible:!1},valueAxis:{narrowRange:!0}},seriesDefaults:{type:"line",area:{line:{width:.5}},bar:{stack:!0},padding:2,width:.5,overlay:{gradient:null},highlight:{visible:!1},border:{width:0},markers:{size:2,visible:!1}},tooltip:{visible:!0,shared:!0},categoryAxis:{crosshair:{visible:!0,tooltip:{visible:!1}}},legend:{visible:!1},transitions:!1,pointWidth:5,panes:[{clip:!1}]});var Mj=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setup=function(){this._initialOpacity=parseFloat(UF(this.element,"opacity").opacity)},t.prototype.step=function(e){UF(this.element,{opacity:String(nR(this._initialOpacity,0,e))})},t.prototype.abort=function(){e.prototype.abort.call(this),UF(this.element,{display:"none",opacity:String(this._initialOpacity)})},t.prototype.cancel=function(){e.prototype.abort.call(this),UF(this.element,{opacity:String(this._initialOpacity)})},t}(nl);function Ej(e,t){var n=document.createElement("div");return n.className=e,t&&(n.style.cssText=t),n}var Ij=function(e){function t(t,n,i){e.call(this),this.options=BF({},this.options,i),this.container=t,this.chartService=n;var r=UF(t,["paddingLeft","paddingTop"]);this.chartPadding={top:r.paddingTop,left:r.paddingLeft},this.createElements(),t.appendChild(this.element)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createElements=function(){var e=this.element=Ej("k-navigator-hint","display: none; position: absolute; top: 1px; left: 1px;"),t=this.tooltip=Ej("k-tooltip k-chart-tooltip"),n=this.scroll=Ej("k-scroll");t.innerHTML="&nbsp;",e.appendChild(t),e.appendChild(n)},t.prototype.show=function(e,t,n){var i=this,r=i.element,o=i.options,a=i.scroll,s=i.tooltip,l=jB(JB(e)+JB(t-e)/2),c=.4*n.width(),d=n.center().x-c,u=(n.center().x-d)/(o.max-o.min),h=l-o.min,p=this.chartService.intl.format(o.format,e,t),f=GF(o);this.clearHideTimeout(),this._visible||(UF(r,{visibility:"hidden",display:"block"}),this._visible=!0),f&&(p=f({from:e,to:t})),s.innerHTML=p,UF(s,{left:n.center().x-s.offsetWidth/2,top:n.y1});var m=UF(s,["marginTop","borderTopWidth","height"]);UF(a,{width:c,left:d+h*u,top:n.y1+m.marginTop+m.borderTopWidth+m.height/2}),UF(r,{visibility:"visible"})},t.prototype.clearHideTimeout=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this._hideAnimation&&this._hideAnimation.cancel()},t.prototype.hide=function(){var e=this;this.clearHideTimeout(),this._hideTimeout=setTimeout((function(){e._visible=!1,e._hideAnimation=new Mj(e.element),e._hideAnimation.setup(),e._hideAnimation.play()}),this.options.hideDelay)},t.prototype.destroy=function(){this.clearHideTimeout(),this.container&&this.container.removeChild(this.element),delete this.container,delete this.chartService,delete this.element,delete this.tooltip,delete this.scroll},t}(fr);DR(Ij,{format:"{0:d} - {1:d}",hideDelay:500});var zj="_navigator",Pj=zj,Hj="_default",Fj=Object.freeze({__proto__:null,DEFAULT_PANE:Hj,NAVIGATOR_AXIS:Pj,NAVIGATOR_PANE:zj}),Rj=function(e){function t(t){var n;e.call(this),this.chart=t;var i=this.options=BF({},this.options,t.options.navigator),r=i.select;r&&(r.from=this.parseDate(r.from),r.to=this.parseDate(r.to)),hR(i.hint.visible)||(i.hint.visible=i.visible),this.chartObserver=new rR(this,((n={})[dN]="_drag",n[uN]="_dragEnd",n[fN]="_zoom",n[mN]="_zoomEnd",n)),t.addObserver(this.chartObserver)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parseDate=function(e){return rO(this.chart.chartService.intl,e)},t.prototype.clean=function(){this.selection&&(this.selection.destroy(),this.selection=null),this.hint&&(this.hint.destroy(),this.hint=null)},t.prototype.destroy=function(){this.chart&&(this.chart.removeObserver(this.chartObserver),delete this.chart),this.clean()},t.prototype.redraw=function(){this._redrawSelf(),this.initSelection()},t.prototype.initSelection=function(){var e,t=this.chart,n=this.options,i=this.mainAxis(),r=i.roundedRange(),o=r.min,a=r.max,s=n.select,l=s.from,c=s.to,d=s.mousewheel,u=(e=i,Lj.prototype=e,new Lj);0!==i.categoriesCount()&&(this.clean(),u.box=i.box,this.selection=new nW(t,u,{min:o,max:a,from:l||o,to:c||a,mousewheel:SR(d,{zoom:"left"}),visible:n.visible},new rR(this,{selectStart:"_selectStart",select:"_select",selectEnd:"_selectEnd"})),n.hint.visible&&(this.hint=new Ij(t.element,t.chartService,{min:o,max:a,template:GF(n.hint),format:n.hint.format})))},t.prototype.setRange=function(){var e=this.chart._createPlotArea(!0).namedCategoryAxes[Pj].roundedRange(),t=e.min,n=e.max,i=this.options.select||{},r=i.from||t;r<t&&(r=t);var o=i.to||n;o>n&&(o=n),this.options.select=BF({},i,{from:r,to:o}),this.filterAxes()},t.prototype._redrawSelf=function(e){var t=this.chart._plotArea;t&&t.redraw(bR(t.panes),e)},t.prototype.redrawSlaves=function(){var e=this.chart,t=e._plotArea,n=t.panes.filter((function(e){return e.options.name!==zj}));t.srcSeries=e.options.series,t.options.categoryAxis=e.options.categoryAxis,t.clearSeriesPointsCache(),t.redraw(n)},t.prototype._drag=function(e){var t,n=this.chart,i=this.selection,r=n._eventCoordinates(e.originalEvent),o=this.mainAxis(),a=o.roundedRange(),s=o.pane.box.containsPoint(r),l=n._plotArea.categoryAxis,c=e.axisRanges[l.options.name],d=this.options.select;if(c&&!s&&i){t=d.from&&d.to?JB(d.to)-JB(d.from):JB(i.options.to)-JB(i.options.from);var u=jB(yR(JB(c.min),a.min,JB(a.max)-t)),h=jB(yR(JB(u)+t,JB(a.min)+t,a.max));this.options.select={from:u,to:h},this.options.liveDrag&&(this.filterAxes(),this.redrawSlaves()),i.set(u,h),this.showHint(u,h)}},t.prototype._dragEnd=function(){this.filterAxes(),this.filter(),this.redrawSlaves(),this.hint&&this.hint.hide()},t.prototype.readSelection=function(){var e=this.selection.options,t=e.from,n=e.to,i=this.options.select;i.from=t,i.to=n},t.prototype.filterAxes=function(){var e=this.options.select;void 0===e&&(e={});for(var t=this.chart.options.categoryAxis,n=e.from,i=e.to,r=0;r<t.length;r++){var o=t[r];o.pane!==zj&&(o.min=n,o.max=i)}},t.prototype.filter=function(){var e=this.chart,t=this.options.select;if(e.requiresHandlers(["navigatorFilter"])){var n=this.mainAxis(),i={from:t.from,to:t.to};if("category"!==n.options.type){var r=new vO(BF({baseUnit:"fit"},e.options.categoryAxis[0],{categories:[t.from,t.to]}),e.chartService).options;i.from=KB(r.min,-r.baseUnitStep,r.baseUnit),i.to=KB(r.max,r.baseUnitStep,r.baseUnit)}this.chart.trigger("navigatorFilter",i)}},t.prototype._zoom=function(e){var t=this,n=t.chart._plotArea.categoryAxis,i=t.selection,r=t.options,o=r.select,a=r.liveDrag,s=this.mainAxis(),l=e.delta;if(i){var c=s.categoryIndex(i.options.from),d=s.categoryIndex(i.options.to),u=this.chart._eventCoordinates(e.originalEvent);e.originalEvent.preventDefault(),Math.abs(l)>1&&(l*=3),d-c>1?(i.zoom(l,u),this.readSelection()):(n.options.min=o.from,o.from=n.scaleRange(-e.delta*this.chart._mousewheelZoomRate(),u).min),a&&(this.filterAxes(),this.redrawSlaves()),i.set(o.from,o.to),this.showHint(this.options.select.from,this.options.select.to)}},t.prototype._zoomEnd=function(e){this._dragEnd(e)},t.prototype.showHint=function(e,t){var n=this.chart._plotArea;this.hint&&this.hint.show(e,t,n.backgroundBox())},t.prototype._selectStart=function(e){return this.chart._selectStart(e)},t.prototype._select=function(e){return this.showHint(e.from,e.to),this.chart._select(e)},t.prototype._selectEnd=function(e){return this.hint&&this.hint.hide(),this.readSelection(),this.filterAxes(),this.filter(),this.redrawSlaves(),this.chart._selectEnd(e)},t.prototype.mainAxis=function(){var e=this.chart._plotArea;if(e)return e.namedCategoryAxes[Pj]},t.prototype.select=function(e,t){var n=this.options.select;return e&&t&&(n.from=this.parseDate(e),n.to=this.parseDate(t),this.filterAxes(),this.filter(),this.redrawSlaves(),this.selection.set(e,t)),{from:n.from,to:n.to}},t.setup=function(e,n){if(void 0===e&&(e={}),void 0===n&&(n={}),!e.__navi){e.__navi=!0;var i=BF({},n.navigator,e.navigator),r=e.panes=[].concat(e.panes),o=BF({},i.pane,{name:zj});i.visible||(o.visible=!1,o.height=.1),"top"!==e.navigator.position?r.push(o):r.unshift(o),r.forEach((function(e){e.name=e.name||Hj})),t.attachAxes(e,i),t.attachSeries(e,i,n)}},t.attachAxes=function(e,t){var n=t.series||[],i=e.categoryAxis=[].concat(e.categoryAxis),r=e.valueAxis=[].concat(e.valueAxis);i.concat(r).forEach((function(e){e.pane=e.pane||Hj}));var o=0===QN(n,qV).length,a=BF({type:"date",pane:zj,roundToBaseUnit:!o,justified:o,_collapse:!1,majorTicks:{visible:!0},tooltip:{visible:!1},labels:{step:1},autoBind:t.autoBindElements,autoBaseUnitSteps:{minutes:[1],hours:[1,2],days:[1,2],weeks:[],months:[1],years:[1]}}),s=t.categoryAxis;i.push(BF({},a,{maxDateGroups:200},s,{name:Pj,title:null,baseUnit:"fit",baseUnitStep:"auto",labels:{visible:!1},majorTicks:{visible:!1}}),BF({},a,s,{name:Pj+"_labels",maxDateGroups:20,baseUnitStep:"auto",labels:{position:""},plotBands:[],autoBaseUnitSteps:{minutes:[]},_overlap:!0}),BF({},a,s,{name:Pj+"_ticks",maxDateGroups:200,majorTicks:{width:.5},plotBands:[],title:null,labels:{visible:!1,mirror:!0},_overlap:!0})),r.push(BF({name:Pj,pane:zj,majorGridLines:{visible:!1},visible:!1},t.valueAxis))},t.attachSeries=function(e,t,n){for(var i=e.series=e.series||[],r=[].concat(t.series||[]),o=n.seriesColors,a=t.seriesDefaults,s=0;s<r.length;s++)i.push(BF({color:o[s%o.length],categoryField:t.dateField,visibleInLegend:!1,tooltip:{visible:!1}},a,r[s],{axis:Pj,categoryAxis:Pj,autoBind:t.autoBindElements}))},t}(fr);function Lj(){}var Bj=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.applyDefaults=function(t,n){var i=mR(this.element).width||UH,r=n,o={seriesDefaults:{categoryField:t.dateField},axisDefaults:{categoryAxis:{name:"default",majorGridLines:{visible:!1},labels:{step:2},majorTicks:{visible:!1},maxDateGroups:Math.floor(i/28)}}};r&&(r=BF({},r,o)),Rj.setup(t,r),e.prototype.applyDefaults.call(this,t,r)},t.prototype._setElementClass=function(e){CF(e,"k-chart k-stockchart")},t.prototype.setOptions=function(t){this.destroyNavigator(),e.prototype.setOptions.call(this,t)},t.prototype.noTransitionsRedraw=function(){var e=this.options.transitions;this.options.transitions=!1,this._fullRedraw(),this.options.transitions=e},t.prototype._resize=function(){this.noTransitionsRedraw()},t.prototype._redraw=function(){var e=this.navigator;!this._dirty()&&e&&e.options.partialRedraw?e.redrawSlaves():this._fullRedraw()},t.prototype._dirty=function(){var e=this.options,t=ZF([].concat(e.series,e.navigator.series),(function(e){return e&&e.visible})).length,n=this._seriesCount!==t;return this._seriesCount=t,n},t.prototype._fullRedraw=function(){var t=this.navigator;t||(t=this.navigator=new Rj(this),this.trigger("navigatorCreated",{navigator:t})),t.clean(),t.setRange(),e.prototype._redraw.call(this),t.initSelection()},t.prototype._trackSharedTooltip=function(t){var n=this._plotArea.paneByPoint(t);n&&n.options.name===zj?this._unsetActivePoint():e.prototype._trackSharedTooltip.call(this,t)},t.prototype.bindCategories=function(){e.prototype.bindCategories.call(this),this.copyNavigatorCategories()},t.prototype.copyNavigatorCategories=function(){for(var e,t=[].concat(this.options.categoryAxis),n=0;n<t.length;n++){var i=t[n];i.name===Pj?e=i.categories:e&&i.pane===zj&&(i.categories=e)}},t.prototype.destroyNavigator=function(){this.navigator&&(this.navigator.destroy(),this.navigator=null)},t.prototype.destroy=function(){this.destroyNavigator(),e.prototype.destroy.call(this)},t.prototype._stopChartHandlers=function(t){var n=this._eventCoordinates(t),i=this._plotArea.paneByPoint(n);return e.prototype._stopChartHandlers.call(this,t)||i&&i.options.name===zj},t.prototype._toggleDragZoomEvents=function(){this._dragZoomEnabled||(this.element.style.touchAction="none",this._dragZoomEnabled=!0)},t}(gj);DR(Bj,{dateField:"date",axisDefaults:{categoryAxis:{type:"date",baseUnit:"fit",justified:!0},valueAxis:{narrowRange:!0,labels:{format:"C"}}},navigator:{select:{},seriesDefaults:{markers:{visible:!1},tooltip:{visible:!1},highlight:{visible:!1},line:{width:2}},hint:{},visible:!0},tooltip:{visible:!0},legend:{visible:!1}});var Oj=150,Vj="arrowPointer",Nj="barPointer",$j=.5,Uj=Math.PI/180,Wj="inside",jj="linear",qj="outside",Gj="radialPointer",Kj="radialRangePointer";function Yj(e,t){var n=e.getOrigin(),i=e.getSize(),r=WF(t);return e.setOrigin([n.x-r.left,n.y-r.top]),e.setSize([i.width+(r.left+r.right),i.height+(r.top+r.bottom)]),e}var Qj=vs,Xj=us,Zj=fs;function Jj(e,t){var n=e.box,i=e.children[0].box,r=t.border||{},o=t.background||"",a=Xj.fromRect(new Yo([n.x1,n.y1],[n.width(),n.height()]),{stroke:{}}),s=new Zj(e.text,new Go(i.x1,i.y1),{font:t.font,fill:{color:t.color}}),l=Yj(s.bbox().clone(),t.padding),c=Xj.fromRect(l,{stroke:{color:r.width?r.color:"",width:r.width,opacity:r.opacity,dashType:r.dashType,lineJoin:"round",lineCap:"round"},fill:{color:o}}),d=new Qj;return d.append(a),d.append(c),d.append(s),d}function eq(e,t,n){var i=hR(e.from)?e.from:JH,r=hR(e.to)?e.to:ZH;return e.from=Math.max(Math.min(r,i),t),e.to=Math.min(Math.max(r,i),n),e}function tq(e,t){var n=WF(t);return n.left=-n.left,n.top=-n.top,n.right=-n.right,n.bottom=-n.bottom,Yj(e,n)}var nq=us,iq=vc,rq=function(e){function t(t,n,i,r){void 0===r&&(r={}),e.call(this),this.element=t,this.theme=i,this.contextService=new yB(this,r),this._originalOptions=BF({},this.options,n),this.options=BF({},this._originalOptions),this._initTheme(i),this.redraw()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this.surface&&(this.surface.destroy(),this.surface=null),delete this.element,delete this.surfaceElement},t.prototype.value=function(e){var t=this.pointers[0];if(0===arguments.length)return t.value();t.value(e),this._setValueOptions(e)},t.prototype._draw=function(){var e=this.surface;e.clear(),e.draw(this._visuals)},t.prototype.exportVisual=function(){return this._visuals},t.prototype.allValues=function(e){var t=this.pointers,n=[];if(0===arguments.length){for(var i=0;i<t.length;i++)n.push(t[i].value());return n}if(xF(e))for(var r=0;r<e.length;r++)MF(e[r])&&t[r].value(e[r]);this._setValueOptions(e)},t.prototype._setValueOptions=function(e){for(var t=[].concat(this.options.pointer),n=[].concat(e),i=0;i<n.length;i++)t[i].value=n[i]},t.prototype.resize=function(){this.noTransitionsRedraw()},t.prototype.noTransitionsRedraw=function(){var e=this.options.transitions;this._toggleTransitions(!1),this.redraw(),this._toggleTransitions(e)},t.prototype.redraw=function(){var e=this._surfaceSize(),t=new Yo([0,0],[e.width,e.height]);this._initSurface(),this.gaugeArea=this._createGaugeArea(),this._createModel();var n=tq(t.bbox(),this._gaugeAreaMargin);this.reflow(n)},t.prototype.setOptions=function(e,t){this._originalOptions=BF(this._originalOptions,e),this.options=BF({},this._originalOptions),this._initTheme(t),this.redraw()},t.prototype.setDirection=function(e){this.contextService.rtl=Boolean(e),this.surface&&"svg"===this.surface.type&&(this.surface.destroy(),this.surface=null)},t.prototype.setIntlService=function(e){this.contextService.intl=e},t.prototype._initTheme=function(e){var t=e||this.theme||{};this.theme=t,this.options=BF({},t,this.options);var n=this.options,i=n.pointer;if(xF(i)){for(var r=[],o=0;o<i.length;o++)r.push(BF({},t.pointer,i[o]));n.pointer=r}},t.prototype._createGaugeArea=function(){var e=this.options.gaugeArea,t=this.surface.size(),n=e.border||{},i=new Yo([0,0],[t.width,t.height]);return this._gaugeAreaMargin=e.margin||5,n.width>0&&(i=tq(i,n.width)),nq.fromRect(i,{stroke:{color:n.width?n.color:"",width:n.width,opacity:n.opacity,dashType:n.dashType,lineJoin:"round",lineCap:"round"},fill:{color:e.background}})},t.prototype._initSurface=function(){var e=this.options,t=this.surface,n=this._surfaceElement(),i=this._surfaceSize();mR(n,i),t&&t.options.type===e.renderAs?(this.surface.clear(),this.surface.resize()):(t&&t.destroy(),this.surface=iq.create(n,{type:e.renderAs}))},t.prototype._surfaceSize=function(){var e=this.options,t=this._getSize();return e.gaugeArea&&BF(t,e.gaugeArea),t},t.prototype._surfaceElement=function(){return this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.element.appendChild(this.surfaceElement)),this.surfaceElement},t.prototype.getSize=function(){return this._getSize()},t.prototype._getSize=function(){var e=this.element,t=this._defaultSize(),n=e.offsetWidth,i=e.offsetHeight;return n||(n=t.width),i||(i=t.height),{width:n,height:i}},t.prototype._defaultSize=function(){return{width:200,height:200}},t.prototype._toggleTransitions=function(e){this.options.transitions=e;for(var t=0;t<this.pointers.length;t++)this.pointers[t].options.animation.transitions=e},t}(fr);DR(rq,{plotArea:{},theme:"default",renderAs:"",pointer:{},scale:{},gaugeArea:{}});var oq=us,aq=vs,sq=Go;function lq(e,t){var n,i,r=e.position,o=e.tickX,a=e.tickY;return e.vertical?(n=new sq(o,r),i=new sq(o+t.size,r)):(n=new sq(r,a),i=new sq(r,a+t.size)),new oq({stroke:{color:t.color,width:t.width}}).moveTo(n).lineTo(i)}function cq(e,t,n,i){var r=t.length;if(i.visible)for(var o=n.mirror,a=n.lineBox,s=i.skip;s<r;s+=i.step)s%i.skipUnit!=0&&(n.tickX=o?a.x2:a.x2-i.size,n.tickY=o?a.y1-i.size:a.y1,n.position=t[s],e.append(lq(n,i)))}var dq=function(e){function t(t,n){var i=t||{};!hR(i.reverse)&&!1===i.vertical&&(n||{}).rtl&&(i=Object.assign({},i,{reverse:!0})),e.call(this,0,1,i,n),this.options.minorUnit=this.options.minorUnit||this.options.majorUnit/10}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initUserOptions=function(e){var t=BF({},this.options,e);return(t=BF({},t,{labels:{mirror:t.mirror}})).majorUnit=t.majorUnit||BL(t.min,t.max),t},t.prototype.initFields=function(){},t.prototype.render=function(){var e=this.elements=new aq,t=this.renderLabels(),n=this.renderLine(),i=this.renderTicks(),r=this.renderRanges();return e.append(n,t,i,r),e},t.prototype.renderRanges=function(){for(var e=this,t=this.options,n=t.min,i=t.max,r=t.vertical,o=t.labels.mirror,a=t.ranges||[],s=new aq,l=a.length,c=t.rangeSize||t.minorTicks.size/2,d=0;d<l;d++){var u=eq(a[d],n,i),h=e.getSlot(u.from,u.to),p=r?e.lineBox():h,f=r?h:e.lineBox();r?p.x1-=c*(o?-1:1):f.y2+=c*(o?-1:1),s.append(oq.fromRect(new Yo([p.x1,f.y1],[p.x2-p.x1,f.y2-f.y1]),{fill:{color:u.color,opacity:u.opacity},stroke:{}}))}return s},t.prototype.renderLabels=function(){for(var e=this.labels,t=this.options,n=new aq,i=0;i<e.length;i++)n.append(Jj(e[i],t.labels));return n},t.prototype.renderLine=function(){var e=this.options.line,t=this.lineBox(),n=new aq;if(e.width>0&&e.visible){var i=new oq({stroke:{color:e.color,dashType:e.dashType,width:e.width}});i.moveTo(t.x1,t.y1).lineTo(t.x2,t.y2),n.append(i)}return n},t.prototype.renderTicks=function(){var e=new aq,t=this.options,n=t.majorTicks.visible?t.majorUnit:0,i={vertical:t.vertical,mirror:t.labels.mirror,lineBox:this.lineBox()};return cq(e,this.getMajorTickPositions(),i,t.majorTicks),cq(e,this.getMinorTickPositions(),i,BF({},{skipUnit:n/t.minorUnit},t.minorTicks)),e},t}(kO);DR(dq,{min:0,max:50,majorTicks:{size:15,align:Wj,color:FH,width:$j,visible:!0},minorTicks:{size:10,align:Wj,color:FH,width:$j,visible:!0},line:{width:$j},labels:{position:Wj,padding:2},mirror:!1,_alignLines:!1});var uq=function(e){function t(t,n){e.call(this);var i=t.options,r=i.min,o=i.max,a=this.options=BF({},this.options,n);a.fill=a.color,this.scale=t,hR(a.value)?a.value=yR(a.value,r,o):a.value=r}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.value=function(e){var t=this.options,n=t.value;if(0===arguments.length)return n;var i=this.scale.options,r=i.min,o=i.max;t._oldValue=hR(t._oldValue)?t.value:r,t.value=yR(e,r,o),this.elements&&this.repaint()},t}(fr);DR(uq,{color:FH});var hq=function(e){function t(t,n){e.call(this,t,n),this.options=BF({track:{visible:hR(n.track)}},this.options)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(){var e,t,n,i=this.options,r=this.scale,o=r.options,a=o.mirror,s=o.vertical,l=r.lineBox(),c=i.track.size||i.size,d=i.size/2,u=WF(i.margin),h=s?u[a?"left":"right"]:u[a?"bottom":"top"];h=a?-h:h,s?(n=new VL(l.x1+h,l.y1,l.x1+h,l.y2),a?n.x1-=c:n.x2+=c,i.shape!==Nj&&(e=t=new VL(l.x2+h,l.y1-d,l.x2+h,l.y2+d))):(n=new VL(l.x1,l.y1-h,l.x2,l.y1-h),a?n.y2+=c:n.y1-=c,i.shape!==Nj&&(e=t=new VL(l.x1-d,l.y1-h,l.x2+d,l.y1-h))),this.trackBox=n,this.pointerRangeBox=t,this.box=e||n.clone().pad(i.border.width)},t.prototype.getElementOptions=function(){var e=this.options;return{fill:{color:e.color,opacity:e.opacity},stroke:hR(e.border)?{color:e.border.width?e.border.color||e.color:"",width:e.border.width,dashType:e.border.dashType,opacity:e.opacity}:null}},t.prototype._margin=function(){var e=this.scale,t=this.options,n=e.options,i=n.mirror,r=n.vertical,o=WF(t.margin);return r?o[i?"left":"right"]:o[i?"bottom":"top"]},t}(uq);DR(hq,{shape:Nj,track:{border:{width:1}},color:FH,border:{width:1},opacity:1,margin:WF(3),animation:{type:Nj},visible:!0});var pq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setup=function(){var e=this.options,t=e.margin,n=e.from,i=e.to,r=e.vertical,o=r?"x1":"y1";e.mirror===r?(n[o]-=t,i[o]-=t):(n[o]+=t,i[o]+=t);var a=this.fromScale=new Go(n.x1,n.y1),s=this.toScale=new Go(i.x1,i.y1);0!==e.duration&&(e.duration=Math.max(a.distanceTo(s)/e.duration*1e3,1))},t.prototype.step=function(e){var t=nR(this.fromScale.x,this.toScale.x,e),n=nR(this.fromScale.y,this.toScale.y,e);this.element.transform(Xo().translate(t,n))},t}(nl);DR(pq,{easing:jj,duration:250}),tl.current.register(Vj,pq);var fq=Go,mq=us,gq=function(e){function t(t,n){e.call(this,t,n),hR(this.options.size)||(this.options.size=.6*this.scale.options.majorTicks.size)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.pointerShape=function(){var e=this.scale,t=this.options.size,n=t/2,i=e.options.mirror?-1:1;return e.options.vertical?[new fq(0,0-n),new fq(0-i*t,0),new fq(0,0+n)]:[new fq(0-n,0),new fq(0,0+i*t),new fq(0+n,0)]},t.prototype.repaint=function(){var e=this.scale,t=this.options,n=new pq(this.elements,BF(t.animation,{vertical:e.options.vertical,mirror:e.options.mirror,margin:this._margin(t.margin),from:e.getSlot(t._oldValue),to:e.getSlot(t.value)}));!1===t.animation.transitions&&(n.options.duration=0),n.setup(),n.play()},t.prototype.render=function(){var e=this.scale,t=this.options,n=this.getElementOptions(),i=this.pointerShape(t.value);t.animation.type=Vj;var r=new mq({stroke:n.stroke,fill:n.fill}).moveTo(i[0]).lineTo(i[1]).lineTo(i[2]).close(),o=e.getSlot(t.value);return r.transform(Xo().translate(o.x1,o.y1)),this.elements=r,r},t}(hq),vq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setup=function(){var e=this.options,t=this.axis=e.vertical?_F:vF,n=this.to=e.newPoints[0][t],i=this.from=e.oldPoints[0][t];0!==e.duration&&(e.duration=Math.max(Math.abs(n-i)/e.speed*1e3,1)),this._set(i)},t.prototype.step=function(e){var t=nR(this.from,this.to,e);this._set(t)},t.prototype._set=function(e){var t="set"+this.axis.toUpperCase(),n=this.options.newPoints;n[0][t](e),n[1][t](e)},t}(nl);DR(vq,{easing:jj,speed:250}),tl.current.register(Nj,vq);var _q=vs,bq=us,yq=function(e){function t(t,n){e.call(this,t,n),hR(this.options.size)||(this.options.size=.3*this.scale.options.majorTicks.size)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.pointerShape=function(e){var t=this.scale,n=this.options,i=t.options,r=i.mirror,o=i.vertical,a=r===o?-1:1,s=n.size*a,l=t.getSlot(t.options.min),c=t.getSlot(e),d=o?_F:vF,u=o?vF:_F,h=this._margin()*a,p=new Go;p[d]=l[d+"1"],p[u]=l[u+"1"];var f=new Go;f[d]=c[d+"1"],f[u]=c[u+"1"],o?(p.translate(h,0),f.translate(h,0)):(p.translate(0,h),f.translate(0,h));var m=f.clone(),g=p.clone();return o?(m.translate(s,0),g.translate(s,0)):(m.translate(0,s),g.translate(0,s)),[p,f,m,g]},t.prototype.repaint=function(){var e=this.scale,t=this.options,n=this.pointerShape(t.value),i=this.pointerPath,r=this.pointerShape(t._oldValue);i.moveTo(n[0]).lineTo(n[1]).lineTo(n[2]).lineTo(n[3]).close();var o=new vq(i,BF(t.animation,{reverse:e.options.reverse,vertical:e.options.vertical,oldPoints:[r[1],r[2]],newPoints:[n[1],n[2]]}));!1===t.animation.transitions&&(o.options.duration=0),o.setup(),o.play()},t.prototype.render=function(){var e=new _q,t=this.getElementOptions();this.options.track.visible&&e.append(this.renderTrack());var n=this.pointerPath=new bq({stroke:t.stroke,fill:t.fill});return e.append(n),this.elements=e,e},t.prototype.renderTrack=function(){var e=this.options.track,t=e.border||{},n=this.trackBox.clone().pad(t.width||0);return new bq.fromRect(n.toRect(),{fill:{color:e.color,opacity:e.opacity},stroke:{color:t.width?t.color||e.color:"",width:t.width,dashType:t.dashType}})},t}(hq),wq=vs,kq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(e){var t=this.pointers,n=e.origin.x,i=e.origin.y,r=new VL(n,i,n+e.width(),i+e.height());this.scale.reflow(r),this._shrinkScaleWidth(r);for(var o=0;o<t.length;o++)t[o].reflow();this.bbox=this._getBox(r),this._alignElements(),this._shrinkElements(),this._buildVisual(),this._draw()},t.prototype._buildVisual=function(){var e=new wq,t=this.scale.render(),n=this.pointers;e.append(this.gaugeArea),e.append(t);for(var i=0;i<n.length;i++){var r=n[i];e.append(r.render()),r.value(r.options.value)}this._visuals=e},t.prototype._createModel=function(){var e=this.options,t=this.scale=new dq(e.scale,this.contextService);this.pointers=[];var n=e.pointer;n=xF(n)?n:[n];for(var i=0;i<n.length;i++){var r=BF({},n[i],{animation:{transitions:e.transitions}}),o="arrow"===r.shape?gq:yq;this.pointers.push(new o(t,r))}},t.prototype._defaultSize=function(){var e=this.options.scale.vertical;return{width:e?60:200,height:e?200:60}},t.prototype._getBox=function(e){for(var t,n=this.scale,i=this.pointers,r=e.center(),o=i[0].box.clone().wrap(n.box),a=0;a<i.length;a++)o.wrap(i[a].box.clone());return n.options.vertical?(t=o.width()/2,o=new VL(r.x-t,e.y1,r.x+t,e.y2)):(t=o.height()/2,o=new VL(e.x1,r.y-t,e.x2,r.y+t)),o},t.prototype._alignElements=function(){for(var e,t=this.scale,n=this.pointers,i=t.box,r=n[0].box.clone().wrap(t.box),o=this.bbox,a=0;a<n.length;a++)r.wrap(n[a].box.clone());t.options.vertical?(e=o.center().x-r.center().x,t.reflow(new VL(i.x1+e,o.y1,i.x2+e,o.y2))):(e=o.center().y-r.center().y,t.reflow(new VL(i.x1,i.y1+e,i.x2,i.y2+e)));for(var s=0;s<n.length;s++)n[s].reflow(this.bbox)},t.prototype._shrinkScaleWidth=function(e){var t=this.scale;if(!t.options.vertical){var n=t.contentBox().width()-e.width();n>0&&(t.box.shrink(n,0),t.box.alignTo(e,"center"),t.reflow(t.box))}},t.prototype._shrinkElements=function(){for(var e=this.scale,t=this.pointers,n=e.box.clone(),i=e.options.vertical?"y":"x",r=t[0].box,o=0;o<t.length;o++)r.wrap(t[o].box.clone());n[i+1]+=Math.max(n[i+1]-r[i+1],0),n[i+2]-=Math.max(r[i+2]-n[i+2],0),e.reflow(n);for(var a=0;a<t.length;a++)t[a].reflow(this.bbox)},t}(rq);DR(kq,{transitions:!0,gaugeArea:{background:""},scale:{vertical:!0}});var xq=180,Cq=ps,Sq=us,Tq=vs;function Dq(e,t,n,i){var r=new Tq,o=e.center,a=e.getRadiusX();if(i.visible)for(var s=0;s<t.length;s++){var l=e.pointAt(t[s]),c=new Go(o.x+a-i.size,o.y).rotate(t[s],o);r.append(new Sq({stroke:{color:i.color,width:i.width}}).moveTo(l).lineTo(c))}return r}function Aq(e,t,n,i){return{from:e,to:t,color:n,opacity:i}}var Mq=function(e){function t(t,n){e.call(this,0,1,t,n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initUserOptions=function(e){var t=BF({},this.options,e);return t.majorUnit=t.majorUnit||BL(t.min,t.max),t.minorUnit=t.minorUnit||t.majorUnit/10,t},t.prototype.initFields=function(){},t.prototype.render=function(e,t){var n=this.renderArc(e,t);this.bbox=n.bbox(),this.labelElements=this.renderLabels(),this.ticks=this.renderTicks(),this.ranges=this.renderRanges()},t.prototype.reflow=function(e){var t=e.center(),n=Math.min(e.height(),e.width())/2;if(!hR(this.bbox))return this.render(t,n);this.bbox=this.arc.bbox(),this.radius(this.arc.getRadiusX()),this.repositionRanges(),this.renderLabels()},t.prototype.slotAngle=function(e){var t=this.options,n=t.min,i=t.max,r=t.reverse,o=t.startAngle,a=t.endAngle,s=a-o;return(r?a-(e-n)/(i-n)*s:(e-n)/(i-n)*s+o)+xq},t.prototype.hasRanges=function(){var e=this.options.ranges;return e&&e.length},t.prototype.ticksSize=function(){var e=this.options,t=e.majorTicks,n=e.minorTicks,i=0;return t.visible&&(i=t.size),n.visible&&(i=Math.max(n.size,i)),i},t.prototype.labelsCount=function(){var t=e.prototype.labelsCount.call(this),n=this.options;return n.endAngle-n.startAngle>=360&&n.max%n.majorUnit==0&&(t-=1),t},t.prototype.renderLabels=function(){var e=this,t=this.options,n=this.arc.clone(),i=n.getRadiusX(),r=this.tickAngles(n,t.majorUnit),o=t.rangeSize=t.rangeSize||.1*i,a=new Tq,s=.05*i;hR(t.rangeDistance)?s=t.rangeDistance:t.rangeDistance=s;var l=t.labels,c=l.position===Wj,d=hR(this.labelElements);c&&(i-=this.ticksSize(),this.hasRanges()&&!d&&(i-=o+s),n.setRadiusX(i).setRadiusY(i));for(var u=this.labels,h=u.length,p=WF(l.padding),f=(p.left+p.right)/2,m=(p.top+p.bottom)/2,g=0;g<h;g++){var v=u[g],_=v.box.width()/2,b=v.box.height()/2,y=r[g],w=(y-xq)*Uj,k=n.pointAt(y),x=k.x+Math.cos(w)*(_+f)*(c?1:-1),C=k.y+Math.sin(w)*(b+m)*(c?1:-1);v.reflow(new VL(x-_,C-b,x+_,C+b));var S=new Go(v.box.x1,v.box.y1),T=void 0;if(d){var D=(T=e.labelElements.children[g]).bbox().origin,A=T.transform()||Xo();A.translate(S.x-D.x,S.y-D.y),T.transform(A)}else T=Jj(v,t.labels),a.append(T);e.bbox=Yo.union(e.bbox,T.bbox())}return a},t.prototype.repositionRanges=function(){var e=this.ranges.children;if(e.length>0){var t=this.options,n=t.rangeDistance,i=t.rangeSize,r=this.getRangeRadius();this.options.labels.position===Wj&&(r+=i+n);for(var o=r+i/2,a=0;a<e.length;a++)e[a]._geometry.setRadiusX(o).setRadiusY(o);this.bbox=Yo.union(this.bbox,this.ranges.bbox())}},t.prototype.renderRanges=function(){var e=this,t=this.rangeSegments(),n=t.length,i=new Tq;if(n){var r=this.options,o=r.rangeSize,a=r.reverse,s=r.rangeDistance,l=this.getRangeRadius();this.radius(this.radius()-o-s);for(var c=0;c<n;c++){var d=t[c],u=e.slotAngle(d[a?"to":"from"]),h=e.slotAngle(d[a?"from":"to"]);h-u!=0&&i.append(e.createRange(u,h,l,d))}}return i},t.prototype.createRange=function(e,t,n,i){var r=this.options.rangeSize,o=new ga(this.arc.center,{radiusX:n+r/2,radiusY:n+r/2,startAngle:e,endAngle:t});return new Cq(o,{stroke:{width:r,color:i.color,opacity:i.opacity,lineCap:i.lineCap}})},t.prototype.rangeSegments=function(){var e=this.options,t=e.ranges||[],n=t.length,i=[];if(n){var r=e.min,o=e.max,a=e.rangePlaceholderColor;i.push(Aq(r,o,a));for(var s=0;s<n;s++)for(var l=eq(t[s],r,o),c=i.length,d=0;d<c;d++){var u=i[d];if(u.from<=l.from&&l.from<=u.to){i.push(Aq(l.from,l.to,l.color,l.opacity)),u.from<=l.to&&l.to<=u.to&&i.push(Aq(l.to,u.to,a,l.opacity)),u.to=l.from;break}}}return i},t.prototype.getRangeRadius=function(){var e=this.arc,t=this.options,n=t.rangeSize,i=t.rangeDistance,r=t.majorTicks.size;return t.labels.position===qj?e.getRadiusX()-r-i-n:e.getRadiusX()-n},t.prototype.renderArc=function(e,t){var n=this.options;return this.arc=new ga(e,{radiusX:t,radiusY:t,startAngle:n.startAngle+xq,endAngle:n.endAngle+xq})},t.prototype.renderTicks=function(){var e=this.arc,t=this.options,n=e.clone();this.majorTickAngles=this.tickAngles(e,t.majorUnit),this.majorTicks=Dq(n,this.majorTickAngles,t.majorUnit,t.majorTicks);var i=new Tq;i.append(this.majorTicks);var r=t.majorTicks.size,o=t.minorTicks.size;if(this._tickDifference=r-o,t.labels.position===qj){var a=n.getRadiusX();n.setRadiusX(a-r+o).setRadiusY(a-r+o)}return this.minorTickAngles=this.normalizeTickAngles(this.tickAngles(e,t.minorUnit)),this.minorTicks=Dq(n,this.minorTickAngles,t.minorUnit,t.minorTicks),i.append(this.minorTicks),i},t.prototype.normalizeTickAngles=function(e){for(var t=this.options,n=t.majorUnit/t.minorUnit,i=e.length-1;i>=0;i--)i%n==0&&e.splice(i,1);return e},t.prototype.tickAngles=function(e,t){var n=this.options,i=n.reverse,r=n.max-n.min,o=e.endAngle-e.startAngle,a=r/t,s=e.startAngle,l=o/a;i&&(s+=o,l=-l),o>=360&&n.max%t==0&&(a-=1);for(var c=[],d=0;d<a;d++)c.push(xR(s,3)),s+=l;return xR(s)<=e.endAngle&&c.push(s),c},t.prototype.radius=function(e){if(!e)return this.arc.getRadiusX();this.arc.setRadiusX(e).setRadiusY(e),this.repositionTicks(this.majorTicks.children,this.majorTickAngles),this.repositionTicks(this.minorTicks.children,this.minorTickAngles,!0)},t.prototype.repositionTicks=function(e,t,n){var i=n&&this._tickDifference||0,r=this.arc,o=r.getRadiusX();n&&this.options.labels.position===qj&&0!==i&&(r=this.arc.clone()).setRadiusX(o-i).setRadiusY(o-i);for(var a=0;a<e.length;a++){var s=r.pointAt(t[a]),l=e[a].segments,c=s.x-l[0].anchor().x,d=s.y-l[0].anchor().y;e[a].transform((new Xo).translate(c,d))}},t}(kO);DR(Mq,{min:0,max:100,majorTicks:{size:15,align:Wj,color:FH,width:$j,visible:!0},minorTicks:{size:10,align:Wj,color:FH,width:$j,visible:!0},startAngle:-30,endAngle:210,labels:{position:Wj,padding:2}});var Eq=function(e){function t(t,n){e.call(this,t,n);var i=this.options;i.duration=Math.max(Math.abs(i.newAngle-i.oldAngle)/i.duration*1e3,1)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.step=function(e){var t=this.options,n=nR(t.oldAngle,t.newAngle,e);this.element.transform(Xo().rotate(n,t.center))},t}(nl);DR(Eq,{easing:jj,duration:Oj}),tl.current.register(Gj,Eq);var Iq=ua,zq=vs,Pq=us,Hq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.setAngle=function(e){this.elements.transform(Xo().rotate(e,this.center))},t.prototype.repaint=function(){var e=this.scale,t=this.options,n=e.slotAngle(t._oldValue),i=e.slotAngle(t.value);!1===t.animation.transitions?this.setAngle(i):new Eq(this.elements,BF(t.animation,{oldAngle:n,newAngle:i})).play()},t.prototype.render=function(){var e=this.scale,t=this.options,n=new zq;return!1!==t.animation&&BF(t.animation,{startAngle:0,center:e.arc.center,reverse:e.options.reverse}),n.append(this._renderNeedle(),this._renderCap()),this.elements=n,this.setAngle(Uj),n},t.prototype.reflow=function(e){var t=this.center=e.center,n=yR(this.options.length||1,.1,1.5),i=this.radius=e.getRadiusX()*n,r=this.capSize=Math.round(i*this.options.cap.size);this.bbox=Yo.fromPoints(new Go(t.x-r,t.y-r),new Go(t.x+r,t.y+r))},t.prototype._renderNeedle=function(){var e=this.scale.options.minorTicks.size,t=this.center,n=this.options.color,i=new Pq({fill:{color:n},stroke:{color:n,width:$j}});return i.moveTo(t.x+this.radius-e,t.y).lineTo(t.x,t.y-this.capSize/2).lineTo(t.x,t.y+this.capSize/2).close(),i},t.prototype._renderCap=function(){var e=this.options,t=e.cap.color||e.color,n=new oa(this.center,this.capSize);return new Iq(n,{fill:{color:t},stroke:{color:t}})},t}(uq);DR(Hq,{cap:{size:.05},arrow:{width:16,height:14},animation:{type:Gj,duration:Oj}});var Fq=vs,Rq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.reflow=function(e){var t=this,n=this.pointers;this.scale.reflow(e),this._initialPlotArea=this.scale.bbox;for(var i=0;i<n.length;i++)n[i].reflow(t.scale.arc),t._initialPlotArea=Yo.union(t._initialPlotArea,n[i].bbox);this.fitScale(e),this.alignScale(e),this._buildVisual(this.gaugeArea,n,this.scale),this._draw()},t.prototype._buildVisual=function(e,t,n){var i=this._visuals=new Fq;i.append(e),i.append(n.ticks),i.append(n.ranges),this._buildPointers(t),i.append(n.labelElements)},t.prototype._buildPointers=function(e){for(var t=0;t<e.length;t++){var n=e[t];n.render(),this._visuals.append(n.elements),n.value(n.options.value)}},t.prototype.fitScale=function(e){for(var t,n,i,r,o,a=this,s=this.scale.arc,l=this._initialPlotArea,c=Math.abs(this.getDiff(l,e)),d=xR(c,3),u=xR(-c,3),h=0,p=0;!(!(p++<100)||(h=o===i?h+1:0)>5||d!==r&&0<=(t=a.getPlotBox(d,e,s))&&t<=2||u!==r&&0<=(i=a.getPlotBox(u,e,s))&&i<=2||(r=t>0&&i>0?2*d:t<0&&i<0?2*u:xR((d+u)/2||1,3),0<=(n=a.getPlotBox(r,e,s))&&n<=2));)o=i,n>0?(u=r,i=n):(d=r,t=n)},t.prototype.getPlotBox=function(e,t,n){var i=this.scale,r=this.pointers,o=n.getRadiusX(),a=n.clone();a.setRadiusX(o+e).setRadiusY(o+e),i.arc=a,i.reflow(t),this.plotBbox=i.bbox;for(var s=0;s<r.length;s++)r[s].reflow(a),this.plotBbox=Yo.union(this.plotBbox,r[s].bbox);return this.getDiff(this.plotBbox,t)},t.prototype.getDiff=function(e,t){return Math.min(t.width()-e.width(),t.height()-e.height())},t.prototype.alignScale=function(e){var t=this.plotBbox.center(),n=e.center(),i=t.x-n.x,r=t.y-n.y,o=this.scale,a=this.pointers;o.arc.center.x-=i,o.arc.center.y-=r,o.reflow(e);for(var s=0;s<a.length;s++)a[s].reflow(o.arc),this.plotBbox=Yo.union(o.bbox,a[s].bbox)},t.prototype._createModel=function(){var e=this.options,t=e.pointer,n=this.scale=new Mq(e.scale,this.contextService);this.pointers=[];for(var i=xF(t)?t:[t],r=0;r<i.length;r++){var o=new Hq(n,BF({},i[r],{animation:{transitions:e.transitions}}));this.pointers.push(o)}},t}(rq);DR(Rq,{transitions:!0,gaugeArea:{background:""}});var Lq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.rangeSegments=function(){var e=this.options;return[{from:e.min,to:e.max,color:e.rangePlaceholderColor,lineCap:e.rangeLineCap}]},t.prototype.hasRanges=function(){return!0},t.prototype.placeholderRangeAngle=function(e){var t=this.ranges.children[0].geometry();this.options.reverse?t.setEndAngle(e):t.setStartAngle(e)},t.prototype.addRange=function(e,t,n){var i=this.options.reverse,r=this.slotAngle(i?t:e),o=this.slotAngle(i?e:t),a=this.createRange(r,o,this.getRangeRadius(),n);return this.ranges.append(a),a},t}(Mq);DR(Lq,{min:0,max:100,majorTicks:{visible:!1},minorTicks:{visible:!1},labels:{visible:!1},startAngle:0,endAngle:180,rangeLineCap:"round"});var Bq=function(e){function t(t,n){e.call(this,t,n);var i=this.options,r=Math.abs(i.newAngle-i.oldAngle)/i.duration*1e3;i.duration=yR(r,Oj,800);var o=t.elements.options.get("stroke.color"),a=t.currentColor();o!==a&&(this.startColor=new qr(o),this.color=new qr(a))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.step=function(e){var t=this,n=t.options,i=t.startColor,r=t.color,o=nR(n.oldAngle,n.newAngle,e);if(this.element.angle(o),r){var a=xR(nR(i.r,r.r,e)),s=xR(nR(i.g,r.g,e)),l=xR(nR(i.b,r.b,e));this.element.stroke(new qr(a,s,l).toHex())}},t}(nl);DR(Bq,{easing:jj,duration:Oj}),tl.current.register(Kj,Bq);var Oq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.repaint=function(){var e=this.scale,t=this.options,n=e.slotAngle(t._oldValue),i=e.slotAngle(t.value);this.animation&&this.animation.abort(),!1===t.animation.transitions?(this.angle(i),this.stroke(this.currentColor())):(this.animation=new Bq(this,BF(t.animation,{oldAngle:n,newAngle:i})),this.animation.play())},t.prototype.angle=function(e){var t=this.elements.geometry();this.scale.options.reverse?t.setStartAngle(e):t.setEndAngle(e),this.scale.placeholderRangeAngle(e)},t.prototype.stroke=function(e){this.elements.stroke(e)},t.prototype.render=function(){if(!this.elements){var e=this.scale,t=this.options;!1!==t.animation&&BF(t.animation,{startAngle:0,center:e.arc.center,reverse:e.options.reverse}),this.elements=e.addRange(e.options.min,this.options.value,{color:this.currentColor(),opacity:t.opacity,lineCap:e.options.rangeLineCap})}},t.prototype.currentColor=function(){var e=this.scale.options,t=e.min,n=e.max,i=this.options,r=i.colors,o=i.color,a=i.value,s=MF(a)?a:t;if(r)for(var l=0;l<r.length;l++){var c=r[l],d=c.color,u=c.from;void 0===u&&(u=t);var h=c.to;if(void 0===h&&(h=n),u<=s&&s<=h)return d}return o},t.prototype.reflow=function(){this.render(),this.bbox=this.elements.bbox()},t}(uq);DR(Oq,{animation:{type:Kj,duration:Oj}});var Vq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._initTheme=function(t){e.prototype._initTheme.call(this,t),this.options.color=this.options.color||(this.theme.pointer||{}).color},t.prototype._createModel=function(){var e=this.options,t=this.scale=new Lq(e.scale,this.contextService),n=new Oq(t,BF({},{colors:e.colors,color:e.color,value:e.value,opacity:e.opacity,animation:{transitions:e.transitions}}));this.pointers=[n]},t.prototype._buildPointers=function(e){for(var t=0;t<e.length;t++){var n=e[t];n.render(),n.value(n.options.value)}},t.prototype._setValueOptions=function(e){this.options.value=e},t.prototype.currentColor=function(){var e=this.pointers[0];if(e)return e.currentColor()},t.prototype.centerLabelPosition=function(e,t){var n=this.getSize(),i=this.scale.arc.center,r=i.x-e/2,o=i.y-t/2;if(e<n.width){var a=r+e;r=Math.max(r,0),a>n.width&&(r-=a-n.width)}if(t<n.height){var s=this.scale.bbox,l=s.bottomRight().y,c=o+t;o=Math.max(o,s.origin.y),c>l&&(o-=c-l)}return{left:r,top:o}},t}(Rq),Nq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._createModel=function(){var t=this.options.scale;"number"!=typeof t.startAngle&&(t.startAngle=90),t.endAngle=t.startAngle+360,e.prototype._createModel.call(this)},t}(Vq),$q=function(e){function t(t){e.call(this),this.setOptions(t),this.initProperties()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){},t.prototype.setOptions=function(e){this.options=Object.assign({},this.options,e),this.quietZoneLength=this.options.addQuietZone?2*this.options.quietZoneLength:0},t.prototype.encode=function(e,t,n){var i=hR(e)?String(e):e;return this.initValue(i,t,n),this.options.addQuietZone&&this.addQuietZone(),this.addData(),this.options.addQuietZone&&this.addQuietZone(),{baseUnit:this.baseUnit,pattern:this.pattern}},t.prototype.initValue=function(){},t.prototype.addQuietZone=function(){this.pattern.push(this.options.quietZoneLength||10)},t.prototype.addData=function(){},t.prototype.invalidCharacterError=function(e){throw new Error('Character "'+e+'" is not valid for symbology '+this.name+".")},t}(fr);DR($q,{quietZoneLength:10,addQuietZone:!0,addCheckSum:!0});var Uq=Object.assign,Wq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),Uq(this,{name:"Code 11",characterMap:["111121","211121","121121","221111","112121","212111","122111","111221","211211","211111","112111"],cCheckSumTotal:10,kCheckSumTotal:9,kCheckSumMinLength:10,checkSumMod:11,DASH_VALUE:10,DASH:"-",START:"112211",STOP:"11221"})},t.prototype.initValue=function(e,t){this.pattern=[],this.value=e,this.width=t,this.totalUnits=0},t.prototype.addData=function(){var e=this.value;this.addPattern(this.START);for(var t=0;t<e.length;t++)this.addCharacter(e.charAt(t));this.options.addCheckSum&&this.addCheckSum(),this.addPattern(this.STOP),this.setBaseUnit()},t.prototype.setBaseUnit=function(){this.baseUnit=this.width/(this.totalUnits+this.quietZoneLength)},t.prototype.addCheckSum=function(){var e=this.value,t=e.length,n=this.getWeightedSum(e,t,this.cCheckSumTotal)%this.checkSumMod;if(this.checksum=String(n),this.addPattern(this.characterMap[n]),++t>=this.kCheckSumMinLength){var i=(n+this.getWeightedSum(e,t,this.kCheckSumTotal))%this.checkSumMod;this.checksum+=i,this.addPattern(this.characterMap[i])}},t.prototype.getWeightedSum=function(e,t,n){for(var i=0,r=0;r<e.length;r++)i+=this.weightedValue(this.getValue(e.charAt(r)),t,r,n);return i},t.prototype.weightedValue=function(e,t,n,i){return((t-n)%i||i)*e},t.prototype.getValue=function(e){return isNaN(e)?(e!==this.DASH&&this.invalidCharacterError(e),this.DASH_VALUE):parseInt(e,10)},t.prototype.addCharacter=function(e){var t=this.getValue(e),n=this.characterMap[t];this.addPattern(n)},t.prototype.addPattern=function(e){for(var t,n=0;n<e.length;n++)t=parseInt(e.charAt(n),10),this.pattern.push(t),this.totalUnits+=t},t}($q);DR(Wq,{addCheckSum:!0});var jq=Object.assign,qq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),jq(this,{minBaseUnitLength:.7})},t.prototype.addData=function(){var e=this.value;this.addStart();for(var t=0;t<e.length;t++)this.addCharacter(e.charAt(t));this.options.addCheckSum&&this.pushCheckSum(),this.addStop(),this.prepareValues()},t.prototype.addCharacter=function(e){var t=this.characterMap[e];t||this.invalidCharacterError(e),this.addBase(t)},t.prototype.addBase=function(){},t}($q),Gq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),jq(this,{name:"Code 39",checkSumMod:43,minRatio:2.5,maxRatio:3,gapWidth:1,splitCharacter:"|",patternMappings:{b:"1|",w:"1|",B:"ratio|",W:"ratio|"},characterMap:{0:{pattern:"bwbWBwBwb",value:0},1:{pattern:"BwbWbwbwB",value:1},2:{pattern:"bwBWbwbwB",value:2},3:{pattern:"BwBWbwbwb",value:3},4:{pattern:"bwbWBwbwB",value:4},5:{pattern:"BwbWBwbwb",value:5},6:{pattern:"bwBWBwbwb",value:6},7:{pattern:"bwbWbwBwB",value:7},8:{pattern:"BwbWbwBwb",value:8},9:{pattern:"bwBWbwBwb",value:9},A:{pattern:"BwbwbWbwB",value:10},B:{pattern:"bwBwbWbwB",value:11},C:{pattern:"BwBwbWbwb",value:12},D:{pattern:"bwbwBWbwB",value:13},E:{pattern:"BwbwBWbwb",value:14},F:{pattern:"bwBwBWbwb",value:15},G:{pattern:"bwbwbWBwB",value:16},H:{pattern:"BwbwbWBwb",value:17},I:{pattern:"bwBwbWBwb",value:18},J:{pattern:"bwbwBWBwb",value:19},K:{pattern:"BwbwbwbWB",value:20},L:{pattern:"bwBwbwbWB",value:21},M:{pattern:"BwBwbwbWb",value:22},N:{pattern:"bwbwBwbWB",value:23},O:{pattern:"BwbwBwbWb",value:24},P:{pattern:"bwBwBwbWb",value:25},Q:{pattern:"bwbwbwBWB",value:26},R:{pattern:"BwbwbwBWb",value:27},S:{pattern:"bwBwbwBWb",value:28},T:{pattern:"bwbwBwBWb",value:29},U:{pattern:"BWbwbwbwB",value:30},V:{pattern:"bWBwbwbwB",value:31},W:{pattern:"BWBwbwbwb",value:32},X:{pattern:"bWbwBwbwB",value:33},Y:{pattern:"BWbwBwbwb",value:34},Z:{pattern:"bWBwBwbwb",value:35},"-":{pattern:"bWbwbwBwB",value:36},".":{pattern:"BWbwbwBwb",value:37}," ":{pattern:"bWBwbwBwb",value:38},$:{pattern:"bWbWbWbwb",value:39},"/":{pattern:"bWbWbwbWb",value:40},"+":{pattern:"bWbwbWbWb",value:41},"%":{pattern:"bwbWbWbWb",value:42},START:{pattern:"bWbwBwBwb"}}})},t.prototype.initValue=function(e,t,n){this.width=t,this.height=n,this.value=e,this.dataLength=e.length,this.pattern=[],this.patternString=""},t.prototype.prepareValues=function(){var e,t=this.minBaseUnitLength,n=this.minRatio,i=Math.ceil(Math.max(.15*this.width,24)),r=this.maxRatio;if(this.height<i)throw new Error("Insufficient height for Code39 encoding: the current height is "+this.height+"px and the minimum height is "+i+"px.");for(e=this.getBaseUnit(r);e<t&&r>n;)r=parseFloat((r-.1).toFixed(1)),e=this.getBaseUnit(r);if(e<t){var o=Math.ceil(this.getBaseWidth(n)*t);throw new Error("Insufficient width for Code39 encoding: the current width is "+this.width+'px and the minimum width for value "'+this.value+'" is '+o+"px.")}this.ratio=r,this.baseUnit=e,this.patternString=this.patternString.substring(0,this.patternString.length-1),this.pattern=this.pattern.concat(this.patternString.replace(/ratio/g,r).split(this.splitCharacter))},t.prototype.getBaseUnit=function(e){return this.width/this.getBaseWidth(e)},t.prototype.getBaseWidth=function(e){var t=3*(e+2);return this.quietZoneLength+t*(this.dataLength+2)+this.gapWidth*(this.dataLength+1)},t.prototype.addStart=function(){this.addPattern(this.characterMap.START.pattern),this.addCharacterGap()},t.prototype.addBase=function(e){this.addPattern(e.pattern),this.addCharacterGap()},t.prototype.addStop=function(){this.addPattern(this.characterMap.START.pattern)},t.prototype.addPattern=function(e){for(var t=0;t<e.length;t++)this.patternString+=this.patternMappings[e.charAt(t)]},t.prototype.addCharacterGap=function(){this.patternString+=this.gapWidth+this.splitCharacter},t}(qq);DR(Gq,{addCheckSum:!1});var Kq={addCharacter:function(e){this.characterMap[e]?this.addBase(this.characterMap[e]):e.charCodeAt(0)>127?this.invalidCharacterError(e):this.addExtended(e.charCodeAt(0))},addExtended:function(e){for(var t,n=this,i=0;i<this.extendedMappings.length;i++)if(t=n.extendedMappings[i].call(n,e)){for(var r=0;r<t.length;r++){var o=t[r];n.addBase(o)}return void(n.dataLength+=t.length-1)}},extendedMappings:[function(e){if(97<=e&&e<=122)return[this.characterMap[this.shiftCharacters[0]],this.characterMap[String.fromCharCode(e-32)]]},function(e){if(33<=e&&e<=58)return[this.characterMap[this.shiftCharacters[1]],this.characterMap[String.fromCharCode(e+32)]]},function(e){if(1<=e&&e<=26)return[this.characterMap[this.shiftCharacters[2]],this.characterMap[String.fromCharCode(e+64)]]},function(e){var t,n,i=this;if(this.specialAsciiCodes[e]){t=[];for(var r=0;r<this.specialAsciiCodes[e].length;r++)t.push(i.characterMap[i.shiftCharacters[3]]),t.push(i.characterMap[i.specialAsciiCodes[e][r]])}else n=6*Math.floor(e/32)+(e-27)%32+64,t=[this.characterMap[this.shiftCharacters[3]],this.characterMap[String.fromCharCode(n)]];return t}],specialAsciiCodes:{0:["U"],64:["V"],96:["W"],127:["T","X","Y","Z"]},shiftValuesAsciiCodes:{39:36,40:47,41:43,42:37},characterMap:{"+":!1,"/":!1,$:!1,"%":!1},shiftCharacters:["SHIFT0","SHIFT1","SHIFT2","SHIFT3"]},Yq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),BF(this,Kq,{name:"Code 39 extended",characterMap:{SHIFT0:{pattern:"bWbwbWbWb",value:41},SHIFT1:{pattern:"bWbWbwbWb",value:40},SHIFT2:{pattern:"bWbWbWbwb",value:39},SHIFT3:{pattern:"bwbWbWbWb",value:42}}})},t}(Gq),Qq=Object.assign,Xq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),Qq(this,{name:"Code 93",cCheckSumTotal:20,kCheckSumTotal:15,checkSumMod:47,characterMap:{0:{pattern:"131112",value:0},1:{pattern:"111213",value:1},2:{pattern:"111312",value:2},3:{pattern:"111411",value:3},4:{pattern:"121113",value:4},5:{pattern:"121212",value:5},6:{pattern:"121311",value:6},7:{pattern:"111114",value:7},8:{pattern:"131211",value:8},9:{pattern:"141111",value:9},A:{pattern:"211113",value:10},B:{pattern:"211212",value:11},C:{pattern:"211311",value:12},D:{pattern:"221112",value:13},E:{pattern:"221211",value:14},F:{pattern:"231111",value:15},G:{pattern:"112113",value:16},H:{pattern:"112212",value:17},I:{pattern:"112311",value:18},J:{pattern:"122112",value:19},K:{pattern:"132111",value:20},L:{pattern:"111123",value:21},M:{pattern:"111222",value:22},N:{pattern:"111321",value:23},O:{pattern:"121122",value:24},P:{pattern:"131121",value:25},Q:{pattern:"212112",value:26},R:{pattern:"212211",value:27},S:{pattern:"211122",value:28},T:{pattern:"211221",value:29},U:{pattern:"221121",value:30},V:{pattern:"222111",value:31},W:{pattern:"112122",value:32},X:{pattern:"112221",value:33},Y:{pattern:"122121",value:34},Z:{pattern:"123111",value:35},"-":{pattern:"121131",value:36},".":{pattern:"311112",value:37}," ":{pattern:"311211",value:38},$:{pattern:"321111",value:39},"/":{pattern:"112131",value:40},"+":{pattern:"113121",value:41},"%":{pattern:"211131",value:42},SHIFT0:{pattern:"122211",value:46},SHIFT1:{pattern:"311121",value:45},SHIFT2:{pattern:"121221",value:43},SHIFT3:{pattern:"312111",value:44},START:{pattern:"111141"},TERMINATION_BAR:"1"}})},t.prototype.initValue=function(e,t,n){this.value=e,this.width=t,this.height=n,this.pattern=[],this.values=[],this.dataLength=e.length},t.prototype.prepareValues=function(){var e=Math.ceil(Math.max(.15*this.width,24));if(this.height<e)throw new Error("Insufficient height for Code93 encoding: the current height is "+this.height+"px, the minimum required height is "+e+"px.");if(this.setBaseUnit(),this.baseUnit<this.minBaseUnitLength){var t=Math.ceil(this.minBaseUnitLength*(this.width/this.baseUnit));throw new Error("Insufficient width for Code93 encoding: the current width is "+this.width+'px and the minimum required width for value "'+this.value+'" is '+t+"px.")}},t.prototype.setBaseUnit=function(){this.baseUnit=this.width/(9*(this.dataLength+2+2)+this.quietZoneLength+1)},t.prototype.addStart=function(){var e=this.characterMap.START.pattern;this.addPattern(e)},t.prototype.addStop=function(){this.addStart(),this.pattern.push(this.characterMap.TERMINATION_BAR)},t.prototype.addBase=function(e){this.addPattern(e.pattern),this.values.push(e.value)},t.prototype.pushCheckSum=function(){var e,t=this,n=this._getCheckValues();this.checksum=n.join("");for(var i=0;i<n.length;i++)e=t.characterMap[t._findCharacterByValue(n[i])],t.addPattern(e.pattern)},t.prototype._getCheckValues=function(){var e,t,n=this,i=this.values,r=i.length,o=0;for(t=r-1;t>=0;t--)o+=n.weightedValue(i[t],r-t,n.cCheckSumTotal);for(e=o%this.checkSumMod,o=this.weightedValue(e,1,this.kCheckSumTotal),t=r-1;t>=0;t--)o+=n.weightedValue(i[t],r-t+1,n.kCheckSumTotal);return[e,o%this.checkSumMod]},t.prototype._findCharacterByValue=function(e){for(var t in this.characterMap)if(this.characterMap[t].value===e)return t},t.prototype.weightedValue=function(e,t,n){return(t%n||n)*e},t.prototype.addPattern=function(e){for(var t,n=0;n<e.length;n++)t=parseInt(e.charAt(n),10),this.pattern.push(t)},t}(qq),Zq=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),BF(this,Kq,{name:"Code 93 extended",pushCheckSum:function(){var e,t=this,n=this._getCheckValues();this.checksum=n.join("");for(var i=0;i<n.length;i++)if(e=n[i],t.shiftValuesAsciiCodes[e])t.addExtended(t.shiftValuesAsciiCodes[e]);else{var r=t._findCharacterByValue(e);t.addPattern(t.characterMap[r].pattern)}}})},t}(Xq),Jq=/^\d+$/,eG=Object.assign,tG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),eG(this,{name:"Postnet",START:"2",VALID_CODE_LENGTHS:[5,9,11],DIGIT_SEPARATOR:"-",characterMap:["22111","11122","11212","11221","12112","12121","12211","21112","21121","21211"]})},t.prototype.initValue=function(e,t,n){this.height=n,this.width=t,this.baseHeight=n/2,this.value=e.replace(new RegExp(this.DIGIT_SEPARATOR,"g"),""),this.pattern=[],this.validate(this.value),this.checkSum=0,this.setBaseUnit()},t.prototype.addData=function(){var e=this.value;this.addPattern(this.START);for(var t=0;t<e.length;t++)this.addCharacter(e.charAt(t));this.options.addCheckSum&&this.addCheckSum(),this.addPattern(this.START),this.pattern.pop()},t.prototype.addCharacter=function(e){var t=this.characterMap[e];this.checkSum+=parseInt(e,10),this.addPattern(t)},t.prototype.addCheckSum=function(){this.checksum=(10-this.checkSum%10)%10,this.addCharacter(this.checksum)},t.prototype.setBaseUnit=function(){this.baseUnit=this.width/(10*(this.value.length+1)+3+this.quietZoneLength)},t.prototype.validate=function(e){if(Jq.test(e)||this.invalidCharacterError(e.match(/[^0-9]/)[0]),!tR(e.length,this.VALID_CODE_LENGTHS))throw new Error("Invalid value length. Valid lengths for the Postnet symbology are "+this.VALID_CODE_LENGTHS.join(",")+".")},t.prototype.addPattern=function(e){for(var t,n=this,i=0;i<e.length;i++)t=n.height-n.baseHeight*e.charAt(i),n.pattern.push({width:1,y1:t,y2:n.height}),n.pattern.push(1)},t}($q),nG=/^\d+$/,iG=/^[a-z0-9]+$/i,rG=Object.assign,oG=function(e){function t(t){e.call(this),this.encoding=t,this.initProperties()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){},t.prototype.addStart=function(){},t.prototype.is=function(){},t.prototype.isCode=function(){return!1},t.prototype.move=function(){},t.prototype.pushState=function(){},t}(fr),aG=function(e){function t(t,n){e.call(this,t),this.states=n,this._initMoves(n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),BF(this,{FNC4:"FNC4",SHIFT:98})},t.prototype.addStart=function(){this.encoding.addPattern(this.START)},t.prototype.is=function(e,t){var n=e.charCodeAt(t);return this.isCode(n)},t.prototype.move=function(e){for(var t=0;!this._moves[t].call(this,e)&&t<this._moves.length;)t++},t.prototype.pushState=function(e){var t,n=this.states,i=e.value,r=i.length;if(tR("C",n)){var o=i.substr(e.index).match(/\d{4,}/g);o&&(r=i.indexOf(o[0],e.index))}for(;(t=e.value.charCodeAt(e.index))>=0&&this.isCode(t)&&e.index<r;)this.encoding.addPattern(this.getValue(t)),e.index++},t.prototype._initMoves=function(e){this._moves=[],tR(this.FNC4,e)&&this._moves.push(this._moveFNC),tR(this.shiftKey,e)&&this._moves.push(this._shiftState),this._moves.push(this._moveState)},t.prototype._moveFNC=function(e){if(e.fnc)return e.fnc=!1,e.previousState===this.key},t.prototype._shiftState=function(e){if(e.previousState===this.shiftKey&&(e.index+1>=e.value.length||this.encoding[this.shiftKey].is(e.value,e.index+1)))return this.encoding.addPattern(this.SHIFT),e.shifted=!0,!0},t.prototype._moveState=function(){return this.encoding.addPattern(this.MOVE),!0},t}(oG),sG={};sG.A=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),rG(this,{key:"A",shiftKey:"B",MOVE:101,START:103})},t.prototype.isCode=function(e){return 0<=e&&e<96},t.prototype.getValue=function(e){return e<32?e+64:e-32},t}(aG),sG.B=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),rG(this,{key:"B",shiftKey:"A",MOVE:100,START:104})},t.prototype.isCode=function(e){return 32<=e&&e<128},t.prototype.getValue=function(e){return e-32},t}(aG),sG.C=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),rG(this,{key:"C",MOVE:99,START:105})},t.prototype.addStart=function(){this.encoding.addPattern(this.START)},t.prototype.is=function(e,t){var n=fG(e,t,4);return(t+4<=e.length||2===e.length)&&nG.test(n)},t.prototype.move=function(){this.encoding.addPattern(this.MOVE)},t.prototype.pushState=function(e){for(var t;(t=fG(e.value,e.index,2))&&nG.test(t)&&2===t.length;)this.encoding.addPattern(parseInt(t,10)),e.index+=2},t.prototype.getValue=function(e){return e},t}(oG),sG.FNC4=function(e){function t(t,n){e.call(this,t),this._initSubStates(n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),rG(this,{key:"FNC4",dependentStates:["A","B"]})},t.prototype.addStart=function(e){var t=e.value.charCodeAt(0)-128,n=this._getSubState(t);this.encoding[n].addStart()},t.prototype.is=function(e,t){var n=e.charCodeAt(t);return this.isCode(n)},t.prototype.isCode=function(e){return 128<=e&&e<256},t.prototype.pushState=function(e){var t,n=this._initSubState(e),i=this.encoding,r=n.value.length;if(e.index+=r,r<3)for(;n.index<r;n.index++)t=n.value.charCodeAt(n.index),n.state=this._getSubState(t),n.previousState!==n.state&&(n.previousState=n.state,i[n.state].move(n)),i.addPattern(i[n.state].MOVE),i.addPattern(i[n.state].getValue(t));else n.state!==n.previousState&&i[n.state].move(n),this._pushStart(n),i.pushData(n,this.subStates),e.index<e.value.length&&this._pushStart(n);e.fnc=!0,e.state=n.state},t.prototype._pushStart=function(e){this.encoding.addPattern(this.encoding[e.state].MOVE),this.encoding.addPattern(this.encoding[e.state].MOVE)},t.prototype._initSubState=function(e){var t={value:this._getAll(e.value,e.index),index:0};return t.state=this._getSubState(t.value.charCodeAt(0)),t.previousState=e.previousState===this.key?t.state:e.previousState,t},t.prototype._initSubStates=function(e){this.subStates=[];for(var t=0;t<e.length;t++)tR(e[t],this.dependentStates)&&this.subStates.push(e[t])},t.prototype._getSubState=function(e){for(var t=this,n=0;n<this.subStates.length;n++)if(t.encoding[t.subStates[n]].isCode(e))return t.subStates[n]},t.prototype._getAll=function(e,t){for(var n,i="",r=t;(n=e.charCodeAt(r++))&&this.isCode(n);)i+=String.fromCharCode(n-128);return i},t}(oG),sG.FNC1=function(e){function t(t,n){e.call(this,t),this.states=n}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),rG(this,{key:"FNC1",startState:"C",startAI:"(",endAI:")",dependentStates:["C","B"],applicationIdentifiers:{22:{max:29,type:"alphanumeric"},402:{length:17},7004:{max:4,type:"alphanumeric"},242:{max:6,type:"alphanumeric"},8020:{max:25,type:"alphanumeric"},703:{min:3,max:30,type:"alphanumeric"},8008:{min:8,max:12,type:"alphanumeric"},253:{min:13,max:17,type:"alphanumeric"},8003:{min:14,max:30,type:"alphanumeric"},multiKey:[{ids:["15","17","8005","8100"],ranges:[[11,13],[310,316],[320,336],[340,369]],type:{length:6}},{ids:["240","241","250","251","400","401","403","7002","8004","8007","8110"],ranges:[[-9]],type:{max:30,type:"alphanumeric"}},{ids:["7001"],ranges:[[410,414]],type:{length:13}},{ids:["10","21","254","420","8002"],type:{max:20,type:"alphanumeric"}},{ids:["00","8006","8017","8018"],type:{length:18}},{ids:["01","02","8001"],type:{length:14}},{ids:["422"],ranges:[[424,426]],type:{length:3}},{ids:["20","8102"],type:{length:2}},{ids:["30","37"],type:{max:8,type:"alphanumeric"}},{ids:["390","392"],type:{max:15,type:"alphanumeric"}},{ids:["421","423"],type:{min:3,max:15,type:"alphanumeric"}},{ids:["391","393"],type:{min:3,max:18,type:"alphanumeric"}},{ids:["7003","8101"],type:{length:10}}]},START:102})},t.prototype.addStart=function(){this.encoding[this.startState].addStart()},t.prototype.is=function(){return tR(this.key,this.states)},t.prototype.pushState=function(e){var t,n,i,r=this,o=this.encoding,a=e.value.replace(/\s/g,""),s=new RegExp("["+this.startAI+this.endAI+"]","g"),l=e.index,c={state:this.startState};o.addPattern(this.START);for(;;){if(c.index=0,(t=(i=a.charAt(l)===r.startAI?2:0)>0?r.getBySeparator(a,l):r.getByLength(a,l)).ai.length)n=l+i+t.id.length+t.ai.length;else if((n=a.indexOf(r.startAI,l+1))<0){if(l+t.ai.max+t.id.length+i<a.length)throw new Error("Separators are required after variable length identifiers");n=a.length}if(c.value=a.substring(l,n).replace(s,""),r.validate(t,c.value),o.pushData(c,r.dependentStates),n>=a.length)break;l=n,c.state!==r.startState&&(o[r.startState].move(c),c.state=r.startState),t.ai.length||o.addPattern(r.START)}e.index=e.value.length},t.prototype.validate=function(e,t){var n=t.substr(e.id.length),i=e.ai;if(!i.type&&!nG.test(n))throw new Error("Application identifier "+e.id+" is numeric only but contains non numeric character(s).");if("alphanumeric"===i.type&&!iG.test(n))throw new Error("Application identifier "+e.id+" is alphanumeric only but contains non alphanumeric character(s).");if(i.length&&i.length!==n.length)throw new Error("Application identifier "+e.id+" must be "+i.length+" characters long.");if(i.min&&i.min>n.length)throw new Error("Application identifier "+e.id+" must be at least "+i.min+" characters long.");if(i.max&&i.max<n.length)throw new Error("Application identifier "+e.id+" must be at most "+i.max+" characters long.")},t.prototype.getByLength=function(e,t){for(var n,i,r=2;r<=4;r++)if(n=fG(e,t,r),i=this.getApplicationIdentifier(n)||this.getApplicationIdentifier(n.substring(0,n.length-1)))return{id:n,ai:i};this.unsupportedAIError(n)},t.prototype.unsupportedAIError=function(e){throw new Error("'"+e+"' is not a supported Application Identifier")},t.prototype.getBySeparator=function(e,t){var n=e.indexOf(this.startAI,t),i=e.indexOf(this.endAI,n),r=e.substring(n+1,i),o=this.getApplicationIdentifier(r)||this.getApplicationIdentifier(r.substr(r.length-1));return o||this.unsupportedAIError(r),{ai:o,id:r}},t.prototype.getApplicationIdentifier=function(e){var t=this.applicationIdentifiers,n=t.multiKey;if(t[e])return t[e];for(var i=0;i<n.length;i++){if(n[i].ids&&tR(e,n[i].ids))return n[i].type;if(n[i].ranges)for(var r=n[i].ranges,o=0;o<r.length;o++)if(r[o][0]<=e&&e<=r[o][1])return n[i].type}},t}(oG);var lG=function(e){function t(t){e.call(this,t),this._initStates()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),rG(this,{characterMap:[212222,222122,222221,121223,121322,131222,122213,122312,132212,221213,221312,231212,112232,122132,122231,113222,123122,123221,223211,221132,221231,213212,223112,312131,311222,321122,321221,312212,322112,322211,212123,212321,232121,111323,131123,131321,112313,132113,132311,211313,231113,231311,112133,112331,132131,113123,113321,133121,313121,211331,231131,213113,213311,213131,311123,311321,331121,312113,312311,332111,314111,221411,431111,111224,111422,121124,121421,141122,141221,112214,112412,122114,122411,142112,142211,241211,221114,413111,241112,134111,111242,121142,121241,114212,124112,124211,411212,421112,421211,212141,214121,412121,111143,111341,131141,114113,114311,411113,411311,113141,114131,311141,411131,211412,211214,211232,2331112],STOP:106})},t.prototype._initStates=function(){for(var e=this,t=0;t<this.states.length;t++)e[e.states[t]]=new sG[e.states[t]](e,e.states)},t.prototype.initValue=function(e,t,n){this.pattern=[],this.value=e,this.width=t,this.height=n,this.checkSum=0,this.totalUnits=0,this.index=0,this.position=1},t.prototype.addData=function(){var e={value:this.value,index:0,state:""};0!==this.value.length&&(e.state=e.previousState=this.getNextState(e,this.states),this.addStart(e),this.pushData(e,this.states),this.addCheckSum(),this.addStop(),this.setBaseUnit())},t.prototype.pushData=function(e,t){for(var n=this;n[e.state].pushState(e),!(e.index>=e.value.length);)if(e.shifted){var i=e.state;e.state=e.previousState,e.previousState=i,e.shifted=!1}else e.previousState=e.state,e.state=n.getNextState(e,t),n[e.state].move(e)},t.prototype.addStart=function(e){this[e.state].addStart(e),this.position=1},t.prototype.addCheckSum=function(){this.checksum=this.checkSum%103,this.addPattern(this.checksum)},t.prototype.addStop=function(){this.addPattern(this.STOP)},t.prototype.setBaseUnit=function(){this.baseUnit=this.width/(this.totalUnits+this.quietZoneLength)},t.prototype.addPattern=function(e){for(var t,n=this.characterMap[e].toString(),i=0;i<n.length;i++)t=parseInt(n.charAt(i),10),this.pattern.push(t),this.totalUnits+=t;this.checkSum+=e*this.position++},t.prototype.getNextState=function(e,t){for(var n=0;n<t.length;n++)if(this[t[n]].is(e.value,e.index))return t[n];this.invalidCharacterError(e.value.charAt(e.index))},t}($q),cG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),rG(this,{name:"Code 128 A",states:["A"]})},t}(lG),dG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),rG(this,{name:"Code 128 B",states:["B"]})},t}(lG),uG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),rG(this,{name:"Code 128 C",states:["C"]})},t}(lG),hG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),rG(this,{name:"Code 128",states:["C","B","A","FNC4"]})},t}(lG),pG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),rG(this,{name:"Code GS1-128",states:["FNC1","C","B"]})},t}(lG);function fG(e,t,n){return e.substring(t,t+n)}var mG=Object.assign,gG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),mG(this,{characterMap:["12121212","12121221","12122112","12122121","12211212","12211221","12212112","12212121","21121212","21121221"],START:"21",STOP:"121",checkSumType:"",checkSums:wG})},t.prototype.initValue=function(e,t){this.pattern=[],this.value=e,this.checkSumLength=0,this.width=t},t.prototype.setBaseUnit=function(){this.baseUnit=this.width/(12*(this.value.length+this.checkSumLength)+this.quietZoneLength+7)},t.prototype.addData=function(){var e=this.value;this.addPattern(this.START);for(var t=0;t<e.length;t++)this.addCharacter(e.charAt(t));this.options.addCheckSum&&this.addCheckSum(),this.addPattern(this.STOP),this.setBaseUnit()},t.prototype.addCharacter=function(e){var t=this.characterMap[e];t||this.invalidCharacterError(e),this.addPattern(t)},t.prototype.addPattern=function(e){for(var t=0;t<e.length;t++)this.pattern.push(parseInt(e.charAt(t),10))},t.prototype.addCheckSum=function(){var e=this,t=this.checkSums[this.checkSumType].call(this.checkSums,this.value);this.checksum=t.join("");for(var n=0;n<t.length;n++)e.checkSumLength++,e.addPattern(e.characterMap[t[n]])},t}($q),vG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),mG(this,{name:"MSI Modulo10",checkSumType:"Modulo10"})},t}(gG),_G=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),mG(this,{name:"MSI Modulo11",checkSumType:"Modulo11"})},t}(gG),bG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),mG(this,{name:"MSI Modulo10 Modulo10",checkSumType:"Modulo10Modulo10"})},t}(gG),yG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),mG(this,{name:"MSI Modulo11 Modulo10",checkSumType:"Modulo11Modulo10"})},t}(gG),wG={Modulo10:function(e){var t,n,i,r=[0,""],o=e.length%2;for(t=0;t<e.length;t++)r[(t+o)%2]+=parseInt(e.charAt(t),10);for(i=r[0],n=(2*r[1]).toString(),t=0;t<n.length;t++)i+=parseInt(n.charAt(t),10);return[(10-i%10)%10]},Modulo11:function(e){for(var t,n=0,i=e.length,r=0;r<i;r++)n+=(((i-r)%6||6)+1)*e.charAt(r);return 10!==(t=(11-n%11)%11)?[t]:[1,0]},Modulo11Modulo10:function(e){var t,n=this.Modulo11(e);return t=e+n[0],n.concat(this.Modulo10(t))},Modulo10Modulo10:function(e){var t,n=this.Modulo10(e);return t=e+n[0],n.concat(this.Modulo10(t))}},kG=Object.assign,xG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),kG(this,{name:"EAN 13",keyTable:["000000","001011","001101","001110","010011","011001","011100","010101","010110","011010"],characterMap:{digits:[[3,2,1,1],[2,2,2,1],[2,1,2,2],[1,4,1,1],[1,1,3,2],[1,2,3,1],[1,1,1,4],[1,3,1,2],[1,2,1,3],[3,1,1,2]],start:[1,1,1],middle:[1,1,1,1,1]}})},t.prototype.initValue=function(e,t,n){var i=String(e);if(12!==i.length||/\D/.test(i))throw new Error('The value of the "EAN13" encoding should be 12 symbols');this.pattern=[],this.options.height=n,this.baseUnit=t/(95+this.quietZoneLength),this.value=i,this.checksum=this.calculateChecksum(),this.leftKey=i[0],this.leftPart=i.substr(1,6),this.rightPart=i.substr(7)+this.checksum},t.prototype.addData=function(){this.addPieces(this.characterMap.start),this.addSide(this.leftPart,this.leftKey),this.addPieces(this.characterMap.middle),this.addSide(this.rightPart),this.addPieces(this.characterMap.start)},t.prototype.addSide=function(e,t){for(var n=this,i=0;i<e.length;i++)t&&parseInt(n.keyTable[t].charAt(i),10)?n.addPieces(Array.prototype.slice.call(n.characterMap.digits[e.charAt(i)]).reverse(),!0):n.addPieces(n.characterMap.digits[e.charAt(i)],!0)},t.prototype.addPieces=function(e,t){for(var n=this,i=0;i<e.length;i++)t?n.pattern.push({y1:0,y2:.95*n.options.height,width:e[i]}):n.pattern.push(e[i])},t.prototype.calculateChecksum=function(){for(var e=0,t=0,n=this.value.split("").reverse().join(""),i=0;i<n.length;i++)i%2?t+=parseInt(n.charAt(i),10):e+=parseInt(n.charAt(i),10);return(10-(3*e+t)%10)%10},t}($q),CG=Object.assign,SG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),CG(this,{name:"EAN 8"})},t.prototype.initValue=function(e,t,n){if(7!==e.length||/\D/.test(e))throw new Error("Invalid value provided");this.value=e,this.options.height=n,this.checksum=this.calculateChecksum(this.value),this.leftPart=this.value.substr(0,4),this.rightPart=this.value.substr(4)+this.checksum,this.pattern=[],this.baseUnit=t/(67+this.quietZoneLength)},t}(xG),TG={code11:Wq,code39:Gq,code39extended:Yq,code93:Xq,code93extended:Zq,code128:hG,code128a:cG,code128b:dG,code128c:uG};function DG(e,t){var n=e.style.display;"canvas"===t&&(e.style.display="block");var i={width:e.clientWidth,height:e.clientHeight};return e.style.display=n,i}TG["gs1-128"]=pG,TG.msimod10=vG,TG.msimod11=_G,TG.msimod1010=bG,TG.msimod1110=yG,TG.postnet=tG,TG.ean8=SG,TG.ean13=xG;var AG=function(e){function t(t,n,i){void 0===i&&(i=KR),e.call(this),this.options=BF({},this.options,n),this.element=t,this.onError=i,this._initElement(),this._initSurface(),this._setOptions(n),n&&hR(n.value)&&this.redraw()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this._destroySurface()},t.prototype._initElement=function(){CF(this.element,"k-barcode")},t.prototype._initSurface=function(){var e=this.options,t=this.surface;t&&t.options.type===e.renderAs||(this._destroySurface(),this._initSurfaceElement(),this.surface=this._createSurface())},t.prototype._createSurface=function(){return vc.create(this.surfaceElement,{type:this.options.renderAs})},t.prototype._destroySurface=function(){this.surface&&(this.surface.destroy(),this.surface=null,this._destroySurfaceElement())},t.prototype._initSurfaceElement=function(){this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.surfaceElement.style.position="relative",this.element.appendChild(this.surfaceElement))},t.prototype._destroySurfaceElement=function(){this.surfaceElement&&this.surfaceElement.parentNode&&(this.surfaceElement.parentNode.removeChild(this.surfaceElement),this.surfaceElement=null)},t.prototype.setOptions=function(e){this._setOptions(e),this._initSurface(),this.redraw()},t.prototype.redraw=function(){var e=this._getSize();this.surface.clear(),this.surface.setSize({width:e.width,height:e.height}),this.createVisual(),this.surface.draw(this.visual)},t.prototype.getSize=function(){return{width:this.element.offsetWidth,height:this.element.offsetHeight}},t.prototype._resize=function(){this.redraw()},t.prototype.createVisual=function(){this.visual=this._render()},t.prototype._render=function(){var e,t,n=this.options,i=n.value,r=n.text,o=WF(r.margin),a=this._getSize(),s=n.border||{},l=this.encoding,c=new VL(0,0,a.width,a.height).unpad(s.width).unpad(n.padding),d=c.height(),u=new vs;this.contentBox=c,u.append(this._getBackground(a)),r.visible&&(d-=Oo(i,{font:r.font}).height+o.top+o.bottom);try{e=l.encode(i,c.width(),d)}catch(e){return this.onError(e),u}return r.visible&&(t=i,n.checksum&&hR(l.checksum)&&(t+=" "+l.checksum),u.append(this._getText(t))),this.barHeight=d,this._bandsGroup=this._getBands(e.pattern,e.baseUnit),u.append(this._bandsGroup),u},t.prototype.exportVisual=function(){return this._render()},t.prototype._getSize=function(){var e=DG(this.element,this.options.renderAs),t=new Ko(300,100);return e.width>0&&(t.width=e.width),e.height>0&&(t.height=e.height),this.options.width&&(t.width=this.options.width),this.options.height&&(t.height=this.options.height),t},t.prototype.value=function(e){if(!hR(e))return this.options.value;this.options.value=String(e),this.redraw()},t.prototype._getBands=function(e,t){for(var n,i,r=this.contentBox,o=r.x1,a=new vs,s=0;s<e.length;s++){if(n=(i=OF(e[s])?e[s]:{width:e[s],y1:0,y2:this.barHeight}).width*t,s%2){var l=Yo.fromPoints(new Go(o,i.y1+r.y1),new Go(o+n,i.y2+r.y1)),c=us.fromRect(l,{fill:{color:this.options.color},stroke:null});a.append(c)}o+=n}return a},t.prototype._getBackground=function(e){var t=this.options,n=t.border||{},i=new VL(0,0,e.width,e.height).unpad(n.width/2);return us.fromRect(i.toRect(),{fill:{color:t.background},stroke:{color:n.width?n.color:"",width:n.width,dashType:n.dashType}})},t.prototype._getText=function(e){var t=this.options.text,n=this._textbox=new sB(e,{font:t.font,color:t.color,align:"center",vAlign:"bottom",margin:t.margin});return n.reflow(this.contentBox),n.renderVisual(),n.visual},t.prototype._setOptions=function(e){if(this.type=(e.type||this.options.type).toLowerCase(),"upca"===this.type&&(this.type="ean13",e.value="0"+e.value),"upce"===this.type&&(this.type="ean8",e.value="0"+e.value),!TG[this.type])throw new Error("Encoding '"+this.type+"' is not supported.");this.encoding=new TG[this.type],this.options=BF({},this.options,e)},t}(fr);DR(AG,{name:"Barcode",renderAs:"svg",value:"",type:"code39",checksum:!1,width:0,height:0,color:"black",background:"white",text:{visible:!0,font:"16px Consolas, Monaco, Sans Mono, monospace, sans-serif",color:"black",margin:{top:0,bottom:0,left:0,right:0}},border:{width:0,dashType:"solid",color:"black"},padding:{top:0,bottom:0,left:0,right:0}});var MG=Object.assign;function EG(e,t){for(var n=[],i=0;i<e.length;)n.push(e.substring(i,i+t)),i+=t;return n}function IG(e,t){var n=Number(e).toString(2);return n.length<t&&(n=new Array(t-n.length+1).join(0)+n),n}function zG(e){return parseInt(e,2)}var PG=function(e){function t(t){e.call(this),this.matrix=t,this.row=t.length-1,this.column=t.length-1,this.startColumn=this.column,this.dir=-1,this.c=0}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.move=function(){this.row+=this.dir*this.c,this.c^=1,this.column=this.startColumn-this.c},t.prototype.getNextCell=function(){for(var e=this;void 0!==this.matrix[this.row][this.column];)e.move(),(e.row<0||e.row>=e.matrix.length)&&(e.dir=-e.dir,e.startColumn-=8!==e.startColumn?2:3,e.column=e.startColumn,e.row=e.dir<0?e.matrix.length-1:0);return{row:this.row,column:this.column}},t.prototype.getNextRemainderCell=function(){if(this.move(),void 0===this.matrix[this.row][this.column])return{row:this.row,column:this.column}},t}(fr),HG=function(e){function t(t,n){e.call(this),this.dataString=t,this.version=n}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(fr),FG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getEncodingResult=function(e,t){var n=function(e){var t,n=[],i=0,r=e;n.push(bK(r,aK,sK,lK,t)),t=n[0].mode,r=r.substr(n[0].modeString.length);for(;r.length>0;){var o=bK(r,cK,dK,uK,t);o.mode!==t?(t=o.mode,n.push(o),i++):n[i].modeString+=o.modeString,r=r.substr(o.modeString.length)}return n}(e),i=function(e){for(var t=0,n=0;n<e.length;n++)t+=VG[e[n].mode].getStringBitsLength(e[n].modeString.length);return Math.ceil(t/8)}(n),r=yK(i,t),o=function(e,t){for(var n="",i=0;i<e.length;i++)n+=VG[e[i].mode].encode(e[i].modeString,t);return n}(n,r);return new HG(o,r)},t}(fr),RG=function(e){function t(){e.call(this),this.initProperties()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){MG(this,{modeIndicator:"",bitsInCharacterCount:[]})},t.prototype.getVersionIndex=function(e){return e<10?0:e>26?2:1},t.prototype.getBitsCharacterCount=function(e){return this.bitsInCharacterCount[this.getVersionIndex(e||40)]},t.prototype.getModeCountString=function(e,t){return this.modeIndicator+IG(e,this.getBitsCharacterCount(t))},t.prototype.encode=function(){},t.prototype.getStringBitsLength=function(){},t.prototype.getValue=function(){},t}(fr),LG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),MG(this,{bitsInCharacterCount:[10,12,14],modeIndicator:"0001"})},t.prototype.getValue=function(e){return parseInt(e,10)},t.prototype.encode=function(e,t){var n,i=EG(e,3),r=this.getModeCountString(e.length,t);for(n=0;n<i.length-1;n++)r+=IG(i[n],10);return r+IG(i[n],1+3*i[n].length)},t.prototype.getStringBitsLength=function(e,t){var n=e%3;return 4+this.getBitsCharacterCount(t)+10*Math.floor(e/3)+3*n+(0===n?0:1)},t}(RG),BG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),MG(this,{characters:{0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,G:16,H:17,I:18,J:19,K:20,L:21,M:22,N:23,O:24,P:25,Q:26,R:27,S:28,T:29,U:30,V:31,W:32,X:33,Y:34,Z:35," ":36,$:37,"%":38,"*":39,"+":40,"-":41,".":42,"/":43,":":44},bitsInCharacterCount:[9,11,13],modeIndicator:"0010"})},t.prototype.getValue=function(e){return this.characters[e]},t.prototype.encode=function(e,t){var n,i=EG(e,2),r=this.getModeCountString(e.length,t);for(n=0;n<i.length-1;n++)r+=IG(45*this.getValue(i[n].charAt(0))+this.getValue(i[n].charAt(1)),11);return r+IG(2===i[n].length?45*this.getValue(i[n].charAt(0))+this.getValue(i[n].charAt(1)):this.getValue(i[n].charAt(0)),1+5*i[n].length)},t.prototype.getStringBitsLength=function(e,t){return 4+this.getBitsCharacterCount(t)+11*Math.floor(e/2)+e%2*6},t}(RG),OG=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),MG(this,{bitsInCharacterCount:[8,16,16],modeIndicator:"0100"})},t.prototype.getValue=function(e){var t=e.charCodeAt(0);if(t<=127||160<=t&&t<=255)return t;throw new Error('Unsupported character in QR Code: "'+e+'".')},t.prototype.encode=function(e,t){for(var n=this.getModeCountString(e.length,t),i=0;i<e.length;i++)n+=IG(this.getValue(e.charAt(i)),8);return n},t.prototype.getStringBitsLength=function(e,t){return 4+this.getBitsCharacterCount(t)+8*e},t}(RG),VG={};VG.numeric=new LG,VG.alphanumeric=new BG,VG.byte=new OG;var NG=function(e){function t(){e.call(this),this.initProperties(),this.mode=VG[this.encodingMode]}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){MG(this,{encodingMode:"byte",utfBOM:"111011111011101110111111",initialModeCountStringLength:20,ranges:[128,2048,65536,2097152,67108864]})},t.prototype.getEncodingResult=function(e,t){var n=this.encode(e),i=yK(this.getDataCodewordsCount(n),t),r=this.mode.getModeCountString(n.length/8,i)+n;return new HG(r,i)},t.prototype.getDataCodewordsCount=function(e){var t=e.length;return Math.ceil((this.initialModeCountStringLength+t)/8)},t.prototype.encode=function(e){for(var t=this.utfBOM,n=0;n<e.length;n++)t+=this.encodeCharacter(e.charCodeAt(n));return t},t.prototype.encodeCharacter=function(e){var t=this.getBytesCount(e),n=t-1,i="";if(1===t)i=IG(e,8);else{for(var r=8-t,o=0;o<n;o++)i=IG(e>>6*o&63|128,8)+i;i=(e>>6*n|255>>r<<r).toString(2)+i}return i},t.prototype.getBytesCount=function(e){for(var t=this.ranges,n=0;n<t.length;n++)if(e<t[n])return n+1},t}(fr),$G=[{L:{groups:[[1,19]],totalDataCodewords:19,errorCodewordsPerBlock:7},M:{groups:[[1,16]],totalDataCodewords:16,errorCodewordsPerBlock:10},Q:{groups:[[1,13]],totalDataCodewords:13,errorCodewordsPerBlock:13},H:{groups:[[1,9]],totalDataCodewords:9,errorCodewordsPerBlock:17}},{L:{groups:[[1,34]],totalDataCodewords:34,errorCodewordsPerBlock:10},M:{groups:[[1,28]],totalDataCodewords:28,errorCodewordsPerBlock:16},Q:{groups:[[1,22]],totalDataCodewords:22,errorCodewordsPerBlock:22},H:{groups:[[1,16]],totalDataCodewords:16,errorCodewordsPerBlock:28}},{L:{groups:[[1,55]],totalDataCodewords:55,errorCodewordsPerBlock:15},M:{groups:[[1,44]],totalDataCodewords:44,errorCodewordsPerBlock:26},Q:{groups:[[2,17]],totalDataCodewords:34,errorCodewordsPerBlock:18},H:{groups:[[2,13]],totalDataCodewords:26,errorCodewordsPerBlock:22}},{L:{groups:[[1,80]],totalDataCodewords:80,errorCodewordsPerBlock:20},M:{groups:[[2,32]],totalDataCodewords:64,errorCodewordsPerBlock:18},Q:{groups:[[2,24]],totalDataCodewords:48,errorCodewordsPerBlock:26},H:{groups:[[4,9]],totalDataCodewords:36,errorCodewordsPerBlock:16}},{L:{groups:[[1,108]],totalDataCodewords:108,errorCodewordsPerBlock:26},M:{groups:[[2,43]],totalDataCodewords:86,errorCodewordsPerBlock:24},Q:{groups:[[2,15],[2,16]],totalDataCodewords:62,errorCodewordsPerBlock:18},H:{groups:[[2,11],[2,12]],totalDataCodewords:46,errorCodewordsPerBlock:22}},{L:{groups:[[2,68]],totalDataCodewords:136,errorCodewordsPerBlock:18},M:{groups:[[4,27]],totalDataCodewords:108,errorCodewordsPerBlock:16},Q:{groups:[[4,19]],totalDataCodewords:76,errorCodewordsPerBlock:24},H:{groups:[[4,15]],totalDataCodewords:60,errorCodewordsPerBlock:28}},{L:{groups:[[2,78]],totalDataCodewords:156,errorCodewordsPerBlock:20},M:{groups:[[4,31]],totalDataCodewords:124,errorCodewordsPerBlock:18},Q:{groups:[[2,14],[4,15]],totalDataCodewords:88,errorCodewordsPerBlock:18},H:{groups:[[4,13],[1,14]],totalDataCodewords:66,errorCodewordsPerBlock:26}},{L:{groups:[[2,97]],totalDataCodewords:194,errorCodewordsPerBlock:24},M:{groups:[[2,38],[2,39]],totalDataCodewords:154,errorCodewordsPerBlock:22},Q:{groups:[[4,18],[2,19]],totalDataCodewords:110,errorCodewordsPerBlock:22},H:{groups:[[4,14],[2,15]],totalDataCodewords:86,errorCodewordsPerBlock:26}},{L:{groups:[[2,116]],totalDataCodewords:232,errorCodewordsPerBlock:30},M:{groups:[[3,36],[2,37]],totalDataCodewords:182,errorCodewordsPerBlock:22},Q:{groups:[[4,16],[4,17]],totalDataCodewords:132,errorCodewordsPerBlock:20},H:{groups:[[4,12],[4,13]],totalDataCodewords:100,errorCodewordsPerBlock:24}},{L:{groups:[[2,68],[2,69]],totalDataCodewords:274,errorCodewordsPerBlock:18},M:{groups:[[4,43],[1,44]],totalDataCodewords:216,errorCodewordsPerBlock:26},Q:{groups:[[6,19],[2,20]],totalDataCodewords:154,errorCodewordsPerBlock:24},H:{groups:[[6,15],[2,16]],totalDataCodewords:122,errorCodewordsPerBlock:28}},{L:{groups:[[4,81]],totalDataCodewords:324,errorCodewordsPerBlock:20},M:{groups:[[1,50],[4,51]],totalDataCodewords:254,errorCodewordsPerBlock:30},Q:{groups:[[4,22],[4,23]],totalDataCodewords:180,errorCodewordsPerBlock:28},H:{groups:[[3,12],[8,13]],totalDataCodewords:140,errorCodewordsPerBlock:24}},{L:{groups:[[2,92],[2,93]],totalDataCodewords:370,errorCodewordsPerBlock:24},M:{groups:[[6,36],[2,37]],totalDataCodewords:290,errorCodewordsPerBlock:22},Q:{groups:[[4,20],[6,21]],totalDataCodewords:206,errorCodewordsPerBlock:26},H:{groups:[[7,14],[4,15]],totalDataCodewords:158,errorCodewordsPerBlock:28}},{L:{groups:[[4,107]],totalDataCodewords:428,errorCodewordsPerBlock:26},M:{groups:[[8,37],[1,38]],totalDataCodewords:334,errorCodewordsPerBlock:22},Q:{groups:[[8,20],[4,21]],totalDataCodewords:244,errorCodewordsPerBlock:24},H:{groups:[[12,11],[4,12]],totalDataCodewords:180,errorCodewordsPerBlock:22}},{L:{groups:[[3,115],[1,116]],totalDataCodewords:461,errorCodewordsPerBlock:30},M:{groups:[[4,40],[5,41]],totalDataCodewords:365,errorCodewordsPerBlock:24},Q:{groups:[[11,16],[5,17]],totalDataCodewords:261,errorCodewordsPerBlock:20},H:{groups:[[11,12],[5,13]],totalDataCodewords:197,errorCodewordsPerBlock:24}},{L:{groups:[[5,87],[1,88]],totalDataCodewords:523,errorCodewordsPerBlock:22},M:{groups:[[5,41],[5,42]],totalDataCodewords:415,errorCodewordsPerBlock:24},Q:{groups:[[5,24],[7,25]],totalDataCodewords:295,errorCodewordsPerBlock:30},H:{groups:[[11,12],[7,13]],totalDataCodewords:223,errorCodewordsPerBlock:24}},{L:{groups:[[5,98],[1,99]],totalDataCodewords:589,errorCodewordsPerBlock:24},M:{groups:[[7,45],[3,46]],totalDataCodewords:453,errorCodewordsPerBlock:28},Q:{groups:[[15,19],[2,20]],totalDataCodewords:325,errorCodewordsPerBlock:24},H:{groups:[[3,15],[13,16]],totalDataCodewords:253,errorCodewordsPerBlock:30}},{L:{groups:[[1,107],[5,108]],totalDataCodewords:647,errorCodewordsPerBlock:28},M:{groups:[[10,46],[1,47]],totalDataCodewords:507,errorCodewordsPerBlock:28},Q:{groups:[[1,22],[15,23]],totalDataCodewords:367,errorCodewordsPerBlock:28},H:{groups:[[2,14],[17,15]],totalDataCodewords:283,errorCodewordsPerBlock:28}},{L:{groups:[[5,120],[1,121]],totalDataCodewords:721,errorCodewordsPerBlock:30},M:{groups:[[9,43],[4,44]],totalDataCodewords:563,errorCodewordsPerBlock:26},Q:{groups:[[17,22],[1,23]],totalDataCodewords:397,errorCodewordsPerBlock:28},H:{groups:[[2,14],[19,15]],totalDataCodewords:313,errorCodewordsPerBlock:28}},{L:{groups:[[3,113],[4,114]],totalDataCodewords:795,errorCodewordsPerBlock:28},M:{groups:[[3,44],[11,45]],totalDataCodewords:627,errorCodewordsPerBlock:26},Q:{groups:[[17,21],[4,22]],totalDataCodewords:445,errorCodewordsPerBlock:26},H:{groups:[[9,13],[16,14]],totalDataCodewords:341,errorCodewordsPerBlock:26}},{L:{groups:[[3,107],[5,108]],totalDataCodewords:861,errorCodewordsPerBlock:28},M:{groups:[[3,41],[13,42]],totalDataCodewords:669,errorCodewordsPerBlock:26},Q:{groups:[[15,24],[5,25]],totalDataCodewords:485,errorCodewordsPerBlock:30},H:{groups:[[15,15],[10,16]],totalDataCodewords:385,errorCodewordsPerBlock:28}},{L:{groups:[[4,116],[4,117]],totalDataCodewords:932,errorCodewordsPerBlock:28},M:{groups:[[17,42]],totalDataCodewords:714,errorCodewordsPerBlock:26},Q:{groups:[[17,22],[6,23]],totalDataCodewords:512,errorCodewordsPerBlock:28},H:{groups:[[19,16],[6,17]],totalDataCodewords:406,errorCodewordsPerBlock:30}},{L:{groups:[[2,111],[7,112]],totalDataCodewords:1006,errorCodewordsPerBlock:28},M:{groups:[[17,46]],totalDataCodewords:782,errorCodewordsPerBlock:28},Q:{groups:[[7,24],[16,25]],totalDataCodewords:568,errorCodewordsPerBlock:30},H:{groups:[[34,13]],totalDataCodewords:442,errorCodewordsPerBlock:24}},{L:{groups:[[4,121],[5,122]],totalDataCodewords:1094,errorCodewordsPerBlock:30},M:{groups:[[4,47],[14,48]],totalDataCodewords:860,errorCodewordsPerBlock:28},Q:{groups:[[11,24],[14,25]],totalDataCodewords:614,errorCodewordsPerBlock:30},H:{groups:[[16,15],[14,16]],totalDataCodewords:464,errorCodewordsPerBlock:30}},{L:{groups:[[6,117],[4,118]],totalDataCodewords:1174,errorCodewordsPerBlock:30},M:{groups:[[6,45],[14,46]],totalDataCodewords:914,errorCodewordsPerBlock:28},Q:{groups:[[11,24],[16,25]],totalDataCodewords:664,errorCodewordsPerBlock:30},H:{groups:[[30,16],[2,17]],totalDataCodewords:514,errorCodewordsPerBlock:30}},{L:{groups:[[8,106],[4,107]],totalDataCodewords:1276,errorCodewordsPerBlock:26},M:{groups:[[8,47],[13,48]],totalDataCodewords:1e3,errorCodewordsPerBlock:28},Q:{groups:[[7,24],[22,25]],totalDataCodewords:718,errorCodewordsPerBlock:30},H:{groups:[[22,15],[13,16]],totalDataCodewords:538,errorCodewordsPerBlock:30}},{L:{groups:[[10,114],[2,115]],totalDataCodewords:1370,errorCodewordsPerBlock:28},M:{groups:[[19,46],[4,47]],totalDataCodewords:1062,errorCodewordsPerBlock:28},Q:{groups:[[28,22],[6,23]],totalDataCodewords:754,errorCodewordsPerBlock:28},H:{groups:[[33,16],[4,17]],totalDataCodewords:596,errorCodewordsPerBlock:30}},{L:{groups:[[8,122],[4,123]],totalDataCodewords:1468,errorCodewordsPerBlock:30},M:{groups:[[22,45],[3,46]],totalDataCodewords:1128,errorCodewordsPerBlock:28},Q:{groups:[[8,23],[26,24]],totalDataCodewords:808,errorCodewordsPerBlock:30},H:{groups:[[12,15],[28,16]],totalDataCodewords:628,errorCodewordsPerBlock:30}},{L:{groups:[[3,117],[10,118]],totalDataCodewords:1531,errorCodewordsPerBlock:30},M:{groups:[[3,45],[23,46]],totalDataCodewords:1193,errorCodewordsPerBlock:28},Q:{groups:[[4,24],[31,25]],totalDataCodewords:871,errorCodewordsPerBlock:30},H:{groups:[[11,15],[31,16]],totalDataCodewords:661,errorCodewordsPerBlock:30}},{L:{groups:[[7,116],[7,117]],totalDataCodewords:1631,errorCodewordsPerBlock:30},M:{groups:[[21,45],[7,46]],totalDataCodewords:1267,errorCodewordsPerBlock:28},Q:{groups:[[1,23],[37,24]],totalDataCodewords:911,errorCodewordsPerBlock:30},H:{groups:[[19,15],[26,16]],totalDataCodewords:701,errorCodewordsPerBlock:30}},{L:{groups:[[5,115],[10,116]],totalDataCodewords:1735,errorCodewordsPerBlock:30},M:{groups:[[19,47],[10,48]],totalDataCodewords:1373,errorCodewordsPerBlock:28},Q:{groups:[[15,24],[25,25]],totalDataCodewords:985,errorCodewordsPerBlock:30},H:{groups:[[23,15],[25,16]],totalDataCodewords:745,errorCodewordsPerBlock:30}},{L:{groups:[[13,115],[3,116]],totalDataCodewords:1843,errorCodewordsPerBlock:30},M:{groups:[[2,46],[29,47]],totalDataCodewords:1455,errorCodewordsPerBlock:28},Q:{groups:[[42,24],[1,25]],totalDataCodewords:1033,errorCodewordsPerBlock:30},H:{groups:[[23,15],[28,16]],totalDataCodewords:793,errorCodewordsPerBlock:30}},{L:{groups:[[17,115]],totalDataCodewords:1955,errorCodewordsPerBlock:30},M:{groups:[[10,46],[23,47]],totalDataCodewords:1541,errorCodewordsPerBlock:28},Q:{groups:[[10,24],[35,25]],totalDataCodewords:1115,errorCodewordsPerBlock:30},H:{groups:[[19,15],[35,16]],totalDataCodewords:845,errorCodewordsPerBlock:30}},{L:{groups:[[17,115],[1,116]],totalDataCodewords:2071,errorCodewordsPerBlock:30},M:{groups:[[14,46],[21,47]],totalDataCodewords:1631,errorCodewordsPerBlock:28},Q:{groups:[[29,24],[19,25]],totalDataCodewords:1171,errorCodewordsPerBlock:30},H:{groups:[[11,15],[46,16]],totalDataCodewords:901,errorCodewordsPerBlock:30}},{L:{groups:[[13,115],[6,116]],totalDataCodewords:2191,errorCodewordsPerBlock:30},M:{groups:[[14,46],[23,47]],totalDataCodewords:1725,errorCodewordsPerBlock:28},Q:{groups:[[44,24],[7,25]],totalDataCodewords:1231,errorCodewordsPerBlock:30},H:{groups:[[59,16],[1,17]],totalDataCodewords:961,errorCodewordsPerBlock:30}},{L:{groups:[[12,121],[7,122]],totalDataCodewords:2306,errorCodewordsPerBlock:30},M:{groups:[[12,47],[26,48]],totalDataCodewords:1812,errorCodewordsPerBlock:28},Q:{groups:[[39,24],[14,25]],totalDataCodewords:1286,errorCodewordsPerBlock:30},H:{groups:[[22,15],[41,16]],totalDataCodewords:986,errorCodewordsPerBlock:30}},{L:{groups:[[6,121],[14,122]],totalDataCodewords:2434,errorCodewordsPerBlock:30},M:{groups:[[6,47],[34,48]],totalDataCodewords:1914,errorCodewordsPerBlock:28},Q:{groups:[[46,24],[10,25]],totalDataCodewords:1354,errorCodewordsPerBlock:30},H:{groups:[[2,15],[64,16]],totalDataCodewords:1054,errorCodewordsPerBlock:30}},{L:{groups:[[17,122],[4,123]],totalDataCodewords:2566,errorCodewordsPerBlock:30},M:{groups:[[29,46],[14,47]],totalDataCodewords:1992,errorCodewordsPerBlock:28},Q:{groups:[[49,24],[10,25]],totalDataCodewords:1426,errorCodewordsPerBlock:30},H:{groups:[[24,15],[46,16]],totalDataCodewords:1096,errorCodewordsPerBlock:30}},{L:{groups:[[4,122],[18,123]],totalDataCodewords:2702,errorCodewordsPerBlock:30},M:{groups:[[13,46],[32,47]],totalDataCodewords:2102,errorCodewordsPerBlock:28},Q:{groups:[[48,24],[14,25]],totalDataCodewords:1502,errorCodewordsPerBlock:30},H:{groups:[[42,15],[32,16]],totalDataCodewords:1142,errorCodewordsPerBlock:30}},{L:{groups:[[20,117],[4,118]],totalDataCodewords:2812,errorCodewordsPerBlock:30},M:{groups:[[40,47],[7,48]],totalDataCodewords:2216,errorCodewordsPerBlock:28},Q:{groups:[[43,24],[22,25]],totalDataCodewords:1582,errorCodewordsPerBlock:30},H:{groups:[[10,15],[67,16]],totalDataCodewords:1222,errorCodewordsPerBlock:30}},{L:{groups:[[19,118],[6,119]],totalDataCodewords:2956,errorCodewordsPerBlock:30},M:{groups:[[18,47],[31,48]],totalDataCodewords:2334,errorCodewordsPerBlock:28},Q:{groups:[[34,24],[34,25]],totalDataCodewords:1666,errorCodewordsPerBlock:30},H:{groups:[[20,15],[61,16]],totalDataCodewords:1276,errorCodewordsPerBlock:30}}],UG="0000",WG="numeric",jG="alphanumeric",qG="byte",GG={1:0},KG={0:1},YG={15:20,16:20,18:24,19:24,22:20,24:22,26:24,28:20,30:20,31:24,32:28,33:24,36:18,37:22,39:20,40:24},QG=[1,0,1,1,1],XG=[1,0,1],ZG={L:"01",M:"00",Q:"11",H:"10"},JG=["11101100","00010001"],eK=[function(e,t){return(e+t)%2==0},function(e,t){return e%2==0},function(e,t){return t%3==0},function(e,t){return(e+t)%3==0},function(e,t){return(Math.floor(e/2)+Math.floor(t/3))%2==0},function(e,t){return e*t%2+e*t%3==0},function(e,t){return(e*t%2+e*t%3)%2==0},function(e,t){return((e+t)%2+e*t%3)%2==0}],tK=/^\d+/,nK="A-Z0-9 $%*+./:-",iK=new RegExp("^[A-Z $%*+./:-]+"),rK=new RegExp("^["+nK+"]+"),oK=new RegExp("^[^"+nK+"]+"),aK=8,sK=5,lK=8,cK=17,dK=9,uK=16,hK=[[1,0],[1,25,0]];function pK(e,t,n,i){for(var r=0;r<e.length;r++)e[r][n][i]=t}function fK(e,t,n,i){for(var r=0;r<eK.length;r++)e[r][n][i]=eK[r](n,i)?1^t:parseInt(t,10)}function mK(e,t){for(var n=[],i=e.length-2;i>=0;i--)n[i]=e[i]^t[i];return n}function gK(e,t){for(var n=[],i=0;i<e.length;i++)for(var r=0;r<t.length;r++)void 0===n[i+r]?n[i+r]=(e[i]+(t[r]>=0?t[r]:0))%255:n[i+r]=GG[KG[n[i+r]]^KG[(e[i]+t[r])%255]];return n}function vK(e,t){var n=[],i=e.length-1;do{n[i]=KG[(e[i]+t)%255],i--}while(void 0!==e[i]);return n}function _K(e,t){var n,i,r=hK[t-1],o=new Array(t).concat(e),a=new Array(o.length-r.length).concat(r),s=e.length,l=[];for(i=0;i<s;i++)n=vK(a,GG[o[o.length-1]]),a.splice(0,1),o=mK(n,o);for(i=o.length-1;i>=0;i--)l[t-1-i]=IG(o[i],8);return l}function bK(e,t,n,i,r){var o,a,s=tK.exec(e),l=s?s[0]:"",c=iK.exec(e),d=c?c[0]:"",u=rK.exec(e),h=u?u[0]:"";return l&&(l.length>=t||e.length===l.length||l.length>=n&&!rK.test(e.charAt(l.length)))?(o=WG,a=l):h&&(e.length===h.length||h.length>=i||r===jG)?(o=jG,a=l||d):(o=qG,a=h?h+oK.exec(e.substring(h.length))[0]:oK.exec(e)[0]),{mode:o,modeString:a}}function yK(e,t){var n=0,i=$G.length-1,r=Math.floor($G.length/2);do{e<$G[r][t].totalDataCodewords?i=r:n=r,r=n+Math.floor((i-n)/2)}while(i-n>1);return e<=$G[n][t].totalDataCodewords?r+1:i+1}function wK(e,t,n){var i=zG(t),r=t.length-1,o=e<<r,a=IG(e,n-r),s=function(e,t){var n=t.toString(2).length,i=e.toString(2).length,r=e;do{i=(r^=t<<i-n).toString(2).length}while(i>=n);return r}(o,i);return s=a+IG(s,r)}function kK(e,t){return parseInt(e.charAt(t),10)}function xK(e,t){var n,i,r=e[0],o=0,a=t.length;for(n=0,i=8;n<=8;n++)6!==n&&pK(e,kK(t,a-1-o++),n,i);for(n=8,i=7;i>=0;i--)6!==i&&pK(e,kK(t,a-1-o++),n,i);for(o=0,i=r.length-1,n=8;i>=r.length-8;i--)pK(e,kK(t,a-1-o++),n,i);for(pK(e,1,r.length-8,8),n=r.length-7,i=8;n<r.length;n++)pK(e,kK(t,a-1-o++),n,i)}function CK(e,t){for(var n,i,r,o=e[0].length,a=o-11,s=o-11,l=0;l<t.length;l++)n=Math.floor(l/3),i=l%3,pK(e,r=kK(t,t.length-l-1),0+n,a+i),pK(e,r,s+i,0+n)}function SK(e,t,n,i){for(var r,o=t.length+2,a=t.length+1,s=0;s<t.length;s++)for(var l=s;l<o-s;l++)pK(e,r=t[s],n+l,i+s),pK(e,r,n+s,i+l),pK(e,r,n+a-l,i+a-s),pK(e,r,n+a-s,i+a-l)}function TK(e,t,n,i){var r=n,o=i,a=e[0];do{pK(e,0,r,i),pK(e,0,n,o),r+=t[0],o+=t[1]}while(r>=0&&r<a.length)}function DK(e,t,n,i,r){t[e][i]=(t[e][i]<<1^r)%128,93===t[e][i]&&(n[e]+=40)}function AK(e,t,n,i,r,o){n[e][o]===i?r[e][o]++:(n[e][o]=i,r[e][o]>=5&&(t[e]+=3+r[e][o]-5),r[e][o]=1)}function MK(e,t){var n=Math.floor(e/t*100),i=n%5,r=Math.abs(n-i-50),o=Math.abs(n+5-i-50);return 10*Math.min(r/5,o/5)}function EK(e,t,n){var i=function(e){return e&&e.toLowerCase().indexOf("utf_8")>=0?new NG:new FG}(n),r=i.getEncodingResult(e,t),o=r.version,a=$G[o-1][t],s=function(e,t){for(var n,i,r,o,a,s=0,l=[],c=[],d=t.groups,u=0;u<d.length;u++){r=d[u][0];for(var h=0;h<r;h++){i=d[u][1],n=[],o=[];for(var p=1;p<=i;p++)a=e.substring(s,s+8),n.push(a),o[i-p]=zG(a),s+=8;l.push(n),c.push(_K(o,t.errorCodewordsPerBlock))}}return[l,c]}(function(e,t){for(var n=8*t,i=0,r=0,o=e;o.length<n&&i<4;)o+=UG.charAt(i++);for(o.length%8!=0&&(o+=new Array(9-o.length%8).join("0"));o.length<n;)o+=JG[r],r^=1;return o}(r.dataString,a.totalDataCodewords),a),l=function(e){for(var t=[],n=17+4*e,i=0;i<eK.length;i++){t[i]=new Array(n);for(var r=0;r<n;r++)t[i][r]=new Array(n)}return t}(o);!function(e){var t=e[0].length;SK(e,QG,0,0),TK(e,[-1,-1],7,7),SK(e,QG,t-7,0),TK(e,[1,-1],t-8,7),SK(e,QG,0,t-7),TK(e,[-1,1],7,t-8)}(l),function(e,t){if(!(t<2)){var n,i,r=e[0],o=r.length,a=Math.floor(t/7),s=[6],l=0;for((n=YG[t])?i=(o-13-n)/a:n=i=(o-13)/(a+1),s.push(s[l++]+n);s[l]+i<o;)s.push(s[l++]+i);for(var c=0;c<s.length;c++)for(var d=0;d<s.length;d++)void 0===r[s[c]][s[d]]&&SK(e,XG,s[c]-2,s[d]-2)}}(l,o),function(e){for(var t=1,n=e[0].length,i=8;i<n-8;i++)pK(e,t,6,i),pK(e,t,i,6),t^=1}(l),o>=7&&CK(l,IG(0,18)),xK(l,IG(0,15)),function(e,t){for(var n,i,r,o=new PG(e[0]),a=0;a<t.length;a++)for(n=t[a],i=0;n.length>0;){for(var s=0;s<n.length;s++)for(var l=0;l<8;l++)r=o.getNextCell(),fK(e,n[s][i].charAt(l),r.row,r.column);for(i++;n[0]&&i===n[0].length;)n.splice(0,1)}for(;r=o.getNextRemainderCell();)fK(e,0,r.row,r.column)}(l,s);var c=function(e){var t,n,i=[],r=[],o=[],a=[],s=[],l=e[0].length;for(n=0;n<e.length;n++)i[n]=0,o[n]=0,s[n]=[0,0],a[n]=[0,0],r[n]=[];for(var c=0;c<l;c++)for(var d=0;d<l;d++)for(var u=0;u<e.length;u++)t=e[u],o[u]+=parseInt(t[c][d],10),r[u][0]===t[c][d]&&c+1<l&&d-1>=0&&t[c+1][d]===r[u][0]&&t[c+1][d-1]===r[u][0]&&(i[u]+=3),DK(u,a,i,0,t[c][d]),DK(u,a,i,1,t[d][c]),AK(u,i,r,t[c][d],s,0),AK(u,i,r,t[d][c],s,1);var h,p=l*l,f=Number.MAX_VALUE;for(n=0;n<i.length;n++)i[n]+=MK(o[n],p),i[n]<f&&(f=i[n],h=n);return h}(l),d=l[c];return o>=7&&CK([d],function(e){return wK(e,"1111100100101",18)}(o)),xK([d],function(e){var t,n="";if(0===zG(e))return"101010000010010";t=wK(zG(e),"10100110111",15);for(var i=0;i<t.length;i++)n+=t.charAt(i)^"101010000010010".charAt(i);return n}(ZG[t]+IG(c,3))),d}!function(){var e,t;for(t=1;t<255;t++)(e=2*KG[t-1])>255&&(e^=285),KG[t]=e,GG[e]=t;e=2*KG[t-1]^285,KG[t]=e,KG[-1]=0}(),function(){for(var e=2;e<=68;e++){var t=hK[e-1],n=[e,0];hK[e]=gK(t,n)}}();var IK=Math.round,zK=[[0,1],[1,1],[1,2],[2,2],[2,1],[3,1],[3,0],[2,0],[2,-1],[1,-1],[1,0]],PK=[[0,1],[1,1],[1,0]],HK=200,FK="L",RK="#fff",LK="#000",BK=1,OK=7,VK=function(e){function t(t,n,i){void 0===i&&(i=KR),e.call(this),this.options=BF({},this.options,n),this.element=t,this.wrapper=this.element,this.onError=i,this._initElement(),this._initSurface(),this.setOptions(n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this._destroySurface()},t.prototype._initElement=function(){CF(this.element,"k-qrcode")},t.prototype._initSurface=function(){var e=this.options,t=this.surface;t&&t.options.type===e.renderAs||(this._destroySurface(),this._initSurfaceElement(),this.surface=this._createSurface())},t.prototype._createSurface=function(){return vc.create(this.surfaceElement,{type:this.options.renderAs})},t.prototype._destroySurface=function(){this.surface&&(this.surface.destroy(),this.surface=null,this._destroySurfaceElement())},t.prototype._initSurfaceElement=function(){this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.surfaceElement.style.position="relative",this.element.appendChild(this.surfaceElement))},t.prototype._destroySurfaceElement=function(){this.surfaceElement&&this.surfaceElement.parentNode&&(this.surfaceElement.parentNode.removeChild(this.surfaceElement),this.surfaceElement=null)},t.prototype.redraw=function(){var e=this._getSize();this.surface.clear(),this.surface.setSize({width:e,height:e}),this.createVisual(),this.surface.draw(this.visual)},t.prototype.getSize=function(){var e=this.element,t=e.clientWidth,n=e.clientHeight,i={width:0,height:0};return t>0&&(i.width=t),n&&(i.height=n),i},t.prototype._resize=function(){this.redraw()},t.prototype.createVisual=function(){this.visual=this._render()},t.prototype.exportVisual=function(){return this._render()},t.prototype._render=function(){var e,t,n,i,r,o=this._value,a=this.options.border||{},s=this.options.padding||0,l=a.width||0;a.width=l;var c=new vs;try{o&&(n=EK(o,this.options.errorCorrection,this.options.encoding),r=(i=this._getSize())-2*(l+s),e=this._calculateBaseUnit(r,n.length),t=l+s+(r-n.length*e)/2,c.append(this._renderBackground(i,a)),c.append(this._renderMatrix(n,e,t)),this._hasCustomLogo()?c.append(this._renderLogo(i,e)):this._isSwiss()&&c.append(this._renderSwissCode(i,e)))}catch(e){this.onError(e)}return c},t.prototype._renderLogo=function(e,t){var n,i=IK(e/2),r=this._getLogoSize(t*OK),o=this.options.overlay.imageUrl,a={x:i-r.width/2,y:i-r.height/2};return n=new Yo(new Go(a.x,a.y),new Ko(r.width,r.height)),new ms(o,n)},t.prototype._renderSwissCode=function(e,t){var n=this._getLogoSize(t*OK),i=(n=Math.max(n.width,n.height))/4,r=i/2,o=e/2,a={},s=new vs;return a.x=a.y=Math.ceil(o-t-n/2),s.append(this._renderShape(a,Math.ceil(n+2*t),PK,"#fff")),a.x=a.y=o-n/2,s.append(this._renderShape(a,n,PK,this.options.color)),a.x=o+r-n/2,a.y=o+r+i-n/2,s.append(this._renderShape(a,i,zK,"#fff")),s},t.prototype._renderShape=function(e,t,n,i){var r=new hs({fill:{color:i},stroke:null});r.moveTo(e.x,e.y);for(var o=0;o<n.length;o++)r.lineTo(e.x+t*n[o][0],e.y+t*n[o][1]);return r.close(),r},t.prototype._getSize=function(){var e;if(this.options.size)e=parseInt(this.options.size,10);else{var t=DG(this.element,this.options.renderAs),n=Math.min(t.width,t.height);e=n>0?n:HK}return e},t.prototype._calculateBaseUnit=function(e,t){var n=Math.floor(e/t);if(n<BK){var i=Math.ceil(t*BK);this.onError(new Error("Insufficient size for QR Code: the current size is "+e+"px and the minimum size is "+i+"px."))}else n*t>=e&&n-1>=BK&&n--;return n},t.prototype._renderMatrix=function(e,t,n){for(var i=new hs({fill:{color:this.options.color},stroke:null}),r=0;r<e.length;r++)for(var o=n+r*t,a=0;a<e.length;){for(;0===e[r][a]&&a<e.length;)a++;if(a<e.length){for(var s=a;1===e[r][a];)a++;var l=IK(n+s*t),c=IK(o),d=IK(n+a*t),u=IK(o+t);i.moveTo(l,c).lineTo(l,u).lineTo(d,u).lineTo(d,c).close()}}return i},t.prototype._renderBackground=function(e,t){var n=new VL(0,0,e,e).unpad(t.width/2);return us.fromRect(n.toRect(),{fill:{color:this.options.background},stroke:{color:t.color,width:t.width}})},t.prototype.setOptions=function(e){var t=e||{};this.options=MG(this.options,t),void 0!==e.value&&(this._value=String(this.options.value)),this._initSurface(),this.redraw()},t.prototype.value=function(e){if(void 0===e)return this._value;this._value=String(e),this.redraw()},t.prototype._hasCustomLogo=function(){return Boolean(this.options.overlay.imageUrl)},t.prototype._isSwiss=function(){return"swiss"===this.options.overlay.type},t.prototype._getLogoSize=function(e){var t=this.options.overlay.width,n=this.options.overlay.height;return t||n?t&&!n?n=t:!t&&n&&(t=n):t=n=e,{width:t,height:n}},t}(fr);DR(VK,{name:"QRCode",renderAs:"svg",encoding:"ISO_8859_1",value:"",errorCorrection:FK,background:RK,color:LK,size:"",padding:0,border:{color:"",width:0},overlay:{type:"image",imageUrl:"",width:0,height:0}});var NK={WGS84:{a:6378137,b:6356752.314245179,f:.0033528106647474805,e:.08181919084262149}};function $K(e){return e*e}var UK=Math,WK=UK.abs,jK=UK.atan,qK=UK.atan2,GK=UK.cos,KK=UK.sin,YK=UK.tan,QK=function(e){function t(t,n){e.call(this),this.initProperties(),1===arguments.length?(this.lat=t[0],this.lng=t[1]):(this.lat=t,this.lng=n)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){BF(this,{DISTANCE_ITERATIONS:100,DISTANCE_CONVERGENCE:1e-12,DISTANCE_PRECISION:2,FORMAT:"{0:N6}{1:N6}"})},t.prototype.toArray=function(){return[this.lat,this.lng]},t.prototype.equals=function(e){return e&&e.lat===this.lat&&e.lng===this.lng},t.prototype.clone=function(){return new t(this.lat,this.lng)},t.prototype.round=function(e){return this.lng=xR(this.lng,e),this.lat=xR(this.lat,e),this},t.prototype.wrap=function(){return this.lng=this.lng%180,this.lat=this.lat%90,this},t.prototype.distanceTo=function(e,t){return this.greatCircleTo(e,t).distance},t.prototype.destination=function(e,n,i){var r=kR(n),o=i||NK.WGS84,a=kR(this.lat),s=kR(this.lng),l=e/o.a,c=UK.asin(KK(a)*GK(l)+GK(a)*KK(l)*GK(r)),d=s+qK(KK(r)*KK(l)*GK(a),GK(l)-KK(a)*KK(c));return new t(pR(c),pR(d))},t.prototype.greatCircleTo=function(e,n){var i=t.create(i),r=n||NK.WGS84;if(!i||this.clone().round(8).equals(i.clone().round(8)))return{distance:0,azimuthFrom:0,azimuthTo:0};for(var o,a,s,l,c,d,u,h,p=r.a,f=r.b,m=r.f,g=kR(i.lng-this.lng),v=jK((1-m)*YK(kR(this.lat))),_=KK(v),b=GK(v),y=jK((1-m)*YK(kR(i.lat))),w=KK(y),k=GK(y),x=g,C=this.DISTANCE_ITERATIONS,S=!1;!S&&C-- >0;){a=KK(x),s=GK(x),l=UK.sqrt($K(k*a)+$K(b*w-_*k*s)),h=qK(l,d=_*w+b*k*s);var T=b*k*a/l;u=0,0!==(c=1-$K(T))&&(u=d-2*_*w/c),o=x;var D=m/16*c*(4+m*(4-3*c));x=g+(1-D)*m*T*(h+D*l*(u+D*d*(2*$K(u)-1))),S=WK(x-o)<=this.DISTANCE_CONVERGENCE}var A=c*($K(p)-$K(f))/$K(f),M=1+A/16384*(4096+A*(A*(320-175*A)-768)),E=A/1024*(256+A*(A*(74-47*A)-128)),I=E*l*(u+E/4*(d*(2*$K(u)-1)-E/6*u*(4*$K(l)-3)*(4*$K(u)-3))),z=qK(k*a,b*w-_*k*s),P=qK(b*a,-_*k+b*w*s);return{distance:xR(f*M*(h-I),this.DISTANCE_PRECISION),azimuthFrom:pR(z),azimuthTo:pR(P)}},t.prototype.toString=function(){return String(this.lat)+","+String(this.lng)},t.fromLngLat=function(e){return new t(e[1],e[0])},t.fromLatLng=function(e){return new t(e[0],e[1])},t.create=function(e,n){if(hR(e))return e instanceof t?e.clone():1===arguments.length&&2===e.length?t.fromLatLng(e):new t(e,n)},t}(fr),XK=Math,ZK=XK.atan,JK=XK.exp,eY=XK.pow,tY=XK.sin,nY=XK.log,iY=XK.tan,rY=Go,oY=XK.PI,aY=oY/2,sY=oY/4,lY=oY/180,cY=NK.WGS84,dY=function(e){function t(t){e.call(this),this.initProperties(),this._initOptions(t)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._initOptions=function(e){this.options=BF({},this.options,e)},t.prototype.initProperties=function(){BF(this,{MAX_LNG:180,MAX_LAT:85.0840590501,INVERSE_ITERATIONS:15,INVERSE_CONVERGENCE:1e-12})},t.prototype.forward=function(e,t){var n=this,i=n.options,r=i.datum.a,o=i.centralMeridian,a=yR(e.lat,-n.MAX_LAT,n.MAX_LAT),s=t?yR(e.lng,-n.MAX_LNG,n.MAX_LNG):e.lng,l=kR(s-o)*r,c=n._projectLat(a);return new rY(l,c)},t.prototype._projectLat=function(e){var t=this.options.datum,n=t.e,i=t.a,r=kR(e),o=iY(sY+r/2),a=n*tY(r),s=eY((1-a)/(1+a),n/2);return i*nY(o*s)},t.prototype.inverse=function(e,t){var n=this,i=n.options,r=i.datum.a,o=i.centralMeridian,a=e.x/(lY*r)+o,s=yR(n._inverseY(e.y),-n.MAX_LAT,n.MAX_LAT);return t&&(a=yR(a,-n.MAX_LNG,n.MAX_LNG)),new QK(s,a)},t.prototype._inverseY=function(e){var t,n=this,i=n.options.datum,r=i.a,o=i.e,a=o/2,s=JK(-e/r),l=aY-2*ZK(s);for(t=0;t<=n.INVERSE_ITERATIONS;t++){var c=o*tY(l),d=eY((1-c)/(1+c),a),u=aY-2*ZK(s*d)-l;if(l+=u,XK.abs(u)<=n.INVERSE_CONVERGENCE)break}return pR(l)},t}(fr);DR(dY,{centralMeridian:0,datum:cY});var uY=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.initProperties=function(){e.prototype.initProperties.call(this),BF(this,{MAX_LAT:85.0511287798})},t.prototype._projectLat=function(e){var t=this.options.datum.a,n=kR(e),i=iY(sY+n/2);return t*nY(i)},t.prototype._inverseY=function(e){var t=this.options.datum.a,n=JK(-e/t);return pR(aY-2*ZK(n))},t}(dY),hY=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.forward=function(e){return new rY(e.lng,e.lat)},t.prototype.inverse=function(e){return new QK(e.y,e.x)},t}(fr),pY=function(e){function t(){e.call(this);var t=this._proj=new uY,n=this.c=2*oY*t.options.datum.a;this._tm=Xo().translate(.5,.5).scale(1/n,-1/n),this._itm=Xo().scale(n,-n).translate(-.5,-.5)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.toPoint=function(e,t,n){return this._proj.forward(e,n).transform(this._tm).scale(t||1)},t.prototype.toLocation=function(e,t,n){var i=e.clone().scale(1/(t||1)).transform(this._itm);return this._proj.inverse(i,n)},t}(fr),fY=(function(e){function t(){e.call(this),this._proj=new dY}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.toPoint=function(e){return this._proj.forward(e)},t.prototype.toLocation=function(e){return this._proj.inverse(e)}}(fr),function(e){function t(){e.call(this),this._proj=new hY}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.toPoint=function(e){return this._proj.forward(e)},t.prototype.toLocation=function(e){return this._proj.inverse(e)}}(fr),Object.assign,function(e,t){return e.bind(t)}),mY=function(e){var t=document.createElement("div");return t.innerHTML=e,t.firstChild},gY=function(e){for(;e.firstChild;)e.removeChild(e.firstChild)},vY=function(e,t){t.insertBefore(e,t.firstChild)},_Y=function(e){return e.replace(/([a-z][A-Z])/g,(function(e){return e.charAt(0)+"-"+e.charAt(1).toLowerCase()}))},bY=function(e){return e&&String(e).endsWith("px")?e:String(e)+"px"},yY=function(e,t){var n=e.prototype;n.events?t.forEach((function(e){n.events.indexOf(e)<0&&n.events.push(e)})):n.events=t},wY=function(e){var t=[];if(e)for(var n=_Y(e).split("-"),i=0;i<n.length;i++)t.push("k-pos-"+n[i]);return t.join(" ")},kY=function(e){function t(t,n){e.call(this),this.element=t,this._initOptions(n),this.items=[],CF(this.element,"k-widget k-attribution")}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._initOptions=function(e){this.options=BF({},this.options,e)},t.prototype.filter=function(e,t){this._extent=e,this._zoom=t,this._render()},t.prototype.add=function(e){var t=e;hR(e)&&("string"==typeof e&&(t={text:e}),this.items.push(t),this._render())},t.prototype.remove=function(e){for(var t=[],n=0;n<this.items.length;n++){var i=this.items[n];i.text!==e&&t.push(i)}this.items=t,this._render()},t.prototype.clear=function(){this.items=[],gY(this.element)},t.prototype._render=function(){for(var e=[],t=0;t<this.items.length;t++){var n=this.items[t],i=this._itemText(n);""!==i&&e.push(i)}e.length>0?(gY(this.element),function(e,t){var n=document.createElement("div");for(n.innerHTML=e;n.childNodes.length>0;)t.appendChild(n.childNodes[0])}(e.join(this.options.separator),this.element),this.showElement()):this.hideElement()},t.prototype.hideElement=function(){this.element.style.display="none"},t.prototype.showElement=function(){this.element.style.display=""},t.prototype._itemText=function(e){var t="",n=this._inZoomLevel(e.minZoom,e.maxZoom),i=this._inArea(e.extent);return n&&i&&(t+=e.text),t},t.prototype._inZoomLevel=function(e,t){var n=SR(e,-Number.MAX_VALUE),i=SR(t,Number.MAX_VALUE);return this._zoom>n&&this._zoom<i},t.prototype._inArea=function(e){var t=!0;return e&&(t=e.contains(this._extent)),t},t}(fL);DR(kY,{name:"Attribution",separator:"&nbsp;|&nbsp;"});var xY={up:{className:"k-navigator-n",iconClass:"k-i-caret-alt-up"},down:{className:"k-navigator-s",iconClass:"k-i-caret-alt-down"},right:{className:"k-navigator-e",iconClass:"k-i-caret-alt-right"},left:{className:"k-navigator-w",iconClass:"k-i-caret-alt-left"}};function CY(e,t){var n='<button class="k-button k-button-square k-rounded-full k-button-flat k-button-flat-base k-icon-button '+xY[e].className+'" aria-label="move '+e+'">'+HR({icon:"caret-alt-"+e,iconClass:"k-button-icon",svgIcons:t.svgIcons,type:t.type})+"</button>";return mY(n)}var SY=function(e){function t(t,n){e.call(this),this.element=t,this._initOptions(n);var i=CY("up",n.icons),r=CY("right",n.icons),o=CY("down",n.icons),a=CY("left",n.icons);this.element.appendChild(i),this.element.appendChild(r),this.element.appendChild(o),this.element.appendChild(a),CF(this.element,"k-widget k-navigator"),rL(this.element,"click",".k-button",fY(this._click,this));var s=this.element.parentNode.closest("[data-role]");this._keyroot=s||this.element,this._tabindex(this._keyroot),this._keydownHandler=fY(this._keydown,this),rL(this._keyroot,"keydown",this._keydownHandler)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this.dispose()},t.prototype.dispose=function(){oL(this._keyroot,"keydown",this._keydownHandler)},t.prototype._tabindex=function(e){var t=e||this.wrapper||this.element,n=this.element,i="tabindex",r=t.getAttribute(i)||n.getAttribute(i);n.removeAttribute(i),t.setAttribute(i,isNaN(r)?0:r)},t.prototype._initOptions=function(e){this.options=BF({},this.options,e)},t.prototype._pan=function(e,t){var n=this.options.panStep;this.trigger("pan",{x:e*n,y:t*n})},t.prototype._click=function(e){var t=0,n=0,i=e.currentTarget;i.matches(".k-navigator-n")?n=1:i.matches(".k-navigator-s")?n=-1:i.matches(".k-navigator-e")?t=1:i.matches(".k-navigator-w")&&(t=-1),this._pan(t,n),e.preventDefault()},t.prototype._keydown=function(e){switch(e.which){case YR.UP:this._pan(0,1),e.preventDefault();break;case YR.DOWN:this._pan(0,-1),e.preventDefault();break;case YR.RIGHT:this._pan(1,0),e.preventDefault();break;case YR.LEFT:this._pan(-1,0),e.preventDefault()}},t}(fL);function TY(e,t,n){var i='<button class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-icon-button k-zoom-'+e+'" title="zoom-'+e+'" aria-label="zoom-'+e+'">'+HR({icon:t,iconClass:"k-button-icon",svgIcons:n.svgIcons,type:n.type})+"</button>";return mY(i)}DR(SY,{name:"Navigator",panStep:1}),yY(SY,["pan"]);var DY="change",AY=function(e){function t(t,n,i){e.call(this),this.element=t,this._initOptions(n);var r=TY("in","plus",i),o=TY("out","minus",i);this.element.appendChild(r),this.element.appendChild(o),this.element.setAttribute("role","group"),CF(this.element,"k-widget k-zoom-control k-button-group k-group-horizontal"),this._clickHandler=this._click.bind(this),rL(this.element,"click",".k-button",this._clickHandler);var a=this.element.parentNode.closest("[data-role]");this._keyroot=a||this.element,this._tabindex(this._keyroot),this._keydownHandler=this._keydown.bind(this),rL(this._keyroot,"keydown",this._keydownHandler)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this.element&&oL(this.element,"click",this._clickHandler),this._keyroot&&oL(this._keyroot,"keydown",this._keydownHandler)},t.prototype._tabindex=function(e){var t=e||this.wrapper||this.element,n=this.element,i="tabindex",r=t.getAttribute(i)||n.getAttribute(i);n.removeAttribute(i),t.setAttribute(i,isNaN(r)?0:r)},t.prototype._initOptions=function(e){this.options=BF({},this.options,e)},t.prototype._change=function(e){var t=this.options.zoomStep;this.trigger(DY,{delta:e*t})},t.prototype._click=function(e){var t=1;JF(e.currentTarget,"k-zoom-out")&&(t=-1),this._change(t),e.preventDefault()},t.prototype._keydown=function(e){switch(e.which){case YR.NUMPAD_PLUS:case 187:case 61:this._change(1);break;case YR.NUMPAD_MINUS:case 189:case 173:this._change(-1)}},t}(fL);DR(AY,{name:"ZoomControl",zoomStep:1}),yY(AY,[DY]);var MY=Math,EY=MY.max,IY=MY.min,zY=function(e){function t(t,n){e.call(this);var i=QK.create(t),r=QK.create(n);i.lng+180>r.lng+180&&i.lat+90<r.lat+90?(this.se=i,this.nw=r):(this.se=r,this.nw=i)}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={World:{configurable:!0}};return t.prototype.contains=function(e){var t=this.nw,n=this.se,i=SR(e.lng,e[1]),r=SR(e.lat,e[0]);return e&&i+180>=t.lng+180&&i+180<=n.lng+180&&r+90>=n.lat+90&&r+90<=t.lat+90},t.prototype.center=function(){var e=this.nw,t=this.se,n=e.lng+(t.lng-e.lng)/2,i=e.lat+(t.lat-e.lat)/2;return new QK(i,n)},t.prototype.containsAny=function(e){for(var t=!1,n=0;n<e.length;n++)t=t||this.contains(e[n]);return t},t.prototype.include=function(e){var t=this.nw,n=this.se,i=SR(e.lng,e[1]),r=SR(e.lat,e[0]);t.lng=IY(t.lng,i),t.lat=EY(t.lat,r),n.lng=EY(n.lng,i),n.lat=IY(n.lat,r)},t.prototype.includeAll=function(e){for(var t=0;t<e.length;t++)this.include(e[t])},t.prototype.edges=function(){var e=this.nw,t=this.se;return{nw:this.nw,ne:new QK(e.lat,t.lng),se:this.se,sw:new QK(t.lat,e.lng)}},t.prototype.toArray=function(){var e=this.nw,t=this.se;return[e,new QK(e.lat,t.lng),t,new QK(t.lat,e.lng)]},t.prototype.overlaps=function(e){return this.containsAny(e.toArray())||e.containsAny(this.toArray())},t.create=function(e,n){return e instanceof t?e:e&&n?new t(e,n):e&&4===e.length&&!n?new t([e[0],e[1]],[e[2],e[3]]):void 0},n.World.get=function(){return new t([90,-180],[-90,180])},Object.defineProperties(t,n),t}(fr),PY="centerChange",HY=function(e){function t(t,n){e.call(this),this.widgetService=t,this.options=BF({},this.options,n),this.offset={x:0,y:0}}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={anchor:{configurable:!0}};return t.prototype.show=function(e,t){this.location!==t.location&&(this.anchor=e,this.location=t.location,this.widgetService.notify("showTooltip",Object.assign({anchor:this.anchor},t)),this.visible=!0)},t.prototype.hide=function(){this.widgetService&&this.widgetService.notify("hideTooltip"),this.visible=!1,this.location=null},n.anchor.get=function(){return this._anchor},n.anchor.set=function(e){var t=this.widgetService.widget._toDocumentCoordinates({x:e.left-this.offset.x,y:e.top-this.offset.y});this._anchor={left:t.left,top:t.top}},t.prototype.destroy=function(){this.widgetService=null},Object.defineProperties(t.prototype,n),t}(fr);DR(HY,{border:{width:1},opacity:1});var FY=function(e){function t(t,n){e.call(this),this.support=aL(),this._initOptions(n),this.map=t;var i=document.createElement("div");CF(i,"k-layer"),i.style.zIndex=this.options.zIndex,i.style.opacity=this.options.opacity,this.element=i,t.scrollElement.appendChild(this.element),this._beforeReset=this._beforeReset.bind(this),this._reset=this._reset.bind(this),this._resize=this._resize.bind(this),this._panEnd=this._panEnd.bind(this),this._activate(),this._updateAttribution()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this._deactivate()},t.prototype._initOptions=function(e){this.options=BF({},this.options,e)},t.prototype.show=function(){this.reset(),this._activate(),this._applyExtent(!0)},t.prototype.hide=function(){this._deactivate(),this._setVisibility(!1)},t.prototype.reset=function(){this._beforeReset(),this._reset()},t.prototype._reset=function(){this._applyExtent()},t.prototype._beforeReset=function(){},t.prototype._resize=function(){},t.prototype._panEnd=function(){this._applyExtent()},t.prototype._applyExtent=function(){var e=this.options,t=this.map.zoom(),n=!hR(e.minZoom)||t>=e.minZoom,i=!hR(e.maxZoom)||t<=e.maxZoom,r=zY.create(e.extent),o=!r||r.overlaps(this.map.extent());this._setVisibility(n&&i&&o)},t.prototype._setVisibility=function(e){this.element.style.display=e?"":"none"},t.prototype._activate=function(){var e=this.map;this._deactivate(),e.bind("beforeReset",this._beforeReset),e.bind("reset",this._reset),e.bind("resize",this._resize),e.bind("panEnd",this._panEnd)},t.prototype._deactivate=function(){var e=this.map;e.unbind("beforeReset",this._beforeReset),e.unbind("reset",this._reset),e.unbind("resize",this._resize),e.unbind("panEnd",this._panEnd)},t.prototype._updateAttribution=function(){var e=this.map.attribution;e&&e.add(this.options.attribution)},t.prototype._readData=function(){return this.options.data||[]},t.prototype._hasData=function(){return this._data&&this._data.length>0},t.prototype._layerIndex=function(){return(this.map.layers||[]).indexOf(this)},t}(fr),RY=Math,LY=Go;function BY(e){return FF(e)?e:qF.compile(e)}function OY(e){return new LY(xR(e.x),xR(e.y))}function VY(e){var t=e;return"string"!=typeof e&&(t+="px"),t}var NY=function(e){function t(t,n){e.call(this,t,n),"string"==typeof this.options.subdomains&&(this.options.subdomains=this.options.subdomains.split(""));var i=this._viewType();this._view=new i(this.element,this.options)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){e.prototype.destroy.call(this),this._view.destroy(),this._view=null},t.prototype._beforeReset=function(){var e=this.map,t=e.locationToLayer(e.extent().nw).round();this._view.viewOrigin(t)},t.prototype._reset=function(){e.prototype._reset.call(this),this._updateView(),this._view.reset()},t.prototype._viewType=function(){return $Y},t.prototype._activate=function(){e.prototype._activate.call(this),this.support.mobileOS||(this._pan||(this._pan=Pr(this._render.bind(this),100)),this.map.bind("pan",this._pan))},t.prototype._deactivate=function(){e.prototype._deactivate.call(this),this._pan&&this.map.unbind("pan",this._pan)},t.prototype._updateView=function(){var e=this._view,t=this.map,n=t.extent(),i={nw:t.locationToLayer(n.nw).round(),se:t.locationToLayer(n.se).round()};e.center(t.locationToLayer(t.center())),e.extent(i),e.zoom(t.zoom())},t.prototype._resize=function(){this._render()},t.prototype._panEnd=function(t){e.prototype._panEnd.call(this,t),this._render()},t.prototype._render=function(){this._updateView(),this._view.render()},t}(FY);DR(NY,{tileSize:256,subdomains:["a","b","c"],urlTemplate:"",zIndex:1});var $Y=function(e){function t(t,n){e.call(this),this.element=t,this._initOptions(n),this.pool=new WY}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._initOptions=function(e){this.options=BF({},this.options,e)},t.prototype.center=function(e){this._center=e},t.prototype.extent=function(e){this._extent=e},t.prototype.viewOrigin=function(e){this._viewOrigin=e},t.prototype.zoom=function(e){this._zoom=e},t.prototype.pointToTileIndex=function(e){return new LY(RY.floor(e.x/this.options.tileSize),RY.floor(e.y/this.options.tileSize))},t.prototype.tileCount=function(){var e=this.size(),t=this.pointToTileIndex(this._extent.nw),n=this._extent.nw,i=this.indexToPoint(t).translate(-n.x,-n.y);return{x:RY.ceil((RY.abs(i.x)+e.width)/this.options.tileSize),y:RY.ceil((RY.abs(i.y)+e.height)/this.options.tileSize)}},t.prototype.size=function(){var e=this._extent.nw,t=this._extent.se.clone().translate(-e.x,-e.y);return{width:t.x,height:t.y}},t.prototype.indexToPoint=function(e){var t=e.x,n=e.y;return new LY(t*this.options.tileSize,n*this.options.tileSize)},t.prototype.subdomainText=function(){var e=this.options.subdomains;return e[this.subdomainIndex++%e.length]},t.prototype.destroy=function(){gY(this.element),this.pool.empty()},t.prototype.reset=function(){this.pool.reset(),this.subdomainIndex=0,this.render()},t.prototype.render=function(){var e,t,n,i=this.tileCount(),r=this.pointToTileIndex(this._extent.nw);for(t=0;t<i.x;t++)for(n=0;n<i.y;n++)(e=this.createTile({x:r.x+t,y:r.y+n})).visible||e.show()},t.prototype.createTile=function(e){var t=this.tileOptions(e),n=this.pool.get(this._center,t);return n.element.parentNode||this.element.append(n.element),n},t.prototype.tileOptions=function(e){var t=this.wrapIndex(e),n=this.indexToPoint(e),i=this._viewOrigin,r=n.clone().translate(-i.x,-i.y);return{index:t,currentIndex:e,point:n,offset:OY(r),zoom:this._zoom,size:this.options.tileSize,subdomain:this.subdomainText(),urlTemplate:this.options.urlTemplate,errorUrlTemplate:this.options.errorUrlTemplate}},t.prototype.wrapIndex=function(e){var t=RY.pow(2,this._zoom);return{x:this.wrapValue(e.x,t),y:yR(e.y,0,t-1)}},t.prototype.wrapValue=function(e,t){var n=RY.abs(e)%t;return e>=0?n:t-(0===n?t:n)},t}(fr),UY=function(e){function t(t,n){e.call(this),this.id=t,this.visible=!0,this._initOptions(n),this.createElement(),this.show()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){var e=this.element,t=e?e.parentNode:null;e&&(t&&t.removeChild(e),this.element=null)},t.prototype._initOptions=function(e){this.options=BF({},this.options,e)},t.prototype.createElement=function(){var e=document.createElement("img"),t=this.options.size+"px";e.setAttribute("alt",""),e.style.position="absolute",e.style.display="block",e.style.width=e.style.maxWidth=t,e.style.height=e.style.maxHeight=t,this.element=e},t.prototype.show=function(){var e=this.element;e.style.top=VY(this.options.offset.y),e.style.left=VY(this.options.offset.x);var t=this.url();t&&e.setAttribute("src",t),e.style.visibility="visible",this.visible=!0},t.prototype.hide=function(){this.element.style.visibility="hidden",this.visible=!1},t.prototype.url=function(){return BY(this.options.urlTemplate)(this.urlOptions())},t.prototype.errorUrl=function(){return BY(this.options.errorUrlTemplate)(this.urlOptions())},t.prototype.urlOptions=function(){var e=this.options;return{zoom:e.zoom,subdomain:e.subdomain,z:e.zoom,x:e.index.x,y:e.index.y,s:e.subdomain,quadkey:e.quadkey,q:e.quadkey,culture:e.culture,c:e.culture}},t}(fr);DR(UY,{urlTemplate:"",errorUrlTemplate:""});var WY=function(e){function t(){e.call(this),this._items=[]}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.get=function(e,t){return this._items.length>=this.options.maxSize&&this._remove(e),this._create(t)},t.prototype.empty=function(){for(var e=this._items,t=0;t<e.length;t++)e[t].destroy();this._items=[]},t.prototype.reset=function(){for(var e=this._items,t=0;t<e.length;t++)e[t].hide()},t.prototype._create=function(e){for(var t,n=this._items,i=_R(e.point.toString()+e.offset.toString()+e.zoom+e.urlTemplate),r=0;r<n.length;r++)if(n[r].id===i){t=n[r];break}return t?t.show():(t=new UY(i,e),this._items.push(t)),t},t.prototype._remove=function(e){for(var t=this._items,n=-1,i=-1,r=0;r<t.length;r++){var o=t[r].options.point.distanceTo(e);o>n&&!t[r].visible&&(i=r,n=o)}-1!==i&&(t[i].destroy(),t.splice(i,1))},t}(fr);DR(WY,{maxSize:100});var jY=Object.assign,qY="change",GY=function(e){function t(t,n){e.call(this);var i=this,r=t[0]||t;i.capture=!1,r.addEventListener?(ZR.down.split(" ").forEach((function(e){r.addEventListener(e,fY(i._press,i),!0)})),ZR.up.split(" ").forEach((function(e){r.addEventListener(e,fY(i._release,i),!0)}))):(ZR.down.split(" ").forEach((function(e){r.attachEvent(e,fY(i._press,i))})),ZR.up.split(" ").forEach((function(e){r.attachEvent(e,fY(i._release,i))}))),i.bind(["press","release"],n||{})}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.captureNext=function(){this.capture=!0},t.prototype.cancelCapture=function(){this.capture=!1},t.prototype._press=function(e){this.trigger("press"),this.capture&&e.preventDefault()},t.prototype._release=function(e){var t=this;t.trigger("release"),t.capture&&(e.preventDefault(),t.cancelCapture())},t}(fL),KY=function(e){function t(t){e.call(this);var n=this;n.forcedEnabled=!1,jY(n,t),n.scale=1,n.horizontal?(n.measure="offsetWidth",n.scrollSize="scrollWidth",n.axis="x"):(n.measure="offsetHeight",n.scrollSize="scrollHeight",n.axis="y")}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.makeVirtual=function(){jY(this,{virtual:!0,forcedEnabled:!0,_virtualMin:0,_virtualMax:0})},t.prototype.virtualSize=function(e,t){this._virtualMin===e&&this._virtualMax===t||(this._virtualMin=e,this._virtualMax=t,this.update())},t.prototype.outOfBounds=function(e){return e>this.max||e<this.min},t.prototype.forceEnabled=function(){this.forcedEnabled=!0},t.prototype.getSize=function(){return this.container[this.measure]},t.prototype.getTotal=function(){return this.element[this.scrollSize]},t.prototype.rescale=function(e){this.scale=e},t.prototype.update=function(e){var t=this,n=t.virtual?t._virtualMax:t.getTotal(),i=n*t.scale,r=t.getSize();(0!==n||t.forcedEnabled)&&(t.max=t.virtual?-t._virtualMin:0,t.size=r,t.total=i,t.min=Math.min(t.max,r-i),t.minScale=r/n,t.centerOffset=(i-r)/2,t.enabled=t.forcedEnabled||i>r,e||t.trigger(qY,t))},t}(fL),YY=function(e){function t(t){e.call(this);var n=this;n.x=new KY(jY({horizontal:!0},t)),n.y=new KY(jY({horizontal:!1},t)),n.container=t.container,n.forcedMinScale=t.minScale,n.maxScale=t.maxScale||100,n.bind(qY,t)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.rescale=function(e){this.x.rescale(e),this.y.rescale(e),this.refresh()},t.prototype.centerCoordinates=function(){return{x:Math.min(0,-this.x.centerOffset),y:Math.min(0,-this.y.centerOffset)}},t.prototype.refresh=function(){var e=this;e.x.update(),e.y.update(),e.enabled=e.x.enabled||e.y.enabled,e.minScale=e.forcedMinScale||Math.min(e.x.minScale,e.y.minScale),e.fitScale=Math.max(e.x.minScale,e.y.minScale),e.trigger(qY)},t}(fL),QY=function(e){function t(t){e.call(this),jY(this,t)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.outOfBounds=function(){return this.dimension.outOfBounds(this.movable[this.axis])},t.prototype.dragMove=function(e){var t=this,n=t.dimension,i=t.axis,r=t.movable,o=r[i]+e;if(n.enabled){var a=e;(o<n.min&&e<0||o>n.max&&e>0)&&(a*=t.resistance),r.translateAxis(i,a),t.trigger(qY,t)}},t}(fL),XY=function(e){function t(t){e.call(this);var n,i,r,o,a=this;jY(a,{elastic:!0},t),r=a.elastic?.5:0,o=a.movable,a.x=n=new QY({axis:"x",dimension:a.dimensions.x,resistance:r,movable:o}),a.y=i=new QY({axis:"y",dimension:a.dimensions.y,resistance:r,movable:o}),a.userEvents.bind(["press","move","end","gesturestart","gesturechange"],{gesturestart:function(e){a.gesture=e,a.offset=fR(a.dimensions.container)},press:function(e){var t=e.event.target.closest("a");t&&t.matches("[data-navigate-on-press=true]")&&e.sender.cancel()},gesturechange:function(e){var t,r=a.gesture,s=r.center,l=e.center,c=e.distance/r.distance,d=a.dimensions.minScale,u=a.dimensions.maxScale;o.scale<=d&&c<1&&(c+=.8*(1-c)),o.scale*c>=u&&(c=u/o.scale);var h=o.x+a.offset.left,p=o.y+a.offset.top;t={x:(h-s.x)*c+l.x-h,y:(p-s.y)*c+l.y-p},o.scaleWith(c),n.dragMove(t.x),i.dragMove(t.y),a.dimensions.rescale(o.scale),a.gesture=e,e.preventDefault()},move:function(e){e.event.target.tagName.match(/textarea|input/i)||(n.dimension.enabled||i.dimension.enabled?(n.dragMove(e.x.delta),i.dragMove(e.y.delta),e.preventDefault()):e.touch.skip())},end:function(e){e.preventDefault()}})}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t}(fr),ZY=function(e,t,n){return"translate3d("+e+"px,"+t+"px,0) scale("+n+")"},JY=function(e){function t(t){e.call(this);var n=this;n.element=t,n.element.style.transformOrigin="left top",n.x=0,n.y=0,n.scale=1;var i=ZY(n.x,n.y,n.scale);n.element.style.transform=i,n._saveCoordinates(i)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.translateAxis=function(e,t){this[e]+=t,this.refresh()},t.prototype.scaleTo=function(e){this.scale=e,this.refresh()},t.prototype.scaleWith=function(e){this.scale*=e,this.refresh()},t.prototype.translate=function(e){this.x+=e.x,this.y+=e.y,this.refresh()},t.prototype.moveAxis=function(e,t){this[e]=t,this.refresh()},t.prototype.moveTo=function(e){jY(this,e),this.refresh()},t.prototype.refresh=function(){var e,t=this,n=t.x,i=t.y;t.round&&(n=Math.round(n),i=Math.round(i)),(e=ZY(n,i,t.scale))!==t.coordinates&&(t.element.style.transform=e,t._saveCoordinates(e),t.trigger(qY))},t.prototype._saveCoordinates=function(e){this.coordinates=e},t}(fL),eQ=vs,tQ=function(e){function t(t,n){e.call(this,t,n),this._pan=fY(this._pan,this),this.surface=vc.create(this.element,{width:t.scrollElement.clientWidth,height:t.scrollElement.clientHeight}),this._initRoot(),this.movable=new JY(this.surface.element),this._markers=[],this._click=this._handler("shapeClick"),this.surface.bind("click",this._click),this._mouseleave=this._handler("shapeMouseLeave"),this.surface.bind("mouseleave",this._mouseleave),this.surface.bind("mouseenter",this._mouseenter.bind(this))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){e.prototype.destroy.call(this),this.surface.destroy()},t.prototype._reset=function(){e.prototype._reset.call(this),this._translateSurface(),this._data=this._readData(),this._hasData()&&this._load(this._data)},t.prototype._initRoot=function(){this._root=new eQ,this.surface.draw(this._root)},t.prototype._beforeReset=function(){this.surface.clear(),this._initRoot()},t.prototype._resize=function(){this.surface.size(this.map.size())},t.prototype._readData=function(){var t=e.prototype._readData.call(this);return"FeatureCollection"===t.type?t.features:"GeometryCollection"===t.type?t.geometries:t},t.prototype._load=function(e){this._data=e,this._clearMarkers(),this._loader||(this._loader=new nQ(this.map,this.options.style,this));for(var t=new eQ,n=0;n<e.length;n++){var i=this._loader.parse(e[n]);i&&t.append(i)}this._root.clear(),this._root.append(t)},t.prototype.shapeCreated=function(e){var t=!1;if(e instanceof ua&&this.map.options.renderPointsAsMarkers&&(t=hR(this._createMarker(e))),!t){var n={layer:this,shape:e};t=this.map.trigger("shapeCreated",n)}return t},t.prototype.featureCreated=function(e){e.layer=this,this.map.trigger("shapeFeatureCreated",e)},t.prototype._createMarker=function(e){var t=this.map.markers.bind({location:e.location},e.dataItem);return t&&this._markers.push(t),t},t.prototype._clearMarkers=function(){for(var e=0;e<this._markers.length;e++)this.map.markers.remove(this._markers[e]);this._markers=[]},t.prototype._pan=function(){this._panning||(this._panning=!0,this.surface.suspendTracking())},t.prototype._panEnd=function(t){e.prototype._panEnd.call(this,t),this._translateSurface(),this.surface.resumeTracking(),this._panning=!1},t.prototype._translateSurface=function(){var e=this.map,t=e.locationToView(e.extent().nw);this.surface.translate&&(this.surface.translate(t),this.movable.moveTo({x:t.x,y:t.y}))},t.prototype._eventArgs=function(e){return{layer:this,layerIndex:this._layerIndex(),shape:e.element,shapeIndex:(this._data||[]).indexOf(e.element.dataItem),originalEvent:e.originalEvent}},t.prototype._handler=function(e){var t=this;return function(n){n.element&&t.map.trigger(e,t._eventArgs(n))}},t.prototype._mouseenter=function(e){if(e.element){this.map.trigger("shapeMouseEnter",this._eventArgs(e));var t=e.element,n=this._tooltipAnchor(e);this.map._tooltip.show(n,this._tooltipContext(t))}},t.prototype._tooltipContext=function(e){return{type:"shape",layerIndex:this._layerIndex(),className:"k-map-shape-tooltip",dataItem:e.dataItem,location:e.location}},t.prototype._tooltipAnchor=function(e){var t=this.map.eventOffset(e.originalEvent);return{top:t.y,left:t.x}},t.prototype._activate=function(){e.prototype._activate.call(this),this._panHandler=fY(this._pan,this),this.map.bind("pan",this.panHandler)},t.prototype._deactivate=function(){e.prototype._deactivate.call(this),this.map.unbind("pan",this._panHandler)},t}(FY);DR(tQ,{autoBind:!0,zIndex:100});var nQ=function(e){function t(t,n,i){e.call(this),this.observer=i,this.locator=t,this.style=n}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parse=function(e){var t=new eQ,n=!0;return"Feature"===e.type?(n=!1,this._loadGeometryTo(t,e.geometry,e),this._featureCreated(t,e)):this._loadGeometryTo(t,e,e),n&&t.children.length<2&&(t=t.children[0]),t},t.prototype._shapeCreated=function(e){var t=!1;return this.observer&&this.observer.shapeCreated&&(t=this.observer.shapeCreated(e)),t},t.prototype._featureCreated=function(e,t){this.observer&&this.observer.featureCreated&&this.observer.featureCreated({group:e,dataItem:t,properties:t.properties})},t.prototype._loadGeometryTo=function(e,t,n){var i,r,o=this,a=t.coordinates;switch(t.type){case"LineString":r=this._loadPolygon(e,[a],n),this._setLineFill(r);break;case"MultiLineString":for(i=0;i<a.length;i++)r=o._loadPolygon(e,[a[i]],n),o._setLineFill(r);break;case"Polygon":this._loadPolygon(e,a,n);break;case"MultiPolygon":for(i=0;i<a.length;i++)o._loadPolygon(e,a[i],n);break;case"Point":this._loadPoint(e,a,n);break;case"MultiPoint":for(i=0;i<a.length;i++)o._loadPoint(e,a[i],n)}},t.prototype._setLineFill=function(e){var t=e.segments;(t.length<4||!t[0].anchor().equals(bR(t).anchor()))&&(e.options.fill=null)},t.prototype._loadShape=function(e,t){return this._shapeCreated(t)||e.append(t),t},t.prototype._loadPolygon=function(e,t,n){var i=this._buildPolygon(t);return i.dataItem=n,i.location=this.locator.viewToLocation(i.bbox().center()),this._loadShape(e,i)},t.prototype._buildPolygon=function(e){for(var t=new(e.length>1?hs:us)(this.style),n=0;n<e.length;n++)for(var i=0;i<e[n].length;i++){var r=this.locator.locationToView(QK.fromLngLat(e[n][i]));0===i?t.moveTo(r.x,r.y):t.lineTo(r.x,r.y)}return t},t.prototype._loadPoint=function(e,t,n){var i=QK.fromLngLat(t),r=this.locator.locationToView(i),o=new oa(r,10),a=new ua(o,this.style);return a.dataItem=n,a.location=i,this._loadShape(e,a)},t}(fr),iQ=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._readData=function(){return this.options.data||[]},t.prototype._load=function(e){var t=this;if(this._data=e,this.surface.clear(),0!==e.length){var n=this.options,i=XF(n.valueField),r=e.slice(0);r.sort((function(e,t){return i(t)-i(e)}));for(var o,a=this._scaleType(),s=XF(this.options.locationField),l=0;l<r.length;l++){var c=r[l],d=s(c),u=i(c);if(hR(d)&&hR(u)){o||(o=new a([0,u],[n.minSize,n.maxSize])),d=QK.create(d);var h=t.map.locationToView(d),p=o.map(u),f=t._createSymbol({center:h,size:p,style:n.style,dataItem:c,location:d});f.dataItem=c,f.location=d,f.value=u,t._drawSymbol(f)}}}},t.prototype._scaleType=function(){var e=this.options.scale;return FF(e)?e:oQ[e]},t.prototype._createSymbol=function(e){var t=this.options.symbol;return FF(t)||(t=aQ[t]),t(e)},t.prototype._drawSymbol=function(e){var t={layer:this,shape:e};this.map.trigger("shapeCreated",t)||this.surface.draw(e)},t.prototype._tooltipContext=function(e){return{type:"bubble",layerIndex:this._layerIndex(),className:"k-map-bubble-tooltip",dataItem:e.dataItem,location:e.location,value:e.value}},t.prototype._tooltipAnchor=function(e){var t=e.element.bbox().center();return{top:t.y,left:t.x}},t}(tQ);DR(iQ,{locationField:"location",valueField:"value",minSize:0,maxSize:100,scale:"sqrt",symbol:"circle",zIndex:200});var rQ=function(e){function t(t,n){e.call(this),this._domain=t,this._range=n;var i=Math.sqrt(t[1])-Math.sqrt(t[0]),r=n[1]-n[0];this._ratio=r/i}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.map=function(e){var t=(Math.sqrt(e)-Math.sqrt(this._domain[0]))*this._ratio;return this._range[0]+t},t}(fr),oQ={sqrt:rQ},aQ={circle:function(e){var t=new oa(e.center,e.size/2);return new ua(t,e.style)},square:function(e){var t=new us(e.style),n=e.size/2,i=e.center;return t.moveTo(i.x-n,i.y-n).lineTo(i.x+n,i.y-n).lineTo(i.x+n,i.y+n).lineTo(i.x-n,i.y+n).close(),t}},sQ="click",lQ="mouseenter",cQ="mouseleave",dQ=Object.assign,uQ="k-marker",hQ="."+uQ,pQ=function(e){function t(t,n){e.call(this,t,n),this._markerClickHandler=fY(this._markerClick,this),rL(this.element,sQ,hQ,this._markerClickHandler),this.items=[],this._load(this._readData())}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){e.prototype.destroy.call(this),oL(this.element,sQ,this._markerClickHandler),this.clear()},t.prototype.add=function(e){if(!xF(e))return this._addOne(e);for(var t=0;t<e.length;t++)this._addOne(e[t])},t.prototype.remove=function(e){e.destroy();var t=(this.items||[]).indexOf(e);t>-1&&this.items.splice(t,1)},t.prototype.clear=function(){for(var e=0;e<this.items.length;e++)this.items[e].destroy();this.items=[]},t.prototype.update=function(e){var t=e.location();if(t){e.showAt(this.map.locationToView(t));var n={marker:e,layer:this};this.map.trigger("markerActivate",n)}},t.prototype._reset=function(){e.prototype._reset.call(this);for(var t=this.items,n=0;n<t.length;n++)this.update(t[n])},t.prototype.bind=function(e,t){var n=fQ.create(e,this.options);n.dataItem=t;var i={marker:n,layer:this};if(!this.map.trigger("markerCreated",i))return this.add(n),n},t.prototype._addOne=function(e){var t=fQ.create(e,this.options);return t.addTo(this),t},t.prototype._readData=function(){return this.options.data||[]},t.prototype._load=function(e){this._data=e,this.clear();for(var t=XF(this.options.locationField),n=XF(this.options.titleField),i=0;i<e.length;i++){var r=e[i];this.bind({location:t(r),title:n(r)},r)}},t.prototype._markerClick=function(e){var t=e.currentTarget._kendoNode,n={layer:this,layerIndex:this._layerIndex(),marker:t,markerIndex:(this.items||[]).indexOf(t),originalEvent:e};this.map.trigger("markerClick",n)},t.prototype._markerMouseEnter=function(e){var t=this._createMarkerEventArgs(e);this.map.trigger("markerMouseEnter",t)},t.prototype._markerMouseLeave=function(e){var t=this._createMarkerEventArgs(e);this.map.trigger("markerMouseLeave",t)},t.prototype._createMarkerEventArgs=function(e){var t=e.marker;return dQ({},{layer:this,layerIndex:this._layerIndex(),marker:t,markerIndex:(this.items||[]).indexOf(t)},e)},t}(FY);DR(pQ,{zIndex:1e3,autoBind:!0,locationField:"location",titleField:"title",template:""});var fQ=function(e){function t(t){e.call(this),this.options=t||{}}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this.layer=null,this.unbindEvents(),this.hide()},t.prototype.addTo=function(e){this.layer=e.markers||e,this.layer.items.push(this),this.layer.update(this)},t.prototype.location=function(e){return e?(this.options.location=QK.create(e).toArray(),this.layer&&this.layer.update(this),this):QK.create(this.options.location)},t.prototype.showAt=function(e){this.render(),this._anchor={left:Math.round(e.x),top:Math.round(e.y)},this.element.style.left=bY(this._anchor.left),this.element.style.top=bY(this._anchor.top)},t.prototype.hide=function(){this.element&&(this.element.remove(),this.element=null)},t.prototype.bindEvents=function(){this.element&&(this._mouseEnterHandler=fY(this._mouseEnter,this),rL(this.element,lQ,hQ,this._mouseEnterHandler),this._mouseLeaveHandler=fY(this._mouseLeave,this),rL(this.element,cQ,hQ,this._mouseLeaveHandler))},t.prototype.unbindEvents=function(){this.element&&(oL(this.element,lQ,this._mouseEnterHandler),oL(this.element,cQ,this._mouseLeaveHandler))},t.prototype.render=function(){if(!this.element){var e=this.options,t=this.layer,n=document.createElement("span");if(CF(n,uQ),this.options.template){var i=this._compileTemplate(this.options.template)(this.dataItem),r=mY(i);n.appendChild(r)}else if(e.svgIcon)HR(n,{icon:e.svgIcon,iconClass:"k-icon-xxl",svgIcons:this.options.icons.svgIcons,type:"svg"});else{var o={icon:"map-marker",iconClass:"k-icon-xxl",svgIcons:this.options.icons.svgIcons,type:this.options.icons.type};e.shape?"pinTarget"===e.shape?(o.icon="map-marker-target",HR(n,o)):"pin"===e.shape?HR(n,o):CF(n,"k-icon k-icon-xxl k-i-marker-"+_Y(e.shape||"pin")):HR(n,o)}e.title&&n.setAttribute("title",e.title);var a=e.attributes||{};Object.keys(a).forEach((function(e){n.setAttribute(e,a[e])})),n._kendoNode=this,n.style.zIndex=e.zIndex,this.element=n,t&&t.element.appendChild(this.element),this.bindEvents()}},t.prototype._mouseEnter=function(e){var t=this._createEventArgs(e);this.layer._markerMouseEnter(t),this.layer.map._tooltip.show({top:this._anchor.top-this.element.offsetHeight,left:this._anchor.left},this._tooltipContext())},t.prototype._tooltipContext=function(){return{type:"marker",layerIndex:this.layer._layerIndex(),className:"k-map-marker-tooltip",dataItem:this.dataItem,title:this.options.title,location:this.location()}},t.prototype._mouseLeave=function(e){var t=this._createEventArgs(e);this.layer._markerMouseLeave(t)},t.prototype._createEventArgs=function(e){return{marker:this,originalEvent:e}},t.prototype._compileTemplate=function(e){return qF.compile(e,{paramName:"dataItem",useWithBlock:!1})},t.create=function(e,n){return e instanceof t?e:new t(BF({},n,e))},t}(fr),mQ=Object.assign;function gQ(e){window.requestAnimationFrame(e)}var vQ=function(e){function t(){e.call(this);var t=this;t._tickProxy=fY(t._tick,t),t._started=!1}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.tick=function(){},t.prototype.done=function(){},t.prototype.onEnd=function(){},t.prototype.onCancel=function(){},t.prototype.start=function(){this.enabled()&&(this.done()?this.onEnd():(this._started=!0,gQ(this._tickProxy)))},t.prototype.enabled=function(){return!0},t.prototype.cancel=function(){this._started=!1,this.onCancel()},t.prototype._tick=function(){var e=this;e._started&&(e.tick(),e.done()?(e._started=!1,e.onEnd()):gQ(e._tickProxy))},t}(fr),_Q=function(e){function t(t){e.call(this),mQ(this,t)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.done=function(){return this.timePassed()>=this.duration},t.prototype.timePassed=function(){return Math.min(this.duration,cL()-this.startDate)},t.prototype.moveTo=function(e){var t=this,n=t.movable;t.initial=n[t.axis],t.delta=e.location-t.initial,t.duration="number"==typeof e.duration?e.duration:300,t.tick=t._easeProxy(e.ease),t.startDate=cL(),t.start()},t.prototype._easeProxy=function(e){var t=this;return function(){t.movable.moveAxis(t.axis,e(t.timePassed(),t.initial,t.delta,t.duration))}},t.easeOutExpo=function(e,t,n,i){return e===i?t+n:n*(1-Math.pow(2,-10*e/i))+t},t}(vQ),bQ=Object.assign,yQ=Math.abs,wQ="change",kQ="scroll",xQ=function(e){function t(t){e.call(this,t);var n=this;bQ(n,t),n.userEvents.bind("gestureend",n.start.bind(this)),n.tapCapture.bind("press",n.cancel.bind(this))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.enabled=function(){return this.movable.scale<this.dimensions.minScale},t.prototype.done=function(){return this.dimensions.minScale-this.movable.scale<.01},t.prototype.tick=function(){var e=this.movable;e.scaleWith(1.1),this.dimensions.rescale(e.scale)},t.prototype.onEnd=function(){var e=this.movable;e.scaleTo(this.dimensions.minScale),this.dimensions.rescale(e.scale)},t}(vQ),CQ=function(e){function t(t){e.call(this);var n=this;bQ(n,t,{transition:new _Q({axis:t.axis,movable:t.movable,onEnd:function(){n._end()}})}),n.tapCapture.bind("press",(function(){n.cancel()})),n.userEvents.bind("end",fY(n.start,n)),n.userEvents.bind("gestureend",fY(n.start,n)),n.userEvents.bind("tap",fY(n.onEnd,n))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.onCancel=function(){this.transition.cancel()},t.prototype.freeze=function(e){this.cancel(),this._moveTo(e)},t.prototype.onEnd=function(){var e=this;e.paneAxis.outOfBounds()?e._snapBack():e._end()},t.prototype.done=function(){return yQ(this.velocity)<1},t.prototype.start=function(t){var n,i=this;i.dimension.enabled&&(i.paneAxis.outOfBounds()?i.transition._started?(i.transition.cancel(),i.velocity=Math.min(t.touch[i.axis].velocity*i.velocityMultiplier,55),e.prototype.start.call(this)):i._snapBack():(n=2===t.touch.id?0:t.touch[i.axis].velocity,i.velocity=Math.max(Math.min(n*i.velocityMultiplier,55),-55),i.tapCapture.captureNext(),e.prototype.start.call(this)))},t.prototype.tick=function(){var e=this,t=e.dimension,n=e.paneAxis.outOfBounds()?.5:e.friction,i=e.velocity*=n,r=e.movable[e.axis]+i;!e.elastic&&t.outOfBounds(r)&&(r=Math.max(Math.min(r,t.max),t.min),e.velocity=0),e.movable.moveAxis(e.axis,r)},t.prototype._end=function(){this.tapCapture.cancelCapture(),this.end()},t.prototype._snapBack=function(){var e=this,t=e.dimension,n=e.movable[e.axis]>t.max?t.max:t.min;e._moveTo(n)},t.prototype._moveTo=function(e){this.transition.moveTo({location:e,duration:500,ease:_Q.easeOutExpo})},t}(vQ),SQ=function(e){function t(t){e.call(this,t);bQ(this,t,{origin:{},destination:{},offset:{}})}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.tick=function(){this._updateCoordinates(),this.moveTo(this.origin)},t.prototype.done=function(){return yQ(this.offset.y)<5&&yQ(this.offset.x)<5},t.prototype.onEnd=function(){this.moveTo(this.destination),this.callback&&this.callback.call()},t.prototype.setCoordinates=function(e,t){this.offset={},this.origin=e,this.destination=t},t.prototype.setCallback=function(e){e&&FF(e)?this.callback=e:e=void 0},t.prototype._updateCoordinates=function(){this.offset={x:(this.destination.x-this.origin.x)/4,y:(this.destination.y-this.origin.y)/4},this.origin={y:this.origin.y+this.offset.y,x:this.origin.x+this.offset.x}},t}(vQ),TQ=function(e){function t(t){e.call(this);var n=this,i="x"===t.axis,r=mY('<div class="km-touch-scrollbar km-'+(i?"horizontal":"vertical")+'-scrollbar" />');bQ(n,t,{element:r,elementSize:0,movable:new JY(r),scrollMovable:t.movable,alwaysVisible:t.alwaysVisible,size:i?"width":"height"}),n.scrollMovable.bind(wQ,n.refresh.bind(n)),n.container.appendChild(r),t.alwaysVisible&&n.show()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.refresh=function(){var e=this,t=e.axis,n=e.dimension,i=n.size,r=e.scrollMovable,o=i/n.total,a=Math.round(-r[t]*o),s=Math.round(i*o);this.element.style.display=o>=1?"none":"",a+s>i?s=i-a:a<0&&(s+=a,a=0),e.elementSize!==s&&(e.element.style[e.size]=s+"px",e.elementSize=s),e.movable.moveAxis(t,a)},t.prototype.show=function(){this.element.style.opacity=.7,this.element.style.visibility="visible"},t.prototype.hide=function(){this.alwaysVisible||(this.element.style.opacity=0)},t}(fr),DQ=function(e){function t(t,n){e.call(this);var i=this;this.element=t,this._initOptions(n);var r=function(){var e=aL().mobileOS;return e.ios||e.android}(navigator.userAgent);i._native=i.options.useNative&&r;var o=mY('<div class="km-scroll-header"/>');if(i._native)return CF(t,"km-native-scroller"),vY(o,t),void bQ(i,{scrollElement:t,fixedContainer:t.children[0]});t.style.overflow="hidden",CF(t,"km-scroll-wrapper"),function(e,t){for(e.appendChild(t);e.firstChild!==t;)t.appendChild(e.firstChild)}(t,mY('<div class="km-scroll-container"/>')),vY(o,t);var a=t.children[1],s=new GY(t),l=new JY(a),c=new YY({element:a,container:t,forcedEnabled:i.options.zoom}),d=this.options.avoidScrolling,u=new LL(t,{touchAction:"none",allowSelection:!0,preventDragEvent:!0,captureUpIfMoved:!0,multiTouch:i.options.zoom,supportDoubleTap:i.options.supportDoubleTap,start:function(e){c.refresh();var t=yQ(e.x.velocity),n=yQ(e.y.velocity),r=2*t>=n,o=2*n>=t;!i.fixedContainer.contains(e.event.target)&&!d(e)&&i.enabled&&(c.x.enabled&&r||c.y.enabled&&o)?u.capture():u.cancel()}}),h=new XY({movable:l,dimensions:c,userEvents:u,elastic:i.options.elastic}),p=new xQ({movable:l,dimensions:c,userEvents:u,tapCapture:s}),f=new SQ({moveTo:function(e){i.scrollTo(e.x,e.y)}});l.bind(wQ,(function(){i.scrollTop=-l.y,i.scrollLeft=-l.x,i.trigger(kQ,{scrollTop:i.scrollTop,scrollLeft:i.scrollLeft})})),i.options.mousewheelScrolling&&(this._wheelScrollHandler=this._wheelScroll.bind(this),rL(t,"wheel",this._wheelScrollHandler)),bQ(i,{movable:l,dimensions:c,zoomSnapBack:p,animatedScroller:f,userEvents:u,pane:h,tapCapture:s,pulled:!1,enabled:!0,scrollElement:a,scrollTop:0,scrollLeft:0,fixedContainer:t.children[0]}),i._initAxis("x"),i._initAxis("y"),i._wheelEnd=function(){i._wheel=!1,i.userEvents.end(0,i._wheelY)},c.refresh(),i.options.pullToRefresh&&i._initPullToRefresh()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype._initOptions=function(e){this.options=BF({},this.options,e)},t.prototype._wheelScroll=function(e){if(!e.ctrlKey){this._wheel||(this._wheel=!0,this._wheelY=0,this.userEvents.press(0,this._wheelY)),clearTimeout(this._wheelTimeout),this._wheelTimeout=setTimeout(this._wheelEnd,50);var t=function(e){var t,n=e.wheelDeltaY;return e.wheelDelta?(void 0===n||n)&&(t=e.wheelDelta):e.detail&&e.axis===e.VERTICAL_AXIS&&(t=10*-e.detail),t}(e);t&&(this._wheelY+=t,this.userEvents.move(0,this._wheelY)),e.preventDefault()}},t.prototype.makeVirtual=function(){this.dimensions.y.makeVirtual()},t.prototype.virtualSize=function(e,t){this.dimensions.y.virtualSize(e,t)},t.prototype.height=function(){return this.dimensions.y.size},t.prototype.scrollHeight=function(){return this.scrollElement.scrollHeight},t.prototype.scrollWidth=function(){return this.scrollElement.scrollWidth},t.prototype._resize=function(){this._native||this.contentResized()},t.prototype.setOptions=function(e){this._initOptions(e),e.pullToRefresh&&this._initPullToRefresh()},t.prototype.reset=function(){this._native?this.scrollElement.scrollTop(0):(this.movable.moveTo({x:0,y:0}),this._scale(1))},t.prototype.contentResized=function(){this.dimensions.refresh(),this.pane.x.outOfBounds()&&this.movable.moveAxis("x",this.dimensions.x.min),this.pane.y.outOfBounds()&&this.movable.moveAxis("y",this.dimensions.y.min)},t.prototype.zoomOut=function(){var e=this.dimensions;e.refresh(),this._scale(e.fitScale),this.movable.moveTo(e.centerCoordinates())},t.prototype.enable=function(){this.enabled=!0},t.prototype.disable=function(){this.enabled=!1},t.prototype.scrollTo=function(e,t){this._native?(this.scrollElement.scrollLeft(yQ(e)),this.scrollElement.scrollTop(yQ(t))):(this.dimensions.refresh(),this.movable.moveTo({x:e,y:t}))},t.prototype.animatedScrollTo=function(e,t,n){var i,r;this._native?this.scrollTo(e,t):(i={x:this.movable.x,y:this.movable.y},r={x:e,y:t},this.animatedScroller.setCoordinates(i,r),this.animatedScroller.setCallback(n),this.animatedScroller.start())},t.prototype.pullHandled=function(){},t.prototype.destroy=function(){oL(this.element,"wheel",this._wheelScrollHandler),this.userEvents&&this.userEvents.destroy()},t.prototype._scale=function(e){this.dimensions.rescale(e),this.movable.scaleTo(e)},t.prototype._initPullToRefresh=function(){},t.prototype._dragEnd=function(){},t.prototype._paneChange=function(){},t.prototype._initAxis=function(e){var t=this,n=t.movable,i=t.dimensions[e],r=t.tapCapture,o=t.pane[e],a=new TQ({axis:e,movable:n,dimension:i,container:t.element,alwaysVisible:t.options.visibleScrollHints});i.bind(wQ,(function(){a.refresh()})),o.bind(wQ,(function(){a.show()})),t[e+"inertia"]=new CQ({axis:e,paneAxis:o,movable:n,tapCapture:r,userEvents:t.userEvents,dimension:i,elastic:t.options.elastic,friction:t.options.friction||.96,velocityMultiplier:t.options.velocityMultiplier||10,end:function(){a.hide(),t.trigger("scrollEnd",{axis:e,scrollTop:t.scrollTop,scrollLeft:t.scrollLeft})}})},t}(fL);DR(DQ,{name:"Scroller",zoom:!1,pullOffset:140,visibleScrollHints:!1,elastic:!0,useNative:!1,mousewheelScrolling:!0,avoidScrolling:function(){return!1},pullToRefresh:!1,messages:{pullTemplate:"Pull to refresh",releaseTemplate:"Release to refresh",refreshTemplate:"Refreshing"}}),yY(DQ,["pull",kQ,"resize"]);var AQ=function(e,t){void 0===t&&(t={}),this.sender=t.sender||e,this.widget=e,this.rtl=Boolean(t.rtl)};AQ.prototype.notify=function(e,t){this.widget&&this.widget.trigger(e,t)};var MQ=Math,EQ=MQ.min,IQ=MQ.pow,zQ=Go,PQ="marker",HQ="location",FQ="wheel",RQ={bubble:iQ,shape:tQ,tile:NY};RQ[PQ]=pQ;var LQ=function(e){function t(t,n,i,r){void 0===n&&(n={}),void 0===i&&(i={}),void 0===r&&(r={}),e.call(this),this._init(t,n,i,r)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this.scroller.destroy(),this._tooltip&&this._tooltip.destroy(),this.navigator&&this.navigator.destroy(),this.attribution&&this.attribution.destroy(),this.zoomControl&&this.zoomControl.destroy(),xF(this.markers)?this.markers.forEach((function(e){e.destroy()})):this.markers.destroy();for(var t=0;t<this.layers.length;t++)this.layers[t].destroy();oL(this.element,FQ,this._mousewheelHandler),e.prototype.destroy.call(this)},t.prototype._init=function(e,t,n,i){void 0===t&&(t={}),void 0===n&&(n={}),void 0===i&&(i={}),this.support=aL(),this.context=i,this.initObserver(i),this.initServices(i),this._notifyObserver("init"),this._initOptions(t),this._setEvents(t),this.crs=new pY,this._initElement(e),this._viewOrigin=this._getOrigin(),this._tooltip=this._createTooltip(),this._initScroller(),this._initMarkers(),this._initControls(),this._initLayers(),this._reset();var r=Pr(this._mousewheel.bind(this),50);this._mousewheelHandler=function(e){e.preventDefault(),r(e)},rL(this.element,FQ,this._mousewheelHandler)},t.prototype._initOptions=function(e){this.options=BF({},this.options,e)},t.prototype._initElement=function(e){this.element=e,CF(e,"k-map"),e.style.position="relative",e.setAttribute("data-role","map"),gY(e);var t=mY("<div />");this.element.appendChild(t)},t.prototype.initServices=function(e){void 0===e&&(e={}),this.widgetService=new AQ(this,e)},t.prototype.initObserver=function(e){void 0===e&&(e={}),this.observers=[],this.addObserver(e.observer)},t.prototype.addObserver=function(e){e&&this.observers.push(e)},t.prototype.removeObserver=function(e){var t=this.observers.indexOf(e);t>=0&&this.observers.splice(t,1)},t.prototype.requiresHandlers=function(e){for(var t=this.observers,n=0;n<t.length;n++)if(t[n].requiresHandlers(e))return!0},t.prototype.trigger=function(t,n){void 0===n&&(n={}),n.sender=this;for(var i=this.observers,r=!1,o=0;o<i.length;o++)i[o].trigger(t,n)&&(r=!0);return r||e.prototype.trigger.call(this,t,n),r},t.prototype._notifyObserver=function(e,t){void 0===t&&(t={}),t.sender=this;for(var n=this.observers,i=!1,r=0;r<n.length;r++)n[r].trigger(e,t)&&(i=!0);return i},t.prototype.zoom=function(e){var t,n=this.options;if(hR(e)){var i=MQ.round(yR(e,n.minZoom,n.maxZoom));n.zoom!==i&&(n.zoom=i,this.widgetService.notify("zoomChange",{zoom:n.zoom}),this._reset()),t=this}else t=n.zoom;return t},t.prototype.center=function(e){var t;if(e){var n=QK.create(e),i=QK.create(this.options.center);n.equals(i)||(this.options.center=n.toArray(),this.widgetService.notify(PY,{center:this.options.center}),this._reset()),t=this}else t=QK.create(this.options.center);return t},t.prototype.extent=function(e){var t;return e?(this._setExtent(e),t=this):t=this._getExtent(),t},t.prototype.setOptions=function(e){void 0===e&&(e={});var t=this.element;this.destroy(),gY(t),this._init(t,e,{},this.context),this._reset()},t.prototype.locationToLayer=function(e,t){var n=!this.options.wraparound,i=QK.create(e);return this.crs.toPoint(i,this._layerSize(t),n)},t.prototype.layerToLocation=function(e,t){var n=!this.options.wraparound,i=zQ.create(e);return this.crs.toLocation(i,this._layerSize(t),n)},t.prototype.locationToView=function(e){var t=QK.create(e),n=this.locationToLayer(this._viewOrigin);return this.locationToLayer(t).translateWith(n.scale(-1))},t.prototype.viewToLocation=function(e,t){var n=this.locationToLayer(this._getOrigin(),t),i=zQ.create(e).clone().translateWith(n);return this.layerToLocation(i,t)},t.prototype.eventOffset=function(e){var t,n,i=fR(this.element);if(e.x&&e.x[HQ]||e.y&&e.y[HQ])t=e.x[HQ]-i.left,n=e.y[HQ]-i.top;else{var r=e.originalEvent||e;t=SR(r.pageX,r.clientX)-i.left,n=SR(r.pageY,r.clientY)-i.top}return new Go(t,n)},t.prototype.eventToView=function(e){var t=this.eventOffset(e);return this.locationToView(this.viewToLocation(t))},t.prototype.eventToLayer=function(e){return this.locationToLayer(this.eventToLocation(e))},t.prototype.eventToLocation=function(e){var t=this.eventOffset(e);return this.viewToLocation(t)},t.prototype.viewSize=function(){var e=this.element,t=this._layerSize(),n=e.clientWidth;return this.options.wraparound||(n=EQ(t,n)),{width:n,height:EQ(t,e.clientHeight)}},t.prototype.exportVisual=function(){return this._reset(),!1},t.prototype.hideTooltip=function(){this._tooltip&&this._tooltip.hide()},t.prototype._setOrigin=function(e,t){var n,i=this.viewSize(),r=this._origin=QK.create(e);return(n=this.locationToLayer(r,t)).x+=i.width/2,n.y+=i.height/2,this.options.center=this.layerToLocation(n,t).toArray(),this.widgetService.notify(PY,{center:this.options.center}),this},t.prototype._getOrigin=function(e){var t,n=this.viewSize();return!e&&this._origin||((t=this.locationToLayer(this.center())).x-=n.width/2,t.y-=n.height/2,this._origin=this.layerToLocation(t)),this._origin},t.prototype._setExtent=function(e){var t=zY.create(e),n=t.se.clone();this.options.wraparound&&n.lng<0&&e.nw.lng>0&&(n.lng=180+(180+n.lng));var i=new zY(t.nw,n);this.center(i.center());var r,o=this.element.clientWidth,a=this.element.clientHeight;for(r=this.options.maxZoom;r>=this.options.minZoom;r--){var s=this.locationToLayer(i.nw,r),l=this.locationToLayer(i.se,r),c=MQ.abs(l.x-s.x),d=MQ.abs(l.y-s.y);if(c<=o&&d<=a)break}this.zoom(r)},t.prototype._getExtent=function(){var e=this._getOrigin(),t=this.locationToLayer(e),n=this.viewSize();t.x+=n.width,t.y+=n.height;var i=this.layerToLocation(t);return new zY(e,i)},t.prototype._zoomAround=function(e,t){this._setOrigin(this.layerToLocation(e,t),t),this.zoom(t)},t.prototype._initControls=function(){var e=this.options.controls;e.attribution&&this._createAttribution(e.attribution),this.support.mobileOS||(e.navigator&&this._createNavigator(e.navigator),e.zoom&&this._createZoomControl(e.zoom))},t.prototype._createControlElement=function(e,t){var n=e.position||t,i="."+wY(n).replace(" ","."),r=this.element.querySelector(".k-map-controls"+i)||[];if(0===r.length){var o=document.createElement("div");CF(o,"k-map-controls "+wY(n)),r=o,this.element.appendChild(r)}var a=document.createElement("div");return r.appendChild(a),a},t.prototype._createAttribution=function(e){var t=this._createControlElement(e,"bottomRight");this.attribution=new kY(t,e)},t.prototype._createNavigator=function(e){var t=this._createControlElement(e,"topLeft"),n=this.navigator=new SY(t,BF({},e,{icons:this.options.icons}));this._navigatorPan=this._navigatorPan.bind(this),n.bind("pan",this._navigatorPan),this._navigatorCenter=this._navigatorCenter.bind(this),n.bind("center",this._navigatorCenter)},t.prototype._navigatorPan=function(e){var t=this.scroller,n=t.scrollLeft+e.x,i=t.scrollTop-e.y,r=this._virtualSize,o=this.element.clientWidth,a=this.element.clientHeight;n=yR(n,r.x.min,r.x.max-o),i=yR(i,r.y.min,r.y.max-a),this.scroller.one("scroll",fY(this._scrollEnd,this)),this.scroller.scrollTo(-n,-i)},t.prototype._navigatorCenter=function(){this.center(this.options.center)},t.prototype._createZoomControl=function(e){var t=this._createControlElement(e,"topLeft"),n=this.zoomControl=new AY(t,e,this.options.icons);this._zoomControlChange=this._zoomControlChange.bind(this),n.bind("change",this._zoomControlChange)},t.prototype._zoomControlChange=function(e){this.trigger("zoomStart",{originalEvent:e})||(this.zoom(this.zoom()+e.delta),this.trigger("zoomEnd",{originalEvent:e}))},t.prototype._initScroller=function(){var e=this.support.mobileOS?.93:.9,t=!1!==this.options.zoomable,n=this.scroller=new DQ(this.element.children[0],{friction:e,velocityMultiplier:5,zoom:t,mousewheelScrolling:!1,supportDoubleTap:!0});n.bind("scroll",fY(this._scroll,this)),n.bind("scrollEnd",fY(this._scrollEnd,this)),n.userEvents.bind("gesturestart",fY(this._scaleStart,this)),n.userEvents.bind("gestureend",fY(this._scale,this)),n.userEvents.bind("doubleTap",fY(this._doubleTap,this)),n.userEvents.bind("tap",fY(this._tap,this)),this.scrollElement=n.scrollElement},t.prototype._initLayers=function(){for(var e=this.options.layers,t=this.layers=[],n=0;n<e.length;n++){var i=e[n],r=this._createLayer(i);t.push(r)}},t.prototype._createLayer=function(e){var t=e.type||"shape",n=this.options.layerDefaults[t],i=t===PQ?BF({},this.options.markerDefaults,e,{icons:this.options.icons}):BF({},n,e),r=new(0,RQ[t])(this,i);return t===PQ&&(this.markers=r),r},t.prototype._createTooltip=function(){return new HY(this.widgetService,this.options.tooltip)},t.prototype._initMarkers=function(){var e=(this.options.layers||[]).filter((function(e){return e&&e.type===PQ}));e.length>0||(this.markers=new pQ(this,BF({},this.options.markerDefaults,{icons:this.options.icons})),this.markers.add(this.options.markers))},t.prototype._scroll=function(e){var t=this.locationToLayer(this._viewOrigin).round(),n=e.sender.movable,i=new Go(n.x,n.y).scale(-1).scale(1/n.scale);t.x+=i.x,t.y+=i.y,this._scrollOffset=i,this._tooltip.offset=i,this.hideTooltip(),this._setOrigin(this.layerToLocation(t)),this.trigger("pan",{originalEvent:e,origin:this._getOrigin(),center:this.center()})},t.prototype._scrollEnd=function(e){this._scrollOffset&&this._panComplete()&&(this._scrollOffset=null,this._panEndTimestamp=cL(),this.trigger("panEnd",{originalEvent:e,origin:this._getOrigin(),center:this.center()}))},t.prototype._panComplete=function(){return cL()-(this._panEndTimestamp||0)>50},t.prototype._scaleStart=function(e){if(this.trigger("zoomStart",{originalEvent:e})){var t=e.touches[1];t&&t.cancel()}},t.prototype._scale=function(e){var t=this.scroller.movable.scale,n=this._scaleToZoom(t),i=new Go(e.center.x,e.center.y),r=this.viewToLocation(i,n),o=this.locationToLayer(r,n).translate(-i.x,-i.y);this._zoomAround(o,n),this.trigger("zoomEnd",{originalEvent:e})},t.prototype._scaleToZoom=function(e){var t=this._layerSize()*e/this.options.minSize,n=MQ.log(t)/MQ.log(2);return MQ.round(n)},t.prototype._reset=function(){this.attribution&&this.attribution.filter(this.center(),this.zoom()),this._viewOrigin=this._getOrigin(!0),this._resetScroller(),this.hideTooltip(),this.trigger("beforeReset"),this.trigger("reset")},t.prototype._resetScroller=function(){var e=this.scroller,t=e.dimensions.x,n=e.dimensions.y,i=this._layerSize(),r=this.extent().nw,o=this.locationToLayer(r).round();e.movable.round=!0,e.reset(),e.userEvents.cancel();var a=this.zoom();e.dimensions.forcedMinScale=IQ(2,this.options.minZoom-a),e.dimensions.maxScale=IQ(2,this.options.maxZoom-a);var s={min:-o.x,max:i-o.x},l={min:-o.y,max:i-o.y};if(this.options.wraparound&&(s.max=20*i,s.min=-s.max),!1===this.options.pannable){var c=this.viewSize();s.min=l.min=0,s.max=c.width,l.max=c.height}t.makeVirtual(),n.makeVirtual(),t.virtualSize(s.min,s.max),n.virtualSize(l.min,l.max),this._virtualSize={x:s,y:l}},t.prototype._renderLayers=function(){},t.prototype._layerSize=function(e){var t=SR(e,this.options.zoom);return this.options.minSize*IQ(2,t)},t.prototype._tap=function(e){if(this._panComplete()){var t=this.eventOffset(e);this.hideTooltip(),this.trigger("click",{originalEvent:e,location:this.viewToLocation(t)})}},t.prototype._doubleTap=function(e){if(!1!==this.options.zoomable&&!this.trigger("zoomStart",{originalEvent:e})){var t=this.zoom()+1,n=this.eventOffset(e),i=this.viewToLocation(n),r=this.locationToLayer(i,t).translate(-n.x,-n.y);this._zoomAround(r,t),this.trigger("zoomEnd",{originalEvent:e})}},t.prototype._mousewheel=function(e){var t=lR(e)>0?-1:1,n=this.options,i=this.zoom(),r=yR(i+t,n.minZoom,n.maxZoom);if(!1!==n.zoomable&&r!==i&&!this.trigger("zoomStart",{originalEvent:e})){var o=this.eventOffset(e),a=this.viewToLocation(o),s=this.locationToLayer(a,r).translate(-o.x,-o.y);this._zoomAround(s,r),this.trigger("zoomEnd",{originalEvent:e})}},t.prototype._toDocumentCoordinates=function(e){var t=fR(this.element);return{left:xR(e.x+t.left),top:xR(e.y+t.top)}},t}(fL);DR(LQ,{name:"Map",controls:{attribution:!0,navigator:{panStep:100},zoom:!0},layers:[],layerDefaults:{shape:{style:{fill:{color:"#fff"},stroke:{color:"#aaa",width:.5}}},bubble:{style:{fill:{color:"#fff",opacity:.5},stroke:{color:"#aaa",width:.5}}},marker:{shape:"pinTarget",tooltip:{position:"top"}}},center:[0,0],icons:{type:"font",svgIcons:{}},zoom:3,minSize:256,minZoom:1,maxZoom:19,markers:[],markerDefaults:{shape:"pinTarget",tooltip:{position:"top"}},wraparound:!0,renderPointsAsMarkers:!1}),yY(LQ,["beforeReset","click","markerActivate","markerClick","markerCreated","markerMouseEnter","markerMouseLeave","pan","panEnd","reset","shapeClick","shapeCreated","shapeFeatureCreated","shapeMouseEnter","shapeMouseLeave","zoomEnd","zoomStart"]);var BQ=function(e,t){return e.map(t).reduce((function(e,t){return e+t}),0)},OQ=function(e,t){return e.y0===t.y0?e.index-t.index:e.y0+e.y1-t.y0-t.y1},VQ=function(e,t){return OQ(e.source,t.source)},NQ=function(e,t){return OQ(e.target,t.target)},$Q=function(e){return e.value};function UQ(e){e.forEach((function(e){e.targetLinks.forEach((function(e){e.source.sourceLinks.sort(NQ)})),e.sourceLinks.forEach((function(e){e.target.targetLinks.sort(VQ)}))}))}var WQ=function(e,t){return"left"===e.align?e.depth:"right"===e.align?t-e.height:e.sourceLinks.length?e.depth:t},jQ=function(e){var t=e.nodesOptions,n=t.offset;void 0===n&&(n={});var i=t.align;this.data={nodes:e.nodes.map((function(e){return BF({},{offset:n,align:i},e)})),links:e.links.map((function(e){return BF({},e)}))},this.width=e.width,this.height=e.height,this.offsetX=e.offsetX||0,this.offsetY=e.offsetY||0,this.nodeWidth=e.nodesOptions.width,this.nodePadding=e.nodesOptions.padding,this.reverse=e.reverse,this.targetColumnIndex=e.targetColumnIndex,this.loops=e.loops,this.autoLayout=e.autoLayout};jQ.prototype.calculate=function(){var e=this.data,t=e.nodes,n=e.links;this.connectLinksToNodes(t,n),this.calculateNodeValues(t);var i=this.calculateNodeHeights(t);if(i)return{nodes:[],links:[],columns:[],circularLinks:i};this.calculateNodeDepths(t);var r=this.calculateNodeColumns(t);return this.calculateNodeBreadths(r),this.applyNodesOffset(t),this.calculateLinkBreadths(t),Object.assign({},this.data,{columns:r})},jQ.prototype.connectLinksToNodes=function(e,t){var n=new Map;e.forEach((function(e,t){e.index=t,e.sourceLinks=[],e.targetLinks=[],e.id=void 0!==e.id?e.id:e.label.text,n.set(e.id,e)})),t.forEach((function(e){e.source=n.get(e.sourceId),e.target=n.get(e.targetId),e.source.sourceLinks.push(e),e.target.targetLinks.push(e)}))},jQ.prototype.calculateNodeValues=function(e){e.forEach((function(e){e.value=Math.max(BQ(e.sourceLinks,$Q),BQ(e.targetLinks,$Q))}))},jQ.prototype.calculateNodeDepths=function(e){for(var t=new Set(e),n=new Set,i=0;t.size;){for(var r=Array.from(t),o=0;o<r.length;o++){var a=r[o];a.depth=i;for(var s=0;s<a.sourceLinks.length;s++){var l=a.sourceLinks[s];n.add(l.target)}}i++,t=n,n=new Set}},jQ.prototype.calculateNodeHeights=function(e){for(var t=e.length,n=new Set(e),i=new Set,r=0,o=function(e){e.height=r,e.targetLinks.forEach((function(e){i.add(e.source)}))};n.size;){if(n.forEach(o),++r>t)return!0;n=i,i=new Set}return!1},jQ.prototype.calculateNodeColumns=function(e){for(var t,n,i=(t=e,n=function(e){return e.depth},Math.max.apply(null,t.map(n))),r=(this.width-this.offsetX-this.nodeWidth)/i,o=new Array(i+1),a=0;a<e.length;a++){var s=e[a],l=Math.max(0,Math.min(i,WQ(s,i)));s.x0=this.offsetX+l*r,s.x1=s.x0+this.nodeWidth,s.layer=l,o[l]=o[l]||[],o[l].push(s)}return o},jQ.prototype.calculateNodeBreadths=function(e){var t,n,i=this,r=(t=e,n=function(e){return(i.height-i.offsetY-(e.length-1)*i.nodePadding)/BQ(e,$Q)},Math.min.apply(null,t.map(n)));if(e.forEach((function(e){var t=i.offsetY;e.forEach((function(e){e.y0=t,e.y1=t+e.value*r,t=e.y1+i.nodePadding,e.sourceLinks.forEach((function(e){e.width=e.value*r}))})),t=(i.height-t+i.nodePadding)/(e.length+1),e.forEach((function(e,n){e.y0+=t*(n+1),e.y1+=t*(n+1)}))})),!1!==this.autoLayout)for(var o=void 0!==this.loops?this.loops:e.length-1,a=this.targetColumnIndex||1,s=0;s<o;s++)i.reverse?(i.uncurlLinksToRight(e,a),i.uncurlLinksToLeft(e,a)):(i.uncurlLinksToLeft(e,a),i.uncurlLinksToRight(e,a));e.forEach(UQ)},jQ.prototype.applyNodesOffset=function(e){e.forEach((function(e){var t=(e.offset?e.offset.left:0)||0,n=(e.offset?e.offset.top:0)||0;e.x0+=t,e.x1+=t,e.y0+=n,e.y1+=n}))},jQ.prototype.calculateLinkBreadths=function(e){e.forEach((function(e){var t=e.sourceLinks,n=e.targetLinks,i=e.y0,r=i;t.forEach((function(e){e.x0=e.source.x1,e.y0=i+e.width/2,i+=e.width})),n.forEach((function(e){e.x1=e.target.x0,e.y1=r+e.width/2,r+=e.width}))}))},jQ.prototype.uncurlLinksToRight=function(e,t){for(var n=this,i=e.length,r=t;r<i;r++){var o=e[r];o.forEach((function(e){var t=0,i=0;e.targetLinks.forEach((function(r){var o=r.value*(e.layer-r.source.layer);t+=n.targetTopPos(r.source,e)*o,i+=o}));var r=0===t?0:t/i-e.y0;e.y0+=r,e.y1+=r,UQ([e])})),o.sort(OQ),n.arrangeNodesVertically(o)}},jQ.prototype.uncurlLinksToLeft=function(e,t){for(var n=this,i=e.length-1-t;i>=0;i--){for(var r=e[i],o=function(e){var t=r[e],i=0,o=0;t.sourceLinks.forEach((function(e){var r=e.value*(e.target.layer-t.layer);i+=n.sourceTopPos(t,e.target)*r,o+=r}));var a=0===i?0:i/o-t.y0;t.y0+=a,t.y1+=a,UQ([t])},a=0;a<r.length;a++)o(a);r.sort(OQ),n.arrangeNodesVertically(r)}},jQ.prototype.arrangeNodesVertically=function(e){var t=e.length-1;this.arrangeUp(e,this.height,t),this.arrangeDown(e,this.offsetY,0)},jQ.prototype.arrangeDown=function(e,t,n){for(var i=t,r=n;r<e.length;r++){var o=e[r],a=Math.max(0,i-o.y0);o.y0+=a,o.y1+=a,i=o.y1+this.nodePadding}},jQ.prototype.arrangeUp=function(e,t,n){for(var i=t,r=n;r>=0;--r){var o=e[r],a=Math.max(0,o.y1-i);o.y0-=a,o.y1-=a,i=o.y0-this.nodePadding}},jQ.prototype.sourceTopPos=function(e,t){for(var n=t.y0-(t.targetLinks.length-1)*this.nodePadding/2,i=0;i<t.targetLinks.length;i++){var r=t.targetLinks[i];if(r.source===e)break;n+=r.width+this.nodePadding}for(var o=0;o<e.sourceLinks.length;o++){var a=e.sourceLinks[o];if(a.target===t)break;n-=a.width}return n},jQ.prototype.targetTopPos=function(e,t){for(var n=e.y0-(e.sourceLinks.length-1)*this.nodePadding/2,i=0;i<e.sourceLinks.length;i++){var r=e.sourceLinks[i];if(r.target===t)break;n+=r.width+this.nodePadding}for(var o=0;o<t.targetLinks.length;o++){var a=t.targetLinks[o];if(a.source===e)break;n-=a.width}return n};var qQ=function(e){return new jQ(e).calculate()};function GQ(e,t,n,i,r,o){var a=(o-t)*(n-e),s=(i-t)*(r-e);return a>s?1:a===s?0:-1}var KQ=function(e){function t(t){e.call(this),this.options=BF({},this.options,t),this.createVisual()}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.createVisual=function(){this.visual=this.createElement()},t.prototype.exportVisual=function(){return this.visual},t.prototype.createElement=function(){var e=this,t=this.options.visual;return t?t({sender:this.getSender(),options:this.visualOptions(),createVisual:function(){return e.getElement()}}):this.getElement()},t.prototype.getSender=function(){return this},t}(fr),YQ=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getElement=function(){return us.fromRect(this.getRect(),this.visualOptions())},t.prototype.getRect=function(){var e=this.options.node;return new Yo([e.x0,e.y0],[e.x1-e.x0,e.y1-e.y0])},t.prototype.getLabelText=function(e){var t=e.labels.ariaTemplate;if(t)return t({node:e.node})},t.prototype.visualOptions=function(){var e=BF({},this.options,this.options.node),t=this.getLabelText(e);return{fill:{color:e.color,opacity:e.opacity},stroke:{width:0},className:"k-sankey-node",role:"graphics-symbol",ariaRoleDescription:"Node",ariaLabel:t}},t.prototype.createFocusHighlight=function(){if(this.options.navigatable)return this._highlight=us.fromRect(this.getRect(),{stroke:this.options.focusHighlight,visible:!1}),this._highlight},t.prototype.focus=function(e){if(this._highlight){var t=(e||{}).highlight;void 0===t&&(t=!0),t&&this._highlight.options.set("visible",!0);var n=this.options.node.id;this.visual.options.set("id",n),this.options.root()&&this.options.root().setAttribute(PH,n)}},t.prototype.blur=function(){this._highlight&&(this._highlight.options.set("visible",!1),this.visual.options.set("id",""),this.options.root()&&this.options.root().removeAttribute(PH))},t}(KQ),QQ=function(e,t,n){return e.color||t[n%t.length]},XQ=function(e,t,n,i){var r=BF({},t,t.node);return BF({},{color:QQ(e,n,i)},r,{node:e},{visual:e.visual,opacity:e.opacity,offset:e.offset,color:e.color})},ZQ=function(e,t){var n,i,r,o,a,s,l,c,d=e.x0,u=e.x1,h=e.y0,p=e.y1,f=(d+u)/2,m=e.width,g=m/2,v=[[(d+f)/2,h-g],[(u+f)/2,p-g]],_=function(e,t){var n=e[0],i=n[0],r=n[1],o=e[1],a=o[0],s=o[1],l=t[0],c=t[1];return Math.abs((a-i)*(c-r)-(l-i)*(s-r))/Math.sqrt(Math.pow(a-i,2)+Math.pow(s-r,2))}(v,[f,(n=h+g,i=h+g,r=p+g,o=p+g,a=.5,s=1-a,l=s*s,c=a*a,n*l*s+3*i*a*l+3*r*c*s+o*c*a)]),b=(m-_)/2,y=function(e,t){var n=e[0],i=n[0],r=n[1],o=e[1],a=o[0],s=o[1],l=t[0],c=l[0],d=l[1],u=t[1],h=u[0],p=u[1],f=Math.atan2(s-r,a-i),m=Math.atan2(p-d,h-c);return Math.abs(f-m)}(v,[[d,h-g],[f,h-g]]),w=b,k=Math.sin(y)*w,x=h-p>0?-1:1;return t&&(x=-x),x*Math.sqrt(w*w+k*k)},JQ=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getElement=function(){var e=this.options.link,t=e.x0,n=e.x1,i=e.y0,r=e.y1,o=(t+n)/2;return new us(this.visualOptions()).moveTo(t,i).curveTo([o,i],[o,r],[n,r])},t.prototype.getLabelText=function(e){var t=e.labels.ariaTemplate;if(t)return t({link:e.link})},t.prototype.visualOptions=function(){var e=this.options,t=this.options.link,n=this.getLabelText(e);return{stroke:{width:e.link.width,color:t.color||e.color,opacity:hR(t.opacity)?t.opacity:e.opacity},role:"graphics-symbol",ariaRoleDescription:"Link",ariaLabel:n}},t.prototype.createFocusHighlight=function(){if(this.options.navigatable){var e=this.options,t=e.link,n=e.rtl,i=t.x0,r=t.x1,o=t.y0,a=t.y1,s=(i+r)/2,l=t.width/2,c=ZQ(t,n);this._highlight=new us({stroke:this.options.focusHighlight,visible:!1}).moveTo(i,o+l).lineTo(i,o-l).curveTo([s+c,o-l],[s+c,a-l],[r,a-l]).lineTo(r,a+l).curveTo([s-c,a+l],[s-c,o+l],[i,o+l])}},t.prototype.focus=function(e){if(this._highlight){var t=(e||{}).highlight;void 0===t&&(t=!0),t&&this._highlight.options.set("visible",!0);var n=this.options.link.sourceId+"->"+this.options.link.targetId;this.visual.options.set("id",n),this.options.root()&&this.options.root().setAttribute(PH,n)}},t.prototype.blur=function(){this._highlight&&(this._highlight.options.set("visible",!1),this.visual.options.set("id",""),this.options.root()&&this.options.root().removeAttribute(PH))},t}(KQ),eX="inside",tX="before",nX="after",iX=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getElement=function(){var e=BF({},this.options,this.options.node.label),t=e.node,n=e.diagramMinX,i=e.diagramMaxX,r=e.text,o=e.offset,a=e.rtl,s=e.position;if(a&&s!==eX&&(s=s===tX?nX:tX),!e.visible||!r)return null;var l=new VL(t.x0,t.y0,t.x1,t.y1),c=this.visualOptions();a&&!c.align&&(c.align="right");var d=new sB(r,c);d.reflow(new VL);var u=d.box,h=l.center().y-u.height()/2,p=t.x1+u.width()>i,f=t.x0-u.width()<n,m=s===tX||s===eX&&p?tX:nX;a&&(m=s===nX||s===eX&&f?nX:tX);var g=[m===tX?t.x0-u.width():t.x1,h],v=new VL(g[0],g[1],g[0]+u.width(),g[1]+u.height());return v.translate(o.left||0,o.top||0),d.reflow(v),d.renderVisual(),d.visual},t.prototype.visualOptions=function(){var e=BF({},this.options,this.options.node.label);return{color:e.color,font:e.font,border:e.border,margin:e.margin,padding:e.padding,align:e.align,paintOrder:e.paintOrder,stroke:e.stroke}},t}(KQ);DR(iX,{position:eX});var rX=function(e,t,n,i,r){return BF({},t,{node:e,diagramMinX:i,diagramMaxX:r,rtl:n,visual:e.label.visual,visible:e.label.visible,margin:e.label.margin,padding:e.label.padding,border:e.label.border,align:e.label.align,offset:e.label.offset})},oX=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getElement=function(){var e=this.options,t=e.drawingRect,n=e.text;if(!1===e.visible||!n)return null;var i=lB.buildTitle(n,e);return i.reflow(t),i.renderVisual(),i.visual},t.prototype.createElement=function(){return this.getElement()},t}(KQ);DR(oX,{align:LH,border:{width:0},margin:WF(5),padding:WF(5)});var aX=function(e,t){return e.node.x0-t.node.x0!=0?e.node.x0-t.node.x0:e.node.y0-t.node.y0},sX=function(e,t){return e.node.x1-t.node.x1!=0?e.node.x1-t.node.x1:t.node.y0-e.node.y0},lX=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.getElement=function(){var e=this.options,t=e.drawingRect,n=e.rtl,i=e.nodes;void 0===i&&(i=[]);var r=e.item,o=e.position;if(!1===e.visible||!i.length)return null;var a=i.map((function(e){return{text:e.label&&e.label.text||"",area:{background:void 0!==r.areaBackground?r.areaBackground:e.color,opacity:void 0!==r.areaOpacity?r.areaOpacity:e.opacity},node:e}}));a.sort(function(e){return e?sX:aX}(n));var s=n&&o!==XH&&o!==aF,l=new ZU(Object.assign({},e,{data:a,reverse:s}),{rtl:n});return l.reflow(t),l.renderVisual(),l.visual},t.prototype.createElement=function(){return this.getElement()},t}(KQ);DR(lX,{markers:{visible:!1},item:{type:fV,cursor:bF,opacity:1},position:RH,align:LH,accessibility:{role:"presentation",ariaLabel:null,ariaRoleDescription:null},border:{width:0}});var cX="link",dX="node",uX=function(e){function t(t,n,i){e.call(this),this._initTheme(i),this._setOptions(n),this._initElement(t),this._initSurface(),n&&n.data&&(this._redraw(),this._initResizeObserver(),this._initNavigation(t))}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.destroy=function(){this.unbind(),this._destroySurface(),this._destroyResizeObserver(),this.element&&(this.element.removeEventListener("keydown",this._keydownHandler),this.element.removeEventListener("focus",this._focusHandler),this.element.removeEventListener("mousedown",this._onDownHandler),this.element.removeEventListener("touchstart",this._onDownHandler),this.element.removeEventListener("pointerdown",this._onDownHandler)),this._focusState=null,this.element=null},t.prototype._initElement=function(e){this.element=e,CF(e,["k-chart","k-sankey"]),e.setAttribute("role","graphics-document");var t=this.options.title;t.text&&e.setAttribute("aria-label",t.text),t.description&&e.setAttribute("aria-roledescription",t.description)},t.prototype._initSurface=function(){this.surface||(this._destroySurface(),this._initSurfaceElement(),this.surface=this._createSurface())},t.prototype._initNavigation=function(e){e.tabIndex=e.getAttribute("tabindex")||0,this.options.disableKeyboardNavigation||(this._keydownHandler=this._keydown.bind(this),this._focusHandler=this._focus.bind(this),this._blurHandler=this._blur.bind(this),this._onDownHandler=this._onDown.bind(this),e.addEventListener("keydown",this._keydownHandler),e.addEventListener("focus",this._focusHandler),e.addEventListener("blur",this._blurHandler),e.addEventListener("mousedown",this._onDownHandler),e.addEventListener("touchstart",this._onDownHandler),e.addEventListener("pointerdown",this._onDownHandler),this._focusState={node:this.firstFocusableNode(),link:null})},t.prototype.firstFocusableNode=function(){return this.columns[0][0]},t.prototype._initResizeObserver=function(){var e=this,t=new ResizeObserver((function(t){t.forEach((function(t){var n=t.contentRect,i=n.width,r=n.height;t.target!==e.element||e.size&&e.size.width===i&&e.size.height===r||(e.size={width:i,height:r},e.surface.setSize(e.size),e.resize=!0,e._redraw())}))}));this._resizeObserver=t,t.observe(this.element)},t.prototype._createSurface=function(){return vc.create(this.surfaceElement,{mouseenter:this._mouseenter.bind(this),mouseleave:this._mouseleave.bind(this),mousemove:this._mousemove.bind(this),click:this._click.bind(this)})},t.prototype._initTheme=function(e){var t=e||this.theme||{};this.theme=t,this.options=BF({},t,this.options)},t.prototype.setLinksOpacity=function(e){var t=this;this.linksVisuals.forEach((function(n){t.setOpacity(n,e,n.linkOptions.opacity)}))},t.prototype.setLinksInactivityOpacity=function(e){var t=this;this.linksVisuals.forEach((function(n){t.setOpacity(n,e,n.linkOptions.highlight.inactiveOpacity)}))},t.prototype.setOpacity=function(e,t,n){e.options.set("stroke",Object.assign({},e.options.stroke,{opacity:hR(n)?n:t}))},t.prototype.trigger=function(t,n){var i=n.element.dataItem,r=n.element.type,o=Object.assign({},n,{type:t,targetType:r,dataItem:i});return e.prototype.trigger.call(this,t,o)},t.prototype._mouseenter=function(e){var t=e.element,n=t.type===cX,i=t.type===dX,r=Boolean(t.chartElement&&t.chartElement.options.node);if(!(n&&this.trigger("linkEnter",e)||i&&this.trigger("nodeEnter",e))){var o=this.options.links.highlight;if(n)this.setLinksInactivityOpacity(o.inactiveOpacity),this.setOpacity(t,o.opacity,t.linkOptions.highlight.opacity);else if(i)this.highlightLinks(t,o);else if(r){var a=this.nodesVisuals.get(t.chartElement.options.node.id);this.highlightLinks(a,o)}}},t.prototype._mouseleave=function(e){var t=this,n=e.element,i=n.type===cX,r=n.type===dX,o=Boolean(n.chartElement&&n.chartElement.options.node),a=e.originalEvent.relatedTarget;i&&a&&"text"===a.nodeName||((i||r)&&(this.tooltipTimeOut&&(clearTimeout(this.tooltipTimeOut),this.tooltipTimeOut=null),this.tooltipShown=!1,this.trigger("tooltipHide",e)),i&&this.trigger("linkLeave",e)||r&&this.trigger("nodeLeave",e)||(i||r||o)&&this.linksVisuals.forEach((function(e){t.setOpacity(e,t.options.links.opacity,e.linkOptions.opacity)})))},t.prototype._mousemove=function(e){var t=this,n=this.options.tooltip,i=n.followPointer,r=n.delay,o=e.element,a=o.type;if(!(a!==cX&&a!==dX||this.tooltipShown&&!i)){var s=e.originalEvent,l=this.element.getBoundingClientRect(),c=s.clientX-l.left<l.width/2,d=s.clientY-l.top<l.height/2;if(e.tooltipData={popupOffset:{left:s.pageX,top:s.pageY},popupAlign:{horizontal:c?"left":"right",vertical:d?"top":"bottom"}},a===dX){var u=o.dataItem,h=u.sourceLinks,p=u.targetLinks,f=p.length?p:h;e.nodeValue=f.reduce((function(e,t){return e+t.value}),0)}this.tooltipTimeOut&&(clearTimeout(this.tooltipTimeOut),this.tooltipTimeOut=null);var m=i&&this.tooltipShown?0:r;this.tooltipTimeOut=setTimeout((function(){t.trigger("tooltipShow",e),t.tooltipShown=!0,t.tooltipTimeOut=null}),m)}},t.prototype._click=function(e){var t=e.element,n=t.dataItem,i=t.type===cX,r=t.type===dX,o=this._focusState||{};if(r)!o.link&&this.sameNode(o.node,n)||(this._focusState={node:n,link:null},this._focusNode({highlight:!1})),this.trigger("nodeClick",e);else if(i){var a={sourceId:n.source.id,targetId:n.target.id,value:n.value};this.sameLink(o.link,a)||(this._focusState={node:n.source,link:a},this._focusLink({highlight:!1})),this.trigger("linkClick",e)}},t.prototype.sameNode=function(e,t){return e&&t&&e.id===t.id},t.prototype.sameLink=function(e,t){return e&&t&&e.sourceId===t.sourceId&&e.targetId===t.targetId},t.prototype._focusNode=function(e){this._cleanFocusHighlight();var t=this._focusState.node;this.models.map.get(t.id).focus(e)},t.prototype._focusLink=function(e){this._cleanFocusHighlight();var t=this._focusState.link;this.models.map.get(t.sourceId+"-"+t.targetId).focus(e)},t.prototype._focusNextNode=function(e){void 0===e&&(e=1);var t=this._focusState.node,n=this.columns.findIndex((function(e){return e.find((function(e){return e.id===t.id}))})),i=this.columns[n],r=i.findIndex((function(e){return e.id===t.id})),o=i[r+e];o&&(this._focusState.node=o,this._focusNode())},t.prototype._focusNextLink=function(e){void 0===e&&(e=1);var t=this._focusState.node,n=this._focusState.link,i=t.sourceLinks.findIndex((function(e){return e.sourceId===n.sourceId&&e.targetId===n.targetId})),r=t.targetLinks.findIndex((function(e){return e.sourceId===n.sourceId&&e.targetId===n.targetId}));if(-1!==i){var o=t.sourceLinks[i+e];o&&(this._focusState.link=o,this._focusLink())}else if(-1!==r){var a=t.targetLinks[r+e];a&&(this._focusState.link=a,this._focusLink())}},t.prototype._focusSourceNode=function(){var e=this._focusState.link,t=this.models.map.get(e.sourceId);this._focusState={node:t.options.node,link:null},this._focusNode()},t.prototype._focusTargetNode=function(){var e=this._focusState.link,t=this.models.map.get(e.targetId);this._focusState={node:t.options.node,link:null},this._focusNode()},t.prototype._focusSourceLink=function(){var e=this._focusState.node.sourceLinks[0];e&&(this._focusState.link=e,this._focusLink())},t.prototype._focusTargetLink=function(){var e=this._focusState.node.targetLinks[0];e&&(this._focusState.link=e,this._focusLink())},t.prototype._focus=function(){this._skipFocusHighlight||(this._focusState.link?this._focusLink():this._focusNode()),this._skipFocusHighlight=!1},t.prototype._blur=function(){this._cleanFocusHighlight()},t.prototype._onDown=function(){this._hasFocus()||(this._skipFocusHighlight=!0)},t.prototype._hasFocus=function(){return this.element.ownerDocument.activeElement===this.element},t.prototype._cleanFocusHighlight=function(){this.models.nodes.forEach((function(e){return e.blur()})),this.models.links.forEach((function(e){return e.blur()}))},t.prototype._keydown=function(e){var t=this["on"+e.key],n=this.options.rtl;n&&"ArrowLeft"===e.key?t=this.onArrowRight:n&&"ArrowRight"===e.key&&(t=this.onArrowLeft),t&&t.call(this,e)},t.prototype.onEscape=function(e){e.preventDefault(),this._focusState={node:this.firstFocusableNode(),link:null},this._focusNode()},t.prototype.onArrowDown=function(e){e.preventDefault(),this._focusState.link?this._focusNextLink(1):this._focusNextNode(1)},t.prototype.onArrowUp=function(e){e.preventDefault(),this._focusState.link?this._focusNextLink(-1):this._focusNextNode(-1)},t.prototype.onArrowLeft=function(e){e.preventDefault(),this._focusState.link?this._focusSourceNode():this._focusTargetLink()},t.prototype.onArrowRight=function(e){e.preventDefault(),this._focusState.link?this._focusTargetNode():this._focusSourceLink()},t.prototype.highlightLinks=function(e,t){var n=this;e&&(this.setLinksInactivityOpacity(t.inactiveOpacity),e.links.forEach((function(e){n.setOpacity(e,t.opacity,e.linkOptions.highlight.opacity)})))},t.prototype._destroySurface=function(){this.surface&&(this.surface.destroy(),this.surface=null,this._destroySurfaceElement())},t.prototype._destroyResizeObserver=function(){this._resizeObserver&&(this._resizeObserver.disconnect(),this._resizeObserver=null)},t.prototype._initSurfaceElement=function(){this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.element.appendChild(this.surfaceElement))},t.prototype._destroySurfaceElement=function(){this.surfaceElement&&this.surfaceElement.parentNode&&(this.surfaceElement.parentNode.removeChild(this.surfaceElement),this.surfaceElement=null)},t.prototype.setOptions=function(e,t){this._setOptions(e),this._initTheme(t),this._initSurface(),this._redraw()},t.prototype._redraw=function(){this.surface.clear();var e=this._getSize(),t=e.width,n=e.height;this.size={width:t,height:n},this.surface.setSize(this.size),this.createVisual(),this.surface.draw(this.visual)},t.prototype._getSize=function(){return this.element.getBoundingClientRect()},t.prototype.createVisual=function(){this.visual=this._render()},t.prototype.titleBox=function(e,t){return e&&!1!==e.visible&&e.text?new oX(Object.assign({},{drawingRect:t},e)).exportVisual().chartElement.box:null},t.prototype.legendBox=function(e,t,n){return e&&!1!==e.visible?new lX(Object.assign({},{nodes:t},e,{drawingRect:n})).exportVisual().chartElement.box:null},t.prototype.calculateSankey=function(e,t){var n=t.title,i=t.legend,r=t.data,o=t.nodes,a=t.labels,s=t.nodeColors,l=t.disableAutoLayout,c=t.disableKeyboardNavigation,d=t.rtl,u=!l,h=c?0:hX.width/2,p=new VL(0,0,e.width,e.height);p.unpad(h);var f=this.titleBox(n,p),m=p.clone();if(f){var g=f.height();n.position===dF?(p.unpad({top:g}),m=new VL(0,g,e.width,e.height)):(p.shrink(0,g),m=new VL(0,0,e.width,e.height-g))}var v=this.legendBox(i,r.nodes,m),_=i&&i.position||lX.prototype.options.position;v&&(_===XH&&p.unpad({left:v.width()}),_===aF&&p.shrink(v.width(),0),_===dF&&p.unpad({top:v.height()}),_===RH&&p.shrink(0,v.height()));var b=qQ(Object.assign({},e,{offsetX:0,offsetY:0,width:p.width(),height:p.height()})),y=b.nodes,w=b.circularLinks;if(w)return console.warn("Circular links detected. Kendo Sankey diagram does not support circular links."),{sankey:{nodes:[],links:[],columns:[[]],circularLinks:w},legendBox:v,titleBox:f};var k=new VL,x=y.reduce((function(e,t){return Math.min(e,t.x0)}),1/0),C=y.reduce((function(e,t){return Math.max(e,t.x1)}),0);y.forEach((function(e,t){if(d){var n=e.x0,i=e.x1;e.x0=C-i,e.x1=C-n}var r=XQ(e,o,s,t),l=new YQ(r);k.wrap(oB(l.exportVisual().rawBBox()));var c=new iX(rX(e,a,d,x,C)).exportVisual();c&&k.wrap(oB(c.rawBBox()))}));var S=p.x1,T=p.y1,D=p.width()+S,A=p.height()+T;if(D-=k.x2>p.width()?k.x2-p.width():0,A-=k.y2>p.height()?k.y2-p.height():0,S+=k.x1<0?-k.x1:0,T+=k.y1<0?-k.y1:0,!1===u)return{sankey:qQ(Object.assign({},e,{offsetX:S,offsetY:T,width:D,height:A,autoLayout:!1})),legendBox:v,titleBox:f};if(this.resize&&u&&this.permutation)return this.resize=!1,{sankey:qQ(Object.assign({},e,{offsetX:S,offsetY:T,width:D,height:A},this.permutation)),legendBox:v,titleBox:f};for(var M=qQ(Object.assign({},e,{offsetX:S,offsetY:T,width:D,height:A,autoLayout:!1})).columns.length,E=[],I=function(t,n){var i=function(e){for(var t,n,i,r,o,a,s=0,l=e.length,c=0;c<l;c++)for(var d=e[c],u=c+1;u<l;u++){var h=e[u];n=h,i=void 0,r=void 0,o=void 0,a=void 0,i=GQ((t=d).x0,t.y0,t.x1,t.y1,n.x1,n.y1),r=GQ(t.x0,t.y0,t.x1,t.y1,n.x0,n.y0),o=GQ(t.x0,t.y0,n.x0,n.y0,n.x1,n.y1),a=GQ(t.x1,t.y1,n.x0,n.y0,n.x1,n.y1),i!==r&&o!==a&&(s+=Math.min(d.value,h.value))}return s}(qQ(Object.assign({},e,{offsetX:S,offsetY:T,width:D,height:A,loops:2,targetColumnIndex:t,reverse:n})).links);return E.push({crosses:i,reverse:n,targetColumnIndex:t}),0===i},z=1;z<=M-1&&(!I(z,!1)&&!I(z,!0));z++);var P=Math.min.apply(null,E.map((function(e){return e.crosses}))),H=E.find((function(e){return e.crosses===P}));return this.permutation={targetColumnIndex:H.targetColumnIndex,reverse:H.reverse},{sankey:qQ(Object.assign({},e,{offsetX:S,offsetY:T,width:D,height:A},this.permutation)),legendBox:v,titleBox:f}},t.prototype._render=function(e,t){var n=e||this.options,i=t||this,r=n.labels,o=n.nodes,a=n.links,s=n.nodeColors,l=n.title,c=n.legend,d=n.rtl,u=n.disableKeyboardNavigation,h=n.data,p=i.size,f=p.width,m=p.height,g=Object.assign({},h,{width:f,height:m,nodesOptions:o,title:l,legend:c}),v=this.calculateSankey(g,n),_=v.sankey,b=v.titleBox,y=v.legendBox;d&&function(e){var t=e.nodes,n=e.links,i=Math.min.apply(Math,t.map((function(e){return e.x0}))),r=Math.max.apply(Math,t.map((function(e){return e.x1})))-i;t.forEach((function(e){var t=r-(e.x1-2*i),n=r-(e.x0-2*i);e.x0=t,e.x1=n})),n.forEach((function(e){var t=r-(e.x1-2*i),n=r-(e.x0-2*i);e.x1=t,e.x0=n}))}(_);var w=_.nodes,k=_.links,x=_.columns;i.columns=x.map((function(e){var t=e.slice();return t.sort((function(e,t){return e.y0-t.y0})),t}));var C=new vs({clip:us.fromRect(new Yo([0,0],[f,m]))});if(b){var S=new oX(Object.assign({},l,{drawingRect:b})).exportVisual();C.append(S)}if(_.circularLinks)return C;var T=new Map;i.nodesVisuals=T;var D={nodes:[],links:[],map:new Map};i.models=D;var A=[];w.forEach((function(e,t){var n=XQ(e,o,s,t);n.root=function(){return i.element},n.navigatable=!0!==u;var r=new YQ(n),a=r.exportVisual();a.links=[],a.type=dX,e.color=n.color,e.opacity=n.opacity,a.dataItem=Object.assign({},h.nodes[t],{color:n.color,opacity:n.opacity,sourceLinks:e.sourceLinks.map((function(e){return{sourceId:e.sourceId,targetId:e.targetId,value:e.value}})),targetLinks:e.targetLinks.map((function(e){return{sourceId:e.sourceId,targetId:e.targetId,value:e.value}}))}),T.set(e.id,a),D.nodes.push(r),D.map.set(e.id,r),C.append(a),r.createFocusHighlight(),r._highlight&&A.push(r._highlight)}));var M=k.slice().sort((function(e,t){return t.value-e.value})),E=[];i.linksVisuals=E,M.forEach((function(e){var t=e.source,n=e.target,r=T.get(t.id),o=T.get(n.id),s=function(e,t,n,i){var r=BF({},t,{link:e,opacity:e.opacity,color:e.color,colorType:e.colorType,visual:e.visual,highlight:e.highlight});return"source"===r.colorType?r.color=n.options.fill.color:"target"===r.colorType&&(r.color=i.options.fill.color),r}(e,a,r,o);s.root=function(){return i.element},s.navigatable=!0!==u,s.rtl=d;var l=new JQ(s),c=l.exportVisual();c.type=cX,c.dataItem={source:Object.assign({},r.dataItem),target:Object.assign({},o.dataItem),value:e.value},c.linkOptions=s,E.push(c),r.links.push(c),o.links.push(c),D.links.push(l),D.map.set(t.id+"-"+n.id,l),l.createFocusHighlight(),l._highlight&&A.push(l._highlight),C.append(c)}));var I=w.reduce((function(e,t){return Math.min(e,t.x0)}),1/0),z=w.reduce((function(e,t){return Math.max(e,t.x1)}),0);if(w.forEach((function(e){var t=rX(e,r,d,I,z),n=new iX(t).exportVisual();n&&C.append(n)})),y){var P=new lX(Object.assign({},c,{rtl:d,drawingRect:y,nodes:w})).exportVisual();C.append(P)}if(0!==A.length){var H=new vs;H.append.apply(H,A),C.append(H)}return C},t.prototype.exportVisual=function(e){var t=e&&e.options?BF({},this.options,e.options):this.options,n={size:{width:hR(e&&e.width)?e.width:this.size.width,height:hR(e&&e.height)?e.height:this.size.height}};return this._render(t,n)},t.prototype._setOptions=function(e){this.options=BF({},this.options,e)},t}(fL),hX={opacity:1,width:2,color:FH};DR(uX,{title:{position:dF},labels:{visible:!0,margin:{left:8,right:8},padding:0,border:{width:0},paintOrder:"stroke",stroke:{lineJoin:"round",width:1},offset:{left:0,top:0}},nodes:{width:24,padding:16,opacity:1,align:"stretch",offset:{left:0,top:0},focusHighlight:Object.assign({},hX),labels:{ariaTemplate:function(e){return e.node.label.text}}},links:{colorType:"static",opacity:.4,highlight:{opacity:.8,inactiveOpacity:.2},focusHighlight:Object.assign({},hX),labels:{ariaTemplate:function(e){var t=e.link;return t.source.label.text+" to "+t.target.label.text}}},tooltip:{followPointer:!1,delay:200}});var pX=function(e,t,n){var i=new Set,r=new Map,o=new Map;e.forEach((function(e){t.forEach((function(t){i.add(t.value(e))}));for(var a=0;a<t.length-1;a++){var s=t[a].value(e),l=t[a+1].value(e),c=s+"_"+l,d=n.value(e),u=r.get(c);void 0!==u?r.set(c,u+d):(r.set(c,d),o.set(c,{source:s,target:l}))}}));var a=new Map,s=Array.from(i).map((function(e,t){return a.set(e,t),{id:t,label:{text:String(e)}}})),l=Array.from(r).map((function(e){var t=e[0],n=e[1],i=o.get(t),r=i.source,s=i.target;return{sourceId:a.get(r),targetId:a.get(s),value:n}}));return{nodes:s,links:l}};var fX=Object.freeze({seriesType:0,stacked:1,categoryAxisX:2,valueAxisY:3,seriesChange:4,areaMarginLeft:5,areaMarginRight:6,areaMarginTop:7,areaMarginBottom:8,areaBackground:9,titleText:10,titleFontName:11,titleFontSize:12,titleColor:13,subtitleText:14,subtitleFontName:15,subtitleFontSize:16,subtitleColor:17,seriesColor:18,seriesLabel:19,legendVisible:20,legendFontName:21,legendFontSize:22,legendColor:23,legendPosition:24,categoryAxisTitleText:25,categoryAxisTitleFontName:26,categoryAxisTitleFontSize:27,categoryAxisTitleColor:28,categoryAxisLabelsFontName:29,categoryAxisLabelsFontSize:30,categoryAxisLabelsColor:31,categoryAxisLabelsRotation:32,categoryAxisReverseOrder:33,valueAxisTitleText:34,valueAxisTitleFontName:35,valueAxisTitleFontSize:36,valueAxisTitleColor:37,valueAxisLabelsFormat:38,valueAxisLabelsFontName:39,valueAxisLabelsFontSize:40,valueAxisLabelsColor:41,valueAxisLabelsRotation:42}),mX="12px",gX="16px",vX=[{text:"Arial",value:"Arial, Helvetica, sans-serif",style:{fontFamily:"Arial, Helvetica, sans-serif"}},{text:"Courier New",value:"'Courier New', Courier, monospace",style:{fontFamily:"'Courier New', Courier, monospace"}},{text:"Georgia",value:"Georgia, serif",style:{fontFamily:"Georgia, serif"}},{text:"Impact",value:"Impact, Charcoal, sans-serif",style:{fontFamily:"Impact, Charcoal, sans-serif"}},{text:"Lucida Console",value:"'Lucida Console', Monaco, monospace",style:{fontFamily:"'Lucida Console', Monaco, monospace"}},{text:"Tahoma",value:"Tahoma, Geneva, sans-serif",style:{fontFamily:"Tahoma, Geneva, sans-serif"}},{text:"Times New Roman",value:"'Times New Roman', Times,serif",style:{fontFamily:"'Times New Roman', Times,serif"}},{text:"Trebuchet MS",value:"'Trebuchet MS', Helvetica, sans-serif",style:{fontFamily:"'Trebuchet MS', Helvetica, sans-serif"}},{text:"Verdana",value:"Verdana, Geneva, sans-serif",style:{fontFamily:"Verdana, Geneva, sans-serif"}}],_X=vX[0].value,bX="line",yX="scatter",wX=["column","bar",bX,yX],kX={type:bX,width:0};function xX(e){return e&&wX.includes(e)}var CX=["string","date","number"],SX=["number"],TX={bar:[{axisType:"category",types:CX},{axisType:"value",types:SX}],column:[{axisType:"category",types:CX},{axisType:"value",types:SX}],line:[{axisType:"category",types:CX},{axisType:"value",types:SX}],pie:[{axisType:"category",types:CX},{axisType:"value",types:SX,count:1}],scatter:[{axisType:"category",types:CX},{axisType:"value",types:SX}]};function DX(e,t){return((t||"")+" "+(e||"")).trim()}function AX(e){var t=(e||"").indexOf(" ");return{size:e&&e.substring(0,t),name:e&&e.substring(t+1)}}var MX=function(e,t,n){var i=AX(n).size;return e?DX(e,i||t):""},EX=function(e,t,n){var i=AX(n).name;return e?DX(i||t,e):""},IX=function(e){return null!=e},zX=function(e){var t=structuredClone(e[0]);return t.forEach((function(t,n){if(!IX(t.value))for(var i=0;i<e.length;i++){var r=e[i][n].value;if(IX(r)){t.value=r;break}}})),t},PX=function(e,t){var n=[],i=zX(e);t.types.forEach((function(e){i.forEach((function(t,i){typeof t.value===e&&n.push(i)}))}));var r=n.findIndex((function(t){var n=e.map((function(e){return e[t].value}));return new Set(n).size===n.length}));return Math.max(r,0)},HX=function(e,t){var n=[],i=zX(e);return t.forEach((function(e){e.types.forEach((function(e){i.forEach((function(t,i){typeof t.value===e&&n.push(i)}))}))})),n},FX=function(){return structuredClone({columns:[],data:[],series:[],initialSeries:[],categoryAxis:[{categories:[],labels:{visible:!0,rotation:"auto"},title:{text:""}}],valueAxis:[{labels:{visible:!0,rotation:"auto"}}],area:{margin:{left:void 0,right:void 0,top:void 0,bottom:void 0}},title:{text:""},subtitle:{text:""},stack:!1})},RX=function(e,t,n){var i=FX();i.seriesType=t,i.data=e||[],i.legend={visible:!0,position:"bottom"};var r=TX[t];if(!r||!e.length)return i;var o=e[0].slice();i.columns=e[0].map((function(e){return String(e.field)}));var a=r.find((function(e){return"category"===e.axisType})),s=-1;a&&(s=n&&n.categoryAxis?i.columns.indexOf(n.categoryAxis):PX(e,a));var l=r.filter((function(e){return"value"===e.axisType})),c=HX(e,l);c.includes(s)&&(c.length>1?c=c.filter((function(e){return e!==s})):s=-1);var d=[];c.forEach((function(n){var i=o[n],r=[];e.forEach((function(e){r.push(e[n].value)})),d.push(Object.assign({},{name:i.field,type:t,data:r,stack:!1,labels:{visible:!1}},t===yX?kX:{}))}));var u=s>-1?e.map((function(e){return String(IX(e[s].value)?e[s].value:" ")})):[];return d.length&&(i.series=d.map((function(e,t){return Object.assign({},e,{id:t})})),i.initialSeries=structuredClone(i.series)),i.categoryAxis=[{categories:u,labels:{visible:!0,rotation:"auto"}}],i.categoryField=i.columns[s],i},LX=function(e,t,n){var i=FX();i.seriesType=t,i.data=e||[];var r=TX[t];if(!r||!e.length)return i;var o=e[0].map((function(e){return e.field})),a=r.find((function(e){return"category"===e.axisType})),s=-1;a&&(s=n&&n.categoryAxis?o.indexOf(n.categoryAxis):PX(e,a));var l=r.filter((function(e){return"value"===e.axisType})),c=[];(c=n&&n.valueAxis?[o.indexOf(n.valueAxis)]:HX(e,l)).includes(s)&&c.length>1&&(c=c.filter((function(e){return e!==s}))),"number"==typeof l[0].count&&(c=c.slice(0,l[0].count));var d=s>-1?e.map((function(e){return String(e[s].value)})):[],u=[];return e.forEach((function(e){var t={};c.forEach((function(n){var i=e[n];t[i.field]=i.value||0,t[e[s].field]=e[s].value||" "})),u.push(t)})),i.columns=o,i.categoryAxis=[{categories:d,title:{text:""}}],i.series=[{id:0,data:u,type:t,name:o[s],labels:{visible:!0},categoryField:o[s],field:o[c[0]]}],i.categoryField=o[s],i.valueField=o[c[0]],i.initialSeries=structuredClone(i.series),i};function BX(e,t){return(xX(t)?RX:LX)(e,t)}function OX(e,t){var n=structuredClone(t);if(n.legend=e.legend,n.area=e.area,n.title=e.title,n.subtitle=e.subtitle,n.series.length===e.series.length)for(var i=0;i<n.series.length;i++)n.series[i].color=e.series[i].color,n.series[i].labels=e.series[i].labels;return e.series.every((function(e){return e.labels&&e.labels.visible}))&&xX(n.seriesType)&&xX(e.seriesType)&&n.series.forEach((function(e){e.labels=e.labels||{},e.labels.visible=!0})),n}function VX(e,t,n){var i=Object.assign({},e);switch(t){case fX.seriesType:return BX(i.data,n);case fX.stacked:return i.series=i.series.map((function(e){return Object.assign({},e,{stack:n})})),i.stack=n,i;case fX.categoryAxisX:return i.seriesType&&xX(i.seriesType)?OX(i,RX(i.data,i.seriesType,{categoryAxis:n})):"pie"===i.seriesType?OX(i,LX(i.data,i.seriesType,{categoryAxis:n})):i;case fX.valueAxisY:return"pie"===i.seriesType?OX(i,LX(i.data,i.seriesType,{categoryAxis:i.categoryField,valueAxis:n})):i;case fX.seriesChange:return i.series=n,i;case fX.areaMarginLeft:return i.area=Object.assign({},i.area,{margin:Object.assign({},i.area&&i.area.margin||{},{left:n})}),i;case fX.areaMarginRight:return i.area=Object.assign({},i.area,{margin:Object.assign({},i.area&&i.area.margin||{},{right:n})}),i;case fX.areaMarginTop:return i.area=Object.assign({},i.area,{margin:Object.assign({},i.area&&i.area.margin||{},{top:n})}),i;case fX.areaMarginBottom:return i.area=Object.assign({},i.area,{margin:Object.assign({},i.area&&i.area.margin||{},{bottom:n})}),i;case fX.areaBackground:return i.area=Object.assign({},i.area,{background:n}),i;case fX.titleText:return i.title=Object.assign({},i.title,{text:n}),i;case fX.titleFontName:return i.title=Object.assign({},i.title,{font:MX(n,"20px",i.title&&i.title.font)}),i;case fX.titleFontSize:return i.title=Object.assign({},i.title,{font:EX(n,_X,i.title&&i.title.font)}),i;case fX.titleColor:return i.title=Object.assign({},i.title,{color:n}),i;case fX.subtitleText:return i.subtitle=Object.assign({},i.subtitle,{text:n}),i;case fX.subtitleFontName:return i.subtitle=Object.assign({},i.subtitle,{font:MX(n,"16px",i.subtitle&&i.subtitle.font)}),i;case fX.subtitleFontSize:return i.subtitle=Object.assign({},i.subtitle,{font:EX(n,_X,i.subtitle&&i.subtitle.font)}),i;case fX.subtitleColor:return i.subtitle=Object.assign({},i.subtitle,{color:n}),i;case fX.seriesColor:return i.series=i.series.map((function(e){return Object.assign({},e,{color:n.seriesName===e.name?n.color:e.color})})),i;case fX.seriesLabel:return i.series=i.series.map((function(e){return n.all||n.seriesName===e.name?Object.assign({},e,{labels:{visible:n.visible}}):e})),i;case fX.legendVisible:return i.legend=Object.assign({},i.legend,{visible:n}),i;case fX.legendFontName:var r=i.legend||{};return i.legend=Object.assign({},r,{labels:Object.assign({},r.labels,{font:MX(n,mX,r.labels&&r.labels.font)})}),i;case fX.legendFontSize:var o=i.legend||{};return i.legend=Object.assign({},o,{labels:Object.assign({},o.labels,{font:EX(n,_X,o.labels&&o.labels.font)})}),i;case fX.legendColor:var a=i.legend||{};return i.legend=Object.assign({},a,{labels:Object.assign({},a.labels,{color:n})}),i;case fX.legendPosition:return i.legend=Object.assign({},i.legend,{position:n}),i;case fX.categoryAxisTitleText:return i.categoryAxis=(i.categoryAxis||[]).map((function(e){return Object.assign({},e,{title:Object.assign({},e.title,{text:n})})})),i;case fX.categoryAxisTitleFontName:return i.categoryAxis=(i.categoryAxis||[]).map((function(e){return Object.assign({},e,{title:Object.assign({},e.title,{font:MX(n,gX,e.title&&e.title.font)})})})),i;case fX.categoryAxisTitleFontSize:return i.categoryAxis=(i.categoryAxis||[]).map((function(e){return Object.assign({},e,{title:Object.assign({},e.title,{font:EX(n,_X,e.title&&e.title.font)})})})),i;case fX.categoryAxisTitleColor:return i.categoryAxis=(i.categoryAxis||[]).map((function(e){return Object.assign({},e,{title:Object.assign({},e.title,{color:n})})})),i;case fX.categoryAxisLabelsFontName:return i.categoryAxis=(i.categoryAxis||[]).map((function(e){return Object.assign({},e,{labels:Object.assign({},e.labels,{font:MX(n,mX,e.labels&&e.labels.font)})})})),i;case fX.categoryAxisLabelsFontSize:return i.categoryAxis=(i.categoryAxis||[]).map((function(e){return Object.assign({},e,{labels:Object.assign({},e.labels,{font:EX(n,_X,e.labels&&e.labels.font)})})})),i;case fX.categoryAxisLabelsColor:return i.categoryAxis=(i.categoryAxis||[]).map((function(e){return Object.assign({},e,{labels:Object.assign({},e.labels,{color:n})})})),i;case fX.categoryAxisLabelsRotation:var s=IX(n)?n:"auto";return i.categoryAxis=(i.categoryAxis||[]).map((function(e){return Object.assign({},e,{labels:Object.assign({},e.labels,{rotation:s})})})),i;case fX.categoryAxisReverseOrder:return i.categoryAxis=(i.categoryAxis||[]).map((function(e){return Object.assign({},e,{reverse:n})})),i;case fX.valueAxisTitleText:return i.valueAxis&&0!==i.valueAxis.length?i.valueAxis=(i.valueAxis||[]).map((function(e){return Object.assign({},e,{title:Object.assign({},e.title,{text:n})})})):i.valueAxis=[{title:{text:n}}],i;case fX.valueAxisTitleFontName:return i.valueAxis=(i.valueAxis||[]).map((function(e){return Object.assign({},e,{title:Object.assign({},e.title,{font:MX(n,gX,e.title&&e.title.font)})})})),i;case fX.valueAxisTitleFontSize:return i.valueAxis=(i.valueAxis||[]).map((function(e){return Object.assign({},e,{title:Object.assign({},e.title,{font:EX(n,_X,e.title&&e.title.font)})})})),i;case fX.valueAxisTitleColor:return i.valueAxis=(i.valueAxis||[]).map((function(e){return Object.assign({},e,{title:Object.assign({},e.title,{color:n})})})),i;case fX.valueAxisLabelsFormat:return i.valueAxis=(i.valueAxis||[]).map((function(e){return Object.assign({},e,{labels:Object.assign({},e.labels,{format:n})})})),i;case fX.valueAxisLabelsFontName:return i.valueAxis=(i.valueAxis||[]).map((function(e){return Object.assign({},e,{labels:Object.assign({},e.labels,{font:MX(n,mX,e.labels&&e.labels.font)})})})),i;case fX.valueAxisLabelsFontSize:return i.valueAxis=(i.valueAxis||[]).map((function(e){return Object.assign({},e,{labels:Object.assign({},e.labels,{font:EX(n,_X,e.labels&&e.labels.font)})})})),i;case fX.valueAxisLabelsColor:return i.valueAxis=(i.valueAxis||[]).map((function(e){return Object.assign({},e,{labels:Object.assign({},e.labels,{color:n})})})),i;case fX.valueAxisLabelsRotation:var l=IX(n)?n:"auto";return i.valueAxis=(i.valueAxis||[]).map((function(e){return Object.assign({},e,{labels:Object.assign({},e.labels,{rotation:l})})})),i;default:return i}}var NX=Object.freeze({windowTitle:"Chart Preview",exportButton:"Export",exportPDFButton:"PDF File",exportSVGButton:"SVG File",exportPNGButton:"PNG File",tabChart:"Chart",tabData:"Data",tabFormat:"Format",barChart:"Bar Chart",barChartBar:"Bar",barChartStackedBar:"Stacked Bar",barChart100StackedBar:"100% Stacked Bar",pieChart:"Pie Chart",pieChartPie:"Pie",columnChart:"Column Chart",columnChartColumn:"Column",columnChartStackedColumn:"Stacked Column",columnChart100StackedColumn:"100% Stacked Column",lineChart:"Line Chart",lineChartLine:"Line",lineChartStackedLine:"Stacked Line",lineChart100StackedLine:"100% Stacked Line",scatterChart:"Scatter Chart",scatterChartScatter:"Scatter",configuration:"Configuration",configurationCategoryAxis:"Category Axis",configurationXAxis:"X Axis",configurationValueAxis:"Value Axis",configurationSeries:"Series",configurationSeriesAdd:"Add",formatChartArea:"Chart Area",formatChartAreaMargins:"Margins",formatChartAreaMarginsAuto:"Auto",formatChartAreaMarginsLeft:"Left",formatChartAreaMarginsRight:"Right",formatChartAreaMarginsTop:"Top",formatChartAreaMarginsBottom:"Bottom",formatChartAreaBackground:"Background",formatChartAreaBackgroundColor:"Color",formatTitle:"Title",formatTitleApplyTo:"Apply to",formatTitleChartTitle:"Chart Title",formatTitleChartSubtitle:"Chart Subtitle",formatTitleLabel:"Title",formatTitleFont:"Font",formatTitleFontPlaceholder:"(inherited font)",formatTitleSize:"Size",formatTitleSizePlaceholder:"px",formatTitleColor:"Color",formatSeries:"Series",formatSeriesApplyTo:"Apply to",formatSeriesAllSeries:"All Series",formatSeriesColor:"Color",formatSeriesShowLabels:"Show Labels",formatLegend:"Legend",formatLegendShowLegend:"Show Legend",formatLegendFont:"Font",formatLegendFontPlaceholder:"(inherited font)",formatLegendSize:"Size",formatLegendSizePlaceholder:"px",formatLegendColor:"Color",formatLegendPosition:"Position",formatLegendPositionTop:"Top",formatLegendPositionBottom:"Bottom",formatLegendPositionLeft:"Left",formatLegendPositionRight:"Right",formatCategoryAxis:"Category Axis",formatXAxis:"X Axis",formatCategoryAxisTitle:"Title",formatCategoryAxisTitlePlaceholder:"Axis Title",formatCategoryAxisTitleFont:"Font",formatCategoryAxisTitleFontPlaceholder:"(inherited font)",formatCategoryAxisTitleSize:"Size",formatCategoryAxisTitleSizePlaceholder:"px",formatCategoryAxisTitleColor:"Color",formatCategoryAxisLabels:"Labels",formatCategoryAxisLabelsFont:"Font",formatCategoryAxisLabelsFontPlaceholder:"(inherited font)",formatCategoryAxisLabelsSize:"Size",formatCategoryAxisLabelsSizePlaceholder:"px",formatCategoryAxisLabelsColor:"Color",formatCategoryAxisLabelsRotation:"Rotation",formatCategoryAxisLabelsRotationAuto:"Auto",formatCategoryAxisLabelsReverseOrder:"Reverse Order",formatValueAxis:"Value Axis",formatYAxis:"Y Axis",formatValueAxisTitle:"Title",formatValueAxisTitlePlaceholder:"Axis Title",formatValueAxisTitleFont:"Font",formatValueAxisTitleFontPlaceholder:"(inherited font)",formatValueAxisTitleSize:"Size",formatValueAxisTitleSizePlaceholder:"px",formatValueAxisTitleColor:"Color",formatValueAxisLabels:"Labels",formatValueAxisLabelsFormat:"Label Format",formatValueAxisLabelsFormatText:"Text",formatValueAxisLabelsFormatNumber:"Number",formatValueAxisLabelsFormatCurrency:"Currency",formatValueAxisLabelsFormatPercent:"Percent",formatValueAxisLabelsFont:"Font",formatValueAxisLabelsFontPlaceholder:"(inherited font)",formatValueAxisLabelsSize:"Size",formatValueAxisLabelsSizePlaceholder:"px",formatValueAxisLabelsColor:"Color",formatValueAxisLabelsRotation:"Rotation",formatValueAxisLabelsRotationAuto:"Auto"}),$X=(Object.freeze({getWizardDataFromDataRows:function(e){var t=[];return e.forEach((function(e){var n=e.dataItem,i=e.dataColumns,r=[];i.forEach((function(e){r.push({field:e.title||e.field,value:XF(e.field)(n)})})),t.push(r)})),t},ActionTypes:fX,createInitialState:function(e,t,n){var i=BX(e,n&&n.seriesType||t);return void 0!==(n&&n.stack)?VX(i,fX.stacked,n.stack):i},createState:BX,fontNames:vX,fontSizes:[{text:"10",value:"10px"},{text:"12",value:"12px"},{text:"14",value:"14px"},{text:"16",value:"16px"},{text:"20",value:"20px"},{text:"28",value:"28px"},{text:"42",value:"42px"},{text:"56",value:"56px"}],isCategorical:xX,mergeStates:OX,parseFont:AX,updateState:VX,messages:NX}),1.5),UX=.4,WX="#000",jX="Arial, Helvetica, sans-serif",qX="11px "+jX,GX="12px "+jX,KX="16px "+jX,YX="transparent",QX="#fff",XX={type:TV},ZX={type:fV},JX=Object.assign({},ZX,{markers:{visible:!1},highlight:{visible:!1}}),eZ=function(){return{icon:{border:{width:1}},label:{font:GX,padding:3},line:{length:10,width:2},legendItem:JX,visible:!0}},tZ=function(){return{highlight:{markers:{border:{}}},line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:ZX,opacity:.4}},nZ=function(){return{highlight:{markers:{border:{}}},line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:ZX,opacity:.4}},iZ=function(){return{outliersField:"",meanField:"",border:{_brightness:.8,width:1},downColor:QX,gap:1,highlight:{border:{opacity:1,width:2},whiskers:{width:3},mean:{width:2},median:{width:2}},mean:{width:2},median:{width:2},spacing:.3,whiskers:{width:2},legendItem:JX}},rZ=function(){return{gap:$X,spacing:UX,target:{color:"#ff0000"},legendItem:JX}},oZ=function(){return{width:2,legendItem:XX}},aZ=function(){return{line:{opacity:1,width:0},markers:{size:6,visible:!1},legendItem:ZX,opacity:.5}},sZ=function(){return{markers:{visible:!1},legendItem:XX,width:2}},lZ=function(){return{gap:.5,line:{color:WX,width:1},legendItem:JX,spacing:UX}},cZ=function(){return{labels:{background:"",color:"",padding:{top:5,bottom:5,left:7,right:7}},legendItem:JX}},dZ=cZ,uZ=function(e){return Object.assign({color:QH,trendline:{},markers:{visible:!1},width:1,dashType:"longDash",legendItem:XX},e)},hZ=function(e){return{visible:!0,labels:{font:qX},overlay:e.gradients?{}:{gradient:"none"},area:tZ(),rangeArea:nZ(),verticalRangeArea:nZ(),bar:{gap:$X,spacing:UX,legendItem:JX},boxPlot:iZ(),bubble:{border:{width:0},labels:{background:YX},legendItem:JX,opacity:.6},bullet:rZ(),candlestick:{border:{_brightness:.8,width:1},downColor:QX,gap:1,highlight:{border:{opacity:1,width:2},line:{width:2}},line:{color:WX,width:1},legendItem:JX,spacing:.3},column:{gap:$X,spacing:UX,legendItem:JX},heatmap:{labels:{color:"",background:YX,visible:!0},highlight:{border:{width:0}},legendItem:JX},pie:{labels:{background:"",color:"",padding:{top:5,bottom:5,left:7,right:7}},legendItem:JX},donut:{margin:1,legendItem:JX},funnel:cZ(),pyramid:dZ(),horizontalWaterfall:lZ(),line:oZ(),notes:eZ(),ohlc:{gap:1,highlight:{line:{opacity:1,width:3}},line:{width:1},legendItem:JX,spacing:.3},radarArea:aZ(),radarLine:sZ(),radarColumn:{legendItem:JX},polarArea:aZ(),polarLine:sZ(),polarScatter:{legendItem:XX},rangeBar:{gap:$X,spacing:UX,legendItem:JX},rangeColumn:{gap:$X,spacing:UX,legendItem:JX},scatter:{legendItem:XX},scatterLine:{width:1,legendItem:XX},verticalArea:tZ(),verticalBoxPlot:iZ(),verticalBullet:rZ(),verticalLine:oZ(),waterfall:lZ(),linearTrendline:uZ(),exponentialTrendline:uZ({style:"smooth"}),logarithmicTrendline:uZ({style:"smooth"}),polynomialTrendline:uZ({style:"smooth"}),powerTrendline:uZ({style:"smooth"}),movingAverageTrendline:uZ()}},pZ=function(e){return void 0===e&&(e={}),{axisDefaults:{labels:{font:GX},notes:eZ(),title:{font:KX,margin:5}},categoryAxis:{majorGridLines:{visible:!0}},navigator:{pane:{height:90,margin:{top:10}}},seriesDefaults:hZ(e),title:{font:KX},subtitle:{font:GX},legend:{labels:{font:GX}}}},fZ=Object.freeze({__proto__:null,Aggregates:WO,AreaChart:x$,AreaSegment:y$,AxisGroupRangeTracker:C$,Bar:D$,BarChart:z$,BarLabel:S$,BoxPlot:F$,BoxPlotChart:L$,BubbleChart:N$,Bullet:U$,BulletChart:W$,Candlestick:P$,CandlestickChart:H$,CategoricalChart:s$,CategoricalErrorBar:NN,CategoricalPlotArea:HU,Chart:gj,ChartAxis:OO,ChartContainer:K$,ChartPane:NO,ChartPlotArea:$O,ClipAnimation:v$,ClusterLayout:E$,Crosshair:G$,CrosshairTooltip:q$,DefaultAggregates:oU,DonutChart:MW,DonutPlotArea:EW,DonutSegment:AW,ErrorBarBase:VN,ErrorRangeCalculator:YO,Highlight:LU,Legend:ZU,LegendItem:QU,LegendLayout:WU,LineChart:b$,LinePoint:d$,LineSegment:u$,MousewheelZoom:UU,OHLCChart:gU,OHLCPoint:mU,Pane:Y$,Pannable:NU,PieAnimation:lW,PieChart:SW,PieChartMixin:CW,PiePlotArea:DW,PieSegment:yW,PlotAreaBase:X$,PlotAreaEventsMixin:nU,PlotAreaFactory:JU,PointEventsMixin:l$,RangeAreaChart:fU,RangeAreaPoint:dU,RangeBar:aU,RangeBarChart:sU,ScatterChart:O$,ScatterErrorBar:B$,ScatterLineChart:cW,Selection:nW,SeriesAggregator:iU,SeriesBinder:qO,SharedTooltip:rW,SplineAreaSegment:k$,SplineSegment:m$,StackWrap:I$,Tooltip:iW,WaterfallChart:_U,WaterfallSegment:vU,XYPlotArea:_W,ZoomSelection:$U,anyHasZIndex:$N,appendIfNotNull:UN,areNumbers:WN,bindSegments:qN,categoriesCount:GN,constants:ON,countNumbers:UO,createOutOfRangePoints:a$,equalsIgnoreCase:KN,evalOptions:YN,filterSeriesByType:QN,findAxisByName:VO,getField:jO,hasGradientOverlay:JN,hasValue:e$,isDateAxis:t$,parseDateCategory:ZN,segmentVisible:jN,singleItemOrArray:n$});window.kendo.dataviz=window.kendo.dataviz||{},kendo.deepExtend(kendo.dataviz,kendo.deepExtend({},BO)),kendo.dataviz.Gradients=JL;const mZ=kendo.jQuery;let gZ=kendo.dataviz,vZ=kendo.drawing,_Z=xB;for(let e in BO)QR(e)&&(gZ[e]=BO[e]);gZ.SASS_THEMES=["sass","default-v2","bootstrap-v4","material-v2"],gZ.ExportMixin={extend:function(e,t){if(!e.exportVisual)throw new Error("Mixin target has no exportVisual method defined.");e.exportSVG=this.exportSVG,e.exportImage=this.exportImage,e.exportPDF=this.exportPDF,t||(e.svg=this.svg,e.imageDataURL=this.imageDataURL)},exportSVG:function(e){return vZ.exportSVG(this.exportVisual(),e)},exportImage:function(e){return vZ.exportImage(this.exportVisual(e),e)},exportPDF:function(e){return vZ.exportPDF(this.exportVisual(),e)},svg:function(){if(vZ.svg.Surface)return vZ.svg.exportGroup(this.exportVisual());throw new Error("SVG Export failed. Unable to export instantiate kendo.drawing.svg.Surface")},imageDataURL:function(){if(!kendo.support.canvas)return null;if(vZ.canvas.Surface){var e=mZ("<div />").css({display:"none",width:this.element.width(),height:this.element.height()}).appendTo(document.body),t=new vZ.canvas.Surface(e[0]);t.draw(this.exportVisual());var n=t._rootElement.toDataURL();return t.destroy(),e.remove(),n}throw new Error("Image Export failed. Unable to export instantiate kendo.drawing.canvas.Surface")}},_Z.IntlService.register({format:function(e){return kendo.format.apply(null,[e].concat(Array.prototype.slice.call(arguments,1)))},toString:kendo.toString,parseDate:kendo.parseDate,firstDay:function(){return kendo.culture().calendars.standard.firstDay}}),_Z.TemplateService.register({compile:kendo.template}),gZ.inArray=function(e,t){if(t)return-1!==t.indexOf(e)},gZ.Point2D=OL,gZ.Box2D=VL,gZ.mwDelta=function(e){return lR(e.originalEvent)};kendo;!function(e){var t;kendo.dataviz.autoTheme=function(n){if(!n&&t)return t;var i,r,o={chart:pZ()},a=e('<div>  <div class="k-var--primary"></div>  <div class="k-var--primary-contrast"></div>  <div class="k-var--base"></div>  <div class="k-var--background"></div>  <div class="k-var--normal-background"></div>  <div class="k-var--normal-text-color"></div>  <div class="k-var--hover-background"></div>  <div class="k-var--hover-text-color"></div>  <div class="k-var--selected-background"></div>  <div class="k-var--selected-text-color"></div>  <div class="k-var--chart-error-bars-background"></div>  <div class="k-var--chart-notes-background"></div>  <div class="k-var--chart-notes-border"></div>  <div class="k-var--chart-notes-lines"></div>  <div class="k-var--chart-crosshair-background"></div>  <div class="k-var--chart-inactive"></div>  <div class="k-var--chart-major-lines"></div>  <div class="k-var--chart-minor-lines"></div>  <div class="k-var--chart-area-opacity"></div>  <div class="k-var--chart-area-inactive-opacity"></div>  <div class="k-var--chart-line-inactive-opacity"></div>  <div class="k-widget k-chart">      <div class="k-var--chart-font"></div>      <div class="k-var--chart-title-font"></div>      <div class="k-var--chart-pane-title-font"></div>      <div class="k-var--chart-label-font"></div>  </div>  <div class="k-var--series-unset"></div>  <div class="k-var--series">'+function(){for(var e='<div class="k-var--series-a"></div><div class="k-var--series-b"></div><div class="k-var--series-c"></div><div class="k-var--series-d"></div><div class="k-var--series-e"></div><div class="k-var--series-f"></div>',t=0;t<30;t++)e+='<div class="k-var--series-'+(t+1)+'"></div>';return e}()+'  </div>  <div class="k-var--gauge-pointer"></div>  <div class="k-var--gauge-track"></div></div>').hide().appendTo(document.body);function s(e,t){c(e,l(t,"backgroundColor"))}function l(e,t){return a.find(".k-var--"+e).css(t)}function c(e,t){for(var n=o,i=e.split("."),r=i.shift();i.length>0;)n=n[r]=n[r]||{},r=i.shift();n[r]=t}function d(e,t){var n=parseFloat(l(t,"opacity"));!isNaN(n)&&n<1&&e.forEach((function(e){c("chart.seriesDefaults."+e+".highlight.inactiveOpacity",n)}))}return function(){s("chart.axisDefaults.crosshair.color","chart-crosshair-background"),s("chart.axisDefaults.labels.color","normal-text-color"),s("chart.axisDefaults.line.color","chart-major-lines"),s("chart.axisDefaults.majorGridLines.color","chart-major-lines"),s("chart.axisDefaults.minorGridLines.color","chart-minor-lines"),s("chart.axisDefaults.notes.icon.background","chart-notes-background"),s("chart.axisDefaults.notes.icon.border.color","chart-notes-border"),s("chart.axisDefaults.notes.line.color","chart-notes-lines"),s("chart.axisDefaults.title.color","normal-text-color"),s("chart.chartArea.background","background"),s("chart.legend.inactiveItems.labels.color","chart-inactive"),s("chart.legend.inactiveItems.markers.color","chart-inactive"),s("chart.legend.labels.color","normal-text-color"),s("chart.seriesDefaults.boxPlot.downColor","chart-major-lines"),s("chart.seriesDefaults.boxPlot.mean.color","base"),s("chart.seriesDefaults.boxPlot.median.color","base"),s("chart.seriesDefaults.boxPlot.whiskers.color","primary"),s("chart.seriesDefaults.bullet.target.color","primary"),s("chart.seriesDefaults.candlestick.downColor","normal-text-color"),s("chart.seriesDefaults.candlestick.line.color","normal-text-color"),s("chart.seriesDefaults.errorBars.color","chart-error-bars-background"),s("chart.seriesDefaults.horizontalWaterfall.line.color","chart-major-lines"),s("chart.seriesDefaults.icon.border.color","chart-major-lines"),s("chart.seriesDefaults.labels.background","background"),s("chart.seriesDefaults.labels.color","normal-text-color"),s("chart.seriesDefaults.notes.icon.background","chart-notes-background"),s("chart.seriesDefaults.notes.icon.border.color","chart-notes-border"),s("chart.seriesDefaults.notes.line.color","chart-notes-lines"),s("chart.seriesDefaults.verticalBoxPlot.downColor","chart-major-lines"),s("chart.seriesDefaults.verticalBoxPlot.mean.color","base"),s("chart.seriesDefaults.verticalBoxPlot.median.color","base"),s("chart.seriesDefaults.verticalBoxPlot.whiskers.color","primary"),s("chart.seriesDefaults.verticalBullet.target.color","primary"),s("chart.seriesDefaults.waterfall.line.color","chart-major-lines"),s("chart.title.color","normal-text-color"),s("chart.subtitle.color","normal-text-color"),s("diagram.shapeDefaults.fill.color","primary"),s("diagram.shapeDefaults.content.color","primary-contrast"),s("diagram.shapeDefaults.connectorDefaults.fill.color","normal-text-color"),s("diagram.shapeDefaults.connectorDefaults.stroke.color","primary-contrast"),s("diagram.shapeDefaults.connectorDefaults.hover.fill.color","primary-contrast"),s("diagram.shapeDefaults.connectorDefaults.hover.stroke.color","normal-text-color"),s("diagram.editable.resize.handles.stroke.color","normal-text-color"),s("diagram.editable.resize.handles.fill.color","normal-background"),s("diagram.editable.resize.handles.hover.stroke.color","normal-text-color"),s("diagram.editable.resize.handles.hover.fill.color","normal-text-color"),s("diagram.selectable.stroke.color","normal-text-color"),s("diagram.connectionDefaults.stroke.color","normal-text-color"),s("diagram.connectionDefaults.content.color","normal-text-color"),s("diagram.connectionDefaults.selection.handles.fill.color","primary-contrast"),s("diagram.connectionDefaults.selection.handles.stroke.color","normal-text-color"),s("diagram.connectionDefaults.selection.stroke.color","normal-text-color"),s("gauge.pointer.color","gauge-pointer"),s("gauge.scale.labels.color","normal-text-color"),s("gauge.scale.minorTicks.color","normal-text-color"),s("gauge.scale.majorTicks.color","normal-text-color"),s("gauge.scale.line.color","normal-text-color"),s("gauge.scale.rangePlaceholderColor","gauge-track");var e=parseFloat(l("chart-area-opacity","opacity"));isNaN(e)||(c("chart.seriesDefaults.area.opacity",e),c("chart.seriesDefaults.radarArea.opacity",e),c("chart.seriesDefaults.verticalArea.opacity",e),c("chart.seriesDefaults.labels.opacity",e)),d(["area","verticalArea"],"chart-area-inactive-opacity"),d(["line","verticalLine"],"chart-line-inactive-opacity")}(),c("diagram.connectionDefaults.selection.handles.width",8),c("diagram.connectionDefaults.selection.handles.height",8),function(){function e(e){return l(e,"fontWeight")+" "+l(e,"fontSize")+" "+l(e,"fontFamily")}var t=e("chart-font"),n=e("chart-title-font"),i=e("chart-pane-title-font"),r=e("chart-label-font");c("chart.axisDefaults.labels.font",r),c("chart.axisDefaults.notes.label.font",t),c("chart.axisDefaults.title.font",t),c("chart.legend.labels.font",t),c("chart.seriesDefaults.labels.font",r),c("chart.seriesDefaults.notes.label.font",t),c("chart.title.font",n),c("chart.subtitle.font",i),c("chart.paneDefaults.title.font",i)}(),i=e(".k-var--series div").toArray(),r=e(".k-var--series-unset").css("backgroundColor"),c("chart.seriesColors",i.reduce((function(t,n){var i=function(e){var t=e.match(/series-([a-z])$/);if(null!==t)return t[1].toLowerCase().charCodeAt(0)-"a".charCodeAt(0);var n=e.split("--series-")[1];return parseInt(n,10)-1}(n.className),o=e(n).css("backgroundColor");return o!==r&&(t[i]=o),t}),[])),a.remove(),t=o,o}}(window.kendo.jQuery);!function(e){window.kendo.dataviz=window.kendo.dataviz||{};var t=window.kendo,n=t.dataviz.ui,i=t.deepExtend,r="#000",o="#fff",a=pZ({gradients:!0}),s={scale:{labels:{font:"12px Arial,Helvetica,sans-serif"}}},l={shapeDefaults:{hover:{opacity:.2},stroke:{width:0}},editable:{resize:{handles:{width:7,height:7}}},selectable:{stroke:{width:1,dashType:"dot"}},connectionDefaults:{stroke:{width:2},selection:{handles:{width:8,height:8}},editable:{tools:["edit","delete"]}}},c=n.themes,d=n.registerTheme=function(e,t){var n={};n.chart=i({},a,t.chart),n.gauge=i({},s,t.gauge),n.diagram=i({},l,t.diagram),n.treeMap=i({},t.treeMap);var r=n.chart.seriesDefaults;r.verticalLine=i({},r.line),r.verticalArea=i({},r.area),r.rangeArea=i({},r.area),r.verticalRangeArea=i({},r.rangeArea),r.verticalBoxPlot=i({},r.boxPlot),r.polarArea=i({},r.radarArea),r.polarLine=i({},r.radarLine),c[e]=n};function u(t,n){return e.map(t,(function(e,t){return[[e,n[t]]]}))}d("black",{chart:{title:{color:o},subtitle:{color:o},legend:{labels:{color:o},inactiveItems:{labels:{color:"#919191"},markers:{color:"#919191"}}},seriesDefaults:{labels:{color:o},errorBars:{color:o},notes:{icon:{background:"#3b3b3b",border:{color:"#8e8e8e"}},label:{color:o},line:{color:"#8e8e8e"}},pie:{overlay:{gradient:"sharpBevel"}},donut:{overlay:{gradient:"sharpGlass"}},line:{markers:{background:"#3d3d3d"}},scatter:{markers:{background:"#3d3d3d"}},scatterLine:{markers:{background:"#3d3d3d"}},waterfall:{line:{color:"#8e8e8e"}},horizontalWaterfall:{line:{color:"#8e8e8e"}},candlestick:{downColor:"#555",line:{color:o},border:{_brightness:1.5,opacity:1},highlight:{border:{color:o,opacity:.2}}},ohlc:{line:{color:o}}},chartArea:{background:"#3d3d3d"},seriesColors:["#0081da","#3aafff","#99c900","#ffeb3d","#b20753","#ff4195"],axisDefaults:{line:{color:"#8e8e8e"},labels:{color:o},majorGridLines:{color:"#545454"},minorGridLines:{color:"#454545"},title:{color:o},crosshair:{color:"#8e8e8e"},notes:{icon:{background:"#3b3b3b",border:{color:"#8e8e8e"}},label:{color:o},line:{color:"#8e8e8e"}}}},gauge:{pointer:{color:"#0070e4"},scale:{rangePlaceholderColor:"#1d1d1d",labels:{color:o},minorTicks:{color:o},majorTicks:{color:o},line:{color:o}}},diagram:{shapeDefaults:{fill:{color:"#0066cc"},connectorDefaults:{fill:{color:o},stroke:{color:"#384049"},hover:{fill:{color:"#3d3d3d"},stroke:{color:"#efefef"}}},content:{color:o}},editable:{resize:{handles:{fill:{color:"#3d3d3d"},stroke:{color:o},hover:{fill:{color:o},stroke:{color:o}}}},rotate:{thumb:{stroke:{color:o},fill:{color:o}}}},selectable:{stroke:{color:o}},connectionDefaults:{stroke:{color:o},content:{color:o},selection:{handles:{fill:{color:"#3d3d3d"},stroke:{color:"#efefef"}}}}},treeMap:{colors:[["#0081da","#314b5c"],["#3aafff","#3c5464"],["#99c900","#4f5931"],["#ffeb3d","#64603d"],["#b20753","#543241"],["#ff4195","#643e4f"]]}}),d("blueopal",{chart:{title:{color:"#293135"},subtitle:{color:"#293135"},legend:{labels:{color:"#293135"},inactiveItems:{labels:{color:"#27A5BA"},markers:{color:"#27A5BA"}}},seriesDefaults:{labels:{color:r,background:o,opacity:.5},errorBars:{color:"#293135"},candlestick:{downColor:"#c4d0d5",line:{color:"#9aabb2"}},waterfall:{line:{color:"#9aabb2"}},horizontalWaterfall:{line:{color:"#9aabb2"}},notes:{icon:{background:"transparent",border:{color:"#9aabb2"}},label:{color:"#293135"},line:{color:"#9aabb2"}}},seriesColors:["#0069a5","#0098ee","#7bd2f6","#ffb800","#ff8517","#e34a00"],axisDefaults:{line:{color:"#9aabb2"},labels:{color:"#293135"},majorGridLines:{color:"#c4d0d5"},minorGridLines:{color:"#edf1f2"},title:{color:"#293135"},crosshair:{color:"#9aabb2"},notes:{icon:{background:"transparent",border:{color:"#9aabb2"}},label:{color:"#293135"},line:{color:"#9aabb2"}}}},gauge:{pointer:{color:"#005c83"},scale:{rangePlaceholderColor:"#daecf4",labels:{color:"#293135"},minorTicks:{color:"#293135"},majorTicks:{color:"#293135"},line:{color:"#293135"}}},diagram:{shapeDefaults:{fill:{color:"#7ec6e3"},connectorDefaults:{fill:{color:"#003f59"},stroke:{color:o},hover:{fill:{color:o},stroke:{color:"#003f59"}}},content:{color:"#293135"}},editable:{resize:{handles:{fill:{color:o},stroke:{color:"#003f59"},hover:{fill:{color:"#003f59"},stroke:{color:"#003f59"}}}},rotate:{thumb:{stroke:{color:"#003f59"},fill:{color:"#003f59"}}}},selectable:{stroke:{color:"#003f59"}},connectionDefaults:{stroke:{color:"#003f59"},content:{color:"#293135"},selection:{handles:{fill:{color:"#3d3d3d"},stroke:{color:"#efefef"}}}}},treeMap:{colors:[["#0069a5","#bad7e7"],["#0098ee","#b9e0f5"],["#7bd2f6","#ceeaf6"],["#ffb800","#e6e3c4"],["#ff8517","#e4d8c8"],["#e34a00","#ddccc2"]]}}),d("highcontrast",{chart:{title:{color:"#ffffff"},subtitle:{color:"#ffffff"},legend:{labels:{color:"#ffffff"},inactiveItems:{labels:{color:"#66465B"},markers:{color:"#66465B"}}},seriesDefaults:{labels:{color:"#ffffff"},errorBars:{color:"#ffffff"},notes:{icon:{background:"transparent",border:{color:"#ffffff"}},label:{color:"#ffffff"},line:{color:"#ffffff"}},pie:{overlay:{gradient:"sharpGlass"}},donut:{overlay:{gradient:"sharpGlass"}},line:{markers:{background:"#2c232b"}},scatter:{markers:{background:"#2c232b"}},scatterLine:{markers:{background:"#2c232b"}},area:{opacity:.5},waterfall:{line:{color:"#ffffff"}},horizontalWaterfall:{line:{color:"#ffffff"}},candlestick:{downColor:"#664e62",line:{color:"#ffffff"},border:{_brightness:1.5,opacity:1},highlight:{border:{color:"#ffffff",opacity:1}}},ohlc:{line:{color:"#ffffff"}}},chartArea:{background:"#2c232b"},seriesColors:["#a7008f","#ffb800","#3aafff","#99c900","#b20753","#ff4195"],axisDefaults:{line:{color:"#ffffff"},labels:{color:"#ffffff"},majorGridLines:{color:"#664e62"},minorGridLines:{color:"#4f394b"},title:{color:"#ffffff"},crosshair:{color:"#ffffff"},notes:{icon:{background:"transparent",border:{color:"#ffffff"}},label:{color:"#ffffff"},line:{color:"#ffffff"}}}},gauge:{pointer:{color:"#a7008f"},scale:{rangePlaceholderColor:"#2c232b",labels:{color:"#ffffff"},minorTicks:{color:"#2c232b"},majorTicks:{color:"#664e62"},line:{color:"#ffffff"}}},diagram:{shapeDefaults:{fill:{color:"#a7018f"},connectorDefaults:{fill:{color:o},stroke:{color:"#2c232b"},hover:{fill:{color:"#2c232b"},stroke:{color:o}}},content:{color:o}},editable:{resize:{handles:{fill:{color:"#2c232b"},stroke:{color:o},hover:{fill:{color:o},stroke:{color:o}}}},rotate:{thumb:{stroke:{color:o},fill:{color:o}}}},selectable:{stroke:{color:o}},connectionDefaults:{stroke:{color:o},content:{color:o},selection:{handles:{fill:{color:"#2c232b"},stroke:{color:o}}}}},treeMap:{colors:[["#a7008f","#451c3f"],["#ffb800","#564122"],["#3aafff","#2f3f55"],["#99c900","#424422"],["#b20753","#471d33"],["#ff4195","#562940"]]}}),d("default",{chart:{title:{color:"#8e8e8e"},subtitle:{color:"#8e8e8e"},legend:{labels:{color:"#232323"},inactiveItems:{labels:{color:"#919191"},markers:{color:"#919191"}}},seriesDefaults:{labels:{color:r,background:o,opacity:.5},errorBars:{color:"#232323"},candlestick:{downColor:"#dedede",line:{color:"#8d8d8d"}},waterfall:{line:{color:"#8e8e8e"}},horizontalWaterfall:{line:{color:"#8e8e8e"}},notes:{icon:{background:"transparent",border:{color:"#8e8e8e"}},label:{color:"#232323"},line:{color:"#8e8e8e"}}},seriesColors:["#ff6800","#a0a700","#ff8d00","#678900","#ffb53c","#396000"],axisDefaults:{line:{color:"#8e8e8e"},labels:{color:"#232323"},minorGridLines:{color:"#f0f0f0"},majorGridLines:{color:"#dfdfdf"},title:{color:"#232323"},crosshair:{color:"#8e8e8e"},notes:{icon:{background:"transparent",border:{color:"#8e8e8e"}},label:{color:"#232323"},line:{color:"#8e8e8e"}}}},gauge:{pointer:{color:"#ea7001"},scale:{rangePlaceholderColor:"#dedede",labels:{color:"#2e2e2e"},minorTicks:{color:"#2e2e2e"},majorTicks:{color:"#2e2e2e"},line:{color:"#2e2e2e"}}},diagram:{shapeDefaults:{fill:{color:"#e15613"},connectorDefaults:{fill:{color:"#282828"},stroke:{color:o},hover:{fill:{color:o},stroke:{color:"#282828"}}},content:{color:"#2e2e2e"}},editable:{resize:{handles:{fill:{color:o},stroke:{color:"#282828"},hover:{fill:{color:"#282828"},stroke:{color:"#282828"}}}},rotate:{thumb:{stroke:{color:"#282828"},fill:{color:"#282828"}}}},selectable:{stroke:{color:"#a7018f"}},connectionDefaults:{stroke:{color:"#282828"},content:{color:"#2e2e2e"},selection:{handles:{fill:{color:o},stroke:{color:"#282828"}}}}},treeMap:{colors:[["#ff6800","#edcfba"],["#a0a700","#dadcba"],["#ff8d00","#edd7ba"],["#678900","#cfd6ba"],["#ffb53c","#eddfc6"],["#396000","#c6ceba"]]}}),d("silver",{chart:{title:{color:"#4e5968"},subtitle:{color:"#4e5968"},legend:{labels:{color:"#4e5968"},inactiveItems:{labels:{color:"#B1BCC8"},markers:{color:"#B1BCC8"}}},seriesDefaults:{labels:{color:"#293135",background:"#eaeaec",opacity:.5},errorBars:{color:"#4e5968"},notes:{icon:{background:"transparent",border:{color:"#4e5968"}},label:{color:"#4e5968"},line:{color:"#4e5968"}},line:{markers:{background:"#eaeaec"}},scatter:{markers:{background:"#eaeaec"}},scatterLine:{markers:{background:"#eaeaec"}},pie:{connectors:{color:"#A6B1C0"}},donut:{connectors:{color:"#A6B1C0"}},waterfall:{line:{color:"#a6b1c0"}},horizontalWaterfall:{line:{color:"#a6b1c0"}},candlestick:{downColor:"#a6afbe"}},chartArea:{background:"#eaeaec"},seriesColors:["#007bc3","#76b800","#ffae00","#ef4c00","#a419b7","#430B62"],axisDefaults:{line:{color:"#a6b1c0"},labels:{color:"#4e5968"},majorGridLines:{color:"#dcdcdf"},minorGridLines:{color:"#eeeeef"},title:{color:"#4e5968"},crosshair:{color:"#a6b1c0"},notes:{icon:{background:"transparent",border:{color:"#4e5968"}},label:{color:"#4e5968"},line:{color:"#4e5968"}}}},gauge:{pointer:{color:"#0879c0"},scale:{rangePlaceholderColor:"#f3f3f4",labels:{color:"#515967"},minorTicks:{color:"#515967"},majorTicks:{color:"#515967"},line:{color:"#515967"}}},diagram:{shapeDefaults:{fill:{color:"#1c82c2"},connectorDefaults:{fill:{color:"#515967"},stroke:{color:o},hover:{fill:{color:o},stroke:{color:"#282828"}}},content:{color:"#515967"}},editable:{resize:{handles:{fill:{color:o},stroke:{color:"#515967"},hover:{fill:{color:"#515967"},stroke:{color:"#515967"}}}},rotate:{thumb:{stroke:{color:"#515967"},fill:{color:"#515967"}}}},selectable:{stroke:{color:"#515967"}},connectionDefaults:{stroke:{color:"#515967"},content:{color:"#515967"},selection:{handles:{fill:{color:o},stroke:{color:"#515967"}}}}},treeMap:{colors:[["#007bc3","#c2dbea"],["#76b800","#dae7c3"],["#ffae00","#f5e5c3"],["#ef4c00","#f2d2c3"],["#a419b7","#e3c7e8"],["#430b62","#d0c5d7"]]}}),d("metro",{chart:{title:{color:"#777777"},subtitle:{color:"#777777"},legend:{labels:{color:"#777777"},inactiveItems:{labels:{color:"#CBCBCB"},markers:{color:"#CBCBCB"}}},seriesDefaults:{labels:{color:r},errorBars:{color:"#777777"},notes:{icon:{background:"transparent",border:{color:"#777777"}},label:{color:"#777777"},line:{color:"#777777"}},candlestick:{downColor:"#c7c7c7",line:{color:"#787878"}},waterfall:{line:{color:"#c7c7c7"}},horizontalWaterfall:{line:{color:"#c7c7c7"}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:["#8ebc00","#309b46","#25a0da","#ff6900","#e61e26","#d8e404","#16aba9","#7e51a1","#313131","#ed1691"],axisDefaults:{line:{color:"#c7c7c7"},labels:{color:"#777777"},minorGridLines:{color:"#c7c7c7"},majorGridLines:{color:"#c7c7c7"},title:{color:"#777777"},crosshair:{color:"#c7c7c7"},notes:{icon:{background:"transparent",border:{color:"#777777"}},label:{color:"#777777"},line:{color:"#777777"}}}},gauge:{pointer:{color:"#8ebc00"},scale:{rangePlaceholderColor:"#e6e6e6",labels:{color:"#777"},minorTicks:{color:"#777"},majorTicks:{color:"#777"},line:{color:"#777"}}},diagram:{shapeDefaults:{fill:{color:"#8ebc00"},connectorDefaults:{fill:{color:r},stroke:{color:o},hover:{fill:{color:o},stroke:{color:r}}},content:{color:"#777"}},editable:{resize:{handles:{fill:{color:o},stroke:{color:"#787878"},hover:{fill:{color:"#787878"},stroke:{color:"#787878"}}}},rotate:{thumb:{stroke:{color:"#787878"},fill:{color:"#787878"}}}},selectable:{stroke:{color:"#515967"}},connectionDefaults:{stroke:{color:"#787878"},content:{color:"#777"},selection:{handles:{fill:{color:o},stroke:{color:"#787878"}}}}},treeMap:{colors:[["#8ebc00","#e8f2cc"],["#309b46","#d6ebda"],["#25a0da","#d3ecf8"],["#ff6900","#ffe1cc"],["#e61e26","#fad2d4"],["#d8e404","#f7facd"],["#16aba9","#d0eeee"],["#7e51a1","#e5dcec"],["#313131","#d6d6d6"],["#ed1691","#fbd0e9"]]}}),d("metroblack",{chart:{title:{color:"#ffffff"},subtitle:{color:"#ffffff"},legend:{labels:{color:"#ffffff"},inactiveItems:{labels:{color:"#797979"},markers:{color:"#797979"}}},seriesDefaults:{border:{_brightness:1},labels:{color:"#ffffff"},errorBars:{color:"#ffffff"},notes:{icon:{background:"transparent",border:{color:"#cecece"}},label:{color:"#ffffff"},line:{color:"#cecece"}},line:{markers:{background:"#0e0e0e"}},bubble:{opacity:.6},scatter:{markers:{background:"#0e0e0e"}},scatterLine:{markers:{background:"#0e0e0e"}},candlestick:{downColor:"#828282",line:{color:"#ffffff"}},waterfall:{line:{color:"#cecece"}},horizontalWaterfall:{line:{color:"#cecece"}},overlay:{gradient:"none"}},chartArea:{background:"#0e0e0e"},seriesColors:["#00aba9","#309b46","#8ebc00","#ff6900","#e61e26","#d8e404","#25a0da","#7e51a1","#313131","#ed1691"],axisDefaults:{line:{color:"#cecece"},labels:{color:"#ffffff"},minorGridLines:{color:"#2d2d2d"},majorGridLines:{color:"#333333"},title:{color:"#ffffff"},crosshair:{color:"#cecece"},notes:{icon:{background:"transparent",border:{color:"#cecece"}},label:{color:"#ffffff"},line:{color:"#cecece"}}}},gauge:{pointer:{color:"#00aba9"},scale:{rangePlaceholderColor:"#2d2d2d",labels:{color:"#ffffff"},minorTicks:{color:"#333333"},majorTicks:{color:"#cecece"},line:{color:"#cecece"}}},diagram:{shapeDefaults:{fill:{color:"#00aba9"},connectorDefaults:{fill:{color:o},stroke:{color:"#0e0e0e"},hover:{fill:{color:"#0e0e0e"},stroke:{color:o}}},content:{color:o}},editable:{resize:{handles:{fill:{color:"#0e0e0e"},stroke:{color:"#787878"},hover:{fill:{color:"#787878"},stroke:{color:"#787878"}}}},rotate:{thumb:{stroke:{color:o},fill:{color:o}}}},selectable:{stroke:{color:"#787878"}},connectionDefaults:{stroke:{color:o},content:{color:o},selection:{handles:{fill:{color:"#0e0e0e"},stroke:{color:o}}}}},treeMap:{colors:[["#00aba9","#0b2d2d"],["#309b46","#152a19"],["#8ebc00","#28310b"],["#ff6900","#3e200b"],["#e61e26","#391113"],["#d8e404","#36390c"],["#25a0da","#132b37"],["#7e51a1","#241b2b"],["#313131","#151515"],["#ed1691","#3b1028"]]}}),d("moonlight",{chart:{title:{color:"#ffffff"},subtitle:{color:"#ffffff"},legend:{labels:{color:"#ffffff"},inactiveItems:{labels:{color:"#A1A7AB"},markers:{color:"#A1A7AB"}}},seriesDefaults:{labels:{color:"#ffffff"},errorBars:{color:"#ffffff"},notes:{icon:{background:"transparent",border:{color:"#8c909e"}},label:{color:"#ffffff"},line:{color:"#8c909e"}},pie:{overlay:{gradient:"sharpBevel"}},donut:{overlay:{gradient:"sharpGlass"}},line:{markers:{background:"#212a33"}},bubble:{opacity:.6},scatter:{markers:{background:"#212a33"}},scatterLine:{markers:{background:"#212a33"}},area:{opacity:.3},candlestick:{downColor:"#757d87",line:{color:"#ea9d06"},border:{_brightness:1.5,opacity:1},highlight:{border:{color:o,opacity:.2}}},waterfall:{line:{color:"#8c909e"}},horizontalWaterfall:{line:{color:"#8c909e"}},ohlc:{line:{color:"#ea9d06"}}},chartArea:{background:"#212a33"},seriesColors:["#ffca08","#ff710f","#ed2e24","#ff9f03","#e13c02","#a00201"],axisDefaults:{line:{color:"#8c909e"},minorTicks:{color:"#8c909e"},majorTicks:{color:"#8c909e"},labels:{color:"#ffffff"},majorGridLines:{color:"#3e424d"},minorGridLines:{color:"#2f3640"},title:{color:"#ffffff"},crosshair:{color:"#8c909e"},notes:{icon:{background:"transparent",border:{color:"#8c909e"}},label:{color:"#ffffff"},line:{color:"#8c909e"}}}},gauge:{pointer:{color:"#f4af03"},scale:{rangePlaceholderColor:"#2f3640",labels:{color:o},minorTicks:{color:"#8c909e"},majorTicks:{color:"#8c909e"},line:{color:"#8c909e"}}},diagram:{shapeDefaults:{fill:{color:"#f3ae03"},connectorDefaults:{fill:{color:o},stroke:{color:"#414550"},hover:{fill:{color:"#414550"},stroke:{color:o}}},content:{color:o}},editable:{resize:{handles:{fill:{color:"#414550"},stroke:{color:o},hover:{fill:{color:o},stroke:{color:o}}}},rotate:{thumb:{stroke:{color:o},fill:{color:o}}}},selectable:{stroke:{color:o}},connectionDefaults:{stroke:{color:o},content:{color:o},selection:{handles:{fill:{color:"#414550"},stroke:{color:o}}}}},treeMap:{colors:[["#ffca08","#4e4b2b"],["#ff710f","#4e392d"],["#ed2e24","#4b2c31"],["#ff9f03","#4e422a"],["#e13c02","#482e2a"],["#a00201","#3b232a"]]}}),d("uniform",{chart:{title:{color:"#686868"},subtitle:{color:"#686868"},legend:{labels:{color:"#686868"},inactiveItems:{labels:{color:"#B6B6B6"},markers:{color:"#B6B6B6"}}},seriesDefaults:{labels:{color:"#686868"},errorBars:{color:"#686868"},notes:{icon:{background:"transparent",border:{color:"#9e9e9e"}},label:{color:"#686868"},line:{color:"#9e9e9e"}},pie:{overlay:{gradient:"sharpBevel"}},donut:{overlay:{gradient:"sharpGlass"}},line:{markers:{background:"#ffffff"}},bubble:{opacity:.6},scatter:{markers:{background:"#ffffff"}},scatterLine:{markers:{background:"#ffffff"}},area:{opacity:.3},candlestick:{downColor:"#cccccc",line:{color:"#cccccc"},border:{_brightness:1.5,opacity:1},highlight:{border:{color:"#cccccc",opacity:.2}}},waterfall:{line:{color:"#9e9e9e"}},horizontalWaterfall:{line:{color:"#9e9e9e"}},ohlc:{line:{color:"#cccccc"}}},chartArea:{background:"#ffffff"},seriesColors:["#527aa3","#6f91b3","#8ca7c2","#a8bdd1","#c5d3e0","#e2e9f0"],axisDefaults:{line:{color:"#9e9e9e"},minorTicks:{color:"#aaaaaa"},majorTicks:{color:"#888888"},labels:{color:"#686868"},majorGridLines:{color:"#dadada"},minorGridLines:{color:"#e7e7e7"},title:{color:"#686868"},crosshair:{color:"#9e9e9e"},notes:{icon:{background:"transparent",border:{color:"#9e9e9e"}},label:{color:"#686868"},line:{color:"#9e9e9e"}}}},gauge:{pointer:{color:"#527aa3"},scale:{rangePlaceholderColor:"#e7e7e7",labels:{color:"#686868"},minorTicks:{color:"#aaaaaa"},majorTicks:{color:"#888888"},line:{color:"#9e9e9e"}}},diagram:{shapeDefaults:{fill:{color:"#d1d1d1"},connectorDefaults:{fill:{color:"#686868"},stroke:{color:o},hover:{fill:{color:o},stroke:{color:"#686868"}}},content:{color:"#686868"}},editable:{resize:{handles:{fill:{color:o},stroke:{color:"#686868"},hover:{fill:{color:"#686868"},stroke:{color:"#686868"}}}},rotate:{thumb:{stroke:{color:"#686868"},fill:{color:"#686868"}}}},selectable:{stroke:{color:"#686868"}},connectionDefaults:{stroke:{color:"#686868"},content:{color:"#686868"},selection:{handles:{fill:{color:o},stroke:{color:"#686868"}}}}},treeMap:{colors:[["#527aa3","#d0d8e1"],["#6f91b3","#d6dde4"],["#8ca7c2","#dce1e7"],["#a8bdd1","#e2e6ea"],["#c5d3e0","#e7eaed"],["#e2e9f0","#edeff0"]]}}),d("bootstrap",{chart:{title:{color:"#333333"},subtitle:{color:"#333333"},legend:{labels:{color:"#333333"},inactiveItems:{labels:{color:"#999999"},markers:{color:"#9A9A9A"}}},seriesDefaults:{labels:{color:"#333333"},overlay:{gradient:"none"},errorBars:{color:"#343434"},notes:{icon:{background:"#000000",border:{color:"#000000"}},label:{color:"#333333"},line:{color:"#000000"}},pie:{overlay:{gradient:"none"}},donut:{overlay:{gradient:"none"}},line:{markers:{background:"#ffffff"}},bubble:{opacity:.6},scatter:{markers:{background:"#ffffff"}},scatterLine:{markers:{background:"#ffffff"}},area:{opacity:.8},candlestick:{downColor:"#d0d0d0",line:{color:"#333333"},border:{_brightness:1.5,opacity:1},highlight:{border:{color:"#b8b8b8",opacity:.2}}},waterfall:{line:{color:"#cccccc"}},horizontalWaterfall:{line:{color:"#cccccc"}},ohlc:{line:{color:"#333333"}}},chartArea:{background:"#ffffff"},seriesColors:["#428bca","#5bc0de","#5cb85c","#f2b661","#e67d4a","#da3b36"],axisDefaults:{line:{color:"#cccccc"},minorTicks:{color:"#ebebeb"},majorTicks:{color:"#cccccc"},labels:{color:"#333333"},majorGridLines:{color:"#cccccc"},minorGridLines:{color:"#ebebeb"},title:{color:"#333333"},crosshair:{color:"#000000"},notes:{icon:{background:"#000000",border:{color:"#000000"}},label:{color:"#ffffff"},line:{color:"#000000"}}}},gauge:{pointer:{color:"#428bca"},scale:{rangePlaceholderColor:"#cccccc",labels:{color:"#333333"},minorTicks:{color:"#ebebeb"},majorTicks:{color:"#cccccc"},line:{color:"#cccccc"}}},diagram:{shapeDefaults:{fill:{color:"#428bca"},connectorDefaults:{fill:{color:"#333333"},stroke:{color:o},hover:{fill:{color:o},stroke:{color:"#333333"}}},content:{color:"#333333"}},editable:{resize:{handles:{fill:{color:o},stroke:{color:"#333333"},hover:{fill:{color:"#333333"},stroke:{color:"#333333"}}}},rotate:{thumb:{stroke:{color:"#333333"},fill:{color:"#333333"}}}},selectable:{stroke:{color:"#333333"}},connectionDefaults:{stroke:{color:"#c4c4c4"},content:{color:"#333333"},selection:{handles:{fill:{color:o},stroke:{color:"#333333"}},stroke:{color:"#333333"}}}},treeMap:{colors:[["#428bca","#d1e0ec"],["#5bc0de","#d6eaf0"],["#5cb85c","#d6e9d6"],["#5cb85c","#f4e8d7"],["#e67d4a","#f2ddd3"],["#da3b36","#f0d0cf"]]}}),d("flat",{chart:{title:{color:"#4c5356"},subtitle:{color:"#4c5356"},legend:{labels:{color:"#4c5356"},inactiveItems:{labels:{color:"#CBCBCB"},markers:{color:"#CBCBCB"}}},seriesDefaults:{labels:{color:"#4c5356"},errorBars:{color:"#4c5356"},notes:{icon:{background:"transparent",border:{color:"#cdcdcd"}},label:{color:"#4c5356"},line:{color:"#cdcdcd"}},candlestick:{downColor:"#c7c7c7",line:{color:"#787878"}},area:{opacity:.9},waterfall:{line:{color:"#cdcdcd"}},horizontalWaterfall:{line:{color:"#cdcdcd"}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:["#10c4b2","#ff7663","#ffb74f","#a2df53","#1c9ec4","#ff63a5","#1cc47b"],axisDefaults:{line:{color:"#cdcdcd"},labels:{color:"#4c5356"},minorGridLines:{color:"#cdcdcd"},majorGridLines:{color:"#cdcdcd"},title:{color:"#4c5356"},crosshair:{color:"#cdcdcd"},notes:{icon:{background:"transparent",border:{color:"#cdcdcd"}},label:{color:"#4c5356"},line:{color:"#cdcdcd"}}}},gauge:{pointer:{color:"#10c4b2"},scale:{rangePlaceholderColor:"#cdcdcd",labels:{color:"#4c5356"},minorTicks:{color:"#4c5356"},majorTicks:{color:"#4c5356"},line:{color:"#4c5356"}}},diagram:{shapeDefaults:{fill:{color:"#10c4b2"},connectorDefaults:{fill:{color:"#363940"},stroke:{color:o},hover:{fill:{color:o},stroke:{color:"#363940"}}},content:{color:"#4c5356"}},editable:{resize:{handles:{fill:{color:o},stroke:{color:"#363940"},hover:{fill:{color:"#363940"},stroke:{color:"#363940"}}}},rotate:{thumb:{stroke:{color:"#363940"},fill:{color:"#363940"}}}},selectable:{stroke:{color:"#363940"}},connectionDefaults:{stroke:{color:"#cdcdcd"},content:{color:"#4c5356"},selection:{handles:{fill:{color:o},stroke:{color:"#363940"}},stroke:{color:"#363940"}}}},treeMap:{colors:[["#10c4b2","#cff3f0"],["#ff7663","#ffe4e0"],["#ffb74f","#fff1dc"],["#a2df53","#ecf9dd"],["#1c9ec4","#d2ecf3"],["#ff63a5","#ffe0ed"],["#1cc47b","#d2f3e5"]]}}),d("material",{chart:{title:{color:"#444444"},subtitle:{color:"#444444"},legend:{labels:{color:"#444444"},inactiveItems:{labels:{color:"#CBCBCB"},markers:{color:"#CBCBCB"}}},seriesDefaults:{labels:{color:"#444444"},errorBars:{color:"#444444"},notes:{icon:{background:"transparent",border:{color:"#e5e5e5"}},label:{color:"#444444"},line:{color:"#e5e5e5"}},candlestick:{downColor:"#c7c7c7",line:{color:"#787878"}},area:{opacity:.9},waterfall:{line:{color:"#e5e5e5"}},horizontalWaterfall:{line:{color:"#e5e5e5"}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:["#3f51b5","#03a9f4","#4caf50","#f9ce1d","#ff9800","#ff5722"],axisDefaults:{line:{color:"#e5e5e5"},labels:{color:"#444444"},minorGridLines:{color:"#e5e5e5"},majorGridLines:{color:"#e5e5e5"},title:{color:"#444444"},crosshair:{color:"#7f7f7f"},notes:{icon:{background:"transparent",border:{color:"#e5e5e5"}},label:{color:"#444444"},line:{color:"#e5e5e5"}}}},gauge:{pointer:{color:"#3f51b5"},scale:{rangePlaceholderColor:"#e5e5e5",labels:{color:"#444444"},minorTicks:{color:"#444444"},majorTicks:{color:"#444444"},line:{color:"#444444"}}},diagram:{shapeDefaults:{fill:{color:"#3f51b5"},connectorDefaults:{fill:{color:"#7f7f7f"},stroke:{color:o},hover:{fill:{color:o},stroke:{color:"#7f7f7f"}}},content:{color:"#444444"}},editable:{resize:{handles:{fill:{color:o},stroke:{color:"#444444"},hover:{fill:{color:"#444444"},stroke:{color:"#444444"}}}},rotate:{thumb:{stroke:{color:"#444444"},fill:{color:"#444444"}}}},selectable:{stroke:{color:"#444444"}},connectionDefaults:{stroke:{color:"#7f7f7f"},content:{color:"#444444"},selection:{handles:{fill:{color:o},stroke:{color:"#444444"}},stroke:{color:"#444444"}}}},treeMap:{colors:[["#3f51b5","#cff3f0"],["#03a9f4","#e5f6fe"],["#4caf50","#edf7ed"],["#f9ce1d","#fefae8"],["#ff9800","#fff4e5"],["#ff5722","#ffeee8"]]}}),d("materialblack",{chart:{title:{color:"#fff"},subtitle:{color:"#fff"},legend:{labels:{color:"#fff"},inactiveItems:{labels:{color:"#CBCBCB"},markers:{color:"#CBCBCB"}}},seriesDefaults:{labels:{color:"#fff"},errorBars:{color:"#fff"},notes:{icon:{background:"transparent",border:{color:"#e5e5e5"}},label:{color:"#fff"},line:{color:"#e5e5e5"}},candlestick:{downColor:"#c7c7c7",line:{color:"#787878"}},area:{opacity:.9},waterfall:{line:{color:"#4d4d4d"}},horizontalWaterfall:{line:{color:"#4d4d4d"}},overlay:{gradient:"none"},border:{_brightness:1}},chartArea:{background:"#1c1c1c"},seriesColors:["#3f51b5","#03a9f4","#4caf50","#f9ce1d","#ff9800","#ff5722"],axisDefaults:{line:{color:"#4d4d4d"},labels:{color:"#fff"},minorGridLines:{color:"#4d4d4d"},majorGridLines:{color:"#4d4d4d"},title:{color:"#fff"},crosshair:{color:"#7f7f7f"},notes:{icon:{background:"transparent",border:{color:"#4d4d4d"}},label:{color:"#fff"},line:{color:"#4d4d4d"}}}},gauge:{pointer:{color:"#3f51b5"},scale:{rangePlaceholderColor:"#4d4d4d",labels:{color:"#fff"},minorTicks:{color:"#fff"},majorTicks:{color:"#fff"},line:{color:"#fff"}}},diagram:{shapeDefaults:{fill:{color:"#3f51b5"},connectorDefaults:{fill:{color:"#7f7f7f"},stroke:{color:o},hover:{fill:{color:o},stroke:{color:"#7f7f7f"}}},content:{color:"#fff"}},editable:{resize:{handles:{fill:{color:o},stroke:{color:"#fff"},hover:{fill:{color:"#fff"},stroke:{color:"#fff"}}}},rotate:{thumb:{stroke:{color:"#fff"},fill:{color:"#fff"}}}},selectable:{stroke:{color:"#fff"}},connectionDefaults:{stroke:{color:"#7f7f7f"},content:{color:"#fff"},selection:{handles:{fill:{color:o},stroke:{color:"#fff"}},stroke:{color:"#fff"}}}},treeMap:{colors:[["#3f51b5","#cff3f0"],["#03a9f4","#e5f6fe"],["#4caf50","#edf7ed"],["#f9ce1d","#fefae8"],["#ff9800","#fff4e5"],["#ff5722","#ffeee8"]]}}),function(){var e="#333333",t="#7f7f7f",n="#bdbdbd",i="#c8c8c8",r=["#008fd3","#99d101","#f39b02","#f05662","#c03c53","#acacac"],a=r[0],s=o;function l(){return{icon:{background:"#007cc0",border:{color:"#007cc0"}},label:{color:"#ffffff"},line:{color:i}}}d("fiori",{chart:{title:{color:e},subtitle:{color:e},legend:{labels:{color:e},inactiveItems:{labels:{color:t},markers:{color:t}}},seriesDefaults:{labels:{color:e},errorBars:{color:e},notes:l(),candlestick:{downColor:i,line:{color:n}},area:{opacity:.8},waterfall:{line:{color:i}},horizontalWaterfall:{line:{color:i}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:r,axisDefaults:{line:{color:i},labels:{color:e},minorGridLines:{color:"#dddddd"},majorGridLines:{color:i},title:{color:e},crosshair:{color:t},notes:l()}},gauge:{pointer:{color:a},scale:{rangePlaceholderColor:i,labels:{color:e},minorTicks:{color:e},majorTicks:{color:e},line:{color:e}}},diagram:{shapeDefaults:{fill:{color:a},connectorDefaults:{fill:{color:e},stroke:{color:s},hover:{fill:{color:s},stroke:{color:e}}},content:{color:e}},editable:{resize:{handles:{fill:{color:s},stroke:{color:n},hover:{fill:{color:n},stroke:{color:n}}}},rotate:{thumb:{stroke:{color:n},fill:{color:n}}}},selectable:{stroke:{color:n}},connectionDefaults:{stroke:{color:n},content:{color:n},selection:{handles:{fill:{color:s},stroke:{color:n}},stroke:{color:n}}}},treeMap:{colors:u(r,["#cbe8f5","#eaf5cb","#fceacc","#fbdcdf","#f2d7dc","#eeeeee"])}})}(),function(){var e="#4e4e4e",t="#7f7f7f",n="#bdbdbd",i="#c8c8c8",r=["#0072c6","#5db2ff","#008a17","#82ba00","#ff8f32","#ac193d"],a=r[0],s=o;function l(){return{icon:{background:"#00b0ff",border:{color:"#00b0ff"}},label:{color:"#ffffff"},line:{color:i}}}d("office365",{chart:{title:{color:e},subtitle:{color:e},legend:{labels:{color:e},inactiveItems:{labels:{color:t},markers:{color:t}}},seriesDefaults:{labels:{color:e},errorBars:{color:e},notes:l(),candlestick:{downColor:i,line:{color:n}},area:{opacity:.8},waterfall:{line:{color:i}},horizontalWaterfall:{line:{color:i}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:r,axisDefaults:{line:{color:i},labels:{color:e},minorGridLines:{color:"#e5e5e5"},majorGridLines:{color:i},title:{color:e},crosshair:{color:t},notes:l()}},gauge:{pointer:{color:a},scale:{rangePlaceholderColor:i,labels:{color:e},minorTicks:{color:e},majorTicks:{color:e},line:{color:e}}},diagram:{shapeDefaults:{fill:{color:a},connectorDefaults:{fill:{color:e},stroke:{color:s},hover:{fill:{color:s},stroke:{color:e}}},content:{color:e}},editable:{resize:{handles:{fill:{color:s},stroke:{color:n},hover:{fill:{color:n},stroke:{color:n}}}},rotate:{thumb:{stroke:{color:n},fill:{color:n}}}},selectable:{stroke:{color:n}},connectionDefaults:{stroke:{color:n},content:{color:n},selection:{handles:{fill:{color:s},stroke:{color:n}},stroke:{color:n}}}},treeMap:{colors:u(r,["#cbe2f3","#deeffe","#cbe7d0","#e5f0cb","#fee8d5","#eed0d7"])}})}(),function(){var e="#32364c",t="#7f7f7f",n="#bdbdbd",i="#dfe0e1",r=["#ff4350","#ff9ea5","#00acc1","#80deea","#ffbf46","#ffd78c"],a=r[0],s=o;function l(){return{icon:{background:"#007cc0",border:{color:"#007cc0"}},label:{color:"#ffffff"},line:{color:i}}}d("nova",{chart:{title:{color:e},subtitle:{color:e},legend:{labels:{color:e},inactiveItems:{labels:{color:t},markers:{color:t}}},seriesDefaults:{labels:{color:e},errorBars:{color:e},notes:l(),candlestick:{downColor:i,line:{color:n}},area:{opacity:.8},waterfall:{line:{color:i}},horizontalWaterfall:{line:{color:i}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:r,axisDefaults:{line:{color:i},labels:{color:e},minorGridLines:{color:"#dfe0e1"},majorGridLines:{color:i},title:{color:e},crosshair:{color:e},notes:l()}},gauge:{pointer:{color:a},scale:{rangePlaceholderColor:i,labels:{color:e},minorTicks:{color:e},majorTicks:{color:e},line:{color:e}}},diagram:{shapeDefaults:{fill:{color:a},connectorDefaults:{fill:{color:e},stroke:{color:s},hover:{fill:{color:s},stroke:{color:e}}},content:{color:e}},editable:{resize:{handles:{fill:{color:s},stroke:{color:n},hover:{fill:{color:n},stroke:{color:n}}}},rotate:{thumb:{stroke:{color:n},fill:{color:n}}}},selectable:{stroke:{color:n}},connectionDefaults:{stroke:{color:n},content:{color:n},selection:{handles:{fill:{color:s},stroke:{color:n}},stroke:{color:n}}}},treeMap:{colors:u(r,["#ffd9dc","#ffeced","#cceef3","#e6f8fb","#fff2da","#fff7e8"])}})}(),d("default-v2",{chart:{},gauge:{},diagram:{},treeMap:{colors:u(["#ff6358","#ffd246","#78d237","#28b4c8","#2d73f5","#aa46be"],["#ffd9dc","#ffeced","#cceef3","#e6f8fb","#fff2da","#fff7e8"])}}),c.sass=c["default-v2"],function(){var e="#292b2c",t=["#0275d8","#5bc0de","#5cb85c","#f0ad4e","#e67d4a","#d9534f"];d("bootstrap-v4",{chart:{},gauge:{pointer:{color:t[0]},scale:{rangePlaceholderColor:"rgba(0, 0, 0, .04)",labels:{color:e},minorTicks:{color:e},majorTicks:{color:e},line:{color:e}}},diagram:{},treeMap:{colors:u(t,["#ffd9dc","#ffeced","#cceef3","#e6f8fb","#fff2da","#fff7e8"])}})}()}(window.kendo.jQuery);kendo;!function(e){window.kendo.dataviz=window.kendo.dataviz||{};var t=kendo.dataviz,n=kendo.ui,i=n.Widget,r=ps,o=fo,a=vs;class s extends nl{constructor(){super(...arguments);var e=this.options,t=this.options.endColor,n=this.options.startColor,i=Math.abs(e.newAngle-e.oldAngle)/e.duration*1e3;e.duration=o(i,150,800),n!==t&&(this.startColor=new kendo.Color(n),this.color=new kendo.Color(t))}step(e){var t=this,n=t.options,i=t.startColor,r=t.color,o=nR(n.oldAngle,n.newAngle,e);if(this.element.geometry().setEndAngle(o),r){var a=xR(nR(i.r,r.r,e)),s=xR(nR(i.g,r.g,e)),l=xR(nR(i.b,r.b,e));this.element.stroke(new kendo.Color(a,s,l).toHex())}}}var l=i.extend({init:function(e,n){i.fn.init.call(this,e,n),this.theme=function(e){var n=t.ui.themes||{},i=e.theme||"",r=i.toLowerCase();if(-1!=t.SASS_THEMES.indexOf(r))return t.autoTheme().gauge;return(n[i]||n[r]||{}).gauge}(this.options),this._value=this.options.value,this.element.addClass("k-gauge"),this.redraw(),this._centerTemplate(),this._aria()},options:{name:"CircularProgressBar",ariaRole:!1,theme:"sass",centerTemplate:"",color:"",colors:[],transitions:!0,pointerWidth:5,indeterminate:!1,label:null,labelId:null},events:[],value:function(e){var t=this;if(undefined===e)return t._value;e=t._restrictValue(e),t._centerSvgElements(),t._pointerChange(t._value,e),t._value=e,t._centerTemplate(),t._updateProgress()},redraw:function(){this._initSurface(),this._buildVisual(),this._draw()},resize:function(){var e=this.options.transitions;this.options.transitions=!1,this._initSurface(),this._buildVisual(),this._draw(),this._centerTemplate(),this.options.transitions=e},destroy:function(){var e=this;e.announce&&e.announce.remove(),i.fn.destroy.call(e)},_aria:function(){var t=this,n=t.options,i=t.value()||0,r=t.element;n.ariaRole&&(r.attr({role:"progressbar"}),n.indeterminate||r.attr({"aria-valuemin":0,"aria-valuemax":100}),n.labelId?r.attr("aria-labelledby",n.labelId):n.label&&r.attr("aria-label",n.label),t.announce=e('<span aria-live="polite" class="k-sr-only k-progress-announce"></span>'),t.announce.appendTo(e("body")),n.indeterminate?t.announce.text("Loading..."):(r.attr("aria-valuenow",i),t.announce.text(i+"%")))},_restrictValue:function(e){return e<0?0:e>100?100:e},_updateProgress:function(){var e=this,t=e.options,n=e.value()||0;t.ariaRole&&!t.indeterminate&&(e.element.attr("aria-valuenow",n),e.announce&&e.announce.text(n+"%"))},_centerSvgElements:function(){var e=this._getCenter();this.circle._geometry.center.x===e.x&&this.circle._geometry.center.y===e.y||(this.circle._geometry.center.x=e.x,this.circle._geometry.center.y=e.y,this.arc._geometry.center.x=e.x,this.arc._geometry.center.y=e.y,this.circle.geometryChange(),this.arc.geometryChange())},_centerTemplate:function(){var e,t,n;this.options.centerTemplate?(t=kendo.template(this.options.centerTemplate),(n=this._getCenterElement()).html(t({color:this._getColor(this.value()),value:this.value()})),e=this._centerTemplatePosition(n.width(),n.height()),n.css(e)):this._centerElement&&(this._centerElement.remove(),this._centerElement=null)},_getCenterElement:function(){var t=this._centerElement;return t||(t=this._centerElement=e("<div></div>").addClass("k-arcgauge-label"),this.element.append(t)),t},_pointerChange:function(e,t){let n;this.options.transitions?(n=new s(this.arc,{oldAngle:this._slotAngle(e),startColor:this._getColor(e),newAngle:this._slotAngle(t),endColor:this._getColor(t)}),n.play()):(this.arc.stroke(this._getColor(t)),this.arc.geometry().setEndAngle(this._slotAngle(t)))},_draw:function(){let t,n,i,r=this.surface;r.clear(),r.draw(this._visuals),this.options.indeterminate?(t=e(r.element).find("path"),n=this._getCenter(),t[0].innerHTML=kendo.format('<animateTransform attributeName="transform" type="rotate" from="0 {0} {1}" to="360 {0} {1}" dur="1s" repeatCount="indefinite" />',n.x,n.y)):this.options.transitions&&(i=new s(this.arc,{oldAngle:this._slotAngle(0),startColor:this._getColor(0),newAngle:this._slotAngle(this.value()),endColor:this._getColor(this.value())}),i.play())},_buildVisual:function(){var e=this._visuals=new a,t=this._getCenter(),n=this._getColor(this.value())||this.theme.pointer.color,i=Math.min(t.x,t.y)-5-this.options.pointerWidth,r=new oa([t.x,t.y],i+this.options.pointerWidth/2),o=this.circle=new ua(r,{fill:{color:"none"},stroke:{color:this.theme.scale.rangePlaceholderColor,width:this.options.pointerWidth}});e.append(o),this.options.indeterminate?this.arc=this._createArc(360,i,t,n):this.arc=this._createArc(this._slotAngle(this.value()),i,t,n),e.append(this.arc)},_slotAngle:function(e){return(e-0)/100*360+90+180},_getColor:function(e){var n=this.options,i=n.colors,r=n.color,o=t.isNumber(e)?e:0;if(i)for(var a=0;a<i.length;a++){var s=i[a],l=s.color,c=s.from;void 0===c&&(c=0);var d=s.to;if(void 0===d&&(d=100),c<=o&&o<=d)return l}return r},_createArc:function(e,t,n,i){var o=this.options.pointerWidth,a=new ga([n.x,n.y],{radiusX:t+o/2,radiusY:t+o/2,startAngle:270,endAngle:e});return new r(a,{stroke:{width:o,color:this.options.color||i,opacity:this.options.opacity}})},_centerTemplatePosition:function(e,t){var n,i,r=this._getSize(),o=this._getCenter(),a=o.x-e/2,s=o.y-t/2;return e<r.width&&(n=a+e,a=Math.max(a,0),n>r.width&&(a-=n-r.width)),t<r.height&&(i=s+t)>r.height&&(s-=i-r.height),{left:a,top:s}},_getCenter:function(){var e=this._getSize();return new t.Point(e.width/2,e.height/2)},_getSize:function(){var e=this.element,t=200,n=200,i=e[0].offsetWidth,r=e[0].offsetHeight;return i||(i=t),r||(r=n),{width:i,height:r}},_surfaceElement:function(){return this.surfaceElement||(this.surfaceElement=document.createElement("div"),this.element[0].appendChild(this.surfaceElement)),this.surfaceElement},_initSurface:function(){var e=this.options,n=this.surface,i=this._surfaceElement(),r=this._getSize();t.elementSize(i,r),n?(this.surface.clear(),this.surface.resize()):this.surface=vc.create(i,{type:e.renderAs})}});n.plugin(l)}(window.kendo.jQuery);kendo;window.kendo=window.kendo||{},window.kendo.inputs=window.kendo.inputs||{},function(e,t){var n=t.util,i=n.elementOffset,r=n.limitValue,o=kendo.geometry.Point,a=kendo.geometry.Rect,s=kendo.geometry.transform,l=function(){},c=function(){function e(e,t){void 0===t&&(t={}),this.element=e,this.lastMoveTime=0,this.options=Object.assign({scale:1,precision:1,samplingRate:200,smooth:!1!==t.smooth,color:t.color||"#000",backgroundColor:t.backgroundColor||"#fff",strokeWidth:1,onChange:l,onDraw:l,onDrawEnd:l},t),this.pathOptions={stroke:{color:this.options.color,width:this.options.strokeWidth,lineCap:"round",lineJoin:"round"}},this.initSurface(),this.attachEvents()}return e.prototype.destroy=function(){this.detachEvents()},e.prototype.clear=function(){this.rootGroup.clear(),this.path=null},Object.defineProperty(e.prototype,"isDrawing",{get:function(){return Boolean(this.points)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"pathData",{get:function(){var e;return null===(e=this.path)||void 0===e?void 0:e.toString(3)},set:function(e){this.clear(),this.path=t.MultiPath.parse(e,this.pathOptions),this.rootGroup.append(this.path)},enumerable:!1,configurable:!0}),e.prototype.loadImage=function(e,n){if(void 0===n&&(n=[]),e){var i=this.size,r=i[0],o=i[1],a=r/this.options.scale,l=o/this.options.scale,c=n[0]||6*a,d=n[1]||6*l,u=a/c,h=l/d,p=Math.min(u,h),f=new t.Image(e,new kendo.geometry.Rect([0,0],[c,d]));f.transform(s().scale(p,p)),this.clear(),this.rootGroup.append(f)}else this.clear()},e.prototype.exportImage=function(e){var n,i=this.size,r=i[0],o=i[1],l=r/this.options.scale,c=o/this.options.scale,d=(null==e?void 0:e.width)||6*l,u=(null==e?void 0:e.height)||6*c,h=d/l,p=u/c,f=Math.min(h,p),m=new a([0,0],[d,u]),g=new t.Group({clip:t.Path.fromRect(m)}),v=new t.Group({transform:s().scale(f,f)}),_=t.Path.fromRect(m,{fill:{color:this.options.backgroundColor}});return g.append(_),g.append(v),(n=v.children).push.apply(n,this.rootGroup.children),t.exportImage(g,Object.assign({width:d,height:u},e))},e.prototype.resize=function(){this.surface.resize(!0)},e.prototype.setOptions=function(e){Object.assign(this.options,e),this.pathOptions.stroke.color=this.options.color,this.pathOptions.stroke.width=this.options.strokeWidth,this.path&&(this.path.options.set("stroke.color",this.options.color),this.path.options.set("stroke.width",this.options.strokeWidth)),this.background.options.set("fill.color",this.options.backgroundColor)},e.prototype.initSurface=function(){this.surface=t.Surface.create(this.element,{type:"canvas"}),this.element.style.touchAction="none";var e=this.options.scale;this.rootGroup=new t.Group({transform:s().scale(e,e)});var n=this.element.offsetWidth||750,i=this.element.offsetHeight||250;this.size=[n,i],this.background=t.Path.fromRect(new a([0,0],this.size),{fill:{color:this.options.backgroundColor}}),this.surface.draw(this.background),this.surface.draw(this.rootGroup)},e.prototype.attachEvents=function(){this.onPointerDown=this.onPointerDown.bind(this),this.onPointerMove=this.onPointerMove.bind(this),this.onPointerUp=this.onPointerUp.bind(this),this.element.addEventListener("pointerdown",this.onPointerDown),this.element.addEventListener("pointermove",this.onPointerMove),this.element.addEventListener("pointerup",this.onPointerUp)},e.prototype.detachEvents=function(){this.element.removeEventListener("pointerdown",this.onPointerDown),this.element.removeEventListener("pointermove",this.onPointerMove),this.element.removeEventListener("pointerup",this.onPointerUp)},e.prototype.touchPoint=function(e){var t=i(this.element),n=e.pageX,r=e.pageY,a=1/this.options.scale;return new o(n-t.left,r-t.top).scale(a,a)},e.prototype.onPointerDown=function(e){if(!this.options.readonly&&e.isPrimary&&function(e){return"number"!=typeof e.button||0===e.button}(e)){this.path||(this.path=new t.MultiPath(this.pathOptions),this.rootGroup.append(this.path)),this.options.onDraw(),this.element.setPointerCapture(e.pointerId);var n=this.touchPoint(e);this.points=[n],this.path.moveTo(n)}},e.prototype.onPointerMove=function(e){if(this.points&&e.isPrimary){var t=(new Date).getTime();if(!(t-this.lastMoveTime<1e3/r(this.options.samplingRate,1,1e4))){this.lastMoveTime=t;var n=this.touchPoint(e),i=this.points[this.points.length-1],o=1/r(this.options.precision,.01,100);n.distanceTo(i)<o||(this.points.push(n),this.path.lineTo(n))}}},e.prototype.onPointerUp=function(e){if(e.isPrimary&&this.path&&this.points&&!this.options.readonly){if(this.options.smooth){var n=t.Path.curveFromPoints(this.points);this.path.paths.splice(this.path.paths.length-1,1,n)}this.points=null,this.options.onDrawEnd(),this.options.onChange(this.pathData)}},e}();e.SignaturePad=c}(window.kendo.inputs.common=window.kendo.inputs.common||{},window.kendo.drawing);!function(e){var t=window.kendo,n=t.ui.Widget,i=t.ui.Dialog,r=t.html,o=t._outerWidth,a=t._outerHeight,s=t.inputs.common.SignaturePad,l=".kendoSignature",c="change",d="open",u="close",h="click",p=n.extend({init:function(e,t){var i=this;t=t||{},n.fn.init.call(i,e,t),i._createElements(i.element,i.options.maximizable?"maxi":"",!1,1),i._createInput(),i.wrapper=i.element,i.options.backgroundColor||(i.options.backgroundColor=getComputedStyle(i.element[0]).backgroundColor||"#ffffff"),i._createPad(),i._createDialogPad(),i._attachHandlers(),i._assignLabel(),i.options.value&&(i._pad.loadImage(i.options.value),i._dialogPad.loadImage(i.options.value)),i.options.readonly&&i.readonly(),i.options.enable||i.enable(!1)},options:{name:"Signature",color:"#000000",enable:!0,fillMode:"solid",hideLine:!1,label:"",maximizable:!0,popupScale:3,readonly:!1,rounded:"medium",size:"medium",smooth:!1,strokeWidth:1,exportScale:2,value:""},events:[c,d,u],setOptions:function(n){var i,r=this.options,o=t.getValidCssClass("k-button-","size",r.size),a=this.element.add(this._dialogPadEl).find("."+o),s=e(this._pad.element).add(this._dialogPad.element);a.removeClass(o),this._clearCssClasses(r),this.element.removeClass(t.getValidCssClass("k-signature-","size",r.size)),t.deepExtend(r,n),this.options=r,this.element.width(r.width),this.element.height(r.height),this._dialogPadEl.width(r.width*r.popupScale),this._dialogPadEl.height(r.height*r.popupScale),i=this._pad.path,this._destroyPad(),this._destroyDialog(),this._createPad(),this._createDialogPad(),function(e,n){if(!n||!n.paths||!n.paths.length)return;e.path=new t.drawing.MultiPath(e.pathOptions),e.rootGroup.append(e.path);for(var i=0;i<n.paths.length;i++)e.path.paths.push(n.paths[i]);e.options.onChange()}(this._pad,i),this.enable(r.enable),this.readonly(r.readonly),this._hideLine(this.element),this._hideLine(this._dialogPadEl),this._applyCssClasses(this.element),this.element.find(".k-signature-maximize").toggle(r.maximizable),this.element.removeClass(t.getValidCssClass("k-input-","size",this.options.size)),this.element.addClass(t.getValidCssClass("k-signature-","size",this.options.size)),a.addClass(t.getValidCssClass("k-button-","size",r.size)),s.removeAttr("aria-label"),this._assignLabel()},close:function(){this._dialog&&this._dialog.close()},open:function(){this.options.maximizable&&this._dialog&&this._dialog.open()},destroy:function(){var e=this;e._destroyPad(),e._destroyDialog(),e.element.off(l),e.element.empty(),n.fn.destroy.call(e)},enable:function(e){(e=!1!==e)||this._dialog.close(),this.element.find(".k-button").toggle(e),this.element.toggleClass("k-disabled",!e),this._pad.options.readonly=!e,this._dialogPad.options.readonly=!e},readonly:function(t){var n=this;t=!1!==t;n._pad.options.readonly=t,n._dialogPad.options.readonly=t,n.element.find(".k-signature-clear").length||t||(e(r.renderButton('<button class="k-signature-action k-signature-clear"></button>',{icon:"x",size:this.options.size,fillMode:"flat"})).insertAfter(n.element.find(".k-signature-actions-bottom")),e(r.renderButton('<button class="k-signature-action k-signature-clear"></button>',{icon:"x",size:this.options.size,fillMode:"flat"})).insertAfter(n._dialogEl.find(".k-signature-actions-bottom"))),n.element.find(".k-signature-clear").toggle(!t),n._dialogEl.find(".k-signature-clear").toggle(!t)},value:function(e){return undefined!==e&&(this._value=e,this._input.val(e),this._pad.loadImage(e)),this._value},reset:function(){this._dialogPad.clear(),this._pad.clear(),this._value=""},_assignLabel:function(){var t=e(this._pad.element).add(this._dialogPad.element);this.options.label?t.attr("aria-label",this.options.label):this._ariaLabel(t),this.element.removeAttr("aria-labelledby")},_attachHandlers:function(){var e=this;e.element.on(h+l,".k-signature-clear",(function(){e.reset()})).on(h+l,".k-signature-maximize",(function(){e._dialog.open(),e._dialog.wrapper.find(".k-signature-minimize").trigger("focus")}))},_createInput:function(){var t=this,n=t.element.attr("name"),i=t.element.attr("autocomplete"),r=t.element.attr("required");t._input=e("<input class='k-hidden' aria-hidden='true'/>").appendTo(t.element),n&&(t._input.attr("name",n),t.element.removeAttr("name")),i&&(t._input.attr("autocomplete",i),t.element.removeAttr("autocomplete")),r&&(t._input.attr("required",r),t.element.removeAttr("required"))},_destroyPad:function(){this._pad&&(t.destroy(this.element.find(".k-signature-canvas")),this._pad=null,this.element.find(".k-signature-canvas").empty())},_destroyDialog:function(){this._dialogPad&&(this._dialogPad.destroy(),this._dialogPad=null,this._dialogEl.off(l),this._dialog.destroy(),this._dialog=null,this._dialogEl.remove(),this._dialogEl=null)},_hideLine:function(t){var n=t.find(".k-signature-line");this.options.hideLine||n.length||e("<div class='k-signature-line'>").appendTo(t),this.options.hideLine&&n.remove()},_createElements:function(n,i,o,a){e("<div class='k-signature-canvas' role='img' tabindex='0'>").appendTo(n),this._hideLine(n),e("<div class='k-signature-actions k-signature-actions-top'></div>").appendTo(n),"mini"==i&&e(r.renderButton('<button class="k-signature-action k-signature-minimize k-rotate-180" aria-label="Minimize signature"></button>',{icon:"hyperlink-open",size:this.options.size,fillMode:"flat"})).appendTo(n.find(".k-signature-actions-top")),"maxi"==i&&e(r.renderButton('<button class="k-signature-action k-signature-maximize" aria-label="Maximize signature"></button>',{icon:"hyperlink-open",size:this.options.size,fillMode:"flat"})).appendTo(n.find(".k-signature-actions-top")),e("<div class='k-signature-actions k-signature-actions-bottom'></div>").appendTo(n),this.options.readonly||e(r.renderButton('<button class="k-signature-action k-signature-clear"  aria-label="Clear signature"></button>',{icon:"x",size:this.options.size,fillMode:"flat"})).appendTo(n.find(".k-signature-actions-bottom")),n.addClass("k-input k-signature"),n.width(this.options.width*a),n.height(this.options.height*a),o&&n.addClass("k-signature-maximized"),this._applyCssClasses(n),n.removeClass(t.getValidCssClass("k-input-","size",this.options.size)),n.addClass(t.getValidCssClass("k-signature-","size",this.options.size))},_createPad:function(){var t=this,n=e.extend(!0,{},t.options,{onChange:function(){var e=o(t.element,!1),n=a(t.element,!1);t._pad.exportImage({width:e*t.options.exportScale,height:n*t.options.exportScale}).then((function(e){t._value=e,t._input.val(e),t.trigger(c)})),t._pad.exportImage({width:e*t.options.exportScale*t.options.popupScale,height:n*t.options.exportScale*t.options.popupScale}).then((function(e){t._dialogPad.loadImage(e)}))},onDraw:function(){t.element.find(".k-button").hide()},onDrawEnd:function(){t.element.find(".k-button").show()}});t._pad=new s(t.element.find(".k-signature-canvas")[0],n)},_createDialogPad:function(){var n,r=this;r._dialogEl=e("<div>").appendTo(r.element),r._dialog=new i(r._dialogEl,{title:!1,closable:!1,open:function(){r.trigger(d)},close:function(){r.trigger(u)}}),r._dialogEl.removeAttr("tabindex").on("keydown",(function(e){e.keyCode===t.keys.ESC&&r._dialog.close()})),r._dialogPadEl=e("<div>").appendTo(r._dialog.element),r._createElements(r._dialogPadEl,"mini",!0,this.options.popupScale),n=r._dialogPadEl.find(".k-signature-canvas")[0],r._dialogPad=new s(n,e.extend(!0,{},r.options,{scale:r.options.popupScale,onChange:function(){var e=o(r.element,!1),t=a(r.element,!1);r._dialogPad.exportImage({width:e*r.options.exportScale,height:t*r.options.exportScale}).then((function(e){r._pad.loadImage(e),r._value=e,r._input.val(e),r.trigger(c)}))},onDraw:function(){r._dialogEl.find(".k-button").hide()},onDrawEnd:function(){r._dialogEl.find(".k-button").show()}})),r._dialog.close(),r._dialogEl.on(h+l,".k-signature-clear",(function(){r.reset()})).on(h+l,".k-signature-minimize",(function(){r._dialog.close()}))}});t.cssProperties.registerPrefix("Signature","k-input-"),t.ui.plugin(p)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.ui,i=t.htmlEncode,r=n.Widget,o=t.html,a=e.extend,s=t.mediaQuery,l="k-focus",c=t.keys,d=".kendoTimeSelector",u=(o=t.html,({value:e})=>`<li class='k-item' data-value='${i(e)}'><span>${i(e)}</span></li>`),h=r.extend({init:function(e,n){var i=this;r.fn.init.call(i,e,n),i.bigScreenMQL=s("large"),i.smallScreenMQL=s("small"),"auto"==i.options.adaptiveMode&&i.smallScreenMQL.onChange((function(){i.popup&&t.isFunction(i.popup.fullscreen)&&i.popup.fullscreen(i.smallScreenMQL.mediaQueryList.matches)})),i._wrappers(),i._buttons(),i._attchHandlers(),i._shortCuts(),i._columns(),i._popup()},options:{name:"TimeSelector",columns:[],shortcuts:[],adaptiveMode:"none",size:"medium",fillMode:"solid",rounded:"medium",messages:{set:"Set",cancel:"Cancel",days:"Days",hours:"Hours",minutes:"Minutes",milliseconds:"Milliseconds",seconds:"Seconds"}},events:["change"],addTranslate:function(){for(var e,t,n,i,r,o=this._listsContainer.find(".k-time-container.k-content.k-scrollable"),a=o.length,s=0;s<a;s++)t=p((e=o.eq(s)).find(".k-item:visible").eq(0)),i="translateY("+((n=e.outerHeight())-t)/2+"px)",r=n-t,e.find("ul").css({transform:i,"-ms-transform":i}),e.find(".k-scrollable-placeholder").css({height:e.find("ul").height()+r}),e.off(d).on("click"+d,".k-item",this._itemClickHandler.bind(this)).on("scroll"+d,this._listScrollHandler.bind(this))},applyValue:function(n){if(n){var i=this,r=this._listsContainer.find(".k-time-container.k-content.k-scrollable"),o=function(e){var t,n=Math.floor(e/864e5);t=e%864e5;var i=Math.floor(t/36e5);t=e%36e5;var r=Math.floor(t/6e4);t=e%6e4;var o=Math.floor(t/1e3);return t=e%1e3,{days:n,hours:i,minutes:r,seconds:o,milliseconds:t}}(n);r.each((function(n,r){var a=i.options.columns[n],s=o[a.name];s>=a.min&&s<=a.max&&i._scrollListToPosition(e(r),t.format(a.selectorFormat,s))}))}},toggle:function(){this.popup.toggle()},destroy:function(){this._listContainer.off(d),this._timeSelectorWrapper.off(d),this.popup&&(this.popup.destroy(),this.popup=null),this.bigScreenMQL&&this.bigScreenMQL.destroy(),this.smallScreenMQL&&this.smallScreenMQL.destroy()},_attchHandlers:function(){var e=this;e._listContainer.on("keydown"+d,this._scrollerKeyDownHandler.bind(this)),e._timeSelectorWrapper.on("click"+d,".k-time-fast-selection button",this._applyShortCut.bind(this)),e._timeSelectorWrapper.on("click"+d,".k-timeduration-footer button.k-time-cancel",this._cancelClickHandler.bind(this)),e._timeSelectorWrapper.on("click"+d,".k-timeduration-footer button.k-time-accept",this._setClickHandler.bind(this)),e._listContainer.on("mouseover"+d,".k-time-list-wrapper",this._mouseOverHandler.bind(this))},_applyShortCut:function(n){n.preventDefault(),this._value=parseInt(e(n.currentTarget).attr(t.attr("value"))),this.options.change(this._value),this.popup.close(),this.options.focus()},_scrollerKeyDownHandler:function(n){var i=this,r=n.keyCode,o=e(n.currentTarget).find(".k-time-list-wrapper.k-focus"),a=i._listContainer.find(".k-time-list-wrapper"),s=a.length,l=a.index(o),d=t.support.isRtl(i.wrapper),u=p(o.find(".k-item:visible").eq(0)),h=o.find(".k-time-container.k-content.k-scrollable");if(o.length)return r!=c.UP&&r!=c.DOWN||!n.altKey?void(r==c.RIGHT&&!d||r==c.LEFT&&d?l+1<s&&i._focusList(a.eq(l+1)):r==c.LEFT&&!d||r==c.RIGHT&&d?l-1>=0&&i._focusList(a.eq(l-1)):r==c.UP?(h.scrollTop(h.scrollTop()-u),n.preventDefault()):r==c.DOWN?(h.scrollTop(h.scrollTop()+u),n.preventDefault()):r===c.ENTER?i._setClickHandler(n):r===c.ESC&&i._cancelClickHandler(n)):(n.preventDefault(),i.toggle(),void setTimeout((function(){i.popup.visible()||i.options.focus()}),100))},_mouseOverHandler:function(t){this._focusList(e(t.currentTarget))},_focusList:function(e){this._listContainer.find(".k-time-list-wrapper").removeClass(l),e.addClass(l),this._listContainer.trigger("focus"),this._scrollTop=e.find(".k-scrollable").scrollTop()},_setClickHandler:function(n){e(t._activeElement()).attr(t.attr("value"))||(n.preventDefault(),this._value=function(e){return 864e5*(e.days||0)+36e5*(e.hours||0)+6e4*(e.minutes||0)+1e3*(e.seconds||0)+(e.milliseconds||0)}(this._currentValues),this.options.change(this._value),this.popup.close(),this.options.focus())},_cancelClickHandler:function(n){e(t._activeElement()).attr(t.attr("value"))||(n.preventDefault(),this.popup.close(),this.options.focus())},_itemClickHandler:function(t){var n=e(t.originalEvent.currentTarget),i=n.find(".k-item:visible").index(e(t.currentTarget)),r=p(n.find(".k-item:visible").eq(0));n.scrollTop(i*r)},_listScrollHandler:function(t){var n=this,i=p(e(t.currentTarget).find(".k-item:visible").eq(0));n._internalScroll||(n._scrollingTimeout&&clearTimeout(n._scrollingTimeout),n._scrollingTimeout=setTimeout((function(){t.currentTarget.scrollTop%i>1&&(t.currentTarget.scrollTop+=i-t.currentTarget.scrollTop%i),n._scrollTop=t.currentTarget.scrollTop,n._updateCurrentlySelected()}),100))},_findSelectedValue:function(e){var t,n,i=(t=e.scrollTop(),n=p(e.find(".k-item:visible").eq(0)),Math.max(Math.round(t/n),0));return e.find(".k-item:visible").eq(i).attr("data-value")},_updateCurrentlySelected:function(){var t=this,n=this._listsContainer.find(".k-content.k-scrollable");this._listsContainer.is(":visible")&&(t._currentValues={},n.each((function(){var n=e(this);t._currentValues[n.attr("data-name")]=parseInt(t._findSelectedValue(n))})))},_scrollListToPosition:function(e,t){var n=e.find('.k-item[data-value="'+t+'"]'),i=p(n);e.scrollTop(e.find(".k-item:visible").index(n)*i)},_renderList:function(n,r){if(r){for(var o=e((({title:e,name:t})=>`<div class="k-time-list-wrapper"><span class="k-title">${i(e)}</span><div class="k-time-list"><div class="k-content k-scrollable k-time-container" data-name="${i(t)}"><ul class="k-reset"></ul><div class="k-scrollable-placeholder"></div></div></div></div>`)({name:r.name,title:this.options.messages[r.name]})),a="",s=r.min;s<=r.max;s+=r.step)a+=u({value:t.format(r.selectorFormat,s)});o.find("ul").html(a),o.appendTo(n)}},_columns:function(){var e,t=this,n=t.options;if(t._listsContainer)for(var i=0;i<n.columns.length;i++)e=n.columns[i],t._renderList(t._listsContainer,e)},_shortCuts:function(){var n,i=this,r=i.options;if(i._shortcuts)for(var a=0;a<r.shortcuts.length;a++)n=r.shortcuts[a],e(o.renderButton(`<button class="k-button ${t.getValidCssClass("k-button-","size",i.options.size||"medium")} k-button-solid k-button-solid-base k-rounded-md">`+n.text+"</button>",{rounded:r.rounded})).attr(t.attr("value"),n.value).appendTo(i._shortcuts)},_buttons:function(){var t=this.options;e("<div class='k-actions k-actions-stretched k-actions-horizontal k-timeduration-footer'>"+o.renderButton('<button class="k-time-cancel k-button">'+i(t.messages.cancel)+"</button>",{rounded:t.rounded,size:t.size})+o.renderButton('<button class="k-time-accept k-button k-button-solid k-button-solid-primary">'+i(t.messages.set)+"</button>",{rounded:t.rounded,size:t.size})+"</div>").appendTo(this._timeSelectorWrapper)},_wrappers:function(){var n=this,i=n.options;n._timeSelectorWrapper=e("<div></div>"),n._listContainer=e(`<div tabindex='0' class='k-timeselector ${t.getValidCssClass("k-timeselector-","size",n.options.size||"medium")}'></div>`),n._listContainer.appendTo(n._timeSelectorWrapper),i.shortcuts&&(n._shortcuts=e("<div class='k-actions k-actions-start k-actions-horizontal k-time-fast-selection'></div>").appendTo(n._listContainer)),i.columns.length&&(n._listsContainer=e("<div class='k-time-list-container'><span class='k-time-highlight'></span></div>").appendTo(n._listContainer),n._listsContainer.attr("id",i.id))},_popup:function(){var e=this,i=e.options;"auto"!=i.adaptiveMode||e.bigScreenMQL.mediaQueryList.matches?e.popup=new n.Popup(e._timeSelectorWrapper,a(!0,{},i.popup,{anchor:i.anchor,open:i.open,close:i.close,isRtl:t.support.isRtl(i.anchor),activate:function(){e.addTranslate(),e._value?e.applyValue(e._value):e._updateCurrentlySelected(),e._focusList(e._listContainer.find(".k-time-list-wrapper").eq(0))}})):(e._timeSelectorWrapper.appendTo(document.body),e.popup=new n.ActionSheet(e._timeSelectorWrapper,{adaptive:!0,title:"Set time",subtitle:"00/00/00",closeButton:!0,fullscreen:e.smallScreenMQL.mediaQueryList.matches,popup:a(!0,{},i.popup,{anchor:i.anchor,open:i.open,close:i.close,isRtl:t.support.isRtl(i.anchor)}),activate:function(){e.addTranslate(),e._value?e.applyValue(e._value):e._updateCurrentlySelected(),e._focusList(e._listContainer.find(".k-time-list-wrapper").eq(0))}}),e._timeSelectorWrapper.find(".k-timeduration-footer").appendTo(e.popup.element))}});function p(e){return e.length&&e[0].getBoundingClientRect().height}n.plugin(h)}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=n.ui,r=i.Widget,o=n.html,a=e.map,s=e.extend,l=n.mediaQuery,c="open",d="close",u="change",h="k-focus",p="aria-expanded",f="mouseenter"+(S=".kendoTimeDurationPicker")+" mouseleave"+S,m="k-disabled",g="aria-hidden",v="aria-disabled",_="aria-readonly",b="disabled",y="readonly",w="k-invalid",k="_",x=n.caret,C=n.keys,S=".kendoTimeDurationPicker";o=n.html;var T={hours:{name:"hours",format:"## hours",divider:36e5,min:0,max:23,step:1},minutes:{name:"minutes",format:"## mins",divider:6e4,min:0,max:59,step:1},seconds:{name:"seconds",format:"## sec",divider:1e3,min:0,max:59,step:1},milliseconds:{name:"milliseconds",format:"### msec",min:0,max:999,step:1},days:{format:"### days",name:"days",divider:864e5,min:0,max:365,step:1}};var D=r.extend({init:function(i,o){var c,d=this;o=o||{},r.fn.init.call(d,i,o),d._columns=(c=o.columns,a(c,(function(e){var t=s(!0,{},T[(e="string"==typeof e?{name:e}:e).name],e);return t.selectorFormat="{0:"+"0".repeat(t.format.match(/#/g).length)+"}",t}))),d.options.columns=d._columns,d.options.readonly=o.readonly!==t?o.readonly:Boolean(d.element.attr("readonly")),d.options.enable=o.enable!==t?o.enable:!Boolean(d.element.is("[disabled]")||e(i).parents("fieldset").is(":disabled")),d.bigScreenMQL=l("large"),"auto"==d.options.adaptiveMode&&d.bigScreenMQL.onChange((()=>{d._timeSelector&&(d._timeSelector.destroy(),d._timeSelector=null),d._popupView()})),d._wrapper(),d._button(),d._applyCssClasses(),d._input(),d._popupView(),d._buildMask(),d._validation(),d._editable({readonly:d.options.readonly,disable:!d.options.enable}),d._ariaLabel(d._timeSelector._listsContainer),d.options.value&&(d.value(o.value),d._old=d._maskedInput.val()),d._canUpdateLast=!0,n.notify(d)},options:{name:"TimeDurationPicker",columns:[],separator:",",shortcuts:[],value:null,adaptiveMode:"none",size:"medium",fillMode:"solid",rounded:"medium",messages:{set:"Set",cancel:"Cancel",days:"Days",hours:"Hours",minutes:"Minutes",milliseconds:"Milliseconds",seconds:"Seconds"}},events:[c,d,u],destroy:function(){var e=this;e.wrapper.off(S),e._maskedInput.off(S),e._timeSelector&&(e._timeSelector.destroy(),e._timeSelector=null),e.bigScreenMQL&&e.bigScreenMQL.destroy()},value:function(e){var n=this;if(e===t)return n._value;e="number"==typeof e?parseInt(e):null,n._value=e,n.element.val(n._value),n._timeSelector._value=n._value,n._updateValueFromTimeSelector()},_toggleHover:function(t){e(t.currentTarget).toggleClass("k-hover","mouseenter"===t.type)},_editable:function(e){var t=this,n=e.disable,i=e.readonly,r=t._maskedInput.add(t.element).off(S),o=t.wrapper.off(S);i||n?(o.addClass(n?m:"").removeClass(n?"":m),r.attr(b,n).attr(y,i).attr(v,n).attr(_,i)):(o.removeClass(m).on(f,t._toggleHover),r&&r.length&&(r.removeAttr(b),r.removeAttr(y)),r.attr(v,!1).attr(_,!1),t._attachHandlers())},readonly:function(e){this._editable({readonly:e===t||e,disable:!1})},enable:function(e){this._editable({readonly:!1,disable:!(e=e===t||e)})},_popupView:function(){var e=this,t=e.options;e._timeSelector||(e._timeSelector=new n.ui.TimeSelector(e._maskedInput,{id:e.element.attr("id")+"_timeSelector",anchor:e.wrapper,adaptiveMode:t.adaptiveMode,columns:t.columns,shortcuts:t.shortcuts,value:t.value,size:"auto"!=t.adaptiveMode||e.bigScreenMQL.mediaQueryList.matches?t.size:"large",fillMode:t.fillMode,rounded:t.rounded,messages:t.messages,focus:function(){e._maskedInput.trigger("focus"),e._selectNearestSection(e._lastCaret||0)},close:function(t){e.trigger(d)?t.preventDefault():(e._maskedInput.attr(p,!1),e._timeSelector._listsContainer.attr(g,!0))},open:function(t){e.trigger(c)?t.preventDefault():(e._maskedInput.attr(p,!0),e._timeSelector._listsContainer.attr(g,!1),e._lastCaret=x(e._maskedInput)[0],e._lastCaret===e._maskedInput.val().length&&(e._lastCaret=0))},change:function(t){e._value=t,e._updateValueFromTimeSelector(),e._removeInvalidState(),e.trigger(u)}}))},_button:function(){var t,n=this,i=n.element,r=n.options;(t=i.next("button.k-input-button"))[0]||(t=e(o.renderButton('<button unselectable="on" tabindex="-1" class="k-input-button" aria-label="select"></button>',{icon:"clock-arrow-rotate",size:r.size,fillMode:r.fillMode,shape:"none",rounded:"none"})).insertAfter(i)),n._button=t.attr({role:"button"})},_buildMask:function(){var e,t,n=this.options.columns,i="",r=0;this._emtpyMask="",this._maskParts=[];for(var o=0;o<n.length;o++)t={},e=n[o].format,o&&(i=this.options.separator),i+=e.replace(/#/g,"_"),this._emtpyMask+=i,t.end=this._emtpyMask.length-1,t.mask=e.replace(/#/g,"_"),t.symbolsLength=t.mask.match(/_/g).length,t.start=this._emtpyMask.indexOf(t.mask,r),t.numberEnd=this._emtpyMask.lastIndexOf(k)+1,t.numberStart=this._emtpyMask.indexOf(k,t.start),r+=t.mask.length,this._maskParts.push(t);this._old=this._emtpyMask,this._maskedInput.val(this._emtpyMask)},_input:function(){var t=this;t._maskedInput=e("<input />").attr(n.attr("validate"),"false").attr({role:"combobox","aria-expanded":!1,"aria-controls":t.element.attr("id")+"_timeSelector",autocomplete:"off"}).addClass("k-input-inner").insertBefore(t.element),t.element.hide()},_wrapper:function(){var e,t=this.element;(e=t.parents(".k-timedurationpicker"))[0]||(e=t.wrap("<span></span>").parent()),this.wrapper=e.addClass("k-timedurationpicker k-input")},_attachHandlers:function(){var e=this;e._maskedInput.on("keydown"+S,e._keydown.bind(e)).on("input"+S,e._inputHandler.bind(e)).on("focus"+S,e._focus.bind(e)).on("focusout"+S,e._focusout.bind(e)).on("paste"+S,e._paste.bind(e)).on("mousedown"+S,e._mouseDown.bind(e)).on("mouseup"+S,e._mouseUp.bind(e)),e.wrapper.on("click"+S,".k-input-button",e._click.bind(e))},_mouseDown:function(){this._mouseOnInput=!0},_mouseUp:function(){var e=x(this._maskedInput[0]),t=this._maskedInput[0].value;e[0]===e[1]&&this._selectNearestSection(e[1]==t.length?t.length-1:e[1])},_triggerChange:function(){(this._lastValue==t&&this._value||this._lastValue!=this._value)&&(this._lastValue=this._value,this.trigger(u))},_focusout:function(){this._updateValueFromInput(),this._triggerChange(),this._canUpdateLast=!0,this.wrapper.removeClass(h)},_focus:function(){var e=this;e._mouseOnInput||setTimeout((function(){e._selectNearestSection(0)}),10),e._mouseOnInput=!1,e.wrapper.addClass(h)},_selectNearestSection:function(e){for(var t,n=0;n<this._maskParts.length;n++)e>=(t=this._maskParts[n]).start&&e<=t.end&&x(this._maskedInput[0],t.numberStart,t.numberEnd)},_getPartValue:function(e,t){var n=this.options.separator,i=e.indexOf(n,t),r=e.lastIndexOf(n,t);return e.substring(r<0?0:r+1,i<0?e.length:i)},_getEmptyPart:function(e){return this._getPartValue(this._emtpyMask,e)},_fillParts:function(e){var t,n=this._emtpyMask.split(this.options.separator);e+="";for(var i=0;i<n.length;i++)(t=n[i].match(/_/g).length)>e.length?n[i]=n[i].replace(k.repeat(t),"0".repeat(t-e.length)+e):(n[i]=n[i].replace(k.repeat(t),e.substring(0,t)),e=e.substring(t,t.length));return n.join(this.options.separator)},_clearParts:function(e,t,n){for(var i,r=e.split(this.options.separator),o=0,a=0;a<r.length;a++)i=o+r[a].length,(o<=t&&i>=t||o<=n&&i>=n)&&(r[a]=this._getEmptyPart(o)),o+=r[a].length+1;return r.join(this.options.separator)},_updatePart:function(e,t){var i=this._getEmptyPart(this._old.indexOf(e)),r=e.substring(i.indexOf(k),i.lastIndexOf(k)+1),o="{0:"+"0".repeat(r.length)+"}";return r.indexOf(k)>=0||"0"!==e[e.search(/[0-9]/)]||t.length>1?e.replace(r,n.format(o,parseInt(t))):e.replace(r,n.format(o,parseInt(r+t)))},_replacePart:function(e,t,n){return e.replace(this._getPartValue(e,n),t)},_click:function(){this._timeSelector&&this._timeSelector.toggle()},_switchPart:function(e){var n,i=this.options.separator,r=e.caret!=t?e.caret:x(this._maskedInput[0])[0],o=this._maskedInput.val();e.next?(n=o.indexOf(i,r))<0?n=o.length-1:n++:(n=o.lastIndexOf(i,r))<0?n=0:n--,this._selectNearestSection(n)},_keydown:function(e){var t,n,i,r,o,a=e.keyCode,s=this.options.separator;if(this._backward=a===C.BACKSPACE,a==C.LEFT||a==C.RIGHT){if(e.preventDefault(),t=x(this._maskedInput[0])[0],r=(n=this._maskedInput.val()).indexOf(s,t),o=n.lastIndexOf(s,t),r<0&&a==C.RIGHT||o<0&&a==C.LEFT)return;i=a==C.LEFT?o-1:r+1,this._selectNearestSection(i),a==C.LEFT&&(this._canUpdateLast=!0)}else this._timeSelector.popup.visible()?this._timeSelector._scrollerKeyDownHandler(e):a==C.UP||a==C.DOWN?(e.preventDefault(),e.altKey&&this._timeSelector.toggle()):a==C.ENTER&&(this._updateValueFromInput(),this._triggerChange())},_updateValueFromTimeSelector:function(){for(var e,t,n,i=this,r=function(e){var t,n=Math.floor(e/864e5);t=e%864e5;var i=Math.floor(t/36e5);t=e%36e5;var r=Math.floor(t/6e4);return t=e%6e4,{days:n,hours:i,minutes:r,seconds:Math.floor(t/1e3),milliseconds:t=e%1e3}}(i._value),o="",a=this._columns[s],s=0;s<this._columns.length;s++)t=r[(a=this._columns[s]).name]+"",e=this._maskParts[s],s&&(o+=i.options.separator),r[a.name]?(n=e.symbolsLength-t.length,o+=e.mask.replace(k.repeat(e.symbolsLength),"0".repeat(n<0?0:n)+t)):o+=e.mask;i._maskedInput.val(o),i._old=o},_validation:function(){var t=this.element;this._validationIcon=e(n.ui.icon({icon:"exclamation-circle",iconClass:"k-input-validation-icon k-hidden"})).insertAfter(t)},_addInvalidState:function(){this.wrapper.addClass(w),this._validationIcon.removeClass("k-hidden")},_removeInvalidState:function(){this.wrapper.removeClass(w),this._validationIcon.addClass("k-hidden")},_updateValueFromInput:function(){for(var e,t,i,r=this._maskedInput.val(),o={},a=!0,s=0;s<this._columns.length;s++){if(e=this._columns[s],t=this._maskParts[s],i=r.substring(t.numberStart,t.numberEnd).replace(/_/g,""),!((i=n.parseInt(i||0))>=e.min&&i<=e.max)){a=!1;break}o[e.name]=i}a?(this._value=function(e){return 864e5*(e.days||0)+36e5*(e.hours||0)+6e4*(e.minutes||0)+1e3*(e.seconds||0)+(e.milliseconds||0)}(o),this.element.val(this._value||""),this._timeSelector._value=this._value,this._removeInvalidState()):this._addInvalidState()},_paste:function(e){var t;this._isPasted=!0,this._pasted=(e.clipboardData||e.originalEvent.clipboardData).getData("Text");var n=x(this._maskedInput);this._maskedInput.val().length!=n[1]||n[0]?(t=this._getEmptyPart(n[0]),this._pasted=this._pasted.substring(0,t.match(/_/g).length)):this._replaceEntire=!0},_inputHandler:function(){if(n._activeElement()===this._maskedInput[0]){var e,t,i,r,o,a,s,l,c,d,u,h=this,p=h._old,f=h.options.separator,m=h._maskedInput[0].value,g=x(h._maskedInput)[0],v=p.length-m.length;if(e=h._isPasted?h._pasted:m.substring(g-1,g),t=/\d/.test(e),h._isPasted&&h._replaceEntire&&t)return h._old=h._fillParts(parseInt(e)),h._maskedInput.val(h._old),h._selectNearestSection(0),void(h._isPasted=h._replaceEntire=!1);if(h._isPasted&&(v=0),h._isPasted=!1,e===f&&!h._backward)return h._maskedInput.val(h._old),void h._switchPart({caret:g,next:!0});if(!m&&h._backward)return h._old=h._emtpyMask,h._maskedInput.val(h._old),void h._selectNearestSection(g);if(!t&&!h._backward)return h._maskedInput.val(h._old),void h._selectNearestSection(g);if(!v||v>0){if(r=m.substring(g,m.length),c=(o=m.substring(0,g))+(a=h._emtpyMask.substring(o.length,p.indexOf(r)))+r,d=h._getPartValue(h._old,g),u=h._old.indexOf(f,h._old.indexOf(d)+1),h._backward){if(a.split(f).length>1)h._old=this._clearParts(c,g,g+a.length);else{if((s=this._getEmptyPart(g))==d)return h._maskedInput.val(h._old),void h._switchPart({caret:g});h._old=h._replacePart(c,s,g)}return h._maskedInput.val(h._old),void h._selectNearestSection(g)}if(u<0&&-1===d.indexOf(k)&&!h._canUpdateLast)return h._maskedInput.val(h._old),void h._selectNearestSection(g);t&&(l="0"===(i=h._updatePart(d,e))[i.search(/[0-9]/)],c=h._replacePart(c,i,g),h._maskedInput.val(c),u>0&&!l?h._selectNearestSection(u+1,!0):h._selectNearestSection(g),h._canUpdateLast=!(u<0&&!l)),h._old=c}else v<0&&(h._maskedInput.val(h._old),h._selectNearestSection(h._old.length-1))}}});n.cssProperties.registerPrefix("TimeDurationPicker","k-input-"),n.cssProperties.registerValues("TimeDurationPicker",[{prop:"rounded",values:n.cssProperties.roundedValues.concat([["full","full"]])}]),i.plugin(D)}(window.kendo.jQuery);kendo;!function(e,t){const n=window.kendo,i=n.ui.Widget,r=".kendoDockManager",o=n.ui,a=e.extend,s=/^\d+(\.\d+)?%$/i,l="k-dock-manager-toolbar",c=`<div class="${l} k-toolbar-left k-toolbar k-toolbar-md k-toolbar-solid"></div>`,d="k-pane-static",u="k-pane-pinned",h="k-pane-unpinned",p="k-pane-tabbed",f="k-splitter",m="k-splitbar",g="horizontal",v="vertical",_="k-hidden",b="k-button",y="k-pane",w="k-dock-manager-pane-container",k="k-pane-actions",x="k-dock-indicator",C="k-dock-navigator",S="k-docking-preview",T="k-selected",D="k-active",A="k-tabstrip",M="split",E="tab",I="height",z="width",P="top",H="bottom",F="left",R="right",L="middle",B="click",O="pin",V="unpin",N="unshift",$=`<div class="${y} k-pane-flex ${d}"></div>`,U=e=>`.${y}[${n.attr("uid")}="${e}"]`,W=e=>`<span class="k-button-text">${e}</span>`,j=n.attr("uid"),q=n.attr("indicator"),G=n.attr("action"),K=`<div class="${x}">\n                        <span class="k-svg-icon k-icon-xl k-svg-i-position-top">\n                        <svg aria-hidden="true" focusable="false" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\n                            <path d="M480 448V32H32v448h448v-32zm-416 0V64h384v384H64zM96 96h320v96H96z"></path>\n                        </svg>\n                        </span>\n                    </div>`,Y=`<div class="${C}" style="position: relative;">\n                                <div class="k-dock-indicator k-dock-indicator-top" ${q}="top">\n                                <span class="k-svg-icon k-icon-xl k-svg-i-position-top">\n                                    <svg aria-hidden="true" focusable="false" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\n                                        <path d="M480 448V32H32v448h448v-32zm-416 0V64h384v384H64zM96 96h320v96H96z"></path>\n                                    </svg>\n                                </span>\n                                </div>\n                                <div class="k-dock-indicator k-dock-indicator-right" ${q}="right">\n                                <span class="k-svg-icon k-icon-xl k-svg-i-position-right">\n                                    <svg aria-hidden="true" focusable="false" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\n                                        <path d="M64 480h416V32H32v448h32zm0-416h384v384H64V64zm256 32h96v320h-96z"></path>\n                                    </svg>\n                                </span>\n                                </div>\n                                <div class="k-dock-indicator k-dock-indicator-bottom" ${q}="bottom">\n                                <span class="k-svg-icon k-icon-xl k-svg-i-position-bottom">\n                                    <svg aria-hidden="true" focusable="false" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\n                                        <path d="M32 64v416h448V32H32v32zm416 0v384H64V64h384zM96 320h320v96H96z"></path>\n                                    </svg>\n                                </span>\n                                </div>\n                                <div class="k-dock-indicator k-dock-indicator-left" ${q}="left">\n                                <span class="k-svg-icon k-icon-xl k-svg-i-position-left">\n                                    <svg aria-hidden="true" focusable="false" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\n                                        <path d="M448 32H32v448h448V32h-32zm0 416H64V64h384v384zM96 96h96v320H96z"></path>\n                                    </svg>\n                                </span>\n                                </div>\n                                <div class="k-dock-indicator k-dock-indicator-middle" ${q}="middle">\n                                <span class="k-svg-icon k-icon-xl k-svg-i-window">\n                                    <svg aria-hidden="true" focusable="false" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\n                                        <path d="M96 96v320h320V96H96zm288 288H128V192h256v192z"></path>\n                                    </svg>\n                                </span>\n                                </div>\n                            </div>`,Q="close",X="dock",Z="innerDock",J="resize",ee="drag",te="dragStart",ne="dragEnd";const ie=i.extend({init:function(t,r){const o=this;i.fn.init.call(o,t,r),r=e.extend(!0,{},r),o.element.addClass("k-dock-manager"),o.panesContainer=e(`<div class="${w}" />`).appendTo(o.element),o._processPanes(o.options.rootPane),o._refreshToolbar(),o._createPane(o.panesContainer,o.options.rootPane),o._bindEvents(),o._initNavigator(),o._initUnpinnedResizable(),n.notify(o)},events:[Q,O,V,X,Z,J,ee,te,ne],options:{name:"DockManager",rootPane:{type:M,orientation:g,panes:[]}},paneDefaults:{visible:!0,closeable:!0,collapsed:!1,size:""},actions:[{name:"pin",icon:"unpin",shouldAdd:e=>e.unpinnable&&e.unpinnable.unpinned},{name:"unpin",icon:"pin",shouldAdd:e=>e.unpinnable&&!e.unpinnable.unpinned},{name:"minimize",icon:"minimize",shouldAdd:e=>e.minimizable},{name:"maximize",icon:"maximize",shouldAdd:e=>e.maximizable},{name:"close",icon:"x",shouldAdd:e=>0!=e.closeable},{name:"more",icon:"more-vertical",shouldAdd:e=>!1}],indicators:[{name:P,top:0,left:"50%",transform:"translate(-50%, 0)",previewTop:()=>0,previewLeft:()=>0,rotate:"0deg"},{name:H,top:"100%",left:"50%",transform:"translate(-50%, -100%)",previewTop:(e,t)=>e-t,previewLeft:()=>0,rotate:"180deg"},{name:F,top:"50%",left:0,transform:"translate(0, -50%)",previewTop:()=>0,previewLeft:()=>0,rotate:"270deg"},{name:R,top:"50%",left:"100%",transform:"translate(-100%, -50%)",previewTop:()=>0,previewLeft:(e,t)=>e-t,rotate:"90deg"},{name:L,previewTop:()=>0,previewLeft:()=>0}],togglePane:function(e){const n=this,i=n._getPaneById(n.options.rootPane,"id",e);i!=t&&n._togglePane(i)},removePane:function(e){const n=this,i=n._getPaneById(n.options.rootPane,"id",e);i!=t&&n._removePane(i)},getOptions:function(){return this.options},setOptions:function(e){const t=this;let i=t.getOptions();n.deepExtend(i,e),t.destroy(),t.element.empty(),t.init(t.element,i)},_initUnpinnedResizable:function(){const e=this;e._unpinnedResizable=new n.ui.Resizable(e.unpinnedContainer,{orientation:g,handle:".k-splitbar-horizontal.k-splitbar-draggable-horizontal",resize:function(t){const n=t.x.delta,i=e.unpinnedContainer.width();e.unpinnedContainer.width(i+n)}})},_bindEvents:function(){const e=this;e.element.on(B+r,`.k-dock-manager-toolbar .${b}`,e._toolbarButtonClick.bind(e)),e.element.on(B+r,`.${w}`,e._hideUnpinnedPanes.bind(e)),e.element.on(B+r,`.${b}[${G}="pin"], .${b}[${G}="unpin"]`,e._pinPaneClick.bind(e)),e.element.on(B+r,`.${b}[${G}="close"]`,e._closePane.bind(e)),e.element.on("mouseenter"+r,`.${x}`,e._displayDockPreview.bind(e)),e.element.on("mouseleave"+r,`.${x}`,e._hideDockPreview.bind(e))},_hideUnpinnedPanes:function(e){const t=this,n=t.unpinnedContainer.find(`.${y}`).filter(":visible"),i=t.unpinnedContainer.is(":visible");if(n&&i)return t._toolbar.find(`.${T}`).removeClass(T),void t.unpinnedContainer.addClass(_)},_toolbarButtonClick:function(t){const n=this,i=e(t.currentTarget).attr(j),r=n.unpinnedContainer.find(`.${y}`).filter(":visible"),o=n.unpinnedContainer.is(":visible");t.preventDefault(),n._toolbar.find(`.${b}`).removeClass(T),r.attr(j)===i&&o?n.unpinnedContainer.addClass(_):n._showUnpinnedPane(i)},_showUnpinnedPane:function(e){const t=this,n=t._toolbar.outerWidth(),i=t._findPaneByUid(e),r=i.unpinnable.unpinnedSize;t.unpinnedContainer.removeClass(_).css({left:`${n}px`}),t.unpinnedContainer.find(`.${y}`).addClass(_),t.unpinnedContainer.find(U(e)).removeClass(_),r&&t.unpinnedContainer.css({width:`${i.unpinnable.unpinnedSize}`}),t._toolbar.find(`.${b}[${j}="${e}"]`).addClass(T)},_pinPaneClick:function(t){const i=this,r=e(t.currentTarget),o=r.parent().is("li"),a=r.attr(G),s=o?r.parent():e(t.currentTarget).closest(`.${y}`),l=i._findPaneByUid(s.attr(j)),c=l.unpinnable.unpinned,d=i._findPaneByUid(l.parentUid),p=(i.panesContainer.find(`.${y}[${j}="${d.uid}"], .${f}[${j}="${d.uid}"]`),{pane:l,paneElement:s});c&&(n.destroy(s),s.remove()),l.unpinnable.unpinned=a!==O,i._refreshRootPane(),i.unpinnedContainer.toggleClass(_,a===O),i.unpinnedContainer.find(`.${y}`).removeClass(u).addClass(h),"pin"!==a?(i.trigger(V,p),i._showUnpinnedPane(l.uid)):i.trigger(O,p)},_closePane:function(t){const n=this,i=e(t.currentTarget),r=i.parent().is("li")?i.parent():e(t.currentTarget).closest(`.${y}`),o=n._findPaneByUid(r.attr(j)),a=n._findPaneByUid(o.parentUid),s=(n.panesContainer.find(`.${y}[${j}="${a.uid}"], .${f}[${j}="${a.uid}"]`),a.panes.indexOf(o)),l={pane:o,paneElement:r,event:t};n.trigger(Q,l)&&t.preventDefault(),o.unpinnable&&o.unpinnable.unpinned&&n.unpinnedContainer.addClass(_),a.panes.splice(s,1),n._shouldHideParent(a)&&(a.visible=!1),n._refreshRootPane()},_shouldHideParent:function(e){const t=this._findPaneByUid(e.parentUid);return 0==e.panes.length?(e.type==E&&1==t.panes.length&&(t.panes.splice(0,1),t.visible=!1),!0):1==e.panes.length&&e.panes[0].type==E&&!e.panes.some((e=>e.visible))},_refreshPane:function(e,t){const i=e.parent(),r=e.is(`.${p}`);n.destroy(e),r?e.empty():e.remove(),this._refreshToolbar(),this._createPane(r?e:i,t)},_processPanes:function(e){const i=this;e.uid=e.uid||n.guid(),i._extendPane(e),e.type!==M||e.orientation||(e.orientation=g),e.panes.forEach((r=>{r.parentUid=e.uid,"content"==r.type&&(r.unpinnable!==t&&!0!==r.unpinnable||(r.unpinnable={unpinned:!1}),r.uid=r.uid||n.guid()),r.panes&&r.panes.length&&i._processPanes(r)}))},_extendPane:function(e){const n=this;if(e.panes)for(var i=0;i<e.panes.length;i++)e.panes.forEach((e=>{n._extendPane(e)}));a(e,{visible:e.visible===t?n.paneDefaults.visible:e.visible,closeable:e.closeable===t?n.paneDefaults.closeable:e.closeable,collapsed:e.collapsed===t?n.paneDefaults.collapsed:e.collapsed,size:e.size===t?n.paneDefaults.size:e.size,scrollable:!1})},_togglePane:function(e){e.visible=!e.visible,this._refreshRootPane()},_removePane:function(e){const t=this,n=t._findPaneByUid(e.parentUid),i=n.panes.indexOf(e);t.panesContainer.find(`[${j}="${e.uid}"]`).parent();n.panes.splice(i,1),t._refreshRootPane()},_refreshToolbar:function(){const t=this,i=t._unpinnedPanes(),r=e(`<div class="${_}"/>`).addClass("k-dock-manager-unpinned-container");if(t.unpinnedContainer||(t.unpinnedContainer=r,r.append('<div class="k-splitbar k-splitbar-horizontal k-splitbar-draggable-horizontal">\n                                    <div class="k-resize-handle"></div>\n                                </div>'),r.insertBefore(t.panesContainer)),!i.length)return t._toolbar&&t._toolbar.remove(),void(t._toolbar=null);t._toolbar||(t._toolbar=t.element.prepend(c).find(`.${l}`)),t._toolbar.empty();for(let r=0;r<i.length;r++){const o=i[r],a=e(n.html.renderButton({fillMode:"flat",size:"small"})).addClass("k-toolbar-button").append(W(t._paneHeader(o)));a.attr(j,o.uid),t._toolbar.append(a),r<i.length-1&&t._toolbar.append('<div class="k-separator k-separator-horizontal"></div>')}},destroy:function(){const e=this;i.fn.destroy.call(e),e.element.off(r),e.element.empty(),n.destroy(e.wrapper)},refresh:function(){const e=this;n.destroy(e.unpinnedContainer),e.unpinnedContainer.empty(),e._refreshRootPane()},_refreshRootPane:function(){const e=this,t=e.element.find(`[${j}="${e.options.rootPane.uid}"]`);e._refreshPane(t,e.options.rootPane)},_createSplitPane:function(i,r){const o=this,a=e("<div ref-dock-splitter/>").attr(j,r.uid),s={orientation:r.orientation||g,panes:[]};if(!r.panes.some((e=>e.visible)))return;i.append(a);const l=[];r.panes.forEach((n=>{const i={uid:n.uid,scrollable:!1},r=e($).removeClass(d);n.unpinnable&&n.unpinnable.unpinned?o._createUnpinnedPane(n):(n.size&&(i.size=n.size),n.visible!=t&&(i.visible=n.visible),n.visible&&(a.append(r),l.push((()=>o._createPane(r,n))),s.panes.push(i)))})),r.splitter=new n.ui.Splitter(a,s),r.splitter.element.addClass("k-dock-manager-splitter"),l.forEach((e=>e())),r.splitter.bind(J,o._updatePaneSize.bind(o))},_updatePaneSize:function(e){const t=this;if(!e.leftPane&&!e.rightPane)return;const n=t._findPaneByUid(e.leftPane.uid),i=t._findPaneByUid(e.rightPane.uid);n.size=e.leftPane.size,i.size=e.rightPane.size,t.trigger(J,{ev:e,leftPane:n,rightPane:i})},_createTabPane:function(n,i){const r=this,o=e("<div class='k-header'/>"),a=e("<ul/>"),s=i.selected===t||-1==i.panes.indexOf(i.panes[i.selected])||i.panes[i.selected].unpinnable.unpinned?0:i.selected;i.panes.some((e=>e.visible))&&(o.append(a),n.append(o),n.attr(j,i.uid),n.addClass(p),i.panes.forEach((t=>{const n=e((e=>`<li><span class="k-link"><span class="k-link-text">${e}</span></span></li>`)(r._paneHeader(t))).attr(j,t.uid),i=e("<div/>");t.unpinnable&&t.unpinnable.unpinned?r._createUnpinnedPane(t):t.visible&&(r._addActions(n,t),a.append(n),o.append(i),r._createPane(i,t))})),e(a.children()[s]).addClass(D),o.kendoTabStrip({animation:!1}))},_createContentPane:function(t,i){const r=this,o="function"==typeof i.content?n.template(i.content)({}):i.content,s=e(`<div class="k-pane-scrollable">\n                                            <div class="k-pane-header">\n                                                <span class="k-pane-title">${(l=a({},i,{title:r._paneHeader(i),content:o})).title}</span>\n                                                <div class="${k}"></div>\n                                            </div>\n                                            <div class="k-pane-content">${l.content}</div>\n                                        </div>`);var l;const c=r._findPaneByUid(i.parentUid),p=i.unpinnable&&i.unpinnable.unpinned;!c||c.type!==E||p?(t.addClass(p?h:u).removeClass(d).attr(j,i.uid),r._addActions(s.find(`.${k}`),i),t.append(s)):t.append(o)},_createUnpinnedPane:function(t){const n=this,i=e($).removeClass(d);n.unpinnedContainer.find(U(t.uid)).length||(n.unpinnedContainer.prepend(i),n._createContentPane(i,t))},_addActions:function(t,i){this.actions.forEach((r=>{r.shouldAdd(i)&&t.append(e(n.html.renderButton({fillMode:"flat",icon:r.icon,themeColor:"base"})).attr(G,r.name))}))},_createPane:function(e,t){return t.id&&e.attr("id",t.id),this["_create"+(n=t.type,n.charAt(0).toUpperCase()+n.slice(1)+"Pane")](e,t);var n},_unpinnedPanes:function(e){const t=this,n=t.options;let i=[];return e||(e=n.rootPane.panes),e.forEach((e=>{e.unpinnable&&e.unpinnable.unpinned&&i.push(e),e.panes&&e.panes.length&&(i=i.concat(t._unpinnedPanes(e.panes)))})),i},_paneHeader:function(e){const t=this._findPaneByUid(e.parentUid),i=t&&"tab"===t.type;let r=e.header;return i&&e.tabHeader&&(r=e.tabHeader),r?n.template(r)(e):e.title||""},_findPaneByUid:function(e,t){const n=this;let i;return(t=t||n.options.rootPane).uid===e?t:(t.panes.forEach((t=>{if(t.uid!==e){if(t.panes&&t.panes.length){const r=n._findPaneByUid(e,t);if(r)return void(i=r)}}else i=t})),i)},_getPaneById:function(e,t,n){const i=this;let r;return e[t]==n?e:(e.panes&&e.panes.forEach((e=>{let o=i._getPaneById(e,t,n);o&&(r=o)})),r)},_initNavigator:function(t){const i=this;i.navigatorDraggable=new n.ui.Draggable(i.element,{autoScroll:!0,filter:".k-pane-header, .k-pane-tabbed .k-tabstrip-item",hint:function(e){const t=e.is("li"),n=e.closest(`.${y}`),r=i._findPaneByUid((t?e:n).attr(j)),o=t?i._getActionButtons(e):n.find(`.${k}`).html();return(e=>`<div class="k-tooltip k-tooltip-primary">\n                                    <div class="k-tooltip-content">${e.title}</div>\n                                </div>`)({width:n.width(),height:n.height(),content:r.content,title:i._paneHeader(r),actions:o})},updateHint:function(t,n){const i={left:n.x.location+1,top:n.y.location+1};t.css(e.extend({},i,{zIndex:100010}))},dragstart:i._dragStart.bind(i),dragend:i._dragEnd.bind(i),drag:i._drag.bind(i)})},_dragStart:function(t){const n=this,i=e(t.currentTarget),r=i.closest(`.${y}`);n.draggedPane={width:r.width(),height:r.height(),pane:r,target:i},n._displayGlobalIndicators(),n.trigger(te,{pane:n.draggedPane.pane,draggableEvent:t})},_dragEnd:function(e){const t=this,n=t.element.find(`.${x}:hover`),i={pane:t.draggedPane.pane,draggableEvent:e};n.length&&(t.navigatorDraggable.hint.hide(),t._updateLayout(n)),t.element.find(`.${x}`).remove(),t.element.find(`.${S}`).remove(),n.length||t._showHiddenPanes(),t.trigger(ne,i),t.hoveredPane=null,t.draggedPane=null},_drag:function(t){const n=this,i=e(t.elementUnderCursor).closest(`.${y}[${j}]`),r=n._findPaneByUid(i.attr(j)),o=e(Y),a=i.attr(j),s=n.hoveredPane&&n.hoveredPane.attr(j),l={pane:n.draggedPane.pane,draggableEvent:t},c=t.currentTarget.closest(`.${y}`).attr(j);n.trigger(ee,l)?t.preventDefault():a!==s&&(n.hoveredPane=i,n.element.find(`.${C}`).remove(),o.css({position:"absolute",top:"50%",left:"50%",transform:"translate(-50%,-50%)","z-index":100008}),r&&r.dockable&&!r.dockable.innerDock&&o.css("display","none"),a!==c&&i.append(o))},_showHiddenPanes:function(){const e=this;if(e.draggedPane.pane.is(`.${p}`))return e._showTab();e._showPane(e.draggedPane.pane)},_showTab:function(e){if(e===t)return;const n=e.closest(`.${A}`).data("kendoTabStrip");e.show(),n.activateTab(e)},_showPane:function(e){const t=e.siblings(`.${m}:hidden`);e.show(),t.show()},_hideDraggedPane:function(e){const t=this;if(e.is("li"))return t._hideTab(e);t._hidePane(e)},_hidePane:function(e){const t=e.closest(`.${y}`),n=t.prev(),i=t.next();if(t.hide(),n.is(`.${m}`))return n.hide();i.hide()},_hideTab:function(e){const t=e.is(`.${D}`),n=e.closest(`.${A}`).data("kendoTabStrip");e.hide(),t&&n.activateTab("li:visible:first")},_getActionButtons:function(t){const n=t.find("button"),i=e("<div/>");return n.each(((t,n)=>i.append(e(n).clone()))),i.html()},_displayGlobalIndicators:function(){const t=this;t.indicators.forEach((n=>{const i=e(K);"middle"!==n.name&&(t.element.append(i),i.css({position:"absolute","z-index":"100002",top:n.top,left:n.left,transform:`${n.transform} rotate(${n.rotate})`}),i.attr(q,n.name))}))},_displayDockPreview:function(t){const i=this,r=e(t.currentTarget),o=!r.parent().is(`.${C}`),a=r.attr(q),s=r.attr(j),l=i.indicators.filter((e=>e.name===a))[0],c=e(`<div class="${S}"/>`),d=o?i.panesContainer:i.hoveredPane,u=i._toolbar?i._toolbar.outerWidth():0,h=d.outerWidth(),p=d.outerHeight(),f=s&&d.find(`.${S}[${j}="${s}"]`),m=n.guid();let g=i.draggedPane.width,v=i.draggedPane.height;if(f&&f.length)return f.show();a===L&&(g=h,v=p),a!==P&&a!==H||(v>p/2&&(v=p/2),g=h),a!==F&&a!==R||(g>h/2&&(g=h/2),v=p);const _={position:"absolute","z-index":1e5,top:l.previewTop(p,v),left:l.previewLeft(h,g)+(o?u:0),width:g,height:v};c.css(_),c.attr(q,l.name).attr(j,m),r.attr(j,m),d.append(c),i.draggedPane.preview={width:g,height:v},i.draggedPane.container={width:h,height:p}},_hideDockPreview:function(){this.element.find(`.${S}`).hide()},_updateLayout:function(e){const t=this,n=t.draggedPane.target.is("li"),i=!e.parent().is(`.${C}`),r=n?t.draggedPane.target:t.draggedPane.pane,o=t._findPaneByUid(t.hoveredPane.attr(j)),a=t._findPaneByUid(r.attr(j)),s=e.attr(q),l=t._findPaneByUid(a.parentUid),c=l.panes.indexOf(a),d=t.element.find(`[${j}="${t.options.rootPane.uid}"]`);l.panes.splice(c,1),s==L?t._tabDock(o,a):t._splitDock(o,a,s,i),t._processPanes(t.options.rootPane),t._adjustSiblingSizes(a,s,i),t._refreshPane(d,t.options.rootPane),s==L?t.trigger(Z,{pane:a,paneElement:r}):t.trigger(X,{pane:a,paneElement:r})},_splitDock:function(e,t,n,i){const r=this,o=i?r.options.rootPane:r._findPaneByUid(e.parentUid),a=o.panes.indexOf(e),s=n===P||n===F?N:"push",l=a+(s===N?0:1),c=n===P||n===H?I:z,d={type:M,orientation:n===P||n===H?v:g,panes:[]},u=`${r.draggedPane.preview[c]}px`;return t.size=u,i?(d.panes.push(o),n===P||n===F?d.panes.unshift(t):d.panes.push(t),void(r.options.rootPane=d)):(n===P||n===H)&&o.orientation===v||(n===F||n===R)&&o.orientation===g?o.panes.splice(l,0,t):(e&&(d.size=e.size,e.size=null),o.panes.splice(a,1),d.panes.push(e),d.panes[s](t),void o.panes.splice(a,0,d))},_tabDock:function(e,t){const n=this._findPaneByUid(e.parentUid),i=n.panes.indexOf(e),r={type:E,panes:[e,t]};e.type!==E?(n.panes.splice(i,1),n.panes.splice(i,0,r)):e.panes.push(t)},_adjustSiblingSizes:function(e,t,n){const i=this,r=i._getSiblings(e),o=t===P||t===H?I:z,a=i.draggedPane.container[o],s=i.draggedPane[o],l=a-s,c=[];let d=l;t!==L&&(2!==r.length?(r.forEach((t=>{t.uid!==e.uid&&(t.size?(t.size=i._calculateNewSize(a,l,t.size),d-=t.size):c.push(t))})),c.forEach((e=>{const t=d/c.length;e.size=t}))):r[0].size=null)},_calculateNewSize:function(e,t,n){const i=t/e;let r,o="px";return function(e){return s.test(e)}(n)&&(o="%"),"string"==typeof n&&(r=+n.replace(o,"")),`${r*i}${o}`},_getSiblings:function(e){return this._findPaneByUid(e.parentUid).panes.filter((t=>!1!==t.visible&&t.uid!==e.uid&&t.unpinnable&&!0!==t.unpinnable.unpinned))}});o.plugin(ie)}(window.kendo.jQuery);kendo;!function(e){let t=kendo.ui.Widget,n=kendo.ui.AIPromptBaseView=t.extend({init:function(e,n){let i=this;t.fn.init.call(i,e,n),i.aiprompt=e.getKendoAIPrompt(),i.contentElement=i.options.contentElement,i.footerElement=i.options.footerElement,i.buttonText=i.options.buttonText,i.buttonIcon=i.options.buttonIcon},options:{name:"AIPromptBaseView",buttonText:"",buttonIcon:""},render:function(){this._renderContent(),this._renderFooter()},_renderContentElement:function(){let t=this,n=e("<div></div>").addClass("k-prompt-content");return t.contentElement=n,t.element.append(n),t.contentElement},_renderFooterElement:function(){let t=this,n=e("<div></div>").addClass("k-prompt-footer");return t.footerElement=n,t.element.append(n),t.footerElement},destroy:function(){let e=this;t.fn.destroy.call(e),e.contentElement&&(e.contentElement.off(),kendo.destroy(e.contentElement),e.contentElement.remove()),e.footerElement&&(e.footerElement.off(),kendo.destroy(e.footerElement),e.footerElement.remove())}}),i=({suggestions:e,promptSuggestionItemTemplate:t,messages:n})=>`<div class="k-prompt-view">\n        <textarea ref-prompt-input></textarea>\n        ${e?.length?`<div class="k-prompt-expander">\n                <button ref-prompt-suggestions-button aria-expanded="true">${n.promptSuggestions}</button>\n                <div class="k-prompt-expander-content" role="list">\n                    ${e.map((e=>t({suggestion:e}))).join("")}\n                </div>\n            </div>`:""}\n    </div>`,r=({messages:e})=>`<div class="k-actions k-actions-start k-actions-horizontal k-prompt-actions">\n        <button ref-generate-output-button>${e.generateOutput}</button>\n    </div>`,o=({suggestion:e})=>`<div role="listitem" class="k-prompt-suggestion">${e}</div>`;kendo.ui.AIPromptPromptView=n.extend({init:function(e,t){let i=this;n.fn.init.call(i,e,t),i.promptSuggestions=i.options.promptSuggestions,i.promptSuggestionItemTemplate=kendo.template(i.options.promptSuggestionItemTemplate||o)},options:{name:"AIPromptPromptView",buttonIcon:"sparkles"},_renderContent:function(){let e=this,t=e.promptSuggestions,n=e.promptSuggestionItemTemplate,r=kendo.template(e.options.viewTemplate||i)({suggestions:t,promptSuggestionItemTemplate:n,messages:e.options.messages});e._renderContentElement(),e.contentElement.append(r)},_renderFooter:function(){let e=this,t=kendo.template(e.options.footerTemplate||r)({messages:e.options.messages});e._renderFooterElement(),e.footerElement.append(t)},setTextAreaValue:function(e){this.contentElement.find("textarea[ref-prompt-input]").getKendoTextArea().value(e)},_focusSuggestion(e){e&&e.length&&(this.contentElement.find(".k-prompt-suggestion[tabindex=0]").attr("tabindex","-1"),e.attr("tabindex","0").trigger("focus"))},initializeComponents:function(){let t=this,n=t.promptSuggestions;if(t.contentElement.find("textarea[ref-prompt-input]").kendoTextArea({resize:"vertical",placeholder:t.options.messages.promptPlaceholder}),t.footerElement.find("button[ref-generate-output-button]").kendoButton({icon:"sparkles",themeColor:"primary",rounded:"full",click:function(e){t.aiprompt.trigger("promptRequest",{isRetry:!1,prompt:t.contentElement.find("textarea[ref-prompt-input]").getKendoTextArea().value()})}}),n?.length){t.contentElement.find(".k-prompt-suggestion").first().attr("tabindex","0");let n=kendo.guid(),i=t.contentElement.find(".k-prompt-expander button[ref-prompt-suggestions-button]");t.contentElement.find(".k-prompt-expander button[ref-prompt-suggestions-button]").attr("aria-controls",n),i.next(".k-prompt-expander-content").attr("id",n),t.contentElement.find(".k-prompt-expander button[ref-prompt-suggestions-button]").kendoButton({icon:"chevron-up",fillMode:"flat",click:function(t){let n=e(t.target).closest(".k-prompt-expander").find(".k-prompt-expander-content"),i=t.sender.element.find(".k-icon");kendo.ui.icon(i,n.is(":visible")?"chevron-down":"chevron-up"),n.toggle(),t.sender.element.attr("aria-expanded",n.is(":visible"))}}),t.contentElement.on("click",".k-prompt-suggestion",(function(n){t.setTextAreaValue(e(n.target).text())})),t.contentElement.on("keydown",".k-prompt-suggestion",(function(n){if(40===n.keyCode||38===n.keyCode||36===n.keyCode||35===n.keyCode||13===n.keyCode||32===n.keyCode){n.preventDefault();let i,r,o=e(n.target),a=o.siblings();40===n.keyCode&&(i=o.next(),t._focusSuggestion(i)),38===n.keyCode&&(r=o.prev(),t._focusSuggestion(r)),36===n.keyCode&&(r=a.first(),t._focusSuggestion(r)),35===n.keyCode&&(i=a.last(),t._focusSuggestion(i)),13!==n.keyCode&&32!==n.keyCode||t.setTextAreaValue(e(n.target).text())}}))}},render:function(){let e=this;e._renderContent(),e._renderFooter(),e.initializeComponents()}});let a=({output:e,showOutputRating:t,messages:n})=>`\n    <div role="listitem" tabindex="0" class="k-card" data-id="${e.id}" >\n        <div class="k-card-header">\n            <div class="k-card-title">${n.outputTitle}</div>\n            <div class="k-card-subtitle">${e.prompt}</div>\n        </div>\n        <div class="k-card-body">\n            <p class="k-white-space-pre-line">${e.output}</p>\n        </div>\n        <div class="k-actions k-actions-start k-actions-horizontal k-card-actions">\n            <button ref-copy-button>${n.copyOutput}</button>\n            <button ref-retry-button>${n.retryGeneration}</button>\n\n            <span class="k-spacer"></span>\n            ${t?`\n            <button ref-rate-positive title=${n.ratePositive?n.ratePositive:"Helpful"}>${n.ratePositive}</button>\n            <button ref-rate-negative title=${n.rateNegative?n.rateNegative:"Unhelpful"}>${n.rateNegative}</button>\n            `:""}\n        </div>\n    </div>`,s=({promptOutputs:e,showOutputRating:t,messages:n})=>`<div class="k-prompt-view"><div role="list" class="k-card-list">\n    ${e?e.map((e=>a({output:e,showOutputRating:t,messages:n}))).join(""):""}\n    </div></div>`;kendo.ui.AIPromptOutputView=n.extend({init:function(e,t){let i=this;n.fn.init.call(i,e,t),i.promptOutputs=(i.options.promptOutputs||[]).map((e=>(e.id=e.id||kendo.guid(),e))),i.showOutputRating=i.options.showOutputRating},options:{name:"AIPromptOutputView",buttonIcon:"comment",promptOutputs:[]},addPromptOutput:function(e){e.id=e.id||kendo.guid(),this.promptOutputs.unshift(e),this.renderPromptOutput(e)},renderPromptOutput:function(t){let n=this,i=n.options.showOutputRating,r=n.options.messages,o=e(kendo.template(a)({output:t,showOutputRating:i,messages:r}));n.outputsContainer.append(o),n.initializeComponents(o)},_renderContent:function(){let t=this,n=t.promptOutputs,i=t.options.showOutputRating,r=t.options.messages,o=kendo.template(t.viewTemplate||s)({promptOutputs:n,showOutputRating:i,messages:r});t.outputsContainer=e(o),t._renderContentElement(),t.contentElement.append(t.outputsContainer)},_getOutputFromElement:function(t){let n=e(t).closest(".k-card").data("id");return this.promptOutputs.find((e=>e.id===n))},initializeComponents:function(e){let t=this;(e=e||t.contentElement).find("[ref-copy-button]").kendoButton({icon:"copy",fillMode:"flat",themeColor:"primary",click:function(e){let n=t._getOutputFromElement(e.target);t.aiprompt.trigger("outputCopy",{output:n,prompt:n.prompt})||navigator.clipboard&&"function"==typeof navigator.clipboard.writeText&&navigator.clipboard.writeText(n.output)}}),e.find("[ref-retry-button]").kendoButton({icon:"arrow-rotate-cw",fillMode:"flat",click:function(e){let n=t._getOutputFromElement(e.target);t.aiprompt.trigger("promptRequest",{isRetry:!0,prompt:n.prompt,output:n})}}),t.options.showOutputRating&&(e.find("[ref-rate-positive]").kendoButton({icon:"thumb-up-outline",fillMode:"flat",click:function(e){let n=t._getOutputFromElement(e.target);t.aiprompt.trigger("outputRatingChange",{rateType:"positive",output:n}),kendo.ui.icon(e.sender.element.find(".k-icon"),"thumb-up"),kendo.ui.icon(e.target.next("[ref-rate-negative]").find(".k-icon"),"thumb-down-outline")}}),e.find("[ref-rate-negative]").kendoButton({icon:"thumb-down-outline",fillMode:"flat",click:function(e){let n=t._getOutputFromElement(e.target);t.aiprompt.trigger("outputRatingChange",{rateType:"negative",output:n}),kendo.ui.icon(e.sender.element.find(".k-icon"),"thumb-down"),kendo.ui.icon(e.target.prev("[ref-rate-positive]").find(".k-icon"),"thumb-up-outline")}}))},render:function(){let t=this;t._renderContent(),t.initializeComponents(),t.contentElement.on("keydown",".k-card",(function(n){let i=e(n.target);40!==n.keyCode&&38!==n.keyCode&&36!==n.keyCode&&35!==n.keyCode||(n.preventDefault(),40===n.keyCode&&i.next(".k-card").trigger("focus"),38===n.keyCode&&i.prev(".k-card").trigger("focus"),36===n.keyCode&&t.contentElement.find(".k-card").first().trigger("focus"),35===n.keyCode&&t.contentElement.find(".k-card").last().trigger("focus"))}))}}),kendo.ui.AIPromptCommandsView=n.extend({options:{name:"AIPromptCommandsView",buttonText:"",buttonIcon:"more-horizontal",promptCommands:[]},initializeComponents:function(){let t=this,n=t.options.promptCommands,i=e("<div></div>").kendoPanelBar({animation:!1,dataSource:n,selectable:!1,select:function(n){let i=e(n.item),r=this.dataItem(i);r.hasChildren||t.aiprompt.trigger("commandExecute",{sender:t.aiprompt,item:r})}});const r=e("<div class='k-prompt-view'>");r.append(i),t.contentElement.append(r)},render:function(){this._renderContentElement(),this.initializeComponents()}});let l=()=>"";kendo.ui.AIPromptCustomView=n.extend({options:{name:"AIPromptCustomView",buttonText:"",buttonIcon:"",viewTemplate:l,footerTemplate:l},initializeComponents:function(){let e=this;"function"==typeof e.options.initializeComponents&&e.options.initializeComponents.call(e)},_renderContent:function(){let e=this,t=kendo.template(e.options.viewTemplate)({aiprompt:e});e._renderContentElement(),e.contentElement.append(t)},_renderFooter:function(){let e=this;if(e.options.footerTemplate===l)return;let t=kendo.template(e.options.footerTemplate)({messages:e.options.messages});e._renderFooterElement(),e.footerElement.append(t)},render:function(){let e=this;e._renderContent(),e._renderFooter(),e.initializeComponents()}})}(window.kendo.jQuery);kendo;!function(e){let t=window.kendo,n=t.ui.Widget,i=t.ui,r=e.extend,o="focus",a="k-prompt",s={prompt:{type:"kendo.ui.AIPromptPromptView",name:"prompt",buttonIcon:"sparkles"},output:{type:"kendo.ui.AIPromptOutputView",name:"output",buttonIcon:"comment"},commands:{type:"kendo.ui.AIPromptCommandsView",name:"commands",buttonIcon:"more-horizontal"},custom:{type:"kendo.ui.AIPromptCustomView",name:"custom"}},l=n.extend({init:function(e,i){let r=this;i=i||{},n.fn.init.call(r,e,i),0==r.options.views.length&&(r.options.views=["prompt","output"],this.options.promptCommands&&this.options.promptCommands.length&&this.options.views.push("commands")),r.promptOutputs=r.options.promptOutputs||[],r._initLayout(),r._initViews(),r._initToolbar(),r.activeView(r.options.activeView),t.notify(r)},options:{name:"AIPrompt",enabled:!0,toolbarItems:[],promptOutputs:[],activeView:0,views:[],popup:null,messages:{promptView:"Ask AI",outputView:"Output",commandsView:"",customView:"Custom View",promptPlaceholder:"Ask or generate content with AI",promptSuggestions:"Prompt Suggestions",generateOutput:"Generate",outputTitle:"Generated with AI",outputRetryTitle:"Generated with AI",copyOutput:"Copy",retryGeneration:"Retry",ratePositive:"",rateNegative:""},showOutputRating:!0},events:["commandExecute","promptRequest","outputRatingChange","outputCopy"],_initializeView:function(e){let n,i=this.views[e];if(i){let e=i.type;if("string"==typeof e&&(e=t.getter(i.type)(window)),!e)throw new Error("There is no such view");n=new e(this.element,r(!0,{promptSuggestions:this.options.promptSuggestions,promptCommands:this.options.promptCommands,promptOutputs:this.promptOutputs,showOutputRating:this.options.showOutputRating,messages:this.options.messages,promptSuggestionItemTemplate:this.options.promptSuggestionItemTemplate},i))}return n},_unbindView:function(e){e&&e.destroy()},_initViews:function(){let e=this,t=e.options.views;e.views={},e.viewsArray=[];for(let n=0,i=t.length;n<i;n++){let i=t[n],r="object"==typeof i,o=i;r&&(o="string"!=typeof i.type?i.name:i.type);let a=s[o];a&&(r&&(i.type=a.type),a.buttonText=e.options.messages[`${o}View`]),i=Object.assign({title:i.title,name:o,index:n},a,r?i:{}),e.viewsArray.push(i),o&&(e.views[o]=i)}},getViews:function(){return this.viewsArray},activeView:function(t){let n=this;if(void 0===t)return n._activeViewIndex;if(Number.isInteger(t)&&(t=n.viewsArray[t].name),t&&n.views[t]){n._selectedView&&n._unbindView(n._selectedView),n._selectedView=n._initializeView(t),n._activeViewIndex=n.viewsArray.findIndex((e=>e.name===t)),n._selectedView.render(),n._updateToolbarState(n._activeViewIndex);let i=e(n.toolbar._getAllItems()[n._activeViewIndex]);n.toolbar._resetTabIndex(i),i.trigger(o)}},addPromptOutput:function(e){if(e.id=e.id||t.guid(),this.promptOutputs.unshift(e),"function"==typeof this._selectedView.renderPromptOutput)return this._selectedView.renderPromptOutput(e)},_updateToolbarState:function(t){let n=this.toolbar;n.element.find(".k-toolbar-toggle-button").each((function(i,r){n.toggle(e(r),i==t)}))},_initLayout:function(){let t=this,n=e("<div></div>").addClass("k-prompt-header");t.header=n,t.element.addClass(a),t.element.append(n);const i=t.element.closest(".k-popup");i.length&&e(i).addClass("k-prompt-popup")},_getViewTools:function(){let e=this;return e.viewsArray.map((t=>("commands"===t.name&&(t.buttonText?t.title=t.buttonText:t.title="More Actions"),{type:"button",text:t.buttonText,icon:t.buttonIcon,fillMode:"flat",themeColor:"primary",rounded:"full",togglable:!0,attributes:{title:t.title},toggle:function(){e.activeView(t.name)}})))},_initToolbar:function(){let t=this,n=t.options.toolbarItems;n=Array.isArray(n)?n:[n];const i=n.find((e=>"x"===e.icon));i&&(i.themeColor="base");let r=e("<div></div>").kendoToolBar({resizable:!1,fillMode:"flat",items:t._getViewTools().concat(n)}).appendTo(t.header);t.toolbar=r.data("kendoToolBar")},focus:function(){this.element.trigger(o)},destroy:function(){let e=this;e.toolbar?.destroy(),e._selectedView?.destroy(),e.element.off(".kendoAIPrompt"),n.fn.destroy.call(e)}});i.plugin(l)}(window.kendo.jQuery);kendo;!function(e){const t=window.kendo,n=t.ui.treelist.ContextMenu,i=e.extend;let r=n.extend({init:function(e,t){n.fn.init.call(this,e,t)},defaultItems:{separator:{name:"separator",separator:!0},copy:{name:"copy",text:"Copy",icon:"copy",command:"CopyCommand",softRules:"windowHasSelection",options:"copy:selection"},copyName:{name:"copyName",text:"Copy Name",icon:"file-txt",command:"CopyCommand",options:"copy:name"},copyDeclaration:{name:"copyDeclatarion",text:"Copy Declaration",icon:"file-data",command:"CopyCommand",options:"copy:declaration"},resize:{name:"resize",text:"Resize Column",icon:"arrows-left-right",rules:"isResizable",command:"ResizeColumnCommand",softRules:"isNotGroupColumn"},reset:{name:"reset",text:"Reset",icon:"arrow-rotate-ccw",command:"ResetCommand",rules:"isEditable",softRules:"isDirty;isNotInEditMode"},expandItem:{name:"expandItem",text:"Expand Item",icon:"folder-open",softRules:"isExpandable",command:"ToggleItemCommand",options:"expand:true"},collapseItem:{name:"collapseItem",text:"Collapse Item",icon:"folder",softRules:"isCollapsible",command:"ToggleItemCommand",options:"expand:false"}}});t.ui.propertygrid=t.ui.propertygrid||{},i(t.ui.propertygrid,{ContextMenu:r})}(window.kendo.jQuery),function(e){let t=window.kendo,n=e.extend,i=t.Class,r=t.keys,o=i.extend({init:function(e){this.options=e,this.propertyGrid=e.propertyGrid}}),a=o.extend({exec:function(){const e=this,t=e.options,n=e.propertyGrid,i=e.options.target.closest("tr"),r=n.dataItem(i);if("selection"==t.copy){let e=window.getSelection().getRangeAt(0).toString();navigator.clipboard.writeText(e)}else if("name"==t.copy)navigator.clipboard.writeText(r.field);else if("declaration"==t.copy){let t=e.propertyGrid._objectFromNodes(r),n=[r.field,JSON.stringify(t[r.field]),r.description].filter((e=>undefined!==e)).join("\t");navigator.clipboard.writeText(n)}}}),s=o.extend({exec:function(){let e=this,t=e.propertyGrid,n=e.options.target.closest("tr"),i=t.dataItem(n);t.dataSource.cancelChanges(i),t.trigger("cancel",{type:"cancel",model:i,container:e.options.target}),t._render()}}),l=o.extend({_actionButtonsTemplate:function({apply:e,cancel:n,insertButtonIcon:i,cancelButtonIcon:r}){return'<div class="k-actions k-actions-start k-actions-horizontal k-window-buttons">'+t.html.renderButton(`<button class="k-dialog-apply">${e}</button>`,{themeColor:"primary",icon:i})+t.html.renderButton(`<button class="k-dialog-close">${n}</button>`,{icon:r})+"</div>"},exec:function(){let t,n,i=this,o=i.propertyGrid,a=i.options.target.index(),s=o.grouped?a-1:a,l=`tr:not(.k-table-group-row):first > td:nth-child(${a+1})`,c=o.table.find(l).outerWidth(),d={title:"Resize Column",visible:!1,resizable:!0,minWidth:350},u=o.table.width();function h(e){let n,i=t.wrapper.find(".k-form").data("kendoForm").options.formData.columnsize,r=t.wrapper.find("#columnsize").data("kendoNumericTextBox").value();i!=r?(i>r?(n=i-r,o.table.width(u-n)):(n=r-i,o.table.width(u+n)),o.columns[s].width=r,o.table.children("colgroup").find("col").eq(a).width(r),o.trigger("columnResize",{column:o.columns[s],oldWidth:i,newWidth:r}),p(e)):p(e)}function p(e){e.preventDefault(),n.destroy(),t.destroy()}!function(t){const n=e=>`tr:not(.k-table-group-row):first > td:nth-child(${e+1})`,i=t.table.children("colgroup").find("col").length;let r=[];for(let e=0;e<i;e++)r.push(t.table.find(n(e)).outerWidth());t.table.children("colgroup").find("col").each(((t,n)=>{e(n).width(r[t])}))}(i.propertyGrid),o.table.width(u),d.close=p,t=e("<div/>").appendTo(document.body).kendoWindow(d).data("kendoWindow"),n=i._createForm(t,c),t.element.after(e(i._actionButtonsTemplate({apply:"Apply",cancel:"Cancel",insertButtonIcon:"check",cancelButtonIcon:"cancel-outline"}))),t.wrapper.find(".k-dialog-apply").on("click",h).end().find(".k-dialog-close").on("click",p).end().find(".k-form-field input").on("keydown",(function(e){e.keyCode==r.ENTER?h(e):e.keyCode==r.ESC&&p(e)})).end(),t.center().open()},_createForm:function(t,n){return e("<div/>").appendTo(t.element).kendoForm({formData:{columnsize:n},validation:{validateOnBlur:!1,validaitonSummary:!1},renderButtons:!1,items:[{field:"columnsize",label:"Set column Size",editor:"NumericTextBox",editorOptions:{min:0}}]}).data("kendoForm")}}),c=o.extend({exec:function(){let e=this,t=e.propertyGrid,n=e.options.target;"true"===e.options.expand?t.expand(n):t.collapse(n)}}),d=o.extend({exec:function(){let e=this.propertyGrid,t=e.grouped;e.grouped=!t,e.grouped||e.wrapper.find("tr:not(.k-details-box)").removeClass("k-hidden"),e._refreshLayout(),e._updateDetails()}}),u=o.extend({exec:function(){let e=this.propertyGrid,t=e.visibleDetails;e.visibleDetails=!t,e.visible||e.table.find("tr.k-details-box").toggleClass("k-hidden")}}),h=o.extend({exec:function(){this.propertyGrid.saveAsExcel()}}),p=o.extend({exec:function(){this.propertyGrid.saveAsPDF()}});t.ui.propertygrid=t.ui.propertygrid||{},n(t.ui.propertygrid,{PropertyGridCommand:o,commands:{ResetCommand:s,CopyCommand:a,ResizeColumnCommand:l,ToggleItemCommand:c,ToggleGroupLayout:d,ToggleDetails:u,ExcelExport:h,PDFExport:p}})}(window.kendo.jQuery);!function(e){const t=window.kendo,n=t.ui,i=".kendoPropertyGrid",r=e.extend,o=t.dom,a=o.element,s=o.html,l=o.text,c=e.extend({F10:121},t.keys),d=n.Editable,u=n.TreeList,h=Array.isArray,p=e.isPlainObject,f="change",m="expand",g="collapse",v="groupExpand",_="groupCollapse",b="a[class*='-i-caret-alt-down']",y="k-grouping-row",w="tr",k="td",x=["copy","copyName","copyDeclaration","separator","reset","separator","resize","separator","expandItem","collapseItem","separator"],C={group:{name:"group",type:"button",text:"Group Items",togglable:!0,showText:"overflow",icon:"categorize",commandName:"ToggleGroupLayout",attributes:{title:"Group Items"},overflow:"never"},details:{name:"details",type:"button",text:"Toggle Info box",togglable:!0,icon:"info-circle",commandName:"ToggleDetails",showText:"overflow",attributes:{title:"Toggle Info box"},overflow:"never"},sort:{name:"sort",component:"DropDownList",componentOptions:{commandOn:f,dataTextField:"text",dataValueField:"value",dataSource:[{text:"Default Sort",value:"none"},{text:"Sort A-Z",value:"asc"},{text:"Sort Z-A",value:"desc"}]},attributes:{class:"k-property-grid-sort",title:"Sort"},overflow:"never"},search:{name:"search",component:"TextBox",componentOptions:{prefixOptions:{icon:"search"},placeholder:"Search..."},attributes:{class:"k-grid-search"},overflow:"never"},separator:{name:"separator",type:"separator"},spacer:{name:"spacer",type:"spacer"},excel:{name:"excel",type:"button",text:"Export to Excel",showText:!1,icon:"file-excel",commandName:"ExcelExport",overflow:"auto"},pdf:{name:"excel",type:"button",text:"Export to PDF",showText:!1,icon:"file-pdf",commandName:"PDFExport",overflow:"auto"}};function S(e){return null==e}function T(e){return"object"!=t.type(e)&&"function"!=t.type(e)}let D=t.data.TreeListDataSource.extend({groupedItemsTree:function(e){let n=this._childrenMap(this.view())[this._defaultParentId()]||[];return new t.data.Query(n).group({field:e}).toArray()},filterGroupedItemsTree:function(e,n){let i=this,r=this.sort()||{},o=e||{filters:[],logic:"or"},a=this._childrenMap(this.data())[this._defaultParentId()]||[],s=new t.data.Query(a).sort(r).group({field:n}).toArray(),l=function(e,n){let o=[];for(let t=0;t<n.length;t++)n[t].hasChildren&&l(e,i.childNodes(n[t])).length>0&&o.push(n[t]);return 0!=o.length?o:new t.data.Query(n).sort(r).filter(e).toArray()},c=[];return s.forEach((function(e){e.items&&(e.items=l(o,e.items)),c.push(e)})),c}});const A=t.ui.treelist.editor.extend({createEditable:function(){let e=this.options;this.fields[0].editor=e.model.editor,this.fields[0].editorOptions={...e.model.editorOptions},this.editable=new d(this.wrapper,{fields:this.fields,target:e.target,clearContainer:e.clearContainer,model:this.model,change:e.change})},destroy:function(){let e=this;e.editable.destroy(),e.editable.element.off().empty().removeAttr(t.attr("role")),e.model=e.wrapper=e.element=e.columns=e.editable=null}}),M=u.extend({init:function(e,n){const i=this;i._processOptions(n),i.options=r(!0,{},i.options,n),i._processedModel=i._processModel(),i._createDataSource(),u.fn.init.call(i,e,i.options),i._wrapper(),i._detailsBox(),i._groupable(),t.notify(i)},options:{name:"PropertyGrid",model:{},items:[],columns:[{field:"field"},{field:"value",editable:function(e){return T(e.value)}}],hasHeader:!1,groupable:!0,resizable:!0,contextMenu:!1,sortable:!0,selectable:!0,scrollable:!0,showDetails:!0,editable:"incell",size:"medium",defaultTools:[C.search,C.sort,C.group,C.details],messages:{defaultGroupName:"Other"}},events:["beforeEdit","edit",f,m,g,"columnResize",v,_,"cellClose","save","cancel","pdfExport"],defaultEditors:{string:"TextBox",date:"DatePicker",number:"NumericTextBox",boolean:"CheckBox"},_groupContentTemplate:({groupName:n,action:i,icon:r})=>`<p class="k-reset">${t.ui.icon(e('<a href="#" tabindex="-1" aria-label='+i+"></a>"),r)}${n}</p>`,_detailsTemplate:({description:e})=>`<span>${e||"&nbsp;"}</span>`,_setEditable:function(e){this.options.editable=e},_processOptions:function(e){const n=this;"boolean"!==t.type(e.editMode)||e.editMode?n._setEditable("incell"):n._setEditable(!1),S(e.toolbar)&&(e.toolbar=n.options.defaultTools),n._extendColumnOptions(e)},_extendColumnOptions:function(e){const t=this;e.columns&&(t.options.columns[0]=r(!0,e.columns.fieldColumn,t.options.columns[0]),t.options.columns[1]=r(!0,e.columns.valueColumn,t.options.columns[1]),delete e.columns)},_processSettings:function(e,t){const n=this;t.forEach((t=>{e[t.field]&&(r(e[t.field],t),e[t.field].items&&n._processSettings(e[t.field].value,e[t.field].items))}))},_processModel:function(){const e=this,t=e.options.model,n=e.options;let i=e._flatten(t);return e._setDefaults(i),e._processSettings(i,n.items),r=i,Object.entries(r).map((e=>e[1]));var r},_createDataSource:function(){const e=new D({data:this._processedModel,serverGrouping:!1,schema:{model:{id:"id",parentId:"parentId",expanded:!0,fields:{field:{editable:!1},value:{editable:!0}}}}});this.options.dataSource=e},_flatten:function(e){let n=1;function i(e,t,n,i,r){S(r)?n.forEach((n=>{e[`${t}.${n}`]=i[n]})):n.forEach((n=>{e[`${t}.${r}.${n}`]=i[n],e[`${t}.${r}.${n}`].parentId=e[`${t}.${r}`].id}))}function r(e,o){const a={};return Object.keys(e||{}).forEach((s=>{if(S(e[s]))a[s]={id:n++,parentId:o,propType:typeof e[s],field:s,value:e[s]};else if(function(e){return"object"==typeof e&&h(e)}(e[s]))!function(e,t,o,a){const s=t[o];e[o]={id:n++,parentId:a,propType:"Array",field:o,value:s};for(let a=0;a<s.length;a++){const l="object"==typeof s[a]?r(s[a],e[o].id):s[a];e[`${o}.${a}`]={id:n++,parentId:e[o].id,propType:typeof t[o],field:`${o}[${a}]`,value:l},"object"==typeof s[a]&&i(e,o,Object.keys(l),l,a)}}(a,e,s,o);else if(function(e){return"object"==typeof e&&!t.isDate(e)}(e[s])){let t=n++;const l=r(e[s],t),c=Object.keys(l);a[s]={id:t,parentId:o,propType:typeof e[s],field:s,value:l},i(a,s,c,l)}else{let i=t.parseDate(e[s].toString());a[s]={id:n++,parentId:o,propType:null!=i?typeof i:typeof e[s],field:s,value:null!=i?i:e[s]}}})),a}return r(e,null)},_setDefaults:function(e){const t=this;Object.keys(e).forEach((n=>{t.options.groupable&&!e[n].group&&(e[n].group=t.options.messages.defaultGroupName),t._setDefaultEditor(e[n])}))},_setDefaultEditor:function(e){const n=this;switch(t.type(e.value)){case"date":e.editor=n.defaultEditors.date;break;case"boolean":e.editor=n.defaultEditors.boolean;break;case"number":e.editor=n.defaultEditors.number;break;default:e.editor=n.defaultEditors.string}},_createIncellEditor:function(e,t){const n=this;let i=r({},t.columns[0]);return t.model.fields.value.validation=t.model.validation?t.model.validation.toJSON():{},delete i.parentColumn,new A(e,r({},{fieldRenderer:n._cellContent.bind(n),appendTo:n.wrapper,clearContainer:!1,target:n,columns:[i],model:t.model,change:t.change}))},_createDirtyTemplate:function(e){let n=this._customTemplateSettings();return t.template((function(n){return'<span class="k-dirty"></span>'+t.template(e.template)(e)}),n).bind({columnTemplate:e.template})},_cellContent:function(e,n){const i=this,r=i._isIncellEditable(),o="value"==e.field;let a,c,d;return o&&n.template?(d=n.dirty?i._createDirtyTemplate(n):t.template(n.template),a=d(n)):e.field?(a=n.get(e.field),c=r?e.dirtyIndicatorTemplate(n):"",S(a)?a=c:(n.format&&(a=t.format(n.format,a)),a=c+a)):S(a)&&(a=""),n.template?s(a):r?T(n.value)&&o?i._editableCellContent(a):s(a):l(a)},_editableCellContent:function(e){let t=a("b"),n=s(e);return t.children.push(n),t},_generateGroupRow:function(e){let n=t.template(this._groupContentTemplate)({groupName:e.value,action:e.visible?g:m,icon:e.visible?"caret-alt-down":"caret-alt-right"}),i=a(k,{className:"k-table-td",class:"k-table-td",colSpan:"3",role:"gridcell","aria-expanded":e.visible,visible:!0},[t.dom.html(n)]);return a(w,{className:"k-table-group-row k-grouping-row k-table-row",role:"row","data-uid":e.uid},[i])},_generateDetailsBox:function(){let e=a(k,{className:"k-table-td",class:"k-table-td",colSpan:this.grouped?3:2,role:"gridcell",visible:!0},[t.dom.html("<span>&nbsp;</span>")]);return a(w,{className:"k-details-box k-bottom k-sticky k-footer-template k-table-row "+(this.visibleDetails?"":"k-hidden"),role:"row"},[e])},_renderRows:function(e,t,n,i,r,o,a){const s=this;let l=i.length?i:s._selectedRowUid,c=[];s.grouped?(0===s.table.find(">colgroup>col.k-group-col").length&&s.table.find(">colgroup").prepend('<col class="k-group-col">'),s._groupedData.forEach((t=>{let i=s._generateGroupRow(t);c.push(i),c=c.concat(s._trs({columns:n,editedColumn:e.editedColumn,editedColumnIndex:e.editedColumnIndex,aggregates:e.aggregates,selected:l,data:t.items,childrenMap:r,viewChildrenMap:o,hasFooterTemplate:a,visible:t.visible,level:0}))}))):(s.table.find(">colgroup>col.k-group-col").remove(),c=c.concat(this._trs({columns:n,editedColumn:e.editedColumn,editedColumnIndex:e.editedColumnIndex,aggregates:e.aggregates,selected:l,data:t,childrenMap:r,viewChildrenMap:o,hasFooterTemplate:a,visible:!0,level:0}))),s.options.showDetails&&c.push(s._generateDetailsBox()),s._contentTree.render(c)},_generateRowOptions:function(e,t,n,i,r,o){const a=this;return{model:e,attr:t,level:n?a._renderedModelLevel(e,i):r,editedColumn:i.editedColumn,editedColumnIndex:i.editedColumnIndex,hasChildren:o,visible:i.visible,isAlt:this._absoluteIndex%2==0,grouped:a.options.groupable&&a.grouped}},_renderRow:function(e,t,n){let i=this._tds(e,t,n);if(e.grouped){let e=a(k,{class:"k-table-td k-group-cell",className:"k-table-td k-group-cell"});i.children.splice(0,0,e)}return i},editCell:function(t){const n=this;let i;t=e(t),i=n.grouped?n.cellIndex(t)-1:n.cellIndex(t);let r=n.columns[i],o=n.dataItem(t);n._isIncellEditable()&&o&&function(e,t){return!(!(e&&t&&e.field)||e.selectable||e.command||e.draggable||e.editable&&!e.editable(t))&&e.field&&t.editable&&t.editable(e.field)}(r,o)&&n._editCell(t,r,o,i)},_wrapper:function(){this.element.css("width",this.options.width),this.wrapper.addClass("k-property-grid")},_toolbar:function(){const e=this,n=e.options;let i=n.toolbar,r=this.toolbar;if(i)if(Array.isArray(i)){let t=e._processToolbarItems(i);t=e._verifyItems(t),r.kendoToolBar({size:"medium",resizable:!0,navigateOnTab:!n.navigatable,items:t}),r.find(".k-grid-search .k-input-inner").attr({placeholder:n.messages.commands.search,title:n.messages.commands.search}),e._attachToolbarHandlers()}else r.append(t.template(i)({}))},_attachToolbarHandlers:function(){const e=this;let t=e.toolbar.getKendoToolBar(),n=t.element.find('[data-command="sort"] input');t.bind("toggle",e._toolbarClick.bind(e)),t.bind("click",e._toolbarClick.bind(e)),n.length>0&&n.getKendoDropDownList().bind("change",e._sortItems.bind(e))},_verifyItems:function(e){const t=this;return t.options.groupable&&t.options.items.some((e=>e.hasOwnProperty("group")))||(e=e.filter((e=>"group"!=e.name))),t.options.showDetails&&t.options.selectable||!(e.findIndex((e=>"details"==e.name))>0)||(e=e.filter((e=>"details"!=e.name))),e},_getCommandType:function(e){return e.type?e.type:e.template?null:"button"},_processToolbarItems:function(e){const t=this,n=t.options.messages.commands;let i=[];return e.map((e=>{let o=(p(e)?e.name||"":e).toLowerCase(),a=n[o];if(!(o||p(e)&&e.template))throw new Error("Commands should have name specified");(e=r({},C[o],{name:o,text:a||(C[o]||{}).text,type:t._getCommandType(C[o]||{})},e)).imageClass&&(e.spriteCssClass=e.imageClass,e.iconClass=e.imageClass),e.attributes||(e.attributes={}),e.attributes["data-command"]=e.commandName||o,(e.menuButtons||e.buttons)&&delete e.name,e.click=e=>{let n=e.event||e.originalEvent;n&&(n.preventDefault(),n.stopPropagation()),t._commandClick({currentTarget:e.target})},e.className&&(e.attributes||(e.attributes={}),e.attributes.class=e.className),e.attributes.title=a||e.attributes.title,i.push(e)})),i},_toolbarClick:function(t){let i=e(t.target).data("command"),o=e(t.target).data("options");e(t.target).val()&&(o=r({},o,{value:e(t.target).val()})),i&&n.propertygrid.commands[i]&&this._action({command:i,options:o})},_sortItems:function(e){const t=this,n=t.dataSource,i=e.sender.value();let r="none"===i?{}:{field:"field",dir:i};n.sort(r),t._groupedData=n.filterGroupedItemsTree(n.filter(),"group").map((e=>({...e,visible:t._groupedData.filter((t=>t.value==e.value))[0].visible,uid:t._groupedData.filter((t=>t.value==e.value))[0].uid}))),t.grouped&&t.refresh()},_initContextMenu:function(){const e=this,t=e.options;if(!t.contextMenu)return;let i=p(t.contextMenu)&&h(t.contextMenu.body)?{items:t.contextMenu.body}:{items:x},o=p(t.contextMenu)?t.contextMenu:{};i=r({},{messages:t.messages,target:e.tbody,filter:".k-table-row:not(.k-grouping-row,.k-details-box) > .k-table-td",action:e._action.bind(e),states:e._buildStates()},o,i),e.tbodyContextMenu=new n.propertygrid.ContextMenu("<ul></ul>",i)},_buildStates:function(){return{isResizable:this.options.resizable,isEditable:this.options.editable,windowHasSelection:()=>void 0!==window.getSelection&&0!=window.getSelection().rangeCount&&""!=window.getSelection().getRangeAt(0).toString(),isDirty:e=>this.dataItem(e).dirty,isNotInEditMode:e=>!e.closest("td").hasClass("k-edit-cell"),isNotGroupColumn:e=>!e.closest("td").hasClass("k-group-cell"),isExpandable:e=>{let t=this.dataItem(e);return t&&t.hasChildren&&!t.expanded},isCollapsible:e=>{let t=this.dataItem(e);return t&&t.hasChildren&&t.expanded}}},_action:function(e){let t=e.command,i=r({propertyGrid:this},e.options);return new n.propertygrid.commands[t](i).exec()},_objectFromNodes:function(e){const t=this,n=Object.create(null),i=t.dataSource;return(e=h(e)?e:[e]).forEach((e=>{"Array"==e.propType?(n[e.field]=[],i.childNodes(e).forEach((r=>{n[e.field].push(r.hasChildren?t._objectFromNodes(i.childNodes(r)):r.value)}))):n[e.field]=e.hasChildren?t._objectFromNodes(i.childNodes(e)):e.value})),n},_groupable:function(){const n=this;n._groupedData=n.dataSource.groupedItemsTree("group").map((e=>({...e,visible:!0,uid:t.guid()}))),n._groupableClickHandler=function(t){let i=e(this),r=i.closest(w),o=n._groupedData.filter((e=>e.value===r.text()))[0];o.visible=!o.visible,i.is(b)?n.trigger(_,{group:o.items,element:r})||n.refresh():n.trigger(v,{group:o.items,element:r})||n.refresh(),t.preventDefault(),t.stopPropagation()},n.table.on("click"+i,".k-grouping-row a[class*='-i-caret-alt-right'], .k-grouping-row "+b,n._groupableClickHandler).on("keydown"+i,n._groupRowKeyDown.bind(n))},_groupRowKeyDown:function(e){const n=this,i=n.current();let r=!1;n.options.navigatable&&(e.keyCode==c.ENTER&&(t.focusElement(n.table),n._setCurrent(n._findCurrentCell()),r=!0),e.keyCode!=c.LEFT&&e.keyCode!=c.RIGHT||!e.altKey||(r=this._handleGroupRowExpandCollapse(i,e.keyCode)),r&&(e.preventDefault(),e.stopPropagation()))},_handleGroupRowExpandCollapse:function(e,t){const n=this,i=e.parent();if(i.is("."+y)){let e=n._groupedData.filter((e=>e.value===i.text()))[0].visible;if(e&&t==c.LEFT||!e&&t==c.RIGHT)return n._toggleGroup(i),!0}},_toggleGroup:function(e){let t=this._groupedData.filter((t=>t.value===e.text()))[0];t.visible=!t.visible,this.refresh()},_getGroupedData:function(e){let t=this;return t.dataSource.filterGroupedItemsTree(e,"group").map((e=>({...e,visible:!0,uid:t._groupedData.filter((t=>t.value==e.value))[0].uid})))},_search:function(e){let t=this,n=e.currentTarget;clearTimeout(t._searchTimeOut),t._searchTimeOut=setTimeout((function(){t._searchTimeOut=null;let e=t.options,i=e.search?e.search.fields:["field","value"],r={filters:[],logic:"or"},o=n.value;if(o)for(let e=0;e<i.length;e++)r.filters.push({field:i[e],operator:"contains",value:o});t._groupedData=t._getGroupedData(r,"group"),t.dataSource.filter(r),t._refreshLayout(),t._updateDetails()}),300)},_refreshLayout:function(){const t=this;t._selectedRowUid=t.select().removeClass("k-selected").map((function(t,n){return e(n).attr("data-uid")})),t._contentTree.render([]),t._render()},_detailsBox:function(){const e=this,t=e.options;e._detailsTemplate=t.detailsTemplate?t.detailsTemplate:e._detailsTemplate,t.showDetails&&(e.detailsContainer=e.wrapper.find("table > tr.k-details-box > td"),e.bind(f,e._updateDetails))},_updateDetails:function(){const e=this;if(!e.options.selectable)return;let n=e.dataItem(e.select());n?e.table.find("tr.k-details-box > td").html(t.template(e._detailsTemplate)(n)):e._clearDetails()},_clearDetails:function(){this.table.find("tr.k-details-box > td").html("<span>&nbsp;</span>")},model:function(e,t){const n=this;if(!e)return n._objectFromNodes(n.dataSource.rootNodes());n.options.model=e,t&&(n.options.items=t),n._processedModel=n._processModel(),n.setDataSource(new D({data:n._processedModel,serverGrouping:!1,schema:{model:{id:"id",parentId:"parentId",expanded:!0,fields:{field:{editable:!1},value:{editable:!0}}}}}))},selectItem:function(e){return this.select(e)},toggleItem:function(e){const t=this;t.dataItem(e).expanded?t.collapse(e):t.expand(e)},toggleGroup:function(t){e(t).is("."+y)&&this._toggleGroup(t)},toggleDetails:function(){this.options.showDetails&&this._action({command:"ToggleDetails"})},edit:function(e){this.editCell(e)},saveState:function(){this.saveChanges()},resetState:function(){this.cancelChanges()},setOptions:function(e){const n=this;let i=n.getOptions(),r=n.wrapper,o=n._events,a=n.element;delete i.model,t.deepExtend(i,e),n.model=n.options.model=e.model||{},n.destroy(),r[0]!==a[0]&&(r.before(a),r.remove()),a.empty(),n.init(a,i,o),n._setEvents(i)},destroy:function(){this.tbodyContextMenu&&(this.tbodyContextMenu.destroy(),this.tbodyContextMenu=null),u.fn.destroy.call(this)}});function E(){let e=this,t=this._depth(),n=this.data,i=[],r=[];if(this._hasFooterTemplate()||(this.collapsible=!1),e.options.widget.grouped){n=e.options.widget.dataSource.groupedItemsTree("group");let r=t+e.options.widget.columns.length;e.options._buildGroupedDataRows(n,i,r)}else e.options._buildDataRows(n,i,r);return this._prependHeaderRows(i),i}let I=t.Class.extend({init:function(t){t._buildDataRows=this._buildDataRows.bind(this),t._buildGroupedDataRows=this._buildGroupedDataRows.bind(this),this._instance=new Gn(t),this._instance._hierarchyRows=E.bind(this),t.columns=this._trimColumns(t.columns||[]),this.allColumns=e.map(this._leafColumns(t.columns||[]),(e=>this._prepareColumn(e))),this.columns=this._visibleColumns(this.allColumns),this.widget=t.widget,this.options=t,this.data=t.data||[],this.aggregates=t.aggregates||{},this.groups=[].concat(t.groups||[]),this.hasGroups=this.groups.length>0,this.hierarchy=t.hierarchy,this.hasGroupHeaderColumn=this.columns.some((function(e){return e.groupHeaderColumnTemplate})),this.collapsible=this.options.collapsible},_recursiveRows:function(e,t){let n=this,i=n.widget.dataSource.level(t);if(e.push(...n._dataRow(t,i+1,this._depth())),t.hasChildren){let i=n.widget.dataSource.childNodes(t);for(let t=0;t<i.length;t++){let n=i[t];this._recursiveRows(e,n)}}},_buildGroupedDataRows:function(e,t,n){for(let i=0;i<e.length;i++){let r=e[i];t.push({type:"group-header",cells:[{value:r.value,colSpan:n,background:"#dfdfdf",color:"#333"}],level:null});for(let e=0;e<r.items.length;e++){let n=r.items[e];this._recursiveRows(t,n)}}},_buildDataRows:function(e,t,n){let i,r=this,o=this._depth(),a=this.hierarchy.itemLevel,s=this.hierarchy.itemId,l=this._hasFooterTemplate(),c=0;for(let d=0;d<e.length;d++){let u=e[d],h=a(u,d);l&&(h>c?n.push({id:i,level:c}):h<c&&t.push(...r._hierarchyFooterRows(n,h,o)),c=h,i=s(u,d)),t.push(...r._dataRow(u,h+1,o))}if(l){t.push(...this._hierarchyFooterRows(n,0,o));let i=e.length?this.aggregates[e[0].parentId]:{};t.push(this._hierarchyFooter(i,0,o))}}});t.getAllMethods(Gn).forEach((e=>t.createProxyMember(I,e))),t.PropertyGridExcelExporter=t.ExcelExporter.extend({workbook:function(){return e.Deferred(function(e){this.dataSource.fetch().then(function(){let t=new I(r({},this.options,this._hierarchy(),{data:this.dataSource.view(),groups:this.dataSource.group(),aggregates:this.dataSource.aggregates()})).workbook();e.resolve(t,this.dataSource.view())}.bind(this))}.bind(this)).promise()}});let z={extend:function(t){t.events.push("excelExport"),t.options.excel=e.extend(t.options.excel,this.options),t.saveAsExcel=this.saveAsExcel},options:{proxyURL:"",filterable:!1,fileName:"Export.xlsx"},saveAsExcel:function(){let e=this.options.excel||{},n=new t.PropertyGridExcelExporter({widget:this,columns:this.columns,dataSource:this.dataSource,data:this.dataSource.data(),allPages:e.allPages,filterable:e.filterable,hierarchy:e.hierarchy,collapsible:e.collapsible});n.workbook().then(function(i,r){if(!this.trigger("excelExport",{workbook:i,data:r})){let r=new t.ooxml.Workbook(i);r.options||(r.options={}),r.options.skipCustomHeight=!0,r.toDataURLAsync().then((function(r){t.saveAs({dataURI:r,fileName:i.fileName||e.fileName,proxyURL:e.proxyURL,forceProxy:e.forceProxy}),n._restoreExpandedState()}))}}.bind(this))}};t.PropertyGridExcelMixin=z,t.ooxml&&t.ooxml.Workbook&&z.extend(M.prototype),t.ui.propertygrid=t.ui.propertygrid||{},r(t.ui.propertygrid,{defaultBodyContextMenu:x}),t.cssProperties.propertyDictionary.PropertyGrid=t.cssProperties.propertyDictionary.TreeList,t.cssProperties.registerPrefix("PropertyGrid","k-property-grid-"),t.ui.plugin(M)}(window.kendo.jQuery);kendo,kendo;!function(e){const t=window.kendo,n=t.dataviz,i=t.ui.Widget,r=i.extend({init:function(e,r){if(i.fn.init.call(this,e,r),!r.chart)throw new Error("ChartBreadcrumb: No Chart instance supplied as `options.chart`");this._attachChartEvents(),this._renderBreadcrumb(),t.notify(this,n.ui)},events:[],options:{name:"ChartBreadcrumb",rootItem:{type:"rootitem",icon:"home",text:"Home",showIcon:!0}},destroy:function(){this.breadcrumb&&(this.breadcrumb.destroy(),this.breadcrumb=null),this.chart&&(this.chart.unbind("drilldown",this._onChartDrilldown),this.chart.unbind("drilldownLevelChange",this._onChartDrilldownLevelChange),this.chart=null),i.fn.destroy.call(this)},_attachChartEvents(t){const n=this.options;if("function"==typeof n.chart.resetDrilldownLevel)this.chart=n.chart;else{if("string"!=typeof n.chart)throw new Error("ChartBreadcrumb: `options.chart` must be a Chart instance, element ID or a selector");if(this.chart=e(n.chart).getKendoChart()||e("#"+n.chart).getKendoChart(),!this.chart&&!t)return void setTimeout((()=>this._attachChartEvents(!0)))}this._onChartDrilldown=this._onChartDrilldown.bind(this),this.chart.bind("drilldown",this._onChartDrilldown),this._onChartDrilldownLevelChange=this._onChartDrilldownLevelChange.bind(this),this.chart.bind("drilldownLevelChange",this._onChartDrilldownLevelChange)},_renderBreadcrumb:function(){const n=e("<nav />");this.element.append(n),this.breadcrumb=new t.ui.Breadcrumb(n,{items:[this.options.rootItem]}),this.breadcrumb.bind("click",(e=>this._onBreadcrumbClick(e)))},_onBreadcrumbClick:function(e){if(!this.breadcrumb||!this.chart)return;const t=this.breadcrumb.items().findIndex((t=>t===e.item));this.chart.resetDrilldownLevel(t)},_onChartDrilldown:function(e){this.breadcrumb&&!e.isDefaultPrevented()&&this.breadcrumb.items([...this.breadcrumb.items(),{type:"item",text:e.point.category}])},_onChartDrilldownLevelChange:function(e){if(!this.breadcrumb)return;let t=this.breadcrumb.items();t=t.slice(0,e.level+1),this.breadcrumb.items(t)}});n.ui.plugin(r)}(window.kendo.jQuery);!function(e,t){var n=window.kendo;n.dataviz=n.dataviz||{},n.deepExtend(n.dataviz,n.deepExtend({},fZ));var i=".kendoChart",r=n.Class,o=n._outerWidth,a=n._outerHeight,s=n.dataviz,l=n.ui.Widget,c=n.data.DataSource,d=n.deepExtend,u=Array.isArray,h=e.extend,p=n.template,f=n.htmlEncode,m="mouseleave"+i,g=ON,v=g.LEGEND_ITEM_CLICK,_=g.LEGEND_ITEM_HOVER,b=g.LEGEND_ITEM_LEAVE,y=g.SERIES_CLICK,w=g.SERIES_HOVER,k=g.SERIES_OVER,x=g.SERIES_LEAVE,C=g.PANE_RENDER,S=g.PLOT_AREA_CLICK,T=g.PLOT_AREA_HOVER,D=g.PLOT_AREA_LEAVE,A=g.DRAG,M=g.DRAG_END,E=g.DRAG_START,I=g.DRILLDOWN,z="drilldownLevelChange",P=g.ZOOM_START,H=g.ZOOM,F=g.ZOOM_END,R=g.SELECT_START,L=g.SELECT,B=g.SELECT_END,O=g.RENDER,V=e(document.documentElement),N="change",$="dataBound",U="leave",W=g.PIE,j=g.DONUT,q=g.FUNNEL,G=n.Observable;kB.register({create:function(e,t){return new n.UserEvents(e,d({global:!0,multiTouch:!0,fastTap:!0},t))}});var K=n.ConvertClass(rR).extend({handlerMap:{showTooltip:"_showTooltip",hideTooltip:"_hideTooltip",legendItemClick:"_onLegendItemClick",render:"_onRender",init:"_onInit",drilldown:"_onDrilldown"}}),Y=l.extend({init:function(e,t){var i;n.destroy(e),l.fn.init.call(this,e),t&&(i=t.dataSource,delete t.dataSource),this.options=d({},this.options,t),this.wrapper=this.element,this._attachEvents(),t&&(t.dataSource=i),this._seriesVisibility=new ee,this.bind(this.events,this.options),this._initDataSource(t),this._drilldownState=[],n.notify(this,s.ui),this._showWatermarkOverlay&&this._showWatermarkOverlay(this.wrapper[0])},events:[$,I,z,y,w,k,x,"axisLabelClick",v,_,b,C,S,T,D,E,A,M,P,H,F,R,L,B,"noteClick","noteHover","noteLeave",O],options:{name:"Chart",renderAs:"",theme:"sass",axisDefaults:{},chartArea:{},legend:{},categoryAxis:{},autoBind:!0,seriesDefaults:{},series:[],seriesColors:null,tooltip:{},transitions:!0,valueAxis:{},plotArea:{},title:{},xAxis:{},yAxis:{},panes:[{}],pannable:!1,zoomable:!1,noData:!0,messages:{noData:"No data available"}},items:function(){return e()},refresh:function(){var e=this,t=e._instance;t.applyDefaults(e.options),t.applySeriesColors(),e._bindSeries(),e._bindCategories(),e.trigger($),e._redraw()},getSize:function(){return n.dimensions(this.element)},redraw:function(e){this._size=null,this._instance.redraw(e)},setOptions:function(e){var t=this,n=e.dataSource;delete e.dataSource,l.fn._setEvents.call(t,e),this._instance.applyOptions(e,this._getThemeOptions(e)),this.options=this._instance.options,this._tooltip.setOptions(this.options.tooltip),this._seriesVisibility.setOptions(this.options),this._sourceSeries=null,n&&t.setDataSource(n),t._hasDataSource?t._onDataChanged():(t._bindCategories(),t.redraw()),t._instance.updateMouseMoveHandler()},setDataSource:function(e){var t=this;t.dataSource.unbind(N,t._dataChangeHandler),t.dataSource=e=c.create(e),t._hasDataSource=!0,t._hasData=!1,e.bind(N,t._dataChangeHandler),t.options.autoBind&&e.fetch()},destroy:function(){var e=this,t=e.dataSource;e.element.off(i),t&&t.unbind(N,e._dataChangeHandler),e._instance&&(e._instance.destroy(),delete this._instance),this._tooltip&&(this._tooltip.destroy(),delete this._tooltip),this._destroyNoData(),this._destroyCrosshairTooltips(),l.fn.destroy.call(e)},findPaneByName:function(e){for(var t=this._plotArea.panes,n=0;n<t.length;n++)if(t[n].options.name===e)return new re(this,t[n])},findPaneByIndex:function(e){var t=this._plotArea.panes;if(t[e])return new re(this,t[e])},findSeries:function(e){for(var t=this._plotArea,n=t.srcSeries||t.series,i=0;i<n.length;i++)if(e(n[i]))return new oe(this,n[i])},findSeriesByName:function(e){return this._createSeries({name:e})},findSeriesByIndex:function(e){return this._createSeries({index:e})},exportVisual:function(e){var t=this._instance;if(t){var n;if(e&&(e.width||e.height)){var i=t.options.chartArea,r=t._originalOptions.chartArea;d(i,e);var o=t._getModel();i.width=r.width,i.height=r.height,o.renderVisual(),function(e){for(var t=0;t<e.length;t++)e[t].notifyRender()}(o._plotArea.panes),n=o.visual}else n=t.exportVisual();return n}},resetDrilldownLevel(e){e=e||0;const t=this._drilldownState;if(!t||e<0||e>t.length-1)return;const n={level:e,sender:this};this.trigger(z,n),this.options.series=this._drilldownState[e],this._drilldownState=this._drilldownState.slice(0,e),this._bindCategories(),this._redraw()},_createSeries:function(e){var t=this._seriesOptions(e);if(t)return new oe(this,t)},_seriesOptions:function(e){var t,n=this._plotArea,i=n.srcSeries||n.series;if(hR(e.index))t=i[e.index];else if(hR(e.name))for(var r=0;r<i.length;r++)if(i[r].name===e.name){t=i[r];break}return t},_attachEvents:function(){this.element.on(m,this._mouseleave.bind(this))},_mouseleave:function(t){var n=this._instance,i=this._tooltip,r=t.relatedTarget;r&&e(r).closest(i.element).length||!n||n.handlingTap||n.hideElements({keepTooltipOpen:!i.options.autoHide})},_getThemeOptions:function(e){var t=(e||{}).theme;if(t&&-1!==s.SASS_THEMES.indexOf(t.toLowerCase()))return s.autoTheme().chart;if(hR(t)){var n=s.ui.themes||{};return(n[t]||n[t.toLowerCase()]||{}).chart||{}}},_initChart:function(){this._createChart(this.options,this._getThemeOptions(this.options)),this.options=this._instance.options,this._seriesVisibility.setOptions(this.options)},_createChart:function(e,t){this._instance=new gj(this.element[0],e,t,{observer:new rR(this,{showTooltip:"_showTooltip",hideTooltip:"_hideTooltip",legendItemClick:"_onLegendItemClick",render:"_onRender",init:"_onInit",drilldown:"_onDrilldown"}),sender:this,rtl:this._isRtl()})},_onInit:function(e){this._instance=e.sender},_initDataSource:function(e){var t=this,n=(e||{}).dataSource;t._dataChangeHandler=t._onDataChanged.bind(t),t.dataSource=c.create(n).bind("change",t._dataChangeHandler),t._bindCategories(),n&&(t._hasDataSource=!0),this._initNoData(),this._initChart(),this._initTooltip(),n&&t.options.autoBind&&t.dataSource.fetch()},_destroyCrosshairTooltips:function(){var e=this._crosshairTooltips;if(e)for(var t in e)e[t].destroy();this._crosshairTooltips={}},_getCrosshairTooltip:function(e,t){var n=this._crosshairTooltips=this._crosshairTooltips||{},i=e+t,r=n[i];return r||(r=n[i]=new ie(this.element)),r},_showTooltip:function(e){e.crosshair?this._getCrosshairTooltip(e.axisName,e.axisIndex).show(e):this._tooltip&&this._tooltip.show(e)},_hideTooltip:function(e){e.crosshair?this._getCrosshairTooltip(e.axisName,e.axisIndex).hide():this._tooltip&&this._tooltip.hide()},_onRender:function(e){this._destroyCrosshairTooltips(),this._copyMembers(e.sender),this._hasDataSource&&!this._hasData&&this.options.autoBind||this.trigger(O)},_copyMembers:function(e){this.options=e.options,this._originalOptions=e._originalOptions,this.surface=e.surface,this._plotArea=e._plotArea,this._model=e._model,this._highlight=e._highlight,this._selections=e._selections,this._pannable=e._pannable,this._zoomSelection=e._zoomSelection,this._mousewheelZoom=e._mousewheelZoom},requiresHandlers:function(e){for(var t=this._events,n=0;n<e.length;n++)if(hR(t[e[n]]))return!0},_initTooltip:function(){this._tooltip=this._createTooltip(),this._tooltip.bind(U,this._tooltipleave.bind(this))},_onLegendItemClick:function(e){this.trigger(v,e)||this._legendItemClick(e.seriesIndex,e.pointIndex)},_legendItemClick:function(t,n){var i=this._instance,r=i._plotArea,o=(r.srcSeries||r.series)[t];if(i._hasInactiveOpacity()&&i._activeChartInstance&&(i._updateSeriesOpacity(null,!0),i._applySeriesOpacity(i._activeChartInstance.children,null,!0),i._activeChartInstance=null),e.inArray(o.type,[W,j,q])>=0){var a=o.data[n];if(a&&hR(a.visible))a.visible=!a.visible;else{var s=o.pointVisibility=o.pointVisibility||{},l=s[n];s[n]=!!hR(l)&&!l}}else o.visible=!o.visible,this._seriesVisibility.save(o);i._noTransitionsRedraw()},_createTooltip:function(){return new ne(this.element,h({},this.options.tooltip,{rtl:this._isRtl()}))},_tooltipleave:function(){this._instance&&this._instance.hideElements()},_onDrilldown:function(e){const{series:t,value:n}=e;if(t.drilldownSeriesFactory){const i=t.drilldownSeriesFactory(n);if(!i)return;i instanceof Promise?i.then((t=>this._onDrilldownData(e,t))):this._onDrilldownData(e,i)}else"object"==typeof n&&this._onDrilldownData(e,n)},_onDrilldownData:function(e,t){const n=Object.assign({},e.series,t),i={point:e.point,series:e.series,drilldownSeries:n,sender:this};this.trigger(I,i)||(this._drilldownState.push(this.options.series),this.options.series=[n],this._bindCategories(),this._redraw())},_bindData:function(e){var t,n,i,r=this,o=r.options,a=r._sourceSeries||o.series,s=a.length,l=r.dataSource.view(),c=(r.dataSource.group()||[]).length>0,d=[],u=this._seriesVisibility;for(u.read(),t=0;t<s;t++)n=a[t],r._isBindable(n)&&c?(i=J(n,l),d=d.concat(i),u.applyByGroup(i,e)):(n=h({},n),d.push(n),u.applyByIndex(n,e));r._sourceSeries=a,o.series=d,this._instance.applySeriesColors(),r._bindSeries(),r._bindCategories(),this._hasData=!0},_initNoData:function(){if(this._noData||!1===this.options.noData)return;const t=e("<div class='k-chart-overlay'></div>");this._noData=t.hide().appendTo(this.wrapper);const i=e("<div class='k-no-data'></div>");i.appendTo(this._noData);const r=this.options.noData?.template||(()=>f(this.options.messages.noData));if(r){const e="function"!=typeof r?n.template(r):r;i.html(e({}))}},_destroyNoData:function(){this._noData&&(n.destroy(this._noData),this._noData.remove(),delete this._noData,delete this._noDataContent)},_onDataChanged:function(e){this._bindData(e),this.dataSource.total()>0&&this._destroyNoData(),this.trigger($),this._instance&&this._instance.fontLoaded&&this._redraw()},_bindSeries:function(){var e,t,n,i,r=this,o=r.dataSource.view(),a=r.options.series,s=a.length;for(e=0;e<s;e++)t=a[e],r._isBindable(t)&&(n=t._groupIx,i=hR(n)?(o[n]||{}).items:o,!1!==t.autoBind&&(t.data=i))},_bindCategories:function(){var e,t,n=this,i=n.dataSource.view()||[],r=(n.dataSource.group()||[]).length>0,o=i,a=n.options,s=[].concat(a.categoryAxis);for(r&&i.length&&(o=i[0].items),e=0;e<s.length;e++)!1!==(t=s[e]).autoBind&&n._bindCategoryAxis(t,o,e)},_bindCategoryAxis:function(e,t,n){var i,r,o,a=(t||[]).length;if(e.field)for(e.categories=[],i=0;i<a;i++)o=t[i],r=jO(e.field,o),0===i?(e.categories=[r],e.dataItems=[o]):(e.categories.push(r),e.dataItems.push(o));else this._instance&&this._instance.bindCategoryAxisFromSeries(e,n)},_isBindable:function(e){var t,n,i=qO.current.valueFields(e),r=!0;for(n=0;n<i.length;n++)if("value"===(t=i[n])?t="field":t+="Field",!hR(e[t])){r=!1;break}return r},_isRtl:function(){return n.support.isRtl(this.element)&&"rtl"===this.element.css("direction")}}),Q=["getAxis","findAxisByName","plotArea","toggleHighlight","showTooltip","hideTooltip","_resize","_redraw","_noTransitionsRedraw","_legendItemHover","_eventCoordinates"];function X(e){Y.fn[e]=function(){var t=this._instance;if(t)return t[e].apply(t,arguments)}}for(var Z=0;Z<Q.length;Z++)X(Q[Z]);function J(e,i){var r,o,a,s=[],l=e.groupNameTemplate,c=i.length;if(0===c)return(a=d({},e)).visibleInLegend=!1,[a];for(hR(l)?(n.logToConsole("'groupNameTemplate' is obsolete and will be removed in future versions. Specify the group name template as 'series.name'"),l&&(r=p(l))):r=p(e.name||(({group:t})=>`${hR(e.name)?t.value+": "+e.name:t.value}`)),o=0;o<c;o++)a=d({},e),n.isFunction(a.color)||(a.color=t),a._groupIx=o,a._groupValue=i[o].value,s.push(a),r&&(a.name=r({series:a,group:i[o]}));return s}s.ExportMixin.extend(Y.fn),n.PDFMixin&&n.PDFMixin.extend(Y.fn),s.ui.plugin(Y);var ee=r.extend({init:function(){this.groups={},this.index={},this.options={}},applyByGroup:function(e,t){if(t&&t.action||this.options.persistSeriesVisibility)for(var n=0;n<e.length;n++)!1===this.groups[e[n]._groupValue]&&(e[n].visible=!1);else this.groups={}},applyByIndex:function(e,t){t&&t.action||this.options.persistSeriesVisibility?!1===this.index[e.index]&&(e.visible=!1):this.index={}},save:function(e){e&&(this.options.persistSeriesVisibility?this.options.series[e.index].visible=e.visible:this.saveState(e))},setOptions:function(e){this.options=e,this.groups={},this.index={}},read:function(){var e=this.options;if(e.persistSeriesVisibility)for(var t=e.series,n=0;n<t.length;n++)this.saveState(t[n])},saveState:function(e){hR(e._groupValue)?this.groups[e._groupValue]=e.visible:this.index[e.index]=e.visible}}),te=n.geometry;var ne=G.extend({init:function(t,i){var r=this;G.fn.init.call(r),this.setOptions(i),r.chartElement=t,r.template=ne.template,r.template||(r.template=ne.template=({autoHide:t,rtl:i,font:r,border:o,opacity:a})=>`<div class='k-tooltip ${t?"k-tooltip-closable":""} k-chart-tooltip ${i?"k-rtl":""}' ${n.attr("style-display")}="none" ${n.attr("style-position")}="absolute" ${n.attr("style-font")}="${r}" ${n.attr("style-opacity")}="${a}" `+(o?`${n.attr("style-border")}="${o.width}px solid" `:"")+'><div class="k-tooltip-content"></div>'+(t?"":'<div class="k-tooltip-button">'+n.ui.icon(e('<a href="#" title="Close"></a>'),{icon:"x"})+"</div>")+"</div>"),r.element=e(r.template(r.options)),n.applyStylesFromKendoAttributes(r.element,["display","position","font","border","opacity"]),r.move=r.move.bind(r),r._mouseleave=r._mouseleave.bind(r);var o=n.format("[{0}='content'],[{0}='scroller']",n.attr("role"));r._mobileScroller=t.closest(o).data("kendoMobileScroller"),r.downEvent=n.applyEventMap("down",n.guid()),r._closeTooltipHandler=r._closeTooltip.bind(r)},destroy:function(){this._clearShowTimeout(),V.off(this.downEvent,this._closeTooltipHandler),this.element&&(this.element.off(m).remove(),this.element=null)},setOptions:function(e){this.options=d({},this.options,e)},options:{opacity:1,animation:{duration:150},sharedTemplate:({colspan:e,categoryText:t,points:i,content:r,colorMarker:o,nameColumn:a})=>`<table><th colspan='${e}'>${t}</th>`+function(e,t,i,r){for(var o="",a=0;a<e.length;a++){var s=e[a];o+="<tr>",t&&(o+=`<td><span class='k-chart-shared-tooltip-marker' ${n.attr("style-background-color")}="${f(s.series.color)}"></span></td>`),i&&(o+=`<td> ${s.series.name?s.series.name+":":"&nbsp;"}</td>`),o+=`<td>${r(s)}</td>`,o+="</tr>"}return o}(i,o,a,r)+"</table>",categoryFormat:"{0:d}",autoHide:!0},move:function(){var e,t=this,n=t.options,i=t.element;t.anchor&&t.element&&(e=t._offset(),t.visible||i.css({top:e.top,left:e.left}),t.visible=!0,t._ensureElement(document.body),i.stop(!0,!0).show().animate({left:e.left,top:e.top},n.animation.duration))},_clearShowTimeout:function(){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=null)},getAnchor:function(e){var t=this.anchor,n=t.point,i=t.align,r=n.left,o=n.top;return"center"===i.horizontal?r-=e.width/2:"right"===i.horizontal&&(r-=e.width),"center"===i.vertical?o-=e.height/2:"bottom"===i.vertical&&(o-=e.height),{x:r,y:o}},_offset:function(){var t=this,i=t._measure(),r=t.getAnchor(i),s=r.y,l=r.x,c=n.support.zoomLevel(),d=e(window),u=window.pageYOffset||document.documentElement.scrollTop||0,h=window.pageXOffset||document.documentElement.scrollLeft||0,p=(this._mobileScroller||{}).movable;if(p&&1!==p.scale){var f=te.transform().scale(p.scale,p.scale,[p.x,p.y]),m=new te.Point(l,s).transform(f);l=m.x,s=m.y}else s+=t._fit(s-u,i.height,a(d)/c),l+=t._fit(l-h,i.width,o(d)/c);return{top:s,left:l}},show:function(r){var o=this,a=e("<div></div>");this.anchor=r.anchor,this.element.css(function(e){for(var n in e)e[n]===t&&(e[n]="");return e}(r.style)),this.element.toggleClass("k-chart-tooltip-inverse",!!r.className),this.element.toggleClass("k-chart-shared-tooltip",!!r.shared);var s=r.shared?this._sharedContent(r):this._pointContent(r.point);a.html(s),n.applyStylesFromKendoAttributes(a,["background-color"]),this.element.find(".k-tooltip-content").empty().append(a),o.options.autoHide||(o.element.off("click"+i).on("click"+i,".k-tooltip-button",o._closeTooltipHandler),V.off(o.downEvent,o._closeTooltipHandler).on(o.downEvent,o._closeTooltipHandler)),this._clearShowTimeout(),this.showTimeout=setTimeout(this.move,100)},hide:function(e){var t=this;(t.options.autoHide||e)&&(clearTimeout(t.showTimeout),t._hideElement(),t.visible&&(t.point=null,t.visible=!1,t.index=null,V.off(t.downEvent,t._closeTooltipHandler)))},_closeTooltip:function(t){e(t.target).is(".k-chart-tooltip, .k-tooltip-content")||(t.preventDefault(),this.chartElement.data("kendoChart")._instance.hideElements(),this.hide(!0))},_sharedContent:function(e){var t=e.points,i=ZF(t,(function(e){return hR(e.series.name)})).length,r=e.series.length>1,o=1;return i&&o++,r&&o++,n.template(this.options.sharedTemplate)({points:t,category:e.category,categoryText:e.categoryText,content:this._pointContent.bind(this),colorMarker:r,nameColumn:i,colspan:o})},_measure:function(){return this._ensureElement(),{width:o(this.element),height:a(this.element)}},_ensureElement:function(){this.element&&this.element.appendTo(document.body).on(m,this._mouseleave)},_mouseleave:function(t){var n=t.relatedTarget,i=this.chartElement[0];n&&n!==i&&!e.contains(i,n)&&this.trigger(U)},_hideElement:function(){var e=this,t=this.element;t&&t.fadeOut({always:function(){e.visible||t.off(m).remove()}})},_pointContent:function(e){var t,n=d({},this.options,e.options.tooltip);return hR(e.value)&&(t=e.value.toString()),n.template?t=p(n.template)({value:e.value,category:e.category,series:e.series,dataItem:e.dataItem,percentage:e.percentage,runningTotal:e.runningTotal,total:e.total,low:e.low,high:e.high,xLow:e.xLow,xHigh:e.xHigh,yLow:e.yLow,yHigh:e.yHigh}):n.format&&(t=e.formatValue(n.format)),t},_fit:function(e,t,n){var i=0;return e+t>n&&(i=n-(e+t)),e<0&&(i=-e),i}}),ie=ne.extend({init:function(e,t){ne.fn.init.call(this,e,t),this.element.addClass("k-chart-crosshair-tooltip")},show:function(e){this.element&&(this.anchor=e.anchor,this.element.css(e.style),this.element.html(this.content(e)),this.move())},move:function(){var e=this,t=e.element,n=e._offset();e._ensureElement(),t.css({top:n.top,left:n.left}).show()},content:function(e){var t=e.value,n=e.crosshair.options.tooltip;return n.template&&(t=p(n.template)({value:t})),t},hide:function(){this.element.hide()}}),re=r.extend({init:function(e,t){this._chart=e,this._pane=t,this.visual=t.visual,this.chartsVisual=t.chartContainer.visual,this.name=t.options.name},series:function(){var e=this._chart,t=e._plotArea.groupSeriesByPane()[this.name||"default"],n=[];if(t)for(var i=0;i<t.length;i++)n.push(new oe(e,t[i]));return n}}),oe=r.extend({init:function(e,t){this._chart=e,this._options=t},points:function(e){var t=this._points;if(!t){var i=this._seriesOptions(),r=this._chart._plotArea;this._points=t=r.pointsBySeriesIndex(i.index)}return n.isFunction(e)&&(t=this._filterPoints(t,e)),t},data:function(e){var t=this._seriesOptions();if(e){var n=this._chart,i=n._plotArea;if(t.data=e,t.categoryField){var r=i.seriesCategoryAxis(t),o=[].concat(n.options.categoryAxis);n._instance.bindCategoryAxisFromSeries(o[r.axisIndex],r.axisIndex)}n._noTransitionsRedraw(),this._clearFields()}return t.data},findPoint:function(e){for(var t=this.points(),n=0;n<t.length;n++)if(e(t[n]))return t[n]},toggleHighlight:function(e,t){t=t?n.isFunction(t)?this.points(t):u(t)?t:[t]:this.points(),this._chart._instance.togglePointsHighlight(e,t)},toggleVisibility:function(e,t){var i=this._chart,r=this._seriesOptions();if(n.isFunction(t))if(tR(r.type,[W,j,q]))for(var o=this._filterData(t),a=0;a<o.length;a++)o[a].visible=e;else r.visible=function(n){return!t(n.dataItem)||e};else r.visible=e,i._seriesVisibility.save(r);i._noTransitionsRedraw(),this._clearFields()},_filterData:function(e){for(var t=this._seriesOptions().data,n=t.length,i=[],r=0;r<n;r++)e(t[r])&&i.push(t[r]);return i},_filterPoints:function(e,t){for(var n=[],i=e.length,r=0;r<i;r++)t(e[r])&&n.push(e[r]);return n},_seriesOptions:function(){var e=this._series;return e||(e=this._series=this._chart._seriesOptions(this._options)),e},_clearFields:function(){delete this._points,delete this._series}});s.Tooltip=ne,s.CrosshairTooltip=ie,s.ChartInstanceObserver=K,s.ChartPane=re,s.ChartSeries=oe}(window.kendo.jQuery),function(){var e=window.kendo,t=e.ui.Widget,n=e.htmlEncode,i="__style",r=`${i}="display: flex; align-items: center;"`,o=e=>`<span ${i}="margin: 0 3px">${e}</span>`,a=e=>`<div ${i}="width: 15px; height: 15px; background-color: ${e}; display: inline-flex; margin-left: 3px"></div>`,s={node:function({dataItem:e,value:t}){const{color:i,label:s}=e;return`<div ${r}>\n                    ${a(i)}\n                    ${o(n(s.text))}\n                    ${o(t)}\n                </div>`},link:function({dataItem:t,value:i,rtl:s}){const{source:l,target:c}=t;return`<div ${r}>\n                    ${a(l.color)}\n                    ${o(n(l.label.text))}\n                    ${o(e.ui.icon({icon:s?"arrow-left":"arrow-right"}))}\n                    ${a(c.color)}\n                    ${o(n(c.label.text))}\n                    ${o(i)}\n                </div>`}},l=t.extend({init:function(e,n){this.options=n,t.fn.init.call(this,e),n.rtl&&this.element.addClass("k-rtl"),this.element.addClass("k-tooltip k-chart-tooltip k-chart-shared-tooltip").append('<div class="k-tooltip-content"></div>')},size:function(){return{width:this.element.outerWidth(),height:this.element.outerHeight()}},setContent:function(e){this.element.find(".k-tooltip-content").html(e),this.element.find(`[${i}]`).each(((e,t)=>{t.getAttribute(i).split(";").filter((e=>""!==e)).forEach((e=>{const n=e.split(":");t.style[n[0].trim()]=n[1].trim()})),t.removeAttribute(i)}))},setPosition:function(e,t,n){const i=this.size(),r={...t};r.left+="left"===e.horizontal?n:-1*n,"right"===e.horizontal&&(r.left-=i.width),"bottom"===e.vertical?r.top-=i.height+n:r.top+=n,this.element.css(r)},show:function(){this.element.show()},hide:function(){this.element.hide()},destroy:function(){this.element.remove()}});e.deepExtend(e.dataviz,{SankeyTooltip:{Tooltip:l,ContentTemplates:s}})}(window.kendo.jQuery);!function(e){window.kendo.dataviz=window.kendo.dataviz||{};const t=window.kendo,n=t.template,i=t.ui.Widget,r=t.dataviz,o=t.htmlEncode,a=t.support.isRtl,{Tooltip:s,ContentTemplates:l}=r.SankeyTooltip,c=i.extend({init:function(n,o){t.destroy(n),e(n).empty(),this.options=t.deepExtend({},this.options,o,{rtl:a(n)}),this._parseAriaLabelTemplates(this.options),i.fn.init.call(this,n),this.wrapper=this.element,this._initSankey(),this._attachEvents(),t.notify(this,r.ui),this._showWatermarkOverlay&&this._showWatermarkOverlay(this.wrapper[0])},setOptions:function(e){var n=this.options;this.events.forEach((e=>{n[e]&&this.unbind(e,n[e])}));const i=t.deepExtend(e,{rtl:a(this.element)});this._parseAriaLabelTemplates(i),this._instance.setOptions(i),this.bind(this.events,this._instance.options)},_initSankey:function(){const e=this._getThemeOptions(this.options),{seriesColors:t,axisDefaults:n,seriesDefaults:i,legend:r,title:o}=e,{line:a,labels:s}=n,l=i.labels.background;this._createSankey(this.options,{nodeColors:t,links:a,labels:{...s,stroke:{color:l}},legend:r,title:o}),this.options=this._instance.options},_createSankey:function(e,t){this._instance=new uX(this.element[0],e,t)},_getThemeOptions:function(e){var t=(e||{}).theme;if(t&&-1!==r.SASS_THEMES.indexOf(t.toLowerCase()))return r.autoTheme().chart;if(hR(t)){var n=r.ui.themes||{};return(n[t]||n[t.toLowerCase()]||{}).chart||{}}},_parseAriaLabelTemplates:function(e){const{nodes:t,links:i}=e;t&&t.labels&&t.labels.ariaTemplate&&(t.labels.ariaTemplate=n(t.labels.ariaTemplate)),i&&i.labels&&i.labels.ariaTemplate&&(i.labels.ariaTemplate=n(i.labels.ariaTemplate))},_attachEvents:function(){this.events.forEach((e=>{this._instance.bind(e,(t=>{this._events[e]&&this._events[e].forEach((e=>e.call(void 0,t)))}))})),this._instance.bind("tooltipShow",this.tooltipShow.bind(this)),this._instance.bind("tooltipHide",this.tooltipHide.bind(this))},tooltipShow:function(i){const{tooltip:r,rtl:a}=this.options,{nodeTemplate:c,linkTemplate:d,offset:u}=r;if(!this._tooltip){const t=this.element[0].ownerDocument;this._tooltip=new s(t.createElement("div"),{rtl:a});const{appendTo:n=t.body}=this.options.tooltip;this._tooltip.element.appendTo(e(n))}const h=n(("node"===i.targetType?c:d)||l[i.targetType]),p=o(t.format(this.options.messages.tooltipUnits,hR(i.nodeValue)?i.nodeValue:i.dataItem.value));this._tooltip.setContent(h({dataItem:i.dataItem,value:p,rtl:a})),this._tooltip.setPosition(i.tooltipData.popupAlign,i.tooltipData.popupOffset,u),this._tooltip.show()},tooltipHide:function(){this._tooltip&&(this._tooltip.destroy(),this._tooltip=null)},exportVisual:function(e){return this._instance.exportVisual(e)},destroy:function(){i.fn.destroy.call(this),this.tooltipHide(),this._instance.destroy(),this._instance=null},events:["nodeClick","linkClick","nodeEnter","nodeLeave","linkEnter","linkLeave"],options:{name:"Sankey",theme:"default",tooltip:{offset:12},messages:{tooltipUnits:"({0} Units)"}}});r.ExportMixin.extend(c.fn),t.PDFMixin&&t.PDFMixin.extend(c.fn),r.ui.plugin(c),t.deepExtend(r,{Sankey:c,createSankeyData:pX})}(window.kendo.jQuery);kendo;!function(e){window.kendo.dataviz=window.kendo.dataviz||{};var t=window.kendo,n=t.ui.Widget,i=t.dataviz,r=t.drawing;function o(e){var t=i.ui.themes||{},n=e.theme||"",r=n.toLowerCase();return-1!=i.SASS_THEMES.indexOf(r)?i.autoTheme().gauge:(t[n]||t[r]||{}).gauge}var a=n.extend({init:function(r,o){t.destroy(r),e(r).empty(),n.fn.init.call(this,r),this.options=t.deepExtend(this.options,o),this.wrapper=this.element,this._createInstance(),this.element.addClass("k-gauge"),t.notify(this,i.ui)},options:{theme:"sass",renderAs:"",pointer:{},scale:{},gaugeArea:{background:""},transitions:!0},setOptions:function(e){this._instance.setOptions(e,o(e)),this._copyFields()},redraw:function(){this._instance.redraw(),this._copyFields()},destroy:function(){n.fn.destroy.call(this),this._instance.destroy()},_createInstance:function(){var e=this._gaugeType();this._instance=new e(this.element[0],this.options,o(this.options)),this._copyFields()},_copyFields:function(){this._originalOptions=this._instance._originalOptions,this.options=this._instance.options,this.surface=this._instance.surface,this.bbox=this._instance.bbox,this.gaugeArea=this._instance.gaugeArea,this.pointers=this._instance.pointers,this.scale=this._instance.scale},_resize:function(){this._instance.resize()}}),s=["getSize","value","allValues","exportVisual"];function l(e){a.fn[e]=function(){return this._instance[e].apply(this._instance,arguments)}}for(var c=0;c<s.length;c++)l(s[c]);i.ExportMixin.extend(a.fn);var d=a.extend({options:{name:"RadialGauge"},_gaugeType:function(){return Rq}}),u=a.extend({options:{name:"LinearGauge",scale:{vertical:!0}},_gaugeType:function(){return kq}}),h=a.extend({init:function(e,t){a.fn.init.call(this,e,t),this.element.css("position","relative"),this.element.addClass("k-arcgauge"),this._centerTemplate()},options:{name:"ArcGauge"},setOptions:function(e){a.fn.setOptions.call(this,e),this._centerTemplate()},redraw:function(){a.fn.redraw.call(this),this._centerTemplate()},value:function(e){var t=this._instance;if(0===arguments.length)return t.value();t.value(e),this._centerTemplate()},destroy:function(){a.fn.destroy.call(this),delete this._centerElement},exportVisual:function(){return!this._centerElement&&a.fn.exportVisual.call(this)},_resize:function(){this._instance.resize(),this._centerTemplate()},_centerTemplate:function(){if(this.options.centerTemplate){var e=t.template(this.options.centerTemplate),n=this._instance,i=this._getCenterElement();i.html(e({color:n.currentColor(),value:n.value()}));var r=n.centerLabelPosition(i.width(),i.height());i.css(r)}else this._centerElement&&(this._centerElement.remove(),this._centerElement=null)},_getCenterElement:function(){var t=this._centerElement;return t||(t=this._centerElement=e("<div></div>").addClass("k-arcgauge-label"),this.element.append(t)),t},_gaugeType:function(){return Vq}}),p=h.extend({options:{name:"CircularGauge"},_gaugeType:function(){return Nq}});function f(e){h.fn[e]=function(t){var n=this,i=r[e];return n._centerElement?r.drawDOM(n.element).then((function(e){return i(e,t)})):i(n.exportVisual(),t)}}var m=["exportSVG","exportImage","exportPDF"];for(c=0;c<m.length;c++)f(m[c]);i.ui.plugin(u),i.ui.plugin(d),i.ui.plugin(h),i.ui.plugin(p),t.deepExtend(i,{Gauge:a,LinearScale:dq,RadialScale:Mq,RadialPointer:Hq,LinearPointer:hq,BarLinearPointer:yq,ArrowLinearPointer:gq,LinearGauge:u,RadialGauge:d,ArcGauge:h,CircularGauge:p})}(window.kendo.jQuery);kendo;!function(e){window.kendo.dataviz=window.kendo.dataviz||{};var t=window.kendo,n=t.ui.Widget,i=e.extend,r=t.deepExtend,o=e.inArray,a=e.isPlainObject,s=t.dataviz,l=/^\d+$/,c=/^[a-z0-9]+$/i;function d(e,t,n){return e.substring(t,t+n)}var u=t.Class.extend({init:function(e){this.setOptions(e)},setOptions:function(e){var t=this;t.options=i({},t.options,e),t.quietZoneLength=t.options.addQuietZone?2*t.options.quietZoneLength:0},encode:function(e,t,n){var i=this;return hR(e)&&(e+=""),i.initValue(e,t,n),i.options.addQuietZone&&i.addQuietZone(),i.addData(),i.options.addQuietZone&&i.addQuietZone(),{baseUnit:i.baseUnit,pattern:i.pattern}},options:{quietZoneLength:10,addQuietZone:!0,addCheckSum:!0},initValue:function(){},addQuietZone:function(){this.pattern.push(this.options.quietZoneLength||10)},addData:function(){},invalidCharacterError:function(e){throw new Error(t.format("Character '{0}' is not valid for symbology {1}",e,this.name))}}),h={},p=u.extend({minBaseUnitLength:.7,addData:function(){var e=this,t=e.value;e.addStart();for(var n=0;n<t.length;n++)e.addCharacter(t.charAt(n));e.options.addCheckSum&&e.pushCheckSum(),e.addStop(),e.prepareValues()},addCharacter:function(e){var t=this,n=t.characterMap[e];n||t.invalidCharacterError(e),t.addBase(n)},addBase:function(){}}),f={addCharacter:function(e){var t=this;t.characterMap[e]?t.addBase(t.characterMap[e]):e.charCodeAt(0)>127?t.invalidCharacterError(e):t.addExtended(e.charCodeAt(0))},addExtended:function(e){for(var t,n=this,i=0;i<n.extendedMappings.length;i++)if(t=n.extendedMappings[i].call(n,e)){for(var r=0;r<t.length;r++)n.addBase(t[r]);return void(n.dataLength+=t.length-1)}},extendedMappings:[function(e){if(97<=e&&e<=122){var t=this;return[t.characterMap[t.shiftCharacters[0]],t.characterMap[String.fromCharCode(e-32)]]}},function(e){if(33<=e&&e<=58){var t=this;return[t.characterMap[t.shiftCharacters[1]],t.characterMap[String.fromCharCode(e+32)]]}},function(e){if(1<=e&&e<=26){var t=this;return[t.characterMap[t.shiftCharacters[2]],t.characterMap[String.fromCharCode(e+64)]]}},function(e){var t,n,i=this;if(i.specialAsciiCodes[e]){t=[];for(var r=0;r<i.specialAsciiCodes[e].length;r++)t.push(i.characterMap[i.shiftCharacters[3]]),t.push(i.characterMap[i.specialAsciiCodes[e][r]])}else n=6*Math.floor(e/32)+(e-27)%32+64,t=[i.characterMap[i.shiftCharacters[3]],i.characterMap[String.fromCharCode(n)]];return t}],specialAsciiCodes:{0:["U"],64:["V"],96:["W"],127:["T","X","Y","Z"]},shiftValuesAsciiCodes:{39:36,40:47,41:43,42:37},characterMap:{"+":!1,"/":!1,$:!1,"%":!1},shiftCharacters:["SHIFT0","SHIFT1","SHIFT2","SHIFT3"]};h.code39=p.extend({name:"Code 39",checkSumMod:43,minRatio:2.5,maxRatio:3,gapWidth:1,splitCharacter:"|",initValue:function(e,t,n){var i=this;i.width=t,i.height=n,i.value=e,i.dataLength=e.length,i.pattern=[],i.patternString=""},prepareValues:function(){var e,t=this,n=t.minBaseUnitLength,i=t.maxRatio,r=t.minRatio,o=Math.max(.15*t.width,24);if(t.height<o)throw new Error("Insufficient Height. The minimum height for value: "+t.value+" is: "+o);for(;(e=t.getBaseUnit(i))<n&&i>r;)i=parseFloat((i-.1).toFixed(1));if(e<n){var a=Math.ceil(t.getBaseWidth(r)*n);throw new Error("Insufficient width. The minimum width for value: "+t.value+" is: "+a)}t.ratio=i,t.baseUnit=e,t.patternString=t.patternString.substring(0,t.patternString.length-1),t.pattern=t.pattern.concat(t.patternString.replace(/ratio/g,i).split(t.splitCharacter))},getBaseUnit:function(e){return this.width/this.getBaseWidth(e)},getBaseWidth:function(e){var t=this,n=3*(e+2);return t.quietZoneLength+n*(t.dataLength+2)+t.gapWidth*(t.dataLength+1)},addStart:function(){var e=this;e.addPattern(e.characterMap.START.pattern),e.addCharacterGap()},addBase:function(e){this.addPattern(e.pattern),this.addCharacterGap()},addStop:function(){this.addPattern(this.characterMap.START.pattern)},addPattern:function(e){for(var t=0;t<e.length;t++)this.patternString+=this.patternMappings[e.charAt(t)]},addCharacterGap:function(){var e=this;e.patternString+=e.gapWidth+e.splitCharacter},patternMappings:{b:"1|",w:"1|",B:"ratio|",W:"ratio|"},characterMap:{0:{pattern:"bwbWBwBwb",value:0},1:{pattern:"BwbWbwbwB",value:1},2:{pattern:"bwBWbwbwB",value:2},3:{pattern:"BwBWbwbwb",value:3},4:{pattern:"bwbWBwbwB",value:4},5:{pattern:"BwbWBwbwb",value:5},6:{pattern:"bwBWBwbwb",value:6},7:{pattern:"bwbWbwBwB",value:7},8:{pattern:"BwbWbwBwb",value:8},9:{pattern:"bwBWbwBwb",value:9},A:{pattern:"BwbwbWbwB",value:10},B:{pattern:"bwBwbWbwB",value:11},C:{pattern:"BwBwbWbwb",value:12},D:{pattern:"bwbwBWbwB",value:13},E:{pattern:"BwbwBWbwb",value:14},F:{pattern:"bwBwBWbwb",value:15},G:{pattern:"bwbwbWBwB",value:16},H:{pattern:"BwbwbWBwb",value:17},I:{pattern:"bwBwbWBwb",value:18},J:{pattern:"bwbwBWBwb",value:19},K:{pattern:"BwbwbwbWB",value:20},L:{pattern:"bwBwbwbWB",value:21},M:{pattern:"BwBwbwbWb",value:22},N:{pattern:"bwbwBwbWB",value:23},O:{pattern:"BwbwBwbWb",value:24},P:{pattern:"bwBwBwbWb",value:25},Q:{pattern:"bwbwbwBWB",value:26},R:{pattern:"BwbwbwBWb",value:27},S:{pattern:"bwBwbwBWb",value:28},T:{pattern:"bwbwBwBWb",value:29},U:{pattern:"BWbwbwbwB",value:30},V:{pattern:"bWBwbwbwB",value:31},W:{pattern:"BWBwbwbwb",value:32},X:{pattern:"bWbwBwbwB",value:33},Y:{pattern:"BWbwBwbwb",value:34},Z:{pattern:"bWBwBwbwb",value:35},"-":{pattern:"bWbwbwBwB",value:36},".":{pattern:"BWbwbwBwb",value:37}," ":{pattern:"bWBwbwBwb",value:38},$:{pattern:"bWbWbWbwb",value:39},"/":{pattern:"bWbWbwbWb",value:40},"+":{pattern:"bWbwbWbWb",value:41},"%":{pattern:"bwbWbWbWb",value:42},START:{pattern:"bWbwBwBwb"}},options:{addCheckSum:!1}}),h.code39extended=h.code39.extend(r({},f,{name:"Code 39 extended",characterMap:{SHIFT0:{pattern:"bWbwbWbWb",value:41},SHIFT1:{pattern:"bWbWbwbWb",value:40},SHIFT2:{pattern:"bWbWbWbwb",value:39},SHIFT3:{pattern:"bwbWbWbWb",value:42}}})),h.code93=p.extend({name:"Code 93",cCheckSumTotal:20,kCheckSumTotal:15,checkSumMod:47,initValue:function(e,t,n){var i=this;i.value=e,i.width=t,i.height=n,i.pattern=[],i.values=[],i.dataLength=e.length},prepareValues:function(){var e=this,t=Math.max(.15*e.width,24);if(e.height<t)throw new Error("Insufficient Height");if(e.setBaseUnit(),e.baseUnit<e.minBaseUnitLength)throw new Error("Insufficient Width")},setBaseUnit:function(){var e=this;e.baseUnit=e.width/(9*(e.dataLength+2+2)+e.quietZoneLength+1)},addStart:function(){var e=this.characterMap.START.pattern;this.addPattern(e)},addStop:function(){var e=this;e.addStart(),e.pattern.push(e.characterMap.TERMINATION_BAR)},addBase:function(e){this.addPattern(e.pattern),this.values.push(e.value)},pushCheckSum:function(){var e,t=this,n=t._getCheckValues();t.checksum=n.join("");for(var i=0;i<n.length;i++)e=t.characterMap[t._findCharacterByValue(n[i])],t.addPattern(e.pattern)},_getCheckValues:function(){var e,t,n=this,i=n.values,r=i.length,o=0;for(t=r-1;t>=0;t--)o+=n.weightedValue(i[t],r-t,n.cCheckSumTotal);for(e=o%n.checkSumMod,o=n.weightedValue(e,1,n.kCheckSumTotal),t=r-1;t>=0;t--)o+=n.weightedValue(i[t],r-t+1,n.kCheckSumTotal);return[e,o%n.checkSumMod]},_findCharacterByValue:function(e){for(var t in this.characterMap)if(this.characterMap[t].value===e)return t},weightedValue:function(e,t,n){return(t%n||n)*e},addPattern:function(e){for(var t,n=0;n<e.length;n++)t=parseInt(e.charAt(n),10),this.pattern.push(t)},characterMap:{0:{pattern:"131112",value:0},1:{pattern:"111213",value:1},2:{pattern:"111312",value:2},3:{pattern:"111411",value:3},4:{pattern:"121113",value:4},5:{pattern:"121212",value:5},6:{pattern:"121311",value:6},7:{pattern:"111114",value:7},8:{pattern:"131211",value:8},9:{pattern:"141111",value:9},A:{pattern:"211113",value:10},B:{pattern:"211212",value:11},C:{pattern:"211311",value:12},D:{pattern:"221112",value:13},E:{pattern:"221211",value:14},F:{pattern:"231111",value:15},G:{pattern:"112113",value:16},H:{pattern:"112212",value:17},I:{pattern:"112311",value:18},J:{pattern:"122112",value:19},K:{pattern:"132111",value:20},L:{pattern:"111123",value:21},M:{pattern:"111222",value:22},N:{pattern:"111321",value:23},O:{pattern:"121122",value:24},P:{pattern:"131121",value:25},Q:{pattern:"212112",value:26},R:{pattern:"212211",value:27},S:{pattern:"211122",value:28},T:{pattern:"211221",value:29},U:{pattern:"221121",value:30},V:{pattern:"222111",value:31},W:{pattern:"112122",value:32},X:{pattern:"112221",value:33},Y:{pattern:"122121",value:34},Z:{pattern:"123111",value:35},"-":{pattern:"121131",value:36},".":{pattern:"311112",value:37}," ":{pattern:"311211",value:38},$:{pattern:"321111",value:39},"/":{pattern:"112131",value:40},"+":{pattern:"113121",value:41},"%":{pattern:"211131",value:42},SHIFT0:{pattern:"122211",value:46},SHIFT1:{pattern:"311121",value:45},SHIFT2:{pattern:"121221",value:43},SHIFT3:{pattern:"312111",value:44},START:{pattern:"111141"},TERMINATION_BAR:"1"}}),h.code93extended=h.code93.extend(r({},f,{name:"Code 93 extended",pushCheckSum:function(){var e,t=this,n=t._getCheckValues();t.checksum=n.join("");for(var i=0;i<n.length;i++)e=n[i],t.shiftValuesAsciiCodes[e]?t.addExtended(t.shiftValuesAsciiCodes[e]):t.addPattern(t.characterMap[t._findCharacterByValue(e)].pattern)}}));var m=t.Class.extend({init:function(e){this.encoding=e},addStart:function(){},is:function(){},move:function(){},pushState:function(){}}),g=m.extend({FNC4:"FNC4",init:function(e,t){var n=this;n.encoding=e,n.states=t,n._initMoves(t)},addStart:function(){this.encoding.addPattern(this.START)},is:function(e,t){var n=e.charCodeAt(t);return this.isCode(n)},move:function(e){for(var t=this,n=0;!t._moves[n].call(t,e)&&n<t._moves.length;)n++},pushState:function(e){var t,n=this,i=n.states,r=e.value,a=r.length;if(o("C",i)>=0){var s=r.substr(e.index).match(/\d{4,}/g);s&&(a=r.indexOf(s[0],e.index))}for(;(t=e.value.charCodeAt(e.index))>=0&&n.isCode(t)&&e.index<a;)n.encoding.addPattern(n.getValue(t)),e.index++},_initMoves:function(e){var t=this;t._moves=[],o(t.FNC4,e)>=0&&t._moves.push(t._moveFNC),o(t.shiftKey,e)>=0&&t._moves.push(t._shiftState),t._moves.push(t._moveState)},_moveFNC:function(e){if(e.fnc)return e.fnc=!1,e.previousState==this.key},_shiftState:function(e){var t=this;if(e.previousState==t.shiftKey&&(e.index+1>=e.value.length||t.encoding[t.shiftKey].is(e.value,e.index+1)))return t.encoding.addPattern(t.SHIFT),e.shifted=!0,!0},_moveState:function(){return this.encoding.addPattern(this.MOVE),!0},SHIFT:98}),v={};v.A=g.extend({key:"A",shiftKey:"B",isCode:function(e){return e>=0&&e<96},getValue:function(e){return e<32?e+64:e-32},MOVE:101,START:103}),v.B=g.extend({key:"B",shiftKey:"A",isCode:function(e){return e>=32&&e<128},getValue:function(e){return e-32},MOVE:100,START:104}),v.C=m.extend({key:"C",addStart:function(){this.encoding.addPattern(this.START)},is:function(e,t){var n=d(e,t,4);return(t+4<=e.length||2==e.length)&&l.test(n)},move:function(){this.encoding.addPattern(this.MOVE)},pushState:function(e){for(var t;(t=d(e.value,e.index,2))&&l.test(t)&&2==t.length;)this.encoding.addPattern(parseInt(t,10)),e.index+=2},getValue:function(e){return e},MOVE:99,START:105}),v.FNC4=m.extend({key:"FNC4",dependentStates:["A","B"],init:function(e,t){this.encoding=e,this._initSubStates(t)},addStart:function(e){var t=e.value.charCodeAt(0)-128,n=this._getSubState(t);this.encoding[n].addStart()},is:function(e,t){var n=e.charCodeAt(t);return this.isCode(n)},isCode:function(e){return e>=128&&e<256},pushState:function(e){var t=this,n=t._initSubState(e),i=t.encoding,r=n.value.length;if(e.index+=r,r<3)for(var o;n.index<r;n.index++)o=n.value.charCodeAt(n.index),n.state=t._getSubState(o),n.previousState!=n.state&&(n.previousState=n.state,i[n.state].move(n)),i.addPattern(i[n.state].MOVE),i.addPattern(i[n.state].getValue(o));else n.state!=n.previousState&&i[n.state].move(n),t._pushStart(n),i.pushData(n,t.subStates),e.index<e.value.length&&t._pushStart(n);e.fnc=!0,e.state=n.state},_pushStart:function(e){var t=this;t.encoding.addPattern(t.encoding[e.state].MOVE),t.encoding.addPattern(t.encoding[e.state].MOVE)},_initSubState:function(e){var t=this,n={value:t._getAll(e.value,e.index),index:0};return n.state=t._getSubState(n.value.charCodeAt(0)),n.previousState=e.previousState==t.key?n.state:e.previousState,n},_initSubStates:function(e){var t=this;t.subStates=[];for(var n=0;n<e.length;n++)o(e[n],t.dependentStates)>=0&&t.subStates.push(e[n])},_getSubState:function(e){for(var t=this,n=0;n<t.subStates.length;n++)if(t.encoding[t.subStates[n]].isCode(e))return t.subStates[n]},_getAll:function(e,t){for(var n,i="";(n=e.charCodeAt(t++))&&this.isCode(n);)i+=String.fromCharCode(n-128);return i}}),v.FNC1=m.extend({key:"FNC1",startState:"C",dependentStates:["C","B"],startAI:"(",endAI:")",init:function(e,t){this.encoding=e,this.states=t},addStart:function(){this.encoding[this.startState].addStart()},is:function(){return o(this.key,this.states)>=0},pushState:function(e){var t,n,i,r=this,o=r.encoding,a=e.value.replace(/\s/g,""),s=new RegExp("["+r.startAI+r.endAI+"]","g"),l=e.index,c={state:r.startState};for(o.addPattern(r.START);;){if(c.index=0,(t=(i=a.charAt(l)===r.startAI?2:0)>0?r.getBySeparator(a,l):r.getByLength(a,l)).ai.length)n=l+i+t.id.length+t.ai.length;else if((n=a.indexOf(r.startAI,l+1))<0){if(l+t.ai.max+t.id.length+i<a.length)throw new Error("Separators are required after variable length identifiers");n=a.length}if(c.value=a.substring(l,n).replace(s,""),r.validate(t,c.value),o.pushData(c,r.dependentStates),n>=a.length)break;l=n,c.state!=r.startState&&(o[r.startState].move(c),c.state=r.startState),t.ai.length||o.addPattern(r.START)}e.index=e.value.length},validate:function(e,t){var n=t.substr(e.id.length),i=e.ai;if(!i.type&&!l.test(n))throw new Error("Application identifier "+e.id+" is numeric only but contains non numeric character(s).");if("alphanumeric"==i.type&&!c.test(n))throw new Error("Application identifier "+e.id+" is alphanumeric only but contains non alphanumeric character(s).");if(i.length&&i.length!==n.length)throw new Error("Application identifier "+e.id+" must be "+i.length+" characters long.");if(i.min&&i.min>n.length)throw new Error("Application identifier "+e.id+" must be at least "+i.min+" characters long.");if(i.max&&i.max<n.length)throw new Error("Application identifier "+e.id+" must be at most "+i.max+" characters long.")},getByLength:function(e,t){for(var n,i,r=this,o=2;o<=4;o++)if(n=d(e,t,o),i=r.getAI(n)||r.getAI(n.substring(0,n.length-1)))return{id:n,ai:i};r.unsupportedAIError(n)},unsupportedAIError:function(e){throw new Error(t.format("'{0}' is not a supported Application Identifier"),e)},getBySeparator:function(e,t){var n=this,i=e.indexOf(n.startAI,t),r=e.indexOf(n.endAI,i),o=e.substring(i+1,r),a=n.getAI(o)||n.getAI(o.substr(o.length-1));return a||n.unsupportedAIError(o),{ai:a,id:o}},getAI:function(e){var t=this.applicationIdentifiers,n=t.multiKey;if(t[e])return t[e];for(var i=0;i<n.length;i++){if(n[i].ids&&o(e,n[i].ids)>=0)return n[i].type;if(n[i].ranges)for(var r=n[i].ranges,a=0;a<r.length;a++)if(r[a][0]<=e&&e<=r[a][1])return n[i].type}},applicationIdentifiers:{22:{max:29,type:"alphanumeric"},402:{length:17},7004:{max:4,type:"alphanumeric"},242:{max:6,type:"alphanumeric"},8020:{max:25,type:"alphanumeric"},703:{min:3,max:30,type:"alphanumeric"},8008:{min:8,max:12,type:"alphanumeric"},253:{min:13,max:17,type:"alphanumeric"},8003:{min:14,max:30,type:"alphanumeric"},multiKey:[{ids:["15","17","8005","8100"],ranges:[[11,13],[310,316],[320,336],[340,369]],type:{length:6}},{ids:["240","241","250","251","400","401","403","7002","8004","8007","8110"],ranges:[[-9]],type:{max:30,type:"alphanumeric"}},{ids:["7001"],ranges:[[410,414]],type:{length:13}},{ids:["10","21","254","420","8002"],type:{max:20,type:"alphanumeric"}},{ids:["00","8006","8017","8018"],type:{length:18}},{ids:["01","02","8001"],type:{length:14}},{ids:["422"],ranges:[[424,426]],type:{length:3}},{ids:["20","8102"],type:{length:2}},{ids:["30","37"],type:{max:8,type:"alphanumeric"}},{ids:["390","392"],type:{max:15,type:"alphanumeric"}},{ids:["421","423"],type:{min:3,max:15,type:"alphanumeric"}},{ids:["391","393"],type:{min:3,max:18,type:"alphanumeric"}},{ids:["7003","8101"],type:{length:10}}]},START:102});var _=u.extend({init:function(e){u.fn.init.call(this,e),this._initStates()},_initStates:function(){for(var e=this,t=0;t<e.states.length;t++)e[e.states[t]]=new v[e.states[t]](e,e.states)},initValue:function(e,t,n){var i=this;i.pattern=[],i.value=e,i.width=t,i.height=n,i.checkSum=0,i.totalUnits=0,i.index=0,i.position=1},addData:function(){var e=this,t={value:e.value,index:0,state:""};0!==e.value.length&&(t.state=t.previousState=e.getNextState(t,e.states),e.addStart(t),e.pushData(t,e.states),e.addCheckSum(),e.addStop(),e.setBaseUnit())},pushData:function(e,t){for(var n=this;n[e.state].pushState(e),!(e.index>=e.value.length);)if(e.shifted){var i=e.state;e.state=e.previousState,e.previousState=i,e.shifted=!1}else e.previousState=e.state,e.state=n.getNextState(e,t),n[e.state].move(e)},addStart:function(e){this[e.state].addStart(e),this.position=1},addCheckSum:function(){var e=this;e.checksum=e.checkSum%103,e.addPattern(e.checksum)},addStop:function(){this.addPattern(this.STOP)},setBaseUnit:function(){var e=this;e.baseUnit=e.width/(e.totalUnits+e.quietZoneLength)},addPattern:function(e){for(var t,n=this,i=n.characterMap[e].toString(),r=0;r<i.length;r++)t=parseInt(i.charAt(r),10),n.pattern.push(t),n.totalUnits+=t;n.checkSum+=e*n.position++},getNextState:function(e,t){for(var n=0;n<t.length;n++)if(this[t[n]].is(e.value,e.index))return t[n];this.invalidCharacterError(e.value.charAt(e.index))},characterMap:[212222,222122,222221,121223,121322,131222,122213,122312,132212,221213,221312,231212,112232,122132,122231,113222,123122,123221,223211,221132,221231,213212,223112,312131,311222,321122,321221,312212,322112,322211,212123,212321,232121,111323,131123,131321,112313,132113,132311,211313,231113,231311,112133,112331,132131,113123,113321,133121,313121,211331,231131,213113,213311,213131,311123,311321,331121,312113,312311,332111,314111,221411,431111,111224,111422,121124,121421,141122,141221,112214,112412,122114,122411,142112,142211,241211,221114,413111,241112,134111,111242,121142,121241,114212,124112,124211,411212,421112,421211,212141,214121,412121,111143,111341,131141,114113,114311,411113,411311,113141,114131,311141,411131,211412,211214,211232,2331112],STOP:106});h.code128a=_.extend({name:"Code 128 A",states:["A"]}),h.code128b=_.extend({name:"Code 128 B",states:["B"]}),h.code128c=_.extend({name:"Code 128 C",states:["C"]}),h.code128=_.extend({name:"Code 128",states:["C","B","A","FNC4"]}),h["gs1-128"]=_.extend({name:"Code GS1-128",states:["FNC1","C","B"]});var b=u.extend({initValue:function(e,t){var n=this;n.pattern=[],n.value=e,n.checkSumLength=0,n.width=t},setBaseUnit:function(){var e=this;e.baseUnit=e.width/(12*(e.value.length+e.checkSumLength)+e.quietZoneLength+7)},addData:function(){var e=this,t=e.value;e.addPattern(e.START);for(var n=0;n<t.length;n++)e.addCharacter(t.charAt(n));e.options.addCheckSum&&e.addCheckSum(),e.addPattern(e.STOP),e.setBaseUnit()},addCharacter:function(e){var t=this,n=t.characterMap[e];n||t.invalidCharacterError(e),t.addPattern(n)},addPattern:function(e){for(var t=0;t<e.length;t++)this.pattern.push(parseInt(e.charAt(t),10))},addCheckSum:function(){var e,t=this;e=t.checkSums[t.checkSumType].call(t.checkSums,t.value),t.checksum=e.join("");for(var n=0;n<e.length;n++)t.checkSumLength++,t.addPattern(t.characterMap[e[n]])},checkSums:{Modulo10:function(e){var t,n,i,r=[0,""],o=e.length%2;for(t=0;t<e.length;t++)r[(t+o)%2]+=parseInt(e.charAt(t),10);for(i=r[0],n=(2*r[1]).toString(),t=0;t<n.length;t++)i+=parseInt(n.charAt(t),10);return[(10-i%10)%10]},Modulo11:function(e){for(var t,n=0,i=e.length,r=0;r<i;r++)n+=(((i-r)%6||6)+1)*e.charAt(r);return 10!=(t=(11-n%11)%11)?[t]:[1,0]},Modulo11Modulo10:function(e){var t,n=this.Modulo11(e);return t=e+n[0],n.concat(this.Modulo10(t))},Modulo10Modulo10:function(e){var t,n=this.Modulo10(e);return t=e+n[0],n.concat(this.Modulo10(t))}},characterMap:["12121212","12121221","12122112","12122121","12211212","12211221","12212112","12212121","21121212","21121221"],START:"21",STOP:"121",checkSumType:""});h.msimod10=b.extend({name:"MSI Modulo10",checkSumType:"Modulo10"}),h.msimod11=b.extend({name:"MSI Modulo11",checkSumType:"Modulo11"}),h.msimod1110=b.extend({name:"MSI Modulo11 Modulo10",checkSumType:"Modulo11Modulo10"}),h.msimod1010=b.extend({name:"MSI Modulo10 Modulo10",checkSumType:"Modulo10Modulo10"}),h.code11=u.extend({name:"Code 11",cCheckSumTotal:10,kCheckSumTotal:9,kCheckSumMinLength:10,checkSumMod:11,DASH_VALUE:10,DASH:"-",START:"112211",STOP:"11221",initValue:function(e,t){var n=this;n.pattern=[],n.value=e,n.width=t,n.totalUnits=0},addData:function(){var e=this,t=e.value;e.addPattern(e.START);for(var n=0;n<t.length;n++)e.addCharacter(t.charAt(n));e.options.addCheckSum&&e.addCheckSum(),e.addPattern(e.STOP),e.setBaseUnit()},setBaseUnit:function(){var e=this;e.baseUnit=e.width/(e.totalUnits+e.quietZoneLength)},addCheckSum:function(){var e,t=this,n=t.value,i=n.length;if(e=t.getWeightedSum(n,i,t.cCheckSumTotal)%t.checkSumMod,t.checksum=e+"",t.addPattern(t.characterMap[e]),++i>=t.kCheckSumMinLength){var r=(e+t.getWeightedSum(n,i,t.kCheckSumTotal))%t.checkSumMod;t.checksum+=r,t.addPattern(t.characterMap[r])}},getWeightedSum:function(e,t,n){for(var i=0,r=0;r<e.length;r++)i+=this.weightedValue(this.getValue(e.charAt(r)),t,r,n);return i},weightedValue:function(e,t,n,i){return((t-n)%i||i)*e},getValue:function(e){var t=this;return isNaN(e)?(e!==t.DASH&&t.invalidCharacterError(e),t.DASH_VALUE):parseInt(e,10)},addCharacter:function(e){var t=this,n=t.getValue(e),i=t.characterMap[n];t.addPattern(i)},addPattern:function(e){for(var t,n=0;n<e.length;n++)t=parseInt(e.charAt(n),10),this.pattern.push(t),this.totalUnits+=t},characterMap:["111121","211121","121121","221111","112121","212111","122111","111221","211211","211111","112111"],options:{addCheckSum:!0}}),h.postnet=u.extend({name:"Postnet",START:"2",VALID_CODE_LENGTHS:[5,9,11],DIGIT_SEPARATOR:"-",initValue:function(e,t,n){var i=this;i.height=n,i.width=t,i.baseHeight=n/2,i.value=e.replace(new RegExp(i.DIGIT_SEPARATOR,"g"),""),i.pattern=[],i.validate(i.value),i.checkSum=0,i.setBaseUnit()},addData:function(){var e=this,t=e.value;e.addPattern(e.START);for(var n=0;n<t.length;n++)e.addCharacter(t.charAt(n));e.options.addCheckSum&&e.addCheckSum(),e.addPattern(e.START),e.pattern.pop()},addCharacter:function(e){var t=this,n=t.characterMap[e];t.checkSum+=parseInt(e,10),t.addPattern(n)},addCheckSum:function(){var e=this;e.checksum=(10-e.checkSum%10)%10,e.addCharacter(e.checksum)},setBaseUnit:function(){var e=this;e.baseUnit=e.width/(10*(e.value.length+1)+3+e.quietZoneLength)},validate:function(e){var t=this;if(l.test(e)||t.invalidCharacterError(e.match(/[^0-9]/)[0]),o(e.length,t.VALID_CODE_LENGTHS)<0)throw new Error("Invalid value length. Valid lengths for the Postnet symbology are "+t.VALID_CODE_LENGTHS.join(","))},addPattern:function(e){for(var t,n=this,i=0;i<e.length;i++)t=n.height-n.baseHeight*e.charAt(i),n.pattern.push({width:1,y1:t,y2:n.height}),n.pattern.push(1)},characterMap:["22111","11122","11212","11221","12112","12121","12211","21112","21121","21211"]}),h.ean13=u.extend({initValue:function(e,t,n){if(12!=(e+="").length||/\D/.test(e))throw new Error('The value of the "EAN13" encoding should be 12 symbols');var i=this;i.pattern=[],i.options.height=n,i.baseUnit=t/(95+i.quietZoneLength),i.value=e,i.checksum=i.calculateChecksum(),i.leftKey=e[0],i.leftPart=e.substr(1,6),i.rightPart=e.substr(7)+i.checksum},addData:function(){var e=this;e.addPieces(e.characterMap.start),e.addSide(e.leftPart,e.leftKey),e.addPieces(e.characterMap.middle),e.addSide(e.rightPart),e.addPieces(e.characterMap.start)},addSide:function(e,t){for(var n=this,i=0;i<e.length;i++)t&&parseInt(n.keyTable[t].charAt(i),10)?n.addPieces(Array.prototype.slice.call(n.characterMap.digits[e.charAt(i)]).reverse(),!0):n.addPieces(n.characterMap.digits[e.charAt(i)],!0)},addPieces:function(e,t){for(var n=this,i=0;i<e.length;i++)t?n.pattern.push({y1:0,y2:.95*n.options.height,width:e[i]}):n.pattern.push(e[i])},calculateChecksum:function(){for(var e=0,t=0,n=this.value.split("").reverse().join(""),i=0;i<n.length;i++)i%2?t+=parseInt(n.charAt(i),10):e+=parseInt(n.charAt(i),10);return(10-(3*e+t)%10)%10},keyTable:["000000","001011","001101","001110","010011","011001","011100","010101","010110","011010"],characterMap:{digits:[[3,2,1,1],[2,2,2,1],[2,1,2,2],[1,4,1,1],[1,1,3,2],[1,2,3,1],[1,1,1,4],[1,3,1,2],[1,2,1,3],[3,1,1,2]],start:[1,1,1],middle:[1,1,1,1,1]}}),h.ean8=h.ean13.extend({initValue:function(e,t,n){var i=this;if(7!=e.length||/\D/.test(e))throw new Error("Invalid value provided");i.value=e,i.options.height=n,i.checksum=i.calculateChecksum(i.value),i.leftPart=i.value.substr(0,4),i.rightPart=i.value.substr(4)+i.checksum,i.pattern=[],i.baseUnit=t/(67+i.quietZoneLength)}});var y=n.extend({init:function(t,i){var r=this;n.fn.init.call(r,t,i),r.element=e(t),r.wrapper=r.element,r.element.addClass("k-barcode").css("display","block"),r.surfaceWrap=e("<div />").css("position","relative").appendTo(this.element),r.surface=vc.create(r.surfaceWrap[0],{type:r.options.renderAs}),r._setOptions(i),i&&hR(i.value)&&r.redraw()},setOptions:function(e){this._setOptions(e),this.redraw()},redraw:function(){var e=this._getSize();this.surface.clear(),this.surface.setSize({width:e.width,height:e.height}),this.createVisual(),this.surface.draw(this.visual)},getSize:function(){return t.dimensions(this.element)},_resize:function(){this.redraw()},createVisual:function(){this.visual=this._render()},_render:function(){var e,t,n=this,i=n.options,r=i.value,o=i.text,a=WF(o.margin),s=n._getSize(),l=i.border||{},c=n.encoding,d=new VL(0,0,s.width,s.height).unpad(l.width).unpad(i.padding),u=d.height(),h=new vs;return n.contentBox=d,h.append(n._getBackground(s)),o.visible&&(u-=Oo(r,{font:o.font}).height+a.top+a.bottom),e=c.encode(r,d.width(),u),o.visible&&(t=r,i.checksum&&hR(c.checksum)&&(t+=" "+c.checksum),h.append(n._getText(t))),n.barHeight=u,this._bandsGroup=this._getBands(e.pattern,e.baseUnit),h.append(this._bandsGroup),h},exportVisual:function(){return this._render()},_getSize:function(){var e=this,t=e.element,n=new Ko(300,100);return t.width()>0&&(n.width=t.width()),t.height()>0&&(n.height=t.height()),e.options.width&&(n.width=e.options.width),e.options.height&&(n.height=e.options.height),n},value:function(e){var t=this;if(!hR(e))return t.options.value;t.options.value=e+"",t.redraw()},_getBands:function(e,t){for(var n,i,r=this,o=r.contentBox,s=o.x1,l=new vs,c=0;c<e.length;c++){if(n=(i=a(e[c])?e[c]:{width:e[c],y1:0,y2:r.barHeight}).width*t,c%2){var d=Yo.fromPoints(new Go(s,i.y1+o.y1),new Go(s+n,i.y2+o.y1)),u=us.fromRect(d,{fill:{color:r.options.color},stroke:null});l.append(u)}s+=n}return l},_getBackground:function(e){var t=this.options,n=t.border||{},i=new VL(0,0,e.width,e.height).unpad(n.width/2);return us.fromRect(i.toRect(),{fill:{color:t.background},stroke:{color:n.width?n.color:"",width:n.width,dashType:n.dashType}})},_getText:function(e){var t=this,n=t.options.text,i=t._textbox=new sB(e,{font:n.font,color:n.color,align:"center",vAlign:"bottom",margin:n.margin});return i.reflow(t.contentBox),i.renderVisual(),i.visual},_setOptions:function(e){var t=this;if(t.type=(e.type||t.options.type).toLowerCase(),"upca"==t.type&&(t.type="ean13",e.value="0"+e.value),"upce"==t.type&&(t.type="ean8",e.value="0"+e.value),!h[t.type])throw new Error("Encoding "+t.type+"is not supported.");t.encoding=new h[t.type],t.options=i(!0,t.options,e)},options:{name:"Barcode",renderAs:"svg",value:"",type:"code39",checksum:!1,width:0,height:0,color:"black",background:"white",text:{visible:!0,font:"16px Consolas, Monaco, Sans Mono, monospace, sans-serif",color:"black",margin:{top:0,bottom:0,left:0,right:0}},border:{width:0,dashType:"solid",color:"black"},padding:{top:0,bottom:0,left:0,right:0}}});s.ExportMixin.extend(y.fn),s.ui.plugin(y),t.deepExtend(s,{encodings:h,Encoding:u})}(window.kendo.jQuery);kendo;!function(e,t){var n=window.kendo,i=e.extend,r=n.dataviz,o=n.ui.Widget,a="0000",s="numeric",l="alphanumeric",c="byte",d={1:0},u={0:1},h=[[1,0],[1,25,0]],p={15:20,16:20,18:24,19:24,22:20,24:22,26:24,28:20,30:20,31:24,32:28,33:24,36:18,37:22,39:20,40:24},f=[{L:{groups:[[1,19]],totalDataCodewords:19,errorCodewordsPerBlock:7},M:{groups:[[1,16]],totalDataCodewords:16,errorCodewordsPerBlock:10},Q:{groups:[[1,13]],totalDataCodewords:13,errorCodewordsPerBlock:13},H:{groups:[[1,9]],totalDataCodewords:9,errorCodewordsPerBlock:17}},{L:{groups:[[1,34]],totalDataCodewords:34,errorCodewordsPerBlock:10},M:{groups:[[1,28]],totalDataCodewords:28,errorCodewordsPerBlock:16},Q:{groups:[[1,22]],totalDataCodewords:22,errorCodewordsPerBlock:22},H:{groups:[[1,16]],totalDataCodewords:16,errorCodewordsPerBlock:28}},{L:{groups:[[1,55]],totalDataCodewords:55,errorCodewordsPerBlock:15},M:{groups:[[1,44]],totalDataCodewords:44,errorCodewordsPerBlock:26},Q:{groups:[[2,17]],totalDataCodewords:34,errorCodewordsPerBlock:18},H:{groups:[[2,13]],totalDataCodewords:26,errorCodewordsPerBlock:22}},{L:{groups:[[1,80]],totalDataCodewords:80,errorCodewordsPerBlock:20},M:{groups:[[2,32]],totalDataCodewords:64,errorCodewordsPerBlock:18},Q:{groups:[[2,24]],totalDataCodewords:48,errorCodewordsPerBlock:26},H:{groups:[[4,9]],totalDataCodewords:36,errorCodewordsPerBlock:16}},{L:{groups:[[1,108]],totalDataCodewords:108,errorCodewordsPerBlock:26},M:{groups:[[2,43]],totalDataCodewords:86,errorCodewordsPerBlock:24},Q:{groups:[[2,15],[2,16]],totalDataCodewords:62,errorCodewordsPerBlock:18},H:{groups:[[2,11],[2,12]],totalDataCodewords:46,errorCodewordsPerBlock:22}},{L:{groups:[[2,68]],totalDataCodewords:136,errorCodewordsPerBlock:18},M:{groups:[[4,27]],totalDataCodewords:108,errorCodewordsPerBlock:16},Q:{groups:[[4,19]],totalDataCodewords:76,errorCodewordsPerBlock:24},H:{groups:[[4,15]],totalDataCodewords:60,errorCodewordsPerBlock:28}},{L:{groups:[[2,78]],totalDataCodewords:156,errorCodewordsPerBlock:20},M:{groups:[[4,31]],totalDataCodewords:124,errorCodewordsPerBlock:18},Q:{groups:[[2,14],[4,15]],totalDataCodewords:88,errorCodewordsPerBlock:18},H:{groups:[[4,13],[1,14]],totalDataCodewords:66,errorCodewordsPerBlock:26}},{L:{groups:[[2,97]],totalDataCodewords:194,errorCodewordsPerBlock:24},M:{groups:[[2,38],[2,39]],totalDataCodewords:154,errorCodewordsPerBlock:22},Q:{groups:[[4,18],[2,19]],totalDataCodewords:110,errorCodewordsPerBlock:22},H:{groups:[[4,14],[2,15]],totalDataCodewords:86,errorCodewordsPerBlock:26}},{L:{groups:[[2,116]],totalDataCodewords:232,errorCodewordsPerBlock:30},M:{groups:[[3,36],[2,37]],totalDataCodewords:182,errorCodewordsPerBlock:22},Q:{groups:[[4,16],[4,17]],totalDataCodewords:132,errorCodewordsPerBlock:20},H:{groups:[[4,12],[4,13]],totalDataCodewords:100,errorCodewordsPerBlock:24}},{L:{groups:[[2,68],[2,69]],totalDataCodewords:274,errorCodewordsPerBlock:18},M:{groups:[[4,43],[1,44]],totalDataCodewords:216,errorCodewordsPerBlock:26},Q:{groups:[[6,19],[2,20]],totalDataCodewords:154,errorCodewordsPerBlock:24},H:{groups:[[6,15],[2,16]],totalDataCodewords:122,errorCodewordsPerBlock:28}},{L:{groups:[[4,81]],totalDataCodewords:324,errorCodewordsPerBlock:20},M:{groups:[[1,50],[4,51]],totalDataCodewords:254,errorCodewordsPerBlock:30},Q:{groups:[[4,22],[4,23]],totalDataCodewords:180,errorCodewordsPerBlock:28},H:{groups:[[3,12],[8,13]],totalDataCodewords:140,errorCodewordsPerBlock:24}},{L:{groups:[[2,92],[2,93]],totalDataCodewords:370,errorCodewordsPerBlock:24},M:{groups:[[6,36],[2,37]],totalDataCodewords:290,errorCodewordsPerBlock:22},Q:{groups:[[4,20],[6,21]],totalDataCodewords:206,errorCodewordsPerBlock:26},H:{groups:[[7,14],[4,15]],totalDataCodewords:158,errorCodewordsPerBlock:28}},{L:{groups:[[4,107]],totalDataCodewords:428,errorCodewordsPerBlock:26},M:{groups:[[8,37],[1,38]],totalDataCodewords:334,errorCodewordsPerBlock:22},Q:{groups:[[8,20],[4,21]],totalDataCodewords:244,errorCodewordsPerBlock:24},H:{groups:[[12,11],[4,12]],totalDataCodewords:180,errorCodewordsPerBlock:22}},{L:{groups:[[3,115],[1,116]],totalDataCodewords:461,errorCodewordsPerBlock:30},M:{groups:[[4,40],[5,41]],totalDataCodewords:365,errorCodewordsPerBlock:24},Q:{groups:[[11,16],[5,17]],totalDataCodewords:261,errorCodewordsPerBlock:20},H:{groups:[[11,12],[5,13]],totalDataCodewords:197,errorCodewordsPerBlock:24}},{L:{groups:[[5,87],[1,88]],totalDataCodewords:523,errorCodewordsPerBlock:22},M:{groups:[[5,41],[5,42]],totalDataCodewords:415,errorCodewordsPerBlock:24},Q:{groups:[[5,24],[7,25]],totalDataCodewords:295,errorCodewordsPerBlock:30},H:{groups:[[11,12],[7,13]],totalDataCodewords:223,errorCodewordsPerBlock:24}},{L:{groups:[[5,98],[1,99]],totalDataCodewords:589,errorCodewordsPerBlock:24},M:{groups:[[7,45],[3,46]],totalDataCodewords:453,errorCodewordsPerBlock:28},Q:{groups:[[15,19],[2,20]],totalDataCodewords:325,errorCodewordsPerBlock:24},H:{groups:[[3,15],[13,16]],totalDataCodewords:253,errorCodewordsPerBlock:30}},{L:{groups:[[1,107],[5,108]],totalDataCodewords:647,errorCodewordsPerBlock:28},M:{groups:[[10,46],[1,47]],totalDataCodewords:507,errorCodewordsPerBlock:28},Q:{groups:[[1,22],[15,23]],totalDataCodewords:367,errorCodewordsPerBlock:28},H:{groups:[[2,14],[17,15]],totalDataCodewords:283,errorCodewordsPerBlock:28}},{L:{groups:[[5,120],[1,121]],totalDataCodewords:721,errorCodewordsPerBlock:30},M:{groups:[[9,43],[4,44]],totalDataCodewords:563,errorCodewordsPerBlock:26},Q:{groups:[[17,22],[1,23]],totalDataCodewords:397,errorCodewordsPerBlock:28},H:{groups:[[2,14],[19,15]],totalDataCodewords:313,errorCodewordsPerBlock:28}},{L:{groups:[[3,113],[4,114]],totalDataCodewords:795,errorCodewordsPerBlock:28},M:{groups:[[3,44],[11,45]],totalDataCodewords:627,errorCodewordsPerBlock:26},Q:{groups:[[17,21],[4,22]],totalDataCodewords:445,errorCodewordsPerBlock:26},H:{groups:[[9,13],[16,14]],totalDataCodewords:341,errorCodewordsPerBlock:26}},{L:{groups:[[3,107],[5,108]],totalDataCodewords:861,errorCodewordsPerBlock:28},M:{groups:[[3,41],[13,42]],totalDataCodewords:669,errorCodewordsPerBlock:26},Q:{groups:[[15,24],[5,25]],totalDataCodewords:485,errorCodewordsPerBlock:30},H:{groups:[[15,15],[10,16]],totalDataCodewords:385,errorCodewordsPerBlock:28}},{L:{groups:[[4,116],[4,117]],totalDataCodewords:932,errorCodewordsPerBlock:28},M:{groups:[[17,42]],totalDataCodewords:714,errorCodewordsPerBlock:26},Q:{groups:[[17,22],[6,23]],totalDataCodewords:512,errorCodewordsPerBlock:28},H:{groups:[[19,16],[6,17]],totalDataCodewords:406,errorCodewordsPerBlock:30}},{L:{groups:[[2,111],[7,112]],totalDataCodewords:1006,errorCodewordsPerBlock:28},M:{groups:[[17,46]],totalDataCodewords:782,errorCodewordsPerBlock:28},Q:{groups:[[7,24],[16,25]],totalDataCodewords:568,errorCodewordsPerBlock:30},H:{groups:[[34,13]],totalDataCodewords:442,errorCodewordsPerBlock:24}},{L:{groups:[[4,121],[5,122]],totalDataCodewords:1094,errorCodewordsPerBlock:30},M:{groups:[[4,47],[14,48]],totalDataCodewords:860,errorCodewordsPerBlock:28},Q:{groups:[[11,24],[14,25]],totalDataCodewords:614,errorCodewordsPerBlock:30},H:{groups:[[16,15],[14,16]],totalDataCodewords:464,errorCodewordsPerBlock:30}},{L:{groups:[[6,117],[4,118]],totalDataCodewords:1174,errorCodewordsPerBlock:30},M:{groups:[[6,45],[14,46]],totalDataCodewords:914,errorCodewordsPerBlock:28},Q:{groups:[[11,24],[16,25]],totalDataCodewords:664,errorCodewordsPerBlock:30},H:{groups:[[30,16],[2,17]],totalDataCodewords:514,errorCodewordsPerBlock:30}},{L:{groups:[[8,106],[4,107]],totalDataCodewords:1276,errorCodewordsPerBlock:26},M:{groups:[[8,47],[13,48]],totalDataCodewords:1e3,errorCodewordsPerBlock:28},Q:{groups:[[7,24],[22,25]],totalDataCodewords:718,errorCodewordsPerBlock:30},H:{groups:[[22,15],[13,16]],totalDataCodewords:538,errorCodewordsPerBlock:30}},{L:{groups:[[10,114],[2,115]],totalDataCodewords:1370,errorCodewordsPerBlock:28},M:{groups:[[19,46],[4,47]],totalDataCodewords:1062,errorCodewordsPerBlock:28},Q:{groups:[[28,22],[6,23]],totalDataCodewords:754,errorCodewordsPerBlock:28},H:{groups:[[33,16],[4,17]],totalDataCodewords:596,errorCodewordsPerBlock:30}},{L:{groups:[[8,122],[4,123]],totalDataCodewords:1468,errorCodewordsPerBlock:30},M:{groups:[[22,45],[3,46]],totalDataCodewords:1128,errorCodewordsPerBlock:28},Q:{groups:[[8,23],[26,24]],totalDataCodewords:808,errorCodewordsPerBlock:30},H:{groups:[[12,15],[28,16]],totalDataCodewords:628,errorCodewordsPerBlock:30}},{L:{groups:[[3,117],[10,118]],totalDataCodewords:1531,errorCodewordsPerBlock:30},M:{groups:[[3,45],[23,46]],totalDataCodewords:1193,errorCodewordsPerBlock:28},Q:{groups:[[4,24],[31,25]],totalDataCodewords:871,errorCodewordsPerBlock:30},H:{groups:[[11,15],[31,16]],totalDataCodewords:661,errorCodewordsPerBlock:30}},{L:{groups:[[7,116],[7,117]],totalDataCodewords:1631,errorCodewordsPerBlock:30},M:{groups:[[21,45],[7,46]],totalDataCodewords:1267,errorCodewordsPerBlock:28},Q:{groups:[[1,23],[37,24]],totalDataCodewords:911,errorCodewordsPerBlock:30},H:{groups:[[19,15],[26,16]],totalDataCodewords:701,errorCodewordsPerBlock:30}},{L:{groups:[[5,115],[10,116]],totalDataCodewords:1735,errorCodewordsPerBlock:30},M:{groups:[[19,47],[10,48]],totalDataCodewords:1373,errorCodewordsPerBlock:28},Q:{groups:[[15,24],[25,25]],totalDataCodewords:985,errorCodewordsPerBlock:30},H:{groups:[[23,15],[25,16]],totalDataCodewords:745,errorCodewordsPerBlock:30}},{L:{groups:[[13,115],[3,116]],totalDataCodewords:1843,errorCodewordsPerBlock:30},M:{groups:[[2,46],[29,47]],totalDataCodewords:1455,errorCodewordsPerBlock:28},Q:{groups:[[42,24],[1,25]],totalDataCodewords:1033,errorCodewordsPerBlock:30},H:{groups:[[23,15],[28,16]],totalDataCodewords:793,errorCodewordsPerBlock:30}},{L:{groups:[[17,115]],totalDataCodewords:1955,errorCodewordsPerBlock:30},M:{groups:[[10,46],[23,47]],totalDataCodewords:1541,errorCodewordsPerBlock:28},Q:{groups:[[10,24],[35,25]],totalDataCodewords:1115,errorCodewordsPerBlock:30},H:{groups:[[19,15],[35,16]],totalDataCodewords:845,errorCodewordsPerBlock:30}},{L:{groups:[[17,115],[1,116]],totalDataCodewords:2071,errorCodewordsPerBlock:30},M:{groups:[[14,46],[21,47]],totalDataCodewords:1631,errorCodewordsPerBlock:28},Q:{groups:[[29,24],[19,25]],totalDataCodewords:1171,errorCodewordsPerBlock:30},H:{groups:[[11,15],[46,16]],totalDataCodewords:901,errorCodewordsPerBlock:30}},{L:{groups:[[13,115],[6,116]],totalDataCodewords:2191,errorCodewordsPerBlock:30},M:{groups:[[14,46],[23,47]],totalDataCodewords:1725,errorCodewordsPerBlock:28},Q:{groups:[[44,24],[7,25]],totalDataCodewords:1231,errorCodewordsPerBlock:30},H:{groups:[[59,16],[1,17]],totalDataCodewords:961,errorCodewordsPerBlock:30}},{L:{groups:[[12,121],[7,122]],totalDataCodewords:2306,errorCodewordsPerBlock:30},M:{groups:[[12,47],[26,48]],totalDataCodewords:1812,errorCodewordsPerBlock:28},Q:{groups:[[39,24],[14,25]],totalDataCodewords:1286,errorCodewordsPerBlock:30},H:{groups:[[22,15],[41,16]],totalDataCodewords:986,errorCodewordsPerBlock:30}},{L:{groups:[[6,121],[14,122]],totalDataCodewords:2434,errorCodewordsPerBlock:30},M:{groups:[[6,47],[34,48]],totalDataCodewords:1914,errorCodewordsPerBlock:28},Q:{groups:[[46,24],[10,25]],totalDataCodewords:1354,errorCodewordsPerBlock:30},H:{groups:[[2,15],[64,16]],totalDataCodewords:1054,errorCodewordsPerBlock:30}},{L:{groups:[[17,122],[4,123]],totalDataCodewords:2566,errorCodewordsPerBlock:30},M:{groups:[[29,46],[14,47]],totalDataCodewords:1992,errorCodewordsPerBlock:28},Q:{groups:[[49,24],[10,25]],totalDataCodewords:1426,errorCodewordsPerBlock:30},H:{groups:[[24,15],[46,16]],totalDataCodewords:1096,errorCodewordsPerBlock:30}},{L:{groups:[[4,122],[18,123]],totalDataCodewords:2702,errorCodewordsPerBlock:30},M:{groups:[[13,46],[32,47]],totalDataCodewords:2102,errorCodewordsPerBlock:28},Q:{groups:[[48,24],[14,25]],totalDataCodewords:1502,errorCodewordsPerBlock:30},H:{groups:[[42,15],[32,16]],totalDataCodewords:1142,errorCodewordsPerBlock:30}},{L:{groups:[[20,117],[4,118]],totalDataCodewords:2812,errorCodewordsPerBlock:30},M:{groups:[[40,47],[7,48]],totalDataCodewords:2216,errorCodewordsPerBlock:28},Q:{groups:[[43,24],[22,25]],totalDataCodewords:1582,errorCodewordsPerBlock:30},H:{groups:[[10,15],[67,16]],totalDataCodewords:1222,errorCodewordsPerBlock:30}},{L:{groups:[[19,118],[6,119]],totalDataCodewords:2956,errorCodewordsPerBlock:30},M:{groups:[[18,47],[31,48]],totalDataCodewords:2334,errorCodewordsPerBlock:28},Q:{groups:[[34,24],[34,25]],totalDataCodewords:1666,errorCodewordsPerBlock:30},H:{groups:[[20,15],[61,16]],totalDataCodewords:1276,errorCodewordsPerBlock:30}}],m=[1,0,1,1,1],g=[1,0,1],v={L:"01",M:"00",Q:"11",H:"10"},_=["11101100","00010001"],b=[function(e,t){return(e+t)%2==0},function(e){return e%2==0},function(e,t){return t%3==0},function(e,t){return(e+t)%3==0},function(e,t){return(Math.floor(e/2)+Math.floor(t/3))%2==0},function(e,t){return e*t%2+e*t%3==0},function(e,t){return(e*t%2+e*t%3)%2==0},function(e,t){return((e+t)%2+e*t%3)%2==0}],y=/^\d+/,w="A-Z0-9 $%*+./:-",k=new RegExp("^[A-Z $%*+./:-]+"),x=new RegExp("^["+w+"]+"),C=new RegExp("^[^"+w+"]+"),S=Math.round,T=[[0,1],[1,1],[1,2],[2,2],[2,1],[3,1],[3,0],[2,0],[2,-1],[1,-1],[1,0]],D=[[0,1],[1,1],[1,0]];function A(e){return parseInt(e,2)}function M(e,t){var n=Number(e).toString(2);return n.length<t&&(n=new Array(t-n.length+1).join(0)+n),n}function E(e,t){for(var n=[],i=0;i<e.length;)n.push(e.substring(i,i+t)),i+=t;return n}var I=n.Class.extend({getVersionIndex:function(e){return e<10?0:e>26?2:1},getBitsCharacterCount:function(e){return this.bitsInCharacterCount[this.getVersionIndex(e||40)]},getModeCountString:function(e,t){return this.modeIndicator+M(e,this.getBitsCharacterCount(t))},encode:function(){},getStringBitsLength:function(){},getValue:function(){},modeIndicator:"",bitsInCharacterCount:[]}),z={};z[s]=I.extend({bitsInCharacterCount:[10,12,14],modeIndicator:"0001",getValue:function(e){return parseInt(e,10)},encode:function(e,t){for(var n=E(e,3),i=this.getModeCountString(e.length,t),r=0;r<n.length-1;r++)i+=M(n[r],10);return i+M(n[r],1+3*n[r].length)},getStringBitsLength:function(e,t){var n=e%3;return 4+this.getBitsCharacterCount(t)+10*Math.floor(e/3)+3*n+(0===n?0:1)}}),z[l]=I.extend({characters:{0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,G:16,H:17,I:18,J:19,K:20,L:21,M:22,N:23,O:24,P:25,Q:26,R:27,S:28,T:29,U:30,V:31,W:32,X:33,Y:34,Z:35," ":36,$:37,"%":38,"*":39,"+":40,"-":41,".":42,"/":43,":":44},bitsInCharacterCount:[9,11,13],modeIndicator:"0010",getValue:function(e){return this.characters[e]},encode:function(e,t){for(var n=this,i=E(e,2),r=n.getModeCountString(e.length,t),o=0;o<i.length-1;o++)r+=M(45*n.getValue(i[o].charAt(0))+n.getValue(i[o].charAt(1)),11);return r+M(2==i[o].length?45*n.getValue(i[o].charAt(0))+n.getValue(i[o].charAt(1)):n.getValue(i[o].charAt(0)),1+5*i[o].length)},getStringBitsLength:function(e,t){return 4+this.getBitsCharacterCount(t)+11*Math.floor(e/2)+e%2*6}}),z[c]=I.extend({bitsInCharacterCount:[8,16,16],modeIndicator:"0100",getValue:function(e){var t=e.charCodeAt(0);if(t<=127||160<=t&&t<=255)return t;throw new Error("Unsupported character: "+e)},encode:function(e,t){for(var n=this.getModeCountString(e.length,t),i=0;i<e.length;i++)n+=M(this.getValue(e.charAt(i)),8);return n},getStringBitsLength:function(e,t){return 4+this.getBitsCharacterCount(t)+8*e}});var P={};for(var H in z)P[H]=new z[H];var F=function(e){var n=this,i=e.length-1,r=e.length-1,o=r,a=-1,s=0;n.move=function(){i+=a*s,r=o-(s^=1)},n.getNextCell=function(){for(;e[i][r]!==t;)n.move(),(i<0||i>=e.length)&&(r=o-=8!=o?2:3,i=(a=-a)<0?e.length-1:0);return{row:i,column:r}},n.getNextRemainderCell=function(){if(n.move(),e[i][r]===t)return{row:i,column:r}}};function R(e,t,n,i){for(var r=0;r<e.length;r++)e[r][n][i]=t}function L(e,t,n,i){for(var r=0;r<b.length;r++)e[r][n][i]=b[r](n,i)?1^t:parseInt(t,10)}var B=function(e,t){for(var n,i,r,o=new F(e[0]),a=0;a<t.length;a++)for(n=t[a],i=0;n.length>0;){for(var s=0;s<n.length;s++)for(var l=0;l<8;l++)r=o.getNextCell(),L(e,n[s][i].charAt(l),r.row,r.column);for(i++;n[0]&&i==n[0].length;)n.splice(0,1)}for(;r=o.getNextRemainderCell();)L(e,0,r.row,r.column)},O=function(e,t){for(var n=8*t,i=0,r=0;e.length<n&&i<4;)e+=a.charAt(i++);for(e.length%8!=0&&(e+=new Array(9-e.length%8).join("0"));e.length<n;)e+=_[r],r^=1;return e};var V=function(e,t){for(var n=[],i=e.length-2;i>=0;i--)n[i]=e[i]^t[i];return n},N=function(e,n){for(var i=[],r=0;r<e.length;r++)for(var o=0;o<n.length;o++)i[r+o]===t?i[r+o]=(e[r]+(n[o]>=0?n[o]:0))%255:i[r+o]=d[u[i[r+o]]^u[(e[r]+n[o])%255]];return i};function $(e,n){var i=[],r=e.length-1;do{i[r]=u[(e[r]+n)%255],r--}while(e[r]!==t);return i}!function(){for(var e,t=1;t<255;t++)(e=2*u[t-1])>255&&(e^=285),u[t]=e,d[e]=t;e=2*u[t-1]^285,u[t]=e,u[-1]=0}(),function(){for(var e=2;e<=68;e++){var t=h[e-1],n=[e,0];h[e]=N(t,n)}}();var U=function(e,t){var n,i,r=h[t-1],o=new Array(t).concat(e),a=new Array(o.length-r.length).concat(r),s=e.length,l=[];for(i=0;i<s;i++)n=$(a,d[o[o.length-1]]),a.splice(0,1),o=V(n,o);for(i=o.length-1;i>=0;i--)l[t-1-i]=M(o[i],8);return l},W=function(e,t){for(var n,i,r,o,a,s=0,l=[],c=[],d=t.groups,u=0;u<d.length;u++){r=d[u][0];for(var h=0;h<r;h++){i=d[u][1],n=[],o=[];for(var p=1;p<=i;p++)a=e.substring(s,s+8),n.push(a),o[i-p]=A(a),s+=8;l.push(n),c.push(U(o,t.errorCodewordsPerBlock))}}return[l,c]},j=function(e,t,n,i,r){var o,a,d=y.exec(e),u=d?d[0]:"",h=k.exec(e),p=h?h[0]:"",f=x.exec(e),m=f?f[0]:"";return u&&(u.length>=t||e.length==u.length||u.length>=n&&!x.test(e.charAt(u.length)))?(o=s,a=u):m&&(e.length==m.length||m.length>=i||r==l)?(o=l,a=u||p):(o=c,a=m?m+C.exec(e.substring(m.length))[0]:C.exec(e)[0]),{mode:o,modeString:a}},q=function(e){var t,n=[],i=0;for(n.push(j(e,8,5,8,t)),t=n[0].mode,e=e.substr(n[0].modeString.length);e.length>0;){var r=j(e,17,9,16,t);r.mode!=t?(t=r.mode,n.push(r),i++):n[i].modeString+=r.modeString,e=e.substr(r.modeString.length)}return n},G=function(e){for(var t=0,n=0;n<e.length;n++)t+=P[e[n].mode].getStringBitsLength(e[n].modeString.length);return Math.ceil(t/8)},K=function(e,t){var n=0,i=f.length-1,r=Math.floor(f.length/2);do{e<f[r][t].totalDataCodewords?i=r:n=r,r=n+Math.floor((i-n)/2)}while(i-n>1);return e<=f[n][t].totalDataCodewords?r+1:i+1},Y=function(e,t){for(var n="",i=0;i<e.length;i++)n+=P[e[i].mode].encode(e[i].modeString,t);return n},Q=function(e){var t,n="";if(0===A(e))return"101010000010010";t=X(A(e),"10100110111",15);for(var i=0;i<t.length;i++)n+=t.charAt(i)^"101010000010010".charAt(i);return n},X=function(e,t,n){var i=A(t),r=t.length-1,o=e<<r,a=M(e,n-r),s=Z(o,i);return s=a+M(s,r)},Z=function(e,t){var n=t.toString(2).length,i=e.toString(2).length;do{i=(e^=t<<i-n).toString(2).length}while(i>=n);return e};function J(e,t){return parseInt(e.charAt(t),10)}var ee=function(e){for(var t=[],n=17+4*e,i=0;i<b.length;i++){t[i]=new Array(n);for(var r=0;r<n;r++)t[i][r]=new Array(n)}return t},te=function(e,t){var n,i,r=e[0],o=0,a=t.length;for(n=0,i=8;n<=8;n++)6!==n&&R(e,J(t,a-1-o++),n,i);for(n=8,i=7;i>=0;i--)6!==i&&R(e,J(t,a-1-o++),n,i);for(o=0,i=r.length-1,n=8;i>=r.length-8;i--)R(e,J(t,a-1-o++),n,i);for(R(e,1,r.length-8,8),n=r.length-7,i=8;n<r.length;n++)R(e,J(t,a-1-o++),n,i)},ne=function(e){return X(e,"1111100100101",18)},ie=function(e,t){for(var n,i,r,o=e[0].length,a=o-11,s=o-11,l=0;l<t.length;l++)n=Math.floor(l/3),i=l%3,R(e,r=J(t,t.length-l-1),0+n,a+i),R(e,r,s+i,0+n)},re=function(e,t,n,i){for(var r,o=t.length+2,a=t.length+1,s=0;s<t.length;s++)for(var l=s;l<o-s;l++)R(e,r=t[s],n+l,i+s),R(e,r,n+s,i+l),R(e,r,n+a-l,i+a-s),R(e,r,n+a-s,i+a-l)},oe=function(e,t,n,i){var r=n,o=i,a=e[0];do{R(e,0,r,i),R(e,0,n,o),r+=t[0],o+=t[1]}while(r>=0&&r<a.length)},ae=function(e){var t=e[0].length;re(e,m,0,0),oe(e,[-1,-1],7,7),re(e,m,t-7,0),oe(e,[1,-1],t-8,7),re(e,m,0,t-7),oe(e,[-1,1],7,t-8)},se=function(e,n){if(!(n<2)){var i,r,o=e[0],a=o.length,s=Math.floor(n/7),l=[6],c=0;for((i=p[n])?r=(a-13-i)/s:i=r=(a-13)/(s+1),l.push(l[c++]+i);l[c]+r<a;)l.push(l[c++]+r);for(var d=0;d<l.length;d++)for(var u=0;u<l.length;u++)o[l[d]][l[u]]===t&&re(e,g,l[d]-2,l[u]-2)}},le=function(e){for(var t=1,n=e[0].length,i=8;i<n-8;i++)R(e,t,6,i),R(e,t,i,6),t^=1},ce=function(e){var t,n,i=[],r=[],o=[],a=[],s=[],l=e[0].length;for(n=0;n<e.length;n++)i[n]=0,o[n]=0,s[n]=[0,0],a[n]=[0,0],r[n]=[];for(n=0;n<l;n++)for(var c=0;c<l;c++)for(var d=0;d<e.length;d++)t=e[d],o[d]+=parseInt(t[n][c],10),r[d][0]===t[n][c]&&n+1<l&&c-1>=0&&t[n+1][c]==r[d][0]&&t[n+1][c-1]==r[d][0]&&(i[d]+=3),de(d,a,i,0,t[n][c]),de(d,a,i,1,t[c][n]),ue(d,i,r,t[n][c],s,0),ue(d,i,r,t[c][n],s,1);var u,h=l*l,p=Number.MAX_VALUE;for(n=0;n<i.length;n++)i[n]+=he(o[n],h),i[n]<p&&(p=i[n],u=n);return u};function de(e,t,n,i,r){t[e][i]=(t[e][i]<<1^r)%128,93==t[e][i]&&(n[e]+=40)}function ue(e,t,n,i,r,o){n[e][o]==i?r[e][o]++:(n[e][o]=i,r[e][o]>=5&&(t[e]+=3+r[e][o]-5),r[e][o]=1)}function he(e,t){var n=Math.floor(e/t*100),i=n%5,r=Math.abs(n-i-50),o=Math.abs(n+5-i-50);return 10*Math.min(r/5,o/5)}var pe=function(e,t){this.dataString=e,this.version=t},fe=function(){this.getEncodingResult=function(e,t){var n=q(e),i=G(n),r=K(i,t),o=Y(n,r);return new pe(o,r)}},me=function(){this.mode=P[this.encodingMode]};me.fn=me.prototype={encodingMode:c,utfBOM:"111011111011101110111111",initialModeCountStringLength:20,getEncodingResult:function(e,t){var n=this,i=n.encode(e),r=n.getDataCodewordsCount(i),o=K(r,t),a=n.mode.getModeCountString(i.length/8,o)+i;return new pe(a,o)},getDataCodewordsCount:function(e){var t=e.length;return Math.ceil((this.initialModeCountStringLength+t)/8)},encode:function(e){for(var t=this.utfBOM,n=0;n<e.length;n++)t+=this.encodeCharacter(e.charCodeAt(n));return t},encodeCharacter:function(e){var t=this.getBytesCount(e),n=t-1,i="";if(1==t)i=M(e,8);else{for(var r=8-t,o=0;o<n;o++)i=M(e>>6*o&63|128,8)+i;i=(e>>6*n|255>>r<<r).toString(2)+i}return i},getBytesCount:function(e){for(var t=this.ranges,n=0;n<t.length;n++)if(e<t[n])return n+1},ranges:[128,2048,65536,2097152,67108864]};var ge=function(e){return e&&e.toLowerCase().indexOf("utf_8")>=0?new me:new fe},ve=function(e,t,n){var i=new ge(n).getEncodingResult(e,t),r=i.version,o=f[r-1][t],a=O(i.dataString,o.totalDataCodewords),s=W(a,o),l=ee(r);ae(l),se(l,r),le(l),r>=7&&ie(l,M(0,18)),te(l,M(0,15)),B(l,s);var c=ce(l),d=l[c];r>=7&&ie([d],ne(r));var u=v[t]+M(c,3);return te([d],Q(u)),d},_e={DEFAULT_SIZE:200,QUIET_ZONE_LENGTH:4,DEFAULT_ERROR_CORRECTION_LEVEL:"L",DEFAULT_BACKGROUND:"#fff",DEFAULT_DARK_MODULE_COLOR:"#000",MIN_BASE_UNIT_SIZE:1},be=o.extend({init:function(t,n){var i=this;o.fn.init.call(i,t,n),i.element=e(t),i.wrapper=i.element,i.element.addClass("k-qrcode"),i.surfaceWrap=e("<div />").css("position","relative").appendTo(this.element),i.surface=vc.create(i.surfaceWrap[0],{type:i.options.renderAs}),i.setOptions(n)},redraw:function(){var e=this._getSize();this.surfaceWrap.css({width:e,height:e}),this.surface.clear(),this.surface.resize(),this.createVisual(),this.surface.draw(this.visual)},getSize:function(){return n.dimensions(this.element)},_resize:function(){this.redraw()},createVisual:function(){this.visual=this._render()},exportVisual:function(){return this._render()},_render:function(){var e,t,n,i,r,o=this,a=o._value,s=o.options.border||{},l=o.options.padding||0,c=s.width||0;s.width=c;var d=new vs;return a&&(n=ve(a,o.options.errorCorrection,o.options.encoding),r=(i=o._getSize())-2*(c+l),e=o._calculateBaseUnit(r,n.length),t=c+l+(r-n.length*e)/2,d.append(o._renderBackground(i,s)),d.append(o._renderMatrix(n,e,t)),o._hasCustomLogo()?d.append(o._renderLogo(i,e)):o._isSwiss()&&d.append(o._renderSwissCode(i,e))),d},_renderLogo:function(e,t){var i,r=S(e/2),o=this._getLogoSize(7*t),a=this.options.overlay.imageUrl,s={x:r-o.width/2,y:r-o.height/2};return i=new n.geometry.Rect(new n.geometry.Point(s.x,s.y),new n.geometry.Size(o.width,o.height)),new ms(a,i)},_renderSwissCode:function(e,t){var n=this._getLogoSize(7*t),i=(n=Math.max(n.width,n.height))/4,r=i/2,o=e/2,a={},s=new vs;return a.x=a.y=Math.ceil(o-t-n/2),s.append(this._renderShape(a,Math.ceil(n+2*t),D,"#fff")),a.x=a.y=o-n/2,s.append(this._renderShape(a,n,D,this.options.color)),a.x=o+r-n/2,a.y=o+r+i-n/2,s.append(this._renderShape(a,i,T,"#fff")),s},_renderShape:function(e,t,n,i){var r=new hs({fill:{color:i},stroke:null});r.moveTo(e.x,e.y);for(var o=0;o<n.length;o++)r.lineTo(e.x+t*n[o][0],e.y+t*n[o][1]);return r.close(),r},_getSize:function(){var e,t=this;if(t.options.size)e=parseInt(t.options.size,10);else{var n=t.element,i=Math.min(n.width(),n.height());e=i>0?i:_e.DEFAULT_SIZE}return e},_calculateBaseUnit:function(e,t){var n=Math.floor(e/t);if(n<_e.MIN_BASE_UNIT_SIZE)throw new Error("Insufficient size.");return n*t>=e&&n-1>=_e.MIN_BASE_UNIT_SIZE&&n--,n},_renderMatrix:function(e,t,n){for(var i=new hs({fill:{color:this.options.color},stroke:null}),r=0;r<e.length;r++)for(var o=n+r*t,a=0;a<e.length;){for(;0===e[r][a]&&a<e.length;)a++;if(a<e.length){for(var s=a;1==e[r][a];)a++;var l=S(n+s*t),c=S(o),d=S(n+a*t),u=S(o+t);i.moveTo(l,c).lineTo(l,u).lineTo(d,u).lineTo(d,c).close()}}return i},_renderBackground:function(e,t){var n=new VL(0,0,e,e).unpad(t.width/2);return us.fromRect(n.toRect(),{fill:{color:this.options.background},stroke:{color:t.color,width:t.width}})},setOptions:function(e){var n=this;e=e||{},n.options=i(n.options,e),e.value!==t&&(n._value=n.options.value+""),n.redraw()},value:function(e){var n=this;if(e===t)return n._value;n._value=e+"",n.redraw()},options:{name:"QRCode",renderAs:"svg",encoding:"ISO_8859_1",value:"",errorCorrection:_e.DEFAULT_ERROR_CORRECTION_LEVEL,background:_e.DEFAULT_BACKGROUND,color:_e.DEFAULT_DARK_MODULE_COLOR,size:"",padding:0,border:{color:"",width:0},overlay:{type:"image",imageUrl:"",width:0,height:0}},_hasCustomLogo:function(){return!!this.options.overlay.imageUrl},_isSwiss:function(){return"swiss"===this.options.overlay.type},_getLogoSize:function(e){var t=this.options.overlay.width,n=this.options.overlay.height;return t||n?t&&!n?n=t:!t&&n&&(t=n):t=n=e,{width:t,height:n}}});r.ExportMixin.extend(be.fn),r.ui.plugin(be),n.deepExtend(r,{QRCode:be,QRCodeDefaults:_e,QRCodeFunctions:{FreeCellVisitor:F,fillData:B,padDataString:O,generateErrorCodewords:U,xorPolynomials:V,getBlocks:W,multiplyPolynomials:N,chooseMode:j,getModes:q,getDataCodewordsCount:G,getVersion:K,getDataString:Y,encodeFormatInformation:Q,encodeBCH:X,dividePolynomials:Z,initMatrices:ee,addFormatInformation:te,encodeVersionInformation:ne,addVersionInformation:ie,addCentricPattern:re,addFinderSeparator:oe,addFinderPatterns:ae,addAlignmentPatterns:se,addTimingFunctions:le,scoreMaskMatrixes:ce,encodeData:ve,UTF8Encoder:me},QRCodeFields:{modes:P,powersOfTwo:d,powersOfTwoResult:u,generatorPolynomials:h}})}(window.kendo.jQuery);kendo;!function(){window.kendo.dataviz=window.kendo.dataviz||{};var e=window.kendo,t=e.dataviz,n=t.ui.Chart,i=e.deepExtend,r=Pj,o=zj,a="change",s=n.extend({options:{name:"StockChart",dateField:"date",axisDefaults:{categoryAxis:{type:"date",baseUnit:"fit",justified:!0},valueAxis:{narrowRange:!0,labels:{format:"C"}}},navigator:{select:{},seriesDefaults:{markers:{visible:!1},tooltip:{visible:!0,template:({category:t})=>e.toString(t,"d")},line:{width:2}},hint:{},visible:!0},tooltip:{visible:!0},legend:{visible:!1},persistSeriesVisibility:!0},_createChart:function(e,t){this._initNavigatorOptions(e),this._instance=new Bj(this.element[0],e,t,{observer:new rR(this,{showTooltip:"_showTooltip",hideTooltip:"_hideTooltip",legendItemClick:"_onLegendItemClick",render:"_onRender",init:"_onInit",drilldown:"_onDrilldown",navigatorFilter:"_onNavigatorFilter",navigatorCreated:"_onNavigatorCreated"}),sender:this,rtl:this._isRtl()})},_initNavigatorOptions:function(t){var n=t.navigator||{},r=e.support,o=r.touch,a=r.browser.mozilla;i(n,{autoBindElements:!n.dataSource,partialRedraw:n.dataSource,liveDrag:!o&&!a})},_initDataSource:function(r){var o=r||{},a=o.dataSource,s=a&&a.serverFiltering,c=[].concat(o.categoryAxis)[0],d=(o.navigator||{}).select,u=d&&d.from&&d.to;if(s&&u){var h=[].concat(a.filter||[]),p=e.parseDate(d.from),f=e.parseDate(d.to),m=new t.DateCategoryAxis(i({baseUnit:"fit"},c,{categories:[p,f]}),e);a.filter=l(m.range().min,f).concat(h)}n.fn._initDataSource.call(this,r)},_onNavigatorCreated:function(e){this._instance=e.sender,this.options=e.sender.options,this._navigator=this.navigator=e.navigator,this._initNavigatorDataSource()},_initNavigatorDataSource:function(){var t=this.options.navigator,n=t.autoBind,i=t.dataSource;i&&(this._navigatorDataChangedHandler=this._navigatorDataChangedHandler||this._onNavigatorDataChanged.bind(this),this._navigatorDataSource=e.data.DataSource.create(i).bind(a,this._navigatorDataChangedHandler),hR(n)||(n=this.options.autoBind),n&&this._navigatorDataSource.fetch())},_bindNavigatorSeries:function(e,t){var n,i,o=e.length;for(n=0;n<o;n++)(i=e[n]).axis==r&&this._isBindable(i)&&(i.data=t)},_onNavigatorDataChanged:function(){var e,t,n,i=this,a=i._instance,s=i.options.categoryAxis,l=s.length,c=i._navigatorDataSource.view();for(this._bindNavigatorSeries(i.options.series,c),i._sourceSeries&&this._bindNavigatorSeries(i._sourceSeries,c),e=0;e<l;e++)(t=s[e]).pane==o&&(t.name==r?(i._bindCategoryAxis(t,c,e),n=t.categories):t.categories=n);if(a._model){var d=this.navigator;d.redraw(),d.setRange(),(!i.options.dataSource||i.options.dataSource&&i._dataBound)&&d.redrawSlaves()}},_bindCategories:function(){n.fn._bindCategories.call(this),this._instance&&this._instance.copyNavigatorCategories()},_onDataChanged:function(){n.fn._onDataChanged.call(this),this._dataBound=!0},setOptions:function(e){this._removeNavigatorDataSource(),this._initNavigatorOptions(e),this._instance.destroyNavigator(),n.fn.setOptions.call(this,e)},_onNavigatorFilter:function(e){this.dataSource.filter(l(e.from,e.to))},requiresHandlers:function(e){if(tR("navigatorFilter",e)){var t=this.dataSource;return t&&t.options.serverFiltering&&this.options.navigator.dataSource}return n.fn.requiresHandlers.call(this,e)},_removeNavigatorDataSource:function(){var e=this._navigatorDataSource;e&&(e.unbind(a,this._navigatorDataChangedHandler),delete this._navigatorDataSource)},destroy:function(){n.fn.destroy.call(this),this._removeNavigatorDataSource()}});function l(e,t){return[{field:"Date",operator:"gte",value:e},{field:"Date",operator:"lt",value:t}]}e.deepExtend(e.dataviz,{constants:Fj,Navigator:Rj,NavigatorHint:Ij,StockChart:s}),t.ui.plugin(s)}(window.kendo.jQuery);kendo;window.kendo.dataviz=window.kendo.dataviz||{};const bZ=window.kendo.jQuery;var yZ=kendo.dataviz,wZ=yZ.ui.Chart,kZ=bZ.extend,xZ=wZ.extend({init:function(e,t){var n=t;n instanceof kendo.data.ObservableArray&&(n={seriesDefaults:{data:n}}),wZ.fn.init.call(this,e,Aj.normalizeOptions(n))},_createChart:function(e,t){this._instance=new Aj(this.element[0],e,t,{observer:new rR(this,{showTooltip:"_showTooltip",hideTooltip:"_hideTooltip",legendItemClick:"_onLegendItemClick",render:"_onRender",init:"_onInit",drilldown:"_onDrilldown"}),sender:this,rtl:this._isRtl()})},_createTooltip:function(){return new CZ(this.element,kZ({},this.options.tooltip,{rtl:this._isRtl()}))},options:{name:"Sparkline",chartArea:{margin:2},axisDefaults:{visible:!1,majorGridLines:{visible:!1},valueAxis:{narrowRange:!0}},seriesDefaults:{type:"line",area:{line:{width:.5}},bar:{stack:!0},padding:2,width:.5,overlay:{gradient:null},highlight:{visible:!1},border:{width:0},markers:{size:2,visible:!1}},tooltip:{visible:!0,shared:!0},categoryAxis:{crosshair:{visible:!0,tooltip:{visible:!1}}},legend:{visible:!1},transitions:!1,pointWidth:5,panes:[{clip:!1}]}});yZ.ui.plugin(xZ);var CZ=yZ.Tooltip.extend({options:{animation:{duration:0}},_hideElement:function(){this.element&&this.element.hide().remove()}});yZ.Sparkline=xZ,yZ.SparklineTooltip=CZ;kendo;!function(){var e=window.kendo,t=e.deepExtend;var n=Date.now;n||(n=function(){return(new Date).getTime()}),t(e,{util:{now:n,renderPos:function(t){var n=[];if(t)for(var i=e.toHyphens(t).split("-"),r=0;r<i.length;r++)n.push("k-pos-"+i[r]);return n.join(" ")},renderSize:function(e){return"string"!=typeof e&&(e+="px"),e},sqr:function(e){return e*e},romanToArabic:function(e){e=e.toLowerCase();for(var t={i:1,v:5,x:10,l:50,c:100,d:500,m:1e3},n=0,i=0,r=0;r<e.length;++r){var o=t[e.charAt(r)];if(!o)return null;n+=o,o>i&&(n-=2*i),i=o}return n},arabicToRoman:function(e){for(var t={1:"i",10:"x",100:"c",2:"ii",20:"xx",200:"cc",3:"iii",30:"xxx",300:"ccc",4:"iv",40:"xl",400:"cd",5:"v",50:"l",500:"d",6:"vi",60:"lx",600:"dc",7:"vii",70:"lxx",700:"dcc",8:"viii",80:"lxxx",800:"dccc",9:"ix",90:"xc",900:"cm",1e3:"m"},n=[1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],i="";e>0;)e<n[0]?n.shift():(i+=t[n[0]],e-=n[0]);return i},memoize:function(e){var t=Object.create(null);return function(){for(var n="",i=arguments.length;--i>=0;)n+=":"+arguments[i];return n in t?t[n]:t[n]=e.apply(this,arguments)}},isUnicodeLetter:function(e){return i.test(e)},withExit:function(e,t){try{return e.call(t,(function(e){throw new n(e)}))}catch(e){if(e instanceof n)return e.value;throw e}function n(e){this.value=e}}}});var i=new RegExp("[\\u0041-\\u005A\\u0061-\\u007A\\u00AA\\u00B5\\u00BA\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377\\u037A-\\u037D\\u037F\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u048A-\\u052F\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05D0-\\u05EA\\u05F0-\\u05F2\\u0620-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA\\u07F4\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u08A0-\\u08B2\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0980\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u0A05-\\u0A0A\\u0A0F\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32\\u0A33\\u0A35\\u0A36\\u0A38\\u0A39\\u0A59-\\u0A5C\\u0A5E\\u0A72-\\u0A74\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8\\u0AAA-\\u0AB0\\u0AB2\\u0AB3\\u0AB5-\\u0AB9\\u0ABD\\u0AD0\\u0AE0\\u0AE1\\u0B05-\\u0B0C\\u0B0F\\u0B10\\u0B13-\\u0B28\\u0B2A-\\u0B30\\u0B32\\u0B33\\u0B35-\\u0B39\\u0B3D\\u0B5C\\u0B5D\\u0B5F-\\u0B61\\u0B71\\u0B83\\u0B85-\\u0B8A\\u0B8E-\\u0B90\\u0B92-\\u0B95\\u0B99\\u0B9A\\u0B9C\\u0B9E\\u0B9F\\u0BA3\\u0BA4\\u0BA8-\\u0BAA\\u0BAE-\\u0BB9\\u0BD0\\u0C05-\\u0C0C\\u0C0E-\\u0C10\\u0C12-\\u0C28\\u0C2A-\\u0C39\\u0C3D\\u0C58\\u0C59\\u0C60\\u0C61\\u0C85-\\u0C8C\\u0C8E-\\u0C90\\u0C92-\\u0CA8\\u0CAA-\\u0CB3\\u0CB5-\\u0CB9\\u0CBD\\u0CDE\\u0CE0\\u0CE1\\u0CF1\\u0CF2\\u0D05-\\u0D0C\\u0D0E-\\u0D10\\u0D12-\\u0D3A\\u0D3D\\u0D4E\\u0D60\\u0D61\\u0D7A-\\u0D7F\\u0D85-\\u0D96\\u0D9A-\\u0DB1\\u0DB3-\\u0DBB\\u0DBD\\u0DC0-\\u0DC6\\u0E01-\\u0E30\\u0E32\\u0E33\\u0E40-\\u0E46\\u0E81\\u0E82\\u0E84\\u0E87\\u0E88\\u0E8A\\u0E8D\\u0E94-\\u0E97\\u0E99-\\u0E9F\\u0EA1-\\u0EA3\\u0EA5\\u0EA7\\u0EAA\\u0EAB\\u0EAD-\\u0EB0\\u0EB2\\u0EB3\\u0EBD\\u0EC0-\\u0EC4\\u0EC6\\u0EDC-\\u0EDF\\u0F00\\u0F40-\\u0F47\\u0F49-\\u0F6C\\u0F88-\\u0F8C\\u1000-\\u102A\\u103F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065\\u1066\\u106E-\\u1070\\u1075-\\u1081\\u108E\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F4\\u1401-\\u166C\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u16EE-\\u16F8\\u1700-\\u170C\\u170E-\\u1711\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7\\u17DC\\u1820-\\u1877\\u1880-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191E\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19C1-\\u19C7\\u1A00-\\u1A16\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4B\\u1B83-\\u1BA0\\u1BAE\\u1BAF\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1CE9-\\u1CEC\\u1CEE-\\u1CF1\\u1CF5\\u1CF6\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2160-\\u2188\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2\\u2CF3\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303C\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312D\\u3131-\\u318E\\u31A0-\\u31BA\\u31F0-\\u31FF\\u3400-\\u4DB5\\u4E00-\\u9FCC\\uA000-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B\\uA640-\\uA66E\\uA67F-\\uA69D\\uA6A0-\\uA6EF\\uA717-\\uA71F\\uA722-\\uA788\\uA78B-\\uA78E\\uA790-\\uA7AD\\uA7B0\\uA7B1\\uA7F7-\\uA801\\uA803-\\uA805\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB\\uA90A-\\uA925\\uA930-\\uA946\\uA960-\\uA97C\\uA984-\\uA9B2\\uA9CF\\uA9E0-\\uA9E4\\uA9E6-\\uA9EF\\uA9FA-\\uA9FE\\uAA00-\\uAA28\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAA60-\\uAA76\\uAA7A\\uAA7E-\\uAAAF\\uAAB1\\uAAB5\\uAAB6\\uAAB9-\\uAABD\\uAAC0\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEA\\uAAF2-\\uAAF4\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\\uAB16\\uAB20-\\uAB26\\uAB28-\\uAB2E\\uAB30-\\uAB5A\\uAB5C-\\uAB5F\\uAB64\\uAB65\\uABC0-\\uABE2\\uAC00-\\uD7A3\\uD7B0-\\uD7C6\\uD7CB-\\uD7FB\\uF900-\\uFA6D\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D\\uFB1F-\\uFB28\\uFB2A-\\uFB36\\uFB38-\\uFB3C\\uFB3E\\uFB40\\uFB41\\uFB43\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE70-\\uFE74\\uFE76-\\uFEFC\\uFF21-\\uFF3A\\uFF41-\\uFF5A\\uFF66-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC]")}(),function(){var e=Math,t=e.abs,n=e.atan,i=e.atan2,r=e.cos,o=e.max,a=e.min,s=e.sin,l=e.tan,c=window.kendo,d=c.Class,u=c.dataviz,h=c.deepExtend,p=c.drawing.util,f=p.defined,m=p.deg,g=p.rad,v=p.round,_=p.valueOrDefault,b=c.util.sqr,y=d.extend({init:function(e,t){1===arguments.length?(this.lat=e[0],this.lng=e[1]):(this.lat=e,this.lng=t)},DISTANCE_ITERATIONS:100,DISTANCE_CONVERGENCE:1e-12,DISTANCE_PRECISION:2,FORMAT:"{0:N6},{1:N6}",toArray:function(){return[this.lat,this.lng]},equals:function(e){return e&&e.lat===this.lat&&e.lng===this.lng},clone:function(){return new y(this.lat,this.lng)},round:function(e){return this.lng=v(this.lng,e),this.lat=v(this.lat,e),this},wrap:function(){return this.lng=this.lng%180,this.lat=this.lat%90,this},distanceTo:function(e,t){return this.greatCircleTo(e,t).distance},destination:function(t,n,o){n=g(n),o=o||u.map.datums.WGS84;var a=g(this.lat),l=g(this.lng),d=t/c.dataviz.map.datums.WGS84.a,h=e.asin(s(a)*r(d)+r(a)*s(d)*r(n)),p=l+i(s(n)*s(d)*r(a),r(d)-s(a)*s(h));return new y(m(h),m(p))},greatCircleTo:function(o,a){if(o=y.create(o),a=a||u.map.datums.WGS84,!o||this.clone().round(8).equals(o.clone().round(8)))return{distance:0,azimuthFrom:0,azimuthTo:0};for(var c,d,h,p,f,_,w,k,x=a.a,C=a.b,S=a.f,T=g(o.lng-this.lng),D=n((1-S)*l(g(this.lat))),A=s(D),M=r(D),E=n((1-S)*l(g(o.lat))),I=s(E),z=r(E),P=T,H=this.DISTANCE_ITERATIONS,F=!1;!F&&H-- >0;){d=s(P),h=r(P),p=e.sqrt(b(z*d)+b(M*I-A*z*h)),k=i(p,_=A*I+M*z*h);var R=M*z*d/p;w=0,0!==(f=1-b(R))&&(w=_-2*A*I/f),c=P;var L=S/16*f*(4+S*(4-3*f));P=T+(1-L)*S*R*(k+L*p*(w+L*_*(2*b(w)-1))),F=t(P-c)<=this.DISTANCE_CONVERGENCE}var B=f*(b(x)-b(C))/b(C),O=1+B/16384*(4096+B*(B*(320-175*B)-768)),V=B/1024*(256+B*(B*(74-47*B)-128)),N=V*p*(w+V/4*(_*(2*b(w)-1)-V/6*w*(4*b(p)-3)*(4*b(w)-3))),$=i(z*d,M*I-A*z*h),U=i(M*d,-A*z+M*I*h);return{distance:v(C*O*(k-N),this.DISTANCE_PRECISION),azimuthFrom:m($),azimuthTo:m(U)}}});y.fn.toString=function(){return c.format(this.FORMAT,this.lat,this.lng)},y.fromLngLat=function(e){return new y(e[1],e[0])},y.fromLatLng=function(e){return new y(e[0],e[1])},y.create=function(e,t){if(f(e))return e instanceof y?e.clone():1===arguments.length&&2===e.length?y.fromLatLng(e):new y(e,t)};var w=d.extend({init:function(e,t){e=y.create(e),t=y.create(t),e.lng+180>t.lng+180&&e.lat+90<t.lat+90?(this.se=e,this.nw=t):(this.se=t,this.nw=e)},contains:function(e){var t=this.nw,n=this.se,i=_(e.lng,e[1]),r=_(e.lat,e[0]);return e&&i+180>=t.lng+180&&i+180<=n.lng+180&&r+90>=n.lat+90&&r+90<=t.lat+90},center:function(){var e=this.nw,t=this.se,n=e.lng+(t.lng-e.lng)/2,i=e.lat+(t.lat-e.lat)/2;return new y(i,n)},containsAny:function(e){for(var t=!1,n=0;n<e.length;n++)t=t||this.contains(e[n]);return t},include:function(e){var t=this.nw,n=this.se,i=_(e.lng,e[1]),r=_(e.lat,e[0]);t.lng=a(t.lng,i),t.lat=o(t.lat,r),n.lng=o(n.lng,i),n.lat=a(n.lat,r)},includeAll:function(e){for(var t=0;t<e.length;t++)this.include(e[t])},edges:function(){var e=this.nw,t=this.se;return{nw:this.nw,ne:new y(e.lat,t.lng),se:this.se,sw:new y(t.lat,e.lng)}},toArray:function(){var e=this.nw,t=this.se;return[e,new y(e.lat,t.lng),t,new y(t.lat,e.lng)]},overlaps:function(e){return this.containsAny(e.toArray())||e.containsAny(this.toArray())}});w.World=new w([90,-180],[-90,180]),w.create=function(e,t){return e instanceof w?e:e&&t?new w(e,t):e&&4===e.length&&!t?new w([e[0],e[1]],[e[2],e[3]]):void 0},h(u,{map:{Extent:w,Location:y}})}(window.kendo.jQuery),function(){var e=window.kendo,t=e.ui.Widget,n=e.template,i=e.drawing.util,r=i.valueOrDefault,o=i.defined,a=t.extend({init:function(e,n){t.fn.init.call(this,e,n),this._initOptions(n),this.items=[],this.element.addClass("k-attribution")},options:{name:"Attribution",separator:"&nbsp;|&nbsp;",itemTemplate:({text:e})=>e},filter:function(e,t){this._extent=e,this._zoom=t,this._render()},add:function(e){o(e)&&("string"==typeof e&&(e={text:e}),this.items.push(e),this._render())},remove:function(e){for(var t=[],n=0;n<this.items.length;n++){var i=this.items[n];i.text!==e&&t.push(i)}this.items=t,this._render()},clear:function(){this.items=[],this.element.empty()},_render:function(){for(var e=[],t=n(this.options.itemTemplate),i=0;i<this.items.length;i++){var r=this.items[i],o=this._itemText(r);""!==o&&e.push(t({text:o}))}e.length>0?this.element.empty().append(e.join(this.options.separator)).show():this.element.hide()},_itemText:function(e){var t="",n=this._inZoomLevel(e.minZoom,e.maxZoom),i=this._inArea(e.extent);return n&&i&&(t+=e.text),t},_inZoomLevel:function(e,t){return e=r(e,-Number.MAX_VALUE),t=r(t,Number.MAX_VALUE),this._zoom>e&&this._zoom<t},_inArea:function(e){var t=!0;return e&&(t=e.contains(this._extent)),t}});e.dataviz.ui.plugin(a)}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.ui.Widget,i=t.keys;function r(e){const n={n:"up",s:"down",e:"right",w:"left"};return`<button class="k-button k-rounded-full k-button-flat k-button-flat-base k-icon-button k-navigator-${e}" aria-label="move ${n[e]}">`+t.ui.icon({icon:`caret-alt-${n[e]}`,iconClass:"k-button-icon"})+"</button>"}var o=r("n")+r("e")+r("s")+r("w"),a=n.extend({init:function(e,i){n.fn.init.call(this,e,i),this._initOptions(i),this.element.addClass("k-navigator").append(o).on("click.kendoNavigator",".k-button",this._click.bind(this));var r=this.element.parent().closest("["+t.attr("role")+"]");this._keyroot=r.length>0?r:this.element,this._tabindex(this._keyroot),this._keydown=this._keydown.bind(this),this._keyroot.on("keydown",this._keydown)},options:{name:"Navigator",panStep:1},events:["pan"],dispose:function(){this._keyroot.off("keydown",this._keydown)},_pan:function(e,t){var n=this.options.panStep;this.trigger("pan",{x:e*n,y:t*n})},_click:function(t){var n=0,i=0,r=e(t.currentTarget);r.is(".k-navigator-n")?i=1:r.is(".k-navigator-s")?i=-1:r.is(".k-navigator-e")?n=1:r.is(".k-navigator-w")&&(n=-1),this._pan(n,i),t.preventDefault()},_keydown:function(e){switch(e.which){case i.UP:this._pan(0,1),e.preventDefault();break;case i.DOWN:this._pan(0,-1),e.preventDefault();break;case i.RIGHT:this._pan(1,0),e.preventDefault();break;case i.LEFT:this._pan(-1,0),e.preventDefault()}}});t.dataviz.ui.plugin(a)}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.ui.Widget,i=t.keys;function r(e,n){return`<button class="k-button k-button-md k-rounded-md k-button-solid k-button-solid-base k-icon-button k-zoom-${e}" title="zoom-${e}" aria-label="zoom-${e}">${t.ui.icon({icon:n,iconClass:"k-button-icon"})}</button>`}var o=r("in","plus")+r("out","minus"),a=n.extend({init:function(e,i){n.fn.init.call(this,e,i),this._initOptions(i),this.element.addClass("k-zoom-control k-button-group k-group-horizontal k-button-group-solid").append(o).on("click.kendoZoomControl",".k-button",this._click.bind(this));var r=this.element.parent().closest("["+t.attr("role")+"]");this._keyroot=r.length>0?r:this.element,this._tabindex(this._keyroot),this._keydown=this._keydown.bind(this),this._keyroot.on("keydown",this._keydown)},options:{name:"ZoomControl",zoomStep:1},events:["change"],_change:function(e){var t=this.options.zoomStep;this.trigger("change",{delta:e*t})},_click:function(t){var n=1;e(t.currentTarget).is(".k-zoom-out")&&(n=-1),this._change(n),t.preventDefault()},_keydown:function(e){switch(e.which){case i.NUMPAD_PLUS:case 187:case 61:this._change(1);break;case i.NUMPAD_MINUS:case 189:case 173:this._change(-1)}}});t.dataviz.ui.plugin(a)}(window.kendo.jQuery),function(){var e=Math,t=e.atan,n=e.exp,i=e.pow,r=e.sin,o=e.log,a=e.tan,s=window.kendo,l=s.Class,c=s.dataviz,d=s.deepExtend,u=s.geometry,h=u.Point,p=c.map.Location,f=s.drawing.util,m=f.rad,g=f.deg,v=f.limitValue,_=e.PI,b=_/2,y=_/4,w=_/180,k={a:6378137,b:6356752.314245179,f:.0033528106647474805,e:.08181919084262149},x=l.extend({init:function(e){this._initOptions(e)},MAX_LNG:180,MAX_LAT:85.0840590501,INVERSE_ITERATIONS:15,INVERSE_CONVERGENCE:1e-12,options:{centralMeridian:0,datum:k},forward:function(e,t){var n=this,i=n.options,r=i.datum.a,o=i.centralMeridian,a=v(e.lat,-n.MAX_LAT,n.MAX_LAT),s=t?v(e.lng,-n.MAX_LNG,n.MAX_LNG):e.lng,l=m(s-o)*r,c=n._projectLat(a);return new h(l,c)},_projectLat:function(e){var t=this.options.datum,n=t.e,s=t.a,l=m(e),c=a(y+l/2),d=n*r(l),u=i((1-d)/(1+d),n/2);return s*o(c*u)},inverse:function(e,t){var n=this,i=n.options,r=i.datum.a,o=i.centralMeridian,a=e.x/(w*r)+o,s=v(n._inverseY(e.y),-n.MAX_LAT,n.MAX_LAT);return t&&(a=v(a,-n.MAX_LNG,n.MAX_LNG)),new p(s,a)},_inverseY:function(o){var a,s=this,l=s.options.datum,c=l.a,d=l.e,u=d/2,h=n(-o/c),p=b-2*t(h);for(a=0;a<=s.INVERSE_ITERATIONS;a++){var f=d*r(p),m=i((1-f)/(1+f),u),v=b-2*t(h*m)-p;if(p+=v,e.abs(v)<=s.INVERSE_CONVERGENCE)break}return g(p)}}),C=x.extend({MAX_LAT:85.0511287798,_projectLat:function(e){var t=this.options.datum.a,n=m(e),i=a(y+n/2);return t*o(i)},_inverseY:function(e){var i=this.options.datum.a,r=n(-e/i);return g(b-2*t(r))}}),S=l.extend({forward:function(e){return new h(e.lng,e.lat)},inverse:function(e){return new p(e.y,e.x)}}),T=l.extend({init:function(){var e=this._proj=new C,t=this.c=2*_*e.options.datum.a;this._tm=u.transform().translate(.5,.5).scale(1/t,-1/t),this._itm=u.transform().scale(t,-t).translate(-.5,-.5)},toPoint:function(e,t,n){return this._proj.forward(e,n).transform(this._tm).scale(t||1)},toLocation:function(e,t,n){return e=e.clone().scale(1/(t||1)).transform(this._itm),this._proj.inverse(e,n)}}),D=l.extend({init:function(){this._proj=new x},toPoint:function(e){return this._proj.forward(e)},toLocation:function(e){return this._proj.inverse(e)}}),A=l.extend({init:function(){this._proj=new S},toPoint:function(e){return this._proj.forward(e)},toLocation:function(e){return this._proj.inverse(e)}});d(c,{map:{crs:{EPSG3395:D,EPSG3857:T,EPSG4326:A},datums:{WGS84:k},projections:{Equirectangular:S,Mercator:x,SphericalMercator:C}}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.Class,i=t.dataviz,r=t.deepExtend,o=i.map.Extent,a=t.drawing.util.defined,s=n.extend({init:function(t,n){this._initOptions(n),this.map=t,this.element=e("<div class='k-layer'></div>").css({zIndex:this.options.zIndex,opacity:this.options.opacity}).appendTo(t.scrollElement),this._beforeReset=this._beforeReset.bind(this),this._reset=this._reset.bind(this),this._resize=this._resize.bind(this),this._panEnd=this._panEnd.bind(this),this._activate(),this._updateAttribution()},destroy:function(){this._deactivate()},show:function(){this.reset(),this._activate(),this._applyExtent(!0)},hide:function(){this._deactivate(),this._setVisibility(!1)},reset:function(){this._beforeReset(),this._reset()},_reset:function(){this._applyExtent()},_beforeReset:e.noop,_resize:e.noop,_panEnd:function(){this._applyExtent()},_applyExtent:function(){var e=this.options,t=this.map.zoom(),n=!a(e.minZoom)||t>=e.minZoom,i=!a(e.maxZoom)||t<=e.maxZoom,r=o.create(e.extent),s=!r||r.overlaps(this.map.extent());this._setVisibility(n&&i&&s)},_setVisibility:function(e){this.element.css("display",e?"":"none")},_activate:function(){var e=this.map;this._deactivate(),e.bind("beforeReset",this._beforeReset),e.bind("reset",this._reset),e.bind("resize",this._resize),e.bind("panEnd",this._panEnd)},_deactivate:function(){var e=this.map;e.unbind("beforeReset",this._beforeReset),e.unbind("reset",this._reset),e.unbind("resize",this._resize),e.unbind("panEnd",this._panEnd)},_updateAttribution:function(){var e=this.map.attribution;e&&e.add(this.options.attribution)}});r(i,{map:{layers:{Layer:s}}})}(window.kendo.jQuery),function(){var e=window.kendo,t=e.Class,n=e.data.DataSource,i=e.dataviz,r=e.deepExtend,o=e.geometry,a=e.drawing,s=a.Group,l=a.util.last,c=a.util.defined,d=i.map,u=d.Location,h=d.layers.Layer,p=h.extend({init:function(t,n){this._pan=this._pan.bind(this),h.fn.init.call(this,t,n),this.surface=a.Surface.create(this.element,{width:t.scrollElement.width(),height:t.scrollElement.height()}),this._initRoot(),this.movable=new e.ui.Movable(this.surface.element),this._markers=[],this._click=this._handler("shapeClick"),this.surface.bind("click",this._click),this._mouseenter=this._handler("shapeMouseEnter"),this.surface.bind("mouseenter",this._mouseenter),this._mouseleave=this._handler("shapeMouseLeave"),this.surface.bind("mouseleave",this._mouseleave),this._initDataSource()},options:{autoBind:!0},destroy:function(){h.fn.destroy.call(this),this.surface.destroy(),this.dataSource.unbind("change",this._dataChange)},setDataSource:function(t){this.dataSource&&this.dataSource.unbind("change",this._dataChange),this.dataSource=e.data.DataSource.create(t),this.dataSource.bind("change",this._dataChange),this.options.autoBind&&this.dataSource.fetch()},_reset:function(){h.fn._reset.call(this),this._translateSurface(),this._data&&this._load(this._data)},_initRoot:function(){this._root=new s,this.surface.draw(this._root)},_beforeReset:function(){this.surface.clear(),this._initRoot()},_resize:function(){this.surface.size(this.map.size())},_initDataSource:function(){var e=this.options.dataSource;this._dataChange=this._dataChange.bind(this),this.dataSource=n.create(e).bind("change",this._dataChange),e&&this.options.autoBind&&this.dataSource.fetch()},_dataChange:function(e){this._data=e.sender.view(),this._load(this._data)},_load:function(e){this._clearMarkers(),this._loader||(this._loader=new f(this.map,this.options.style,this));for(var t=new s,n=0;n<e.length;n++){var i=this._loader.parse(e[n]);i&&t.append(i)}this._root.clear(),this._root.append(t)},shapeCreated:function(e){var t=!1;if(e instanceof a.Circle&&(t=c(this._createMarker(e))),!t){var n={layer:this,shape:e};t=this.map.trigger("shapeCreated",n)}return t},featureCreated:function(e){e.layer=this,this.map.trigger("shapeFeatureCreated",e)},_createMarker:function(e){var t=this.map.markers.bind({location:e.location},e.dataItem);return t&&this._markers.push(t),t},_clearMarkers:function(){for(var e=0;e<this._markers.length;e++)this.map.markers.remove(this._markers[e]);this._markers=[]},_pan:function(){this._panning||(this._panning=!0,this.surface.suspendTracking())},_panEnd:function(e){h.fn._panEnd.call(this,e),this._translateSurface(),this.surface.resumeTracking(),this._panning=!1},_translateSurface:function(){var e=this.map,t=e.locationToView(e.extent().nw);this.surface.translate&&(this.surface.translate(t),this.movable.moveTo({x:t.x,y:t.y}))},_handler:function(e){var t=this;return function(n){if(n.element){var i={layer:t,shape:n.element,originalEvent:n.originalEvent};t.map.trigger(e,i)}}},_activate:function(){h.fn._activate.call(this),this.map.bind("pan",this._pan)},_deactivate:function(){h.fn._deactivate.call(this),this.map.unbind("pan",this._pan)}}),f=t.extend({init:function(e,t,n){this.observer=n,this.locator=e,this.style=t},parse:function(e){var t=new s,n=!0;return"Feature"===e.type?(n=!1,this._loadGeometryTo(t,e.geometry,e),this._featureCreated(t,e)):this._loadGeometryTo(t,e,e),n&&t.children.length<2&&(t=t.children[0]),t},_shapeCreated:function(e){var t=!1;return this.observer&&this.observer.shapeCreated&&(t=this.observer.shapeCreated(e)),t},_featureCreated:function(e,t){this.observer&&this.observer.featureCreated&&this.observer.featureCreated({group:e,dataItem:t,properties:t.properties})},_loadGeometryTo:function(e,t,n){var i,r,o=t.coordinates;switch(t.type){case"LineString":r=this._loadPolygon(e,[o],n),this._setLineFill(r);break;case"MultiLineString":for(i=0;i<o.length;i++)r=this._loadPolygon(e,[o[i]],n),this._setLineFill(r);break;case"Polygon":this._loadPolygon(e,o,n);break;case"MultiPolygon":for(i=0;i<o.length;i++)this._loadPolygon(e,o[i],n);break;case"Point":this._loadPoint(e,o,n);break;case"MultiPoint":for(i=0;i<o.length;i++)this._loadPoint(e,o[i],n)}},_setLineFill:function(e){var t=e.segments;(t.length<4||!t[0].anchor().equals(l(t).anchor()))&&(e.options.fill=null)},_loadShape:function(e,t){return this._shapeCreated(t)||e.append(t),t},_loadPolygon:function(e,t,n){var i=this._buildPolygon(t);return i.dataItem=n,this._loadShape(e,i)},_buildPolygon:function(e){for(var t=new(e.length>1?a.MultiPath:a.Path)(this.style),n=0;n<e.length;n++)for(var i=0;i<e[n].length;i++){var r=this.locator.locationToView(u.fromLngLat(e[n][i]));0===i?t.moveTo(r.x,r.y):t.lineTo(r.x,r.y)}return t},_loadPoint:function(e,t,n){var i=u.fromLngLat(t),r=this.locator.locationToView(i),s=new o.Circle(r,10),l=new a.Circle(s,this.style);return l.dataItem=n,l.location=i,this._loadShape(e,l)}});r(e.data,{schemas:{geojson:{type:"json",data:function(e){return"FeatureCollection"===e.type?e.features:"GeometryCollection"===e.type?e.geometries:e}}},transports:{geojson:{read:{dataType:"json"}}}}),r(i,{map:{layers:{shape:p,ShapeLayer:p},GeoJSONLoader:f}})}(window.kendo.jQuery),function(){var e=window.kendo,t=e.getter,n=e.dataviz,i=e.deepExtend,r=e.geometry,o=e.drawing,a=o.util.defined,s=n.map,l=s.Location,c=s.layers.ShapeLayer.extend({options:{autoBind:!0,locationField:"location",valueField:"value",minSize:0,maxSize:100,scale:"sqrt",symbol:"circle"},_load:function(e){if(this.surface.clear(),0!==e.length){var n=this.options,i=t(n.valueField);(e=e.slice(0)).sort((function(e,t){return i(t)-i(e)}));for(var r,o=this._scaleType(),s=0;s<e.length;s++){var c=e[s],d=t(n.locationField)(c),u=t(n.valueField)(c);if(a(d)&&a(u)){r||(r=new o([0,u],[n.minSize,n.maxSize])),d=l.create(d);var h=this.map.locationToView(d),p=r.map(u),f=this._createSymbol({center:h,size:p,style:n.style,dataItem:c,location:d});f.dataItem=c,f.location=d,f.value=u,this._drawSymbol(f)}}}},_scaleType:function(){var t=this.options.scale;return e.isFunction(t)?t:n.map.scales[t]},_createSymbol:function(t){var i=this.options.symbol;return e.isFunction(i)||(i=n.map.symbols[i]),i(t)},_drawSymbol:function(e){var t={layer:this,shape:e};this.map.trigger("shapeCreated",t)||this.surface.draw(e)}}),d=e.Class.extend({init:function(e,t){this._domain=e,this._range=t;var n=Math.sqrt(e[1])-Math.sqrt(e[0]),i=t[1]-t[0];this._ratio=i/n},map:function(e){var t=(Math.sqrt(e)-Math.sqrt(this._domain[0]))*this._ratio;return this._range[0]+t}});i(n,{map:{layers:{bubble:c,BubbleLayer:c},scales:{sqrt:d},symbols:{circle:function(e){var t=new r.Circle(e.center,e.size/2);return new o.Circle(t,e.style)},square:function(e){var t=new o.Path(e.style),n=e.size/2,i=e.center;return t.moveTo(i.x-n,i.y-n).lineTo(i.x+n,i.y-n).lineTo(i.x+n,i.y+n).lineTo(i.x-n,i.y+n).close(),t}}}})}(window.kendo.jQuery),function(e){var t=Math,n=window.kendo,i=n.Class,r=n.template,o=n.dataviz,a=n.deepExtend,s=n.geometry.Point,l=o.map.layers.Layer,c=n.util,d=c.renderSize,u=n.drawing.util,h=u.round,p=u.limitValue,f=l.extend({init:function(e,t){l.fn.init.call(this,e,t),"string"==typeof this.options.subdomains&&(this.options.subdomains=this.options.subdomains.split(""));var n=this._viewType();this._view=new n(this.element,this.options)},destroy:function(){l.fn.destroy.call(this),this._view.destroy(),this._view=null},_beforeReset:function(){var e=this.map,t=e.locationToLayer(e.extent().nw).round();this._view.viewOrigin(t)},_reset:function(e){var t;t=e?e.tileTitle:"",l.fn._reset.call(this),this._updateView(),this._view.reset(t)},_viewType:function(){return m},_activate:function(){l.fn._activate.call(this),n.support.mobileOS||(this._pan||(this._pan=n.throttle(this._render.bind(this),100)),this.map.bind("pan",this._pan))},_deactivate:function(){l.fn._deactivate.call(this),this._pan&&this.map.unbind("pan",this._pan)},_updateView:function(){var e=this._view,t=this.map,n=t.extent(),i={nw:t.locationToLayer(n.nw).round(),se:t.locationToLayer(n.se).round()};e.center(t.locationToLayer(t.center())),e.extent(i),e.zoom(t.zoom())},_resize:function(){this._render()},_panEnd:function(e){l.fn._panEnd.call(this,e),this._render()},_render:function(){this._updateView(),this._view.render()}}),m=i.extend({init:function(e,t){this.element=e,this._initOptions(t),this.pool=new v},options:{tileSize:256,subdomains:["a","b","c"],urlTemplate:()=>""},center:function(e){this._center=e},extent:function(e){this._extent=e},viewOrigin:function(e){this._viewOrigin=e},zoom:function(e){this._zoom=e},pointToTileIndex:function(e){return new s(t.floor(e.x/this.options.tileSize),t.floor(e.y/this.options.tileSize))},tileCount:function(){var e=this.size(),n=this.pointToTileIndex(this._extent.nw),i=this._extent.nw,r=this.indexToPoint(n).translate(-i.x,-i.y);return{x:t.ceil((t.abs(r.x)+e.width)/this.options.tileSize),y:t.ceil((t.abs(r.y)+e.height)/this.options.tileSize)}},size:function(){var e=this._extent.nw,t=this._extent.se.clone().translate(-e.x,-e.y);return{width:t.x,height:t.y}},indexToPoint:function(e){var t=e.x,n=e.y;return new s(t*this.options.tileSize,n*this.options.tileSize)},subdomainText:function(){var e=this.options.subdomains;return e[this.subdomainIndex++%e.length]},destroy:function(){this.element.empty(),this.pool.empty()},reset:function(e){this._tileTitle=e,this.pool.reset(),this.subdomainIndex=0,this.render()},render:function(){var e,t,n,i=this.tileCount(),r=this.pointToTileIndex(this._extent.nw);for(t=0;t<i.x;t++)for(n=0;n<i.y;n++)(e=this.createTile({x:r.x+t,y:r.y+n})).visible||e.show()},createTile:function(e){var t=this.tileOptions(e),n=this.pool.get(this._center,t);return 0===n.element.parent().length&&this.element.append(n.element),n},tileOptions:function(e){var t=this.wrapIndex(e),n=this.indexToPoint(e),i=this._viewOrigin,r=n.clone().translate(-i.x,-i.y);return{index:t,currentIndex:e,point:n,offset:_(r),zoom:this._zoom,size:this.options.tileSize,subdomain:this.subdomainText(),urlTemplate:this.options.urlTemplate,errorUrlTemplate:this.options.errorUrlTemplate,tileTitle:this._tileTitle}},wrapIndex:function(e){var n=t.pow(2,this._zoom);return{x:this.wrapValue(e.x,n),y:p(e.y,0,n-1)}},wrapValue:function(e,n){var i=t.abs(e)%n;return e=e>=0?i:n-(0===i?n:i)}}),g=i.extend({init:function(e,t){this.id=e,this.visible=!0,this._initOptions(t),this.createElement(),this.show()},options:{urlTemplate:()=>"",errorUrlTemplate:()=>""},createElement:function(){this.element=e("<img alt='"+this.options.tileTitle+"' />").css({position:"absolute",display:"block",width:this.options.size,height:this.options.size}).on("error",function(e){this.errorUrl()?e.target.setAttribute("src",this.errorUrl()):e.target.removeAttribute("src")}.bind(this))},show:function(){var e=this.element[0];e.style.top=d(this.options.offset.y),e.style.left=d(this.options.offset.x);var t=this.url();t&&e.setAttribute("src",t),e.style.visibility="visible",this.visible=!0},hide:function(){this.element[0].style.visibility="hidden",this.visible=!1},url:function(){return r(this.options.urlTemplate)(this.urlOptions())},errorUrl:function(){return r(this.options.errorUrlTemplate)(this.urlOptions())},urlOptions:function(){var e=this.options;return{zoom:e.zoom,subdomain:e.subdomain,z:e.zoom,x:e.index.x,y:e.index.y,s:e.subdomain,quadkey:e.quadkey,q:e.quadkey,culture:e.culture,c:e.culture}},destroy:function(){this.element&&(this.element.remove(),this.element=null)}}),v=i.extend({init:function(){this._items=[]},options:{maxSize:100},get:function(e,t){return this._items.length>=this.options.maxSize&&this._remove(e),this._create(t)},empty:function(){for(var e=this._items,t=0;t<e.length;t++)e[t].destroy();this._items=[]},reset:function(){for(var e=this._items,t=0;t<e.length;t++)e[t].hide()},_create:function(e){for(var t,n=this._items,i=c.hashKey(e.point.toString()+e.offset.toString()+e.zoom+e.urlTemplate),r=0;r<n.length;r++)if(n[r].id===i){t=n[r];break}return t?t.show():(t=new g(i,e),this._items.push(t)),t},_remove:function(e){for(var t=this._items,n=-1,i=-1,r=0;r<t.length;r++){var o=t[r].options.point.distanceTo(e);o>n&&!t[r].visible&&(i=r,n=o)}-1!==i&&(t[i].destroy(),t.splice(i,1))}});function _(e){return new s(h(e.x),h(e.y))}a(o,{map:{layers:{tile:f,TileLayer:f,ImageTile:g,TilePool:v,TileView:m}}})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.dataviz,i=t.deepExtend,r=t.drawing.util.defined,o=n.map.Extent,a=n.map.Location,s=n.map.layers.TileLayer,l=n.map.layers.TileView,c=s.extend({init:function(e,t){this.options.baseUrl=this._scheme()+"://dev.virtualearth.net/REST/v1/Imagery/Metadata/",s.fn.init.call(this,e,t),this._onMetadata=this._onMetadata.bind(this),this._fetchMetadata()},options:{imagerySet:"road"},_fetchMetadata:function(){var t=this.options;if(!t.key)throw new Error("Bing tile layer: API key is required");e.ajax({url:t.baseUrl+t.imagerySet,data:{output:"json",include:"ImageryProviders",key:t.key,uriScheme:this._scheme()},type:"get",dataType:"jsonp",jsonp:"jsonp",success:this._onMetadata})},_scheme:function(e){return"https"===(e=e||window.location.protocol).replace(":","")?"https":"http"},_onMetadata:function(e){var t=this;if(e&&e.resourceSets.length){var n=t.resource=e.resourceSets[0].resources[0];i(t._view.options,{urlTemplate:({subdomain:e,quadkey:n,culture:i})=>t.resource.imageUrl.replace("{subdomain}",e).replace("{quadkey}",n).replace("{culture}",i),subdomains:n.imageUrlSubdomains});var o=t.options;r(o.minZoom)||(o.minZoom=n.zoomMin),r(o.maxZoom)||(o.maxZoom=n.zoomMax),t._addAttribution(),"none"!==t.element.css("display")&&t._reset()}},_viewType:function(){return d},_addAttribution:function(){var e=this.map.attribution;if(e){var t=this.resource.imageryProviders;if(t)for(var n=0;n<t.length;n++)for(var i=t[n],r=0;r<i.coverageAreas.length;r++){var s=i.coverageAreas[r];e.add({text:i.attribution,minZoom:s.zoomMin,maxZoom:s.zoomMax,extent:new o(new a(s.bbox[2],s.bbox[1]),new a(s.bbox[0],s.bbox[3]))})}}},imagerySet:function(e){if(!e)return this.options.imagerySet;this.options.imagerySet=e,this.map.attribution.clear(),this._fetchMetadata()}}),d=l.extend({options:{culture:"en-US"},tileOptions:function(e){var t=l.fn.tileOptions.call(this,e);return t.culture=this.options.culture,t.quadkey=this.tileQuadKey(this.wrapIndex(e)),t},tileQuadKey:function(e){var t,n,i,r="";for(i=this._zoom;i>0;i--)t=0,n=1<<i-1,e.x&n&&t++,e.y&n&&(t+=2),r+=t;return r}});i(n,{map:{layers:{bing:c,BingLayer:c,BingView:d}}})}(window.kendo.jQuery),function(e){var t=document,n=Math,i=e.inArray,r=window.kendo,o=r.Class,a=r.data.DataSource,s=r.ui.Tooltip,l=r.dataviz,c=r.deepExtend,d=l.map,u=d.Location,h=d.layers.Layer,p=h.extend({init:function(e,t){h.fn.init.call(this,e,t),this._markerClick=this._markerClick.bind(this),this.element.on("click",".k-marker",this._markerClick),this.items=[],this._initDataSource()},destroy:function(){h.fn.destroy.call(this),this.element.off("click",".k-marker",this._markerClick),this.dataSource.unbind("change",this._dataChange),this.clear()},options:{zIndex:1e3,autoBind:!0,dataSource:{},locationField:"location",titleField:"title"},add:function(e){if(!Array.isArray(e))return this._addOne(e);for(var t=0;t<e.length;t++)this._addOne(e[t])},remove:function(e){e.destroy();var t=i(e,this.items);t>-1&&this.items.splice(t,1)},clear:function(){for(var e=0;e<this.items.length;e++)this.items[e].destroy();this.items=[]},update:function(e){var t=e.location();if(t){e.showAt(this.map.locationToView(t));var n={marker:e,layer:this};this.map.trigger("markerActivate",n)}},_reset:function(){h.fn._reset.call(this);for(var e=this.items,t=0;t<e.length;t++)this.update(e[t])},bind:function(e,t){var n=d.Marker.create(e,this.options);n.dataItem=t;var i={marker:n,layer:this};if(!this.map.trigger("markerCreated",i))return this.add(n),n},setDataSource:function(e){this.dataSource&&this.dataSource.unbind("change",this._dataChange),this.dataSource=r.data.DataSource.create(e),this.dataSource.bind("change",this._dataChange),this.options.autoBind&&this.dataSource.fetch()},_addOne:function(e){var t=f.create(e,this.options);return t.addTo(this),t},_initDataSource:function(){var e=this.options.dataSource;this._dataChange=this._dataChange.bind(this),this.dataSource=a.create(e).bind("change",this._dataChange),e&&this.options.autoBind&&this.dataSource.fetch()},_dataChange:function(e){this._load(e.sender.view())},_load:function(e){this._data=e,this.clear();for(var t=r.getter(this.options.locationField),n=r.getter(this.options.titleField),i=0;i<e.length;i++){var o=e[i];this.bind({location:t(o),title:n(o)},o)}},_markerClick:function(t){var n={marker:e(t.currentTarget).data("kendoMarker"),layer:this};this.map.trigger("markerClick",n)}}),f=o.extend({init:function(e){this.options=e||{}},addTo:function(e){this.layer=e.markers||e,this.layer.items.push(this),this.layer.update(this)},location:function(e){return e?(this.options.location=u.create(e).toArray(),this.layer&&this.layer.update(this),this):u.create(this.options.location)},showAt:function(e){this.render(),this.element.css({left:n.round(e.x),top:n.round(e.y)}),this.tooltip&&this.tooltip.popup&&this.tooltip.popup._position()},hide:function(){this.element&&(this.element.remove(),this.element=null),this.tooltip&&(this.tooltip.destroy(),this.tooltip=null)},destroy:function(){this.layer=null,this.hide()},render:function(){if(!this.element){let n=this.options,i=this.layer;this.element=e(t.createElement("span")).attr("title",n.title?r.htmlEncode(n.title):null).attr(n.attributes||{}).data("kendoMarker",this).css("zIndex",n.zIndex),n.shape?"pinTarget"===n.shape?r.ui.icon(this.element,{icon:"map-marker-target",iconClass:"k-marker",size:"xxlarge"}):"pin"===n.shape?r.ui.icon(this.element,{icon:"map-marker",iconClass:"k-marker",size:"xxlarge"}):this.element.addClass("k-marker k-icon k-i-marker-"+r.toHyphens(n.shape)):r.ui.icon(this.element,{icon:"map-marker",iconClass:"k-marker",size:"xxlarge"}),i&&i.element.append(this.element),this.renderTooltip()}},renderTooltip:function(){var e=this,t=e.options.title,n=e.options.tooltip||{};if(n&&s){var i=n.template;if(i){var o=r.template(i);n.content=function(t){return t.location=e.location(),t.marker=e,o(t)}}(t||n.content||n.contentUrl)&&(this.tooltip=new s(this.element,n),this.tooltip.marker=this)}}});f.create=function(e,t){return e instanceof f?e:new f(c({},t,e))},c(l,{map:{layers:{marker:p,MarkerLayer:p},Marker:f}})}(window.kendo.jQuery),function(e){var t=document,n=Math,i=n.min,r=n.pow,o=window.kendo,a=o.ui.Widget,s=o.deepExtend,l=o.dataviz,c=l.ui,d=o.geometry,u=d.Point,h=l.map,p=h.Extent,f=h.Location,m=h.crs.EPSG3857,g=o.util.renderPos,v=o.drawing.util,_=v.defined,b=v.limitValue,y=v.valueOrDefault,w=a.extend({init:function(e,n){o.destroy(e),a.fn.init.call(this,e),this._initOptions(n),this.bind(this.events,n),this.crs=new m,this.element.addClass("k-"+this.options.name.toLowerCase()).css("position","relative").empty().append(t.createElement("div")),this._viewOrigin=this._getOrigin(),this._initScroller(),this._initMarkers(),this._initControls(),this._initLayers(),this._reset(),this.scrollElement.parent().removeClass("km-widget"),this._mousewheel=this._mousewheel.bind(this),this.element.on("DOMMouseScroll mousewheel",this._mousewheel)},options:{name:"Map",controls:{attribution:!0,navigator:{panStep:100},zoom:!0},layers:[],layerDefaults:{shape:{style:{fill:{color:"#fff"},stroke:{color:"#aaa",width:.5}}},bubble:{style:{fill:{color:"#fff",opacity:.5},stroke:{color:"#aaa",width:.5}}},marker:{shape:"pinTarget",tooltip:{position:"top"}}},center:[0,0],zoom:3,minSize:256,minZoom:1,maxZoom:19,markers:[],markerDefaults:{shape:"pinTarget",tooltip:{position:"top"}},wraparound:!0,messages:{tileTitle:"Map tile"}},events:["beforeReset","click","markerActivate","markerClick","markerCreated","pan","panEnd","reset","shapeClick","shapeCreated","shapeFeatureCreated","shapeMouseEnter","shapeMouseLeave","zoomEnd","zoomStart"],destroy:function(){this.scroller.destroy(),this.navigator&&this.navigator.destroy(),this.attribution&&this.attribution.destroy(),this.zoomControl&&this.zoomControl.destroy(),this.markers.destroy();for(var e=0;e<this.layers.length;e++)this.layers[e].destroy();a.fn.destroy.call(this)},zoom:function(e){var t=this.options;return _(e)?(e=n.round(b(e,t.minZoom,t.maxZoom)),t.zoom!==e&&(t.zoom=e,this._reset()),this):t.zoom},center:function(e){return e?(this.options.center=f.create(e).toArray(),this._reset(),this):f.create(this.options.center)},extent:function(e){return e?(this._setExtent(e),this):this._getExtent()},setOptions:function(e){a.fn.setOptions.call(this,e),this._reset()},locationToLayer:function(e,t){var n=!this.options.wraparound;return e=f.create(e),this.crs.toPoint(e,this._layerSize(t),n)},layerToLocation:function(e,t){var n=!this.options.wraparound;return e=u.create(e),this.crs.toLocation(e,this._layerSize(t),n)},locationToView:function(e){e=f.create(e);var t=this.locationToLayer(this._viewOrigin);return this.locationToLayer(e).translateWith(t.scale(-1))},viewToLocation:function(e,t){var n=this.locationToLayer(this._getOrigin(),t);return e=(e=u.create(e)).clone().translateWith(n),this.layerToLocation(e,t)},eventOffset:function(e){var t,n,i,r=this.element.offset();if(e.x||e.y){var o="location";n=e.x[o]-r.left,i=e.y[o]-r.top,t=new d.Point(n,i)}else{var a=e.originalEvent||e;n=y(a.pageX,a.clientX)-r.left,i=y(a.pageY,a.clientY)-r.top,t=new d.Point(n,i)}return t},eventToView:function(e){var t=this.eventOffset(e);return this.locationToView(this.viewToLocation(t))},eventToLayer:function(e){return this.locationToLayer(this.eventToLocation(e))},eventToLocation:function(e){var t=this.eventOffset(e);return this.viewToLocation(t)},viewSize:function(){var e=this.element,t=this._layerSize(),n=e.width();return this.options.wraparound||(n=i(t,n)),{width:n,height:i(t,e.height())}},exportVisual:function(){return this._reset(),!1},_setOrigin:function(e,t){var n,i=this.viewSize();return e=this._origin=f.create(e),(n=this.locationToLayer(e,t)).x+=i.width/2,n.y+=i.height/2,this.options.center=this.layerToLocation(n,t).toArray(),this},_getOrigin:function(e){var t,n=this.viewSize();return!e&&this._origin||((t=this.locationToLayer(this.center())).x-=n.width/2,t.y-=n.height/2,this._origin=this.layerToLocation(t)),this._origin},_setExtent:function(e){var t=p.create(e),i=t.se.clone();this.options.wraparound&&i.lng<0&&e.nw.lng>0&&(i.lng=180+(180+i.lng)),e=new p(t.nw,i),this.center(e.center());for(var r=this.element.width(),o=this.element.height(),a=this.options.maxZoom;a>=this.options.minZoom;a--){var s=this.locationToLayer(e.nw,a),l=this.locationToLayer(e.se,a),c=n.abs(l.x-s.x),d=n.abs(l.y-s.y);if(c<=r&&d<=o)break}this.zoom(a)},_getExtent:function(){var e=this._getOrigin(),t=this.locationToLayer(e),n=this.viewSize();t.x+=n.width,t.y+=n.height;var i=this.layerToLocation(t);return new p(e,i)},_zoomAround:function(e,t){this._setOrigin(this.layerToLocation(e,t),t),this.zoom(t)},_initControls:function(){var e=this.options.controls;c.Attribution&&e.attribution&&this._createAttribution(e.attribution),o.support.mobileOS||(c.Navigator&&e.navigator&&this._createNavigator(e.navigator),c.ZoomControl&&e.zoom&&this._createZoomControl(e.zoom))},_createControlElement:function(t,n){var i=t.position||n,r="."+g(i).replace(" ","."),o=e(".k-map-controls"+r,this.element);return 0===o.length&&(o=e("<div>").addClass("k-map-controls "+g(i)).appendTo(this.element)),e("<div>").appendTo(o)},_createAttribution:function(e){var t=this._createControlElement(e,"bottomRight");this.attribution=new c.Attribution(t,e)},_createNavigator:function(e){var t=this._createControlElement(e,"topLeft"),n=this.navigator=new c.Navigator(t,e);this._navigatorPan=this._navigatorPan.bind(this),n.bind("pan",this._navigatorPan),this._navigatorCenter=this._navigatorCenter.bind(this),n.bind("center",this._navigatorCenter)},_navigatorPan:function(e){var t=this,n=t.scroller,i=n.scrollLeft+e.x,r=n.scrollTop-e.y,o=this._virtualSize,a=this.element.height(),s=this.element.width();i=b(i,o.x.min,o.x.max-s),r=b(r,o.y.min,o.y.max-a),t.scroller.one("scroll",(function(e){t._scrollEnd(e)})),t.scroller.scrollTo(-i,-r)},_navigatorCenter:function(){this.center(this.options.center)},_createZoomControl:function(e){var t=this._createControlElement(e,"topLeft"),n=this.zoomControl=new c.ZoomControl(t,e);this._zoomControlChange=this._zoomControlChange.bind(this),n.bind("change",this._zoomControlChange)},_zoomControlChange:function(e){this.trigger("zoomStart",{originalEvent:e})||(this.zoom(this.zoom()+e.delta),this.trigger("zoomEnd",{originalEvent:e}))},_initScroller:function(){var e=o.support.mobileOS?.93:.9,t=!1!==this.options.zoomable,n=this.scroller=new o.mobile.ui.Scroller(this.element.children(0),{friction:e,velocityMultiplier:5,zoom:t,mousewheelScrolling:!1,supportDoubleTap:!0});n.bind("scroll",this._scroll.bind(this)),n.bind("scrollEnd",this._scrollEnd.bind(this)),n.userEvents.bind("gesturestart",this._scaleStart.bind(this)),n.userEvents.bind("gestureend",this._scale.bind(this)),n.userEvents.bind("doubleTap",this._doubleTap.bind(this)),n.userEvents.bind("tap",this._tap.bind(this)),this.scrollElement=n.scrollElement},_initLayers:function(){for(var e=this.options.layers,t=this.layers=[],n=0;n<e.length;n++){var i=e[n],r=i.type||"shape",o=this.options.layerDefaults[r],a=l.map.layers[r];t.push(new a(this,s({},o,i)))}},_initMarkers:function(){this.markers=new h.layers.MarkerLayer(this,this.options.markerDefaults),this.markers.add(this.options.markers)},_scroll:function(e){var t=this.locationToLayer(this._viewOrigin).round(),n=e.sender.movable,i=new d.Point(n.x,n.y).scale(-1).scale(1/n.scale);t.x+=i.x,t.y+=i.y,this._scrollOffset=i,this._setOrigin(this.layerToLocation(t)),this.trigger("pan",{originalEvent:e,origin:this._getOrigin(),center:this.center()})},_scrollEnd:function(e){this._scrollOffset&&this._panComplete()&&(this._scrollOffset=null,this._panEndTS=new Date,this.trigger("panEnd",{originalEvent:e,origin:this._getOrigin(),center:this.center()}))},_panComplete:function(){return new Date-(this._panEndTS||0)>50},_scaleStart:function(e){if(this.trigger("zoomStart",{originalEvent:e})){var t=e.touches[1];t&&t.cancel()}},_scale:function(e){var t=this.scroller.movable.scale,n=this._scaleToZoom(t),i=new d.Point(e.center.x,e.center.y),r=this.viewToLocation(i,n),o=this.locationToLayer(r,n).translate(-i.x,-i.y);this._zoomAround(o,n),this.trigger("zoomEnd",{originalEvent:e})},_scaleToZoom:function(e){var t=this._layerSize()*e/this.options.minSize,i=n.log(t)/n.log(2);return n.round(i)},_reset:function(){this.attribution&&this.attribution.filter(this.center(),this.zoom()),this._viewOrigin=this._getOrigin(!0),this._resetScroller(),this.trigger("beforeReset"),this.trigger("reset",{tileTitle:this.options.messages.tileTitle})},_resetScroller:function(){var e=this.scroller,t=e.dimensions.x,n=e.dimensions.y,i=this._layerSize(),o=this.extent().nw,a=this.locationToLayer(o).round();e.movable.round=!0,e.reset(),e.userEvents.cancel();var s=this.zoom();e.dimensions.forcedMinScale=r(2,this.options.minZoom-s),e.dimensions.maxScale=r(2,this.options.maxZoom-s);var l={min:-a.x,max:i-a.x},c={min:-a.y,max:i-a.y};if(this.options.wraparound&&(l.max=20*i,l.min=-l.max),!1===this.options.pannable){var d=this.viewSize();l.min=c.min=0,l.max=d.width,c.max=d.height}t.makeVirtual(),n.makeVirtual(),t.virtualSize(l.min,l.max),n.virtualSize(c.min,c.max),this._virtualSize={x:l,y:c}},_renderLayers:function(){var e=this.options.layers,t=this.layers=[];this.scrollWrap.empty();for(var n=0;n<e.length;n++){var i=e[n],r=i.type||"shape",o=this.options.layerDefaults[r],a=l.map.layers[r];t.push(new a(this,s({},o,i)))}},_layerSize:function(e){return e=y(e,this.options.zoom),this.options.minSize*r(2,e)},_tap:function(e){if(this._panComplete()){var t=this.eventOffset(e);this.trigger("click",{originalEvent:e,location:this.viewToLocation(t)})}},_doubleTap:function(e){if(!1!==this.options.zoomable&&!this.trigger("zoomStart",{originalEvent:e})){var t=this.zoom()+1,n=this.eventOffset(e),i=this.viewToLocation(n),r=this.locationToLayer(i,t).translate(-n.x,-n.y);this._zoomAround(r,t),this.trigger("zoomEnd",{originalEvent:e})}},_mousewheel:function(e){e.preventDefault();var t=l.mwDelta(e)>0?-1:1,n=this.options,i=this.zoom(),r=b(i+t,n.minZoom,n.maxZoom);if(!1!==n.zoomable&&r!==i&&!this.trigger("zoomStart",{originalEvent:e})){var o=this.eventOffset(e),a=this.viewToLocation(o),s=this.locationToLayer(a,r).translate(-o.x,-o.y);this._zoomAround(s,r),this.trigger("zoomEnd",{originalEvent:e})}}});l.ui.plugin(w)}(window.kendo.jQuery);kendo;!function(e){var t=window.kendo,n=t.dataviz.diagram={},i=t.deepExtend,r=Array.isArray,o={};i(o,{isNearZero:function(e){return Math.abs(e)<1e-6},isDefined:function(e){return void 0!==e},isUndefined:function(e){return null==e},isObject:function(e){return e===Object(e)},has:function(e,t){return Object.hasOwnProperty.call(e,t)},isString:function(e){return"[object String]"==Object.prototype.toString.call(e)},isBoolean:function(e){return"[object Boolean]"==Object.prototype.toString.call(e)},isType:function(e,t){return Object.prototype.toString.call(e)=="[object "+t+"]"},isNumber:function(e){return!isNaN(parseFloat(e))&&isFinite(e)},isEmpty:function(e){if(null===e)return!0;if(r(e)||o.isString(e))return 0===e.length;for(var t in e)if(o.has(e,t))return!1;return!0},simpleExtend:function(e,t){if(o.isObject(t))for(var n in t)e[n]=t[n]},initArray:function(e,t){for(var n=[],i=0;i<e;++i)n[i]=t;return n},serializePoints:function(e){for(var t=[],n=0;n<e.length;n++){var i=e[n];t.push(i.x+";"+i.y)}return t.join(";")},deserializePoints:function(e){var t=e.split(";"),i=[];if(t.length%2!=0)throw"Not an array of points.";for(var r=0;r<t.length;r+=2)i.push(new n.Point(parseInt(t[r],10),parseInt(t[r+1],10)));return i},randomInteger:function(e,t){return parseInt(Math.floor(Math.random()*t)+e,10)},DFT:function(e,t){if(t(e),e.childNodes)for(var n=0;n<e.childNodes.length;n++){var i=e.childNodes[n];this.DFT(i,t)}},getMatrixAngle:function(e){return null===e||0===e.d?0:180*Math.atan2(e.b,e.d)/Math.PI},getMatrixScaling:function(e){return[Math.sqrt(e.a*e.a+e.c*e.c),Math.sqrt(e.b*e.b+e.d*e.d)]}}),o.sign=function(e){return e?e<0?-1:1:0},o.findAngle=function(e,t){return 180*function(e,t){if(e==t)return 0;var n=t.x-e.x,i=e.y-t.y,r=Math.atan(n/i);return i>=0?n<0?r+2*Math.PI:r:r+Math.PI}(e,t)/Math.PI},o.forEach=function(e,t,n){for(var i=0;i<e.length;i++)t.call(n,e[i],i,e)},o.any=function(e,t){for(var n=0;n<e.length;++n)if(t(e[n]))return e[n];return null},o.remove=function(e,t){for(var n;-1!==(n=o.indexOf(e,t));)e.splice(n,1);return e},o.contains=function(e,t){return-1!==o.indexOf(e,t)},o.indexOf=function(t,n){return e.inArray(n,t)},o.fold=function(e,t,n,i){for(var r=arguments.length>2,o=0;o<e.length;o++){var a=e[o];r?n=t.call(i,n,a,o,e):(n=a,r=!0)}if(!r)throw"Reduce of empty array with no initial value";return n},o.find=function(e,t,n){var i;return o.any(e,(function(e,r,o){return!!t.call(n,e,r,o)&&(i=e,!0)})),i},o.first=function(e,t,n){return 0===e.length?null:o.isUndefined(t)?e[0]:o.find(e,t,n)},o.insert=function(e,t,n){return e.splice(n,0,t),e},o.all=function(e,t,n){for(var i,r=!0,o=0;o<e.length&&(i=e[o],r=r&&t.call(n,i,o,e));o++);return r},o.clear=function(e){e.splice(0,e.length)},o.bisort=function(e,t,n){if(o.isUndefined(e))throw"First array is not specified.";if(o.isUndefined(t))throw"Second array is not specified.";if(e.length!=t.length)throw"The two arrays should have equal length";var i,r=[];for(i=0;i<e.length;i++)r.push({x:e[i],y:t[i]});for(o.isUndefined(n)?r.sort((function(e,t){return e.x-t.x})):r.sort((function(e,t){return n(e.x,t.x)})),o.clear(e),o.clear(t),i=0;i<r.length;i++)e.push(r[i].x),t.push(r[i].y)},o.addRange=function(e,t){e.push.apply(e,t)};var a=function(e){return-Math.cos(e*Math.PI)/2+.5},s=t.Class.extend({init:function(){this.adapters=[],this.target=0,this.tick=0,this.interval=20,this.duration=800,this.lastTime=null,this.handlers=[];var e=this;this.transition=a,this.timerDelegate=function(){e.onTimerEvent()}},addAdapter:function(e){this.adapters.push(e)},onComplete:function(e){this.handlers.push(e)},removeHandler:function(t){this.handlers=e.grep(this.handlers,(function(e){return e!==t}))},trigger:function(){var e=this;this.handlers&&o.forEach(this.handlers,(function(t){return t.call(null!==e.caller?e.caller:e)}))},onStep:function(){},seekTo:function(e){this.seekFromTo(this.tick,e)},seekFromTo:function(e,t){this.target=Math.max(0,Math.min(1,t)),this.tick=Math.max(0,Math.min(1,e)),this.lastTime=(new Date).getTime(),this.intervalId||(this.intervalId=window.setInterval(this.timerDelegate,this.interval))},stop:function(){this.intervalId&&(window.clearInterval(this.intervalId),this.intervalId=null,this.trigger())},play:function(e){0!==this.adapters.length&&(null!==e&&(this.caller=e),this.initState(),this.seekFromTo(0,1))},reverse:function(){this.seekFromTo(1,0)},initState:function(){if(0!==this.adapters.length)for(var e=0;e<this.adapters.length;e++)this.adapters[e].initState()},propagate:function(){for(var e=this.transition(this.tick),t=0;t<this.adapters.length;t++)this.adapters[t].update(e)},onTimerEvent:function(){var e=(new Date).getTime(),t=e-this.lastTime;this.lastTime=e;var n=t/this.duration*(this.tick<this.target?1:-1);Math.abs(n)>=Math.abs(this.tick-this.target)?this.tick=this.target:this.tick+=n;try{this.propagate()}finally{this.onStep.call(this),this.target==this.tick&&this.stop()}}});t.deepExtend(n,{init:function(e){t.init(e,n.ui)},Utils:o,Range:function(e,t,n){if(void 0===e||void 0===t)return[];if(n&&o.sign(t-e)!=o.sign(n))throw"The sign of the increment should allow to reach the stop-value.";if(e=e||0,((t=t||e)-e)/(n=n||1)==1/0)throw"Infinite range defined.";var i,r=[],a=-1,s=function(e){for(var t=1;e*t%1;)t*=10;return t}(Math.abs(n));if(n*=s,(e*=s)>(t*=s)&&n>0&&(n=-n),n<0)for(;(i=e+n*++a)>=t;)r.push(i/s);else for(;(i=e+n*++a)<=t;)r.push(i/s);return r},Ticker:s})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.dataviz.diagram,i=t.Class,r=t.deepExtend,o=n.Utils,a=t.geometry.Point,s=t.isFunction,l=o.contains,c=e.map;class d extends a{constructor(e,t){super(e,t)}clone(){return new d(this.x,this.y)}plus(e){return new d(this.x+e.x,this.y+e.y)}minus(e){return new d(this.x-e.x,this.y-e.y)}offset(e){return new d(this.x-e,this.y-e)}times(e){return new d(this.x*e,this.y*e)}normalize(){return 0===this.length()?new d:this.times(1/this.length())}length(){return Math.sqrt(this.x*this.x+this.y*this.y)}toString(){return"("+this.x+","+this.y+")"}lengthSquared(){return this.x*this.x+this.y*this.y}middleOf(e,t){return new d(t.x-e.x,t.y-e.y).times(.5).plus(e)}toPolar(e){var t=1;e&&(t=180/Math.PI);var n=Math.atan2(Math.abs(this.y),Math.abs(this.x)),i=Math.PI/2,r=this.length();if(0===this.x){if(0===this.y)return new v(0,0);if(this.y>0)return new v(r,t*i);if(this.y<0)return new v(r,3*t*i)}else if(this.x>0){if(0===this.y)return new v(r,0);if(this.y>0)return new v(r,t*n);if(this.y<0)return new v(r,t*(4*i-n))}else{if(0===this.y)return new v(r,2*i);if(this.y>0)return new v(r,t*(2*i-n));if(this.y<0)return new v(r,t*(2*i+n))}}isOnLine(e,t){if(e.x>t.x){var n=t;t=e,e=n}var i,r,o=new h(e.x,e.y).inflate(3,3),a=new h(t.x,t.y).inflate(3,3);return!!o.union(a).contains(this)&&(e.x===t.x||e.y===t.y||(e.y<t.y?(i=o.x+(a.x-o.x)*(this.y-(o.y+o.height))/(a.y+a.height-(o.y+o.height)),r=o.x+o.width+(a.x+a.width-(o.x+o.width))*(this.y-o.y)/(a.y-o.y)):(i=o.x+(a.x-o.x)*(this.y-o.y)/(a.y-o.y),r=o.x+o.width+(a.x+a.width-(o.x+o.width))*(this.y-(o.y+o.height))/(a.y+a.height-(o.y+o.height))),this.x>i&&this.x<r))}parse(e){var t=e.slice(1,e.length-1).split(","),n=parseInt(t[0],10),i=parseInt(t[1],10);if(!isNaN(n)&&!isNaN(i))return new d(n,i)}}var u=i.extend({init:function(e,t,n){this.point=e,this.left=t,this.right=n}}),h=i.extend({init:function(e,t,n,i){this.x=e||0,this.y=t||0,this.width=n||0,this.height=i||0},contains:function(e){return e.x>=this.x&&e.x<=this.x+this.width&&e.y>=this.y&&e.y<=this.y+this.height},inflate:function(e,t){return undefined===t&&(t=e),this.x-=e,this.y-=t,this.width+=2*e+1,this.height+=2*t+1,this},offset:function(e,t){var n=e,i=t;return e instanceof d&&(n=e.x,i=e.y),this.x+=n,this.y+=i,this},union:function(e){var t=Math.min(this.x,e.x),n=Math.min(this.y,e.y),i=Math.max(this.x+this.width,e.x+e.width),r=Math.max(this.y+this.height,e.y+e.height);return new h(t,n,i-t,r-n)},center:function(){return new d(this.x+this.width/2,this.y+this.height/2)},top:function(){return new d(this.x+this.width/2,this.y)},right:function(){return new d(this.x+this.width,this.y+this.height/2)},bottom:function(){return new d(this.x+this.width/2,this.y+this.height)},left:function(){return new d(this.x,this.y+this.height/2)},topLeft:function(){return new d(this.x,this.y)},topRight:function(){return new d(this.x+this.width,this.y)},bottomLeft:function(){return new d(this.x,this.y+this.height)},bottomRight:function(){return new d(this.x+this.width,this.y+this.height)},clone:function(){return new h(this.x,this.y,this.width,this.height)},isEmpty:function(){return!this.width&&!this.height},equals:function(e){return this.x===e.x&&this.y===e.y&&this.width===e.width&&this.height===e.height},rotatedBounds:function(e){var t=this.clone(),n=this.rotatedPoints(e),i=n[0],r=n[1],o=n[2],a=n[3];return t.x=Math.min(o.x,i.x,r.x,a.x),t.y=Math.min(o.y,i.y,r.y,a.y),t.width=Math.max(o.x,i.x,r.x,a.x)-t.x,t.height=Math.max(o.y,i.y,r.y,a.y)-t.y,t},rotatedPoints:function(e){var t=this,n=t.center(),i=t.bottomRight().rotate(e,n);return[t.topLeft().rotate(e,n),t.topRight().rotate(e,n),i,t.bottomLeft().rotate(e,n)]},toString:function(e){return e=e||" ",this.x+e+this.y+e+this.width+e+this.height},scale:function(e,t,n,i,r){var o=this.topLeft(),a=this.center();o.rotate(r,a).rotate(r,i);var s=n.minus(o),l=new d(s.x*e,s.y*t),c=s.minus(l);(o=o.plus(c)).rotate(r,i).rotate(r,a),this.x=o.x,this.y=o.y,this.width*=e,this.height*=t},zoom:function(e){return this.x*=e,this.y*=e,this.width*=e,this.height*=e,this},overlaps:function(e){var t=this.bottomRight(),n=e.bottomRight();return!(t.x<e.x||t.y<e.y||n.x<this.x||n.y<this.y)}}),p=i.extend({init:function(e,t){this.width=e,this.height=t}});function f(e,t,n,i,r){var o=(t.x-e.x)*(i.y-n.y)-(t.y-e.y)*(i.x-n.x);if(a=o,!(Math.abs(a)<1e-6)){var a,s=((e.y-n.y)*(i.x-n.x)-(e.x-n.x)*(i.y-n.y))/o,l=((e.y-n.y)*(t.x-e.x)-(e.x-n.x)*(t.y-e.y))/o;if(!r||!(s<0||s>1||l<0||l>1))return new d(e.x+s*(t.x-e.x),e.y+s*(t.y-e.y))}}p.prototype.Empty=new p(0,0),h.toRect=function(e){return e instanceof h||(e=new h(e.x,e.y,e.width,e.height)),e},h.empty=function(){return new h(0,0,0,0)},h.fromPoints=function(e,t){if(isNaN(e.x)||isNaN(e.y)||isNaN(t.x)||isNaN(t.y))throw"Some values are NaN.";return new h(Math.min(e.x,t.x),Math.min(e.y,t.y),Math.abs(e.x-t.x),Math.abs(e.y-t.y))};var m={lines:function(e,t,n,i){return f(e,t,n,i)},segments:function(e,t,n,i){return f(e,t,n,i,!0)},rectWithLine:function(e,t,n){return m.segments(t,n,e.topLeft(),e.topRight())||m.segments(t,n,e.topRight(),e.bottomRight())||m.segments(t,n,e.bottomLeft(),e.bottomRight())||m.segments(t,n,e.topLeft(),e.bottomLeft())},rects:function(e,t,n){var i=t.topLeft(),r=t.topRight(),o=t.bottomLeft(),a=t.bottomRight(),s=t.center();n&&(i=i.rotate(n,s),r=r.rotate(n,s),o=o.rotate(n,s),a=a.rotate(n,s));var l=e.contains(i)||e.contains(r)||e.contains(o)||e.contains(a)||m.rectWithLine(e,i,r)||m.rectWithLine(e,i,o)||m.rectWithLine(e,r,a)||m.rectWithLine(e,o,a);if(!l){if(i=e.topLeft(),r=e.topRight(),o=e.bottomLeft(),a=e.bottomRight(),n){var c=360-n;i=i.rotate(c,s),r=r.rotate(c,s),o=o.rotate(c,s),a=a.rotate(c,s)}l=t.contains(i)||t.contains(r)||t.contains(o)||t.contains(a)}return l}},g=i.extend({init:function(e){this.container=h.toRect(e)},align:function(e,t){for(var n=t.toLowerCase().split(" "),i=0;i<n.length;i++)e=this._singleAlign(e,n[i]);return e},_singleAlign:function(e,t){return s(this[t])?this[t](e):e},left:function(e){return this._align(e,this._left)},center:function(e){return this._align(e,this._center)},right:function(e){return this._align(e,this._right)},stretch:function(e){return this._align(e,this._stretch)},top:function(e){return this._align(e,this._top)},middle:function(e){return this._align(e,this._middle)},bottom:function(e){return this._align(e,this._bottom)},_left:function(e,t){t.x=e.x},_center:function(e,t){t.x=(e.width-t.width)/2||0},_right:function(e,t){t.x=e.width-t.width},_top:function(e,t){t.y=e.y},_middle:function(e,t){t.y=(e.height-t.height)/2||0},_bottom:function(e,t){t.y=e.height-t.height},_stretch:function(e,t){t.x=0,t.y=0,t.height=e.height,t.width=e.width},_align:function(e,t){return e=h.toRect(e),t(this.container,e),e}}),v=i.extend({init:function(e,t){this.r=e,this.angle=t}}),_=i.extend({init:function(e,t,n,i,r,o){this.a=e||0,this.b=t||0,this.c=n||0,this.d=i||0,this.e=r||0,this.f=o||0},plus:function(e){this.a+=e.a,this.b+=e.b,this.c+=e.c,this.d+=e.d,this.e+=e.e,this.f+=e.f},minus:function(e){this.a-=e.a,this.b-=e.b,this.c-=e.c,this.d-=e.d,this.e-=e.e,this.f-=e.f},times:function(e){return new _(this.a*e.a+this.c*e.b,this.b*e.a+this.d*e.b,this.a*e.c+this.c*e.d,this.b*e.c+this.d*e.d,this.a*e.e+this.c*e.f+this.e,this.b*e.e+this.d*e.f+this.f)},apply:function(e){return new d(this.a*e.x+this.c*e.y+this.e,this.b*e.x+this.d*e.y+this.f)},applyRect:function(e){return h.fromPoints(this.apply(e.topLeft()),this.apply(e.bottomRight()))},toString:function(){return"matrix("+this.a+" "+this.b+" "+this.c+" "+this.d+" "+this.e+" "+this.f+")"}});r(_,{fromSVGMatrix:function(e){var t=new _;return t.a=e.a,t.b=e.b,t.c=e.c,t.d=e.d,t.e=e.e,t.f=e.f,t},fromMatrixVector:function(e){var t=new _;return t.a=e.a,t.b=e.b,t.c=e.c,t.d=e.d,t.e=e.e,t.f=e.f,t},fromList:function(e){if(6!==e.length)throw"The given list should consist of six elements.";var t=new _;return t.a=e[0],t.b=e[1],t.c=e[2],t.d=e[3],t.e=e[4],t.f=e[5],t},translation:function(e,t){var n=new _;return n.a=1,n.b=0,n.c=0,n.d=1,n.e=e,n.f=t,n},unit:function(){return new _(1,0,0,1,0,0)},rotation:function(e,t,n){var i=new _;return i.a=Math.cos(e*Math.PI/180),i.b=Math.sin(e*Math.PI/180),i.c=-i.b,i.d=i.a,i.e=t-t*i.a+n*i.b||0,i.f=n-n*i.a-t*i.b||0,i},scaling:function(e,t){var n=new _;return n.a=e,n.b=0,n.c=0,n.d=t,n.e=0,n.f=0,n},parse:function(e){var t,n;if(e){if("matrix"===(e=e.trim()).slice(0,6).toLowerCase()){if(6===(t=(n=e.slice(7,e.length-1).trim()).split(",")).length)return _.fromList(c(t,(function(e){return parseFloat(e)})));if(6===(t=n.split(" ")).length)return _.fromList(c(t,(function(e){return parseFloat(e)})))}if("("===e.slice(0,1)&&")"===e.slice(e.length-1)&&(e=e.substr(1,e.length-1)),e.indexOf(",")>0&&6===(t=e.split(",")).length)return _.fromList(c(t,(function(e){return parseFloat(e)})));if(e.indexOf(" ")>0&&6===(t=e.split(" ")).length)return _.fromList(c(t,(function(e){return parseFloat(e)})))}return t}});var b=i.extend({init:function(e,t,n,i,r,o){this.a=e||0,this.b=t||0,this.c=n||0,this.d=i||0,this.e=r||0,this.f=o||0},fromMatrix:function(e){var t=new b;return t.a=e.a,t.b=e.b,t.c=e.c,t.d=e.d,t.e=e.e,t.f=e.f,t}});function y(e){o.isUndefined(e)&&(e=10);for(var t="",n="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ",i=e;i>0;--i)t+=n.charAt(Math.round(61*Math.random()));return t}var w={_distanceToLineSquared:function(e,t,n){function i(e,t){return(e.x-t.x)*(e.x-t.x)+(e.y-t.y)*(e.y-t.y)}if(t===n)return i(e,t);var r=n.x-t.x,o=n.y-t.y,a=(e.x-t.x)*r+(e.y-t.y)*o;return a<0?i(t,e):(a=(n.x-e.x)*r+(n.y-e.y)*o)<0?i(n,e):(a=(n.x-e.x)*o-(n.y-e.y)*r)*a/(r*r+o*o)},distanceToLine:function(e,t,n){return Math.sqrt(this._distanceToLineSquared(e,t,n))},distanceToPolyline:function(e,t){var n=Number.MAX_VALUE;if(o.isUndefined(t)||0===t.length)return Number.MAX_VALUE;for(var i=0;i<t.length-1;i++){var r=t[i],a=t[i+1],s=this._distanceToLineSquared(e,r,a);s<n&&(n=s)}return Math.sqrt(n)}},k=t.Class.extend({init:function(){this._buckets=[],this.length=0},add:function(e,t){var n=this._createGetBucket(e);return o.isDefined(t)&&(n.value=t),n},get:function(e){return this._bucketExists(e)?this._createGetBucket(e):null},set:function(e,t){this.add(e,t)},containsKey:function(e){return this._bucketExists(e)},remove:function(e){if(this._bucketExists(e)){var t=this._hash(e);return delete this._buckets[t],this.length--,e}},forEach:function(e){for(var t=this._hashes(),n=0,i=t.length;n<i;n++){var r=t[n],a=this._buckets[r];o.isUndefined(a)||e(a)}},clone:function(){for(var e=new k,t=this._hashes(),n=0,i=t.length;n<i;n++){var r=t[n],a=this._buckets[r];o.isUndefined(a)||e.add(a.key,a.value)}return e},_hashes:function(){var e=[];for(var t in this._buckets)this._buckets.hasOwnProperty(t)&&e.push(t);return e},_bucketExists:function(e){var t=this._hash(e);return o.isDefined(this._buckets[t])},_createGetBucket:function(e){var t=this._hash(e),n=this._buckets[t];return o.isUndefined(n)&&(n={key:e},this._buckets[t]=n,this.length++),n},_hash:function(e){if(o.isNumber(e))return e;if(o.isString(e))return this._hashString(e);if(o.isObject(e))return this._objectHashId(e);throw"Unsupported key type."},_hashString:function(e){var t=0;if(0===e.length)return t;for(var n=0;n<e.length;n++){t=32*t-t+e.charCodeAt(n)}return t},_objectHashId:function(e){var t=e._hashId;return o.isUndefined(t)&&(t=y(),e._hashId=t),t}}),x=t.Observable.extend({init:function(e){if(t.Observable.fn.init.call(this),this._hashTable=new k,this.length=0,o.isDefined(e))if(Array.isArray(e))for(var n=0;n<e.length;n++)this.add(e[n]);else e.forEach((function(e,t){this.add(e,t)}),this)},add:function(e,t){var n=this._hashTable.get(e);n||(n=this._hashTable.add(e),this.length++,this.trigger("changed")),n.value=t},set:function(e,t){this.add(e,t)},get:function(e){var t=this._hashTable.get(e);if(t)return t.value;throw new Error("Cannot find key "+e)},containsKey:function(e){return this._hashTable.containsKey(e)},remove:function(e){if(this.containsKey(e))return this.trigger("changed"),this.length--,this._hashTable.remove(e)},forEach:function(e,t){this._hashTable.forEach((function(n){e.call(t,n.key,n.value)}))},forEachValue:function(e,t){this._hashTable.forEach((function(n){e.call(t,n.value)}))},forEachKey:function(e,t){this._hashTable.forEach((function(n){e.call(t,n.key)}))},keys:function(){var e=[];return this.forEachKey((function(t){e.push(t)})),e}}),C=t.Class.extend({init:function(){this._tail=null,this._head=null,this.length=0},enqueue:function(e){var t={value:e,next:null};this._head?(this._tail.next=t,this._tail=this._tail.next):(this._head=t,this._tail=this._head),this.length++},dequeue:function(){if(this.length<1)throw new Error("The queue is empty.");var e=this._head.value;return this._head=this._head.next,this.length--,e},contains:function(e){for(var t=this._head;t;){if(t.value===e)return!0;t=t.next}return!1}}),S=t.Observable.extend({init:function(e){t.Observable.fn.init.call(this),this._hashTable=new k,this.length=0,o.isDefined(e)&&(e instanceof k?e.forEach((function(e){this.add(e)})):e instanceof x&&e.forEach((function(e,t){this.add({key:e,value:t})}),this))},contains:function(e){return this._hashTable.containsKey(e)},add:function(e){this._hashTable.get(e)||(this._hashTable.add(e,e),this.length++,this.trigger("changed"))},get:function(e){return this.contains(e)?this._hashTable.get(e).value:null},hash:function(e){return this._hashTable._hash(e)},remove:function(e){this.contains(e)&&(this._hashTable.remove(e),this.length--,this.trigger("changed"))},forEach:function(e,t){this._hashTable.forEach((function(t){e(t.value)}),t)},toArray:function(){var e=[];return this.forEach((function(t){e.push(t)})),e}}),T=t.Class.extend({init:function(e,t){if(this.links=[],this.outgoing=[],this.incoming=[],this.weight=1,o.isDefined(e)?this.id=e:this.id=y(),o.isDefined(t)){this.associatedShape=t;var n=t.bounds();this.width=n.width,this.height=n.height,this.x=n.x,this.y=n.y}else this.associatedShape=null;this.data=null,this.type="Node",this.shortForm="Node '"+this.id+"'",this.isVirtual=!1},isIsolated:function(){return o.isEmpty(this.links)},bounds:function(e){if(!o.isDefined(e))return new n.Rect(this.x,this.y,this.width,this.height);this.x=e.x,this.y=e.y,this.width=e.width,this.height=e.height},isLinkedTo:function(e){var t=this;return o.any(t.links,(function(n){return n.getComplement(t)===e}))},getChildren:function(){if(0===this.outgoing.length)return[];for(var e=[],t=0,n=this.outgoing.length;t<n;t++){var i=this.outgoing[t];e.push(i.getComplement(this))}return e},getParents:function(){if(0===this.incoming.length)return[];for(var e=[],t=0,n=this.incoming.length;t<n;t++){var i=this.incoming[t];e.push(i.getComplement(this))}return e},clone:function(){var e=new T;return o.isDefined(this.weight)&&(e.weight=this.weight),o.isDefined(this.balance)&&(e.balance=this.balance),o.isDefined(this.owner)&&(e.owner=this.owner),e.associatedShape=this.associatedShape,e.x=this.x,e.y=this.y,e.width=this.width,e.height=this.height,e},adjacentTo:function(e){return null!==this.isLinkedTo(e)},removeLink:function(e){e.source===this&&(o.remove(this.links,e),o.remove(this.outgoing,e),e.source=null),e.target===this&&(o.remove(this.links,e),o.remove(this.incoming,e),e.target=null)},hasLinkTo:function(e){return o.any(this.outgoing,(function(t){return t.target===e}))},degree:function(){return this.links.length},incidentWith:function(e){return l(this.links,e)},getLinksWith:function(e){return o.all(this.links,(function(t){return t.getComplement(this)===e}),this)},getNeighbors:function(){var e=[];return o.forEach(this.incoming,(function(t){e.push(t.getComplement(this))}),this),o.forEach(this.outgoing,(function(t){e.push(t.getComplement(this))}),this),e}}),D=t.Class.extend({init:function(e,t,n,i){if(o.isUndefined(e))throw"The source of the new link is not set.";if(o.isUndefined(t))throw"The target of the new link is not set.";var r,a;r=o.isString(e)?new T(e):e,a=o.isString(t)?new T(t):t,this.source=r,this.target=a,this.source.links.push(this),this.target.links.push(this),this.source.outgoing.push(this),this.target.incoming.push(this),o.isDefined(n)?this.id=n:this.id=y(),o.isDefined(i)?this.associatedConnection=i:this.associatedConnection=null,this.type="Link",this.shortForm="Link '"+this.source.id+"->"+this.target.id+"'"},getComplement:function(e){if(this.source!==e&&this.target!==e)throw"The given node is not incident with this link.";return this.source===e?this.target:this.source},getCommonNode:function(e){return this.source===e.source||this.source===e.target?this.source:this.target===e.source||this.target===e.target?this.target:null},isBridging:function(e,t){return this.source===e&&this.target===t||this.source===t&&this.target===e},getNodes:function(){return[this.source,this.target]},incidentWith:function(e){return this.source===e||this.target===e},adjacentTo:function(e){return l(this.source.links,e)||l(this.target.links,e)},changeSource:function(e){o.remove(this.source.links,this),o.remove(this.source.outgoing,this),e.links.push(this),e.outgoing.push(this),this.source=e},changeTarget:function(e){o.remove(this.target.links,this),o.remove(this.target.incoming,this),e.links.push(this),e.incoming.push(this),this.target=e},changesNodes:function(e,t){this.source===e?this.changeSource(t):this.target===e&&this.changeTarget(t)},reverse:function(){var e=this.source,t=this.target;return this.source=t,o.remove(e.outgoing,this),this.source.outgoing.push(this),this.target=e,o.remove(t.incoming,this),this.target.incoming.push(this),this},directTo:function(e){if(this.source!==e&&this.target!==e)throw"The given node is not incident with this link.";this.target!==e&&this.reverse()},createReverseEdge:function(){var e=this.clone();return e.reverse(),e.reversed=!0,e},clone:function(){return new D(this.source,this.target)}}),A=t.Class.extend({init:function(e){this.links=[],this.nodes=[],this._nodeMap=new x,this.diagram=null,this._root=null,o.isDefined(e)?o.isString(e)?this.id=e:(this.diagram=e,this.id=e.id):this.id=y(),this.bounds=new h,this._hasCachedRelationships=!1,this.type="Graph"},cacheRelationships:function(e){if(o.isUndefined(e)&&(e=!1),!this._hasCachedRelationships||e){for(var t=0,n=this.nodes.length;t<n;t++){var i=this.nodes[t];i.children=this.getChildren(i),i.parents=this.getParents(i)}this._hasCachedRelationships=!0}},assignLevels:function(e,t,n){if(!e)throw"Start node not specified.";o.isUndefined(t)&&(t=0),this.cacheRelationships(),o.isUndefined(n)&&(n=new x,o.forEach(this.nodes,(function(e){n.add(e,!1)}))),n.set(e,!0),e.level=t;for(var i=e.children,r=0,a=i.length;r<a;r++){var s=i[r];s&&!n.get(s)&&this.assignLevels(s,t+1,n)}},root:function(e){if(o.isUndefined(e)){if(this._root)return this._root;var t=o.first(this.nodes,(function(e){return 0===e.incoming.length}));return t||o.first(this.nodes)}this._root=e},getConnectedComponents:function(){this.componentIndex=0,this.setItemIndices();for(var e=o.initArray(this.nodes.length,-1),t=0;t<this.nodes.length;t++)-1===e[t]&&(this._collectConnectedNodes(e,t),this.componentIndex++);var n,i=[];for(n=0;n<this.componentIndex;++n)i[n]=new A;for(n=0;n<e.length;++n){i[e[n]].addNodeAndOutgoings(this.nodes[n])}return i.sort((function(e,t){return t.nodes.length-e.nodes.length})),i},_collectConnectedNodes:function(e,t){e[t]=this.componentIndex;var n=this.nodes[t];o.forEach(n.links,(function(t){var i=t.getComplement(n).index;-1===e[i]&&this._collectConnectedNodes(e,i)}),this)},calcBounds:function(){if(this.isEmpty())return this.bounds=new h,this.bounds;for(var e=null,t=0,n=this.nodes.length;t<n;t++){var i=this.nodes[t];e=e?e.union(i.bounds()):i.bounds()}return this.bounds=e,this.bounds},getSpanningTree:function(e){var t,n,i=new A,r=new x;i.root=e.clone(),i.root.level=0,i.root.id=e.id,r.add(e,i.root),e.level=0;var a=[],s=[];i._addNode(i.root),a.push(e),s.push(e);for(var c=1;s.length>0;)for(var d=s.pop(),u=0;u<d.links.length;u++){var h=d.links[u].getComplement(d);if(!l(a,h)){h.level=d.level+1,c<h.level+1&&(c=h.level+1),l(s,h)||s.push(h),l(a,h)||a.push(h),r.containsKey(d)?t=r.get(d):((t=d.clone()).level=d.level,t.id=d.id,r.add(d,t)),r.containsKey(h)?n=r.get(h):((n=h.clone()).level=h.level,n.id=h.id,r.add(h,n));var p=new D(t,n);i.addLink(p)}}for(var f=[],m=0;m<c;m++)f.push([]);return o.forEach(i.nodes,(function(e){f[e.level].push(e)})),i.treeLevels=f,i.cacheRelationships(),i},takeRandomNode:function(t,n){if(o.isUndefined(t)&&(t=[]),o.isUndefined(n)&&(n=4),0===this.nodes.length)return null;if(1===this.nodes.length)return l(t,this.nodes[0])?null:this.nodes[0];var i=e.grep(this.nodes,(function(e){return!l(t,e)&&e.degree()<=n}));return o.isEmpty(i)?null:i[o.randomInteger(0,i.length)]},isEmpty:function(){return o.isEmpty(this.nodes)},isHealthy:function(){return o.all(this.links,(function(e){return l(this.nodes,e.source)&&l(this.nodes,e.target)}),this)},getParents:function(e){if(!this.hasNode(e))throw"The given node is not part of this graph.";return e.getParents()},getChildren:function(e){if(!this.hasNode(e))throw"The given node is not part of this graph.";return e.getChildren()},addLink:function(e,t,n){if(o.isUndefined(e))throw"The source of the link is not defined.";if(o.isUndefined(t)){if(o.isDefined(e.type)&&"Link"===e.type)return void this.addExistingLink(e);throw"The target of the link is not defined."}var i=this.getNode(e);o.isUndefined(i)&&(i=this.addNode(e));var r=this.getNode(t);o.isUndefined(r)&&(r=this.addNode(t));var a=new D(i,r);return o.isDefined(n)&&(a.owner=n),this.links.push(a),a},removeAllLinks:function(){for(;this.links.length>0;){var e=this.links[0];this.removeLink(e)}},addExistingLink:function(e){if(!this.hasLink(e)){if(this.links.push(e),this.hasNode(e.source.id)){var t=this.getNode(e.source.id);e.changeSource(t)}else this.addNode(e.source);if(this.hasNode(e.target.id)){var n=this.getNode(e.target.id);e.changeTarget(n)}else this.addNode(e.target)}},hasLink:function(e){if(o.isString(e))return o.any(this.links,(function(t){return t.id===e}));if("Link"===e.type)return l(this.links,e);throw"The given object is neither an identifier nor a Link."},getNode:function(e){var t=e.id||e;if(this._nodeMap.containsKey(t))return this._nodeMap.get(t)},hasNode:function(e){var t=e.id||e;return this._nodeMap.containsKey(t)},_addNode:function(e){this.nodes.push(e),this._nodeMap.add(e.id,e)},_removeNode:function(e){o.remove(this.nodes,e),this._nodeMap.remove(e.id)},removeNode:function(e){var t=e;if(o.isString(e)&&(t=this.getNode(e)),!o.isDefined(t))throw"The identifier should be a Node or the Id (string) of a node.";var n=t.links;t.links=[];for(var i=0,r=n.length;i<r;i++){var a=n[i];this.removeLink(a)}this._removeNode(t)},areConnected:function(e,t){return o.any(this.links,(function(n){return n.source==e&&n.target==t||n.source==t&&n.target==e}))},removeLink:function(e){o.remove(this.links,e),o.remove(e.source.outgoing,e),o.remove(e.source.links,e),o.remove(e.target.incoming,e),o.remove(e.target.links,e)},addNode:function(e,t,n){var i=null;if(!o.isDefined(e))throw"No Node or identifier for a new Node is given.";if(o.isString(e)){if(this.hasNode(e))return this.getNode(e);i=new T(e)}else{if(this.hasNode(e))return this.getNode(e);i=e}return o.isDefined(t)&&i.bounds(t),o.isDefined(n)&&(i.owner=n),this._addNode(i),i},addNodeAndOutgoings:function(e){this.hasNode(e)||this._addNode(e);var t=e.outgoing;e.outgoing=[],o.forEach(t,(function(e){this.addExistingLink(e)}),this)},setItemIndices:function(){var e;for(e=0;e<this.nodes.length;++e)this.nodes[e].index=e;for(e=0;e<this.links.length;++e)this.links[e].index=e},clone:function(e){var t=new A,n=o.isDefined(e)&&!0===e;n&&(t.nodeMap=new x,t.linkMap=new x);var i=new x;return o.forEach(this.nodes,(function(e){var r=e.clone();i.set(e,r),t._addNode(r),n&&t.nodeMap.set(r,e)})),o.forEach(this.links,(function(e){if(i.containsKey(e.source)&&i.containsKey(e.target)){var r=t.addLink(i.get(e.source),i.get(e.target));n&&t.linkMap.set(r,e)}})),t},linearize:function(e){return A.Utils.linearize(this,e)},depthFirstTraversal:function(e,t){if(o.isUndefined(e))throw"You need to supply a starting node.";if(o.isUndefined(t))throw"You need to supply an action.";if(!this.hasNode(e))throw"The given start-node is not part of this graph";var n=this.getNode(e);this._dftIterator(n,t,[])},_dftIterator:function(e,t,n){t(e),n.push(e);for(var i=e.getChildren(),r=0,o=i.length;r<o;r++){var a=i[r];l(n,a)||this._dftIterator(a,t,n)}},breadthFirstTraversal:function(e,t){if(o.isUndefined(e))throw"You need to supply a starting node.";if(o.isUndefined(t))throw"You need to supply an action.";if(!this.hasNode(e))throw"The given start-node is not part of this graph";var n=this.getNode(e),i=new C,r=[];for(i.enqueue(n);i.length>0;){var a=i.dequeue();t(a),r.push(a);for(var s=a.getChildren(),c=0,d=s.length;c<d;c++){var u=s[c];l(r,u)||l(i,u)||i.enqueue(u)}}},_stronglyConnectedComponents:function(e,t,n,i,r,o,a){n.add(t,a),i.add(t,a),a++,o.push(t);for(var s,c=t.getChildren(),d=0,u=c.length;d<u;d++)s=c[d],n.containsKey(s)?l(o,s)&&i.add(t,Math.min(i.get(t),n.get(s))):(this._stronglyConnectedComponents(e,s,n,i,r,o,a),i.add(t,Math.min(i.get(t),i.get(s))));if(i.get(t)===n.get(t)){var h=[];do{s=o.pop(),h.push(s)}while(s!==t);(!e||h.length>1)&&r.push(h)}},findCycles:function(e){o.isUndefined(e)&&(e=!0);for(var t=new x,n=new x,i=[],r=[],a=0,s=this.nodes.length;a<s;a++){var l=this.nodes[a];t.containsKey(l)||this._stronglyConnectedComponents(e,l,t,n,i,r,0)}return i},isAcyclic:function(){return o.isEmpty(this.findCycles())},isSubGraph:function(e){var t=e.linearize(),n=this.linearize();return o.all(t,(function(e){return l(n,e)}))},makeAcyclic:function(){if(this.isEmpty()||this.nodes.length<=1||this.links.length<=1)return[];if(2==this.nodes.length){var e=[];if(this.links.length>1)for(var t=this.links[0].source,n=0,i=this.links.length;n<i;n++){var r=this.links[n];if(r.source!=t){var a=r.reverse();e.push(a)}}return e}var s=this.clone(!0),l=this.nodes.length,c=new x,d=function(e){return 0===e.outgoing.length?2-l:0===e.incoming.length?l-2:e.outgoing.length-e.incoming.length},u=function(e,t){var n=d(e);t.containsKey(n)||t.set(n,[]),t.get(n).push(e)};o.forEach(s.nodes,(function(e){u(e,c)}));for(var h=[],p=[];s.nodes.length>0;){var f,m,g;if(c.containsKey(2-l))for(var v=c.get(2-l);v.length>0;){m=v.pop();for(var _=0;_<m.links.length;_++){var b=m.links[_];f=b.getComplement(m),g=d(f),o.remove(c.get(g),f),f.removeLink(b),u(f,c)}s._removeNode(m),p.unshift(m)}if(c.containsKey(l-2))for(var y=c.get(l-2);y.length>0;){f=y.pop();for(var w=0;w<f.links.length;w++){var k=f.links[w];m=k.getComplement(f),g=d(m),o.remove(c.get(g),m),m.removeLink(k),u(m,c)}h.push(f),s._removeNode(f)}if(s.nodes.length>0)for(var C=l-3;C>2-l;C--)if(c.containsKey(C)&&c.get(C).length>0){for(var S=c.get(C).pop(),T=0;T<S.links.length;T++){var D=S.links[T],A=D.getComplement(S);g=d(A),o.remove(c.get(g),A),A.removeLink(D),u(A,c)}h.push(S),s._removeNode(S);break}}h=h.concat(p);for(var M=new x,E=0;E<this.nodes.length;E++)M.set(s.nodeMap.get(h[E]),E);var I=[];return o.forEach(this.links,(function(e){M.get(e.source)>M.get(e.target)&&(e.reverse(),I.push(e))})),I}});A.Predefined={EightGraph:function(){return A.Utils.parse(["1->2","2->3","3->4","4->1","3->5","5->6","6->7","7->3"])},Mindmap:function(){return A.Utils.parse(["0->1","0->2","0->3","0->4","0->5","1->6","1->7","7->8","2->9","9->10","9->11","3->12","12->13","13->14","4->15","4->16","15->17","15->18","18->19","18->20","14->21","14->22","5->23","23->24","23->25","6->26"])},ThreeGraph:function(){return A.Utils.parse(["1->2","2->3","3->1"])},BinaryTree:function(e){return o.isUndefined(e)&&(e=5),A.Utils.createBalancedTree(e,2)},Linear:function(e){return o.isUndefined(e)&&(e=10),A.Utils.createBalancedTree(e,1)},Tree:function(e,t){return A.Utils.createBalancedTree(e,t)},Forest:function(e,t,n){return A.Utils.createBalancedForest(e,t,n)},Workflow:function(){return A.Utils.parse(["0->1","1->2","2->3","1->4","4->3","3->5","5->6","6->3","6->7","5->4"])},Grid:function(e,t){var i=new n.Graph;if(e<=0&&t<=0)return i;for(var r=0;r<e+1;r++)for(var o=null,a=0;a<t+1;a++){var s=new T(r.toString()+"."+a.toString());if(i.addNode(s),o&&i.addLink(o,s),r>0){var l=i.getNode((r-1).toString()+"."+a.toString());i.addLink(l,s)}o=s}return i}},A.Utils={parse:function(e){for(var i,r=new n.Graph,a=e.slice(),s=0,l=a.length;s<l;s++){var c=a[s];if(o.isString(c)){if(c.indexOf("->")<0)throw"The link should be specified as 'a->b'.";var d=c.split("->");if(2!=d.length)throw"The link should be specified as 'a->b'.";i=new D(d[0],d[1]),r.addLink(i)}if(o.isObject(c)){if(!i)throw"Specification found before Link definition.";t.deepExtend(i,c)}}return r},linearize:function(e,t){if(o.isUndefined(e))throw"Expected an instance of a Graph object in slot one.";o.isUndefined(t)&&(t=!1);for(var n=[],i=0,r=e.links.length;i<r;i++){var a=e.links[i];n.push(a.source.id+"->"+a.target.id),t&&n.push({id:a.id})}return n},_addShape:function(e,n,i,r){return o.isUndefined(n)&&(n=new d(0,0)),o.isUndefined(i)&&(i=y()),r=t.deepExtend({width:20,height:20,id:i,radius:10,fill:"#778899",data:"circle",undoable:!1,x:n.x,y:n.y},r),e.addShape(r)},_addConnection:function(e,t,n,i){return e.connect(t,n,i)},createDiagramFromGraph:function(e,n,i,r){if(o.isUndefined(e))throw"The diagram surface is undefined.";if(o.isUndefined(n))throw"No graph specification defined.";o.isUndefined(i)&&(i=!0),o.isUndefined(r)&&(r=!1);for(var a,s,l=e.element.clientWidth||200,c=e.element.clientHeight||200,u=[],p=0,f=n.nodes.length;p<f;p++){var m=(a=n.nodes[p]).position;o.isUndefined(m)&&(m=o.isDefined(a.x)&&o.isDefined(a.y)?new d(a.x,a.y):new d(o.randomInteger(10,l-20),o.randomInteger(10,c-20)));var g={};"0"===a.id||r&&t.deepExtend(g,{width:150*Math.random()+20,height:80*Math.random()+50,data:"rectangle",fill:{color:"#778899"}});var v=(s=this._addShape(e,m,a.id,g)).bounds();o.isDefined(v)&&(a.x=v.x,a.y=v.y,a.width=v.width,a.height=v.height),u[a.id]=s}for(var _=0;_<n.links.length;_++){var b=n.links[_],y=u[b.source.id];if(!o.isUndefined(y)){var w=u[b.target.id];o.isUndefined(w)||this._addConnection(e,y,w,{id:b.id})}}if(i){new e.SpringLayout(e).layoutGraph(n,{limitToView:!1});for(var k=0;k<n.nodes.length;k++)(s=u[(a=n.nodes[k]).id]).bounds(new h(a.x,a.y,a.width,a.height))}},createBalancedTree:function(e,t){o.isUndefined(e)&&(e=3),o.isUndefined(t)&&(t=3);var i,r=new n.Graph,a=-1,s=[];if(e<=0||t<=0)return r;var l=new T((++a).toString());r.addNode(l),r.root=l,s.push(l);for(var c=0;c<e;c++){i=[];for(var d=0;d<s.length;d++)for(var u=s[d],h=0;h<t;h++){var p=new T((++a).toString());r.addLink(u,p),i.push(p)}s=i}return r},createBalancedForest:function(e,t,i){o.isUndefined(e)&&(e=3),o.isUndefined(t)&&(t=3),o.isUndefined(i)&&(i=5);var r,a=new n.Graph,s=-1,l=[];if(e<=0||t<=0||i<=0)return a;for(var c=0;c<i;c++){var d=new T((++s).toString());a.addNode(d),l=[d];for(var u=0;u<e;u++){r=[];for(var h=0;h<l.length;h++)for(var p=l[h],f=0;f<t;f++){var m=new T((++s).toString());a.addLink(p,m),r.push(m)}l=r}}return a},createRandomConnectedGraph:function(e,t,i){o.isUndefined(e)&&(e=40),o.isUndefined(t)&&(t=4),o.isUndefined(i)&&(i=!1);var r=new n.Graph,a=-1;if(e<=0)return r;var s=new T((++a).toString());if(r.addNode(s),1===e)return r;if(e>1){for(var l=1;l<e;l++){var c=r.takeRandomNode([],t);if(!c)break;var d=r.addNode(l.toString());r.addLink(c,d)}if(!i&&e>1)for(var u=o.randomInteger(1,e),h=0;h<u;h++){var p=r.takeRandomNode([],t),f=r.takeRandomNode([],t);p&&f&&!r.areConnected(p,f)&&r.addLink(p,f)}return r}},randomDiagram:function(e,n,i,r,o){var a=t.dataviz.diagram.Graph.Utils.createRandomConnectedGraph(n,i,r);A.Utils.createDiagramFromGraph(e,a,!1,o)}},t.deepExtend(n,{init:function(e){t.init(e,n.ui)},Point:d,Intersect:m,Geometry:w,Rect:h,Size:p,RectAlign:g,Matrix:_,MatrixVector:b,normalVariable:function(e,t){var n,i,r;do{r=(n=2*Math.random()-1)*n+(i=2*Math.random()-1)*i}while(!r||r>1);return e+t*n*Math.sqrt(-2*Math.log(r)/r)},randomId:y,Dictionary:x,HashTable:k,Queue:C,Set:S,Node:T,Link:D,Graph:A,PathDefiner:u})}(window.kendo.jQuery),function(e,t){var n=window.kendo,i=n.dataviz.diagram,r=n.Class,o=n.deepExtend,a=i.Point,s=i.Rect,l=i.Matrix,c=i.Utils,d=c.isNumber,u=c.isString,h=i.MatrixVector,p=n.geometry,f=n.drawing,m=f.util.defined,g=e.inArray,v="transparent",_={none:"none",arrowStart:"ArrowStart",filledCircle:"FilledCircle",arrowEnd:"ArrowEnd"},b="start",y="end",w="width",k="height";function x(e,t){for(var n,i,r=this.options,o=!1,a=0;a<t.length;a++)n=e[i=t[a]],d(n)&&r[i]!==n&&(r[i]=n,o=!0);return o}i.Markers=_;var C=r.extend({init:function(e,t){this.x=e,this.y=t},toMatrix:function(){return l.scaling(this.x,this.y)},toString:function(){return n.format("scale({0},{1})",this.x,this.y)},invert:function(){return new C(1/this.x,1/this.y)}}),S=r.extend({init:function(e,t){this.x=e,this.y=t},toMatrixVector:function(){return new h(0,0,0,0,this.x,this.y)},toMatrix:function(){return l.translation(this.x,this.y)},toString:function(){return n.format("translate({0},{1})",this.x,this.y)},plus:function(e){this.x+=e.x,this.y+=e.y},times:function(e){this.x*=e,this.y*=e},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},normalize:function(){0!==this.Length&&this.times(1/this.length())},invert:function(){return new S(-this.x,-this.y)}}),T=r.extend({init:function(e,t,n){this.x=t||0,this.y=n||0,this.angle=e},toString:function(){return this.x&&this.y?n.format("rotate({0},{1},{2})",this.angle,this.x,this.y):n.format("rotate({0})",this.angle)},toMatrix:function(){return l.rotation(this.angle,this.x,this.y)},center:function(){return new a(this.x,this.y)},invert:function(){return new T(360-this.angle,this.x,this.y)}});T.ZERO=new T(0),T.create=function(e){return new T(e.angle,e.x,e.y)},T.parse=function(e){var t=e.slice(1,e.length-1).split(","),n=t[0],i=t[1],r=t[2];return new T(n,i,r)};var D=r.extend({init:function(e,n,i,r,o,a){this.translate=new S(e,n),i!==t&&r!==t&&(this.scale=new C(i,r)),o!==t&&(this.rotate=a?new T(o,a.x,a.y):new T(o))},toString:function(){var e=function(e){return e?e.toString():""};return e(this.translate)+e(this.rotate)+e(this.scale)},render:function(e){e._transform=this,e._renderTransform()},toMatrix:function(){var e=l.unit();return this.translate&&(e=e.times(this.translate.toMatrix())),this.rotate&&(e=e.times(this.rotate.toMatrix())),this.scale&&(e=e.times(this.scale.toMatrix())),e},invert:function(){var e=this.rotate?this.rotate.invert():t,n=e?e.toMatrix():l.unit(),i=this.scale?this.scale.invert():t,r=i?i.toMatrix():l.unit(),o=new a(-this.translate.x,-this.translate.y);o=n.times(r).apply(o);var s=new S(o.x,o.y),c=new D;return c.translate=s,c.rotate=e,c.scale=i,c}}),A={_setScale:function(){var e=this.options,t=this._originWidth,n=this._originHeight,i=e.width/t,r=e.height/n;d(i)||(i=1),d(r)||(r=1),this._transform.scale=new C(i,r)},_setTranslate:function(){var e=this.options,t=e.x||0,n=e.y||0;this._transform.translate=new S(t,n)},_initSize:function(){var e=this.options,t=!1;!1!==e.autoSize&&(m(e.width)||m(e.height))&&(this._measure(!0),this._setScale(),t=!0),(m(e.x)||m(e.y))&&(this._setTranslate(),t=!0),t&&this._renderTransform()},_updateSize:function(e){var t=!1;return!1!==this.options.autoSize&&this._diffNumericOptions(e,[w,k])&&(t=!0,this._measure(!0),this._setScale()),this._diffNumericOptions(e,["x","y"])&&(t=!0,this._setTranslate()),t&&this._renderTransform(),t}},M=r.extend({init:function(e){var t=this;t.options=o({},t.options,e),t.id=t.options.id,t._originSize=s.empty(),t._transform=new D},visible:function(e){return this.drawingContainer().visible(e)},redraw:function(e){e&&e.id&&(this.id=e.id)},position:function(e,t){var n=this.options;if(!m(e))return new a(n.x,n.y);m(t)?(n.x=e,n.y=t):e instanceof a&&(n.x=e.x,n.y=e.y),this._transform.translate=new S(n.x,n.y),this._renderTransform()},rotate:function(e,t){return m(e)&&(this._transform.rotate=new T(e,t.x,t.y),this._renderTransform()),this._transform.rotate||T.ZERO},drawingContainer:function(){return this.drawingElement},_renderTransform:function(){var e=this._transform.toMatrix();this.drawingContainer().transform(new p.Matrix(e.a,e.b,e.c,e.d,e.e,e.f))},_hover:function(){},_diffNumericOptions:x,_measure:function(e){var t;if(!this._measured||e){var n=this._boundingBox()||new p.Rect,i=n.topLeft();t=new s(i.x,i.y,n.width(),n.height()),this._originSize=t,this._originWidth=t.width,this._originHeight=t.height,this._measured=!0}else t=this._originSize;return t},_boundingBox:function(){return this.drawingElement.rawBBox()}}),E=M.extend({init:function(e){M.fn.init.call(this,e),(e=this.options).fill=q(e.fill),e.stroke=q(e.stroke)},options:{stroke:{color:"gray",width:1},fill:{color:v}},fill:function(e,t){this._fill({color:G(e),opacity:t})},stroke:function(e,t,n){this._stroke({color:G(e),width:t,opacity:n})},redraw:function(e){if(e){var t=e.stroke,n=e.fill;t&&this._stroke(q(t)),n&&this._fill(q(n)),M.fn.redraw.call(this,e)}},_hover:function(e){var t=this.drawingElement,n=this.options,i=n.hover;if(i&&i.fill){var r=e?q(i.fill):n.fill;t.fill(r.color,r.opacity)}},_stroke:function(e){var t=this.options;o(t,{stroke:e});var n=null;(e=t.stroke).width>0&&(n={color:e.color,width:e.width,opacity:e.opacity,dashType:e.dashType}),this.drawingElement.options.set("stroke",n)},_fill:function(e){var t=this.options;o(t,{fill:e||{}});var n=t.fill;if(n.gradient){var i=n.gradient,r="radial"===i.type?f.RadialGradient:f.LinearGradient;this.drawingElement.fill(new r(i))}else this.drawingElement.fill(n.color,n.opacity)}}),I=E.extend({init:function(e){e=this._textColor(e),E.fn.init.call(this,e),this._font(),this._initText(),this._initSize()},options:{fontSize:15,fontFamily:"sans-serif",stroke:{width:0},fill:{color:"black"},autoSize:!0},_initText:function(){var e=this.options;this.drawingElement=new f.Text(m(e.text)?e.text:"",new p.Point,{font:e.font}),this._fill(),this._stroke()},_textColor:function(e){return e&&e.color&&(e=o({},e,{fill:{color:e.color}})),e},_font:function(){var e=this.options;if(e.fontFamily&&m(e.fontSize)){var t=[];e.fontStyle&&t.push(e.fontStyle),e.fontWeight&&t.push(e.fontWeight),t.push(e.fontSize+(d(e.fontSize)?"px":"")),t.push(e.fontFamily),e.font=t.join(" ")}else delete e.font},content:function(e){return this.drawingElement.content(e)},redraw:function(e){if(e){var t=!1,n=this.options;e=this._textColor(e),E.fn.redraw.call(this,e),(e.fontFamily||m(e.fontSize)||e.fontStyle||e.fontWeight)&&(o(n,{fontFamily:e.fontFamily,fontSize:e.fontSize,fontStyle:e.fontStyle,fontWeight:e.fontWeight}),this._font(),this.drawingElement.options.set("font",n.font),t=!0),e.text&&(this.content(e.text),t=!0),!this._updateSize(e)&&t&&this._initSize()}}});o(I.fn,A);var z=E.extend({init:function(e){E.fn.init.call(this,e),this._initPath(),this._setPosition()},_setPosition:function(){var e=this.options,t=e.x,n=e.y;(m(t)||m(n))&&this.position(t||0,n||0)},redraw:function(e){e&&(E.fn.redraw.call(this,e),this._diffNumericOptions(e,[w,k])&&this._drawPath(),this._diffNumericOptions(e,["x","y"])&&this._setPosition())},_initPath:function(){var e=this.options;this.drawingElement=new f.Path({stroke:e.stroke,closed:!0}),this._fill(),this._drawPath()},_drawPath:function(){var e=this.drawingElement,t=j(this.options),n=t.width,i=t.height;e.segments.elements([K(0,0),K(n,0),K(n,i),K(0,i)])}}),P=E.extend({init:function(e){E.fn.init.call(this,e);var t=this.options.anchor;this.anchor=new p.Point(t.x,t.y),this.createElement()},options:{stroke:{color:v,width:0},fill:{color:"black"}},_transformToPath:function(e,t){var n=t.transform();return e&&n&&(e=e.transformCopy(n)),e},redraw:function(e){e&&(e.position&&(this.options.position=e.position),E.fn.redraw.call(this,e))}}),H=P.extend({options:{radius:4,anchor:{x:0,y:0}},createElement:function(){var e=this.options;this.drawingElement=new f.Circle(new p.Circle(this.anchor,e.radius),{fill:e.fill,stroke:e.stroke})},positionMarker:function(e){var t,n,i=this.options.position,r=e.segments;(t=i==b?r[0]:r[r.length-1])&&(n=this._transformToPath(t.anchor(),e),this.drawingElement.transform(p.transform().translate(n.x,n.y)))}}),F=P.extend({options:{path:"M 0 0 L 10 5 L 0 10 L 3 5 z",anchor:{x:10,y:5}},createElement:function(){var e=this.options;this.drawingElement=f.Path.parse(e.path,{fill:e.fill,stroke:e.stroke})},positionMarker:function(e){var t,n,i,r,o=this._linePoints(e),a=o.start,s=o.end,l=p.transform();if(a&&l.rotate((t=a,i=(n=s).x-t.x,r=n.y-t.y,f.util.deg(Math.atan2(r,i))),s),s){var c=this.anchor,d=s.clone().translate(-c.x,-c.y);l.translate(d.x,d.y)}this.drawingElement.transform(l)},_linePoints:function(e){var t,n,i,r=this.options,o=e.segments;if(r.position==b){if(i=o[0]){n=i.anchor(),t=i.controlOut();var a=o[1];!t&&a&&(t=a.anchor())}}else if(i=o[o.length-1]){n=i.anchor(),t=i.controlIn();var s=o[o.length-2];!t&&s&&(t=s.anchor())}if(n)return{start:this._transformToPath(t,e),end:this._transformToPath(n,e)}}}),R={_getPath:function(e){var t=this.drawingElement;if(t instanceof f.MultiPath&&(t=e==b?t.paths[0]:t.paths[t.paths.length-1]),t&&t.segments.length)return t},_normalizeMarkerOptions:function(e){var t=e.startCap,n=e.endCap;u(t)&&(e.startCap={type:t}),u(n)&&(e.endCap={type:n})},_removeMarker:function(e){var t=this._markers[e];t&&(this.drawingContainer().remove(t.drawingElement),delete this._markers[e])},_createMarkers:function(){var e=this.options;this._normalizeMarkerOptions(e),this._markers={},this._markers[b]=this._createMarker(e.startCap,b),this._markers[y]=this._createMarker(e.endCap,y)},_createMarker:function(e,t){var n,i,r=(e||{}).type,a=this._getPath(t);if(a)return r==_.filledCircle?n=H:r==_.arrowStart||r==_.arrowEnd?n=F:this._removeMarker(t),n?((i=new n(o({},e,{position:t}))).positionMarker(a),this.drawingContainer().append(i.drawingElement),i):void 0;this._removeMarker(t)},_positionMarker:function(e){var t=this._markers[e];if(t){var n=this._getPath(e);n?t.positionMarker(n):this._removeMarker(e)}},_capMap:{start:"startCap",end:"endCap"},_redrawMarker:function(e,t,n){this._normalizeMarkerOptions(n);var i=this.options,r=this._capMap[t],a=(i[r]||{}).type,s=n[r],l=!1;return s?(i[r]=o({},i[r],s),s.type&&a!=s.type?(this._removeMarker(t),this._markers[t]=this._createMarker(i[r],t),l=!0):this._markers[t]&&this._markers[t].redraw(s)):e&&!this._markers[t]&&i[r]&&(this._markers[t]=this._createMarker(i[r],t),l=!0),l},_redrawMarkers:function(e,t){!this._redrawMarker(e,b,t)&&e&&this._positionMarker(b),!this._redrawMarker(e,y,t)&&e&&this._positionMarker(y)}},L=E.extend({init:function(e){E.fn.init.call(this,e),this.container=new f.Group,this._createElements(),this._initSize()},options:{autoSize:!0},drawingContainer:function(){return this.container},data:function(e){var t=this.options;if(!e)return t.data;t.data!=e&&(t.data=e,this._setData(e),this._initSize(),this._redrawMarkers(!0,{}))},redraw:function(e){if(e){E.fn.redraw.call(this,e);var t=this.options,n=e.data;m(n)&&t.data!=n?(t.data=n,this._setData(n),this._updateSize(e)||this._initSize(),this._redrawMarkers(!0,e)):(this._updateSize(e),this._redrawMarkers(!1,e))}},_createElements:function(){var e=this.options;this.drawingElement=f.Path.parse(e.data||"",{stroke:e.stroke}),this._fill(),this.container.append(this.drawingElement),this._createMarkers()},_setData:function(e){var t=this.drawingElement,n=f.Path.parse(e||""),i=n.paths.slice(0);n.paths.elements([]),t.paths.elements(i)}});o(L.fn,A),o(L.fn,R);var B=E.extend({init:function(e){E.fn.init.call(this,e),this.container=new f.Group,this._initPath(),this._createMarkers()},drawingContainer:function(){return this.container},redraw:function(e){if(e){var t=(e=e||{}).from,n=e.to;t&&(this.options.from=t),n&&(this.options.to=n),t||n?(this._drawPath(),this._redrawMarkers(!0,e)):this._redrawMarkers(!1,e),E.fn.redraw.call(this,e)}},_initPath:function(){var e=this.options,t=this.drawingElement=new f.Path({stroke:e.stroke});this._fill(),this._drawPath(),this.container.append(t)},_drawPath:function(){var e=this.options,t=this.drawingElement,n=e.from||new a,i=e.to||new a;t.segments.elements([K(n.x,n.y),K(i.x,i.y)])}});o(B.fn,R);var O=E.extend({init:function(e){E.fn.init.call(this,e),this.container=new f.Group,this._initPath(),this._createMarkers()},drawingContainer:function(){return this.container},points:function(e){var t=this.options;if(!e)return t.points;t.points=e,this._updatePath()},redraw:function(e){if(e){var t=e.points;E.fn.redraw.call(this,e),t&&this._pointsDiffer(t)?(this.points(t),this._redrawMarkers(!0,e)):this._redrawMarkers(!1,e)}},_initPath:function(){var e=this.options;this.drawingElement=new f.Path({stroke:e.stroke}),this._fill(),this.container.append(this.drawingElement),e.points&&this._updatePath()},_pointsDiffer:function(e){var t=this.options.points,n=t.length!==e.length;if(!n)for(var i=0;i<e.length;i++)if(t[i].x!==e[i].x||t[i].y!==e[i].y){n=!0;break}return n},_updatePath:function(){for(var e,t=this.drawingElement,n=this.options.points,i=[],r=0;r<n.length;r++)e=n[r],i.push(K(e.x,e.y));t.segments.elements(i)},options:{points:[]}});o(O.fn,R);var V=M.extend({init:function(e){M.fn.init.call(this,e),this._initImage()},redraw:function(e){e&&(e.source&&this.drawingElement.src(e.source),this._diffNumericOptions(e,[w,k,"x","y"])&&this.drawingElement.rect(this._rect()),M.fn.redraw.call(this,e))},_initImage:function(){var e=this.options,t=this._rect();this.drawingElement=new f.Image(e.source,t,{})},_rect:function(){var e=j(this.options),t=new p.Point(e.x,e.y),n=new p.Size(e.width,e.height);return new p.Rect(t,n)}}),N=M.extend({init:function(e){this.children=[],M.fn.init.call(this,e),this.drawingElement=new f.Group,this._initSize()},options:{autoSize:!1},append:function(e){this.drawingElement.append(e.drawingContainer()),this.children.push(e),this._childrenChange=!0},remove:function(e){this._remove(e)&&(this._childrenChange=!0)},_remove:function(e){var t=g(e,this.children);if(t>=0)return this.drawingElement.removeAt(t),this.children.splice(t,1),!0},clear:function(){this.drawingElement.clear(),this.children=[],this._childrenChange=!0},toFront:function(e){for(var t,n=0;n<e.length;n++)t=e[n],this._remove(t)&&this.append(t)},toBack:function(e){this._reorderChildren(e,0)},toIndex:function(e,t){this._reorderChildren(e,t)},_reorderChildren:function(e,t){var n,i,r,o,a,s=this.drawingElement,l=s.children.slice(0),c=this.children,u=d(t);for(n=0;n<e.length;n++)o=(a=e[n]).drawingContainer(),(i=g(a,c))>=0&&(l.splice(i,1),c.splice(i,1),r=u?t:t[n],l.splice(r,0,o),c.splice(r,0,a));s.clear(),s.append.apply(s,l)},redraw:function(e){e&&(this._childrenChange?(this._childrenChange=!1,this._updateSize(e)||this._initSize()):this._updateSize(e),M.fn.redraw.call(this,e))},_boundingBox:function(){for(var e,t,n,i=this.children,r=0;r<i.length;r++)(t=i[r]).visible()&&!1!==t._includeInBBox&&(n=t.drawingContainer().clippedBBox(null))&&(e=e?p.Rect.union(e,n):n);return e}});o(N.fn,A);var $=N.extend({init:function(e,t){this.children=[],M.fn.init.call(this,t),this.drawingElement=new f.Layout(Y(e),t),this._initSize()},rect:function(e){if(e)this.drawingElement.rect(Y(e));else{var t=this.drawingElement.rect();if(t)return new s(t.origin.x,t.origin.y,t.size.width,t.size.height)}},reflow:function(){this.drawingElement.reflow()},redraw:function(e){n.deepExtend(this.drawingElement.options,e),N.fn.redraw.call(this,e)}}),U=E.extend({init:function(e){E.fn.init.call(this,e),this._initCircle(),this._initSize()},redraw:function(e){if(e){var t=this.options;e.center&&(o(t,{center:e.center}),this._center.move(t.center.x,t.center.y)),this._diffNumericOptions(e,["radius"])&&this._circle.setRadius(t.radius),this._updateSize(e),E.fn.redraw.call(this,e)}},_initCircle:function(){var e=this.options,t=e.width,n=e.height,i=e.radius;m(i)||(m(t)||(t=n),m(n)||(n=t),e.radius=i=Math.min(t,n)/2);var r=e.center||{x:i,y:i};this._center=new p.Point(r.x,r.y),this._circle=new p.Circle(this._center,i),this.drawingElement=new f.Circle(this._circle,{stroke:e.stroke}),this._fill()}});o(U.fn,A);var W=r.extend({init:function(e,t){t=t||{},this.element=e,this.surface=f.Surface.create(e,t),n.isFunction(this.surface.translate)&&(this.translate=this._translate),this.drawingElement=new f.Group,this._viewBox=new s(0,0,t.width,t.height),this.size(this._viewBox)},bounds:function(){var e=this.drawingElement.clippedBBox();return new s(0,0,e.width(),e.height())},size:function(e){var t=this._viewBox;return m(e)&&(t.width=e.width,t.height=e.height,this.surface.setSize(e)),{width:t.width,height:t.height}},_translate:function(e,t){var n=this._viewBox;return m(e)&&m(t)&&(n.x=e,n.y=t,this.surface.translate({x:e,y:t})),{x:n.x,y:n.y}},draw:function(){this.surface.draw(this.drawingElement)},append:function(e){return this.drawingElement.append(e.drawingContainer()),this},remove:function(e){this.drawingElement.remove(e.drawingContainer())},insertBefore:function(){},clear:function(){this.drawingElement.clear()},destroy:function(t){this.surface.destroy(),t&&e(this.element).remove()}});function j(e){return{x:e.x||0,y:e.y||0,width:e.width||0,height:e.height||0}}function q(e){if(e){var t=e;return u(t)&&(t={color:t}),t.color&&(t.color=G(t.color)),t}}function G(e){return e!=v?new f.Color(e).toHex():e}function K(e,t){return new p.Segment(new p.Point(e,t))}function Y(e){if(e)return new p.Rect([e.x,e.y],[e.width,e.height])}n.deepExtend(i,{init:function(e){n.init(e,i.ui)},diffNumericOptions:x,Element:M,Scale:C,Translation:S,Rotation:T,Circle:U,Group:N,Rectangle:z,Canvas:W,Path:L,Layout:$,Line:B,MarkerBase:P,ArrowMarker:F,CircleMarker:H,Polyline:O,CompositeTransform:D,TextBlock:I,Image:V,VisualBase:E})}(window.kendo.jQuery),function(e,t){var n=window.kendo,i=n.dataviz.diagram,r=n.Class,o=i.Group,a=i.Rect,s=i.Rectangle,l=i.Utils,c=l.isUndefined,d=i.Point,u=i.Circle,h=i.Ticker,p=n.deepExtend,f=n.ui.Movable,m=n.drawing.util,g=m.defined,v=e.inArray,_={arrow:"default",grip:"pointer",cross:"pointer",add:"pointer",move:"move",select:"pointer",south:"s-resize",east:"e-resize",west:"w-resize",north:"n-resize",rowresize:"row-resize",colresize:"col-resize"},b=10,y="Auto",w="Top",k="Right",x="Left",C="Bottom",S="dragStart",T="drag",D="dragEnd",A="itemBoundsChange",M="transparent",E="rotated",I="target",z={"-1":"source",1:I};i.Cursors=_;var P=n.Class.extend({init:function(e){this.layoutState=e,this.diagram=e.diagram},initState:function(){this.froms=[],this.tos=[],this.subjects=[],this.layoutState.nodeMap.forEach((function(e,t){var n=this.diagram.getShapeById(e);n&&(this.subjects.push(n),this.froms.push(n.bounds().topLeft()),this.tos.push(t.topLeft()))}),this)},update:function(e){if(!(this.subjects.length<=0))for(var t=0;t<this.subjects.length;t++)this.subjects[t].position(new d(this.froms[t].x+(this.tos[t].x-this.froms[t].x)*e,this.froms[t].y+(this.tos[t].y-this.froms[t].y)*e))}}),H=r.extend({init:function(e,t,n){c(n)?this.animate=!1:this.animate=n,this._initialState=e,this._finalState=t,this.title="Diagram layout"},undo:function(){this.setState(this._initialState)},redo:function(){this.setState(this._finalState)},setState:function(e){var t=e.diagram;if(this.animate){e.linkMap.forEach((function(e,n){var i=t.getShapeById(e);i.visible(!1),i&&i.points(n)}));var n=new h;n.addAdapter(new P(e)),n.onComplete((function(){e.linkMap.forEach((function(e){t.getShapeById(e).visible(!0)}))})),n.play()}else e.nodeMap.forEach((function(e,n){var i=t.getShapeById(e);i&&i.position(n.topLeft())})),e.linkMap.forEach((function(e,n){var i=t.getShapeById(e);i&&i.points(n)}))}}),F=r.extend({init:function(e){this.units=[],this.title="Composite unit",e!==t&&this.units.push(e)},add:function(e){this.units.push(e)},undo:function(){for(var e=0;e<this.units.length;e++)this.units[e].undo()},redo:function(){for(var e=0;e<this.units.length;e++)this.units[e].redo()}}),R=r.extend({init:function(e,t,n){this.item=e,this._redoSource=t,this._redoTarget=n,g(t)&&(this._undoSource=e.source()),g(n)&&(this._undoTarget=e.target()),this.title="Connection Editing"},undo:function(){this._undoSource!==t&&this.item._updateConnector(this._undoSource,"source"),this._undoTarget!==t&&this.item._updateConnector(this._undoTarget,"target"),this.item.updateModel()},redo:function(){this._redoSource!==t&&this.item._updateConnector(this._redoSource,"source"),this._redoTarget!==t&&this.item._updateConnector(this._redoTarget,"target"),this.item.updateModel()}}),L=r.extend({init:function(e,t,n){this.item=e,this._undoSource=t,this._undoTarget=n,this._redoSource=e.source(),this._redoTarget=e.target(),this.title="Connection Editing"},undo:function(){this.item._updateConnector(this._undoSource,"source"),this.item._updateConnector(this._undoTarget,"target"),this.item.updateModel()},redo:function(){this.item._updateConnector(this._redoSource,"source"),this.item._updateConnector(this._redoTarget,"target"),this.item.updateModel()}}),B=r.extend({init:function(e){this.connection=e,this.diagram=e.diagram,this.targetConnector=e.targetConnector,this.title="Delete connection"},undo:function(){this.diagram._addConnection(this.connection,!1)},redo:function(){this.diagram.remove(this.connection,!1)}}),O=r.extend({init:function(e){this.shape=e,this.diagram=e.diagram,this.title="Deletion"},undo:function(){this.diagram._addShape(this.shape,!1),this.shape.select(!1)},redo:function(){this.shape.select(!1),this.diagram.remove(this.shape,!1)}}),V=r.extend({init:function(e,t,n){this.shapes=e,this.undoStates=t,this.title="Transformation",this.redoStates=[],this.adorner=n;for(var i=0;i<this.shapes.length;i++){var r=this.shapes[i];this.redoStates.push(r.bounds())}},undo:function(){for(var e=0;e<this.shapes.length;e++){var t=this.shapes[e];t.bounds(this.undoStates[e]),t.hasOwnProperty("layout")&&t.layout(t,this.redoStates[e],this.undoStates[e]),t.updateModel()}this.adorner&&(this.adorner.refreshBounds(),this.adorner.refresh())},redo:function(){for(var e=0;e<this.shapes.length;e++){var t=this.shapes[e];t.bounds(this.redoStates[e]),t.hasOwnProperty("layout")&&t.layout(t,this.undoStates[e],this.redoStates[e]),t.updateModel()}this.adorner&&(this.adorner.refreshBounds(),this.adorner.refresh())}}),N=r.extend({init:function(e,t){this.connection=e,this.diagram=t,this.title="New connection"},undo:function(){this.diagram.remove(this.connection,!1)},redo:function(){this.diagram._addConnection(this.connection,!1)}}),$=r.extend({init:function(e,t){this.shape=e,this.diagram=t,this.title="New shape"},undo:function(){this.diagram.deselect(),this.diagram.remove(this.shape,!1)},redo:function(){this.diagram._addShape(this.shape,!1)}}),U=r.extend({init:function(e,t,n){this.initial=e,this.finalPos=t,this.diagram=n,this.title="Pan Unit"},undo:function(){this.diagram.pan(this.initial)},redo:function(){this.diagram.pan(this.finalPos)}}),W=r.extend({init:function(e,t,n){this.shapes=t,this.undoRotates=n,this.title="Rotation",this.redoRotates=[],this.redoAngle=e._angle,this.adorner=e,this.center=e._innerBounds.center();for(var i=0;i<this.shapes.length;i++){var r=this.shapes[i];this.redoRotates.push(r.rotate().angle)}},undo:function(){var e,t;for(e=0;e<this.shapes.length;e++)(t=this.shapes[e]).rotate(this.undoRotates[e],this.center,!1),t.hasOwnProperty("layout")&&t.layout(t),t.updateModel();this.adorner&&(this.adorner._initialize(),this.adorner.refresh())},redo:function(){var e,t;for(e=0;e<this.shapes.length;e++)(t=this.shapes[e]).rotate(this.redoRotates[e],this.center,!1),t.hasOwnProperty("layout")&&t.layout(t),t.updateModel();this.adorner&&(this.adorner._initialize(),this.adorner.refresh())}}),j=r.extend({init:function(e,t,n){this.diagram=e,this.indices=n,this.items=t,this.title="Rotate Unit"},undo:function(){this.diagram._toIndex(this.items,this.indices)},redo:function(){this.diagram.toFront(this.items,!1)}}),q=r.extend({init:function(e,t,n){this.diagram=e,this.indices=n,this.items=t,this.title="Rotate Unit"},undo:function(){this.diagram._toIndex(this.items,this.indices)},redo:function(){this.diagram.toBack(this.items,!1)}}),G=n.Observable.extend({init:function(e){n.Observable.fn.init.call(this,e),this.bind(this.events,e),this.stack=[],this.index=0,this.capacity=100},events:["undone","redone"],begin:function(){this.composite=new F},cancel:function(){this.composite=t},commit:function(e){this.composite.units.length>0&&this._restart(this.composite,e),this.composite=t},addCompositeItem:function(e){this.composite?this.composite.add(e):this.add(e)},add:function(e,t){this._restart(e,t)},pop:function(){this.index>0&&(this.stack.pop(),this.index--)},count:function(){return this.stack.length},undo:function(){this.index>0&&(this.index--,this.stack[this.index].undo(),this.trigger("undone"))},redo:function(){this.stack.length>0&&this.index<this.stack.length&&(this.stack[this.index].redo(),this.index++,this.trigger("redone"))},_restart:function(e,t){this.stack.splice(this.index,this.stack.length-this.index),this.stack.push(e),!1!==t?this.redo():this.index++,this.stack.length>this.capacity&&(this.stack.splice(0,this.stack.length-this.capacity),this.index=this.capacity)},clear:function(){this.stack=[],this.index=0}}),K=r.extend({init:function(e){this.toolService=e},start:function(){},move:function(){},end:function(){},tryActivate:function(){return!1},getCursor:function(){return _.arrow}}),Y=K.extend({init:function(t){var i=this,r=n.support.mobileOS?.93:.9;K.fn.init.call(i,t);var o=i.toolService.diagram,a=o.canvas,s=o.scroller=i.scroller=e(o.scrollable).kendoMobileScroller({friction:r,velocityMultiplier:5,mousewheelScrolling:!1,zoom:!1,scroll:i._move.bind(i)}).data("kendoMobileScroller");a.translate&&(i.movableCanvas=new f(a.element));var l=function(e,t,n){e.makeVirtual(),e.virtualSize(t||-2e4,n||2e4)};l(s.dimensions.x),l(s.dimensions.y),s.disable()},tryActivate:function(e,t){var n=this.toolService,i=n.diagram.options.pannable,r=t.ctrlKey;return g(i.key)&&(r=i.key&&"none"!=i.key?t[i.key+"Key"]:pe(t)&&!g(n.hoveredItem)),!1!==i&&r&&!g(n.hoveredAdorner)&&!g(n._hoveredConnector)},start:function(){this.scroller.enable()},move:function(){},_move:function(e){var t=this.toolService.diagram,n=t.canvas,i=new d(e.scrollLeft,e.scrollTop);n.translate?(t._storePan(i.times(-1)),this.movableCanvas.moveTo(i),n.translate(i.x,i.y)):i=i.plus(t._pan.times(-1)),t.trigger("pan",{pan:i})},end:function(){this.scroller.disable()},getCursor:function(){return _.move}}),Q=r.extend({init:function(e){this.toolService=e},tryActivate:function(){return!0},start:function(e,t){var n=this.toolService,i=n.diagram,r=n.hoveredItem;r&&(n.selectSingle(r,t),r.adorner&&(this.adorner=r.adorner,this.handle=this.adorner._hitTest(e))),this.handle||(this.handle=i._resizingAdorner._hitTest(e),this.handle&&(this.adorner=i._resizingAdorner)),this.adorner&&(this.adorner.isDragHandle(this.handle)&&i.trigger(S,{shapes:this.adorner.shapes,connections:[]})?(n.startPoint=e,n.end(e)):this.adorner.start(e))},move:function(e){this.adorner&&(this.adorner.move(this.handle,e),this.adorner.isDragHandle(this.handle)&&this.toolService.diagram.trigger(T,{shapes:this.adorner.shapes,connections:[]}))},end:function(){var e,n=this.toolService.diagram,i=this.adorner;i&&(i.isDragHandle(this.handle)&&n.trigger(D,{shapes:i.shapes,connections:[]})?i.cancel():(e=i.stop())&&n.undoRedoService.add(e,!1)),this.adorner=t,this.handle=t},getCursor:function(e){return this.toolService.hoveredItem?this.toolService.hoveredItem._getCursor(e):_.arrow}}),X=r.extend({init:function(e){this.toolService=e},tryActivate:function(e,t){var n=this.toolService,i=n.diagram.options.selectable,r=i&&!1!==i.multiple;return r&&(r=i.key&&"none"!=i.key?t[i.key+"Key"]:pe(t)),r&&!g(n.hoveredItem)&&!g(n.hoveredAdorner)},start:function(e){var t=this.toolService.diagram;t.deselect(),t.selector.start(e)},move:function(e){this.toolService.diagram.selector.move(e)},end:function(e,t){var n=this.toolService.diagram,i=this.toolService.hoveredItem,r=n.selector.bounds();i&&i.isSelected||t.ctrlKey||n.deselect(),r.isEmpty()||n.selectArea(r),n.selector.end()},getCursor:function(){return _.arrow}}),Z=r.extend({init:function(e){this.toolService=e,this.type="ConnectionTool"},tryActivate:function(){return this.toolService._hoveredConnector},start:function(e,t){var n=this.toolService,i=n.diagram,r=n._hoveredConnector,o=i._createConnection({},r._c,e);he(o)&&!i.trigger(S,{shapes:[],connections:[o],connectionHandle:I})&&i._addConnection(o)?(n._connectionManipulation(o,r._c.shape,!0),n._removeHover(),n.selectSingle(n.activeConnection,t),"touchmove"==t.type&&(i._cachedTouchTarget=r.visual)):(o.source(null),n.end(e))},move:function(e){var t=this.toolService,n=t.activeConnection;return n.target(e),t.diagram.trigger(T,{shapes:[],connections:[n],connectionHandle:I}),!0},end:function(e){var t,n=this.toolService,r=n.diagram,o=n.activeConnection,a=n.hoveredItem,s=n._hoveredConnector,l=r._cachedTouchTarget;o&&(t=s&&s._c!=o.sourceConnector?s._c:a&&a instanceof i.Shape?a.getConnector(y)||a.getConnector(e):e,o.target(t),r.trigger(D,{shapes:[],connections:[o],connectionHandle:I})?(r.remove(o,!1),r.undoRedoService.pop()):(o.updateModel(),r._syncConnectionChanges()),n._connectionManipulation(),l&&(r._connectorsAdorner.visual.remove(l),r._cachedTouchTarget=null))},getCursor:function(){return _.arrow}}),J=r.extend({init:function(e){this.toolService=e,this.type="ConnectionTool"},tryActivate:function(e,t){var n=this.toolService,i=n.diagram.options.selectable,r=n.hoveredItem,o=!1!==i&&r&&r.path&&!(r.isSelected&&t.ctrlKey);return o&&(this._c=r),o},start:function(e,t){var n=this.toolService,i=this._c;n.selectSingle(i,t);var r,o,a=i.adorner;a&&(r=a._hitTest(e),o=z[r]),he(i)&&a&&!n.diagram.trigger(S,{shapes:[],connections:[i],connectionHandle:o})?(this.handle=r,this.handleName=o,a.start(e)):(n.startPoint=e,n.end(e))},move:function(e){var t=this._c.adorner;if(he(this._c)&&t)return t.move(this.handle,e),this.toolService.diagram.trigger(T,{shapes:[],connections:[this._c],connectionHandle:this.handleName}),!0},end:function(e){var t=this._c,n=t.adorner,i=this.toolService.diagram;if(n&&he(t)){var r=n.stop(e);i.trigger(D,{shapes:[],connections:[t],connectionHandle:this.handleName})?r.undo():(i.undoRedoService.add(r,!1),t.updateModel(),i._syncConnectionChanges())}},getCursor:function(){return _.move}});function ee(e,t){return t.charCodeAt(0)==e||t.toUpperCase().charCodeAt(0)==e}var te=r.extend({init:function(e){this.diagram=e,this.tools=[new Y(this),new J(this),new Z(this),new X(this),new Q(this)],this.activeTool=t},start:function(e,t){return t=p({},t),this.activeTool&&this.activeTool.end(e,t),this._updateHoveredItem(e),this._activateTool(e,t),this.activeTool.start(e,t),this._updateCursor(e),this.diagram.focus(),this.diagram.canvas.surface.suspendTracking(),this.startPoint=e,!0},move:function(e,t){t=p({},t);var n=!0;return this.activeTool&&(n=this.activeTool.move(e,t)),n&&this._updateHoveredItem(e),this._updateCursor(e),!0},end:function(e,n){return n=p({},n),this.activeTool&&this.activeTool.end(e,n),this.diagram.canvas.surface.resumeTracking(),this.activeTool=t,this._updateCursor(e),!0},keyDown:function(e,t){var n=this.diagram;if(!(t=p({ctrlKey:!1,metaKey:!1,altKey:!1},t)).ctrlKey&&!t.metaKey||t.altKey){if(46===e||8===e){var i=this.diagram._triggerRemove(n.select());return i.length&&(this.diagram.remove(i,!0),this.diagram._syncChanges(),this.diagram._destroyToolBar()),!0}if(27===e)return this._discardNewConnection(),n.deselect(),n._destroyToolBar(),!0}else{if(ee(e,"a"))return n.selectAll(),n._destroyToolBar(),!0;if(ee(e,"z"))return n.undo(),n._destroyToolBar(),!0;if(ee(e,"y"))return n.redo(),n._destroyToolBar(),!0;ee(e,"c")?(n.copy(),n._destroyToolBar()):ee(e,"x")?(n.cut(),n._destroyToolBar()):ee(e,"v")?(n.paste(),n._destroyToolBar()):ee(e,"l")?(n.layout(),n._destroyToolBar()):ee(e,"d")&&(n._destroyToolBar(),n.copy(),n.paste())}},wheel:function(e,t){var i=this.diagram,r=t.delta,o=i.zoom(),a=i.options,s=a.zoomRate,l={point:e,meta:t,zoom:o};if(!i.trigger("zoomStart",l))return r<0?o+=s:o-=s,o=n.drawing.util.round(Math.max(a.zoomMin,Math.min(a.zoomMax,o)),2),l.zoom=o,i.zoom(o,l),i.trigger("zoomEnd",l),!0},setTool:function(e,t){e.toolService=this,this.tools[t]=e},selectSingle:function(e,t){var n=this.diagram,i=n.options.selectable;if(i&&!e.isSelected&&!1!==e.options.selectable){var r=t.ctrlKey&&!1!==i.multiple;n.select(e,{addToSelection:r})}},_discardNewConnection:function(){this.newConnection&&(this.diagram.remove(this.newConnection),this.newConnection=t)},_activateTool:function(e,t){for(var n=0;n<this.tools.length;n++){var i=this.tools[n];if(i.tryActivate(e,t)){this.activeTool=i;break}}},_updateCursor:function(e){var t=this.diagram.element,n=this.activeTool?this.activeTool.getCursor(e):this.hoveredAdorner?this.hoveredAdorner._getCursor(e):this.hoveredItem?this.hoveredItem._getCursor(e):_.arrow;t.css({cursor:n})},_connectionManipulation:function(e,n,i){this.activeConnection=e,this.disabledShape=n,this.newConnection=i?this.activeConnection:t},_updateHoveredItem:function(e){var n=this._hitTest(e),i=this.diagram;n==this.hoveredItem||this.disabledShape&&n==this.disabledShape||(this.hoveredItem&&(i.trigger("mouseLeave",{item:this.hoveredItem}),this.hoveredItem._hover(!1)),n&&n.options.enable?(i.trigger("mouseEnter",{item:n}),this.hoveredItem=n,this.hoveredItem._hover(!0)):this.hoveredItem=t)},_removeHover:function(){this.hoveredItem&&(this.hoveredItem._hover(!1),this.hoveredItem=t)},_hitTest:function(e){var n,r,o,a=this.diagram;if(this._hoveredConnector&&(this._hoveredConnector._hover(!1),this._hoveredConnector=t),a._connectorsAdorner._visible&&(n=a._connectorsAdorner._hitTest(e)))return n;if(n=this.diagram._resizingAdorner._hitTest(e)){if(this.hoveredAdorner=a._resizingAdorner,0!==n.x||0!==n.y)return;n=t}else this.hoveredAdorner=t;if(!this.activeTool||"ConnectionTool"!==this.activeTool.type){var s=[];for(o=0;o<a._selectedItems.length;o++)(r=a._selectedItems[o])instanceof i.Connection&&s.push(r);n=this._hitTestItems(s,e)}return n||this._hitTestElements(e)},_hitTestElements:function(e){var t,n=this.diagram,i=this._hitTestItems(n.shapes,e),r=this._hitTestItems(n.connections,e);if((!this.activeTool||"ConnectionTool"!=this.activeTool.type)&&i&&r&&!function(e,t){for(var n,i,r,o=0;o<e.connectors.length;o++)if(i=(n=e.connectors[o]).position(),(r=new a(i.x,i.y)).inflate(b,b),r.contains(t))return n}(i,e)){var o=n.mainLayer;t=v(i.visual,o.children)>v(r.visual,o.children)?i:r}return t||i||r},_hitTestItems:function(e,t){var n,i;for(n=e.length-1;n>=0;n--)if(i=e[n]._hitTest(t))return i}}),ne=n.Class.extend({init:function(){}}),ie=ne.extend({init:function(e){ne.fn.init.call(this),this.connection=e},hitTest:function(e){return!!this.getBounds().inflate(b).contains(e)&&i.Geometry.distanceToPolyline(e,this.connection.allPoints())<b},getBounds:function(){for(var e=this.connection.allPoints(),t=e[0],n=e[e.length-1],i=Math.max(t.x,n.x),r=Math.min(t.x,n.x),o=Math.min(t.y,n.y),s=Math.max(t.y,n.y),l=1;l<e.length-1;++l)i=Math.max(i,e[l].x),r=Math.min(r,e[l].x),o=Math.min(o,e[l].y),s=Math.max(s,e[l].y);return new a(r,o,i-r,s-o)}}),re=ie.extend({init:function(e){ie.fn.init.call(this),this.connection=e},route:function(){}}),oe=ie.extend({SAME_SIDE_DISTANCE_RATIO:5,init:function(e){ie.fn.init.call(this),this.connection=e},routePoints:function(e,t,n,i){return n&&i?this._connectorPoints(e,t,n,i):this._floatingPoints(e,t,n)},route:function(){var e=this.connection._resolvedSourceConnector,t=this.connection._resolvedTargetConnector,n=this.connection.sourcePoint(),i=this.connection.targetPoint(),r=this.routePoints(n,i,e,t);this.connection.points(r)},_connectorSides:[{name:"Top",axis:"y",boundsPoint:"topLeft",secondarySign:1},{name:"Left",axis:"x",boundsPoint:"topLeft",secondarySign:1},{name:"Bottom",axis:"y",boundsPoint:"bottomRight",secondarySign:-1},{name:"Right",axis:"x",boundsPoint:"bottomRight",secondarySign:-1}],_connectorSide:function(e,t){for(var n,i,r,o,a=e.position(),s=e.shape.bounds(E),l={topLeft:s.topLeft(),bottomRight:s.bottomRight()},c=this._connectorSides,d=m.MAX_NUM,u=0;u<c.length;u++)r=(o=c[u]).axis,(n=Math.round(Math.abs(a[r]-l[o.boundsPoint][r])))<d?(d=n,i=o):n===d&&(a[r]-t[r])*o.secondarySign>(a[i.axis]-t[i.axis])*i.secondarySign&&(i=o);return i.name},_sameSideDistance:function(e){var t=e.shape.bounds(E);return Math.min(t.width,t.height)/this.SAME_SIDE_DISTANCE_RATIO},_connectorPoints:function(e,t,n,i){var r,o,a=this._connectorSide(n,t),s=this._connectorSide(i,e),l=t.x-e.x,c=t.y-e.y,u=this._sameSideDistance(n),h=[];return a===w||a==C?s==w||s==C?a==s?(o=a==w?Math.min(e.y,t.y)-u:Math.max(e.y,t.y)+u,h=[new d(e.x,o),new d(t.x,o)]):h=[new d(e.x,e.y+c/2),new d(t.x,e.y+c/2)]:h=[new d(e.x,t.y)]:s==x||s==k?a==s?(r=a==x?Math.min(e.x,t.x)-u:Math.max(e.x,t.x)+u,h=[new d(r,e.y),new d(r,t.y)]):h=[new d(e.x+l/2,e.y),new d(e.x+l/2,e.y+c)]:h=[new d(t.x,e.y)],h},_floatingPoints:function(e,t,n){for(var i,r,o=n?this._connectorSide(n,t):null,a=this._startHorizontal(e,t,o),s=[e,e,t,t],l=t.x-e.x,c=t.y-e.y,u=s.length,h=1;h<u-1;++h)a?h%2!=0?(i=l/(u/2),r=0):(i=0,r=c/((u-1)/2)):h%2!=0?(i=0,r=c/(u/2)):(i=l/((u-1)/2),r=0),s[h]=new d(s[h-1].x+i,s[h-1].y+r);return h--,s[u-2]=a&&h%2!=0||!a&&h%2==0?new d(s[u-1].x,s[u-2].y):new d(s[u-2].x,s[u-1].y),[s[1],s[2]]},_startHorizontal:function(e,t,n){return null!==n&&(n===k||n===x)||Math.abs(e.x-t.x)>Math.abs(e.y-t.y)}}),ae=r.extend({init:function(e,t){var n=this;n.diagram=e,n.options=p({},n.options,t),n.visual=new o,n.diagram._adorners.push(n)},refresh:function(){}}),se=ae.extend({init:function(e,t){var n,i=this;i.connection=e,n=i.connection.diagram,i._ts=n.toolService,ae.fn.init.call(i,n,t);var r=i.connection.sourcePoint(),o=i.connection.targetPoint();i.spVisual=new u(p(i.options.handles,{center:r})),i.epVisual=new u(p(i.options.handles,{center:o})),i.visual.append(i.spVisual),i.visual.append(i.epVisual)},options:{handles:{}},_getCursor:function(){return _.move},start:function(e){switch(this.handle=this._hitTest(e),this.startPoint=e,this._initialSource=this.connection.source(),this._initialTarget=this.connection.target(),this.handle){case-1:this.connection.targetConnector&&this._ts._connectionManipulation(this.connection,this.connection.targetConnector.shape);break;case 1:this.connection.sourceConnector&&this._ts._connectionManipulation(this.connection,this.connection.sourceConnector.shape)}},move:function(e,t){switch(e){case-1:this.connection.source(t);break;case 1:this.connection.target(t);break;default:var n=t.minus(this.startPoint);this.startPoint=t,this.connection.sourceConnector||this.connection.source(this.connection.sourcePoint().plus(n)),this.connection.targetConnector||this.connection.target(this.connection.targetPoint().plus(n))}return this.refresh(),!0},stop:function(e){var n,r=this.diagram.toolService,o=r.hoveredItem;return n=r._hoveredConnector?r._hoveredConnector._c:o&&o instanceof i.Shape?o.getConnector(y)||o.getConnector(e):e,-1===this.handle?this.connection.source(n):1===this.handle&&this.connection.target(n),this.handle=t,this._ts._connectionManipulation(),new L(this.connection,this._initialSource,this._initialTarget)},_hitTest:function(e){var t=this.connection.sourcePoint(),n=this.connection.targetPoint(),i=this.options.handles.width/2+b,r=this.options.handles.height/2+b,o=t.distanceTo(e),s=n.distanceTo(e),l=new a(t.x,t.y).inflate(i,r).contains(e),c=new a(n.x,n.y).inflate(i,r).contains(e),d=0;return l&&(!c||o<s)?d=-1:c&&(!l||s<o)&&(d=1),d},refresh:function(){this.spVisual.redraw({center:this.diagram.modelToLayer(this.connection.sourcePoint())}),this.epVisual.redraw({center:this.diagram.modelToLayer(this.connection.targetPoint())})}}),le=ae.extend({init:function(e,t){var n=this;ae.fn.init.call(n,e,t),n._refreshHandler=function(e){e.item==n.shape&&n.refresh()}},show:function(e){var t,n,i,r=this;for(r._visible=!0,r.shape=e,r.diagram.bind(A,r._refreshHandler),t=e.connectors.length,r.connectors=[],r._clearVisual(),n=0;n<t;n++)i=new ue(e.connectors[n]),r.connectors.push(i),r.visual.append(i.visual);r.visual.visible(!0),r.refresh()},_clearVisual:function(){var e=this;e.diagram._cachedTouchTarget?e._keepCachedTouchTarget():e.visual.clear()},_keepCachedTouchTarget:function(){for(var e=this,t=e.visual.children,n=t.length,i=v(e.diagram._cachedTouchTarget,t),r=n-1;r>=0;r--)r!=i&&e.visual.remove(t[r])},destroy:function(){var e=this;e.diagram.unbind(A,e._refreshHandler),e.shape=t,e._visible=t,e.visual.visible(!1)},_hitTest:function(e){var t,n;for(n=0;n<this.connectors.length;n++)if((t=this.connectors[n])._hitTest(e)){t._hover(!0),this.diagram.toolService._hoveredConnector=t;break}},refresh:function(){if(this.shape){var t=this.shape.bounds();t=this.diagram.modelToLayer(t),this.visual.position(t.topLeft()),e.each(this.connectors,(function(){this.refresh()}))}}});var ce=ae.extend({init:function(e,t){var n=this;ae.fn.init.call(n,e,t),n._manipulating=!1,n.map=[],n.shapes=[],n._initSelection(),n._createHandles(),n.redraw(),n.diagram.bind("select",(function(e){n._initialize(e.selected)})),n._refreshHandler=function(){n._internalChange||(n.refreshBounds(),n.refresh())},n._rotatedHandler=function(){1==n.shapes.length&&(n._angle=n.shapes[0].rotate().angle),n._refreshHandler()},n.diagram.bind(A,n._refreshHandler).bind("itemRotate",n._rotatedHandler),n.refreshBounds(),n.refresh()},options:{handles:{fill:{color:"#fff"},stroke:{color:"#282828"},height:7,width:7,hover:{fill:{color:"#282828"},stroke:{color:"#282828"}}},selectable:{stroke:{color:"#778899",width:1,dashType:"dash"},fill:{color:M}},offset:10},_initSelection:function(){var e=this,t=e.diagram.options.selectable,n=p({},e.options.selectable,t);e.rect=new s(n),e.visual.append(e.rect)},_resizable:function(){return this.options.editable&&!1!==this.options.editable.resize},_handleOptions:function(){return(this.options.editable.resize||{}).handles||this.options.handles},_createHandles:function(){var e,t,n,i;if(this._resizable())for(e=this._handleOptions(),i=-1;i<=1;i++)for(n=-1;n<=1;n++)0===i&&0===n||((t=new s(e)).drawingElement._hover=this._hover.bind(this),this.map.push({x:i,y:n,visual:t}),this.visual.append(t))},bounds:function(e){if(!e)return this._bounds;this._innerBounds=e.clone(),this._bounds=this.diagram.modelToLayer(e).inflate(this.options.offset,this.options.offset)},_hitTest:function(e){var t,n,i,r,o=this.diagram.modelToLayer(e),a=this.map.length;if(this._angle&&(o=o.clone().rotate(this._angle,this._bounds.center())),this._resizable())for(t=0;t<a;t++)if(r=this.map[t],n=new d(r.x,r.y),(i=this._getHandleBounds(n)).offset(this._bounds.x,this._bounds.y),i.contains(o))return n;if(this._bounds.contains(o))return new d(0,0)},_getHandleBounds:function(e){if(this._resizable()){var t=this._handleOptions(),n=t.width,i=t.height,r=new a(0,0,n,i);return e.x<0?r.x=-n/2:0===e.x?r.x=Math.floor(this._bounds.width/2)-n/2:e.x>0&&(r.x=this._bounds.width+1-n/2),e.y<0?r.y=-i/2:0===e.y?r.y=Math.floor(this._bounds.height/2)-i/2:e.y>0&&(r.y=this._bounds.height+1-i/2),r}},_getCursor:function(e){var t=this._hitTest(e);if(t&&t.x>=-1&&t.x<=1&&t.y>=-1&&t.y<=1&&this._resizable()){var n=this._angle;if(n&&(t.rotate(n,new d(0,0)),t=new d(Math.round(t.x),Math.round(t.y))),-1==t.x&&-1==t.y)return"nw-resize";if(1==t.x&&1==t.y)return"se-resize";if(-1==t.x&&1==t.y)return"sw-resize";if(1==t.x&&-1==t.y)return"ne-resize";if(0===t.x&&-1==t.y)return"n-resize";if(0===t.x&&1==t.y)return"s-resize";if(1==t.x&&0===t.y)return"e-resize";if(-1==t.x&&0===t.y)return"w-resize"}return this._manipulating?_.move:_.select},_initialize:function(){var e,t,n=this,r=n.diagram.select();for(n.shapes=[],e=0;e<r.length;e++)(t=r[e])instanceof i.Shape&&(n.shapes.push(t),t._rotationOffset=new d);n._angle=1==n.shapes.length?n.shapes[0].rotate().angle:0,n._startAngle=n._angle,n._rotates(),n._positions(),n.refreshBounds(),n.refresh(),n.redraw()},_rotates:function(){var e,t,n=this;for(n.initialRotates=[],e=0;e<n.shapes.length;e++)t=n.shapes[e],n.initialRotates.push(t.rotate().angle)},_positions:function(){var e,t,n=this;for(n.initialStates=[],e=0;e<n.shapes.length;e++)t=n.shapes[e],n.initialStates.push(t.bounds())},_hover:function(e,t){if(this._resizable()){var n=this._handleOptions(),i=n.hover,r=n.stroke,o=n.fill;e&&l.isDefined(i.stroke)&&(r=p({},r,i.stroke)),e&&l.isDefined(i.fill)&&(o=i.fill),t.stroke(r.color,r.width,r.opacity),t.fill(o.color,o.opacity)}},start:function(e){this._sp=e,this._cp=e,this._lp=e,this._manipulating=!0,this._internalChange=!0,this.shapeStates=[];for(var t=0;t<this.shapes.length;t++){var n=this.shapes[t];this.shapeStates.push(n.bounds())}},redraw:function(){var e,t=this._resizable();for(e=0;e<this.map.length;e++)this.map[e].visual.visible(t)},angle:function(e){return g(e)&&(this._angle=e),this._angle},rotate:function(){var e=this._innerBounds.center(),t=this.angle();this._internalChange=!0;for(var n=0;n<this.shapes.length;n++){var i=this.shapes[n];t=(t+this.initialRotates[n]-this._startAngle)%360,i.rotate(t,e)}this.refresh()},move:function(e,t){var n,i,r,o,s,c,u,h,p,f,m,g=new d,v=new d,_=0;if(-2===e.y&&-1===e.x){for(o=this._innerBounds.center(),this._angle=this._truncateAngle(l.findAngle(o,t)),c=0;c<this.shapes.length;c++)s=this.shapes[c],u=(this._angle+this.initialRotates[c]-this._startAngle)%360,s.rotate(u,o),s.hasOwnProperty("layout")&&s.layout(s),this._rotating=!0;this.refresh()}else{if(this.shouldSnap()){var b=this._truncateDistance(t.minus(this._lp));if(0===b.x&&0===b.y)return void(this._cp=t);n=b,this._lp=new d(this._lp.x+b.x,this._lp.y+b.y)}else n=t.minus(this._cp);for(this.isDragHandle(e)?(v=g=n,i=!0):(this._angle&&n.rotate(this._angle,new d(0,0)),-1==e.x?g.x=n.x:1==e.x&&(v.x=n.x),-1==e.y?g.y=n.y:1==e.y&&(v.y=n.y)),i||(p=function(e,t){var n;return-1==e.x&&-1==e.y?n=t.bottomRight():1==e.x&&1==e.y?n=t.topLeft():-1==e.x&&1==e.y?n=t.topRight():1==e.x&&-1==e.y?n=t.bottomLeft():0===e.x&&-1==e.y?n=t.bottom():0===e.x&&1==e.y?n=t.top():1==e.x&&0===e.y?n=t.left():-1==e.x&&0===e.y&&(n=t.right()),n}(e,this._innerBounds),f=(this._innerBounds.width+n.x*e.x)/this._innerBounds.width,m=(this._innerBounds.height+n.y*e.y)/this._innerBounds.height),c=0;c<this.shapes.length;c++){if(r=(s=this.shapes[c]).bounds(),i){if(!he(s))continue;h=this._displaceBounds(r,g,v,i)}else{(h=r.clone()).scale(f,m,p,this._innerBounds.center(),s.rotate().angle);var y=h.center();y.rotate(-this._angle,r.center()),h=new a(y.x-h.width/2,y.y-h.height/2,h.width,h.height)}if(h.width>=s.options.minWidth&&h.height>=s.options.minHeight){var w=r;s.bounds(h),s.hasOwnProperty("layout")&&s.layout(s,w,h),w.width===h.width&&w.height===h.height||s.rotate(s.rotate().angle),_+=1}}_&&(_==c?(h=this._displaceBounds(this._innerBounds,g,v,i),this.bounds(h)):this.refreshBounds(),this.refresh()),this._positions()}this._cp=t},isDragHandle:function(e){return 0===e.x&&0===e.y},cancel:function(){for(var e=this.shapes,n=this.shapeStates,i=0;i<e.length;i++)e[i].bounds(n[i]);this.refreshBounds(),this.refresh(),this._manipulating=t,this._internalChange=t,this._rotating=t},_truncatePositionToGuides:function(e){return this.diagram.ruler?this.diagram.ruler.truncatePositionToGuides(e):e},_truncateSizeToGuides:function(e){return this.diagram.ruler?this.diagram.ruler.truncateSizeToGuides(e):e},_truncateAngle:function(e){var t=this.snapOptions(),n=Math.max(t.angle||10,5);return t?Math.floor(e%360/n)*n:e%360},_truncateDistance:function(e){if(e instanceof i.Point)return new i.Point(this._truncateDistance(e.x),this._truncateDistance(e.y));var t=this.snapOptions()||{},n=Math.max(t.size||10,5);return t?Math.floor(e/n)*n:e},snapOptions:function(){return((this.diagram.options.editable||{}).drag||{}).snap||{}},shouldSnap:function(){var e=this.diagram.options.editable,t=(e||{}).drag,n=(t||{}).snap;return!1!==e&&!1!==t&&!1!==n},_displaceBounds:function(e,t,n,i){var r,o=e.topLeft().plus(t),s=e.bottomRight().plus(n),l=a.fromPoints(o,s);return i||((r=l.center()).rotate(e.center(),-this._angle),l=new a(r.x-l.width/2,r.y-l.height/2,l.width,l.height)),l},stop:function(){var e,n,i;if(this._cp!=this._sp)if(this._rotating)e=new W(this,this.shapes,this.initialRotates),this._rotating=!1;else if(this._diffStates()){if(this.diagram.ruler)for(n=0;n<this.shapes.length;n++){var r=(i=this.shapes[n]).bounds();r=this._truncateSizeToGuides(this._truncatePositionToGuides(r)),i.bounds(r),this.refreshBounds(),this.refresh()}for(n=0;n<this.shapes.length;n++)(i=this.shapes[n]).updateModel();e=new V(this.shapes,this.shapeStates,this),this.diagram._syncShapeChanges()}return this._manipulating=t,this._internalChange=t,this._rotating=t,e},_diffStates:function(){for(var e=this.shapes,t=this.shapeStates,n=0;n<e.length;n++)if(!e[n].bounds().equals(t[n]))return!0;return!1},refreshBounds:function(){var e=1==this.shapes.length?this.shapes[0].bounds().clone():this.diagram.boundingBox(this.shapes,!0);this.bounds(e)},refresh:function(){var t,n,i=this;if(this.shapes.length>0){n=this.bounds(),this.visual.visible(!0),this.visual.position(n.topLeft()),e.each(this.map,(function(){t=i._getHandleBounds(new d(this.x,this.y)),this.visual.position(t.topLeft())})),this.visual.position(n.topLeft());var r=new d(n.width/2,n.height/2);if(this.visual.rotate(this._angle,r),this.rect.redraw({width:n.width,height:n.height}),this.rotationThumb){var o=this.options.editable.rotate.thumb;this._rotationThumbBounds=new a(n.center().x,n.y+o.y,0,0).inflate(o.width),this.rotationThumb.redraw({x:n.width/2-o.width/2})}}else this.visual.visible(!1)}}),de=r.extend({init:function(e){var t=e.options.selectable;this.options=p({},this.options,t),this.visual=new s(this.options),this.diagram=e},options:{stroke:{color:"#778899",width:1,dashType:"dash"},fill:{color:M}},start:function(e){this._sp=this._ep=e,this.refresh(),this.diagram._adorn(this,!0)},end:function(){this._sp=this._ep=t,this.diagram._adorn(this,!1)},bounds:function(e){return e&&(this._bounds=e),this._bounds},move:function(e){this._ep=e,this.refresh()},refresh:function(){if(this._sp){var e=a.fromPoints(this.diagram.modelToLayer(this._sp),this.diagram.modelToLayer(this._ep));this.bounds(a.fromPoints(this._sp,this._ep)),this.visual.position(e.topLeft()),this.visual.redraw({height:e.height+1,width:e.width+1})}}}),ue=r.extend({init:function(e){this.options=p({},e.options),this._c=e,this.visual=new u(this.options),this.refresh()},_hover:function(e){var t=this.options,n=t.hover,i=t.stroke,r=t.fill;e&&l.isDefined(n.stroke)&&(i=p({},i,n.stroke)),e&&l.isDefined(n.fill)&&(r=n.fill),this.visual.redraw({stroke:i,fill:r})},refresh:function(){var e=this._c.shape.diagram.modelToView(this._c.position()),t=e.minus(this._c.shape.bounds("transformed").topLeft()),n=new a(e.x,e.y,0,0);n.inflate(this.options.width/2,this.options.height/2),this._visualBounds=n,this.visual.redraw({center:new d(t.x,t.y)})},_hitTest:function(e){var t=this._c.shape.diagram.modelToView(e);return this._visualBounds.contains(t)}});function he(e){var t=e.options.editable;return t&&!1!==t.drag}function pe(e){return!1===e.ctrlKey&&!1===e.altKey&&!1===e.shiftKey}p(i,{CompositeUnit:F,TransformUnit:V,PanUndoUnit:U,AddShapeUnit:$,AddConnectionUnit:N,DeleteShapeUnit:O,DeleteConnectionUnit:B,ConnectionEditAdorner:se,ConnectionTool:Z,ConnectorVisual:ue,UndoRedoService:G,ResizingAdorner:ce,Selector:de,ToolService:te,ConnectorsAdorner:le,LayoutUndoUnit:H,ConnectionEditUnit:R,ToFrontUnit:j,ToBackUnit:q,ConnectionRouterBase:ne,PolylineRouter:re,CascadingRouter:oe,SelectionTool:X,ScrollerTool:Y,PointerTool:Q,ConnectionEditTool:J,RotateUnit:W})}(window.kendo.jQuery),function(e){var t=window.kendo,n=t.dataviz.diagram,i=n.Graph,r=n.Node,o=n.Link,a=t.deepExtend,s=n.Size,l=n.Rect,c=n.Dictionary,d=n.Set,u=n.Graph,h=n.Utils,p=n.Point,f=1e-6,m=Math.PI/180,g=h.contains,v=e.grep,_=t.Class.extend({defaultOptions:{type:"Tree",subtype:"Down",roots:null,animate:!1,limitToView:!1,friction:.9,nodeDistance:50,iterations:300,horizontalSeparation:90,verticalSeparation:50,underneathVerticalTopOffset:15,underneathHorizontalOffset:15,underneathVerticalSeparation:15,grid:{width:1500,offsetX:50,offsetY:50,componentSpacingX:20,componentSpacingY:20},layerSeparation:50,layeredIterations:2,startRadialAngle:0,endRadialAngle:360,radialSeparation:150,radialFirstLevelSeparation:200,keepComponentsInOneRadialLayout:!1,ignoreContainers:!0,layoutContainerChildren:!1,ignoreInvisible:!0,animateTransitions:!1},init:function(){},gridLayoutComponents:function(e){if(!e)throw"No components supplied.";h.forEach(e,(function(e){e.calcBounds()})),e.sort((function(e,t){return t.bounds.width-e.bounds.width}));for(var t,n=this.options.grid.width,i=this.options.grid.componentSpacingX,r=this.options.grid.componentSpacingY,o=0,a=this.options.grid.offsetX,s=a,l=this.options.grid.offsetY,c=[],d=[];e.length>0;){s>=n&&(s=a,l+=o+r,o=0);var u=e.pop();for(this.moveToOffset(u,new p(s,l)),t=0;t<u.nodes.length;t++)d.push(u.nodes[t]);for(t=0;t<u.links.length;t++)c.push(u.links[t]);var f=u.bounds,m=f.height;(m<=0||isNaN(m))&&(m=0);var g=f.width;(g<=0||isNaN(g))&&(g=0),m>=o&&(o=m),s+=g+i}return{nodes:d,links:c}},moveToOffset:function(e,t){var n,i,r=e.bounds,o=t.x-r.x,a=t.y-r.y;for(n=0;n<e.nodes.length;n++){var s=e.nodes[n],c=s.bounds();0===c.width&&0===c.height&&0===c.x&&0===c.y&&(c=new l(0,0,0,0)),c.x+=o,c.y+=a,s.bounds(c)}for(n=0;n<e.links.length;n++){var d=e.links[n];if(d.points){var u=[],h=d.points;for(i=0;i<h.length;i++){var f=h[i];f.x+=o,f.y+=a,u.push(f)}d.points=u}}return this.currentHorizontalOffset+=r.width+this.options.grid.offsetX,new p(o,a)},transferOptions:function(e){this.options=t.deepExtend({},this.defaultOptions),h.isUndefined(e)||(this.options=t.deepExtend(this.options,e||{}))}}),b=t.Class.extend({init:function(e){this.nodeMap=new c,this.shapeMap=new c,this.nodes=[],this.edges=[],this.edgeMap=new c,this.finalNodes=[],this.finalLinks=[],this.ignoredConnections=[],this.ignoredShapes=[],this.hyperMap=new c,this.hyperTree=new i,this.finalGraph=null,this.diagram=e},convert:function(e){if(h.isUndefined(this.diagram))throw"No diagram to convert.";return this.options=t.deepExtend({ignoreInvisible:!0,ignoreContainers:!0,layoutContainerChildren:!1},e||{}),this.clear(),this._renormalizeShapes(),this._renormalizeConnections(),this.finalNodes=new c(this.nodes),this.finalLinks=new c(this.edges),this.finalGraph=new i,this.finalNodes.forEach((function(e){this.finalGraph.addNode(e)}),this),this.finalLinks.forEach((function(e){this.finalGraph.addExistingLink(e)}),this),this.finalGraph},mapConnection:function(e){return this.edgeMap.get(e.id)},mapShape:function(e){return this.nodeMap.get(e.id)},getEdge:function(e,t){return h.first(e.links,(function(n){return n.getComplement(e)===t}))},clear:function(){this.finalGraph=null,this.hyperTree=!this.options.ignoreContainers&&this.options.layoutContainerChildren?new u:null,this.hyperMap=!this.options.ignoreContainers&&this.options.layoutContainerChildren?new c:null,this.nodeMap=new c,this.shapeMap=new c,this.nodes=[],this.edges=[],this.edgeMap=new c,this.ignoredConnections=[],this.ignoredShapes=[],this.finalNodes=[],this.finalLinks=[]},listToRoot:function(e){var t=[],n=e.container;if(!n)return t;for(t.push(n);n.parentContainer;)n=n.parentContainer,t.push(n);return t.reverse(),t},firstNonIgnorableContainer:function(e){return e.isContainer&&!this._isIgnorableItem(e)?e:e.parentContainer?this.firstNonIgnorableContainer(e.parentContainer):null},isContainerConnection:function(e,t){return!(!e.isContainer||!this.isDescendantOf(e,t))||t.isContainer&&this.isDescendantOf(t,e)},isDescendantOf:function(e,t){if(!e.isContainer)throw"Expecting a container.";if(e===t)return!1;if(g(e.children,t))return!0;for(var n=[],i=0,r=e.children.length;i<r;i++){var o=e.children[i];o.isContainer&&this.isDescendantOf(o,t)&&n.push(o)}return n.length>0},isIgnorableItem:function(e){return this.options.ignoreInvisible?(!e.isCollapsed||!this._isVisible(e))&&!(!e.isCollapsed&&this._isVisible(e)):e.isCollapsed&&!this._isTop(e)},isShapeMapped:function(e){return e.isCollapsed&&!this._isVisible(e)&&!this._isTop(e)},leastCommonAncestor:function(e,t){if(!e)throw"Parameter should not be null.";if(!t)throw"Parameter should not be null.";if(!this.hyperTree)throw"No hypertree available.";var n=this.listToRoot(e),i=this.listToRoot(t),r=null;if(h.isEmpty(n)||h.isEmpty(i))return this.hyperTree.root.data;for(var o=n[0],a=i[0],s=0;o===a&&(r=n[s],!(++s>=n.length||s>=i.length));)o=n[s],a=i[s];return r?v(this.hyperTree.nodes,(function(e){return e.data.container===r})):this.hyperTree.root.data},_isTop:function(e){return!e.parentContainer},_isVisible:function(e){return!!e.visible()&&(e.parentContainer?this._isVisible(e.parentContainer):e.visible())},_isCollapsed:function(e){return!(!e.isContainer||!e.isCollapsed)||e.parentContainer&&this._isCollapsed(e.parentContainer)},_renormalizeShapes:function(){if(!this.options.ignoreContainers)throw"Containers are not supported yet, but stay tuned.";for(var e=0,t=this.diagram.shapes.length;e<t;e++){var n=this.diagram.shapes[e];if(this.options.ignoreInvisible&&!this._isVisible(n)||n.isContainer)this.ignoredShapes.push(n);else{var i=new r(n.id,n);i.isVirtual=!1,this.nodeMap.add(n.id,i),this.nodes.push(i)}}},_renormalizeConnections:function(){if(0!==this.diagram.connections.length)for(var e=0,t=this.diagram.connections.length;e<t;e++){var n=this.diagram.connections[e];if(this.isIgnorableItem(n))this.ignoredConnections.push(n);else{var i=n.sourceConnector?n.sourceConnector.shape:null,r=n.targetConnector?n.targetConnector.shape:null;if(i&&r)if(!g(this.ignoredShapes,i)||this.shapeMap.containsKey(i))if(!g(this.ignoredShapes,r)||this.shapeMap.containsKey(r)){this.shapeMap.containsKey(i)&&(i=this.shapeMap[i]),this.shapeMap.containsKey(r)&&(r=this.shapeMap[r]);var a=this.mapShape(i),s=this.mapShape(r);if(a===s||this.areConnectedAlready(a,s))this.ignoredConnections.push(n);else{if(null===a||null===s)throw"A shape was not mapped to a node.";if(!this.options.ignoreContainers)throw"Containers are not supported yet, but stay tuned.";if(a.isVirtual||s.isVirtual)this.ignoredConnections.push(n);else{var l=new o(a,s,n.id,n);this.edgeMap.add(n.id,l),this.edges.push(l)}}}else this.ignoredConnections.push(n);else this.ignoredConnections.push(n);else this.ignoredConnections.push(n)}}},areConnectedAlready:function(e,t){return h.any(this.edges,(function(n){return n.source===e&&n.target===t||n.source===t&&n.target===e}))}}),y=_.extend({init:function(e){if(_.fn.init.call(this),h.isUndefined(e))throw"Diagram is not specified.";this.diagram=e},layout:function(e){this.transferOptions(e);var t=new b(this.diagram).convert(e);if(!t.isEmpty()){var i=t.getConnectedComponents();if(!h.isEmpty(i)){for(var r=0;r<i.length;r++){var o=i[r];this.layoutGraph(o,e)}var a=this.gridLayoutComponents(i);return new n.LayoutState(this.diagram,a)}}},layoutGraph:function(e,t){h.isDefined(t)&&this.transferOptions(t),this.graph=e;var n=9*this.options.nodeDistance;this.temperature=n;var i=this._expectedBounds();this.width=i.width,this.height=i.height;for(var r=0;r<this.options.iterations;r++)this.refineStage=r>=5*this.options.iterations/6,this.tick(),this.temperature=this.refineStage?n/30:n*(1-r/(2*this.options.iterations))},tick:function(){var e;for(e=0;e<this.graph.nodes.length;e++)this._repulsion(this.graph.nodes[e]);for(e=0;e<this.graph.links.length;e++)this._attraction(this.graph.links[e]);for(e=0;e<this.graph.nodes.length;e++){var t=this.graph.nodes[e],n=Math.sqrt(t.dx*t.dx+t.dy*t.dy);if(0===n)return;t.x+=Math.min(n,this.temperature)*t.dx/n,t.y+=Math.min(n,this.temperature)*t.dy/n,this.options.limitToView&&(t.x=Math.min(this.width,Math.max(t.width/2,t.x)),t.y=Math.min(this.height,Math.max(t.height/2,t.y)))}},_shake:function(e){var t=Math.random()*this.options.nodeDistance/4,n=2*Math.random()*Math.PI;e.x+=t*Math.cos(n),e.y-=t*Math.sin(n)},_InverseSquareForce:function(e,t,n){var i;if(this.refineStage){var r=t.x-n.x,o=t.y-n.y,a=t.width/2,s=t.height/2,l=n.width/2,c=n.height/2;i=Math.pow(r,2)/Math.pow(a+l+this.options.nodeDistance,2)+Math.pow(o,2)/Math.pow(s+c+this.options.nodeDistance,2)}else i=Math.pow(e,2)/Math.pow(this.options.nodeDistance,2);return 4*i/3},_SquareForce:function(e,t,n){return 1/this._InverseSquareForce(e,t,n)},_repulsion:function(e){e.dx=0,e.dy=0,h.forEach(this.graph.nodes,(function(t){if(t!==e){for(;e.x===t.x&&e.y===t.y;)this._shake(t);var n=e.x-t.x,i=e.y-t.y,r=Math.sqrt(n*n+i*i),o=2*this._SquareForce(r,e,t);e.dx+=n/r*o,e.dy+=i/r*o}}),this)},_attraction:function(e){var t=e.target,n=e.source;if(n!==t){for(;n.x===t.x&&n.y===t.y;)this._shake(t);var i=n.x-t.x,r=n.y-t.y,o=Math.sqrt(i*i+r*r),a=5*this._InverseSquareForce(o,n,t),s=i/o*a,l=r/o*a;t.dx+=s,t.dy+=l,n.dx-=s,n.dy-=l}},_expectedBounds:function(){var e,t=this.graph.nodes.length;if(0===t)return e;var n=(e=h.fold(this.graph.nodes,(function(e,t){var n=t.width*t.height;return n>0?e+=Math.sqrt(n):0}),0,this))/t*Math.ceil(Math.sqrt(t));return{width:4*(n*Math.sqrt(1.5)),height:4*(n/Math.sqrt(1.5))}}}),w=t.Class.extend({init:function(e){this.center=null,this.options=e},layout:function(e,t){if(this.graph=e,this.graph.nodes&&0!==this.graph.nodes.length){if(!g(this.graph.nodes,t))throw"The given root is not in the graph.";this.center=t,this.graph.cacheRelationships(),this.layoutSwitch()}},layoutLeft:function(e){this.setChildrenDirection(this.center,"Left",!1),this.setChildrenLayout(this.center,"Default",!1);var t,n,i,r=0,o=0;for(n=0;n<e.length;n++){(i=e[n]).TreeDirection="Left";var a=this.measure(i,s.Empty);o=Math.max(o,a.Width),r+=a.height+this.options.verticalSeparation}r-=this.options.verticalSeparation;var l=this.center.x-this.options.horizontalSeparation;for(t=this.center.y+(this.center.height-r)/2,n=0;n<e.length;n++){i=e[n];var c=new p(l-i.Size.width,t);this.arrange(i,c),t+=i.Size.height+this.options.verticalSeparation}},layoutRight:function(e){this.setChildrenDirection(this.center,"Right",!1),this.setChildrenLayout(this.center,"Default",!1);var t,n,i,r=0,o=0;for(n=0;n<e.length;n++){(i=e[n]).TreeDirection="Right";var a=this.measure(i,s.Empty);o=Math.max(o,a.Width),r+=a.height+this.options.verticalSeparation}r-=this.options.verticalSeparation;var l=this.center.x+this.options.horizontalSeparation+this.center.width;for(t=this.center.y+(this.center.height-r)/2,n=0;n<e.length;n++){i=e[n];var c=new p(l,t);this.arrange(i,c),t+=i.Size.height+this.options.verticalSeparation}},layoutUp:function(e){this.setChildrenDirection(this.center,"Up",!1),this.setChildrenLayout(this.center,"Default",!1);var t,n,i,r=0;for(i=0;i<e.length;i++){(n=e[i]).TreeDirection="Up",r+=this.measure(n,s.Empty).width+this.options.horizontalSeparation}r-=this.options.horizontalSeparation;var o=this.center.x+this.center.width/2-r/2;for(i=0;i<e.length;i++){n=e[i],t=this.center.y-this.options.verticalSeparation-n.Size.height;var a=new p(o,t);this.arrange(n,a),o+=n.Size.width+this.options.horizontalSeparation}},layoutDown:function(e){var t,n;this.setChildrenDirection(this.center,"Down",!1),this.setChildrenLayout(this.center,"Default",!1);var i,r=0;for(n=0;n<e.length;n++){(t=e[n]).treeDirection="Down",r+=this.measure(t,s.Empty).width+this.options.horizontalSeparation}r-=this.options.horizontalSeparation;var o=this.center.x+this.center.width/2-r/2;for(i=this.center.y+this.options.verticalSeparation+this.center.height,n=0;n<e.length;n++){t=e[n];var a=new p(o,i);this.arrange(t,a),o+=t.Size.width+this.options.horizontalSeparation}},layoutRadialTree:function(){this.setChildrenDirection(this.center,"Radial",!1),this.setChildrenLayout(this.center,"Default",!1),this.previousRoot=null;var e=this.options.startRadialAngle*m,t=this.options.endRadialAngle*m;if(t<=e)throw"Final angle should not be less than the start angle.";this.maxDepth=0,this.origin=new p(this.center.x,this.center.y),this.calculateAngularWidth(this.center,0),this.maxDepth>0&&this.radialLayout(this.center,this.options.radialFirstLevelSeparation,e,t),this.center.Angle=t-e},tipOverTree:function(e,t){h.isUndefined(t)&&(t=0),this.setChildrenDirection(this.center,"Down",!1),this.setChildrenLayout(this.center,"Default",!1),this.setChildrenLayout(this.center,"Underneath",!1,t);var n,i,r,o=0;for(r=0;r<e.length;r++){(i=e[r]).TreeDirection="Down",o+=this.measure(i,s.Empty).width+this.options.horizontalSeparation}o-=this.options.horizontalSeparation,o-=e[e.length-1].width,o+=e[e.length-1].associatedShape.bounds().width;var a=this.center.x+this.center.width/2-o/2;for(n=this.center.y+this.options.verticalSeparation+this.center.height,r=0;r<e.length;r++){i=e[r];var l=new p(a,n);this.arrange(i,l),a+=i.Size.width+this.options.horizontalSeparation}},calculateAngularWidth:function(e,t){t>this.maxDepth&&(this.maxDepth=t);var n=0,i=0===t?0:Math.sqrt(2e6)/t;if(e.children.length>0){for(var r=0,o=e.children.length;r<o;r++){var a=e.children[r];n+=this.calculateAngularWidth(a,t+1)}n=Math.max(i,n)}else n=i;return e.sectorAngle=n,n},sortChildren:function(e){var t,n=0;if(e.parents.length>1)throw"Node is not part of a tree.";var i=e.parents[0];if(i){var r=new p(i.x,i.y),o=new p(e.x,e.y);n=this.normalizeAngle(Math.atan2(r.y-o.y,r.x-o.x))}var a=e.children.length;if(0===a)return null;var s=[],l=[];for(t=0;t<a;++t){var c=e.children[t],d=new p(c.x,c.y);l[t]=t,s[t]=this.normalizeAngle(-n+Math.atan2(d.y-d.y,d.x-d.x))}h.bisort(s,l);var u=[],f=e.children;for(t=0;t<a;++t)u.push(f[l[t]]);return u},normalizeAngle:function(e){for(;e>2*Math.PI;)e-=2*Math.PI;for(;e<0;)e+=2*Math.PI;return e},radialLayout:function(e,t,n,i){for(var r=i-n,o=r/2,a=e.sectorAngle,s=0,l=this.sortChildren(e),c=0,d=l.length;c<d;c++){var u=l[c],h=u,p=h.sectorAngle/a;u.children.length>0&&this.radialLayout(u,t+this.options.radialSeparation,n+s*r,n+(s+p)*r),this.setPolarLocation(u,t,n+s*r+p*o),h.angle=p*r,s+=p}},setPolarLocation:function(e,t,n){e.x=this.origin.x+t*Math.cos(n),e.y=this.origin.y+t*Math.sin(n),e.BoundingRectangle=new l(e.x,e.y,e.width,e.height)},setChildrenDirection:function(e,t,n){var i=e.treeDirection;this.graph.depthFirstTraversal(e,(function(e){e.treeDirection=t})),n||(e.treeDirection=i)},setChildrenLayout:function(e,t,n,i){h.isUndefined(i)&&(i=0);var r=e.childrenLayout;i>0?(this.graph.assignLevels(e),this.graph.depthFirstTraversal(e,(function(e){e.level>=i+1&&(e.childrenLayout=t)}))):(this.graph.depthFirstTraversal(e,(function(e){e.childrenLayout=t})),n||(e.childrenLayout=r))},measure:function(e,t){var n,i=0,r=0,o=new s(0,0);if(!e)throw"";var a=e.associatedShape.bounds(),l=a.width,c=a.height;if(1!==e.parents.length)throw"Node not in a spanning tree.";var d=e.parents[0];if("Undefined"===e.treeDirection&&(e.treeDirection=d.treeDirection),h.isEmpty(e.children))o=new s(Math.abs(l)<f?50:l,Math.abs(c)<f?25:c);else if(1===e.children.length){switch(e.treeDirection){case"Radial":n=this.measure(e.children[0],t),i=l+this.options.radialSeparation*Math.cos(e.AngleToParent)+n.width,r=c+Math.abs(this.options.radialSeparation*Math.sin(e.AngleToParent))+n.height;break;case"Left":case"Right":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":i=l+(n=this.measure(e.children[0],t)).width+this.options.underneathHorizontalOffset,r=c+this.options.underneathVerticalTopOffset+n.height;break;case"Default":n=this.measure(e.children[0],t),i=l+this.options.horizontalSeparation+n.width,r=Math.max(c,n.height);break;default:throw"Unhandled TreeDirection in the Radial layout measuring."}break;case"Up":case"Down":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":n=this.measure(e.children[0],t),i=Math.max(l,n.width+this.options.underneathHorizontalOffset),r=c+this.options.underneathVerticalTopOffset+n.height;break;case"Default":n=this.measure(e.children[0],t),r=c+this.options.verticalSeparation+n.height,i=Math.max(l,n.width);break;default:throw"Unhandled TreeDirection in the Down layout measuring."}break;default:throw"Unhandled TreeDirection in the layout measuring."}o=new s(i,r)}else{var u,p;switch(e.treeDirection){case"Left":case"Right":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(i=l,r=c+this.options.underneathVerticalTopOffset,u=0;u<e.children.length;u++)p=e.children[u],n=this.measure(p,t),i=Math.max(i,n.width+this.options.underneathHorizontalOffset),r+=n.height+this.options.underneathVerticalSeparation;r-=this.options.underneathVerticalSeparation;break;case"Default":for(i=l,r=0,u=0;u<e.children.length;u++)p=e.children[u],n=this.measure(p,t),i=Math.max(i,l+this.options.horizontalSeparation+n.width),r+=n.height+this.options.verticalSeparation;r-=this.options.verticalSeparation;break;default:throw"Unhandled TreeDirection in the Right layout measuring."}break;case"Up":case"Down":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(i=l,r=c+this.options.underneathVerticalTopOffset,u=0;u<e.children.length;u++)p=e.children[u],n=this.measure(p,t),i=Math.max(i,n.width+this.options.underneathHorizontalOffset),r+=n.height+this.options.underneathVerticalSeparation;r-=this.options.underneathVerticalSeparation;break;case"Default":for(i=0,r=0,u=0;u<e.children.length;u++)p=e.children[u],i+=(n=this.measure(p,t)).width+this.options.horizontalSeparation,r=Math.max(r,n.height+this.options.verticalSeparation+c);i-=this.options.horizontalSeparation;break;default:throw"Unhandled TreeDirection in the Down layout measuring."}break;default:throw"Unhandled TreeDirection in the layout measuring."}o=new s(i,r)}return e.SectorAngle=Math.sqrt(i*i/4+r*r/4),e.Size=o,o},arrange:function(e,t){var n,i,r,o,a,s,c,d=e.associatedShape.bounds(),u=d.width,m=d.height;if(h.isEmpty(e.children))e.x=t.x,e.y=t.y,e.BoundingRectangle=new l(t.x,t.y,u,m);else switch(e.treeDirection){case"Left":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(c=t,e.x=c.x,e.y=c.y,e.BoundingRectangle=new l(e.x,e.y,e.width,e.height),s=t.y+m+this.options.underneathVerticalTopOffset,n=0;n<r.children.length;n++)r=r.children[n],a=c.x-r.associatedShape.width-this.options.underneathHorizontalOffset,i=new p(a,s),this.arrange(r,i),s+=r.Size.height+this.options.underneathVerticalSeparation;break;case"Default":for(c=new p(t.x+e.Size.width-u,t.y+(e.Size.height-m)/2),e.x=c.x,e.y=c.y,e.BoundingRectangle=new l(e.x,e.y,e.width,e.height),a=c.x-this.options.horizontalSeparation,s=t.y,n=0;n<e.children.length;n++)r=e.children[n],i=new p(a-r.Size.width,s),this.arrange(r,i),s+=r.Size.height+this.options.verticalSeparation;break;default:throw"Unsupported TreeDirection"}break;case"Right":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(c=t,e.x=c.x,e.y=c.y,e.BoundingRectangle=new l(e.x,e.y,e.width,e.height),a=t.x+u+this.options.underneathHorizontalOffset,s=t.y+m+this.options.underneathVerticalTopOffset,n=0;n<e.children.length;n++)r=e.children[n],i=new p(a,s),this.arrange(r,i),s+=r.Size.height+this.options.underneathVerticalSeparation;break;case"Default":for(c=new p(t.x,t.y+(e.Size.height-m)/2),e.x=c.x,e.y=c.y,e.BoundingRectangle=new l(e.x,e.y,e.width,e.height),a=t.x+u+this.options.horizontalSeparation,s=t.y,n=0;n<e.children.length;n++)r=e.children[n],i=new p(a,s),this.arrange(r,i),s+=r.Size.height+this.options.verticalSeparation;break;default:throw"Unsupported TreeDirection"}break;case"Up":if(c=new p(t.x+(e.Size.width-u)/2,t.y+e.Size.height-m),e.x=c.x,e.y=c.y,e.BoundingRectangle=new l(e.x,e.y,e.width,e.height),Math.abs(c.x-t.x)<f){for(o=0,n=0;n<e.children.length;n++)o+=e.children[n].Size.width+this.options.horizontalSeparation;o-=this.options.horizontalSeparation,a=t.x+(u-o)/2}else a=t.x;for(n=0;n<e.children.length;n++)r=e.children[n],s=c.y-this.options.verticalSeparation-r.Size.height,i=new p(a,s),this.arrange(r,i),a+=r.Size.width+this.options.horizontalSeparation;break;case"Down":switch(e.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(c=t,e.x=c.x,e.y=c.y,e.BoundingRectangle=new l(e.x,e.y,e.width,e.height),a=t.x+this.options.underneathHorizontalOffset,s=t.y+m+this.options.underneathVerticalTopOffset,n=0;n<e.children.length;n++)r=e.children[n],i=new p(a,s),this.arrange(r,i),s+=r.Size.height+this.options.underneathVerticalSeparation;break;case"Default":if(c=new p(t.x+(e.Size.width-u)/2,t.y),e.x=c.x,e.y=c.y,e.BoundingRectangle=new l(e.x,e.y,e.width,e.height),Math.abs(c.x-t.x)<f){for(o=0,n=0;n<e.children.length;n++)o+=e.children[n].Size.width+this.options.horizontalSeparation;o-=this.options.horizontalSeparation,a=t.x+(u-o)/2}else a=t.x;for(n=0;n<e.children.length;n++)r=e.children[n],s=c.y+this.options.verticalSeparation+m,i=new p(a,s),this.arrange(r,i),a+=r.Size.width+this.options.horizontalSeparation;break;default:throw"Unsupported TreeDirection"}break;case"None":break;default:throw"Unsupported TreeDirection"}},layoutSwitch:function(){if(this.center&&!h.isEmpty(this.center.children)){var e,t,n,i,r=this.options.subtype;h.isUndefined(r)&&(r="Down");var o=this.center.children;switch(r.toLowerCase()){case"radial":case"radialtree":this.layoutRadialTree();break;case"mindmaphorizontal":case"mindmap":e=this.center.children,1===this.center.children.length?this.layoutRight(e):(i=o.length/2,t=v(this.center.children,(function(e){return h.indexOf(o,e)<i})),n=v(this.center.children,(function(e){return h.indexOf(o,e)>=i})),this.layoutLeft(t),this.layoutRight(n));break;case"mindmapvertical":e=this.center.children,1===this.center.children.length?this.layoutDown(e):(i=o.length/2,t=v(this.center.children,(function(e){return h.indexOf(o,e)<i})),n=v(this.center.children,(function(e){return h.indexOf(o,e)>=i})),this.layoutUp(t),this.layoutDown(n));break;case"right":this.layoutRight(this.center.children);break;case"left":this.layoutLeft(this.center.children);break;case"up":case"bottom":this.layoutUp(this.center.children);break;case"down":case"top":this.layoutDown(this.center.children);break;case"tipover":case"tipovertree":if(this.options.tipOverTreeStartLevel<0)throw"The tip-over level should be a positive integer.";this.tipOverTree(this.center.children,this.options.tipOverTreeStartLevel)}}}}),k=_.extend({init:function(e){if(_.fn.init.call(this),h.isUndefined(e))throw"No diagram specified.";this.diagram=e},layout:function(e){this.transferOptions(e);var t=new b(this.diagram);this.graph=t.convert();var i=this.layoutComponents();return new n.LayoutState(this.diagram,i)},layoutComponents:function(){if(!this.graph.isEmpty()){var e=this.graph.getConnectedComponents();if(!h.isEmpty(e)){for(var t=new w(this.options),n=[],i=0;i<e.length;i++){var r=e[i],o=this.getTree(r);if(!o)throw"Failed to find a spanning tree for the component.";var a=o.root,s=o.tree;t.layout(s,a),n.push(s)}return this.gridLayoutComponents(n)}}},getTree:function(e){var t=null;if(this.options.roots&&this.options.roots.length>0)for(var n=0,i=e.nodes.length;n<i;n++)for(var r=e.nodes[n],o=0;o<this.options.roots.length;o++){if(this.options.roots[o]===r.associatedShape){t=r;break}}if(!t&&!(t=e.root()))throw"Unable to find a root for the tree.";return this.getTreeForRoot(e,t)},getTreeForRoot:function(e,t){var n=e.getSpanningTree(t);return h.isUndefined(n)||n.isEmpty()?null:{tree:n,root:n.root}}}),x=_.extend({init:function(e){if(_.fn.init.call(this),h.isUndefined(e))throw"Diagram is not specified.";this.diagram=e},layout:function(e){this.transferOptions(e);var t=new b(this.diagram).convert(e);if(!t.isEmpty()){var i=t.getConnectedComponents();if(!h.isEmpty(i)){for(var r=0;r<i.length;r++){var o=i[r];this.layoutGraph(o,e)}var a=this.gridLayoutComponents(i);return new n.LayoutState(this.diagram,a)}}},_initRuntimeProperties:function(){for(var e=0;e<this.graph.nodes.length;e++){var t=this.graph.nodes[e];t.layer=-1,t.downstreamLinkCount=0,t.upstreamLinkCount=0,t.isVirtual=!1,t.uBaryCenter=0,t.dBaryCenter=0,t.upstreamPriority=0,t.downstreamPriority=0,t.gridPosition=0}},_prepare:function(e){var t,n,i,r,o,a,s=[],l=new c,d=0;for(h.forEach(e.nodes,(function(e){0===e.incoming.length&&(l.set(e,0),s.push(e))}));s.length>0;)for(o=s.shift(),t=0;t<o.outgoing.length;t++)a=(i=o.outgoing[t]).target,r=l.containsKey(a)?Math.max(l.get(o)+1,l.get(a)):l.get(o)+1,l.set(a,r),r>d&&(d=r),g(s,a)||s.push(a);var u,p=l.keys();p.sort((function(e,t){var n=l.get(e),i=l.get(t);return h.sign(i-n)}));for(var f=0;f<p.length;++f){var m=p[f],v=Number.MAX_VALUE;if(0!==m.outgoing.length){for(n=0;n<m.outgoing.length;++n)i=m.outgoing[n],v=Math.min(v,l.get(i.target));v>1&&l.set(m,v-1)}}for(this.layers=[],t=0;t<d+1;t++)(u=[]).linksTo={},this.layers.push(u);for(l.forEach((function(e,t){e.layer=t,this.layers[t].push(e)}),this),n=0;n<this.layers.length;n++)for(u=this.layers[n],t=0;t<u.length;t++)u[t].gridPosition=t},layoutGraph:function(e,t){if(h.isUndefined(e))throw"No graph given or graph analysis of the diagram failed.";h.isDefined(t)&&this.transferOptions(t),this.graph=e,e.setItemIndices();var n=e.makeAcyclic();this._initRuntimeProperties(),this._prepare(e,t),this._dummify(),this._optimizeCrossings(),this._swapPairs(),this.arrangeNodes(),this._moveThingsAround(),this._dedummify(),h.forEach(n,(function(e){e.points&&e.points.reverse()}))},setMinDist:function(e,t,n){var i=e.layer,r=e.layerIndex;this.minDistances[i][r]=n},getMinDist:function(e,t){for(var n=0,i=e.layerIndex,r=t.layerIndex,o=e.layer,a=Math.min(i,r),s=Math.max(i,r),l=a;l<s;++l)n+=this.minDistances[o][l];return n},placeLeftToRight:function(e){for(var t,n,i=new c,r=0;r<this.layers.length;++r){var o=e[r];if(o){for(t=0;t<o.length;t++)n=o[t],i.containsKey(n)||this.placeLeft(n,i,r);var a=Number.POSITIVE_INFINITY;for(t=0;t<o.length;t++){n=o[t];var s=this.rightSibling(n);s&&this.nodeLeftClass.get(s)!==r&&(a=Math.min(a,i.get(s)-i.get(n)-this.getMinDist(n,s)))}if(a===Number.POSITIVE_INFINITY){var l=[];for(t=0;t<o.length;t++){n=o[t];var d=[];h.addRange(d,this.upNodes.get(n)),h.addRange(d,this.downNodes.get(n));for(var u=0;u<d.length;u++){var p=d[u];this.nodeLeftClass.get(p)<r&&l.push(i.get(p)-i.get(n))}}l.sort(),a=0===l.length?0:l.length%2==1?l[this.intDiv(l.length,2)]:(l[this.intDiv(l.length,2)-1]+l[this.intDiv(l.length,2)])/2}for(t=0;t<o.length;t++)n=o[t],i.set(n,i.get(n)+a)}}return i},placeRightToLeft:function(e){for(var t,n,i=new c,r=0;r<this.layers.length;++r){var o=e[r];if(o){for(t=0;t<o.length;t++)n=o[t],i.containsKey(n)||this.placeRight(n,i,r);var a=Number.NEGATIVE_INFINITY;for(t=0;t<o.length;t++){n=o[t];var s=this.leftSibling(n);s&&this.nodeRightClass.get(s)!==r&&(a=Math.max(a,i.get(s)-i.get(n)+this.getMinDist(s,n)))}if(a===Number.NEGATIVE_INFINITY){var l=[];for(t=0;t<o.length;t++){n=o[t];var d=[];h.addRange(d,this.upNodes.get(n)),h.addRange(d,this.downNodes.get(n));for(var u=0;u<d.length;u++){var p=d[u];this.nodeRightClass.get(p)<r&&l.push(i.get(n)-i.get(p))}}l.sort(),a=0===l.length?0:l.length%2==1?l[this.intDiv(l.length,2)]:(l[this.intDiv(l.length,2)-1]+l[this.intDiv(l.length,2)])/2}for(t=0;t<o.length;t++)n=o[t],i.set(n,i.get(n)+a)}}return i},_getLeftWing:function(){var e={value:null},t=this.computeClasses(e,1);return this.nodeLeftClass=e.value,t},_getRightWing:function(){var e={value:null},t=this.computeClasses(e,-1);return this.nodeRightClass=e.value,t},computeClasses:function(e,t){for(var n=0,i=e.value=new c,r=0;r<this.layers.length;++r){n=r;for(var o=this.layers[r],a=1===t?0:o.length-1;a>=0&&a<o.length;a+=t){var s=o[a];if(i.containsKey(s))n=i.get(s);else if(i.set(s,n),s.isVirtual)for(var l=this._nodesInLink(s),d=0;d<l.length;d++){var u=l[d];i.set(u,n)}}}for(var h=[],p=0;p<this.layers.length;p++)h.push(null);return i.forEach((function(e,t){null===h[t]&&(h[t]=[]),h[t].push(e)})),h},_isVerticalLayout:function(){return"up"===this.options.subtype.toLowerCase()||"down"===this.options.subtype.toLowerCase()||"vertical"===this.options.subtype.toLowerCase()},_isHorizontalLayout:function(){return"right"===this.options.subtype.toLowerCase()||"left"===this.options.subtype.toLowerCase()||"horizontal"===this.options.subtype.toLowerCase()},_isIncreasingLayout:function(){return"right"===this.options.subtype.toLowerCase()||"down"===this.options.subtype.toLowerCase()},_moveThingsAround:function(){var e,t,n,i,r,o;for(t=0;t<this.layers.length;++t)(i=this.layers[t]).sort(this._gridPositionComparer);for(this.minDistances=[],t=0;t<this.layers.length;++t)for(i=this.layers[t],this.minDistances[t]=[],r=0;r<i.length;++r)(n=i[r]).layerIndex=r,this.minDistances[t][r]=this.options.nodeDistance,r<i.length-1&&(this._isVerticalLayout()?this.minDistances[t][r]+=(n.width+i[r+1].width)/2:this.minDistances[t][r]+=(n.height+i[r+1].height)/2);for(this.downNodes=new c,this.upNodes=new c,h.forEach(this.graph.nodes,(function(e){this.downNodes.set(e,[]),this.upNodes.set(e,[])}),this),h.forEach(this.graph.links,(function(e){var t=e.source,n=e.target,i=null,r=null;t.layer>n.layer?(i=e.source,r=e.target):(r=e.source,i=e.target),this.downNodes.get(r).push(i),this.upNodes.get(i).push(r)}),this),this.downNodes.forEachValue((function(e){e.sort(this._gridPositionComparer)}),this),this.upNodes.forEachValue((function(e){e.sort(this._gridPositionComparer)}),this),t=0;t<this.layers.length-1;++t)for(i=this.layers[t],o=0;o<i.length-1;o++){var a=i[o];if(a.isVirtual){var s=this.downNodes.get(a)[0];if(s.isVirtual)for(r=o+1;r<i.length;++r)if((n=i[r]).isVirtual){var l=this.downNodes.get(n)[0];if(l.isVirtual&&s.gridPosition>l.gridPosition){var d=s.gridPosition;s.gridPosition=l.gridPosition,l.gridPosition=d;var u=s.layerIndex,p=l.layerIndex;this.layers[t+1][u]=l,this.layers[t+1][p]=s,s.layerIndex=p,l.layerIndex=u}}}}var f=this._getLeftWing(),m=this._getRightWing(),g=this.placeLeftToRight(f),v=this.placeRightToLeft(m),_=new c;h.forEach(this.graph.nodes,(function(e){_.set(e,(g.get(e)+v.get(e))/2)}));var b=new c,y=new c;for(t=0;t<this.layers.length;++t){i=this.layers[t];var w=-1;for(r=0;r<i.length;++r)n=i[r],b.set(n,0),y.set(n,!1),n.isVirtual&&(-1===w||w===r-1||(b.set(i[w],0),_.get(n)-_.get(i[w])===this.getMinDist(i[w],n)?y.set(i[w],!0):y.set(i[w],!1)),w=r)}h.forEach([1,-1],(function(t){for(var n=1===t?0:this.layers.length-1;n>=0&&n<this.layers.length;n+=t){var i=this.layers[n],r=this._firstVirtualNode(i),o=null,a=null;if(-1!==r)for(o=i[r],a=[],e=0;e<r;e++)a.push(i[e]);else o=null,a=i;if(a.length>0){for(this._sequencer(_,null,o,t,a),e=0;e<a.length-1;++e)this.setMinDist(a[e],a[e+1],_.get(a[e+1])-_.get(a[e]));o&&this.setMinDist(a[a.length-1],o,_.get(o)-_.get(a[a.length-1]))}for(;o;){var s=this.nextVirtualNode(i,o);if(s){if(b.get(o)===t){r=o.layerIndex;var l=s.layerIndex;for(a=[],e=r+1;e<l;e++)a.push(i[e]);a.length>0&&this._sequencer(_,o,s,t,a),y.set(o,!0)}}else{for(r=o.layerIndex,a=[],e=r+1;e<i.length;e++)a.push(i[e]);if(a.length>0){for(this._sequencer(_,o,null,t,a),e=0;e<a.length-1;++e)this.setMinDist(a[e],a[e+1],_.get(a[e+1])-_.get(a[e]));this.setMinDist(o,a[0],_.get(a[0])-_.get(o))}}o=s}this.adjustDirections(n,t,b,y)}}),this);var k,x,C=this._isIncreasingLayout()?0:this.layers.length-1,S=this._isIncreasingLayout()?1:-1,T=0;function D(e,t){for(var n=Number.MIN_VALUE,i=0;i<e.length;++i){var r=e[i];n=t._isVerticalLayout()?Math.max(n,r.height):Math.max(n,r.width)}return n}for(e=C;k=e,(x=this)._isIncreasingLayout()?k<x.layers.length:k>=0;e+=S){var A=D(i=this.layers[e],this);for(r=0;r<i.length;++r)n=i[r],this._isVerticalLayout()?(n.x=_.get(n),n.y=T+A/2):(n.x=T+A/2,n.y=_.get(n));T+=this.options.layerSeparation+A}},adjustDirections:function(e,t,n,i){if(!(e+t<0||e+t>=this.layers.length))for(var r=null,o=null,a=this.layers[e+t],s=0;s<a.length;++s){var l=a[s];if(l.isVirtual){var c=this.getNeighborOnLayer(l,e);if(c.isVirtual){if(r){for(var d=i.get(o),u=this.layers[e],h=o.layerIndex,p=c.layerIndex,f=h+1;f<p;++f)u[f].isVirtual&&(d=d&&i.get(u[f]));if(d){n.set(r,t);for(var m=r.layerIndex,g=l.layerIndex,v=m+1;v<g;++v)a[v].isVirtual&&n.set(a[v],t)}}r=l,o=c}}}},getNeighborOnLayer:function(e,t){var n=this.upNodes.get(e)[0];return n.layer===t||(n=this.downNodes.get(e)[0]).layer===t?n:null},_sequencer:function(e,t,n,i,r){if(1===r.length&&this._sequenceSingle(e,t,n,i,r[0]),r.length>1){var o=r.length,a=this.intDiv(o,2);this._sequencer(e,t,n,i,r.slice(0,a)),this._sequencer(e,t,n,i,r.slice(a)),this.combineSequences(e,t,n,i,r)}},_sequenceSingle:function(e,t,n,i,r){var o=-1===i?this.downNodes.get(r):this.upNodes.get(r),a=o.length;0!==a&&(a%2==1?e.set(r,e.get(o[this.intDiv(a,2)])):e.set(r,(e.get(o[this.intDiv(a,2)-1])+e.get(o[this.intDiv(a,2)]))/2),t&&e.set(r,Math.max(e.get(r),e.get(t)+this.getMinDist(t,r))),n&&e.set(r,Math.min(e.get(r),e.get(n)-this.getMinDist(r,n))))},combineSequences:function(e,t,n,i,r){var o,a,s,l,c,d,u=r.length,h=this.intDiv(u,2),p=[];for(o=0;o<h;++o){for(a=0,l=-1===i?this.downNodes.get(r[o]):this.upNodes.get(r[o]),s=0;s<l.length;++s)c=l[s],e.get(c)>=e.get(r[o])?a++:(a--,p.push({k:e.get(c)+this.getMinDist(r[o],r[h-1]),v:2}));p.push({k:e.get(r[o])+this.getMinDist(r[o],r[h-1]),v:a})}t&&p.push({k:e.get(t)+this.getMinDist(t,r[h-1]),v:Number.MAX_VALUE}),p.sort(this._positionDescendingComparer);var f=[];for(o=h;o<u;++o){for(a=0,l=-1===i?this.downNodes.get(r[o]):this.upNodes.get(r[o]),s=0;s<l.length;++s)c=l[s],e.get(c)<=e.get(r[o])?a++:(a--,f.push({k:e.get(c)-this.getMinDist(r[o],r[h]),v:2}));f.push({k:e.get(r[o])-this.getMinDist(r[o],r[h]),v:a})}n&&f.push({k:e.get(n)-this.getMinDist(n,r[h]),v:Number.MAX_VALUE}),f.sort(this._positionAscendingComparer);for(var m=0,g=0,v=this.getMinDist(r[h-1],r[h]);e.get(r[h])-e.get(r[h-1])<v;)if(m<g){if(0===p.length){e.set(r[h-1],e.get(r[h])-v);break}m+=(d=p.shift()).v,e.set(r[h-1],d.k),e.set(r[h-1],Math.max(e.get(r[h-1]),e.get(r[h])-v))}else{if(0===f.length){e.set(r[h],e.get(r[h-1])+v);break}g+=(d=f.shift()).v,e.set(r[h],d.k),e.set(r[h],Math.min(e.get(r[h]),e.get(r[h-1])+v))}for(o=h-2;o>=0;o--)e.set(r[o],Math.min(e.get(r[o]),e.get(r[h-1])-this.getMinDist(r[o],r[h-1])));for(o=h+1;o<u;o++)e.set(r[o],Math.max(e.get(r[o]),e.get(r[h])+this.getMinDist(r[o],r[h])))},placeLeft:function(e,t,n){var i=Number.NEGATIVE_INFINITY;h.forEach(this._getComposite(e),(function(e){var r=this.leftSibling(e);r&&this.nodeLeftClass.get(r)===this.nodeLeftClass.get(e)&&(t.containsKey(r)||this.placeLeft(r,t,n),i=Math.max(i,t.get(r)+this.getMinDist(r,e)))}),this),i===Number.NEGATIVE_INFINITY&&(i=0),h.forEach(this._getComposite(e),(function(e){t.set(e,i)}))},placeRight:function(e,t,n){var i=Number.POSITIVE_INFINITY;h.forEach(this._getComposite(e),(function(e){var r=this.rightSibling(e);r&&this.nodeRightClass.get(r)===this.nodeRightClass.get(e)&&(t.containsKey(r)||this.placeRight(r,t,n),i=Math.min(i,t.get(r)-this.getMinDist(e,r)))}),this),i===Number.POSITIVE_INFINITY&&(i=0),h.forEach(this._getComposite(e),(function(e){t.set(e,i)}))},leftSibling:function(e){var t=this.layers[e.layer],n=e.layerIndex;return 0===n?null:t[n-1]},rightSibling:function(e){var t=this.layers[e.layer],n=e.layerIndex;return n===t.length-1?null:t[n+1]},_getComposite:function(e){return e.isVirtual?this._nodesInLink(e):[e]},arrangeNodes:function(){var e,t,n,i,r;for(t=0;t<this.layers.length;t++)for(i=this.layers[t],n=0;n<i.length;n++)(r=i[n]).upstreamPriority=r.upstreamLinkCount,r.downstreamPriority=r.downstreamLinkCount;for(var o=0;o<2;o++){for(e=this.layers.length-1;e>=1;e--)this.layoutLayer(!1,e);for(e=0;e<this.layers.length-1;e++)this.layoutLayer(!0,e)}var a=Number.MAX_VALUE;for(t=0;t<this.layers.length;t++)for(i=this.layers[t],n=0;n<i.length;n++)r=i[n],a=Math.min(a,r.gridPosition);if(a<0)for(t=0;t<this.layers.length;t++)for(i=this.layers[t],n=0;n<i.length;n++)(r=i[n]).gridPosition=r.gridPosition-a},layoutLayer:function(e,t){var n,i;i=e?this.layers[n=t+1]:this.layers[n=t-1];for(var r=[],o=0;o<i.length;o++)r.push(i[o]);r.sort((function(e,t){var n=(e.upstreamPriority+e.downstreamPriority)/2,i=(t.upstreamPriority+t.downstreamPriority)/2;return Math.abs(n-i)<1e-4?0:n<i?1:-1})),h.forEach(r,(function(e){var t=e.gridPosition,n=this.calcBaryCenter(e),r=(e.upstreamPriority+e.downstreamPriority)/2;if(!(Math.abs(t-n)<1e-4||Math.abs(t-n)<.2501))if(t<n)for(;t<n&&this.moveRight(e,i,r);)t=e.gridPosition;else for(;t>n&&this.moveLeft(e,i,r);)t=e.gridPosition}),this),n>0&&this.calcDownData(n-1),n<this.layers.length-1&&this.calcUpData(n+1)},moveRight:function(e,t,n){var i=h.indexOf(t,e);if(i===t.length-1)return e.gridPosition=e.gridPosition+.5,!0;var r=t[i+1],o=(r.upstreamPriority+r.downstreamPriority)/2;return r.gridPosition>e.gridPosition+1?(e.gridPosition=e.gridPosition+.5,!0):!(o>n||Math.abs(o-n)<1e-4)&&(!!this.moveRight(r,t,n)&&(e.gridPosition=e.gridPosition+.5,!0))},moveLeft:function(e,t,n){var i=h.indexOf(t,e);if(0===i)return e.gridPosition=e.gridPosition-.5,!0;var r=t[i-1],o=(r.upstreamPriority+r.downstreamPriority)/2;return r.gridPosition<e.gridPosition-1?(e.gridPosition=e.gridPosition-.5,!0):!(o>n||Math.abs(o-n)<1e-4)&&(!!this.moveLeft(r,t,n)&&(e.gridPosition=e.gridPosition-.5,!0))},mapVirtualNode:function(e,t){this.nodeToLinkMap.set(e,t),this.linkToNodeMap.containsKey(t)||this.linkToNodeMap.set(t,[]),this.linkToNodeMap.get(t).push(e)},_nodesInLink:function(e){return this.linkToNodeMap.get(this.nodeToLinkMap.get(e))},_dummify:function(){this.linkToNodeMap=new c,this.nodeToLinkMap=new c;var e,t,n,i,a,s,l,d,u=this.graph.links.slice(0),p=this.layers,f=function(e,t,n){p[e].linksTo[t]=p[e].linksTo[t]||[],p[e].linksTo[t].push(n)};for(d=0;d<u.length;d++){var m=u[d],g=m.source,v=m.target,_=g.layer,b=v.layer,y=g.gridPosition,w=v.gridPosition,k=(w-y)/Math.abs(b-_),x=g;if(_-b>1){for(l=_-1;l>b;l--){for((n=new r).x=g.x,n.y=g.y,n.width=g.width/100,n.height=g.height/100,(t=(l-b)*k+y)>(e=p[l]).length&&(t=e.length),y>=p[_].length-1&&w>=p[b].length-1?t=e.length:0===y&&0===w&&(t=0),n.layer=l,n.uBaryCenter=0,n.dBaryCenter=0,n.upstreamLinkCount=0,n.downstreamLinkCount=0,n.gridPosition=t,n.isVirtual=!0,h.insert(e,n,t),a=t+1;a<e.length;a++)(i=e[a]).gridPosition=i.gridPosition+1;(s=new o(x,n)).depthOfDumminess=0,f(l-1,l,s),x=n,this.graph._addNode(n),this.graph.addLink(s),n.index=this.graph.nodes.length-1,this.mapVirtualNode(n,m)}f(b-1,b,s),m.changeSource(x),m.depthOfDumminess=_-b-1}else if(_-b<-1){for(l=_+1;l<b;l++){for((n=new r).x=g.x,n.y=g.y,n.width=g.width/100,n.height=g.height/100,(t=(l-_)*k+y)>(e=p[l]).length&&(t=e.length),y>=p[_].length-1&&w>=p[b].length-1?t=e.length:0===y&&0===w&&(t=0),n.layer=l,n.uBaryCenter=0,n.dBaryCenter=0,n.upstreamLinkCount=0,n.downstreamLinkCount=0,n.gridPosition=t,n.isVirtual=!0,t&=t,h.insert(e,n,t),a=t+1;a<e.length;a++)(i=e[a]).gridPosition=i.gridPosition+1;(s=new o(x,n)).depthOfDumminess=0,f(l-1,l,s),x=n,this.graph._addNode(n),this.graph.addLink(s),n.index=this.graph.nodes.length-1,this.mapVirtualNode(n,m)}f(b-1,b,m),m.changeSource(x),m.depthOfDumminess=b-_-1}else f(_,b,m)}},_dedummify:function(){for(var e=!0;e;){e=!1;for(var t=0;t<this.graph.links.length;t++){var n=this.graph.links[t];if(n.depthOfDumminess){var i=[];i.unshift({x:n.target.x,y:n.target.y}),i.unshift({x:n.source.x,y:n.source.y});for(var r=n,o=n.depthOfDumminess,a=0;a<o;a++){var s=r.source.incoming[0];i.unshift({x:s.source.x,y:s.source.y}),r=s}n.changeSource(r.source),n.depthOfDumminess=0,i.length>2?(i.splice(0,1),i.splice(i.length-1),n.points=i):n.points=[],e=!0;break}}}},_optimizeCrossings:function(){for(var e,t=-1,n=0;0!==t&&!(n++>3);){for(t=0,e=this.layers.length-1;e>=1;e--)t+=this.optimizeLayerCrossings(!1,e);for(e=0;e<this.layers.length-1;e++)t+=this.optimizeLayerCrossings(!0,e)}},calcUpData:function(e){if(0!==e){var t,n,i,r=this.layers[e],o=new d,a=this.layers[e-1];for(t=0;t<a.length;t++)o.add(a[t]);for(t=0;t<r.length;t++){var s=r[t],l=0,c=0;for(n=0;n<s.incoming.length;n++)i=s.incoming[n],o.contains(i.source)&&(c++,l+=i.source.gridPosition);for(n=0;n<s.outgoing.length;n++)i=s.outgoing[n],o.contains(i.target)&&(c++,l+=i.target.gridPosition);c>0?(s.uBaryCenter=l/c,s.upstreamLinkCount=c):(s.uBaryCenter=t,s.upstreamLinkCount=0)}}},calcDownData:function(e){if(e!==this.layers.length-1){var t,n,i,r=this.layers[e],o=new d,a=this.layers[e+1];for(t=0;t<a.length;t++)o.add(a[t]);for(t=0;t<r.length;t++){var s=r[t],l=0,c=0;for(n=0;n<s.incoming.length;n++)i=s.incoming[n],o.contains(i.source)&&(c++,l+=i.source.gridPosition);for(n=0;n<s.outgoing.length;n++)i=s.outgoing[n],o.contains(i.target)&&(c++,l+=i.target.gridPosition);c>0?(s.dBaryCenter=l/c,s.downstreamLinkCount=c):(s.dBaryCenter=t,s.downstreamLinkCount=0)}}},optimizeLayerCrossings:function(e,t){var n,i,r=(i=e?this.layers[n=t+1]:this.layers[n=t-1]).slice(0);e?this.calcUpData(n):this.calcDownData(n);var o=this;i.sort((function(e,t){var n=o.calcBaryCenter(e),i=o.calcBaryCenter(t);if(Math.abs(n-i)<1e-4)return e.degree()===t.degree()?o.compareByIndex(e,t):e.degree()<t.degree()?1:-1;var r=1e3*(i-n);return r>0?-1:r<0?1:o.compareByIndex(e,t)}));var a,s=0;for(a=0;a<i.length;a++)i[a]!==r[a]&&s++;if(s>0){var l=0;for(a=0;a<i.length;a++){i[a].gridPosition=l++}}return s},_swapPairs:function(){for(var e=this.options.layeredIterations,t=0;!(t++>e);)for(var n=t%4<=1,i=t%4==1,r=n?0:this.layers.length-1;n?r<=this.layers.length-1:r>=0;r+=n?1:-1){for(var o=this.layers[r],a=!1,s=!0,l=0,c=0;c<o.length-1;c++){var d=0,u=0,h=0;if(s?(0!==r&&(d=this.countLinksCrossingBetweenTwoLayers(r-1,r)),r!==this.layers.length-1&&(u=this.countLinksCrossingBetweenTwoLayers(r,r+1)),n?d*=2:u*=2,h=d+u):h=l,0!==h){var p=o[c],f=o[c+1],m=p.gridPosition,g=f.gridPosition;o[c]=f,o[c+1]=p,p.gridPosition=g,f.gridPosition=m,d=0,0!==r&&(d=this.countLinksCrossingBetweenTwoLayers(r-1,r)),u=0,r!==this.layers.length-1&&(u=this.countLinksCrossingBetweenTwoLayers(r,r+1)),n?d*=2:u*=2;var v=d+u;(i?v>=h:v>h)?(p=o[c],f=o[c+1],m=p.gridPosition,g=f.gridPosition,o[c]=f,o[c+1]=p,p.gridPosition=g,f.gridPosition=m,l=h,s=!1):(a=!0,s=!0)}}a&&(r!==this.layers.length-1&&this.calcUpData(r+1),0!==r&&this.calcDownData(r-1))}},countLinksCrossingBetweenTwoLayers:function(e,t){var n,i,r,o,a,s,l,c,d=this.layers[e].linksTo[t],u=0,h=d.length;for(l=0;l<h;l++)for(n=d[l],c=l+1;c<h;c++){i=d[c],n.target.layer===t?(r=n.source,o=n.target):(r=n.target,o=n.source),i.target.layer===t?(a=i.source,s=i.target):(a=i.target,s=i.source);var p=r.gridPosition,f=o.gridPosition;(p-a.gridPosition)*(f-s.gridPosition)<0&&u++}return u},calcBaryCenter:function(e){var t=e.upstreamLinkCount,n=e.downstreamLinkCount,i=e.uBaryCenter,r=e.dBaryCenter;return t>0&&n>0?(i+r)/2:t>0?i:n>0?r:0},_gridPositionComparer:function(e,t){return e.gridPosition<t.gridPosition?-1:e.gridPosition>t.gridPosition?1:0},_positionAscendingComparer:function(e,t){return e.k<t.k?-1:e.k>t.k?1:0},_positionDescendingComparer:function(e,t){return e.k<t.k?1:e.k>t.k?-1:0},_firstVirtualNode:function(e){for(var t=0;t<e.length;t++)if(e[t].isVirtual)return t;return-1},compareByIndex:function(e,t){var n=e.index,i=t.index;return n<i?1:n>i?-1:0},intDiv:function(e,t){return(e-e%t)/t},nextVirtualNode:function(e,t){for(var n=t.layerIndex+1;n<e.length;++n)if(e[n].isVirtual)return e[n];return null}}),C=t.Class.extend({init:function(e,t){if(h.isUndefined(e))throw"No diagram given";this.diagram=e,this.nodeMap=new c,this.linkMap=new c,this.capture(t||e)},capture:function(e){var t,i,r,o,a,s,c;if(e instanceof n.Graph){for(o=0;o<e.nodes.length;o++)r=(t=e.nodes[o]).associatedShape,this.nodeMap.set(r.visual.id,new l(t.x,t.y,t.width,t.height));for(o=0;o<e.links.length;o++)a=(s=e.links[o]).associatedConnection,this.linkMap.set(a.visual.id,s.points())}else if(e instanceof Array)for(i=e,o=0;o<i.length;o++)(r=(t=i[o]).associatedShape)&&this.nodeMap.set(r.visual.id,new l(t.x,t.y,t.width,t.height));else if(e.hasOwnProperty("links")&&e.hasOwnProperty("nodes")){for(i=e.nodes,c=e.links,o=0;o<i.length;o++)(r=(t=i[o]).associatedShape)&&this.nodeMap.set(r.visual.id,new l(t.x,t.y,t.width,t.height));for(o=0;o<c.length;o++)(a=(s=c[o]).associatedConnection)&&this.linkMap.set(a.visual.id,s.points)}else{var d=this.diagram.shapes,u=this.diagram.connections;for(o=0;o<d.length;o++)r=d[o],this.nodeMap.set(r.visual.id,r.bounds());for(o=0;o<u.length;o++)a=u[o],this.linkMap.set(a.visual.id,a.points())}}});a(n,{init:function(e){t.init(e,n.ui)},SpringLayout:y,TreeLayout:k,GraphAdapter:b,LayeredLayout:x,LayoutBase:_,LayoutState:C})}(window.kendo.jQuery),function(e,t){var n=kendo.dataviz,i=kendo.drawing,r=kendo.geometry,o=n.diagram,a=kendo.ui.Widget,s=kendo.Class,l=kendo.deepExtend,c=kendo._outerWidth,d=kendo._outerHeight,u=e.extend,h=kendo.data.HierarchicalDataSource,p=o.Canvas,f=o.Group,m=o.Rectangle,g=o.Circle,v=o.CompositeTransform,_=o.Rect,b=o.Path,y=o.DeleteShapeUnit,w=o.DeleteConnectionUnit,k=o.TextBlock,x=o.Image,C=o.Point,S=o.Intersect,T=o.ConnectionEditAdorner,D=o.UndoRedoService,A=o.ToolService,M=o.Selector,E=o.ResizingAdorner,I=o.ConnectorsAdorner,z=o.Cursors,P=o.Utils,H=kendo.Observable,F=o.ToBackUnit,R=o.ToFrontUnit,L=o.PolylineRouter,B=o.CascadingRouter,O=P.isUndefined,V=P.isDefined,N=i.util.defined,$=Array.isArray,U=kendo.isFunction,W=P.isString,j=e.isPlainObject,q=Math,G=".kendoDiagram",K="cascading",Y="itemBoundsChange",Q="change",X="click",Z="error",J="Auto",ee=9007199254740992,te="select",ne="itemRotate",ie="pan",re="zoomStart",oe="zoomEnd",ae="none",se=Number.MAX_VALUE,le=-Number.MAX_VALUE,ce="transformed",de="rotated",ue="DOMMouseScroll"+G+" mousewheel"+G,he=({className:e,icon:t,themeColor:n,text:i})=>kendo.html.renderButton(`<button class="${e}" href="#">${i}</button>`,{icon:t,themeColor:n});o.DefaultConnectors=[{name:"Top"},{name:"Bottom"},{name:"Left"},{name:"Right"},{name:J,position:function(e){return e.getPosition("center")}}];var pe={cancel:{text:"Cancel",icon:"cancel-outline",className:"k-diagram-cancel"},update:{text:"Save",imageClass:"save",className:"k-diagram-update",icon:"save",themeColor:"primary"}};function fe(e){return e.options.name.toLowerCase()===J.toLowerCase()}function me(e,t){for(var n,i,r=ee,o=0;o<t.length;o++)if(!fe(i=t[o])){var a=e.distanceTo(i.position());a<r&&(r=a,n=i)}return n}function ge(e,t){var n,i,r=[],o=e.drawingContainer().children,a=o.length;for(n=0;n<t.length;n++){i=t[n];for(var s=0;s<a;s++)if(o[s]==i.drawingContainer()){r.push(s);break}}return r}o.shapeDefaults=function(e){var t={type:"rectangle",path:"",autoSize:!0,visual:null,x:0,y:0,minWidth:20,minHeight:20,width:100,height:100,hover:{},editable:{connect:!0,tools:[]},connectors:o.DefaultConnectors,rotation:{angle:0}};return P.simpleExtend(t,e),t};var ve=H.extend({init:function(e){var t=this;t.dataItem=(e||{}).dataItem,H.fn.init.call(t),t.options=l({id:o.randomId()},t.options,e),t.isSelected=!1,t.visual=new f({id:t.options.id,autoSize:t.options.autoSize}),t.id=t.options.id,t._template()},options:{hover:{},cursor:z.grip,content:{align:"center middle"},selectable:!0,serializable:!0,enable:!0},_getCursor:function(e){return this.adorner?this.adorner._getCursor(e):this.options.cursor},visible:function(e){if(O(e))return this.visual.visible();this.visual.visible(e)},bounds:function(){},refresh:function(){this.visual.redraw()},position:function(e){this.options.x=e.x,this.options.y=e.y,this.visual.position(e)},toString:function(){return this.options.id},serialize:function(){var e=l({},{options:this.options});return this.dataItem&&(e.dataItem=this.dataItem.toString()),e},_content:function(e){if(e!==t){var n=this.options;o.Utils.isString(e)?n.content.text=e:l(n.content,e);var i=n.content;this._contentVisual?this._updateContentVisual(i):this._createContentVisual(i)}return this.options.content.text},_createContentVisual:function(e){e.text&&(this._contentVisual=new k(e),this._contentVisual._includeInBBox=!1,this.visual.append(this._contentVisual))},_updateContentVisual:function(e){this._contentVisual.redraw(e)},_hitTest:function(e){var t=this.bounds();return this.visible()&&t.contains(e)&&this.options.enable},_template:function(){var e=this;if(e.options.content.template){var t=e.dataItem||{},n=kendo.template(e.options.content.template,{paramName:"dataItem"});e.options.content.text=n(t)}},_canSelect:function(){return!1!==this.options.selectable},toJSON:function(){return{id:this.options.id}}}),_e=s.extend({init:function(e,t){this.options=l({},this.options,t),this.connections=[],this.shape=e},options:{width:7,height:7,fill:{color:"Yellow"},hover:{}},position:function(){return this.options.position?this.options.position(this.shape):this.shape.getPosition(this.options.name)},toJSON:function(){return{shapeId:this.shape.toString(),connector:this.options.name}}});_e.parse=function(e,t){for(var n=t.split(":"),i=n[0],r=n[1]||J,o=0;o<e.shapes.length;o++){var a=e.shapes[o];if(a.options.id==i)return a.getConnector(r.trim())}};var be=ve.extend({init:function(e,t){var n=this;ve.fn.init.call(n,e),this.diagram=t,this.updateOptionsFromModel(),e=n.options,n.connectors=[],n.type=e.type,n.createShapeVisual(),n.updateBounds(),n.content(n.content()),n._createConnectors()},options:o.shapeDefaults(),_setOptionsFromModel:function(e){var t=ke(e||this.dataItem);this.options=l({},this.options,t),this.redrawVisual()},updateOptionsFromModel:function(e,t){if(this.diagram&&this.diagram._isEditable){var i=ke(e||this.dataItem);if(e&&t)if(n.inArray(t,["x","y","width","height"])){var r=this.bounds();r[t]=e[t],this.bounds(r)}else this.options.visual?this._redrawVisual():i.type&&(this.options=l({},this.options,i),this._redrawVisual()),this.options.content&&(this._template(),this.content(this.options.content));else this.options=l({},this.options,i)}},_redrawVisual:function(){this.visual.clear(),this._contentVisual=null,this.options.dataItem=this.dataItem,this.createShapeVisual(),this.updateBounds()},redrawVisual:function(){this._redrawVisual(),this.options.content&&(this._template(),this.content(this.options.content))},updateModel:function(e){var t=this.diagram;if(t&&t._isEditable){var n=this._bounds,i=this.dataItem;i&&(t._suspendModelRefresh(),N(i.x)&&n.x!==i.x&&i.set("x",n.x),N(i.y)&&n.y!==i.y&&i.set("y",n.y),N(i.width)&&n.width!==i.width&&i.set("width",n.width),N(i.height)&&n.height!==i.height&&i.set("height",n.height),this.dataItem=i,t._resumeModelRefresh(),e&&t._syncShapeChanges())}},updateBounds:function(){var e=this.visual._measure(!0),t=this.options;this.bounds(new _(t.x,t.y,e.width,e.height)),this._rotate(),this._alignContent()},content:function(e){var t=this._content(e);return this._alignContent(),t},_alignContent:function(){var e=this.options.content||{},t=this._contentVisual;if(t&&e.align){var n=this.visual._measure(),i=new o.RectAlign(n),r=t.drawingElement.bbox(null),a=new _(0,0,r.width(),r.height()),s=i.align(a,e.align);t.position(s.topLeft())}},_createConnectors:function(){var e,t,n=this.options,i=n.connectors.length,r=n.connectorDefaults;for(t=0;t<i;t++)e=new _e(this,l({},r,n.connectors[t])),this.connectors.push(e)},bounds:function(e){var t;if(e)if(W(e))switch(e){case ce:t=this._transformedBounds();break;case"absolute":t=this._transformedBounds();var n=this.diagram._pan;t.x+=n.x,t.y+=n.y;break;case de:t=this._rotatedBounds();break;default:t=this._bounds}else this._setBounds(e),this._triggerBoundsChange(),this.diagram&&this.diagram._layouting||this.refreshConnections();else t=this._bounds;return t},_setBounds:function(e){var t=this.options,n=e.topLeft(),i=t.x=n.x,r=t.y=n.y,o=t.width=q.max(e.width,t.minWidth),a=t.height=q.max(e.height,t.minHeight);this._bounds=new _(i,r,o,a),this.visual.redraw({x:i,y:r,width:o,height:a})},position:function(e){if(!e)return this._bounds.topLeft();this.bounds(new _(e.x,e.y,this._bounds.width,this._bounds.height))},clone:function(){var e=this.serialize();return e.options.id=o.randomId(),this.diagram&&this.diagram._isEditable&&N(this.dataItem)&&(e.options.dataItem=ze(this.dataItem)),new be(e.options)},select:function(e){var t,n,i=this.diagram;if(O(e)&&(e=!0),this._canSelect()&&this.isSelected!=e)return t=[],n=[],this.isSelected=e,this.isSelected?(i._selectedItems.push(this),t.push(this)):(P.remove(i._selectedItems,this),n.push(this)),i._internalSelection||i._selectionChanged(t,n),!0},rotate:function(e,n,i){var r=this.visual.rotate();if(e!==t){!1!==i&&this.diagram&&this.diagram.undoRedoService&&e!==r.angle&&this.diagram.undoRedoService.add(new o.RotateUnit(this.diagram._resizingAdorner,[this],[r.angle]),!1);var a,s,l=this.bounds(),c=new C(l.width/2,l.height/2);n&&(a=e-r.angle,s=l.center().rotate(a,n).minus(c),this._rotationOffset=this._rotationOffset.plus(s.minus(l.topLeft())),this.position(s)),this.visual.rotate(e,c),this.options.rotation.angle=e,this.diagram&&this.diagram._connectorsAdorner&&this.diagram._connectorsAdorner.refresh(),this.refreshConnections(),this.diagram&&this.diagram.trigger(ne,{item:this})}return r},connections:function(e){var t,n,i,r,o=[];for(t=0;t<this.connectors.length;t++)for(r=this.connectors[t].connections,n=0;n<r.length;n++)if(i=r[n],"out"==e){var a=i.source();a.shape&&a.shape==this&&o.push(i)}else if("in"==e){var s=i.target();s.shape&&s.shape==this&&o.push(i)}else o.push(i);return o},refreshConnections:function(){e.each(this.connections(),(function(){this.refresh()}))},getConnector:function(e){var t,n;if(!W(e))return e instanceof C?me(e,this.connectors):this.connectors.length?this.connectors[0]:null;for(e=e.toLocaleLowerCase(),t=0;t<this.connectors.length;t++)if((n=this.connectors[t]).options.name.toLocaleLowerCase()==e)return n},getPosition:function(e){var t=this.bounds(),n=e.charAt(0).toLowerCase()+e.slice(1);return U(t[n])?this._transformPoint(t[n]()):t.center()},redraw:function(e){if(e){var t,n=this.options;this.shapeVisual.redraw(this._visualOptions(e)),this._diffNumericOptions(e,["width","height","x","y"])&&(this.bounds(new _(n.x,n.y,n.width,n.height)),t=!0),e.connectors&&(n.connectors=e.connectors,this._updateConnectors()),n=l(n,e),(e.rotation||t)&&this._rotate(),n.content&&this.content(n.content)}},_updateConnectors:function(){var e,t,n,i=this.connections();this.connectors=[],this._createConnectors();for(var r=0;r<i.length;r++)t=(e=i[r]).source(),n=e.target(),t.shape&&t.shape===this?e.source(this.getConnector(t.options.name)||null):n.shape&&n.shape===this&&e.target(this.getConnector(n.options.name)||null),e.updateModel()},_diffNumericOptions:o.diffNumericOptions,_visualOptions:function(e){return{data:e.path,source:e.source,hover:e.hover,fill:e.fill,stroke:e.stroke}},_triggerBoundsChange:function(){this.diagram&&this.diagram.trigger(Y,{item:this,bounds:this._bounds.clone()})},_transformPoint:function(e){var t=this.rotate(),n=this.bounds().topLeft();return t.angle&&e.rotate(t.angle,t.center().plus(n)),e},_transformedBounds:function(){var e=this.bounds(),t=e.topLeft(),n=e.bottomRight();return _.fromPoints(this.diagram.modelToView(t),this.diagram.modelToView(n))},_rotatedBounds:function(){var e=this.bounds().rotatedBounds(this.rotate().angle),t=e.topLeft(),n=e.bottomRight();return _.fromPoints(t,n)},_rotate:function(){var e=this.options.rotation;e&&e.angle&&this.rotate(e.angle),this._rotationOffset=new C},_hover:function(e){var t=this.options,n=t.hover,i=t.stroke,r=t.fill;e&&V(n.stroke)&&(i=l({},i,n.stroke)),e&&V(n.fill)&&(r=n.fill),this.shapeVisual.redraw({stroke:i,fill:r}),t.editable&&t.editable.connect&&this.diagram._showConnectors(this,e)},_hitTest:function(e){if(this.visible()){var t,n=this.bounds(),i=this.rotate().angle;if(e.isEmpty&&!e.isEmpty())return S.rects(e,n,i||0);if(t=e.clone().rotate(i,n.center()),n.contains(t))return this}},toJSON:function(){return{shapeId:this.options.id}},createShapeVisual:function(){var e,t,n,i=this.options,r=this._visualOptions(i),o=i.visual,a=(i.type+"").toLocaleLowerCase();r.width=i.width,r.height=i.height,U(o)?e=o.call(this,i):r.data?(e=new b(r),0===(n=(t=e).drawingContainer().clippedBBox(null)).origin.x&&0===n.origin.y||t.position(-n.origin.x,-n.origin.y)):e="rectangle"==a?new m(r):"circle"==a?new g(r):"text"==a?new k(r):"image"==a?new x(r):new b(r),this.shapeVisual=e,this.visual.append(this.shapeVisual)}}),ye=ve.extend({init:function(e,t,n){var i=this;ve.fn.init.call(i,n),this.updateOptionsFromModel(),this._initRouter(),i.path=new o.Polyline(i.options),i.path.fill("transparent"),i.visual.append(i.path),i._sourcePoint=i._targetPoint=new C,i._setSource(e),i._setTarget(t),i.content(i.options.content),i.definers=[],N(n)&&n.points&&i.points(n.points)},options:{hover:{stroke:{}},startCap:ae,endCap:ae,points:[],selectable:!0,fromConnector:J,toConnector:J},_setOptionsFromModel:function(e){this.updateOptionsFromModel(e||this.dataItem)},updateOptionsFromModel:function(e){if(this.diagram&&this.diagram._isEditable){var t=this.diagram._dataMap,n=function(e){var t={};N((e=e||{}).text)&&null!==e.text&&(t.content=e.text);N(e.type)&&null!==e.type&&(t.type=e.type);N(e.from)&&null!==e.from&&(t.from=e.from);N(e.fromConnector)&&null!==e.fromConnector&&(t.fromConnector=e.fromConnector);N(e.fromX)&&null!==e.fromX&&(t.fromX=e.fromX);N(e.fromY)&&null!==e.fromY&&(t.fromY=e.fromY);N(e.to)&&null!==e.to&&(t.to=e.to);N(e.toConnector)&&null!==e.toConnector&&(t.toConnector=e.toConnector);N(e.toX)&&null!==e.toX&&(t.toX=e.toX);N(e.toY)&&null!==e.toY&&(t.toY=e.toY);return t}(e||this.dataItem);if(e){if(N(n.from)){var i=t[n.from];i&&N(n.fromConnector)&&(i=i.getConnector(n.fromConnector)),this.source(i)}else N(n.fromX)&&N(n.fromY)&&this.source(new C(n.fromX,n.fromY));if(N(n.to)){var r=t[n.to];r&&N(n.toConnector)&&(r=r.getConnector(n.toConnector)),this.target(r)}else N(n.toX)&&N(n.toY)&&this.target(new C(n.toX,n.toY));N(n.type)&&this.type()!==n.type&&(this.points([]),this.type(n.type)),this.dataItem=e,this._template(),this.redraw(this.options)}else this.options=l({},n,this.options)}},updateModel:function(e){if(this.diagram&&this.diagram._isEditable&&this.diagram.connectionsDataSource){var t=this.diagram.connectionsDataSource.getByUid(this.dataItem.uid);t&&(this.diagram._suspendModelRefresh(),N(this.options.fromX)&&null!==this.options.fromX?(Fe("from",t),Fe("fromConnector",t),t.set("fromX",this.options.fromX),t.set("fromY",this.options.fromY)):(t.set("from",this.options.from),N(t.fromConnector)&&t.set("fromConnector",this.sourceConnector?this.sourceConnector.options.name:null),Fe("fromX",t),Fe("fromY",t)),N(this.options.toX)&&null!==this.options.toX?(Fe("to",t),Fe("toConnector",t),t.set("toX",this.options.toX),t.set("toY",this.options.toY)):(t.set("to",this.options.to),N(t.toConnector)&&t.set("toConnector",this.targetConnector?this.targetConnector.options.name:null),Fe("toX",t),Fe("toY",t)),N(this.options.type)&&N(t.type)&&t.set("type",this.options.type),this.dataItem=t,this.diagram._resumeModelRefresh(),e&&this.diagram._syncConnectionChanges())}},sourcePoint:function(){return this._resolvedSourceConnector?this._resolvedSourceConnector.position():this._sourcePoint},_setSource:function(e){var n,i=e instanceof be,r=this.options.fromConnector||J;i&&!e.getConnector(r)||(e!==t&&(this.from=e),this._removeFromSourceConnector(),null===e?this.sourceConnector&&(this._sourcePoint=(this._resolvedSourceConnector||this.sourceConnector).position(),this._clearSourceConnector(),this._setFromOptions(null,this._sourcePoint)):e instanceof _e?((n=e.shape.dataItem)&&this._setFromOptions(n.id),this.sourceConnector=e,this.sourceConnector.connections.push(this)):e instanceof C?(this._setFromOptions(null,e),this._sourcePoint=e,this.sourceConnector&&this._clearSourceConnector()):i&&((n=e.dataItem)&&this._setFromOptions(n.id),this.sourceConnector=e.getConnector(r),this.sourceConnector.connections.push(this)))},source:function(e,t){return V(e)&&(t&&this.diagram&&this.diagram.undoRedoService.addCompositeItem(new o.ConnectionEditUnit(this,e)),this._setSource(e),this.refresh()),this.sourceConnector?this.sourceConnector:this._sourcePoint},_setFromOptions:function(e,t){this.options.from=e,t?(this.options.fromX=t.x,this.options.fromY=t.y):(this.options.fromX=null,this.options.fromY=null)},sourceDefiner:function(e){if(!e)return this._sourceDefiner||(this._sourceDefiner=new o.PathDefiner(this.sourcePoint(),null,null)),this._sourceDefiner;if(!(e instanceof o.PathDefiner))throw"The sourceDefiner needs to be a PathDefiner.";e.left=null,this._sourceDefiner=e,this.source(e.point)},targetPoint:function(){return this._resolvedTargetConnector?this._resolvedTargetConnector.position():this._targetPoint},_setTarget:function(e){var n,i=e instanceof be,r=this.options.toConnector||J;i&&!e.getConnector(r)||(e!==t&&(this.to=e),this._removeFromTargetConnector(),null===e?this.targetConnector&&(this._targetPoint=(this._resolvedTargetConnector||this.targetConnector).position(),this._clearTargetConnector(),this._setToOptions(null,this._targetPoint)):e instanceof _e?((n=e.shape.dataItem)&&this._setToOptions(n.id),this.targetConnector=e,this.targetConnector.connections.push(this)):e instanceof C?(this._setToOptions(null,e),this._targetPoint=e,this.targetConnector&&this._clearTargetConnector()):i&&((n=e.dataItem)&&this._setToOptions(n.id),this.targetConnector=e.getConnector(r),this.targetConnector.connections.push(this)))},target:function(e,n){return V(e)&&(n&&this.diagram&&this.diagram.undoRedoService.addCompositeItem(new o.ConnectionEditUnit(this,t,e)),this._setTarget(e),this.refresh()),this.targetConnector?this.targetConnector:this._targetPoint},_setToOptions:function(e,t){this.options.to=e,t?(this.options.toX=t.x,this.options.toY=t.y):(this.options.toX=null,this.options.toY=null)},targetDefiner:function(e){if(!e)return this._targetDefiner||(this._targetDefiner=new o.PathDefiner(this.targetPoint(),null,null)),this._targetDefiner;if(!(e instanceof o.PathDefiner))throw"The sourceDefiner needs to be a PathDefiner.";e.right=null,this._targetDefiner=e,this.target(e.point)},_updateConnectors:function(){this._updateConnector(this.source(),"source"),this._updateConnector(this.target(),"target")},_updateConnector:function(e,t){var n=this,i=n.diagram;if(e instanceof _e&&!i.getShapeById(e.shape.id)){var r=e.shape.dataItem,o=e.options.name,a=function(){var a=i._dataMap[r.id];e=a.getConnector(o),n[t](e,!1),n.updateModel()};if(i._dataMap[r.id])a();else{var s=i._inactiveShapeItems.getByUid(r.uid);s&&i._deferredConnectionUpdates.push(s.onActivate(a))}}else n[t](e,!1)},content:function(e){var t=this._content(e);return N(e)&&this._alignContent(),t},_createContentVisual:function(e){var t;return U(e.visual)?t=e.visual.call(this,e):e.text&&(t=new k(e)),t&&(this._contentVisual=t,t._includeInBBox=!1,this.visual.append(t)),t},_updateContentVisual:function(e){U(e.visual)?(this.visual.remove(this._contentVisual),this._createContentVisual(e)):this._contentVisual.redraw(e)},_alignContent:function(){if(this._contentVisual){for(var e=5,t=this.allPoints(),n=q.floor(t.length/2),r=n-1;r>0&&t[r].equals(t[n]);)r--,n++;var o,a=t[n],s=t[r],l=this._contentVisual._measure(),c=l.width,d=l.height,u=t.length%2==0,h=s.distanceTo(a);if(u&&t.length>2&&h>0&&(s.y===a.y&&h<c||s.x===a.x&&h<d)&&(u=!1,e=0),u){var p=i.util.deg(q.atan2(a.y-s.y,a.x-s.x));o=new C((a.x-s.x)/2+s.x,(a.y-s.y)/2+s.y),90===q.abs(p)?(o.x+=e,o.y-=d/2):p%180==0?(o.x-=c/2,o.y-=d+e):p<-90||0<p&&p<90?o.y-=d:(p<0||p>90)&&(o.x-=c,o.y-=d)}else{var f=q.floor(t.length/2);o=t[f].clone(),s=t[f-1],a=t[f+1];var m=s.x<=o.x&&a.x<=o.x?e:-l.width-e,g=s.y<=o.y&&a.y<=o.y?e:-l.height-e;o.x+=m,o.y+=g}this._contentVisual.position(o)}},select:function(e){var n,i,r=this.diagram;if(this._canSelect()&&this.isSelected!==e)return this.isSelected=e,n=[],i=[],this.isSelected?(this.adorner=new T(this,this.options.selection),r._adorn(this.adorner,!0),r._selectedItems.push(this),n.push(this)):this.adorner&&(r._adorn(this.adorner,!1),P.remove(r._selectedItems,this),this.adorner=t,i.push(this)),this.adorner&&this.adorner.refresh(),r._internalSelection||r._selectionChanged(n,i),!0},bounds:function(e){if(!e||W(e))return this._bounds;this._bounds=e},type:function(e){var t=this.options;if(!e)return t.type;e!==t.type&&(t.type=e,this._initRouter(),this.refresh())},_initRouter:function(){var e=(this.options.type||"").toLowerCase();this._router=e==K?new B(this):new L(this)},points:function(e){if(!e){var t=[];if(V(this.definers))for(var n=0;n<this.definers.length;n++)t.push(this.definers[n].point);return t}this.definers=[];for(var i=0;i<e.length;i++){var r=e[i];if(r instanceof o.Point)this.definers.push(new o.PathDefiner(r));else{if(!r.hasOwnProperty("x")||!r.hasOwnProperty("y"))throw"A Connection point needs to be a Point or an object with x and y properties.";this.definers.push(new o.PathDefiner(new C(r.x,r.y)))}}},allPoints:function(){var e=[this.sourcePoint()];if(this.definers)for(var t=0;t<this.definers.length;t++)e.push(this.definers[t].point);return e.push(this.targetPoint()),e},refresh:function(){this._resolveConnectors(),this._refreshPath(),this._alignContent(),this.adorner&&this.adorner.refresh()},_resolveConnectors:function(){var e,t,n,i,r=this,o=r.source(),a=r.target();o instanceof C?e=o:o instanceof _e&&(n=fe(o)?o.shape.connectors:[o]),a instanceof C?t=a:a instanceof _e&&(i=fe(a)?a.shape.connectors:[a]),e?i&&(r._resolvedTargetConnector=me(e,i)):n&&(t?r._resolvedSourceConnector=me(t,n):i&&this._resolveAutoConnectors(n,i))},_resolveAutoConnectors:function(e,t){var n,i,r,o,a,s,l,c,d,u,h,p=ee,f=ee;for(d=0;d<e.length;d++)if(!fe(l=e[d]))for(r=l.position(),u=0;u<t.length;u++)fe(c=t[u])||(o=c.position(),(h=q.round(r.distanceTo(o)))<p&&this.diagram&&this._testRoutePoints(r,o,l,c)&&(p=h,n=l,i=c),h<f&&(a=l,s=c,f=h));n&&(a=n,s=i),this._resolvedSourceConnector=a,this._resolvedTargetConnector=s},_testRoutePoints:function(e,t,n,i){var r=this._router,o=!0;if(r instanceof B){var a,s,l,c,d=r.routePoints(e,t,n,i);c=this._getRouteExclude(e,t,n.shape,i.shape),d.unshift(e),d.push(t);for(var u=1;u<d.length;u++)if(a=d[u-1],s=d[u],(l=new _(q.min(a.x,s.x),q.min(a.y,s.y),q.abs(a.x-s.x),q.abs(a.y-s.y))).width>0&&(l.x++,l.width-=2),l.height>0&&(l.y++,l.height-=2),!l.isEmpty()&&this.diagram._shapesQuadTree.hitTestRect(l,c)){o=!1;break}}return o},_getRouteExclude:function(e,t,n,i){var r=[];return this._isPointInsideShape(e,n)&&r.push(n),this._isPointInsideShape(t,i)&&r.push(i),r},_isPointInsideShape:function(e,t){var n,i,r,o=t.bounds(),a=t.rotate().angle,s=o.x,l=o.y;return i=(n=e.clone().rotate(a,o.center())).x,r=n.y,i>s&&i<s+o.width&&r>l&&r<l+o.height},redraw:function(e){if(e){this.options=l({},this.options,e);var t=this.options.points;N(t)&&t.length>0&&(this.points(t),this._refreshPath()),(e&&e.content||e.text)&&this.content(e.content),this.path.redraw({fill:e.fill,stroke:e.stroke,startCap:e.startCap,endCap:e.endCap})}},clone:function(){var e=this.serialize();return this.diagram&&this.diagram._isEditable&&N(this.dataItem)&&(e.options.dataItem=ze(this.dataItem)),new ye(this.from,this.to,e.options)},serialize:function(){var e=this.from.toJSON?this.from.toJSON:this.from.toString(),t=this.to.toJSON?this.to.toJSON:this.to.toString(),n=l({},{options:this.options,from:e,to:t});return N(this.dataItem)&&(n.dataItem=this.dataItem.toString()),n.options.points=this.points(),n},_hitTest:function(e){if(this.visible()){var t=new C(e.x,e.y),n=this.sourcePoint(),i=this.targetPoint();if(e.isEmpty&&!e.isEmpty()&&e.contains(n)&&e.contains(i))return this;if(this._router.hitTest(t))return this}},_hover:function(e){var t=(this.options.stroke||{}).color;e&&V(this.options.hover.stroke.color)&&(t=this.options.hover.stroke.color),this.path.redraw({stroke:{color:t}})},_refreshPath:function(){N(this.path)&&(this._drawPath(),this.bounds(this._router.getBounds()))},_drawPath:function(){this._router&&this._router.route();var e=this.sourcePoint(),t=this.targetPoint(),n=this.points();this.path.redraw({points:[e].concat(n,[t])})},_clearSourceConnector:function(){this.sourceConnector=t,this._resolvedSourceConnector=t},_clearTargetConnector:function(){this.targetConnector=t,this._resolvedTargetConnector=t},_removeFromSourceConnector:function(){this.sourceConnector&&P.remove(this.sourceConnector.connections,this)},_removeFromTargetConnector:function(){this.targetConnector&&P.remove(this.targetConnector.connections,this)},toJSON:function(){var e,t=this;return{from:t.from&&t.from.toJSON?t.from.toJSON():{x:(e=t._sourcePoint).x,y:e.y},to:t.to&&t.to.toJSON?t.to.toJSON():{x:(e=t._targetPoint).x,y:e.y}}}}),we=a.extend({init:function(e,t){var n=this;kendo.destroy(e),a.fn.init.call(n,e,t),n._initTheme(),n._initElements(),n._extendLayoutOptions(n.options),n._initDefaults(t),n._interactionDefaults(),n._initCanvas(),n.mainLayer=new f({id:"main-layer"}),n.canvas.append(n.mainLayer),n._shapesQuadTree=new Ie(n),n._pan=new C,n._adorners=[],n.adornerLayer=new f({id:"adorner-layer"}),n.canvas.append(n.adornerLayer),n._createHandlers(),n._initialize(),n._resizingAdorner=new E(n,{editable:n.options.editable}),n._connectorsAdorner=new I(n),n._adorn(n._resizingAdorner,!0),n._adorn(n._connectorsAdorner,!0),n.selector=new M(n),n._clipboard=[],n.pauseMouseHandlers=!1,n._fetchFreshData(),n._createGlobalToolBar(),n._createOptionElements(),n.zoom(n.options.zoom),n.canvas.draw()},options:{name:"Diagram",theme:"sass",layout:"",zoomRate:.1,zoom:1,zoomMin:0,zoomMax:2,dataSource:{},draggable:!0,template:"",autoBind:!0,editable:{rotate:{},resize:{},text:!0,tools:[],drag:{snap:{size:10,angle:10}},remove:!0},pannable:{},selectable:{key:"none"},tooltip:{enabled:!0,format:"{0}"},copy:{enabled:!0,offsetX:20,offsetY:20},shapeDefaults:o.shapeDefaults({undoable:!0}),connectionDefaults:{editable:{tools:[]},type:K},shapes:[],connections:[]},events:[oe,re,ie,te,ne,Y,Q,X,"mouseEnter","mouseLeave","toolBarClick","save","cancel","edit","remove","add","dataBound","dragStart","drag","dragEnd"],items:function(){return e()},_createGlobalToolBar:function(){var e=this.options.editable;if(e){var t=e.tools;!this._isEditable||!1===t||t&&0!==t.length||(t=["createShape","undo","redo","rotateClockwise","rotateAnticlockwise"]),t&&t.length&&(this.toolBar=new xe(this,{tools:t||{},click:this._toolBarClick.bind(this),modal:!1}),this.toolBar.element.css({textAlign:"left"}),this.element.prepend(this.toolBar.element),this._resize())}},createShape:function(){if(this.editor&&this.editor.end()||!this.editor){var e=this.dataSource,t=(e.view()||[]).length,n=He(e,{}),i=this._createShape(n,{});if(!this.trigger("add",{shape:i}))e.insert(t,n),this._inactiveShapeItems.getByUid(n.uid).element=i,this.edit(i)}},_createShape:function(e,t){return(t=l({},this.options.shapeDefaults,t)).dataItem=e,new be(t,this)},createConnection:function(){if(this.editor&&this.editor.end()||!this.editor){var e=this.connectionsDataSource,t=(e.view()||[]).length,n=He(e,{}),i=this._createConnection(n);this.trigger("add",{connection:i})||(this._connectionsDataMap[n.uid]=i,e.insert(t,n),this.addConnection(i,!1),this.edit(i))}},_createConnection:function(e,t,n){var i=l({},this.options.connectionDefaults);return i.dataItem=e,new ye(t||new C,n||new C,i)},editModel:function(e,t){var n,i;this.cancelEdit();var r=this.options.editable;if("shape"==t)n=r.shapeEditors,i=r.shapeTemplate;else{if("connection"!=t)return;var o=Te.bind(this);n=l({},{from:o,to:o},r.connectionEditors),i=r.connectionTemplate}this.editor=new Se(this.element,{update:this._update.bind(this),cancel:this._cancel.bind(this),model:e,type:t,target:this,editors:n,template:i}),this.trigger("edit",this._editArgs())},edit:function(e){if(e.dataItem){var t=e instanceof be?"shape":"connection";this.editModel(e.dataItem,t)}},cancelEdit:function(){this.editor&&(this._getEditDataSource().cancelChanges(this.editor.model),this._destroyEditor())},saveEdit:function(){this.editor&&this.editor.end()&&!this.trigger("save",this._editArgs())&&this._getEditDataSource().sync()},_update:function(){this.editor&&this.editor.end()&&!this.trigger("save",this._editArgs())&&(this._getEditDataSource().sync(),this._destroyEditor())},_cancel:function(){if(this.editor&&!this.trigger("cancel",this._editArgs())){var e=this.editor.model;this._getEditDataSource().cancelChanges(e);var t=this._connectionsDataMap[e.uid]||this._dataMap[e.id];t&&t._setOptionsFromModel(e),this._destroyEditor()}},_getEditDataSource:function(){return"shape"===this.editor.options.type?this.dataSource:this.connectionsDataSource},_editArgs:function(){var e={container:this.editor.wrapper};return e[this.editor.options.type]=this.editor.model,e},_destroyEditor:function(){this.editor&&(this.editor.close(),this.editor=null)},_initElements:function(){this.wrapper=this.element.empty().css("position","relative").attr("tabindex",0).addClass("k-widget k-diagram"),this.scrollable=e("<div />").appendTo(this.element)},_initDefaults:function(e){var t=this.options,n=t.editable,i=t.shapeDefaults,r=t.connectionDefaults,o=(e||{}).shapeDefaults;!1===n?(i.editable=!1,r.editable=!1):(Re(n,i.editable,["drag","remove","connect"]),Re(n,r.editable,["drag","remove"])),o&&o.connectors&&(t.shapeDefaults.connectors=o.connectors)},_interactionDefaults:function(){var e=this.options,t=e.selectable,n=e.pannable,i=kendo.support.mobileOS;t&&!N(t.multiple)&&(e.selectable=l({multiple:!i},e.selectable)),n&&!N(n.key)&&(e.pannable=l({key:i?"none":"ctrl"},e.pannable))},_initCanvas:function(){var t=e("<div class='k-layer'></div>").appendTo(this.scrollable)[0],n=this.viewport();this.canvas=new p(t,{width:n.width||600,height:n.height||600})},_createHandlers:function(){var e=this;e.element.on(ue,e._wheel.bind(e)).on("keydown"+G,e._keydown.bind(e)),e._userEvents=new kendo.UserEvents(this.scrollable,{multiTouch:!0,fastTap:!0,tap:e._tap.bind(e),start:e._dragStart.bind(e),move:e._drag.bind(e),end:e._dragEnd.bind(e),gesturestart:e._gestureStart.bind(e),gesturechange:e._gestureChange.bind(e),gestureend:e._gestureEnd.bind(e),doubleTap:e._doubleTap.bind(e),supportDoubleTap:!0}),e.toolService=new A(e),this.scrollable.on("mouseover"+G,e._mouseover.bind(e)).on("mouseout"+G,e._mouseout.bind(e)).on("mousemove"+G,e._mouseMove.bind(e)).on("mousedown"+G,e._mouseDown.bind(e)).on("mouseup"+G,e._mouseUp.bind(e)),this._syncHandler=e._syncChanges.bind(e),e._resizeHandler=e.resize.bind(e,!1),kendo.onResize(e._resizeHandler),this.bind(re,e._destroyToolBar.bind(e)),this.bind(ie,e._destroyToolBar.bind(e))},_dragStart:function(e){this._pauseMouseHandlers=!0;var t=this._eventPositions(e,!0),n=e.event;this.toolService.start(t,this._meta(n))&&(this._destroyToolBar(),n.preventDefault())},_drag:function(e){var t=this._eventPositions(e),n=e.event;this.toolService.move(t,this._meta(n))&&n.preventDefault()},_dragEnd:function(e){this._pauseMouseHandlers=!1;var t=this._eventPositions(e),n=e.event;this.toolService.end(t,this._meta(n))&&(this._createToolBar(),n.preventDefault())},_mouseMove:function(e){if(!this._pauseMouseHandlers){var t=this._eventPositions(e);this.toolService._updateHoveredItem(t),this.toolService._updateCursor(t)}},_mouseDown:function(){this._pauseMouseHandlers=!0},_mouseUp:function(){this._pauseMouseHandlers=!1},_tap:function(e){var t=this.toolService,n=this.options.selectable,i=this._eventPositions(e),r=this.focus();if(t._updateHoveredItem(i),t.hoveredItem){var o=t.hoveredItem;if(this.trigger("click",{item:o,point:i,meta:this._meta(e.event)}),n&&!1!==o.options.selectable){var a=!1!==n.multiple,s=kendo.support.mobileOS||this._meta(e.event).ctrlKey;o.isSelected?s?(this._destroyToolBar(),o.select(!1)):this._createToolBar(r):(this._destroyToolBar(),this.select(o,{addToSelection:a&&s}),this._createToolBar(r))}}else n&&(this._destroyToolBar(),this.deselect())},_keydown:function(e){this.toolService.keyDown(e.keyCode,this._meta(e))&&e.preventDefault()},_wheel:function(e){var t=function(e){var t=e.originalEvent,n=0;return t.wheelDelta?n=(n=-t.wheelDelta/40)>0?q.ceil(n):q.floor(n):t.detail&&(n=t.detail),n}(e),n=this._eventPositions(e),i=l(this._meta(e),{delta:t});this.toolService.wheel(n,i)&&e.preventDefault()},_meta:function(e){return{ctrlKey:e.ctrlKey,metaKey:e.metaKey,altKey:e.altKey,shiftKey:e.shiftKey,type:e.type}},_eventPositions:function(e,t){var n;if(e.touch){var i=t?"startLocation":"location";n=new C(e.x[i],e.y[i])}else{var r=e.originalEvent;n=new C(r.pageX,r.pageY)}return this.documentToModel(n)},_gestureStart:function(e){this._destroyToolBar(),this.scroller.disable();var t=this.documentToModel(new C(e.center.x,e.center.y)),n={point:t,zoom:this.zoom()};this.trigger(re,n)||(this._gesture=e,this._initialCenter=t)},_gestureChange:function(e){var t=this._gesture,n=this._initialCenter,i=this.documentToView(new C(e.center.x,e.center.y)),r=e.distance/t.distance,o=this._zoom,a=!1;q.abs(r-1)>=.05&&(this._zoom=o=this._getValidZoom(o*r),this.options.zoom=o,this._gesture=e,a=!0);var s=n.times(o),l=i.minus(s);(a||this._pan.distanceTo(l)>=5)&&(this._panTransform(l),this._updateAdorners()),e.preventDefault()},_doubleTap:function(e){var t=this,n=this._eventPositions(e),i=t.options,r=i.zoomRate,o=t.zoom()+r,a={point:n,meta:this._meta(e),zoom:o};t.trigger(re,a)||(o=kendo.drawing.util.round(Math.max(i.zoomMin,Math.min(i.zoomMax,o)),2),a.zoom=o,t.zoom(o,a),t.trigger(oe,a))},_gestureEnd:function(){!1!==this.options.pannable&&this.scroller.enable(),this.trigger(oe,{point:this._initialCenter,zoom:this.zoom()})},_resize:function(){var e=this.viewport();this.canvas&&this.canvas.size(e),this.scrollable&&this.toolBar&&this.scrollable.height(e.height)},_mouseover:function(e){var t=e.target._kendoNode;t&&t.srcElement._hover&&t.srcElement._hover(!0,t.srcElement)},_mouseout:function(e){var t=e.target._kendoNode;t&&t.srcElement._hover&&t.srcElement._hover(!1,t.srcElement)},_initTheme:function(){var e,t=this,i=((t.options||{}).theme||"").toLowerCase(),r=n.ui.themes||{};e=-1!=n.SASS_THEMES.indexOf(i)?n.autoTheme().diagram:(r[i]||{}).diagram,t.options=l({},e,t.options),!0===t.options.editable&&l(t.options,{editable:(e||{}).editable})},_createOptionElements:function(){var e=this.options,t=e.shapes.length;t&&this._createShapes(),e.connections.length&&this._createConnections(),t&&e.layout&&this.layout(e.layout)},_createShapes:function(){var e,t,n=this.options.shapes;for(t=0;t<n.length;t++)e=n[t],this.addShape(e)},_createConnections:function(){var e,t,n,i,r=this,o=r.options,a=o.connectionDefaults,s=o.connections;for(i=0;i<s.length;i++)e=s[i],t=r._findConnectionTarget(e.from),n=r._findConnectionTarget(e.to),r.connect(t,n,l({},a,e))},_findConnectionTarget:function(e){var t,n=W(e=e||{})?e:e.shapeId||e.id;return n?(t=this.getShapeById(n),e.connector&&(t=t.getConnector(e.connector))):t=new C(e.x||0,e.y||0),t},destroy:function(){var e=this;a.fn.destroy.call(e),this._userEvents&&this._userEvents.destroy(),kendo.unbindResize(e._resizeHandler),e.clear(),e.element.off(G),e.scroller.wrapper.off(G),e.canvas.destroy(!0),e.canvas=t,e._destroyEditor(),e.destroyScroller(),e._destroyGlobalToolBar(),e._destroyToolBar()},destroyScroller:function(){var e=this.scroller;e&&(e.destroy(),e.element.remove(),this.scroller=null)},save:function(){var e,t,n,i={shapes:[],connections:[]};for(e=0;e<this.shapes.length;e++)(n=this.shapes[e]).options.serializable&&i.shapes.push(n.options);for(e=0;e<this.connections.length;e++)t=this.connections[e],i.connections.push(l({},t.options,t.toJSON()));return i},focus:function(){if(!this.element.is(kendo._activeElement())){var e,t=this.element,n=t[0],i=[],r=[],o=document.documentElement;do{(n=n.parentNode).scrollHeight>n.clientHeight&&(i.push(n),r.push(n.scrollTop))}while(n!=o);for(t.trigger("focus"),e=0;e<i.length;e++)i[e].scrollTop=r[e];return!0}},load:function(e){this.clear(),this.setOptions(e),this._createShapes(),this._createConnections()},setOptions:function(e){l(this.options,e)},clear:function(){var e=this;e.select(!1),e.mainLayer.clear(),e._shapesQuadTree.clear(),e._initialize()},connect:function(e,t,n){var i;if(this.connectionsDataSource&&this._isEditable){var r=this.connectionsDataSource.add({});(i=this._connectionsDataMap[r.uid]).source(e),i.target(t),i.redraw(n),i.updateModel()}else i=new ye(e,t,l({},this.options.connectionDefaults,n)),this.addConnection(i);return i},connected:function(e,t){for(var n=0;n<this.connections.length;n++){var i=this.connections[n];if(i.from==e&&i.to==t)return!0}return!1},addConnection:function(e,t){return!1!==t&&this.undoRedoService.add(new o.AddConnectionUnit(e,this),!1),e.diagram=this,e._setOptionsFromModel(),e.refresh(),this.mainLayer.append(e.visual),this.connections.push(e),this.trigger(Q,{added:[e],removed:[]}),e},_addConnection:function(e,t){var n,i=this.connectionsDataSource;if(i&&this._isEditable){if(n=He(i,ze(e.dataItem)),e.dataItem=n,e.updateModel(),!this.trigger("add",{connection:e}))return this._connectionsDataMap[n.uid]=e,i.add(n),this.addConnection(e,t),e._updateConnectors(),e}else if(!this.trigger("add",{connection:e}))return this.addConnection(e,t),e._updateConnectors(),e},addShape:function(e,t){var n,i=this.options.shapeDefaults;if(e instanceof be)n=e,this._parseBounds(n.bounds());else{if(e instanceof kendo.Class)return;i=l({},i,e||{}),n=new be(i,this),this._parseBounds(n.bounds())}return!1!==t&&this.undoRedoService.add(new o.AddShapeUnit(n,this),!1),this.shapes.push(n),n.diagram!==this&&(this._shapesQuadTree.insert(n),n.diagram=this),this.mainLayer.append(n.visual),this.trigger(Q,{added:[n],removed:[]}),n},_addShape:function(e,t){var n,i=this.dataSource;if(i&&this._isEditable){if(n=He(i,ze(e.dataItem)),e.dataItem=n,e.updateModel(),!this.trigger("add",{shape:e})){this.dataSource.add(n);var r=this._inactiveShapeItems.getByUid(n.uid);return r.element=e,r.undoable=t,e}}else if(!this.trigger("add",{shape:e}))return this.addShape(e,t)},_parseBounds:function(e){e.x="string"==typeof e.x?parseFloat(e.x):e.x,e.y="string"==typeof e.y?parseFloat(e.y):e.y},remove:function(e,t){var n,i=Pe(e=$(e)?e.slice(0):[e]),r=i.shapes,o=i.connections;for(N(t)||(t=!0),t&&this.undoRedoService.begin(),this._suspendModelRefresh(),n=r.length-1;n>=0;n--)this._removeItem(r[n],t,o);for(n=o.length-1;n>=0;n--)this._removeItem(o[n],t);this._resumeModelRefresh(),t&&this.undoRedoService.commit(!1),this.trigger(Q,{added:[],removed:e})},_removeShapeDataItem:function(e){this._isEditable&&(this.dataSource.remove(e.dataItem),delete this._dataMap[e.dataItem.id])},_removeConnectionDataItem:function(e){this._isEditable&&(this.connectionsDataSource.remove(e.dataItem),delete this._connectionsDataMap[e.dataItem.uid])},_triggerRemove:function(e){for(var t,n,i,r=[],o=0;o<e.length;o++)i=(t=e[o]).options.editable,n=t instanceof be?{shape:t}:{connection:t},i&&!1!==i.remove&&!this.trigger("remove",n)&&r.push(t);return r},undo:function(){this.undoRedoService.undo()},redo:function(){this.undoRedoService.redo()},select:function(e,t){if(!V(e))return this._selectedItems;var n,i,r=[],o=[];for((t=l({addToSelection:!1},t)).addToSelection||this.deselect(),this._internalSelection=!0,e instanceof Array?r=e:e instanceof ve&&(r=[e]),n=0;n<r.length;n++)(i=r[n]).select(!0)&&o.push(i);this._selectionChanged(o,[]),this._internalSelection=!1},selectAll:function(){this.select(this.shapes.concat(this.connections))},selectArea:function(e){var t,n,i;this._internalSelection=!0;var r=[];if(e instanceof _)for(n=this.shapes.concat(this.connections),t=0;t<n.length;t++)i=n[t],e&&!i._hitTest(e)||!i.options.enable||i.select(!0)&&r.push(i);this._selectionChanged(r,[]),this._internalSelection=!1},deselect:function(e){this._internalSelection=!0;var t,n,i=[],r=[];for(e instanceof Array?r=e:e instanceof ve?r.push(e):V(e)||(r=this._selectedItems.slice(0)),n=0;n<r.length;n++)(t=r[n]).select(!1)&&i.push(t);this._selectionChanged([],i),this._internalSelection=!1},toFront:function(e,t){e||(e=this._selectedItems.slice());var n,i=this._getDiagramItems(e);if(!N(t)||t){n=ge(this.mainLayer,i.visuals);var r=new R(this,e,n);this.undoRedoService.add(r)}else this.mainLayer.toFront(i.visuals),this._fixOrdering(i,!0)},toBack:function(e,t){e||(e=this._selectedItems.slice());var n,i=this._getDiagramItems(e);if(!N(t)||t){n=ge(this.mainLayer,i.visuals);var r=new F(this,e,n);this.undoRedoService.add(r)}else this.mainLayer.toBack(i.visuals),this._fixOrdering(i,!1)},bringIntoView:function(e,t){var n,i,r,a,s=this.viewport(),c=new o.RectAlign(s);0!==s.width&&0!==s.height&&("none"==(t=l({animate:!1,align:"center middle"},t)).align&&(t.align="center middle"),e instanceof ve?i=e.bounds(ce):$(e)?i=this.boundingBox(e):e instanceof _&&(i=e.clone()),r=i.clone(),i.zoom(this._zoom),(i.width>s.width||i.height>s.height)&&(this._zoom=this._getValidZoom(q.min(s.width/r.width,s.height/r.height)),i=r.clone().zoom(this._zoom)),this._zoomMainLayer(),n=i.clone(),c.align(i,t.align),a=i.topLeft().minus(n.topLeft()),this.pan(a.times(-1),t.animate))},alignShapes:function(e){O(e)&&(e="Left");var t,n,i,r=this.select();if(0!==r.length){switch(e.toLowerCase()){case"left":case"top":t=se;break;case"right":case"bottom":t=le}for(i=0;i<r.length;i++)if((n=r[i])instanceof be)switch(e.toLowerCase()){case"left":t=q.min(t,n.options.x);break;case"top":t=q.min(t,n.options.y);break;case"right":t=q.max(t,n.options.x);break;case"bottom":t=q.max(t,n.options.y)}var a=[],s=[];for(i=0;i<r.length;i++)if((n=r[i])instanceof be)switch(s.push(n),a.push(n.bounds()),e.toLowerCase()){case"left":case"right":n.position(new C(t,n.options.y));break;case"top":case"bottom":n.position(new C(n.options.x,t))}var l=new o.TransformUnit(s,a);this.undoRedoService.add(l,!1)}},zoom:function(e,t){if(e){var n=t?t.point:new o.Point(0,0);if(e=this._zoom=this._getValidZoom(e),!O(n)){var i=(n=new o.Point(q.round(n.x),q.round(n.y))).times(e),r=this.modelToView(n).minus(i);this._storePan(new o.Point(q.round(r.x),q.round(r.y)))}t&&(t.zoom=e),this._panTransform(),this.canvas.surface.hideTooltip(),this._updateAdorners()}return this._zoom},_getPan:function(e){return this.canvas.translate||(e=e.plus(this._pan)),e},pan:function(e,t){if(!(e instanceof C))return this._pan.times(-1);var n=this,i=n.scroller;e=(e=n._getPan(e)).times(-1),t?i.animatedScrollTo(e.x,e.y,(function(){n._updateAdorners()})):(i.scrollTo(e.x,e.y),n._updateAdorners())},viewport:function(){var e=this.element,t=e.width(),n=e.height();return this.toolBar&&(n-=d(this.toolBar.element)),new _(0,0,t,n)},copy:function(){if(this.options.copy.enabled){this._clipboard=[],this._copyOffset=1;for(var e=0;e<this._selectedItems.length;e++){var t=this._selectedItems[e];this._clipboard.push(t)}}},cut:function(){if(this.options.copy.enabled){this._clipboard=[],this._copyOffset=0;for(var e=0;e<this._selectedItems.length;e++){var t=this._selectedItems[e];this._clipboard.push(t)}this.remove(this._clipboard,!0)}},paste:function(){if(this._clipboard.length>0){var e,t,n,i={},r=Pe(this._clipboard),o=r.connections,a=r.shapes,s={x:this._copyOffset*this.options.copy.offsetX,y:this._copyOffset*this.options.copy.offsetY};for(this.deselect(),n=0;n<a.length;n++)t=(e=a[n]).clone(),i[e.id]=t,t.position(new C(e.options.x+s.x,e.options.y+s.y)),t.diagram=this,(t=this._addShape(t))&&t.select();for(n=0;n<o.length;n++)e=o[n],(t=this._addConnection(e.clone()))&&(this._updateCopiedConnection(t,e,"source",i,s),this._updateCopiedConnection(t,e,"target",i,s),t.select(!0),t.updateModel());this._syncChanges(),this._copyOffset+=1}},_updateCopiedConnection:function(e,t,n,i,r){var o,a,s,l=t[n](),c=this;l instanceof _e&&i[l.shape.id]?(s=i[l.shape.id],c.getShapeById(s.id)?e[n](s.getConnector(l.options.name)):(a=c._inactiveShapeItems.getByUid(s.dataItem.uid))&&(o=function(t){s=c._dataMap[t.id],e[n](s.getConnector(l.options.name)),e.updateModel()},c._deferredConnectionUpdates.push(a.onActivate(o)))):e[n](new C(t[n+"Point"]().x+r.x,t[n+"Point"]().y+r.y))},boundingBox:function(e,t){var n,i=_.empty(),r=V(e)?this._getDiagramItems(e):{shapes:this.shapes};if(r.shapes.length>0){var o=r.shapes[0];i=o.bounds(de);for(var a=1;a<r.shapes.length;a++)n=(o=r.shapes[a]).bounds(de),!0===t&&(n.x-=o._rotationOffset.x,n.y-=o._rotationOffset.y),i=i.union(n)}return i},_containerOffset:function(){var e=this.element.offset();return this.toolBar&&(e.top+=d(this.toolBar.element)),e},documentToView:function(e){var t=this._containerOffset();return new C(e.x-t.left,e.y-t.top)},viewToDocument:function(e){var t=this._containerOffset();return new C(e.x+t.left,e.y+t.top)},viewToModel:function(e){return this._transformWithMatrix(e,this._matrixInvert)},modelToView:function(e){return this._transformWithMatrix(e,this._matrix)},modelToLayer:function(e){return this._transformWithMatrix(e,this._layerMatrix)},layerToModel:function(e){return this._transformWithMatrix(e,this._layerMatrixInvert)},documentToModel:function(e){var t=this.documentToView(e);return this.canvas.translate||(t.x=t.x+this.scroller.scrollLeft,t.y=t.y+this.scroller.scrollTop),this.viewToModel(t)},modelToDocument:function(e){return this.viewToDocument(this.modelToView(e))},_transformWithMatrix:function(e,t){var n=e;if(e instanceof C)t&&(n=t.apply(e));else{var i=this._transformWithMatrix(e.topLeft(),t),r=this._transformWithMatrix(e.bottomRight(),t);n=_.fromPoints(i,r)}return n},setDataSource:function(e){this.options.dataSource=e,this._dataSource(),this.options.autoBind&&this.dataSource.fetch()},setConnectionsDataSource:function(e){this.options.connectionsDataSource=e,this._connectionDataSource(),this.options.autoBind&&this.connectionsDataSource.fetch()},layout:function(e){var t,n;switch(this._layouting=!0,O(e)&&(e=this.options.layout),(t=O(e)||O(e.type)?"Tree":e.type).toLowerCase()){case"tree":n=new o.TreeLayout(this);break;case"layered":n=new o.LayeredLayout(this);break;case"forcedirected":case"force":case"spring":case"springembedder":n=new o.SpringLayout(this);break;default:throw"Layout algorithm '"+t+"' is not supported."}var i=new o.LayoutState(this),r=n.layout(e);if(r){var a=new o.LayoutUndoUnit(i,r,e?e.animate:null);this.undoRedoService.add(a)}this._layouting=!1,this._redrawConnections()},getShapeById:function(e){var t;return(t=P.first(this.shapes,(function(t){return t.visual.id===e})))?t:t=P.first(this.connections,(function(t){return t.visual.id===e}))},getShapeByModelId:function(e){return this._isEditable?this._dataMap[e]:P.first(this.shapes,(function(t){return(t.dataItem||{}).id===e}))},getShapeByModelUid:function(e){return this._isEditable?P.first(this.shapes,(function(t){return(t.dataItem||{}).uid===e})):this._dataMap[e]},getConnectionByModelId:function(e){var t;return this.connectionsDataSource&&(t=P.first(this.connections,(function(t){return(t.dataItem||{}).id===e}))),t},getConnectionByModelUid:function(e){var t;return this.connectionsDataSource&&(t=this._connectionsDataMap[e]),t},_extendLayoutOptions:function(e){e.layout&&(e.layout=l({},o.LayoutBase.fn.defaultOptions||{},e.layout))},_selectionChanged:function(e,t){(e.length||t.length)&&this.trigger(te,{selected:e,deselected:t})},_getValidZoom:function(e){return q.min(q.max(e,this.options.zoomMin),this.options.zoomMax)},_panTransform:function(e){var t=this,n=e||t._pan;t.canvas.translate?(t.scroller.scrollTo(n.x,n.y),t._zoomMainLayer()):(t._storePan(n),t._transformMainLayer())},_finishPan:function(){this.trigger(ie,{total:this._pan,delta:Number.NaN})},_storePan:function(e){this._pan=e,this._storeViewMatrix()},_zoomMainLayer:function(){var e=this._zoom,t=new v(0,0,e,e);t.render(this.mainLayer),this._storeLayerMatrix(t),this._storeViewMatrix()},_transformMainLayer:function(){var e=this._pan,t=this._zoom,n=new v(e.x,e.y,t,t);n.render(this.mainLayer),this._storeLayerMatrix(n),this._storeViewMatrix()},_storeLayerMatrix:function(e){this._layerMatrix=e.toMatrix(),this._layerMatrixInvert=e.invert().toMatrix()},_storeViewMatrix:function(){var e=this._pan,t=this._zoom,n=new v(e.x,e.y,t,t);this._matrix=n.toMatrix(),this._matrixInvert=n.invert().toMatrix()},_toIndex:function(e,t){var n=this._getDiagramItems(e);this.mainLayer.toIndex(n.visuals,t),this._fixOrdering(n,!1)},_fixOrdering:function(e,t){var n,i,r=t?this.shapes.length-1:0,o=t?this.connections.length-1:0;for(n=0;n<e.shapes.length;n++)i=e.shapes[n],P.remove(this.shapes,i),P.insert(this.shapes,i,r);for(n=0;n<e.cons.length;n++)i=e.cons[n],P.remove(this.connections,i),P.insert(this.connections,i,o)},_getDiagramItems:function(e){var t,n={},i=e;for(n.visuals=[],n.shapes=[],n.cons=[],e?$(e)||(i=[e]):i=this._selectedItems.slice(),t=0;t<i.length;t++){var r=i[t];r instanceof be?(n.shapes.push(r),n.visuals.push(r.visual)):r instanceof ye&&(n.cons.push(r),n.visuals.push(r.visual))}return n},_removeItem:function(e,t,n){e.select(!1),e instanceof be?(this._removeShapeDataItem(e),this._removeShape(e,t,n)):e instanceof ye&&(this._removeConnectionDataItem(e),this._removeConnection(e,t)),this.mainLayer.remove(e.visual)},_removeShape:function(e,t,i){var r,o,a,s=[],l=[];for(this.toolService._removeHover(),t&&this.undoRedoService.addCompositeItem(new y(e)),P.remove(this.shapes,e),this._shapesQuadTree.remove(e),r=0;r<e.connectors.length;r++){a=e.connectors[r];for(var c=0;c<a.connections.length;c++)o=a.connections[c],i&&n.inArray(o,i)||(o.sourceConnector==a?s.push(o):o.targetConnector==a&&l.push(o))}for(r=0;r<s.length;r++)s[r].source(null,t),s[r].updateModel();for(r=0;r<l.length;r++)l[r].target(null,t),l[r].updateModel()},_removeConnection:function(e,t){e.sourceConnector&&P.remove(e.sourceConnector.connections,e),e.targetConnector&&P.remove(e.targetConnector.connections,e),t&&this.undoRedoService.addCompositeItem(new w(e)),P.remove(this.connections,e)},_removeDataItems:function(e,t){var n,i,r,o;for(e=$(e)?e:[e];e.length;)if(n=e.shift(),(r=this._dataMap[n.uid])&&(this._removeShapeConnections(r),this._removeItem(r,!1),delete this._dataMap[n.uid],t&&n.hasChildren&&n.loaded()))for(i=n.children.data(),o=0;o<i.length;o++)e.push(i[o])},_removeShapeConnections:function(e){var t,n=e.connections();if(n)for(t=0;t<n.length;t++)this._removeItem(n[t],!1)},_addDataItem:function(e,t){if(N(e)){var n=this._dataMap[e.id];if(n)return n;var i=l({},this.options.shapeDefaults);return i.dataItem=e,n=new be(i,this),this.addShape(n,!1!==t),this._dataMap[e.id]=n,n}},_addDataItemByUid:function(e){if(N(e)){var t=this._dataMap[e.uid];if(t)return t;var n=l({},this.options.shapeDefaults);return n.dataItem=e,t=new be(n,this),this.addShape(t),this._dataMap[e.uid]=t,t}},_addDataItems:function(e,t){var n,i,r,o;for(i=0;i<e.length;i++)n=e[i],r=this._addDataItemByUid(n),(o=this._addDataItemByUid(t))&&!this.connected(o,r)&&this.connect(o,r)},_refreshSource:function(e){var t,n,i=this,r=e.node,o=e.action,a=e.items,s=i.options;if(e.field)for(t=0;t<a.length;t++)this._dataMap[a[t].uid]&&this._dataMap[a[t].uid].redrawVisual();else{if("remove"==o)this._removeDataItems(e.items,!0);else for(o&&"itemloaded"!==o||this._bindingRoots||(this._bindingRoots=!0,n=!0),o||r||i.clear(),this._addDataItems(a,r),t=0;t<a.length;t++)a[t].load();s.layout&&(n||"remove"==o||"add"==o)&&i.layout(s.layout),n&&(this.trigger("dataBound"),this._bindingRoots=!1)}},_addItem:function(e){e instanceof be?this.addShape(e):e instanceof ye&&this.addConnection(e)},_createToolBar:function(e){var t=this.toolService.diagram;if(!this.singleToolBar&&1===t.select().length){var n=t.select()[0];if(n&&!1!==n.options.editable){var i=n.options.editable,r=i.tools;if(this._isEditable&&0===r.length&&(n instanceof be?r=["edit","rotateClockwise","rotateAnticlockwise"]:n instanceof ye&&(r=["edit"]),i&&!1!==i.remove&&r.push("delete")),r&&r.length){var o;this.singleToolBar=new xe(t,{tools:r,click:this._toolBarClick.bind(this),modal:!0,popupZIndex:parseInt(t.element.closest(".k-window").css("zIndex"),10)+10});var a=c(this.singleToolBar._popup.element),s=d(this.singleToolBar._popup.element);if(n instanceof be){var l=this.modelToView(n.bounds(de));o=new C(l.x,l.y).minus(new C((a-l.width)/2,s+20))}else if(n instanceof ye){var u=this.modelToView(n.bounds());o=new C(u.x,u.y).minus(new C((a-u.width-20)/2,s+20))}o?(this.canvas.translate||(o=o.minus(new C(this.scroller.scrollLeft,this.scroller.scrollTop))),o=this.viewToDocument(o),o=new C(q.max(o.x,0),q.max(o.y,0)),this.singleToolBar.showAt(o),e&&this.singleToolBar._popup.one("close",Le)):this._destroyToolBar()}}}},_toolBarClick:function(e){this.trigger("toolBarClick",e),this._destroyToolBar()},_normalizePointZoom:function(e){return e.times(1/this.zoom())},_initialize:function(){this.shapes=[],this._selectedItems=[],this.connections=[],this._dataMap={},this._connectionsDataMap={},this._inactiveShapeItems=new Ae,this._deferredConnectionUpdates=[],this.undoRedoService=new D({undone:this._syncHandler,redone:this._syncHandler}),this.id=o.randomId()},_fetchFreshData:function(){var e=this;e._dataSource(),e._isEditable&&e._connectionDataSource(),e.options.autoBind&&(e._isEditable?(this._loadingShapes=!0,this._loadingConnections=!0,e.dataSource.fetch(),e.connectionsDataSource.fetch()):e.dataSource.fetch())},_dataSource:function(){if(N(this.options.connectionsDataSource)){this._isEditable=!0;var e=this.options.dataSource||{},t=$(e)?{data:e}:e;this.dataSource&&this._shapesRefreshHandler?this.dataSource.unbind("change",this._shapesRefreshHandler).unbind("requestStart",this._shapesRequestStartHandler).unbind("error",this._shapesErrorHandler):(this._shapesRefreshHandler=this._refreshShapes.bind(this),this._shapesRequestStartHandler=this._shapesRequestStart.bind(this),this._shapesErrorHandler=this._error.bind(this)),this.dataSource=kendo.data.DataSource.create(t).bind("change",this._shapesRefreshHandler).bind("requestStart",this._shapesRequestStartHandler).bind("error",this._shapesErrorHandler)}else this._treeDataSource(),this._isEditable=!1},_connectionDataSource:function(){var e=this.options.connectionsDataSource;if(e){var t=$(e)?{data:e}:e;this.connectionsDataSource&&this._connectionsRefreshHandler?this.connectionsDataSource.unbind("change",this._connectionsRefreshHandler).unbind("requestStart",this._connectionsRequestStartHandler).unbind("error",this._connectionsErrorHandler):(this._connectionsRefreshHandler=this._refreshConnections.bind(this),this._connectionsRequestStartHandler=this._connectionsRequestStart.bind(this),this._connectionsErrorHandler=this._connectionsError.bind(this)),this.connectionsDataSource=kendo.data.DataSource.create(t).bind("change",this._connectionsRefreshHandler).bind("requestStart",this._connectionsRequestStartHandler).bind("error",this._connectionsErrorHandler)}},_shapesRequestStart:function(e){"read"==e.type&&(this._loadingShapes=!0)},_connectionsRequestStart:function(e){"read"==e.type&&(this._loadingConnections=!0)},_error:function(){this._loadingShapes=!1},_connectionsError:function(){this._loadingConnections=!1},_refreshShapes:function(e){"remove"===e.action?this._shouldRefresh()&&this._removeShapes(e.items):"itemchange"===e.action?this._shouldRefresh()&&this._updateShapes(e.items,e.field):"add"===e.action?this._inactiveShapeItems.add(e.items):"sync"===e.action?this._syncShapes(e.items):this.refresh()},_shouldRefresh:function(){return!this._suspended},_suspendModelRefresh:function(){this._suspended=(this._suspended||0)+1},_resumeModelRefresh:function(){this._suspended=q.max((this._suspended||0)-1,0)},refresh:function(){this._loadingShapes=!1,this._loadingConnections||this._rebindShapesAndConnections()},_rebindShapesAndConnections:function(){this.clear(),this._addShapes(this.dataSource.view()),this.connectionsDataSource&&this._addConnections(this.connectionsDataSource.view(),!1),this.options.layout?this.layout(this.options.layout):this._redrawConnections(),this.trigger("dataBound")},refreshConnections:function(){this._loadingConnections=!1,this._loadingShapes||this._rebindShapesAndConnections()},_redrawConnections:function(){for(var e=this.connections,t=0;t<e.length;t++)e[t].refresh()},_removeShapes:function(e){var t,n,i=this._dataMap;for(n=0;n<e.length;n++)i[(t=e[n]).id]&&(this.remove(i[t.id],!1),i[t.id]=null)},_syncShapes:function(){var e=this,t=e._inactiveShapeItems;t.forEach((function(n){var i=n.dataItem,r=n.element;i.isNew()||(r?(r._setOptionsFromModel(),e.addShape(r,n.undoable),e._dataMap[i.id]=r):e._addDataItem(i),n.activate(),t.remove(i))}))},_updateShapes:function(e,t){for(var n=0;n<e.length;n++){var i=e[n],r=this._dataMap[i.id];r&&r.updateOptionsFromModel(i,t)}},_addShapes:function(e){for(var t=0;t<e.length;t++)this._addDataItem(e[t],!1)},_refreshConnections:function(e){"remove"===e.action?this._shouldRefresh()&&this._removeConnections(e.items):"add"===e.action?this._addConnections(e.items):"sync"===e.action||("itemchange"===e.action?this._shouldRefresh()&&this._updateConnections(e.items):this.refreshConnections())},_removeConnections:function(e){for(var t=0;t<e.length;t++)this.remove(this._connectionsDataMap[e[t].uid],!1),this._connectionsDataMap[e[t].uid]=null},_updateConnections:function(e){for(var t=0;t<e.length;t++){var n=e[t];this._connectionsDataMap[n.uid].updateOptionsFromModel(n)}},_addConnections:function(e,t){for(var n=e.length,i=0;i<n;i++){var r=e[i];this._addConnectionDataItem(r,t)}},_addConnectionDataItem:function(e,t){if(!this._connectionsDataMap[e.uid]){var n=this._validateConnector(e.from);N(n)&&null!==n||(n=new C(e.fromX,e.fromY));var i=this._validateConnector(e.to);if(N(i)&&null!==i||(i=new C(e.toX,e.toY)),N(n)&&N(i)){var r=l({},this.options.connectionDefaults);r.dataItem=e;var o=new ye(n,i,r);this._connectionsDataMap[e.uid]=o,this.addConnection(o,t)}}},_validateConnector:function(e){var t;return N(e)&&null!==e&&(t=this._dataMap[e]),t},_treeDataSource:function(){var e=this,t=e.options.dataSource;if((t=$(t)?{data:t}:t)instanceof kendo.data.DataSource&&!(t instanceof kendo.data.HierarchicalDataSource))throw new Error("Incorrect DataSource type. If a single dataSource instance is set to the diagram then it should be a HierarchicalDataSource. You should set only the options instead of an instance or a HierarchicalDataSource instance or supply connectionsDataSource as well.");t.fields||(t.fields=[{field:"text"},{field:"url"},{field:"spriteCssClass"},{field:"imageUrl"}]),e.dataSource&&e._refreshHandler&&e._unbindDataSource(),e._refreshHandler=e._refreshSource.bind(e),e._errorHandler=e._error.bind(e),e.dataSource=h.create(t).bind(Q,e._refreshHandler).bind(Z,e._errorHandler)},_unbindDataSource:function(){var e=this;e.dataSource.unbind(Q,e._refreshHandler).unbind(Z,e._errorHandler)},_adorn:function(e,n){n!==t&&e&&(n?(this._adorners.push(e),this.adornerLayer.append(e.visual)):(P.remove(this._adorners,e),this.adornerLayer.remove(e.visual)))},_showConnectors:function(e,t){t?this._connectorsAdorner.show(e):this._connectorsAdorner.destroy()},_updateAdorners:function(){for(var e=this._adorners,t=0;t<e.length;t++){var n=e[t];n.refreshBounds&&n.refreshBounds(),n.refresh()}},_refresh:function(){for(var e=0;e<this.connections.length;e++)this.connections[e].refresh()},_destroyToolBar:function(){this.singleToolBar&&(this.singleToolBar.hide(),this.singleToolBar.destroy(),this.singleToolBar=null)},_destroyGlobalToolBar:function(){this.toolBar&&(this.toolBar.hide(),this.toolBar.destroy(),this.toolBar=null)},exportDOMVisual:function(){var e=this.canvas._viewBox,t=r.transform().translate(-e.x,-e.y),n=new r.Rect([0,0],[e.width,e.height]),o=i.Path.fromRect(n),a=new i.Group({transform:t}),s=new i.Group({clip:o}),l=this.canvas.drawingElement.children[0];return s.append(a),a.children.push(l),s},exportVisual:function(){var e=r.transform().scale(1/this._zoom),t=new i.Group({transform:e}),n=this.mainLayer.drawingElement;return t.children.push(n),t},_syncChanges:function(){this._syncShapeChanges(),this._syncConnectionChanges()},_syncShapeChanges:function(){this.dataSource&&this._isEditable&&this.dataSource.sync()},_syncConnectionChanges:function(){var t=this;t.connectionsDataSource&&t._isEditable&&(e.when.apply(e,t._deferredConnectionUpdates).then((function(){t.connectionsDataSource.sync()})),t.deferredConnectionUpdates=[])}});function ke(e){var t={};return N((e=e||{}).text)&&null!==e.text&&(t.text=e.text),N(e.x)&&null!==e.x&&(t.x=e.x),N(e.y)&&null!==e.y&&(t.y=e.y),N(e.width)&&null!==e.width&&(t.width=e.width),N(e.height)&&null!==e.height&&(t.height=e.height),N(e.type)&&null!==e.type&&(t.type=e.type),t}n.ExportMixin.extend(we.fn,!0),kendo.PDFMixin&&kendo.PDFMixin.extend(we.fn);var xe=kendo.Observable.extend({init:function(e,t){kendo.Observable.fn.init.call(this),this.diagram=e,this.options=l({},this.options,t),this._tools=[],this.createToolBar(),this.createTools(),this.appendTools(),this.options.modal&&this.createPopup(),this.bind(this.events,t)},events:["click"],createPopup:function(){this.container=e("<div/>").append(this.element),this._popup=this.container.kendoPopup({}).getKendoPopup()},appendTools:function(){for(var e=0;e<this._tools.length;e++){var t=this._tools[e];(t.buttons&&t.buttons.length||!N(t.buttons))&&this._toolBar.add(t)}},createToolBar:function(){this.element=e("<div/>"),this._toolBar=this.element.kendoToolBar({click:this.click.bind(this),resizable:!1}).getKendoToolBar(),this.element.css("border","none")},createTools:function(){for(var e=0;e<this.options.tools.length;e++)this.createTool(this.options.tools[e])},createTool:function(e){j(e)||(e={name:e});var t=e.name+"Tool";this[t]?this[t](e):this._tools.push(l({},e,{attributes:this._setAttributes({action:e.name})}))},showAt:function(e){var t=parseInt(this.options.popupZIndex,10);this._popup&&(this._popup.open(e.x,e.y),t&&this._popup.wrapper.css("zIndex",t))},hide:function(){this._popup&&this._popup.close()},newGroup:function(){return{type:"buttonGroup",buttons:[]}},editTool:function(){this._tools.push({icon:"pencil",showText:"overflow",type:"button",text:"Edit",attributes:this._setAttributes({action:"edit"})})},deleteTool:function(){this._tools.push({icon:"x",showText:"overflow",type:"button",text:"Delete",attributes:this._setAttributes({action:"delete"})})},rotateAnticlockwiseTool:function(e){this._appendGroup("rotate"),this._rotateGroup.buttons.push({icon:"rotate-left",showText:"overflow",text:"RotateAnticlockwise",group:"rotate",attributes:this._setAttributes({action:"rotateAnticlockwise",step:e.step})})},rotateClockwiseTool:function(e){this._appendGroup("rotate"),this._rotateGroup.buttons.push({icon:"rotate-right",attributes:this._setAttributes({action:"rotateClockwise",step:e.step}),showText:"overflow",text:"RotateClockwise",group:"rotate"})},createShapeTool:function(){this._appendGroup("create"),this._createGroup.buttons.push({icon:"shapes",showText:"overflow",text:"CreateShape",group:"create",attributes:this._setAttributes({action:"createShape"})})},createConnectionTool:function(){this._appendGroup("create"),this._createGroup.buttons.push({icon:"connector",showText:"overflow",text:"CreateConnection",group:"create",attributes:this._setAttributes({action:"createConnection"})})},undoTool:function(){this._appendGroup("history"),this._historyGroup.buttons.push({icon:"undo",showText:"overflow",text:"Undo",group:"history",attributes:this._setAttributes({action:"undo"})})},redoTool:function(){this._appendGroup("history"),this._historyGroup.buttons.push({icon:"redo",showText:"overflow",text:"Redo",group:"history",attributes:this._setAttributes({action:"redo"})})},_appendGroup:function(e){var t="_"+e+"Group";this[t]||(this[t]=this.newGroup(),this._tools.push(this[t]))},_setAttributes:function(e){var t={};return e.action&&(t[kendo.attr("action")]=e.action),e.step&&(t[kendo.attr("step")]=e.step),t},_getAttributes:function(e){var t={},n=e.attr(kendo.attr("action"));n&&(t.action=n);var i=e.attr(kendo.attr("step"));return i&&(t.step=i),t},click:function(t){var n=this._getAttributes(e(t.target)),i=n.action;i&&this[i]&&this[i](n),this.trigger("click",this.eventData(i,t.target))},eventData:function(e,t){for(var n,i=this.selectedElements(),r=i.length,o=[],a=[],s=0;s<r;s++)(n=i[s])instanceof be?o.push(n):a.push(n);return{shapes:o,connections:a,action:e,target:t}},delete:function(){var e=this.diagram._triggerRemove(this.selectedElements());e.length&&(this.diagram.remove(e,!0),this.diagram._syncChanges())},edit:function(){var e=this.selectedElements();1===e.length&&this.diagram.edit(e[0])},rotateClockwise:function(e){var t=parseFloat(e.step||90);this._rotate(t)},rotateAnticlockwise:function(e){var t=parseFloat(e.step||90);this._rotate(-t)},_rotate:function(e){var t=this.diagram._resizingAdorner;t.angle(t.angle()+e),t.rotate()},selectedElements:function(){return this.diagram.select()},createShape:function(){this.diagram.createShape()},createConnection:function(){this.diagram.createConnection()},undo:function(){this.diagram.undo()},redo:function(){this.diagram.redo()},destroy:function(){this.diagram=null,this.element=null,this.options=null,this._toolBar&&this._toolBar.destroy(),this._popup&&this._popup.destroy()}}),Ce=kendo.Observable.extend({init:function(e,t){kendo.Observable.fn.init.call(this),this.options=u(!0,{},this.options,t),this.element=e,this.model=this.options.model,this.fields=this._getFields(),this._initContainer(),this.createEditable()},options:{editors:{}},_initContainer:function(){this.wrapper=this.element},createEditable:function(){var e=this.options;this.editable=new kendo.ui.Editable(this.wrapper,{fields:this.fields,target:e.target,clearContainer:!1,model:this.model})},_isEditable:function(e){return this.model.editable&&this.model.editable(e)},_getFields:function(){var e=[],t=this.model.fields;for(var n in t){var i={};if(this._isEditable(n)){var r=this.options.editors[n];r&&(i.editor=r),i.field=n,e.push(i)}}return e},end:function(){return this.editable.end()},destroy:function(){this.editable.destroy(),this.editable.element.find("["+kendo.attr("container-for")+"]").empty(),this.model=this.wrapper=this.element=this.columns=this.editable=null}}),Se=Ce.extend({init:function(e,t){Ce.fn.init.call(this,e,t),this.bind(this.events,this.options),this.open()},events:["update","cancel"],options:{window:{modal:!0,resizable:!1,draggable:!0,title:"Edit",visible:!1}},_initContainer:function(){var t=this;this.wrapper=e('<div class="k-popup-edit-form"/>').attr(kendo.attr("uid"),this.model.uid);var n="";this.options.template?(n+=this._renderTemplate(),this.fields=[]):n+=this._renderFields(),n+=this._renderButtons(),this.wrapper.append(e('<div class="k-edit-form-container"/>').append(n)),this.window=new kendo.ui.Window(this.wrapper.appendTo(this.element),this.options.window),this.window.bind("close",(function(e){e.userTriggered&&(e.sender.element.trigger("focus"),t._cancelClick(e))})),this._attachButtonEvents()},_renderTemplate:function(){var e=this.options.template;return"string"==typeof e&&(e=kendo.unescape(e)),e=kendo.template(e)(this.model)},_renderFields:function(){for(var e="",t=0;t<this.fields.length;t++){var n=this.fields[t];e+='<div class="k-edit-label"><label for="'+n.field+'">'+(n.field||"")+"</label></div>",this._isEditable(n.field)&&(e+="<div "+kendo.attr("container-for")+'="'+n.field+'" class="k-edit-field"></div>')}return e},_renderButtons:function(){var e='<div class="k-edit-buttons">';return e+=this._createButton("update"),e+=this._createButton("cancel"),e+="</div>"},_createButton:function(e){return kendo.template(he)(pe[e])},_attachButtonEvents:function(){this._cancelClickHandler=this._cancelClick.bind(this),this.window.element.on(X+G,"button.k-diagram-cancel",this._cancelClickHandler),this._updateClickHandler=this._updateClick.bind(this),this.window.element.on(X+G,"button.k-diagram-update",this._updateClickHandler)},_updateClick:function(e){e.preventDefault(),this.trigger("update")},_cancelClick:function(e){e.preventDefault(),this.trigger("cancel")},open:function(){this.window.center().open()},close:function(){this.window.bind("deactivate",this.destroy.bind(this)).close()},destroy:function(){this.window.close().destroy(),this.window.element.off(X+G,"a.k-diagram-cancel",this._cancelClickHandler),this.window.element.off(X+G,"a.k-diagram-update",this._updateClickHandler),this._cancelClickHandler=null,this._editUpdateClickHandler=null,this.window=null,Ce.fn.destroy.call(this)}});function Te(t,n){var i=this.dataSource.reader.model;if(i){var r=i.fn.fields.text?"text":i.idField;e("<input name='"+n.field+"' />").appendTo(t).kendoDropDownList({dataValueField:i.idField,dataTextField:r,dataSource:this.dataSource.data().toJSON(),optionLabel:" ",valuePrimitive:!0})}}function De(e){this.dataItem=e,this.callbacks=[]}function Ae(){this.items={}}De.fn=De.prototype={onActivate:function(t){var n=e.Deferred();return this.callbacks.push({callback:t,deferred:n}),n},activate:function(){for(var e,t=this.callbacks,n=0;n<t.length;n++)(e=this.callbacks[n]).callback(this.dataItem),e.deferred.resolve();this.callbacks=[]}},Ae.fn=Ae.prototype={add:function(e){for(var t=0;t<e.length;t++)this.items[e[t].uid]=new De(e[t])},forEach:function(e){for(var t in this.items)e(this.items[t])},getByUid:function(e){return this.items[e]},remove:function(e){delete this.items[e.uid]}};var Me=s.extend({init:function(){this.shapes=[]},_add:function(e,t){this.shapes.push({bounds:t,shape:e}),e._quadNode=this},insert:function(e,t){this._add(e,t)},remove:function(e){for(var t=this.shapes,n=t.length,i=0;i<n;i++)if(t[i].shape===e){t.splice(i,1);break}},hitTestRect:function(e,t){for(var i=this.shapes,r=i.length,o=0;o<r;o++)if(this._testRect(i[o].shape,e)&&!n.inArray(i[o].shape,t))return!0},_testRect:function(e,t){var n=e.rotate().angle,i=e.bounds();return n?S.rects(t,i,-n):i.overlaps(t)}}),Ee=Me.extend({init:function(e){Me.fn.init.call(this),this.children=[],this.rect=e},inBounds:function(e){var t=this.rect,n=t.bottomRight(),i=e.bottomRight();return t.x<=e.x&&t.y<=e.y&&i.x<=n.x&&i.y<=n.y},overlapsBounds:function(e){return this.rect.overlaps(e)},insert:function(e,t){var n=!1,i=this.children,r=i.length;if(this.inBounds(t)){if(!r&&this.shapes.length<4)this._add(e,t);else{r||this._initChildren();for(var o=0;o<i.length;o++)if(i[o].insert(e,t)){n=!0;break}n||this._add(e,t)}n=!0}return n},_initChildren:function(){var e,t,n=this.rect,i=this.children,r=this.shapes,o=n.center(),a=n.width/2,s=n.height/2;for(i.push(new Ee(new _(n.x,n.y,a,s)),new Ee(new _(o.x,n.y,a,s)),new Ee(new _(n.x,o.y,a,s)),new Ee(new _(o.x,o.y,a,s))),t=r.length-1;t>=0;t--)for(e=0;e<i.length;e++)if(i[e].insert(r[t].shape,r[t].bounds)){r.splice(t,1);break}},hitTestRect:function(e,t){var n,i=this.children,r=i.length,o=!1;if(this.overlapsBounds(e))if(Me.fn.hitTestRect.call(this,e,t))o=!0;else for(n=0;n<r;n++)if(i[n].hitTestRect(e,t)){o=!0;break}return o}}),Ie=s.extend({ROOT_SIZE:1e3,init:function(e){var t=this._boundsChange.bind(this);e.bind(Y,t),e.bind(ne,t),this.initRoots()},initRoots:function(){this.rootMap={},this.root=new Me},clear:function(){this.initRoots()},_boundsChange:function(e){e.item._quadNode&&e.item._quadNode.remove(e.item),this.insert(e.item)},insert:function(e){var t=e.bounds(de),n=this.ROOT_SIZE,i=this.getSectors(t),r=i[0][0],o=i[1][0];this.inRoot(i)?this.root.insert(e,t):(this.rootMap[r]||(this.rootMap[r]={}),this.rootMap[r][o]||(this.rootMap[r][o]=new Ee(new _(r*n,o*n,n,n))),this.rootMap[r][o].insert(e,t))},remove:function(e){e._quadNode&&e._quadNode.remove(e)},inRoot:function(e){return e[0].length>1||e[1].length>1},getSectors:function(e){for(var t=this.ROOT_SIZE,n=e.bottomRight(),i=q.floor(n.x/t),r=q.floor(n.y/t),o=[[],[]],a=q.floor(e.x/t);a<=i;a++)o[0].push(a);for(var s=q.floor(e.y/t);s<=r;s++)o[1].push(s);return o},hitTestRect:function(e,t){var n,i,r,o,a,s=this.getSectors(e);if(this.root.hitTestRect(e,t))return!0;for(n=0;n<s[0].length;n++)for(r=s[0][n],i=0;i<s[1].length;i++)if(o=s[1][i],(a=(this.rootMap[r]||{})[o])&&a.hitTestRect(e,t))return!0;return!1}});function ze(e){var t=e;return e instanceof kendo.data.Model&&((t=e.toJSON())[e.idField]=e._defaultId),t}function Pe(e){var t,n,i=[],r=[];for(n=0;n<e.length;n++)(t=e[n])instanceof be?r.push(t):i.push(t);return{shapes:r,connections:i}}function He(e,t){return e.reader.model?new e.reader.model(t):new kendo.data.ObservableObject(t)}function Fe(e,t){N(t[e])&&t.set(e,null)}function Re(e,t,n){for(var i,r=0;r<n.length;r++)i=n[r],t&&!N(t[i])&&(t[i]=e[i])}function Le(e){e.preventDefault()}n.ui.plugin(we),l(o,{Shape:be,Connection:ye,Connector:_e,DiagramToolBar:xe,QuadNode:Ee,QuadRoot:Me,ShapesQuadTree:Ie,PopupEditor:Se})}(window.kendo.jQuery);kendo;!function(e){var t=Math,n=Array.isArray,i=window.kendo,r=i._outerHeight,o=i._outerWidth,a=i.Class,s=i.ui.Widget,l=i.template,c=i.deepExtend,d=i.data.HierarchicalDataSource,u=i.getter,h=i.dataviz,p=".kendoTreeMap",f="change",m="dataBound",g="itemCreated",v=Number.MAX_VALUE,_="mouseover"+p,b="mouseleave"+p,y=s.extend({init:function(t,n){i.destroy(t),e(t).empty(),s.fn.init.call(this,t,n),this.wrapper=this.element,this._initTheme(this.options),this.element.addClass("k-widget k-treemap"),this._setLayout(),this._originalOptions=c({},this.options),this._initDataSource(),this._attachEvents(),i.notify(this,h.ui)},options:{name:"TreeMap",theme:"sass",autoBind:!0,textField:"text",valueField:"value",colorField:"color"},events:[m,g],_initTheme:function(e){var t=((h.ui.themes||{})[((e||{}).theme||"").toLowerCase()]||{}).treeMap;this.options=c({},t,e)},_attachEvents:function(){this.element.on(_,this._mouseover.bind(this)).on(b,this._mouseleave.bind(this)),this._resizeHandler=this.resize.bind(this,!1),i.onResize(this._resizeHandler)},_setLayout:function(){"horizontal"===this.options.type?(this._layout=new x(!1),this._view=new C(this,this.options)):"vertical"===this.options.type?(this._layout=new x(!0),this._view=new C(this,this.options)):(this._layout=new w,this._view=new k(this,this.options))},_initDataSource:function(){var e=this,t=e.options.dataSource;e._dataChangeHandler=e._onDataChange.bind(e),e.dataSource=d.create(t).bind(f,e._dataChangeHandler),t&&e.options.autoBind&&e.dataSource.fetch()},setDataSource:function(e){var t=this;t.dataSource.unbind(f,t._dataChangeHandler),t.dataSource=e.bind(f,t._dataChangeHandler),e&&t.options.autoBind&&t.dataSource.fetch()},_onDataChange:function(e){var t,n,a=e.node,s=e.items,l=this.options;if(a){if(s.length){var c=this._getByUid(a.uid);for(c.children=[],s=new i.data.Query(s)._sortForGrouping(l.valueField,"desc"),n=0;n<s.length;n++)t=s[n],c.children.push(this._wrapItem(t));var d=this._view.htmlSize(c);this._layout.compute(c.children,c.coord,d),this._setColors(c.children),this._view.render(c)}}else this.element.empty(),t=this._wrapItem(s[0]),this._layout.createRoot(t,o(this.element),r(this.element),"vertical"===this.options.type),this._view.createRoot(t),this._root=t,this._colorIdx=0;for(n=0;n<s.length;n++)s[n].load();a&&this.trigger(m,{node:a})},_setColors:function(e){var t,i,r=this.options.colors,o=r[this._colorIdx%r.length];n(o)&&(t=function(e,t,n){var i=M(e),r=M(t),o=z(e)-z(t)<0,a=[];a.push(e);for(var s=0;s<n;s++){var l={r:D(i.r,r.r,s,n,o),g:D(i.g,r.g,s,n,o),b:D(i.b,r.b,s,n,o)};a.push(A(l))}return a.push(t),a}(o[0],o[1],e.length));for(var a=!1,s=0;s<e.length;s++)T((i=e[s]).color)||(i.color=t?t[s]:o),i.dataItem.hasChildren||(a=!0);a&&this._colorIdx++},_contentSize:function(e){this.view.renderHeight(e)},_wrapItem:function(e){var t={};return T(this.options.valueField)&&(t.value=S(this.options.valueField,e)),T(this.options.colorField)&&(t.color=S(this.options.colorField,e)),T(this.options.textField)&&(t.text=S(this.options.textField,e)),t.level=e.level(),t.dataItem=e,t},_getByUid:function(e){for(var t,n=[this._root];n.length;){if((t=n.pop()).dataItem.uid===e)return t;t.children&&(n=n.concat(t.children))}},dataItem:function(t){var n=e(t).attr(i.attr("uid")),r=this.dataSource;return r&&r.getByUid(n)},findByUid:function(e){return this.element.find(".k-treemap-tile["+i.attr("uid")+"='"+e+"']")},_mouseover:function(t){var n=e(t.target);n.hasClass("k-leaf")&&(this._removeActiveState(),n.removeClass("k-hover").addClass("k-hover"))},_removeActiveState:function(){this.element.find(".k-hover").removeClass("k-hover")},_mouseleave:function(){this._removeActiveState()},destroy:function(){s.fn.destroy.call(this),this.element.off(p),this.dataSource&&this.dataSource.unbind(f,this._dataChangeHandler),this._root=null,i.unbindResize(this._resizeHandler),i.destroy(this.element)},items:function(){return e()},getSize:function(){return i.dimensions(this.element)},_resize:function(){var e=this._root;if(e){var t=this.element,n=t.children();e.coord.width=o(t),e.coord.height=r(t),n.css({width:e.coord.width,height:e.coord.height}),this._resizeItems(e,n)}},_resizeItems:function(e,t){if(e.children&&e.children.length){var n,r,o=t.children(".k-treemap-wrap").children();this._layout.compute(e.children,e.coord,{text:this._view.titleSize(e,t)});for(var a=0;a<e.children.length;a++)n=e.children[a],r=o.filter("["+i.attr("uid")+"='"+n.dataItem.uid+"']"),this._view.setItemSize(n,r),this._resizeItems(n,r)}},setOptions:function(e){var t=e.dataSource;e.dataSource=undefined,this._originalOptions=c(this._originalOptions,e),this.options=c({},this._originalOptions),this._setLayout(),this._initTheme(this.options),s.fn._setEvents.call(this,e),t&&this.setDataSource(d.create(t)),this.options.autoBind&&this.dataSource.fetch()}}),w=a.extend({createRoot:function(e,t,n){e.coord={width:t,height:n,top:0,left:0}},leaf:function(e){return!e.children},layoutChildren:function(e,t){var n,i=t.width*t.height,r=0,o=[];for(n=0;n<e.length;n++)o[n]=parseFloat(e[n].value),r+=o[n];for(n=0;n<o.length;n++)e[n].area=i*o[n]/r;var a=this.layoutHorizontal()?t.height:t.width,s=[e[0]],l=e.slice(1);this.squarify(l,s,a,t)},squarify:function(e,t,n,i){this.computeDim(e,t,n,i)},computeDim:function(e,t,n,i){if(e.length+t.length!=1)if(e.length>=2&&0===t.length&&(t=[e[0]],e=e.slice(1)),0!==e.length){var r=e[0];if(this.worstAspectRatio(t,n)>=this.worstAspectRatio([r].concat(t),n))this.computeDim(e.slice(1),t.concat([r]),n,i);else{var o=this.layoutRow(t,n,i);this.computeDim(e,[],o.dim,o)}}else t.length>0&&this.layoutRow(t,n,i);else{var a=1==e.length?e:t;this.layoutLast(a,n,i)}},layoutLast:function(e,t,n){e[0].coord=n},layoutRow:function(e,t,n){return this.layoutHorizontal()?this.layoutV(e,t,n):this.layoutH(e,t,n)},orientation:"h",layoutVertical:function(){return"v"===this.orientation},layoutHorizontal:function(){return"h"===this.orientation},layoutChange:function(){this.orientation=this.layoutVertical()?"h":"v"},worstAspectRatio:function(e,n){if(!e||0===e.length)return v;for(var i=0,r=0,o=v,a=0;a<e.length;a++){var s=e[a].area;i+=s,o=o<s?o:s,r=r>s?r:s}return t.max(n*n*r/(i*i),i*i/(n*n*o))},compute:function(e,t,n){if(t.width>=t.height&&this.layoutHorizontal()||this.layoutChange(),e&&e.length>0){var i={width:t.width,height:t.height-n.text,top:0,left:0};this.layoutChildren(e,i)}},layoutV:function(e,n,i){var r=0;n=P(this._totalArea(e)/n);for(var o=0;o<e.length;o++){var a=P(e[o].area/n);e[o].coord={height:a,width:n,top:i.top+r,left:i.left},r+=a}var s={height:i.height,width:i.width-n,top:i.top,left:i.left+n};return s.dim=t.min(s.width,s.height),s.dim!=s.height&&this.layoutChange(),s},layoutH:function(e,n,i){for(var r=P(this._totalArea(e)/n),o=i.top,a=0,s=0;s<e.length;s++)e[s].coord={height:r,width:P(e[s].area/r),top:o,left:i.left+a},a+=e[s].coord.width;var l={height:i.height-r,width:i.width,top:i.top+r,left:i.left};return l.dim=t.min(l.width,l.height),l.dim!=l.width&&this.layoutChange(),l},_totalArea:function(e){for(var t=0,n=0;n<e.length;n++)t+=e[n].area;return t}}),k=a.extend({init:function(t,n){this.options=c({},this.options,n),this.treeMap=t,this.element=e(t.element),this.offset=0},titleSize:function(e,t){return t.children(".k-treemap-title").height()||0},htmlSize:function(e){var t=this._getByUid(e.dataItem.uid),n={text:0};if(e.children){if(this._clean(t),this._getText(e)){var i=this._createTitle(e);t.append(i),this._compile(i,e.dataItem),n.text=i.height()}t.append(this._createWrap()),this.offset=(o(t)-t.innerWidth())/2}return n},_compile:function(e,t){},_getByUid:function(e){return this.element.find(".k-treemap-tile["+i.attr("uid")+"='"+e+"']")},render:function(e){var t=this._getByUid(e.dataItem.uid),n=e.children;if(n)for(var i=t.find(".k-treemap-wrap"),r=0;r<n.length;r++){var o=n[r],a=this._createLeaf(o);i.append(a),this._compile(a.children(),o.dataItem),this.treeMap.trigger(g,{element:a})}},createRoot:function(e){var t=this._createLeaf(e);this.element.append(t),this._compile(t.children(),e.dataItem),this.treeMap.trigger(g,{element:t})},_clean:function(e){e.css("background-color",""),e.removeClass("k-leaf"),e.removeClass("k-inverse"),e.empty()},_createLeaf:function(t){return this._createTile(t).css("background-color",t.color).addClass("k-leaf").toggleClass("k-inverse",this._tileColorBrightness(t)>180).toggle(0!==t.value).append(e("<div></div>").html(this._getText(t)))},_createTile:function(t){var n=e("<div class='k-treemap-tile'></div>");return this.setItemSize(t,n),T(t.dataItem)&&T(t.dataItem.uid)&&n.attr(i.attr("uid"),t.dataItem.uid),n},_itemCoordinates:function(e){var t={width:e.coord.width,height:e.coord.height,left:e.coord.left,top:e.coord.top};return t.left&&this.offset?t.width+=2*this.offset:t.width+=this.offset,t.top?t.height+=2*this.offset:t.height+=this.offset,t},setItemSize:function(e,t){var n=this._itemCoordinates(e);t.css({width:n.width,height:n.height,left:n.left,top:n.top})},_getText:function(e){return this.options.template?this._renderTemplate(e):i.htmlEncode(e.text)},_renderTemplate:function(e){return l(this.options.template)({dataItem:e.dataItem,text:e.text})},_createTitle:function(t){return e("<div class='k-treemap-title'></div>").append(e("<div></div>").html(this._getText(t)))},_createWrap:function(){return e("<div class='k-treemap-wrap'></div>")},_tileColorBrightness:function(e){return z(e.color)}}),x=a.extend({createRoot:function(e,t,n,i){e.coord={width:t,height:n,top:0,left:0},e.vertical=i},init:function(e){this.vertical=e,this.quotient=e?1:0},compute:function(e,t,n){if(e.length>0){var i=t.width,r=t.height;this.vertical?r-=n.text:i-=n.text;var o={width:i,height:r,top:0,left:0};this.layoutChildren(e,o)}},layoutChildren:function(e,t){var n,i=t.width*t.height,r=0,o=[];for(n=0;n<e.length;n++){var a=e[n];o[n]=parseFloat(e[n].value),r+=o[n],a.vertical=this.vertical}for(n=0;n<o.length;n++)e[n].area=i*o[n]/r;this.sliceAndDice(e,t)},sliceAndDice:function(e,t){var n=this._totalArea(e);e[0].level%2===this.quotient?this.layoutHorizontal(e,t,n):this.layoutVertical(e,t,n)},layoutHorizontal:function(e,t,n){for(var i=0,r=0;r<e.length;r++){var o=e[r],a=o.area/(n/t.width);o.coord={height:t.height,width:a,top:t.top,left:t.left+i},i+=a}},layoutVertical:function(e,t,n){for(var i=0,r=0;r<e.length;r++){var o=e[r],a=o.area/(n/t.height);o.coord={height:a,width:t.width,top:t.top+i,left:t.left},i+=a}},_totalArea:function(e){for(var t=0,n=0;n<e.length;n++)t+=e[n].area;return t}}),C=k.extend({htmlSize:function(e){var t=this._getByUid(e.dataItem.uid),n={text:0,offset:0};if(e.children){if(this._clean(t),this._getText(e)){var i=this._createTitle(e);t.append(i),this._compile(i,e.dataItem),e.vertical?n.text=i.height():n.text=i.width()}t.append(this._createWrap()),this.offset=(o(t)-t.innerWidth())/2}return n},titleSize:function(e,t){return(e.vertical?t.children(".k-treemap-title").height():t.children(".k-treemap-title-vertical").width())||0},_createTitle:function(t){return(t.vertical?e("<div class='k-treemap-title'></div>"):e("<div class='k-treemap-title-vertical'></div>")).append(e("<div></div>").html(this._getText(t)))}});function S(e,t){return null===t?t:u(e,!0)(t)}function T(e){return void 0!==e}function D(e,n,i,r,o){var a=t.min(t.abs(e),t.abs(n)),s=t.max(t.abs(e),t.abs(n)),l=(s-a)/(r+1)*(i+1);return o?a+l:s-l}function A(e){return"#"+E(e.r)+E(e.g)+E(e.b)}function M(e){var t=function(e){var t=e.length,n={};3===t?(n.r=e[0],n.g=e[1],n.b=e[2]):(n.r=e.substring(0,2),n.g=e.substring(2,4),n.b=e.substring(4,6));return n}(e=e.replace("#",""));return{r:I(t.r),g:I(t.g),b:I(t.b)}}function E(e){var n=t.round(e).toString(16).toUpperCase();return 1===n.length&&(n="0"+n),n}function I(e){return parseInt(e.toString(16),16)}function z(e){var n=0;return e&&(e=M(e),n=t.sqrt(.241*e.r*e.r+.691*e.g*e.g+.068*e.b*e.b)),n}function P(e){var n=t.pow(10,4);return t.round(e*n)/n}h.ui.plugin(y)}(window.kendo.jQuery);kendo,kendo,kendo;return kendo}));
//# sourceMappingURL=kendo.all.min.js.map

/** 
 * Kendo UI v2019.2.514 (http://www.telerik.com/kendo-ui)                                                                                                                                               
 * Copyright 2019 Progress Software Corporation and/or one of its subsidiaries or affiliates. All rights reserved.                                                                                      
 *                                                                                                                                                                                                      
 * Kendo UI commercial licenses may be obtained at                                                                                                                                                      
 * http://www.telerik.com/purchase/license-agreement/kendo-ui-complete                                                                                                                                  
 * If you do not own a commercial license, this file shall be governed by the trial license terms.                                                                                                      
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       

*/
!function(e,define){define("aspnetmvc/kendo.data.aspnetmvc.min",["kendo.data.min","kendo.combobox.min","kendo.multiselect.min","kendo.validator.min"],e)}(function(){!function(e,t){function n(t,n,r){var o,i={};return t.sort?(i[this.options.prefix+"sort"]=e.map(t.sort,function(e){return e.field+"-"+e.dir}).join("~"),delete t.sort):i[this.options.prefix+"sort"]="",t.page&&(i[this.options.prefix+"page"]=t.page,delete t.page),t.pageSize&&(i[this.options.prefix+"pageSize"]=t.pageSize,delete t.pageSize),t.group?(i[this.options.prefix+"group"]=e.map(t.group,function(e){return e.field+"-"+e.dir}).join("~"),delete t.group):i[this.options.prefix+"group"]="",t.aggregate&&(i[this.options.prefix+"aggregate"]=e.map(t.aggregate,function(e){return e.field+"-"+e.aggregate}).join("~"),delete t.aggregate),t.filter?(i[this.options.prefix+"filter"]=a(t.filter,r.encode),delete t.filter):(i[this.options.prefix+"filter"]="",delete t.filter),delete t.take,delete t.skip,o=new g(r),o.serialize(i,t,""),i}function a(n,o){return n.filters?e.map(n.filters,function(e){var t=e.filters&&e.filters.length>1,n=a(e,o);return n&&t&&(n="("+n+")"),n}).join("~"+n.logic+"~"):n.field?n.field+"~"+n.operator+"~"+r(n.value,o):t}function r(e,t){if("string"==typeof e){if(!(e.indexOf("Date(")>-1))return e=e.replace(f,"''"),t&&(e=encodeURIComponent(e)),"'"+e+"'";e=new Date(parseInt(e.replace(/^\/Date\((.*?)\)\/$/,"$1"),10))}return e&&e.getTime?"datetime'"+c.format("{0:yyyy-MM-ddTHH-mm-ss}",e)+"'":e}function o(e,n){return t!==e?e:n}function i(t){var n=t.HasSubgroups||t.hasSubgroups||!1,a=t.Items||t.items;return{value:o(t.Key,o(t.key,t.value)),field:t.Member||t.member||t.field,hasSubgroups:n,aggregates:d(t.Aggregates||t.aggregates),items:n?e.map(a,i):a}}function s(e){var t={};return t[e.AggregateMethodName.toLowerCase()]=e.Value,t}function d(e){var t,n,a,r={};for(t in e){r={},a=e[t];for(n in a)r[n.toLowerCase()]=a[n];e[t]=r}return e}function u(e){var t,n,a,r={};for(t=0,n=e.length;t<n;t++)a=e[t],r[a.Member]=l(!0,r[a.Member],s(a));return r}var c=window.kendo,f=/'/gi,l=e.extend,p=e.isArray,m=e.isPlainObject,v=".",g=function(e){e=e||{},this.culture=e.culture||c.culture(),this.stringifyDates=e.stringifyDates,this.decimalSeparator=this.culture.numberFormat[v]};g.prototype=g.fn={serialize:function(e,t,n){var a,r;for(r in t)a=n?n+"."+r:r,this.serializeField(e,t[r],t,r,a)},serializeField:function(e,n,a,r,o){p(n)?this.serializeArray(e,n,o):m(n)?this.serialize(e,n,o):e[o]===t&&(e[o]=a[r]=this.serializeValue(n))},serializeArray:function(e,t,n){var a,r,o,i,s;for(i=0,s=0;i<t.length;i++)a=t[i],r="["+s+"]",o=n+r,this.serializeField(e,a,t,r,o),s++},serializeValue:function(e){return e instanceof Date?e=this.stringifyDates?c.stringify(e).replace(/"/g,""):c.toString(e,"G",this.culture.name):"number"==typeof e&&(e=(""+e).replace(v,this.decimalSeparator)),e}},l(!0,c.data,{schemas:{"aspnetmvc-ajax":{groups:function(t){return e.map(this._dataAccessFunction(t),i)},aggregates:function(t){var n,a;if(t=t.d||t,n=t.AggregateResults||[],!e.isArray(n)){for(a in n)n[a]=u(n[a]);return n}return u(n)}}}}),l(!0,c.data,{transports:{"aspnetmvc-ajax":c.data.RemoteTransport.extend({init:function(e){var t=this,a=(e||{}).stringifyDates;c.data.RemoteTransport.fn.init.call(this,l(!0,{},this.options,e,{parameterMap:function(e,r){return n.call(t,e,r,{encode:!1,stringifyDates:a})}}))},read:function(e){var t=this.options.data,n=this.options.read.url;m(t)?(n&&(this.options.data=null),!t.Data.length&&n?c.data.RemoteTransport.fn.read.call(this,e):e.success(t)):c.data.RemoteTransport.fn.read.call(this,e)},options:{read:{type:"POST"},update:{type:"POST"},create:{type:"POST"},destroy:{type:"POST"},parameterMap:n,prefix:""}})}}),l(!0,c.data,{schemas:{webapi:c.data.schemas["aspnetmvc-ajax"]}}),l(!0,c.data,{transports:{webapi:c.data.RemoteTransport.extend({init:function(e){var t,a,r=this,o=(e||{}).stringifyDates;e.update&&(t="string"==typeof e.update?e.update:e.update.url,e.update=l(e.update,{url:function(n){return c.format(t,n[e.idField])}})),e.destroy&&(a="string"==typeof e.destroy?e.destroy:e.destroy.url,e.destroy=l(e.destroy,{url:function(t){return c.format(a,t[e.idField])}})),e.create&&"string"==typeof e.create&&(e.create={url:e.create}),c.data.RemoteTransport.fn.init.call(this,l(!0,{},this.options,e,{parameterMap:function(e,t){return n.call(r,e,t,{encode:!1,stringifyDates:o,culture:c.cultures["en-US"]})}}))},read:function(e){var t=this.options.data,n=this.options.read.url;m(t)?(n&&(this.options.data=null),!t.Data.length&&n?c.data.RemoteTransport.fn.read.call(this,e):e.success(t)):c.data.RemoteTransport.fn.read.call(this,e)},options:{read:{type:"GET"},update:{type:"PUT"},create:{type:"POST"},destroy:{type:"DELETE"},parameterMap:n,prefix:""}})}}),l(!0,c.data,{transports:{"aspnetmvc-server":c.data.RemoteTransport.extend({init:function(e){var t=this;c.data.RemoteTransport.fn.init.call(this,l(e,{parameterMap:function(e,a){return n.call(t,e,a,{encode:!0})}}))},read:function(t){var n,a,r=this.options.prefix,o=[r+"sort",r+"page",r+"pageSize",r+"group",r+"aggregate",r+"filter"],i=RegExp("("+o.join("|")+")=[^&]*&?","g");a=location.search.replace(i,"").replace("?",""),a.length&&!/&$/.test(a)&&(a+="&"),t=this.setup(t,"read"),n=t.url,n.indexOf("?")>=0?(a=a.replace(/(.*?=.*?)&/g,function(e){return n.indexOf(e.substr(0,e.indexOf("=")))>=0?"":e}),n+="&"+a):n+="?"+a,n+=e.map(t.data,function(e,t){return t+"="+e}).join("&"),location.href=n}})}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("aspnetmvc/kendo.combobox.aspnetmvc.min",["aspnetmvc/kendo.data.aspnetmvc.min"],e)}(function(){!function(e,t){var n=window.kendo,a=n.ui;a&&a.ComboBox&&(a.ComboBox.requestData=function(t){var n,a,r=e(t).data("kendoComboBox");if(r)return n=r.dataSource.filter(),a=r.input.val(),n&&n.filters.length||(a=""),{text:a}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("aspnetmvc/kendo.multicolumncombobox.aspnetmvc.min",["aspnetmvc/kendo.data.aspnetmvc.min"],e)}(function(){!function(e,t){var n=window.kendo,a=n.ui;a&&a.MultiColumnComboBox&&(a.MultiColumnComboBox.requestData=function(t){var n,a,r=e(t).data("kendoMultiColumnComboBox");if(r)return n=r.dataSource.filter(),a=r.input.val(),n&&n.filters.length||(a=""),{text:a}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("aspnetmvc/kendo.dropdownlist.aspnetmvc.min",["aspnetmvc/kendo.data.aspnetmvc.min"],e)}(function(){!function(e,t){var n=window.kendo,a=n.ui;a&&a.DropDownList&&(a.DropDownList.requestData=function(t){var n,a,r,o=e(t).data("kendoDropDownList");if(o)return n=o.dataSource.filter(),a=o.filterInput,r=a?a.val():"",n&&n.filters.length||(r=""),{text:r}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("aspnetmvc/kendo.dropdowntree.aspnetmvc.min",["aspnetmvc/kendo.data.aspnetmvc.min"],e)}(function(){!function(e,t){var n=window.kendo,a=n.ui;a&&a.DropDownTree&&(a.DropDownTree.requestData=function(t){var n,a,r,o=e(t).data("kendoDropDownTree");if(o)return n=o.dataSource.filter(),a=o.filterInput,r=a?a.val():"",n&&n.filters.length||(r=""),{text:r}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("aspnetmvc/kendo.multiselect.aspnetmvc.min",["aspnetmvc/kendo.combobox.aspnetmvc.min"],e)}(function(){!function(e,t){var n=window.kendo,a=n.ui;a&&a.MultiSelect&&(a.MultiSelect.requestData=function(t){var n,a=e(t).data("kendoMultiSelect");if(a)return n=a.input.val(),{text:n!==a.options.placeholder?n:""}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("aspnetmvc/kendo.imagebrowser.aspnetmvc.min",["aspnetmvc/kendo.multiselect.aspnetmvc.min"],e)}(function(){!function(e,t){var n=window.kendo,a=e.extend,r=e.isFunction;a(!0,n.data,{schemas:{"imagebrowser-aspnetmvc":{data:function(e){return e||[]},model:{id:"name",fields:{name:{field:"Name"},size:{field:"Size"},type:{field:"EntryType",parse:function(e){return 0==e?"f":"d"}}}}}}}),a(!0,n.data,{schemas:{"filebrowser-aspnetmvc":n.data.schemas["imagebrowser-aspnetmvc"]}}),a(!0,n.data,{transports:{"imagebrowser-aspnetmvc":n.data.RemoteTransport.extend({init:function(t){n.data.RemoteTransport.fn.init.call(this,e.extend(!0,{},this.options,t))},_call:function(t,a){a.data=e.extend({},a.data,{path:this.options.path()}),r(this.options[t])?this.options[t].call(this,a):n.data.RemoteTransport.fn[t].call(this,a)},read:function(e){this._call("read",e)},create:function(e){this._call("create",e)},destroy:function(e){this._call("destroy",e)},update:function(){},options:{read:{type:"POST"},update:{type:"POST"},create:{type:"POST"},destroy:{type:"POST"},parameterMap:function(e,t){return"read"!=t&&(e.EntryType="f"===e.EntryType?0:1),e}}})}}),a(!0,n.data,{transports:{"filebrowser-aspnetmvc":n.data.transports["imagebrowser-aspnetmvc"]}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("aspnetmvc/kendo.validator.aspnetmvc.min",["aspnetmvc/kendo.imagebrowser.aspnetmvc.min"],e)}(function(){!function(e,t){function n(){var e,t={};for(e in m)t["mvc"+e]=s(e);return t}function a(){var e,t={};for(e in m)t["mvc"+e]=d(e);return t}function r(e,t){var n,a,r,o={},i=e.data(),s=t.length;for(r in i)a=r.toLowerCase(),n=a.indexOf(t),n>-1&&(a=a.substring(n+s,r.length),a&&(o[a]=i[r]));return o}function o(t){var n,a,r=t.Fields||[],o={};for(n=0,a=r.length;n<a;n++)e.extend(!0,o,i(r[n]));return o}function i(e){var t,n,a,r,o={},i={},s=e.FieldName,d=e.ValidationRules;for(a=0,r=d.length;a<r;a++)t=d[a].ValidationType,n=d[a].ValidationParameters,o[s+t]=c(s,t,n),i[s+t]=u(d[a].ErrorMessage);return{rules:o,messages:i}}function s(e){return function(t){return t.attr("data-val-"+e)}}function d(e){return function(t){return!t.filter("[data-val-"+e+"]").length||m[e](t,r(t,e))}}function u(e){return function(){return e}}function c(e,t,n){return function(a){return!a.filter("[name="+e+"]").length||m[t](a,n)}}function f(e,t){return"string"==typeof t&&(t=RegExp("^(?:"+t+")$")),t.test(e)}var l=/("|\%|'|\[|\]|\$|\.|\,|\:|\;|\+|\*|\&|\!|\#|\(|\)|<|>|\=|\?|\@|\^|\{|\}|\~|\/|\||`)/g,p=".k-switch",m={required:function(e){var t,n,a,r=e.val(),o=e.filter("[type=checkbox]");return o.length&&(t=o[0].name.replace(l,"\\$1"),n="input:hidden[name='"+t+"']",o.closest(p).length&&(o=o.closest(p)),a=o.next(n),a.length||(a=o.next("label.k-checkbox-label").next(n)),r=a.length?a.val():e.prop("checked")===!0),!(""===r||!r||0===r.length)},number:function(e){return""===e.val()||null==e.val()||null!==kendo.parseFloat(e.val())},regex:function(e,t){return""===e.val()||f(e.val(),t.pattern)},range:function(e,t){return""===e.val()||this.min(e,t)&&this.max(e,t)},min:function(e,t){var n=parseFloat(t.min)||0,a=kendo.parseFloat(e.val());return n<=a},max:function(e,t){var n=parseFloat(t.max)||0,a=kendo.parseFloat(e.val());return a<=n},date:function(e){return""===e.val()||null!==kendo.parseDate(e.val())},length:function(t,n){if(""!==t.val()){var a=e.trim(t.val()).length;return(!n.min||a>=(n.min||0))&&(!n.max||a<=(n.max||0))}return!0}};e.extend(!0,kendo.ui.validator,{rules:a(),messages:n(),messageLocators:{mvcLocator:{locate:function(e,t){return t=t.replace(l,"\\$1"),e.find(".field-validation-valid[data-valmsg-for='"+t+"'], .field-validation-error[data-valmsg-for='"+t+"']")},decorate:function(e,t){e.addClass("field-validation-error").attr("data-valmsg-for",t||"")}},mvcMetadataLocator:{locate:function(e,t){return t=t.replace(l,"\\$1"),e.find("#"+t+"_validationMessage.field-validation-valid")},decorate:function(e,t){e.addClass("field-validation-error").attr("id",t+"_validationMessage")}}},ruleResolvers:{mvcMetaDataResolver:{resolve:function(t){var n,a=window.mvcClientValidationMetadata||[];if(a.length)for(t=e(t),n=0;n<a.length;n++)if(a[n].FormId==t.attr("id"))return o(a[n]);return{}}}}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.aspnetmvc.min",["kendo.data.min","kendo.combobox.min","kendo.dropdownlist.min","kendo.dropdowntree.min","kendo.multiselect.min","kendo.validator.min","aspnetmvc/kendo.data.aspnetmvc.min","aspnetmvc/kendo.combobox.aspnetmvc.min","aspnetmvc/kendo.multicolumncombobox.aspnetmvc.min","aspnetmvc/kendo.dropdownlist.aspnetmvc.min","aspnetmvc/kendo.dropdowntree.aspnetmvc.min","aspnetmvc/kendo.multiselect.aspnetmvc.min","aspnetmvc/kendo.imagebrowser.aspnetmvc.min","aspnetmvc/kendo.validator.aspnetmvc.min"],e)}(function(){!function(e,t){function n(t){kendo.__documentIsReady?t():e(t)}var a=e.extend;e(function(){kendo.__documentIsReady=!0}),a(kendo,{syncReady:n})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()});
//# sourceMappingURL=kendo.aspnetmvc.min.js.map

